@pandacss/preset-base 0.36.1 → 0.37.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +947 -794
- package/dist/index.mjs +947 -794
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -101,8 +101,8 @@ var conditions = {
|
|
|
101
101
|
print: "@media print",
|
|
102
102
|
landscape: "@media (orientation: landscape)",
|
|
103
103
|
portrait: "@media (orientation: portrait)",
|
|
104
|
-
dark: "
|
|
105
|
-
light: "
|
|
104
|
+
dark: ".dark &",
|
|
105
|
+
light: ".light &",
|
|
106
106
|
osDark: "@media (prefers-color-scheme: dark)",
|
|
107
107
|
osLight: "@media (prefers-color-scheme: light)",
|
|
108
108
|
highContrast: "@media (forced-colors: active)",
|
|
@@ -114,171 +114,594 @@ var conditions = {
|
|
|
114
114
|
scrollbarThumb: "&::-webkit-scrollbar-thumb",
|
|
115
115
|
scrollbarTrack: "&::-webkit-scrollbar-track",
|
|
116
116
|
horizontal: "&[data-orientation=horizontal]",
|
|
117
|
-
vertical: "&[data-orientation=vertical]"
|
|
117
|
+
vertical: "&[data-orientation=vertical]",
|
|
118
|
+
starting: "@starting-style"
|
|
118
119
|
};
|
|
119
120
|
|
|
120
|
-
// src/
|
|
121
|
-
var
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
121
|
+
// src/global-css.ts
|
|
122
|
+
var EMPTY = "/*-*/ /*-*/";
|
|
123
|
+
var globalCss = {
|
|
124
|
+
"*, ::before, ::after, ::backdrop": {
|
|
125
|
+
"--blur": EMPTY,
|
|
126
|
+
"--brightness": EMPTY,
|
|
127
|
+
"--contrast": EMPTY,
|
|
128
|
+
"--grayscale": EMPTY,
|
|
129
|
+
"--hue-rotate": EMPTY,
|
|
130
|
+
"--invert": EMPTY,
|
|
131
|
+
"--saturate": EMPTY,
|
|
132
|
+
"--sepia": EMPTY,
|
|
133
|
+
"--drop-shadow": EMPTY,
|
|
134
|
+
"--backdrop-blur": EMPTY,
|
|
135
|
+
"--backdrop-brightness": EMPTY,
|
|
136
|
+
"--backdrop-contrast": EMPTY,
|
|
137
|
+
"--backdrop-grayscale": EMPTY,
|
|
138
|
+
"--backdrop-hue-rotate": EMPTY,
|
|
139
|
+
"--backdrop-invert": EMPTY,
|
|
140
|
+
"--backdrop-opacity": EMPTY,
|
|
141
|
+
"--backdrop-saturate": EMPTY,
|
|
142
|
+
"--backdrop-sepia": EMPTY,
|
|
143
|
+
"--gradient-from-position": EMPTY,
|
|
144
|
+
"--gradient-to-position": EMPTY,
|
|
145
|
+
"--gradient-via-position": EMPTY,
|
|
146
|
+
"--scroll-snap-strictness": "proximity",
|
|
147
|
+
"--border-spacing-x": 0,
|
|
148
|
+
"--border-spacing-y": 0,
|
|
149
|
+
"--translate-x": 0,
|
|
150
|
+
"--translate-y": 0,
|
|
151
|
+
"--rotate": 0,
|
|
152
|
+
"--rotate-x": 0,
|
|
153
|
+
"--rotate-y": 0,
|
|
154
|
+
"--skew-x": 0,
|
|
155
|
+
"--skew-y": 0,
|
|
156
|
+
"--scale-x": 1,
|
|
157
|
+
"--scale-y": 1
|
|
158
|
+
}
|
|
130
159
|
};
|
|
131
160
|
|
|
132
|
-
// src/
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
161
|
+
// src/patterns.ts
|
|
162
|
+
function definePattern(config) {
|
|
163
|
+
return config;
|
|
164
|
+
}
|
|
165
|
+
var box = definePattern({
|
|
166
|
+
transform(props) {
|
|
167
|
+
return props;
|
|
168
|
+
}
|
|
169
|
+
});
|
|
170
|
+
var flex = definePattern({
|
|
171
|
+
properties: {
|
|
172
|
+
align: { type: "property", value: "alignItems" },
|
|
173
|
+
justify: { type: "property", value: "justifyContent" },
|
|
174
|
+
direction: { type: "property", value: "flexDirection" },
|
|
175
|
+
wrap: { type: "property", value: "flexWrap" },
|
|
176
|
+
basis: { type: "property", value: "flexBasis" },
|
|
177
|
+
grow: { type: "property", value: "flexGrow" },
|
|
178
|
+
shrink: { type: "property", value: "flexShrink" }
|
|
138
179
|
},
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
180
|
+
transform(props) {
|
|
181
|
+
const { direction, align, justify, wrap: wrap2, basis, grow, shrink, ...rest } = props;
|
|
182
|
+
return {
|
|
183
|
+
display: "flex",
|
|
184
|
+
flexDirection: direction,
|
|
185
|
+
alignItems: align,
|
|
186
|
+
justifyContent: justify,
|
|
187
|
+
flexWrap: wrap2,
|
|
188
|
+
flexBasis: basis,
|
|
189
|
+
flexGrow: grow,
|
|
190
|
+
flexShrink: shrink,
|
|
191
|
+
...rest
|
|
192
|
+
};
|
|
193
|
+
}
|
|
194
|
+
});
|
|
195
|
+
var stack = definePattern({
|
|
196
|
+
properties: {
|
|
197
|
+
align: { type: "property", value: "alignItems" },
|
|
198
|
+
justify: { type: "property", value: "justifyContent" },
|
|
199
|
+
direction: { type: "property", value: "flexDirection" },
|
|
200
|
+
gap: { type: "property", value: "gap" }
|
|
143
201
|
},
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
group: "Background"
|
|
202
|
+
defaultValues: {
|
|
203
|
+
direction: "column",
|
|
204
|
+
gap: "10px"
|
|
148
205
|
},
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
206
|
+
transform(props) {
|
|
207
|
+
const { align, justify, direction, gap, ...rest } = props;
|
|
208
|
+
return {
|
|
209
|
+
display: "flex",
|
|
210
|
+
flexDirection: direction,
|
|
211
|
+
alignItems: align,
|
|
212
|
+
justifyContent: justify,
|
|
213
|
+
gap,
|
|
214
|
+
...rest
|
|
215
|
+
};
|
|
216
|
+
}
|
|
217
|
+
});
|
|
218
|
+
var vstack = definePattern({
|
|
219
|
+
jsxName: "VStack",
|
|
220
|
+
properties: {
|
|
221
|
+
justify: { type: "property", value: "justifyContent" },
|
|
222
|
+
gap: { type: "property", value: "gap" }
|
|
153
223
|
},
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
className: "bg-clip",
|
|
157
|
-
group: "Background",
|
|
158
|
-
transform(value) {
|
|
159
|
-
return {
|
|
160
|
-
backgroundClip: value,
|
|
161
|
-
WebkitBackgroundClip: value
|
|
162
|
-
};
|
|
163
|
-
}
|
|
224
|
+
defaultValues: {
|
|
225
|
+
gap: "10px"
|
|
164
226
|
},
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
227
|
+
transform(props) {
|
|
228
|
+
const { justify, gap, ...rest } = props;
|
|
229
|
+
return {
|
|
230
|
+
display: "flex",
|
|
231
|
+
alignItems: "center",
|
|
232
|
+
justifyContent: justify,
|
|
233
|
+
gap,
|
|
234
|
+
flexDirection: "column",
|
|
235
|
+
...rest
|
|
236
|
+
};
|
|
237
|
+
}
|
|
238
|
+
});
|
|
239
|
+
var hstack = definePattern({
|
|
240
|
+
jsxName: "HStack",
|
|
241
|
+
properties: {
|
|
242
|
+
justify: { type: "property", value: "justifyContent" },
|
|
243
|
+
gap: { type: "property", value: "gap" }
|
|
171
244
|
},
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
className: "bg",
|
|
175
|
-
values: "colors",
|
|
176
|
-
group: "Background",
|
|
177
|
-
transform: createColorMixTransform("backgroundColor")
|
|
245
|
+
defaultValues: {
|
|
246
|
+
gap: "10px"
|
|
178
247
|
},
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
248
|
+
transform(props) {
|
|
249
|
+
const { justify, gap, ...rest } = props;
|
|
250
|
+
return {
|
|
251
|
+
display: "flex",
|
|
252
|
+
alignItems: "center",
|
|
253
|
+
justifyContent: justify,
|
|
254
|
+
gap,
|
|
255
|
+
flexDirection: "row",
|
|
256
|
+
...rest
|
|
257
|
+
};
|
|
258
|
+
}
|
|
259
|
+
});
|
|
260
|
+
var spacer = definePattern({
|
|
261
|
+
properties: {
|
|
262
|
+
size: { type: "token", value: "spacing" }
|
|
183
263
|
},
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
264
|
+
transform(props, { map }) {
|
|
265
|
+
const { size, ...rest } = props;
|
|
266
|
+
return {
|
|
267
|
+
alignSelf: "stretch",
|
|
268
|
+
justifySelf: "stretch",
|
|
269
|
+
flex: map(size, (v) => v == null ? "1" : `0 0 ${v}`),
|
|
270
|
+
...rest
|
|
271
|
+
};
|
|
272
|
+
}
|
|
273
|
+
});
|
|
274
|
+
var circle = definePattern({
|
|
275
|
+
properties: {
|
|
276
|
+
size: { type: "property", value: "width" }
|
|
189
277
|
},
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
278
|
+
transform(props) {
|
|
279
|
+
const { size, ...rest } = props;
|
|
280
|
+
return {
|
|
281
|
+
display: "flex",
|
|
282
|
+
alignItems: "center",
|
|
283
|
+
justifyContent: "center",
|
|
284
|
+
flex: "0 0 auto",
|
|
285
|
+
width: size,
|
|
286
|
+
height: size,
|
|
287
|
+
borderRadius: "9999px",
|
|
288
|
+
...rest
|
|
289
|
+
};
|
|
290
|
+
}
|
|
291
|
+
});
|
|
292
|
+
var square = definePattern({
|
|
293
|
+
properties: {
|
|
294
|
+
size: { type: "property", value: "width" }
|
|
194
295
|
},
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
296
|
+
transform(props) {
|
|
297
|
+
const { size, ...rest } = props;
|
|
298
|
+
return {
|
|
299
|
+
display: "flex",
|
|
300
|
+
alignItems: "center",
|
|
301
|
+
justifyContent: "center",
|
|
302
|
+
flex: "0 0 auto",
|
|
303
|
+
width: size,
|
|
304
|
+
height: size,
|
|
305
|
+
...rest
|
|
306
|
+
};
|
|
307
|
+
}
|
|
308
|
+
});
|
|
309
|
+
var grid = definePattern({
|
|
310
|
+
properties: {
|
|
311
|
+
gap: { type: "property", value: "gap" },
|
|
312
|
+
columnGap: { type: "property", value: "gap" },
|
|
313
|
+
rowGap: { type: "property", value: "gap" },
|
|
314
|
+
columns: { type: "number" },
|
|
315
|
+
minChildWidth: { type: "token", value: "sizes", property: "width" }
|
|
199
316
|
},
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
className: "bg",
|
|
203
|
-
group: "Background"
|
|
317
|
+
defaultValues(props) {
|
|
318
|
+
return { gap: props.columnGap || props.rowGap ? void 0 : "10px" };
|
|
204
319
|
},
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
},
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
backgroundImage: value
|
|
227
|
-
};
|
|
228
|
-
}
|
|
320
|
+
transform(props, { map, isCssUnit }) {
|
|
321
|
+
const { columnGap, rowGap, gap, columns, minChildWidth, ...rest } = props;
|
|
322
|
+
const getValue = (v) => isCssUnit(v) ? v : `token(sizes.${v}, ${v})`;
|
|
323
|
+
return {
|
|
324
|
+
display: "grid",
|
|
325
|
+
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,
|
|
326
|
+
gap,
|
|
327
|
+
columnGap,
|
|
328
|
+
rowGap,
|
|
329
|
+
...rest
|
|
330
|
+
};
|
|
331
|
+
}
|
|
332
|
+
});
|
|
333
|
+
var gridItem = definePattern({
|
|
334
|
+
properties: {
|
|
335
|
+
colSpan: { type: "number" },
|
|
336
|
+
rowSpan: { type: "number" },
|
|
337
|
+
colStart: { type: "number" },
|
|
338
|
+
rowStart: { type: "number" },
|
|
339
|
+
colEnd: { type: "number" },
|
|
340
|
+
rowEnd: { type: "number" }
|
|
229
341
|
},
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
342
|
+
transform(props, { map }) {
|
|
343
|
+
const { colSpan, rowSpan, colStart, rowStart, colEnd, rowEnd, ...rest } = props;
|
|
344
|
+
const spanFn = (v) => v === "auto" ? v : `span ${v}`;
|
|
345
|
+
return {
|
|
346
|
+
gridColumn: colSpan != null ? map(colSpan, spanFn) : void 0,
|
|
347
|
+
gridRow: rowSpan != null ? map(rowSpan, spanFn) : void 0,
|
|
348
|
+
gridColumnStart: colStart,
|
|
349
|
+
gridColumnEnd: colEnd,
|
|
350
|
+
gridRowStart: rowStart,
|
|
351
|
+
gridRowEnd: rowEnd,
|
|
352
|
+
...rest
|
|
353
|
+
};
|
|
354
|
+
}
|
|
355
|
+
});
|
|
356
|
+
var wrap = definePattern({
|
|
357
|
+
properties: {
|
|
358
|
+
gap: { type: "property", value: "gap" },
|
|
359
|
+
rowGap: { type: "property", value: "gap" },
|
|
360
|
+
columnGap: { type: "property", value: "gap" },
|
|
361
|
+
align: { type: "property", value: "alignItems" },
|
|
362
|
+
justify: { type: "property", value: "justifyContent" }
|
|
363
|
+
},
|
|
364
|
+
transform(props) {
|
|
365
|
+
const { columnGap, rowGap, gap = columnGap || rowGap ? void 0 : "10px", align, justify, ...rest } = props;
|
|
366
|
+
return {
|
|
367
|
+
display: "flex",
|
|
368
|
+
flexWrap: "wrap",
|
|
369
|
+
alignItems: align,
|
|
370
|
+
justifyContent: justify,
|
|
371
|
+
gap,
|
|
372
|
+
columnGap,
|
|
373
|
+
rowGap,
|
|
374
|
+
...rest
|
|
375
|
+
};
|
|
376
|
+
}
|
|
377
|
+
});
|
|
378
|
+
var container = definePattern({
|
|
379
|
+
transform(props) {
|
|
380
|
+
return {
|
|
381
|
+
position: "relative",
|
|
382
|
+
maxWidth: "8xl",
|
|
383
|
+
mx: "auto",
|
|
384
|
+
px: { base: "4", md: "6", lg: "8" },
|
|
385
|
+
...props
|
|
386
|
+
};
|
|
387
|
+
}
|
|
388
|
+
});
|
|
389
|
+
var center = definePattern({
|
|
390
|
+
properties: {
|
|
391
|
+
inline: { type: "boolean" }
|
|
392
|
+
},
|
|
393
|
+
transform(props) {
|
|
394
|
+
const { inline, ...rest } = props;
|
|
395
|
+
return {
|
|
396
|
+
display: inline ? "inline-flex" : "flex",
|
|
397
|
+
alignItems: "center",
|
|
398
|
+
justifyContent: "center",
|
|
399
|
+
...rest
|
|
400
|
+
};
|
|
401
|
+
}
|
|
402
|
+
});
|
|
403
|
+
var aspectRatio = definePattern({
|
|
404
|
+
properties: {
|
|
405
|
+
ratio: { type: "number" }
|
|
406
|
+
},
|
|
407
|
+
blocklist: ["aspectRatio"],
|
|
408
|
+
transform(props, { map }) {
|
|
409
|
+
const { ratio = 4 / 3, ...rest } = props;
|
|
410
|
+
return {
|
|
411
|
+
position: "relative",
|
|
412
|
+
_before: {
|
|
413
|
+
content: `""`,
|
|
414
|
+
display: "block",
|
|
415
|
+
height: "0",
|
|
416
|
+
paddingBottom: map(ratio, (r) => `${1 / r * 100}%`)
|
|
417
|
+
},
|
|
418
|
+
"&>*": {
|
|
419
|
+
display: "flex",
|
|
420
|
+
justifyContent: "center",
|
|
421
|
+
alignItems: "center",
|
|
422
|
+
overflow: "hidden",
|
|
423
|
+
position: "absolute",
|
|
424
|
+
inset: "0",
|
|
425
|
+
width: "100%",
|
|
426
|
+
height: "100%"
|
|
427
|
+
},
|
|
428
|
+
"&>img, &>video": {
|
|
429
|
+
objectFit: "cover"
|
|
430
|
+
},
|
|
431
|
+
...rest
|
|
432
|
+
};
|
|
433
|
+
}
|
|
434
|
+
});
|
|
435
|
+
var divider = definePattern({
|
|
436
|
+
properties: {
|
|
437
|
+
orientation: { type: "enum", value: ["horizontal", "vertical"] },
|
|
438
|
+
thickness: { type: "token", value: "sizes", property: "borderWidth" },
|
|
439
|
+
color: { type: "token", value: "colors", property: "borderColor" }
|
|
440
|
+
},
|
|
441
|
+
defaultValues: {
|
|
442
|
+
orientation: "horizontal",
|
|
443
|
+
thickness: "1px"
|
|
444
|
+
},
|
|
445
|
+
transform(props, { map }) {
|
|
446
|
+
const { orientation, thickness, color, ...rest } = props;
|
|
447
|
+
return {
|
|
448
|
+
"--thickness": thickness,
|
|
449
|
+
width: map(orientation, (v) => v === "vertical" ? void 0 : "100%"),
|
|
450
|
+
height: map(orientation, (v) => v === "horizontal" ? void 0 : "100%"),
|
|
451
|
+
borderBlockEndWidth: map(orientation, (v) => v === "horizontal" ? "var(--thickness)" : void 0),
|
|
452
|
+
borderInlineEndWidth: map(orientation, (v) => v === "vertical" ? "var(--thickness)" : void 0),
|
|
453
|
+
borderColor: color,
|
|
454
|
+
...rest
|
|
455
|
+
};
|
|
456
|
+
}
|
|
457
|
+
});
|
|
458
|
+
var linkBox = definePattern({
|
|
459
|
+
transform(props) {
|
|
460
|
+
return {
|
|
461
|
+
position: "relative",
|
|
462
|
+
"& :where(a, abbr)": {
|
|
463
|
+
position: "relative",
|
|
464
|
+
zIndex: "1"
|
|
465
|
+
},
|
|
466
|
+
...props
|
|
467
|
+
};
|
|
468
|
+
}
|
|
469
|
+
});
|
|
470
|
+
var linkOverlay = definePattern({
|
|
471
|
+
jsxElement: "a",
|
|
472
|
+
transform(props) {
|
|
473
|
+
return {
|
|
474
|
+
position: "static",
|
|
475
|
+
_before: {
|
|
476
|
+
content: '""',
|
|
477
|
+
display: "block",
|
|
478
|
+
position: "absolute",
|
|
479
|
+
cursor: "inherit",
|
|
480
|
+
inset: "0",
|
|
481
|
+
zIndex: "0",
|
|
482
|
+
...props["_before"]
|
|
483
|
+
},
|
|
484
|
+
...props
|
|
485
|
+
};
|
|
486
|
+
}
|
|
487
|
+
});
|
|
488
|
+
var float = definePattern({
|
|
489
|
+
properties: {
|
|
490
|
+
offsetX: { type: "token", value: "spacing", property: "left" },
|
|
491
|
+
offsetY: { type: "token", value: "spacing", property: "top" },
|
|
492
|
+
offset: { type: "token", value: "spacing", property: "top" },
|
|
493
|
+
placement: {
|
|
494
|
+
type: "enum",
|
|
495
|
+
value: [
|
|
496
|
+
"bottom-end",
|
|
497
|
+
"bottom-start",
|
|
498
|
+
"top-end",
|
|
499
|
+
"top-start",
|
|
500
|
+
"bottom-center",
|
|
501
|
+
"top-center",
|
|
502
|
+
"middle-center",
|
|
503
|
+
"middle-end",
|
|
504
|
+
"middle-start"
|
|
505
|
+
]
|
|
506
|
+
}
|
|
507
|
+
},
|
|
508
|
+
defaultValues(props) {
|
|
509
|
+
const offset = props.offset || "0";
|
|
510
|
+
return { offset, offsetX: offset, offsetY: offset, placement: "top-end" };
|
|
511
|
+
},
|
|
512
|
+
transform(props, { map }) {
|
|
513
|
+
const { offset, offsetX, offsetY, placement, ...rest } = props;
|
|
514
|
+
return {
|
|
515
|
+
display: "inline-flex",
|
|
516
|
+
justifyContent: "center",
|
|
517
|
+
alignItems: "center",
|
|
518
|
+
position: "absolute",
|
|
519
|
+
insetBlockStart: map(placement, (v) => {
|
|
520
|
+
const [side] = v.split("-");
|
|
521
|
+
const map2 = { top: offsetY, middle: "50%", bottom: "auto" };
|
|
522
|
+
return map2[side];
|
|
523
|
+
}),
|
|
524
|
+
insetBlockEnd: map(placement, (v) => {
|
|
525
|
+
const [side] = v.split("-");
|
|
526
|
+
const map2 = { top: "auto", middle: "50%", bottom: offsetY };
|
|
527
|
+
return map2[side];
|
|
528
|
+
}),
|
|
529
|
+
insetInlineStart: map(placement, (v) => {
|
|
530
|
+
const [, align] = v.split("-");
|
|
531
|
+
const map2 = { start: offsetX, center: "50%", end: "auto" };
|
|
532
|
+
return map2[align];
|
|
533
|
+
}),
|
|
534
|
+
insetInlineEnd: map(placement, (v) => {
|
|
535
|
+
const [, align] = v.split("-");
|
|
536
|
+
const map2 = { start: "auto", center: "50%", end: offsetX };
|
|
537
|
+
return map2[align];
|
|
538
|
+
}),
|
|
539
|
+
translate: map(placement, (v) => {
|
|
540
|
+
const [side, align] = v.split("-");
|
|
541
|
+
const mapX = { start: "-50%", center: "-50%", end: "50%" };
|
|
542
|
+
const mapY = { top: "-50%", middle: "-50%", bottom: "50%" };
|
|
543
|
+
return `${mapX[align]} ${mapY[side]}`;
|
|
544
|
+
}),
|
|
545
|
+
...rest
|
|
546
|
+
};
|
|
547
|
+
}
|
|
548
|
+
});
|
|
549
|
+
var bleed = definePattern({
|
|
550
|
+
properties: {
|
|
551
|
+
inline: { type: "property", value: "marginInline" },
|
|
552
|
+
block: { type: "property", value: "marginBlock" }
|
|
553
|
+
},
|
|
554
|
+
defaultValues: {
|
|
555
|
+
inline: "0",
|
|
556
|
+
block: "0"
|
|
557
|
+
},
|
|
558
|
+
transform(props, { map, isCssUnit, isCssVar }) {
|
|
559
|
+
const { inline, block, ...rest } = props;
|
|
560
|
+
const valueFn = (v) => isCssUnit(v) || isCssVar(v) ? v : `token(spacing.${v}, ${v})`;
|
|
561
|
+
return {
|
|
562
|
+
"--bleed-x": map(inline, valueFn),
|
|
563
|
+
"--bleed-y": map(block, valueFn),
|
|
564
|
+
marginInline: "calc(var(--bleed-x, 0) * -1)",
|
|
565
|
+
marginBlock: "calc(var(--bleed-y, 0) * -1)",
|
|
566
|
+
...rest
|
|
567
|
+
};
|
|
568
|
+
}
|
|
569
|
+
});
|
|
570
|
+
var visuallyHidden = definePattern({
|
|
571
|
+
transform(props) {
|
|
572
|
+
return {
|
|
573
|
+
srOnly: true,
|
|
574
|
+
...props
|
|
575
|
+
};
|
|
576
|
+
}
|
|
577
|
+
});
|
|
578
|
+
var cq = definePattern({
|
|
579
|
+
properties: {
|
|
580
|
+
name: { type: "token", value: "containerNames", property: "containerName" },
|
|
581
|
+
type: { type: "property", value: "containerType" }
|
|
582
|
+
},
|
|
583
|
+
defaultValues: {
|
|
584
|
+
type: "inline-size"
|
|
585
|
+
},
|
|
586
|
+
transform(props) {
|
|
587
|
+
const { name, type, ...rest } = props;
|
|
588
|
+
return {
|
|
589
|
+
containerType: type,
|
|
590
|
+
containerName: name,
|
|
591
|
+
...rest
|
|
592
|
+
};
|
|
593
|
+
}
|
|
594
|
+
});
|
|
595
|
+
var patterns = {
|
|
596
|
+
box,
|
|
597
|
+
flex,
|
|
598
|
+
stack,
|
|
599
|
+
vstack,
|
|
600
|
+
hstack,
|
|
601
|
+
spacer,
|
|
602
|
+
square,
|
|
603
|
+
circle,
|
|
604
|
+
center,
|
|
605
|
+
linkBox,
|
|
606
|
+
linkOverlay,
|
|
607
|
+
aspectRatio,
|
|
608
|
+
grid,
|
|
609
|
+
gridItem,
|
|
610
|
+
wrap,
|
|
611
|
+
container,
|
|
612
|
+
divider,
|
|
613
|
+
float,
|
|
614
|
+
bleed,
|
|
615
|
+
visuallyHidden,
|
|
616
|
+
cq
|
|
617
|
+
};
|
|
618
|
+
|
|
619
|
+
// src/color-mix-transform.ts
|
|
620
|
+
var createColorMixTransform = (prop) => (value, args) => {
|
|
621
|
+
const mix = args.utils.colorMix(value);
|
|
622
|
+
if (mix.invalid)
|
|
623
|
+
return { [prop]: value };
|
|
624
|
+
const cssVar = "--mix-" + prop;
|
|
625
|
+
return {
|
|
626
|
+
[cssVar]: mix.value,
|
|
627
|
+
[prop]: `var(${cssVar}, ${mix.color})`
|
|
628
|
+
};
|
|
629
|
+
};
|
|
630
|
+
|
|
631
|
+
// src/utilities/background.ts
|
|
632
|
+
var background = {
|
|
633
|
+
backgroundPosition: {
|
|
634
|
+
shorthand: "bgPosition",
|
|
635
|
+
className: "bg-pos",
|
|
636
|
+
group: "Background"
|
|
637
|
+
},
|
|
638
|
+
backgroundPositionX: {
|
|
639
|
+
shorthand: "bgPositionX",
|
|
640
|
+
className: "bg-pos-x",
|
|
641
|
+
group: "Background"
|
|
642
|
+
},
|
|
643
|
+
backgroundPositionY: {
|
|
644
|
+
shorthand: "bgPositionY",
|
|
645
|
+
className: "bg-pos-y",
|
|
646
|
+
group: "Background"
|
|
647
|
+
},
|
|
648
|
+
backgroundAttachment: {
|
|
649
|
+
shorthand: "bgAttachment",
|
|
650
|
+
className: "bg-attach",
|
|
651
|
+
group: "Background"
|
|
652
|
+
},
|
|
653
|
+
backgroundClip: {
|
|
654
|
+
shorthand: "bgClip",
|
|
655
|
+
className: "bg-clip",
|
|
656
|
+
group: "Background",
|
|
246
657
|
transform(value) {
|
|
247
658
|
return {
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
backgroundImage: value,
|
|
251
|
-
WebkitBackgroundClip: "text",
|
|
252
|
-
color: "transparent"
|
|
659
|
+
backgroundClip: value,
|
|
660
|
+
WebkitBackgroundClip: value
|
|
253
661
|
};
|
|
254
662
|
}
|
|
255
663
|
},
|
|
256
|
-
|
|
257
|
-
|
|
664
|
+
background: {
|
|
665
|
+
shorthand: "bg",
|
|
666
|
+
className: "bg",
|
|
258
667
|
values: "colors",
|
|
259
668
|
group: "Background",
|
|
260
|
-
transform: createColorMixTransform("
|
|
669
|
+
transform: createColorMixTransform("background")
|
|
261
670
|
},
|
|
262
|
-
|
|
263
|
-
|
|
671
|
+
backgroundColor: {
|
|
672
|
+
shorthand: "bgColor",
|
|
673
|
+
className: "bg",
|
|
264
674
|
values: "colors",
|
|
265
675
|
group: "Background",
|
|
266
|
-
transform: createColorMixTransform("
|
|
676
|
+
transform: createColorMixTransform("backgroundColor")
|
|
267
677
|
},
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
group: "Background"
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
678
|
+
backgroundOrigin: {
|
|
679
|
+
shorthand: "bgOrigin",
|
|
680
|
+
className: "bg-origin",
|
|
681
|
+
group: "Background"
|
|
682
|
+
},
|
|
683
|
+
backgroundImage: {
|
|
684
|
+
shorthand: "bgImage",
|
|
685
|
+
className: "bg-img",
|
|
686
|
+
values: "assets",
|
|
687
|
+
group: "Background"
|
|
688
|
+
},
|
|
689
|
+
backgroundRepeat: {
|
|
690
|
+
shorthand: "bgRepeat",
|
|
691
|
+
className: "bg-repeat",
|
|
692
|
+
group: "Background"
|
|
693
|
+
},
|
|
694
|
+
backgroundBlendMode: {
|
|
695
|
+
shorthand: "bgBlendMode",
|
|
696
|
+
className: "bg-blend",
|
|
697
|
+
group: "Background"
|
|
698
|
+
},
|
|
699
|
+
backgroundSize: {
|
|
700
|
+
shorthand: "bgSize",
|
|
701
|
+
className: "bg-size",
|
|
702
|
+
group: "Background"
|
|
279
703
|
}
|
|
280
704
|
};
|
|
281
|
-
var gradientVia = createColorMixTransform("--gradient-via");
|
|
282
705
|
|
|
283
706
|
// src/utilities/border.ts
|
|
284
707
|
var border = {
|
|
@@ -595,7 +1018,7 @@ var border = {
|
|
|
595
1018
|
};
|
|
596
1019
|
|
|
597
1020
|
// src/utilities/container.ts
|
|
598
|
-
var
|
|
1021
|
+
var container2 = {
|
|
599
1022
|
container: {
|
|
600
1023
|
className: "cq",
|
|
601
1024
|
group: "Container"
|
|
@@ -649,10 +1072,11 @@ var display = {
|
|
|
649
1072
|
};
|
|
650
1073
|
|
|
651
1074
|
// src/utilities/divide.ts
|
|
1075
|
+
var divideColor = createColorMixTransform("borderColor");
|
|
652
1076
|
var divide = {
|
|
653
1077
|
divideX: {
|
|
654
1078
|
className: "divide-x",
|
|
655
|
-
values:
|
|
1079
|
+
values: "borderWidths",
|
|
656
1080
|
group: "Border",
|
|
657
1081
|
transform(value) {
|
|
658
1082
|
return {
|
|
@@ -665,7 +1089,7 @@ var divide = {
|
|
|
665
1089
|
},
|
|
666
1090
|
divideY: {
|
|
667
1091
|
className: "divide-y",
|
|
668
|
-
values:
|
|
1092
|
+
values: "borderWidths",
|
|
669
1093
|
group: "Border",
|
|
670
1094
|
transform(value) {
|
|
671
1095
|
return {
|
|
@@ -677,7 +1101,7 @@ var divide = {
|
|
|
677
1101
|
}
|
|
678
1102
|
},
|
|
679
1103
|
divideColor: {
|
|
680
|
-
className: "divide",
|
|
1104
|
+
className: "divide-color",
|
|
681
1105
|
values: "colors",
|
|
682
1106
|
group: "Border",
|
|
683
1107
|
transform(value, args) {
|
|
@@ -687,7 +1111,7 @@ var divide = {
|
|
|
687
1111
|
}
|
|
688
1112
|
},
|
|
689
1113
|
divideStyle: {
|
|
690
|
-
className: "divide",
|
|
1114
|
+
className: "divide-style",
|
|
691
1115
|
property: "borderStyle",
|
|
692
1116
|
group: "Border",
|
|
693
1117
|
transform(value) {
|
|
@@ -699,7 +1123,6 @@ var divide = {
|
|
|
699
1123
|
}
|
|
700
1124
|
}
|
|
701
1125
|
};
|
|
702
|
-
var divideColor = createColorMixTransform("borderColor");
|
|
703
1126
|
|
|
704
1127
|
// src/utilities/effects.ts
|
|
705
1128
|
var effects = {
|
|
@@ -715,7 +1138,7 @@ var effects = {
|
|
|
715
1138
|
},
|
|
716
1139
|
boxShadowColor: {
|
|
717
1140
|
shorthand: "shadowColor",
|
|
718
|
-
className: "shadow",
|
|
1141
|
+
className: "shadow-color",
|
|
719
1142
|
values: "colors",
|
|
720
1143
|
transform: createColorMixTransform("--shadow-color"),
|
|
721
1144
|
group: "Color"
|
|
@@ -728,17 +1151,7 @@ var effects = {
|
|
|
728
1151
|
className: "filter",
|
|
729
1152
|
group: "Effect",
|
|
730
1153
|
values: {
|
|
731
|
-
auto:
|
|
732
|
-
"var(--blur)",
|
|
733
|
-
"var(--brightness)",
|
|
734
|
-
"var(--contrast)",
|
|
735
|
-
"var(--grayscale)",
|
|
736
|
-
"var(--hue-rotate)",
|
|
737
|
-
"var(--invert)",
|
|
738
|
-
"var(--saturate)",
|
|
739
|
-
"var(--sepia)",
|
|
740
|
-
"var(--drop-shadow)"
|
|
741
|
-
].join(" ")
|
|
1154
|
+
auto: "var(--blur, ) var(--brightness, ) var(--contrast, ) var(--grayscale, ) var(--hue-rotate, ) var(--invert, ) var(--saturate, ) var(--sepia, ) var(--drop-shadow, )"
|
|
742
1155
|
}
|
|
743
1156
|
},
|
|
744
1157
|
brightness: {
|
|
@@ -828,16 +1241,7 @@ var effects = {
|
|
|
828
1241
|
className: "backdrop",
|
|
829
1242
|
group: "Effect",
|
|
830
1243
|
values: {
|
|
831
|
-
auto:
|
|
832
|
-
"var(--backdrop-blur)",
|
|
833
|
-
"var(--backdrop-brightness)",
|
|
834
|
-
"var(--backdrop-contrast)",
|
|
835
|
-
"var(--backdrop-grayscale)",
|
|
836
|
-
"var(--backdrop-hue-rotate)",
|
|
837
|
-
"var(--backdrop-invert)",
|
|
838
|
-
"var(--backdrop-saturate)",
|
|
839
|
-
"var(--backdrop-sepia)"
|
|
840
|
-
].join(" ")
|
|
1244
|
+
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, )"
|
|
841
1245
|
},
|
|
842
1246
|
transform(value) {
|
|
843
1247
|
return {
|
|
@@ -1143,6 +1547,111 @@ var flexGrid = {
|
|
|
1143
1547
|
}
|
|
1144
1548
|
};
|
|
1145
1549
|
|
|
1550
|
+
// src/utilities/gradient.ts
|
|
1551
|
+
var gradientVia = createColorMixTransform("--gradient-via");
|
|
1552
|
+
var gradientTemplate = {
|
|
1553
|
+
"to-t": "linear-gradient(to top, var(--gradient))",
|
|
1554
|
+
"to-tr": "linear-gradient(to top right, var(--gradient))",
|
|
1555
|
+
"to-r": "linear-gradient(to right, var(--gradient))",
|
|
1556
|
+
"to-br": "linear-gradient(to bottom right, var(--gradient))",
|
|
1557
|
+
"to-b": "linear-gradient(to bottom, var(--gradient))",
|
|
1558
|
+
"to-bl": "linear-gradient(to bottom left, var(--gradient))",
|
|
1559
|
+
"to-l": "linear-gradient(to left, var(--gradient))",
|
|
1560
|
+
"to-tl": "linear-gradient(to top left, var(--gradient))"
|
|
1561
|
+
};
|
|
1562
|
+
var gradientVars = {
|
|
1563
|
+
"--gradient-stops": "var(--gradient-via-stops, var(--gradient-from) var(--gradient-from-position), var(--gradient-to) var(--gradient-to-position))",
|
|
1564
|
+
"--gradient": "var(--gradient-via-stops, var(--gradient-stops))"
|
|
1565
|
+
};
|
|
1566
|
+
var backgroundGradients = {
|
|
1567
|
+
backgroundGradient: {
|
|
1568
|
+
shorthand: "bgGradient",
|
|
1569
|
+
className: "bg-gradient",
|
|
1570
|
+
group: "Background Gradient",
|
|
1571
|
+
values(theme) {
|
|
1572
|
+
return {
|
|
1573
|
+
...theme("gradients"),
|
|
1574
|
+
...gradientTemplate
|
|
1575
|
+
};
|
|
1576
|
+
},
|
|
1577
|
+
transform(value) {
|
|
1578
|
+
return {
|
|
1579
|
+
...gradientVars,
|
|
1580
|
+
backgroundImage: value
|
|
1581
|
+
};
|
|
1582
|
+
}
|
|
1583
|
+
},
|
|
1584
|
+
textGradient: {
|
|
1585
|
+
className: "text-gradient",
|
|
1586
|
+
group: "Background Gradient",
|
|
1587
|
+
values(theme) {
|
|
1588
|
+
return {
|
|
1589
|
+
...theme("gradients"),
|
|
1590
|
+
...gradientTemplate
|
|
1591
|
+
};
|
|
1592
|
+
},
|
|
1593
|
+
transform(value) {
|
|
1594
|
+
return {
|
|
1595
|
+
...gradientVars,
|
|
1596
|
+
backgroundImage: value,
|
|
1597
|
+
WebkitBackgroundClip: "text",
|
|
1598
|
+
color: "transparent"
|
|
1599
|
+
};
|
|
1600
|
+
}
|
|
1601
|
+
},
|
|
1602
|
+
gradientFromPosition: {
|
|
1603
|
+
className: "gradient-from-pos",
|
|
1604
|
+
group: "Background Gradient",
|
|
1605
|
+
transform(value) {
|
|
1606
|
+
return {
|
|
1607
|
+
"--gradient-from-position": value
|
|
1608
|
+
};
|
|
1609
|
+
}
|
|
1610
|
+
},
|
|
1611
|
+
gradientToPosition: {
|
|
1612
|
+
className: "gradient-to-pos",
|
|
1613
|
+
group: "Background Gradient",
|
|
1614
|
+
transform(value) {
|
|
1615
|
+
return {
|
|
1616
|
+
"--gradient-to-position": value
|
|
1617
|
+
};
|
|
1618
|
+
}
|
|
1619
|
+
},
|
|
1620
|
+
gradientFrom: {
|
|
1621
|
+
className: "gradient-from",
|
|
1622
|
+
values: "colors",
|
|
1623
|
+
group: "Background Gradient",
|
|
1624
|
+
transform: createColorMixTransform("--gradient-from")
|
|
1625
|
+
},
|
|
1626
|
+
gradientTo: {
|
|
1627
|
+
className: "gradient-to",
|
|
1628
|
+
values: "colors",
|
|
1629
|
+
group: "Background Gradient",
|
|
1630
|
+
transform: createColorMixTransform("--gradient-to")
|
|
1631
|
+
},
|
|
1632
|
+
gradientVia: {
|
|
1633
|
+
className: "gradient-via",
|
|
1634
|
+
values: "colors",
|
|
1635
|
+
group: "Background Gradient",
|
|
1636
|
+
transform(value, args) {
|
|
1637
|
+
const transformed = gradientVia(value, args);
|
|
1638
|
+
return {
|
|
1639
|
+
...transformed,
|
|
1640
|
+
"--gradient-stops": "var(--gradient-from) var(--gradient-from-position), var(--gradient-via) var(--gradient-via-position), var(--gradient-to) var(--gradient-to-position)"
|
|
1641
|
+
};
|
|
1642
|
+
}
|
|
1643
|
+
},
|
|
1644
|
+
gradientViaPosition: {
|
|
1645
|
+
className: "gradient-via-pos",
|
|
1646
|
+
group: "Background Gradient",
|
|
1647
|
+
transform(value) {
|
|
1648
|
+
return {
|
|
1649
|
+
"--gradient-via-position": value
|
|
1650
|
+
};
|
|
1651
|
+
}
|
|
1652
|
+
}
|
|
1653
|
+
};
|
|
1654
|
+
|
|
1146
1655
|
// src/utilities/helpers.ts
|
|
1147
1656
|
var srMapping = {
|
|
1148
1657
|
true: {
|
|
@@ -1351,15 +1860,15 @@ var interactivity = {
|
|
|
1351
1860
|
group: "Scroll"
|
|
1352
1861
|
},
|
|
1353
1862
|
scrollSnapAlign: {
|
|
1354
|
-
className: "snap",
|
|
1863
|
+
className: "snap-align",
|
|
1355
1864
|
group: "Scroll"
|
|
1356
1865
|
},
|
|
1357
1866
|
scrollSnapStop: {
|
|
1358
|
-
className: "snap",
|
|
1867
|
+
className: "snap-stop",
|
|
1359
1868
|
group: "Scroll"
|
|
1360
1869
|
},
|
|
1361
1870
|
scrollSnapType: {
|
|
1362
|
-
className: "snap",
|
|
1871
|
+
className: "snap-type",
|
|
1363
1872
|
group: "Scroll",
|
|
1364
1873
|
values: {
|
|
1365
1874
|
none: "none",
|
|
@@ -1369,7 +1878,7 @@ var interactivity = {
|
|
|
1369
1878
|
}
|
|
1370
1879
|
},
|
|
1371
1880
|
scrollSnapStrictness: {
|
|
1372
|
-
className: "strictness",
|
|
1881
|
+
className: "snap-strictness",
|
|
1373
1882
|
values: ["mandatory", "proximity"],
|
|
1374
1883
|
group: "Scroll",
|
|
1375
1884
|
transform(value) {
|
|
@@ -1446,11 +1955,11 @@ var layout = {
|
|
|
1446
1955
|
group: "System"
|
|
1447
1956
|
},
|
|
1448
1957
|
objectPosition: {
|
|
1449
|
-
className: "
|
|
1958
|
+
className: "obj-pos",
|
|
1450
1959
|
group: "Layout"
|
|
1451
1960
|
},
|
|
1452
1961
|
objectFit: {
|
|
1453
|
-
className: "
|
|
1962
|
+
className: "obj-fit",
|
|
1454
1963
|
group: "Layout"
|
|
1455
1964
|
},
|
|
1456
1965
|
overscrollBehavior: {
|
|
@@ -1567,11 +2076,11 @@ var layout = {
|
|
|
1567
2076
|
// src/utilities/list.ts
|
|
1568
2077
|
var list = {
|
|
1569
2078
|
listStyleType: {
|
|
1570
|
-
className: "list",
|
|
2079
|
+
className: "list-type",
|
|
1571
2080
|
group: "List"
|
|
1572
2081
|
},
|
|
1573
2082
|
listStylePosition: {
|
|
1574
|
-
className: "list",
|
|
2083
|
+
className: "list-pos",
|
|
1575
2084
|
group: "List"
|
|
1576
2085
|
},
|
|
1577
2086
|
listStyleImage: {
|
|
@@ -1584,13 +2093,13 @@ var list = {
|
|
|
1584
2093
|
// src/utilities/outline.ts
|
|
1585
2094
|
var outline = {
|
|
1586
2095
|
outlineWidth: {
|
|
1587
|
-
className: "ring",
|
|
2096
|
+
className: "ring-width",
|
|
1588
2097
|
shorthand: "ringWidth",
|
|
1589
2098
|
values: "borderWidths",
|
|
1590
2099
|
group: "Border"
|
|
1591
2100
|
},
|
|
1592
2101
|
outlineColor: {
|
|
1593
|
-
className: "ring",
|
|
2102
|
+
className: "ring-color",
|
|
1594
2103
|
values: "colors",
|
|
1595
2104
|
group: "Color",
|
|
1596
2105
|
shorthand: "ringColor",
|
|
@@ -1609,7 +2118,7 @@ var outline = {
|
|
|
1609
2118
|
}
|
|
1610
2119
|
},
|
|
1611
2120
|
outlineOffset: {
|
|
1612
|
-
className: "ring",
|
|
2121
|
+
className: "ring-offset",
|
|
1613
2122
|
shorthand: "ringOffset",
|
|
1614
2123
|
values: "spacing",
|
|
1615
2124
|
group: "Border"
|
|
@@ -1668,7 +2177,7 @@ var polyfill = {
|
|
|
1668
2177
|
}
|
|
1669
2178
|
},
|
|
1670
2179
|
textSizeAdjust: {
|
|
1671
|
-
className: "text-
|
|
2180
|
+
className: "text-adjust",
|
|
1672
2181
|
group: "Typography",
|
|
1673
2182
|
transform(value) {
|
|
1674
2183
|
return { textSizeAdjust: value, WebkitTextSizeAdjust: value };
|
|
@@ -1933,6 +2442,34 @@ var spacing = {
|
|
|
1933
2442
|
shorthand: ["ms", "marginStart"],
|
|
1934
2443
|
values: marginValues,
|
|
1935
2444
|
group: "Margin"
|
|
2445
|
+
},
|
|
2446
|
+
spaceX: {
|
|
2447
|
+
className: "space-x",
|
|
2448
|
+
values: marginValues,
|
|
2449
|
+
property: "marginInlineStart",
|
|
2450
|
+
group: "Margin",
|
|
2451
|
+
transform(value) {
|
|
2452
|
+
return {
|
|
2453
|
+
"& > :not([hidden]) ~ :not([hidden])": {
|
|
2454
|
+
marginInlineStart: value,
|
|
2455
|
+
marginInlineEnd: "0px"
|
|
2456
|
+
}
|
|
2457
|
+
};
|
|
2458
|
+
}
|
|
2459
|
+
},
|
|
2460
|
+
spaceY: {
|
|
2461
|
+
className: "space-y",
|
|
2462
|
+
values: marginValues,
|
|
2463
|
+
property: "marginBlockStart",
|
|
2464
|
+
group: "Margin",
|
|
2465
|
+
transform(value) {
|
|
2466
|
+
return {
|
|
2467
|
+
"& > :not([hidden]) ~ :not([hidden])": {
|
|
2468
|
+
marginTop: value,
|
|
2469
|
+
marginBottom: "0px"
|
|
2470
|
+
}
|
|
2471
|
+
};
|
|
2472
|
+
}
|
|
1936
2473
|
}
|
|
1937
2474
|
};
|
|
1938
2475
|
|
|
@@ -1965,8 +2502,13 @@ var tables = {
|
|
|
1965
2502
|
},
|
|
1966
2503
|
borderSpacing: {
|
|
1967
2504
|
className: "border-spacing",
|
|
1968
|
-
|
|
1969
|
-
|
|
2505
|
+
group: "Table",
|
|
2506
|
+
values(theme) {
|
|
2507
|
+
return {
|
|
2508
|
+
...theme("spacing"),
|
|
2509
|
+
auto: "var(--border-spacing-x) var(--border-spacing-y)"
|
|
2510
|
+
};
|
|
2511
|
+
}
|
|
1970
2512
|
},
|
|
1971
2513
|
borderSpacingX: {
|
|
1972
2514
|
className: "border-spacing-x",
|
|
@@ -1974,7 +2516,7 @@ var tables = {
|
|
|
1974
2516
|
group: "Table",
|
|
1975
2517
|
transform(value) {
|
|
1976
2518
|
return {
|
|
1977
|
-
|
|
2519
|
+
"--border-spacing-x": value
|
|
1978
2520
|
};
|
|
1979
2521
|
}
|
|
1980
2522
|
},
|
|
@@ -1984,7 +2526,7 @@ var tables = {
|
|
|
1984
2526
|
group: "Table",
|
|
1985
2527
|
transform(value) {
|
|
1986
2528
|
return {
|
|
1987
|
-
|
|
2529
|
+
"--border-spacing-y": value
|
|
1988
2530
|
};
|
|
1989
2531
|
}
|
|
1990
2532
|
},
|
|
@@ -2013,6 +2555,45 @@ var transforms = {
|
|
|
2013
2555
|
className: "origin",
|
|
2014
2556
|
group: "Transform"
|
|
2015
2557
|
},
|
|
2558
|
+
rotate: {
|
|
2559
|
+
className: "rotate",
|
|
2560
|
+
group: "Transform",
|
|
2561
|
+
property: "rotate",
|
|
2562
|
+
values: {
|
|
2563
|
+
auto: "var(--rotate-x) var(--rotate-y)",
|
|
2564
|
+
"auto-3d": "var(--rotate-x) var(--rotate-y) var(--rotate-z)"
|
|
2565
|
+
}
|
|
2566
|
+
},
|
|
2567
|
+
rotateX: {
|
|
2568
|
+
className: "rotate-x",
|
|
2569
|
+
group: "Transform",
|
|
2570
|
+
property: "rotate",
|
|
2571
|
+
transform(value) {
|
|
2572
|
+
return {
|
|
2573
|
+
"--rotate-x": value
|
|
2574
|
+
};
|
|
2575
|
+
}
|
|
2576
|
+
},
|
|
2577
|
+
rotateY: {
|
|
2578
|
+
className: "rotate-y",
|
|
2579
|
+
group: "Transform",
|
|
2580
|
+
property: "rotate",
|
|
2581
|
+
transform(value) {
|
|
2582
|
+
return {
|
|
2583
|
+
"--rotate-y": value
|
|
2584
|
+
};
|
|
2585
|
+
}
|
|
2586
|
+
},
|
|
2587
|
+
rotateZ: {
|
|
2588
|
+
className: "rotate-z",
|
|
2589
|
+
group: "Transform",
|
|
2590
|
+
property: "rotate",
|
|
2591
|
+
transform(value) {
|
|
2592
|
+
return {
|
|
2593
|
+
"--rotate-z": value
|
|
2594
|
+
};
|
|
2595
|
+
}
|
|
2596
|
+
},
|
|
2016
2597
|
scale: {
|
|
2017
2598
|
className: "scale",
|
|
2018
2599
|
group: "Transform",
|
|
@@ -2044,7 +2625,8 @@ var transforms = {
|
|
|
2044
2625
|
group: "Transform",
|
|
2045
2626
|
property: "translate",
|
|
2046
2627
|
values: {
|
|
2047
|
-
auto: "var(--translate-x) var(--translate-y)"
|
|
2628
|
+
auto: "var(--translate-x) var(--translate-y)",
|
|
2629
|
+
"auto-3d": "var(--translate-x) var(--translate-y) var(--translate-z)"
|
|
2048
2630
|
}
|
|
2049
2631
|
},
|
|
2050
2632
|
translateX: {
|
|
@@ -2078,6 +2660,22 @@ var transforms = {
|
|
|
2078
2660
|
"--translate-y": value
|
|
2079
2661
|
};
|
|
2080
2662
|
}
|
|
2663
|
+
},
|
|
2664
|
+
translateZ: {
|
|
2665
|
+
shorthand: "z",
|
|
2666
|
+
className: "translate-z",
|
|
2667
|
+
group: "Transform",
|
|
2668
|
+
values(theme) {
|
|
2669
|
+
return {
|
|
2670
|
+
...theme("spacing"),
|
|
2671
|
+
...fractions
|
|
2672
|
+
};
|
|
2673
|
+
},
|
|
2674
|
+
transform(value) {
|
|
2675
|
+
return {
|
|
2676
|
+
"--translate-z": value
|
|
2677
|
+
};
|
|
2678
|
+
}
|
|
2081
2679
|
}
|
|
2082
2680
|
};
|
|
2083
2681
|
|
|
@@ -2154,6 +2752,16 @@ var transitions = {
|
|
|
2154
2752
|
values: "animationName",
|
|
2155
2753
|
group: "Transition"
|
|
2156
2754
|
},
|
|
2755
|
+
animationTimingFunction: {
|
|
2756
|
+
className: "animation-ease",
|
|
2757
|
+
values: "easings",
|
|
2758
|
+
group: "Transition"
|
|
2759
|
+
},
|
|
2760
|
+
animationDuration: {
|
|
2761
|
+
className: "animation-duration",
|
|
2762
|
+
values: "durations",
|
|
2763
|
+
group: "Transition"
|
|
2764
|
+
},
|
|
2157
2765
|
animationDelay: {
|
|
2158
2766
|
className: "animation-delay",
|
|
2159
2767
|
values: "durations",
|
|
@@ -2165,647 +2773,192 @@ var transitions = {
|
|
|
2165
2773
|
var typography = {
|
|
2166
2774
|
color: {
|
|
2167
2775
|
className: "text",
|
|
2168
|
-
values: "colors",
|
|
2169
|
-
group: "Color",
|
|
2170
|
-
transform: createColorMixTransform("color")
|
|
2171
|
-
},
|
|
2172
|
-
fontFamily: {
|
|
2173
|
-
className: "font",
|
|
2174
|
-
values: "fonts",
|
|
2175
|
-
group: "Typography"
|
|
2176
|
-
},
|
|
2177
|
-
fontSize: {
|
|
2178
|
-
className: "fs",
|
|
2179
|
-
values: "fontSizes",
|
|
2180
|
-
group: "Typography"
|
|
2181
|
-
},
|
|
2182
|
-
fontWeight: {
|
|
2183
|
-
className: "font",
|
|
2184
|
-
values: "fontWeights",
|
|
2185
|
-
group: "Typography"
|
|
2186
|
-
},
|
|
2187
|
-
fontSmoothing: {
|
|
2188
|
-
className: "smoothing",
|
|
2189
|
-
group: "Typography",
|
|
2190
|
-
values: {
|
|
2191
|
-
antialiased: "antialiased",
|
|
2192
|
-
"subpixel-antialiased": "auto"
|
|
2193
|
-
},
|
|
2194
|
-
transform(value) {
|
|
2195
|
-
return {
|
|
2196
|
-
WebkitFontSmoothing: value
|
|
2197
|
-
};
|
|
2198
|
-
}
|
|
2199
|
-
},
|
|
2200
|
-
fontVariantNumeric: {
|
|
2201
|
-
className: "numeric",
|
|
2202
|
-
group: "Typography"
|
|
2203
|
-
},
|
|
2204
|
-
letterSpacing: {
|
|
2205
|
-
className: "tracking",
|
|
2206
|
-
values: "letterSpacings",
|
|
2207
|
-
group: "Typography"
|
|
2208
|
-
},
|
|
2209
|
-
lineHeight: {
|
|
2210
|
-
className: "leading",
|
|
2211
|
-
values: "lineHeights",
|
|
2212
|
-
group: "Typography"
|
|
2213
|
-
},
|
|
2214
|
-
textAlign: {
|
|
2215
|
-
className: "text",
|
|
2216
|
-
group: "Typography"
|
|
2217
|
-
},
|
|
2218
|
-
textDecoration: {
|
|
2219
|
-
className: "text-decor",
|
|
2220
|
-
group: "Typography"
|
|
2221
|
-
},
|
|
2222
|
-
textDecorationColor: {
|
|
2223
|
-
className: "text-decor",
|
|
2224
|
-
values: "colors",
|
|
2225
|
-
transform: createColorMixTransform("textDecorationColor"),
|
|
2226
|
-
group: "Typography"
|
|
2227
|
-
},
|
|
2228
|
-
textEmphasisColor: {
|
|
2229
|
-
className: "text-emphasis",
|
|
2230
|
-
values: "colors",
|
|
2231
|
-
transform: createColorMixTransform("textEmphasisColor"),
|
|
2232
|
-
group: "Typography"
|
|
2233
|
-
},
|
|
2234
|
-
textDecorationStyle: {
|
|
2235
|
-
className: "decoration",
|
|
2236
|
-
group: "Typography"
|
|
2237
|
-
},
|
|
2238
|
-
textDecorationThickness: {
|
|
2239
|
-
className: "decoration",
|
|
2240
|
-
group: "Typography"
|
|
2241
|
-
},
|
|
2242
|
-
textUnderlineOffset: {
|
|
2243
|
-
className: "underline-offset",
|
|
2244
|
-
group: "Typography"
|
|
2245
|
-
},
|
|
2246
|
-
textTransform: {
|
|
2247
|
-
className: "text",
|
|
2248
|
-
group: "Typography"
|
|
2249
|
-
},
|
|
2250
|
-
textIndent: {
|
|
2251
|
-
className: "indent",
|
|
2252
|
-
group: "Typography",
|
|
2253
|
-
values: "spacing"
|
|
2254
|
-
},
|
|
2255
|
-
textShadow: {
|
|
2256
|
-
className: "text-shadow",
|
|
2257
|
-
values: "shadows",
|
|
2258
|
-
group: "Typography"
|
|
2259
|
-
},
|
|
2260
|
-
textShadowColor: {
|
|
2261
|
-
shorthand: "textShadowColor",
|
|
2262
|
-
className: "text-shadow",
|
|
2263
|
-
values: "colors",
|
|
2264
|
-
transform: createColorMixTransform("--text-shadow-color"),
|
|
2265
|
-
group: "Typography"
|
|
2266
|
-
},
|
|
2267
|
-
textOverflow: {
|
|
2268
|
-
className: "text",
|
|
2269
|
-
group: "Typography"
|
|
2270
|
-
},
|
|
2271
|
-
verticalAlign: {
|
|
2272
|
-
className: "align",
|
|
2273
|
-
group: "Typography"
|
|
2274
|
-
},
|
|
2275
|
-
wordBreak: {
|
|
2276
|
-
className: "break",
|
|
2277
|
-
group: "Typography"
|
|
2278
|
-
},
|
|
2279
|
-
textWrap: {
|
|
2280
|
-
className: "text",
|
|
2281
|
-
values: ["wrap", "balance", "nowrap"],
|
|
2282
|
-
group: "Typography",
|
|
2283
|
-
transform(value) {
|
|
2284
|
-
return { textWrap: value };
|
|
2285
|
-
}
|
|
2286
|
-
},
|
|
2287
|
-
truncate: {
|
|
2288
|
-
className: "truncate",
|
|
2289
|
-
values: { type: "boolean" },
|
|
2290
|
-
group: "Typography",
|
|
2291
|
-
transform(value) {
|
|
2292
|
-
if (!value)
|
|
2293
|
-
return {};
|
|
2294
|
-
return {
|
|
2295
|
-
overflow: "hidden",
|
|
2296
|
-
textOverflow: "ellipsis",
|
|
2297
|
-
whiteSpace: "nowrap"
|
|
2298
|
-
};
|
|
2299
|
-
}
|
|
2300
|
-
},
|
|
2301
|
-
lineClamp: {
|
|
2302
|
-
className: "clamp",
|
|
2303
|
-
group: "Typography",
|
|
2304
|
-
transform(value) {
|
|
2305
|
-
if (value === "none") {
|
|
2306
|
-
return {
|
|
2307
|
-
WebkitLineClamp: "unset"
|
|
2308
|
-
};
|
|
2309
|
-
}
|
|
2310
|
-
return {
|
|
2311
|
-
overflow: "hidden",
|
|
2312
|
-
display: "-webkit-box",
|
|
2313
|
-
WebkitLineClamp: value,
|
|
2314
|
-
WebkitBoxOrient: "vertical"
|
|
2315
|
-
};
|
|
2316
|
-
}
|
|
2317
|
-
}
|
|
2318
|
-
};
|
|
2319
|
-
|
|
2320
|
-
// src/utilities/index.ts
|
|
2321
|
-
var utilities = Object.assign(
|
|
2322
|
-
{},
|
|
2323
|
-
layout,
|
|
2324
|
-
display,
|
|
2325
|
-
flexGrid,
|
|
2326
|
-
spacing,
|
|
2327
|
-
outline,
|
|
2328
|
-
divide,
|
|
2329
|
-
sizing,
|
|
2330
|
-
typography,
|
|
2331
|
-
list,
|
|
2332
|
-
background,
|
|
2333
|
-
border,
|
|
2334
|
-
effects,
|
|
2335
|
-
tables,
|
|
2336
|
-
transitions,
|
|
2337
|
-
transforms,
|
|
2338
|
-
interactivity,
|
|
2339
|
-
svg,
|
|
2340
|
-
helpers,
|
|
2341
|
-
polyfill,
|
|
2342
|
-
container
|
|
2343
|
-
);
|
|
2344
|
-
|
|
2345
|
-
// src/patterns.ts
|
|
2346
|
-
function definePattern(config) {
|
|
2347
|
-
return config;
|
|
2348
|
-
}
|
|
2349
|
-
var box = definePattern({
|
|
2350
|
-
transform(props) {
|
|
2351
|
-
return props;
|
|
2352
|
-
}
|
|
2353
|
-
});
|
|
2354
|
-
var flex = definePattern({
|
|
2355
|
-
properties: {
|
|
2356
|
-
align: { type: "property", value: "alignItems" },
|
|
2357
|
-
justify: { type: "property", value: "justifyContent" },
|
|
2358
|
-
direction: { type: "property", value: "flexDirection" },
|
|
2359
|
-
wrap: { type: "property", value: "flexWrap" },
|
|
2360
|
-
basis: { type: "property", value: "flexBasis" },
|
|
2361
|
-
grow: { type: "property", value: "flexGrow" },
|
|
2362
|
-
shrink: { type: "property", value: "flexShrink" }
|
|
2363
|
-
},
|
|
2364
|
-
transform(props) {
|
|
2365
|
-
const { direction, align, justify, wrap: wrap2, basis, grow, shrink, ...rest } = props;
|
|
2366
|
-
return {
|
|
2367
|
-
display: "flex",
|
|
2368
|
-
flexDirection: direction,
|
|
2369
|
-
alignItems: align,
|
|
2370
|
-
justifyContent: justify,
|
|
2371
|
-
flexWrap: wrap2,
|
|
2372
|
-
flexBasis: basis,
|
|
2373
|
-
flexGrow: grow,
|
|
2374
|
-
flexShrink: shrink,
|
|
2375
|
-
...rest
|
|
2376
|
-
};
|
|
2377
|
-
}
|
|
2378
|
-
});
|
|
2379
|
-
var stack = definePattern({
|
|
2380
|
-
properties: {
|
|
2381
|
-
align: { type: "property", value: "alignItems" },
|
|
2382
|
-
justify: { type: "property", value: "justifyContent" },
|
|
2383
|
-
direction: { type: "property", value: "flexDirection" },
|
|
2384
|
-
gap: { type: "property", value: "gap" }
|
|
2385
|
-
},
|
|
2386
|
-
defaultValues: {
|
|
2387
|
-
direction: "column",
|
|
2388
|
-
gap: "10px"
|
|
2389
|
-
},
|
|
2390
|
-
transform(props) {
|
|
2391
|
-
const { align, justify, direction, gap, ...rest } = props;
|
|
2392
|
-
return {
|
|
2393
|
-
display: "flex",
|
|
2394
|
-
flexDirection: direction,
|
|
2395
|
-
alignItems: align,
|
|
2396
|
-
justifyContent: justify,
|
|
2397
|
-
gap,
|
|
2398
|
-
...rest
|
|
2399
|
-
};
|
|
2400
|
-
}
|
|
2401
|
-
});
|
|
2402
|
-
var vstack = definePattern({
|
|
2403
|
-
jsxName: "VStack",
|
|
2404
|
-
properties: {
|
|
2405
|
-
justify: { type: "property", value: "justifyContent" },
|
|
2406
|
-
gap: { type: "property", value: "gap" }
|
|
2776
|
+
values: "colors",
|
|
2777
|
+
group: "Color",
|
|
2778
|
+
transform: createColorMixTransform("color")
|
|
2407
2779
|
},
|
|
2408
|
-
|
|
2409
|
-
|
|
2780
|
+
fontFamily: {
|
|
2781
|
+
className: "font",
|
|
2782
|
+
values: "fonts",
|
|
2783
|
+
group: "Typography"
|
|
2410
2784
|
},
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
alignItems: "center",
|
|
2416
|
-
justifyContent: justify,
|
|
2417
|
-
gap,
|
|
2418
|
-
flexDirection: "column",
|
|
2419
|
-
...rest
|
|
2420
|
-
};
|
|
2421
|
-
}
|
|
2422
|
-
});
|
|
2423
|
-
var hstack = definePattern({
|
|
2424
|
-
jsxName: "HStack",
|
|
2425
|
-
properties: {
|
|
2426
|
-
justify: { type: "property", value: "justifyContent" },
|
|
2427
|
-
gap: { type: "property", value: "gap" }
|
|
2785
|
+
fontSize: {
|
|
2786
|
+
className: "fs",
|
|
2787
|
+
values: "fontSizes",
|
|
2788
|
+
group: "Typography"
|
|
2428
2789
|
},
|
|
2429
|
-
|
|
2430
|
-
|
|
2790
|
+
fontWeight: {
|
|
2791
|
+
className: "fw",
|
|
2792
|
+
values: "fontWeights",
|
|
2793
|
+
group: "Typography"
|
|
2431
2794
|
},
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
}
|
|
2444
|
-
var spacer = definePattern({
|
|
2445
|
-
properties: {
|
|
2446
|
-
size: { type: "token", value: "spacing" }
|
|
2795
|
+
fontSmoothing: {
|
|
2796
|
+
className: "smoothing",
|
|
2797
|
+
group: "Typography",
|
|
2798
|
+
values: {
|
|
2799
|
+
antialiased: "antialiased",
|
|
2800
|
+
"subpixel-antialiased": "auto"
|
|
2801
|
+
},
|
|
2802
|
+
transform(value) {
|
|
2803
|
+
return {
|
|
2804
|
+
WebkitFontSmoothing: value
|
|
2805
|
+
};
|
|
2806
|
+
}
|
|
2447
2807
|
},
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
alignSelf: "stretch",
|
|
2452
|
-
justifySelf: "stretch",
|
|
2453
|
-
flex: map(size, (v) => v == null ? "1" : `0 0 ${v}`),
|
|
2454
|
-
...rest
|
|
2455
|
-
};
|
|
2456
|
-
}
|
|
2457
|
-
});
|
|
2458
|
-
var circle = definePattern({
|
|
2459
|
-
properties: {
|
|
2460
|
-
size: { type: "property", value: "width" }
|
|
2808
|
+
fontVariantNumeric: {
|
|
2809
|
+
className: "numeric",
|
|
2810
|
+
group: "Typography"
|
|
2461
2811
|
},
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
alignItems: "center",
|
|
2467
|
-
justifyContent: "center",
|
|
2468
|
-
flex: "0 0 auto",
|
|
2469
|
-
width: size,
|
|
2470
|
-
height: size,
|
|
2471
|
-
borderRadius: "9999px",
|
|
2472
|
-
...rest
|
|
2473
|
-
};
|
|
2474
|
-
}
|
|
2475
|
-
});
|
|
2476
|
-
var square = definePattern({
|
|
2477
|
-
properties: {
|
|
2478
|
-
size: { type: "property", value: "width" }
|
|
2812
|
+
letterSpacing: {
|
|
2813
|
+
className: "tracking",
|
|
2814
|
+
values: "letterSpacings",
|
|
2815
|
+
group: "Typography"
|
|
2479
2816
|
},
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
alignItems: "center",
|
|
2485
|
-
justifyContent: "center",
|
|
2486
|
-
flex: "0 0 auto",
|
|
2487
|
-
width: size,
|
|
2488
|
-
height: size,
|
|
2489
|
-
...rest
|
|
2490
|
-
};
|
|
2491
|
-
}
|
|
2492
|
-
});
|
|
2493
|
-
var grid = definePattern({
|
|
2494
|
-
properties: {
|
|
2495
|
-
gap: { type: "property", value: "gap" },
|
|
2496
|
-
columnGap: { type: "property", value: "gap" },
|
|
2497
|
-
rowGap: { type: "property", value: "gap" },
|
|
2498
|
-
columns: { type: "number" },
|
|
2499
|
-
minChildWidth: { type: "token", value: "sizes", property: "width" }
|
|
2817
|
+
lineHeight: {
|
|
2818
|
+
className: "leading",
|
|
2819
|
+
values: "lineHeights",
|
|
2820
|
+
group: "Typography"
|
|
2500
2821
|
},
|
|
2501
|
-
|
|
2502
|
-
|
|
2822
|
+
textAlign: {
|
|
2823
|
+
className: "text-align",
|
|
2824
|
+
group: "Typography"
|
|
2503
2825
|
},
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
return {
|
|
2508
|
-
display: "grid",
|
|
2509
|
-
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,
|
|
2510
|
-
gap,
|
|
2511
|
-
columnGap,
|
|
2512
|
-
rowGap,
|
|
2513
|
-
...rest
|
|
2514
|
-
};
|
|
2515
|
-
}
|
|
2516
|
-
});
|
|
2517
|
-
var gridItem = definePattern({
|
|
2518
|
-
properties: {
|
|
2519
|
-
colSpan: { type: "number" },
|
|
2520
|
-
rowSpan: { type: "number" },
|
|
2521
|
-
colStart: { type: "number" },
|
|
2522
|
-
rowStart: { type: "number" },
|
|
2523
|
-
colEnd: { type: "number" },
|
|
2524
|
-
rowEnd: { type: "number" }
|
|
2826
|
+
textDecoration: {
|
|
2827
|
+
className: "text-decor",
|
|
2828
|
+
group: "Typography"
|
|
2525
2829
|
},
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
gridRow: rowSpan != null ? map(rowSpan, spanFn) : void 0,
|
|
2532
|
-
gridColumnStart: colStart,
|
|
2533
|
-
gridColumnEnd: colEnd,
|
|
2534
|
-
gridRowStart: rowStart,
|
|
2535
|
-
gridRowEnd: rowEnd,
|
|
2536
|
-
...rest
|
|
2537
|
-
};
|
|
2538
|
-
}
|
|
2539
|
-
});
|
|
2540
|
-
var wrap = definePattern({
|
|
2541
|
-
properties: {
|
|
2542
|
-
gap: { type: "property", value: "gap" },
|
|
2543
|
-
rowGap: { type: "property", value: "gap" },
|
|
2544
|
-
columnGap: { type: "property", value: "gap" },
|
|
2545
|
-
align: { type: "property", value: "alignItems" },
|
|
2546
|
-
justify: { type: "property", value: "justifyContent" }
|
|
2830
|
+
textDecorationColor: {
|
|
2831
|
+
className: "text-decor-color",
|
|
2832
|
+
values: "colors",
|
|
2833
|
+
transform: createColorMixTransform("textDecorationColor"),
|
|
2834
|
+
group: "Typography"
|
|
2547
2835
|
},
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
alignItems: align,
|
|
2554
|
-
justifyContent: justify,
|
|
2555
|
-
gap,
|
|
2556
|
-
columnGap,
|
|
2557
|
-
rowGap,
|
|
2558
|
-
...rest
|
|
2559
|
-
};
|
|
2560
|
-
}
|
|
2561
|
-
});
|
|
2562
|
-
var container2 = definePattern({
|
|
2563
|
-
transform(props) {
|
|
2564
|
-
return {
|
|
2565
|
-
position: "relative",
|
|
2566
|
-
maxWidth: "8xl",
|
|
2567
|
-
mx: "auto",
|
|
2568
|
-
px: { base: "4", md: "6", lg: "8" },
|
|
2569
|
-
...props
|
|
2570
|
-
};
|
|
2571
|
-
}
|
|
2572
|
-
});
|
|
2573
|
-
var center = definePattern({
|
|
2574
|
-
properties: {
|
|
2575
|
-
inline: { type: "boolean" }
|
|
2836
|
+
textEmphasisColor: {
|
|
2837
|
+
className: "text-emphasis-color",
|
|
2838
|
+
values: "colors",
|
|
2839
|
+
transform: createColorMixTransform("textEmphasisColor"),
|
|
2840
|
+
group: "Typography"
|
|
2576
2841
|
},
|
|
2577
|
-
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
display: inline ? "inline-flex" : "flex",
|
|
2581
|
-
alignItems: "center",
|
|
2582
|
-
justifyContent: "center",
|
|
2583
|
-
...rest
|
|
2584
|
-
};
|
|
2585
|
-
}
|
|
2586
|
-
});
|
|
2587
|
-
var aspectRatio = definePattern({
|
|
2588
|
-
properties: {
|
|
2589
|
-
ratio: { type: "number" }
|
|
2842
|
+
textDecorationStyle: {
|
|
2843
|
+
className: "decoration-style",
|
|
2844
|
+
group: "Typography"
|
|
2590
2845
|
},
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
|
|
2594
|
-
return {
|
|
2595
|
-
position: "relative",
|
|
2596
|
-
_before: {
|
|
2597
|
-
content: `""`,
|
|
2598
|
-
display: "block",
|
|
2599
|
-
height: "0",
|
|
2600
|
-
paddingBottom: map(ratio, (r) => `${1 / r * 100}%`)
|
|
2601
|
-
},
|
|
2602
|
-
"&>*": {
|
|
2603
|
-
display: "flex",
|
|
2604
|
-
justifyContent: "center",
|
|
2605
|
-
alignItems: "center",
|
|
2606
|
-
overflow: "hidden",
|
|
2607
|
-
position: "absolute",
|
|
2608
|
-
inset: "0",
|
|
2609
|
-
width: "100%",
|
|
2610
|
-
height: "100%"
|
|
2611
|
-
},
|
|
2612
|
-
"&>img, &>video": {
|
|
2613
|
-
objectFit: "cover"
|
|
2614
|
-
},
|
|
2615
|
-
...rest
|
|
2616
|
-
};
|
|
2617
|
-
}
|
|
2618
|
-
});
|
|
2619
|
-
var divider = definePattern({
|
|
2620
|
-
properties: {
|
|
2621
|
-
orientation: { type: "enum", value: ["horizontal", "vertical"] },
|
|
2622
|
-
thickness: { type: "token", value: "sizes", property: "borderWidth" },
|
|
2623
|
-
color: { type: "token", value: "colors", property: "borderColor" }
|
|
2846
|
+
textDecorationThickness: {
|
|
2847
|
+
className: "decoration-thickness",
|
|
2848
|
+
group: "Typography"
|
|
2624
2849
|
},
|
|
2625
|
-
|
|
2626
|
-
|
|
2627
|
-
|
|
2850
|
+
textUnderlineOffset: {
|
|
2851
|
+
className: "underline-offset",
|
|
2852
|
+
group: "Typography"
|
|
2628
2853
|
},
|
|
2629
|
-
|
|
2630
|
-
|
|
2631
|
-
|
|
2632
|
-
"--thickness": thickness,
|
|
2633
|
-
width: map(orientation, (v) => v === "vertical" ? void 0 : "100%"),
|
|
2634
|
-
height: map(orientation, (v) => v === "horizontal" ? void 0 : "100%"),
|
|
2635
|
-
borderBlockEndWidth: map(orientation, (v) => v === "horizontal" ? "var(--thickness)" : void 0),
|
|
2636
|
-
borderInlineEndWidth: map(orientation, (v) => v === "vertical" ? "var(--thickness)" : void 0),
|
|
2637
|
-
borderColor: color,
|
|
2638
|
-
...rest
|
|
2639
|
-
};
|
|
2640
|
-
}
|
|
2641
|
-
});
|
|
2642
|
-
var linkBox = definePattern({
|
|
2643
|
-
transform(props) {
|
|
2644
|
-
return {
|
|
2645
|
-
position: "relative",
|
|
2646
|
-
"& :where(a, abbr)": {
|
|
2647
|
-
position: "relative",
|
|
2648
|
-
zIndex: "1"
|
|
2649
|
-
},
|
|
2650
|
-
...props
|
|
2651
|
-
};
|
|
2652
|
-
}
|
|
2653
|
-
});
|
|
2654
|
-
var linkOverlay = definePattern({
|
|
2655
|
-
jsxElement: "a",
|
|
2656
|
-
transform(props) {
|
|
2657
|
-
return {
|
|
2658
|
-
position: "static",
|
|
2659
|
-
_before: {
|
|
2660
|
-
content: '""',
|
|
2661
|
-
display: "block",
|
|
2662
|
-
position: "absolute",
|
|
2663
|
-
cursor: "inherit",
|
|
2664
|
-
inset: "0",
|
|
2665
|
-
zIndex: "0",
|
|
2666
|
-
...props["_before"]
|
|
2667
|
-
},
|
|
2668
|
-
...props
|
|
2669
|
-
};
|
|
2670
|
-
}
|
|
2671
|
-
});
|
|
2672
|
-
var float = definePattern({
|
|
2673
|
-
properties: {
|
|
2674
|
-
offsetX: { type: "token", value: "spacing", property: "left" },
|
|
2675
|
-
offsetY: { type: "token", value: "spacing", property: "top" },
|
|
2676
|
-
offset: { type: "token", value: "spacing", property: "top" },
|
|
2677
|
-
placement: {
|
|
2678
|
-
type: "enum",
|
|
2679
|
-
value: [
|
|
2680
|
-
"bottom-end",
|
|
2681
|
-
"bottom-start",
|
|
2682
|
-
"top-end",
|
|
2683
|
-
"top-start",
|
|
2684
|
-
"bottom-center",
|
|
2685
|
-
"top-center",
|
|
2686
|
-
"middle-center",
|
|
2687
|
-
"middle-end",
|
|
2688
|
-
"middle-start"
|
|
2689
|
-
]
|
|
2690
|
-
}
|
|
2854
|
+
textTransform: {
|
|
2855
|
+
className: "text-transform",
|
|
2856
|
+
group: "Typography"
|
|
2691
2857
|
},
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2858
|
+
textIndent: {
|
|
2859
|
+
className: "indent",
|
|
2860
|
+
group: "Typography",
|
|
2861
|
+
values: "spacing"
|
|
2695
2862
|
},
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
justifyContent: "center",
|
|
2701
|
-
alignItems: "center",
|
|
2702
|
-
position: "absolute",
|
|
2703
|
-
insetBlockStart: map(placement, (v) => {
|
|
2704
|
-
const [side] = v.split("-");
|
|
2705
|
-
const map2 = { top: offsetY, middle: "50%", bottom: "auto" };
|
|
2706
|
-
return map2[side];
|
|
2707
|
-
}),
|
|
2708
|
-
insetBlockEnd: map(placement, (v) => {
|
|
2709
|
-
const [side] = v.split("-");
|
|
2710
|
-
const map2 = { top: "auto", middle: "50%", bottom: offsetY };
|
|
2711
|
-
return map2[side];
|
|
2712
|
-
}),
|
|
2713
|
-
insetInlineStart: map(placement, (v) => {
|
|
2714
|
-
const [, align] = v.split("-");
|
|
2715
|
-
const map2 = { start: offsetX, center: "50%", end: "auto" };
|
|
2716
|
-
return map2[align];
|
|
2717
|
-
}),
|
|
2718
|
-
insetInlineEnd: map(placement, (v) => {
|
|
2719
|
-
const [, align] = v.split("-");
|
|
2720
|
-
const map2 = { start: "auto", center: "50%", end: offsetX };
|
|
2721
|
-
return map2[align];
|
|
2722
|
-
}),
|
|
2723
|
-
translate: map(placement, (v) => {
|
|
2724
|
-
const [side, align] = v.split("-");
|
|
2725
|
-
const mapX = { start: "-50%", center: "-50%", end: "50%" };
|
|
2726
|
-
const mapY = { top: "-50%", middle: "-50%", bottom: "50%" };
|
|
2727
|
-
return `${mapX[align]} ${mapY[side]}`;
|
|
2728
|
-
}),
|
|
2729
|
-
...rest
|
|
2730
|
-
};
|
|
2731
|
-
}
|
|
2732
|
-
});
|
|
2733
|
-
var bleed = definePattern({
|
|
2734
|
-
properties: {
|
|
2735
|
-
inline: { type: "property", value: "marginInline" },
|
|
2736
|
-
block: { type: "property", value: "marginBlock" }
|
|
2863
|
+
textShadow: {
|
|
2864
|
+
className: "text-shadow",
|
|
2865
|
+
values: "shadows",
|
|
2866
|
+
group: "Typography"
|
|
2737
2867
|
},
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2868
|
+
textShadowColor: {
|
|
2869
|
+
shorthand: "textShadowColor",
|
|
2870
|
+
className: "text-shadow",
|
|
2871
|
+
values: "colors",
|
|
2872
|
+
transform: createColorMixTransform("--text-shadow-color"),
|
|
2873
|
+
group: "Typography"
|
|
2741
2874
|
},
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
return {
|
|
2746
|
-
"--bleed-x": map(inline, valueFn),
|
|
2747
|
-
"--bleed-y": map(block, valueFn),
|
|
2748
|
-
marginInline: "calc(var(--bleed-x, 0) * -1)",
|
|
2749
|
-
marginBlock: "calc(var(--bleed-y, 0) * -1)",
|
|
2750
|
-
...rest
|
|
2751
|
-
};
|
|
2752
|
-
}
|
|
2753
|
-
});
|
|
2754
|
-
var visuallyHidden = definePattern({
|
|
2755
|
-
transform(props) {
|
|
2756
|
-
return {
|
|
2757
|
-
srOnly: true,
|
|
2758
|
-
...props
|
|
2759
|
-
};
|
|
2760
|
-
}
|
|
2761
|
-
});
|
|
2762
|
-
var cq = definePattern({
|
|
2763
|
-
properties: {
|
|
2764
|
-
name: { type: "token", value: "containerNames", property: "containerName" },
|
|
2765
|
-
type: { type: "property", value: "containerType" }
|
|
2875
|
+
textOverflow: {
|
|
2876
|
+
className: "text-overflow",
|
|
2877
|
+
group: "Typography"
|
|
2766
2878
|
},
|
|
2767
|
-
|
|
2768
|
-
|
|
2879
|
+
verticalAlign: {
|
|
2880
|
+
className: "v-align",
|
|
2881
|
+
group: "Typography"
|
|
2769
2882
|
},
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2883
|
+
wordBreak: {
|
|
2884
|
+
className: "break",
|
|
2885
|
+
group: "Typography"
|
|
2886
|
+
},
|
|
2887
|
+
textWrap: {
|
|
2888
|
+
className: "text-wrap",
|
|
2889
|
+
values: ["wrap", "balance", "nowrap"],
|
|
2890
|
+
group: "Typography",
|
|
2891
|
+
transform(value) {
|
|
2892
|
+
return { textWrap: value };
|
|
2893
|
+
}
|
|
2894
|
+
},
|
|
2895
|
+
truncate: {
|
|
2896
|
+
className: "truncate",
|
|
2897
|
+
values: { type: "boolean" },
|
|
2898
|
+
group: "Typography",
|
|
2899
|
+
transform(value) {
|
|
2900
|
+
if (!value)
|
|
2901
|
+
return {};
|
|
2902
|
+
return {
|
|
2903
|
+
overflow: "hidden",
|
|
2904
|
+
textOverflow: "ellipsis",
|
|
2905
|
+
whiteSpace: "nowrap"
|
|
2906
|
+
};
|
|
2907
|
+
}
|
|
2908
|
+
},
|
|
2909
|
+
lineClamp: {
|
|
2910
|
+
className: "clamp",
|
|
2911
|
+
group: "Typography",
|
|
2912
|
+
transform(value) {
|
|
2913
|
+
if (value === "none") {
|
|
2914
|
+
return {
|
|
2915
|
+
WebkitLineClamp: "unset"
|
|
2916
|
+
};
|
|
2917
|
+
}
|
|
2918
|
+
return {
|
|
2919
|
+
overflow: "hidden",
|
|
2920
|
+
display: "-webkit-box",
|
|
2921
|
+
WebkitLineClamp: value,
|
|
2922
|
+
WebkitBoxOrient: "vertical"
|
|
2923
|
+
};
|
|
2924
|
+
}
|
|
2777
2925
|
}
|
|
2778
|
-
});
|
|
2779
|
-
var patterns = {
|
|
2780
|
-
box,
|
|
2781
|
-
flex,
|
|
2782
|
-
stack,
|
|
2783
|
-
vstack,
|
|
2784
|
-
hstack,
|
|
2785
|
-
spacer,
|
|
2786
|
-
square,
|
|
2787
|
-
circle,
|
|
2788
|
-
center,
|
|
2789
|
-
linkBox,
|
|
2790
|
-
linkOverlay,
|
|
2791
|
-
aspectRatio,
|
|
2792
|
-
grid,
|
|
2793
|
-
gridItem,
|
|
2794
|
-
wrap,
|
|
2795
|
-
container: container2,
|
|
2796
|
-
divider,
|
|
2797
|
-
float,
|
|
2798
|
-
bleed,
|
|
2799
|
-
visuallyHidden,
|
|
2800
|
-
cq
|
|
2801
2926
|
};
|
|
2802
2927
|
|
|
2928
|
+
// src/utilities/index.ts
|
|
2929
|
+
var utilities = Object.assign(
|
|
2930
|
+
{},
|
|
2931
|
+
layout,
|
|
2932
|
+
display,
|
|
2933
|
+
flexGrid,
|
|
2934
|
+
spacing,
|
|
2935
|
+
outline,
|
|
2936
|
+
divide,
|
|
2937
|
+
sizing,
|
|
2938
|
+
typography,
|
|
2939
|
+
list,
|
|
2940
|
+
background,
|
|
2941
|
+
backgroundGradients,
|
|
2942
|
+
border,
|
|
2943
|
+
effects,
|
|
2944
|
+
tables,
|
|
2945
|
+
transitions,
|
|
2946
|
+
transforms,
|
|
2947
|
+
interactivity,
|
|
2948
|
+
svg,
|
|
2949
|
+
helpers,
|
|
2950
|
+
polyfill,
|
|
2951
|
+
container2
|
|
2952
|
+
);
|
|
2953
|
+
|
|
2803
2954
|
// src/index.ts
|
|
2804
2955
|
var definePreset = (preset2) => preset2;
|
|
2805
2956
|
var preset = definePreset({
|
|
2806
2957
|
conditions,
|
|
2807
2958
|
utilities,
|
|
2808
|
-
patterns
|
|
2959
|
+
patterns,
|
|
2960
|
+
// globalVars,
|
|
2961
|
+
globalCss
|
|
2809
2962
|
});
|
|
2810
2963
|
var src_default = preset;
|
|
2811
2964
|
// Annotate the CommonJS export names for ESM import in node:
|