2024-04-03 21:14:44 +00:00
|
|
|
/**
|
|
|
|
* All of the deprecation types currently used by Sass.
|
|
|
|
*
|
|
|
|
* Any of these IDs or the deprecation objects they point to can be passed to
|
|
|
|
* `fatalDeprecations`, `futureDeprecations`, or `silenceDeprecations`.
|
|
|
|
*/
|
|
|
|
export interface Deprecations {
|
2024-05-29 21:23:18 +00:00
|
|
|
// START AUTOGENERATED LIST
|
2024-09-17 22:41:07 +00:00
|
|
|
// Checksum: 0243e0f7ee85127d6e1bda5c08e363509959e758
|
2024-05-29 21:23:18 +00:00
|
|
|
|
2024-04-03 21:14:44 +00:00
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for passing a string directly to meta.call().
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
2024-05-29 21:23:18 +00:00
|
|
|
* This deprecation was active in the first version of Dart Sass.
|
2024-04-03 21:14:44 +00:00
|
|
|
*/
|
|
|
|
'call-string': Deprecation<'call-string'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for @elseif.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.3.2.
|
|
|
|
*/
|
|
|
|
elseif: Deprecation<'elseif'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for @-moz-document.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.7.2.
|
|
|
|
*/
|
|
|
|
'moz-document': Deprecation<'moz-document'>;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Deprecation for imports using relative canonical URLs.
|
|
|
|
*
|
2024-05-29 21:23:18 +00:00
|
|
|
* This deprecation became active in Dart Sass 1.14.2.
|
2024-04-03 21:14:44 +00:00
|
|
|
*/
|
|
|
|
'relative-canonical': Deprecation<'relative-canonical'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for declaring new variables with !global.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.17.2.
|
|
|
|
*/
|
|
|
|
'new-global': Deprecation<'new-global'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for using color module functions in place of plain CSS functions.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.23.0.
|
|
|
|
*/
|
|
|
|
'color-module-compat': Deprecation<'color-module-compat'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for / operator for division.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.33.0.
|
|
|
|
*/
|
|
|
|
'slash-div': Deprecation<'slash-div'>;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Deprecation for leading, trailing, and repeated combinators.
|
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.54.0.
|
|
|
|
*/
|
|
|
|
'bogus-combinators': Deprecation<'bogus-combinators'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for ambiguous + and - operators.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.55.0.
|
|
|
|
*/
|
|
|
|
'strict-unary': Deprecation<'strict-unary'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for passing invalid units to built-in functions.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.56.0.
|
|
|
|
*/
|
|
|
|
'function-units': Deprecation<'function-units'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for using !default or !global multiple times for one variable.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.62.0.
|
|
|
|
*/
|
|
|
|
'duplicate-var-flags': Deprecation<'duplicate-var-flags'>;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Deprecation for passing null as alpha in the JS API.
|
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.62.3.
|
|
|
|
*/
|
|
|
|
'null-alpha': Deprecation<'null-alpha'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for passing percentages to the Sass abs() function.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.65.0.
|
|
|
|
*/
|
|
|
|
'abs-percent': Deprecation<'abs-percent'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for using the current working directory as an implicit load path.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.73.0.
|
|
|
|
*/
|
|
|
|
'fs-importer-cwd': Deprecation<'fs-importer-cwd'>;
|
|
|
|
|
2024-04-11 23:23:20 +00:00
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for function and mixin names beginning with --.
|
2024-04-11 23:23:20 +00:00
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.76.0.
|
|
|
|
*/
|
2024-04-30 21:19:57 +00:00
|
|
|
'css-function-mixin': Deprecation<'css-function-mixin'>;
|
|
|
|
|
2024-06-19 00:08:12 +00:00
|
|
|
/**
|
|
|
|
* Deprecation for declarations after or between nested rules.
|
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.77.7.
|
|
|
|
*/
|
2024-06-19 02:44:39 +00:00
|
|
|
'mixed-decls': Deprecation<'mixed-decls'>;
|
2024-06-19 00:08:12 +00:00
|
|
|
|
2024-08-20 00:57:51 +00:00
|
|
|
/**
|
|
|
|
* Deprecation for meta.feature-exists
|
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.78.0.
|
|
|
|
*/
|
|
|
|
'feature-exists': Deprecation<'feature-exists'>;
|
|
|
|
|
2024-05-30 01:21:23 +00:00
|
|
|
/**
|
|
|
|
* Deprecation for certain uses of built-in sass:color functions.
|
|
|
|
*
|
2024-08-12 19:16:09 +00:00
|
|
|
* This deprecation became active in Dart Sass 1.79.0.
|
2024-05-30 01:21:23 +00:00
|
|
|
*/
|
2024-04-11 23:23:20 +00:00
|
|
|
'color-4-api': Deprecation<'color-4-api'>;
|
|
|
|
|
|
|
|
/**
|
2024-05-30 01:21:23 +00:00
|
|
|
* Deprecation for using global color functions instead of sass:color.
|
2024-04-11 23:23:20 +00:00
|
|
|
*
|
2024-08-12 19:16:09 +00:00
|
|
|
* This deprecation became active in Dart Sass 1.79.0.
|
2024-04-11 23:23:20 +00:00
|
|
|
*/
|
|
|
|
'color-functions': Deprecation<'color-functions'>;
|
|
|
|
|
2024-09-17 22:41:07 +00:00
|
|
|
/**
|
|
|
|
* Deprecation for legacy JS API.
|
|
|
|
*
|
|
|
|
* This deprecation became active in Dart Sass 1.79.0.
|
|
|
|
*/
|
|
|
|
'legacy-js-api': Deprecation<'legacy-js-api'>;
|
|
|
|
|
2024-04-03 21:14:44 +00:00
|
|
|
/**
|
2024-05-29 21:23:18 +00:00
|
|
|
* Deprecation for @import rules.
|
2024-04-03 21:14:44 +00:00
|
|
|
*
|
|
|
|
* This deprecation is not yet active, but will be soon.
|
|
|
|
*/
|
|
|
|
import: Deprecation<'import'>;
|
|
|
|
|
2024-09-05 23:23:49 +00:00
|
|
|
/**
|
|
|
|
* Deprecation for global built-in functions that are available in sass: modules.
|
|
|
|
*
|
|
|
|
* This deprecation is not yet active, but will be soon.
|
|
|
|
*/
|
|
|
|
'global-builtin': Deprecation<'global-builtin'>;
|
|
|
|
|
2024-05-29 21:23:18 +00:00
|
|
|
// END AUTOGENERATED LIST
|
|
|
|
|
2024-04-03 21:14:44 +00:00
|
|
|
/**
|
|
|
|
* Used for any user-emitted deprecation warnings.
|
|
|
|
*/
|
|
|
|
'user-authored': Deprecation<'user-authored', 'user'>;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Either a deprecation or its ID, either of which can be passed to any of
|
|
|
|
* the relevant compiler options.
|
|
|
|
*
|
|
|
|
* @category Messages
|
|
|
|
* @compatibility dart: "1.74.0", node: false
|
|
|
|
*/
|
|
|
|
export type DeprecationOrId = Deprecation | keyof Deprecations;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The possible statuses that each deprecation can have.
|
|
|
|
*
|
|
|
|
* "active" deprecations are currently emitting deprecation warnings.
|
|
|
|
* "future" deprecations are not yet active, but will be in the future.
|
|
|
|
* "obsolete" deprecations were once active, but no longer are.
|
|
|
|
*
|
|
|
|
* The only "user" deprecation is "user-authored", which is used for deprecation
|
|
|
|
* warnings coming from user code.
|
|
|
|
*
|
|
|
|
* @category Messages
|
|
|
|
* @compatibility dart: "1.74.0", node: false
|
|
|
|
*/
|
|
|
|
export type DeprecationStatus = 'active' | 'user' | 'future' | 'obsolete';
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A deprecated feature in the language.
|
|
|
|
*
|
|
|
|
* @category Messages
|
|
|
|
* @compatibility dart: "1.74.0", node: false
|
|
|
|
*/
|
|
|
|
export interface Deprecation<
|
|
|
|
id extends keyof Deprecations = keyof Deprecations,
|
|
|
|
status extends DeprecationStatus = DeprecationStatus
|
|
|
|
> {
|
|
|
|
/** The unique ID of this deprecation. */
|
|
|
|
id: id;
|
|
|
|
|
|
|
|
/** The current status of this deprecation. */
|
|
|
|
status: status;
|
|
|
|
|
|
|
|
/** A human-readable description of this deprecation. */
|
|
|
|
description?: string;
|
|
|
|
|
|
|
|
/** The version this deprecation first became active in. */
|
|
|
|
deprecatedIn: status extends 'future' | 'user' ? null : Version;
|
|
|
|
|
|
|
|
/** The version this deprecation became obsolete in. */
|
|
|
|
obsoleteIn: status extends 'obsolete' ? Version : null;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A semantic version of the compiler.
|
|
|
|
*
|
|
|
|
* @category Messages
|
|
|
|
* @compatibility dart: "1.74.0", node: false
|
|
|
|
*/
|
|
|
|
export class Version {
|
|
|
|
/**
|
|
|
|
* Constructs a new version.
|
|
|
|
*
|
|
|
|
* All components must be non-negative integers.
|
|
|
|
*
|
|
|
|
* @param major - The major version.
|
|
|
|
* @param minor - The minor version.
|
|
|
|
* @param patch - The patch version.
|
|
|
|
*/
|
|
|
|
constructor(major: number, minor: number, patch: number);
|
|
|
|
readonly major: number;
|
|
|
|
readonly minor: number;
|
|
|
|
readonly patch: number;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Parses a version from a string.
|
|
|
|
*
|
|
|
|
* This throws an error if a valid version can't be parsed.
|
|
|
|
*
|
|
|
|
* @param version - A string in the form "major.minor.patch".
|
|
|
|
*/
|
|
|
|
static parse(version: string): Version;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* An object containing all deprecation types.
|
|
|
|
*
|
|
|
|
* @category Messages
|
|
|
|
* @compatibility dart: "1.74.0", node: false
|
|
|
|
*/
|
|
|
|
export const deprecations: Deprecations;
|