infinity-ui-elements 1.0.1 → 1.0.3

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.esm.js CHANGED
@@ -1,14 +1,3509 @@
1
- import { jsx } from 'react/jsx-runtime';
1
+ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
2
+ import * as React from 'react';
2
3
 
3
- const Button = ({ variant = "primary", children, onClick, disabled = false, className = "", }) => {
4
- const baseClasses = "px-4 py-2 rounded font-semibold transition-colors duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2";
5
- const variantClasses = {
6
- primary: "bg-primary text-white hover:bg-blue-600 focus:ring-primary disabled:bg-gray-400 disabled:cursor-not-allowed",
7
- secondary: "bg-secondary text-white hover:bg-gray-600 focus:ring-secondary disabled:bg-gray-400 disabled:cursor-not-allowed",
4
+ // packages/react/compose-refs/src/compose-refs.tsx
5
+ function setRef(ref, value) {
6
+ if (typeof ref === "function") {
7
+ return ref(value);
8
+ } else if (ref !== null && ref !== void 0) {
9
+ ref.current = value;
10
+ }
11
+ }
12
+ function composeRefs(...refs) {
13
+ return (node) => {
14
+ let hasCleanup = false;
15
+ const cleanups = refs.map((ref) => {
16
+ const cleanup = setRef(ref, node);
17
+ if (!hasCleanup && typeof cleanup == "function") {
18
+ hasCleanup = true;
19
+ }
20
+ return cleanup;
21
+ });
22
+ if (hasCleanup) {
23
+ return () => {
24
+ for (let i = 0; i < cleanups.length; i++) {
25
+ const cleanup = cleanups[i];
26
+ if (typeof cleanup == "function") {
27
+ cleanup();
28
+ } else {
29
+ setRef(refs[i], null);
30
+ }
31
+ }
32
+ };
33
+ }
34
+ };
35
+ }
36
+
37
+ // src/slot.tsx
38
+ // @__NO_SIDE_EFFECTS__
39
+ function createSlot(ownerName) {
40
+ const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
41
+ const Slot2 = React.forwardRef((props, forwardedRef) => {
42
+ const { children, ...slotProps } = props;
43
+ const childrenArray = React.Children.toArray(children);
44
+ const slottable = childrenArray.find(isSlottable);
45
+ if (slottable) {
46
+ const newElement = slottable.props.children;
47
+ const newChildren = childrenArray.map((child) => {
48
+ if (child === slottable) {
49
+ if (React.Children.count(newElement) > 1) return React.Children.only(null);
50
+ return React.isValidElement(newElement) ? newElement.props.children : null;
51
+ } else {
52
+ return child;
53
+ }
54
+ });
55
+ return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });
56
+ }
57
+ return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
58
+ });
59
+ Slot2.displayName = `${ownerName}.Slot`;
60
+ return Slot2;
61
+ }
62
+ var Slot = /* @__PURE__ */ createSlot("Slot");
63
+ // @__NO_SIDE_EFFECTS__
64
+ function createSlotClone(ownerName) {
65
+ const SlotClone = React.forwardRef((props, forwardedRef) => {
66
+ const { children, ...slotProps } = props;
67
+ if (React.isValidElement(children)) {
68
+ const childrenRef = getElementRef(children);
69
+ const props2 = mergeProps(slotProps, children.props);
70
+ if (children.type !== React.Fragment) {
71
+ props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
72
+ }
73
+ return React.cloneElement(children, props2);
74
+ }
75
+ return React.Children.count(children) > 1 ? React.Children.only(null) : null;
76
+ });
77
+ SlotClone.displayName = `${ownerName}.SlotClone`;
78
+ return SlotClone;
79
+ }
80
+ var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
81
+ function isSlottable(child) {
82
+ return React.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
83
+ }
84
+ function mergeProps(slotProps, childProps) {
85
+ const overrideProps = { ...childProps };
86
+ for (const propName in childProps) {
87
+ const slotPropValue = slotProps[propName];
88
+ const childPropValue = childProps[propName];
89
+ const isHandler = /^on[A-Z]/.test(propName);
90
+ if (isHandler) {
91
+ if (slotPropValue && childPropValue) {
92
+ overrideProps[propName] = (...args) => {
93
+ const result = childPropValue(...args);
94
+ slotPropValue(...args);
95
+ return result;
96
+ };
97
+ } else if (slotPropValue) {
98
+ overrideProps[propName] = slotPropValue;
99
+ }
100
+ } else if (propName === "style") {
101
+ overrideProps[propName] = { ...slotPropValue, ...childPropValue };
102
+ } else if (propName === "className") {
103
+ overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
104
+ }
105
+ }
106
+ return { ...slotProps, ...overrideProps };
107
+ }
108
+ function getElementRef(element) {
109
+ let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
110
+ let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
111
+ if (mayWarn) {
112
+ return element.ref;
113
+ }
114
+ getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
115
+ mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
116
+ if (mayWarn) {
117
+ return element.props.ref;
118
+ }
119
+ return element.props.ref || element.ref;
120
+ }
121
+
122
+ function r(e){var t,f,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=" "),n+=f);}else for(f in e)e[f]&&(n&&(n+=" "),n+=f);return n}function clsx(){for(var e,t,f=0,n="",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=" "),n+=t);return n}
123
+
124
+ const falsyToString = (value)=>typeof value === "boolean" ? `${value}` : value === 0 ? "0" : value;
125
+ const cx = clsx;
126
+ const cva = (base, config)=>(props)=>{
127
+ var _config_compoundVariants;
128
+ if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
129
+ const { variants, defaultVariants } = config;
130
+ const getVariantClassNames = Object.keys(variants).map((variant)=>{
131
+ const variantProp = props === null || props === void 0 ? void 0 : props[variant];
132
+ const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];
133
+ if (variantProp === null) return null;
134
+ const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);
135
+ return variants[variant][variantKey];
136
+ });
137
+ const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param)=>{
138
+ let [key, value] = param;
139
+ if (value === undefined) {
140
+ return acc;
141
+ }
142
+ acc[key] = value;
143
+ return acc;
144
+ }, {});
145
+ const getCompoundVariantClassNames = config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param)=>{
146
+ let { class: cvClass, className: cvClassName, ...compoundVariantOptions } = param;
147
+ return Object.entries(compoundVariantOptions).every((param)=>{
148
+ let [key, value] = param;
149
+ return Array.isArray(value) ? value.includes({
150
+ ...defaultVariants,
151
+ ...propsWithoutUndefined
152
+ }[key]) : ({
153
+ ...defaultVariants,
154
+ ...propsWithoutUndefined
155
+ })[key] === value;
156
+ }) ? [
157
+ ...acc,
158
+ cvClass,
159
+ cvClassName
160
+ ] : acc;
161
+ }, []);
162
+ return cx(base, getVariantClassNames, getCompoundVariantClassNames, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
163
+ };
164
+
165
+ var cssUnit = {
166
+ cm: true,
167
+ mm: true,
168
+ in: true,
169
+ px: true,
170
+ pt: true,
171
+ pc: true,
172
+ em: true,
173
+ ex: true,
174
+ ch: true,
175
+ rem: true,
176
+ vw: true,
177
+ vh: true,
178
+ vmin: true,
179
+ vmax: true,
180
+ "%": true,
181
+ };
182
+ /**
183
+ * If size is a number, append px to the value as default unit.
184
+ * If size is a string, validate against list of valid units.
185
+ * If unit is valid, return size as is.
186
+ * If unit is invalid, console warn issue, replace with px as the unit.
187
+ *
188
+ * @param {(number | string)} size
189
+ * @return {LengthObject} LengthObject
190
+ */
191
+ function parseLengthAndUnit(size) {
192
+ if (typeof size === "number") {
193
+ return {
194
+ value: size,
195
+ unit: "px",
196
+ };
197
+ }
198
+ var value;
199
+ var valueString = (size.match(/^[0-9.]*/) || "").toString();
200
+ if (valueString.includes(".")) {
201
+ value = parseFloat(valueString);
202
+ }
203
+ else {
204
+ value = parseInt(valueString, 10);
205
+ }
206
+ var unit = (size.match(/[^0-9]*$/) || "").toString();
207
+ if (cssUnit[unit]) {
208
+ return {
209
+ value: value,
210
+ unit: unit,
211
+ };
212
+ }
213
+ console.warn("React Spinners: ".concat(size, " is not a valid css value. Defaulting to ").concat(value, "px."));
214
+ return {
215
+ value: value,
216
+ unit: "px",
8
217
  };
9
- const combinedClasses = `${baseClasses} ${variantClasses[variant]} ${className}`;
10
- return (jsx("button", { className: combinedClasses, onClick: onClick, disabled: disabled, children: children }));
218
+ }
219
+ /**
220
+ * Take value as an input and return valid css value
221
+ *
222
+ * @param {(number | string)} value
223
+ * @return {string} valid css value
224
+ */
225
+ function cssValue(value) {
226
+ var lengthWithunit = parseLengthAndUnit(value);
227
+ return "".concat(lengthWithunit.value).concat(lengthWithunit.unit);
228
+ }
229
+
230
+ var createAnimation = function (loaderName, frames, suffix) {
231
+ var animationName = "react-spinners-".concat(loaderName, "-").concat(suffix);
232
+ if (typeof window == "undefined" || !window.document) {
233
+ return animationName;
234
+ }
235
+ var styleEl = document.createElement("style");
236
+ document.head.appendChild(styleEl);
237
+ var styleSheet = styleEl.sheet;
238
+ var keyFrames = "\n @keyframes ".concat(animationName, " {\n ").concat(frames, "\n }\n ");
239
+ if (styleSheet) {
240
+ styleSheet.insertRule(keyFrames, 0);
241
+ }
242
+ return animationName;
243
+ };
244
+
245
+ var __assign$1 = (undefined && undefined.__assign) || function () {
246
+ __assign$1 = Object.assign || function(t) {
247
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
248
+ s = arguments[i];
249
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
250
+ t[p] = s[p];
251
+ }
252
+ return t;
253
+ };
254
+ return __assign$1.apply(this, arguments);
255
+ };
256
+ var __rest$1 = (undefined && undefined.__rest) || function (s, e) {
257
+ var t = {};
258
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
259
+ t[p] = s[p];
260
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
261
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
262
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
263
+ t[p[i]] = s[p[i]];
264
+ }
265
+ return t;
266
+ };
267
+ var clip = createAnimation("ClipLoader", "0% {transform: rotate(0deg) scale(1)} 50% {transform: rotate(180deg) scale(0.8)} 100% {transform: rotate(360deg) scale(1)}", "clip");
268
+ function ClipLoader(_a) {
269
+ var _b = _a.loading, loading = _b === void 0 ? true : _b, _c = _a.color, color = _c === void 0 ? "#000000" : _c, _d = _a.speedMultiplier, speedMultiplier = _d === void 0 ? 1 : _d, _e = _a.cssOverride, cssOverride = _e === void 0 ? {} : _e, _f = _a.size, size = _f === void 0 ? 35 : _f, additionalprops = __rest$1(_a, ["loading", "color", "speedMultiplier", "cssOverride", "size"]);
270
+ var style = __assign$1({ background: "transparent !important", width: cssValue(size), height: cssValue(size), borderRadius: "100%", border: "2px solid", borderTopColor: color, borderBottomColor: "transparent", borderLeftColor: color, borderRightColor: color, display: "inline-block", animation: "".concat(clip, " ").concat(0.75 / speedMultiplier, "s 0s infinite linear"), animationFillMode: "both" }, cssOverride);
271
+ if (!loading) {
272
+ return null;
273
+ }
274
+ return React.createElement("span", __assign$1({ style: style }, additionalprops));
275
+ }
276
+
277
+ var __assign = (undefined && undefined.__assign) || function () {
278
+ __assign = Object.assign || function(t) {
279
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
280
+ s = arguments[i];
281
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
282
+ t[p] = s[p];
283
+ }
284
+ return t;
285
+ };
286
+ return __assign.apply(this, arguments);
287
+ };
288
+ var __rest = (undefined && undefined.__rest) || function (s, e) {
289
+ var t = {};
290
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
291
+ t[p] = s[p];
292
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
293
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
294
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
295
+ t[p[i]] = s[p[i]];
296
+ }
297
+ return t;
298
+ };
299
+ var pulse = createAnimation("PulseLoader", "0% {transform: scale(1); opacity: 1} 45% {transform: scale(0.1); opacity: 0.7} 80% {transform: scale(1); opacity: 1}", "pulse");
300
+ function PulseLoader(_a) {
301
+ var _b = _a.loading, loading = _b === void 0 ? true : _b, _c = _a.color, color = _c === void 0 ? "#000000" : _c, _d = _a.speedMultiplier, speedMultiplier = _d === void 0 ? 1 : _d, _e = _a.cssOverride, cssOverride = _e === void 0 ? {} : _e, _f = _a.size, size = _f === void 0 ? 15 : _f, _g = _a.margin, margin = _g === void 0 ? 2 : _g, additionalprops = __rest(_a, ["loading", "color", "speedMultiplier", "cssOverride", "size", "margin"]);
302
+ var wrapper = __assign({ display: "inherit" }, cssOverride);
303
+ var style = function (i) {
304
+ return {
305
+ backgroundColor: color,
306
+ width: cssValue(size),
307
+ height: cssValue(size),
308
+ margin: cssValue(margin),
309
+ borderRadius: "100%",
310
+ display: "inline-block",
311
+ animation: "".concat(pulse, " ").concat(0.75 / speedMultiplier, "s ").concat((i * 0.12) / speedMultiplier, "s infinite cubic-bezier(0.2, 0.68, 0.18, 1.08)"),
312
+ animationFillMode: "both",
313
+ };
314
+ };
315
+ if (!loading) {
316
+ return null;
317
+ }
318
+ return (React.createElement("span", __assign({ style: wrapper }, additionalprops),
319
+ React.createElement("span", { style: style(1) }),
320
+ React.createElement("span", { style: style(2) }),
321
+ React.createElement("span", { style: style(3) })));
322
+ }
323
+
324
+ const CLASS_PART_SEPARATOR = '-';
325
+ const createClassGroupUtils = config => {
326
+ const classMap = createClassMap(config);
327
+ const {
328
+ conflictingClassGroups,
329
+ conflictingClassGroupModifiers
330
+ } = config;
331
+ const getClassGroupId = className => {
332
+ const classParts = className.split(CLASS_PART_SEPARATOR);
333
+ // Classes like `-inset-1` produce an empty string as first classPart. We assume that classes for negative values are used correctly and remove it from classParts.
334
+ if (classParts[0] === '' && classParts.length !== 1) {
335
+ classParts.shift();
336
+ }
337
+ return getGroupRecursive(classParts, classMap) || getGroupIdForArbitraryProperty(className);
338
+ };
339
+ const getConflictingClassGroupIds = (classGroupId, hasPostfixModifier) => {
340
+ const conflicts = conflictingClassGroups[classGroupId] || [];
341
+ if (hasPostfixModifier && conflictingClassGroupModifiers[classGroupId]) {
342
+ return [...conflicts, ...conflictingClassGroupModifiers[classGroupId]];
343
+ }
344
+ return conflicts;
345
+ };
346
+ return {
347
+ getClassGroupId,
348
+ getConflictingClassGroupIds
349
+ };
350
+ };
351
+ const getGroupRecursive = (classParts, classPartObject) => {
352
+ if (classParts.length === 0) {
353
+ return classPartObject.classGroupId;
354
+ }
355
+ const currentClassPart = classParts[0];
356
+ const nextClassPartObject = classPartObject.nextPart.get(currentClassPart);
357
+ const classGroupFromNextClassPart = nextClassPartObject ? getGroupRecursive(classParts.slice(1), nextClassPartObject) : undefined;
358
+ if (classGroupFromNextClassPart) {
359
+ return classGroupFromNextClassPart;
360
+ }
361
+ if (classPartObject.validators.length === 0) {
362
+ return undefined;
363
+ }
364
+ const classRest = classParts.join(CLASS_PART_SEPARATOR);
365
+ return classPartObject.validators.find(({
366
+ validator
367
+ }) => validator(classRest))?.classGroupId;
368
+ };
369
+ const arbitraryPropertyRegex = /^\[(.+)\]$/;
370
+ const getGroupIdForArbitraryProperty = className => {
371
+ if (arbitraryPropertyRegex.test(className)) {
372
+ const arbitraryPropertyClassName = arbitraryPropertyRegex.exec(className)[1];
373
+ const property = arbitraryPropertyClassName?.substring(0, arbitraryPropertyClassName.indexOf(':'));
374
+ if (property) {
375
+ // I use two dots here because one dot is used as prefix for class groups in plugins
376
+ return 'arbitrary..' + property;
377
+ }
378
+ }
379
+ };
380
+ /**
381
+ * Exported for testing only
382
+ */
383
+ const createClassMap = config => {
384
+ const {
385
+ theme,
386
+ classGroups
387
+ } = config;
388
+ const classMap = {
389
+ nextPart: new Map(),
390
+ validators: []
391
+ };
392
+ for (const classGroupId in classGroups) {
393
+ processClassesRecursively(classGroups[classGroupId], classMap, classGroupId, theme);
394
+ }
395
+ return classMap;
11
396
  };
