@animus-ui/system 0.1.0-next.1

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.
Files changed (46) hide show
  1. package/dist/Animus.d.ts +75 -0
  2. package/dist/Animus.d.ts.map +1 -0
  3. package/dist/AnimusExtended.d.ts +69 -0
  4. package/dist/AnimusExtended.d.ts.map +1 -0
  5. package/dist/PropertyBuilder.d.ts +11 -0
  6. package/dist/PropertyBuilder.d.ts.map +1 -0
  7. package/dist/SystemBuilder.d.ts +46 -0
  8. package/dist/SystemBuilder.d.ts.map +1 -0
  9. package/dist/groups/index.d.ts +630 -0
  10. package/dist/groups/index.d.ts.map +1 -0
  11. package/dist/groups/index.js +474 -0
  12. package/dist/index.d.ts +17 -0
  13. package/dist/index.d.ts.map +1 -0
  14. package/dist/index.js +295 -0
  15. package/dist/scales/createScale.d.ts +7 -0
  16. package/dist/scales/createScale.d.ts.map +1 -0
  17. package/dist/size-Dge_rsuz.js +70 -0
  18. package/dist/transforms/border.d.ts +2 -0
  19. package/dist/transforms/border.d.ts.map +1 -0
  20. package/dist/transforms/createTransform.d.ts +6 -0
  21. package/dist/transforms/createTransform.d.ts.map +1 -0
  22. package/dist/transforms/grid.d.ts +5 -0
  23. package/dist/transforms/grid.d.ts.map +1 -0
  24. package/dist/transforms/index.d.ts +6 -0
  25. package/dist/transforms/index.d.ts.map +1 -0
  26. package/dist/transforms/size.d.ts +3 -0
  27. package/dist/transforms/size.d.ts.map +1 -0
  28. package/dist/transforms/utils.d.ts +3 -0
  29. package/dist/transforms/utils.d.ts.map +1 -0
  30. package/dist/types/component.d.ts +55 -0
  31. package/dist/types/component.d.ts.map +1 -0
  32. package/dist/types/config.d.ts +78 -0
  33. package/dist/types/config.d.ts.map +1 -0
  34. package/dist/types/properties.d.ts +19 -0
  35. package/dist/types/properties.d.ts.map +1 -0
  36. package/dist/types/props.d.ts +35 -0
  37. package/dist/types/props.d.ts.map +1 -0
  38. package/dist/types/scales.d.ts +3 -0
  39. package/dist/types/scales.d.ts.map +1 -0
  40. package/dist/types/shared.d.ts +5 -0
  41. package/dist/types/shared.d.ts.map +1 -0
  42. package/dist/types/theme.d.ts +32 -0
  43. package/dist/types/theme.d.ts.map +1 -0
  44. package/dist/types/utils.d.ts +5 -0
  45. package/dist/types/utils.d.ts.map +1 -0
  46. package/package.json +46 -0
