@il4mb/css-tokenizer 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
1
|
+
export type * from "./type";
|
|
2
|
+
export * from "./registry";
|
|
3
|
+
export * from "./tokenizer";
|
|
3
4
|
export * from "./tools";
|
|
4
5
|
export * from "./tupleList";
|
|
5
|
-
export declare const
|
|
6
|
+
export declare const tokenizeImpl: (content: string) => import("./tupleList").TupleList;
|
package/dist/types/registry.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { ModelDefinition } from "./type";
|
|
1
|
+
import { Exp, ModelDefinition } from "./type";
|
|
2
2
|
export declare class Registry implements Iterable<ModelDefinition> {
|
|
3
|
-
private items;
|
|
3
|
+
private readonly items;
|
|
4
4
|
constructor(models?: ModelDefinition[]);
|
|
5
|
+
all(): ModelDefinition[];
|
|
5
6
|
add(def: ModelDefinition): void;
|
|
6
7
|
get(index: number): ModelDefinition;
|
|
7
8
|
get length(): number;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Registry } from "./registry";
|
|
2
2
|
import { TupleList } from "./tupleList";
|
|
3
|
-
import { ModelDefinition } from "./type";
|
|
3
|
+
import { Exp, ModelDefinition, TRange, Tuple } from "./type";
|
|
4
4
|
export declare class Tokenizer {
|
|
5
5
|
registry: Registry;
|
|
6
6
|
constructor(registry: Registry);
|
package/dist/types/tools.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
export declare
|
|
1
|
+
export declare const CSS_NAMED_COLORS: string[];
|
|
2
|
+
export declare const COLOR_FUNCTIONS: RegExp[];
|
|
3
|
+
export declare const HEX_COLOR: RegExp;
|
|
4
|
+
export declare const CSS_UNITS: string[];
|
|
5
|
+
export declare const findFunctionEnd: (source: string, index: number) => number;
|
|
2
6
|
export declare const readWhile: (content: string, index: number, test: RegExp) => number;
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
import { Registry } from "./registry";
|
|
2
|
-
|
|
3
|
-
type: string;
|
|
4
|
-
start: number;
|
|
5
|
-
end: number;
|
|
6
|
-
value: string;
|
|
7
|
-
children?: TokenTree[];
|
|
8
|
-
};
|
|
2
|
+
import { Token, TokenTree, Tuple } from "./type";
|
|
9
3
|
export declare class TupleList {
|
|
10
4
|
protected registry: Registry;
|
|
11
5
|
protected items: Tuple[];
|
|
12
6
|
constructor(registry: Registry);
|
|
13
7
|
push(...items: Tuple[]): void;
|
|
14
8
|
toArray(): Tuple[];
|
|
15
|
-
toTokenList(content: string):
|
|
9
|
+
toTokenList(content: string): Token[];
|
|
16
10
|
toTokenTree(content: string): TokenTree[];
|
|
17
11
|
}
|