@pandacss/preset-base 0.0.0-dev-20230608163155

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/dist/index.mjs ADDED
@@ -0,0 +1,2292 @@
1
+ // src/conditions.ts
2
+ var conditions = {
3
+ hover: "&:where(:hover, [data-hover])",
4
+ focus: "&:where(:focus, [data-focus])",
5
+ focusWithin: "&:focus-within",
6
+ focusVisible: "&:where(:focus-visible, [data-focus-visible])",
7
+ disabled: "&:where(:disabled, [disabled], [data-disabled])",
8
+ active: "&:where(:active, [data-active])",
9
+ visited: "&:visited",
10
+ target: "&:target",
11
+ readOnly: "&:where(:read-only, [data-read-only])",
12
+ readWrite: "&:read-write",
13
+ empty: "&:where(:empty, [data-empty])",
14
+ checked: "&:where(:checked, [data-checked], [aria-checked=true])",
15
+ enabled: "&:enabled",
16
+ expanded: "&:where([aria-expanded=true], [data-expanded])",
17
+ highlighted: "&[data-highlighted]",
18
+ before: "&::before",
19
+ after: "&::after",
20
+ firstLetter: "&::first-letter",
21
+ firstLine: "&::first-line",
22
+ marker: "&::marker",
23
+ selection: "&::selection",
24
+ file: "&::file-selector-button",
25
+ backdrop: "&::backdrop",
26
+ first: "&:first-child",
27
+ last: "&:last-child",
28
+ only: "&:only-child",
29
+ even: "&:even",
30
+ odd: "&:odd",
31
+ firstOfType: "&:first-of-type",
32
+ lastOfType: "&:last-of-type",
33
+ onlyOfType: "&:only-of-type",
34
+ peerFocus: ".peer:where(:focus, [data-focus]) ~ &",
35
+ peerHover: ".peer:where(:hover, [data-hover]) ~ &",
36
+ peerActive: ".peer:where(:active, [data-active]) ~ &",
37
+ peerFocusWithin: ".peer:focus-within ~ &",
38
+ peerFocusVisible: ".peer:where(:focus-visible, [data-focus-visible]) ~ &",
39
+ peerDisabled: ".peer:where(:disabled, [disabled], [data-disabled]) ~ &",
40
+ peerChecked: ".peer:where(:checked, [data-checked], [aria-checked=true]) ~ &",
41
+ peerInvalid: ".peer:where(:invalid, [data-invalid], [aria-invalid=true]) ~ &",
42
+ peerExpanded: ".peer:where([aria-expanded=true], [data-expanded]) ~ &",
43
+ peerPlaceholderShown: ".peer:placeholder-shown ~ &",
44
+ groupFocus: ".group:where(:focus, [data-focus]) &",
45
+ groupHover: ".group:where(:hover, [data-hover]) &",
46
+ groupActive: ".group:where(:active, [data-active]) &",
47
+ groupFocusWithin: ".group:focus-within &",
48
+ groupFocusVisible: ".group:where(:focus-visible, [data-focus-visible]) &",
49
+ groupDisabled: ".group:where(:disabled, [disabled], [data-disabled]) &",
50
+ groupChecked: ".group:where(:checked, [data-checked], [aria-checked=true]) &",
51
+ groupExpanded: ".group:where([aria-expanded=true], [data-expanded]) &",
52
+ groupInvalid: ".group:invalid &",
53
+ indeterminate: "&:where(:indeterminate, [data-indeterminate], [aria-checked=mixed])",
54
+ required: "&:required",
55
+ valid: "&:where(:valid, [data-valid])",
56
+ invalid: "&:where(:invalid, [data-invalid])",
57
+ autofill: "&:autofill",
58
+ inRange: "&:in-range",
59
+ outOfRange: "&:out-of-range",
60
+ placeholder: "&:placeholder",
61
+ placeholderShown: "&:placeholder-shown",
62
+ pressed: "&:where([aria-pressed=true], [data-pressed])",
63
+ selected: "&:where([aria-selected=true], [data-selected])",
64
+ default: "&:default",
65
+ optional: "&:optional",
66
+ open: "&[open]",
67
+ fullscreen: "&:fullscreen",
68
+ loading: "&:where([data-loading], [aria-busy=true])",
69
+ currentPage: "&[aria-current=page]",
70
+ currentStep: "&[aria-current=step]",
71
+ motionReduce: "@media (prefers-reduced-motion: reduce)",
72
+ motionSafe: "@media (prefers-reduced-motion: no-preference)",
73
+ print: "@media print",
74
+ landscape: "@media (orientation: landscape)",
75
+ portrait: "@media (orientation: portrait)",
76
+ dark: " &.dark, .dark &",
77
+ light: " &.light, .light &",
78
+ osDark: "@media (prefers-color-scheme: dark)",
79
+ osLight: "@media (prefers-color-scheme: light)",
80
+ highConstrast: "@media (forced-colors: active)",
81
+ lessContrast: "@media (prefers-contrast: less)",
82
+ moreContrast: "@media (prefers-contrast: more)",
83
+ ltr: "[dir=ltr] &",
84
+ rtl: "[dir=rtl] &",
85
+ scrollbar: "&::-webkit-scrollbar",
86
+ scrollbarThumb: "&::-webkit-scrollbar-thumb",
87
+ scrollbarTrack: "&::-webkit-scrollbar-track",
88
+ horizontal: "&[data-orientation=horizontal]",
89
+ vertical: "&[data-orientation=vertical]"
90
+ };
91
+
92
+ // src/utilities/background.ts
93
+ var background = {
94
+ backgroundPosition: {
95
+ shorthand: "bgPosition",
96
+ className: "bg"
97
+ },
98
+ backgroundPositionX: {
99
+ shorthand: "bgPositionX",
100
+ className: "bg-x"
101
+ },
102
+ backgroundPositionY: {
103
+ shorthand: "bgPositionY",
104
+ className: "bg-y"
105
+ },
106
+ backgroundAttachment: {
107
+ shorthand: "bgAttachment",
108
+ className: "bg"
109
+ },
110
+ backgroundClip: {
111
+ shorthand: "bgClip",
112
+ className: "bg-clip"
113
+ },
114
+ background: {
115
+ shorthand: "bg",
116
+ className: "bg",
117
+ values: "colors"
118
+ },
119
+ backgroundColor: {
120
+ shorthand: "bgColor",
121
+ className: "bg",
122
+ values: "colors"
123
+ },
124
+ backgroundOrigin: {
125
+ shorthand: "bgOrigin",
126
+ className: "bg-origin"
127
+ },
128
+ backgroundImage: {
129
+ shorthand: "bgImage",
130
+ className: "bg-img",
131
+ values: "assets"
132
+ },
133
+ backgroundRepeat: {
134
+ shorthand: "bgRepeat",
135
+ className: "bg-repeat"
136
+ },
137
+ backgroundBlendMode: {
138
+ shorthand: "bgBlendMode",
139
+ className: "bg-blend"
140
+ },
141
+ backgroundSize: {
142
+ shorthand: "bgSize",
143
+ className: "bg"
144
+ },
145
+ backgroundGradient: {
146
+ shorthand: "bgGradient",
147
+ className: "bg-gradient",
148
+ values(theme) {
149
+ return {
150
+ ...theme("gradients"),
151
+ "to-t": "linear-gradient(to top, var(--gradient))",
152
+ "to-tr": "linear-gradient(to top right, var(--gradient))",
153
+ "to-r": "linear-gradient(to right, var(--gradient))",
154
+ "to-br": "linear-gradient(to bottom right, var(--gradient))",
155
+ "to-b": "linear-gradient(to bottom, var(--gradient))",
156
+ "to-bl": "linear-gradient(to bottom left, var(--gradient))",
157
+ "to-l": "linear-gradient(to left, var(--gradient))",
158
+ "to-tl": "linear-gradient(to top left, var(--gradient))"
159
+ };
160
+ },
161
+ transform(value) {
162
+ return {
163
+ "--gradient-stops": "var(--gradient-from), var(--gradient-to)",
164
+ "--gradient": "var(--gradient-via-stops, var(--gradient-stops))",
165
+ backgroundImage: value
166
+ };
167
+ }
168
+ },
169
+ textGradient: {
170
+ className: "text-gradient",
171
+ values(theme) {
172
+ return {
173
+ ...theme("gradients"),
174
+ "to-t": "linear-gradient(to top, var(--gradient))",
175
+ "to-tr": "linear-gradient(to top right, var(--gradient))",
176
+ "to-r": "linear-gradient(to right, var(--gradient))",
177
+ "to-br": "linear-gradient(to bottom right, var(--gradient))",
178
+ "to-b": "linear-gradient(to bottom, var(--gradient))",
179
+ "to-bl": "linear-gradient(to bottom left, var(--gradient))",
180
+ "to-l": "linear-gradient(to left, var(--gradient))",
181
+ "to-tl": "linear-gradient(to top left, var(--gradient))"
182
+ };
183
+ },
184
+ transform(value) {
185
+ return {
186
+ "--gradient-stops": "var(--gradient-from), var(--gradient-to)",
187
+ "--gradient": "var(--gradient-via-stops, var(--gradient-stops))",
188
+ backgroundImage: value,
189
+ backgroundClip: "text",
190
+ color: "transparent"
191
+ };
192
+ }
193
+ },
194
+ gradientFrom: {
195
+ className: "from",
196
+ values: "colors",
197
+ transform(value) {
198
+ return {
199
+ "--gradient-from": value
200
+ };
201
+ }
202
+ },
203
+ gradientTo: {
204
+ className: "to",
205
+ values: "colors",
206
+ transform(value) {
207
+ return {
208
+ "--gradient-to": value
209
+ };
210
+ }
211
+ },
212
+ gradientVia: {
213
+ className: "via",
214
+ values: "colors",
215
+ transform(value) {
216
+ return {
217
+ "--gradient-via-stops": "var(--gradient-from), var(--gradient-via), var(--gradient-to)",
218
+ "--gradient-via": value
219
+ };
220
+ }
221
+ }
222
+ };
223
+
224
+ // src/utilities/border.ts
225
+ var border = {
226
+ borderRadius: {
227
+ className: "rounded",
228
+ shorthand: "rounded",
229
+ values: "radii"
230
+ },
231
+ borderTopLeftRadius: {
232
+ className: "rounded-tl",
233
+ shorthand: "roundedTopLeft",
234
+ values: "radii"
235
+ },
236
+ borderTopRightRadius: {
237
+ className: "rounded-tr",
238
+ shorthand: "roundedTopRight",
239
+ values: "radii"
240
+ },
241
+ borderBottomRightRadius: {
242
+ className: "rounded-br",
243
+ shorthand: "roundedBottomRight",
244
+ values: "radii"
245
+ },
246
+ borderBottomLeftRadius: {
247
+ className: "rounded-bl",
248
+ shorthand: "roundedBottomLeft",
249
+ values: "radii"
250
+ },
251
+ borderTopRadius: {
252
+ className: "rounded-t",
253
+ shorthand: "roundedTop",
254
+ property: "borderRadius",
255
+ values: "radii",
256
+ transform(value) {
257
+ return {
258
+ borderTopLeftRadius: value,
259
+ borderTopRightRadius: value
260
+ };
261
+ }
262
+ },
263
+ borderRightRadius: {
264
+ className: "rounded-r",
265
+ shorthand: "roundedRight",
266
+ property: "borderRadius",
267
+ values: "radii",
268
+ transform(value) {
269
+ return {
270
+ borderTopRightRadius: value,
271
+ borderBottomRightRadius: value
272
+ };
273
+ }
274
+ },
275
+ borderBottomRadius: {
276
+ className: "rounded-b",
277
+ shorthand: "roundedBottom",
278
+ property: "borderRadius",
279
+ values: "radii",
280
+ transform(value) {
281
+ return {
282
+ borderBottomLeftRadius: value,
283
+ borderBottomRightRadius: value
284
+ };
285
+ }
286
+ },
287
+ borderLeftRadius: {
288
+ className: "rounded-l",
289
+ shorthand: "roundedLeft",
290
+ values: "radii",
291
+ property: "borderRadius",
292
+ transform(value) {
293
+ return {
294
+ borderTopLeftRadius: value,
295
+ borderBottomLeftRadius: value
296
+ };
297
+ }
298
+ },
299
+ borderStartStartRadius: {
300
+ className: "rounded-ss",
301
+ shorthand: "roundedStartStart",
302
+ values: "radii"
303
+ },
304
+ borderStartEndRadius: {
305
+ className: "rounded-se",
306
+ shorthand: "roundedStartEnd",
307
+ values: "radii"
308
+ },
309
+ borderStartRadius: {
310
+ className: "rounded-s",
311
+ values: "radii",
312
+ property: "borderRadius",
313
+ shorthand: "roundedStart",
314
+ transform(value) {
315
+ return {
316
+ borderStartStartRadius: value,
317
+ borderEndStartRadius: value
318
+ };
319
+ }
320
+ },
321
+ borderEndStartRadius: {
322
+ className: "rounded-es",
323
+ shorthand: "roundedEndStart",
324
+ values: "radii"
325
+ },
326
+ borderEndEndRadius: {
327
+ className: "rounded-ee",
328
+ shorthand: "roundedEndEnd",
329
+ values: "radii"
330
+ },
331
+ borderEndRadius: {
332
+ className: "rounded-e",
333
+ shorthand: "roundedEnd",
334
+ property: "borderRadius",
335
+ values: "radii",
336
+ transform(value) {
337
+ return {
338
+ borderStartEndRadius: value,
339
+ borderEndEndRadius: value
340
+ };
341
+ }
342
+ },
343
+ border: {
344
+ className: "border",
345
+ values: "borders"
346
+ },
347
+ borderColor: {
348
+ className: "border",
349
+ values: "colors"
350
+ },
351
+ borderInline: {
352
+ className: "border-x",
353
+ values: "borders",
354
+ shorthand: "borderX"
355
+ },
356
+ borderInlineColor: {
357
+ className: "border-x",
358
+ values: "colors",
359
+ shorthand: "borderXColor"
360
+ },
361
+ borderBlock: {
362
+ className: "border-y",
363
+ values: "borders"
364
+ },
365
+ borderBlockColor: {
366
+ className: "border-y",
367
+ values: "colors",
368
+ shorthand: "borderYColor"
369
+ },
370
+ borderLeft: {
371
+ className: "border-l",
372
+ values: "borders"
373
+ },
374
+ borderLeftColor: {
375
+ className: "border-l",
376
+ values: "colors"
377
+ },
378
+ borderInlineStart: {
379
+ className: "border-s",
380
+ values: "borders"
381
+ },
382
+ borderInlineStartColor: {
383
+ className: "border-s"
384
+ },
385
+ borderRight: {
386
+ className: "border-r",
387
+ values: "borders"
388
+ },
389
+ borderRightColor: {
390
+ className: "border-r",
391
+ values: "colors"
392
+ },
393
+ borderInlineEnd: {
394
+ className: "border-e",
395
+ values: "borders"
396
+ },
397
+ borderInlineEndColor: {
398
+ className: "border-e",
399
+ values: "colors"
400
+ },
401
+ borderTop: {
402
+ className: "border-t",
403
+ values: "borders"
404
+ },
405
+ borderTopColor: {
406
+ className: "border-t",
407
+ values: "colors"
408
+ },
409
+ borderBottom: {
410
+ className: "border-b",
411
+ values: "borders"
412
+ },
413
+ borderBottomColor: {
414
+ className: "border-b",
415
+ values: "colors"
416
+ },
417
+ borderBlockEnd: {
418
+ className: "border-be",
419
+ values: "borders"
420
+ },
421
+ borderBlockEndColor: {
422
+ className: "border-be",
423
+ values: "colors"
424
+ },
425
+ borderBlockStart: {
426
+ className: "border-bs",
427
+ values: "borders"
428
+ },
429
+ borderBlockStartColor: {
430
+ className: "border-bs",
431
+ values: "colors"
432
+ }
433
+ };
434
+
435
+ // src/utilities/display.ts
436
+ var display = {
437
+ display: {
438
+ className: "d"
439
+ },
440
+ hideFrom: {
441
+ className: "hide",
442
+ values: "breakpoints",
443
+ transform(value, { raw }) {
444
+ return {
445
+ [`@breakpoint ${raw}`]: {
446
+ display: "none"
447
+ }
448
+ };
449
+ }
450
+ },
451
+ hideBelow: {
452
+ className: "show",
453
+ values: "breakpoints",
454
+ transform(value, { raw }) {
455
+ return {
456
+ [`@breakpoint ${raw}Down`]: {
457
+ display: "none"
458
+ }
459
+ };
460
+ }
461
+ }
462
+ };
463
+
464
+ // src/utilities/divide.ts
465
+ var divide = {
466
+ divideX: {
467
+ className: "divide-x",
468
+ values: { type: "string" },
469
+ transform(value) {
470
+ return {
471
+ "& > :not([hidden]) ~ :not([hidden])": {
472
+ borderLeftWidth: value,
473
+ borderRightWidth: "0px"
474
+ }
475
+ };
476
+ }
477
+ },
478
+ divideY: {
479
+ className: "divide-y",
480
+ values: { type: "string" },
481
+ transform(value) {
482
+ return {
483
+ "& > :not([hidden]) ~ :not([hidden])": {
484
+ borderTopWidth: value,
485
+ borderBottomWidth: "0px"
486
+ }
487
+ };
488
+ }
489
+ },
490
+ divideColor: {
491
+ className: "divide",
492
+ values: "colors",
493
+ transform(value) {
494
+ return {
495
+ "& > :not([hidden]) ~ :not([hidden])": {
496
+ borderColor: value
497
+ }
498
+ };
499
+ }
500
+ },
501
+ divideStyle: {
502
+ className: "divide",
503
+ property: "borderStyle",
504
+ transform(value) {
505
+ return {
506
+ "& > :not([hidden]) ~ :not([hidden])": {
507
+ borderStyle: value
508
+ }
509
+ };
510
+ }
511
+ }
512
+ };
513
+
514
+ // src/utilities/effects.ts
515
+ var effects = {
516
+ boxShadow: {
517
+ shorthand: "shadow",
518
+ className: "shadow",
519
+ values: "shadows"
520
+ },
521
+ boxShadowColor: {
522
+ shorthand: "shadowColor",
523
+ className: "shadow",
524
+ values: "colors",
525
+ transform(value) {
526
+ return {
527
+ "--shadow-color": value
528
+ };
529
+ }
530
+ },
531
+ mixBlendMode: {
532
+ className: "mix-blend"
533
+ },
534
+ filter: {
535
+ className: "filter",
536
+ values: {
537
+ auto: [
538
+ "var(--blur)",
539
+ "var(--brightness)",
540
+ "var(--contrast)",
541
+ "var(--grayscale)",
542
+ "var(--hue-rotate)",
543
+ "var(--invert)",
544
+ "var(--saturate)",
545
+ "var(--sepia)",
546
+ "var(--drop-shadow)"
547
+ ].join(" ")
548
+ }
549
+ },
550
+ brightness: {
551
+ className: "brightness",
552
+ transform(value) {
553
+ return {
554
+ "--brightness": `brightness(${value})`
555
+ };
556
+ }
557
+ },
558
+ contrast: {
559
+ className: "contrast",
560
+ transform(value) {
561
+ return {
562
+ "--contrast": `constrast(${value})`
563
+ };
564
+ }
565
+ },
566
+ grayscale: {
567
+ className: "grayscale",
568
+ transform(value) {
569
+ return {
570
+ "--grayscale": `grayscale(${value})`
571
+ };
572
+ }
573
+ },
574
+ hueRotate: {
575
+ className: "hue-rotate",
576
+ transform(value) {
577
+ return {
578
+ "--hue-rotate": `hue-rotate(${value})`
579
+ };
580
+ }
581
+ },
582
+ invert: {
583
+ className: "invert",
584
+ transform(value) {
585
+ return {
586
+ "--invert": `invert(${value})`
587
+ };
588
+ }
589
+ },
590
+ saturate: {
591
+ className: "saturate",
592
+ transform(value) {
593
+ return {
594
+ "--saturate": `saturate(${value})`
595
+ };
596
+ }
597
+ },
598
+ sepia: {
599
+ className: "sepia",
600
+ transform(value) {
601
+ return {
602
+ "--sepia": `sepia(${value})`
603
+ };
604
+ }
605
+ },
606
+ dropShadow: {
607
+ className: "drop-shadow",
608
+ values: "dropShadows",
609
+ transform(value) {
610
+ return {
611
+ "--drop-shadow": value
612
+ };
613
+ }
614
+ },
615
+ blur: {
616
+ className: "blur",
617
+ values: "blurs",
618
+ transform(value) {
619
+ return {
620
+ "--blur": `blur(${value})`
621
+ };
622
+ }
623
+ },
624
+ backdropFilter: {
625
+ className: "backdrop",
626
+ values: {
627
+ auto: [
628
+ "var(--backdrop-blur)",
629
+ "var(--backdrop-brightness)",
630
+ "var(--backdrop-contrast)",
631
+ "var(--backdrop-grayscale)",
632
+ "var(--backdrop-hue-rotate)",
633
+ "var(--backdrop-invert)",
634
+ "var(--backdrop-saturate)",
635
+ "var(--backdrop-sepia)"
636
+ ].join(" ")
637
+ }
638
+ },
639
+ backdropBlur: {
640
+ className: "backdrop-blur",
641
+ values: "blurs",
642
+ transform(value) {
643
+ return {
644
+ "--backdrop-blur": `blur(${value})`
645
+ };
646
+ }
647
+ },
648
+ backdropBrightness: {
649
+ className: "backdrop-brightness",
650
+ transform(value) {
651
+ return {
652
+ "--backdrop-brightness": `brightness(${value})`
653
+ };
654
+ }
655
+ },
656
+ backdropContrast: {
657
+ className: "backdrop-contrast",
658
+ transform(value) {
659
+ return {
660
+ "--backdrop-contrast": `constrast(${value})`
661
+ };
662
+ }
663
+ },
664
+ backdropGrayscale: {
665
+ className: "backdrop-grayscale",
666
+ transform(value) {
667
+ return {
668
+ "--backdrop-grayscale": `grayscale(${value})`
669
+ };
670
+ }
671
+ },
672
+ backdropHueRotate: {
673
+ className: "backdrop-hue-rotate",
674
+ transform(value) {
675
+ return {
676
+ "--backdrop-hue-rotate": `hue-rotate(${value})`
677
+ };
678
+ }
679
+ },
680
+ backdropInvert: {
681
+ className: "backdrop-invert",
682
+ transform(value) {
683
+ return {
684
+ "--backdrop-invert": `invert(${value})`
685
+ };
686
+ }
687
+ },
688
+ backdropOpacity: {
689
+ className: "backdrop-opacity",
690
+ transform(value) {
691
+ return {
692
+ "--backdrop-opacity": value
693
+ };
694
+ }
695
+ },
696
+ backdropSaturate: {
697
+ className: "backdrop-saturate",
698
+ transform(value) {
699
+ return {
700
+ "--backdrop-saturate": `saturate(${value})`
701
+ };
702
+ }
703
+ },
704
+ backdropSepia: {
705
+ className: "backdrop-sepia",
706
+ transform(value) {
707
+ return {
708
+ "--backdrop-sepia": `sepia(${value})`
709
+ };
710
+ }
711
+ }
712
+ };
713
+
714
+ // src/utilities/flex-and-grid.ts
715
+ var flexGrid = {
716
+ flexBasis: {
717
+ className: "basis",
718
+ values(theme) {
719
+ return {
720
+ ...theme("spacing"),
721
+ "1/2": "50%",
722
+ "1/3": "33.333333%",
723
+ "2/3": "66.666667%",
724
+ "1/4": "25%",
725
+ "2/4": "50%",
726
+ "3/4": "75%",
727
+ "1/5": "20%",
728
+ "2/5": "40%",
729
+ "3/5": "60%",
730
+ "4/5": "80%",
731
+ "1/6": "16.666667%",
732
+ "2/6": "33.333333%",
733
+ "3/6": "50%",
734
+ "4/6": "66.666667%",
735
+ "5/6": "83.333333%",
736
+ "1/12": "8.333333%",
737
+ "2/12": "16.666667%",
738
+ "3/12": "25%",
739
+ "4/12": "33.333333%",
740
+ "5/12": "41.666667%",
741
+ "6/12": "50%",
742
+ "7/12": "58.333333%",
743
+ "8/12": "66.666667%",
744
+ "9/12": "75%",
745
+ "10/12": "83.333333%",
746
+ "11/12": "91.666667%",
747
+ full: "100%"
748
+ };
749
+ }
750
+ },
751
+ flex: {
752
+ className: "flex",
753
+ values: {
754
+ "1": "1 1 0%",
755
+ auto: "1 1 auto",
756
+ initial: "0 1 auto",
757
+ none: "none"
758
+ }
759
+ },
760
+ flexDirection: {
761
+ className: "flex",
762
+ shorthand: "flexDir"
763
+ },
764
+ flexGrow: {
765
+ className: "grow"
766
+ },
767
+ flexShrink: {
768
+ className: "shrink"
769
+ },
770
+ gridTemplateColumns: {
771
+ className: "grid-cols",
772
+ values: {
773
+ "1": "repeat(1, minmax(0, 1fr))",
774
+ "2": "repeat(2, minmax(0, 1fr))",
775
+ "3": "repeat(3, minmax(0, 1fr))",
776
+ "4": "repeat(4, minmax(0, 1fr))",
777
+ "5": "repeat(5, minmax(0, 1fr))",
778
+ "6": "repeat(6, minmax(0, 1fr))",
779
+ "7": "repeat(7, minmax(0, 1fr))",
780
+ "8": "repeat(8, minmax(0, 1fr))",
781
+ "9": "repeat(9, minmax(0, 1fr))",
782
+ "10": "repeat(10, minmax(0, 1fr))",
783
+ "11": "repeat(11, minmax(0, 1fr))",
784
+ "12": "repeat(12, minmax(0, 1fr))"
785
+ }
786
+ },
787
+ gridTemplateRows: {
788
+ className: "grid-cols",
789
+ values: {
790
+ "1": "repeat(1, minmax(0, 1fr))",
791
+ "2": "repeat(2, minmax(0, 1fr))",
792
+ "3": "repeat(3, minmax(0, 1fr))",
793
+ "4": "repeat(4, minmax(0, 1fr))",
794
+ "5": "repeat(5, minmax(0, 1fr))",
795
+ "6": "repeat(6, minmax(0, 1fr))",
796
+ "7": "repeat(7, minmax(0, 1fr))",
797
+ "8": "repeat(8, minmax(0, 1fr))",
798
+ "9": "repeat(9, minmax(0, 1fr))",
799
+ "10": "repeat(10, minmax(0, 1fr))",
800
+ "11": "repeat(11, minmax(0, 1fr))",
801
+ "12": "repeat(12, minmax(0, 1fr))"
802
+ }
803
+ },
804
+ gridColumn: {
805
+ className: "col-span",
806
+ values: {
807
+ full: "1 / -1",
808
+ "1": "span 1 / span 1",
809
+ "2": "span 2 / span 2",
810
+ "3": "span 3 / span 3",
811
+ "4": "span 4 / span 4",
812
+ "5": "span 5 / span 5",
813
+ "6": "span 6 / span 6",
814
+ "7": "span 7 / span 7",
815
+ "8": "span 8 / span 8",
816
+ "9": "span 9 / span 9",
817
+ "10": "span 10 / span 10",
818
+ "11": "span 11 / span 11",
819
+ "12": "span 12 / span 12"
820
+ }
821
+ },
822
+ gridRow: {
823
+ className: "row-span",
824
+ values: {
825
+ full: "1 / -1",
826
+ "1": "span 1 / span 1",
827
+ "2": "span 2 / span 2",
828
+ "3": "span 3 / span 3",
829
+ "4": "span 4 / span 4",
830
+ "5": "span 5 / span 5",
831
+ "6": "span 6 / span 6",
832
+ "7": "span 7 / span 7",
833
+ "8": "span 8 / span 8",
834
+ "9": "span 9 / span 9",
835
+ "10": "span 10 / span 10",
836
+ "11": "span 11 / span 11",
837
+ "12": "span 12 / span 12"
838
+ }
839
+ },
840
+ gridColumnStart: {
841
+ className: "col-start"
842
+ },
843
+ gridColumnEnd: {
844
+ className: "col-end"
845
+ },
846
+ gridAutoFlow: {
847
+ className: "grid-flow"
848
+ },
849
+ gridAutoColumns: {
850
+ className: "auto-cols",
851
+ values: {
852
+ min: "min-content",
853
+ max: "max-content",
854
+ fr: "minmax(0, 1fr)"
855
+ }
856
+ },
857
+ gridAutoRows: {
858
+ className: "auto-rows",
859
+ values: {
860
+ min: "min-content",
861
+ max: "max-content",
862
+ fr: "minmax(0, 1fr)"
863
+ }
864
+ },
865
+ gap: {
866
+ className: "gap",
867
+ values: "spacing"
868
+ },
869
+ gridGap: {
870
+ className: "gap",
871
+ values: "spacing"
872
+ },
873
+ gridRowGap: {
874
+ className: "gap-x",
875
+ values: "spacing"
876
+ },
877
+ gridColumnGap: {
878
+ className: "gap-y",
879
+ values: "spacing"
880
+ },
881
+ rowGap: {
882
+ className: "gap-x",
883
+ values: "spacing"
884
+ },
885
+ columnGap: {
886
+ className: "gap-y",
887
+ values: "spacing"
888
+ },
889
+ justifyContent: {
890
+ className: "justify"
891
+ },
892
+ alignContent: {
893
+ className: "content"
894
+ },
895
+ alignItems: {
896
+ className: "items"
897
+ },
898
+ alignSelf: {
899
+ className: "self"
900
+ }
901
+ };
902
+
903
+ // src/utilities/helpers.ts
904
+ var srMapping = {
905
+ true: {
906
+ position: "absolute",
907
+ width: "1px",
908
+ height: "1px",
909
+ padding: "0",
910
+ margin: "-1px",
911
+ overflow: "hidden",
912
+ clip: "rect(0, 0, 0, 0)",
913
+ whiteSpace: "nowrap",
914
+ borderWidth: "0"
915
+ },
916
+ false: {
917
+ position: "static",
918
+ width: "auto",
919
+ height: "auto",
920
+ padding: "0",
921
+ margin: "0",
922
+ overflow: "visible",
923
+ clip: "auto",
924
+ whiteSpace: "normal"
925
+ }
926
+ };
927
+ var helpers = {
928
+ srOnly: {
929
+ className: "sr",
930
+ values: { type: "boolean" },
931
+ transform(value) {
932
+ return srMapping[value] || {};
933
+ }
934
+ },
935
+ debug: {
936
+ className: "debug",
937
+ values: { type: "boolean" },
938
+ transform(value) {
939
+ if (!value)
940
+ return {};
941
+ return {
942
+ outline: "1px solid blue !important",
943
+ "&>*": {
944
+ outline: "1px solid red !important"
945
+ }
946
+ };
947
+ }
948
+ }
949
+ };
950
+
951
+ // src/utilities/interactivity.ts
952
+ var interactivity = {
953
+ accentColor: {
954
+ className: "accent",
955
+ values: "colors"
956
+ },
957
+ caretColor: {
958
+ className: "caret",
959
+ values: "colors"
960
+ },
961
+ scrollBehavior: {
962
+ className: "scroll"
963
+ },
964
+ scrollbar: {
965
+ className: "scrollbar",
966
+ values: ["visible", "hidden"],
967
+ transform(value) {
968
+ if (value === "visible") {
969
+ return {
970
+ msOverflowStyle: "auto",
971
+ scrollbarWidth: "auto",
972
+ "&::-webkit-scrollbar": {
973
+ display: "block"
974
+ }
975
+ };
976
+ }
977
+ if (value === "hidden") {
978
+ return {
979
+ msOverflowStyle: "none",
980
+ scrollbarWidth: "none",
981
+ "&::-webkit-scrollbar": {
982
+ display: "none"
983
+ }
984
+ };
985
+ }
986
+ }
987
+ },
988
+ scrollMargin: {
989
+ className: "scroll-m",
990
+ values: "spacing"
991
+ },
992
+ scrollMarginX: {
993
+ className: "scroll-mx",
994
+ values: "spacing",
995
+ property: "scrollMarginInline",
996
+ transform(value) {
997
+ return {
998
+ scrollMarginInline: value
999
+ };
1000
+ }
1001
+ },
1002
+ scrollMarginY: {
1003
+ className: "scroll-my",
1004
+ values: "spacing",
1005
+ property: "scrollMarginBlock",
1006
+ transform(value) {
1007
+ return {
1008
+ scrollMarginBlock: value
1009
+ };
1010
+ }
1011
+ },
1012
+ scrollMarginLeft: {
1013
+ className: "scroll-ml",
1014
+ values: "spacing"
1015
+ },
1016
+ scrollMarginRight: {
1017
+ className: "scroll-mr",
1018
+ values: "spacing"
1019
+ },
1020
+ scrollMarginTop: {
1021
+ className: "scroll-mt",
1022
+ values: "spacing"
1023
+ },
1024
+ scrollMarginBottom: {
1025
+ className: "scroll-mb",
1026
+ values: "spacing"
1027
+ },
1028
+ scrollMarginBlock: {
1029
+ className: "scroll-my",
1030
+ values: "spacing"
1031
+ },
1032
+ scrollMarginBlockEnd: {
1033
+ className: "scroll-mb",
1034
+ values: "spacing"
1035
+ },
1036
+ scrollMarginBlockStart: {
1037
+ className: "scroll-mt",
1038
+ values: "spacing"
1039
+ },
1040
+ scrollMarginInline: {
1041
+ className: "scroll-mx",
1042
+ values: "spacing"
1043
+ },
1044
+ scrollMarginInlineEnd: {
1045
+ className: "scroll-me",
1046
+ values: "spacing"
1047
+ },
1048
+ scrollMarginInlineStart: {
1049
+ className: "scroll-ms",
1050
+ values: "spacing"
1051
+ },
1052
+ scrollPadding: {
1053
+ className: "scroll-p",
1054
+ values: "spacing"
1055
+ },
1056
+ scrollPaddingBlock: {
1057
+ className: "scroll-pb",
1058
+ values: "spacing"
1059
+ },
1060
+ scrollPaddingBlockStart: {
1061
+ className: "scroll-pt",
1062
+ values: "spacing"
1063
+ },
1064
+ scrollPaddingBlockEnd: {
1065
+ className: "scroll-pb",
1066
+ values: "spacing"
1067
+ },
1068
+ scrollPaddingInline: {
1069
+ className: "scroll-px",
1070
+ values: "spacing"
1071
+ },
1072
+ scrollPaddingInlineEnd: {
1073
+ className: "scroll-pe",
1074
+ values: "spacing"
1075
+ },
1076
+ scrollPaddingInlineStart: {
1077
+ className: "scroll-ps",
1078
+ values: "spacing"
1079
+ },
1080
+ scrollPaddingX: {
1081
+ className: "scroll-px",
1082
+ values: "spacing",
1083
+ property: "scrollPaddingInline",
1084
+ transform(value) {
1085
+ return {
1086
+ scrollPaddingInline: value
1087
+ };
1088
+ }
1089
+ },
1090
+ scrollPaddingY: {
1091
+ className: "scroll-py",
1092
+ values: "spacing",
1093
+ property: "scrollPaddingBlock",
1094
+ transform(value) {
1095
+ return {
1096
+ scrollPaddingBlock: value
1097
+ };
1098
+ }
1099
+ },
1100
+ scrollPaddingLeft: {
1101
+ className: "scroll-pl",
1102
+ values: "spacing"
1103
+ },
1104
+ scrollPaddingRight: {
1105
+ className: "scroll-pr",
1106
+ values: "spacing"
1107
+ },
1108
+ scrollPaddingTop: {
1109
+ className: "scroll-pt",
1110
+ values: "spacing"
1111
+ },
1112
+ scrollPaddingBottom: {
1113
+ className: "scroll-pb",
1114
+ values: "spacing"
1115
+ },
1116
+ scrollSnapAlign: {
1117
+ className: "snap"
1118
+ },
1119
+ scrollSnapStop: {
1120
+ className: "snap"
1121
+ },
1122
+ scrollSnapType: {
1123
+ className: "snap",
1124
+ values: {
1125
+ none: "none",
1126
+ x: "x var(--scroll-snap-strictness)",
1127
+ y: "y var(--scroll-snap-strictness)",
1128
+ both: "both var(--scroll-snap-strictness)"
1129
+ }
1130
+ },
1131
+ scrollSnapStrictness: {
1132
+ className: "strictness",
1133
+ values: ["mandatory", "proximity"],
1134
+ transform(value) {
1135
+ return {
1136
+ "--scroll-snap-strictness": value
1137
+ };
1138
+ }
1139
+ },
1140
+ scrollSnapMargin: {
1141
+ className: "snap-m",
1142
+ values: "spacing"
1143
+ },
1144
+ scrollSnapMarginTop: {
1145
+ className: "snap-mt",
1146
+ values: "spacing"
1147
+ },
1148
+ scrollSnapMarginBottom: {
1149
+ className: "snap-mb",
1150
+ values: "spacing"
1151
+ },
1152
+ scrollSnapMarginLeft: {
1153
+ className: "snap-ml",
1154
+ values: "spacing"
1155
+ },
1156
+ scrollSnapMarginRight: {
1157
+ className: "snap-mr",
1158
+ values: "spacing"
1159
+ },
1160
+ touchAction: {
1161
+ className: "touch"
1162
+ },
1163
+ userSelect: {
1164
+ className: "select"
1165
+ }
1166
+ };
1167
+
1168
+ // src/utilities/layout.ts
1169
+ var layout = {
1170
+ aspectRatio: {
1171
+ className: "aspect",
1172
+ values: {
1173
+ square: "1 / 1",
1174
+ landscape: "4 / 3",
1175
+ portrait: "3 / 4",
1176
+ wide: "16 / 9",
1177
+ ultrawide: "18 / 5",
1178
+ golden: "1.618 / 1"
1179
+ }
1180
+ },
1181
+ boxDecorationBreak: {
1182
+ className: "decoration"
1183
+ },
1184
+ zIndex: {
1185
+ className: "z"
1186
+ },
1187
+ boxSizing: {
1188
+ className: "box"
1189
+ },
1190
+ objectPosition: {
1191
+ className: "object"
1192
+ },
1193
+ objectFit: {
1194
+ className: "object"
1195
+ },
1196
+ overscrollBehavior: {
1197
+ className: "overscroll"
1198
+ },
1199
+ overscrollBehaviorX: {
1200
+ className: "overscroll-x"
1201
+ },
1202
+ overscrollBehaviorY: {
1203
+ className: "overscroll-y"
1204
+ },
1205
+ position: {
1206
+ className: "pos",
1207
+ shorthand: "pos"
1208
+ },
1209
+ top: {
1210
+ className: "top",
1211
+ values: "spacing"
1212
+ },
1213
+ left: {
1214
+ className: "left",
1215
+ values: "spacing"
1216
+ },
1217
+ insetInline: {
1218
+ className: "inset-x",
1219
+ values: "spacing"
1220
+ },
1221
+ insetBlock: {
1222
+ className: "inset-y",
1223
+ values: "spacing"
1224
+ },
1225
+ inset: {
1226
+ className: "inset",
1227
+ values: "spacing"
1228
+ },
1229
+ insetBlockEnd: {
1230
+ className: "inset-b",
1231
+ values: "spacing"
1232
+ },
1233
+ insetBlockStart: {
1234
+ className: "inset-t",
1235
+ values: "spacing"
1236
+ },
1237
+ insetInlineEnd: {
1238
+ className: "end",
1239
+ values: "spacing",
1240
+ shorthand: ["insetEnd", "end"]
1241
+ },
1242
+ insetInlineStart: {
1243
+ className: "start",
1244
+ values: "spacing",
1245
+ shorthand: ["insetStart", "start"]
1246
+ },
1247
+ right: {
1248
+ className: "right",
1249
+ values: "spacing"
1250
+ },
1251
+ bottom: {
1252
+ className: "bottom",
1253
+ values: "spacing"
1254
+ },
1255
+ insetX: {
1256
+ className: "inset-x",
1257
+ values: "spacing",
1258
+ property: "insetInline",
1259
+ transform(value) {
1260
+ return {
1261
+ insetInline: value
1262
+ };
1263
+ }
1264
+ },
1265
+ insetY: {
1266
+ className: "inset-y",
1267
+ values: "spacing",
1268
+ property: "insetBlock",
1269
+ transform(value) {
1270
+ return {
1271
+ insetBlock: value
1272
+ };
1273
+ }
1274
+ },
1275
+ float: {
1276
+ className: "float",
1277
+ values: ["left", "right", "start", "end"],
1278
+ transform(value) {
1279
+ if (value === "start") {
1280
+ return {
1281
+ float: "left",
1282
+ '[dir="rtl"] &': {
1283
+ float: "right"
1284
+ }
1285
+ };
1286
+ }
1287
+ if (value === "end") {
1288
+ return {
1289
+ float: "right",
1290
+ '[dir="rtl"] &': {
1291
+ float: "left"
1292
+ }
1293
+ };
1294
+ }
1295
+ return {
1296
+ float: value
1297
+ };
1298
+ }
1299
+ },
1300
+ visibility: {
1301
+ className: "vis"
1302
+ }
1303
+ };
1304
+
1305
+ // src/utilities/list.ts
1306
+ var list = {
1307
+ listStyleType: {
1308
+ className: "list"
1309
+ },
1310
+ listStylePosition: {
1311
+ className: "list"
1312
+ },
1313
+ listStyleImage: {
1314
+ className: "list-img",
1315
+ values: "assets"
1316
+ }
1317
+ };
1318
+
1319
+ // src/utilities/outline.ts
1320
+ var outline = {
1321
+ outlineWidth: {
1322
+ className: "ring",
1323
+ shorthand: "ringWidth"
1324
+ },
1325
+ outlineColor: {
1326
+ className: "ring",
1327
+ values: "colors",
1328
+ shorthand: "ringColor"
1329
+ },
1330
+ outline: {
1331
+ className: "ring",
1332
+ shorthand: "ring",
1333
+ values: "borders",
1334
+ transform(value) {
1335
+ if (value === "none") {
1336
+ return { outline: "2px solid transparent", outlineOffset: "2px" };
1337
+ }
1338
+ return { outline: value };
1339
+ }
1340
+ },
1341
+ outlineOffset: {
1342
+ className: "ring",
1343
+ shorthand: "ringOffset",
1344
+ values: "spacing"
1345
+ }
1346
+ };
1347
+
1348
+ // src/utilities/sizing.ts
1349
+ var widthValues = (theme) => ({
1350
+ ...theme("sizes"),
1351
+ "1/2": "50%",
1352
+ "1/3": "33.333333%",
1353
+ "2/3": "66.666667%",
1354
+ "1/4": "25%",
1355
+ "2/4": "50%",
1356
+ "3/4": "75%",
1357
+ "1/5": "20%",
1358
+ "2/5": "40%",
1359
+ "3/5": "60%",
1360
+ "4/5": "80%",
1361
+ "1/6": "16.666667%",
1362
+ "2/6": "33.333333%",
1363
+ "3/6": "50%",
1364
+ "4/6": "66.666667%",
1365
+ "5/6": "83.333333%",
1366
+ "1/12": "8.333333%",
1367
+ "2/12": "16.666667%",
1368
+ "3/12": "25%",
1369
+ "4/12": "33.333333%",
1370
+ "5/12": "41.666667%",
1371
+ "6/12": "50%",
1372
+ "7/12": "58.333333%",
1373
+ "8/12": "66.666667%",
1374
+ "9/12": "75%",
1375
+ "10/12": "83.333333%",
1376
+ "11/12": "91.666667%",
1377
+ screen: "100vw"
1378
+ });
1379
+ var heightValues = (theme) => ({
1380
+ ...theme("sizes"),
1381
+ svh: "100svh",
1382
+ lvh: "100lvh",
1383
+ dvh: "100dvh",
1384
+ screen: "100vh",
1385
+ "1/2": "50%",
1386
+ "1/3": "33.333333%",
1387
+ "2/3": "66.666667%",
1388
+ "1/4": "25%",
1389
+ "2/4": "50%",
1390
+ "3/4": "75%",
1391
+ "1/5": "20%",
1392
+ "2/5": "40%",
1393
+ "3/5": "60%",
1394
+ "4/5": "80%",
1395
+ "1/6": "16.666667%",
1396
+ "2/6": "33.333333%",
1397
+ "3/6": "50%",
1398
+ "4/6": "66.666667%",
1399
+ "5/6": "83.333333%"
1400
+ });
1401
+ var sizing = {
1402
+ width: {
1403
+ shorthand: "w",
1404
+ className: "w",
1405
+ values: widthValues
1406
+ },
1407
+ inlineSize: {
1408
+ className: "w",
1409
+ values: widthValues
1410
+ },
1411
+ minWidth: {
1412
+ shorthand: "minW",
1413
+ className: "min-w",
1414
+ values: widthValues
1415
+ },
1416
+ minInlineSize: {
1417
+ className: "min-w",
1418
+ values: widthValues
1419
+ },
1420
+ maxWidth: {
1421
+ shorthand: "maxW",
1422
+ className: "max-w",
1423
+ values: widthValues
1424
+ },
1425
+ maxInlineSize: {
1426
+ className: "max-w",
1427
+ values: widthValues
1428
+ },
1429
+ height: {
1430
+ shorthand: "h",
1431
+ className: "h",
1432
+ values: heightValues
1433
+ },
1434
+ blockSize: {
1435
+ className: "h",
1436
+ values: heightValues
1437
+ },
1438
+ minHeight: {
1439
+ shorthand: "minH",
1440
+ className: "min-h",
1441
+ values: heightValues
1442
+ },
1443
+ minBlockSize: {
1444
+ className: "min-h",
1445
+ values: heightValues
1446
+ },
1447
+ maxHeight: {
1448
+ shorthand: "maxH",
1449
+ className: "max-h",
1450
+ values: heightValues
1451
+ },
1452
+ maxBlockSize: {
1453
+ className: "max-b",
1454
+ values: heightValues
1455
+ }
1456
+ };
1457
+
1458
+ // src/utilities/spacing.ts
1459
+ var spacing = {
1460
+ padding: {
1461
+ className: "p",
1462
+ shorthand: "p",
1463
+ values: "spacing"
1464
+ },
1465
+ paddingLeft: {
1466
+ className: "pl",
1467
+ shorthand: "pl",
1468
+ values: "spacing"
1469
+ },
1470
+ paddingRight: {
1471
+ className: "pr",
1472
+ shorthand: "pr",
1473
+ values: "spacing"
1474
+ },
1475
+ paddingTop: {
1476
+ className: "pt",
1477
+ shorthand: "pt",
1478
+ values: "spacing"
1479
+ },
1480
+ paddingBottom: {
1481
+ className: "pb",
1482
+ shorthand: "pb",
1483
+ values: "spacing"
1484
+ },
1485
+ paddingBlock: {
1486
+ className: "py",
1487
+ values: "spacing",
1488
+ shorthand: ["py", "paddingY"]
1489
+ },
1490
+ paddingBlockEnd: {
1491
+ className: "pb",
1492
+ values: "spacing"
1493
+ },
1494
+ paddingBlockStart: {
1495
+ className: "pt",
1496
+ values: "spacing"
1497
+ },
1498
+ paddingInline: {
1499
+ className: "px",
1500
+ values: "spacing",
1501
+ shorthand: ["paddingX", "px"]
1502
+ },
1503
+ paddingInlineEnd: {
1504
+ className: "pe",
1505
+ shorthand: ["pe", "paddingEnd"],
1506
+ values: "spacing"
1507
+ },
1508
+ paddingInlineStart: {
1509
+ className: "ps",
1510
+ shorthand: ["ps", "paddingStart"],
1511
+ values: "spacing"
1512
+ },
1513
+ marginLeft: {
1514
+ className: "ml",
1515
+ shorthand: "ml",
1516
+ values: "spacing"
1517
+ },
1518
+ marginRight: {
1519
+ className: "mr",
1520
+ shorthand: "mr",
1521
+ values: "spacing"
1522
+ },
1523
+ marginTop: {
1524
+ className: "mt",
1525
+ shorthand: "mt",
1526
+ values: "spacing"
1527
+ },
1528
+ marginBottom: {
1529
+ className: "mb",
1530
+ shorthand: "mb",
1531
+ values: "spacing"
1532
+ },
1533
+ margin: {
1534
+ className: "m",
1535
+ shorthand: "m",
1536
+ values: "spacing"
1537
+ },
1538
+ marginBlock: {
1539
+ className: "my",
1540
+ values: "spacing",
1541
+ shorthand: ["my", "marginY"]
1542
+ },
1543
+ marginBlockEnd: {
1544
+ className: "mb",
1545
+ values: "spacing"
1546
+ },
1547
+ marginBlockStart: {
1548
+ className: "mt",
1549
+ values: "spacing"
1550
+ },
1551
+ marginInline: {
1552
+ className: "mx",
1553
+ values: "spacing",
1554
+ shorthand: ["mx", "marginX"]
1555
+ },
1556
+ marginInlineEnd: {
1557
+ className: "me",
1558
+ shorthand: ["me", "marginEnd"],
1559
+ values: "spacing"
1560
+ },
1561
+ marginInlineStart: {
1562
+ className: "ms",
1563
+ shorthand: ["ms", "marginStart"],
1564
+ values: "spacing"
1565
+ }
1566
+ };
1567
+
1568
+ // src/utilities/svg.ts
1569
+ var svg = {
1570
+ fill: {
1571
+ className: "fill",
1572
+ values: "colors"
1573
+ },
1574
+ stroke: {
1575
+ className: "stroke",
1576
+ values: "colors"
1577
+ }
1578
+ };
1579
+
1580
+ // src/utilities/tables.ts
1581
+ var tables = {
1582
+ borderCollapse: {
1583
+ className: "border"
1584
+ },
1585
+ borderSpacing: {
1586
+ className: "border-spacing",
1587
+ values: "spacing"
1588
+ },
1589
+ borderSpacingX: {
1590
+ className: "border-spacing-x",
1591
+ values: "spacing",
1592
+ transform(value) {
1593
+ return {
1594
+ borderSpacing: `${value} var(--border-spacing-y)`
1595
+ };
1596
+ }
1597
+ },
1598
+ borderSpacingY: {
1599
+ className: "border-spacing-y",
1600
+ values: "spacing",
1601
+ transform(value) {
1602
+ return {
1603
+ borderSpacing: `var(--border-spacing-x) ${value}`
1604
+ };
1605
+ }
1606
+ },
1607
+ tableLayout: {
1608
+ className: "table"
1609
+ }
1610
+ };
1611
+
1612
+ // src/utilities/transforms.ts
1613
+ var transformTemplate = [
1614
+ "rotate(var(--rotate))",
1615
+ "scaleX(var(--scale-x))",
1616
+ "scaleY(var(--scale-y))",
1617
+ "skewX(var(--skew-x))",
1618
+ "skewY(var(--skew-y))"
1619
+ ];
1620
+ var baseTransformTemplate = [
1621
+ "translateX(var(--translate-x))",
1622
+ "translateY(var(--translate-y))",
1623
+ ...transformTemplate
1624
+ ].join(" ");
1625
+ var gpuTransformTemplate = [
1626
+ "translate3d(var(--translate-x), var(--translate-y), 0)",
1627
+ ...transformTemplate
1628
+ ].join(" ");
1629
+ var transforms = {
1630
+ transform: {
1631
+ className: "transform",
1632
+ values: {
1633
+ auto: baseTransformTemplate,
1634
+ "auto-gpu": gpuTransformTemplate
1635
+ }
1636
+ },
1637
+ transformOrigin: {
1638
+ className: "origin"
1639
+ },
1640
+ scale: {
1641
+ className: "scale",
1642
+ transform(value) {
1643
+ return {
1644
+ "--scale-x": value,
1645
+ "--scale-y": value
1646
+ };
1647
+ }
1648
+ },
1649
+ scaleX: {
1650
+ className: "scale-x",
1651
+ transform(value) {
1652
+ return {
1653
+ "--scale-x": value
1654
+ };
1655
+ }
1656
+ },
1657
+ scaleY: {
1658
+ className: "scale-y",
1659
+ transform(value) {
1660
+ return {
1661
+ "--scale-y": value
1662
+ };
1663
+ }
1664
+ },
1665
+ rotate: {
1666
+ className: "rotate",
1667
+ transform(value) {
1668
+ return {
1669
+ "--rotate": value
1670
+ };
1671
+ }
1672
+ },
1673
+ translateX: {
1674
+ shorthand: "x",
1675
+ className: "translate-x",
1676
+ values(theme) {
1677
+ return {
1678
+ ...theme("spacing"),
1679
+ "1/2": "50%",
1680
+ "1/3": "33.333333%",
1681
+ "2/3": "66.666667%",
1682
+ "1/4": "25%",
1683
+ "2/4": "50%",
1684
+ "3/4": "75%",
1685
+ full: "100%"
1686
+ };
1687
+ },
1688
+ transform(value) {
1689
+ return {
1690
+ "--translate-x": value
1691
+ };
1692
+ }
1693
+ },
1694
+ translateY: {
1695
+ shorthand: "y",
1696
+ className: "translate-y",
1697
+ values(theme) {
1698
+ return {
1699
+ ...theme("spacing"),
1700
+ "1/2": "50%",
1701
+ "1/3": "33.333333%",
1702
+ "2/3": "66.666667%",
1703
+ "1/4": "25%",
1704
+ "2/4": "50%",
1705
+ "3/4": "75%",
1706
+ full: "100%"
1707
+ };
1708
+ },
1709
+ transform(value) {
1710
+ return {
1711
+ "--translate-y": value
1712
+ };
1713
+ }
1714
+ },
1715
+ skewX: {
1716
+ className: "skew-x",
1717
+ transform(value) {
1718
+ return {
1719
+ "--skew-x": value
1720
+ };
1721
+ }
1722
+ },
1723
+ skewY: {
1724
+ className: "skew-y",
1725
+ transform(value) {
1726
+ return {
1727
+ "--skew-y": value
1728
+ };
1729
+ }
1730
+ }
1731
+ };
1732
+
1733
+ // src/utilities/transitions.ts
1734
+ var transitions = {
1735
+ transitionTimingFunction: {
1736
+ className: "ease",
1737
+ values: "easings"
1738
+ },
1739
+ transitionDelay: {
1740
+ className: "delay",
1741
+ values: "durations"
1742
+ },
1743
+ transitionDuration: {
1744
+ className: "duration",
1745
+ values: "durations"
1746
+ },
1747
+ transitionProperty: {
1748
+ className: "transition",
1749
+ values: {
1750
+ all: "all",
1751
+ none: "none",
1752
+ opacity: "opacity",
1753
+ shadow: "box-shadow",
1754
+ transform: "transform",
1755
+ base: "color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",
1756
+ background: "background, background-color",
1757
+ colors: "color, background-color, border-color, outline-color, text-decoration-color, fill, stroke"
1758
+ }
1759
+ },
1760
+ animation: {
1761
+ className: "animation",
1762
+ values: "animations"
1763
+ },
1764
+ animationDelay: {
1765
+ className: "animation-delay",
1766
+ values: "durations"
1767
+ }
1768
+ };
1769
+
1770
+ // src/utilities/typography.ts
1771
+ var typography = {
1772
+ color: {
1773
+ className: "text",
1774
+ values: "colors"
1775
+ },
1776
+ fontFamily: {
1777
+ className: "font",
1778
+ values: "fonts"
1779
+ },
1780
+ fontSize: {
1781
+ className: "fs",
1782
+ values: "fontSizes"
1783
+ },
1784
+ fontWeight: {
1785
+ className: "font",
1786
+ values: "fontWeights"
1787
+ },
1788
+ fontSmoothing: {
1789
+ className: "smoothing",
1790
+ values: {
1791
+ antialiased: "antialiased",
1792
+ "subpixel-antialiased": "auto"
1793
+ },
1794
+ transform(value) {
1795
+ return {
1796
+ WebkitFontSmoothing: value
1797
+ };
1798
+ }
1799
+ },
1800
+ fontVariantNumeric: {
1801
+ className: "numeric"
1802
+ },
1803
+ letterSpacing: {
1804
+ className: "tracking",
1805
+ values: "letterSpacings"
1806
+ },
1807
+ lineHeight: {
1808
+ className: "leading",
1809
+ values: "lineHeights"
1810
+ },
1811
+ textAlign: {
1812
+ className: "text"
1813
+ },
1814
+ textDecoration: {
1815
+ className: "text-decor"
1816
+ },
1817
+ textDecorationColor: {
1818
+ className: "text-decor",
1819
+ values: "colors"
1820
+ },
1821
+ textEmphasisColor: {
1822
+ className: "text-emphasis",
1823
+ values: "colors"
1824
+ },
1825
+ textDecorationStyle: {
1826
+ className: "decoration"
1827
+ },
1828
+ textDecorationThickness: {
1829
+ className: "decoration"
1830
+ },
1831
+ textUnderlineOffset: {
1832
+ className: "underline-offset"
1833
+ },
1834
+ textTransform: {
1835
+ className: "text"
1836
+ },
1837
+ textIndent: {
1838
+ className: "indent",
1839
+ values: "spacing"
1840
+ },
1841
+ textShadow: {
1842
+ className: "text-shadow",
1843
+ values: "shadows"
1844
+ },
1845
+ textOverflow: {
1846
+ className: "text"
1847
+ },
1848
+ verticalAlign: {
1849
+ className: "align"
1850
+ },
1851
+ wordBreak: {
1852
+ className: "break"
1853
+ },
1854
+ textWrap: {
1855
+ className: "text",
1856
+ values: ["wrap", "balance", "nowrap"],
1857
+ transform(value) {
1858
+ return { textWrap: value };
1859
+ }
1860
+ },
1861
+ truncate: {
1862
+ className: "truncate",
1863
+ values: { type: "boolean" },
1864
+ transform(value) {
1865
+ if (!value)
1866
+ return {};
1867
+ return {
1868
+ overflow: "hidden",
1869
+ textOverflow: "ellipsis",
1870
+ whiteSpace: "nowrap"
1871
+ };
1872
+ }
1873
+ },
1874
+ lineClamp: {
1875
+ className: "clamp",
1876
+ transform(value) {
1877
+ if (value === "none") {
1878
+ return {
1879
+ WebkitLineClamp: "unset"
1880
+ };
1881
+ }
1882
+ return {
1883
+ overflow: "hidden",
1884
+ display: "-webkit-box",
1885
+ WebkitLineClamp: value,
1886
+ WebkitBoxOrient: "vertical"
1887
+ };
1888
+ }
1889
+ }
1890
+ };
1891
+
1892
+ // src/utilities/index.ts
1893
+ var utilities = Object.assign(
1894
+ {},
1895
+ layout,
1896
+ display,
1897
+ flexGrid,
1898
+ spacing,
1899
+ outline,
1900
+ divide,
1901
+ sizing,
1902
+ typography,
1903
+ list,
1904
+ background,
1905
+ border,
1906
+ effects,
1907
+ tables,
1908
+ transitions,
1909
+ transforms,
1910
+ interactivity,
1911
+ svg,
1912
+ helpers
1913
+ );
1914
+
1915
+ // src/patterns.ts
1916
+ function definePattern(config) {
1917
+ return config;
1918
+ }
1919
+ var box = definePattern({
1920
+ properties: {},
1921
+ transform(props) {
1922
+ return props;
1923
+ }
1924
+ });
1925
+ var flex = definePattern({
1926
+ properties: {
1927
+ align: { type: "property", value: "alignItems" },
1928
+ justify: { type: "property", value: "justifyContent" },
1929
+ direction: { type: "property", value: "flexDirection" },
1930
+ wrap: { type: "property", value: "flexWrap" },
1931
+ basis: { type: "property", value: "flexBasis" },
1932
+ grow: { type: "property", value: "flexGrow" },
1933
+ shrink: { type: "property", value: "flexShrink" }
1934
+ },
1935
+ transform(props) {
1936
+ const { direction, align, justify, wrap: wrap2, basis, grow, shrink, ...rest } = props;
1937
+ return {
1938
+ display: "flex",
1939
+ flexDirection: direction,
1940
+ alignItems: align,
1941
+ justifyContent: justify,
1942
+ flexWrap: wrap2,
1943
+ flexBasis: basis,
1944
+ flexGrow: grow,
1945
+ flexShrink: shrink,
1946
+ ...rest
1947
+ };
1948
+ }
1949
+ });
1950
+ var stack = definePattern({
1951
+ properties: {
1952
+ align: { type: "property", value: "alignItems" },
1953
+ justify: { type: "property", value: "justifyContent" },
1954
+ direction: { type: "property", value: "flexDirection" },
1955
+ gap: { type: "property", value: "gap" }
1956
+ },
1957
+ transform(props) {
1958
+ const { align, justify, direction = "column", gap = "10px", ...rest } = props;
1959
+ return {
1960
+ display: "flex",
1961
+ flexDirection: direction,
1962
+ alignItems: align,
1963
+ justifyContent: justify,
1964
+ gap,
1965
+ ...rest
1966
+ };
1967
+ }
1968
+ });
1969
+ var vstack = definePattern({
1970
+ jsx: "VStack",
1971
+ properties: {
1972
+ justify: { type: "property", value: "justifyContent" },
1973
+ gap: { type: "property", value: "gap" }
1974
+ },
1975
+ transform(props) {
1976
+ const { justify, gap = "10px", ...rest } = props;
1977
+ return {
1978
+ display: "flex",
1979
+ alignItems: "center",
1980
+ justifyContent: justify,
1981
+ gap,
1982
+ flexDirection: "column",
1983
+ ...rest
1984
+ };
1985
+ }
1986
+ });
1987
+ var hstack = definePattern({
1988
+ jsx: "HStack",
1989
+ properties: {
1990
+ justify: { type: "property", value: "justifyContent" },
1991
+ gap: { type: "property", value: "gap" }
1992
+ },
1993
+ transform(props) {
1994
+ const { justify, gap = "10px", ...rest } = props;
1995
+ return {
1996
+ display: "flex",
1997
+ alignItems: "center",
1998
+ justifyContent: justify,
1999
+ gap,
2000
+ flexDirection: "row",
2001
+ ...rest
2002
+ };
2003
+ }
2004
+ });
2005
+ var spacer = definePattern({
2006
+ properties: {
2007
+ size: { type: "token", value: "spacing" }
2008
+ },
2009
+ transform(props, { map }) {
2010
+ const { size, ...rest } = props;
2011
+ return {
2012
+ alignSelf: "stretch",
2013
+ justifySelf: "stretch",
2014
+ flex: map(size, (v) => v == null ? "1" : `0 0 ${v}`),
2015
+ ...rest
2016
+ };
2017
+ }
2018
+ });
2019
+ var circle = definePattern({
2020
+ properties: {
2021
+ size: { type: "property", value: "width" }
2022
+ },
2023
+ transform(props) {
2024
+ const { size, ...rest } = props;
2025
+ return {
2026
+ display: "flex",
2027
+ alignItems: "center",
2028
+ justifyContent: "center",
2029
+ flex: "0 0 auto",
2030
+ width: size,
2031
+ height: size,
2032
+ borderRadius: "9999px",
2033
+ ...rest
2034
+ };
2035
+ }
2036
+ });
2037
+ var square = definePattern({
2038
+ properties: {
2039
+ size: { type: "property", value: "width" }
2040
+ },
2041
+ transform(props) {
2042
+ const { size, ...rest } = props;
2043
+ return {
2044
+ display: "flex",
2045
+ alignItems: "center",
2046
+ justifyContent: "center",
2047
+ flex: "0 0 auto",
2048
+ width: size,
2049
+ height: size,
2050
+ ...rest
2051
+ };
2052
+ }
2053
+ });
2054
+ var absoluteCenter = definePattern({
2055
+ properties: {
2056
+ axis: { type: "enum", value: ["x", "y", "both"] }
2057
+ },
2058
+ transform(props, { map }) {
2059
+ const { axis = "both", ...rest } = props;
2060
+ return {
2061
+ position: "absolute",
2062
+ insetBlockStart: map(axis, (v) => v === "x" ? "auto" : "50%"),
2063
+ insetInlineStart: map(axis, (v) => v === "y" ? "auto" : "50%"),
2064
+ transform: map(
2065
+ axis,
2066
+ (v) => v === "both" ? "translate(-50%, -50%)" : v === "x" ? "translateX(-50%)" : "translateY(-50%)"
2067
+ ),
2068
+ maxWidth: "100%",
2069
+ maxHeight: "100%",
2070
+ ...rest
2071
+ };
2072
+ }
2073
+ });
2074
+ var grid = definePattern({
2075
+ properties: {
2076
+ gap: { type: "property", value: "gap" },
2077
+ columnGap: { type: "property", value: "gap" },
2078
+ rowGap: { type: "property", value: "gap" },
2079
+ columns: { type: "number" },
2080
+ minChildWidth: { type: "token", value: "sizes", property: "width" }
2081
+ },
2082
+ transform(props, { map }) {
2083
+ const { columnGap, rowGap, gap = columnGap || rowGap ? void 0 : "10px", columns, minChildWidth, ...rest } = props;
2084
+ return {
2085
+ display: "grid",
2086
+ gridTemplateColumns: columns != null ? map(columns, (v) => `repeat(${v}, minmax(0, 1fr))`) : minChildWidth != null ? map(minChildWidth, (v) => `repeat(auto-fit, minmax(${v}, 1fr))`) : void 0,
2087
+ gap,
2088
+ columnGap,
2089
+ rowGap,
2090
+ ...rest
2091
+ };
2092
+ }
2093
+ });
2094
+ var gridItem = definePattern({
2095
+ properties: {
2096
+ colSpan: { type: "number" },
2097
+ rowSpan: { type: "number" },
2098
+ colStart: { type: "number" },
2099
+ rowStart: { type: "number" },
2100
+ colEnd: { type: "number" },
2101
+ rowEnd: { type: "number" }
2102
+ },
2103
+ transform(props, { map }) {
2104
+ const { colSpan, rowSpan, colStart, rowStart, colEnd, rowEnd, ...rest } = props;
2105
+ const spanFn = (v) => v === "auto" ? v : `span ${v}`;
2106
+ return {
2107
+ gridColumn: colSpan != null ? map(colSpan, spanFn) : void 0,
2108
+ gridRow: rowSpan != null ? map(rowSpan, spanFn) : void 0,
2109
+ gridColumnEnd: colEnd,
2110
+ gridRowEnd: rowEnd,
2111
+ ...rest
2112
+ };
2113
+ }
2114
+ });
2115
+ var wrap = definePattern({
2116
+ properties: {
2117
+ gap: { type: "property", value: "gap" },
2118
+ rowGap: { type: "property", value: "gap" },
2119
+ columnGap: { type: "property", value: "gap" },
2120
+ align: { type: "property", value: "alignItems" },
2121
+ justify: { type: "property", value: "justifyContent" }
2122
+ },
2123
+ transform(props) {
2124
+ const { columnGap, rowGap, gap = columnGap || rowGap ? void 0 : "10px", align, justify, ...rest } = props;
2125
+ return {
2126
+ display: "flex",
2127
+ flexWrap: "wrap",
2128
+ alignItems: align,
2129
+ justifyContent: justify,
2130
+ gap,
2131
+ columnGap,
2132
+ rowGap,
2133
+ ...rest
2134
+ };
2135
+ }
2136
+ });
2137
+ var container = definePattern({
2138
+ properties: {},
2139
+ transform(props) {
2140
+ return {
2141
+ position: "relative",
2142
+ maxWidth: "8xl",
2143
+ mx: "auto",
2144
+ px: { base: "4", md: "6", lg: "8" },
2145
+ ...props
2146
+ };
2147
+ }
2148
+ });
2149
+ var center = definePattern({
2150
+ properties: {
2151
+ inline: { type: "boolean" }
2152
+ },
2153
+ transform(props) {
2154
+ const { inline, ...rest } = props;
2155
+ return {
2156
+ display: inline ? "inline-flex" : "flex",
2157
+ alignItems: "center",
2158
+ justifyContent: "center",
2159
+ ...rest
2160
+ };
2161
+ }
2162
+ });
2163
+ var aspectRatio = definePattern({
2164
+ properties: {
2165
+ ratio: { type: "number" }
2166
+ },
2167
+ blocklist: ["aspectRatio"],
2168
+ transform(props) {
2169
+ const { ratio, ...rest } = props;
2170
+ return {
2171
+ aspectRatio: ratio,
2172
+ overflow: "hidden",
2173
+ display: "flex",
2174
+ justifyContent: "center",
2175
+ alignItems: "center",
2176
+ "&>img, &>video": {
2177
+ width: "100%",
2178
+ height: "100%",
2179
+ objectFit: "cover"
2180
+ },
2181
+ ...rest
2182
+ };
2183
+ }
2184
+ });
2185
+ var divider = definePattern({
2186
+ properties: {
2187
+ orientation: { type: "enum", value: ["horizontal", "vertical"] },
2188
+ thickness: { type: "token", value: "sizes", property: "borderWidth" },
2189
+ color: { type: "token", value: "colors", property: "borderColor" }
2190
+ },
2191
+ transform(props, { map }) {
2192
+ const { orientation = "horizontal", thickness = "1px", color, ...rest } = props;
2193
+ return {
2194
+ "--thickness": thickness,
2195
+ width: map(orientation, (v) => v === "vertical" ? void 0 : "100%"),
2196
+ height: map(orientation, (v) => v === "horizontal" ? void 0 : "100%"),
2197
+ borderInlineStartWidth: map(orientation, (v) => v === "horizontal" ? "var(--thickness)" : void 0),
2198
+ borderInlineEndWidth: map(orientation, (v) => v === "vertical" ? "var(--thickness)" : void 0),
2199
+ borderColor: color,
2200
+ ...rest
2201
+ };
2202
+ }
2203
+ });
2204
+ var float = definePattern({
2205
+ properties: {
2206
+ offsetX: { type: "token", value: "spacing", property: "left" },
2207
+ offsetY: { type: "token", value: "spacing", property: "top" },
2208
+ offset: { type: "token", value: "spacing", property: "top" },
2209
+ placement: {
2210
+ type: "enum",
2211
+ value: [
2212
+ "bottom-end",
2213
+ "bottom-start",
2214
+ "top-end",
2215
+ "top-start",
2216
+ "bottom-center",
2217
+ "top-center",
2218
+ "middle-center",
2219
+ "middle-end",
2220
+ "middle-start"
2221
+ ]
2222
+ }
2223
+ },
2224
+ transform(props, { map }) {
2225
+ const { offset = "0", offsetX = offset, offsetY = offset, placement = "top-end", ...rest } = props;
2226
+ return {
2227
+ display: "inline-flex",
2228
+ justifyContent: "center",
2229
+ alignItems: "center",
2230
+ position: "absolute",
2231
+ insetBlockStart: map(placement, (v) => {
2232
+ const [side] = v.split("-");
2233
+ const map2 = { top: offsetY, middle: "50%", bottom: "auto" };
2234
+ return map2[side];
2235
+ }),
2236
+ insetBlockEnd: map(placement, (v) => {
2237
+ const [side] = v.split("-");
2238
+ const map2 = { top: "auto", middle: "50%", bottom: offsetY };
2239
+ return map2[side];
2240
+ }),
2241
+ insetInlineStart: map(placement, (v) => {
2242
+ const [, align] = v.split("-");
2243
+ const map2 = { start: offsetX, center: "50%", end: "auto" };
2244
+ return map2[align];
2245
+ }),
2246
+ insetInlineEnd: map(placement, (v) => {
2247
+ const [, align] = v.split("-");
2248
+ const map2 = { start: "auto", center: "50%", end: offsetX };
2249
+ return map2[align];
2250
+ }),
2251
+ translate: map(placement, (v) => {
2252
+ const [side, align] = v.split("-");
2253
+ const mapX = { start: "-50%", center: "-50%", end: "50%" };
2254
+ const mapY = { top: "-50%", middle: "-50%", bottom: "50%" };
2255
+ return `${mapX[align]} ${mapY[side]}`;
2256
+ }),
2257
+ ...rest
2258
+ };
2259
+ }
2260
+ });
2261
+ var patterns = {
2262
+ box,
2263
+ flex,
2264
+ stack,
2265
+ vstack,
2266
+ hstack,
2267
+ spacer,
2268
+ square,
2269
+ circle,
2270
+ center,
2271
+ absoluteCenter,
2272
+ aspectRatio,
2273
+ grid,
2274
+ gridItem,
2275
+ wrap,
2276
+ container,
2277
+ divider,
2278
+ float
2279
+ };
2280
+
2281
+ // src/index.ts
2282
+ var definePreset = (preset2) => preset2;
2283
+ var preset = definePreset({
2284
+ conditions,
2285
+ utilities,
2286
+ patterns
2287
+ });
2288
+ var src_default = preset;
2289
+ export {
2290
+ src_default as default,
2291
+ preset
2292
+ };