@dazl/shorthands-opener 4.2.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/README.md +3 -0
- package/dist/compounds/compound-css-data.d.ts +22 -0
- package/dist/compounds/compound-css-data.d.ts.map +1 -0
- package/dist/compounds/compound-css-data.js +2 -0
- package/dist/compounds/compound-css-data.js.map +1 -0
- package/dist/compounds/compound-mapper.d.ts +4 -0
- package/dist/compounds/compound-mapper.d.ts.map +1 -0
- package/dist/compounds/compound-mapper.js +10 -0
- package/dist/compounds/compound-mapper.js.map +1 -0
- package/dist/compounds/compound-parser-utils.d.ts +3 -0
- package/dist/compounds/compound-parser-utils.d.ts.map +1 -0
- package/dist/compounds/compound-parser-utils.js +33 -0
- package/dist/compounds/compound-parser-utils.js.map +1 -0
- package/dist/compounds/compound-types.d.ts +26 -0
- package/dist/compounds/compound-types.d.ts.map +1 -0
- package/dist/compounds/compound-types.js +2 -0
- package/dist/compounds/compound-types.js.map +1 -0
- package/dist/compounds/compound-value-parsers.d.ts +6 -0
- package/dist/compounds/compound-value-parsers.d.ts.map +1 -0
- package/dist/compounds/compound-value-parsers.js +5 -0
- package/dist/compounds/compound-value-parsers.js.map +1 -0
- package/dist/compounds/index.d.ts +6 -0
- package/dist/compounds/index.d.ts.map +1 -0
- package/dist/compounds/index.js +6 -0
- package/dist/compounds/index.js.map +1 -0
- package/dist/compounds/parsers/index.d.ts +2 -0
- package/dist/compounds/parsers/index.d.ts.map +1 -0
- package/dist/compounds/parsers/index.js +2 -0
- package/dist/compounds/parsers/index.js.map +1 -0
- package/dist/compounds/parsers/shadow-compound.d.ts +5 -0
- package/dist/compounds/parsers/shadow-compound.d.ts.map +1 -0
- package/dist/compounds/parsers/shadow-compound.js +39 -0
- package/dist/compounds/parsers/shadow-compound.js.map +1 -0
- package/dist/css-data-types/data-types-consts.d.ts +212 -0
- package/dist/css-data-types/data-types-consts.d.ts.map +1 -0
- package/dist/css-data-types/data-types-consts.js +790 -0
- package/dist/css-data-types/data-types-consts.js.map +1 -0
- package/dist/css-data-types/data-types-predicates.d.ts +32 -0
- package/dist/css-data-types/data-types-predicates.d.ts.map +1 -0
- package/dist/css-data-types/data-types-predicates.js +353 -0
- package/dist/css-data-types/data-types-predicates.js.map +1 -0
- package/dist/css-data-types/data-types-state-machines.d.ts +14 -0
- package/dist/css-data-types/data-types-state-machines.d.ts.map +1 -0
- package/dist/css-data-types/data-types-state-machines.js +129 -0
- package/dist/css-data-types/data-types-state-machines.js.map +1 -0
- package/dist/css-data-types/data-types-types.d.ts +26 -0
- package/dist/css-data-types/data-types-types.d.ts.map +1 -0
- package/dist/css-data-types/data-types-types.js +2 -0
- package/dist/css-data-types/data-types-types.js.map +1 -0
- package/dist/css-data-types/data-types-utils.d.ts +31 -0
- package/dist/css-data-types/data-types-utils.d.ts.map +1 -0
- package/dist/css-data-types/data-types-utils.js +176 -0
- package/dist/css-data-types/data-types-utils.js.map +1 -0
- package/dist/css-data-types/data-types.d.ts +64 -0
- package/dist/css-data-types/data-types.d.ts.map +1 -0
- package/dist/css-data-types/data-types.js +304 -0
- package/dist/css-data-types/data-types.js.map +1 -0
- package/dist/css-data-types/index.d.ts +7 -0
- package/dist/css-data-types/index.d.ts.map +1 -0
- package/dist/css-data-types/index.js +7 -0
- package/dist/css-data-types/index.js.map +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -0
- package/dist/shorthands/index.d.ts +8 -0
- package/dist/shorthands/index.d.ts.map +1 -0
- package/dist/shorthands/index.js +8 -0
- package/dist/shorthands/index.js.map +1 -0
- package/dist/shorthands/openers/background-position-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/background-position-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/background-position-shorthand.js +173 -0
- package/dist/shorthands/openers/background-position-shorthand.js.map +1 -0
- package/dist/shorthands/openers/background-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/background-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/background-shorthand.js +88 -0
- package/dist/shorthands/openers/background-shorthand.js.map +1 -0
- package/dist/shorthands/openers/border-image-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/border-image-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/border-image-shorthand.js +16 -0
- package/dist/shorthands/openers/border-image-shorthand.js.map +1 -0
- package/dist/shorthands/openers/border-radius-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/border-radius-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/border-radius-shorthand.js +61 -0
- package/dist/shorthands/openers/border-radius-shorthand.js.map +1 -0
- package/dist/shorthands/openers/border-shorthand.d.ts +20 -0
- package/dist/shorthands/openers/border-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/border-shorthand.js +90 -0
- package/dist/shorthands/openers/border-shorthand.js.map +1 -0
- package/dist/shorthands/openers/flex-flow-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/flex-flow-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/flex-flow-shorthand.js +13 -0
- package/dist/shorthands/openers/flex-flow-shorthand.js.map +1 -0
- package/dist/shorthands/openers/flex-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/flex-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/flex-shorthand.js +55 -0
- package/dist/shorthands/openers/flex-shorthand.js.map +1 -0
- package/dist/shorthands/openers/font-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/font-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/font-shorthand.js +60 -0
- package/dist/shorthands/openers/font-shorthand.js.map +1 -0
- package/dist/shorthands/openers/gap-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/gap-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/gap-shorthand.js +28 -0
- package/dist/shorthands/openers/gap-shorthand.js.map +1 -0
- package/dist/shorthands/openers/grid-axis-shorthand.d.ts +6 -0
- package/dist/shorthands/openers/grid-axis-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/grid-axis-shorthand.js +36 -0
- package/dist/shorthands/openers/grid-axis-shorthand.js.map +1 -0
- package/dist/shorthands/openers/grid-gap-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/grid-gap-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/grid-gap-shorthand.js +21 -0
- package/dist/shorthands/openers/grid-gap-shorthand.js.map +1 -0
- package/dist/shorthands/openers/grid-shorthand.d.ts +8 -0
- package/dist/shorthands/openers/grid-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/grid-shorthand.js +145 -0
- package/dist/shorthands/openers/grid-shorthand.js.map +1 -0
- package/dist/shorthands/openers/grid-template-shorthand.d.ts +10 -0
- package/dist/shorthands/openers/grid-template-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/grid-template-shorthand.js +113 -0
- package/dist/shorthands/openers/grid-template-shorthand.js.map +1 -0
- package/dist/shorthands/openers/index.d.ts +22 -0
- package/dist/shorthands/openers/index.d.ts.map +1 -0
- package/dist/shorthands/openers/index.js +22 -0
- package/dist/shorthands/openers/index.js.map +1 -0
- package/dist/shorthands/openers/list-style-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/list-style-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/list-style-shorthand.js +15 -0
- package/dist/shorthands/openers/list-style-shorthand.js.map +1 -0
- package/dist/shorthands/openers/margin-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/margin-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/margin-shorthand.js +11 -0
- package/dist/shorthands/openers/margin-shorthand.js.map +1 -0
- package/dist/shorthands/openers/outline-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/outline-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/outline-shorthand.js +14 -0
- package/dist/shorthands/openers/outline-shorthand.js.map +1 -0
- package/dist/shorthands/openers/overflow-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/overflow-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/overflow-shorthand.js +21 -0
- package/dist/shorthands/openers/overflow-shorthand.js.map +1 -0
- package/dist/shorthands/openers/padding-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/padding-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/padding-shorthand.js +11 -0
- package/dist/shorthands/openers/padding-shorthand.js.map +1 -0
- package/dist/shorthands/openers/place-content-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/place-content-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/place-content-shorthand.js +29 -0
- package/dist/shorthands/openers/place-content-shorthand.js.map +1 -0
- package/dist/shorthands/openers/place-items-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/place-items-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/place-items-shorthand.js +23 -0
- package/dist/shorthands/openers/place-items-shorthand.js.map +1 -0
- package/dist/shorthands/openers/text-decoration-shorthand.d.ts +5 -0
- package/dist/shorthands/openers/text-decoration-shorthand.d.ts.map +1 -0
- package/dist/shorthands/openers/text-decoration-shorthand.js +14 -0
- package/dist/shorthands/openers/text-decoration-shorthand.js.map +1 -0
- package/dist/shorthands/shorthand-css-data.d.ts +120 -0
- package/dist/shorthands/shorthand-css-data.d.ts.map +1 -0
- package/dist/shorthands/shorthand-css-data.js +48 -0
- package/dist/shorthands/shorthand-css-data.js.map +1 -0
- package/dist/shorthands/shorthand-mapper.d.ts +6 -0
- package/dist/shorthands/shorthand-mapper.d.ts.map +1 -0
- package/dist/shorthands/shorthand-mapper.js +72 -0
- package/dist/shorthands/shorthand-mapper.js.map +1 -0
- package/dist/shorthands/shorthand-parser-errors.d.ts +25 -0
- package/dist/shorthands/shorthand-parser-errors.d.ts.map +1 -0
- package/dist/shorthands/shorthand-parser-errors.js +41 -0
- package/dist/shorthands/shorthand-parser-errors.js.map +1 -0
- package/dist/shorthands/shorthand-parser-utils.d.ts +24 -0
- package/dist/shorthands/shorthand-parser-utils.d.ts.map +1 -0
- package/dist/shorthands/shorthand-parser-utils.js +398 -0
- package/dist/shorthands/shorthand-parser-utils.js.map +1 -0
- package/dist/shorthands/shorthand-types.d.ts +64 -0
- package/dist/shorthands/shorthand-types.d.ts.map +1 -0
- package/dist/shorthands/shorthand-types.js +2 -0
- package/dist/shorthands/shorthand-types.js.map +1 -0
- package/dist/shorthands/shorthands-ast-evaluation.d.ts +5 -0
- package/dist/shorthands/shorthands-ast-evaluation.d.ts.map +1 -0
- package/dist/shorthands/shorthands-ast-evaluation.js +19 -0
- package/dist/shorthands/shorthands-ast-evaluation.js.map +1 -0
- package/dist/tokenizers/css-value-tokenizer.d.ts +43 -0
- package/dist/tokenizers/css-value-tokenizer.d.ts.map +1 -0
- package/dist/tokenizers/css-value-tokenizer.js +154 -0
- package/dist/tokenizers/css-value-tokenizer.js.map +1 -0
- package/dist/tokenizers/index.d.ts +2 -0
- package/dist/tokenizers/index.d.ts.map +1 -0
- package/dist/tokenizers/index.js +2 -0
- package/dist/tokenizers/index.js.map +1 -0
- package/package.json +54 -0
- package/src/compounds/compound-css-data.ts +24 -0
- package/src/compounds/compound-mapper.ts +21 -0
- package/src/compounds/compound-parser-utils.ts +47 -0
- package/src/compounds/compound-types.ts +35 -0
- package/src/compounds/compound-value-parsers.ts +12 -0
- package/src/compounds/index.ts +5 -0
- package/src/compounds/parsers/index.ts +1 -0
- package/src/compounds/parsers/shadow-compound.ts +56 -0
- package/src/css-data-types/data-types-consts.ts +877 -0
- package/src/css-data-types/data-types-predicates.ts +477 -0
- package/src/css-data-types/data-types-state-machines.ts +169 -0
- package/src/css-data-types/data-types-types.ts +43 -0
- package/src/css-data-types/data-types-utils.ts +258 -0
- package/src/css-data-types/data-types.ts +435 -0
- package/src/css-data-types/index.ts +6 -0
- package/src/index.ts +4 -0
- package/src/shorthands/index.ts +7 -0
- package/src/shorthands/openers/background-position-shorthand.ts +180 -0
- package/src/shorthands/openers/background-shorthand.ts +161 -0
- package/src/shorthands/openers/border-image-shorthand.ts +35 -0
- package/src/shorthands/openers/border-radius-shorthand.ts +93 -0
- package/src/shorthands/openers/border-shorthand.ts +198 -0
- package/src/shorthands/openers/flex-flow-shorthand.ts +24 -0
- package/src/shorthands/openers/flex-shorthand.ts +79 -0
- package/src/shorthands/openers/font-shorthand.ts +85 -0
- package/src/shorthands/openers/gap-shorthand.ts +47 -0
- package/src/shorthands/openers/grid-axis-shorthand.ts +61 -0
- package/src/shorthands/openers/grid-gap-shorthand.ts +40 -0
- package/src/shorthands/openers/grid-shorthand.ts +260 -0
- package/src/shorthands/openers/grid-template-shorthand.ts +176 -0
- package/src/shorthands/openers/index.ts +21 -0
- package/src/shorthands/openers/list-style-shorthand.ts +33 -0
- package/src/shorthands/openers/margin-shorthand.ts +20 -0
- package/src/shorthands/openers/outline-shorthand.ts +27 -0
- package/src/shorthands/openers/overflow-shorthand.ts +40 -0
- package/src/shorthands/openers/padding-shorthand.ts +21 -0
- package/src/shorthands/openers/place-content-shorthand.ts +49 -0
- package/src/shorthands/openers/place-items-shorthand.ts +43 -0
- package/src/shorthands/openers/text-decoration-shorthand.ts +27 -0
- package/src/shorthands/shorthand-css-data.ts +210 -0
- package/src/shorthands/shorthand-mapper.ts +157 -0
- package/src/shorthands/shorthand-parser-errors.ts +47 -0
- package/src/shorthands/shorthand-parser-utils.ts +602 -0
- package/src/shorthands/shorthand-types.ts +107 -0
- package/src/shorthands/shorthands-ast-evaluation.ts +38 -0
- package/src/tokenizers/css-value-tokenizer.ts +220 -0
- package/src/tokenizers/index.ts +1 -0
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { openBackgroundShorthand, closeBackgroundShorthand, openBackgroundPositionShorthand, closeBackgroundPositionShorthand, openBorderRadiusShorthand, closeBorderRadiusShorthand, openBorderShorthand, closeBorderShorthand, openBorderTopShorthand, closeBorderTopShorthand, openBorderRightShorthand, closeBorderRightShorthand, openBorderBottomShorthand, closeBorderBottomShorthand, openBorderLeftShorthand, closeBorderLeftShorthand, openBorderStyleShorthand, closeBorderStyleShorthand, openBorderWidthShorthand, closeBorderWidthShorthand, openBorderColorShorthand, closeBorderColorShorthand, openOutlineShorthand, closeOutlineShorthand, openBorderImageShorthand, closeBorderImageShorthand, openFontShorthand, closeFontShorthand, openPlaceContentShorthand, closePlaceContentShorthand, openPlaceItemsShorthand, closePlaceItemsShorthand, openFlexShorthand, closeFlexShorthand, openFlexFlowShorthand, closeFlexFlowShorthand, openGapShorthand, closeGapShorthand, openGridRowShorthand, closeGridRowShorthand, openGridColumnShorthand, closeGridColumnShorthand, openGridGapShorthand, closeGridGapShorthand, openGridTemplateShorthand, closeGridTemplateShorthand, openGridShorthand, closeGridShorthand, openMarginShorthand, closeMarginShorthand, openPaddingShorthand, closePaddingShorthand, openOverflowShorthand, closeOverflowShorthand, openTextDecorationShorthand, closeTextDecorationShorthand, openListStyleShorthand, closeListStyleShorthand, } from './openers/index.js';
|
|
2
|
+
const shorthandOpenersMap = {
|
|
3
|
+
background: openBackgroundShorthand,
|
|
4
|
+
'background-position': openBackgroundPositionShorthand,
|
|
5
|
+
'border-radius': openBorderRadiusShorthand,
|
|
6
|
+
border: openBorderShorthand,
|
|
7
|
+
'border-top': openBorderTopShorthand,
|
|
8
|
+
'border-right': openBorderRightShorthand,
|
|
9
|
+
'border-bottom': openBorderBottomShorthand,
|
|
10
|
+
'border-left': openBorderLeftShorthand,
|
|
11
|
+
'border-style': openBorderStyleShorthand,
|
|
12
|
+
'border-width': openBorderWidthShorthand,
|
|
13
|
+
'border-color': openBorderColorShorthand,
|
|
14
|
+
outline: openOutlineShorthand,
|
|
15
|
+
'border-image': openBorderImageShorthand,
|
|
16
|
+
font: openFontShorthand,
|
|
17
|
+
'place-content': openPlaceContentShorthand,
|
|
18
|
+
'place-items': openPlaceItemsShorthand,
|
|
19
|
+
flex: openFlexShorthand,
|
|
20
|
+
'flex-flow': openFlexFlowShorthand,
|
|
21
|
+
margin: openMarginShorthand,
|
|
22
|
+
padding: openPaddingShorthand,
|
|
23
|
+
overflow: openOverflowShorthand,
|
|
24
|
+
gap: openGapShorthand,
|
|
25
|
+
'grid-gap': openGridGapShorthand,
|
|
26
|
+
'grid-row': openGridRowShorthand,
|
|
27
|
+
'grid-column': openGridColumnShorthand,
|
|
28
|
+
'grid-template': openGridTemplateShorthand,
|
|
29
|
+
grid: openGridShorthand,
|
|
30
|
+
'text-decoration': openTextDecorationShorthand,
|
|
31
|
+
'list-style': openListStyleShorthand,
|
|
32
|
+
};
|
|
33
|
+
const shorthandClosersMap = {
|
|
34
|
+
background: closeBackgroundShorthand,
|
|
35
|
+
'background-position': closeBackgroundPositionShorthand,
|
|
36
|
+
'border-radius': closeBorderRadiusShorthand,
|
|
37
|
+
border: closeBorderShorthand,
|
|
38
|
+
'border-top': closeBorderTopShorthand,
|
|
39
|
+
'border-right': closeBorderRightShorthand,
|
|
40
|
+
'border-bottom': closeBorderBottomShorthand,
|
|
41
|
+
'border-left': closeBorderLeftShorthand,
|
|
42
|
+
'border-style': closeBorderStyleShorthand,
|
|
43
|
+
'border-width': closeBorderWidthShorthand,
|
|
44
|
+
'border-color': closeBorderColorShorthand,
|
|
45
|
+
outline: closeOutlineShorthand,
|
|
46
|
+
'border-image': closeBorderImageShorthand,
|
|
47
|
+
font: closeFontShorthand,
|
|
48
|
+
'place-content': closePlaceContentShorthand,
|
|
49
|
+
'place-items': closePlaceItemsShorthand,
|
|
50
|
+
flex: closeFlexShorthand,
|
|
51
|
+
'flex-flow': closeFlexFlowShorthand,
|
|
52
|
+
margin: closeMarginShorthand,
|
|
53
|
+
padding: closePaddingShorthand,
|
|
54
|
+
overflow: closeOverflowShorthand,
|
|
55
|
+
gap: closeGapShorthand,
|
|
56
|
+
'grid-gap': closeGridGapShorthand,
|
|
57
|
+
'grid-row': closeGridRowShorthand,
|
|
58
|
+
'grid-column': closeGridColumnShorthand,
|
|
59
|
+
'grid-template': closeGridTemplateShorthand,
|
|
60
|
+
grid: closeGridShorthand,
|
|
61
|
+
'text-decoration': closeTextDecorationShorthand,
|
|
62
|
+
'list-style': closeListStyleShorthand,
|
|
63
|
+
};
|
|
64
|
+
export const getShorthandOpener = (prop) => {
|
|
65
|
+
const getOpener = shorthandOpenersMap[prop];
|
|
66
|
+
return getOpener();
|
|
67
|
+
};
|
|
68
|
+
export const getShorthandCloser = (prop) => {
|
|
69
|
+
const getCloser = shorthandClosersMap[prop];
|
|
70
|
+
return getCloser();
|
|
71
|
+
};
|
|
72
|
+
//# sourceMappingURL=shorthand-mapper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shorthand-mapper.js","sourceRoot":"","sources":["../../src/shorthands/shorthand-mapper.ts"],"names":[],"mappings":"AASA,OAAO,EACH,uBAAuB,EACvB,wBAAwB,EACxB,+BAA+B,EAC/B,gCAAgC,EAChC,yBAAyB,EACzB,0BAA0B,EAC1B,mBAAmB,EACnB,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,EACvB,wBAAwB,EACxB,yBAAyB,EACzB,yBAAyB,EACzB,0BAA0B,EAC1B,uBAAuB,EACvB,wBAAwB,EACxB,wBAAwB,EACxB,yBAAyB,EACzB,wBAAwB,EACxB,yBAAyB,EACzB,wBAAwB,EACxB,yBAAyB,EACzB,oBAAoB,EACpB,qBAAqB,EACrB,wBAAwB,EACxB,yBAAyB,EACzB,iBAAiB,EACjB,kBAAkB,EAClB,yBAAyB,EACzB,0BAA0B,EAC1B,uBAAuB,EACvB,wBAAwB,EACxB,iBAAiB,EACjB,kBAAkB,EAClB,qBAAqB,EACrB,sBAAsB,EACtB,gBAAgB,EAChB,iBAAiB,EACjB,oBAAoB,EACpB,qBAAqB,EACrB,uBAAuB,EACvB,wBAAwB,EACxB,oBAAoB,EACpB,qBAAqB,EACrB,yBAAyB,EACzB,0BAA0B,EAC1B,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,oBAAoB,EACpB,qBAAqB,EACrB,qBAAqB,EACrB,sBAAsB,EACtB,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;IACzC,OAAO,EAAE,qBAAqB;IAC9B,cAAc,EAAE,yBAAyB;IACzC,IAAI,EAAE,kBAAkB;IACxB,eAAe,EAAE,0BAA0B;IAC3C,aAAa,EAAE,wBAAwB;IACvC,IAAI,EAAE,kBAAkB;IACxB,WAAW,EAAE,sBAAsB;IACnC,MAAM,EAAE,oBAAoB;IAC5B,OAAO,EAAE,qBAAqB;IAC9B,QAAQ,EAAE,sBAAsB;IAChC,GAAG,EAAE,iBAAiB;IACtB,UAAU,EAAE,qBAAqB;IACjC,UAAU,EAAE,qBAAqB;IACjC,aAAa,EAAE,wBAAwB;IACvC,eAAe,EAAE,0BAA0B;IAC3C,IAAI,EAAE,kBAAkB;IACxB,iBAAiB,EAAE,4BAA4B;IAC/C,YAAY,EAAE,uBAAuB;CACxC,CAAC;AASF,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAuC,IAAO,EAA+B,EAAE;IAC7G,MAAM,SAAS,GAAG,mBAAmB,CAAC,IAAI,CAA6C,CAAC;IACxF,OAAO,SAAS,EAAoC,CAAC;AACzD,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAC9B,IAAO,EACiC,EAAE;IAC1C,MAAM,SAAS,GAAG,mBAAmB,CAAC,IAAI,CAA6C,CAAC;IACxF,OAAO,SAAS,EAAK,CAAC;AAC1B,CAAC,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare class ShorthandParserError extends Error {
|
|
2
|
+
constructor(message: string, prop?: string);
|
|
3
|
+
}
|
|
4
|
+
export declare class NoDataTypeMatchError extends ShorthandParserError {
|
|
5
|
+
constructor(value: string);
|
|
6
|
+
}
|
|
7
|
+
export declare class NoMandatoryPartMatchError extends ShorthandParserError {
|
|
8
|
+
constructor(prop: string, partProp: string);
|
|
9
|
+
}
|
|
10
|
+
export declare class InvalidIntersectionValueError extends ShorthandParserError {
|
|
11
|
+
constructor(prop: string, value: string);
|
|
12
|
+
}
|
|
13
|
+
export declare class InvalidEdgesInputLengthError extends ShorthandParserError {
|
|
14
|
+
constructor(prop: string, length: number);
|
|
15
|
+
}
|
|
16
|
+
export declare class CannotCloseBorderError extends ShorthandParserError {
|
|
17
|
+
constructor();
|
|
18
|
+
}
|
|
19
|
+
export declare class CannotCloseGridTemplateError extends ShorthandParserError {
|
|
20
|
+
constructor();
|
|
21
|
+
}
|
|
22
|
+
export declare class CannotCloseGridError extends ShorthandParserError {
|
|
23
|
+
constructor();
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=shorthand-parser-errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shorthand-parser-errors.d.ts","sourceRoot":"","sources":["../../src/shorthands/shorthand-parser-errors.ts"],"names":[],"mappings":"AAAA,qBAAa,oBAAqB,SAAQ,KAAK;gBAC/B,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM;CAG7C;AAED,qBAAa,oBAAqB,SAAQ,oBAAoB;gBAC9C,KAAK,EAAE,MAAM;CAG5B;AAED,qBAAa,yBAA0B,SAAQ,oBAAoB;gBACnD,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM;CAG7C;AAED,qBAAa,6BAA8B,SAAQ,oBAAoB;gBACvD,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM;CAG1C;AAED,qBAAa,4BAA6B,SAAQ,oBAAoB;gBACtD,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;CAG3C;AAED,qBAAa,sBAAuB,SAAQ,oBAAoB;;CAI/D;AAED,qBAAa,4BAA6B,SAAQ,oBAAoB;;CAIrE;AAED,qBAAa,oBAAqB,SAAQ,oBAAoB;;CAI7D"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
export class ShorthandParserError extends Error {
|
|
2
|
+
constructor(message, prop) {
|
|
3
|
+
super(`Shorthand Parser Error! ${prop ? '[' + prop + '] ' : ''}${message}`);
|
|
4
|
+
}
|
|
5
|
+
}
|
|
6
|
+
export class NoDataTypeMatchError extends ShorthandParserError {
|
|
7
|
+
constructor(value) {
|
|
8
|
+
super(`No data-type match: "${value}".`);
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
export class NoMandatoryPartMatchError extends ShorthandParserError {
|
|
12
|
+
constructor(prop, partProp) {
|
|
13
|
+
super(`No mandatory match on shorthand part: "${partProp}".`, prop);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
export class InvalidIntersectionValueError extends ShorthandParserError {
|
|
17
|
+
constructor(prop, value) {
|
|
18
|
+
super(`Invalid value for intersection: "${value}"`, prop);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
export class InvalidEdgesInputLengthError extends ShorthandParserError {
|
|
22
|
+
constructor(prop, length) {
|
|
23
|
+
super(`Invalid edges input length: "${length}".`, prop);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
export class CannotCloseBorderError extends ShorthandParserError {
|
|
27
|
+
constructor() {
|
|
28
|
+
super(`Cannot close border object.`, 'border');
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
export class CannotCloseGridTemplateError extends ShorthandParserError {
|
|
32
|
+
constructor() {
|
|
33
|
+
super(`Cannot close grid-template object.`, 'grid-template');
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
export class CannotCloseGridError extends ShorthandParserError {
|
|
37
|
+
constructor() {
|
|
38
|
+
super(`Cannot close grid object.`, 'grid');
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=shorthand-parser-errors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shorthand-parser-errors.js","sourceRoot":"","sources":["../../src/shorthands/shorthand-parser-errors.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,oBAAqB,SAAQ,KAAK;IAC3C,YAAY,OAAe,EAAE,IAAa;QACtC,KAAK,CAAC,2BAA2B,IAAI,CAAC,CAAC,CAAC,GAAG,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;CACJ;AAED,MAAM,OAAO,oBAAqB,SAAQ,oBAAoB;IAC1D,YAAY,KAAa;QACrB,KAAK,CAAC,wBAAwB,KAAK,IAAI,CAAC,CAAC;IAC7C,CAAC;CACJ;AAED,MAAM,OAAO,yBAA0B,SAAQ,oBAAoB;IAC/D,YAAY,IAAY,EAAE,QAAgB;QACtC,KAAK,CAAC,0CAA0C,QAAQ,IAAI,EAAE,IAAI,CAAC,CAAC;IACxE,CAAC;CACJ;AAED,MAAM,OAAO,6BAA8B,SAAQ,oBAAoB;IACnE,YAAY,IAAY,EAAE,KAAa;QACnC,KAAK,CAAC,oCAAoC,KAAK,GAAG,EAAE,IAAI,CAAC,CAAC;IAC9D,CAAC;CACJ;AAED,MAAM,OAAO,4BAA6B,SAAQ,oBAAoB;IAClE,YAAY,IAAY,EAAE,MAAc;QACpC,KAAK,CAAC,gCAAgC,MAAM,IAAI,EAAE,IAAI,CAAC,CAAC;IAC5D,CAAC;CACJ;AAED,MAAM,OAAO,sBAAuB,SAAQ,oBAAoB;IAC5D;QACI,KAAK,CAAC,6BAA6B,EAAE,QAAQ,CAAC,CAAC;IACnD,CAAC;CACJ;AAED,MAAM,OAAO,4BAA6B,SAAQ,oBAAoB;IAClE;QACI,KAAK,CAAC,oCAAoC,EAAE,eAAe,CAAC,CAAC;IACjE,CAAC;CACJ;AAED,MAAM,OAAO,oBAAqB,SAAQ,oBAAoB;IAC1D;QACI,KAAK,CAAC,2BAA2B,EAAE,MAAM,CAAC,CAAC;IAC/C,CAAC;CACJ"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { CSSAstNode, ParseShorthandAPI, EvaluatedAst, OpenedShorthandValue, OpenedShorthand, ShorthandOpener, ShorthandOpenerInner, SimpleShorthandOpenerInner, UnorderedListShorthandOptions, BeforeOpenerCheck, ShorthandPart, ShorthandOpenerData, SimpleShorthandOpener, ShorthandCloserTemplate, ShorthandCloser } from './shorthand-types.js';
|
|
2
|
+
import { DataTypeType, type DataType } from '../css-data-types/index.js';
|
|
3
|
+
export declare const matchDataType: <V>(dataType: DataType, astNodes: EvaluatedAst<V>[], index: number, prevDataType?: DataTypeType) => import("../css-data-types/data-types-types.js").PredicateMatch;
|
|
4
|
+
export declare const isOpenedInitial: <V, T extends string>(opened: OpenedShorthand<V, T>, prop: T, dataType: DataType) => boolean;
|
|
5
|
+
export declare const getInitialAst: <V>(value: string) => EvaluatedAst<V>[];
|
|
6
|
+
export declare const edgesShorthandOpener: <V, T extends string>(prop: string, corners?: boolean) => SimpleShorthandOpenerInner<V, T>;
|
|
7
|
+
export declare const intersectionBeforeOpenerCheck: <V>(prop: string, dataTypes: DataType[]) => BeforeOpenerCheck<V>;
|
|
8
|
+
export declare const splitSimpleShorthandOpener: <V, T extends string>(props: string[]) => SimpleShorthandOpenerInner<V, T>;
|
|
9
|
+
export declare const splitShorthandOpener: <V, T extends string>(props: string[]) => ShorthandOpenerInner<V, T>;
|
|
10
|
+
export declare const singleKeywordShorthandOpener: <V, T extends string>(keywordValueMap: Record<string, Record<T, string>>, multipleItems?: boolean) => ShorthandOpenerInner<V, T>;
|
|
11
|
+
export declare const unorderedListShorthandOpener: <V, T extends string>(parts: ShorthandPart<V>[], { shallow, commonValue }?: UnorderedListShorthandOptions) => ShorthandOpenerInner<V, T>;
|
|
12
|
+
export declare const getShorthandLayers: <V>(astNodes: EvaluatedAst<V>[], seperator?: string) => EvaluatedAst<V>[][];
|
|
13
|
+
export declare const getOpenedLayer: <V, T extends string>(opened: OpenedShorthand<V, T>, index: number, multipleItemProps?: T[]) => OpenedShorthand<V, T> | undefined;
|
|
14
|
+
export declare const layersShorthandOpener: <V, T extends string>(prop: string, singleLayerOpener: ShorthandOpenerInner<V, T>, singleLayerParts: ShorthandPart<V>[], lastLayerOpener?: ShorthandOpenerInner<V, T>, lastLayerParts?: ShorthandPart<V>[]) => ShorthandOpenerInner<V, T>;
|
|
15
|
+
export declare const createShorthandOpener: <V, T extends string>({ prop, singleKeywordPart, parts, shorthandOpener, }: ShorthandOpenerData<V, T>) => ShorthandOpener<V, T>;
|
|
16
|
+
export declare const createShorthandOpenerFromPart: <V, T extends string>(part: ShorthandPart<V, T>) => SimpleShorthandOpener<V, T>;
|
|
17
|
+
export declare const getOpenedNode: <V>(nodeOrNodes: OpenedShorthandValue<V>, api: ParseShorthandAPI<V>, detachExpressions?: boolean, multiExpressions?: string[]) => CSSAstNode<V>[];
|
|
18
|
+
export declare const getOpenedNodeValue: <V>(nodes: CSSAstNode<V>[], api: ParseShorthandAPI<V>) => string;
|
|
19
|
+
export declare const edgesShorthandCloser: <V, T extends string = string>(prop: string, corners?: boolean) => ShorthandCloser<V, T>;
|
|
20
|
+
export declare const shorthandCloserTemplate: <T extends string>(strings: TemplateStringsArray, ...keys: string[]) => ShorthandCloserTemplate<T>;
|
|
21
|
+
export declare const createShorthandCloserTemplateFromParts: <V, T extends string>(parts: ShorthandPart<V, T>[]) => ShorthandCloserTemplate<T>;
|
|
22
|
+
export declare const createShorthandCloser: <V, T extends string = string, R extends OpenedShorthand<V, T> = OpenedShorthand<V, T>>(template: ShorthandCloserTemplate<T>) => ShorthandCloser<V, T, R>;
|
|
23
|
+
export declare const fixAstNodesPositions: <V>(nodes: readonly CSSAstNode<V>[], api: ParseShorthandAPI<V>, start?: number) => CSSAstNode<V>[];
|
|
24
|
+
//# sourceMappingURL=shorthand-parser-utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shorthand-parser-utils.d.ts","sourceRoot":"","sources":["../../src/shorthands/shorthand-parser-utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,UAAU,EACV,iBAAiB,EACjB,YAAY,EAEZ,oBAAoB,EACpB,eAAe,EAEf,eAAe,EACf,oBAAoB,EACpB,0BAA0B,EAC1B,6BAA6B,EAC7B,iBAAiB,EACjB,aAAa,EACb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/B,KAAK,iBAAiB,CAAC,CAAC,CAAC,EACzB,cAAS,KACV,UAAU,CAAC,CAAC,CAAC,EAwDf,CAAC"}
|
|
@@ -0,0 +1,398 @@
|
|
|
1
|
+
import { isCSSCodeAst, createCssValueAST, valueTextNode, getFullText, } from '../tokenizers/index.js';
|
|
2
|
+
import { evaluateAst } from './shorthands-ast-evaluation.js';
|
|
3
|
+
import { DataTypeType, unorderedListPredicate, universalDataType, DEFAULT_LAYER_SEPERATOR, } from '../css-data-types/index.js';
|
|
4
|
+
import { CSS_PROPERTY_DELIMITER, EDGE_SHORTHAND_EDGES, CORNER_SHORTHAND_CORNERS, EDGE_SHORTHAND_INDICES_BY_LENGTH, } from './shorthand-css-data.js';
|
|
5
|
+
import { NoDataTypeMatchError, NoMandatoryPartMatchError, InvalidIntersectionValueError, InvalidEdgesInputLengthError, } from './shorthand-parser-errors.js';
|
|
6
|
+
export const matchDataType = (dataType, astNodes, index, prevDataType) => dataType.predicate(astNodes[index].value, index, astNodes, prevDataType);
|
|
7
|
+
const getDataTypeMatch = (astNodes, index, parts, prevDataType) => {
|
|
8
|
+
for (let i = 0; i < parts.length; i++) {
|
|
9
|
+
let matchAmount = 0;
|
|
10
|
+
if ((matchAmount = Number(matchDataType(parts[i].dataType, astNodes, index, prevDataType))) > 0) {
|
|
11
|
+
return { matchAmount, matchIndex: i };
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
return { matchAmount: 1, matchIndex: -1 };
|
|
15
|
+
};
|
|
16
|
+
export const isOpenedInitial = (opened, prop, dataType) => {
|
|
17
|
+
const openedAst = opened[prop];
|
|
18
|
+
return openedAst.length === 1 && openedAst[0].value.text === dataType.initial;
|
|
19
|
+
};
|
|
20
|
+
export const getInitialAst = (value) => {
|
|
21
|
+
return createCssValueAST(value).map((node) => ({ value: node, isImplicit: true }));
|
|
22
|
+
};
|
|
23
|
+
const setInitialOpenedProps = (shorthandProp, parts, opened, shallow) => {
|
|
24
|
+
for (const part of parts) {
|
|
25
|
+
const props = shallow || !part.openedProps ? [part.prop] : part.openedProps;
|
|
26
|
+
for (const prop of props) {
|
|
27
|
+
if (opened[prop] === undefined) {
|
|
28
|
+
if (!part.mandatory) {
|
|
29
|
+
const initialAst = getInitialAst(part.dataType.initial);
|
|
30
|
+
opened[prop] = part.multipleItems ? initialAst : initialAst[0];
|
|
31
|
+
}
|
|
32
|
+
else {
|
|
33
|
+
throw new NoMandatoryPartMatchError(shorthandProp, prop);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
return opened;
|
|
39
|
+
};
|
|
40
|
+
const setCommonProps = (parts, nodes, opened) => {
|
|
41
|
+
for (let i = 0; i < parts.length && nodes.length > 0; i++) {
|
|
42
|
+
const { prop } = parts[i];
|
|
43
|
+
if (opened[prop] === undefined) {
|
|
44
|
+
let commonNode;
|
|
45
|
+
if ((commonNode = nodes.shift())) {
|
|
46
|
+
opened[prop] = commonNode;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
return opened;
|
|
51
|
+
};
|
|
52
|
+
export const edgesShorthandOpener = (prop, corners) => (astNodes) => {
|
|
53
|
+
if (astNodes.length < 1 || astNodes.length > 4) {
|
|
54
|
+
throw new InvalidEdgesInputLengthError(prop, astNodes.length);
|
|
55
|
+
}
|
|
56
|
+
const [propPrefix, propSuffix] = prop.split(CSS_PROPERTY_DELIMITER);
|
|
57
|
+
const prefix = propPrefix + CSS_PROPERTY_DELIMITER;
|
|
58
|
+
const suffix = propSuffix ? CSS_PROPERTY_DELIMITER + propSuffix : '';
|
|
59
|
+
const edgeIndices = EDGE_SHORTHAND_INDICES_BY_LENGTH[astNodes.length - 1];
|
|
60
|
+
const edges = !corners ? EDGE_SHORTHAND_EDGES : CORNER_SHORTHAND_CORNERS;
|
|
61
|
+
const edgeProp = (edge) => `${prefix}${edge}${suffix}`;
|
|
62
|
+
const edgeValue = (index) => astNodes[edgeIndices[index]];
|
|
63
|
+
return {
|
|
64
|
+
[edgeProp(edges[0])]: edgeValue(0),
|
|
65
|
+
[edgeProp(edges[1])]: edgeValue(1),
|
|
66
|
+
[edgeProp(edges[2])]: edgeValue(2),
|
|
67
|
+
[edgeProp(edges[3])]: edgeValue(3),
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
export const intersectionBeforeOpenerCheck = (prop, dataTypes) => (astNodes) => {
|
|
71
|
+
const validateValue = (value, dataType) => {
|
|
72
|
+
if (!dataType.predicate(value)) {
|
|
73
|
+
throw new InvalidIntersectionValueError(prop, value.text);
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
if (astNodes.length === 1) {
|
|
77
|
+
for (const dataType of dataTypes) {
|
|
78
|
+
validateValue(astNodes[0].value, dataType);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
else if (astNodes.length > 1 && dataTypes.length === astNodes.length) {
|
|
82
|
+
for (let i = 0; i < dataTypes.length; i++) {
|
|
83
|
+
validateValue(astNodes[i].value, dataTypes[i]);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
export const splitSimpleShorthandOpener = (props) => (astNodes) => {
|
|
88
|
+
const opened = {};
|
|
89
|
+
for (const prop of props) {
|
|
90
|
+
opened[prop] = astNodes[0];
|
|
91
|
+
}
|
|
92
|
+
return opened;
|
|
93
|
+
};
|
|
94
|
+
export const splitShorthandOpener = (props) => (astNodes) => {
|
|
95
|
+
const opened = {};
|
|
96
|
+
for (const prop of props) {
|
|
97
|
+
opened[prop] = astNodes;
|
|
98
|
+
}
|
|
99
|
+
return opened;
|
|
100
|
+
};
|
|
101
|
+
export const singleKeywordShorthandOpener = (keywordValueMap, multipleItems = false) => (astNodes) => {
|
|
102
|
+
const opened = {};
|
|
103
|
+
const keywordValues = keywordValueMap[astNodes[0].value.text];
|
|
104
|
+
const props = Object.keys(keywordValues);
|
|
105
|
+
for (const prop of props) {
|
|
106
|
+
const initialAst = getInitialAst(keywordValues[prop]);
|
|
107
|
+
opened[prop] = multipleItems ? initialAst : initialAst[0];
|
|
108
|
+
}
|
|
109
|
+
return opened;
|
|
110
|
+
};
|
|
111
|
+
export const unorderedListShorthandOpener = (parts, { shallow, commonValue } = {}) => (astNodes, api) => {
|
|
112
|
+
let opened = {};
|
|
113
|
+
const unfoundParts = [...parts];
|
|
114
|
+
const commonMatch = commonValue ? unorderedListPredicate(commonValue) : () => false;
|
|
115
|
+
const commonNodes = [];
|
|
116
|
+
let prevDataType = DataTypeType.Unknown;
|
|
117
|
+
for (let index = 0; index < astNodes.length;) {
|
|
118
|
+
let currNode = astNodes[index];
|
|
119
|
+
if (commonValue && commonMatch(currNode.value)) {
|
|
120
|
+
commonNodes.push(astNodes[index++]);
|
|
121
|
+
continue;
|
|
122
|
+
}
|
|
123
|
+
const dataTypeMatch = getDataTypeMatch(astNodes, index, unfoundParts, prevDataType);
|
|
124
|
+
const { matchAmount, matchIndex } = dataTypeMatch;
|
|
125
|
+
const foundPart = unfoundParts[matchIndex];
|
|
126
|
+
if (matchIndex !== -1 && foundPart) {
|
|
127
|
+
let matchLength = matchAmount;
|
|
128
|
+
const { prop, dataType, partOpener, beforeOpenerCheck, multipleItems, multipleSplit } = foundPart;
|
|
129
|
+
beforeOpenerCheck?.(astNodes);
|
|
130
|
+
if (dataType.prefix && currNode.value.text === dataType.prefix.prefixChar) {
|
|
131
|
+
currNode = astNodes[++index];
|
|
132
|
+
matchLength--;
|
|
133
|
+
}
|
|
134
|
+
const nodes = matchLength === 1 ? currNode : astNodes.slice(index, index + matchLength);
|
|
135
|
+
if (shallow || !partOpener) {
|
|
136
|
+
opened[prop] = multipleItems
|
|
137
|
+
? (!multipleSplit ? opened[prop] || [] : []).concat(nodes)
|
|
138
|
+
: nodes;
|
|
139
|
+
}
|
|
140
|
+
else {
|
|
141
|
+
opened = {
|
|
142
|
+
...opened,
|
|
143
|
+
...partOpener(Array.isArray(nodes) ? nodes : [nodes], api),
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
unfoundParts.splice(matchIndex, 1);
|
|
147
|
+
prevDataType = dataType.dataType;
|
|
148
|
+
index += matchLength;
|
|
149
|
+
}
|
|
150
|
+
else {
|
|
151
|
+
throw new NoDataTypeMatchError(currNode.value.text);
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
if (commonValue) {
|
|
155
|
+
opened = setCommonProps(parts, commonNodes, opened);
|
|
156
|
+
}
|
|
157
|
+
return opened;
|
|
158
|
+
};
|
|
159
|
+
export const getShorthandLayers = (astNodes, seperator = DEFAULT_LAYER_SEPERATOR) => {
|
|
160
|
+
const layers = [];
|
|
161
|
+
let layerIndex = 0;
|
|
162
|
+
for (const node of astNodes) {
|
|
163
|
+
if (node.value.text === seperator) {
|
|
164
|
+
layerIndex++;
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
if (!layers[layerIndex]) {
|
|
168
|
+
layers[layerIndex] = [];
|
|
169
|
+
}
|
|
170
|
+
layers[layerIndex].push(node);
|
|
171
|
+
}
|
|
172
|
+
return layers;
|
|
173
|
+
};
|
|
174
|
+
export const getOpenedLayer = (opened, index, multipleItemProps) => {
|
|
175
|
+
const layer = {};
|
|
176
|
+
const props = Object.keys(opened);
|
|
177
|
+
let hasValue = false;
|
|
178
|
+
for (const prop of props) {
|
|
179
|
+
const value = opened[prop];
|
|
180
|
+
if (!value) {
|
|
181
|
+
continue;
|
|
182
|
+
}
|
|
183
|
+
if (multipleItemProps && multipleItemProps.includes(prop)) {
|
|
184
|
+
const valueInIndex = value[index];
|
|
185
|
+
if (!Array.isArray(valueInIndex)) {
|
|
186
|
+
if (index === 0) {
|
|
187
|
+
layer[prop] = value;
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
else {
|
|
191
|
+
layer[prop] = valueInIndex;
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
else {
|
|
195
|
+
layer[prop] = index === 0 && !Array.isArray(value) ? value : value[index];
|
|
196
|
+
}
|
|
197
|
+
if (layer[prop]) {
|
|
198
|
+
hasValue = true;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
return hasValue ? layer : undefined;
|
|
202
|
+
};
|
|
203
|
+
export const layersShorthandOpener = (prop, singleLayerOpener, singleLayerParts, lastLayerOpener, lastLayerParts) => (astNodes, api) => {
|
|
204
|
+
const layers = getShorthandLayers(astNodes);
|
|
205
|
+
let openedLayers = (!lastLayerOpener ? layers : layers.slice(0, -1)).map((layer) => setInitialOpenedProps(prop, singleLayerParts, singleLayerOpener(layer, api)));
|
|
206
|
+
if (lastLayerOpener) {
|
|
207
|
+
openedLayers = openedLayers.concat([
|
|
208
|
+
setInitialOpenedProps(prop, lastLayerParts || [], lastLayerOpener(layers[layers.length - 1], api)),
|
|
209
|
+
]);
|
|
210
|
+
}
|
|
211
|
+
if (layers.length === 1) {
|
|
212
|
+
return openedLayers[0];
|
|
213
|
+
}
|
|
214
|
+
const opened = {};
|
|
215
|
+
for (const layer of openedLayers) {
|
|
216
|
+
const layerProps = Object.keys(layer);
|
|
217
|
+
for (const prop of layerProps) {
|
|
218
|
+
const existingValue = opened[prop];
|
|
219
|
+
const propValue = layer[prop];
|
|
220
|
+
if (!existingValue) {
|
|
221
|
+
opened[prop] = propValue;
|
|
222
|
+
}
|
|
223
|
+
else {
|
|
224
|
+
if (!Array.isArray(propValue)) {
|
|
225
|
+
opened[prop] = Array.isArray(existingValue)
|
|
226
|
+
? existingValue.concat(propValue)
|
|
227
|
+
: [existingValue, propValue];
|
|
228
|
+
}
|
|
229
|
+
else {
|
|
230
|
+
opened[prop] = Array.isArray(existingValue[0])
|
|
231
|
+
? existingValue.concat([propValue])
|
|
232
|
+
: [existingValue, propValue];
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
return opened;
|
|
238
|
+
};
|
|
239
|
+
const getShorthandPartsProps = (parts, shallow) => {
|
|
240
|
+
let partsProps = [];
|
|
241
|
+
for (const part of parts) {
|
|
242
|
+
partsProps = partsProps.concat(shallow || !part.openedProps ? part.prop : part.openedProps);
|
|
243
|
+
}
|
|
244
|
+
return partsProps;
|
|
245
|
+
};
|
|
246
|
+
const openSingleKeywordShorthand = (shorthandProp, partProps, astNodes, api, part) => {
|
|
247
|
+
let opened = {};
|
|
248
|
+
if (astNodes.length === 1) {
|
|
249
|
+
const node = astNodes[0];
|
|
250
|
+
const universalPart = {
|
|
251
|
+
prop: shorthandProp,
|
|
252
|
+
dataType: universalDataType,
|
|
253
|
+
partOpener: splitSimpleShorthandOpener(partProps),
|
|
254
|
+
};
|
|
255
|
+
/* Identify shorthand single-keyword with predicate */
|
|
256
|
+
const matchingPart = part && part.dataType.predicate(node.value)
|
|
257
|
+
? part
|
|
258
|
+
: universalPart.dataType.predicate(node.value)
|
|
259
|
+
? universalPart
|
|
260
|
+
: undefined;
|
|
261
|
+
if (matchingPart) {
|
|
262
|
+
/* Return the opened single-keyword shorthand, using opener if it exists */
|
|
263
|
+
opened = matchingPart.partOpener ? matchingPart.partOpener([node], api) : { [matchingPart.prop]: node };
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
return opened;
|
|
267
|
+
};
|
|
268
|
+
export const createShorthandOpener = ({ prop, singleKeywordPart, parts, shorthandOpener, }) => (shortHand, api, shallow) => {
|
|
269
|
+
/* Evaluate the full input AST */
|
|
270
|
+
const astNodes = evaluateAst(shortHand, api);
|
|
271
|
+
/* Try opening the shorthand as a single keyword and return it if so */
|
|
272
|
+
const singleKeywordOpened = openSingleKeywordShorthand(prop, getShorthandPartsProps(parts, shallow), astNodes, api, singleKeywordPart);
|
|
273
|
+
if (Object.keys(singleKeywordOpened).length > 0) {
|
|
274
|
+
return singleKeywordOpened;
|
|
275
|
+
}
|
|
276
|
+
// TODO: Catch errors and return some value on error?
|
|
277
|
+
/* Open the shorthand using the provided method */
|
|
278
|
+
const opened = shorthandOpener(astNodes, api, parts, shallow);
|
|
279
|
+
/* Return the opened shorthand, after setting missing initial values */
|
|
280
|
+
return setInitialOpenedProps(prop, parts, opened, shallow);
|
|
281
|
+
};
|
|
282
|
+
export const createShorthandOpenerFromPart = (part) => {
|
|
283
|
+
return createShorthandOpener({
|
|
284
|
+
prop: part.prop,
|
|
285
|
+
parts: [part],
|
|
286
|
+
shorthandOpener: (astNodes, api, _parts, shallow) => part.partOpener ? part.partOpener(astNodes, api, shallow) : {},
|
|
287
|
+
});
|
|
288
|
+
};
|
|
289
|
+
export const getOpenedNode = (nodeOrNodes, api, detachExpressions = false, multiExpressions = []) => {
|
|
290
|
+
if (Array.isArray(nodeOrNodes)) {
|
|
291
|
+
return nodeOrNodes.reduce((values, node) => values.concat(getOpenedNode(node, api, detachExpressions, multiExpressions)), []);
|
|
292
|
+
}
|
|
293
|
+
const { origin } = nodeOrNodes;
|
|
294
|
+
if (!origin || detachExpressions) {
|
|
295
|
+
return [nodeOrNodes.value];
|
|
296
|
+
}
|
|
297
|
+
const expression = api.toString(origin);
|
|
298
|
+
if (multiExpressions.includes(expression)) {
|
|
299
|
+
return [];
|
|
300
|
+
}
|
|
301
|
+
if (api.getValue(origin).length > 1) {
|
|
302
|
+
multiExpressions.push(expression);
|
|
303
|
+
}
|
|
304
|
+
return [origin];
|
|
305
|
+
};
|
|
306
|
+
export const getOpenedNodeValue = (nodes, api) => nodes
|
|
307
|
+
.reduce((value, node) => value + (isCSSCodeAst(node) ? getFullText(node) : ' ' + api.toString(node)), '')
|
|
308
|
+
.trim();
|
|
309
|
+
export const edgesShorthandCloser = (prop, corners) => (opened, api, detachExpressions = false) => {
|
|
310
|
+
const [propPrefix, propSuffix] = prop.split(CSS_PROPERTY_DELIMITER);
|
|
311
|
+
const prefix = propPrefix + CSS_PROPERTY_DELIMITER;
|
|
312
|
+
const suffix = propSuffix ? CSS_PROPERTY_DELIMITER + propSuffix : '';
|
|
313
|
+
const edges = !corners ? EDGE_SHORTHAND_EDGES : CORNER_SHORTHAND_CORNERS;
|
|
314
|
+
const multiExpressions = [];
|
|
315
|
+
const edgeProp = (edge) => `${prefix}${edge}${suffix}`;
|
|
316
|
+
const edgeValue = (index) => getOpenedNode(opened[edgeProp(edges[index])], api, detachExpressions, multiExpressions);
|
|
317
|
+
const edgeNodes = [edgeValue(0), edgeValue(1), edgeValue(2), edgeValue(3)];
|
|
318
|
+
const edgeValues = edgeNodes.map((nodes) => getOpenedNodeValue(nodes, api));
|
|
319
|
+
if (edgeValues[3] === edgeValues[1]) {
|
|
320
|
+
edgeNodes.pop();
|
|
321
|
+
edgeValues.pop();
|
|
322
|
+
if (edgeValues[2] === edgeValues[0]) {
|
|
323
|
+
edgeNodes.pop();
|
|
324
|
+
edgeValues.pop();
|
|
325
|
+
if (edgeValues[1] === edgeValues[0]) {
|
|
326
|
+
edgeNodes.pop();
|
|
327
|
+
edgeValues.pop();
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
}
|
|
331
|
+
return fixAstNodesPositions(edgeNodes.filter((nodes) => nodes.length > 0).map((nodes) => nodes[0]), api);
|
|
332
|
+
};
|
|
333
|
+
export const shorthandCloserTemplate = (strings, ...keys) => ({ strings, keys });
|
|
334
|
+
export const createShorthandCloserTemplateFromParts = (parts) => {
|
|
335
|
+
const keys = parts.map(({ prop }) => prop);
|
|
336
|
+
return {
|
|
337
|
+
keys,
|
|
338
|
+
strings: [''].concat(Array(keys.length).fill(' ')),
|
|
339
|
+
};
|
|
340
|
+
};
|
|
341
|
+
export const createShorthandCloser = (template) => (opened, api, detachExpressions = false) => {
|
|
342
|
+
const multiExpressions = [];
|
|
343
|
+
return fixAstNodesPositions(template.strings.reduce((nodes, currString, index) => {
|
|
344
|
+
const currKey = template.keys[index];
|
|
345
|
+
return currKey === undefined
|
|
346
|
+
? nodes
|
|
347
|
+
: nodes.concat(valueTextNode(currString), getOpenedNode(opened[currKey], api, detachExpressions, multiExpressions));
|
|
348
|
+
}, []), api);
|
|
349
|
+
};
|
|
350
|
+
export const fixAstNodesPositions = (nodes, api, start = 0) => {
|
|
351
|
+
let currPosition = start;
|
|
352
|
+
const fixedNodes = [];
|
|
353
|
+
nodes.forEach((node) => {
|
|
354
|
+
let nodeText = '';
|
|
355
|
+
if (isCSSCodeAst(node)) {
|
|
356
|
+
nodeText = node.text.trim();
|
|
357
|
+
if (nodeText.length === 0) {
|
|
358
|
+
return;
|
|
359
|
+
}
|
|
360
|
+
const before = [];
|
|
361
|
+
if (fixedNodes.length > 0 && nodeText !== ',') {
|
|
362
|
+
// Trailing spaces are added only after the first valid node
|
|
363
|
+
before.push({
|
|
364
|
+
type: 'space',
|
|
365
|
+
value: ' ',
|
|
366
|
+
start: currPosition,
|
|
367
|
+
end: currPosition + 1,
|
|
368
|
+
});
|
|
369
|
+
currPosition++;
|
|
370
|
+
}
|
|
371
|
+
let args = [];
|
|
372
|
+
if (node.type === 'call') {
|
|
373
|
+
args = fixAstNodesPositions(node.args, api,
|
|
374
|
+
// Current position + function name + (
|
|
375
|
+
currPosition + node.name.length + 1);
|
|
376
|
+
}
|
|
377
|
+
fixedNodes.push({
|
|
378
|
+
...node,
|
|
379
|
+
...(nodeText === '/' ? { type: '/' } : nodeText === ',' ? { type: ',' } : {}),
|
|
380
|
+
text: nodeText,
|
|
381
|
+
start: currPosition,
|
|
382
|
+
end: currPosition + nodeText.length,
|
|
383
|
+
before,
|
|
384
|
+
...(args.length > 0 ? { args } : {}),
|
|
385
|
+
});
|
|
386
|
+
}
|
|
387
|
+
else {
|
|
388
|
+
nodeText = api.toString(node);
|
|
389
|
+
if (fixedNodes.length > 0) {
|
|
390
|
+
currPosition++; // To account for a space before non-first expression nodes
|
|
391
|
+
}
|
|
392
|
+
fixedNodes.push(node);
|
|
393
|
+
}
|
|
394
|
+
currPosition += nodeText.length;
|
|
395
|
+
});
|
|
396
|
+
return fixedNodes;
|
|
397
|
+
};
|
|
398
|
+
//# sourceMappingURL=shorthand-parser-utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shorthand-parser-utils.js","sourceRoot":"","s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