From 06823fbf1c2e763a5bf76c3990ca98fbbcd98691 Mon Sep 17 00:00:00 2001 From: littleblack111 Date: Tue, 14 May 2024 14:05:49 +0800 Subject: updated node_modules --- .../css-parser-algorithms/dist/index.d.ts | 43 +++++++++------------- 1 file changed, 17 insertions(+), 26 deletions(-) (limited to 'node_modules/@csstools/css-parser-algorithms/dist/index.d.ts') diff --git a/node_modules/@csstools/css-parser-algorithms/dist/index.d.ts b/node_modules/@csstools/css-parser-algorithms/dist/index.d.ts index 9759d057..9889d9ea 100644 --- a/node_modules/@csstools/css-parser-algorithms/dist/index.d.ts +++ b/node_modules/@csstools/css-parser-algorithms/dist/index.d.ts @@ -15,7 +15,7 @@ * Parse a string of CSS into a component value: * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseComponentValue } from '@csstools/css-parser'; + * import { parseComponentValue } from '@csstools/css-parser-algorithms'; * * const myCSS = `calc(1px * 2)`; * @@ -35,15 +35,15 @@ * If your context allows a list of component values, use {@link parseListOfComponentValues}: * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseListOfComponentValues } from '@csstools/css-parser'; + * import { parseListOfComponentValues } from '@csstools/css-parser-algorithms'; * - * parseComponentValue(tokenize({ css: `10x 20px` })); + * parseListOfComponentValues(tokenize({ css: `10x 20px` })); * ``` * * If your context allows a comma-separated list of component values, use {@link parseCommaSeparatedListOfComponentValues}: * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseCommaSeparatedListOfComponentValues } from '@csstools/css-parser'; + * import { parseCommaSeparatedListOfComponentValues } from '@csstools/css-parser-algorithms'; * * parseCommaSeparatedListOfComponentValues(tokenize({ css: `20deg, 50%, 30%` })); * ``` @@ -53,7 +53,7 @@ * * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseComponentValue, isSimpleBlockNode } from '@csstools/css-parser'; + * import { parseComponentValue, isSimpleBlockNode } from '@csstools/css-parser-algorithms'; * * const myCSS = `calc(1px * (5 / 2))`; * @@ -106,10 +106,7 @@ export declare class CommentNode { * A debug helper to convert the current object to a JSON representation. * This is useful in asserts and to store large ASTs in files. */ - toJSON(): { - type: ComponentValueType; - tokens: CSSToken[]; - }; + toJSON(): Record; /** * @internal */ @@ -344,14 +341,14 @@ export declare function isWhitespaceNode(x: unknown): x is WhitespaceNode; * @example * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseCommaSeparatedListOfComponentValues } from '@csstools/css-parser'; + * import { parseCommaSeparatedListOfComponentValues } from '@csstools/css-parser-algorithms'; * * parseCommaSeparatedListOfComponentValues(tokenize({ css: `20deg, 50%, 30%` })); * ``` */ export declare function parseCommaSeparatedListOfComponentValues(tokens: Array, options?: { onParseError?: (error: ParseError) => void; -}): ComponentValue[][]; +}): Array>; /** * Parse a single component value. @@ -359,7 +356,7 @@ export declare function parseCommaSeparatedListOfComponentValues(tokens: Array, options?: { * @example * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseListOfComponentValues } from '@csstools/css-parser'; + * import { parseListOfComponentValues } from '@csstools/css-parser-algorithms'; * * parseListOfComponentValues(tokenize({ css: `20deg 30%` })); * ``` */ export declare function parseListOfComponentValues(tokens: Array, options?: { onParseError?: (error: ParseError) => void; -}): ComponentValue[]; +}): Array; /** * Replace specific component values in a list of component values. * A helper for the most common and simplistic cases when mutating an AST. */ -export declare function replaceComponentValues(componentValuesList: Array>, replaceWith: (componentValue: ComponentValue) => ComponentValue | void): ComponentValue[][]; +export declare function replaceComponentValues(componentValuesList: Array>, replaceWith: (componentValue: ComponentValue) => Array | ComponentValue | void): Array>; /** * A simple block node. @@ -479,7 +476,7 @@ export declare class TokenNode { /** * This is the inverse of parsing from a list of tokens. */ - tokens(): Array; + tokens(): [CSSToken]; /** * Convert the current token to a string. * This is not a true serialization. @@ -492,14 +489,11 @@ export declare class TokenNode { * A debug helper to convert the current object to a JSON representation. * This is useful in asserts and to store large ASTs in files. */ - toJSON(): { - type: ComponentValueType; - tokens: CSSToken[]; - }; + toJSON(): Record; /** * @internal */ - isTokenNode(): this is TokenNode; + isTokenNod(): this is TokenNode; /** * @internal */ @@ -524,7 +518,7 @@ export declare class TokenNode { * @example * ```js * import { tokenize } from '@csstools/css-tokenizer'; - * import { parseListOfComponentValues, isSimpleBlockNode } from '@csstools/css-parser'; + * import { parseListOfComponentValues, isSimpleBlockNode } from '@csstools/css-parser-algorithms'; * * const myCSS = `calc(1px * (5 / 2)) 10px`; * @@ -590,10 +584,7 @@ export declare class WhitespaceNode { * A debug helper to convert the current object to a JSON representation. * This is useful in asserts and to store large ASTs in files. */ - toJSON(): { - type: ComponentValueType; - tokens: CSSToken[]; - }; + toJSON(): Record; /** * @internal */ -- cgit v1.2.3