397
+ const processClassesRecursively = (classGroup, classPartObject, classGroupId, theme) => {
398
+ classGroup.forEach(classDefinition => {
399
+ if (typeof classDefinition === 'string') {
400
+ const classPartObjectToEdit = classDefinition === '' ? classPartObject : getPart(classPartObject, classDefinition);
401
+ classPartObjectToEdit.classGroupId = classGroupId;
402
+ return;
403
+ }
404
+ if (typeof classDefinition === 'function') {
405
+ if (isThemeGetter(classDefinition)) {
406
+ processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);
407
+ return;
408
+ }
409
+ classPartObject.validators.push({
410
+ validator: classDefinition,
411
+ classGroupId
412
+ });
413
+ return;
414
+ }
415
+ Object.entries(classDefinition).forEach(([key, classGroup]) => {
416
+ processClassesRecursively(classGroup, getPart(classPartObject, key), classGroupId, theme);
417
+ });
418
+ });
419
+ };
420
+ const getPart = (classPartObject, path) => {
421
+ let currentClassPartObject = classPartObject;
422
+ path.split(CLASS_PART_SEPARATOR).forEach(pathPart => {
423
+ if (!currentClassPartObject.nextPart.has(pathPart)) {
424
+ currentClassPartObject.nextPart.set(pathPart, {
425
+ nextPart: new Map(),
426
+ validators: []
427
+ });
428
+ }
429
+ currentClassPartObject = currentClassPartObject.nextPart.get(pathPart);
430
+ });
431
+ return currentClassPartObject;
432
+ };
433
+ const isThemeGetter = func => func.isThemeGetter;
434
+
435
+ // LRU cache inspired from hashlru (https://github.com/dominictarr/hashlru/blob/v1.0.4/index.js) but object replaced with Map to improve performance
436
+ const createLruCache = maxCacheSize => {
437
+ if (maxCacheSize < 1) {
438
+ return {
439
+ get: () => undefined,
440
+ set: () => {}
441
+ };
442
+ }
443
+ let cacheSize = 0;
444
+ let cache = new Map();
445
+ let previousCache = new Map();
446
+ const update = (key, value) => {
447
+ cache.set(key, value);
448
+ cacheSize++;
449
+ if (cacheSize > maxCacheSize) {
450
+ cacheSize = 0;
451
+ previousCache = cache;
452
+ cache = new Map();
453
+ }
454
+ };
455
+ return {
456
+ get(key) {
457
+ let value = cache.get(key);
458
+ if (value !== undefined) {
459
+ return value;
460
+ }
461
+ if ((value = previousCache.get(key)) !== undefined) {
462
+ update(key, value);
463
+ return value;
464
+ }
465
+ },
466
+ set(key, value) {
467
+ if (cache.has(key)) {
468
+ cache.set(key, value);
469
+ } else {
470
+ update(key, value);
471
+ }
472
+ }
473
+ };
474
+ };
475
+ const IMPORTANT_MODIFIER = '!';
476
+ const MODIFIER_SEPARATOR = ':';
477
+ const MODIFIER_SEPARATOR_LENGTH = MODIFIER_SEPARATOR.length;
478
+ const createParseClassName = config => {
479
+ const {
480
+ prefix,
481
+ experimentalParseClassName
482
+ } = config;
483
+ /**
484
+ * Parse class name into parts.
485
+ *
486
+ * Inspired by `splitAtTopLevelOnly` used in Tailwind CSS
487
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v3.2.2/src/util/splitAtTopLevelOnly.js
488
+ */
489
+ let parseClassName = className => {
490
+ const modifiers = [];
491
+ let bracketDepth = 0;
492
+ let parenDepth = 0;
493
+ let modifierStart = 0;
494
+ let postfixModifierPosition;
495
+ for (let index = 0; index < className.length; index++) {
496
+ let currentCharacter = className[index];
497
+ if (bracketDepth === 0 && parenDepth === 0) {
498
+ if (currentCharacter === MODIFIER_SEPARATOR) {
499
+ modifiers.push(className.slice(modifierStart, index));
500
+ modifierStart = index + MODIFIER_SEPARATOR_LENGTH;
501
+ continue;
502
+ }
503
+ if (currentCharacter === '/') {
504
+ postfixModifierPosition = index;
505
+ continue;
506
+ }
507
+ }
508
+ if (currentCharacter === '[') {
509
+ bracketDepth++;
510
+ } else if (currentCharacter === ']') {
511
+ bracketDepth--;
512
+ } else if (currentCharacter === '(') {
513
+ parenDepth++;
514
+ } else if (currentCharacter === ')') {
515
+ parenDepth--;
516
+ }
517
+ }
518
+ const baseClassNameWithImportantModifier = modifiers.length === 0 ? className : className.substring(modifierStart);
519
+ const baseClassName = stripImportantModifier(baseClassNameWithImportantModifier);
520
+ const hasImportantModifier = baseClassName !== baseClassNameWithImportantModifier;
521
+ const maybePostfixModifierPosition = postfixModifierPosition && postfixModifierPosition > modifierStart ? postfixModifierPosition - modifierStart : undefined;
522
+ return {
523
+ modifiers,
524
+ hasImportantModifier,
525
+ baseClassName,
526
+ maybePostfixModifierPosition
527
+ };
528
+ };
529
+ if (prefix) {
530
+ const fullPrefix = prefix + MODIFIER_SEPARATOR;
531
+ const parseClassNameOriginal = parseClassName;
532
+ parseClassName = className => className.startsWith(fullPrefix) ? parseClassNameOriginal(className.substring(fullPrefix.length)) : {
533
+ isExternal: true,
534
+ modifiers: [],
535
+ hasImportantModifier: false,
536
+ baseClassName: className,
537
+ maybePostfixModifierPosition: undefined
538
+ };
539
+ }
540
+ if (experimentalParseClassName) {
541
+ const parseClassNameOriginal = parseClassName;
542
+ parseClassName = className => experimentalParseClassName({
543
+ className,
544
+ parseClassName: parseClassNameOriginal
545
+ });
546
+ }
547
+ return parseClassName;
548
+ };
549
+ const stripImportantModifier = baseClassName => {
550
+ if (baseClassName.endsWith(IMPORTANT_MODIFIER)) {
551
+ return baseClassName.substring(0, baseClassName.length - 1);
552
+ }
553
+ /**
554
+ * In Tailwind CSS v3 the important modifier was at the start of the base class name. This is still supported for legacy reasons.
555
+ * @see https://github.com/dcastil/tailwind-merge/issues/513#issuecomment-2614029864
556
+ */
557
+ if (baseClassName.startsWith(IMPORTANT_MODIFIER)) {
558
+ return baseClassName.substring(1);
559
+ }
560
+ return baseClassName;
561
+ };
562
+
563
+ /**
564
+ * Sorts modifiers according to following schema:
565
+ * - Predefined modifiers are sorted alphabetically
566
+ * - When an arbitrary variant appears, it must be preserved which modifiers are before and after it
567
+ */
568
+ const createSortModifiers = config => {
569
+ const orderSensitiveModifiers = Object.fromEntries(config.orderSensitiveModifiers.map(modifier => [modifier, true]));
570
+ const sortModifiers = modifiers => {
571
+ if (modifiers.length <= 1) {
572
+ return modifiers;
573
+ }
574
+ const sortedModifiers = [];
575
+ let unsortedModifiers = [];
576
+ modifiers.forEach(modifier => {
577
+ const isPositionSensitive = modifier[0] === '[' || orderSensitiveModifiers[modifier];
578
+ if (isPositionSensitive) {
579
+ sortedModifiers.push(...unsortedModifiers.sort(), modifier);
580
+ unsortedModifiers = [];
581
+ } else {
582
+ unsortedModifiers.push(modifier);
583
+ }
584
+ });
585
+ sortedModifiers.push(...unsortedModifiers.sort());
586
+ return sortedModifiers;
587
+ };
588
+ return sortModifiers;
589
+ };
590
+ const createConfigUtils = config => ({
591
+ cache: createLruCache(config.cacheSize),
592
+ parseClassName: createParseClassName(config),
593
+ sortModifiers: createSortModifiers(config),
594
+ ...createClassGroupUtils(config)
595
+ });
596
+ const SPLIT_CLASSES_REGEX = /\s+/;
597
+ const mergeClassList = (classList, configUtils) => {
598
+ const {
599
+ parseClassName,
600
+ getClassGroupId,
601
+ getConflictingClassGroupIds,
602
+ sortModifiers
603
+ } = configUtils;
604
+ /**
605
+ * Set of classGroupIds in following format:
606
+ * `{importantModifier}{variantModifiers}{classGroupId}`
607
+ * @example 'float'
608
+ * @example 'hover:focus:bg-color'
609
+ * @example 'md:!pr'
610
+ */
611
+ const classGroupsInConflict = [];
612
+ const classNames = classList.trim().split(SPLIT_CLASSES_REGEX);
613
+ let result = '';
614
+ for (let index = classNames.length - 1; index >= 0; index -= 1) {
615
+ const originalClassName = classNames[index];
616
+ const {
617
+ isExternal,
618
+ modifiers,
619
+ hasImportantModifier,
620
+ baseClassName,
621
+ maybePostfixModifierPosition
622
+ } = parseClassName(originalClassName);
623
+ if (isExternal) {
624
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
625
+ continue;
626
+ }
627
+ let hasPostfixModifier = !!maybePostfixModifierPosition;
628
+ let classGroupId = getClassGroupId(hasPostfixModifier ? baseClassName.substring(0, maybePostfixModifierPosition) : baseClassName);
629
+ if (!classGroupId) {
630
+ if (!hasPostfixModifier) {
631
+ // Not a Tailwind class
632
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
633
+ continue;
634
+ }
635
+ classGroupId = getClassGroupId(baseClassName);
636
+ if (!classGroupId) {
637
+ // Not a Tailwind class
638
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
639
+ continue;
640
+ }
641
+ hasPostfixModifier = false;
642
+ }
643
+ const variantModifier = sortModifiers(modifiers).join(':');
644
+ const modifierId = hasImportantModifier ? variantModifier + IMPORTANT_MODIFIER : variantModifier;
645
+ const classId = modifierId + classGroupId;
646
+ if (classGroupsInConflict.includes(classId)) {
647
+ // Tailwind class omitted due to conflict
648
+ continue;
649
+ }
650
+ classGroupsInConflict.push(classId);
651
+ const conflictGroups = getConflictingClassGroupIds(classGroupId, hasPostfixModifier);
652
+ for (let i = 0; i < conflictGroups.length; ++i) {
653
+ const group = conflictGroups[i];
654
+ classGroupsInConflict.push(modifierId + group);
655
+ }
656
+ // Tailwind class not in conflict
657
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
658
+ }
659
+ return result;
660
+ };
661
+
662
+ /**
663
+ * The code in this file is copied from https://github.com/lukeed/clsx and modified to suit the needs of tailwind-merge better.
664
+ *
665
+ * Specifically:
666
+ * - Runtime code from https://github.com/lukeed/clsx/blob/v1.2.1/src/index.js
667
+ * - TypeScript types from https://github.com/lukeed/clsx/blob/v1.2.1/clsx.d.ts
668
+ *
669
+ * Original code has MIT license: Copyright (c) Luke Edwards <luke.edwards05@gmail.com> (lukeed.com)
670
+ */
671
+ function twJoin() {
672
+ let index = 0;
673
+ let argument;
674
+ let resolvedValue;
675
+ let string = '';
676
+ while (index < arguments.length) {
677
+ if (argument = arguments[index++]) {
678
+ if (resolvedValue = toValue(argument)) {
679
+ string && (string += ' ');
680
+ string += resolvedValue;
681
+ }
682
+ }
683
+ }
684
+ return string;
685
+ }
686
+ const toValue = mix => {
687
+ if (typeof mix === 'string') {
688
+ return mix;
689
+ }
690
+ let resolvedValue;
691
+ let string = '';
692
+ for (let k = 0; k < mix.length; k++) {
693
+ if (mix[k]) {
694
+ if (resolvedValue = toValue(mix[k])) {
695
+ string && (string += ' ');
696
+ string += resolvedValue;
697
+ }
698
+ }
699
+ }
700
+ return string;
701
+ };
702
+ function createTailwindMerge(createConfigFirst, ...createConfigRest) {
703
+ let configUtils;
704
+ let cacheGet;
705
+ let cacheSet;
706
+ let functionToCall = initTailwindMerge;
707
+ function initTailwindMerge(classList) {
708
+ const config = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());
709
+ configUtils = createConfigUtils(config);
710
+ cacheGet = configUtils.cache.get;
711
+ cacheSet = configUtils.cache.set;
712
+ functionToCall = tailwindMerge;
713
+ return tailwindMerge(classList);
714
+ }
715
+ function tailwindMerge(classList) {
716
+ const cachedResult = cacheGet(classList);
717
+ if (cachedResult) {
718
+ return cachedResult;
719
+ }
720
+ const result = mergeClassList(classList, configUtils);
721
+ cacheSet(classList, result);
722
+ return result;
723
+ }
724
+ return function callTailwindMerge() {
725
+ return functionToCall(twJoin.apply(null, arguments));
726
+ };
727
+ }
728
+ const fromTheme = key => {
729
+ const themeGetter = theme => theme[key] || [];
730
+ themeGetter.isThemeGetter = true;
731
+ return themeGetter;
732
+ };
733
+ const arbitraryValueRegex = /^\[(?:(\w[\w-]*):)?(.+)\]$/i;
734
+ const arbitraryVariableRegex = /^\((?:(\w[\w-]*):)?(.+)\)$/i;
735
+ const fractionRegex = /^\d+\/\d+$/;
736
+ const tshirtUnitRegex = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/;
737
+ const lengthUnitRegex = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/;
738
+ const colorFunctionRegex = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/;
739
+ // Shadow always begins with x and y offset separated by underscore optionally prepended by inset
740
+ const shadowRegex = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;
741
+ const imageRegex = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;
742
+ const isFraction = value => fractionRegex.test(value);
743
+ const isNumber = value => !!value && !Number.isNaN(Number(value));
744
+ const isInteger = value => !!value && Number.isInteger(Number(value));
745
+ const isPercent = value => value.endsWith('%') && isNumber(value.slice(0, -1));
746
+ const isTshirtSize = value => tshirtUnitRegex.test(value);
747
+ const isAny = () => true;
748
+ const isLengthOnly = value =>
749
+ // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
750
+ // For example, `hsl(0 0% 0%)` would be classified as a length without this check.
751
+ // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
752
+ lengthUnitRegex.test(value) && !colorFunctionRegex.test(value);
753
+ const isNever = () => false;
754
+ const isShadow = value => shadowRegex.test(value);
755
+ const isImage = value => imageRegex.test(value);
756
+ const isAnyNonArbitrary = value => !isArbitraryValue(value) && !isArbitraryVariable(value);
757
+ const isArbitrarySize = value => getIsArbitraryValue(value, isLabelSize, isNever);
758
+ const isArbitraryValue = value => arbitraryValueRegex.test(value);
759
+ const isArbitraryLength = value => getIsArbitraryValue(value, isLabelLength, isLengthOnly);
760
+ const isArbitraryNumber = value => getIsArbitraryValue(value, isLabelNumber, isNumber);
761
+ const isArbitraryPosition = value => getIsArbitraryValue(value, isLabelPosition, isNever);
762
+ const isArbitraryImage = value => getIsArbitraryValue(value, isLabelImage, isImage);
763
+ const isArbitraryShadow = value => getIsArbitraryValue(value, isLabelShadow, isShadow);
764
+ const isArbitraryVariable = value => arbitraryVariableRegex.test(value);
765
+ const isArbitraryVariableLength = value => getIsArbitraryVariable(value, isLabelLength);
766
+ const isArbitraryVariableFamilyName = value => getIsArbitraryVariable(value, isLabelFamilyName);
767
+ const isArbitraryVariablePosition = value => getIsArbitraryVariable(value, isLabelPosition);
768
+ const isArbitraryVariableSize = value => getIsArbitraryVariable(value, isLabelSize);
769
+ const isArbitraryVariableImage = value => getIsArbitraryVariable(value, isLabelImage);
770
+ const isArbitraryVariableShadow = value => getIsArbitraryVariable(value, isLabelShadow, true);
771
+ // Helpers
772
+ const getIsArbitraryValue = (value, testLabel, testValue) => {
773
+ const result = arbitraryValueRegex.exec(value);
774
+ if (result) {
775
+ if (result[1]) {
776
+ return testLabel(result[1]);
777
+ }
778
+ return testValue(result[2]);
779
+ }
780
+ return false;
781
+ };
782
+ const getIsArbitraryVariable = (value, testLabel, shouldMatchNoLabel = false) => {
783
+ const result = arbitraryVariableRegex.exec(value);
784
+ if (result) {
785
+ if (result[1]) {
786
+ return testLabel(result[1]);
787
+ }
788
+ return shouldMatchNoLabel;
789
+ }
790
+ return false;
791
+ };
792
+ // Labels
793
+ const isLabelPosition = label => label === 'position' || label === 'percentage';
794
+ const isLabelImage = label => label === 'image' || label === 'url';
795
+ const isLabelSize = label => label === 'length' || label === 'size' || label === 'bg-size';
796
+ const isLabelLength = label => label === 'length';
797
+ const isLabelNumber = label => label === 'number';
798
+ const isLabelFamilyName = label => label === 'family-name';
799
+ const isLabelShadow = label => label === 'shadow';
800
+ const getDefaultConfig = () => {
801
+ /**
802
+ * Theme getters for theme variable namespaces
803
+ * @see https://tailwindcss.com/docs/theme#theme-variable-namespaces
804
+ */
805
+ /***/
806
+ const themeColor = fromTheme('color');
807
+ const themeFont = fromTheme('font');
808
+ const themeText = fromTheme('text');
809
+ const themeFontWeight = fromTheme('font-weight');
810
+ const themeTracking = fromTheme('tracking');
811
+ const themeLeading = fromTheme('leading');
812
+ const themeBreakpoint = fromTheme('breakpoint');
813
+ const themeContainer = fromTheme('container');
814
+ const themeSpacing = fromTheme('spacing');
815
+ const themeRadius = fromTheme('radius');
816
+ const themeShadow = fromTheme('shadow');
817
+ const themeInsetShadow = fromTheme('inset-shadow');
818
+ const themeTextShadow = fromTheme('text-shadow');
819
+ const themeDropShadow = fromTheme('drop-shadow');
820
+ const themeBlur = fromTheme('blur');
821
+ const themePerspective = fromTheme('perspective');
822
+ const themeAspect = fromTheme('aspect');
823
+ const themeEase = fromTheme('ease');
824
+ const themeAnimate = fromTheme('animate');
825
+ /**
826
+ * Helpers to avoid repeating the same scales
827
+ *
828
+ * We use functions that create a new array every time they're called instead of static arrays.
829
+ * This ensures that users who modify any scale by mutating the array (e.g. with `array.push(element)`) don't accidentally mutate arrays in other parts of the config.
830
+ */
831
+ /***/
832
+ const scaleBreak = () => ['auto', 'avoid', 'all', 'avoid-page', 'page', 'left', 'right', 'column'];
833
+ const scalePosition = () => ['center', 'top', 'bottom', 'left', 'right', 'top-left',
834
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
835
+ 'left-top', 'top-right',
836
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
837
+ 'right-top', 'bottom-right',
838
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
839
+ 'right-bottom', 'bottom-left',
840
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
841
+ 'left-bottom'];
842
+ const scalePositionWithArbitrary = () => [...scalePosition(), isArbitraryVariable, isArbitraryValue];
843
+ const scaleOverflow = () => ['auto', 'hidden', 'clip', 'visible', 'scroll'];
844
+ const scaleOverscroll = () => ['auto', 'contain', 'none'];
845
+ const scaleUnambiguousSpacing = () => [isArbitraryVariable, isArbitraryValue, themeSpacing];
846
+ const scaleInset = () => [isFraction, 'full', 'auto', ...scaleUnambiguousSpacing()];
847
+ const scaleGridTemplateColsRows = () => [isInteger, 'none', 'subgrid', isArbitraryVariable, isArbitraryValue];
848
+ const scaleGridColRowStartAndEnd = () => ['auto', {
849
+ span: ['full', isInteger, isArbitraryVariable, isArbitraryValue]
850
+ }, isInteger, isArbitraryVariable, isArbitraryValue];
851
+ const scaleGridColRowStartOrEnd = () => [isInteger, 'auto', isArbitraryVariable, isArbitraryValue];
852
+ const scaleGridAutoColsRows = () => ['auto', 'min', 'max', 'fr', isArbitraryVariable, isArbitraryValue];
853
+ const scaleAlignPrimaryAxis = () => ['start', 'end', 'center', 'between', 'around', 'evenly', 'stretch', 'baseline', 'center-safe', 'end-safe'];
854
+ const scaleAlignSecondaryAxis = () => ['start', 'end', 'center', 'stretch', 'center-safe', 'end-safe'];
855
+ const scaleMargin = () => ['auto', ...scaleUnambiguousSpacing()];
856
+ const scaleSizing = () => [isFraction, 'auto', 'full', 'dvw', 'dvh', 'lvw', 'lvh', 'svw', 'svh', 'min', 'max', 'fit', ...scaleUnambiguousSpacing()];
857
+ const scaleColor = () => [themeColor, isArbitraryVariable, isArbitraryValue];
858
+ const scaleBgPosition = () => [...scalePosition(), isArbitraryVariablePosition, isArbitraryPosition, {
859
+ position: [isArbitraryVariable, isArbitraryValue]
860
+ }];
861
+ const scaleBgRepeat = () => ['no-repeat', {
862
+ repeat: ['', 'x', 'y', 'space', 'round']
863
+ }];
864
+ const scaleBgSize = () => ['auto', 'cover', 'contain', isArbitraryVariableSize, isArbitrarySize, {
865
+ size: [isArbitraryVariable, isArbitraryValue]
866
+ }];
867
+ const scaleGradientStopPosition = () => [isPercent, isArbitraryVariableLength, isArbitraryLength];
868
+ const scaleRadius = () => [
869
+ // Deprecated since Tailwind CSS v4.0.0
870
+ '', 'none', 'full', themeRadius, isArbitraryVariable, isArbitraryValue];
871
+ const scaleBorderWidth = () => ['', isNumber, isArbitraryVariableLength, isArbitraryLength];
872
+ const scaleLineStyle = () => ['solid', 'dashed', 'dotted', 'double'];
873
+ const scaleBlendMode = () => ['normal', 'multiply', 'screen', 'overlay', 'darken', 'lighten', 'color-dodge', 'color-burn', 'hard-light', 'soft-light', 'difference', 'exclusion', 'hue', 'saturation', 'color', 'luminosity'];
874
+ const scaleMaskImagePosition = () => [isNumber, isPercent, isArbitraryVariablePosition, isArbitraryPosition];
875
+ const scaleBlur = () => [
876
+ // Deprecated since Tailwind CSS v4.0.0
877
+ '', 'none', themeBlur, isArbitraryVariable, isArbitraryValue];
878
+ const scaleRotate = () => ['none', isNumber, isArbitraryVariable, isArbitraryValue];
879
+ const scaleScale = () => ['none', isNumber, isArbitraryVariable, isArbitraryValue];
880
+ const scaleSkew = () => [isNumber, isArbitraryVariable, isArbitraryValue];
881
+ const scaleTranslate = () => [isFraction, 'full', ...scaleUnambiguousSpacing()];
882
+ return {
883
+ cacheSize: 500,
884
+ theme: {
885
+ animate: ['spin', 'ping', 'pulse', 'bounce'],
886
+ aspect: ['video'],
887
+ blur: [isTshirtSize],
888
+ breakpoint: [isTshirtSize],
889
+ color: [isAny],
890
+ container: [isTshirtSize],
891
+ 'drop-shadow': [isTshirtSize],
892
+ ease: ['in', 'out', 'in-out'],
893
+ font: [isAnyNonArbitrary],
894
+ 'font-weight': ['thin', 'extralight', 'light', 'normal', 'medium', 'semibold', 'bold', 'extrabold', 'black'],
895
+ 'inset-shadow': [isTshirtSize],
896
+ leading: ['none', 'tight', 'snug', 'normal', 'relaxed', 'loose'],
897
+ perspective: ['dramatic', 'near', 'normal', 'midrange', 'distant', 'none'],
898
+ radius: [isTshirtSize],
899
+ shadow: [isTshirtSize],
900
+ spacing: ['px', isNumber],
901
+ text: [isTshirtSize],
902
+ 'text-shadow': [isTshirtSize],
903
+ tracking: ['tighter', 'tight', 'normal', 'wide', 'wider', 'widest']
904
+ },
905
+ classGroups: {
906
+ // --------------
907
+ // --- Layout ---
908
+ // --------------
909
+ /**
910
+ * Aspect Ratio
911
+ * @see https://tailwindcss.com/docs/aspect-ratio
912
+ */
913
+ aspect: [{
914
+ aspect: ['auto', 'square', isFraction, isArbitraryValue, isArbitraryVariable, themeAspect]
915
+ }],
916
+ /**
917
+ * Container
918
+ * @see https://tailwindcss.com/docs/container
919
+ * @deprecated since Tailwind CSS v4.0.0
920
+ */
921
+ container: ['container'],
922
+ /**
923
+ * Columns
924
+ * @see https://tailwindcss.com/docs/columns
925
+ */
926
+ columns: [{
927
+ columns: [isNumber, isArbitraryValue, isArbitraryVariable, themeContainer]
928
+ }],
929
+ /**
930
+ * Break After
931
+ * @see https://tailwindcss.com/docs/break-after
932
+ */
933
+ 'break-after': [{
934
+ 'break-after': scaleBreak()
935
+ }],
936
+ /**
937
+ * Break Before
938
+ * @see https://tailwindcss.com/docs/break-before
939
+ */
940
+ 'break-before': [{
941
+ 'break-before': scaleBreak()
942
+ }],
943
+ /**
944
+ * Break Inside
945
+ * @see https://tailwindcss.com/docs/break-inside
946
+ */
947
+ 'break-inside': [{
948
+ 'break-inside': ['auto', 'avoid', 'avoid-page', 'avoid-column']
949
+ }],
950
+ /**
951
+ * Box Decoration Break
952
+ * @see https://tailwindcss.com/docs/box-decoration-break
953
+ */
954
+ 'box-decoration': [{
955
+ 'box-decoration': ['slice', 'clone']
956
+ }],
957
+ /**
958
+ * Box Sizing
959
+ * @see https://tailwindcss.com/docs/box-sizing
960
+ */
961
+ box: [{
962
+ box: ['border', 'content']
963
+ }],
964
+ /**
965
+ * Display
966
+ * @see https://tailwindcss.com/docs/display
967
+ */
968
+ display: ['block', 'inline-block', 'inline', 'flex', 'inline-flex', 'table', 'inline-table', 'table-caption', 'table-cell', 'table-column', 'table-column-group', 'table-footer-group', 'table-header-group', 'table-row-group', 'table-row', 'flow-root', 'grid', 'inline-grid', 'contents', 'list-item', 'hidden'],
969
+ /**
970
+ * Screen Reader Only
971
+ * @see https://tailwindcss.com/docs/display#screen-reader-only
972
+ */
973
+ sr: ['sr-only', 'not-sr-only'],
974
+ /**
975
+ * Floats
976
+ * @see https://tailwindcss.com/docs/float
977
+ */
978
+ float: [{
979
+ float: ['right', 'left', 'none', 'start', 'end']
980
+ }],
981
+ /**
982
+ * Clear
983
+ * @see https://tailwindcss.com/docs/clear
984
+ */
985
+ clear: [{
986
+ clear: ['left', 'right', 'both', 'none', 'start', 'end']
987
+ }],
988
+ /**
989
+ * Isolation
990
+ * @see https://tailwindcss.com/docs/isolation
991
+ */
992
+ isolation: ['isolate', 'isolation-auto'],
993
+ /**
994
+ * Object Fit
995
+ * @see https://tailwindcss.com/docs/object-fit
996
+ */
997
+ 'object-fit': [{
998
+ object: ['contain', 'cover', 'fill', 'none', 'scale-down']
999
+ }],
1000
+ /**
1001
+ * Object Position
1002
+ * @see https://tailwindcss.com/docs/object-position
1003
+ */
1004
+ 'object-position': [{
1005
+ object: scalePositionWithArbitrary()
1006
+ }],
1007
+ /**
1008
+ * Overflow
1009
+ * @see https://tailwindcss.com/docs/overflow
1010
+ */
1011
+ overflow: [{
1012
+ overflow: scaleOverflow()
1013
+ }],
1014
+ /**
1015
+ * Overflow X
1016
+ * @see https://tailwindcss.com/docs/overflow
1017
+ */
1018
+ 'overflow-x': [{
1019
+ 'overflow-x': scaleOverflow()
1020
+ }],
1021
+ /**
1022
+ * Overflow Y
1023
+ * @see https://tailwindcss.com/docs/overflow
1024
+ */
1025
+ 'overflow-y': [{
1026
+ 'overflow-y': scaleOverflow()
1027
+ }],
1028
+ /**
1029
+ * Overscroll Behavior
1030
+ * @see https://tailwindcss.com/docs/overscroll-behavior
1031
+ */
1032
+ overscroll: [{
1033
+ overscroll: scaleOverscroll()
1034
+ }],
1035
+ /**
1036
+ * Overscroll Behavior X
1037
+ * @see https://tailwindcss.com/docs/overscroll-behavior
1038
+ */
1039
+ 'overscroll-x': [{
1040
+ 'overscroll-x': scaleOverscroll()
1041
+ }],
1042
+ /**
1043
+ * Overscroll Behavior Y
1044
+ * @see https://tailwindcss.com/docs/overscroll-behavior
1045
+ */
1046
+ 'overscroll-y': [{
1047
+ 'overscroll-y': scaleOverscroll()
1048
+ }],
1049
+ /**
1050
+ * Position
1051
+ * @see https://tailwindcss.com/docs/position
1052
+ */
1053
+ position: ['static', 'fixed', 'absolute', 'relative', 'sticky'],
1054
+ /**
1055
+ * Top / Right / Bottom / Left
1056
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1057
+ */
1058
+ inset: [{
1059
+ inset: scaleInset()
1060
+ }],
1061
+ /**
1062
+ * Right / Left
1063
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1064
+ */
1065
+ 'inset-x': [{
1066
+ 'inset-x': scaleInset()
1067
+ }],
1068
+ /**
1069
+ * Top / Bottom
1070
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1071
+ */
1072
+ 'inset-y': [{
1073
+ 'inset-y': scaleInset()
1074
+ }],
1075
+ /**
1076
+ * Start
1077
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1078
+ */
1079
+ start: [{
1080
+ start: scaleInset()
1081
+ }],
1082
+ /**
1083
+ * End
1084
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1085
+ */
1086
+ end: [{
1087
+ end: scaleInset()
1088
+ }],
1089
+ /**
1090
+ * Top
1091
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1092
+ */
1093
+ top: [{
1094
+ top: scaleInset()
1095
+ }],
1096
+ /**
1097
+ * Right
1098
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1099
+ */
1100
+ right: [{
1101
+ right: scaleInset()
1102
+ }],
1103
+ /**
1104
+ * Bottom
1105
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1106
+ */
1107
+ bottom: [{
1108
+ bottom: scaleInset()
1109
+ }],
1110
+ /**
1111
+ * Left
1112
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1113
+ */
1114
+ left: [{
1115
+ left: scaleInset()
1116
+ }],
1117
+ /**
1118
+ * Visibility
1119
+ * @see https://tailwindcss.com/docs/visibility
1120
+ */
1121
+ visibility: ['visible', 'invisible', 'collapse'],
1122
+ /**
1123
+ * Z-Index
1124
+ * @see https://tailwindcss.com/docs/z-index
1125
+ */
1126
+ z: [{
1127
+ z: [isInteger, 'auto', isArbitraryVariable, isArbitraryValue]
1128
+ }],
1129
+ // ------------------------
1130
+ // --- Flexbox and Grid ---
1131
+ // ------------------------
1132
+ /**
1133
+ * Flex Basis
1134
+ * @see https://tailwindcss.com/docs/flex-basis
1135
+ */
1136
+ basis: [{
1137
+ basis: [isFraction, 'full', 'auto', themeContainer, ...scaleUnambiguousSpacing()]
1138
+ }],
1139
+ /**
1140
+ * Flex Direction
1141
+ * @see https://tailwindcss.com/docs/flex-direction
1142
+ */
1143
+ 'flex-direction': [{
1144
+ flex: ['row', 'row-reverse', 'col', 'col-reverse']
1145
+ }],
1146
+ /**
1147
+ * Flex Wrap
1148
+ * @see https://tailwindcss.com/docs/flex-wrap
1149
+ */
1150
+ 'flex-wrap': [{
1151
+ flex: ['nowrap', 'wrap', 'wrap-reverse']
1152
+ }],
1153
+ /**
1154
+ * Flex
1155
+ * @see https://tailwindcss.com/docs/flex
1156
+ */
1157
+ flex: [{
1158
+ flex: [isNumber, isFraction, 'auto', 'initial', 'none', isArbitraryValue]
1159
+ }],
1160
+ /**
1161
+ * Flex Grow
1162
+ * @see https://tailwindcss.com/docs/flex-grow
1163
+ */
1164
+ grow: [{
1165
+ grow: ['', isNumber, isArbitraryVariable, isArbitraryValue]
1166
+ }],
1167
+ /**
1168
+ * Flex Shrink
1169
+ * @see https://tailwindcss.com/docs/flex-shrink
1170
+ */
1171
+ shrink: [{
1172
+ shrink: ['', isNumber, isArbitraryVariable, isArbitraryValue]
1173
+ }],
1174
+ /**
1175
+ * Order
1176
+ * @see https://tailwindcss.com/docs/order
1177
+ */
1178
+ order: [{
1179
+ order: [isInteger, 'first', 'last', 'none', isArbitraryVariable, isArbitraryValue]
1180
+ }],
1181
+ /**
1182
+ * Grid Template Columns
1183
+ * @see https://tailwindcss.com/docs/grid-template-columns
1184
+ */
1185
+ 'grid-cols': [{
1186
+ 'grid-cols': scaleGridTemplateColsRows()
1187
+ }],
1188
+ /**
1189
+ * Grid Column Start / End
1190
+ * @see https://tailwindcss.com/docs/grid-column
1191
+ */
1192
+ 'col-start-end': [{
1193
+ col: scaleGridColRowStartAndEnd()
1194
+ }],
1195
+ /**
1196
+ * Grid Column Start
1197
+ * @see https://tailwindcss.com/docs/grid-column
1198
+ */
1199
+ 'col-start': [{
1200
+ 'col-start': scaleGridColRowStartOrEnd()
1201
+ }],
1202
+ /**
1203
+ * Grid Column End
1204
+ * @see https://tailwindcss.com/docs/grid-column
1205
+ */
1206
+ 'col-end': [{
1207
+ 'col-end': scaleGridColRowStartOrEnd()
1208
+ }],
1209
+ /**
1210
+ * Grid Template Rows
1211
+ * @see https://tailwindcss.com/docs/grid-template-rows
1212
+ */
1213
+ 'grid-rows': [{
1214
+ 'grid-rows': scaleGridTemplateColsRows()
1215
+ }],
1216
+ /**
1217
+ * Grid Row Start / End
1218
+ * @see https://tailwindcss.com/docs/grid-row
1219
+ */
1220
+ 'row-start-end': [{
1221
+ row: scaleGridColRowStartAndEnd()
1222
+ }],
1223
+ /**
1224
+ * Grid Row Start
1225
+ * @see https://tailwindcss.com/docs/grid-row
1226
+ */
1227
+ 'row-start': [{
1228
+ 'row-start': scaleGridColRowStartOrEnd()
1229
+ }],
1230
+ /**
1231
+ * Grid Row End
1232
+ * @see https://tailwindcss.com/docs/grid-row
1233
+ */
1234
+ 'row-end': [{
1235
+ 'row-end': scaleGridColRowStartOrEnd()
1236
+ }],
1237
+ /**
1238
+ * Grid Auto Flow
1239
+ * @see https://tailwindcss.com/docs/grid-auto-flow
1240
+ */
1241
+ 'grid-flow': [{
1242
+ 'grid-flow': ['row', 'col', 'dense', 'row-dense', 'col-dense']
1243
+ }],
1244
+ /**
1245
+ * Grid Auto Columns
1246
+ * @see https://tailwindcss.com/docs/grid-auto-columns
1247
+ */
1248
+ 'auto-cols': [{
1249
+ 'auto-cols': scaleGridAutoColsRows()
1250
+ }],
1251
+ /**
1252
+ * Grid Auto Rows
1253
+ * @see https://tailwindcss.com/docs/grid-auto-rows
1254
+ */
1255
+ 'auto-rows': [{
1256
+ 'auto-rows': scaleGridAutoColsRows()
1257
+ }],
1258
+ /**
1259
+ * Gap
1260
+ * @see https://tailwindcss.com/docs/gap
1261
+ */
1262
+ gap: [{
1263
+ gap: scaleUnambiguousSpacing()
1264
+ }],
1265
+ /**
1266
+ * Gap X
1267
+ * @see https://tailwindcss.com/docs/gap
1268
+ */
1269
+ 'gap-x': [{
1270
+ 'gap-x': scaleUnambiguousSpacing()
1271
+ }],
1272
+ /**
1273
+ * Gap Y
1274
+ * @see https://tailwindcss.com/docs/gap
1275
+ */
1276
+ 'gap-y': [{
1277
+ 'gap-y': scaleUnambiguousSpacing()
1278
+ }],
1279
+ /**
1280
+ * Justify Content
1281
+ * @see https://tailwindcss.com/docs/justify-content
1282
+ */
1283
+ 'justify-content': [{
1284
+ justify: [...scaleAlignPrimaryAxis(), 'normal']
1285
+ }],
1286
+ /**
1287
+ * Justify Items
1288
+ * @see https://tailwindcss.com/docs/justify-items
1289
+ */
1290
+ 'justify-items': [{
1291
+ 'justify-items': [...scaleAlignSecondaryAxis(), 'normal']
1292
+ }],
1293
+ /**
1294
+ * Justify Self
1295
+ * @see https://tailwindcss.com/docs/justify-self
1296
+ */
1297
+ 'justify-self': [{
1298
+ 'justify-self': ['auto', ...scaleAlignSecondaryAxis()]
1299
+ }],
1300
+ /**
1301
+ * Align Content
1302
+ * @see https://tailwindcss.com/docs/align-content
1303
+ */
1304
+ 'align-content': [{
1305
+ content: ['normal', ...scaleAlignPrimaryAxis()]
1306
+ }],
1307
+ /**
1308
+ * Align Items
1309
+ * @see https://tailwindcss.com/docs/align-items
1310
+ */
1311
+ 'align-items': [{
1312
+ items: [...scaleAlignSecondaryAxis(), {
1313
+ baseline: ['', 'last']
1314
+ }]
1315
+ }],
1316
+ /**
1317
+ * Align Self
1318
+ * @see https://tailwindcss.com/docs/align-self
1319
+ */
1320
+ 'align-self': [{
1321
+ self: ['auto', ...scaleAlignSecondaryAxis(), {
1322
+ baseline: ['', 'last']
1323
+ }]
1324
+ }],
1325
+ /**
1326
+ * Place Content
1327
+ * @see https://tailwindcss.com/docs/place-content
1328
+ */
1329
+ 'place-content': [{
1330
+ 'place-content': scaleAlignPrimaryAxis()
1331
+ }],
1332
+ /**
1333
+ * Place Items
1334
+ * @see https://tailwindcss.com/docs/place-items
1335
+ */
1336
+ 'place-items': [{
1337
+ 'place-items': [...scaleAlignSecondaryAxis(), 'baseline']
1338
+ }],
1339
+ /**
1340
+ * Place Self
1341
+ * @see https://tailwindcss.com/docs/place-self
1342
+ */
1343
+ 'place-self': [{
1344
+ 'place-self': ['auto', ...scaleAlignSecondaryAxis()]
1345
+ }],
1346
+ // Spacing
1347
+ /**
1348
+ * Padding
1349
+ * @see https://tailwindcss.com/docs/padding
1350
+ */
1351
+ p: [{
1352
+ p: scaleUnambiguousSpacing()
1353
+ }],
1354
+ /**
1355
+ * Padding X
1356
+ * @see https://tailwindcss.com/docs/padding
1357
+ */
1358
+ px: [{
1359
+ px: scaleUnambiguousSpacing()
1360
+ }],
1361
+ /**
1362
+ * Padding Y
1363
+ * @see https://tailwindcss.com/docs/padding
1364
+ */
1365
+ py: [{
1366
+ py: scaleUnambiguousSpacing()
1367
+ }],
1368
+ /**
1369
+ * Padding Start
1370
+ * @see https://tailwindcss.com/docs/padding
1371
+ */
1372
+ ps: [{
1373
+ ps: scaleUnambiguousSpacing()
1374
+ }],
1375
+ /**
1376
+ * Padding End
1377
+ * @see https://tailwindcss.com/docs/padding
1378
+ */
1379
+ pe: [{
1380
+ pe: scaleUnambiguousSpacing()
1381
+ }],
1382
+ /**
1383
+ * Padding Top
1384
+ * @see https://tailwindcss.com/docs/padding
1385
+ */
1386
+ pt: [{
1387
+ pt: scaleUnambiguousSpacing()
1388
+ }],
1389
+ /**
1390
+ * Padding Right
1391
+ * @see https://tailwindcss.com/docs/padding
1392
+ */
1393
+ pr: [{
1394
+ pr: scaleUnambiguousSpacing()
1395
+ }],
1396
+ /**
1397
+ * Padding Bottom
1398
+ * @see https://tailwindcss.com/docs/padding
1399
+ */
1400
+ pb: [{
1401
+ pb: scaleUnambiguousSpacing()
1402
+ }],
1403
+ /**
1404
+ * Padding Left
1405
+ * @see https://tailwindcss.com/docs/padding
1406
+ */
1407
+ pl: [{
1408
+ pl: scaleUnambiguousSpacing()
1409
+ }],
1410
+ /**
1411
+ * Margin
1412
+ * @see https://tailwindcss.com/docs/margin
1413
+ */
1414
+ m: [{
1415
+ m: scaleMargin()
1416
+ }],
1417
+ /**
1418
+ * Margin X
1419
+ * @see https://tailwindcss.com/docs/margin
1420
+ */
1421
+ mx: [{
1422
+ mx: scaleMargin()
1423
+ }],
1424
+ /**
1425
+ * Margin Y
1426
+ * @see https://tailwindcss.com/docs/margin
1427
+ */
1428
+ my: [{
1429
+ my: scaleMargin()
1430
+ }],
1431
+ /**
1432
+ * Margin Start
1433
+ * @see https://tailwindcss.com/docs/margin
1434
+ */
1435
+ ms: [{
1436
+ ms: scaleMargin()
1437
+ }],
1438
+ /**
1439
+ * Margin End
1440
+ * @see https://tailwindcss.com/docs/margin
1441
+ */
1442
+ me: [{
1443
+ me: scaleMargin()
1444
+ }],
1445
+ /**
1446
+ * Margin Top
1447
+ * @see https://tailwindcss.com/docs/margin
1448
+ */
1449
+ mt: [{
1450
+ mt: scaleMargin()
1451
+ }],
1452
+ /**
1453
+ * Margin Right
1454
+ * @see https://tailwindcss.com/docs/margin
1455
+ */
1456
+ mr: [{
1457
+ mr: scaleMargin()
1458
+ }],
1459
+ /**
1460
+ * Margin Bottom
1461
+ * @see https://tailwindcss.com/docs/margin
1462
+ */
1463
+ mb: [{
1464
+ mb: scaleMargin()
1465
+ }],
1466
+ /**
1467
+ * Margin Left
1468
+ * @see https://tailwindcss.com/docs/margin
1469
+ */
1470
+ ml: [{
1471
+ ml: scaleMargin()
1472
+ }],
1473
+ /**
1474
+ * Space Between X
1475
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1476
+ */
1477
+ 'space-x': [{
1478
+ 'space-x': scaleUnambiguousSpacing()
1479
+ }],
1480
+ /**
1481
+ * Space Between X Reverse
1482
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1483
+ */
1484
+ 'space-x-reverse': ['space-x-reverse'],
1485
+ /**
1486
+ * Space Between Y
1487
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1488
+ */
1489
+ 'space-y': [{
1490
+ 'space-y': scaleUnambiguousSpacing()
1491
+ }],
1492
+ /**
1493
+ * Space Between Y Reverse
1494
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1495
+ */
1496
+ 'space-y-reverse': ['space-y-reverse'],
1497
+ // --------------
1498
+ // --- Sizing ---
1499
+ // --------------
1500
+ /**
1501
+ * Size
1502
+ * @see https://tailwindcss.com/docs/width#setting-both-width-and-height
1503
+ */
1504
+ size: [{
1505
+ size: scaleSizing()
1506
+ }],
1507
+ /**
1508
+ * Width
1509
+ * @see https://tailwindcss.com/docs/width
1510
+ */
1511
+ w: [{
1512
+ w: [themeContainer, 'screen', ...scaleSizing()]
1513
+ }],
1514
+ /**
1515
+ * Min-Width
1516
+ * @see https://tailwindcss.com/docs/min-width
1517
+ */
1518
+ 'min-w': [{
1519
+ 'min-w': [themeContainer, 'screen', /** Deprecated. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1520
+ 'none', ...scaleSizing()]
1521
+ }],
1522
+ /**
1523
+ * Max-Width
1524
+ * @see https://tailwindcss.com/docs/max-width
1525
+ */
1526
+ 'max-w': [{
1527
+ 'max-w': [themeContainer, 'screen', 'none', /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1528
+ 'prose', /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1529
+ {
1530
+ screen: [themeBreakpoint]
1531
+ }, ...scaleSizing()]
1532
+ }],
1533
+ /**
1534
+ * Height
1535
+ * @see https://tailwindcss.com/docs/height
1536
+ */
1537
+ h: [{
1538
+ h: ['screen', 'lh', ...scaleSizing()]
1539
+ }],
1540
+ /**
1541
+ * Min-Height
1542
+ * @see https://tailwindcss.com/docs/min-height
1543
+ */
1544
+ 'min-h': [{
1545
+ 'min-h': ['screen', 'lh', 'none', ...scaleSizing()]
1546
+ }],
1547
+ /**
1548
+ * Max-Height
1549
+ * @see https://tailwindcss.com/docs/max-height
1550
+ */
1551
+ 'max-h': [{
1552
+ 'max-h': ['screen', 'lh', ...scaleSizing()]
1553
+ }],
1554
+ // ------------------
1555
+ // --- Typography ---
1556
+ // ------------------
1557
+ /**
1558
+ * Font Size
1559
+ * @see https://tailwindcss.com/docs/font-size
1560
+ */
1561
+ 'font-size': [{
1562
+ text: ['base', themeText, isArbitraryVariableLength, isArbitraryLength]
1563
+ }],
1564
+ /**
1565
+ * Font Smoothing
1566
+ * @see https://tailwindcss.com/docs/font-smoothing
1567
+ */
1568
+ 'font-smoothing': ['antialiased', 'subpixel-antialiased'],
1569
+ /**
1570
+ * Font Style
1571
+ * @see https://tailwindcss.com/docs/font-style
1572
+ */
1573
+ 'font-style': ['italic', 'not-italic'],
1574
+ /**
1575
+ * Font Weight
1576
+ * @see https://tailwindcss.com/docs/font-weight
1577
+ */
1578
+ 'font-weight': [{
1579
+ font: [themeFontWeight, isArbitraryVariable, isArbitraryNumber]
1580
+ }],
1581
+ /**
1582
+ * Font Stretch
1583
+ * @see https://tailwindcss.com/docs/font-stretch
1584
+ */
1585
+ 'font-stretch': [{
1586
+ 'font-stretch': ['ultra-condensed', 'extra-condensed', 'condensed', 'semi-condensed', 'normal', 'semi-expanded', 'expanded', 'extra-expanded', 'ultra-expanded', isPercent, isArbitraryValue]
1587
+ }],
1588
+ /**
1589
+ * Font Family
1590
+ * @see https://tailwindcss.com/docs/font-family
1591
+ */
1592
+ 'font-family': [{
1593
+ font: [isArbitraryVariableFamilyName, isArbitraryValue, themeFont]
1594
+ }],
1595
+ /**
1596
+ * Font Variant Numeric
1597
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1598
+ */
1599
+ 'fvn-normal': ['normal-nums'],
1600
+ /**
1601
+ * Font Variant Numeric
1602
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1603
+ */
1604
+ 'fvn-ordinal': ['ordinal'],
1605
+ /**
1606
+ * Font Variant Numeric
1607
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1608
+ */
1609
+ 'fvn-slashed-zero': ['slashed-zero'],
1610
+ /**
1611
+ * Font Variant Numeric
1612
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1613
+ */
1614
+ 'fvn-figure': ['lining-nums', 'oldstyle-nums'],
1615
+ /**
1616
+ * Font Variant Numeric
1617
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1618
+ */
1619
+ 'fvn-spacing': ['proportional-nums', 'tabular-nums'],
1620
+ /**
1621
+ * Font Variant Numeric
1622
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1623
+ */
1624
+ 'fvn-fraction': ['diagonal-fractions', 'stacked-fractions'],
1625
+ /**
1626
+ * Letter Spacing
1627
+ * @see https://tailwindcss.com/docs/letter-spacing
1628
+ */
1629
+ tracking: [{
1630
+ tracking: [themeTracking, isArbitraryVariable, isArbitraryValue]
1631
+ }],
1632
+ /**
1633
+ * Line Clamp
1634
+ * @see https://tailwindcss.com/docs/line-clamp
1635
+ */
1636
+ 'line-clamp': [{
1637
+ 'line-clamp': [isNumber, 'none', isArbitraryVariable, isArbitraryNumber]
1638
+ }],
1639
+ /**
1640
+ * Line Height
1641
+ * @see https://tailwindcss.com/docs/line-height
1642
+ */
1643
+ leading: [{
1644
+ leading: [/** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1645
+ themeLeading, ...scaleUnambiguousSpacing()]
1646
+ }],
1647
+ /**
1648
+ * List Style Image
1649
+ * @see https://tailwindcss.com/docs/list-style-image
1650
+ */
1651
+ 'list-image': [{
1652
+ 'list-image': ['none', isArbitraryVariable, isArbitraryValue]
1653
+ }],
1654
+ /**
1655
+ * List Style Position
1656
+ * @see https://tailwindcss.com/docs/list-style-position
1657
+ */
1658
+ 'list-style-position': [{
1659
+ list: ['inside', 'outside']
1660
+ }],
1661
+ /**
1662
+ * List Style Type
1663
+ * @see https://tailwindcss.com/docs/list-style-type
1664
+ */
1665
+ 'list-style-type': [{
1666
+ list: ['disc', 'decimal', 'none', isArbitraryVariable, isArbitraryValue]
1667
+ }],
1668
+ /**
1669
+ * Text Alignment
1670
+ * @see https://tailwindcss.com/docs/text-align
1671
+ */
1672
+ 'text-alignment': [{
1673
+ text: ['left', 'center', 'right', 'justify', 'start', 'end']
1674
+ }],
1675
+ /**
1676
+ * Placeholder Color
1677
+ * @deprecated since Tailwind CSS v3.0.0
1678
+ * @see https://v3.tailwindcss.com/docs/placeholder-color
1679
+ */
1680
+ 'placeholder-color': [{
1681
+ placeholder: scaleColor()
1682
+ }],
1683
+ /**
1684
+ * Text Color
1685
+ * @see https://tailwindcss.com/docs/text-color
1686
+ */
1687
+ 'text-color': [{
1688
+ text: scaleColor()
1689
+ }],
1690
+ /**
1691
+ * Text Decoration
1692
+ * @see https://tailwindcss.com/docs/text-decoration
1693
+ */
1694
+ 'text-decoration': ['underline', 'overline', 'line-through', 'no-underline'],
1695
+ /**
1696
+ * Text Decoration Style
1697
+ * @see https://tailwindcss.com/docs/text-decoration-style
1698
+ */
1699
+ 'text-decoration-style': [{
1700
+ decoration: [...scaleLineStyle(), 'wavy']
1701
+ }],
1702
+ /**
1703
+ * Text Decoration Thickness
1704
+ * @see https://tailwindcss.com/docs/text-decoration-thickness
1705
+ */
1706
+ 'text-decoration-thickness': [{
1707
+ decoration: [isNumber, 'from-font', 'auto', isArbitraryVariable, isArbitraryLength]
1708
+ }],
1709
+ /**
1710
+ * Text Decoration Color
1711
+ * @see https://tailwindcss.com/docs/text-decoration-color
1712
+ */
1713
+ 'text-decoration-color': [{
1714
+ decoration: scaleColor()
1715
+ }],
1716
+ /**
1717
+ * Text Underline Offset
1718
+ * @see https://tailwindcss.com/docs/text-underline-offset
1719
+ */
1720
+ 'underline-offset': [{
1721
+ 'underline-offset': [isNumber, 'auto', isArbitraryVariable, isArbitraryValue]
1722
+ }],
1723
+ /**
1724
+ * Text Transform
1725
+ * @see https://tailwindcss.com/docs/text-transform
1726
+ */
1727
+ 'text-transform': ['uppercase', 'lowercase', 'capitalize', 'normal-case'],
1728
+ /**
1729
+ * Text Overflow
1730
+ * @see https://tailwindcss.com/docs/text-overflow
1731
+ */
1732
+ 'text-overflow': ['truncate', 'text-ellipsis', 'text-clip'],
1733
+ /**
1734
+ * Text Wrap
1735
+ * @see https://tailwindcss.com/docs/text-wrap
1736
+ */
1737
+ 'text-wrap': [{
1738
+ text: ['wrap', 'nowrap', 'balance', 'pretty']
1739
+ }],
1740
+ /**
1741
+ * Text Indent
1742
+ * @see https://tailwindcss.com/docs/text-indent
1743
+ */
1744
+ indent: [{
1745
+ indent: scaleUnambiguousSpacing()
1746
+ }],
1747
+ /**
1748
+ * Vertical Alignment
1749
+ * @see https://tailwindcss.com/docs/vertical-align
1750
+ */
1751
+ 'vertical-align': [{
1752
+ align: ['baseline', 'top', 'middle', 'bottom', 'text-top', 'text-bottom', 'sub', 'super', isArbitraryVariable, isArbitraryValue]
1753
+ }],
1754
+ /**
1755
+ * Whitespace
1756
+ * @see https://tailwindcss.com/docs/whitespace
1757
+ */
1758
+ whitespace: [{
1759
+ whitespace: ['normal', 'nowrap', 'pre', 'pre-line', 'pre-wrap', 'break-spaces']
1760
+ }],
1761
+ /**
1762
+ * Word Break
1763
+ * @see https://tailwindcss.com/docs/word-break
1764
+ */
1765
+ break: [{
1766
+ break: ['normal', 'words', 'all', 'keep']
1767
+ }],
1768
+ /**
1769
+ * Overflow Wrap
1770
+ * @see https://tailwindcss.com/docs/overflow-wrap
1771
+ */
1772
+ wrap: [{
1773
+ wrap: ['break-word', 'anywhere', 'normal']
1774
+ }],
1775
+ /**
1776
+ * Hyphens
1777
+ * @see https://tailwindcss.com/docs/hyphens
1778
+ */
1779
+ hyphens: [{
1780
+ hyphens: ['none', 'manual', 'auto']
1781
+ }],
1782
+ /**
1783
+ * Content
1784
+ * @see https://tailwindcss.com/docs/content
1785
+ */
1786
+ content: [{
1787
+ content: ['none', isArbitraryVariable, isArbitraryValue]
1788
+ }],
1789
+ // -------------------
1790
+ // --- Backgrounds ---
1791
+ // -------------------
1792
+ /**
1793
+ * Background Attachment
1794
+ * @see https://tailwindcss.com/docs/background-attachment
1795
+ */
1796
+ 'bg-attachment': [{
1797
+ bg: ['fixed', 'local', 'scroll']
1798
+ }],
1799
+ /**
1800
+ * Background Clip
1801
+ * @see https://tailwindcss.com/docs/background-clip
1802
+ */
1803
+ 'bg-clip': [{
1804
+ 'bg-clip': ['border', 'padding', 'content', 'text']
1805
+ }],
1806
+ /**
1807
+ * Background Origin
1808
+ * @see https://tailwindcss.com/docs/background-origin
1809
+ */
1810
+ 'bg-origin': [{
1811
+ 'bg-origin': ['border', 'padding', 'content']
1812
+ }],
1813
+ /**
1814
+ * Background Position
1815
+ * @see https://tailwindcss.com/docs/background-position
1816
+ */
1817
+ 'bg-position': [{
1818
+ bg: scaleBgPosition()
1819
+ }],
1820
+ /**
1821
+ * Background Repeat
1822
+ * @see https://tailwindcss.com/docs/background-repeat
1823
+ */
1824
+ 'bg-repeat': [{
1825
+ bg: scaleBgRepeat()
1826
+ }],
1827
+ /**
1828
+ * Background Size
1829
+ * @see https://tailwindcss.com/docs/background-size
1830
+ */
1831
+ 'bg-size': [{
1832
+ bg: scaleBgSize()
1833
+ }],
1834
+ /**
1835
+ * Background Image
1836
+ * @see https://tailwindcss.com/docs/background-image
1837
+ */
1838
+ 'bg-image': [{
1839
+ bg: ['none', {
1840
+ linear: [{
1841
+ to: ['t', 'tr', 'r', 'br', 'b', 'bl', 'l', 'tl']
1842
+ }, isInteger, isArbitraryVariable, isArbitraryValue],
1843
+ radial: ['', isArbitraryVariable, isArbitraryValue],
1844
+ conic: [isInteger, isArbitraryVariable, isArbitraryValue]
1845
+ }, isArbitraryVariableImage, isArbitraryImage]
1846
+ }],
1847
+ /**
1848
+ * Background Color
1849
+ * @see https://tailwindcss.com/docs/background-color
1850
+ */
1851
+ 'bg-color': [{
1852
+ bg: scaleColor()
1853
+ }],
1854
+ /**
1855
+ * Gradient Color Stops From Position
1856
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1857
+ */
1858
+ 'gradient-from-pos': [{
1859
+ from: scaleGradientStopPosition()
1860
+ }],
1861
+ /**
1862
+ * Gradient Color Stops Via Position
1863
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1864
+ */
1865
+ 'gradient-via-pos': [{
1866
+ via: scaleGradientStopPosition()
1867
+ }],
1868
+ /**
1869
+ * Gradient Color Stops To Position
1870
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1871
+ */
1872
+ 'gradient-to-pos': [{
1873
+ to: scaleGradientStopPosition()
1874
+ }],
1875
+ /**
1876
+ * Gradient Color Stops From
1877
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1878
+ */
1879
+ 'gradient-from': [{
1880
+ from: scaleColor()
1881
+ }],
1882
+ /**
1883
+ * Gradient Color Stops Via
1884
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1885
+ */
1886
+ 'gradient-via': [{
1887
+ via: scaleColor()
1888
+ }],
1889
+ /**
1890
+ * Gradient Color Stops To
1891
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1892
+ */
1893
+ 'gradient-to': [{
1894
+ to: scaleColor()
1895
+ }],
1896
+ // ---------------
1897
+ // --- Borders ---
1898
+ // ---------------
1899
+ /**
1900
+ * Border Radius
1901
+ * @see https://tailwindcss.com/docs/border-radius
1902
+ */
1903
+ rounded: [{
1904
+ rounded: scaleRadius()
1905
+ }],
1906
+ /**
1907
+ * Border Radius Start
1908
+ * @see https://tailwindcss.com/docs/border-radius
1909
+ */
1910
+ 'rounded-s': [{
1911
+ 'rounded-s': scaleRadius()
1912
+ }],
1913
+ /**
1914
+ * Border Radius End
1915
+ * @see https://tailwindcss.com/docs/border-radius
1916
+ */
1917
+ 'rounded-e': [{
1918
+ 'rounded-e': scaleRadius()
1919
+ }],
1920
+ /**
1921
+ * Border Radius Top
1922
+ * @see https://tailwindcss.com/docs/border-radius
1923
+ */
1924
+ 'rounded-t': [{
1925
+ 'rounded-t': scaleRadius()
1926
+ }],
1927
+ /**
1928
+ * Border Radius Right
1929
+ * @see https://tailwindcss.com/docs/border-radius
1930
+ */
1931
+ 'rounded-r': [{
1932
+ 'rounded-r': scaleRadius()
1933
+ }],
1934
+ /**
1935
+ * Border Radius Bottom
1936
+ * @see https://tailwindcss.com/docs/border-radius
1937
+ */
1938
+ 'rounded-b': [{
1939
+ 'rounded-b': scaleRadius()
1940
+ }],
1941
+ /**
1942
+ * Border Radius Left
1943
+ * @see https://tailwindcss.com/docs/border-radius
1944
+ */
1945
+ 'rounded-l': [{
1946
+ 'rounded-l': scaleRadius()
1947
+ }],
1948
+ /**
1949
+ * Border Radius Start Start
1950
+ * @see https://tailwindcss.com/docs/border-radius
1951
+ */
1952
+ 'rounded-ss': [{
1953
+ 'rounded-ss': scaleRadius()
1954
+ }],
1955
+ /**
1956
+ * Border Radius Start End
1957
+ * @see https://tailwindcss.com/docs/border-radius
1958
+ */
1959
+ 'rounded-se': [{
1960
+ 'rounded-se': scaleRadius()
1961
+ }],
1962
+ /**
1963
+ * Border Radius End End
1964
+ * @see https://tailwindcss.com/docs/border-radius
1965
+ */
1966
+ 'rounded-ee': [{
1967
+ 'rounded-ee': scaleRadius()
1968
+ }],
1969
+ /**
1970
+ * Border Radius End Start
1971
+ * @see https://tailwindcss.com/docs/border-radius
1972
+ */
1973
+ 'rounded-es': [{
1974
+ 'rounded-es': scaleRadius()
1975
+ }],
1976
+ /**
1977
+ * Border Radius Top Left
1978
+ * @see https://tailwindcss.com/docs/border-radius
1979
+ */
1980
+ 'rounded-tl': [{
1981
+ 'rounded-tl': scaleRadius()
1982
+ }],
1983
+ /**
1984
+ * Border Radius Top Right
1985
+ * @see https://tailwindcss.com/docs/border-radius
1986
+ */
1987
+ 'rounded-tr': [{
1988
+ 'rounded-tr': scaleRadius()
1989
+ }],
1990
+ /**
1991
+ * Border Radius Bottom Right
1992
+ * @see https://tailwindcss.com/docs/border-radius
1993
+ */
1994
+ 'rounded-br': [{
1995
+ 'rounded-br': scaleRadius()
1996
+ }],
1997
+ /**
1998
+ * Border Radius Bottom Left
1999
+ * @see https://tailwindcss.com/docs/border-radius
2000
+ */
2001
+ 'rounded-bl': [{
2002
+ 'rounded-bl': scaleRadius()
2003
+ }],
2004
+ /**
2005
+ * Border Width
2006
+ * @see https://tailwindcss.com/docs/border-width
2007
+ */
2008
+ 'border-w': [{
2009
+ border: scaleBorderWidth()
2010
+ }],
2011
+ /**
2012
+ * Border Width X
2013
+ * @see https://tailwindcss.com/docs/border-width
2014
+ */
2015
+ 'border-w-x': [{
2016
+ 'border-x': scaleBorderWidth()
2017
+ }],
2018
+ /**
2019
+ * Border Width Y
2020
+ * @see https://tailwindcss.com/docs/border-width
2021
+ */
2022
+ 'border-w-y': [{
2023
+ 'border-y': scaleBorderWidth()
2024
+ }],
2025
+ /**
2026
+ * Border Width Start
2027
+ * @see https://tailwindcss.com/docs/border-width
2028
+ */
2029
+ 'border-w-s': [{
2030
+ 'border-s': scaleBorderWidth()
2031
+ }],
2032
+ /**
2033
+ * Border Width End
2034
+ * @see https://tailwindcss.com/docs/border-width
2035
+ */
2036
+ 'border-w-e': [{
2037
+ 'border-e': scaleBorderWidth()
2038
+ }],
2039
+ /**
2040
+ * Border Width Top
2041
+ * @see https://tailwindcss.com/docs/border-width
2042
+ */
2043
+ 'border-w-t': [{
2044
+ 'border-t': scaleBorderWidth()
2045
+ }],
2046
+ /**
2047
+ * Border Width Right
2048
+ * @see https://tailwindcss.com/docs/border-width
2049
+ */
2050
+ 'border-w-r': [{
2051
+ 'border-r': scaleBorderWidth()
2052
+ }],
2053
+ /**
2054
+ * Border Width Bottom
2055
+ * @see https://tailwindcss.com/docs/border-width
2056
+ */
2057
+ 'border-w-b': [{
2058
+ 'border-b': scaleBorderWidth()
2059
+ }],
2060
+ /**
2061
+ * Border Width Left
2062
+ * @see https://tailwindcss.com/docs/border-width
2063
+ */
2064
+ 'border-w-l': [{
2065
+ 'border-l': scaleBorderWidth()
2066
+ }],
2067
+ /**
2068
+ * Divide Width X
2069
+ * @see https://tailwindcss.com/docs/border-width#between-children
2070
+ */
2071
+ 'divide-x': [{
2072
+ 'divide-x': scaleBorderWidth()
2073
+ }],
2074
+ /**
2075
+ * Divide Width X Reverse
2076
+ * @see https://tailwindcss.com/docs/border-width#between-children
2077
+ */
2078
+ 'divide-x-reverse': ['divide-x-reverse'],
2079
+ /**
2080
+ * Divide Width Y
2081
+ * @see https://tailwindcss.com/docs/border-width#between-children
2082
+ */
2083
+ 'divide-y': [{
2084
+ 'divide-y': scaleBorderWidth()
2085
+ }],
2086
+ /**
2087
+ * Divide Width Y Reverse
2088
+ * @see https://tailwindcss.com/docs/border-width#between-children
2089
+ */
2090
+ 'divide-y-reverse': ['divide-y-reverse'],
2091
+ /**
2092
+ * Border Style
2093
+ * @see https://tailwindcss.com/docs/border-style
2094
+ */
2095
+ 'border-style': [{
2096
+ border: [...scaleLineStyle(), 'hidden', 'none']
2097
+ }],
2098
+ /**
2099
+ * Divide Style
2100
+ * @see https://tailwindcss.com/docs/border-style#setting-the-divider-style
2101
+ */
2102
+ 'divide-style': [{
2103
+ divide: [...scaleLineStyle(), 'hidden', 'none']
2104
+ }],
2105
+ /**
2106
+ * Border Color
2107
+ * @see https://tailwindcss.com/docs/border-color
2108
+ */
2109
+ 'border-color': [{
2110
+ border: scaleColor()
2111
+ }],
2112
+ /**
2113
+ * Border Color X
2114
+ * @see https://tailwindcss.com/docs/border-color
2115
+ */
2116
+ 'border-color-x': [{
2117
+ 'border-x': scaleColor()
2118
+ }],
2119
+ /**
2120
+ * Border Color Y
2121
+ * @see https://tailwindcss.com/docs/border-color
2122
+ */
2123
+ 'border-color-y': [{
2124
+ 'border-y': scaleColor()
2125
+ }],
2126
+ /**
2127
+ * Border Color S
2128
+ * @see https://tailwindcss.com/docs/border-color
2129
+ */
2130
+ 'border-color-s': [{
2131
+ 'border-s': scaleColor()
2132
+ }],
2133
+ /**
2134
+ * Border Color E
2135
+ * @see https://tailwindcss.com/docs/border-color
2136
+ */
2137
+ 'border-color-e': [{
2138
+ 'border-e': scaleColor()
2139
+ }],
2140
+ /**
2141
+ * Border Color Top
2142
+ * @see https://tailwindcss.com/docs/border-color
2143
+ */
2144
+ 'border-color-t': [{
2145
+ 'border-t': scaleColor()
2146
+ }],
2147
+ /**
2148
+ * Border Color Right
2149
+ * @see https://tailwindcss.com/docs/border-color
2150
+ */
2151
+ 'border-color-r': [{
2152
+ 'border-r': scaleColor()
2153
+ }],
2154
+ /**
2155
+ * Border Color Bottom
2156
+ * @see https://tailwindcss.com/docs/border-color
2157
+ */
2158
+ 'border-color-b': [{
2159
+ 'border-b': scaleColor()
2160
+ }],
2161
+ /**
2162
+ * Border Color Left
2163
+ * @see https://tailwindcss.com/docs/border-color
2164
+ */
2165
+ 'border-color-l': [{
2166
+ 'border-l': scaleColor()
2167
+ }],
2168
+ /**
2169
+ * Divide Color
2170
+ * @see https://tailwindcss.com/docs/divide-color
2171
+ */
2172
+ 'divide-color': [{
2173
+ divide: scaleColor()
2174
+ }],
2175
+ /**
2176
+ * Outline Style
2177
+ * @see https://tailwindcss.com/docs/outline-style
2178
+ */
2179
+ 'outline-style': [{
2180
+ outline: [...scaleLineStyle(), 'none', 'hidden']
2181
+ }],
2182
+ /**
2183
+ * Outline Offset
2184
+ * @see https://tailwindcss.com/docs/outline-offset
2185
+ */
2186
+ 'outline-offset': [{
2187
+ 'outline-offset': [isNumber, isArbitraryVariable, isArbitraryValue]
2188
+ }],
2189
+ /**
2190
+ * Outline Width
2191
+ * @see https://tailwindcss.com/docs/outline-width
2192
+ */
2193
+ 'outline-w': [{
2194
+ outline: ['', isNumber, isArbitraryVariableLength, isArbitraryLength]
2195
+ }],
2196
+ /**
2197
+ * Outline Color
2198
+ * @see https://tailwindcss.com/docs/outline-color
2199
+ */
2200
+ 'outline-color': [{
2201
+ outline: scaleColor()
2202
+ }],
2203
+ // ---------------
2204
+ // --- Effects ---
2205
+ // ---------------
2206
+ /**
2207
+ * Box Shadow
2208
+ * @see https://tailwindcss.com/docs/box-shadow
2209
+ */
2210
+ shadow: [{
2211
+ shadow: [
2212
+ // Deprecated since Tailwind CSS v4.0.0
2213
+ '', 'none', themeShadow, isArbitraryVariableShadow, isArbitraryShadow]
2214
+ }],
2215
+ /**
2216
+ * Box Shadow Color
2217
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-shadow-color
2218
+ */
2219
+ 'shadow-color': [{
2220
+ shadow: scaleColor()
2221
+ }],
2222
+ /**
2223
+ * Inset Box Shadow
2224
+ * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-shadow
2225
+ */
2226
+ 'inset-shadow': [{
2227
+ 'inset-shadow': ['none', themeInsetShadow, isArbitraryVariableShadow, isArbitraryShadow]
2228
+ }],
2229
+ /**
2230
+ * Inset Box Shadow Color
2231
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-shadow-color
2232
+ */
2233
+ 'inset-shadow-color': [{
2234
+ 'inset-shadow': scaleColor()
2235
+ }],
2236
+ /**
2237
+ * Ring Width
2238
+ * @see https://tailwindcss.com/docs/box-shadow#adding-a-ring
2239
+ */
2240
+ 'ring-w': [{
2241
+ ring: scaleBorderWidth()
2242
+ }],
2243
+ /**
2244
+ * Ring Width Inset
2245
+ * @see https://v3.tailwindcss.com/docs/ring-width#inset-rings
2246
+ * @deprecated since Tailwind CSS v4.0.0
2247
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
2248
+ */
2249
+ 'ring-w-inset': ['ring-inset'],
2250
+ /**
2251
+ * Ring Color
2252
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-ring-color
2253
+ */
2254
+ 'ring-color': [{
2255
+ ring: scaleColor()
2256
+ }],
2257
+ /**
2258
+ * Ring Offset Width
2259
+ * @see https://v3.tailwindcss.com/docs/ring-offset-width
2260
+ * @deprecated since Tailwind CSS v4.0.0
2261
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
2262
+ */
2263
+ 'ring-offset-w': [{
2264
+ 'ring-offset': [isNumber, isArbitraryLength]
2265
+ }],
2266
+ /**
2267
+ * Ring Offset Color
2268
+ * @see https://v3.tailwindcss.com/docs/ring-offset-color
2269
+ * @deprecated since Tailwind CSS v4.0.0
2270
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
2271
+ */
2272
+ 'ring-offset-color': [{
2273
+ 'ring-offset': scaleColor()
2274
+ }],
2275
+ /**
2276
+ * Inset Ring Width
2277
+ * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-ring
2278
+ */
2279
+ 'inset-ring-w': [{
2280
+ 'inset-ring': scaleBorderWidth()
2281
+ }],
2282
+ /**
2283
+ * Inset Ring Color
2284
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-ring-color
2285
+ */
2286
+ 'inset-ring-color': [{
2287
+ 'inset-ring': scaleColor()
2288
+ }],
2289
+ /**
2290
+ * Text Shadow
2291
+ * @see https://tailwindcss.com/docs/text-shadow
2292
+ */
2293
+ 'text-shadow': [{
2294
+ 'text-shadow': ['none', themeTextShadow, isArbitraryVariableShadow, isArbitraryShadow]
2295
+ }],
2296
+ /**
2297
+ * Text Shadow Color
2298
+ * @see https://tailwindcss.com/docs/text-shadow#setting-the-shadow-color
2299
+ */
2300
+ 'text-shadow-color': [{
2301
+ 'text-shadow': scaleColor()
2302
+ }],
2303
+ /**
2304
+ * Opacity
2305
+ * @see https://tailwindcss.com/docs/opacity
2306
+ */
2307
+ opacity: [{
2308
+ opacity: [isNumber, isArbitraryVariable, isArbitraryValue]
2309
+ }],
2310
+ /**
2311
+ * Mix Blend Mode
2312
+ * @see https://tailwindcss.com/docs/mix-blend-mode
2313
+ */
2314
+ 'mix-blend': [{
2315
+ 'mix-blend': [...scaleBlendMode(), 'plus-darker', 'plus-lighter']
2316
+ }],
2317
+ /**
2318
+ * Background Blend Mode
2319
+ * @see https://tailwindcss.com/docs/background-blend-mode
2320
+ */
2321
+ 'bg-blend': [{
2322
+ 'bg-blend': scaleBlendMode()
2323
+ }],
2324
+ /**
2325
+ * Mask Clip
2326
+ * @see https://tailwindcss.com/docs/mask-clip
2327
+ */
2328
+ 'mask-clip': [{
2329
+ 'mask-clip': ['border', 'padding', 'content', 'fill', 'stroke', 'view']
2330
+ }, 'mask-no-clip'],
2331
+ /**
2332
+ * Mask Composite
2333
+ * @see https://tailwindcss.com/docs/mask-composite
2334
+ */
2335
+ 'mask-composite': [{
2336
+ mask: ['add', 'subtract', 'intersect', 'exclude']
2337
+ }],
2338
+ /**
2339
+ * Mask Image
2340
+ * @see https://tailwindcss.com/docs/mask-image
2341
+ */
2342
+ 'mask-image-linear-pos': [{
2343
+ 'mask-linear': [isNumber]
2344
+ }],
2345
+ 'mask-image-linear-from-pos': [{
2346
+ 'mask-linear-from': scaleMaskImagePosition()
2347
+ }],
2348
+ 'mask-image-linear-to-pos': [{
2349
+ 'mask-linear-to': scaleMaskImagePosition()
2350
+ }],
2351
+ 'mask-image-linear-from-color': [{
2352
+ 'mask-linear-from': scaleColor()
2353
+ }],
2354
+ 'mask-image-linear-to-color': [{
2355
+ 'mask-linear-to': scaleColor()
2356
+ }],
2357
+ 'mask-image-t-from-pos': [{
2358
+ 'mask-t-from': scaleMaskImagePosition()
2359
+ }],
2360
+ 'mask-image-t-to-pos': [{
2361
+ 'mask-t-to': scaleMaskImagePosition()
2362
+ }],
2363
+ 'mask-image-t-from-color': [{
2364
+ 'mask-t-from': scaleColor()
2365
+ }],
2366
+ 'mask-image-t-to-color': [{
2367
+ 'mask-t-to': scaleColor()
2368
+ }],
2369
+ 'mask-image-r-from-pos': [{
2370
+ 'mask-r-from': scaleMaskImagePosition()
2371
+ }],
2372
+ 'mask-image-r-to-pos': [{
2373
+ 'mask-r-to': scaleMaskImagePosition()
2374
+ }],
2375
+ 'mask-image-r-from-color': [{
2376
+ 'mask-r-from': scaleColor()
2377
+ }],
2378
+ 'mask-image-r-to-color': [{
2379
+ 'mask-r-to': scaleColor()
2380
+ }],
2381
+ 'mask-image-b-from-pos': [{
2382
+ 'mask-b-from': scaleMaskImagePosition()
2383
+ }],
2384
+ 'mask-image-b-to-pos': [{
2385
+ 'mask-b-to': scaleMaskImagePosition()
2386
+ }],
2387
+ 'mask-image-b-from-color': [{
2388
+ 'mask-b-from': scaleColor()
2389
+ }],
2390
+ 'mask-image-b-to-color': [{
2391
+ 'mask-b-to': scaleColor()
2392
+ }],
2393
+ 'mask-image-l-from-pos': [{
2394
+ 'mask-l-from': scaleMaskImagePosition()
2395
+ }],
2396
+ 'mask-image-l-to-pos': [{
2397
+ 'mask-l-to': scaleMaskImagePosition()
2398
+ }],
2399
+ 'mask-image-l-from-color': [{
2400
+ 'mask-l-from': scaleColor()
2401
+ }],
2402
+ 'mask-image-l-to-color': [{
2403
+ 'mask-l-to': scaleColor()
2404
+ }],
2405
+ 'mask-image-x-from-pos': [{
2406
+ 'mask-x-from': scaleMaskImagePosition()
2407
+ }],
2408
+ 'mask-image-x-to-pos': [{
2409
+ 'mask-x-to': scaleMaskImagePosition()
2410
+ }],
2411
+ 'mask-image-x-from-color': [{
2412
+ 'mask-x-from': scaleColor()
2413
+ }],
2414
+ 'mask-image-x-to-color': [{
2415
+ 'mask-x-to': scaleColor()
2416
+ }],
2417
+ 'mask-image-y-from-pos': [{
2418
+ 'mask-y-from': scaleMaskImagePosition()
2419
+ }],
2420
+ 'mask-image-y-to-pos': [{
2421
+ 'mask-y-to': scaleMaskImagePosition()
2422
+ }],
2423
+ 'mask-image-y-from-color': [{
2424
+ 'mask-y-from': scaleColor()
2425
+ }],
2426
+ 'mask-image-y-to-color': [{
2427
+ 'mask-y-to': scaleColor()
2428
+ }],
2429
+ 'mask-image-radial': [{
2430
+ 'mask-radial': [isArbitraryVariable, isArbitraryValue]
2431
+ }],
2432
+ 'mask-image-radial-from-pos': [{
2433
+ 'mask-radial-from': scaleMaskImagePosition()
2434
+ }],
2435
+ 'mask-image-radial-to-pos': [{
2436
+ 'mask-radial-to': scaleMaskImagePosition()
2437
+ }],
2438
+ 'mask-image-radial-from-color': [{
2439
+ 'mask-radial-from': scaleColor()
2440
+ }],
2441
+ 'mask-image-radial-to-color': [{
2442
+ 'mask-radial-to': scaleColor()
2443
+ }],
2444
+ 'mask-image-radial-shape': [{
2445
+ 'mask-radial': ['circle', 'ellipse']
2446
+ }],
2447
+ 'mask-image-radial-size': [{
2448
+ 'mask-radial': [{
2449
+ closest: ['side', 'corner'],
2450
+ farthest: ['side', 'corner']
2451
+ }]
2452
+ }],
2453
+ 'mask-image-radial-pos': [{
2454
+ 'mask-radial-at': scalePosition()
2455
+ }],
2456
+ 'mask-image-conic-pos': [{
2457
+ 'mask-conic': [isNumber]
2458
+ }],
2459
+ 'mask-image-conic-from-pos': [{
2460
+ 'mask-conic-from': scaleMaskImagePosition()
2461
+ }],
2462
+ 'mask-image-conic-to-pos': [{
2463
+ 'mask-conic-to': scaleMaskImagePosition()
2464
+ }],
2465
+ 'mask-image-conic-from-color': [{
2466
+ 'mask-conic-from': scaleColor()
2467
+ }],
2468
+ 'mask-image-conic-to-color': [{
2469
+ 'mask-conic-to': scaleColor()
2470
+ }],
2471
+ /**
2472
+ * Mask Mode
2473
+ * @see https://tailwindcss.com/docs/mask-mode
2474
+ */
2475
+ 'mask-mode': [{
2476
+ mask: ['alpha', 'luminance', 'match']
2477
+ }],
2478
+ /**
2479
+ * Mask Origin
2480
+ * @see https://tailwindcss.com/docs/mask-origin
2481
+ */
2482
+ 'mask-origin': [{
2483
+ 'mask-origin': ['border', 'padding', 'content', 'fill', 'stroke', 'view']
2484
+ }],
2485
+ /**
2486
+ * Mask Position
2487
+ * @see https://tailwindcss.com/docs/mask-position
2488
+ */
2489
+ 'mask-position': [{
2490
+ mask: scaleBgPosition()
2491
+ }],
2492
+ /**
2493
+ * Mask Repeat
2494
+ * @see https://tailwindcss.com/docs/mask-repeat
2495
+ */
2496
+ 'mask-repeat': [{
2497
+ mask: scaleBgRepeat()
2498
+ }],
2499
+ /**
2500
+ * Mask Size
2501
+ * @see https://tailwindcss.com/docs/mask-size
2502
+ */
2503
+ 'mask-size': [{
2504
+ mask: scaleBgSize()
2505
+ }],
2506
+ /**
2507
+ * Mask Type
2508
+ * @see https://tailwindcss.com/docs/mask-type
2509
+ */
2510
+ 'mask-type': [{
2511
+ 'mask-type': ['alpha', 'luminance']
2512
+ }],
2513
+ /**
2514
+ * Mask Image
2515
+ * @see https://tailwindcss.com/docs/mask-image
2516
+ */
2517
+ 'mask-image': [{
2518
+ mask: ['none', isArbitraryVariable, isArbitraryValue]
2519
+ }],
2520
+ // ---------------
2521
+ // --- Filters ---
2522
+ // ---------------
2523
+ /**
2524
+ * Filter
2525
+ * @see https://tailwindcss.com/docs/filter
2526
+ */
2527
+ filter: [{
2528
+ filter: [
2529
+ // Deprecated since Tailwind CSS v3.0.0
2530
+ '', 'none', isArbitraryVariable, isArbitraryValue]
2531
+ }],
2532
+ /**
2533
+ * Blur
2534
+ * @see https://tailwindcss.com/docs/blur
2535
+ */
2536
+ blur: [{
2537
+ blur: scaleBlur()
2538
+ }],
2539
+ /**
2540
+ * Brightness
2541
+ * @see https://tailwindcss.com/docs/brightness
2542
+ */
2543
+ brightness: [{
2544
+ brightness: [isNumber, isArbitraryVariable, isArbitraryValue]
2545
+ }],
2546
+ /**
2547
+ * Contrast
2548
+ * @see https://tailwindcss.com/docs/contrast
2549
+ */
2550
+ contrast: [{
2551
+ contrast: [isNumber, isArbitraryVariable, isArbitraryValue]
2552
+ }],
2553
+ /**
2554
+ * Drop Shadow
2555
+ * @see https://tailwindcss.com/docs/drop-shadow
2556
+ */
2557
+ 'drop-shadow': [{
2558
+ 'drop-shadow': [
2559
+ // Deprecated since Tailwind CSS v4.0.0
2560
+ '', 'none', themeDropShadow, isArbitraryVariableShadow, isArbitraryShadow]
2561
+ }],
2562
+ /**
2563
+ * Drop Shadow Color
2564
+ * @see https://tailwindcss.com/docs/filter-drop-shadow#setting-the-shadow-color
2565
+ */
2566
+ 'drop-shadow-color': [{
2567
+ 'drop-shadow': scaleColor()
2568
+ }],
2569
+ /**
2570
+ * Grayscale
2571
+ * @see https://tailwindcss.com/docs/grayscale
2572
+ */
2573
+ grayscale: [{
2574
+ grayscale: ['', isNumber, isArbitraryVariable, isArbitraryValue]
2575
+ }],
2576
+ /**
2577
+ * Hue Rotate
2578
+ * @see https://tailwindcss.com/docs/hue-rotate
2579
+ */
2580
+ 'hue-rotate': [{
2581
+ 'hue-rotate': [isNumber, isArbitraryVariable, isArbitraryValue]
2582
+ }],
2583
+ /**
2584
+ * Invert
2585
+ * @see https://tailwindcss.com/docs/invert
2586
+ */
2587
+ invert: [{
2588
+ invert: ['', isNumber, isArbitraryVariable, isArbitraryValue]
2589
+ }],
2590
+ /**
2591
+ * Saturate
2592
+ * @see https://tailwindcss.com/docs/saturate
2593
+ */
2594
+ saturate: [{
2595
+ saturate: [isNumber, isArbitraryVariable, isArbitraryValue]
2596
+ }],
2597
+ /**
2598
+ * Sepia
2599
+ * @see https://tailwindcss.com/docs/sepia
2600
+ */
2601
+ sepia: [{
2602
+ sepia: ['', isNumber, isArbitraryVariable, isArbitraryValue]
2603
+ }],
2604
+ /**
2605
+ * Backdrop Filter
2606
+ * @see https://tailwindcss.com/docs/backdrop-filter
2607
+ */
2608
+ 'backdrop-filter': [{
2609
+ 'backdrop-filter': [
2610
+ // Deprecated since Tailwind CSS v3.0.0
2611
+ '', 'none', isArbitraryVariable, isArbitraryValue]
2612
+ }],
2613
+ /**
2614
+ * Backdrop Blur
2615
+ * @see https://tailwindcss.com/docs/backdrop-blur
2616
+ */
2617
+ 'backdrop-blur': [{
2618
+ 'backdrop-blur': scaleBlur()
2619
+ }],
2620
+ /**
2621
+ * Backdrop Brightness
2622
+ * @see https://tailwindcss.com/docs/backdrop-brightness
2623
+ */
2624
+ 'backdrop-brightness': [{
2625
+ 'backdrop-brightness': [isNumber, isArbitraryVariable, isArbitraryValue]
2626
+ }],
2627
+ /**
2628
+ * Backdrop Contrast
2629
+ * @see https://tailwindcss.com/docs/backdrop-contrast
2630
+ */
2631
+ 'backdrop-contrast': [{
2632
+ 'backdrop-contrast': [isNumber, isArbitraryVariable, isArbitraryValue]
2633
+ }],
2634
+ /**
2635
+ * Backdrop Grayscale
2636
+ * @see https://tailwindcss.com/docs/backdrop-grayscale
2637
+ */
2638
+ 'backdrop-grayscale': [{
2639
+ 'backdrop-grayscale': ['', isNumber, isArbitraryVariable, isArbitraryValue]
2640
+ }],
2641
+ /**
2642
+ * Backdrop Hue Rotate
2643
+ * @see https://tailwindcss.com/docs/backdrop-hue-rotate
2644
+ */
2645
+ 'backdrop-hue-rotate': [{
2646
+ 'backdrop-hue-rotate': [isNumber, isArbitraryVariable, isArbitraryValue]
2647
+ }],
2648
+ /**
2649
+ * Backdrop Invert
2650
+ * @see https://tailwindcss.com/docs/backdrop-invert
2651
+ */
2652
+ 'backdrop-invert': [{
2653
+ 'backdrop-invert': ['', isNumber, isArbitraryVariable, isArbitraryValue]
2654
+ }],
2655
+ /**
2656
+ * Backdrop Opacity
2657
+ * @see https://tailwindcss.com/docs/backdrop-opacity
2658
+ */
2659
+ 'backdrop-opacity': [{
2660
+ 'backdrop-opacity': [isNumber, isArbitraryVariable, isArbitraryValue]
2661
+ }],
2662
+ /**
2663
+ * Backdrop Saturate
2664
+ * @see https://tailwindcss.com/docs/backdrop-saturate
2665
+ */
2666
+ 'backdrop-saturate': [{
2667
+ 'backdrop-saturate': [isNumber, isArbitraryVariable, isArbitraryValue]
2668
+ }],
2669
+ /**
2670
+ * Backdrop Sepia
2671
+ * @see https://tailwindcss.com/docs/backdrop-sepia
2672
+ */
2673
+ 'backdrop-sepia': [{
2674
+ 'backdrop-sepia': ['', isNumber, isArbitraryVariable, isArbitraryValue]
2675
+ }],
2676
+ // --------------
2677
+ // --- Tables ---
2678
+ // --------------
2679
+ /**
2680
+ * Border Collapse
2681
+ * @see https://tailwindcss.com/docs/border-collapse
2682
+ */
2683
+ 'border-collapse': [{
2684
+ border: ['collapse', 'separate']
2685
+ }],
2686
+ /**
2687
+ * Border Spacing
2688
+ * @see https://tailwindcss.com/docs/border-spacing
2689
+ */
2690
+ 'border-spacing': [{
2691
+ 'border-spacing': scaleUnambiguousSpacing()
2692
+ }],
2693
+ /**
2694
+ * Border Spacing X
2695
+ * @see https://tailwindcss.com/docs/border-spacing
2696
+ */
2697
+ 'border-spacing-x': [{
2698
+ 'border-spacing-x': scaleUnambiguousSpacing()
2699
+ }],
2700
+ /**
2701
+ * Border Spacing Y
2702
+ * @see https://tailwindcss.com/docs/border-spacing
2703
+ */
2704
+ 'border-spacing-y': [{
2705
+ 'border-spacing-y': scaleUnambiguousSpacing()
2706
+ }],
2707
+ /**
2708
+ * Table Layout
2709
+ * @see https://tailwindcss.com/docs/table-layout
2710
+ */
2711
+ 'table-layout': [{
2712
+ table: ['auto', 'fixed']
2713
+ }],
2714
+ /**
2715
+ * Caption Side
2716
+ * @see https://tailwindcss.com/docs/caption-side
2717
+ */
2718
+ caption: [{
2719
+ caption: ['top', 'bottom']
2720
+ }],
2721
+ // ---------------------------------
2722
+ // --- Transitions and Animation ---
2723
+ // ---------------------------------
2724
+ /**
2725
+ * Transition Property
2726
+ * @see https://tailwindcss.com/docs/transition-property
2727
+ */
2728
+ transition: [{
2729
+ transition: ['', 'all', 'colors', 'opacity', 'shadow', 'transform', 'none', isArbitraryVariable, isArbitraryValue]
2730
+ }],
2731
+ /**
2732
+ * Transition Behavior
2733
+ * @see https://tailwindcss.com/docs/transition-behavior
2734
+ */
2735
+ 'transition-behavior': [{
2736
+ transition: ['normal', 'discrete']
2737
+ }],
2738
+ /**
2739
+ * Transition Duration
2740
+ * @see https://tailwindcss.com/docs/transition-duration
2741
+ */
2742
+ duration: [{
2743
+ duration: [isNumber, 'initial', isArbitraryVariable, isArbitraryValue]
2744
+ }],
2745
+ /**
2746
+ * Transition Timing Function
2747
+ * @see https://tailwindcss.com/docs/transition-timing-function
2748
+ */
2749
+ ease: [{
2750
+ ease: ['linear', 'initial', themeEase, isArbitraryVariable, isArbitraryValue]
2751
+ }],
2752
+ /**
2753
+ * Transition Delay
2754
+ * @see https://tailwindcss.com/docs/transition-delay
2755
+ */
2756
+ delay: [{
2757
+ delay: [isNumber, isArbitraryVariable, isArbitraryValue]
2758
+ }],
2759
+ /**
2760
+ * Animation
2761
+ * @see https://tailwindcss.com/docs/animation
2762
+ */
2763
+ animate: [{
2764
+ animate: ['none', themeAnimate, isArbitraryVariable, isArbitraryValue]
2765
+ }],
2766
+ // ------------------
2767
+ // --- Transforms ---
2768
+ // ------------------
2769
+ /**
2770
+ * Backface Visibility
2771
+ * @see https://tailwindcss.com/docs/backface-visibility
2772
+ */
2773
+ backface: [{
2774
+ backface: ['hidden', 'visible']
2775
+ }],
2776
+ /**
2777
+ * Perspective
2778
+ * @see https://tailwindcss.com/docs/perspective
2779
+ */
2780
+ perspective: [{
2781
+ perspective: [themePerspective, isArbitraryVariable, isArbitraryValue]
2782
+ }],
2783
+ /**
2784
+ * Perspective Origin
2785
+ * @see https://tailwindcss.com/docs/perspective-origin
2786
+ */
2787
+ 'perspective-origin': [{
2788
+ 'perspective-origin': scalePositionWithArbitrary()
2789
+ }],
2790
+ /**
2791
+ * Rotate
2792
+ * @see https://tailwindcss.com/docs/rotate
2793
+ */
2794
+ rotate: [{
2795
+ rotate: scaleRotate()
2796
+ }],
2797
+ /**
2798
+ * Rotate X
2799
+ * @see https://tailwindcss.com/docs/rotate
2800
+ */
2801
+ 'rotate-x': [{
2802
+ 'rotate-x': scaleRotate()
2803
+ }],
2804
+ /**
2805
+ * Rotate Y
2806
+ * @see https://tailwindcss.com/docs/rotate
2807
+ */
2808
+ 'rotate-y': [{
2809
+ 'rotate-y': scaleRotate()
2810
+ }],
2811
+ /**
2812
+ * Rotate Z
2813
+ * @see https://tailwindcss.com/docs/rotate
2814
+ */
2815
+ 'rotate-z': [{
2816
+ 'rotate-z': scaleRotate()
2817
+ }],
2818
+ /**
2819
+ * Scale
2820
+ * @see https://tailwindcss.com/docs/scale
2821
+ */
2822
+ scale: [{
2823
+ scale: scaleScale()
2824
+ }],
2825
+ /**
2826
+ * Scale X
2827
+ * @see https://tailwindcss.com/docs/scale
2828
+ */
2829
+ 'scale-x': [{
2830
+ 'scale-x': scaleScale()
2831
+ }],
2832
+ /**
2833
+ * Scale Y
2834
+ * @see https://tailwindcss.com/docs/scale
2835
+ */
2836
+ 'scale-y': [{
2837
+ 'scale-y': scaleScale()
2838
+ }],
2839
+ /**
2840
+ * Scale Z
2841
+ * @see https://tailwindcss.com/docs/scale
2842
+ */
2843
+ 'scale-z': [{
2844
+ 'scale-z': scaleScale()
2845
+ }],
2846
+ /**
2847
+ * Scale 3D
2848
+ * @see https://tailwindcss.com/docs/scale
2849
+ */
2850
+ 'scale-3d': ['scale-3d'],
2851
+ /**
2852
+ * Skew
2853
+ * @see https://tailwindcss.com/docs/skew
2854
+ */
2855
+ skew: [{
2856
+ skew: scaleSkew()
2857
+ }],
2858
+ /**
2859
+ * Skew X
2860
+ * @see https://tailwindcss.com/docs/skew
2861
+ */
2862
+ 'skew-x': [{
2863
+ 'skew-x': scaleSkew()
2864
+ }],
2865
+ /**
2866
+ * Skew Y
2867
+ * @see https://tailwindcss.com/docs/skew
2868
+ */
2869
+ 'skew-y': [{
2870
+ 'skew-y': scaleSkew()
2871
+ }],
2872
+ /**
2873
+ * Transform
2874
+ * @see https://tailwindcss.com/docs/transform
2875
+ */
2876
+ transform: [{
2877
+ transform: [isArbitraryVariable, isArbitraryValue, '', 'none', 'gpu', 'cpu']
2878
+ }],
2879
+ /**
2880
+ * Transform Origin
2881
+ * @see https://tailwindcss.com/docs/transform-origin
2882
+ */
2883
+ 'transform-origin': [{
2884
+ origin: scalePositionWithArbitrary()
2885
+ }],
2886
+ /**
2887
+ * Transform Style
2888
+ * @see https://tailwindcss.com/docs/transform-style
2889
+ */
2890
+ 'transform-style': [{
2891
+ transform: ['3d', 'flat']
2892
+ }],
2893
+ /**
2894
+ * Translate
2895
+ * @see https://tailwindcss.com/docs/translate
2896
+ */
2897
+ translate: [{
2898
+ translate: scaleTranslate()
2899
+ }],
2900
+ /**
2901
+ * Translate X
2902
+ * @see https://tailwindcss.com/docs/translate
2903
+ */
2904
+ 'translate-x': [{
2905
+ 'translate-x': scaleTranslate()
2906
+ }],
2907
+ /**
2908
+ * Translate Y
2909
+ * @see https://tailwindcss.com/docs/translate
2910
+ */
2911
+ 'translate-y': [{
2912
+ 'translate-y': scaleTranslate()
2913
+ }],
2914
+ /**
2915
+ * Translate Z
2916
+ * @see https://tailwindcss.com/docs/translate
2917
+ */
2918
+ 'translate-z': [{
2919
+ 'translate-z': scaleTranslate()
2920
+ }],
2921
+ /**
2922
+ * Translate None
2923
+ * @see https://tailwindcss.com/docs/translate
2924
+ */
2925
+ 'translate-none': ['translate-none'],
2926
+ // ---------------------
2927
+ // --- Interactivity ---
2928
+ // ---------------------
2929
+ /**
2930
+ * Accent Color
2931
+ * @see https://tailwindcss.com/docs/accent-color
2932
+ */
2933
+ accent: [{
2934
+ accent: scaleColor()
2935
+ }],
2936
+ /**
2937
+ * Appearance
2938
+ * @see https://tailwindcss.com/docs/appearance
2939
+ */
2940
+ appearance: [{
2941
+ appearance: ['none', 'auto']
2942
+ }],
2943
+ /**
2944
+ * Caret Color
2945
+ * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
2946
+ */
2947
+ 'caret-color': [{
2948
+ caret: scaleColor()
2949
+ }],
2950
+ /**
2951
+ * Color Scheme
2952
+ * @see https://tailwindcss.com/docs/color-scheme
2953
+ */
2954
+ 'color-scheme': [{
2955
+ scheme: ['normal', 'dark', 'light', 'light-dark', 'only-dark', 'only-light']
2956
+ }],
2957
+ /**
2958
+ * Cursor
2959
+ * @see https://tailwindcss.com/docs/cursor
2960
+ */
2961
+ cursor: [{
2962
+ cursor: ['auto', 'default', 'pointer', 'wait', 'text', 'move', 'help', 'not-allowed', 'none', 'context-menu', 'progress', 'cell', 'crosshair', 'vertical-text', 'alias', 'copy', 'no-drop', 'grab', 'grabbing', 'all-scroll', 'col-resize', 'row-resize', 'n-resize', 'e-resize', 's-resize', 'w-resize', 'ne-resize', 'nw-resize', 'se-resize', 'sw-resize', 'ew-resize', 'ns-resize', 'nesw-resize', 'nwse-resize', 'zoom-in', 'zoom-out', isArbitraryVariable, isArbitraryValue]
2963
+ }],
2964
+ /**
2965
+ * Field Sizing
2966
+ * @see https://tailwindcss.com/docs/field-sizing
2967
+ */
2968
+ 'field-sizing': [{
2969
+ 'field-sizing': ['fixed', 'content']
2970
+ }],
2971
+ /**
2972
+ * Pointer Events
2973
+ * @see https://tailwindcss.com/docs/pointer-events
2974
+ */
2975
+ 'pointer-events': [{
2976
+ 'pointer-events': ['auto', 'none']
2977
+ }],
2978
+ /**
2979
+ * Resize
2980
+ * @see https://tailwindcss.com/docs/resize
2981
+ */
2982
+ resize: [{
2983
+ resize: ['none', '', 'y', 'x']
2984
+ }],
2985
+ /**
2986
+ * Scroll Behavior
2987
+ * @see https://tailwindcss.com/docs/scroll-behavior
2988
+ */
2989
+ 'scroll-behavior': [{
2990
+ scroll: ['auto', 'smooth']
2991
+ }],
2992
+ /**
2993
+ * Scroll Margin
2994
+ * @see https://tailwindcss.com/docs/scroll-margin
2995
+ */
2996
+ 'scroll-m': [{
2997
+ 'scroll-m': scaleUnambiguousSpacing()
2998
+ }],
2999
+ /**
3000
+ * Scroll Margin X
3001
+ * @see https://tailwindcss.com/docs/scroll-margin
3002
+ */
3003
+ 'scroll-mx': [{
3004
+ 'scroll-mx': scaleUnambiguousSpacing()
3005
+ }],
3006
+ /**
3007
+ * Scroll Margin Y
3008
+ * @see https://tailwindcss.com/docs/scroll-margin
3009
+ */
3010
+ 'scroll-my': [{
3011
+ 'scroll-my': scaleUnambiguousSpacing()
3012
+ }],
3013
+ /**
3014
+ * Scroll Margin Start
3015
+ * @see https://tailwindcss.com/docs/scroll-margin
3016
+ */
3017
+ 'scroll-ms': [{
3018
+ 'scroll-ms': scaleUnambiguousSpacing()
3019
+ }],
3020
+ /**
3021
+ * Scroll Margin End
3022
+ * @see https://tailwindcss.com/docs/scroll-margin
3023
+ */
3024
+ 'scroll-me': [{
3025
+ 'scroll-me': scaleUnambiguousSpacing()
3026
+ }],
3027
+ /**
3028
+ * Scroll Margin Top
3029
+ * @see https://tailwindcss.com/docs/scroll-margin
3030
+ */
3031
+ 'scroll-mt': [{
3032
+ 'scroll-mt': scaleUnambiguousSpacing()
3033
+ }],
3034
+ /**
3035
+ * Scroll Margin Right
3036
+ * @see https://tailwindcss.com/docs/scroll-margin
3037
+ */
3038
+ 'scroll-mr': [{
3039
+ 'scroll-mr': scaleUnambiguousSpacing()
3040
+ }],
3041
+ /**
3042
+ * Scroll Margin Bottom
3043
+ * @see https://tailwindcss.com/docs/scroll-margin
3044
+ */
3045
+ 'scroll-mb': [{
3046
+ 'scroll-mb': scaleUnambiguousSpacing()
3047
+ }],
3048
+ /**
3049
+ * Scroll Margin Left
3050
+ * @see https://tailwindcss.com/docs/scroll-margin
3051
+ */
3052
+ 'scroll-ml': [{
3053
+ 'scroll-ml': scaleUnambiguousSpacing()
3054
+ }],
3055
+ /**
3056
+ * Scroll Padding
3057
+ * @see https://tailwindcss.com/docs/scroll-padding
3058
+ */
3059
+ 'scroll-p': [{
3060
+ 'scroll-p': scaleUnambiguousSpacing()
3061
+ }],
3062
+ /**
3063
+ * Scroll Padding X
3064
+ * @see https://tailwindcss.com/docs/scroll-padding
3065
+ */
3066
+ 'scroll-px': [{
3067
+ 'scroll-px': scaleUnambiguousSpacing()
3068
+ }],
3069
+ /**
3070
+ * Scroll Padding Y
3071
+ * @see https://tailwindcss.com/docs/scroll-padding
3072
+ */
3073
+ 'scroll-py': [{
3074
+ 'scroll-py': scaleUnambiguousSpacing()
3075
+ }],
3076
+ /**
3077
+ * Scroll Padding Start
3078
+ * @see https://tailwindcss.com/docs/scroll-padding
3079
+ */
3080
+ 'scroll-ps': [{
3081
+ 'scroll-ps': scaleUnambiguousSpacing()
3082
+ }],
3083
+ /**
3084
+ * Scroll Padding End
3085
+ * @see https://tailwindcss.com/docs/scroll-padding
3086
+ */
3087
+ 'scroll-pe': [{
3088
+ 'scroll-pe': scaleUnambiguousSpacing()
3089
+ }],
3090
+ /**
3091
+ * Scroll Padding Top
3092
+ * @see https://tailwindcss.com/docs/scroll-padding
3093
+ */
3094
+ 'scroll-pt': [{
3095
+ 'scroll-pt': scaleUnambiguousSpacing()
3096
+ }],
3097
+ /**
3098
+ * Scroll Padding Right
3099
+ * @see https://tailwindcss.com/docs/scroll-padding
3100
+ */
3101
+ 'scroll-pr': [{
3102
+ 'scroll-pr': scaleUnambiguousSpacing()
3103
+ }],
3104
+ /**
3105
+ * Scroll Padding Bottom
3106
+ * @see https://tailwindcss.com/docs/scroll-padding
3107
+ */
3108
+ 'scroll-pb': [{
3109
+ 'scroll-pb': scaleUnambiguousSpacing()
3110
+ }],
3111
+ /**
3112
+ * Scroll Padding Left
3113
+ * @see https://tailwindcss.com/docs/scroll-padding
3114
+ */
3115
+ 'scroll-pl': [{
3116
+ 'scroll-pl': scaleUnambiguousSpacing()
3117
+ }],
3118
+ /**
3119
+ * Scroll Snap Align
3120
+ * @see https://tailwindcss.com/docs/scroll-snap-align
3121
+ */
3122
+ 'snap-align': [{
3123
+ snap: ['start', 'end', 'center', 'align-none']
3124
+ }],
3125
+ /**
3126
+ * Scroll Snap Stop
3127
+ * @see https://tailwindcss.com/docs/scroll-snap-stop
3128
+ */
3129
+ 'snap-stop': [{
3130
+ snap: ['normal', 'always']
3131
+ }],
3132
+ /**
3133
+ * Scroll Snap Type
3134
+ * @see https://tailwindcss.com/docs/scroll-snap-type
3135
+ */
3136
+ 'snap-type': [{
3137
+ snap: ['none', 'x', 'y', 'both']
3138
+ }],
3139
+ /**
3140
+ * Scroll Snap Type Strictness
3141
+ * @see https://tailwindcss.com/docs/scroll-snap-type
3142
+ */
3143
+ 'snap-strictness': [{
3144
+ snap: ['mandatory', 'proximity']
3145
+ }],
3146
+ /**
3147
+ * Touch Action
3148
+ * @see https://tailwindcss.com/docs/touch-action
3149
+ */
3150
+ touch: [{
3151
+ touch: ['auto', 'none', 'manipulation']
3152
+ }],
3153
+ /**
3154
+ * Touch Action X
3155
+ * @see https://tailwindcss.com/docs/touch-action
3156
+ */
3157
+ 'touch-x': [{
3158
+ 'touch-pan': ['x', 'left', 'right']
3159
+ }],
3160
+ /**
3161
+ * Touch Action Y
3162
+ * @see https://tailwindcss.com/docs/touch-action
3163
+ */
3164
+ 'touch-y': [{
3165
+ 'touch-pan': ['y', 'up', 'down']
3166
+ }],
3167
+ /**
3168
+ * Touch Action Pinch Zoom
3169
+ * @see https://tailwindcss.com/docs/touch-action
3170
+ */
3171
+ 'touch-pz': ['touch-pinch-zoom'],
3172
+ /**
3173
+ * User Select
3174
+ * @see https://tailwindcss.com/docs/user-select
3175
+ */
3176
+ select: [{
3177
+ select: ['none', 'text', 'all', 'auto']
3178
+ }],
3179
+ /**
3180
+ * Will Change
3181
+ * @see https://tailwindcss.com/docs/will-change
3182
+ */
3183
+ 'will-change': [{
3184
+ 'will-change': ['auto', 'scroll', 'contents', 'transform', isArbitraryVariable, isArbitraryValue]
3185
+ }],
3186
+ // -----------
3187
+ // --- SVG ---
3188
+ // -----------
3189
+ /**
3190
+ * Fill
3191
+ * @see https://tailwindcss.com/docs/fill
3192
+ */
3193
+ fill: [{
3194
+ fill: ['none', ...scaleColor()]
3195
+ }],
3196
+ /**
3197
+ * Stroke Width
3198
+ * @see https://tailwindcss.com/docs/stroke-width
3199
+ */
3200
+ 'stroke-w': [{
3201
+ stroke: [isNumber, isArbitraryVariableLength, isArbitraryLength, isArbitraryNumber]
3202
+ }],
3203
+ /**
3204
+ * Stroke
3205
+ * @see https://tailwindcss.com/docs/stroke
3206
+ */
3207
+ stroke: [{
3208
+ stroke: ['none', ...scaleColor()]
3209
+ }],
3210
+ // ---------------------
3211
+ // --- Accessibility ---
3212
+ // ---------------------
3213
+ /**
3214
+ * Forced Color Adjust
3215
+ * @see https://tailwindcss.com/docs/forced-color-adjust
3216
+ */
3217
+ 'forced-color-adjust': [{
3218
+ 'forced-color-adjust': ['auto', 'none']
3219
+ }]
3220
+ },
3221
+ conflictingClassGroups: {
3222
+ overflow: ['overflow-x', 'overflow-y'],
3223
+ overscroll: ['overscroll-x', 'overscroll-y'],
3224
+ inset: ['inset-x', 'inset-y', 'start', 'end', 'top', 'right', 'bottom', 'left'],
3225
+ 'inset-x': ['right', 'left'],
3226
+ 'inset-y': ['top', 'bottom'],
3227
+ flex: ['basis', 'grow', 'shrink'],
3228
+ gap: ['gap-x', 'gap-y'],
3229
+ p: ['px', 'py', 'ps', 'pe', 'pt', 'pr', 'pb', 'pl'],
3230
+ px: ['pr', 'pl'],
3231
+ py: ['pt', 'pb'],
3232
+ m: ['mx', 'my', 'ms', 'me', 'mt', 'mr', 'mb', 'ml'],
3233
+ mx: ['mr', 'ml'],
3234
+ my: ['mt', 'mb'],
3235
+ size: ['w', 'h'],
3236
+ 'font-size': ['leading'],
3237
+ 'fvn-normal': ['fvn-ordinal', 'fvn-slashed-zero', 'fvn-figure', 'fvn-spacing', 'fvn-fraction'],
3238
+ 'fvn-ordinal': ['fvn-normal'],
3239
+ 'fvn-slashed-zero': ['fvn-normal'],
3240
+ 'fvn-figure': ['fvn-normal'],
3241
+ 'fvn-spacing': ['fvn-normal'],
3242
+ 'fvn-fraction': ['fvn-normal'],
3243
+ 'line-clamp': ['display', 'overflow'],
3244
+ rounded: ['rounded-s', 'rounded-e', 'rounded-t', 'rounded-r', 'rounded-b', 'rounded-l', 'rounded-ss', 'rounded-se', 'rounded-ee', 'rounded-es', 'rounded-tl', 'rounded-tr', 'rounded-br', 'rounded-bl'],
3245
+ 'rounded-s': ['rounded-ss', 'rounded-es'],
3246
+ 'rounded-e': ['rounded-se', 'rounded-ee'],
3247
+ 'rounded-t': ['rounded-tl', 'rounded-tr'],
3248
+ 'rounded-r': ['rounded-tr', 'rounded-br'],
3249
+ 'rounded-b': ['rounded-br', 'rounded-bl'],
3250
+ 'rounded-l': ['rounded-tl', 'rounded-bl'],
3251
+ 'border-spacing': ['border-spacing-x', 'border-spacing-y'],
3252
+ 'border-w': ['border-w-x', 'border-w-y', 'border-w-s', 'border-w-e', 'border-w-t', 'border-w-r', 'border-w-b', 'border-w-l'],
3253
+ 'border-w-x': ['border-w-r', 'border-w-l'],
3254
+ 'border-w-y': ['border-w-t', 'border-w-b'],
3255
+ 'border-color': ['border-color-x', 'border-color-y', 'border-color-s', 'border-color-e', 'border-color-t', 'border-color-r', 'border-color-b', 'border-color-l'],
3256
+ 'border-color-x': ['border-color-r', 'border-color-l'],
3257
+ 'border-color-y': ['border-color-t', 'border-color-b'],
3258
+ translate: ['translate-x', 'translate-y', 'translate-none'],
3259
+ 'translate-none': ['translate', 'translate-x', 'translate-y', 'translate-z'],
3260
+ 'scroll-m': ['scroll-mx', 'scroll-my', 'scroll-ms', 'scroll-me', 'scroll-mt', 'scroll-mr', 'scroll-mb', 'scroll-ml'],
3261
+ 'scroll-mx': ['scroll-mr', 'scroll-ml'],
3262
+ 'scroll-my': ['scroll-mt', 'scroll-mb'],
3263
+ 'scroll-p': ['scroll-px', 'scroll-py', 'scroll-ps', 'scroll-pe', 'scroll-pt', 'scroll-pr', 'scroll-pb', 'scroll-pl'],
3264
+ 'scroll-px': ['scroll-pr', 'scroll-pl'],
3265
+ 'scroll-py': ['scroll-pt', 'scroll-pb'],
3266
+ touch: ['touch-x', 'touch-y', 'touch-pz'],
3267
+ 'touch-x': ['touch'],
3268
+ 'touch-y': ['touch'],
3269
+ 'touch-pz': ['touch']
3270
+ },
3271
+ conflictingClassGroupModifiers: {
3272
+ 'font-size': ['leading']
3273
+ },
3274
+ orderSensitiveModifiers: ['*', '**', 'after', 'backdrop', 'before', 'details-content', 'file', 'first-letter', 'first-line', 'marker', 'placeholder', 'selection']
3275
+ };
3276
+ };
3277
+ const twMerge = /*#__PURE__*/createTailwindMerge(getDefaultConfig);
3278
+
3279
+ function cn(...inputs) {
3280
+ return twMerge(clsx(inputs));
3281
+ }
3282
+
3283
+ const buttonVariants = cva("items-center gap-3 justify-center whitespace-nowrap text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none", {
3284
+ variants: {
3285
+ variant: {
3286
+ primary: "bg-action-fill-primary-default text-action-ink-on-primary-normal hover:bg-action-fill-primary-hover",
3287
+ secondary: "border border-input bg-background hover:bg-accent hover:text-accent-foreground",
3288
+ tertiary: "hover:bg-accent hover:text-accent-foreground",
3289
+ },
3290
+ color: {
3291
+ primary: "",
3292
+ positive: "",
3293
+ negative: "",
3294
+ notice: "",
3295
+ info: "",
3296
+ neutral: "",
3297
+ },
3298
+ size: {
3299
+ xsmall: "md:h-[28px] px-3 text-xs rounded-medium",
3300
+ small: "md:h-[32px] px-4 text-xs rounded-medium",
3301
+ medium: "md:h-[36px] px-6 py-2 rounded-medium",
3302
+ large: "md:h-[44px] px-6 text-base rounded-xlarge",
3303
+ },
3304
+ isIconOnly: {
3305
+ true: "aspect-square p-0",
3306
+ false: "",
3307
+ },
3308
+ isLoading: {
3309
+ true: "cursor-not-allowed",
3310
+ false: "",
3311
+ },
3312
+ isDisabled: {
3313
+ true: "cursor-not-allowed",
3314
+ false: "cursor-pointer",
3315
+ },
3316
+ isFullWidth: {
3317
+ true: "flex w-full",
3318
+ false: "flex w-fit",
3319
+ },
3320
+ },
3321
+ compoundVariants: [
3322
+ // Primary variant colors
3323
+ {
3324
+ variant: "primary",
3325
+ color: "primary",
3326
+ class: `bg-action-fill-primary-default text-action-ink-on-primary-normal
3327
+ hover:bg-action-fill-primary-hover
3328
+ disabled:bg-action-fill-primary-disabled
3329
+ disabled:text-action-ink-primary-disabled
3330
+ `,
3331
+ },
3332
+ {
3333
+ variant: "primary",
3334
+ color: "positive",
3335
+ class: `bg-action-fill-positive-default text-action-ink-on-primary-normal
3336
+ hover:bg-action-fill-positive-hover
3337
+ disabled:bg-action-fill-primary-disabled
3338
+ disabled:text-action-ink-primary-disabled
3339
+ `,
3340
+ },
3341
+ {
3342
+ variant: "primary",
3343
+ color: "negative",
3344
+ class: `bg-action-fill-negative-default text-action-ink-on-primary-normal
3345
+ hover:bg-action-fill-negative-hover
3346
+ disabled:bg-action-fill-negative-disabled
3347
+ disabled:text-action-ink-negative-disabled
3348
+ `,
3349
+ },
3350
+ {
3351
+ variant: "primary",
3352
+ color: "notice",
3353
+ class: `bg-action-fill-notice-default text-action-ink-on-primary-normal
3354
+ hover:bg-action-fill-notice-hover
3355
+ disabled:bg-action-fill-notice-disabled
3356
+ disabled:text-action-ink-notice-disabled
3357
+ `,
3358
+ },
3359
+ {
3360
+ variant: "primary",
3361
+ color: "info",
3362
+ class: `bg-action-fill-info-default text-action-ink-on-primary-normal
3363
+ hover:bg-action-fill-info-hover
3364
+ disabled:bg-action-fill-info-disabled
3365
+ disabled:text-action-ink-info-disabled
3366
+ `,
3367
+ },
3368
+ {
3369
+ variant: "primary",
3370
+ color: "neutral",
3371
+ class: `bg-action-fill-neutral-default text-action-ink-on-primary-normal
3372
+ hover:bg-action-fill-neutral-hover
3373
+ disabled:bg-action-fill-neutral-disabled
3374
+ disabled:text-action-ink-neutral-disabled
3375
+ `,
3376
+ },
3377
+ // Secondary variant colors
3378
+ {
3379
+ variant: "secondary",
3380
+ color: "primary",
3381
+ class: `border-action-outline-info-faded text-action-ink-primary-normal hover:border-action-outline-info-faded-hover
3382
+ disabled:bg-action-outline-info-disabled
3383
+ disabled:text-action-ink-primary-disabled
3384
+ disabled:border-action-outline-primary-disabled
3385
+ `,
3386
+ },
3387
+ {
3388
+ variant: "secondary",
3389
+ color: "positive",
3390
+ class: "border-action-outline-positive-faded text-action-ink-positive-normal hover:border-action-outline-positive-faded-hover disabled:bg-action-outline-positive-disabled",
3391
+ },
3392
+ {
3393
+ variant: "secondary",
3394
+ color: "negative",
3395
+ class: "border-action-outline-negative-faded text-action-ink-negative-normal hover:border-action-outline-negative-faded-hover disabled:bg-action-outline-negative-disabled",
3396
+ },
3397
+ {
3398
+ variant: "secondary",
3399
+ color: "notice",
3400
+ class: "border-action-outline-notice-faded text-action-ink-notice-normal hover:border-action-outline-notice-faded-hover disabled:bg-action-outline-notice-disabled",
3401
+ },
3402
+ {
3403
+ variant: "secondary",
3404
+ color: "info",
3405
+ class: "border-action-outline-info-faded text-action-ink-info-normal hover:border-action-outline-info-faded-hover disabled:bg-action-outline-info-disabled",
3406
+ },
3407
+ {
3408
+ variant: "secondary",
3409
+ color: "neutral",
3410
+ class: "border-action-outline-neutral-faded text-action-ink-neutral-normal hover:bg-action-outline-neutral-faded-hover",
3411
+ },
3412
+ // Tertiary variant colors
3413
+ {
3414
+ variant: "tertiary",
3415
+ color: "primary",
3416
+ class: `text-action-ink-primary-normal
3417
+ hover:bg-action-fill-primary-faded
3418
+ disabled:text-action-ink-on-primary-muted
3419
+ `,
3420
+ },
3421
+ {
3422
+ variant: "tertiary",
3423
+ color: "positive",
3424
+ class: `text-action-ink-positive-normal
3425
+ hover:bg-action-fill-positive-faded
3426
+ disabled:text-action-ink-on-positive-muted
3427
+ `,
3428
+ },
3429
+ {
3430
+ variant: "tertiary",
3431
+ color: "negative",
3432
+ class: `text-action-ink-negative-normal
3433
+ hover:bg-action-fill-negative-faded
3434
+ disabled:text-action-ink-on-negative-muted
3435
+ `,
3436
+ },
3437
+ {
3438
+ variant: "tertiary",
3439
+ color: "notice",
3440
+ class: `text-action-ink-notice-normal
3441
+ hover:bg-action-fill-notice-faded
3442
+ disabled:text-action-ink-on-notice-muted
3443
+ `,
3444
+ },
3445
+ {
3446
+ variant: "tertiary",
3447
+ color: "info",
3448
+ class: `text-action-ink-info-normal
3449
+ hover:bg-action-fill-info-faded
3450
+ disabled:text-action-ink-on-notice-muted
3451
+ `,
3452
+ },
3453
+ {
3454
+ variant: "tertiary",
3455
+ color: "neutral",
3456
+ class: `text-action-ink-neutral-normal
3457
+ hover:bg-action-fill-neutral-faded
3458
+ disabled:text-action-ink-on-notice-muted
3459
+ `,
3460
+ },
3461
+ // Icon only sizing
3462
+ {
3463
+ isIconOnly: true,
3464
+ size: "xsmall",
3465
+ class: "h-7 w-7",
3466
+ },
3467
+ {
3468
+ isIconOnly: true,
3469
+ size: "small",
3470
+ class: "h-8 w-8",
3471
+ },
3472
+ {
3473
+ isIconOnly: true,
3474
+ size: "medium",
3475
+ class: "h-9 w-9",
3476
+ },
3477
+ {
3478
+ isIconOnly: true,
3479
+ size: "large",
3480
+ class: "h-10 w-10",
3481
+ },
3482
+ ],
3483
+ defaultVariants: {
3484
+ variant: "primary",
3485
+ color: "primary",
3486
+ size: "medium",
3487
+ isIconOnly: false,
3488
+ isLoading: false,
3489
+ isFullWidth: false,
3490
+ },
3491
+ });
3492
+ const Button = React.forwardRef(({ className, variant = "primary", color = "primary", size, isIconOnly, isLoading, asChild = false, leadingIcon, trailingIcon, isFullWidth = false, children, disabled, ...props }, ref) => {
3493
+ const Comp = asChild ? Slot : "button";
3494
+ const isDisabled = disabled || isLoading || false;
3495
+ const buttonContent = (jsxs(Fragment, { children: [isLoading && !isIconOnly && (jsx(PulseLoader, { color: `var(--color-action-ink-${color}-normal)`, size: 10 })), isLoading && isIconOnly && (jsx(ClipLoader, { color: `var(--color-action-ink-${color}-normal)`, size: 20 })), !isLoading && leadingIcon && (jsx("span", { className: "mr-2", children: leadingIcon })), !isIconOnly && !isLoading && children, isIconOnly && !isLoading && children, !isLoading && trailingIcon && jsx("span", { children: trailingIcon })] }));
3496
+ return (jsx(Comp, { className: cn(buttonVariants({
3497
+ variant,
3498
+ color,
3499
+ size,
3500
+ isIconOnly,
3501
+ isLoading,
3502
+ isDisabled,
3503
+ isFullWidth,
3504
+ }), className), ref: ref, disabled: isDisabled, ...props, children: buttonContent }));
3505
+ });
3506
+ Button.displayName = "Button";
12
3507
 
13
- export { Button };
3508
+ export { Button, buttonVariants };
14
3509
  //# sourceMappingURL=index.esm.js.map