postcss-calc 10.0.0 → 10.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/package.json +9 -26
- package/src/lib/reducer.js +26 -0
- package/src/parser.d.ts +27 -1
- package/src/parser.js +527 -163
- package/types/index.d.ts +2 -2
- package/types/lib/reducer.d.ts +3 -3
- package/types/lib/stringifier.d.ts +1 -1
- package/types/lib/transform.d.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "postcss-calc",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.0.2",
|
|
4
4
|
"description": "PostCSS plugin to reduce calc()",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"css",
|
|
@@ -23,37 +23,20 @@
|
|
|
23
23
|
],
|
|
24
24
|
"author": "Andy Jansson",
|
|
25
25
|
"license": "MIT",
|
|
26
|
-
"eslintConfig": {
|
|
27
|
-
"extends": [
|
|
28
|
-
"eslint:recommended",
|
|
29
|
-
"prettier"
|
|
30
|
-
],
|
|
31
|
-
"env": {
|
|
32
|
-
"node": true,
|
|
33
|
-
"es2017": true
|
|
34
|
-
},
|
|
35
|
-
"ignorePatterns": [
|
|
36
|
-
"src/parser.js"
|
|
37
|
-
],
|
|
38
|
-
"rules": {
|
|
39
|
-
"curly": "error"
|
|
40
|
-
}
|
|
41
|
-
},
|
|
42
26
|
"engines": {
|
|
43
27
|
"node": "^18.12 || ^20.9 || >=22.0"
|
|
44
28
|
},
|
|
45
29
|
"devDependencies": {
|
|
46
|
-
"@types/node": "^
|
|
47
|
-
"eslint": "^9.
|
|
30
|
+
"@types/node": "^22.4.0",
|
|
31
|
+
"eslint": "^9.9.0",
|
|
48
32
|
"eslint-config-prettier": "^9.1.0",
|
|
49
|
-
"jison-gho": "
|
|
50
|
-
"postcss": "^8.4.
|
|
51
|
-
"prettier": "^3.
|
|
52
|
-
"typescript": "~5.4
|
|
53
|
-
"uvu": "^0.5.6"
|
|
33
|
+
"jison-gho": "0.6.1-216",
|
|
34
|
+
"postcss": "^8.4.41",
|
|
35
|
+
"prettier": "^3.3.3",
|
|
36
|
+
"typescript": "~5.5.4"
|
|
54
37
|
},
|
|
55
38
|
"dependencies": {
|
|
56
|
-
"postcss-selector-parser": "^6.
|
|
39
|
+
"postcss-selector-parser": "^6.1.2",
|
|
57
40
|
"postcss-value-parser": "^4.2.0"
|
|
58
41
|
},
|
|
59
42
|
"peerDependencies": {
|
|
@@ -62,6 +45,6 @@
|
|
|
62
45
|
"scripts": {
|
|
63
46
|
"build": "jison ./parser.jison -o src/parser.js",
|
|
64
47
|
"lint": "eslint . && tsc",
|
|
65
|
-
"test": "
|
|
48
|
+
"test": "node --test"
|
|
66
49
|
}
|
|
67
50
|
}
|
package/src/lib/reducer.js
CHANGED
|
@@ -17,9 +17,35 @@ function isValueType(node) {
|
|
|
17
17
|
case 'ChValue':
|
|
18
18
|
case 'RemValue':
|
|
19
19
|
case 'VhValue':
|
|
20
|
+
case 'SvhValue':
|
|
21
|
+
case 'LvhValue':
|
|
22
|
+
case 'DvhValue':
|
|
20
23
|
case 'VwValue':
|
|
24
|
+
case 'SvwValue':
|
|
25
|
+
case 'LvwValue':
|
|
26
|
+
case 'DvwValue':
|
|
21
27
|
case 'VminValue':
|
|
28
|
+
case 'SvminValue':
|
|
29
|
+
case 'LvminValue':
|
|
30
|
+
case 'DvminValue':
|
|
22
31
|
case 'VmaxValue':
|
|
32
|
+
case 'SvmaxValue':
|
|
33
|
+
case 'LvmaxValue':
|
|
34
|
+
case 'DvmaxValue':
|
|
35
|
+
case 'VbValue':
|
|
36
|
+
case 'SvbValue':
|
|
37
|
+
case 'LvbValue':
|
|
38
|
+
case 'DvbValue':
|
|
39
|
+
case 'ViValue':
|
|
40
|
+
case 'SviValue':
|
|
41
|
+
case 'LviValue':
|
|
42
|
+
case 'DviValue':
|
|
43
|
+
case 'CqwValue':
|
|
44
|
+
case 'CqhValue':
|
|
45
|
+
case 'CqiValue':
|
|
46
|
+
case 'CqbValue':
|
|
47
|
+
case 'CqminValue':
|
|
48
|
+
case 'CqmaxValue':
|
|
23
49
|
case 'PercentageValue':
|
|
24
50
|
case 'Number':
|
|
25
51
|
return true;
|
package/src/parser.d.ts
CHANGED
|
@@ -23,9 +23,35 @@ export interface DimensionExpression {
|
|
|
23
23
|
| 'ChValue'
|
|
24
24
|
| 'RemValue'
|
|
25
25
|
| 'VhValue'
|
|
26
|
+
| 'SvhValue'
|
|
27
|
+
| 'LvhValue'
|
|
28
|
+
| 'DvhValue'
|
|
26
29
|
| 'VwValue'
|
|
30
|
+
| 'SvwValue'
|
|
31
|
+
| 'LvwValue'
|
|
32
|
+
| 'DvwValue'
|
|
27
33
|
| 'VminValue'
|
|
28
|
-
| '
|
|
34
|
+
| 'SvminValue'
|
|
35
|
+
| 'LvminValue'
|
|
36
|
+
| 'DvminValue'
|
|
37
|
+
| 'VmaxValue'
|
|
38
|
+
| 'SvmaxValue'
|
|
39
|
+
| 'LvmaxValue'
|
|
40
|
+
| 'DvmaxValue'
|
|
41
|
+
| 'VbValue'
|
|
42
|
+
| 'SvbValue'
|
|
43
|
+
| 'LvbValue'
|
|
44
|
+
| 'DvbValue'
|
|
45
|
+
| 'ViValue'
|
|
46
|
+
| 'SviValue'
|
|
47
|
+
| 'LviValue'
|
|
48
|
+
| 'DviValue'
|
|
49
|
+
| 'CqwValue'
|
|
50
|
+
| 'CqhValue'
|
|
51
|
+
| 'CqbValue'
|
|
52
|
+
| 'CqiValue'
|
|
53
|
+
| 'CqminValue'
|
|
54
|
+
| 'CqmaxValue';
|
|
29
55
|
value: number;
|
|
30
56
|
unit: string;
|
|
31
57
|
}
|
package/src/parser.js
CHANGED
|
@@ -613,7 +613,19 @@ symbols_: {
|
|
|
613
613
|
"ANGLE": 12,
|
|
614
614
|
"CALC": 3,
|
|
615
615
|
"CHS": 19,
|
|
616
|
+
"CQBS": 48,
|
|
617
|
+
"CQHS": 46,
|
|
618
|
+
"CQIS": 47,
|
|
619
|
+
"CQMAXS": 50,
|
|
620
|
+
"CQMINS": 49,
|
|
621
|
+
"CQWS": 45,
|
|
616
622
|
"DIV": 9,
|
|
623
|
+
"DVBS": 40,
|
|
624
|
+
"DVHS": 24,
|
|
625
|
+
"DVIS": 44,
|
|
626
|
+
"DVMAXS": 36,
|
|
627
|
+
"DVMINS": 32,
|
|
628
|
+
"DVWS": 28,
|
|
617
629
|
"EMS": 17,
|
|
618
630
|
"EOF": 1,
|
|
619
631
|
"EXS": 18,
|
|
@@ -621,25 +633,39 @@ symbols_: {
|
|
|
621
633
|
"FUNCTION": 10,
|
|
622
634
|
"LENGTH": 11,
|
|
623
635
|
"LPAREN": 4,
|
|
636
|
+
"LVBS": 39,
|
|
637
|
+
"LVHS": 23,
|
|
638
|
+
"LVIS": 43,
|
|
639
|
+
"LVMAXS": 35,
|
|
640
|
+
"LVMINS": 31,
|
|
641
|
+
"LVWS": 27,
|
|
624
642
|
"MUL": 8,
|
|
625
|
-
"NUMBER":
|
|
626
|
-
"PERCENTAGE":
|
|
643
|
+
"NUMBER": 52,
|
|
644
|
+
"PERCENTAGE": 51,
|
|
627
645
|
"REMS": 20,
|
|
628
646
|
"RES": 15,
|
|
629
647
|
"RPAREN": 5,
|
|
630
648
|
"SUB": 7,
|
|
649
|
+
"SVBS": 38,
|
|
650
|
+
"SVHS": 22,
|
|
651
|
+
"SVIS": 42,
|
|
652
|
+
"SVMAXS": 34,
|
|
653
|
+
"SVMINS": 30,
|
|
654
|
+
"SVWS": 26,
|
|
631
655
|
"TIME": 13,
|
|
632
656
|
"UNKNOWN_DIMENSION": 16,
|
|
657
|
+
"VBS": 37,
|
|
633
658
|
"VHS": 21,
|
|
634
|
-
"
|
|
635
|
-
"
|
|
636
|
-
"
|
|
637
|
-
"
|
|
659
|
+
"VIS": 41,
|
|
660
|
+
"VMAXS": 33,
|
|
661
|
+
"VMINS": 29,
|
|
662
|
+
"VWS": 25,
|
|
663
|
+
"dimension": 56,
|
|
638
664
|
"error": 2,
|
|
639
|
-
"expression":
|
|
640
|
-
"function":
|
|
641
|
-
"math_expression":
|
|
642
|
-
"number":
|
|
665
|
+
"expression": 53,
|
|
666
|
+
"function": 55,
|
|
667
|
+
"math_expression": 54,
|
|
668
|
+
"number": 57
|
|
643
669
|
},
|
|
644
670
|
terminals_: {
|
|
645
671
|
1: "EOF",
|
|
@@ -663,11 +689,37 @@ terminals_: {
|
|
|
663
689
|
19: "CHS",
|
|
664
690
|
20: "REMS",
|
|
665
691
|
21: "VHS",
|
|
666
|
-
22: "
|
|
667
|
-
23: "
|
|
668
|
-
24: "
|
|
669
|
-
25: "
|
|
670
|
-
26: "
|
|
692
|
+
22: "SVHS",
|
|
693
|
+
23: "LVHS",
|
|
694
|
+
24: "DVHS",
|
|
695
|
+
25: "VWS",
|
|
696
|
+
26: "SVWS",
|
|
697
|
+
27: "LVWS",
|
|
698
|
+
28: "DVWS",
|
|
699
|
+
29: "VMINS",
|
|
700
|
+
30: "SVMINS",
|
|
701
|
+
31: "LVMINS",
|
|
702
|
+
32: "DVMINS",
|
|
703
|
+
33: "VMAXS",
|
|
704
|
+
34: "SVMAXS",
|
|
705
|
+
35: "LVMAXS",
|
|
706
|
+
36: "DVMAXS",
|
|
707
|
+
37: "VBS",
|
|
708
|
+
38: "SVBS",
|
|
709
|
+
39: "LVBS",
|
|
710
|
+
40: "DVBS",
|
|
711
|
+
41: "VIS",
|
|
712
|
+
42: "SVIS",
|
|
713
|
+
43: "LVIS",
|
|
714
|
+
44: "DVIS",
|
|
715
|
+
45: "CQWS",
|
|
716
|
+
46: "CQHS",
|
|
717
|
+
47: "CQIS",
|
|
718
|
+
48: "CQBS",
|
|
719
|
+
49: "CQMINS",
|
|
720
|
+
50: "CQMAXS",
|
|
721
|
+
51: "PERCENTAGE",
|
|
722
|
+
52: "NUMBER"
|
|
671
723
|
},
|
|
672
724
|
TERROR: 2,
|
|
673
725
|
EOF: 1,
|
|
@@ -773,14 +825,14 @@ TERROR: 2,
|
|
|
773
825
|
},
|
|
774
826
|
productions_: bp({
|
|
775
827
|
pop: u([
|
|
776
|
-
|
|
828
|
+
53,
|
|
777
829
|
s,
|
|
778
|
-
[
|
|
779
|
-
|
|
830
|
+
[54, 9],
|
|
831
|
+
55,
|
|
780
832
|
s,
|
|
781
|
-
[
|
|
833
|
+
[56, 43],
|
|
782
834
|
s,
|
|
783
|
-
[
|
|
835
|
+
[57, 3]
|
|
784
836
|
]),
|
|
785
837
|
rule: u([
|
|
786
838
|
2,
|
|
@@ -788,7 +840,7 @@ productions_: bp({
|
|
|
788
840
|
s,
|
|
789
841
|
[3, 5],
|
|
790
842
|
s,
|
|
791
|
-
[1,
|
|
843
|
+
[1, 45],
|
|
792
844
|
2,
|
|
793
845
|
2,
|
|
794
846
|
c,
|
|
@@ -933,50 +985,206 @@ case 22:
|
|
|
933
985
|
break;
|
|
934
986
|
|
|
935
987
|
case 23:
|
|
988
|
+
/*! Production:: dimension : SVHS */
|
|
989
|
+
|
|
990
|
+
this.$ = { type: 'SvhValue', value: parseFloat(yyvstack[yysp]), unit: 'svh' };
|
|
991
|
+
break;
|
|
992
|
+
|
|
993
|
+
case 24:
|
|
994
|
+
/*! Production:: dimension : LVHS */
|
|
995
|
+
|
|
996
|
+
this.$ = { type: 'LvhValue', value: parseFloat(yyvstack[yysp]), unit: 'lvh' };
|
|
997
|
+
break;
|
|
998
|
+
|
|
999
|
+
case 25:
|
|
1000
|
+
/*! Production:: dimension : DVHS */
|
|
1001
|
+
|
|
1002
|
+
this.$ = { type: 'DvhValue', value: parseFloat(yyvstack[yysp]), unit: 'dvh' };
|
|
1003
|
+
break;
|
|
1004
|
+
|
|
1005
|
+
case 26:
|
|
936
1006
|
/*! Production:: dimension : VWS */
|
|
937
1007
|
|
|
938
1008
|
this.$ = { type: 'VwValue', value: parseFloat(yyvstack[yysp]), unit: 'vw' };
|
|
939
1009
|
break;
|
|
940
1010
|
|
|
941
|
-
case
|
|
1011
|
+
case 27:
|
|
1012
|
+
/*! Production:: dimension : SVWS */
|
|
1013
|
+
|
|
1014
|
+
this.$ = { type: 'SvwValue', value: parseFloat(yyvstack[yysp]), unit: 'svw' };
|
|
1015
|
+
break;
|
|
1016
|
+
|
|
1017
|
+
case 28:
|
|
1018
|
+
/*! Production:: dimension : LVWS */
|
|
1019
|
+
|
|
1020
|
+
this.$ = { type: 'LvwValue', value: parseFloat(yyvstack[yysp]), unit: 'lvw' };
|
|
1021
|
+
break;
|
|
1022
|
+
|
|
1023
|
+
case 29:
|
|
1024
|
+
/*! Production:: dimension : DVWS */
|
|
1025
|
+
|
|
1026
|
+
this.$ = { type: 'DvwValue', value: parseFloat(yyvstack[yysp]), unit: 'dvw' };
|
|
1027
|
+
break;
|
|
1028
|
+
|
|
1029
|
+
case 30:
|
|
942
1030
|
/*! Production:: dimension : VMINS */
|
|
943
1031
|
|
|
944
1032
|
this.$ = { type: 'VminValue', value: parseFloat(yyvstack[yysp]), unit: 'vmin' };
|
|
945
1033
|
break;
|
|
946
1034
|
|
|
947
|
-
case
|
|
1035
|
+
case 31:
|
|
1036
|
+
/*! Production:: dimension : SVMINS */
|
|
1037
|
+
|
|
1038
|
+
this.$ = { type: 'SvminValue', value: parseFloat(yyvstack[yysp]), unit: 'svmin' };
|
|
1039
|
+
break;
|
|
1040
|
+
|
|
1041
|
+
case 32:
|
|
1042
|
+
/*! Production:: dimension : LVMINS */
|
|
1043
|
+
|
|
1044
|
+
this.$ = { type: 'LvminValue', value: parseFloat(yyvstack[yysp]), unit: 'lvmin' };
|
|
1045
|
+
break;
|
|
1046
|
+
|
|
1047
|
+
case 33:
|
|
1048
|
+
/*! Production:: dimension : DVMINS */
|
|
1049
|
+
|
|
1050
|
+
this.$ = { type: 'DvminValue', value: parseFloat(yyvstack[yysp]), unit: 'dvmin' };
|
|
1051
|
+
break;
|
|
1052
|
+
|
|
1053
|
+
case 34:
|
|
948
1054
|
/*! Production:: dimension : VMAXS */
|
|
949
1055
|
|
|
950
1056
|
this.$ = { type: 'VmaxValue', value: parseFloat(yyvstack[yysp]), unit: 'vmax' };
|
|
951
1057
|
break;
|
|
952
1058
|
|
|
953
|
-
case
|
|
1059
|
+
case 35:
|
|
1060
|
+
/*! Production:: dimension : SVMAXS */
|
|
1061
|
+
|
|
1062
|
+
this.$ = { type: 'SvmaxValue', value: parseFloat(yyvstack[yysp]), unit: 'svmax' };
|
|
1063
|
+
break;
|
|
1064
|
+
|
|
1065
|
+
case 36:
|
|
1066
|
+
/*! Production:: dimension : LVMAXS */
|
|
1067
|
+
|
|
1068
|
+
this.$ = { type: 'LvmaxValue', value: parseFloat(yyvstack[yysp]), unit: 'lvmax' };
|
|
1069
|
+
break;
|
|
1070
|
+
|
|
1071
|
+
case 37:
|
|
1072
|
+
/*! Production:: dimension : DVMAXS */
|
|
1073
|
+
|
|
1074
|
+
this.$ = { type: 'DvmaxValue', value: parseFloat(yyvstack[yysp]), unit: 'dvmax' };
|
|
1075
|
+
break;
|
|
1076
|
+
|
|
1077
|
+
case 38:
|
|
1078
|
+
/*! Production:: dimension : VBS */
|
|
1079
|
+
|
|
1080
|
+
this.$ = { type: 'VbValue', value: parseFloat(yyvstack[yysp]), unit: 'vb' };
|
|
1081
|
+
break;
|
|
1082
|
+
|
|
1083
|
+
case 39:
|
|
1084
|
+
/*! Production:: dimension : SVBS */
|
|
1085
|
+
|
|
1086
|
+
this.$ = { type: 'SvbValue', value: parseFloat(yyvstack[yysp]), unit: 'svb' };
|
|
1087
|
+
break;
|
|
1088
|
+
|
|
1089
|
+
case 40:
|
|
1090
|
+
/*! Production:: dimension : LVBS */
|
|
1091
|
+
|
|
1092
|
+
this.$ = { type: 'LvbValue', value: parseFloat(yyvstack[yysp]), unit: 'lvb' };
|
|
1093
|
+
break;
|
|
1094
|
+
|
|
1095
|
+
case 41:
|
|
1096
|
+
/*! Production:: dimension : DVBS */
|
|
1097
|
+
|
|
1098
|
+
this.$ = { type: 'DvbValue', value: parseFloat(yyvstack[yysp]), unit: 'dvb' };
|
|
1099
|
+
break;
|
|
1100
|
+
|
|
1101
|
+
case 42:
|
|
1102
|
+
/*! Production:: dimension : VIS */
|
|
1103
|
+
|
|
1104
|
+
this.$ = { type: 'VhValue', value: parseFloat(yyvstack[yysp]), unit: 'vi' };
|
|
1105
|
+
break;
|
|
1106
|
+
|
|
1107
|
+
case 43:
|
|
1108
|
+
/*! Production:: dimension : SVIS */
|
|
1109
|
+
|
|
1110
|
+
this.$ = { type: 'SvhValue', value: parseFloat(yyvstack[yysp]), unit: 'svi' };
|
|
1111
|
+
break;
|
|
1112
|
+
|
|
1113
|
+
case 44:
|
|
1114
|
+
/*! Production:: dimension : LVIS */
|
|
1115
|
+
|
|
1116
|
+
this.$ = { type: 'LvhValue', value: parseFloat(yyvstack[yysp]), unit: 'lvi' };
|
|
1117
|
+
break;
|
|
1118
|
+
|
|
1119
|
+
case 45:
|
|
1120
|
+
/*! Production:: dimension : DVIS */
|
|
1121
|
+
|
|
1122
|
+
this.$ = { type: 'DvhValue', value: parseFloat(yyvstack[yysp]), unit: 'dvi' };
|
|
1123
|
+
break;
|
|
1124
|
+
|
|
1125
|
+
case 46:
|
|
1126
|
+
/*! Production:: dimension : CQWS */
|
|
1127
|
+
|
|
1128
|
+
this.$ = { type: 'CqwValue', value: parseFloat(yyvstack[yysp]), unit: 'cqw' };
|
|
1129
|
+
break;
|
|
1130
|
+
|
|
1131
|
+
case 47:
|
|
1132
|
+
/*! Production:: dimension : CQHS */
|
|
1133
|
+
|
|
1134
|
+
this.$ = { type: 'CqhValue', value: parseFloat(yyvstack[yysp]), unit: 'cqh' };
|
|
1135
|
+
break;
|
|
1136
|
+
|
|
1137
|
+
case 48:
|
|
1138
|
+
/*! Production:: dimension : CQIS */
|
|
1139
|
+
|
|
1140
|
+
this.$ = { type: 'CqiValue', value: parseFloat(yyvstack[yysp]), unit: 'cqi' };
|
|
1141
|
+
break;
|
|
1142
|
+
|
|
1143
|
+
case 49:
|
|
1144
|
+
/*! Production:: dimension : CQBS */
|
|
1145
|
+
|
|
1146
|
+
this.$ = { type: 'CqbValue', value: parseFloat(yyvstack[yysp]), unit: 'cqb' };
|
|
1147
|
+
break;
|
|
1148
|
+
|
|
1149
|
+
case 50:
|
|
1150
|
+
/*! Production:: dimension : CQMINS */
|
|
1151
|
+
|
|
1152
|
+
this.$ = { type: 'CqminValue', value: parseFloat(yyvstack[yysp]), unit: 'cqmin' };
|
|
1153
|
+
break;
|
|
1154
|
+
|
|
1155
|
+
case 51:
|
|
1156
|
+
/*! Production:: dimension : CQMAXS */
|
|
1157
|
+
|
|
1158
|
+
this.$ = { type: 'CqmaxValue', value: parseFloat(yyvstack[yysp]), unit: 'cqmax' };
|
|
1159
|
+
break;
|
|
1160
|
+
|
|
1161
|
+
case 52:
|
|
954
1162
|
/*! Production:: dimension : PERCENTAGE */
|
|
955
1163
|
|
|
956
1164
|
this.$ = { type: 'PercentageValue', value: parseFloat(yyvstack[yysp]), unit: '%' };
|
|
957
1165
|
break;
|
|
958
1166
|
|
|
959
|
-
case
|
|
1167
|
+
case 53:
|
|
960
1168
|
/*! Production:: dimension : ADD dimension */
|
|
961
1169
|
|
|
962
1170
|
var prev = yyvstack[yysp]; this.$ = prev;
|
|
963
1171
|
break;
|
|
964
1172
|
|
|
965
|
-
case
|
|
1173
|
+
case 54:
|
|
966
1174
|
/*! Production:: dimension : SUB dimension */
|
|
967
1175
|
|
|
968
1176
|
var prev = yyvstack[yysp]; prev.value *= -1; this.$ = prev;
|
|
969
1177
|
break;
|
|
970
1178
|
|
|
971
|
-
case
|
|
1179
|
+
case 55:
|
|
972
1180
|
/*! Production:: number : NUMBER */
|
|
973
|
-
case
|
|
1181
|
+
case 56:
|
|
974
1182
|
/*! Production:: number : ADD NUMBER */
|
|
975
1183
|
|
|
976
1184
|
this.$ = { type: 'Number', value: parseFloat(yyvstack[yysp]) };
|
|
977
1185
|
break;
|
|
978
1186
|
|
|
979
|
-
case
|
|
1187
|
+
case 57:
|
|
980
1188
|
/*! Production:: number : SUB NUMBER */
|
|
981
1189
|
|
|
982
1190
|
this.$ = { type: 'Number', value: parseFloat(yyvstack[yysp]) * -1 };
|
|
@@ -986,24 +1194,24 @@ case 31:
|
|
|
986
1194
|
},
|
|
987
1195
|
table: bt({
|
|
988
1196
|
len: u([
|
|
989
|
-
|
|
1197
|
+
52,
|
|
990
1198
|
1,
|
|
991
1199
|
5,
|
|
992
1200
|
1,
|
|
993
|
-
|
|
1201
|
+
51,
|
|
994
1202
|
s,
|
|
995
|
-
[0,
|
|
996
|
-
|
|
997
|
-
|
|
1203
|
+
[0, 45],
|
|
1204
|
+
45,
|
|
1205
|
+
45,
|
|
998
1206
|
0,
|
|
999
1207
|
0,
|
|
1000
1208
|
s,
|
|
1001
|
-
[
|
|
1209
|
+
[51, 5],
|
|
1002
1210
|
5,
|
|
1003
1211
|
0,
|
|
1004
1212
|
0,
|
|
1005
|
-
|
|
1006
|
-
|
|
1213
|
+
44,
|
|
1214
|
+
44,
|
|
1007
1215
|
0,
|
|
1008
1216
|
0,
|
|
1009
1217
|
6,
|
|
@@ -1019,37 +1227,37 @@ table: bt({
|
|
|
1019
1227
|
6,
|
|
1020
1228
|
7,
|
|
1021
1229
|
s,
|
|
1022
|
-
[10,
|
|
1230
|
+
[10, 48, 1],
|
|
1023
1231
|
1,
|
|
1024
1232
|
1,
|
|
1025
1233
|
s,
|
|
1026
1234
|
[6, 4, 1],
|
|
1027
1235
|
4,
|
|
1028
1236
|
c,
|
|
1029
|
-
[
|
|
1237
|
+
[59, 47],
|
|
1030
1238
|
c,
|
|
1031
|
-
[
|
|
1239
|
+
[58, 4],
|
|
1032
1240
|
6,
|
|
1033
1241
|
7,
|
|
1034
1242
|
c,
|
|
1035
|
-
[
|
|
1036
|
-
|
|
1243
|
+
[48, 42],
|
|
1244
|
+
56,
|
|
1037
1245
|
c,
|
|
1038
|
-
[
|
|
1246
|
+
[45, 45],
|
|
1039
1247
|
c,
|
|
1040
|
-
[
|
|
1248
|
+
[141, 51],
|
|
1041
1249
|
c,
|
|
1042
|
-
[
|
|
1250
|
+
[51, 204],
|
|
1043
1251
|
s,
|
|
1044
1252
|
[5, 5, 1],
|
|
1045
1253
|
c,
|
|
1046
|
-
[
|
|
1254
|
+
[305, 43],
|
|
1047
1255
|
c,
|
|
1048
|
-
[
|
|
1049
|
-
|
|
1256
|
+
[349, 44],
|
|
1257
|
+
56,
|
|
1050
1258
|
1,
|
|
1051
1259
|
c,
|
|
1052
|
-
[
|
|
1260
|
+
[94, 5],
|
|
1053
1261
|
c,
|
|
1054
1262
|
[6, 6],
|
|
1055
1263
|
c,
|
|
@@ -1057,26 +1265,26 @@ table: bt({
|
|
|
1057
1265
|
]),
|
|
1058
1266
|
type: u([
|
|
1059
1267
|
s,
|
|
1060
|
-
[2,
|
|
1268
|
+
[2, 47],
|
|
1061
1269
|
s,
|
|
1062
1270
|
[0, 5],
|
|
1063
1271
|
1,
|
|
1064
1272
|
s,
|
|
1065
|
-
[2,
|
|
1273
|
+
[2, 53],
|
|
1066
1274
|
s,
|
|
1067
1275
|
[0, 4],
|
|
1068
1276
|
c,
|
|
1069
|
-
[
|
|
1277
|
+
[48, 45],
|
|
1070
1278
|
c,
|
|
1071
|
-
[
|
|
1279
|
+
[45, 89],
|
|
1072
1280
|
c,
|
|
1073
|
-
[
|
|
1281
|
+
[141, 51],
|
|
1074
1282
|
c,
|
|
1075
|
-
[
|
|
1283
|
+
[51, 207],
|
|
1076
1284
|
c,
|
|
1077
|
-
[
|
|
1285
|
+
[304, 45],
|
|
1078
1286
|
c,
|
|
1079
|
-
[
|
|
1287
|
+
[44, 18]
|
|
1080
1288
|
]),
|
|
1081
1289
|
state: u([
|
|
1082
1290
|
1,
|
|
@@ -1084,30 +1292,30 @@ table: bt({
|
|
|
1084
1292
|
5,
|
|
1085
1293
|
6,
|
|
1086
1294
|
7,
|
|
1087
|
-
|
|
1295
|
+
59,
|
|
1088
1296
|
c,
|
|
1089
1297
|
[4, 3],
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1298
|
+
60,
|
|
1299
|
+
64,
|
|
1300
|
+
66,
|
|
1093
1301
|
c,
|
|
1094
1302
|
[6, 3],
|
|
1095
|
-
|
|
1303
|
+
67,
|
|
1096
1304
|
c,
|
|
1097
1305
|
[4, 3],
|
|
1098
|
-
|
|
1306
|
+
68,
|
|
1099
1307
|
c,
|
|
1100
1308
|
[4, 3],
|
|
1101
|
-
|
|
1309
|
+
69,
|
|
1102
1310
|
c,
|
|
1103
1311
|
[4, 3],
|
|
1104
|
-
|
|
1312
|
+
70,
|
|
1105
1313
|
c,
|
|
1106
1314
|
[22, 5]
|
|
1107
1315
|
]),
|
|
1108
1316
|
mode: u([
|
|
1109
1317
|
s,
|
|
1110
|
-
[1,
|
|
1318
|
+
[1, 514],
|
|
1111
1319
|
s,
|
|
1112
1320
|
[2, 4],
|
|
1113
1321
|
c,
|
|
@@ -1118,70 +1326,70 @@ table: bt({
|
|
|
1118
1326
|
goto: u([
|
|
1119
1327
|
3,
|
|
1120
1328
|
4,
|
|
1121
|
-
|
|
1122
|
-
|
|
1329
|
+
50,
|
|
1330
|
+
51,
|
|
1123
1331
|
s,
|
|
1124
|
-
[8,
|
|
1332
|
+
[8, 42, 1],
|
|
1125
1333
|
s,
|
|
1126
|
-
[
|
|
1334
|
+
[52, 7, 1],
|
|
1127
1335
|
c,
|
|
1128
|
-
[
|
|
1129
|
-
|
|
1130
|
-
|
|
1336
|
+
[53, 47],
|
|
1337
|
+
62,
|
|
1338
|
+
63,
|
|
1131
1339
|
c,
|
|
1132
|
-
[
|
|
1133
|
-
|
|
1340
|
+
[44, 41],
|
|
1341
|
+
61,
|
|
1134
1342
|
c,
|
|
1135
|
-
[
|
|
1136
|
-
|
|
1343
|
+
[44, 43],
|
|
1344
|
+
65,
|
|
1137
1345
|
c,
|
|
1138
|
-
[
|
|
1346
|
+
[135, 47],
|
|
1139
1347
|
c,
|
|
1140
|
-
[
|
|
1141
|
-
|
|
1348
|
+
[47, 188],
|
|
1349
|
+
71,
|
|
1142
1350
|
c,
|
|
1143
|
-
[
|
|
1351
|
+
[376, 4],
|
|
1144
1352
|
c,
|
|
1145
|
-
[
|
|
1353
|
+
[284, 43],
|
|
1146
1354
|
c,
|
|
1147
|
-
[
|
|
1355
|
+
[43, 43],
|
|
1148
1356
|
s,
|
|
1149
1357
|
[3, 4],
|
|
1150
|
-
|
|
1151
|
-
|
|
1358
|
+
56,
|
|
1359
|
+
57,
|
|
1152
1360
|
s,
|
|
1153
1361
|
[4, 4],
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1362
|
+
56,
|
|
1363
|
+
57,
|
|
1364
|
+
72,
|
|
1157
1365
|
c,
|
|
1158
|
-
[
|
|
1366
|
+
[103, 4]
|
|
1159
1367
|
])
|
|
1160
1368
|
}),
|
|
1161
1369
|
defaultActions: bda({
|
|
1162
1370
|
idx: u([
|
|
1163
1371
|
s,
|
|
1164
|
-
[5,
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1372
|
+
[5, 45, 1],
|
|
1373
|
+
52,
|
|
1374
|
+
53,
|
|
1375
|
+
60,
|
|
1376
|
+
61,
|
|
1377
|
+
64,
|
|
1378
|
+
65,
|
|
1379
|
+
68,
|
|
1380
|
+
69,
|
|
1381
|
+
71,
|
|
1382
|
+
72
|
|
1175
1383
|
]),
|
|
1176
1384
|
goto: u([
|
|
1177
1385
|
s,
|
|
1178
|
-
[8,
|
|
1179
|
-
|
|
1386
|
+
[8, 45, 1],
|
|
1387
|
+
55,
|
|
1180
1388
|
1,
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1389
|
+
53,
|
|
1390
|
+
56,
|
|
1391
|
+
54,
|
|
1392
|
+
57,
|
|
1185
1393
|
5,
|
|
1186
1394
|
6,
|
|
1187
1395
|
7,
|
|
@@ -1225,7 +1433,7 @@ parse: function parse(input) {
|
|
|
1225
1433
|
var TERROR = this.TERROR;
|
|
1226
1434
|
var EOF = this.EOF;
|
|
1227
1435
|
var ERROR_RECOVERY_TOKEN_DISCARD_COUNT = (this.options.errorRecoveryTokenDiscardCount | 0) || 3;
|
|
1228
|
-
var NO_ACTION = [0,
|
|
1436
|
+
var NO_ACTION = [0, 73 /* === table.length :: ensures that anyone using this new state will fail dramatically! */];
|
|
1229
1437
|
|
|
1230
1438
|
var lexer;
|
|
1231
1439
|
if (this.__lexer__) {
|
|
@@ -3578,115 +3786,219 @@ EOF: 1,
|
|
|
3578
3786
|
|
|
3579
3787
|
/*! Conditions:: INITIAL */
|
|
3580
3788
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)vw\b */
|
|
3581
|
-
11:
|
|
3789
|
+
11: 25,
|
|
3790
|
+
|
|
3791
|
+
/*! Conditions:: INITIAL */
|
|
3792
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)svw\b */
|
|
3793
|
+
12: 26,
|
|
3794
|
+
|
|
3795
|
+
/*! Conditions:: INITIAL */
|
|
3796
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)lvw\b */
|
|
3797
|
+
13: 27,
|
|
3798
|
+
|
|
3799
|
+
/*! Conditions:: INITIAL */
|
|
3800
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dvw\b */
|
|
3801
|
+
14: 28,
|
|
3582
3802
|
|
|
3583
3803
|
/*! Conditions:: INITIAL */
|
|
3584
3804
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)vh\b */
|
|
3585
|
-
|
|
3805
|
+
15: 21,
|
|
3806
|
+
|
|
3807
|
+
/*! Conditions:: INITIAL */
|
|
3808
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)svh\b */
|
|
3809
|
+
16: 22,
|
|
3810
|
+
|
|
3811
|
+
/*! Conditions:: INITIAL */
|
|
3812
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)lvh\b */
|
|
3813
|
+
17: 23,
|
|
3814
|
+
|
|
3815
|
+
/*! Conditions:: INITIAL */
|
|
3816
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dvh\b */
|
|
3817
|
+
18: 24,
|
|
3586
3818
|
|
|
3587
3819
|
/*! Conditions:: INITIAL */
|
|
3588
3820
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)vmin\b */
|
|
3589
|
-
|
|
3821
|
+
19: 29,
|
|
3822
|
+
|
|
3823
|
+
/*! Conditions:: INITIAL */
|
|
3824
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)svmin\b */
|
|
3825
|
+
20: 30,
|
|
3826
|
+
|
|
3827
|
+
/*! Conditions:: INITIAL */
|
|
3828
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)lvmin\b */
|
|
3829
|
+
21: 31,
|
|
3830
|
+
|
|
3831
|
+
/*! Conditions:: INITIAL */
|
|
3832
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dvmin\b */
|
|
3833
|
+
22: 32,
|
|
3590
3834
|
|
|
3591
3835
|
/*! Conditions:: INITIAL */
|
|
3592
3836
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)vmax\b */
|
|
3593
|
-
|
|
3837
|
+
23: 33,
|
|
3838
|
+
|
|
3839
|
+
/*! Conditions:: INITIAL */
|
|
3840
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)svmax\b */
|
|
3841
|
+
24: 34,
|
|
3842
|
+
|
|
3843
|
+
/*! Conditions:: INITIAL */
|
|
3844
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)lvmax\b */
|
|
3845
|
+
25: 35,
|
|
3846
|
+
|
|
3847
|
+
/*! Conditions:: INITIAL */
|
|
3848
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dvmax\b */
|
|
3849
|
+
26: 36,
|
|
3850
|
+
|
|
3851
|
+
/*! Conditions:: INITIAL */
|
|
3852
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)vb\b */
|
|
3853
|
+
27: 37,
|
|
3854
|
+
|
|
3855
|
+
/*! Conditions:: INITIAL */
|
|
3856
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)svb\b */
|
|
3857
|
+
28: 38,
|
|
3858
|
+
|
|
3859
|
+
/*! Conditions:: INITIAL */
|
|
3860
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)lvb\b */
|
|
3861
|
+
29: 39,
|
|
3862
|
+
|
|
3863
|
+
/*! Conditions:: INITIAL */
|
|
3864
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dvb\b */
|
|
3865
|
+
30: 40,
|
|
3866
|
+
|
|
3867
|
+
/*! Conditions:: INITIAL */
|
|
3868
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)vi\b */
|
|
3869
|
+
31: 41,
|
|
3870
|
+
|
|
3871
|
+
/*! Conditions:: INITIAL */
|
|
3872
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)svi\b */
|
|
3873
|
+
32: 42,
|
|
3874
|
+
|
|
3875
|
+
/*! Conditions:: INITIAL */
|
|
3876
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)lvi\b */
|
|
3877
|
+
33: 43,
|
|
3878
|
+
|
|
3879
|
+
/*! Conditions:: INITIAL */
|
|
3880
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dvi\b */
|
|
3881
|
+
34: 44,
|
|
3882
|
+
|
|
3883
|
+
/*! Conditions:: INITIAL */
|
|
3884
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cqw\b */
|
|
3885
|
+
35: 45,
|
|
3886
|
+
|
|
3887
|
+
/*! Conditions:: INITIAL */
|
|
3888
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cqh\b */
|
|
3889
|
+
36: 46,
|
|
3890
|
+
|
|
3891
|
+
/*! Conditions:: INITIAL */
|
|
3892
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cqi\b */
|
|
3893
|
+
37: 47,
|
|
3894
|
+
|
|
3895
|
+
/*! Conditions:: INITIAL */
|
|
3896
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cqb\b */
|
|
3897
|
+
38: 48,
|
|
3898
|
+
|
|
3899
|
+
/*! Conditions:: INITIAL */
|
|
3900
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cqmin\b */
|
|
3901
|
+
39: 49,
|
|
3902
|
+
|
|
3903
|
+
/*! Conditions:: INITIAL */
|
|
3904
|
+
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cqmax\b */
|
|
3905
|
+
40: 50,
|
|
3594
3906
|
|
|
3595
3907
|
/*! Conditions:: INITIAL */
|
|
3596
3908
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)cm\b */
|
|
3597
|
-
|
|
3909
|
+
41: 11,
|
|
3598
3910
|
|
|
3599
3911
|
/*! Conditions:: INITIAL */
|
|
3600
3912
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)mm\b */
|
|
3601
|
-
|
|
3913
|
+
42: 11,
|
|
3602
3914
|
|
|
3603
3915
|
/*! Conditions:: INITIAL */
|
|
3604
3916
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)Q\b */
|
|
3605
|
-
|
|
3917
|
+
43: 11,
|
|
3606
3918
|
|
|
3607
3919
|
/*! Conditions:: INITIAL */
|
|
3608
3920
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)in\b */
|
|
3609
|
-
|
|
3921
|
+
44: 11,
|
|
3610
3922
|
|
|
3611
3923
|
/*! Conditions:: INITIAL */
|
|
3612
3924
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)pt\b */
|
|
3613
|
-
|
|
3925
|
+
45: 11,
|
|
3614
3926
|
|
|
3615
3927
|
/*! Conditions:: INITIAL */
|
|
3616
3928
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)pc\b */
|
|
3617
|
-
|
|
3929
|
+
46: 11,
|
|
3618
3930
|
|
|
3619
3931
|
/*! Conditions:: INITIAL */
|
|
3620
3932
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)px\b */
|
|
3621
|
-
|
|
3933
|
+
47: 11,
|
|
3622
3934
|
|
|
3623
3935
|
/*! Conditions:: INITIAL */
|
|
3624
3936
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)deg\b */
|
|
3625
|
-
|
|
3937
|
+
48: 12,
|
|
3626
3938
|
|
|
3627
3939
|
/*! Conditions:: INITIAL */
|
|
3628
3940
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)grad\b */
|
|
3629
|
-
|
|
3941
|
+
49: 12,
|
|
3630
3942
|
|
|
3631
3943
|
/*! Conditions:: INITIAL */
|
|
3632
3944
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)rad\b */
|
|
3633
|
-
|
|
3945
|
+
50: 12,
|
|
3634
3946
|
|
|
3635
3947
|
/*! Conditions:: INITIAL */
|
|
3636
3948
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)turn\b */
|
|
3637
|
-
|
|
3949
|
+
51: 12,
|
|
3638
3950
|
|
|
3639
3951
|
/*! Conditions:: INITIAL */
|
|
3640
3952
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)s\b */
|
|
3641
|
-
|
|
3953
|
+
52: 13,
|
|
3642
3954
|
|
|
3643
3955
|
/*! Conditions:: INITIAL */
|
|
3644
3956
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)ms\b */
|
|
3645
|
-
|
|
3957
|
+
53: 13,
|
|
3646
3958
|
|
|
3647
3959
|
/*! Conditions:: INITIAL */
|
|
3648
3960
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)Hz\b */
|
|
3649
|
-
|
|
3961
|
+
54: 14,
|
|
3650
3962
|
|
|
3651
3963
|
/*! Conditions:: INITIAL */
|
|
3652
3964
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)kHz\b */
|
|
3653
|
-
|
|
3965
|
+
55: 14,
|
|
3654
3966
|
|
|
3655
3967
|
/*! Conditions:: INITIAL */
|
|
3656
3968
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dpi\b */
|
|
3657
|
-
|
|
3969
|
+
56: 15,
|
|
3658
3970
|
|
|
3659
3971
|
/*! Conditions:: INITIAL */
|
|
3660
3972
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dpcm\b */
|
|
3661
|
-
|
|
3973
|
+
57: 15,
|
|
3662
3974
|
|
|
3663
3975
|
/*! Conditions:: INITIAL */
|
|
3664
3976
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)dppx\b */
|
|
3665
|
-
|
|
3977
|
+
58: 15,
|
|
3666
3978
|
|
|
3667
3979
|
/*! Conditions:: INITIAL */
|
|
3668
3980
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)% */
|
|
3669
|
-
|
|
3981
|
+
59: 51,
|
|
3670
3982
|
|
|
3671
3983
|
/*! Conditions:: INITIAL */
|
|
3672
3984
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)\b */
|
|
3673
|
-
|
|
3985
|
+
60: 52,
|
|
3674
3986
|
|
|
3675
3987
|
/*! Conditions:: INITIAL */
|
|
3676
3988
|
/*! Rule:: (([0-9]+(\.[0-9]+)?|\.[0-9]+)(e(\+|-)[0-9]+)?)-?([a-zA-Z_]|[\240-\377]|(\\[0-9a-fA-F]{1,6}(\r\n|[ \t\r\n\f])?|\\[^\r\n\f0-9a-fA-F]))([a-zA-Z0-9_-]|[\240-\377]|(\\[0-9a-fA-F]{1,6}(\r\n|[ \t\r\n\f])?|\\[^\r\n\f0-9a-fA-F]))*\b */
|
|
3677
|
-
|
|
3989
|
+
61: 16,
|
|
3678
3990
|
|
|
3679
3991
|
/*! Conditions:: INITIAL */
|
|
3680
3992
|
/*! Rule:: \( */
|
|
3681
|
-
|
|
3993
|
+
62: 4,
|
|
3682
3994
|
|
|
3683
3995
|
/*! Conditions:: INITIAL */
|
|
3684
3996
|
/*! Rule:: \) */
|
|
3685
|
-
|
|
3997
|
+
63: 5,
|
|
3686
3998
|
|
|
3687
3999
|
/*! Conditions:: INITIAL */
|
|
3688
4000
|
/*! Rule:: $ */
|
|
3689
|
-
|
|
4001
|
+
64: 1
|
|
3690
4002
|
},
|
|
3691
4003
|
|
|
3692
4004
|
rules: [
|
|
@@ -3702,33 +4014,59 @@ EOF: 1,
|
|
|
3702
4014
|
/* 9: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)ch\b)/i,
|
|
3703
4015
|
/* 10: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)rem\b)/i,
|
|
3704
4016
|
/* 11: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)vw\b)/i,
|
|
3705
|
-
/* 12: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3706
|
-
/* 13: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3707
|
-
/* 14: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3708
|
-
/* 15: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3709
|
-
/* 16: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3710
|
-
/* 17: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3711
|
-
/* 18: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3712
|
-
/* 19: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3713
|
-
/* 20: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3714
|
-
/* 21: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3715
|
-
/* 22: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3716
|
-
/* 23: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3717
|
-
/* 24: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3718
|
-
/* 25: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3719
|
-
/* 26: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3720
|
-
/* 27: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3721
|
-
/* 28: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3722
|
-
/* 29: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3723
|
-
/* 30: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3724
|
-
/* 31: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3725
|
-
/* 32: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3726
|
-
/* 33: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3727
|
-
/* 34: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)\b)/i,
|
|
3728
|
-
/* 35: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)
|
|
3729
|
-
/* 36: */ /^(
|
|
3730
|
-
/* 37: */ /^(
|
|
3731
|
-
/* 38: */ /^(
|
|
4017
|
+
/* 12: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)svw\b)/i,
|
|
4018
|
+
/* 13: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)lvw\b)/i,
|
|
4019
|
+
/* 14: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dvw\b)/i,
|
|
4020
|
+
/* 15: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)vh\b)/i,
|
|
4021
|
+
/* 16: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)svh\b)/i,
|
|
4022
|
+
/* 17: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)lvh\b)/i,
|
|
4023
|
+
/* 18: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dvh\b)/i,
|
|
4024
|
+
/* 19: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)vmin\b)/i,
|
|
4025
|
+
/* 20: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)svmin\b)/i,
|
|
4026
|
+
/* 21: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)lvmin\b)/i,
|
|
4027
|
+
/* 22: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dvmin\b)/i,
|
|
4028
|
+
/* 23: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)vmax\b)/i,
|
|
4029
|
+
/* 24: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)svmax\b)/i,
|
|
4030
|
+
/* 25: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)lvmax\b)/i,
|
|
4031
|
+
/* 26: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dvmax\b)/i,
|
|
4032
|
+
/* 27: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)vb\b)/i,
|
|
4033
|
+
/* 28: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)svb\b)/i,
|
|
4034
|
+
/* 29: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)lvb\b)/i,
|
|
4035
|
+
/* 30: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dvb\b)/i,
|
|
4036
|
+
/* 31: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)vi\b)/i,
|
|
4037
|
+
/* 32: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)svi\b)/i,
|
|
4038
|
+
/* 33: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)lvi\b)/i,
|
|
4039
|
+
/* 34: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dvi\b)/i,
|
|
4040
|
+
/* 35: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cqw\b)/i,
|
|
4041
|
+
/* 36: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cqh\b)/i,
|
|
4042
|
+
/* 37: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cqi\b)/i,
|
|
4043
|
+
/* 38: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cqb\b)/i,
|
|
4044
|
+
/* 39: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cqmin\b)/i,
|
|
4045
|
+
/* 40: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cqmax\b)/i,
|
|
4046
|
+
/* 41: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)cm\b)/i,
|
|
4047
|
+
/* 42: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)mm\b)/i,
|
|
4048
|
+
/* 43: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)Q\b)/i,
|
|
4049
|
+
/* 44: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)in\b)/i,
|
|
4050
|
+
/* 45: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)pt\b)/i,
|
|
4051
|
+
/* 46: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)pc\b)/i,
|
|
4052
|
+
/* 47: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)px\b)/i,
|
|
4053
|
+
/* 48: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)deg\b)/i,
|
|
4054
|
+
/* 49: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)grad\b)/i,
|
|
4055
|
+
/* 50: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)rad\b)/i,
|
|
4056
|
+
/* 51: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)turn\b)/i,
|
|
4057
|
+
/* 52: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)s\b)/i,
|
|
4058
|
+
/* 53: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)ms\b)/i,
|
|
4059
|
+
/* 54: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)Hz\b)/i,
|
|
4060
|
+
/* 55: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)kHz\b)/i,
|
|
4061
|
+
/* 56: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dpi\b)/i,
|
|
4062
|
+
/* 57: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dpcm\b)/i,
|
|
4063
|
+
/* 58: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)dppx\b)/i,
|
|
4064
|
+
/* 59: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)%)/i,
|
|
4065
|
+
/* 60: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)\b)/i,
|
|
4066
|
+
/* 61: */ /^(?:((\d+(\.\d+)?|\.\d+)(e(\+|-)\d+)?)-?([^\W\d]|[ -ÿ]|(\\[\dA-Fa-f]{1,6}(\r\n|[\t\n\f\r ])?|\\[^\d\n\f\rA-Fa-f]))([\w\-]|[ -ÿ]|(\\[\dA-Fa-f]{1,6}(\r\n|[\t\n\f\r ])?|\\[^\d\n\f\rA-Fa-f]))*\b)/i,
|
|
4067
|
+
/* 62: */ /^(?:\()/i,
|
|
4068
|
+
/* 63: */ /^(?:\))/i,
|
|
4069
|
+
/* 64: */ /^(?:$)/i
|
|
3732
4070
|
],
|
|
3733
4071
|
|
|
3734
4072
|
conditions: {
|
|
@@ -3772,7 +4110,33 @@ EOF: 1,
|
|
|
3772
4110
|
35,
|
|
3773
4111
|
36,
|
|
3774
4112
|
37,
|
|
3775
|
-
38
|
|
4113
|
+
38,
|
|
4114
|
+
39,
|
|
4115
|
+
40,
|
|
4116
|
+
41,
|
|
4117
|
+
42,
|
|
4118
|
+
43,
|
|
4119
|
+
44,
|
|
4120
|
+
45,
|
|
4121
|
+
46,
|
|
4122
|
+
47,
|
|
4123
|
+
48,
|
|
4124
|
+
49,
|
|
4125
|
+
50,
|
|
4126
|
+
51,
|
|
4127
|
+
52,
|
|
4128
|
+
53,
|
|
4129
|
+
54,
|
|
4130
|
+
55,
|
|
4131
|
+
56,
|
|
4132
|
+
57,
|
|
4133
|
+
58,
|
|
4134
|
+
59,
|
|
4135
|
+
60,
|
|
4136
|
+
61,
|
|
4137
|
+
62,
|
|
4138
|
+
63,
|
|
4139
|
+
64
|
|
3776
4140
|
],
|
|
3777
4141
|
|
|
3778
4142
|
inclusive: true
|
package/types/index.d.ts
CHANGED
|
@@ -11,10 +11,11 @@ export = pluginCreator;
|
|
|
11
11
|
* @param {PostCssCalcOptions} opts
|
|
12
12
|
* @return {import('postcss').Plugin}
|
|
13
13
|
*/
|
|
14
|
-
declare function pluginCreator(opts: PostCssCalcOptions): import(
|
|
14
|
+
declare function pluginCreator(opts: PostCssCalcOptions): import("postcss").Plugin;
|
|
15
15
|
declare namespace pluginCreator {
|
|
16
16
|
export { postcss, PostCssCalcOptions };
|
|
17
17
|
}
|
|
18
|
+
declare var postcss: true;
|
|
18
19
|
type PostCssCalcOptions = {
|
|
19
20
|
precision?: number | false;
|
|
20
21
|
preserve?: boolean;
|
|
@@ -22,4 +23,3 @@ type PostCssCalcOptions = {
|
|
|
22
23
|
mediaQueries?: boolean;
|
|
23
24
|
selectors?: boolean;
|
|
24
25
|
};
|
|
25
|
-
declare var postcss: true;
|
package/types/lib/reducer.d.ts
CHANGED
|
@@ -4,11 +4,11 @@ export = reduce;
|
|
|
4
4
|
* @param {number} precision
|
|
5
5
|
* @return {import('../parser').CalcNode}
|
|
6
6
|
*/
|
|
7
|
-
declare function reduce(node: import(
|
|
7
|
+
declare function reduce(node: import("../parser").CalcNode, precision: number): import("../parser").CalcNode;
|
|
8
8
|
declare namespace reduce {
|
|
9
9
|
export { Collectible };
|
|
10
10
|
}
|
|
11
11
|
type Collectible = {
|
|
12
|
-
preOperator:
|
|
13
|
-
node: import(
|
|
12
|
+
preOperator: "+" | "-";
|
|
13
|
+
node: import("../parser").CalcNode;
|
|
14
14
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare function _exports(calc: string, node: import(
|
|
1
|
+
declare function _exports(calc: string, node: import("../parser").CalcNode, originalValue: string, options: {
|
|
2
2
|
precision: number | false;
|
|
3
3
|
warnWhenCannotResolve: boolean;
|
|
4
4
|
}, result: import("postcss").Result, item: import("postcss").ChildNode): string;
|
package/types/lib/transform.d.ts
CHANGED