@stylexjs/shared 0.2.0-beta.9 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +3 -3
- package/lib/common-types.d.ts +49 -0
- package/lib/common-types.js.flow +64 -0
- package/lib/convert-to-className.d.ts +16 -0
- package/lib/convert-to-className.js +17 -26
- package/lib/convert-to-className.js.flow +23 -0
- package/lib/generate-css-rule.d.ts +17 -0
- package/lib/generate-css-rule.js +6 -17
- package/lib/generate-css-rule.js.flow +17 -0
- package/lib/hash.d.ts +11 -0
- package/lib/hash.js +3 -27
- package/lib/hash.js.flow +10 -0
- package/lib/index.d.ts +42 -85
- package/lib/index.js +21 -29
- package/lib/index.js.flow +57 -3
- package/lib/messages.d.ts +41 -0
- package/lib/messages.js +33 -53
- package/lib/messages.js.flow +44 -0
- package/lib/physical-rtl/generate-ltr.d.ts +11 -0
- package/lib/physical-rtl/generate-ltr.js +18 -46
- package/lib/physical-rtl/generate-ltr.js.flow +12 -0
- package/lib/physical-rtl/generate-rtl.d.ts +13 -0
- package/lib/physical-rtl/generate-rtl.js +18 -50
- package/lib/physical-rtl/generate-rtl.js.flow +12 -0
- package/lib/preprocess-rules/PreRule.d.ts +52 -0
- package/lib/preprocess-rules/PreRule.js +87 -0
- package/lib/preprocess-rules/PreRule.js.flow +64 -0
- package/lib/preprocess-rules/application-order.d.ts +290 -0
- package/lib/preprocess-rules/application-order.js +60 -133
- package/lib/preprocess-rules/application-order.js.flow +241 -0
- package/lib/preprocess-rules/basic-validation.d.ts +13 -0
- package/lib/preprocess-rules/basic-validation.js +83 -0
- package/lib/preprocess-rules/basic-validation.js.flow +13 -0
- package/lib/preprocess-rules/flatten-raw-style-obj.d.ts +25 -0
- package/lib/preprocess-rules/flatten-raw-style-obj.js +120 -0
- package/lib/preprocess-rules/flatten-raw-style-obj.js.flow +27 -0
- package/lib/preprocess-rules/index.d.ts +18 -0
- package/lib/preprocess-rules/index.js +0 -9
- package/lib/preprocess-rules/index.js.flow +19 -0
- package/lib/preprocess-rules/legacy-expand-shorthands.d.ts +200 -0
- package/lib/preprocess-rules/legacy-expand-shorthands.js +90 -123
- package/lib/preprocess-rules/legacy-expand-shorthands.js.flow +179 -0
- package/lib/preprocess-rules/property-specificity.d.ts +89 -0
- package/lib/preprocess-rules/property-specificity.js +46 -74
- package/lib/preprocess-rules/property-specificity.js.flow +98 -0
- package/lib/properties/CSS Animations.json +445 -0
- package/lib/properties/CSS Backgrounds and Borders.json +1085 -0
- package/lib/properties/CSS Basic User Interface.json +365 -0
- package/lib/properties/CSS Box Alignment.json +245 -0
- package/lib/properties/CSS Box Model.json +501 -0
- package/lib/properties/CSS Color.json +100 -0
- package/lib/properties/CSS Columns.json +185 -0
- package/lib/properties/CSS Containment.json +203 -0
- package/lib/properties/CSS Counter Styles.json +56 -0
- package/lib/properties/CSS Display.json +20 -0
- package/lib/properties/CSS Flexible Box Layout.json +167 -0
- package/lib/properties/CSS Fonts.json +684 -0
- package/lib/properties/CSS Fragmentation.json +110 -0
- package/lib/properties/CSS Generated Content.json +38 -0
- package/lib/properties/CSS Grid Layout.json +500 -0
- package/lib/properties/CSS Images.json +91 -0
- package/lib/properties/CSS Inline.json +38 -0
- package/lib/properties/CSS Lists and Counters.json +86 -0
- package/lib/properties/CSS Logical Properties.json +1086 -0
- package/lib/properties/CSS Masking.json +399 -0
- package/lib/properties/CSS Miscellaneous.json +38 -0
- package/lib/properties/CSS Motion Path.json +132 -0
- package/lib/properties/CSS Overflow.json +216 -0
- package/lib/properties/CSS Pages.json +83 -0
- package/lib/properties/CSS Positioning.json +166 -0
- package/lib/properties/CSS Ruby.json +55 -0
- package/lib/properties/CSS Scroll Anchoring.json +19 -0
- package/lib/properties/CSS Scroll Snap.json +604 -0
- package/lib/properties/CSS Scrollbars.json +38 -0
- package/lib/properties/CSS Shapes.json +56 -0
- package/lib/properties/CSS Speech.json +20 -0
- package/lib/properties/CSS Table.json +115 -0
- package/lib/properties/CSS Text Decoration.json +312 -0
- package/lib/properties/CSS Text.json +415 -0
- package/lib/properties/CSS Transforms.json +188 -0
- package/lib/properties/CSS Transitions.json +122 -0
- package/lib/properties/CSS Variables.json +20 -0
- package/lib/properties/CSS View Transitions.json +20 -0
- package/lib/properties/CSS Will Change.json +20 -0
- package/lib/properties/CSS Writing Modes.json +92 -0
- package/lib/properties/Compositing and Blending.json +62 -0
- package/lib/properties/Filter Effects.json +38 -0
- package/lib/properties/MathML.json +56 -0
- package/lib/properties/Microsoft Extensions.json +885 -0
- package/lib/properties/Mozilla Extensions.json +607 -0
- package/lib/properties/Pointer Events.json +20 -0
- package/lib/properties/WebKit Extensions.json +707 -0
- package/lib/properties.json +10122 -0
- package/lib/stylex-create-theme.d.ts +26 -0
- package/lib/stylex-create-theme.js +67 -0
- package/lib/stylex-create-theme.js.flow +19 -0
- package/lib/stylex-create.d.ts +23 -0
- package/lib/stylex-create.js +30 -146
- package/lib/stylex-create.js.flow +30 -0
- package/lib/stylex-define-vars.d.ts +29 -0
- package/lib/stylex-define-vars.js +73 -0
- package/lib/stylex-define-vars.js.flow +26 -0
- package/lib/stylex-first-that-works.d.ts +13 -0
- package/lib/stylex-first-that-works.js +0 -10
- package/lib/stylex-first-that-works.js.flow +12 -0
- package/lib/stylex-include.d.ts +18 -0
- package/lib/stylex-include.js +2 -12
- package/lib/stylex-include.js.flow +20 -0
- package/lib/stylex-keyframes.d.ts +17 -0
- package/lib/stylex-keyframes.js +6 -26
- package/lib/stylex-keyframes.js.flow +20 -0
- package/lib/transform-value.d.ts +22 -0
- package/lib/transform-value.js +9 -23
- package/lib/transform-value.js.flow +25 -0
- package/lib/types/index.d.ts +205 -0
- package/lib/types/index.js +191 -0
- package/lib/types/index.js.flow +241 -0
- package/lib/utils/Rule.d.ts +58 -0
- package/lib/utils/Rule.js +0 -21
- package/lib/utils/Rule.js.flow +64 -0
- package/lib/utils/dashify.d.ts +11 -0
- package/lib/utils/dashify.js +0 -8
- package/lib/utils/dashify.js.flow +10 -0
- package/lib/utils/default-options.d.ts +11 -0
- package/lib/utils/default-options.js +13 -0
- package/lib/utils/default-options.js.flow +25 -0
- package/lib/utils/file-based-identifier.d.ts +15 -0
- package/lib/utils/file-based-identifier.js +14 -0
- package/lib/utils/file-based-identifier.js.flow +14 -0
- package/lib/utils/genCSSRule.d.ts +15 -0
- package/lib/utils/genCSSRule.js +9 -18
- package/lib/utils/genCSSRule.js.flow +15 -0
- package/lib/utils/normalize-value.d.ts +16 -0
- package/lib/utils/normalize-value.js +8 -15
- package/lib/utils/normalize-value.js.flow +16 -0
- package/lib/utils/normalizers/convert-camel-case-transition-props.d.ts +14 -0
- package/lib/utils/normalizers/convert-camel-case-transition-props.js +23 -0
- package/lib/utils/normalizers/convert-camel-case-transition-props.js.flow +13 -0
- package/lib/utils/normalizers/convert-camel-case-values.d.ts +14 -0
- package/lib/utils/normalizers/convert-camel-case-values.js +23 -0
- package/lib/utils/normalizers/convert-camel-case-values.js.flow +13 -0
- package/lib/utils/normalizers/detect-unclosed-fns.d.ts +17 -0
- package/lib/utils/normalizers/detect-unclosed-fns.js +2 -14
- package/lib/utils/normalizers/detect-unclosed-fns.js.flow +16 -0
- package/lib/utils/normalizers/font-size-px-to-rem.d.ts +19 -0
- package/lib/utils/normalizers/font-size-px-to-rem.js +9 -19
- package/lib/utils/normalizers/font-size-px-to-rem.js.flow +18 -0
- package/lib/utils/normalizers/leading-zero.d.ts +17 -0
- package/lib/utils/normalizers/leading-zero.js +0 -12
- package/lib/utils/normalizers/leading-zero.js.flow +16 -0
- package/lib/utils/normalizers/quotes.d.ts +18 -0
- package/lib/utils/normalizers/quotes.js +0 -13
- package/lib/utils/normalizers/quotes.js.flow +17 -0
- package/lib/utils/normalizers/timings.d.ts +18 -0
- package/lib/utils/normalizers/timings.js +0 -14
- package/lib/utils/normalizers/timings.js.flow +17 -0
- package/lib/utils/normalizers/whitespace.d.ts +19 -0
- package/lib/utils/normalizers/whitespace.js +0 -15
- package/lib/utils/normalizers/whitespace.js.flow +18 -0
- package/lib/utils/normalizers/zero-dimensions.d.ts +19 -0
- package/lib/utils/normalizers/zero-dimensions.js +0 -15
- package/lib/utils/normalizers/zero-dimensions.js.flow +18 -0
- package/lib/utils/object-utils.d.ts +66 -0
- package/lib/utils/object-utils.js +21 -13
- package/lib/utils/object-utils.js.flow +77 -0
- package/lib/utils/property-priorities.d.ts +11 -0
- package/lib/utils/property-priorities.js +516 -101
- package/lib/utils/property-priorities.js.flow +10 -0
- package/lib/utils/split-css-value.d.ts +14 -0
- package/lib/utils/split-css-value.js +0 -14
- package/lib/utils/split-css-value.js.flow +15 -0
- package/lib/validate.d.ts +12 -0
- package/lib/validate.js +1 -10
- package/lib/validate.js.flow +12 -0
- package/package.json +4 -5
- package/lib/expand-shorthands.d.ts +0 -5
- package/lib/expand-shorthands.js +0 -330
- package/lib/namespace-transforms/__tests__/preflatten.test.js +0 -120
- package/lib/namespace-transforms/preflatten.js +0 -89
- package/lib/preprocess-rules/expand-shorthands.js +0 -156
- package/lib/preprocess-rules/null-out-longhand.js +0 -310
- package/lib/preprocess-rules/react-native-web.js +0 -142
- package/lib/stylex-defaultValue.js +0 -397
@@ -0,0 +1,91 @@
|
|
1
|
+
[
|
2
|
+
{
|
3
|
+
"syntax": "from-image | <angle> | [ <angle>? flip ]",
|
4
|
+
"media": "visual",
|
5
|
+
"inherited": true,
|
6
|
+
"animationType": "discrete",
|
7
|
+
"percentages": "no",
|
8
|
+
"groups": [
|
9
|
+
"CSS Images"
|
10
|
+
],
|
11
|
+
"initial": "from-image",
|
12
|
+
"appliesto": "allElements",
|
13
|
+
"computed": "angleRoundedToNextQuarter",
|
14
|
+
"order": "uniqueOrder",
|
15
|
+
"status": "standard",
|
16
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/image-orientation",
|
17
|
+
"property": "image-orientation",
|
18
|
+
"group": "CSS Images"
|
19
|
+
},
|
20
|
+
{
|
21
|
+
"syntax": "auto | crisp-edges | pixelated",
|
22
|
+
"media": "visual",
|
23
|
+
"inherited": true,
|
24
|
+
"animationType": "discrete",
|
25
|
+
"percentages": "no",
|
26
|
+
"groups": [
|
27
|
+
"CSS Images"
|
28
|
+
],
|
29
|
+
"initial": "auto",
|
30
|
+
"appliesto": "allElements",
|
31
|
+
"computed": "asSpecified",
|
32
|
+
"order": "uniqueOrder",
|
33
|
+
"status": "standard",
|
34
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/image-rendering",
|
35
|
+
"property": "image-rendering",
|
36
|
+
"group": "CSS Images"
|
37
|
+
},
|
38
|
+
{
|
39
|
+
"syntax": "[ from-image || <resolution> ] && snap?",
|
40
|
+
"media": "visual",
|
41
|
+
"inherited": true,
|
42
|
+
"animationType": "discrete",
|
43
|
+
"percentages": "no",
|
44
|
+
"groups": [
|
45
|
+
"CSS Images"
|
46
|
+
],
|
47
|
+
"initial": "1dppx",
|
48
|
+
"appliesto": "allElements",
|
49
|
+
"computed": "asSpecifiedWithExceptionOfResolution",
|
50
|
+
"order": "uniqueOrder",
|
51
|
+
"status": "experimental",
|
52
|
+
"property": "image-resolution",
|
53
|
+
"group": "CSS Images"
|
54
|
+
},
|
55
|
+
{
|
56
|
+
"syntax": "fill | contain | cover | none | scale-down",
|
57
|
+
"media": "visual",
|
58
|
+
"inherited": false,
|
59
|
+
"animationType": "discrete",
|
60
|
+
"percentages": "no",
|
61
|
+
"groups": [
|
62
|
+
"CSS Images"
|
63
|
+
],
|
64
|
+
"initial": "fill",
|
65
|
+
"appliesto": "replacedElements",
|
66
|
+
"computed": "asSpecified",
|
67
|
+
"order": "uniqueOrder",
|
68
|
+
"status": "standard",
|
69
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/object-fit",
|
70
|
+
"property": "object-fit",
|
71
|
+
"group": "CSS Images"
|
72
|
+
},
|
73
|
+
{
|
74
|
+
"syntax": "<position>",
|
75
|
+
"media": "visual",
|
76
|
+
"inherited": true,
|
77
|
+
"animationType": "repeatableList",
|
78
|
+
"percentages": "referToWidthAndHeightOfElement",
|
79
|
+
"groups": [
|
80
|
+
"CSS Images"
|
81
|
+
],
|
82
|
+
"initial": "50% 50%",
|
83
|
+
"appliesto": "replacedElements",
|
84
|
+
"computed": "asSpecified",
|
85
|
+
"order": "uniqueOrder",
|
86
|
+
"status": "standard",
|
87
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/object-position",
|
88
|
+
"property": "object-position",
|
89
|
+
"group": "CSS Images"
|
90
|
+
}
|
91
|
+
]
|
@@ -0,0 +1,38 @@
|
|
1
|
+
[
|
2
|
+
{
|
3
|
+
"syntax": "normal | [ <number> <integer>? ]",
|
4
|
+
"media": "visual",
|
5
|
+
"inherited": false,
|
6
|
+
"animationType": "byComputedValueType",
|
7
|
+
"percentages": "no",
|
8
|
+
"groups": [
|
9
|
+
"CSS Inline"
|
10
|
+
],
|
11
|
+
"initial": "normal",
|
12
|
+
"appliesto": "firstLetterPseudoElementsAndInlineLevelFirstChildren",
|
13
|
+
"computed": "asSpecified",
|
14
|
+
"order": "uniqueOrder",
|
15
|
+
"status": "experimental",
|
16
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/initial-letter",
|
17
|
+
"property": "initial-letter",
|
18
|
+
"group": "CSS Inline"
|
19
|
+
},
|
20
|
+
{
|
21
|
+
"syntax": "[ auto | alphabetic | hanging | ideographic ]",
|
22
|
+
"media": "visual",
|
23
|
+
"inherited": false,
|
24
|
+
"animationType": "discrete",
|
25
|
+
"percentages": "no",
|
26
|
+
"groups": [
|
27
|
+
"CSS Inline"
|
28
|
+
],
|
29
|
+
"initial": "auto",
|
30
|
+
"appliesto": "firstLetterPseudoElementsAndInlineLevelFirstChildren",
|
31
|
+
"computed": "asSpecified",
|
32
|
+
"order": "uniqueOrder",
|
33
|
+
"status": "experimental",
|
34
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/initial-letter-align",
|
35
|
+
"property": "initial-letter-align",
|
36
|
+
"group": "CSS Inline"
|
37
|
+
}
|
38
|
+
]
|
@@ -0,0 +1,86 @@
|
|
1
|
+
[
|
2
|
+
{
|
3
|
+
"syntax": "<'list-style-type'> || <'list-style-position'> || <'list-style-image'>",
|
4
|
+
"media": "visual",
|
5
|
+
"inherited": true,
|
6
|
+
"animationType": [
|
7
|
+
"list-style-image",
|
8
|
+
"list-style-position",
|
9
|
+
"list-style-type"
|
10
|
+
],
|
11
|
+
"percentages": "no",
|
12
|
+
"groups": [
|
13
|
+
"CSS Lists and Counters"
|
14
|
+
],
|
15
|
+
"initial": [
|
16
|
+
"list-style-type",
|
17
|
+
"list-style-position",
|
18
|
+
"list-style-image"
|
19
|
+
],
|
20
|
+
"appliesto": "listItems",
|
21
|
+
"computed": [
|
22
|
+
"list-style-image",
|
23
|
+
"list-style-position",
|
24
|
+
"list-style-type"
|
25
|
+
],
|
26
|
+
"order": "orderOfAppearance",
|
27
|
+
"status": "standard",
|
28
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/list-style",
|
29
|
+
"property": "list-style",
|
30
|
+
"group": "CSS Lists and Counters"
|
31
|
+
},
|
32
|
+
{
|
33
|
+
"syntax": "<image> | none",
|
34
|
+
"media": "visual",
|
35
|
+
"inherited": true,
|
36
|
+
"animationType": "discrete",
|
37
|
+
"percentages": "no",
|
38
|
+
"groups": [
|
39
|
+
"CSS Lists and Counters"
|
40
|
+
],
|
41
|
+
"initial": "none",
|
42
|
+
"appliesto": "listItems",
|
43
|
+
"computed": "theKeywordListStyleImageNoneOrComputedValue",
|
44
|
+
"order": "uniqueOrder",
|
45
|
+
"status": "standard",
|
46
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/list-style-image",
|
47
|
+
"property": "list-style-image",
|
48
|
+
"group": "CSS Lists and Counters"
|
49
|
+
},
|
50
|
+
{
|
51
|
+
"syntax": "inside | outside",
|
52
|
+
"media": "visual",
|
53
|
+
"inherited": true,
|
54
|
+
"animationType": "discrete",
|
55
|
+
"percentages": "no",
|
56
|
+
"groups": [
|
57
|
+
"CSS Lists and Counters"
|
58
|
+
],
|
59
|
+
"initial": "outside",
|
60
|
+
"appliesto": "listItems",
|
61
|
+
"computed": "asSpecified",
|
62
|
+
"order": "uniqueOrder",
|
63
|
+
"status": "standard",
|
64
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/list-style-position",
|
65
|
+
"property": "list-style-position",
|
66
|
+
"group": "CSS Lists and Counters"
|
67
|
+
},
|
68
|
+
{
|
69
|
+
"syntax": "<counter-style> | <string> | none",
|
70
|
+
"media": "visual",
|
71
|
+
"inherited": true,
|
72
|
+
"animationType": "discrete",
|
73
|
+
"percentages": "no",
|
74
|
+
"groups": [
|
75
|
+
"CSS Lists and Counters"
|
76
|
+
],
|
77
|
+
"initial": "disc",
|
78
|
+
"appliesto": "listItems",
|
79
|
+
"computed": "asSpecified",
|
80
|
+
"order": "uniqueOrder",
|
81
|
+
"status": "standard",
|
82
|
+
"mdn_url": "https://developer.mozilla.org/docs/Web/CSS/list-style-type",
|
83
|
+
"property": "list-style-type",
|
84
|
+
"group": "CSS Lists and Counters"
|
85
|
+
}
|
86
|
+
]
|