@@ -0,0 +1,474 @@
1
+ import { a as borderShorthand, i as gridItemRatio, n as size, r as gridItem, s as createScale } from "../size-Dge_rsuz.js";
2
+ //#region src/groups/index.ts
3
+ const color = {
4
+ color: {
5
+ property: "color",
6
+ scale: "colors"
7
+ },
8
+ bg: {
9
+ property: "backgroundColor",
10
+ scale: "colors"
11
+ },
12
+ gradient: {
13
+ property: "backgroundImage",
14
+ scale: "gradients"
15
+ },
16
+ borderColor: {
17
+ property: "borderColor",
18
+ scale: "colors"
19
+ },
20
+ borderColorX: {
21
+ property: "borderColor",
22
+ properties: ["borderLeftColor", "borderRightColor"],
23
+ scale: "colors"
24
+ },
25
+ borderColorY: {
26
+ property: "borderColor",
27
+ properties: ["borderTopColor", "borderBottomColor"],
28
+ scale: "colors"
29
+ },
30
+ borderColorLeft: {
31
+ property: "borderLeftColor",
32
+ scale: "colors"
33
+ },
34
+ borderColorRight: {
35
+ property: "borderRightColor",
36
+ scale: "colors"
37
+ },
38
+ borderColorTop: {
39
+ property: "borderTopColor",
40
+ scale: "colors"
41
+ },
42
+ borderColorBottom: {
43
+ property: "borderBottomColor",
44
+ scale: "colors"
45
+ },
46
+ fill: {
47
+ property: "fill",
48
+ scale: "colors"
49
+ },
50
+ stroke: {
51
+ property: "stroke",
52
+ scale: "colors"
53
+ }
54
+ };
55
+ const border = {
56
+ border: {
57
+ property: "border",
58
+ scale: "borders",
59
+ transform: borderShorthand
60
+ },
61
+ borderX: {
62
+ property: "border",
63
+ properties: ["borderLeft", "borderRight"],
64
+ scale: "borders",
65
+ transform: borderShorthand
66
+ },
67
+ borderY: {
68
+ property: "border",
69
+ properties: ["borderTop", "borderBottom"],
70
+ scale: "borders",
71
+ transform: borderShorthand
72
+ },
73
+ borderTop: {
74
+ property: "borderTop",
75
+ scale: "borders",
76
+ transform: borderShorthand
77
+ },
78
+ borderRight: {
79
+ property: "borderRight",
80
+ scale: "borders",
81
+ transform: borderShorthand
82
+ },
83
+ borderBottom: {
84
+ property: "borderBottom",
85
+ scale: "borders",
86
+ transform: borderShorthand
87
+ },
88
+ borderLeft: {
89
+ property: "borderLeft",
90
+ scale: "borders",
91
+ transform: borderShorthand
92
+ },
93
+ borderWidth: {
94
+ property: "borderWidth",
95
+ scale: "borderWidths"
96
+ },
97
+ borderWidthX: {
98
+ property: "borderWidth",
99
+ properties: ["borderLeftWidth", "borderRightWidth"],
100
+ scale: "borderWidths"
101
+ },
102
+ borderWidthY: {
103
+ property: "borderWidth",
104
+ properties: ["borderTopWidth", "borderBottomWidth"],
105
+ scale: "borderWidths"
106
+ },
107
+ borderWidthLeft: {
108
+ property: "borderLeftWidth",
109
+ scale: "borderWidths"
110
+ },
111
+ borderWidthRight: {
112
+ property: "borderRightWidth",
113
+ scale: "borderWidths"
114
+ },
115
+ borderWidthTop: {
116
+ property: "borderTopWidth",
117
+ scale: "borderWidths"
118
+ },
119
+ borderWidthBottom: {
120
+ property: "borderBottomWidth",
121
+ scale: "borderWidths"
122
+ },
123
+ borderRadius: {
124
+ property: "borderRadius",
125
+ scale: "radii",
126
+ transform: size
127
+ },
128
+ borderRadiusLeft: {
129
+ property: "borderRadius",
130
+ properties: ["borderTopLeftRadius", "borderBottomLeftRadius"],
131
+ scale: "radii",
132
+ transform: size
133
+ },
134
+ borderRadiusTop: {
135
+ property: "borderRadius",
136
+ properties: ["borderTopLeftRadius", "borderTopRightRadius"],
137
+ scale: "radii",
138
+ transform: size
139
+ },
140
+ borderRadiusBottom: {
141
+ property: "borderRadius",
142
+ properties: ["borderBottomLeftRadius", "borderBottomRightRadius"],
143
+ scale: "radii",
144
+ transform: size
145
+ },
146
+ borderRadiusRight: {
147
+ property: "borderRadius",
148
+ properties: ["borderTopRightRadius", "borderBottomRightRadius"],
149
+ scale: "radii",
150
+ transform: size
151
+ },
152
+ borderRadiusTopLeft: {
153
+ property: "borderTopLeftRadius",
154
+ scale: "radii",
155
+ transform: size
156
+ },
157
+ borderRadiusTopRight: {
158
+ property: "borderTopRightRadius",
159
+ scale: "radii",
160
+ transform: size
161
+ },
162
+ borderRadiusBottomRight: {
163
+ property: "borderBottomRightRadius",
164
+ scale: "radii",
165
+ transform: size
166
+ },
167
+ borderRadiusBottomLeft: {
168
+ property: "borderBottomLeftRadius",
169
+ scale: "radii",
170
+ transform: size
171
+ },
172
+ borderStyle: { property: "borderStyle" },
173
+ borderStyleX: {
174
+ property: "borderStyle",
175
+ properties: ["borderLeftStyle", "borderRightStyle"]
176
+ },
177
+ borderStyleY: {
178
+ property: "borderStyle",
179
+ properties: ["borderTopStyle", "borderBottomStyle"]
180
+ },
181
+ borderStyleLeft: { property: "borderLeftStyle" },
182
+ borderStyleRight: { property: "borderRightStyle" },
183
+ borderStyleTop: { property: "borderTopStyle" },
184
+ borderStyleBottom: { property: "borderBottomStyle" }
185
+ };
186
+ const gaps = {
187
+ gap: {
188
+ property: "gap",
189
+ scale: "space"
190
+ },
191
+ rowGap: {
192
+ property: "rowGap",
193
+ scale: "space"
194
+ },
195
+ columnGap: {
196
+ property: "columnGap",
197
+ scale: "space"
198
+ }
199
+ };
200
+ const selfAlignments = {
201
+ justifySelf: { property: "justifySelf" },
202
+ alignSelf: { property: "alignSelf" },
203
+ gridArea: { property: "gridArea" },
204
+ area: { property: "gridArea" }
205
+ };
206
+ const alignments = {
207
+ justifyContent: { property: "justifyContent" },
208
+ justifyItems: { property: "justifyItems" },
209
+ alignItems: { property: "alignItems" },
210
+ alignContent: { property: "alignContent" },
211
+ ...selfAlignments
212
+ };
213
+ const flexItems = {
214
+ flexBasis: { property: "flexBasis" },
215
+ flexShrink: { property: "flexShrink" },
216
+ flexGrow: { property: "flexGrow" },
217
+ order: { property: "order" }
218
+ };
219
+ const flex = {
220
+ flexDirection: { property: "flexDirection" },
221
+ flexWrap: { property: "flexWrap" },
222
+ flex: { property: "flex" },
223
+ ...alignments,
224
+ ...flexItems,
225
+ ...gaps
226
+ };
227
+ const gridItems = {
228
+ gridColumn: { property: "gridColumn" },
229
+ gridRow: { property: "gridRow" },
230
+ gridColumnStart: { property: "gridColumnStart" },
231
+ gridRowStart: { property: "gridRowStart" },
232
+ gridColumnEnd: { property: "gridColumnEnd" },
233
+ gridRowEnd: { property: "gridRowEnd" }
234
+ };
235
+ const grid = {
236
+ gridAutoColumns: { property: "gridAutoColumns" },
237
+ gridAutoRows: { property: "gridAutoRows" },
238
+ gridTemplateColumns: { property: "gridTemplateColumns" },
239
+ gridTemplateRows: { property: "gridTemplateRows" },
240
+ gridTemplateAreas: { property: "gridTemplateAreas" },
241
+ gridAutoFlow: { property: "gridAutoFlow" },
242
+ flow: {
243
+ property: "gridAutoFlow",
244
+ scale: createScale()
245
+ },
246
+ cols: {
247
+ property: "gridTemplateColumns",
248
+ transform: gridItemRatio,
249
+ scale: createScale()
250
+ },
251
+ rows: {
252
+ property: "gridTemplateRows",
253
+ transform: gridItemRatio,
254
+ scale: createScale()
255
+ },
256
+ autoRows: {
257
+ property: "gridAutoRows",
258
+ transform: gridItem
259
+ },
260
+ autoCols: {
261
+ property: "gridAutoColumns",
262
+ transform: gridItem
263
+ },
264
+ alignAll: {
265
+ property: "justifyContent",
266
+ properties: ["justifyContent", "alignItems"]
267
+ },
268
+ ...alignments,
269
+ ...gridItems,
270
+ ...gaps
271
+ };
272
+ const background = {
273
+ background: { property: "background" },
274
+ backgroundImage: { property: "backgroundImage" },
275
+ backgroundSize: { property: "backgroundSize" },
276
+ backgroundRepeat: { property: "backgroundRepeat" },
277
+ backgroundPosition: { property: "backgroundPosition" }
278
+ };
279
+ const positioning = {
280
+ position: { property: "position" },
281
+ inset: {
282
+ property: "inset",
283
+ properties: [
284
+ "top",
285
+ "right",
286
+ "bottom",
287
+ "left"
288
+ ],
289
+ transform: size
290
+ },
291
+ top: {
292
+ property: "top",
293
+ transform: size
294
+ },
295
+ right: {
296
+ property: "right",
297
+ transform: size
298
+ },
299
+ bottom: {
300
+ property: "bottom",
301
+ transform: size
302
+ },
303
+ left: {
304
+ property: "left",
305
+ transform: size
306
+ },
307
+ zIndex: {
308
+ property: "zIndex",
309
+ scale: "zIndices"
310
+ },
311
+ opacity: {
312
+ property: "opacity",
313
+ scale: "opacities"
314
+ }
315
+ };
316
+ const shadows = {
317
+ boxShadow: {
318
+ property: "boxShadow",
319
+ scale: "shadows"
320
+ },
321
+ textShadow: {
322
+ property: "textShadow",
323
+ scale: "shadows"
324
+ }
325
+ };
326
+ const layout = {
327
+ display: { property: "display" },
328
+ overflow: { property: "overflow" },
329
+ overflowX: { property: "overflowX" },
330
+ overflowY: { property: "overflowY" },
331
+ size: {
332
+ property: "width",
333
+ properties: ["width", "height"],
334
+ transform: size
335
+ },
336
+ width: {
337
+ property: "width",
338
+ transform: size
339
+ },
340
+ minWidth: {
341
+ property: "minWidth",
342
+ transform: size
343
+ },
344
+ maxWidth: {
345
+ property: "maxWidth",
346
+ transform: size
347
+ },
348
+ height: {
349
+ property: "height",
350
+ transform: size
351
+ },
352
+ minHeight: {
353
+ property: "minHeight",
354
+ transform: size
355
+ },
356
+ maxHeight: {
357
+ property: "maxHeight",
358
+ transform: size
359
+ },
360
+ verticalAlign: { property: "verticalAlign" },
361
+ ...selfAlignments,
362
+ ...gridItems,
363
+ ...flexItems
364
+ };
365
+ const typography = {
366
+ fontFamily: {
367
+ property: "fontFamily",
368
+ scale: "fonts"
369
+ },
370
+ fontWeight: {
371
+ property: "fontWeight",
372
+ scale: "fontWeights"
373
+ },
374
+ lineHeight: {
375
+ property: "lineHeight",
376
+ scale: "lineHeights"
377
+ },
378
+ fontSize: {
379
+ property: "fontSize",
380
+ scale: "fontSizes"
381
+ },
382
+ letterSpacing: {
383
+ property: "letterSpacing",
384
+ scale: "letterSpacings"
385
+ },
386
+ textAlign: { property: "textAlign" },
387
+ fontStyle: { property: "fontStyle" },
388
+ textDecoration: { property: "textDecoration" },
389
+ textTransform: { property: "textTransform" },
390
+ whiteSpace: { property: "whiteSpace" }
391
+ };
392
+ const margin = {
393
+ m: {
394
+ property: "margin",
395
+ scale: "space"
396
+ },
397
+ mx: {
398
+ property: "margin",
399
+ properties: ["marginLeft", "marginRight"],
400
+ scale: "space"
401
+ },
402
+ my: {
403
+ property: "margin",
404
+ properties: ["marginTop", "marginBottom"],
405
+ scale: "space"
406
+ },
407
+ mt: {
408
+ property: "marginTop",
409
+ scale: "space"
410
+ },
411
+ mb: {
412
+ property: "marginBottom",
413
+ scale: "space"
414
+ },
415
+ mr: {
416
+ property: "marginRight",
417
+ scale: "space"
418
+ },
419
+ ml: {
420
+ property: "marginLeft",
421
+ scale: "space"
422
+ }
423
+ };
424
+ const padding = {
425
+ p: {
426
+ property: "padding",
427
+ scale: "space"
428
+ },
429
+ px: {
430
+ property: "padding",
431
+ properties: ["paddingLeft", "paddingRight"],
432
+ scale: "space"
433
+ },
434
+ py: {
435
+ property: "padding",
436
+ properties: ["paddingTop", "paddingBottom"],
437
+ scale: "space"
438
+ },
439
+ pt: {
440
+ property: "paddingTop",
441
+ scale: "space"
442
+ },
443
+ pb: {
444
+ property: "paddingBottom",
445
+ scale: "space"
446
+ },
447
+ pr: {
448
+ property: "paddingRight",
449
+ scale: "space"
450
+ },
451
+ pl: {
452
+ property: "paddingLeft",
453
+ scale: "space"
454
+ }
455
+ };
456
+ const space = {
457
+ ...margin,
458
+ ...padding
459
+ };
460
+ const transitions = {
461
+ transition: {
462
+ property: "transition",
463
+ scale: "transitions"
464
+ },
465
+ animation: { property: "animation" },
466
+ animationPlayState: { property: "animationPlayState" }
467
+ };
468
+ const mode = { mode: {
469
+ property: "none",
470
+ scale: "mode"
471
+ } };
472
+ const vars = { vars: { property: "variables" } };
473
+ //#endregion
474
+ export { background, border, color, flex, grid, layout, mode, positioning, shadows, space, transitions, typography, vars };
@@ -0,0 +1,17 @@
1
+ export { Animus, AnimusWithAll } from './Animus';
2
+ export { AnimusExtended, AnimusExtendedWithAll } from './AnimusExtended';
3
+ export { PropertyBuilder } from './PropertyBuilder';
4
+ export type { SerializedConfig, SystemInstance } from './SystemBuilder';
5
+ export { createSystem, SystemBuilder } from './SystemBuilder';
6
+ export { createScale, numericOrStringScale, numericScale, stringScale, } from './scales/createScale';
7
+ export { borderShorthand } from './transforms/border';
8
+ export { createTransform, type NamedTransform, type TransformFn, } from './transforms/createTransform';
9
+ export { gridItem, gridItemRatio } from './transforms/grid';
10
+ export { percentageOrAbsolute, size } from './transforms/size';
11
+ export type { AnimusComponent, AnimusWrappedComponent, } from './types/component';
12
+ export type { AbstractParser, CSSPropMap, CSSProps, Parser, ParserProps, Prop, PropertyValues, Scale, ScaleValue, SystemProps, ThemedCSSPropMap, ThemedCSSProps, ThemedScale, ThemedScaleValue, VariantConfig, } from './types/config';
13
+ export type { AbstractProps, MediaQueryArray, MediaQueryMap, ResponsiveProp, ThemeProps, } from './types/props';
14
+ export type { ArrayScale, MapScale } from './types/scales';
15
+ export type { CSSObject, NarrowPrimitive } from './types/shared';
16
+ export type { BaseTheme, Breakpoints, Theme, TokenScales } from './types/theme';
17
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACjD,OAAO,EAAE,cAAc,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAEzE,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,YAAY,EAAE,gBAAgB,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACxE,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAE9D,OAAO,EACL,WAAW,EACX,oBAAoB,EACpB,YAAY,EACZ,WAAW,GACZ,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtD,OAAO,EACL,eAAe,EACf,KAAK,cAAc,EACnB,KAAK,WAAW,GACjB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,oBAAoB,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAE/D,YAAY,EACV,eAAe,EACf,sBAAsB,GACvB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EACV,cAAc,EACd,UAAU,EACV,QAAQ,EACR,MAAM,EACN,WAAW,EACX,IAAI,EACJ,cAAc,EACd,KAAK,EACL,UAAU,EACV,WAAW,EACX,gBAAgB,EAChB,cAAc,EACd,WAAW,EACX,gBAAgB,EAChB,aAAa,GACd,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,aAAa,EACb,eAAe,EACf,aAAa,EACb,cAAc,EACd,UAAU,GACX,MAAM,eAAe,CAAC;AACvB,YAAY,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC3D,YAAY,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEjE,YAAY,EAAE,SAAS,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC"}