@bamboocss/preset-base 1.11.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.
package/dist/index.js ADDED
@@ -0,0 +1,3355 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/index.ts
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
+ default: () => index_default,
24
+ preset: () => preset
25
+ });
26
+ module.exports = __toCommonJS(index_exports);
27
+
28
+ // src/conditions.ts
29
+ var conditions = {
30
+ hover: "&:is(:hover, [data-hover])",
31
+ focus: "&:is(:focus, [data-focus])",
32
+ focusWithin: "&:focus-within",
33
+ focusVisible: "&:is(:focus-visible, [data-focus-visible])",
34
+ disabled: "&:is(:disabled, [disabled], [data-disabled], [aria-disabled=true])",
35
+ active: "&:is(:active, [data-active])",
36
+ visited: "&:visited",
37
+ target: "&:target",
38
+ readOnly: "&:is(:read-only, [data-read-only], [aria-readonly=true])",
39
+ readWrite: "&:read-write",
40
+ empty: "&:is(:empty, [data-empty])",
41
+ checked: '&:is(:checked, [data-checked], [aria-checked=true], [data-state="checked"])',
42
+ enabled: "&:enabled",
43
+ expanded: '&:is([aria-expanded=true], [data-expanded], [data-state="expanded"])',
44
+ highlighted: "&[data-highlighted]",
45
+ complete: "&[data-complete]",
46
+ incomplete: "&[data-incomplete]",
47
+ dragging: "&[data-dragging]",
48
+ before: "&::before",
49
+ after: "&::after",
50
+ firstLetter: "&::first-letter",
51
+ firstLine: "&::first-line",
52
+ marker: "&::marker, &::-webkit-details-marker",
53
+ selection: "&::selection",
54
+ file: "&::file-selector-button",
55
+ backdrop: "&::backdrop",
56
+ first: "&:first-child",
57
+ last: "&:last-child",
58
+ only: "&:only-child",
59
+ even: "&:nth-child(even)",
60
+ odd: "&:nth-child(odd)",
61
+ firstOfType: "&:first-of-type",
62
+ lastOfType: "&:last-of-type",
63
+ onlyOfType: "&:only-of-type",
64
+ peerFocus: ".peer:is(:focus, [data-focus]) ~ &",
65
+ peerHover: ".peer:is(:hover, [data-hover]) ~ &",
66
+ peerActive: ".peer:is(:active, [data-active]) ~ &",
67
+ peerFocusWithin: ".peer:focus-within ~ &",
68
+ peerFocusVisible: ".peer:is(:focus-visible, [data-focus-visible]) ~ &",
69
+ peerDisabled: ".peer:is(:disabled, [disabled], [data-disabled], [aria-disabled=true]) ~ &",
70
+ peerChecked: '.peer:is(:checked, [data-checked], [aria-checked=true], [data-state="checked"]) ~ &',
71
+ peerInvalid: ".peer:is(:invalid, [data-invalid], [aria-invalid=true]) ~ &",
72
+ peerExpanded: '.peer:is([aria-expanded=true], [data-expanded], [data-state="expanded"]) ~ &',
73
+ peerPlaceholderShown: ".peer:placeholder-shown ~ &",
74
+ groupFocus: ".group:is(:focus, [data-focus]) &",
75
+ groupHover: ".group:is(:hover, [data-hover]) &",
76
+ groupActive: ".group:is(:active, [data-active]) &",
77
+ groupFocusWithin: ".group:focus-within &",
78
+ groupFocusVisible: ".group:is(:focus-visible, [data-focus-visible]) &",
79
+ groupDisabled: ".group:is(:disabled, [disabled], [data-disabled], [aria-disabled=true]) &",
80
+ groupChecked: '.group:is(:checked, [data-checked], [aria-checked=true], [data-state="checked"]) &',
81
+ groupExpanded: '.group:is([aria-expanded=true], [data-expanded], [data-state="expanded"]) &',
82
+ groupInvalid: ".group:is(:invalid, [data-invalid], [aria-invalid=true]) &",
83
+ indeterminate: '&:is(:indeterminate, [data-indeterminate], [aria-checked=mixed], [data-state="indeterminate"])',
84
+ required: "&:is(:required, [data-required], [aria-required=true])",
85
+ valid: "&:is(:valid, [data-valid])",
86
+ invalid: "&:is(:invalid, [data-invalid], [aria-invalid=true])",
87
+ autofill: "&:autofill",
88
+ inRange: "&:is(:in-range, [data-in-range])",
89
+ outOfRange: "&:is(:out-of-range, [data-outside-range])",
90
+ placeholder: "&::placeholder, &[data-placeholder]",
91
+ placeholderShown: "&:is(:placeholder-shown, [data-placeholder-shown])",
92
+ pressed: "&:is([aria-pressed=true], [data-pressed])",
93
+ selected: "&:is([aria-selected=true], [data-selected])",
94
+ grabbed: "&:is([aria-grabbed=true], [data-grabbed])",
95
+ underValue: "&[data-state=under-value]",
96
+ overValue: "&[data-state=over-value]",
97
+ atValue: "&[data-state=at-value]",
98
+ default: "&:default",
99
+ optional: "&:optional",
100
+ open: '&:is([open], [data-open], [data-state="open"], :popover-open)',
101
+ closed: '&:is([closed], [data-closed], [data-state="closed"])',
102
+ fullscreen: "&:is(:fullscreen, [data-fullscreen])",
103
+ loading: "&:is([data-loading], [aria-busy=true])",
104
+ hidden: "&:is([hidden], [data-hidden])",
105
+ current: "&:is([aria-current=true], [data-current])",
106
+ currentPage: "&[aria-current=page]",
107
+ currentStep: "&[aria-current=step]",
108
+ today: "&[data-today]",
109
+ unavailable: "&[data-unavailable]",
110
+ rangeStart: "&[data-range-start]",
111
+ rangeEnd: "&[data-range-end]",
112
+ now: "&[data-now]",
113
+ topmost: "&[data-topmost]",
114
+ motionReduce: "@media (prefers-reduced-motion: reduce)",
115
+ motionSafe: "@media (prefers-reduced-motion: no-preference)",
116
+ print: "@media print",
117
+ landscape: "@media (orientation: landscape)",
118
+ portrait: "@media (orientation: portrait)",
119
+ dark: ".dark &",
120
+ light: ".light &",
121
+ osDark: "@media (prefers-color-scheme: dark)",
122
+ osLight: "@media (prefers-color-scheme: light)",
123
+ highContrast: "@media (forced-colors: active)",
124
+ lessContrast: "@media (prefers-contrast: less)",
125
+ moreContrast: "@media (prefers-contrast: more)",
126
+ ltr: ":where([dir=ltr], :dir(ltr)) &",
127
+ rtl: ":where([dir=rtl], :dir(rtl)) &",
128
+ scrollbar: "&::-webkit-scrollbar",
129
+ scrollbarThumb: "&::-webkit-scrollbar-thumb",
130
+ scrollbarTrack: "&::-webkit-scrollbar-track",
131
+ horizontal: "&[data-orientation=horizontal]",
132
+ vertical: "&[data-orientation=vertical]",
133
+ icon: "& :where(svg)",
134
+ starting: "@starting-style",
135
+ noscript: "@media (scripting: none)",
136
+ invertedColors: "@media (inverted-colors: inverted)"
137
+ };
138
+
139
+ // src/global-css.ts
140
+ var EMPTY = "/*-*/ /*-*/";
141
+ var globalCss = {
142
+ "*, ::before, ::after, ::backdrop": {
143
+ "--blur": EMPTY,
144
+ "--brightness": EMPTY,
145
+ "--contrast": EMPTY,
146
+ "--grayscale": EMPTY,
147
+ "--hue-rotate": EMPTY,
148
+ "--invert": EMPTY,
149
+ "--saturate": EMPTY,
150
+ "--sepia": EMPTY,
151
+ "--drop-shadow": EMPTY,
152
+ "--backdrop-blur": EMPTY,
153
+ "--backdrop-brightness": EMPTY,
154
+ "--backdrop-contrast": EMPTY,
155
+ "--backdrop-grayscale": EMPTY,
156
+ "--backdrop-hue-rotate": EMPTY,
157
+ "--backdrop-invert": EMPTY,
158
+ "--backdrop-opacity": EMPTY,
159
+ "--backdrop-saturate": EMPTY,
160
+ "--backdrop-sepia": EMPTY,
161
+ "--gradient-from-position": EMPTY,
162
+ "--gradient-to-position": EMPTY,
163
+ "--gradient-via-position": EMPTY,
164
+ "--scroll-snap-strictness": "proximity",
165
+ "--border-spacing-x": 0,
166
+ "--border-spacing-y": 0,
167
+ "--translate-x": 0,
168
+ "--translate-y": 0,
169
+ "--rotate": 0,
170
+ "--rotate-x": 0,
171
+ "--rotate-y": 0,
172
+ "--skew-x": 0,
173
+ "--skew-y": 0,
174
+ "--scale-x": 1,
175
+ "--scale-y": 1
176
+ }
177
+ };
178
+
179
+ // src/patterns.ts
180
+ function definePattern(config) {
181
+ return config;
182
+ }
183
+ var box = definePattern({
184
+ transform(props) {
185
+ return props;
186
+ }
187
+ });
188
+ var flex = definePattern({
189
+ properties: {
190
+ align: { type: "property", value: "alignItems" },
191
+ justify: { type: "property", value: "justifyContent" },
192
+ direction: { type: "property", value: "flexDirection" },
193
+ wrap: { type: "property", value: "flexWrap" },
194
+ basis: { type: "property", value: "flexBasis" },
195
+ grow: { type: "property", value: "flexGrow" },
196
+ shrink: { type: "property", value: "flexShrink" }
197
+ },
198
+ transform(props) {
199
+ const { direction, align, justify, wrap: wrap2, basis, grow, shrink, ...rest } = props;
200
+ return {
201
+ display: "flex",
202
+ flexDirection: direction,
203
+ alignItems: align,
204
+ justifyContent: justify,
205
+ flexWrap: wrap2,
206
+ flexBasis: basis,
207
+ flexGrow: grow,
208
+ flexShrink: shrink,
209
+ ...rest
210
+ };
211
+ }
212
+ });
213
+ var stack = definePattern({
214
+ properties: {
215
+ align: { type: "property", value: "alignItems" },
216
+ justify: { type: "property", value: "justifyContent" },
217
+ direction: { type: "property", value: "flexDirection" },
218
+ gap: { type: "property", value: "gap" }
219
+ },
220
+ defaultValues: {
221
+ direction: "column",
222
+ gap: "8px"
223
+ },
224
+ transform(props) {
225
+ const { align, justify, direction, gap, ...rest } = props;
226
+ return {
227
+ display: "flex",
228
+ flexDirection: direction,
229
+ alignItems: align,
230
+ justifyContent: justify,
231
+ gap,
232
+ ...rest
233
+ };
234
+ }
235
+ });
236
+ var vstack = definePattern({
237
+ jsxName: "VStack",
238
+ properties: {
239
+ justify: { type: "property", value: "justifyContent" },
240
+ gap: { type: "property", value: "gap" }
241
+ },
242
+ defaultValues: {
243
+ gap: "8px"
244
+ },
245
+ transform(props) {
246
+ const { justify, gap, ...rest } = props;
247
+ return {
248
+ display: "flex",
249
+ alignItems: "center",
250
+ justifyContent: justify,
251
+ gap,
252
+ flexDirection: "column",
253
+ ...rest
254
+ };
255
+ }
256
+ });
257
+ var hstack = definePattern({
258
+ jsxName: "HStack",
259
+ properties: {
260
+ justify: { type: "property", value: "justifyContent" },
261
+ gap: { type: "property", value: "gap" }
262
+ },
263
+ defaultValues: {
264
+ gap: "8px"
265
+ },
266
+ transform(props) {
267
+ const { justify, gap, ...rest } = props;
268
+ return {
269
+ display: "flex",
270
+ alignItems: "center",
271
+ justifyContent: justify,
272
+ gap,
273
+ flexDirection: "row",
274
+ ...rest
275
+ };
276
+ }
277
+ });
278
+ var spacer = definePattern({
279
+ properties: {
280
+ size: { type: "token", value: "spacing" }
281
+ },
282
+ transform(props, { map, isCssUnit, isCssVar }) {
283
+ const { size, ...rest } = props;
284
+ return {
285
+ alignSelf: "stretch",
286
+ justifySelf: "stretch",
287
+ flex: map(size, (v) => {
288
+ if (v == null) return "1";
289
+ const val = isCssUnit(v) || isCssVar(v) ? v : `token(spacing.${v}, ${v})`;
290
+ return `0 0 ${val}`;
291
+ }),
292
+ ...rest
293
+ };
294
+ }
295
+ });
296
+ var circle = definePattern({
297
+ properties: {
298
+ size: { type: "property", value: "width" }
299
+ },
300
+ transform(props) {
301
+ const { size, ...rest } = props;
302
+ return {
303
+ display: "flex",
304
+ alignItems: "center",
305
+ justifyContent: "center",
306
+ flex: "0 0 auto",
307
+ width: size,
308
+ height: size,
309
+ borderRadius: "9999px",
310
+ ...rest
311
+ };
312
+ }
313
+ });
314
+ var square = definePattern({
315
+ properties: {
316
+ size: { type: "property", value: "width" }
317
+ },
318
+ transform(props) {
319
+ const { size, ...rest } = props;
320
+ return {
321
+ display: "flex",
322
+ alignItems: "center",
323
+ justifyContent: "center",
324
+ flex: "0 0 auto",
325
+ width: size,
326
+ height: size,
327
+ ...rest
328
+ };
329
+ }
330
+ });
331
+ var grid = definePattern({
332
+ properties: {
333
+ gap: { type: "property", value: "gap" },
334
+ columnGap: { type: "property", value: "gap" },
335
+ rowGap: { type: "property", value: "gap" },
336
+ columns: { type: "number" },
337
+ minChildWidth: { type: "token", value: "sizes", property: "width" }
338
+ },
339
+ defaultValues(props) {
340
+ return { gap: props.columnGap || props.rowGap ? void 0 : "8px" };
341
+ },
342
+ transform(props, { map, isCssUnit }) {
343
+ const { columnGap, rowGap, gap, columns, minChildWidth, ...rest } = props;
344
+ const getValue = (v) => isCssUnit(v) ? v : `token(sizes.${v}, ${v})`;
345
+ return {
346
+ display: "grid",
347
+ gridTemplateColumns: columns != null ? map(columns, (v) => `repeat(${v}, minmax(0, 1fr))`) : minChildWidth != null ? map(minChildWidth, (v) => `repeat(auto-fit, minmax(${getValue(v)}, 1fr))`) : void 0,
348
+ gap,
349
+ columnGap,
350
+ rowGap,
351
+ ...rest
352
+ };
353
+ }
354
+ });
355
+ var gridItem = definePattern({
356
+ properties: {
357
+ colSpan: { type: "number" },
358
+ rowSpan: { type: "number" },
359
+ colStart: { type: "number" },
360
+ rowStart: { type: "number" },
361
+ colEnd: { type: "number" },
362
+ rowEnd: { type: "number" }
363
+ },
364
+ transform(props, { map }) {
365
+ const { colSpan, rowSpan, colStart, rowStart, colEnd, rowEnd, ...rest } = props;
366
+ const spanFn = (v) => v === "auto" ? v : `span ${v}`;
367
+ return {
368
+ gridColumn: colSpan != null ? map(colSpan, spanFn) : void 0,
369
+ gridRow: rowSpan != null ? map(rowSpan, spanFn) : void 0,
370
+ gridColumnStart: colStart,
371
+ gridColumnEnd: colEnd,
372
+ gridRowStart: rowStart,
373
+ gridRowEnd: rowEnd,
374
+ ...rest
375
+ };
376
+ }
377
+ });
378
+ var wrap = definePattern({
379
+ properties: {
380
+ gap: { type: "property", value: "gap" },
381
+ rowGap: { type: "property", value: "gap" },
382
+ columnGap: { type: "property", value: "gap" },
383
+ align: { type: "property", value: "alignItems" },
384
+ justify: { type: "property", value: "justifyContent" }
385
+ },
386
+ transform(props) {
387
+ const { columnGap, rowGap, gap = columnGap || rowGap ? void 0 : "8px", align, justify, ...rest } = props;
388
+ return {
389
+ display: "flex",
390
+ flexWrap: "wrap",
391
+ alignItems: align,
392
+ justifyContent: justify,
393
+ gap,
394
+ columnGap,
395
+ rowGap,
396
+ ...rest
397
+ };
398
+ }
399
+ });
400
+ var container = definePattern({
401
+ transform(props) {
402
+ return {
403
+ position: "relative",
404
+ maxWidth: "8xl",
405
+ mx: "auto",
406
+ px: { base: "4", md: "6", lg: "8" },
407
+ ...props
408
+ };
409
+ }
410
+ });
411
+ var center = definePattern({
412
+ properties: {
413
+ inline: { type: "boolean" }
414
+ },
415
+ transform(props) {
416
+ const { inline, ...rest } = props;
417
+ return {
418
+ display: inline ? "inline-flex" : "flex",
419
+ alignItems: "center",
420
+ justifyContent: "center",
421
+ ...rest
422
+ };
423
+ }
424
+ });
425
+ var aspectRatio = definePattern({
426
+ properties: {
427
+ ratio: { type: "number" }
428
+ },
429
+ blocklist: ["aspectRatio"],
430
+ transform(props, { map }) {
431
+ const { ratio = 4 / 3, ...rest } = props;
432
+ return {
433
+ position: "relative",
434
+ _before: {
435
+ content: `""`,
436
+ display: "block",
437
+ height: "0",
438
+ paddingBottom: map(ratio, (r) => `${1 / r * 100}%`)
439
+ },
440
+ "&>*": {
441
+ display: "flex",
442
+ justifyContent: "center",
443
+ alignItems: "center",
444
+ overflow: "hidden",
445
+ position: "absolute",
446
+ inset: "0",
447
+ width: "100%",
448
+ height: "100%"
449
+ },
450
+ "&>img, &>video": {
451
+ objectFit: "cover"
452
+ },
453
+ ...rest
454
+ };
455
+ }
456
+ });
457
+ var divider = definePattern({
458
+ properties: {
459
+ orientation: { type: "enum", value: ["horizontal", "vertical"] },
460
+ thickness: { type: "token", value: "sizes", property: "borderWidth" },
461
+ color: { type: "token", value: "colors", property: "borderColor" }
462
+ },
463
+ defaultValues: {
464
+ orientation: "horizontal",
465
+ thickness: "1px"
466
+ },
467
+ transform(props, { map }) {
468
+ const { orientation, thickness, color, ...rest } = props;
469
+ return {
470
+ "--thickness": thickness,
471
+ width: map(orientation, (v) => v === "vertical" ? void 0 : "100%"),
472
+ height: map(orientation, (v) => v === "horizontal" ? void 0 : "100%"),
473
+ borderBlockEndWidth: map(orientation, (v) => v === "horizontal" ? "var(--thickness)" : void 0),
474
+ borderInlineEndWidth: map(orientation, (v) => v === "vertical" ? "var(--thickness)" : void 0),
475
+ borderColor: color,
476
+ ...rest
477
+ };
478
+ }
479
+ });
480
+ var linkOverlay = definePattern({
481
+ jsxElement: "a",
482
+ transform(props) {
483
+ return {
484
+ _before: {
485
+ content: '""',
486
+ position: "absolute",
487
+ inset: "0",
488
+ zIndex: "0",
489
+ ...props["_before"]
490
+ },
491
+ ...props
492
+ };
493
+ }
494
+ });
495
+ var float = definePattern({
496
+ properties: {
497
+ offsetX: { type: "token", value: "spacing", property: "left" },
498
+ offsetY: { type: "token", value: "spacing", property: "top" },
499
+ offset: { type: "token", value: "spacing", property: "top" },
500
+ placement: {
501
+ type: "enum",
502
+ value: [
503
+ "bottom-end",
504
+ "bottom-start",
505
+ "top-end",
506
+ "top-start",
507
+ "bottom-center",
508
+ "top-center",
509
+ "middle-center",
510
+ "middle-end",
511
+ "middle-start"
512
+ ]
513
+ }
514
+ },
515
+ defaultValues(props) {
516
+ const offset = props.offset || "0";
517
+ return { offset, offsetX: offset, offsetY: offset, placement: "top-end" };
518
+ },
519
+ transform(props, { map }) {
520
+ const { offset, offsetX, offsetY, placement, ...rest } = props;
521
+ return {
522
+ display: "inline-flex",
523
+ justifyContent: "center",
524
+ alignItems: "center",
525
+ position: "absolute",
526
+ insetBlockStart: map(placement, (v) => {
527
+ const [side] = v.split("-");
528
+ const map2 = { top: offsetY, middle: "50%", bottom: "auto" };
529
+ return map2[side];
530
+ }),
531
+ insetBlockEnd: map(placement, (v) => {
532
+ const [side] = v.split("-");
533
+ const map2 = { top: "auto", middle: "50%", bottom: offsetY };
534
+ return map2[side];
535
+ }),
536
+ insetInlineStart: map(placement, (v) => {
537
+ const [, align] = v.split("-");
538
+ const map2 = { start: offsetX, center: "50%", end: "auto" };
539
+ return map2[align];
540
+ }),
541
+ insetInlineEnd: map(placement, (v) => {
542
+ const [, align] = v.split("-");
543
+ const map2 = { start: "auto", center: "50%", end: offsetX };
544
+ return map2[align];
545
+ }),
546
+ translate: map(placement, (v) => {
547
+ const [side, align] = v.split("-");
548
+ const mapX = { start: "-50%", center: "-50%", end: "50%" };
549
+ const mapY = { top: "-50%", middle: "-50%", bottom: "50%" };
550
+ return `${mapX[align]} ${mapY[side]}`;
551
+ }),
552
+ ...rest
553
+ };
554
+ }
555
+ });
556
+ var bleed = definePattern({
557
+ properties: {
558
+ inline: { type: "property", value: "marginInline" },
559
+ block: { type: "property", value: "marginBlock" }
560
+ },
561
+ defaultValues: {
562
+ inline: "0",
563
+ block: "0"
564
+ },
565
+ transform(props, { map, isCssUnit, isCssVar }) {
566
+ const { inline, block, ...rest } = props;
567
+ const valueFn = (v) => isCssUnit(v) || isCssVar(v) ? v : `token(spacing.${v}, ${v})`;
568
+ return {
569
+ "--bleed-x": map(inline, valueFn),
570
+ "--bleed-y": map(block, valueFn),
571
+ marginInline: "calc(var(--bleed-x, 0) * -1)",
572
+ marginBlock: "calc(var(--bleed-y, 0) * -1)",
573
+ ...rest
574
+ };
575
+ }
576
+ });
577
+ var visuallyHidden = definePattern({
578
+ transform(props) {
579
+ return {
580
+ srOnly: true,
581
+ ...props
582
+ };
583
+ }
584
+ });
585
+ var cq = definePattern({
586
+ properties: {
587
+ name: { type: "token", value: "containerNames", property: "containerName" },
588
+ type: { type: "property", value: "containerType" }
589
+ },
590
+ defaultValues: {
591
+ type: "inline-size"
592
+ },
593
+ transform(props) {
594
+ const { name, type, ...rest } = props;
595
+ return {
596
+ containerType: type,
597
+ containerName: name,
598
+ ...rest
599
+ };
600
+ }
601
+ });
602
+ var patterns = {
603
+ box,
604
+ flex,
605
+ stack,
606
+ vstack,
607
+ hstack,
608
+ spacer,
609
+ square,
610
+ circle,
611
+ center,
612
+ linkOverlay,
613
+ aspectRatio,
614
+ grid,
615
+ gridItem,
616
+ wrap,
617
+ container,
618
+ divider,
619
+ float,
620
+ bleed,
621
+ visuallyHidden,
622
+ cq
623
+ };
624
+
625
+ // src/color-mix-transform.ts
626
+ var createColorMixTransform = (prop) => (value, args) => {
627
+ const mix = args.utils.colorMix(value);
628
+ if (mix.invalid) return { [prop]: value };
629
+ const cssVar = "--mix-" + prop;
630
+ return {
631
+ [cssVar]: mix.value,
632
+ [prop]: `var(${cssVar}, ${mix.color})`
633
+ };
634
+ };
635
+
636
+ // src/utilities/background.ts
637
+ var background = {
638
+ backgroundPosition: {
639
+ shorthand: "bgPosition",
640
+ className: "bg-p",
641
+ group: "Background"
642
+ },
643
+ backgroundPositionX: {
644
+ shorthand: "bgPositionX",
645
+ className: "bg-p-x",
646
+ group: "Background"
647
+ },
648
+ backgroundPositionY: {
649
+ shorthand: "bgPositionY",
650
+ className: "bg-p-y",
651
+ group: "Background"
652
+ },
653
+ backgroundAttachment: {
654
+ shorthand: "bgAttachment",
655
+ className: "bg-a",
656
+ group: "Background"
657
+ },
658
+ backgroundClip: {
659
+ shorthand: "bgClip",
660
+ className: "bg-cp",
661
+ group: "Background",
662
+ transform(value) {
663
+ return {
664
+ backgroundClip: value,
665
+ WebkitBackgroundClip: value
666
+ };
667
+ }
668
+ },
669
+ background: {
670
+ shorthand: "bg",
671
+ className: "bg",
672
+ values: "colors",
673
+ group: "Background",
674
+ transform: createColorMixTransform("background")
675
+ },
676
+ backgroundColor: {
677
+ shorthand: "bgColor",
678
+ className: "bg-c",
679
+ values: "colors",
680
+ group: "Background",
681
+ transform: createColorMixTransform("backgroundColor")
682
+ },
683
+ backgroundOrigin: {
684
+ shorthand: "bgOrigin",
685
+ className: "bg-o",
686
+ group: "Background"
687
+ },
688
+ backgroundImage: {
689
+ shorthand: "bgImage",
690
+ className: "bg-i",
691
+ values: "assets",
692
+ group: "Background"
693
+ },
694
+ backgroundRepeat: {
695
+ shorthand: "bgRepeat",
696
+ className: "bg-r",
697
+ group: "Background"
698
+ },
699
+ backgroundBlendMode: {
700
+ shorthand: "bgBlendMode",
701
+ className: "bg-bm",
702
+ group: "Background"
703
+ },
704
+ backgroundSize: {
705
+ shorthand: "bgSize",
706
+ className: "bg-s",
707
+ group: "Background"
708
+ }
709
+ };
710
+
711
+ // src/utilities/border.ts
712
+ var border = {
713
+ // Border Radius
714
+ borderRadius: {
715
+ className: "bdr",
716
+ shorthand: "rounded",
717
+ values: "radii",
718
+ group: "Border Radius"
719
+ },
720
+ borderTopLeftRadius: {
721
+ className: "bdr-tl",
722
+ shorthand: "roundedTopLeft",
723
+ values: "radii",
724
+ group: "Border Radius"
725
+ },
726
+ borderTopRightRadius: {
727
+ className: "bdr-tr",
728
+ shorthand: "roundedTopRight",
729
+ values: "radii",
730
+ group: "Border Radius"
731
+ },
732
+ borderBottomRightRadius: {
733
+ className: "bdr-br",
734
+ shorthand: "roundedBottomRight",
735
+ values: "radii",
736
+ group: "Border Radius"
737
+ },
738
+ borderBottomLeftRadius: {
739
+ className: "bdr-bl",
740
+ shorthand: "roundedBottomLeft",
741
+ values: "radii",
742
+ group: "Border Radius"
743
+ },
744
+ borderTopRadius: {
745
+ className: "bdr-t",
746
+ shorthand: "roundedTop",
747
+ property: "borderRadius",
748
+ values: "radii",
749
+ group: "Border Radius",
750
+ transform(value) {
751
+ return {
752
+ borderTopLeftRadius: value,
753
+ borderTopRightRadius: value
754
+ };
755
+ }
756
+ },
757
+ borderRightRadius: {
758
+ className: "bdr-r",
759
+ shorthand: "roundedRight",
760
+ property: "borderRadius",
761
+ values: "radii",
762
+ group: "Border Radius",
763
+ transform(value) {
764
+ return {
765
+ borderTopRightRadius: value,
766
+ borderBottomRightRadius: value
767
+ };
768
+ }
769
+ },
770
+ borderBottomRadius: {
771
+ className: "bdr-b",
772
+ shorthand: "roundedBottom",
773
+ property: "borderRadius",
774
+ values: "radii",
775
+ group: "Border Radius",
776
+ transform(value) {
777
+ return {
778
+ borderBottomLeftRadius: value,
779
+ borderBottomRightRadius: value
780
+ };
781
+ }
782
+ },
783
+ borderLeftRadius: {
784
+ className: "bdr-l",
785
+ shorthand: "roundedLeft",
786
+ values: "radii",
787
+ property: "borderRadius",
788
+ group: "Border Radius",
789
+ transform(value) {
790
+ return {
791
+ borderTopLeftRadius: value,
792
+ borderBottomLeftRadius: value
793
+ };
794
+ }
795
+ },
796
+ borderStartStartRadius: {
797
+ className: "bdr-ss",
798
+ shorthand: "roundedStartStart",
799
+ values: "radii",
800
+ group: "Border Radius"
801
+ },
802
+ borderStartEndRadius: {
803
+ className: "bdr-se",
804
+ shorthand: "roundedStartEnd",
805
+ values: "radii",
806
+ group: "Border Radius"
807
+ },
808
+ borderStartRadius: {
809
+ className: "bdr-s",
810
+ values: "radii",
811
+ property: "borderRadius",
812
+ shorthand: "roundedStart",
813
+ group: "Border Radius",
814
+ transform(value) {
815
+ return {
816
+ borderStartStartRadius: value,
817
+ borderEndStartRadius: value
818
+ };
819
+ }
820
+ },
821
+ borderEndStartRadius: {
822
+ className: "bdr-es",
823
+ shorthand: "roundedEndStart",
824
+ values: "radii",
825
+ group: "Border Radius"
826
+ },
827
+ borderEndEndRadius: {
828
+ className: "bdr-ee",
829
+ shorthand: "roundedEndEnd",
830
+ values: "radii",
831
+ group: "Border Radius"
832
+ },
833
+ borderEndRadius: {
834
+ className: "bdr-e",
835
+ shorthand: "roundedEnd",
836
+ property: "borderRadius",
837
+ values: "radii",
838
+ group: "Border Radius",
839
+ transform(value) {
840
+ return {
841
+ borderStartEndRadius: value,
842
+ borderEndEndRadius: value
843
+ };
844
+ }
845
+ },
846
+ // Border
847
+ border: {
848
+ className: "bd",
849
+ values: "borders",
850
+ group: "Border"
851
+ },
852
+ borderWidth: {
853
+ className: "bd-w",
854
+ values: "borderWidths",
855
+ group: "Border Radius"
856
+ },
857
+ borderTopWidth: {
858
+ className: "bd-t-w",
859
+ values: "borderWidths",
860
+ group: "Border"
861
+ },
862
+ borderLeftWidth: {
863
+ className: "bd-l-w",
864
+ values: "borderWidths",
865
+ group: "Border"
866
+ },
867
+ borderRightWidth: {
868
+ className: "bd-r-w",
869
+ values: "borderWidths",
870
+ group: "Border"
871
+ },
872
+ borderBottomWidth: {
873
+ className: "bd-b-w",
874
+ values: "borderWidths",
875
+ group: "Border"
876
+ },
877
+ borderBlockStartWidth: {
878
+ className: "bd-bs-w",
879
+ values: "borderWidths",
880
+ group: "Border Radius"
881
+ },
882
+ borderBlockEndWidth: {
883
+ className: "bd-be-w",
884
+ values: "borderWidths",
885
+ group: "Border Radius"
886
+ },
887
+ borderColor: {
888
+ className: "bd-c",
889
+ values: "colors",
890
+ group: "Border",
891
+ transform: createColorMixTransform("borderColor")
892
+ },
893
+ borderInline: {
894
+ className: "bd-x",
895
+ values: "borders",
896
+ group: "Border",
897
+ shorthand: "borderX"
898
+ },
899
+ borderInlineWidth: {
900
+ className: "bd-x-w",
901
+ values: "borderWidths",
902
+ group: "Border",
903
+ shorthand: "borderXWidth"
904
+ },
905
+ borderInlineColor: {
906
+ className: "bd-x-c",
907
+ values: "colors",
908
+ group: "Border",
909
+ shorthand: "borderXColor",
910
+ transform: createColorMixTransform("borderInlineColor")
911
+ },
912
+ borderBlock: {
913
+ className: "bd-y",
914
+ values: "borders",
915
+ group: "Border",
916
+ shorthand: "borderY"
917
+ },
918
+ borderBlockWidth: {
919
+ className: "bd-y-w",
920
+ values: "borderWidths",
921
+ group: "Border",
922
+ shorthand: "borderYWidth"
923
+ },
924
+ borderBlockColor: {
925
+ className: "bd-y-c",
926
+ values: "colors",
927
+ group: "Border",
928
+ shorthand: "borderYColor",
929
+ transform: createColorMixTransform("borderBlockColor")
930
+ },
931
+ borderLeft: {
932
+ className: "bd-l",
933
+ values: "borders",
934
+ group: "Border"
935
+ },
936
+ borderLeftColor: {
937
+ className: "bd-l-c",
938
+ values: "colors",
939
+ group: "Border",
940
+ transform: createColorMixTransform("borderLeftColor")
941
+ },
942
+ borderInlineStart: {
943
+ className: "bd-s",
944
+ values: "borders",
945
+ group: "Border",
946
+ shorthand: "borderStart"
947
+ },
948
+ borderInlineStartWidth: {
949
+ className: "bd-s-w",
950
+ values: "borderWidths",
951
+ group: "Border",
952
+ shorthand: "borderStartWidth"
953
+ },
954
+ borderInlineStartColor: {
955
+ className: "bd-s-c",
956
+ values: "colors",
957
+ group: "Border",
958
+ shorthand: "borderStartColor",
959
+ transform: createColorMixTransform("borderInlineStartColor")
960
+ },
961
+ borderRight: {
962
+ className: "bd-r",
963
+ values: "borders",
964
+ group: "Border"
965
+ },
966
+ borderRightColor: {
967
+ className: "bd-r-c",
968
+ values: "colors",
969
+ group: "Border",
970
+ transform: createColorMixTransform("borderRightColor")
971
+ },
972
+ borderInlineEnd: {
973
+ className: "bd-e",
974
+ values: "borders",
975
+ group: "Border",
976
+ shorthand: "borderEnd"
977
+ },
978
+ borderInlineEndWidth: {
979
+ className: "bd-e-w",
980
+ values: "borderWidths",
981
+ group: "Border",
982
+ shorthand: "borderEndWidth"
983
+ },
984
+ borderInlineEndColor: {
985
+ className: "bd-e-c",
986
+ values: "colors",
987
+ group: "Border",
988
+ shorthand: "borderEndColor",
989
+ transform: createColorMixTransform("borderInlineEndColor")
990
+ },
991
+ borderTop: {
992
+ className: "bd-t",
993
+ values: "borders",
994
+ group: "Border"
995
+ },
996
+ borderTopColor: {
997
+ className: "bd-t-c",
998
+ values: "colors",
999
+ group: "Border",
1000
+ transform: createColorMixTransform("borderTopColor")
1001
+ },
1002
+ borderBottom: {
1003
+ className: "bd-b",
1004
+ values: "borders",
1005
+ group: "Border"
1006
+ },
1007
+ borderBottomColor: {
1008
+ className: "bd-b-c",
1009
+ values: "colors",
1010
+ group: "Border",
1011
+ transform: createColorMixTransform("borderBottomColor")
1012
+ },
1013
+ borderBlockEnd: {
1014
+ className: "bd-be",
1015
+ values: "borders",
1016
+ group: "Border"
1017
+ },
1018
+ borderBlockEndColor: {
1019
+ className: "bd-be-c",
1020
+ values: "colors",
1021
+ group: "Border",
1022
+ transform: createColorMixTransform("borderBlockEndColor")
1023
+ },
1024
+ borderBlockStart: {
1025
+ className: "bd-bs",
1026
+ values: "borders",
1027
+ group: "Border"
1028
+ },
1029
+ borderBlockStartColor: {
1030
+ className: "bd-bs-c",
1031
+ values: "colors",
1032
+ group: "Border",
1033
+ transform: createColorMixTransform("borderBlockStartColor")
1034
+ }
1035
+ };
1036
+
1037
+ // src/utilities/container.ts
1038
+ var container2 = {
1039
+ container: {
1040
+ className: "cq",
1041
+ group: "Container"
1042
+ },
1043
+ containerName: {
1044
+ className: "cq-n",
1045
+ property: "containerName",
1046
+ values: "containerNames",
1047
+ group: "Container"
1048
+ },
1049
+ containerType: {
1050
+ className: "cq-t",
1051
+ group: "Container"
1052
+ }
1053
+ };
1054
+
1055
+ // src/utilities/cursor.ts
1056
+ var cursor = {
1057
+ cursor: {
1058
+ className: "cursor",
1059
+ values: "cursor",
1060
+ group: "System"
1061
+ }
1062
+ };
1063
+
1064
+ // src/utilities/display.ts
1065
+ var display = {
1066
+ display: {
1067
+ className: "d",
1068
+ group: "Display"
1069
+ },
1070
+ hideFrom: {
1071
+ className: "hide",
1072
+ values: "breakpoints",
1073
+ group: "Display",
1074
+ transform(value, { raw, token }) {
1075
+ const bp = token.raw(`breakpoints.${raw}`);
1076
+ const media = bp ? `@breakpoint ${raw}` : `@media screen and (min-width: ${value})`;
1077
+ return {
1078
+ [media]: {
1079
+ display: "none"
1080
+ }
1081
+ };
1082
+ }
1083
+ },
1084
+ hideBelow: {
1085
+ className: "show",
1086
+ values: "breakpoints",
1087
+ group: "Display",
1088
+ transform(value, { raw, token }) {
1089
+ const bp = token.raw(`breakpoints.${raw}`);
1090
+ const media = bp ? `@breakpoint ${raw}Down` : `@media screen and (max-width: ${value})`;
1091
+ return {
1092
+ [media]: {
1093
+ display: "none"
1094
+ }
1095
+ };
1096
+ }
1097
+ }
1098
+ };
1099
+
1100
+ // src/utilities/divide.ts
1101
+ var divideColor = createColorMixTransform("borderColor");
1102
+ var divide = {
1103
+ divideX: {
1104
+ className: "dvd-x",
1105
+ values: "borderWidths",
1106
+ group: "Border",
1107
+ transform(value) {
1108
+ return {
1109
+ "& > :not([hidden]) ~ :not([hidden])": {
1110
+ borderInlineStartWidth: value,
1111
+ borderInlineEndWidth: "0px"
1112
+ }
1113
+ };
1114
+ }
1115
+ },
1116
+ divideY: {
1117
+ className: "dvd-y",
1118
+ values: "borderWidths",
1119
+ group: "Border",
1120
+ transform(value) {
1121
+ return {
1122
+ "& > :not([hidden]) ~ :not([hidden])": {
1123
+ borderTopWidth: value,
1124
+ borderBottomWidth: "0px"
1125
+ }
1126
+ };
1127
+ }
1128
+ },
1129
+ divideColor: {
1130
+ className: "dvd-c",
1131
+ values: "colors",
1132
+ group: "Border",
1133
+ transform(value, args) {
1134
+ return {
1135
+ "& > :not([hidden]) ~ :not([hidden])": divideColor(value, args)
1136
+ };
1137
+ }
1138
+ },
1139
+ divideStyle: {
1140
+ className: "dvd-s",
1141
+ property: "borderStyle",
1142
+ group: "Border",
1143
+ transform(value) {
1144
+ return {
1145
+ "& > :not([hidden]) ~ :not([hidden])": {
1146
+ borderStyle: value
1147
+ }
1148
+ };
1149
+ }
1150
+ }
1151
+ };
1152
+
1153
+ // src/utilities/effects.ts
1154
+ var effects = {
1155
+ opacity: {
1156
+ className: "op",
1157
+ values: "opacity",
1158
+ group: "Background"
1159
+ },
1160
+ boxShadow: {
1161
+ shorthand: "shadow",
1162
+ className: "bx-sh",
1163
+ values: "shadows",
1164
+ group: "Shadow"
1165
+ },
1166
+ boxShadowColor: {
1167
+ shorthand: "shadowColor",
1168
+ className: "bx-sh-c",
1169
+ values: "colors",
1170
+ transform: createColorMixTransform("--shadow-color"),
1171
+ group: "Color"
1172
+ },
1173
+ mixBlendMode: {
1174
+ className: "mix-bm",
1175
+ group: "Effect"
1176
+ },
1177
+ filter: {
1178
+ className: "filter",
1179
+ group: "Effect",
1180
+ values: {
1181
+ auto: "var(--blur, ) var(--brightness, ) var(--contrast, ) var(--grayscale, ) var(--hue-rotate, ) var(--invert, ) var(--saturate, ) var(--sepia, ) var(--drop-shadow, )"
1182
+ }
1183
+ },
1184
+ brightness: {
1185
+ className: "brightness",
1186
+ group: "Effect",
1187
+ transform(value) {
1188
+ return {
1189
+ "--brightness": `brightness(${value})`
1190
+ };
1191
+ }
1192
+ },
1193
+ contrast: {
1194
+ className: "contrast",
1195
+ group: "Effect",
1196
+ transform(value) {
1197
+ return {
1198
+ "--contrast": `contrast(${value})`
1199
+ };
1200
+ }
1201
+ },
1202
+ grayscale: {
1203
+ className: "grayscale",
1204
+ group: "Effect",
1205
+ transform(value) {
1206
+ return {
1207
+ "--grayscale": `grayscale(${value})`
1208
+ };
1209
+ }
1210
+ },
1211
+ hueRotate: {
1212
+ className: "hue-rotate",
1213
+ group: "Effect",
1214
+ transform(value) {
1215
+ return {
1216
+ "--hue-rotate": `hue-rotate(${value})`
1217
+ };
1218
+ }
1219
+ },
1220
+ invert: {
1221
+ className: "invert",
1222
+ group: "Effect",
1223
+ transform(value) {
1224
+ return {
1225
+ "--invert": `invert(${value})`
1226
+ };
1227
+ }
1228
+ },
1229
+ saturate: {
1230
+ className: "saturate",
1231
+ group: "Effect",
1232
+ transform(value) {
1233
+ return {
1234
+ "--saturate": `saturate(${value})`
1235
+ };
1236
+ }
1237
+ },
1238
+ sepia: {
1239
+ className: "sepia",
1240
+ group: "Effect",
1241
+ transform(value) {
1242
+ return {
1243
+ "--sepia": `sepia(${value})`
1244
+ };
1245
+ }
1246
+ },
1247
+ dropShadow: {
1248
+ className: "drop-shadow",
1249
+ group: "Effect",
1250
+ values: "dropShadows",
1251
+ transform(value) {
1252
+ return {
1253
+ "--drop-shadow": value
1254
+ };
1255
+ }
1256
+ },
1257
+ blur: {
1258
+ className: "blur",
1259
+ group: "Effect",
1260
+ values: "blurs",
1261
+ transform(value) {
1262
+ return {
1263
+ "--blur": `blur(${value})`
1264
+ };
1265
+ }
1266
+ },
1267
+ backdropFilter: {
1268
+ className: "bkdp",
1269
+ group: "Effect",
1270
+ values: {
1271
+ auto: "var(--backdrop-blur, ) var(--backdrop-brightness, ) var(--backdrop-contrast, ) var(--backdrop-grayscale, ) var(--backdrop-hue-rotate, ) var(--backdrop-invert, ) var(--backdrop-opacity, ) var(--backdrop-saturate, ) var(--backdrop-sepia, )"
1272
+ },
1273
+ transform(value) {
1274
+ return {
1275
+ backdropFilter: value,
1276
+ WebkitBackdropFilter: value
1277
+ };
1278
+ }
1279
+ },
1280
+ backdropBlur: {
1281
+ className: "bkdp-blur",
1282
+ group: "Effect",
1283
+ values: "blurs",
1284
+ transform(value) {
1285
+ return {
1286
+ "--backdrop-blur": `blur(${value})`
1287
+ };
1288
+ }
1289
+ },
1290
+ backdropBrightness: {
1291
+ className: "bkdp-brightness",
1292
+ group: "Effect",
1293
+ transform(value) {
1294
+ return {
1295
+ "--backdrop-brightness": `brightness(${value})`
1296
+ };
1297
+ }
1298
+ },
1299
+ backdropContrast: {
1300
+ className: "bkdp-contrast",
1301
+ group: "Effect",
1302
+ transform(value) {
1303
+ return {
1304
+ "--backdrop-contrast": `contrast(${value})`
1305
+ };
1306
+ }
1307
+ },
1308
+ backdropGrayscale: {
1309
+ className: "bkdp-grayscale",
1310
+ group: "Effect",
1311
+ transform(value) {
1312
+ return {
1313
+ "--backdrop-grayscale": `grayscale(${value})`
1314
+ };
1315
+ }
1316
+ },
1317
+ backdropHueRotate: {
1318
+ className: "bkdp-hue-rotate",
1319
+ group: "Effect",
1320
+ transform(value) {
1321
+ return {
1322
+ "--backdrop-hue-rotate": `hue-rotate(${value})`
1323
+ };
1324
+ }
1325
+ },
1326
+ backdropInvert: {
1327
+ className: "bkdp-invert",
1328
+ group: "Effect",
1329
+ transform(value) {
1330
+ return {
1331
+ "--backdrop-invert": `invert(${value})`
1332
+ };
1333
+ }
1334
+ },
1335
+ backdropOpacity: {
1336
+ className: "bkdp-opacity",
1337
+ group: "Effect",
1338
+ transform(value) {
1339
+ return {
1340
+ "--backdrop-opacity": value
1341
+ };
1342
+ }
1343
+ },
1344
+ backdropSaturate: {
1345
+ className: "bkdp-saturate",
1346
+ group: "Effect",
1347
+ transform(value) {
1348
+ return {
1349
+ "--backdrop-saturate": `saturate(${value})`
1350
+ };
1351
+ }
1352
+ },
1353
+ backdropSepia: {
1354
+ className: "bkdp-sepia",
1355
+ group: "Effect",
1356
+ transform(value) {
1357
+ return {
1358
+ "--backdrop-sepia": `sepia(${value})`
1359
+ };
1360
+ }
1361
+ }
1362
+ };
1363
+
1364
+ // src/utilities/flex-and-grid.ts
1365
+ var flexGrid = {
1366
+ flexBasis: {
1367
+ className: "flex-b",
1368
+ group: "Flex Layout",
1369
+ values(theme) {
1370
+ return {
1371
+ ...theme("sizes"),
1372
+ "1/2": "50%",
1373
+ "1/3": "33.333333%",
1374
+ "2/3": "66.666667%",
1375
+ "1/4": "25%",
1376
+ "2/4": "50%",
1377
+ "3/4": "75%",
1378
+ "1/5": "20%",
1379
+ "2/5": "40%",
1380
+ "3/5": "60%",
1381
+ "4/5": "80%",
1382
+ "1/6": "16.666667%",
1383
+ "2/6": "33.333333%",
1384
+ "3/6": "50%",
1385
+ "4/6": "66.666667%",
1386
+ "5/6": "83.333333%",
1387
+ "1/12": "8.333333%",
1388
+ "2/12": "16.666667%",
1389
+ "3/12": "25%",
1390
+ "4/12": "33.333333%",
1391
+ "5/12": "41.666667%",
1392
+ "6/12": "50%",
1393
+ "7/12": "58.333333%",
1394
+ "8/12": "66.666667%",
1395
+ "9/12": "75%",
1396
+ "10/12": "83.333333%",
1397
+ "11/12": "91.666667%",
1398
+ full: "100%"
1399
+ };
1400
+ }
1401
+ },
1402
+ flex: {
1403
+ className: "flex",
1404
+ group: "Flex Layout",
1405
+ values: {
1406
+ "1": "1 1 0%",
1407
+ auto: "1 1 auto",
1408
+ initial: "0 1 auto",
1409
+ none: "none"
1410
+ }
1411
+ },
1412
+ flexDirection: {
1413
+ className: "flex-d",
1414
+ group: "Flex Layout",
1415
+ shorthand: "flexDir"
1416
+ },
1417
+ flexGrow: {
1418
+ className: "flex-g",
1419
+ group: "Flex Layout"
1420
+ },
1421
+ flexShrink: {
1422
+ className: "flex-sh",
1423
+ group: "Flex Layout"
1424
+ },
1425
+ gridTemplateColumns: {
1426
+ className: "grid-tc",
1427
+ group: "Grid Layout"
1428
+ },
1429
+ gridTemplateRows: {
1430
+ className: "grid-tr",
1431
+ group: "Grid Layout"
1432
+ },
1433
+ gridColumn: {
1434
+ className: "grid-c",
1435
+ group: "Grid Layout"
1436
+ },
1437
+ gridRow: {
1438
+ className: "grid-r",
1439
+ group: "Grid Layout"
1440
+ },
1441
+ gridColumnStart: {
1442
+ className: "grid-cs",
1443
+ group: "Grid Layout"
1444
+ },
1445
+ gridColumnEnd: {
1446
+ className: "grid-ce",
1447
+ group: "Grid Layout"
1448
+ },
1449
+ gridAutoFlow: {
1450
+ className: "grid-af",
1451
+ group: "Grid Layout"
1452
+ },
1453
+ gridAutoColumns: {
1454
+ className: "grid-ac",
1455
+ group: "Grid Layout",
1456
+ values: {
1457
+ min: "min-content",
1458
+ max: "max-content",
1459
+ fr: "minmax(0, 1fr)"
1460
+ }
1461
+ },
1462
+ gridAutoRows: {
1463
+ className: "grid-ar",
1464
+ group: "Grid Layout",
1465
+ values: {
1466
+ min: "min-content",
1467
+ max: "max-content",
1468
+ fr: "minmax(0, 1fr)"
1469
+ }
1470
+ },
1471
+ gap: {
1472
+ className: "gap",
1473
+ group: "Flex Layout",
1474
+ values: "spacing"
1475
+ },
1476
+ gridGap: {
1477
+ className: "grid-g",
1478
+ group: "Grid Layout",
1479
+ values: "spacing"
1480
+ },
1481
+ gridRowGap: {
1482
+ className: "grid-rg",
1483
+ group: "Grid Layout",
1484
+ values: "spacing"
1485
+ },
1486
+ gridColumnGap: {
1487
+ className: "grid-cg",
1488
+ group: "Grid Layout",
1489
+ values: "spacing"
1490
+ },
1491
+ rowGap: {
1492
+ className: "rg",
1493
+ group: "Grid Layout",
1494
+ values: "spacing"
1495
+ },
1496
+ columnGap: {
1497
+ className: "cg",
1498
+ group: "Grid Layout",
1499
+ values: "spacing"
1500
+ },
1501
+ justifyContent: {
1502
+ className: "jc",
1503
+ group: "Flex Layout"
1504
+ },
1505
+ alignContent: {
1506
+ className: "ac",
1507
+ group: "Flex Layout"
1508
+ },
1509
+ alignItems: {
1510
+ className: "ai",
1511
+ group: "Flex Layout"
1512
+ },
1513
+ alignSelf: {
1514
+ className: "as",
1515
+ group: "Flex Layout"
1516
+ }
1517
+ };
1518
+
1519
+ // src/utilities/focus-ring.ts
1520
+ function createFocusRing(selector, className) {
1521
+ return {
1522
+ className,
1523
+ group: "Focus Ring",
1524
+ values: ["outside", "inside", "mixed", "none"],
1525
+ transform(value) {
1526
+ const fallback = "var(--global-color-focus-ring, #005FCC)";
1527
+ const focusRingColor = `var(--focus-ring-color-prop, ${fallback})`;
1528
+ switch (value) {
1529
+ case "inside":
1530
+ return {
1531
+ "--focus-ring-color": focusRingColor,
1532
+ [selector]: {
1533
+ outlineOffset: "0px",
1534
+ outlineWidth: "var(--focus-ring-width, 1px)",
1535
+ outlineColor: "var(--focus-ring-color)",
1536
+ outlineStyle: "var(--focus-ring-style, solid)",
1537
+ borderColor: "var(--focus-ring-color)"
1538
+ }
1539
+ };
1540
+ case "outside":
1541
+ return {
1542
+ "--focus-ring-color": focusRingColor,
1543
+ [selector]: {
1544
+ outlineWidth: "var(--focus-ring-width, 2px)",
1545
+ outlineOffset: "var(--focus-ring-offset, 2px)",
1546
+ outlineStyle: "var(--focus-ring-style, solid)",
1547
+ outlineColor: "var(--focus-ring-color)"
1548
+ }
1549
+ };
1550
+ case "mixed":
1551
+ return {
1552
+ "--focus-ring-color": focusRingColor,
1553
+ [selector]: {
1554
+ outlineOffset: "0px",
1555
+ outlineWidth: "var(--focus-ring-width, 3px)",
1556
+ outlineStyle: "var(--focus-ring-style, solid)",
1557
+ outlineColor: "color-mix(in srgb, var(--focus-ring-color), transparent 60%)",
1558
+ borderColor: "var(--focus-ring-color)"
1559
+ }
1560
+ };
1561
+ case "none":
1562
+ return {
1563
+ "--focus-ring-color": focusRingColor,
1564
+ [selector]: {
1565
+ outline: "none"
1566
+ }
1567
+ };
1568
+ default:
1569
+ return {};
1570
+ }
1571
+ }
1572
+ };
1573
+ }
1574
+ var focusRing = {
1575
+ focusRing: createFocusRing("&:is(:focus, [data-focus])", "focus-ring"),
1576
+ focusVisibleRing: createFocusRing("&:is(:focus-visible, [data-focus-visible])", "focus-v-ring"),
1577
+ focusRingColor: {
1578
+ className: "focus-ring-c",
1579
+ values: "colors",
1580
+ group: "Focus Ring",
1581
+ transform(value, { utils }) {
1582
+ const prop = "--focus-ring-color-prop";
1583
+ const mix = utils.colorMix(value);
1584
+ if (mix.invalid) return { [prop]: value };
1585
+ const cssVar = "--mix-" + prop;
1586
+ return {
1587
+ [cssVar]: mix.value,
1588
+ [prop]: `var(${cssVar}, ${mix.color})`
1589
+ };
1590
+ }
1591
+ },
1592
+ focusRingOffset: {
1593
+ className: "focus-ring-o",
1594
+ values: "spacing",
1595
+ group: "Focus Ring",
1596
+ transform: (v) => ({ "--focus-ring-offset": v })
1597
+ },
1598
+ focusRingWidth: {
1599
+ className: "focus-ring-w",
1600
+ values: "borderWidths",
1601
+ property: "outlineWidth",
1602
+ group: "Focus Ring",
1603
+ transform: (v) => ({ "--focus-ring-width": v })
1604
+ },
1605
+ focusRingStyle: {
1606
+ className: "focus-ring-s",
1607
+ values: "borderStyles",
1608
+ property: "outlineStyle",
1609
+ group: "Focus Ring",
1610
+ transform: (v) => ({ "--focus-ring-style": v })
1611
+ }
1612
+ };
1613
+
1614
+ // src/utilities/gradient.ts
1615
+ var gradientVia = createColorMixTransform("--gradient-via");
1616
+ var linearGradientDirectionMap = /* @__PURE__ */ new Map([
1617
+ ["to-t", "to top"],
1618
+ ["to-tr", "to top right"],
1619
+ ["to-r", "to right"],
1620
+ ["to-br", "to bottom right"],
1621
+ ["to-b", "to bottom"],
1622
+ ["to-bl", "to bottom left"],
1623
+ ["to-l", "to left"],
1624
+ ["to-tl", "to top left"]
1625
+ ]);
1626
+ var isGradientShortcut = (value) => linearGradientDirectionMap.has(value);
1627
+ var linearGradientValues = (theme) => {
1628
+ return {
1629
+ ...theme("gradients"),
1630
+ ...Object.fromEntries(linearGradientDirectionMap.entries())
1631
+ };
1632
+ };
1633
+ var gradientStops = "var(--gradient-via-stops, var(--gradient-position), var(--gradient-from) var(--gradient-from-position), var(--gradient-to) var(--gradient-to-position))";
1634
+ var gradientViaStops = "var(--gradient-position), var(--gradient-from) var(--gradient-from-position), var(--gradient-via) var(--gradient-via-position), var(--gradient-to) var(--gradient-to-position)";
1635
+ var backgroundGradients = {
1636
+ backgroundGradient: {
1637
+ shorthand: "bgGradient",
1638
+ className: "bg-grad",
1639
+ group: "Background Gradient",
1640
+ values: linearGradientValues,
1641
+ transform(value, { raw, token }) {
1642
+ const tokenValue = token(`gradients.${raw}`);
1643
+ if (tokenValue) {
1644
+ return { backgroundImage: tokenValue };
1645
+ }
1646
+ if (!isGradientShortcut(raw)) {
1647
+ return { backgroundImage: value };
1648
+ }
1649
+ return {
1650
+ "--gradient-stops": gradientStops,
1651
+ "--gradient-position": linearGradientDirectionMap.get(raw),
1652
+ backgroundImage: `linear-gradient(var(--gradient-stops))`
1653
+ };
1654
+ }
1655
+ },
1656
+ backgroundLinear: {
1657
+ shorthand: "bgLinear",
1658
+ className: "bg-linear",
1659
+ group: "Background Gradient",
1660
+ values: linearGradientValues,
1661
+ transform(value, { raw, token }) {
1662
+ const tokenValue = token(`gradients.${raw}`);
1663
+ if (tokenValue) {
1664
+ return { backgroundImage: tokenValue };
1665
+ }
1666
+ if (!isGradientShortcut(raw)) {
1667
+ return { backgroundImage: value };
1668
+ }
1669
+ return {
1670
+ "--gradient-stops": gradientStops,
1671
+ "--gradient-position": linearGradientDirectionMap.get(raw),
1672
+ backgroundImage: `linear-gradient(var(--gradient-stops))`
1673
+ };
1674
+ }
1675
+ },
1676
+ backgroundRadial: {
1677
+ shorthand: "bgRadial",
1678
+ className: "bg-radial",
1679
+ group: "Background Gradient",
1680
+ values: "gradients",
1681
+ transform(value, { raw, token }) {
1682
+ const tokenValue = token(`gradients.${raw}`);
1683
+ if (tokenValue) {
1684
+ return { backgroundImage: tokenValue };
1685
+ }
1686
+ return {
1687
+ "--gradient-stops": gradientStops,
1688
+ "--gradient-position": value,
1689
+ backgroundImage: `radial-gradient(var(--gradient-stops,${value}))`
1690
+ };
1691
+ }
1692
+ },
1693
+ backgroundConic: {
1694
+ shorthand: "bgConic",
1695
+ className: "bg-conic",
1696
+ group: "Background Gradient",
1697
+ transform(value) {
1698
+ return {
1699
+ "--gradient-stops": gradientStops,
1700
+ "--gradient-position": value,
1701
+ backgroundImage: `conic-gradient(var(--gradient-stops))`
1702
+ };
1703
+ }
1704
+ },
1705
+ textGradient: {
1706
+ className: "txt-grad",
1707
+ group: "Background Gradient",
1708
+ values: linearGradientValues,
1709
+ transform(value, { raw, token }) {
1710
+ const tokenValue = token(`gradients.${raw}`);
1711
+ if (tokenValue) {
1712
+ return {
1713
+ backgroundImage: tokenValue,
1714
+ WebkitBackgroundClip: "text",
1715
+ color: "transparent"
1716
+ };
1717
+ }
1718
+ if (!isGradientShortcut(raw)) {
1719
+ return {
1720
+ backgroundImage: value,
1721
+ WebkitBackgroundClip: "text",
1722
+ color: "transparent"
1723
+ };
1724
+ }
1725
+ return {
1726
+ "--gradient-stops": gradientStops,
1727
+ "--gradient-position": linearGradientDirectionMap.get(raw),
1728
+ backgroundImage: `linear-gradient(var(--gradient-stops))`,
1729
+ WebkitBackgroundClip: "text",
1730
+ color: "transparent"
1731
+ };
1732
+ }
1733
+ },
1734
+ gradientFromPosition: {
1735
+ className: "grad-from-pos",
1736
+ group: "Background Gradient",
1737
+ transform(value) {
1738
+ return {
1739
+ "--gradient-from-position": value
1740
+ };
1741
+ }
1742
+ },
1743
+ gradientToPosition: {
1744
+ className: "grad-to-pos",
1745
+ group: "Background Gradient",
1746
+ transform(value) {
1747
+ return {
1748
+ "--gradient-to-position": value
1749
+ };
1750
+ }
1751
+ },
1752
+ gradientFrom: {
1753
+ className: "grad-from",
1754
+ values: "colors",
1755
+ group: "Background Gradient",
1756
+ transform: createColorMixTransform("--gradient-from")
1757
+ },
1758
+ gradientTo: {
1759
+ className: "grad-to",
1760
+ values: "colors",
1761
+ group: "Background Gradient",
1762
+ transform: createColorMixTransform("--gradient-to")
1763
+ },
1764
+ gradientVia: {
1765
+ className: "grad-via",
1766
+ values: "colors",
1767
+ group: "Background Gradient",
1768
+ transform(value, args) {
1769
+ const transformed = gradientVia(value, args);
1770
+ return {
1771
+ ...transformed,
1772
+ "--gradient-stops": "var(--gradient-via-stops)",
1773
+ "--gradient-via-stops": gradientViaStops
1774
+ };
1775
+ }
1776
+ },
1777
+ gradientViaPosition: {
1778
+ className: "grad-via-pos",
1779
+ group: "Background Gradient",
1780
+ transform(value) {
1781
+ return {
1782
+ "--gradient-via-position": value
1783
+ };
1784
+ }
1785
+ }
1786
+ };
1787
+
1788
+ // src/utilities/helpers.ts
1789
+ var srMapping = {
1790
+ true: {
1791
+ position: "absolute",
1792
+ width: "1px",
1793
+ height: "1px",
1794
+ padding: "0",
1795
+ margin: "-1px",
1796
+ overflow: "hidden",
1797
+ clip: "rect(0, 0, 0, 0)",
1798
+ whiteSpace: "nowrap",
1799
+ borderWidth: "0"
1800
+ },
1801
+ false: {
1802
+ position: "static",
1803
+ width: "auto",
1804
+ height: "auto",
1805
+ padding: "0",
1806
+ margin: "0",
1807
+ overflow: "visible",
1808
+ clip: "auto",
1809
+ whiteSpace: "normal"
1810
+ }
1811
+ };
1812
+ var helpers = {
1813
+ srOnly: {
1814
+ className: "sr",
1815
+ values: { type: "boolean" },
1816
+ group: "Other",
1817
+ transform(value) {
1818
+ return srMapping[value] || {};
1819
+ }
1820
+ },
1821
+ debug: {
1822
+ className: "debug",
1823
+ values: { type: "boolean" },
1824
+ group: "Other",
1825
+ transform(value) {
1826
+ if (!value) return {};
1827
+ return {
1828
+ outline: "1px solid blue !important",
1829
+ "&>*": {
1830
+ outline: "1px solid red !important"
1831
+ }
1832
+ };
1833
+ }
1834
+ }
1835
+ };
1836
+
1837
+ // src/utilities/interactivity.ts
1838
+ var interactivity = {
1839
+ accentColor: {
1840
+ className: "ac-c",
1841
+ values: "colors",
1842
+ transform: createColorMixTransform("accentColor"),
1843
+ group: "Color"
1844
+ },
1845
+ caretColor: {
1846
+ className: "ca-c",
1847
+ values: "colors",
1848
+ group: "Color",
1849
+ transform: createColorMixTransform("caretColor")
1850
+ },
1851
+ scrollBehavior: {
1852
+ className: "scr-bhv",
1853
+ group: "Scroll"
1854
+ },
1855
+ // Scroll bar
1856
+ scrollbar: {
1857
+ className: "scr-bar",
1858
+ values: ["visible", "hidden"],
1859
+ group: "Scroll",
1860
+ transform(value) {
1861
+ if (value === "visible") {
1862
+ return {
1863
+ msOverflowStyle: "auto",
1864
+ scrollbarWidth: "auto",
1865
+ "&::-webkit-scrollbar": {
1866
+ display: "block"
1867
+ }
1868
+ };
1869
+ }
1870
+ if (value === "hidden") {
1871
+ return {
1872
+ msOverflowStyle: "none",
1873
+ scrollbarWidth: "none",
1874
+ "&::-webkit-scrollbar": {
1875
+ display: "none"
1876
+ }
1877
+ };
1878
+ }
1879
+ }
1880
+ },
1881
+ scrollbarColor: {
1882
+ className: "scr-bar-c",
1883
+ values: "colors",
1884
+ group: "Scroll",
1885
+ transform: createColorMixTransform("scrollbarColor")
1886
+ },
1887
+ scrollbarGutter: {
1888
+ className: "scr-bar-g",
1889
+ group: "Scroll"
1890
+ },
1891
+ scrollbarWidth: {
1892
+ className: "scr-bar-w",
1893
+ values: "sizes",
1894
+ group: "Scroll"
1895
+ },
1896
+ // Scroll Margin
1897
+ scrollMargin: {
1898
+ className: "scr-m",
1899
+ values: "spacing",
1900
+ group: "Scroll"
1901
+ },
1902
+ scrollMarginLeft: {
1903
+ className: "scr-ml",
1904
+ values: "spacing",
1905
+ group: "Scroll"
1906
+ },
1907
+ scrollMarginRight: {
1908
+ className: "scr-mr",
1909
+ values: "spacing",
1910
+ group: "Scroll"
1911
+ },
1912
+ scrollMarginTop: {
1913
+ className: "scr-mt",
1914
+ values: "spacing",
1915
+ group: "Scroll"
1916
+ },
1917
+ scrollMarginBottom: {
1918
+ className: "scr-mb",
1919
+ values: "spacing",
1920
+ group: "Scroll"
1921
+ },
1922
+ scrollMarginBlock: {
1923
+ className: "scr-my",
1924
+ values: "spacing",
1925
+ group: "Scroll",
1926
+ shorthand: ["scrollMarginY"]
1927
+ },
1928
+ scrollMarginBlockEnd: {
1929
+ className: "scr-mbe",
1930
+ values: "spacing",
1931
+ group: "Scroll"
1932
+ },
1933
+ scrollMarginBlockStart: {
1934
+ className: "scr-mbt",
1935
+ values: "spacing",
1936
+ group: "Scroll"
1937
+ },
1938
+ scrollMarginInline: {
1939
+ className: "scr-mx",
1940
+ values: "spacing",
1941
+ group: "Scroll",
1942
+ shorthand: ["scrollMarginX"]
1943
+ },
1944
+ scrollMarginInlineEnd: {
1945
+ className: "scr-me",
1946
+ values: "spacing",
1947
+ group: "Scroll"
1948
+ },
1949
+ scrollMarginInlineStart: {
1950
+ className: "scr-ms",
1951
+ values: "spacing",
1952
+ group: "Scroll"
1953
+ },
1954
+ // Scroll Padding
1955
+ scrollPadding: {
1956
+ className: "scr-p",
1957
+ values: "spacing",
1958
+ group: "Scroll"
1959
+ },
1960
+ scrollPaddingBlock: {
1961
+ className: "scr-py",
1962
+ values: "spacing",
1963
+ group: "Scroll",
1964
+ shorthand: ["scrollPaddingY"]
1965
+ },
1966
+ scrollPaddingBlockStart: {
1967
+ className: "scr-pbs",
1968
+ values: "spacing",
1969
+ group: "Scroll"
1970
+ },
1971
+ scrollPaddingBlockEnd: {
1972
+ className: "scr-pbe",
1973
+ values: "spacing",
1974
+ group: "Scroll"
1975
+ },
1976
+ scrollPaddingInline: {
1977
+ className: "scr-px",
1978
+ values: "spacing",
1979
+ group: "Scroll",
1980
+ shorthand: ["scrollPaddingX"]
1981
+ },
1982
+ scrollPaddingInlineEnd: {
1983
+ className: "scr-pe",
1984
+ values: "spacing",
1985
+ group: "Scroll"
1986
+ },
1987
+ scrollPaddingInlineStart: {
1988
+ className: "scr-ps",
1989
+ values: "spacing",
1990
+ group: "Scroll"
1991
+ },
1992
+ scrollPaddingLeft: {
1993
+ className: "scr-pl",
1994
+ values: "spacing",
1995
+ group: "Scroll"
1996
+ },
1997
+ scrollPaddingRight: {
1998
+ className: "scr-pr",
1999
+ values: "spacing",
2000
+ group: "Scroll"
2001
+ },
2002
+ scrollPaddingTop: {
2003
+ className: "scr-pt",
2004
+ values: "spacing",
2005
+ group: "Scroll"
2006
+ },
2007
+ scrollPaddingBottom: {
2008
+ className: "scr-pb",
2009
+ values: "spacing",
2010
+ group: "Scroll"
2011
+ },
2012
+ // Scroll Snap
2013
+ scrollSnapAlign: {
2014
+ className: "scr-sa",
2015
+ group: "Scroll"
2016
+ },
2017
+ scrollSnapStop: {
2018
+ className: "scrs-s",
2019
+ group: "Scroll"
2020
+ },
2021
+ scrollSnapType: {
2022
+ className: "scrs-t",
2023
+ group: "Scroll",
2024
+ values: {
2025
+ none: "none",
2026
+ x: "x var(--scroll-snap-strictness)",
2027
+ y: "y var(--scroll-snap-strictness)",
2028
+ both: "both var(--scroll-snap-strictness)"
2029
+ }
2030
+ },
2031
+ scrollSnapStrictness: {
2032
+ className: "scrs-strt",
2033
+ values: ["mandatory", "proximity"],
2034
+ group: "Scroll",
2035
+ transform(value) {
2036
+ return {
2037
+ "--scroll-snap-strictness": value
2038
+ };
2039
+ }
2040
+ },
2041
+ scrollSnapMargin: {
2042
+ className: "scrs-m",
2043
+ values: "spacing",
2044
+ group: "Scroll"
2045
+ },
2046
+ scrollSnapMarginTop: {
2047
+ className: "scrs-mt",
2048
+ values: "spacing",
2049
+ group: "Scroll"
2050
+ },
2051
+ scrollSnapMarginBottom: {
2052
+ className: "scrs-mb",
2053
+ values: "spacing",
2054
+ group: "Scroll"
2055
+ },
2056
+ scrollSnapMarginLeft: {
2057
+ className: "scrs-ml",
2058
+ values: "spacing",
2059
+ group: "Scroll"
2060
+ },
2061
+ scrollSnapMarginRight: {
2062
+ className: "scrs-mr",
2063
+ values: "spacing",
2064
+ group: "Scroll"
2065
+ },
2066
+ scrollSnapCoordinate: {
2067
+ className: "scrs-c",
2068
+ group: "Scroll"
2069
+ },
2070
+ scrollSnapDestination: {
2071
+ className: "scrs-d",
2072
+ group: "Scroll"
2073
+ },
2074
+ scrollSnapPointsX: {
2075
+ className: "scrs-px",
2076
+ group: "Scroll"
2077
+ },
2078
+ scrollSnapPointsY: {
2079
+ className: "scrs-py",
2080
+ group: "Scroll"
2081
+ },
2082
+ scrollSnapTypeX: {
2083
+ className: "scrs-tx",
2084
+ group: "Scroll"
2085
+ },
2086
+ scrollSnapTypeY: {
2087
+ className: "scrs-ty",
2088
+ group: "Scroll"
2089
+ },
2090
+ // Scroll Timeline
2091
+ scrollTimeline: {
2092
+ className: "scrtl",
2093
+ group: "Scroll"
2094
+ },
2095
+ scrollTimelineAxis: {
2096
+ className: "scrtl-a",
2097
+ group: "Scroll"
2098
+ },
2099
+ scrollTimelineName: {
2100
+ className: "scrtl-n",
2101
+ group: "Scroll"
2102
+ },
2103
+ touchAction: {
2104
+ className: "tch-a",
2105
+ group: "Interactivity"
2106
+ },
2107
+ userSelect: {
2108
+ className: "us",
2109
+ group: "Interactivity",
2110
+ transform(value) {
2111
+ return {
2112
+ WebkitUserSelect: value,
2113
+ userSelect: value
2114
+ };
2115
+ }
2116
+ },
2117
+ // Overflow
2118
+ overflow: {
2119
+ className: "ov",
2120
+ group: "Scroll"
2121
+ },
2122
+ overflowWrap: {
2123
+ className: "ov-wrap",
2124
+ group: "Scroll"
2125
+ },
2126
+ overflowX: {
2127
+ className: "ov-x",
2128
+ group: "Scroll"
2129
+ },
2130
+ overflowY: {
2131
+ className: "ov-y",
2132
+ group: "Scroll"
2133
+ },
2134
+ overflowAnchor: {
2135
+ className: "ov-a",
2136
+ group: "Scroll"
2137
+ },
2138
+ overflowBlock: {
2139
+ className: "ov-b",
2140
+ group: "Scroll"
2141
+ },
2142
+ overflowInline: {
2143
+ className: "ov-i",
2144
+ group: "Scroll"
2145
+ },
2146
+ overflowClipBox: {
2147
+ className: "ovcp-bx",
2148
+ group: "Scroll"
2149
+ },
2150
+ overflowClipMargin: {
2151
+ className: "ovcp-m",
2152
+ group: "Scroll"
2153
+ },
2154
+ overscrollBehavior: {
2155
+ className: "ovs-b",
2156
+ group: "Scroll"
2157
+ },
2158
+ overscrollBehaviorX: {
2159
+ className: "ovs-bx",
2160
+ group: "Scroll"
2161
+ },
2162
+ overscrollBehaviorY: {
2163
+ className: "ovs-by",
2164
+ group: "Scroll"
2165
+ },
2166
+ overscrollBehaviorBlock: {
2167
+ className: "ovs-bb",
2168
+ group: "Scroll"
2169
+ },
2170
+ overscrollBehaviorInline: {
2171
+ className: "ovs-bi",
2172
+ group: "Scroll"
2173
+ }
2174
+ };
2175
+
2176
+ // src/utilities/layout.ts
2177
+ var layout = {
2178
+ aspectRatio: {
2179
+ className: "asp",
2180
+ values: "aspectRatios",
2181
+ group: "Layout"
2182
+ },
2183
+ boxDecorationBreak: {
2184
+ className: "bx-db",
2185
+ group: "Layout",
2186
+ transform(value) {
2187
+ return {
2188
+ boxDecorationBreak: value,
2189
+ WebkitBoxDecorationBreak: value
2190
+ };
2191
+ }
2192
+ },
2193
+ zIndex: {
2194
+ className: "z",
2195
+ values: "zIndex",
2196
+ group: "Visibility"
2197
+ },
2198
+ boxSizing: {
2199
+ className: "bx-s",
2200
+ group: "System"
2201
+ },
2202
+ objectPosition: {
2203
+ className: "obj-p",
2204
+ group: "Layout"
2205
+ },
2206
+ objectFit: {
2207
+ className: "obj-f",
2208
+ group: "Layout"
2209
+ },
2210
+ overscrollBehavior: {
2211
+ className: "ovscl",
2212
+ group: "Scroll"
2213
+ },
2214
+ overscrollBehaviorX: {
2215
+ className: "ovscl-x",
2216
+ group: "Scroll"
2217
+ },
2218
+ overscrollBehaviorY: {
2219
+ className: "ovscl-y",
2220
+ group: "Scroll"
2221
+ },
2222
+ position: {
2223
+ className: "pos",
2224
+ shorthand: "pos",
2225
+ group: "Position"
2226
+ },
2227
+ top: {
2228
+ className: "top",
2229
+ values: "spacing",
2230
+ group: "Position"
2231
+ },
2232
+ left: {
2233
+ className: "left",
2234
+ values: "spacing",
2235
+ group: "Position"
2236
+ },
2237
+ inset: {
2238
+ className: "inset",
2239
+ group: "Position",
2240
+ values: (theme) => ({
2241
+ auto: "auto",
2242
+ ...theme("spacing")
2243
+ })
2244
+ },
2245
+ insetInline: {
2246
+ className: "inset-x",
2247
+ values: "spacing",
2248
+ group: "Position",
2249
+ shorthand: ["insetX"]
2250
+ },
2251
+ insetBlock: {
2252
+ className: "inset-y",
2253
+ values: "spacing",
2254
+ group: "Position",
2255
+ shorthand: ["insetY"]
2256
+ },
2257
+ insetBlockEnd: {
2258
+ className: "inset-be",
2259
+ values: "spacing",
2260
+ group: "Position"
2261
+ },
2262
+ insetBlockStart: {
2263
+ className: "inset-bs",
2264
+ values: "spacing",
2265
+ group: "Position"
2266
+ },
2267
+ insetInlineEnd: {
2268
+ className: "inset-e",
2269
+ values: "spacing",
2270
+ group: "Position",
2271
+ shorthand: ["insetEnd", "end"]
2272
+ },
2273
+ insetInlineStart: {
2274
+ className: "inset-s",
2275
+ values: "spacing",
2276
+ group: "Position",
2277
+ shorthand: ["insetStart", "start"]
2278
+ },
2279
+ right: {
2280
+ className: "right",
2281
+ values: "spacing",
2282
+ group: "Position"
2283
+ },
2284
+ bottom: {
2285
+ className: "bottom",
2286
+ values: "spacing",
2287
+ group: "Position"
2288
+ },
2289
+ float: {
2290
+ className: "float",
2291
+ values: ["start", "end"],
2292
+ property: "float",
2293
+ group: "Position",
2294
+ transform(value) {
2295
+ if (value === "start") {
2296
+ return {
2297
+ float: "left",
2298
+ '[dir="rtl"] &': {
2299
+ float: "right"
2300
+ }
2301
+ };
2302
+ }
2303
+ if (value === "end") {
2304
+ return {
2305
+ float: "right",
2306
+ '[dir="rtl"] &': {
2307
+ float: "left"
2308
+ }
2309
+ };
2310
+ }
2311
+ return {
2312
+ float: value
2313
+ };
2314
+ }
2315
+ },
2316
+ visibility: {
2317
+ className: "vis",
2318
+ group: "Visibility"
2319
+ }
2320
+ };
2321
+
2322
+ // src/utilities/list.ts
2323
+ var list = {
2324
+ listStyleType: {
2325
+ className: "li-t",
2326
+ group: "List"
2327
+ },
2328
+ listStylePosition: {
2329
+ className: "li-pos",
2330
+ group: "List"
2331
+ },
2332
+ listStyleImage: {
2333
+ className: "li-img",
2334
+ group: "List",
2335
+ values: "assets"
2336
+ },
2337
+ listStyle: {
2338
+ className: "li-s",
2339
+ group: "List"
2340
+ }
2341
+ };
2342
+
2343
+ // src/utilities/outline.ts
2344
+ var outline = {
2345
+ outlineWidth: {
2346
+ className: "ring-w",
2347
+ shorthand: "ringWidth",
2348
+ values: "borderWidths",
2349
+ group: "Border"
2350
+ },
2351
+ outlineColor: {
2352
+ className: "ring-c",
2353
+ values: "colors",
2354
+ group: "Color",
2355
+ shorthand: "ringColor",
2356
+ transform: createColorMixTransform("outlineColor")
2357
+ },
2358
+ outline: {
2359
+ className: "ring",
2360
+ shorthand: "ring",
2361
+ values: "borders",
2362
+ group: "Border",
2363
+ transform(value) {
2364
+ if (value === "none") {
2365
+ return { outline: "2px solid transparent", outlineOffset: "2px" };
2366
+ }
2367
+ return { outline: value };
2368
+ }
2369
+ },
2370
+ outlineOffset: {
2371
+ className: "ring-o",
2372
+ shorthand: "ringOffset",
2373
+ values: "spacing",
2374
+ group: "Border"
2375
+ }
2376
+ };
2377
+
2378
+ // src/utilities/polyfill.ts
2379
+ var polyfill = {
2380
+ appearance: {
2381
+ className: "ap",
2382
+ group: "Visibility",
2383
+ transform(value) {
2384
+ return { appearance: value, WebkitAppearance: value };
2385
+ }
2386
+ },
2387
+ backfaceVisibility: {
2388
+ className: "bfv",
2389
+ group: "Visibility",
2390
+ transform(value) {
2391
+ return { backfaceVisibility: value, WebkitBackfaceVisibility: value };
2392
+ }
2393
+ },
2394
+ clipPath: {
2395
+ className: "cp-path",
2396
+ group: "Other",
2397
+ transform(value) {
2398
+ return { clipPath: value, WebkitClipPath: value };
2399
+ }
2400
+ },
2401
+ hyphens: {
2402
+ className: "hy",
2403
+ group: "Other",
2404
+ transform(value) {
2405
+ return { hyphens: value, WebkitHyphens: value };
2406
+ }
2407
+ },
2408
+ mask: {
2409
+ className: "msk",
2410
+ group: "Other",
2411
+ transform(value) {
2412
+ return { mask: value, WebkitMask: value };
2413
+ }
2414
+ },
2415
+ maskImage: {
2416
+ className: "msk-i",
2417
+ group: "Other",
2418
+ transform(value) {
2419
+ return { maskImage: value, WebkitMaskImage: value };
2420
+ }
2421
+ },
2422
+ maskSize: {
2423
+ className: "msk-s",
2424
+ group: "Other",
2425
+ transform(value) {
2426
+ return { maskSize: value, WebkitMaskSize: value };
2427
+ }
2428
+ },
2429
+ textSizeAdjust: {
2430
+ className: "txt-adj",
2431
+ group: "Typography",
2432
+ transform(value) {
2433
+ return { textSizeAdjust: value, WebkitTextSizeAdjust: value };
2434
+ }
2435
+ }
2436
+ };
2437
+
2438
+ // src/utilities/sizing.ts
2439
+ var widthValues = (theme) => ({
2440
+ auto: "auto",
2441
+ ...theme("sizes"),
2442
+ "1/2": "50%",
2443
+ "1/3": "33.333333%",
2444
+ "2/3": "66.666667%",
2445
+ "1/4": "25%",
2446
+ "2/4": "50%",
2447
+ "3/4": "75%",
2448
+ "1/5": "20%",
2449
+ "2/5": "40%",
2450
+ "3/5": "60%",
2451
+ "4/5": "80%",
2452
+ "1/6": "16.666667%",
2453
+ "2/6": "33.333333%",
2454
+ "3/6": "50%",
2455
+ "4/6": "66.666667%",
2456
+ "5/6": "83.333333%",
2457
+ "1/12": "8.333333%",
2458
+ "2/12": "16.666667%",
2459
+ "3/12": "25%",
2460
+ "4/12": "33.333333%",
2461
+ "5/12": "41.666667%",
2462
+ "6/12": "50%",
2463
+ "7/12": "58.333333%",
2464
+ "8/12": "66.666667%",
2465
+ "9/12": "75%",
2466
+ "10/12": "83.333333%",
2467
+ "11/12": "91.666667%",
2468
+ screen: "100vw"
2469
+ });
2470
+ var heightValues = (theme) => ({
2471
+ auto: "auto",
2472
+ ...theme("sizes"),
2473
+ svh: "100svh",
2474
+ lvh: "100lvh",
2475
+ dvh: "100dvh",
2476
+ screen: "100vh",
2477
+ "1/2": "50%",
2478
+ "1/3": "33.333333%",
2479
+ "2/3": "66.666667%",
2480
+ "1/4": "25%",
2481
+ "2/4": "50%",
2482
+ "3/4": "75%",
2483
+ "1/5": "20%",
2484
+ "2/5": "40%",
2485
+ "3/5": "60%",
2486
+ "4/5": "80%",
2487
+ "1/6": "16.666667%",
2488
+ "2/6": "33.333333%",
2489
+ "3/6": "50%",
2490
+ "4/6": "66.666667%",
2491
+ "5/6": "83.333333%"
2492
+ });
2493
+ var sizing = {
2494
+ width: {
2495
+ shorthand: "w",
2496
+ className: "w",
2497
+ group: "Width",
2498
+ values: widthValues
2499
+ },
2500
+ inlineSize: {
2501
+ className: "w-is",
2502
+ group: "Width",
2503
+ values: widthValues
2504
+ },
2505
+ minWidth: {
2506
+ shorthand: "minW",
2507
+ className: "min-w",
2508
+ group: "Width",
2509
+ values: widthValues
2510
+ },
2511
+ minInlineSize: {
2512
+ className: "min-w-is",
2513
+ group: "Width",
2514
+ values: widthValues
2515
+ },
2516
+ maxWidth: {
2517
+ shorthand: "maxW",
2518
+ className: "max-w",
2519
+ group: "Width",
2520
+ values: widthValues
2521
+ },
2522
+ maxInlineSize: {
2523
+ className: "max-w-is",
2524
+ group: "Width",
2525
+ values: widthValues
2526
+ },
2527
+ height: {
2528
+ shorthand: "h",
2529
+ className: "h",
2530
+ group: "Height",
2531
+ values: heightValues
2532
+ },
2533
+ blockSize: {
2534
+ className: "h-bs",
2535
+ group: "Height",
2536
+ values: heightValues
2537
+ },
2538
+ minHeight: {
2539
+ shorthand: "minH",
2540
+ className: "min-h",
2541
+ group: "Height",
2542
+ values: heightValues
2543
+ },
2544
+ minBlockSize: {
2545
+ className: "min-h-bs",
2546
+ group: "Height",
2547
+ values: heightValues
2548
+ },
2549
+ maxHeight: {
2550
+ shorthand: "maxH",
2551
+ className: "max-h",
2552
+ group: "Height",
2553
+ values: heightValues
2554
+ },
2555
+ maxBlockSize: {
2556
+ className: "max-b",
2557
+ group: "Height",
2558
+ values: heightValues
2559
+ },
2560
+ boxSize: {
2561
+ className: "size",
2562
+ group: "Width",
2563
+ values: widthValues,
2564
+ transform(value) {
2565
+ return {
2566
+ width: value,
2567
+ height: value
2568
+ };
2569
+ }
2570
+ }
2571
+ };
2572
+
2573
+ // src/utilities/spacing.ts
2574
+ var marginValues = (theme) => ({
2575
+ auto: "auto",
2576
+ ...theme("spacing")
2577
+ });
2578
+ var spacing = {
2579
+ padding: {
2580
+ className: "p",
2581
+ shorthand: "p",
2582
+ values: "spacing",
2583
+ group: "Padding"
2584
+ },
2585
+ paddingLeft: {
2586
+ className: "pl",
2587
+ shorthand: "pl",
2588
+ values: "spacing",
2589
+ group: "Padding"
2590
+ },
2591
+ paddingRight: {
2592
+ className: "pr",
2593
+ shorthand: "pr",
2594
+ values: "spacing",
2595
+ group: "Padding"
2596
+ },
2597
+ paddingTop: {
2598
+ className: "pt",
2599
+ shorthand: "pt",
2600
+ values: "spacing",
2601
+ group: "Padding"
2602
+ },
2603
+ paddingBottom: {
2604
+ className: "pb",
2605
+ shorthand: "pb",
2606
+ values: "spacing",
2607
+ group: "Padding"
2608
+ },
2609
+ paddingBlock: {
2610
+ className: "py",
2611
+ values: "spacing",
2612
+ group: "Padding",
2613
+ shorthand: ["py", "paddingY"]
2614
+ },
2615
+ paddingBlockEnd: {
2616
+ className: "pbe",
2617
+ values: "spacing",
2618
+ group: "Padding"
2619
+ },
2620
+ paddingBlockStart: {
2621
+ className: "pbs",
2622
+ values: "spacing",
2623
+ group: "Padding"
2624
+ },
2625
+ paddingInline: {
2626
+ className: "px",
2627
+ values: "spacing",
2628
+ group: "Padding",
2629
+ shorthand: ["paddingX", "px"]
2630
+ },
2631
+ paddingInlineEnd: {
2632
+ className: "pe",
2633
+ shorthand: ["pe", "paddingEnd"],
2634
+ values: "spacing",
2635
+ group: "Padding"
2636
+ },
2637
+ paddingInlineStart: {
2638
+ className: "ps",
2639
+ shorthand: ["ps", "paddingStart"],
2640
+ values: "spacing",
2641
+ group: "Padding"
2642
+ },
2643
+ marginLeft: {
2644
+ className: "ml",
2645
+ shorthand: "ml",
2646
+ values: marginValues,
2647
+ group: "Margin"
2648
+ },
2649
+ marginRight: {
2650
+ className: "mr",
2651
+ shorthand: "mr",
2652
+ values: marginValues,
2653
+ group: "Margin"
2654
+ },
2655
+ marginTop: {
2656
+ className: "mt",
2657
+ shorthand: "mt",
2658
+ values: marginValues,
2659
+ group: "Margin"
2660
+ },
2661
+ marginBottom: {
2662
+ className: "mb",
2663
+ shorthand: "mb",
2664
+ values: marginValues,
2665
+ group: "Margin"
2666
+ },
2667
+ margin: {
2668
+ className: "m",
2669
+ shorthand: "m",
2670
+ values: marginValues,
2671
+ group: "Margin"
2672
+ },
2673
+ marginBlock: {
2674
+ className: "my",
2675
+ values: marginValues,
2676
+ group: "Margin",
2677
+ shorthand: ["my", "marginY"]
2678
+ },
2679
+ marginBlockEnd: {
2680
+ className: "mbe",
2681
+ values: marginValues,
2682
+ group: "Margin"
2683
+ },
2684
+ marginBlockStart: {
2685
+ className: "mbs",
2686
+ values: marginValues,
2687
+ group: "Margin"
2688
+ },
2689
+ marginInline: {
2690
+ className: "mx",
2691
+ values: marginValues,
2692
+ group: "Margin",
2693
+ shorthand: ["mx", "marginX"]
2694
+ },
2695
+ marginInlineEnd: {
2696
+ className: "me",
2697
+ shorthand: ["me", "marginEnd"],
2698
+ values: marginValues,
2699
+ group: "Margin"
2700
+ },
2701
+ marginInlineStart: {
2702
+ className: "ms",
2703
+ shorthand: ["ms", "marginStart"],
2704
+ values: marginValues,
2705
+ group: "Margin"
2706
+ },
2707
+ spaceX: {
2708
+ className: "sx",
2709
+ values: marginValues,
2710
+ property: "marginInlineStart",
2711
+ group: "Margin",
2712
+ transform(value) {
2713
+ return {
2714
+ "& > :not([hidden]) ~ :not([hidden])": {
2715
+ marginInlineStart: value,
2716
+ marginInlineEnd: "0px"
2717
+ }
2718
+ };
2719
+ }
2720
+ },
2721
+ spaceY: {
2722
+ className: "sy",
2723
+ values: marginValues,
2724
+ property: "marginBlockStart",
2725
+ group: "Margin",
2726
+ transform(value) {
2727
+ return {
2728
+ "& > :not([hidden]) ~ :not([hidden])": {
2729
+ marginTop: value,
2730
+ marginBottom: "0px"
2731
+ }
2732
+ };
2733
+ }
2734
+ }
2735
+ };
2736
+
2737
+ // src/utilities/svg.ts
2738
+ var svg = {
2739
+ fill: {
2740
+ className: "fill",
2741
+ values: "colors",
2742
+ group: "Color",
2743
+ transform: createColorMixTransform("fill")
2744
+ },
2745
+ stroke: {
2746
+ className: "stk",
2747
+ values: "colors",
2748
+ group: "Color",
2749
+ transform: createColorMixTransform("stroke")
2750
+ },
2751
+ strokeWidth: {
2752
+ className: "stk-w",
2753
+ values: "borderWidths",
2754
+ group: "Border"
2755
+ },
2756
+ strokeDasharray: {
2757
+ className: "stk-dsh",
2758
+ group: "Border"
2759
+ },
2760
+ strokeDashoffset: {
2761
+ className: "stk-do",
2762
+ group: "Border"
2763
+ },
2764
+ strokeLinecap: {
2765
+ className: "stk-lc",
2766
+ group: "Border"
2767
+ },
2768
+ strokeLinejoin: {
2769
+ className: "stk-lj",
2770
+ group: "Border"
2771
+ },
2772
+ strokeMiterlimit: {
2773
+ className: "stk-ml",
2774
+ group: "Border"
2775
+ },
2776
+ strokeOpacity: {
2777
+ className: "stk-op",
2778
+ group: "Border"
2779
+ }
2780
+ };
2781
+
2782
+ // src/utilities/tables.ts
2783
+ var tables = {
2784
+ borderCollapse: {
2785
+ className: "bd-cl",
2786
+ group: "Table"
2787
+ },
2788
+ borderSpacing: {
2789
+ className: "bd-sp",
2790
+ group: "Table",
2791
+ values(theme) {
2792
+ return {
2793
+ ...theme("spacing"),
2794
+ auto: "var(--border-spacing-x) var(--border-spacing-y)"
2795
+ };
2796
+ }
2797
+ },
2798
+ borderSpacingX: {
2799
+ className: "bd-sx",
2800
+ values: "spacing",
2801
+ group: "Table",
2802
+ transform(value) {
2803
+ return {
2804
+ "--border-spacing-x": value
2805
+ };
2806
+ }
2807
+ },
2808
+ borderSpacingY: {
2809
+ className: "bd-sy",
2810
+ values: "spacing",
2811
+ group: "Table",
2812
+ transform(value) {
2813
+ return {
2814
+ "--border-spacing-y": value
2815
+ };
2816
+ }
2817
+ },
2818
+ tableLayout: {
2819
+ className: "tbl",
2820
+ group: "Table"
2821
+ }
2822
+ };
2823
+
2824
+ // src/utilities/transforms.ts
2825
+ var positiveFractions = {
2826
+ "1/2": "50%",
2827
+ "1/3": "33.333333%",
2828
+ "2/3": "66.666667%",
2829
+ "1/4": "25%",
2830
+ "2/4": "50%",
2831
+ "3/4": "75%",
2832
+ full: "100%"
2833
+ };
2834
+ var negativeFractions = Object.fromEntries(
2835
+ Object.entries(positiveFractions).map(([key, value]) => [`-${key}`, `-${value}`])
2836
+ );
2837
+ var fractions = { ...positiveFractions, ...negativeFractions };
2838
+ var transforms = {
2839
+ transformOrigin: {
2840
+ className: "trf-o",
2841
+ group: "Transform"
2842
+ },
2843
+ transformBox: {
2844
+ className: "trf-b",
2845
+ group: "Transform"
2846
+ },
2847
+ transformStyle: {
2848
+ className: "trf-s",
2849
+ group: "Transform"
2850
+ },
2851
+ transform: {
2852
+ className: "trf",
2853
+ group: "Transform"
2854
+ },
2855
+ rotate: {
2856
+ className: "rotate",
2857
+ group: "Transform",
2858
+ property: "rotate",
2859
+ values: {
2860
+ auto: "var(--rotate-x) var(--rotate-y)",
2861
+ "auto-3d": "var(--rotate-x) var(--rotate-y) var(--rotate-z)"
2862
+ }
2863
+ },
2864
+ rotateX: {
2865
+ className: "rotate-x",
2866
+ group: "Transform",
2867
+ property: "rotate",
2868
+ transform(value) {
2869
+ return {
2870
+ "--rotate-x": value
2871
+ };
2872
+ }
2873
+ },
2874
+ rotateY: {
2875
+ className: "rotate-y",
2876
+ group: "Transform",
2877
+ property: "rotate",
2878
+ transform(value) {
2879
+ return {
2880
+ "--rotate-y": value
2881
+ };
2882
+ }
2883
+ },
2884
+ rotateZ: {
2885
+ className: "rotate-z",
2886
+ group: "Transform",
2887
+ property: "rotate",
2888
+ transform(value) {
2889
+ return {
2890
+ "--rotate-z": value
2891
+ };
2892
+ }
2893
+ },
2894
+ scale: {
2895
+ className: "scale",
2896
+ group: "Transform",
2897
+ property: "scale",
2898
+ values: {
2899
+ auto: "var(--scale-x) var(--scale-y)"
2900
+ }
2901
+ },
2902
+ scaleX: {
2903
+ className: "scale-x",
2904
+ group: "Transform",
2905
+ transform(value) {
2906
+ return {
2907
+ "--scale-x": value
2908
+ };
2909
+ }
2910
+ },
2911
+ scaleY: {
2912
+ className: "scale-y",
2913
+ group: "Transform",
2914
+ transform(value) {
2915
+ return {
2916
+ "--scale-y": value
2917
+ };
2918
+ }
2919
+ },
2920
+ translate: {
2921
+ className: "translate",
2922
+ group: "Transform",
2923
+ property: "translate",
2924
+ values: {
2925
+ auto: "var(--translate-x) var(--translate-y)",
2926
+ "auto-3d": "var(--translate-x) var(--translate-y) var(--translate-z)"
2927
+ }
2928
+ },
2929
+ translateX: {
2930
+ shorthand: "x",
2931
+ className: "translate-x",
2932
+ group: "Transform",
2933
+ values(theme) {
2934
+ return {
2935
+ ...theme("spacing"),
2936
+ ...fractions
2937
+ };
2938
+ },
2939
+ transform(value) {
2940
+ return {
2941
+ "--translate-x": value
2942
+ };
2943
+ }
2944
+ },
2945
+ translateY: {
2946
+ shorthand: "y",
2947
+ className: "translate-y",
2948
+ group: "Transform",
2949
+ values(theme) {
2950
+ return {
2951
+ ...theme("spacing"),
2952
+ ...fractions
2953
+ };
2954
+ },
2955
+ transform(value) {
2956
+ return {
2957
+ "--translate-y": value
2958
+ };
2959
+ }
2960
+ },
2961
+ translateZ: {
2962
+ shorthand: "z",
2963
+ className: "translate-z",
2964
+ group: "Transform",
2965
+ values(theme) {
2966
+ return {
2967
+ ...theme("spacing"),
2968
+ ...fractions
2969
+ };
2970
+ },
2971
+ transform(value) {
2972
+ return {
2973
+ "--translate-z": value
2974
+ };
2975
+ }
2976
+ }
2977
+ };
2978
+
2979
+ // src/utilities/transitions.ts
2980
+ var createTransition = (value) => ({
2981
+ transitionProperty: `var(--transition-prop, ${value})`,
2982
+ transitionTimingFunction: "var(--transition-easing, cubic-bezier(0.4, 0, 0.2, 1))",
2983
+ transitionDuration: "var(--transition-duration, 150ms)"
2984
+ });
2985
+ var transitionMap = {
2986
+ all: createTransition("all"),
2987
+ common: createTransition(
2988
+ "color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter"
2989
+ ),
2990
+ size: createTransition("width, height, min-width, max-width, min-height, max-height"),
2991
+ position: createTransition("left, right, top, bottom, inset, inset-inline, inset-block"),
2992
+ background: createTransition("background, background-color, background-image, background-position"),
2993
+ colors: createTransition("color, background-color, border-color, outline-color, text-decoration-color, fill, stroke"),
2994
+ opacity: createTransition("opacity"),
2995
+ shadow: createTransition("box-shadow"),
2996
+ transform: createTransition("transform")
2997
+ };
2998
+ var transitionPropertyMap = {
2999
+ common: "color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",
3000
+ colors: "color, background-color, border-color, outline-color, text-decoration-color, fill, stroke",
3001
+ size: "width, height, min-width, max-width, min-height, max-height",
3002
+ position: "left, right, top, bottom, inset, inset-inline, inset-block",
3003
+ background: "background, background-color, background-image, background-position"
3004
+ };
3005
+ var transitions = {
3006
+ transitionTimingFunction: {
3007
+ className: "trs-tmf",
3008
+ values: "easings",
3009
+ group: "Transition",
3010
+ transform(value) {
3011
+ return {
3012
+ "--transition-easing": value,
3013
+ transitionTimingFunction: value
3014
+ };
3015
+ }
3016
+ },
3017
+ transitionDelay: {
3018
+ className: "trs-dly",
3019
+ values: "durations",
3020
+ group: "Transition"
3021
+ },
3022
+ transitionDuration: {
3023
+ className: "trs-dur",
3024
+ values: "durations",
3025
+ group: "Transition",
3026
+ transform(value) {
3027
+ return {
3028
+ "--transition-duration": value,
3029
+ transitionDuration: value
3030
+ };
3031
+ }
3032
+ },
3033
+ transitionProperty: {
3034
+ className: "trs-prop",
3035
+ group: "Transition",
3036
+ values: transitionPropertyMap,
3037
+ transform(value) {
3038
+ return {
3039
+ "--transition-prop": value,
3040
+ transitionProperty: value
3041
+ };
3042
+ }
3043
+ },
3044
+ transition: {
3045
+ className: "trs",
3046
+ values: Object.keys(transitionMap),
3047
+ group: "Transition",
3048
+ transform(value) {
3049
+ return transitionMap[value] ?? { transition: value };
3050
+ }
3051
+ },
3052
+ // Animations
3053
+ animation: {
3054
+ className: "anim",
3055
+ values: "animations",
3056
+ group: "Animation"
3057
+ },
3058
+ animationName: {
3059
+ className: "anim-n",
3060
+ values: "keyframes",
3061
+ group: "Animation"
3062
+ },
3063
+ animationTimingFunction: {
3064
+ className: "anim-tmf",
3065
+ values: "easings",
3066
+ group: "Animation"
3067
+ },
3068
+ animationDuration: {
3069
+ className: "anim-dur",
3070
+ values: "durations",
3071
+ group: "Animation"
3072
+ },
3073
+ animationDelay: {
3074
+ className: "anim-dly",
3075
+ values: "durations",
3076
+ group: "Animation"
3077
+ },
3078
+ animationPlayState: {
3079
+ className: "anim-ps",
3080
+ group: "Animation"
3081
+ },
3082
+ animationComposition: {
3083
+ className: "anim-comp",
3084
+ group: "Animation"
3085
+ },
3086
+ animationFillMode: {
3087
+ className: "anim-fm",
3088
+ group: "Animation"
3089
+ },
3090
+ animationDirection: {
3091
+ className: "anim-dir",
3092
+ group: "Animation"
3093
+ },
3094
+ animationIterationCount: {
3095
+ className: "anim-ic",
3096
+ group: "Animation"
3097
+ },
3098
+ animationRange: {
3099
+ className: "anim-r",
3100
+ group: "Animation"
3101
+ },
3102
+ animationState: {
3103
+ className: "anim-s",
3104
+ group: "Animation"
3105
+ },
3106
+ animationRangeStart: {
3107
+ className: "anim-rs",
3108
+ group: "Animation"
3109
+ },
3110
+ animationRangeEnd: {
3111
+ className: "anim-re",
3112
+ group: "Animation"
3113
+ },
3114
+ animationTimeline: {
3115
+ className: "anim-tl",
3116
+ group: "Animation"
3117
+ }
3118
+ };
3119
+
3120
+ // src/utilities/typography.ts
3121
+ var typography = {
3122
+ color: {
3123
+ className: "c",
3124
+ values: "colors",
3125
+ group: "Color",
3126
+ transform: createColorMixTransform("color")
3127
+ },
3128
+ fontFamily: {
3129
+ className: "ff",
3130
+ values: "fonts",
3131
+ group: "Typography"
3132
+ },
3133
+ fontSize: {
3134
+ className: "fs",
3135
+ values: "fontSizes",
3136
+ group: "Typography"
3137
+ },
3138
+ fontSizeAdjust: {
3139
+ className: "fs-a",
3140
+ group: "Typography"
3141
+ },
3142
+ fontPalette: {
3143
+ className: "fp",
3144
+ group: "Typography"
3145
+ },
3146
+ fontKerning: {
3147
+ className: "fk",
3148
+ group: "Typography"
3149
+ },
3150
+ fontFeatureSettings: {
3151
+ className: "ff-s",
3152
+ group: "Typography"
3153
+ },
3154
+ fontWeight: {
3155
+ className: "fw",
3156
+ values: "fontWeights",
3157
+ group: "Typography"
3158
+ },
3159
+ fontSmoothing: {
3160
+ className: "fsmt",
3161
+ group: "Typography",
3162
+ values: {
3163
+ antialiased: "antialiased",
3164
+ "subpixel-antialiased": "auto"
3165
+ },
3166
+ transform(value) {
3167
+ return {
3168
+ WebkitFontSmoothing: value
3169
+ };
3170
+ }
3171
+ },
3172
+ fontVariant: {
3173
+ className: "fv",
3174
+ group: "Typography"
3175
+ },
3176
+ fontVariantAlternates: {
3177
+ className: "fv-alt",
3178
+ group: "Typography"
3179
+ },
3180
+ fontVariantCaps: {
3181
+ className: "fv-caps",
3182
+ group: "Typography"
3183
+ },
3184
+ fontVariationSettings: {
3185
+ className: "fv-s",
3186
+ group: "Typography"
3187
+ },
3188
+ fontVariantNumeric: {
3189
+ className: "fv-num",
3190
+ group: "Typography"
3191
+ },
3192
+ letterSpacing: {
3193
+ className: "ls",
3194
+ values: "letterSpacings",
3195
+ group: "Typography"
3196
+ },
3197
+ lineHeight: {
3198
+ className: "lh",
3199
+ values: "lineHeights",
3200
+ group: "Typography"
3201
+ },
3202
+ textAlign: {
3203
+ className: "ta",
3204
+ group: "Typography"
3205
+ },
3206
+ textDecoration: {
3207
+ className: "td",
3208
+ group: "Typography"
3209
+ },
3210
+ textDecorationColor: {
3211
+ className: "td-c",
3212
+ values: "colors",
3213
+ transform: createColorMixTransform("textDecorationColor"),
3214
+ group: "Typography"
3215
+ },
3216
+ textEmphasisColor: {
3217
+ className: "te-c",
3218
+ values: "colors",
3219
+ transform: createColorMixTransform("textEmphasisColor"),
3220
+ group: "Typography"
3221
+ },
3222
+ textDecorationStyle: {
3223
+ className: "td-s",
3224
+ group: "Typography"
3225
+ },
3226
+ textDecorationThickness: {
3227
+ className: "td-t",
3228
+ group: "Typography"
3229
+ },
3230
+ textUnderlineOffset: {
3231
+ className: "tu-o",
3232
+ group: "Typography"
3233
+ },
3234
+ textTransform: {
3235
+ className: "tt",
3236
+ group: "Typography"
3237
+ },
3238
+ textIndent: {
3239
+ className: "ti",
3240
+ group: "Typography",
3241
+ values: "spacing"
3242
+ },
3243
+ textShadow: {
3244
+ className: "tsh",
3245
+ values: "shadows",
3246
+ group: "Typography"
3247
+ },
3248
+ textShadowColor: {
3249
+ shorthand: "textShadowColor",
3250
+ className: "tsh-c",
3251
+ values: "colors",
3252
+ transform: createColorMixTransform("--text-shadow-color"),
3253
+ group: "Typography"
3254
+ },
3255
+ WebkitTextFillColor: {
3256
+ className: "wktf-c",
3257
+ values: "colors",
3258
+ transform: createColorMixTransform("WebkitTextFillColor"),
3259
+ group: "Typography"
3260
+ },
3261
+ textOverflow: {
3262
+ className: "tov",
3263
+ group: "Typography"
3264
+ },
3265
+ verticalAlign: {
3266
+ className: "va",
3267
+ group: "Typography"
3268
+ },
3269
+ wordBreak: {
3270
+ className: "wb",
3271
+ group: "Typography"
3272
+ },
3273
+ textWrap: {
3274
+ className: "tw",
3275
+ values: ["wrap", "balance", "nowrap"],
3276
+ group: "Typography",
3277
+ transform(value) {
3278
+ return { textWrap: value };
3279
+ }
3280
+ },
3281
+ truncate: {
3282
+ className: "trunc",
3283
+ values: { type: "boolean" },
3284
+ group: "Typography",
3285
+ transform(value) {
3286
+ if (!value) return {};
3287
+ return {
3288
+ overflow: "hidden",
3289
+ textOverflow: "ellipsis",
3290
+ whiteSpace: "nowrap"
3291
+ };
3292
+ }
3293
+ },
3294
+ lineClamp: {
3295
+ className: "lc",
3296
+ group: "Typography",
3297
+ transform(value) {
3298
+ if (value === "none") {
3299
+ return {
3300
+ WebkitLineClamp: "unset"
3301
+ };
3302
+ }
3303
+ return {
3304
+ overflow: "hidden",
3305
+ display: "-webkit-box",
3306
+ WebkitLineClamp: value,
3307
+ WebkitBoxOrient: "vertical"
3308
+ };
3309
+ }
3310
+ }
3311
+ };
3312
+
3313
+ // src/utilities/index.ts
3314
+ var utilities = Object.assign(
3315
+ {},
3316
+ layout,
3317
+ display,
3318
+ flexGrid,
3319
+ spacing,
3320
+ outline,
3321
+ focusRing,
3322
+ divide,
3323
+ sizing,
3324
+ typography,
3325
+ list,
3326
+ background,
3327
+ backgroundGradients,
3328
+ border,
3329
+ effects,
3330
+ tables,
3331
+ transitions,
3332
+ transforms,
3333
+ interactivity,
3334
+ svg,
3335
+ helpers,
3336
+ polyfill,
3337
+ container2,
3338
+ cursor
3339
+ );
3340
+
3341
+ // src/index.ts
3342
+ var definePreset = (preset2) => preset2;
3343
+ var preset = definePreset({
3344
+ name: "@bamboocss/preset-base",
3345
+ conditions,
3346
+ utilities,
3347
+ patterns,
3348
+ // globalVars,
3349
+ globalCss
3350
+ });
3351
+ var index_default = preset;
3352
+ // Annotate the CommonJS export names for ESM import in node:
3353
+ 0 && (module.exports = {
3354
+ preset
3355
+ });