@stylix/core 3.1.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 +100 -0
- package/dist/Stylix.d.ts +3 -0
- package/dist/Stylix.js +66 -0
- package/dist/Stylix.js.map +1 -0
- package/dist/StylixProvider.d.ts +51 -0
- package/dist/StylixProvider.js +139 -0
- package/dist/StylixProvider.js.map +1 -0
- package/dist/applyRules.d.ts +5 -0
- package/dist/applyRules.js +31 -0
- package/dist/applyRules.js.map +1 -0
- package/dist/classifyProps.d.ts +7 -0
- package/dist/classifyProps.js +35 -0
- package/dist/classifyProps.js.map +1 -0
- package/dist/css-props.json +413 -0
- package/dist/html-tags.json +119 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.js +28 -0
- package/dist/index.js.map +1 -0
- package/dist/plugins/cleanStyles.d.ts +5 -0
- package/dist/plugins/cleanStyles.js +28 -0
- package/dist/plugins/cleanStyles.js.map +1 -0
- package/dist/plugins/customProps.d.ts +2 -0
- package/dist/plugins/customProps.js +61 -0
- package/dist/plugins/customProps.js.map +1 -0
- package/dist/plugins/defaultUnits.d.ts +7 -0
- package/dist/plugins/defaultUnits.js +41 -0
- package/dist/plugins/defaultUnits.js.map +1 -0
- package/dist/plugins/flattenNestedStyles.d.ts +5 -0
- package/dist/plugins/flattenNestedStyles.js +47 -0
- package/dist/plugins/flattenNestedStyles.js.map +1 -0
- package/dist/plugins/index.d.ts +30 -0
- package/dist/plugins/index.js +44 -0
- package/dist/plugins/index.js.map +1 -0
- package/dist/plugins/mediaArrays.d.ts +5 -0
- package/dist/plugins/mediaArrays.js +56 -0
- package/dist/plugins/mediaArrays.js.map +1 -0
- package/dist/plugins/merge$css.d.ts +6 -0
- package/dist/plugins/merge$css.js +45 -0
- package/dist/plugins/merge$css.js.map +1 -0
- package/dist/plugins/propCasing.d.ts +5 -0
- package/dist/plugins/propCasing.js +25 -0
- package/dist/plugins/propCasing.js.map +1 -0
- package/dist/plugins/replace$$class.d.ts +5 -0
- package/dist/plugins/replace$$class.js +20 -0
- package/dist/plugins/replace$$class.js.map +1 -0
- package/dist/plugins/themeFunctions.d.ts +5 -0
- package/dist/plugins/themeFunctions.js +20 -0
- package/dist/plugins/themeFunctions.js.map +1 -0
- package/dist/styleCollector.d.ts +8 -0
- package/dist/styleCollector.js +36 -0
- package/dist/styleCollector.js.map +1 -0
- package/dist/stylesToRuleArray.d.ts +5 -0
- package/dist/stylesToRuleArray.js +41 -0
- package/dist/stylesToRuleArray.js.map +1 -0
- package/dist/types.d.ts +76 -0
- package/dist/types.js +3 -0
- package/dist/types.js.map +1 -0
- package/dist/useStyles.d.ts +16 -0
- package/dist/useStyles.js +81 -0
- package/dist/useStyles.js.map +1 -0
- package/dist/util/cloneDeep.d.ts +4 -0
- package/dist/util/cloneDeep.js +28 -0
- package/dist/util/cloneDeep.js.map +1 -0
- package/dist/util/flatten.d.ts +4 -0
- package/dist/util/flatten.js +19 -0
- package/dist/util/flatten.js.map +1 -0
- package/dist/util/hashString.d.ts +4 -0
- package/dist/util/hashString.js +15 -0
- package/dist/util/hashString.js.map +1 -0
- package/dist/util/isPlainObject.d.ts +4 -0
- package/dist/util/isPlainObject.js +11 -0
- package/dist/util/isPlainObject.js.map +1 -0
- package/dist/util/mapObjectRecursive.d.ts +8 -0
- package/dist/util/mapObjectRecursive.js +48 -0
- package/dist/util/mapObjectRecursive.js.map +1 -0
- package/dist/util/merge.d.ts +5 -0
- package/dist/util/merge.js +31 -0
- package/dist/util/merge.js.map +1 -0
- package/dist/util/useIsoLayoutEffect.d.ts +3 -0
- package/dist/util/useIsoLayoutEffect.js +6 -0
- package/dist/util/useIsoLayoutEffect.js.map +1 -0
- package/dist/util/walkRecursive.d.ts +8 -0
- package/dist/util/walkRecursive.js +26 -0
- package/dist/util/walkRecursive.js.map +1 -0
- package/package.json +65 -0
|
@@ -0,0 +1,413 @@
|
|
|
1
|
+
[
|
|
2
|
+
"align-content",
|
|
3
|
+
"align-items",
|
|
4
|
+
"align-self",
|
|
5
|
+
"align-tracks",
|
|
6
|
+
"all",
|
|
7
|
+
"animation",
|
|
8
|
+
"animation-delay",
|
|
9
|
+
"animation-direction",
|
|
10
|
+
"animation-duration",
|
|
11
|
+
"animation-fill-mode",
|
|
12
|
+
"animation-iteration-count",
|
|
13
|
+
"animation-name",
|
|
14
|
+
"animation-play-state",
|
|
15
|
+
"animation-timing-function",
|
|
16
|
+
"appearance",
|
|
17
|
+
"aspect-ratio",
|
|
18
|
+
"azimuth",
|
|
19
|
+
"backdrop-filter",
|
|
20
|
+
"backface-visibility",
|
|
21
|
+
"background",
|
|
22
|
+
"background-attachment",
|
|
23
|
+
"background-blend-mode",
|
|
24
|
+
"background-clip",
|
|
25
|
+
"background-color",
|
|
26
|
+
"background-image",
|
|
27
|
+
"background-origin",
|
|
28
|
+
"background-position",
|
|
29
|
+
"background-position-x",
|
|
30
|
+
"background-position-y",
|
|
31
|
+
"background-repeat",
|
|
32
|
+
"background-size",
|
|
33
|
+
"block-overflow",
|
|
34
|
+
"block-size",
|
|
35
|
+
"border",
|
|
36
|
+
"border-block",
|
|
37
|
+
"border-block-color",
|
|
38
|
+
"border-block-style",
|
|
39
|
+
"border-block-width",
|
|
40
|
+
"border-block-end",
|
|
41
|
+
"border-block-end-color",
|
|
42
|
+
"border-block-end-style",
|
|
43
|
+
"border-block-end-width",
|
|
44
|
+
"border-block-start",
|
|
45
|
+
"border-block-start-color",
|
|
46
|
+
"border-block-start-style",
|
|
47
|
+
"border-block-start-width",
|
|
48
|
+
"border-bottom",
|
|
49
|
+
"border-bottom-color",
|
|
50
|
+
"border-bottom-left-radius",
|
|
51
|
+
"border-bottom-right-radius",
|
|
52
|
+
"border-bottom-style",
|
|
53
|
+
"border-bottom-width",
|
|
54
|
+
"border-collapse",
|
|
55
|
+
"border-color",
|
|
56
|
+
"border-end-end-radius",
|
|
57
|
+
"border-end-start-radius",
|
|
58
|
+
"border-image",
|
|
59
|
+
"border-image-outset",
|
|
60
|
+
"border-image-repeat",
|
|
61
|
+
"border-image-slice",
|
|
62
|
+
"border-image-source",
|
|
63
|
+
"border-image-width",
|
|
64
|
+
"border-inline",
|
|
65
|
+
"border-inline-end",
|
|
66
|
+
"border-inline-color",
|
|
67
|
+
"border-inline-style",
|
|
68
|
+
"border-inline-width",
|
|
69
|
+
"border-inline-end-color",
|
|
70
|
+
"border-inline-end-style",
|
|
71
|
+
"border-inline-end-width",
|
|
72
|
+
"border-inline-start",
|
|
73
|
+
"border-inline-start-color",
|
|
74
|
+
"border-inline-start-style",
|
|
75
|
+
"border-inline-start-width",
|
|
76
|
+
"border-left",
|
|
77
|
+
"border-left-color",
|
|
78
|
+
"border-left-style",
|
|
79
|
+
"border-left-width",
|
|
80
|
+
"border-radius",
|
|
81
|
+
"border-right",
|
|
82
|
+
"border-right-color",
|
|
83
|
+
"border-right-style",
|
|
84
|
+
"border-right-width",
|
|
85
|
+
"border-spacing",
|
|
86
|
+
"border-start-end-radius",
|
|
87
|
+
"border-start-start-radius",
|
|
88
|
+
"border-style",
|
|
89
|
+
"border-top",
|
|
90
|
+
"border-top-color",
|
|
91
|
+
"border-top-left-radius",
|
|
92
|
+
"border-top-right-radius",
|
|
93
|
+
"border-top-style",
|
|
94
|
+
"border-top-width",
|
|
95
|
+
"border-width",
|
|
96
|
+
"bottom",
|
|
97
|
+
"box-align",
|
|
98
|
+
"box-decoration-break",
|
|
99
|
+
"box-direction",
|
|
100
|
+
"box-flex",
|
|
101
|
+
"box-flex-group",
|
|
102
|
+
"box-lines",
|
|
103
|
+
"box-ordinal-group",
|
|
104
|
+
"box-orient",
|
|
105
|
+
"box-pack",
|
|
106
|
+
"box-shadow",
|
|
107
|
+
"box-sizing",
|
|
108
|
+
"break-after",
|
|
109
|
+
"break-before",
|
|
110
|
+
"break-inside",
|
|
111
|
+
"caption-side",
|
|
112
|
+
"caret-color",
|
|
113
|
+
"clear",
|
|
114
|
+
"clip",
|
|
115
|
+
"clip-path",
|
|
116
|
+
"color",
|
|
117
|
+
"color-adjust",
|
|
118
|
+
"color-scheme",
|
|
119
|
+
"column-count",
|
|
120
|
+
"column-fill",
|
|
121
|
+
"column-gap",
|
|
122
|
+
"column-rule",
|
|
123
|
+
"column-rule-color",
|
|
124
|
+
"column-rule-style",
|
|
125
|
+
"column-rule-width",
|
|
126
|
+
"column-span",
|
|
127
|
+
"column-width",
|
|
128
|
+
"columns",
|
|
129
|
+
"contain",
|
|
130
|
+
"content",
|
|
131
|
+
"content-visibility",
|
|
132
|
+
"counter-increment",
|
|
133
|
+
"counter-reset",
|
|
134
|
+
"counter-set",
|
|
135
|
+
"cursor",
|
|
136
|
+
"direction",
|
|
137
|
+
"display",
|
|
138
|
+
"empty-cells",
|
|
139
|
+
"filter",
|
|
140
|
+
"flex",
|
|
141
|
+
"flex-basis",
|
|
142
|
+
"flex-direction",
|
|
143
|
+
"flex-flow",
|
|
144
|
+
"flex-grow",
|
|
145
|
+
"flex-shrink",
|
|
146
|
+
"flex-wrap",
|
|
147
|
+
"float",
|
|
148
|
+
"font",
|
|
149
|
+
"font-family",
|
|
150
|
+
"font-feature-settings",
|
|
151
|
+
"font-kerning",
|
|
152
|
+
"font-language-override",
|
|
153
|
+
"font-optical-sizing",
|
|
154
|
+
"font-variation-settings",
|
|
155
|
+
"font-size",
|
|
156
|
+
"font-size-adjust",
|
|
157
|
+
"font-smooth",
|
|
158
|
+
"font-stretch",
|
|
159
|
+
"font-style",
|
|
160
|
+
"font-synthesis",
|
|
161
|
+
"font-variant",
|
|
162
|
+
"font-variant-alternates",
|
|
163
|
+
"font-variant-caps",
|
|
164
|
+
"font-variant-east-asian",
|
|
165
|
+
"font-variant-ligatures",
|
|
166
|
+
"font-variant-numeric",
|
|
167
|
+
"font-variant-position",
|
|
168
|
+
"font-weight",
|
|
169
|
+
"forced-color-adjust",
|
|
170
|
+
"gap",
|
|
171
|
+
"grid",
|
|
172
|
+
"grid-area",
|
|
173
|
+
"grid-auto-columns",
|
|
174
|
+
"grid-auto-flow",
|
|
175
|
+
"grid-auto-rows",
|
|
176
|
+
"grid-column",
|
|
177
|
+
"grid-column-end",
|
|
178
|
+
"grid-column-gap",
|
|
179
|
+
"grid-column-start",
|
|
180
|
+
"grid-gap",
|
|
181
|
+
"grid-row",
|
|
182
|
+
"grid-row-end",
|
|
183
|
+
"grid-row-gap",
|
|
184
|
+
"grid-row-start",
|
|
185
|
+
"grid-template",
|
|
186
|
+
"grid-template-areas",
|
|
187
|
+
"grid-template-columns",
|
|
188
|
+
"grid-template-rows",
|
|
189
|
+
"hanging-punctuation",
|
|
190
|
+
"height",
|
|
191
|
+
"hyphens",
|
|
192
|
+
"image-orientation",
|
|
193
|
+
"image-rendering",
|
|
194
|
+
"image-resolution",
|
|
195
|
+
"ime-mode",
|
|
196
|
+
"initial-letter",
|
|
197
|
+
"initial-letter-align",
|
|
198
|
+
"inline-size",
|
|
199
|
+
"inset",
|
|
200
|
+
"inset-block",
|
|
201
|
+
"inset-block-end",
|
|
202
|
+
"inset-block-start",
|
|
203
|
+
"inset-inline",
|
|
204
|
+
"inset-inline-end",
|
|
205
|
+
"inset-inline-start",
|
|
206
|
+
"isolation",
|
|
207
|
+
"justify-content",
|
|
208
|
+
"justify-items",
|
|
209
|
+
"justify-self",
|
|
210
|
+
"justify-tracks",
|
|
211
|
+
"left",
|
|
212
|
+
"letter-spacing",
|
|
213
|
+
"line-break",
|
|
214
|
+
"line-clamp",
|
|
215
|
+
"line-height",
|
|
216
|
+
"line-height-step",
|
|
217
|
+
"list-style",
|
|
218
|
+
"list-style-image",
|
|
219
|
+
"list-style-position",
|
|
220
|
+
"list-style-type",
|
|
221
|
+
"margin",
|
|
222
|
+
"margin-block",
|
|
223
|
+
"margin-block-end",
|
|
224
|
+
"margin-block-start",
|
|
225
|
+
"margin-bottom",
|
|
226
|
+
"margin-inline",
|
|
227
|
+
"margin-inline-end",
|
|
228
|
+
"margin-inline-start",
|
|
229
|
+
"margin-left",
|
|
230
|
+
"margin-right",
|
|
231
|
+
"margin-top",
|
|
232
|
+
"margin-trim",
|
|
233
|
+
"mask",
|
|
234
|
+
"mask-border",
|
|
235
|
+
"mask-border-mode",
|
|
236
|
+
"mask-border-outset",
|
|
237
|
+
"mask-border-repeat",
|
|
238
|
+
"mask-border-slice",
|
|
239
|
+
"mask-border-source",
|
|
240
|
+
"mask-border-width",
|
|
241
|
+
"mask-clip",
|
|
242
|
+
"mask-composite",
|
|
243
|
+
"mask-image",
|
|
244
|
+
"mask-mode",
|
|
245
|
+
"mask-origin",
|
|
246
|
+
"mask-position",
|
|
247
|
+
"mask-repeat",
|
|
248
|
+
"mask-size",
|
|
249
|
+
"mask-type",
|
|
250
|
+
"masonry-auto-flow",
|
|
251
|
+
"math-style",
|
|
252
|
+
"max-block-size",
|
|
253
|
+
"max-height",
|
|
254
|
+
"max-inline-size",
|
|
255
|
+
"max-lines",
|
|
256
|
+
"max-width",
|
|
257
|
+
"min-block-size",
|
|
258
|
+
"min-height",
|
|
259
|
+
"min-inline-size",
|
|
260
|
+
"min-width",
|
|
261
|
+
"mix-blend-mode",
|
|
262
|
+
"object-fit",
|
|
263
|
+
"object-position",
|
|
264
|
+
"offset",
|
|
265
|
+
"offset-anchor",
|
|
266
|
+
"offset-distance",
|
|
267
|
+
"offset-path",
|
|
268
|
+
"offset-position",
|
|
269
|
+
"offset-rotate",
|
|
270
|
+
"opacity",
|
|
271
|
+
"order",
|
|
272
|
+
"orphans",
|
|
273
|
+
"outline",
|
|
274
|
+
"outline-color",
|
|
275
|
+
"outline-offset",
|
|
276
|
+
"outline-style",
|
|
277
|
+
"outline-width",
|
|
278
|
+
"overflow",
|
|
279
|
+
"overflow-anchor",
|
|
280
|
+
"overflow-block",
|
|
281
|
+
"overflow-clip-box",
|
|
282
|
+
"overflow-clip-margin",
|
|
283
|
+
"overflow-inline",
|
|
284
|
+
"overflow-wrap",
|
|
285
|
+
"overflow-x",
|
|
286
|
+
"overflow-y",
|
|
287
|
+
"overscroll-behavior",
|
|
288
|
+
"overscroll-behavior-block",
|
|
289
|
+
"overscroll-behavior-inline",
|
|
290
|
+
"overscroll-behavior-x",
|
|
291
|
+
"overscroll-behavior-y",
|
|
292
|
+
"padding",
|
|
293
|
+
"padding-block",
|
|
294
|
+
"padding-block-end",
|
|
295
|
+
"padding-block-start",
|
|
296
|
+
"padding-bottom",
|
|
297
|
+
"padding-inline",
|
|
298
|
+
"padding-inline-end",
|
|
299
|
+
"padding-inline-start",
|
|
300
|
+
"padding-left",
|
|
301
|
+
"padding-right",
|
|
302
|
+
"padding-top",
|
|
303
|
+
"page-break-after",
|
|
304
|
+
"page-break-before",
|
|
305
|
+
"page-break-inside",
|
|
306
|
+
"paint-order",
|
|
307
|
+
"perspective",
|
|
308
|
+
"perspective-origin",
|
|
309
|
+
"place-content",
|
|
310
|
+
"place-items",
|
|
311
|
+
"place-self",
|
|
312
|
+
"pointer-events",
|
|
313
|
+
"position",
|
|
314
|
+
"quotes",
|
|
315
|
+
"resize",
|
|
316
|
+
"right",
|
|
317
|
+
"rotate",
|
|
318
|
+
"row-gap",
|
|
319
|
+
"ruby-align",
|
|
320
|
+
"ruby-merge",
|
|
321
|
+
"ruby-position",
|
|
322
|
+
"scale",
|
|
323
|
+
"scrollbar-color",
|
|
324
|
+
"scrollbar-gutter",
|
|
325
|
+
"scrollbar-width",
|
|
326
|
+
"scroll-behavior",
|
|
327
|
+
"scroll-margin",
|
|
328
|
+
"scroll-margin-block",
|
|
329
|
+
"scroll-margin-block-start",
|
|
330
|
+
"scroll-margin-block-end",
|
|
331
|
+
"scroll-margin-bottom",
|
|
332
|
+
"scroll-margin-inline",
|
|
333
|
+
"scroll-margin-inline-start",
|
|
334
|
+
"scroll-margin-inline-end",
|
|
335
|
+
"scroll-margin-left",
|
|
336
|
+
"scroll-margin-right",
|
|
337
|
+
"scroll-margin-top",
|
|
338
|
+
"scroll-padding",
|
|
339
|
+
"scroll-padding-block",
|
|
340
|
+
"scroll-padding-block-start",
|
|
341
|
+
"scroll-padding-block-end",
|
|
342
|
+
"scroll-padding-bottom",
|
|
343
|
+
"scroll-padding-inline",
|
|
344
|
+
"scroll-padding-inline-start",
|
|
345
|
+
"scroll-padding-inline-end",
|
|
346
|
+
"scroll-padding-left",
|
|
347
|
+
"scroll-padding-right",
|
|
348
|
+
"scroll-padding-top",
|
|
349
|
+
"scroll-snap-align",
|
|
350
|
+
"scroll-snap-coordinate",
|
|
351
|
+
"scroll-snap-destination",
|
|
352
|
+
"scroll-snap-points-x",
|
|
353
|
+
"scroll-snap-points-y",
|
|
354
|
+
"scroll-snap-stop",
|
|
355
|
+
"scroll-snap-type",
|
|
356
|
+
"scroll-snap-type-x",
|
|
357
|
+
"scroll-snap-type-y",
|
|
358
|
+
"shape-image-threshold",
|
|
359
|
+
"shape-margin",
|
|
360
|
+
"shape-outside",
|
|
361
|
+
"tab-size",
|
|
362
|
+
"table-layout",
|
|
363
|
+
"text-align",
|
|
364
|
+
"text-align-last",
|
|
365
|
+
"text-combine-upright",
|
|
366
|
+
"text-decoration",
|
|
367
|
+
"text-decoration-color",
|
|
368
|
+
"text-decoration-line",
|
|
369
|
+
"text-decoration-skip",
|
|
370
|
+
"text-decoration-skip-ink",
|
|
371
|
+
"text-decoration-style",
|
|
372
|
+
"text-decoration-thickness",
|
|
373
|
+
"text-emphasis",
|
|
374
|
+
"text-emphasis-color",
|
|
375
|
+
"text-emphasis-position",
|
|
376
|
+
"text-emphasis-style",
|
|
377
|
+
"text-indent",
|
|
378
|
+
"text-justify",
|
|
379
|
+
"text-orientation",
|
|
380
|
+
"text-overflow",
|
|
381
|
+
"text-rendering",
|
|
382
|
+
"text-shadow",
|
|
383
|
+
"text-size-adjust",
|
|
384
|
+
"text-transform",
|
|
385
|
+
"text-underline-offset",
|
|
386
|
+
"text-underline-position",
|
|
387
|
+
"top",
|
|
388
|
+
"touch-action",
|
|
389
|
+
"transform",
|
|
390
|
+
"transform-box",
|
|
391
|
+
"transform-origin",
|
|
392
|
+
"transform-style",
|
|
393
|
+
"transition",
|
|
394
|
+
"transition-delay",
|
|
395
|
+
"transition-duration",
|
|
396
|
+
"transition-property",
|
|
397
|
+
"transition-timing-function",
|
|
398
|
+
"translate",
|
|
399
|
+
"unicode-bidi",
|
|
400
|
+
"user-select",
|
|
401
|
+
"vertical-align",
|
|
402
|
+
"visibility",
|
|
403
|
+
"white-space",
|
|
404
|
+
"widows",
|
|
405
|
+
"width",
|
|
406
|
+
"will-change",
|
|
407
|
+
"word-break",
|
|
408
|
+
"word-spacing",
|
|
409
|
+
"word-wrap",
|
|
410
|
+
"writing-mode",
|
|
411
|
+
"z-index",
|
|
412
|
+
"zoom"
|
|
413
|
+
]
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
[
|
|
2
|
+
"a",
|
|
3
|
+
"abbr",
|
|
4
|
+
"address",
|
|
5
|
+
"area",
|
|
6
|
+
"article",
|
|
7
|
+
"aside",
|
|
8
|
+
"audio",
|
|
9
|
+
"b",
|
|
10
|
+
"base",
|
|
11
|
+
"bdi",
|
|
12
|
+
"bdo",
|
|
13
|
+
"blockquote",
|
|
14
|
+
"body",
|
|
15
|
+
"br",
|
|
16
|
+
"button",
|
|
17
|
+
"canvas",
|
|
18
|
+
"caption",
|
|
19
|
+
"cite",
|
|
20
|
+
"code",
|
|
21
|
+
"col",
|
|
22
|
+
"colgroup",
|
|
23
|
+
"data",
|
|
24
|
+
"datalist",
|
|
25
|
+
"dd",
|
|
26
|
+
"del",
|
|
27
|
+
"details",
|
|
28
|
+
"dfn",
|
|
29
|
+
"dialog",
|
|
30
|
+
"div",
|
|
31
|
+
"dl",
|
|
32
|
+
"dt",
|
|
33
|
+
"em",
|
|
34
|
+
"embed",
|
|
35
|
+
"fieldset",
|
|
36
|
+
"figcaption",
|
|
37
|
+
"figure",
|
|
38
|
+
"footer",
|
|
39
|
+
"form",
|
|
40
|
+
"h1",
|
|
41
|
+
"h2",
|
|
42
|
+
"h3",
|
|
43
|
+
"h4",
|
|
44
|
+
"h5",
|
|
45
|
+
"h6",
|
|
46
|
+
"head",
|
|
47
|
+
"header",
|
|
48
|
+
"hgroup",
|
|
49
|
+
"hr",
|
|
50
|
+
"html",
|
|
51
|
+
"i",
|
|
52
|
+
"iframe",
|
|
53
|
+
"img",
|
|
54
|
+
"input",
|
|
55
|
+
"ins",
|
|
56
|
+
"kbd",
|
|
57
|
+
"label",
|
|
58
|
+
"legend",
|
|
59
|
+
"li",
|
|
60
|
+
"link",
|
|
61
|
+
"main",
|
|
62
|
+
"map",
|
|
63
|
+
"mark",
|
|
64
|
+
"math",
|
|
65
|
+
"menu",
|
|
66
|
+
"menuitem",
|
|
67
|
+
"meta",
|
|
68
|
+
"meter",
|
|
69
|
+
"nav",
|
|
70
|
+
"noscript",
|
|
71
|
+
"object",
|
|
72
|
+
"ol",
|
|
73
|
+
"optgroup",
|
|
74
|
+
"option",
|
|
75
|
+
"output",
|
|
76
|
+
"p",
|
|
77
|
+
"param",
|
|
78
|
+
"picture",
|
|
79
|
+
"pre",
|
|
80
|
+
"progress",
|
|
81
|
+
"q",
|
|
82
|
+
"rb",
|
|
83
|
+
"rp",
|
|
84
|
+
"rt",
|
|
85
|
+
"rtc",
|
|
86
|
+
"ruby",
|
|
87
|
+
"s",
|
|
88
|
+
"samp",
|
|
89
|
+
"script",
|
|
90
|
+
"section",
|
|
91
|
+
"select",
|
|
92
|
+
"slot",
|
|
93
|
+
"small",
|
|
94
|
+
"source",
|
|
95
|
+
"span",
|
|
96
|
+
"strong",
|
|
97
|
+
"style",
|
|
98
|
+
"sub",
|
|
99
|
+
"summary",
|
|
100
|
+
"sup",
|
|
101
|
+
"svg",
|
|
102
|
+
"table",
|
|
103
|
+
"tbody",
|
|
104
|
+
"td",
|
|
105
|
+
"template",
|
|
106
|
+
"textarea",
|
|
107
|
+
"tfoot",
|
|
108
|
+
"th",
|
|
109
|
+
"thead",
|
|
110
|
+
"time",
|
|
111
|
+
"title",
|
|
112
|
+
"tr",
|
|
113
|
+
"track",
|
|
114
|
+
"u",
|
|
115
|
+
"ul",
|
|
116
|
+
"var",
|
|
117
|
+
"video",
|
|
118
|
+
"wbr"
|
|
119
|
+
]
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export { StylixProps, StylixPropsExtensions } from './types';
|
|
2
|
+
export { useStylixContext, useStylixTheme, StylixProvider, StylixPublicContext as StylixContext, StylixTheme, } from './StylixProvider';
|
|
3
|
+
export { useStyles, useKeyframes, useGlobalStyles } from './useStyles';
|
|
4
|
+
export { defaultPlugins, customProps, StylixPlugin, StylixPluginFunctionContext } from './plugins';
|
|
5
|
+
export { mapObjectRecursive } from './util/mapObjectRecursive';
|
|
6
|
+
export { walkRecursive } from './util/walkRecursive';
|
|
7
|
+
export { createStyleCollector, styleCollectorContext, StyleCollector } from './styleCollector';
|
|
8
|
+
export { default } from './Stylix';
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.default = exports.styleCollectorContext = exports.createStyleCollector = exports.walkRecursive = exports.mapObjectRecursive = exports.customProps = exports.defaultPlugins = exports.useGlobalStyles = exports.useKeyframes = exports.useStyles = exports.StylixTheme = exports.StylixProvider = exports.useStylixTheme = exports.useStylixContext = void 0;
|
|
7
|
+
var StylixProvider_1 = require("./StylixProvider");
|
|
8
|
+
Object.defineProperty(exports, "useStylixContext", { enumerable: true, get: function () { return StylixProvider_1.useStylixContext; } });
|
|
9
|
+
Object.defineProperty(exports, "useStylixTheme", { enumerable: true, get: function () { return StylixProvider_1.useStylixTheme; } });
|
|
10
|
+
Object.defineProperty(exports, "StylixProvider", { enumerable: true, get: function () { return StylixProvider_1.StylixProvider; } });
|
|
11
|
+
Object.defineProperty(exports, "StylixTheme", { enumerable: true, get: function () { return StylixProvider_1.StylixTheme; } });
|
|
12
|
+
var useStyles_1 = require("./useStyles");
|
|
13
|
+
Object.defineProperty(exports, "useStyles", { enumerable: true, get: function () { return useStyles_1.useStyles; } });
|
|
14
|
+
Object.defineProperty(exports, "useKeyframes", { enumerable: true, get: function () { return useStyles_1.useKeyframes; } });
|
|
15
|
+
Object.defineProperty(exports, "useGlobalStyles", { enumerable: true, get: function () { return useStyles_1.useGlobalStyles; } });
|
|
16
|
+
var plugins_1 = require("./plugins");
|
|
17
|
+
Object.defineProperty(exports, "defaultPlugins", { enumerable: true, get: function () { return plugins_1.defaultPlugins; } });
|
|
18
|
+
Object.defineProperty(exports, "customProps", { enumerable: true, get: function () { return plugins_1.customProps; } });
|
|
19
|
+
var mapObjectRecursive_1 = require("./util/mapObjectRecursive");
|
|
20
|
+
Object.defineProperty(exports, "mapObjectRecursive", { enumerable: true, get: function () { return mapObjectRecursive_1.mapObjectRecursive; } });
|
|
21
|
+
var walkRecursive_1 = require("./util/walkRecursive");
|
|
22
|
+
Object.defineProperty(exports, "walkRecursive", { enumerable: true, get: function () { return walkRecursive_1.walkRecursive; } });
|
|
23
|
+
var styleCollector_1 = require("./styleCollector");
|
|
24
|
+
Object.defineProperty(exports, "createStyleCollector", { enumerable: true, get: function () { return styleCollector_1.createStyleCollector; } });
|
|
25
|
+
Object.defineProperty(exports, "styleCollectorContext", { enumerable: true, get: function () { return styleCollector_1.styleCollectorContext; } });
|
|
26
|
+
var Stylix_1 = require("./Stylix");
|
|
27
|
+
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(Stylix_1).default; } });
|
|
28
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":";;;;;;AACA,mDAM0B;AALxB,kHAAA,gBAAgB,OAAA;AAChB,gHAAA,cAAc,OAAA;AACd,gHAAA,cAAc,OAAA;AAEd,6GAAA,WAAW,OAAA;AAEb,yCAAuE;AAA9D,sGAAA,SAAS,OAAA;AAAE,yGAAA,YAAY,OAAA;AAAE,4GAAA,eAAe,OAAA;AACjD,qCAAmG;AAA1F,yGAAA,cAAc,OAAA;AAAE,sGAAA,WAAW,OAAA;AACpC,gEAA+D;AAAtD,wHAAA,kBAAkB,OAAA;AAC3B,sDAAqD;AAA5C,8GAAA,aAAa,OAAA;AACtB,mDAA+F;AAAtF,sHAAA,oBAAoB,OAAA;AAAE,uHAAA,qBAAqB,OAAA;AACpD,mCAAmC;AAA1B,kHAAA,OAAO,OAAA"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.cleanStyles = void 0;
|
|
4
|
+
const isPlainObject_1 = require("../util/isPlainObject");
|
|
5
|
+
function cleanObject(object) {
|
|
6
|
+
for (const key in object) {
|
|
7
|
+
const value = object[key];
|
|
8
|
+
if (value === null || value === undefined || value === '')
|
|
9
|
+
delete object[key];
|
|
10
|
+
else if (isPlainObject_1.isPlainObject(value) || Array.isArray(value)) {
|
|
11
|
+
cleanObject(value);
|
|
12
|
+
if (!Object.keys(value).length)
|
|
13
|
+
delete object[key];
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
return object;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Fixes casing and hyphenation on known style props
|
|
20
|
+
*/
|
|
21
|
+
exports.cleanStyles = {
|
|
22
|
+
name: 'cleanStyles',
|
|
23
|
+
type: 'processStyles',
|
|
24
|
+
plugin(ctx, styles) {
|
|
25
|
+
return cleanObject(styles);
|
|
26
|
+
},
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=cleanStyles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cleanStyles.js","sourceRoot":"","sources":["../../src/plugins/cleanStyles.ts"],"names":[],"mappings":";;;AAAA,yDAAsD;AAGtD,SAAS,WAAW,CAAC,MAAW;IAC9B,KAAK,MAAM,GAAG,IAAI,MAAM,EAAE;QACxB,MAAM,KAAK,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;QAC1B,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,EAAE;YAAE,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;aACzE,IAAI,6BAAa,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE;YACrD,WAAW,CAAC,KAAK,CAAC,CAAC;YACnB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM;gBAAE,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;SACpD;KACF;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAED;;GAEG;AACU,QAAA,WAAW,GAAiB;IACvC,IAAI,EAAE,aAAa;IACnB,IAAI,EAAE,eAAe;IACrB,MAAM,CAAC,GAAgC,EAAE,MAAW;QAClD,OAAO,WAAW,CAAC,MAAM,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.customProps = void 0;
|
|
4
|
+
const classifyProps_1 = require("../classifyProps");
|
|
5
|
+
const isPlainObject_1 = require("../util/isPlainObject");
|
|
6
|
+
const walkRecursive_1 = require("../util/walkRecursive");
|
|
7
|
+
const mediaArrays_1 = require("./mediaArrays");
|
|
8
|
+
const customProps = (customProps) => {
|
|
9
|
+
for (const key in customProps) {
|
|
10
|
+
customProps[classifyProps_1.simplifyStylePropName(key)] = customProps[key];
|
|
11
|
+
}
|
|
12
|
+
return [
|
|
13
|
+
{
|
|
14
|
+
name: 'customPropsInit',
|
|
15
|
+
type: 'initialize',
|
|
16
|
+
plugin(ctx) {
|
|
17
|
+
for (const key in customProps) {
|
|
18
|
+
ctx.styleProps[classifyProps_1.simplifyStylePropName(key)] = key;
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
name: 'customPropsProcess',
|
|
24
|
+
type: 'processStyles',
|
|
25
|
+
before: mediaArrays_1.mediaArrays,
|
|
26
|
+
plugin(ctx, styles) {
|
|
27
|
+
return walkRecursive_1.walkRecursive(styles, (key, value, object) => {
|
|
28
|
+
if (!classifyProps_1.isValidJSXProp(key) || isPlainObject_1.isPlainObject(value))
|
|
29
|
+
return;
|
|
30
|
+
const simpleKey = classifyProps_1.simplifyStylePropName(key);
|
|
31
|
+
const propValue = customProps[simpleKey];
|
|
32
|
+
if (!propValue)
|
|
33
|
+
return;
|
|
34
|
+
const objectClone = Object.assign({}, object);
|
|
35
|
+
const keys = Object.keys(object);
|
|
36
|
+
const afterKeys = keys.slice(keys.indexOf(key) + 1);
|
|
37
|
+
const newStyles = {};
|
|
38
|
+
if (typeof propValue === 'object') {
|
|
39
|
+
if (value)
|
|
40
|
+
Object.assign(newStyles, propValue);
|
|
41
|
+
}
|
|
42
|
+
else if (typeof propValue === 'string') {
|
|
43
|
+
newStyles[propValue] = value;
|
|
44
|
+
}
|
|
45
|
+
else if (typeof propValue === 'function') {
|
|
46
|
+
Object.assign(newStyles, propValue(value));
|
|
47
|
+
}
|
|
48
|
+
delete object[key];
|
|
49
|
+
Object.assign(object, newStyles);
|
|
50
|
+
for (const k of afterKeys) {
|
|
51
|
+
const val = objectClone[k];
|
|
52
|
+
delete object[k];
|
|
53
|
+
object[k] = val;
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
];
|
|
59
|
+
};
|
|
60
|
+
exports.customProps = customProps;
|
|
61
|
+
//# sourceMappingURL=customProps.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customProps.js","sourceRoot":"","sources":["../../src/plugins/customProps.ts"],"names":[],"mappings":";;;AAAA,oDAAyE;AACzE,yDAAsD;AACtD,yDAAsD;AAEtD,+CAA4C;AAErC,MAAM,WAAW,GAAG,CAAC,WAAgC,EAAkB,EAAE;IAC9E,KAAK,MAAM,GAAG,IAAI,WAAW,EAAE;QAC7B,WAAW,CAAC,qCAAqB,CAAC,GAAG,CAAC,CAAC,GAAG,WAAW,CAAC,GAAG,CAAC,CAAC;KAC5D;IAED,OAAO;QACL;YACE,IAAI,EAAE,iBAAiB;YACvB,IAAI,EAAE,YAAY;YAClB,MAAM,CAAC,GAAgC;gBACrC,KAAK,MAAM,GAAG,IAAI,WAAW,EAAE;oBAC7B,GAAG,CAAC,UAAU,CAAC,qCAAqB,CAAC,GAAG,CAAC,CAAC,GAAG,GAAG,CAAC;iBAClD;YACH,CAAC;SACF;QACD;YACE,IAAI,EAAE,oBAAoB;YAC1B,IAAI,EAAE,eAAe;YACrB,MAAM,EAAE,yBAAW;YACnB,MAAM,CAAC,GAAgC,EAAE,MAAW;gBAClD,OAAO,6BAAa,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;oBAClD,IAAI,CAAC,8BAAc,CAAC,GAAG,CAAC,IAAI,6BAAa,CAAC,KAAK,CAAC;wBAAE,OAAO;oBAEzD,MAAM,SAAS,GAAG,qCAAqB,CAAC,GAAG,CAAC,CAAC;oBAC7C,MAAM,SAAS,GAAG,WAAW,CAAC,SAAS,CAAC,CAAC;oBACzC,IAAI,CAAC,SAAS;wBAAE,OAAO;oBAEvB,MAAM,WAAW,qBAAQ,MAAM,CAAE,CAAC;oBAClC,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;oBACjC,MAAM,SAAS,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,CAAC;oBAEpD,MAAM,SAAS,GAAG,EAAE,CAAC;oBACrB,IAAI,OAAO,SAAS,KAAK,QAAQ,EAAE;wBACjC,IAAI,KAAK;4BAAE,MAAM,CAAC,MAAM,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;qBAChD;yBAAM,IAAI,OAAO,SAAS,KAAK,QAAQ,EAAE;wBACxC,SAAS,CAAC,SAAS,CAAC,GAAG,KAAK,CAAC;qBAC9B;yBAAM,IAAI,OAAO,SAAS,KAAK,UAAU,EAAE;wBAC1C,MAAM,CAAC,MAAM,CAAC,SAAS,EAAE,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;qBAC5C;oBACD,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;oBACnB,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;oBACjC,KAAK,MAAM,CAAC,IAAI,SAAS,EAAE;wBACzB,MAAM,GAAG,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC;wBAC3B,OAAO,MAAM,CAAC,CAAC,CAAC,CAAC;wBACjB,MAAM,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC;qBACjB;gBACH,CAAC,CAAC,CAAC;YACL,CAAC;SACF;KACF,CAAC;AACJ,CAAC,CAAC;AAlDW,QAAA,WAAW,eAkDtB"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { StylixPlugin } from './index';
|
|
2
|
+
export declare const defaultIgnoreUnits: string[];
|
|
3
|
+
/**
|
|
4
|
+
* Adds unit (px, em, etc) to numeric values for any style properties not included in `ignoreProps`..
|
|
5
|
+
*/
|
|
6
|
+
export declare const defaultUnits: (unit?: string, ignoreProps?: string[]) => StylixPlugin;
|
|
7
|
+
export declare const defaultPixelUnits: StylixPlugin;
|