@tbela99/css-parser 1.3.3 → 1.4.0
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/CHANGELOG.md +44 -0
- package/README.md +64 -48
- package/dist/config.json.js +3 -0
- package/dist/index-umd-web.js +2266 -631
- package/dist/index.cjs +2271 -620
- package/dist/index.d.ts +522 -181
- package/dist/lib/ast/expand.js +5 -10
- package/dist/lib/ast/features/calc.js +3 -2
- package/dist/lib/ast/features/inlinecssvariables.js +5 -3
- package/dist/lib/ast/features/prefix.js +1 -1
- package/dist/lib/ast/features/shorthand.js +1 -0
- package/dist/lib/ast/features/transform.js +13 -19
- package/dist/lib/ast/features/type.js +1 -1
- package/dist/lib/ast/minify.js +6 -3
- package/dist/lib/ast/transform/compute.js +2 -4
- package/dist/lib/ast/transform/matrix.js +20 -20
- package/dist/lib/ast/transform/minify.js +105 -12
- package/dist/lib/ast/transform/rotate.js +11 -11
- package/dist/lib/ast/transform/scale.js +6 -6
- package/dist/lib/ast/transform/skew.js +4 -4
- package/dist/lib/ast/transform/translate.js +3 -3
- package/dist/lib/ast/transform/utils.js +30 -37
- package/dist/lib/ast/types.js +76 -5
- package/dist/lib/ast/walk.js +77 -58
- package/dist/lib/fs/resolve.js +69 -10
- package/dist/lib/parser/declaration/list.js +6 -1
- package/dist/lib/parser/parse.js +1169 -312
- package/dist/lib/parser/tokenize.js +33 -20
- package/dist/lib/parser/utils/declaration.js +54 -0
- package/dist/lib/parser/utils/hash.js +86 -0
- package/dist/lib/parser/utils/text.js +8 -0
- package/dist/lib/renderer/render.js +26 -7
- package/dist/lib/syntax/color/relativecolor.js +0 -3
- package/dist/lib/syntax/syntax.js +36 -18
- package/dist/lib/validation/at-rules/container.js +11 -0
- package/dist/lib/validation/at-rules/counter-style.js +11 -0
- package/dist/lib/validation/at-rules/font-feature-values.js +11 -0
- package/dist/lib/validation/at-rules/keyframes.js +11 -0
- package/dist/lib/validation/at-rules/layer.js +11 -0
- package/dist/lib/validation/at-rules/media.js +11 -0
- package/dist/lib/validation/at-rules/page-margin-box.js +11 -0
- package/dist/lib/validation/at-rules/page.js +11 -0
- package/dist/lib/validation/at-rules/supports.js +11 -0
- package/dist/lib/validation/at-rules/when.js +11 -0
- package/dist/lib/validation/config.js +0 -2
- package/dist/lib/validation/config.json.js +36 -4
- package/dist/lib/validation/parser/parse.js +53 -2
- package/dist/lib/validation/syntax.js +204 -36
- package/dist/lib/validation/syntaxes/compound-selector.js +1 -2
- package/dist/lib/validation/syntaxes/relative-selector-list.js +2 -5
- package/dist/node.js +60 -18
- package/dist/types.d.ts +17 -0
- package/dist/types.js +20 -0
- package/dist/web.js +43 -17
- package/package.json +20 -17
- package/dist/lib/validation/parser/types.js +0 -54
package/dist/index.d.ts
CHANGED
|
@@ -17,19 +17,31 @@ declare enum ValidationLevel {
|
|
|
17
17
|
* disable validation
|
|
18
18
|
*/
|
|
19
19
|
None = 0,
|
|
20
|
+
/**
|
|
21
|
+
* validate selectors
|
|
22
|
+
*/
|
|
23
|
+
Selector = 1,
|
|
24
|
+
/**
|
|
25
|
+
* validate at-rules
|
|
26
|
+
*/
|
|
27
|
+
AtRule = 2,
|
|
28
|
+
/**
|
|
29
|
+
* validate declarations
|
|
30
|
+
*/
|
|
31
|
+
Declaration = 4,
|
|
20
32
|
/**
|
|
21
33
|
* validate selectors and at-rules
|
|
22
34
|
*/
|
|
23
|
-
Default =
|
|
35
|
+
Default = 3,// selectors + at-rules
|
|
24
36
|
/**
|
|
25
37
|
* validate selectors, at-rules and declarations
|
|
26
38
|
*/
|
|
27
|
-
All =
|
|
39
|
+
All = 7
|
|
28
40
|
}
|
|
29
41
|
/**
|
|
30
42
|
* enum of all token types
|
|
31
43
|
*/
|
|
32
|
-
declare enum EnumToken
|
|
44
|
+
declare enum EnumToken {
|
|
33
45
|
/**
|
|
34
46
|
* comment token
|
|
35
47
|
*/
|
|
@@ -410,6 +422,22 @@ declare enum EnumToken$1 {
|
|
|
410
422
|
* invalid declaration node type
|
|
411
423
|
*/
|
|
412
424
|
InvalidDeclarationNodeType = 94,
|
|
425
|
+
/**
|
|
426
|
+
* composes token node type
|
|
427
|
+
*/
|
|
428
|
+
ComposesSelectorNodeType = 95,
|
|
429
|
+
/**
|
|
430
|
+
* css variable token type
|
|
431
|
+
*/
|
|
432
|
+
CssVariableTokenType = 96,
|
|
433
|
+
/**
|
|
434
|
+
* css variable import token type
|
|
435
|
+
*/
|
|
436
|
+
CssVariableImportTokenType = 97,
|
|
437
|
+
/**
|
|
438
|
+
* css variable declaration map token type
|
|
439
|
+
*/
|
|
440
|
+
CssVariableDeclarationMapTokenType = 98,
|
|
413
441
|
/**
|
|
414
442
|
* alias for time token type
|
|
415
443
|
*/
|
|
@@ -524,7 +552,7 @@ declare enum EnumToken$1 {
|
|
|
524
552
|
*/
|
|
525
553
|
declare enum ColorType {
|
|
526
554
|
/**
|
|
527
|
-
* system colors
|
|
555
|
+
* deprecated system colors
|
|
528
556
|
*/
|
|
529
557
|
SYS = 0,
|
|
530
558
|
/**
|
|
@@ -532,7 +560,7 @@ declare enum ColorType {
|
|
|
532
560
|
*/
|
|
533
561
|
DPSYS = 1,
|
|
534
562
|
/**
|
|
535
|
-
* colors
|
|
563
|
+
* named colors
|
|
536
564
|
*/
|
|
537
565
|
LIT = 2,
|
|
538
566
|
/**
|
|
@@ -632,6 +660,46 @@ declare enum ColorType {
|
|
|
632
660
|
*/
|
|
633
661
|
DEVICE_CMYK = 7
|
|
634
662
|
}
|
|
663
|
+
declare enum ModuleCaseTransformEnum {
|
|
664
|
+
/**
|
|
665
|
+
* export class names as-is
|
|
666
|
+
*/
|
|
667
|
+
IgnoreCase = 1,
|
|
668
|
+
/**
|
|
669
|
+
* transform mapping key name to camel case
|
|
670
|
+
*/
|
|
671
|
+
CamelCase = 2,
|
|
672
|
+
/**
|
|
673
|
+
* transform class names and mapping key name to camel case
|
|
674
|
+
*/
|
|
675
|
+
CamelCaseOnly = 4,
|
|
676
|
+
/**
|
|
677
|
+
* transform mapping key name to dash case
|
|
678
|
+
*/
|
|
679
|
+
DashCase = 8,
|
|
680
|
+
/**
|
|
681
|
+
* transform class names and mapping key name to dash case
|
|
682
|
+
*/
|
|
683
|
+
DashCaseOnly = 16
|
|
684
|
+
}
|
|
685
|
+
declare enum ModuleScopeEnumOptions {
|
|
686
|
+
/**
|
|
687
|
+
* use the global scope
|
|
688
|
+
*/
|
|
689
|
+
Global = 32,
|
|
690
|
+
/**
|
|
691
|
+
* use the local scope
|
|
692
|
+
*/
|
|
693
|
+
Local = 64,
|
|
694
|
+
/**
|
|
695
|
+
* do not allow selector without an id or class
|
|
696
|
+
*/
|
|
697
|
+
Pure = 128,
|
|
698
|
+
/**
|
|
699
|
+
* export using ICSS module format
|
|
700
|
+
*/
|
|
701
|
+
ICSS = 256
|
|
702
|
+
}
|
|
635
703
|
|
|
636
704
|
/**
|
|
637
705
|
* apply minification rules to the ast tree
|
|
@@ -658,18 +726,18 @@ declare enum WalkerOptionEnum {
|
|
|
658
726
|
*/
|
|
659
727
|
Stop = 2,
|
|
660
728
|
/**
|
|
661
|
-
* ignore node and process children
|
|
729
|
+
* ignore the current node and process its children
|
|
662
730
|
*/
|
|
663
731
|
Children = 4,
|
|
664
732
|
/**
|
|
665
|
-
* ignore children
|
|
733
|
+
* ignore the current node children
|
|
666
734
|
*/
|
|
667
735
|
IgnoreChildren = 8
|
|
668
736
|
}
|
|
669
737
|
/**
|
|
670
738
|
* event types for the walkValues function
|
|
671
739
|
*/
|
|
672
|
-
declare enum
|
|
740
|
+
declare enum WalkerEvent {
|
|
673
741
|
/**
|
|
674
742
|
* enter node
|
|
675
743
|
*/
|
|
@@ -709,11 +777,10 @@ declare enum WalkerValueEvent {
|
|
|
709
777
|
* }
|
|
710
778
|
* ```
|
|
711
779
|
*
|
|
712
|
-
* Using a filter to control the
|
|
780
|
+
* Using a {@link filter} function to control the ast traversal. the filter function returns a value of type {@link WalkerOption}.
|
|
713
781
|
*
|
|
714
782
|
* ```ts
|
|
715
|
-
*
|
|
716
|
-
* import {walk} from '@tbela99/css-parser';
|
|
783
|
+
* import {EnumToken, transform, walk, WalkerOptionEnum} from '@tbela99/css-parser';
|
|
717
784
|
*
|
|
718
785
|
* const css = `
|
|
719
786
|
* body { color: color(from var(--base-color) display-p3 r calc(g + 0.24) calc(b + 0.15)); }
|
|
@@ -729,17 +796,28 @@ declare enum WalkerValueEvent {
|
|
|
729
796
|
* }
|
|
730
797
|
* `;
|
|
731
798
|
*
|
|
732
|
-
*
|
|
799
|
+
* function filter(node) {
|
|
733
800
|
*
|
|
734
801
|
* if (node.typ == EnumToken.AstRule && node.sel.includes('html')) {
|
|
735
802
|
*
|
|
736
803
|
* // skip the children of the current node
|
|
737
804
|
* return WalkerOptionEnum.IgnoreChildren;
|
|
738
805
|
* }
|
|
739
|
-
* }
|
|
806
|
+
* }
|
|
740
807
|
*
|
|
741
|
-
*
|
|
808
|
+
* const result = await transform(css);
|
|
809
|
+
* for (const {node} of walk(result.ast, filter)) {
|
|
810
|
+
*
|
|
811
|
+
* console.error([EnumToken[node.typ]]);
|
|
742
812
|
* }
|
|
813
|
+
*
|
|
814
|
+
* // [ "StyleSheetNodeType" ]
|
|
815
|
+
* // [ "RuleNodeType" ]
|
|
816
|
+
* // [ "DeclarationNodeType" ]
|
|
817
|
+
* // [ "RuleNodeType" ]
|
|
818
|
+
* // [ "DeclarationNodeType" ]
|
|
819
|
+
* // [ "RuleNodeType" ]
|
|
820
|
+
* // [ "DeclarationNodeType" ]
|
|
743
821
|
* ```
|
|
744
822
|
*/
|
|
745
823
|
declare function walk(node: AstNode$1, filter?: WalkerFilter | null, reverse?: boolean): Generator<WalkResult>;
|
|
@@ -754,32 +832,46 @@ declare function walk(node: AstNode$1, filter?: WalkerFilter | null, reverse?: b
|
|
|
754
832
|
*
|
|
755
833
|
* ```ts
|
|
756
834
|
*
|
|
757
|
-
* import {EnumToken,
|
|
835
|
+
* import {AstDeclaration, EnumToken, transform, walkValues} from '@tbela99/css-parser';
|
|
758
836
|
*
|
|
759
837
|
* const css = `
|
|
760
838
|
* body { color: color(from var(--base-color) display-p3 r calc(g + 0.24) calc(b + 0.15)); }
|
|
761
|
-
*
|
|
762
|
-
* html,
|
|
763
|
-
* body {
|
|
764
|
-
* line-height: 1.474;
|
|
765
|
-
* }
|
|
766
|
-
*
|
|
767
|
-
* .ruler {
|
|
768
|
-
*
|
|
769
|
-
* height: 10px;
|
|
770
|
-
* }
|
|
771
839
|
* `;
|
|
772
840
|
*
|
|
773
|
-
*
|
|
841
|
+
* const result = await transform(css);
|
|
842
|
+
* const declaration = result.ast.chi[0].chi[0] as AstDeclaration;
|
|
843
|
+
*
|
|
844
|
+
* // walk the node attribute's tokens in reverse order
|
|
845
|
+
* for (const {value} of walkValues(declaration.val, null, null,true)) {
|
|
774
846
|
*
|
|
775
847
|
* console.error([EnumToken[value.typ], value.val]);
|
|
776
848
|
* }
|
|
777
849
|
*
|
|
850
|
+
* // [ "Color", "color" ]
|
|
851
|
+
* // [ "FunctionTokenType", "calc" ]
|
|
852
|
+
* // [ "Number", 0.15 ]
|
|
853
|
+
* // [ "Add", undefined ]
|
|
854
|
+
* // [ "Iden", "b" ]
|
|
855
|
+
* // [ "Whitespace", undefined ]
|
|
856
|
+
* // [ "FunctionTokenType", "calc" ]
|
|
857
|
+
* // [ "Number", 0.24 ]
|
|
858
|
+
* // [ "Add", undefined ]
|
|
859
|
+
* // [ "Iden", "g" ]
|
|
860
|
+
* // [ "Whitespace", undefined ]
|
|
861
|
+
* // [ "Iden", "r" ]
|
|
862
|
+
* // [ "Whitespace", undefined ]
|
|
863
|
+
* // [ "Iden", "display-p3" ]
|
|
864
|
+
* // [ "Whitespace", undefined ]
|
|
865
|
+
* // [ "FunctionTokenType", "var" ]
|
|
866
|
+
* // [ "DashedIden", "--base-color" ]
|
|
867
|
+
* // [ "Whitespace", undefined ]
|
|
868
|
+
* // [ "Iden", "from" ]
|
|
869
|
+
* ```
|
|
778
870
|
*/
|
|
779
871
|
declare function walkValues(values: Token$1[], root?: AstNode$1 | Token$1 | null, filter?: WalkerValueFilter | null | {
|
|
780
|
-
event?:
|
|
872
|
+
event?: WalkerEvent;
|
|
781
873
|
fn?: WalkerValueFilter;
|
|
782
|
-
type?: EnumToken
|
|
874
|
+
type?: EnumToken | EnumToken[] | ((token: Token$1) => boolean);
|
|
783
875
|
}, reverse?: boolean): Generator<WalkAttributesResult>;
|
|
784
876
|
|
|
785
877
|
/**
|
|
@@ -788,7 +880,7 @@ declare function walkValues(values: Token$1[], root?: AstNode$1 | Token$1 | null
|
|
|
788
880
|
*
|
|
789
881
|
* @private
|
|
790
882
|
*/
|
|
791
|
-
declare function expand(ast:
|
|
883
|
+
declare function expand(ast: AstStyleSheet | AstAtRule | AstRule): AstNode$1;
|
|
792
884
|
|
|
793
885
|
/**
|
|
794
886
|
*
|
|
@@ -889,7 +981,7 @@ declare function parseTokens(tokens: Token$1[], options?: ParseTokenOptions): To
|
|
|
889
981
|
*/
|
|
890
982
|
export declare interface LiteralToken extends BaseToken {
|
|
891
983
|
|
|
892
|
-
typ: EnumToken
|
|
984
|
+
typ: EnumToken.LiteralTokenType;
|
|
893
985
|
val: string;
|
|
894
986
|
}
|
|
895
987
|
|
|
@@ -898,7 +990,7 @@ export declare interface LiteralToken extends BaseToken {
|
|
|
898
990
|
*/
|
|
899
991
|
export declare interface ClassSelectorToken extends BaseToken {
|
|
900
992
|
|
|
901
|
-
typ: EnumToken
|
|
993
|
+
typ: EnumToken.ClassSelectorTokenType;
|
|
902
994
|
val: string;
|
|
903
995
|
}
|
|
904
996
|
|
|
@@ -907,7 +999,7 @@ export declare interface ClassSelectorToken extends BaseToken {
|
|
|
907
999
|
*/
|
|
908
1000
|
export declare interface InvalidClassSelectorToken extends BaseToken {
|
|
909
1001
|
|
|
910
|
-
typ: EnumToken
|
|
1002
|
+
typ: EnumToken.InvalidClassSelectorTokenType;
|
|
911
1003
|
val: string;
|
|
912
1004
|
}
|
|
913
1005
|
|
|
@@ -916,7 +1008,7 @@ export declare interface InvalidClassSelectorToken extends BaseToken {
|
|
|
916
1008
|
*/
|
|
917
1009
|
export declare interface UniversalSelectorToken extends BaseToken {
|
|
918
1010
|
|
|
919
|
-
typ: EnumToken
|
|
1011
|
+
typ: EnumToken.UniversalSelectorTokenType;
|
|
920
1012
|
}
|
|
921
1013
|
|
|
922
1014
|
/**
|
|
@@ -924,7 +1016,7 @@ export declare interface UniversalSelectorToken extends BaseToken {
|
|
|
924
1016
|
*/
|
|
925
1017
|
export declare interface IdentToken extends BaseToken {
|
|
926
1018
|
|
|
927
|
-
typ: EnumToken
|
|
1019
|
+
typ: EnumToken.IdenTokenType,
|
|
928
1020
|
val: string;
|
|
929
1021
|
}
|
|
930
1022
|
|
|
@@ -933,7 +1025,7 @@ export declare interface IdentToken extends BaseToken {
|
|
|
933
1025
|
*/
|
|
934
1026
|
export declare interface IdentListToken extends BaseToken {
|
|
935
1027
|
|
|
936
|
-
typ: EnumToken
|
|
1028
|
+
typ: EnumToken.IdenListTokenType,
|
|
937
1029
|
val: string;
|
|
938
1030
|
}
|
|
939
1031
|
|
|
@@ -942,7 +1034,7 @@ export declare interface IdentListToken extends BaseToken {
|
|
|
942
1034
|
*/
|
|
943
1035
|
export declare interface DashedIdentToken extends BaseToken {
|
|
944
1036
|
|
|
945
|
-
typ: EnumToken
|
|
1037
|
+
typ: EnumToken.DashedIdenTokenType,
|
|
946
1038
|
val: string;
|
|
947
1039
|
}
|
|
948
1040
|
|
|
@@ -951,7 +1043,7 @@ export declare interface DashedIdentToken extends BaseToken {
|
|
|
951
1043
|
*/
|
|
952
1044
|
export declare interface CommaToken extends BaseToken {
|
|
953
1045
|
|
|
954
|
-
typ: EnumToken
|
|
1046
|
+
typ: EnumToken.CommaTokenType
|
|
955
1047
|
}
|
|
956
1048
|
|
|
957
1049
|
/**
|
|
@@ -959,7 +1051,7 @@ export declare interface CommaToken extends BaseToken {
|
|
|
959
1051
|
*/
|
|
960
1052
|
export declare interface ColonToken extends BaseToken {
|
|
961
1053
|
|
|
962
|
-
typ: EnumToken
|
|
1054
|
+
typ: EnumToken.ColonTokenType
|
|
963
1055
|
}
|
|
964
1056
|
|
|
965
1057
|
/**
|
|
@@ -967,7 +1059,7 @@ export declare interface ColonToken extends BaseToken {
|
|
|
967
1059
|
*/
|
|
968
1060
|
export declare interface SemiColonToken extends BaseToken {
|
|
969
1061
|
|
|
970
|
-
typ: EnumToken
|
|
1062
|
+
typ: EnumToken.SemiColonTokenType
|
|
971
1063
|
}
|
|
972
1064
|
|
|
973
1065
|
/**
|
|
@@ -975,7 +1067,7 @@ export declare interface SemiColonToken extends BaseToken {
|
|
|
975
1067
|
*/
|
|
976
1068
|
export declare interface NestingSelectorToken extends BaseToken {
|
|
977
1069
|
|
|
978
|
-
typ: EnumToken
|
|
1070
|
+
typ: EnumToken.NestingSelectorTokenType
|
|
979
1071
|
}
|
|
980
1072
|
|
|
981
1073
|
/**
|
|
@@ -983,7 +1075,7 @@ export declare interface NestingSelectorToken extends BaseToken {
|
|
|
983
1075
|
*/
|
|
984
1076
|
export declare interface NumberToken extends BaseToken {
|
|
985
1077
|
|
|
986
|
-
typ: EnumToken
|
|
1078
|
+
typ: EnumToken.NumberTokenType,
|
|
987
1079
|
val: number | FractionToken;
|
|
988
1080
|
}
|
|
989
1081
|
|
|
@@ -992,7 +1084,7 @@ export declare interface NumberToken extends BaseToken {
|
|
|
992
1084
|
*/
|
|
993
1085
|
export declare interface AtRuleToken extends BaseToken {
|
|
994
1086
|
|
|
995
|
-
typ: EnumToken
|
|
1087
|
+
typ: EnumToken.AtRuleTokenType,
|
|
996
1088
|
val: string;
|
|
997
1089
|
pre: string;
|
|
998
1090
|
}
|
|
@@ -1002,7 +1094,7 @@ export declare interface AtRuleToken extends BaseToken {
|
|
|
1002
1094
|
*/
|
|
1003
1095
|
export declare interface PercentageToken extends BaseToken {
|
|
1004
1096
|
|
|
1005
|
-
typ: EnumToken
|
|
1097
|
+
typ: EnumToken.PercentageTokenType,
|
|
1006
1098
|
val: number | FractionToken;
|
|
1007
1099
|
}
|
|
1008
1100
|
|
|
@@ -1011,7 +1103,7 @@ export declare interface PercentageToken extends BaseToken {
|
|
|
1011
1103
|
*/
|
|
1012
1104
|
export declare interface FlexToken extends BaseToken {
|
|
1013
1105
|
|
|
1014
|
-
typ: EnumToken
|
|
1106
|
+
typ: EnumToken.FlexTokenType,
|
|
1015
1107
|
val: number | FractionToken;
|
|
1016
1108
|
}
|
|
1017
1109
|
|
|
@@ -1020,7 +1112,7 @@ export declare interface FlexToken extends BaseToken {
|
|
|
1020
1112
|
*/
|
|
1021
1113
|
export declare interface FunctionToken extends BaseToken {
|
|
1022
1114
|
|
|
1023
|
-
typ: EnumToken
|
|
1115
|
+
typ: EnumToken.FunctionTokenType,
|
|
1024
1116
|
val: string;
|
|
1025
1117
|
chi: Token$1[];
|
|
1026
1118
|
}
|
|
@@ -1030,7 +1122,7 @@ export declare interface FunctionToken extends BaseToken {
|
|
|
1030
1122
|
*/
|
|
1031
1123
|
export declare interface GridTemplateFuncToken extends BaseToken {
|
|
1032
1124
|
|
|
1033
|
-
typ: EnumToken
|
|
1125
|
+
typ: EnumToken.GridTemplateFuncTokenType,
|
|
1034
1126
|
val: string;
|
|
1035
1127
|
chi: Token$1[];
|
|
1036
1128
|
}
|
|
@@ -1040,9 +1132,9 @@ export declare interface GridTemplateFuncToken extends BaseToken {
|
|
|
1040
1132
|
*/
|
|
1041
1133
|
export declare interface FunctionURLToken extends BaseToken {
|
|
1042
1134
|
|
|
1043
|
-
typ: EnumToken
|
|
1135
|
+
typ: EnumToken.UrlFunctionTokenType,
|
|
1044
1136
|
val: 'url';
|
|
1045
|
-
chi: Array<UrlToken | CommentToken>;
|
|
1137
|
+
chi: Array<UrlToken | StringToken | CommentToken>;
|
|
1046
1138
|
}
|
|
1047
1139
|
|
|
1048
1140
|
/**
|
|
@@ -1050,7 +1142,7 @@ export declare interface FunctionURLToken extends BaseToken {
|
|
|
1050
1142
|
*/
|
|
1051
1143
|
export declare interface FunctionImageToken extends BaseToken {
|
|
1052
1144
|
|
|
1053
|
-
typ: EnumToken
|
|
1145
|
+
typ: EnumToken.ImageFunctionTokenType,
|
|
1054
1146
|
val: 'linear-gradient' | 'radial-gradient' | 'repeating-linear-gradient' | 'repeating-radial-gradient' | 'conic-gradient' | 'image' | 'image-set' | 'element' | 'cross-fade';
|
|
1055
1147
|
chi: Array<UrlToken | CommentToken>;
|
|
1056
1148
|
}
|
|
@@ -1060,7 +1152,7 @@ export declare interface FunctionImageToken extends BaseToken {
|
|
|
1060
1152
|
*/
|
|
1061
1153
|
export declare interface TimingFunctionToken extends BaseToken {
|
|
1062
1154
|
|
|
1063
|
-
typ: EnumToken
|
|
1155
|
+
typ: EnumToken.TimingFunctionTokenType;
|
|
1064
1156
|
val: string;
|
|
1065
1157
|
chi: Token$1[];
|
|
1066
1158
|
}
|
|
@@ -1070,7 +1162,7 @@ export declare interface TimingFunctionToken extends BaseToken {
|
|
|
1070
1162
|
*/
|
|
1071
1163
|
export declare interface TimelineFunctionToken extends BaseToken {
|
|
1072
1164
|
|
|
1073
|
-
typ: EnumToken
|
|
1165
|
+
typ: EnumToken.TimelineFunctionTokenType;
|
|
1074
1166
|
val: string;
|
|
1075
1167
|
chi: Token$1[];
|
|
1076
1168
|
}
|
|
@@ -1080,7 +1172,7 @@ export declare interface TimelineFunctionToken extends BaseToken {
|
|
|
1080
1172
|
*/
|
|
1081
1173
|
export declare interface StringToken extends BaseToken {
|
|
1082
1174
|
|
|
1083
|
-
typ: EnumToken
|
|
1175
|
+
typ: EnumToken.StringTokenType;
|
|
1084
1176
|
val: string;
|
|
1085
1177
|
}
|
|
1086
1178
|
|
|
@@ -1089,7 +1181,7 @@ export declare interface StringToken extends BaseToken {
|
|
|
1089
1181
|
*/
|
|
1090
1182
|
export declare interface BadStringToken extends BaseToken {
|
|
1091
1183
|
|
|
1092
|
-
typ: EnumToken
|
|
1184
|
+
typ: EnumToken.BadStringTokenType;
|
|
1093
1185
|
val: string;
|
|
1094
1186
|
}
|
|
1095
1187
|
|
|
@@ -1098,7 +1190,7 @@ export declare interface BadStringToken extends BaseToken {
|
|
|
1098
1190
|
*/
|
|
1099
1191
|
export declare interface UnclosedStringToken extends BaseToken {
|
|
1100
1192
|
|
|
1101
|
-
typ: EnumToken
|
|
1193
|
+
typ: EnumToken.UnclosedStringTokenType;
|
|
1102
1194
|
val: string;
|
|
1103
1195
|
}
|
|
1104
1196
|
|
|
@@ -1107,7 +1199,7 @@ export declare interface UnclosedStringToken extends BaseToken {
|
|
|
1107
1199
|
*/
|
|
1108
1200
|
export declare interface DimensionToken extends BaseToken {
|
|
1109
1201
|
|
|
1110
|
-
typ: EnumToken
|
|
1202
|
+
typ: EnumToken.DimensionTokenType;
|
|
1111
1203
|
val: number | FractionToken;
|
|
1112
1204
|
unit: string;
|
|
1113
1205
|
}
|
|
@@ -1117,7 +1209,7 @@ export declare interface DimensionToken extends BaseToken {
|
|
|
1117
1209
|
*/
|
|
1118
1210
|
export declare interface LengthToken extends BaseToken {
|
|
1119
1211
|
|
|
1120
|
-
typ: EnumToken
|
|
1212
|
+
typ: EnumToken.LengthTokenType;
|
|
1121
1213
|
val: number | FractionToken;
|
|
1122
1214
|
unit: string;
|
|
1123
1215
|
}
|
|
@@ -1127,7 +1219,7 @@ export declare interface LengthToken extends BaseToken {
|
|
|
1127
1219
|
*/
|
|
1128
1220
|
export declare interface AngleToken extends BaseToken {
|
|
1129
1221
|
|
|
1130
|
-
typ: EnumToken
|
|
1222
|
+
typ: EnumToken.AngleTokenType;
|
|
1131
1223
|
val: number | FractionToken;
|
|
1132
1224
|
unit: string;
|
|
1133
1225
|
}
|
|
@@ -1137,7 +1229,7 @@ export declare interface AngleToken extends BaseToken {
|
|
|
1137
1229
|
*/
|
|
1138
1230
|
export declare interface TimeToken extends BaseToken {
|
|
1139
1231
|
|
|
1140
|
-
typ: EnumToken
|
|
1232
|
+
typ: EnumToken.TimeTokenType;
|
|
1141
1233
|
val: number | FractionToken;
|
|
1142
1234
|
unit: 'ms' | 's';
|
|
1143
1235
|
}
|
|
@@ -1147,7 +1239,7 @@ export declare interface TimeToken extends BaseToken {
|
|
|
1147
1239
|
*/
|
|
1148
1240
|
export declare interface FrequencyToken extends BaseToken {
|
|
1149
1241
|
|
|
1150
|
-
typ: EnumToken
|
|
1242
|
+
typ: EnumToken.FrequencyTokenType;
|
|
1151
1243
|
val: number | FractionToken;
|
|
1152
1244
|
unit: 'Hz' | 'Khz';
|
|
1153
1245
|
}
|
|
@@ -1157,7 +1249,7 @@ export declare interface FrequencyToken extends BaseToken {
|
|
|
1157
1249
|
*/
|
|
1158
1250
|
export declare interface ResolutionToken extends BaseToken {
|
|
1159
1251
|
|
|
1160
|
-
typ: EnumToken
|
|
1252
|
+
typ: EnumToken.ResolutionTokenType;
|
|
1161
1253
|
val: number | FractionToken;
|
|
1162
1254
|
unit: 'dpi' | 'dpcm' | 'dppx' | 'x';
|
|
1163
1255
|
}
|
|
@@ -1167,7 +1259,7 @@ export declare interface ResolutionToken extends BaseToken {
|
|
|
1167
1259
|
*/
|
|
1168
1260
|
export declare interface HashToken extends BaseToken {
|
|
1169
1261
|
|
|
1170
|
-
typ: EnumToken
|
|
1262
|
+
typ: EnumToken.HashTokenType;
|
|
1171
1263
|
val: string;
|
|
1172
1264
|
}
|
|
1173
1265
|
|
|
@@ -1176,7 +1268,7 @@ export declare interface HashToken extends BaseToken {
|
|
|
1176
1268
|
*/
|
|
1177
1269
|
export declare interface BlockStartToken extends BaseToken {
|
|
1178
1270
|
|
|
1179
|
-
typ: EnumToken
|
|
1271
|
+
typ: EnumToken.BlockStartTokenType
|
|
1180
1272
|
}
|
|
1181
1273
|
|
|
1182
1274
|
/**
|
|
@@ -1184,7 +1276,7 @@ export declare interface BlockStartToken extends BaseToken {
|
|
|
1184
1276
|
*/
|
|
1185
1277
|
export declare interface BlockEndToken extends BaseToken {
|
|
1186
1278
|
|
|
1187
|
-
typ: EnumToken
|
|
1279
|
+
typ: EnumToken.BlockEndTokenType
|
|
1188
1280
|
}
|
|
1189
1281
|
|
|
1190
1282
|
/**
|
|
@@ -1192,7 +1284,7 @@ export declare interface BlockEndToken extends BaseToken {
|
|
|
1192
1284
|
*/
|
|
1193
1285
|
export declare interface AttrStartToken extends BaseToken {
|
|
1194
1286
|
|
|
1195
|
-
typ: EnumToken
|
|
1287
|
+
typ: EnumToken.AttrStartTokenType;
|
|
1196
1288
|
chi?: Token$1[];
|
|
1197
1289
|
}
|
|
1198
1290
|
|
|
@@ -1201,7 +1293,7 @@ export declare interface AttrStartToken extends BaseToken {
|
|
|
1201
1293
|
*/
|
|
1202
1294
|
export declare interface AttrEndToken extends BaseToken {
|
|
1203
1295
|
|
|
1204
|
-
typ: EnumToken
|
|
1296
|
+
typ: EnumToken.AttrEndTokenType
|
|
1205
1297
|
}
|
|
1206
1298
|
|
|
1207
1299
|
/**
|
|
@@ -1209,7 +1301,7 @@ export declare interface AttrEndToken extends BaseToken {
|
|
|
1209
1301
|
*/
|
|
1210
1302
|
export declare interface ParensStartToken extends BaseToken {
|
|
1211
1303
|
|
|
1212
|
-
typ: EnumToken
|
|
1304
|
+
typ: EnumToken.StartParensTokenType;
|
|
1213
1305
|
}
|
|
1214
1306
|
|
|
1215
1307
|
/**
|
|
@@ -1217,7 +1309,7 @@ export declare interface ParensStartToken extends BaseToken {
|
|
|
1217
1309
|
*/
|
|
1218
1310
|
export declare interface ParensEndToken extends BaseToken {
|
|
1219
1311
|
|
|
1220
|
-
typ: EnumToken
|
|
1312
|
+
typ: EnumToken.EndParensTokenType
|
|
1221
1313
|
}
|
|
1222
1314
|
|
|
1223
1315
|
/**
|
|
@@ -1225,7 +1317,7 @@ export declare interface ParensEndToken extends BaseToken {
|
|
|
1225
1317
|
*/
|
|
1226
1318
|
export declare interface ParensToken extends BaseToken {
|
|
1227
1319
|
|
|
1228
|
-
typ: EnumToken
|
|
1320
|
+
typ: EnumToken.ParensTokenType;
|
|
1229
1321
|
chi: Token$1[];
|
|
1230
1322
|
}
|
|
1231
1323
|
|
|
@@ -1234,7 +1326,7 @@ export declare interface ParensToken extends BaseToken {
|
|
|
1234
1326
|
*/
|
|
1235
1327
|
export declare interface WhitespaceToken extends BaseToken {
|
|
1236
1328
|
|
|
1237
|
-
typ: EnumToken
|
|
1329
|
+
typ: EnumToken.WhitespaceTokenType
|
|
1238
1330
|
}
|
|
1239
1331
|
|
|
1240
1332
|
/**
|
|
@@ -1242,7 +1334,7 @@ export declare interface WhitespaceToken extends BaseToken {
|
|
|
1242
1334
|
*/
|
|
1243
1335
|
export declare interface CommentToken extends BaseToken {
|
|
1244
1336
|
|
|
1245
|
-
typ: EnumToken
|
|
1337
|
+
typ: EnumToken.CommentTokenType;
|
|
1246
1338
|
val: string;
|
|
1247
1339
|
}
|
|
1248
1340
|
|
|
@@ -1251,7 +1343,7 @@ export declare interface CommentToken extends BaseToken {
|
|
|
1251
1343
|
*/
|
|
1252
1344
|
export declare interface BadCommentToken extends BaseToken {
|
|
1253
1345
|
|
|
1254
|
-
typ: EnumToken
|
|
1346
|
+
typ: EnumToken.BadCommentTokenType;
|
|
1255
1347
|
val: string;
|
|
1256
1348
|
}
|
|
1257
1349
|
|
|
@@ -1260,7 +1352,7 @@ export declare interface BadCommentToken extends BaseToken {
|
|
|
1260
1352
|
*/
|
|
1261
1353
|
export declare interface CDOCommentToken extends BaseToken {
|
|
1262
1354
|
|
|
1263
|
-
typ: EnumToken
|
|
1355
|
+
typ: EnumToken.CDOCOMMTokenType;
|
|
1264
1356
|
val: string;
|
|
1265
1357
|
}
|
|
1266
1358
|
|
|
@@ -1269,7 +1361,7 @@ export declare interface CDOCommentToken extends BaseToken {
|
|
|
1269
1361
|
*/
|
|
1270
1362
|
export declare interface BadCDOCommentToken extends BaseToken {
|
|
1271
1363
|
|
|
1272
|
-
typ: EnumToken
|
|
1364
|
+
typ: EnumToken.BadCdoTokenType;
|
|
1273
1365
|
val: string;
|
|
1274
1366
|
}
|
|
1275
1367
|
|
|
@@ -1278,7 +1370,7 @@ export declare interface BadCDOCommentToken extends BaseToken {
|
|
|
1278
1370
|
*/
|
|
1279
1371
|
export declare interface IncludeMatchToken extends BaseToken {
|
|
1280
1372
|
|
|
1281
|
-
typ: EnumToken
|
|
1373
|
+
typ: EnumToken.IncludeMatchTokenType;
|
|
1282
1374
|
// val: '~=';
|
|
1283
1375
|
}
|
|
1284
1376
|
|
|
@@ -1287,7 +1379,7 @@ export declare interface IncludeMatchToken extends BaseToken {
|
|
|
1287
1379
|
*/
|
|
1288
1380
|
export declare interface DashMatchToken extends BaseToken {
|
|
1289
1381
|
|
|
1290
|
-
typ: EnumToken
|
|
1382
|
+
typ: EnumToken.DashMatchTokenType;
|
|
1291
1383
|
// val: '|=';
|
|
1292
1384
|
}
|
|
1293
1385
|
|
|
@@ -1296,7 +1388,7 @@ export declare interface DashMatchToken extends BaseToken {
|
|
|
1296
1388
|
*/
|
|
1297
1389
|
export declare interface EqualMatchToken extends BaseToken {
|
|
1298
1390
|
|
|
1299
|
-
typ: EnumToken
|
|
1391
|
+
typ: EnumToken.EqualMatchTokenType;
|
|
1300
1392
|
// val: '|=';
|
|
1301
1393
|
}
|
|
1302
1394
|
|
|
@@ -1305,7 +1397,7 @@ export declare interface EqualMatchToken extends BaseToken {
|
|
|
1305
1397
|
*/
|
|
1306
1398
|
export declare interface StartMatchToken extends BaseToken {
|
|
1307
1399
|
|
|
1308
|
-
typ: EnumToken
|
|
1400
|
+
typ: EnumToken.StartMatchTokenType;
|
|
1309
1401
|
// val: '^=';
|
|
1310
1402
|
}
|
|
1311
1403
|
|
|
@@ -1314,7 +1406,7 @@ export declare interface StartMatchToken extends BaseToken {
|
|
|
1314
1406
|
*/
|
|
1315
1407
|
export declare interface EndMatchToken extends BaseToken {
|
|
1316
1408
|
|
|
1317
|
-
typ: EnumToken
|
|
1409
|
+
typ: EnumToken.EndMatchTokenType;
|
|
1318
1410
|
// val: '|=';
|
|
1319
1411
|
}
|
|
1320
1412
|
|
|
@@ -1323,7 +1415,7 @@ export declare interface EndMatchToken extends BaseToken {
|
|
|
1323
1415
|
*/
|
|
1324
1416
|
export declare interface ContainMatchToken extends BaseToken {
|
|
1325
1417
|
|
|
1326
|
-
typ: EnumToken
|
|
1418
|
+
typ: EnumToken.ContainMatchTokenType;
|
|
1327
1419
|
// val: '|=';
|
|
1328
1420
|
}
|
|
1329
1421
|
|
|
@@ -1332,7 +1424,7 @@ export declare interface ContainMatchToken extends BaseToken {
|
|
|
1332
1424
|
*/
|
|
1333
1425
|
export declare interface LessThanToken extends BaseToken {
|
|
1334
1426
|
|
|
1335
|
-
typ: EnumToken
|
|
1427
|
+
typ: EnumToken.LtTokenType;
|
|
1336
1428
|
}
|
|
1337
1429
|
|
|
1338
1430
|
/**
|
|
@@ -1340,7 +1432,7 @@ export declare interface LessThanToken extends BaseToken {
|
|
|
1340
1432
|
*/
|
|
1341
1433
|
export declare interface LessThanOrEqualToken extends BaseToken {
|
|
1342
1434
|
|
|
1343
|
-
typ: EnumToken
|
|
1435
|
+
typ: EnumToken.LteTokenType;
|
|
1344
1436
|
}
|
|
1345
1437
|
|
|
1346
1438
|
/**
|
|
@@ -1348,7 +1440,7 @@ export declare interface LessThanOrEqualToken extends BaseToken {
|
|
|
1348
1440
|
*/
|
|
1349
1441
|
export declare interface GreaterThanToken extends BaseToken {
|
|
1350
1442
|
|
|
1351
|
-
typ: EnumToken
|
|
1443
|
+
typ: EnumToken.GtTokenType;
|
|
1352
1444
|
}
|
|
1353
1445
|
|
|
1354
1446
|
/**
|
|
@@ -1356,7 +1448,7 @@ export declare interface GreaterThanToken extends BaseToken {
|
|
|
1356
1448
|
*/
|
|
1357
1449
|
export declare interface GreaterThanOrEqualToken extends BaseToken {
|
|
1358
1450
|
|
|
1359
|
-
typ: EnumToken
|
|
1451
|
+
typ: EnumToken.GteTokenType;
|
|
1360
1452
|
}
|
|
1361
1453
|
|
|
1362
1454
|
/**
|
|
@@ -1364,7 +1456,7 @@ export declare interface GreaterThanOrEqualToken extends BaseToken {
|
|
|
1364
1456
|
*/
|
|
1365
1457
|
export declare interface ColumnCombinatorToken extends BaseToken {
|
|
1366
1458
|
|
|
1367
|
-
typ: EnumToken
|
|
1459
|
+
typ: EnumToken.ColumnCombinatorTokenType;
|
|
1368
1460
|
}
|
|
1369
1461
|
|
|
1370
1462
|
/**
|
|
@@ -1372,7 +1464,7 @@ export declare interface ColumnCombinatorToken extends BaseToken {
|
|
|
1372
1464
|
*/
|
|
1373
1465
|
export declare interface PseudoClassToken extends BaseToken {
|
|
1374
1466
|
|
|
1375
|
-
typ: EnumToken
|
|
1467
|
+
typ: EnumToken.PseudoClassTokenType;
|
|
1376
1468
|
val: string;
|
|
1377
1469
|
}
|
|
1378
1470
|
|
|
@@ -1381,7 +1473,7 @@ export declare interface PseudoClassToken extends BaseToken {
|
|
|
1381
1473
|
*/
|
|
1382
1474
|
export declare interface PseudoElementToken extends BaseToken {
|
|
1383
1475
|
|
|
1384
|
-
typ: EnumToken
|
|
1476
|
+
typ: EnumToken.PseudoElementTokenType;
|
|
1385
1477
|
val: string;
|
|
1386
1478
|
}
|
|
1387
1479
|
|
|
@@ -1390,7 +1482,7 @@ export declare interface PseudoElementToken extends BaseToken {
|
|
|
1390
1482
|
*/
|
|
1391
1483
|
export declare interface PseudoPageToken extends BaseToken {
|
|
1392
1484
|
|
|
1393
|
-
typ: EnumToken
|
|
1485
|
+
typ: EnumToken.PseudoPageTokenType;
|
|
1394
1486
|
val: string;
|
|
1395
1487
|
}
|
|
1396
1488
|
|
|
@@ -1399,7 +1491,7 @@ export declare interface PseudoPageToken extends BaseToken {
|
|
|
1399
1491
|
*/
|
|
1400
1492
|
export declare interface PseudoClassFunctionToken extends BaseToken {
|
|
1401
1493
|
|
|
1402
|
-
typ: EnumToken
|
|
1494
|
+
typ: EnumToken.PseudoClassFuncTokenType;
|
|
1403
1495
|
val: string;
|
|
1404
1496
|
chi: Token$1[];
|
|
1405
1497
|
}
|
|
@@ -1409,7 +1501,7 @@ export declare interface PseudoClassFunctionToken extends BaseToken {
|
|
|
1409
1501
|
*/
|
|
1410
1502
|
export declare interface DelimToken extends BaseToken {
|
|
1411
1503
|
|
|
1412
|
-
typ: EnumToken
|
|
1504
|
+
typ: EnumToken.DelimTokenType;
|
|
1413
1505
|
}
|
|
1414
1506
|
|
|
1415
1507
|
/**
|
|
@@ -1417,7 +1509,7 @@ export declare interface DelimToken extends BaseToken {
|
|
|
1417
1509
|
*/
|
|
1418
1510
|
export declare interface BadUrlToken extends BaseToken {
|
|
1419
1511
|
|
|
1420
|
-
typ: EnumToken
|
|
1512
|
+
typ: EnumToken.BadUrlTokenType,
|
|
1421
1513
|
val: string;
|
|
1422
1514
|
}
|
|
1423
1515
|
|
|
@@ -1426,7 +1518,7 @@ export declare interface BadUrlToken extends BaseToken {
|
|
|
1426
1518
|
*/
|
|
1427
1519
|
export declare interface UrlToken extends BaseToken {
|
|
1428
1520
|
|
|
1429
|
-
typ: EnumToken
|
|
1521
|
+
typ: EnumToken.UrlTokenTokenType,
|
|
1430
1522
|
val: string;
|
|
1431
1523
|
}
|
|
1432
1524
|
|
|
@@ -1435,7 +1527,7 @@ export declare interface UrlToken extends BaseToken {
|
|
|
1435
1527
|
*/
|
|
1436
1528
|
export declare interface EOFToken extends BaseToken {
|
|
1437
1529
|
|
|
1438
|
-
typ: EnumToken
|
|
1530
|
+
typ: EnumToken.EOFTokenType;
|
|
1439
1531
|
}
|
|
1440
1532
|
|
|
1441
1533
|
/**
|
|
@@ -1443,7 +1535,7 @@ export declare interface EOFToken extends BaseToken {
|
|
|
1443
1535
|
*/
|
|
1444
1536
|
export declare interface ImportantToken extends BaseToken {
|
|
1445
1537
|
|
|
1446
|
-
typ: EnumToken
|
|
1538
|
+
typ: EnumToken.ImportantTokenType;
|
|
1447
1539
|
}
|
|
1448
1540
|
|
|
1449
1541
|
/**
|
|
@@ -1451,7 +1543,7 @@ export declare interface ImportantToken extends BaseToken {
|
|
|
1451
1543
|
*/
|
|
1452
1544
|
export declare interface ColorToken extends BaseToken {
|
|
1453
1545
|
|
|
1454
|
-
typ: EnumToken
|
|
1546
|
+
typ: EnumToken.ColorTokenType;
|
|
1455
1547
|
val: string;
|
|
1456
1548
|
kin: ColorType;
|
|
1457
1549
|
chi?: Token$1[];
|
|
@@ -1464,7 +1556,7 @@ export declare interface ColorToken extends BaseToken {
|
|
|
1464
1556
|
*/
|
|
1465
1557
|
export declare interface AttrToken extends BaseToken {
|
|
1466
1558
|
|
|
1467
|
-
typ: EnumToken
|
|
1559
|
+
typ: EnumToken.AttrTokenType,
|
|
1468
1560
|
chi: Token$1[]
|
|
1469
1561
|
}
|
|
1470
1562
|
|
|
@@ -1473,7 +1565,7 @@ export declare interface AttrToken extends BaseToken {
|
|
|
1473
1565
|
*/
|
|
1474
1566
|
export declare interface InvalidAttrToken extends BaseToken {
|
|
1475
1567
|
|
|
1476
|
-
typ: EnumToken
|
|
1568
|
+
typ: EnumToken.InvalidAttrTokenType,
|
|
1477
1569
|
chi: Token$1[]
|
|
1478
1570
|
}
|
|
1479
1571
|
|
|
@@ -1482,7 +1574,7 @@ export declare interface InvalidAttrToken extends BaseToken {
|
|
|
1482
1574
|
*/
|
|
1483
1575
|
export declare interface ChildCombinatorToken extends BaseToken {
|
|
1484
1576
|
|
|
1485
|
-
typ: EnumToken
|
|
1577
|
+
typ: EnumToken.ChildCombinatorTokenType
|
|
1486
1578
|
}
|
|
1487
1579
|
|
|
1488
1580
|
/**
|
|
@@ -1490,7 +1582,7 @@ export declare interface ChildCombinatorToken extends BaseToken {
|
|
|
1490
1582
|
*/
|
|
1491
1583
|
export declare interface MediaFeatureToken extends BaseToken {
|
|
1492
1584
|
|
|
1493
|
-
typ: EnumToken
|
|
1585
|
+
typ: EnumToken.MediaFeatureTokenType,
|
|
1494
1586
|
val: string;
|
|
1495
1587
|
}
|
|
1496
1588
|
|
|
@@ -1499,7 +1591,7 @@ export declare interface MediaFeatureToken extends BaseToken {
|
|
|
1499
1591
|
*/
|
|
1500
1592
|
export declare interface MediaFeatureNotToken extends BaseToken {
|
|
1501
1593
|
|
|
1502
|
-
typ: EnumToken
|
|
1594
|
+
typ: EnumToken.MediaFeatureNotTokenType,
|
|
1503
1595
|
val: Token$1;
|
|
1504
1596
|
}
|
|
1505
1597
|
|
|
@@ -1508,7 +1600,7 @@ export declare interface MediaFeatureNotToken extends BaseToken {
|
|
|
1508
1600
|
*/
|
|
1509
1601
|
export declare interface MediaFeatureOnlyToken extends BaseToken {
|
|
1510
1602
|
|
|
1511
|
-
typ: EnumToken
|
|
1603
|
+
typ: EnumToken.MediaFeatureOnlyTokenType,
|
|
1512
1604
|
val: Token$1;
|
|
1513
1605
|
}
|
|
1514
1606
|
|
|
@@ -1517,7 +1609,7 @@ export declare interface MediaFeatureOnlyToken extends BaseToken {
|
|
|
1517
1609
|
*/
|
|
1518
1610
|
export declare interface MediaFeatureAndToken extends BaseToken {
|
|
1519
1611
|
|
|
1520
|
-
typ: EnumToken
|
|
1612
|
+
typ: EnumToken.MediaFeatureAndTokenType;
|
|
1521
1613
|
}
|
|
1522
1614
|
|
|
1523
1615
|
/**
|
|
@@ -1525,7 +1617,7 @@ export declare interface MediaFeatureAndToken extends BaseToken {
|
|
|
1525
1617
|
*/
|
|
1526
1618
|
export declare interface MediaFeatureOrToken extends BaseToken {
|
|
1527
1619
|
|
|
1528
|
-
typ: EnumToken
|
|
1620
|
+
typ: EnumToken.MediaFeatureOrTokenType;
|
|
1529
1621
|
}
|
|
1530
1622
|
|
|
1531
1623
|
/**
|
|
@@ -1533,7 +1625,7 @@ export declare interface MediaFeatureOrToken extends BaseToken {
|
|
|
1533
1625
|
*/
|
|
1534
1626
|
export declare interface MediaQueryConditionToken extends BaseToken {
|
|
1535
1627
|
|
|
1536
|
-
typ: EnumToken
|
|
1628
|
+
typ: EnumToken.MediaQueryConditionTokenType,
|
|
1537
1629
|
l: Token$1,
|
|
1538
1630
|
op: ColonToken | GreaterThanToken | LessThanToken | GreaterThanOrEqualToken | LessThanOrEqualToken,
|
|
1539
1631
|
r: Token$1[]
|
|
@@ -1544,7 +1636,7 @@ export declare interface MediaQueryConditionToken extends BaseToken {
|
|
|
1544
1636
|
*/
|
|
1545
1637
|
export declare interface DescendantCombinatorToken extends BaseToken {
|
|
1546
1638
|
|
|
1547
|
-
typ: EnumToken
|
|
1639
|
+
typ: EnumToken.DescendantCombinatorTokenType
|
|
1548
1640
|
}
|
|
1549
1641
|
|
|
1550
1642
|
/**
|
|
@@ -1552,7 +1644,7 @@ export declare interface DescendantCombinatorToken extends BaseToken {
|
|
|
1552
1644
|
*/
|
|
1553
1645
|
export declare interface NextSiblingCombinatorToken extends BaseToken {
|
|
1554
1646
|
|
|
1555
|
-
typ: EnumToken
|
|
1647
|
+
typ: EnumToken.NextSiblingCombinatorTokenType
|
|
1556
1648
|
}
|
|
1557
1649
|
|
|
1558
1650
|
/**
|
|
@@ -1560,7 +1652,7 @@ export declare interface NextSiblingCombinatorToken extends BaseToken {
|
|
|
1560
1652
|
*/
|
|
1561
1653
|
export declare interface SubsequentCombinatorToken extends BaseToken {
|
|
1562
1654
|
|
|
1563
|
-
typ: EnumToken
|
|
1655
|
+
typ: EnumToken.SubsequentSiblingCombinatorTokenType
|
|
1564
1656
|
}
|
|
1565
1657
|
|
|
1566
1658
|
/**
|
|
@@ -1568,7 +1660,7 @@ export declare interface SubsequentCombinatorToken extends BaseToken {
|
|
|
1568
1660
|
*/
|
|
1569
1661
|
export declare interface AddToken extends BaseToken {
|
|
1570
1662
|
|
|
1571
|
-
typ: EnumToken
|
|
1663
|
+
typ: EnumToken.Add;
|
|
1572
1664
|
}
|
|
1573
1665
|
|
|
1574
1666
|
/**
|
|
@@ -1576,7 +1668,7 @@ export declare interface AddToken extends BaseToken {
|
|
|
1576
1668
|
*/
|
|
1577
1669
|
export declare interface SubToken extends BaseToken {
|
|
1578
1670
|
|
|
1579
|
-
typ: EnumToken
|
|
1671
|
+
typ: EnumToken.Sub;
|
|
1580
1672
|
}
|
|
1581
1673
|
|
|
1582
1674
|
/**
|
|
@@ -1584,7 +1676,7 @@ export declare interface SubToken extends BaseToken {
|
|
|
1584
1676
|
*/
|
|
1585
1677
|
export declare interface DivToken extends BaseToken {
|
|
1586
1678
|
|
|
1587
|
-
typ: EnumToken
|
|
1679
|
+
typ: EnumToken.Div;
|
|
1588
1680
|
}
|
|
1589
1681
|
|
|
1590
1682
|
/**
|
|
@@ -1592,7 +1684,7 @@ export declare interface DivToken extends BaseToken {
|
|
|
1592
1684
|
*/
|
|
1593
1685
|
export declare interface MulToken extends BaseToken {
|
|
1594
1686
|
|
|
1595
|
-
typ: EnumToken
|
|
1687
|
+
typ: EnumToken.Mul;
|
|
1596
1688
|
}
|
|
1597
1689
|
|
|
1598
1690
|
/**
|
|
@@ -1600,8 +1692,8 @@ export declare interface MulToken extends BaseToken {
|
|
|
1600
1692
|
*/
|
|
1601
1693
|
export declare interface UnaryExpression extends BaseToken {
|
|
1602
1694
|
|
|
1603
|
-
typ: EnumToken
|
|
1604
|
-
sign: EnumToken
|
|
1695
|
+
typ: EnumToken.UnaryExpressionTokenType
|
|
1696
|
+
sign: EnumToken.Add | EnumToken.Sub;
|
|
1605
1697
|
val: UnaryExpressionNode;
|
|
1606
1698
|
}
|
|
1607
1699
|
|
|
@@ -1610,7 +1702,7 @@ export declare interface UnaryExpression extends BaseToken {
|
|
|
1610
1702
|
*/
|
|
1611
1703
|
export declare interface FractionToken extends BaseToken {
|
|
1612
1704
|
|
|
1613
|
-
typ: EnumToken
|
|
1705
|
+
typ: EnumToken.FractionTokenType;
|
|
1614
1706
|
l: NumberToken;
|
|
1615
1707
|
r: NumberToken;
|
|
1616
1708
|
}
|
|
@@ -1620,8 +1712,8 @@ export declare interface FractionToken extends BaseToken {
|
|
|
1620
1712
|
*/
|
|
1621
1713
|
export declare interface BinaryExpressionToken extends BaseToken {
|
|
1622
1714
|
|
|
1623
|
-
typ: EnumToken
|
|
1624
|
-
op: EnumToken
|
|
1715
|
+
typ: EnumToken.BinaryExpressionTokenType
|
|
1716
|
+
op: EnumToken.Add | EnumToken.Sub | EnumToken.Div | EnumToken.Mul;
|
|
1625
1717
|
l: BinaryExpressionNode | Token$1;
|
|
1626
1718
|
r: BinaryExpressionNode | Token$1;
|
|
1627
1719
|
}
|
|
@@ -1631,7 +1723,7 @@ export declare interface BinaryExpressionToken extends BaseToken {
|
|
|
1631
1723
|
*/
|
|
1632
1724
|
export declare interface MatchExpressionToken extends BaseToken {
|
|
1633
1725
|
|
|
1634
|
-
typ: EnumToken
|
|
1726
|
+
typ: EnumToken.MatchExpressionTokenType
|
|
1635
1727
|
op: EqualMatchToken | DashMatchToken | StartMatchToken | ContainMatchToken | EndMatchToken | IncludeMatchToken;
|
|
1636
1728
|
l: Token$1;
|
|
1637
1729
|
r: Token$1;
|
|
@@ -1643,7 +1735,7 @@ export declare interface MatchExpressionToken extends BaseToken {
|
|
|
1643
1735
|
*/
|
|
1644
1736
|
export declare interface NameSpaceAttributeToken extends BaseToken {
|
|
1645
1737
|
|
|
1646
|
-
typ: EnumToken
|
|
1738
|
+
typ: EnumToken.NameSpaceAttributeTokenType
|
|
1647
1739
|
l?: Token$1;
|
|
1648
1740
|
r: Token$1;
|
|
1649
1741
|
}
|
|
@@ -1653,10 +1745,44 @@ export declare interface NameSpaceAttributeToken extends BaseToken {
|
|
|
1653
1745
|
*/
|
|
1654
1746
|
export declare interface ListToken extends BaseToken {
|
|
1655
1747
|
|
|
1656
|
-
typ: EnumToken
|
|
1748
|
+
typ: EnumToken.ListToken
|
|
1657
1749
|
chi: Token$1[];
|
|
1658
1750
|
}
|
|
1659
1751
|
|
|
1752
|
+
/**
|
|
1753
|
+
* Composes selector token
|
|
1754
|
+
*/
|
|
1755
|
+
export declare interface ComposesSelectorToken extends BaseToken {
|
|
1756
|
+
|
|
1757
|
+
typ: EnumToken.ComposesSelectorTokenType;
|
|
1758
|
+
l: Token$1[];
|
|
1759
|
+
r: Token$1 | null;
|
|
1760
|
+
}
|
|
1761
|
+
|
|
1762
|
+
/**
|
|
1763
|
+
* Css variable token
|
|
1764
|
+
*/
|
|
1765
|
+
export declare interface CssVariableToken$1 extends BaseToken {
|
|
1766
|
+
|
|
1767
|
+
typ: EnumToken.CssVariableTokenType;
|
|
1768
|
+
nam: string;
|
|
1769
|
+
val: Token$1[];
|
|
1770
|
+
}
|
|
1771
|
+
|
|
1772
|
+
export declare interface CssVariableImportTokenType$1 extends BaseToken {
|
|
1773
|
+
|
|
1774
|
+
typ: EnumToken.CssVariableImportTokenType;
|
|
1775
|
+
nam: string;
|
|
1776
|
+
val: Token$1[];
|
|
1777
|
+
}
|
|
1778
|
+
|
|
1779
|
+
export declare interface CssVariableMapTokenType extends BaseToken {
|
|
1780
|
+
|
|
1781
|
+
typ: EnumToken.CssVariableMapTokenType;
|
|
1782
|
+
vars: Token$1[];
|
|
1783
|
+
from: Token$1[];
|
|
1784
|
+
}
|
|
1785
|
+
|
|
1660
1786
|
/**
|
|
1661
1787
|
* Unary expression node
|
|
1662
1788
|
*/
|
|
@@ -1748,6 +1874,8 @@ export declare type Token$1 =
|
|
|
1748
1874
|
| ContainMatchToken
|
|
1749
1875
|
| MatchExpressionToken
|
|
1750
1876
|
| NameSpaceAttributeToken
|
|
1877
|
+
| ComposesSelectorToken
|
|
1878
|
+
| CssVariableToken$1
|
|
1751
1879
|
|
|
|
1752
1880
|
DashMatchToken
|
|
1753
1881
|
| EqualMatchToken
|
|
@@ -1828,12 +1956,16 @@ declare const enum ValidationSyntaxGroupEnum {
|
|
|
1828
1956
|
Selectors = "selectors",
|
|
1829
1957
|
AtRules = "atRules"
|
|
1830
1958
|
}
|
|
1959
|
+
|
|
1831
1960
|
interface Position$1 {
|
|
1961
|
+
|
|
1832
1962
|
ind: number;
|
|
1833
1963
|
lin: number;
|
|
1834
1964
|
col: number;
|
|
1835
1965
|
}
|
|
1966
|
+
|
|
1836
1967
|
interface ValidationToken$1 {
|
|
1968
|
+
|
|
1837
1969
|
typ: ValidationTokenEnum;
|
|
1838
1970
|
pos: Position$1;
|
|
1839
1971
|
isList?: boolean;
|
|
@@ -1845,7 +1977,7 @@ interface ValidationToken$1 {
|
|
|
1845
1977
|
occurence?: {
|
|
1846
1978
|
min: number;
|
|
1847
1979
|
max: number | null;
|
|
1848
|
-
}
|
|
1980
|
+
}
|
|
1849
1981
|
}
|
|
1850
1982
|
|
|
1851
1983
|
export declare interface ValidationSyntaxNode {
|
|
@@ -1993,7 +2125,7 @@ export declare interface BaseToken {
|
|
|
1993
2125
|
/**
|
|
1994
2126
|
* token type
|
|
1995
2127
|
*/
|
|
1996
|
-
typ: EnumToken
|
|
2128
|
+
typ: EnumToken;
|
|
1997
2129
|
/**
|
|
1998
2130
|
* location info
|
|
1999
2131
|
*/
|
|
@@ -2005,7 +2137,7 @@ export declare interface BaseToken {
|
|
|
2005
2137
|
/**
|
|
2006
2138
|
* parent node
|
|
2007
2139
|
*/
|
|
2008
|
-
parent?:
|
|
2140
|
+
parent?: AstAtRule | astRule | AstKeyframesAtRule | AstKeyFrameRule | AstInvalidRule | AstInvalidAtRule | null;
|
|
2009
2141
|
/**
|
|
2010
2142
|
* @private
|
|
2011
2143
|
*/
|
|
@@ -2017,7 +2149,8 @@ export declare interface BaseToken {
|
|
|
2017
2149
|
*/
|
|
2018
2150
|
export declare interface AstComment extends BaseToken {
|
|
2019
2151
|
|
|
2020
|
-
typ: EnumToken
|
|
2152
|
+
typ: EnumToken.CommentNodeType | EnumToken.CDOCOMMNodeType,
|
|
2153
|
+
tokens?: null;
|
|
2021
2154
|
val: string;
|
|
2022
2155
|
}
|
|
2023
2156
|
|
|
@@ -2027,8 +2160,9 @@ export declare interface AstComment extends BaseToken {
|
|
|
2027
2160
|
export declare interface AstDeclaration extends BaseToken {
|
|
2028
2161
|
|
|
2029
2162
|
nam: string,
|
|
2163
|
+
tokens?: null;
|
|
2030
2164
|
val: Token$1[];
|
|
2031
|
-
typ: EnumToken
|
|
2165
|
+
typ: EnumToken.DeclarationNodeType
|
|
2032
2166
|
}
|
|
2033
2167
|
|
|
2034
2168
|
/**
|
|
@@ -2036,9 +2170,9 @@ export declare interface AstDeclaration extends BaseToken {
|
|
|
2036
2170
|
*/
|
|
2037
2171
|
export declare interface AstRule extends BaseToken {
|
|
2038
2172
|
|
|
2039
|
-
typ: EnumToken
|
|
2173
|
+
typ: EnumToken.RuleNodeType;
|
|
2040
2174
|
sel: string;
|
|
2041
|
-
chi: Array<AstDeclaration | AstComment |
|
|
2175
|
+
chi: Array<AstDeclaration | AstComment | AstRule | AstAtRule | AstInvalidRule | AstInvalidDeclaration | AstInvalidAtRule>;
|
|
2042
2176
|
optimized?: OptimizedSelector | null;
|
|
2043
2177
|
raw?: RawSelectorTokens | null;
|
|
2044
2178
|
}
|
|
@@ -2048,7 +2182,7 @@ export declare interface AstRule extends BaseToken {
|
|
|
2048
2182
|
*/
|
|
2049
2183
|
export declare interface AstInvalidRule extends BaseToken {
|
|
2050
2184
|
|
|
2051
|
-
typ: EnumToken
|
|
2185
|
+
typ: EnumToken.InvalidRuleTokenType;
|
|
2052
2186
|
sel: string;
|
|
2053
2187
|
chi: Array<AstNode$1>;
|
|
2054
2188
|
}
|
|
@@ -2058,8 +2192,9 @@ export declare interface AstInvalidRule extends BaseToken {
|
|
|
2058
2192
|
*/
|
|
2059
2193
|
export declare interface AstInvalidDeclaration extends BaseToken {
|
|
2060
2194
|
|
|
2061
|
-
typ: EnumToken
|
|
2062
|
-
|
|
2195
|
+
typ: EnumToken.InvalidDeclarationNodeType;
|
|
2196
|
+
tokens?: null;
|
|
2197
|
+
val: Array<Token$1>;
|
|
2063
2198
|
}
|
|
2064
2199
|
|
|
2065
2200
|
/**
|
|
@@ -2067,7 +2202,7 @@ export declare interface AstInvalidDeclaration extends BaseToken {
|
|
|
2067
2202
|
*/
|
|
2068
2203
|
export declare interface AstInvalidAtRule extends BaseToken {
|
|
2069
2204
|
|
|
2070
|
-
typ: EnumToken
|
|
2205
|
+
typ: EnumToken.InvalidAtRuleTokenType;
|
|
2071
2206
|
nam: string;
|
|
2072
2207
|
val: string;
|
|
2073
2208
|
chi?: Array<AstNode$1>;
|
|
@@ -2078,9 +2213,9 @@ export declare interface AstInvalidAtRule extends BaseToken {
|
|
|
2078
2213
|
*/
|
|
2079
2214
|
export declare interface AstKeyFrameRule extends BaseToken {
|
|
2080
2215
|
|
|
2081
|
-
typ: EnumToken
|
|
2216
|
+
typ: EnumToken.KeyFramesRuleNodeType;
|
|
2082
2217
|
sel: string;
|
|
2083
|
-
chi: Array<AstDeclaration | AstComment>;
|
|
2218
|
+
chi: Array<AstDeclaration | AstComment | AstInvalidDeclaration>;
|
|
2084
2219
|
optimized?: OptimizedSelector;
|
|
2085
2220
|
raw?: RawSelectorTokens;
|
|
2086
2221
|
tokens?: Token$1[]
|
|
@@ -2120,7 +2255,7 @@ export declare interface OptimizedSelectorToken {
|
|
|
2120
2255
|
*/
|
|
2121
2256
|
export declare interface AstAtRule extends BaseToken {
|
|
2122
2257
|
|
|
2123
|
-
typ: EnumToken
|
|
2258
|
+
typ: EnumToken.AtRuleNodeType,
|
|
2124
2259
|
nam: string;
|
|
2125
2260
|
val: string;
|
|
2126
2261
|
chi?: Array<AstDeclaration | AstInvalidDeclaration | AstComment> | Array<AstRule | AstComment>
|
|
@@ -2131,7 +2266,7 @@ export declare interface AstAtRule extends BaseToken {
|
|
|
2131
2266
|
*/
|
|
2132
2267
|
export declare interface AstKeyframesRule extends BaseToken {
|
|
2133
2268
|
|
|
2134
|
-
typ: EnumToken
|
|
2269
|
+
typ: EnumToken.KeyFramesRuleNodeType;
|
|
2135
2270
|
sel: string;
|
|
2136
2271
|
chi: Array<AstDeclaration | AstInvalidDeclaration | AstComment | AstRuleList>;
|
|
2137
2272
|
optimized?: OptimizedSelector;
|
|
@@ -2143,7 +2278,7 @@ export declare interface AstKeyframesRule extends BaseToken {
|
|
|
2143
2278
|
*/
|
|
2144
2279
|
export declare interface AstKeyframesAtRule extends BaseToken {
|
|
2145
2280
|
|
|
2146
|
-
typ: EnumToken
|
|
2281
|
+
typ: EnumToken.KeyframesAtRuleNodeType,
|
|
2147
2282
|
nam: string;
|
|
2148
2283
|
val: string;
|
|
2149
2284
|
chi: Array<AstKeyframesRule | AstComment>;
|
|
@@ -2152,18 +2287,20 @@ export declare interface AstKeyframesAtRule extends BaseToken {
|
|
|
2152
2287
|
/**
|
|
2153
2288
|
* rule list node
|
|
2154
2289
|
*/
|
|
2155
|
-
export declare
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2290
|
+
export declare type AstRuleList =
|
|
2291
|
+
AstStyleSheet
|
|
2292
|
+
| AstAtRule
|
|
2293
|
+
| AstRule
|
|
2294
|
+
| AstKeyframesAtRule
|
|
2295
|
+
| AstKeyFrameRule
|
|
2296
|
+
| AstInvalidRule;
|
|
2160
2297
|
|
|
2161
2298
|
/**
|
|
2162
|
-
*
|
|
2299
|
+
* stylesheet node
|
|
2163
2300
|
*/
|
|
2164
|
-
export declare interface AstStyleSheet extends
|
|
2165
|
-
typ: EnumToken
|
|
2166
|
-
chi: Array<
|
|
2301
|
+
export declare interface AstStyleSheet extends BaseToken {
|
|
2302
|
+
typ: EnumToken.StyleSheetNodeType,
|
|
2303
|
+
chi: Array<AstRule | AstAtRule | astKeyframesAtRule | AstComment | AstInvalidAtRule | AstInvalidRule>;
|
|
2167
2304
|
tokens?: null;
|
|
2168
2305
|
}
|
|
2169
2306
|
|
|
@@ -2180,15 +2317,18 @@ export declare type AstNode$1 =
|
|
|
2180
2317
|
| AstKeyframesAtRule
|
|
2181
2318
|
| AstKeyFrameRule
|
|
2182
2319
|
| AstInvalidRule
|
|
2183
|
-
|
|
|
2320
|
+
| AstInvalidAtRule
|
|
2321
|
+
| AstInvalidDeclaration
|
|
2322
|
+
| CssVariableToken
|
|
2323
|
+
| CssVariableImportTokenType;
|
|
2184
2324
|
|
|
2185
|
-
export declare type VisitorEventType = 'Enter' | 'Leave' ;
|
|
2186
2325
|
export declare type GenericVisitorResult<T> = T | T[] | Promise<T> | Promise<T[]> | null | Promise<null>;
|
|
2187
2326
|
export declare type GenericVisitorHandler<T> = ((node: T, parent?: AstNode | Token, root?: AstNode | Token) => GenericVisitorResult<T>);
|
|
2188
2327
|
export declare type GenericVisitorAstNodeHandlerMap<T> =
|
|
2189
2328
|
Record<string, GenericVisitorHandler<T>>
|
|
2190
2329
|
| GenericVisitorHandler<T>
|
|
2191
|
-
| { type:
|
|
2330
|
+
| { type: WalkerEvent, handler: GenericVisitorHandler<T> }
|
|
2331
|
+
| { type: WalkerEvent, handler: Record<string, GenericVisitorHandler<T>> };
|
|
2192
2332
|
|
|
2193
2333
|
export declare type ValueVisitorHandler = GenericVisitorHandler<Token>;
|
|
2194
2334
|
|
|
@@ -2402,15 +2542,12 @@ export declare interface VisitorNodeMap {
|
|
|
2402
2542
|
|
|
2403
2543
|
KeyframesRule?: GenericVisitorAstNodeHandlerMap<AstKeyframesRule>;
|
|
2404
2544
|
|
|
2405
|
-
KeyframesAtRule?: GenericVisitorAstNodeHandlerMap<AstKeyframesAtRule
|
|
2545
|
+
KeyframesAtRule?: GenericVisitorAstNodeHandlerMap<AstKeyframesAtRule>;
|
|
2406
2546
|
|
|
2407
2547
|
/**
|
|
2408
2548
|
* value visitor
|
|
2409
2549
|
*/
|
|
2410
|
-
Value?:
|
|
2411
|
-
type: VisitorEventType,
|
|
2412
|
-
handler: GenericVisitorHandler<Token> | Record<keyof EnumToken, GenericVisitorHandler<Token>>
|
|
2413
|
-
};
|
|
2550
|
+
Value?: GenericVisitorAstNodeHandlerMap<Token>;
|
|
2414
2551
|
|
|
2415
2552
|
/**
|
|
2416
2553
|
* generic token visitor. the key name is of type keyof EnumToken.
|
|
@@ -2459,30 +2596,47 @@ export declare interface VisitorNodeMap {
|
|
|
2459
2596
|
* // body {color:#f3fff0}
|
|
2460
2597
|
* ```
|
|
2461
2598
|
*/
|
|
2462
|
-
[key: keyof EnumToken]:
|
|
2463
|
-
type: VisitorEventType,
|
|
2464
|
-
handler: GenericVisitorHandler<Token>
|
|
2465
|
-
};
|
|
2599
|
+
[key : keyof typeof EnumToken]: GenericVisitorAstNodeHandlerMap<Token> | GenericVisitorAstNodeHandlerMap<AstNode>;
|
|
2466
2600
|
}
|
|
2467
2601
|
|
|
2468
2602
|
export declare interface PropertyListOptions {
|
|
2469
2603
|
|
|
2470
|
-
removeDuplicateDeclarations?: boolean;
|
|
2604
|
+
removeDuplicateDeclarations?: boolean | string | string[];
|
|
2471
2605
|
computeShorthand?: boolean;
|
|
2472
2606
|
}
|
|
2473
2607
|
|
|
2608
|
+
/**
|
|
2609
|
+
* parse info
|
|
2610
|
+
*/
|
|
2474
2611
|
export declare interface ParseInfo {
|
|
2475
2612
|
|
|
2613
|
+
/**
|
|
2614
|
+
* read buffer
|
|
2615
|
+
*/
|
|
2476
2616
|
buffer: string;
|
|
2617
|
+
/**
|
|
2618
|
+
* stream
|
|
2619
|
+
*/
|
|
2477
2620
|
stream: string;
|
|
2621
|
+
/**
|
|
2622
|
+
* last token position
|
|
2623
|
+
*/
|
|
2478
2624
|
position: Position;
|
|
2625
|
+
/**
|
|
2626
|
+
* current parsing position
|
|
2627
|
+
*/
|
|
2479
2628
|
currentPosition: Position;
|
|
2629
|
+
|
|
2630
|
+
/**
|
|
2631
|
+
* offset
|
|
2632
|
+
*/
|
|
2633
|
+
offset: number;
|
|
2480
2634
|
}
|
|
2481
2635
|
|
|
2482
2636
|
/**
|
|
2483
2637
|
* feature walk mode
|
|
2484
2638
|
*
|
|
2485
|
-
* @
|
|
2639
|
+
* @private
|
|
2486
2640
|
*/
|
|
2487
2641
|
declare enum FeatureWalkMode {
|
|
2488
2642
|
/**
|
|
@@ -2521,7 +2675,7 @@ interface ShorthandPropertyType {
|
|
|
2521
2675
|
types: string[];
|
|
2522
2676
|
multiple: boolean;
|
|
2523
2677
|
separator: {
|
|
2524
|
-
typ: keyof EnumToken
|
|
2678
|
+
typ: keyof EnumToken;
|
|
2525
2679
|
val: string
|
|
2526
2680
|
};
|
|
2527
2681
|
keywords: string[];
|
|
@@ -2540,13 +2694,13 @@ interface PropertyMapType {
|
|
|
2540
2694
|
required?: boolean;
|
|
2541
2695
|
multiple?: boolean;
|
|
2542
2696
|
prefix?: {
|
|
2543
|
-
typ: keyof EnumToken
|
|
2697
|
+
typ: keyof EnumToken;
|
|
2544
2698
|
val: string
|
|
2545
2699
|
};
|
|
2546
2700
|
previous?: string;
|
|
2547
2701
|
separator?: {
|
|
2548
2702
|
|
|
2549
|
-
typ: keyof EnumToken
|
|
2703
|
+
typ: keyof EnumToken;
|
|
2550
2704
|
};
|
|
2551
2705
|
constraints?: {
|
|
2552
2706
|
[key: string]: {
|
|
@@ -2564,7 +2718,7 @@ interface ShorthandMapType {
|
|
|
2564
2718
|
default: string[];
|
|
2565
2719
|
mapping?: Record<string, string>;
|
|
2566
2720
|
multiple?: boolean;
|
|
2567
|
-
separator?: { typ: keyof EnumToken
|
|
2721
|
+
separator?: { typ: keyof EnumToken; val?: string };
|
|
2568
2722
|
set?: Record<string, string[]>
|
|
2569
2723
|
properties: {
|
|
2570
2724
|
[property: string]: PropertyMapType;
|
|
@@ -2572,7 +2726,7 @@ interface ShorthandMapType {
|
|
|
2572
2726
|
}
|
|
2573
2727
|
|
|
2574
2728
|
interface ShorthandProperties {
|
|
2575
|
-
types: EnumToken
|
|
2729
|
+
types: EnumToken[];
|
|
2576
2730
|
default: string[];
|
|
2577
2731
|
keywords: string[];
|
|
2578
2732
|
required?: boolean;
|
|
@@ -3006,20 +3160,22 @@ interface BorderRadius {
|
|
|
3006
3160
|
/**
|
|
3007
3161
|
* node walker option
|
|
3008
3162
|
*/
|
|
3009
|
-
export declare type WalkerOption = WalkerOptionEnum | Token$1 | null;
|
|
3163
|
+
export declare type WalkerOption = WalkerOptionEnum | AstNode$1 | Token$1 | null;
|
|
3010
3164
|
/**
|
|
3011
3165
|
* returned value:
|
|
3012
3166
|
* - {@link WalkerOptionEnum.Ignore}: ignore this node and its children
|
|
3013
3167
|
* - {@link WalkerOptionEnum.Stop}: stop walking the tree
|
|
3014
3168
|
* - {@link WalkerOptionEnum.Children}: walk the children and ignore the current node
|
|
3015
3169
|
* - {@link WalkerOptionEnum.IgnoreChildren}: walk the node and ignore children
|
|
3170
|
+
* - {@link AstNode}:
|
|
3171
|
+
* - {@link Token}:
|
|
3016
3172
|
*/
|
|
3017
3173
|
export declare type WalkerFilter = (node: AstNode$1) => WalkerOption;
|
|
3018
3174
|
|
|
3019
3175
|
/**
|
|
3020
|
-
* filter
|
|
3176
|
+
* filter nodes
|
|
3021
3177
|
*/
|
|
3022
|
-
export declare type WalkerValueFilter = (node: AstNode$1 | Token$1, parent?: AstNode$1 | Token$1 | null, event?:
|
|
3178
|
+
export declare type WalkerValueFilter = (node: AstNode$1 | Token$1, parent?: AstNode$1 | Token$1 | AstNode$1[] | Token$1[] | null, event?: WalkerEvent) => WalkerOption | null;
|
|
3023
3179
|
|
|
3024
3180
|
export declare interface WalkResult {
|
|
3025
3181
|
node: AstNode$1;
|
|
@@ -3115,7 +3271,7 @@ interface ValidationOptions {
|
|
|
3115
3271
|
*
|
|
3116
3272
|
* @private
|
|
3117
3273
|
*/
|
|
3118
|
-
|
|
3274
|
+
occurrence?: boolean | null;
|
|
3119
3275
|
/**
|
|
3120
3276
|
* at least once
|
|
3121
3277
|
*
|
|
@@ -3172,7 +3328,7 @@ interface MinifyOptions {
|
|
|
3172
3328
|
*
|
|
3173
3329
|
* ```
|
|
3174
3330
|
*/
|
|
3175
|
-
removeDuplicateDeclarations?: boolean | string[];
|
|
3331
|
+
removeDuplicateDeclarations?: boolean | string | string[];
|
|
3176
3332
|
/**
|
|
3177
3333
|
* compute shorthand properties
|
|
3178
3334
|
*/
|
|
@@ -3211,6 +3367,126 @@ export declare type LoadResult =
|
|
|
3211
3367
|
| string
|
|
3212
3368
|
| Promise<string>;
|
|
3213
3369
|
|
|
3370
|
+
export declare interface ModuleOptions {
|
|
3371
|
+
|
|
3372
|
+
/**
|
|
3373
|
+
* use local scope vs global scope
|
|
3374
|
+
*/
|
|
3375
|
+
scoped?: boolean | ModuleScopeEnumOptions;
|
|
3376
|
+
|
|
3377
|
+
/**
|
|
3378
|
+
* module output file path. it is used to generate the scoped name. if not provided, [options.src](../docs/interfaces/node.ParserOptions.html#src) will be used
|
|
3379
|
+
*/
|
|
3380
|
+
filePath?: string;
|
|
3381
|
+
|
|
3382
|
+
/**
|
|
3383
|
+
* generated scope hash length. the default is 5
|
|
3384
|
+
*/
|
|
3385
|
+
hashLength?: number;
|
|
3386
|
+
|
|
3387
|
+
/**
|
|
3388
|
+
* the pattern used to generate scoped names. the supported placeholders are:
|
|
3389
|
+
* - name: the file base name without the extension
|
|
3390
|
+
* - hash: the file path hash
|
|
3391
|
+
* - local: the local name
|
|
3392
|
+
* - path: the file path
|
|
3393
|
+
* - folder: the folder name
|
|
3394
|
+
* - ext: the file extension
|
|
3395
|
+
*
|
|
3396
|
+
* the pattern can optionally have a maximum number of characters:
|
|
3397
|
+
* ```
|
|
3398
|
+
* pattern: '[local:2]-[hash:5]'
|
|
3399
|
+
* ```
|
|
3400
|
+
* the hash pattern can take an algorithm, a maximum number of characters or both:
|
|
3401
|
+
* ```
|
|
3402
|
+
* pattern: '[local]-[hash:base64:5]'
|
|
3403
|
+
* ```
|
|
3404
|
+
* or
|
|
3405
|
+
* ```
|
|
3406
|
+
* pattern: '[local]-[hash:5]'
|
|
3407
|
+
* ```
|
|
3408
|
+
* or
|
|
3409
|
+
* ```
|
|
3410
|
+
* pattern: '[local]-[hash:sha1]'
|
|
3411
|
+
* ```
|
|
3412
|
+
*
|
|
3413
|
+
* supported hash algorithms are:
|
|
3414
|
+
* - base64
|
|
3415
|
+
* - hex
|
|
3416
|
+
* - base64url
|
|
3417
|
+
* - sha1
|
|
3418
|
+
* - sha256
|
|
3419
|
+
* - sha384
|
|
3420
|
+
* - sha512
|
|
3421
|
+
*
|
|
3422
|
+
* ```typescript
|
|
3423
|
+
*
|
|
3424
|
+
* import {transform, ModuleCaseTransformEnum} from '@tbela99/css-parser';
|
|
3425
|
+
* import type {TransformResult} from '@tbela99/css-parser';
|
|
3426
|
+
* css = `
|
|
3427
|
+
* :local(.className) {
|
|
3428
|
+
* background: red;
|
|
3429
|
+
* color: yellow;
|
|
3430
|
+
* }
|
|
3431
|
+
*
|
|
3432
|
+
* :local(.subClass) {
|
|
3433
|
+
* composes: className;
|
|
3434
|
+
* background: blue;
|
|
3435
|
+
* }
|
|
3436
|
+
* `;
|
|
3437
|
+
*
|
|
3438
|
+
* let result: TransformResult = await transform(css, {
|
|
3439
|
+
*
|
|
3440
|
+
* beautify:true,
|
|
3441
|
+
* module: {
|
|
3442
|
+
* pattern: '[local]-[hash:sha256]'
|
|
3443
|
+
* }
|
|
3444
|
+
*
|
|
3445
|
+
* });
|
|
3446
|
+
*
|
|
3447
|
+
* console.log(result.code);
|
|
3448
|
+
* ```
|
|
3449
|
+
* generated css
|
|
3450
|
+
*
|
|
3451
|
+
* ```css
|
|
3452
|
+
* .className-b629f {
|
|
3453
|
+
* background: red;
|
|
3454
|
+
* color: #ff0
|
|
3455
|
+
* }
|
|
3456
|
+
* .subClass-a0c35 {
|
|
3457
|
+
* background: blue
|
|
3458
|
+
* }
|
|
3459
|
+
* ```
|
|
3460
|
+
*/
|
|
3461
|
+
pattern?: string;
|
|
3462
|
+
|
|
3463
|
+
/**
|
|
3464
|
+
* optional. function change the case of the scoped name and the class mapping
|
|
3465
|
+
*
|
|
3466
|
+
* - {@link ModuleCaseTransformEnum.IgnoreCase}: do not change case
|
|
3467
|
+
* - {@link ModuleCaseTransformEnum.CamelCase}: camelCase {@link ParseResult.mapping} key name
|
|
3468
|
+
* - {@link ModuleCaseTransformEnum.CamelCaseOnly}: camelCase {@link ParseResult.mapping} key name and the scoped class name
|
|
3469
|
+
* - {@link ModuleCaseTransformEnum.DashCase}: dashCase {@link ParseResult.mapping} key name
|
|
3470
|
+
* - {@link ModuleCaseTransformEnum.DashCaseOnly}: dashCase {@link ParseResult.mapping} key name and the scoped class name
|
|
3471
|
+
*
|
|
3472
|
+
*/
|
|
3473
|
+
naming?: ModuleCaseTransformEnum,
|
|
3474
|
+
|
|
3475
|
+
/**
|
|
3476
|
+
* optional function to generate scoped name
|
|
3477
|
+
* @param localName
|
|
3478
|
+
* @param filePath
|
|
3479
|
+
* @param pattern see {@link ModuleOptions.pattern}
|
|
3480
|
+
* @param hashLength
|
|
3481
|
+
*/
|
|
3482
|
+
generateScopedName?: (
|
|
3483
|
+
localName: string,
|
|
3484
|
+
filePath: string,
|
|
3485
|
+
pattern: string,
|
|
3486
|
+
hashLength?: number
|
|
3487
|
+
) => string | Promise<string>;
|
|
3488
|
+
}
|
|
3489
|
+
|
|
3214
3490
|
/**
|
|
3215
3491
|
* parser options
|
|
3216
3492
|
*/
|
|
@@ -3246,9 +3522,10 @@ export declare interface ParserOptions extends MinifyOptions, MinifyFeatureOptio
|
|
|
3246
3522
|
* url and file loader
|
|
3247
3523
|
* @param url
|
|
3248
3524
|
* @param currentUrl
|
|
3525
|
+
* @param asStream
|
|
3249
3526
|
*
|
|
3250
3527
|
*/
|
|
3251
|
-
load?: (url: string, currentUrl
|
|
3528
|
+
load?: (url: string, currentUrl?: string, asStream?: boolean) => LoadResult;
|
|
3252
3529
|
/**
|
|
3253
3530
|
* get directory name
|
|
3254
3531
|
* @param path
|
|
@@ -3274,9 +3551,9 @@ export declare interface ParserOptions extends MinifyOptions, MinifyFeatureOptio
|
|
|
3274
3551
|
|
|
3275
3552
|
/**
|
|
3276
3553
|
* node visitor
|
|
3277
|
-
* {@link VisitorNodeMap}
|
|
3554
|
+
* {@link VisitorNodeMap | VisitorNodeMap[]}
|
|
3278
3555
|
*/
|
|
3279
|
-
visitor?: VisitorNodeMap;
|
|
3556
|
+
visitor?: VisitorNodeMap | VisitorNodeMap[];
|
|
3280
3557
|
/**
|
|
3281
3558
|
* abort signal
|
|
3282
3559
|
*
|
|
@@ -3302,6 +3579,11 @@ export declare interface ParserOptions extends MinifyOptions, MinifyFeatureOptio
|
|
|
3302
3579
|
* @private
|
|
3303
3580
|
*/
|
|
3304
3581
|
cache?: WeakMap<AstNode$1, string>;
|
|
3582
|
+
|
|
3583
|
+
/**
|
|
3584
|
+
* css modules options
|
|
3585
|
+
*/
|
|
3586
|
+
module?: boolean | ModuleCaseTransformEnum | ModuleScopeEnumOptions | ModuleOptions
|
|
3305
3587
|
}
|
|
3306
3588
|
|
|
3307
3589
|
/**
|
|
@@ -3326,6 +3608,11 @@ export declare interface MinifyFeatureOptions {
|
|
|
3326
3608
|
*/
|
|
3327
3609
|
export declare interface MinifyFeature {
|
|
3328
3610
|
|
|
3611
|
+
/**
|
|
3612
|
+
* accepted tokens
|
|
3613
|
+
*/
|
|
3614
|
+
accept?: Set<EnumToken>;
|
|
3615
|
+
|
|
3329
3616
|
/**
|
|
3330
3617
|
* ordering
|
|
3331
3618
|
*/
|
|
@@ -3473,13 +3760,17 @@ export declare interface ParseResultStats {
|
|
|
3473
3760
|
*/
|
|
3474
3761
|
importedBytesIn: number;
|
|
3475
3762
|
/**
|
|
3476
|
-
* parse time
|
|
3763
|
+
* parse processing time
|
|
3477
3764
|
*/
|
|
3478
3765
|
parse: string;
|
|
3479
3766
|
/**
|
|
3480
|
-
* minify time
|
|
3767
|
+
* minify processing time
|
|
3481
3768
|
*/
|
|
3482
3769
|
minify: string;
|
|
3770
|
+
/**
|
|
3771
|
+
* module processing time
|
|
3772
|
+
*/
|
|
3773
|
+
module?: string;
|
|
3483
3774
|
/**
|
|
3484
3775
|
* total time
|
|
3485
3776
|
*/
|
|
@@ -3487,7 +3778,17 @@ export declare interface ParseResultStats {
|
|
|
3487
3778
|
/**
|
|
3488
3779
|
* imported files stats
|
|
3489
3780
|
*/
|
|
3490
|
-
imports: ParseResultStats[]
|
|
3781
|
+
imports: ParseResultStats[],
|
|
3782
|
+
|
|
3783
|
+
/**
|
|
3784
|
+
* nodes count
|
|
3785
|
+
*/
|
|
3786
|
+
nodesCount: number;
|
|
3787
|
+
|
|
3788
|
+
/**
|
|
3789
|
+
* tokens count
|
|
3790
|
+
*/
|
|
3791
|
+
tokensCount: number;
|
|
3491
3792
|
}
|
|
3492
3793
|
|
|
3493
3794
|
/**
|
|
@@ -3505,7 +3806,22 @@ export declare interface ParseResult {
|
|
|
3505
3806
|
/**
|
|
3506
3807
|
* parse stats
|
|
3507
3808
|
*/
|
|
3508
|
-
stats: ParseResultStats
|
|
3809
|
+
stats: ParseResultStats;
|
|
3810
|
+
|
|
3811
|
+
/**
|
|
3812
|
+
* css module mapping
|
|
3813
|
+
*/
|
|
3814
|
+
mapping?: Record<string, string>;
|
|
3815
|
+
|
|
3816
|
+
cssModuleVariables?: Record<string, CssVariableToken$1>;
|
|
3817
|
+
|
|
3818
|
+
importMapping?: Record<string, Record<string, string>>;
|
|
3819
|
+
|
|
3820
|
+
/**
|
|
3821
|
+
* css module reverse mapping
|
|
3822
|
+
* @private
|
|
3823
|
+
*/
|
|
3824
|
+
revMapping?: Record<string, string>;
|
|
3509
3825
|
}
|
|
3510
3826
|
|
|
3511
3827
|
/**
|
|
@@ -3605,7 +3921,7 @@ export declare interface TokenizeResult {
|
|
|
3605
3921
|
/**
|
|
3606
3922
|
* token type hint
|
|
3607
3923
|
*/
|
|
3608
|
-
hint?: EnumToken
|
|
3924
|
+
hint?: EnumToken;
|
|
3609
3925
|
/**
|
|
3610
3926
|
* token start position
|
|
3611
3927
|
*/
|
|
@@ -3708,19 +4024,39 @@ declare function resolve(url: string, currentDirectory: string, cwd?: string): {
|
|
|
3708
4024
|
relative: string;
|
|
3709
4025
|
};
|
|
3710
4026
|
|
|
4027
|
+
/**
|
|
4028
|
+
* response type
|
|
4029
|
+
*/
|
|
4030
|
+
declare enum ResponseType {
|
|
4031
|
+
/**
|
|
4032
|
+
* return text
|
|
4033
|
+
*/
|
|
4034
|
+
Text = 0,
|
|
4035
|
+
/**
|
|
4036
|
+
* return a readable stream
|
|
4037
|
+
*/
|
|
4038
|
+
ReadableStream = 1,
|
|
4039
|
+
/**
|
|
4040
|
+
* return an arraybuffer
|
|
4041
|
+
*/
|
|
4042
|
+
ArrayBuffer = 2
|
|
4043
|
+
}
|
|
4044
|
+
|
|
3711
4045
|
/**
|
|
3712
4046
|
* load file or url as stream
|
|
3713
4047
|
* @param url
|
|
3714
4048
|
* @param currentFile
|
|
4049
|
+
* @param responseType
|
|
3715
4050
|
* @throws Error file not found
|
|
3716
4051
|
*
|
|
3717
4052
|
* @private
|
|
3718
4053
|
*/
|
|
3719
|
-
declare function load(url: string, currentFile?: string): Promise<ReadableStream<Uint8Array
|
|
4054
|
+
declare function load(url: string, currentFile?: string, responseType?: boolean | ResponseType): Promise<string | ArrayBuffer | ReadableStream<Uint8Array<ArrayBufferLike>>>;
|
|
3720
4055
|
/**
|
|
3721
4056
|
* render the ast tree
|
|
3722
4057
|
* @param data
|
|
3723
4058
|
* @param options
|
|
4059
|
+
* @param mapping
|
|
3724
4060
|
*
|
|
3725
4061
|
* Example:
|
|
3726
4062
|
*
|
|
@@ -3745,11 +4081,15 @@ declare function load(url: string, currentFile?: string): Promise<ReadableStream
|
|
|
3745
4081
|
* // }
|
|
3746
4082
|
* ```
|
|
3747
4083
|
*/
|
|
3748
|
-
declare function render(data: AstNode$1, options?: RenderOptions
|
|
4084
|
+
declare function render(data: AstNode$1, options?: RenderOptions, mapping?: {
|
|
4085
|
+
mapping: Record<string, string>;
|
|
4086
|
+
importMapping: Record<string, Record<string, string>> | null;
|
|
4087
|
+
} | null): RenderResult;
|
|
3749
4088
|
/**
|
|
3750
4089
|
* parse css file
|
|
3751
4090
|
* @param file url or path
|
|
3752
4091
|
* @param options
|
|
4092
|
+
* @param asStream load file as stream
|
|
3753
4093
|
*
|
|
3754
4094
|
* @throws Error file not found
|
|
3755
4095
|
*
|
|
@@ -3768,7 +4108,7 @@ declare function render(data: AstNode$1, options?: RenderOptions): RenderResult;
|
|
|
3768
4108
|
* console.log(result.ast);
|
|
3769
4109
|
* ```
|
|
3770
4110
|
*/
|
|
3771
|
-
declare function parseFile(file: string, options?: ParserOptions): Promise<ParseResult>;
|
|
4111
|
+
declare function parseFile(file: string, options?: ParserOptions, asStream?: boolean): Promise<ParseResult>;
|
|
3772
4112
|
/**
|
|
3773
4113
|
* parse css
|
|
3774
4114
|
* @param stream
|
|
@@ -3817,6 +4157,7 @@ declare function parse(stream: string | ReadableStream<Uint8Array>, options?: Pa
|
|
|
3817
4157
|
* transform css file
|
|
3818
4158
|
* @param file url or path
|
|
3819
4159
|
* @param options
|
|
4160
|
+
* @param asStream load file as stream
|
|
3820
4161
|
*
|
|
3821
4162
|
* @throws Error file not found
|
|
3822
4163
|
*
|
|
@@ -3835,7 +4176,7 @@ declare function parse(stream: string | ReadableStream<Uint8Array>, options?: Pa
|
|
|
3835
4176
|
* console.log(result.code);
|
|
3836
4177
|
* ```
|
|
3837
4178
|
*/
|
|
3838
|
-
declare function transformFile(file: string, options?: TransformOptions): Promise<TransformResult>;
|
|
4179
|
+
declare function transformFile(file: string, options?: TransformOptions, asStream?: boolean): Promise<TransformResult>;
|
|
3839
4180
|
/**
|
|
3840
4181
|
* transform css
|
|
3841
4182
|
* @param css
|
|
@@ -3881,5 +4222,5 @@ declare function transformFile(file: string, options?: TransformOptions): Promis
|
|
|
3881
4222
|
*/
|
|
3882
4223
|
declare function transform(css: string | ReadableStream<Uint8Array>, options?: TransformOptions): Promise<TransformResult>;
|
|
3883
4224
|
|
|
3884
|
-
export { ColorType, EnumToken
|
|
3885
|
-
export type { AddToken, AngleToken, AstAtRule, AstComment, AstDeclaration, AstInvalidAtRule, AstInvalidDeclaration, AstInvalidRule, AstKeyFrameRule, AstKeyframesAtRule, AstKeyframesRule, AstNode$1 as AstNode, AstRule, AstRuleList, AstStyleSheet, AtRuleToken, AtRuleVisitorHandler, AttrEndToken, AttrStartToken, AttrToken, Background, BackgroundAttachmentMapping, BackgroundPosition, BackgroundPositionClass, BackgroundPositionConstraints, BackgroundPositionMapping, BackgroundProperties, BackgroundRepeat, BackgroundRepeatMapping, BackgroundSize, BackgroundSizeMapping, BadCDOCommentToken, BadCommentToken, BadStringToken, BadUrlToken, BaseToken, BinaryExpressionNode, BinaryExpressionToken, BlockEndToken, BlockStartToken, Border, BorderColor, BorderColorClass, BorderProperties, BorderRadius, CDOCommentToken, ChildCombinatorToken, ClassSelectorToken, ColonToken, ColorToken, ColumnCombinatorToken, CommaToken, CommentToken, ConstraintsMapping, ContainMatchToken, Context, DashMatchToken, DashedIdentToken, DeclarationVisitorHandler, DelimToken, DescendantCombinatorToken, DimensionToken, DivToken, EOFToken, EndMatchToken, EqualMatchToken, ErrorDescription, FlexToken, Font, FontFamily, FontProperties, FontWeight, FontWeightConstraints, FontWeightMapping, FractionToken, FrequencyToken, FunctionImageToken, FunctionToken, FunctionURLToken, GenericVisitorAstNodeHandlerMap, GenericVisitorHandler, GenericVisitorResult, GreaterThanOrEqualToken, GreaterThanToken, GridTemplateFuncToken, HashToken, IdentListToken, IdentToken, ImportantToken, IncludeMatchToken, InvalidAttrToken, InvalidClassSelectorToken, LengthToken, LessThanOrEqualToken, LessThanToken, LineHeight, ListToken, LiteralToken, LoadResult, Location, Map$1 as Map, MatchExpressionToken, MatchedSelector, MediaFeatureAndToken, MediaFeatureNotToken, MediaFeatureOnlyToken, MediaFeatureOrToken, MediaFeatureToken, MediaQueryConditionToken, MinifyFeature, MinifyFeatureOptions, MinifyOptions, MulToken, NameSpaceAttributeToken, NestingSelectorToken, NextSiblingCombinatorToken, NumberToken, OptimizedSelector, OptimizedSelectorToken, Outline, OutlineProperties, ParensEndToken, ParensStartToken, ParensToken, ParseInfo, ParseResult, ParseResultStats, ParseTokenOptions, ParserOptions, PercentageToken, Position, Prefix, PropertiesConfig, PropertiesConfigProperties, PropertyListOptions, PropertyMapType, PropertySetType, PropertyType, PseudoClassFunctionToken, PseudoClassToken, PseudoElementToken, PseudoPageToken, PurpleBackgroundAttachment, RawSelectorTokens, RenderOptions, RenderResult, ResolutionToken, ResolvedPath, RuleVisitorHandler, SemiColonToken, Separator, ShorthandDef, ShorthandMapType, ShorthandProperties, ShorthandPropertyType, ShorthandType, SourceMapObject, StartMatchToken, StringToken, SubToken, SubsequentCombinatorToken, TimeToken, TimelineFunctionToken, TimingFunctionToken, Token$1 as Token, TokenizeResult, TransformOptions, TransformResult, UnaryExpression, UnaryExpressionNode, UnclosedStringToken, UniversalSelectorToken, UrlToken, ValidationConfiguration, ValidationOptions, ValidationResult, ValidationSelectorOptions, ValidationSyntaxNode, ValidationSyntaxResult, Value, ValueVisitorHandler, VariableScopeInfo,
|
|
4225
|
+
export { ColorType, EnumToken, FeatureWalkMode, ModuleCaseTransformEnum, ModuleScopeEnumOptions, ResponseType, SourceMap, ValidationLevel, WalkerEvent, WalkerOptionEnum, convertColor, dirname, expand, isOkLabClose, load, mathFuncs, minify, okLabDistance, parse, parseDeclarations, parseFile, parseString, parseTokens, render, renderToken, resolve, transform, transformFile, transformFunctions, walk, walkValues };
|
|
4226
|
+
export type { AddToken, AngleToken, AstAtRule, AstComment, AstDeclaration, AstInvalidAtRule, AstInvalidDeclaration, AstInvalidRule, AstKeyFrameRule, AstKeyframesAtRule, AstKeyframesRule, AstNode$1 as AstNode, AstRule, AstRuleList, AstStyleSheet, AtRuleToken, AtRuleVisitorHandler, AttrEndToken, AttrStartToken, AttrToken, Background, BackgroundAttachmentMapping, BackgroundPosition, BackgroundPositionClass, BackgroundPositionConstraints, BackgroundPositionMapping, BackgroundProperties, BackgroundRepeat, BackgroundRepeatMapping, BackgroundSize, BackgroundSizeMapping, BadCDOCommentToken, BadCommentToken, BadStringToken, BadUrlToken, BaseToken, BinaryExpressionNode, BinaryExpressionToken, BlockEndToken, BlockStartToken, Border, BorderColor, BorderColorClass, BorderProperties, BorderRadius, CDOCommentToken, ChildCombinatorToken, ClassSelectorToken, ColonToken, ColorToken, ColumnCombinatorToken, CommaToken, CommentToken, ComposesSelectorToken, ConstraintsMapping, ContainMatchToken, Context, CssVariableImportTokenType$1 as CssVariableImportTokenType, CssVariableMapTokenType, CssVariableToken$1 as CssVariableToken, DashMatchToken, DashedIdentToken, DeclarationVisitorHandler, DelimToken, DescendantCombinatorToken, DimensionToken, DivToken, EOFToken, EndMatchToken, EqualMatchToken, ErrorDescription, FlexToken, Font, FontFamily, FontProperties, FontWeight, FontWeightConstraints, FontWeightMapping, FractionToken, FrequencyToken, FunctionImageToken, FunctionToken, FunctionURLToken, GenericVisitorAstNodeHandlerMap, GenericVisitorHandler, GenericVisitorResult, GreaterThanOrEqualToken, GreaterThanToken, GridTemplateFuncToken, HashToken, IdentListToken, IdentToken, ImportantToken, IncludeMatchToken, InvalidAttrToken, InvalidClassSelectorToken, LengthToken, LessThanOrEqualToken, LessThanToken, LineHeight, ListToken, LiteralToken, LoadResult, Location, Map$1 as Map, MatchExpressionToken, MatchedSelector, MediaFeatureAndToken, MediaFeatureNotToken, MediaFeatureOnlyToken, MediaFeatureOrToken, MediaFeatureToken, MediaQueryConditionToken, MinifyFeature, MinifyFeatureOptions, MinifyOptions, ModuleOptions, MulToken, NameSpaceAttributeToken, NestingSelectorToken, NextSiblingCombinatorToken, NumberToken, OptimizedSelector, OptimizedSelectorToken, Outline, OutlineProperties, ParensEndToken, ParensStartToken, ParensToken, ParseInfo, ParseResult, ParseResultStats, ParseTokenOptions, ParserOptions, PercentageToken, Position, Prefix, PropertiesConfig, PropertiesConfigProperties, PropertyListOptions, PropertyMapType, PropertySetType, PropertyType, PseudoClassFunctionToken, PseudoClassToken, PseudoElementToken, PseudoPageToken, PurpleBackgroundAttachment, RawSelectorTokens, RenderOptions, RenderResult, ResolutionToken, ResolvedPath, RuleVisitorHandler, SemiColonToken, Separator, ShorthandDef, ShorthandMapType, ShorthandProperties, ShorthandPropertyType, ShorthandType, SourceMapObject, StartMatchToken, StringToken, SubToken, SubsequentCombinatorToken, TimeToken, TimelineFunctionToken, TimingFunctionToken, Token$1 as Token, TokenizeResult, TransformOptions, TransformResult, UnaryExpression, UnaryExpressionNode, UnclosedStringToken, UniversalSelectorToken, UrlToken, ValidationConfiguration, ValidationOptions, ValidationResult, ValidationSelectorOptions, ValidationSyntaxNode, ValidationSyntaxResult, Value, ValueVisitorHandler, VariableScopeInfo, VisitorNodeMap, WalkAttributesResult, WalkResult, WalkerFilter, WalkerOption, WalkerValueFilter, WhitespaceToken };
|