design-system-silkhaus 0.0.0 → 0.0.2

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.cjs DELETED
@@ -1,2543 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
-
5
- const jsxRuntime = require('react/jsx-runtime');
6
- const React = require('react');
7
-
8
- 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}
9
-
10
- const CLASS_PART_SEPARATOR = '-';
11
- function createClassUtils(config) {
12
- const classMap = createClassMap(config);
13
- const {
14
- conflictingClassGroups,
15
- conflictingClassGroupModifiers
16
- } = config;
17
- function getClassGroupId(className) {
18
- const classParts = className.split(CLASS_PART_SEPARATOR);
19
- // 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.
20
- if (classParts[0] === '' && classParts.length !== 1) {
21
- classParts.shift();
22
- }
23
- return getGroupRecursive(classParts, classMap) || getGroupIdForArbitraryProperty(className);
24
- }
25
- function getConflictingClassGroupIds(classGroupId, hasPostfixModifier) {
26
- const conflicts = conflictingClassGroups[classGroupId] || [];
27
- if (hasPostfixModifier && conflictingClassGroupModifiers[classGroupId]) {
28
- return [...conflicts, ...conflictingClassGroupModifiers[classGroupId]];
29
- }
30
- return conflicts;
31
- }
32
- return {
33
- getClassGroupId,
34
- getConflictingClassGroupIds
35
- };
36
- }
37
- function getGroupRecursive(classParts, classPartObject) {
38
- if (classParts.length === 0) {
39
- return classPartObject.classGroupId;
40
- }
41
- const currentClassPart = classParts[0];
42
- const nextClassPartObject = classPartObject.nextPart.get(currentClassPart);
43
- const classGroupFromNextClassPart = nextClassPartObject ? getGroupRecursive(classParts.slice(1), nextClassPartObject) : undefined;
44
- if (classGroupFromNextClassPart) {
45
- return classGroupFromNextClassPart;
46
- }
47
- if (classPartObject.validators.length === 0) {
48
- return undefined;
49
- }
50
- const classRest = classParts.join(CLASS_PART_SEPARATOR);
51
- return classPartObject.validators.find(({
52
- validator
53
- }) => validator(classRest))?.classGroupId;
54
- }
55
- const arbitraryPropertyRegex = /^\[(.+)\]$/;
56
- function getGroupIdForArbitraryProperty(className) {
57
- if (arbitraryPropertyRegex.test(className)) {
58
- const arbitraryPropertyClassName = arbitraryPropertyRegex.exec(className)[1];
59
- const property = arbitraryPropertyClassName?.substring(0, arbitraryPropertyClassName.indexOf(':'));
60
- if (property) {
61
- // I use two dots here because one dot is used as prefix for class groups in plugins
62
- return 'arbitrary..' + property;
63
- }
64
- }
65
- }
66
- /**
67
- * Exported for testing only
68
- */
69
- function createClassMap(config) {
70
- const {
71
- theme,
72
- prefix
73
- } = config;
74
- const classMap = {
75
- nextPart: new Map(),
76
- validators: []
77
- };
78
- const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(config.classGroups), prefix);
79
- prefixedClassGroupEntries.forEach(([classGroupId, classGroup]) => {
80
- processClassesRecursively(classGroup, classMap, classGroupId, theme);
81
- });
82
- return classMap;
83
- }
84
- function processClassesRecursively(classGroup, classPartObject, classGroupId, theme) {
85
- classGroup.forEach(classDefinition => {
86
- if (typeof classDefinition === 'string') {
87
- const classPartObjectToEdit = classDefinition === '' ? classPartObject : getPart(classPartObject, classDefinition);
88
- classPartObjectToEdit.classGroupId = classGroupId;
89
- return;
90
- }
91
- if (typeof classDefinition === 'function') {
92
- if (isThemeGetter(classDefinition)) {
93
- processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);
94
- return;
95
- }
96
- classPartObject.validators.push({
97
- validator: classDefinition,
98
- classGroupId
99
- });
100
- return;
101
- }
102
- Object.entries(classDefinition).forEach(([key, classGroup]) => {
103
- processClassesRecursively(classGroup, getPart(classPartObject, key), classGroupId, theme);
104
- });
105
- });
106
- }
107
- function getPart(classPartObject, path) {
108
- let currentClassPartObject = classPartObject;
109
- path.split(CLASS_PART_SEPARATOR).forEach(pathPart => {
110
- if (!currentClassPartObject.nextPart.has(pathPart)) {
111
- currentClassPartObject.nextPart.set(pathPart, {
112
- nextPart: new Map(),
113
- validators: []
114
- });
115
- }
116
- currentClassPartObject = currentClassPartObject.nextPart.get(pathPart);
117
- });
118
- return currentClassPartObject;
119
- }
120
- function isThemeGetter(func) {
121
- return func.isThemeGetter;
122
- }
123
- function getPrefixedClassGroupEntries(classGroupEntries, prefix) {
124
- if (!prefix) {
125
- return classGroupEntries;
126
- }
127
- return classGroupEntries.map(([classGroupId, classGroup]) => {
128
- const prefixedClassGroup = classGroup.map(classDefinition => {
129
- if (typeof classDefinition === 'string') {
130
- return prefix + classDefinition;
131
- }
132
- if (typeof classDefinition === 'object') {
133
- return Object.fromEntries(Object.entries(classDefinition).map(([key, value]) => [prefix + key, value]));
134
- }
135
- return classDefinition;
136
- });
137
- return [classGroupId, prefixedClassGroup];
138
- });
139
- }
140
-
141
- // LRU cache inspired from hashlru (https://github.com/dominictarr/hashlru/blob/v1.0.4/index.js) but object replaced with Map to improve performance
142
- function createLruCache(maxCacheSize) {
143
- if (maxCacheSize < 1) {
144
- return {
145
- get: () => undefined,
146
- set: () => {}
147
- };
148
- }
149
- let cacheSize = 0;
150
- let cache = new Map();
151
- let previousCache = new Map();
152
- function update(key, value) {
153
- cache.set(key, value);
154
- cacheSize++;
155
- if (cacheSize > maxCacheSize) {
156
- cacheSize = 0;
157
- previousCache = cache;
158
- cache = new Map();
159
- }
160
- }
161
- return {
162
- get(key) {
163
- let value = cache.get(key);
164
- if (value !== undefined) {
165
- return value;
166
- }
167
- if ((value = previousCache.get(key)) !== undefined) {
168
- update(key, value);
169
- return value;
170
- }
171
- },
172
- set(key, value) {
173
- if (cache.has(key)) {
174
- cache.set(key, value);
175
- } else {
176
- update(key, value);
177
- }
178
- }
179
- };
180
- }
181
- const IMPORTANT_MODIFIER = '!';
182
- function createSplitModifiers(config) {
183
- const separator = config.separator;
184
- const isSeparatorSingleCharacter = separator.length === 1;
185
- const firstSeparatorCharacter = separator[0];
186
- const separatorLength = separator.length;
187
- // splitModifiers inspired by https://github.com/tailwindlabs/tailwindcss/blob/v3.2.2/src/util/splitAtTopLevelOnly.js
188
- return function splitModifiers(className) {
189
- const modifiers = [];
190
- let bracketDepth = 0;
191
- let modifierStart = 0;
192
- let postfixModifierPosition;
193
- for (let index = 0; index < className.length; index++) {
194
- let currentCharacter = className[index];
195
- if (bracketDepth === 0) {
196
- if (currentCharacter === firstSeparatorCharacter && (isSeparatorSingleCharacter || className.slice(index, index + separatorLength) === separator)) {
197
- modifiers.push(className.slice(modifierStart, index));
198
- modifierStart = index + separatorLength;
199
- continue;
200
- }
201
- if (currentCharacter === '/') {
202
- postfixModifierPosition = index;
203
- continue;
204
- }
205
- }
206
- if (currentCharacter === '[') {
207
- bracketDepth++;
208
- } else if (currentCharacter === ']') {
209
- bracketDepth--;
210
- }
211
- }
212
- const baseClassNameWithImportantModifier = modifiers.length === 0 ? className : className.substring(modifierStart);
213
- const hasImportantModifier = baseClassNameWithImportantModifier.startsWith(IMPORTANT_MODIFIER);
214
- const baseClassName = hasImportantModifier ? baseClassNameWithImportantModifier.substring(1) : baseClassNameWithImportantModifier;
215
- const maybePostfixModifierPosition = postfixModifierPosition && postfixModifierPosition > modifierStart ? postfixModifierPosition - modifierStart : undefined;
216
- return {
217
- modifiers,
218
- hasImportantModifier,
219
- baseClassName,
220
- maybePostfixModifierPosition
221
- };
222
- };
223
- }
224
- /**
225
- * Sorts modifiers according to following schema:
226
- * - Predefined modifiers are sorted alphabetically
227
- * - When an arbitrary variant appears, it must be preserved which modifiers are before and after it
228
- */
229
- function sortModifiers(modifiers) {
230
- if (modifiers.length <= 1) {
231
- return modifiers;
232
- }
233
- const sortedModifiers = [];
234
- let unsortedModifiers = [];
235
- modifiers.forEach(modifier => {
236
- const isArbitraryVariant = modifier[0] === '[';
237
- if (isArbitraryVariant) {
238
- sortedModifiers.push(...unsortedModifiers.sort(), modifier);
239
- unsortedModifiers = [];
240
- } else {
241
- unsortedModifiers.push(modifier);
242
- }
243
- });
244
- sortedModifiers.push(...unsortedModifiers.sort());
245
- return sortedModifiers;
246
- }
247
- function createConfigUtils(config) {
248
- return {
249
- cache: createLruCache(config.cacheSize),
250
- splitModifiers: createSplitModifiers(config),
251
- ...createClassUtils(config)
252
- };
253
- }
254
- const SPLIT_CLASSES_REGEX = /\s+/;
255
- function mergeClassList(classList, configUtils) {
256
- const {
257
- splitModifiers,
258
- getClassGroupId,
259
- getConflictingClassGroupIds
260
- } = configUtils;
261
- /**
262
- * Set of classGroupIds in following format:
263
- * `{importantModifier}{variantModifiers}{classGroupId}`
264
- * @example 'float'
265
- * @example 'hover:focus:bg-color'
266
- * @example 'md:!pr'
267
- */
268
- const classGroupsInConflict = new Set();
269
- return classList.trim().split(SPLIT_CLASSES_REGEX).map(originalClassName => {
270
- const {
271
- modifiers,
272
- hasImportantModifier,
273
- baseClassName,
274
- maybePostfixModifierPosition
275
- } = splitModifiers(originalClassName);
276
- let classGroupId = getClassGroupId(maybePostfixModifierPosition ? baseClassName.substring(0, maybePostfixModifierPosition) : baseClassName);
277
- let hasPostfixModifier = Boolean(maybePostfixModifierPosition);
278
- if (!classGroupId) {
279
- if (!maybePostfixModifierPosition) {
280
- return {
281
- isTailwindClass: false,
282
- originalClassName
283
- };
284
- }
285
- classGroupId = getClassGroupId(baseClassName);
286
- if (!classGroupId) {
287
- return {
288
- isTailwindClass: false,
289
- originalClassName
290
- };
291
- }
292
- hasPostfixModifier = false;
293
- }
294
- const variantModifier = sortModifiers(modifiers).join(':');
295
- const modifierId = hasImportantModifier ? variantModifier + IMPORTANT_MODIFIER : variantModifier;
296
- return {
297
- isTailwindClass: true,
298
- modifierId,
299
- classGroupId,
300
- originalClassName,
301
- hasPostfixModifier
302
- };
303
- }).reverse()
304
- // Last class in conflict wins, so we need to filter conflicting classes in reverse order.
305
- .filter(parsed => {
306
- if (!parsed.isTailwindClass) {
307
- return true;
308
- }
309
- const {
310
- modifierId,
311
- classGroupId,
312
- hasPostfixModifier
313
- } = parsed;
314
- const classId = modifierId + classGroupId;
315
- if (classGroupsInConflict.has(classId)) {
316
- return false;
317
- }
318
- classGroupsInConflict.add(classId);
319
- getConflictingClassGroupIds(classGroupId, hasPostfixModifier).forEach(group => classGroupsInConflict.add(modifierId + group));
320
- return true;
321
- }).reverse().map(parsed => parsed.originalClassName).join(' ');
322
- }
323
-
324
- /**
325
- * The code in this file is copied from https://github.com/lukeed/clsx and modified to suit the needs of tailwind-merge better.
326
- *
327
- * Specifically:
328
- * - Runtime code from https://github.com/lukeed/clsx/blob/v1.2.1/src/index.js
329
- * - TypeScript types from https://github.com/lukeed/clsx/blob/v1.2.1/clsx.d.ts
330
- *
331
- * Original code has MIT license: Copyright (c) Luke Edwards <luke.edwards05@gmail.com> (lukeed.com)
332
- */
333
- function twJoin() {
334
- let index = 0;
335
- let argument;
336
- let resolvedValue;
337
- let string = '';
338
- while (index < arguments.length) {
339
- if (argument = arguments[index++]) {
340
- if (resolvedValue = toValue(argument)) {
341
- string && (string += ' ');
342
- string += resolvedValue;
343
- }
344
- }
345
- }
346
- return string;
347
- }
348
- function toValue(mix) {
349
- if (typeof mix === 'string') {
350
- return mix;
351
- }
352
- let resolvedValue;
353
- let string = '';
354
- for (let k = 0; k < mix.length; k++) {
355
- if (mix[k]) {
356
- if (resolvedValue = toValue(mix[k])) {
357
- string && (string += ' ');
358
- string += resolvedValue;
359
- }
360
- }
361
- }
362
- return string;
363
- }
364
- function createTailwindMerge(createConfigFirst, ...createConfigRest) {
365
- let configUtils;
366
- let cacheGet;
367
- let cacheSet;
368
- let functionToCall = initTailwindMerge;
369
- function initTailwindMerge(classList) {
370
- const config = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());
371
- configUtils = createConfigUtils(config);
372
- cacheGet = configUtils.cache.get;
373
- cacheSet = configUtils.cache.set;
374
- functionToCall = tailwindMerge;
375
- return tailwindMerge(classList);
376
- }
377
- function tailwindMerge(classList) {
378
- const cachedResult = cacheGet(classList);
379
- if (cachedResult) {
380
- return cachedResult;
381
- }
382
- const result = mergeClassList(classList, configUtils);
383
- cacheSet(classList, result);
384
- return result;
385
- }
386
- return function callTailwindMerge() {
387
- return functionToCall(twJoin.apply(null, arguments));
388
- };
389
- }
390
- function fromTheme(key) {
391
- const themeGetter = theme => theme[key] || [];
392
- themeGetter.isThemeGetter = true;
393
- return themeGetter;
394
- }
395
- const arbitraryValueRegex = /^\[(?:([a-z-]+):)?(.+)\]$/i;
396
- const fractionRegex = /^\d+\/\d+$/;
397
- const stringLengths = /*#__PURE__*/new Set(['px', 'full', 'screen']);
398
- const tshirtUnitRegex = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/;
399
- 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$/;
400
- // Shadow always begins with x and y offset separated by underscore
401
- const shadowRegex = /^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;
402
- const imageRegex = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;
403
- function isLength(value) {
404
- return isNumber(value) || stringLengths.has(value) || fractionRegex.test(value);
405
- }
406
- function isArbitraryLength(value) {
407
- return getIsArbitraryValue(value, 'length', isLengthOnly);
408
- }
409
- function isNumber(value) {
410
- return Boolean(value) && !Number.isNaN(Number(value));
411
- }
412
- function isArbitraryNumber(value) {
413
- return getIsArbitraryValue(value, 'number', isNumber);
414
- }
415
- function isInteger(value) {
416
- return Boolean(value) && Number.isInteger(Number(value));
417
- }
418
- function isPercent(value) {
419
- return value.endsWith('%') && isNumber(value.slice(0, -1));
420
- }
421
- function isArbitraryValue(value) {
422
- return arbitraryValueRegex.test(value);
423
- }
424
- function isTshirtSize(value) {
425
- return tshirtUnitRegex.test(value);
426
- }
427
- const sizeLabels = /*#__PURE__*/new Set(['length', 'size', 'percentage']);
428
- function isArbitrarySize(value) {
429
- return getIsArbitraryValue(value, sizeLabels, isNever);
430
- }
431
- function isArbitraryPosition(value) {
432
- return getIsArbitraryValue(value, 'position', isNever);
433
- }
434
- const imageLabels = /*#__PURE__*/new Set(['image', 'url']);
435
- function isArbitraryImage(value) {
436
- return getIsArbitraryValue(value, imageLabels, isImage);
437
- }
438
- function isArbitraryShadow(value) {
439
- return getIsArbitraryValue(value, '', isShadow);
440
- }
441
- function isAny() {
442
- return true;
443
- }
444
- function getIsArbitraryValue(value, label, testValue) {
445
- const result = arbitraryValueRegex.exec(value);
446
- if (result) {
447
- if (result[1]) {
448
- return typeof label === 'string' ? result[1] === label : label.has(result[1]);
449
- }
450
- return testValue(result[2]);
451
- }
452
- return false;
453
- }
454
- function isLengthOnly(value) {
455
- return lengthUnitRegex.test(value);
456
- }
457
- function isNever() {
458
- return false;
459
- }
460
- function isShadow(value) {
461
- return shadowRegex.test(value);
462
- }
463
- function isImage(value) {
464
- return imageRegex.test(value);
465
- }
466
- function getDefaultConfig() {
467
- const colors = fromTheme('colors');
468
- const spacing = fromTheme('spacing');
469
- const blur = fromTheme('blur');
470
- const brightness = fromTheme('brightness');
471
- const borderColor = fromTheme('borderColor');
472
- const borderRadius = fromTheme('borderRadius');
473
- const borderSpacing = fromTheme('borderSpacing');
474
- const borderWidth = fromTheme('borderWidth');
475
- const contrast = fromTheme('contrast');
476
- const grayscale = fromTheme('grayscale');
477
- const hueRotate = fromTheme('hueRotate');
478
- const invert = fromTheme('invert');
479
- const gap = fromTheme('gap');
480
- const gradientColorStops = fromTheme('gradientColorStops');
481
- const gradientColorStopPositions = fromTheme('gradientColorStopPositions');
482
- const inset = fromTheme('inset');
483
- const margin = fromTheme('margin');
484
- const opacity = fromTheme('opacity');
485
- const padding = fromTheme('padding');
486
- const saturate = fromTheme('saturate');
487
- const scale = fromTheme('scale');
488
- const sepia = fromTheme('sepia');
489
- const skew = fromTheme('skew');
490
- const space = fromTheme('space');
491
- const translate = fromTheme('translate');
492
- const getOverscroll = () => ['auto', 'contain', 'none'];
493
- const getOverflow = () => ['auto', 'hidden', 'clip', 'visible', 'scroll'];
494
- const getSpacingWithAutoAndArbitrary = () => ['auto', isArbitraryValue, spacing];
495
- const getSpacingWithArbitrary = () => [isArbitraryValue, spacing];
496
- const getLengthWithEmptyAndArbitrary = () => ['', isLength, isArbitraryLength];
497
- const getNumberWithAutoAndArbitrary = () => ['auto', isNumber, isArbitraryValue];
498
- const getPositions = () => ['bottom', 'center', 'left', 'left-bottom', 'left-top', 'right', 'right-bottom', 'right-top', 'top'];
499
- const getLineStyles = () => ['solid', 'dashed', 'dotted', 'double', 'none'];
500
- const getBlendModes = () => ['normal', 'multiply', 'screen', 'overlay', 'darken', 'lighten', 'color-dodge', 'color-burn', 'hard-light', 'soft-light', 'difference', 'exclusion', 'hue', 'saturation', 'color', 'luminosity', 'plus-lighter'];
501
- const getAlign = () => ['start', 'end', 'center', 'between', 'around', 'evenly', 'stretch'];
502
- const getZeroAndEmpty = () => ['', '0', isArbitraryValue];
503
- const getBreaks = () => ['auto', 'avoid', 'all', 'avoid-page', 'page', 'left', 'right', 'column'];
504
- const getNumber = () => [isNumber, isArbitraryNumber];
505
- const getNumberAndArbitrary = () => [isNumber, isArbitraryValue];
506
- return {
507
- cacheSize: 500,
508
- separator: ':',
509
- theme: {
510
- colors: [isAny],
511
- spacing: [isLength, isArbitraryLength],
512
- blur: ['none', '', isTshirtSize, isArbitraryValue],
513
- brightness: getNumber(),
514
- borderColor: [colors],
515
- borderRadius: ['none', '', 'full', isTshirtSize, isArbitraryValue],
516
- borderSpacing: getSpacingWithArbitrary(),
517
- borderWidth: getLengthWithEmptyAndArbitrary(),
518
- contrast: getNumber(),
519
- grayscale: getZeroAndEmpty(),
520
- hueRotate: getNumberAndArbitrary(),
521
- invert: getZeroAndEmpty(),
522
- gap: getSpacingWithArbitrary(),
523
- gradientColorStops: [colors],
524
- gradientColorStopPositions: [isPercent, isArbitraryLength],
525
- inset: getSpacingWithAutoAndArbitrary(),
526
- margin: getSpacingWithAutoAndArbitrary(),
527
- opacity: getNumber(),
528
- padding: getSpacingWithArbitrary(),
529
- saturate: getNumber(),
530
- scale: getNumber(),
531
- sepia: getZeroAndEmpty(),
532
- skew: getNumberAndArbitrary(),
533
- space: getSpacingWithArbitrary(),
534
- translate: getSpacingWithArbitrary()
535
- },
536
- classGroups: {
537
- // Layout
538
- /**
539
- * Aspect Ratio
540
- * @see https://tailwindcss.com/docs/aspect-ratio
541
- */
542
- aspect: [{
543
- aspect: ['auto', 'square', 'video', isArbitraryValue]
544
- }],
545
- /**
546
- * Container
547
- * @see https://tailwindcss.com/docs/container
548
- */
549
- container: ['container'],
550
- /**
551
- * Columns
552
- * @see https://tailwindcss.com/docs/columns
553
- */
554
- columns: [{
555
- columns: [isTshirtSize]
556
- }],
557
- /**
558
- * Break After
559
- * @see https://tailwindcss.com/docs/break-after
560
- */
561
- 'break-after': [{
562
- 'break-after': getBreaks()
563
- }],
564
- /**
565
- * Break Before
566
- * @see https://tailwindcss.com/docs/break-before
567
- */
568
- 'break-before': [{
569
- 'break-before': getBreaks()
570
- }],
571
- /**
572
- * Break Inside
573
- * @see https://tailwindcss.com/docs/break-inside
574
- */
575
- 'break-inside': [{
576
- 'break-inside': ['auto', 'avoid', 'avoid-page', 'avoid-column']
577
- }],
578
- /**
579
- * Box Decoration Break
580
- * @see https://tailwindcss.com/docs/box-decoration-break
581
- */
582
- 'box-decoration': [{
583
- 'box-decoration': ['slice', 'clone']
584
- }],
585
- /**
586
- * Box Sizing
587
- * @see https://tailwindcss.com/docs/box-sizing
588
- */
589
- box: [{
590
- box: ['border', 'content']
591
- }],
592
- /**
593
- * Display
594
- * @see https://tailwindcss.com/docs/display
595
- */
596
- 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'],
597
- /**
598
- * Floats
599
- * @see https://tailwindcss.com/docs/float
600
- */
601
- float: [{
602
- float: ['right', 'left', 'none', 'start', 'end']
603
- }],
604
- /**
605
- * Clear
606
- * @see https://tailwindcss.com/docs/clear
607
- */
608
- clear: [{
609
- clear: ['left', 'right', 'both', 'none', 'start', 'end']
610
- }],
611
- /**
612
- * Isolation
613
- * @see https://tailwindcss.com/docs/isolation
614
- */
615
- isolation: ['isolate', 'isolation-auto'],
616
- /**
617
- * Object Fit
618
- * @see https://tailwindcss.com/docs/object-fit
619
- */
620
- 'object-fit': [{
621
- object: ['contain', 'cover', 'fill', 'none', 'scale-down']
622
- }],
623
- /**
624
- * Object Position
625
- * @see https://tailwindcss.com/docs/object-position
626
- */
627
- 'object-position': [{
628
- object: [...getPositions(), isArbitraryValue]
629
- }],
630
- /**
631
- * Overflow
632
- * @see https://tailwindcss.com/docs/overflow
633
- */
634
- overflow: [{
635
- overflow: getOverflow()
636
- }],
637
- /**
638
- * Overflow X
639
- * @see https://tailwindcss.com/docs/overflow
640
- */
641
- 'overflow-x': [{
642
- 'overflow-x': getOverflow()
643
- }],
644
- /**
645
- * Overflow Y
646
- * @see https://tailwindcss.com/docs/overflow
647
- */
648
- 'overflow-y': [{
649
- 'overflow-y': getOverflow()
650
- }],
651
- /**
652
- * Overscroll Behavior
653
- * @see https://tailwindcss.com/docs/overscroll-behavior
654
- */
655
- overscroll: [{
656
- overscroll: getOverscroll()
657
- }],
658
- /**
659
- * Overscroll Behavior X
660
- * @see https://tailwindcss.com/docs/overscroll-behavior
661
- */
662
- 'overscroll-x': [{
663
- 'overscroll-x': getOverscroll()
664
- }],
665
- /**
666
- * Overscroll Behavior Y
667
- * @see https://tailwindcss.com/docs/overscroll-behavior
668
- */
669
- 'overscroll-y': [{
670
- 'overscroll-y': getOverscroll()
671
- }],
672
- /**
673
- * Position
674
- * @see https://tailwindcss.com/docs/position
675
- */
676
- position: ['static', 'fixed', 'absolute', 'relative', 'sticky'],
677
- /**
678
- * Top / Right / Bottom / Left
679
- * @see https://tailwindcss.com/docs/top-right-bottom-left
680
- */
681
- inset: [{
682
- inset: [inset]
683
- }],
684
- /**
685
- * Right / Left
686
- * @see https://tailwindcss.com/docs/top-right-bottom-left
687
- */
688
- 'inset-x': [{
689
- 'inset-x': [inset]
690
- }],
691
- /**
692
- * Top / Bottom
693
- * @see https://tailwindcss.com/docs/top-right-bottom-left
694
- */
695
- 'inset-y': [{
696
- 'inset-y': [inset]
697
- }],
698
- /**
699
- * Start
700
- * @see https://tailwindcss.com/docs/top-right-bottom-left
701
- */
702
- start: [{
703
- start: [inset]
704
- }],
705
- /**
706
- * End
707
- * @see https://tailwindcss.com/docs/top-right-bottom-left
708
- */
709
- end: [{
710
- end: [inset]
711
- }],
712
- /**
713
- * Top
714
- * @see https://tailwindcss.com/docs/top-right-bottom-left
715
- */
716
- top: [{
717
- top: [inset]
718
- }],
719
- /**
720
- * Right
721
- * @see https://tailwindcss.com/docs/top-right-bottom-left
722
- */
723
- right: [{
724
- right: [inset]
725
- }],
726
- /**
727
- * Bottom
728
- * @see https://tailwindcss.com/docs/top-right-bottom-left
729
- */
730
- bottom: [{
731
- bottom: [inset]
732
- }],
733
- /**
734
- * Left
735
- * @see https://tailwindcss.com/docs/top-right-bottom-left
736
- */
737
- left: [{
738
- left: [inset]
739
- }],
740
- /**
741
- * Visibility
742
- * @see https://tailwindcss.com/docs/visibility
743
- */
744
- visibility: ['visible', 'invisible', 'collapse'],
745
- /**
746
- * Z-Index
747
- * @see https://tailwindcss.com/docs/z-index
748
- */
749
- z: [{
750
- z: ['auto', isInteger, isArbitraryValue]
751
- }],
752
- // Flexbox and Grid
753
- /**
754
- * Flex Basis
755
- * @see https://tailwindcss.com/docs/flex-basis
756
- */
757
- basis: [{
758
- basis: getSpacingWithAutoAndArbitrary()
759
- }],
760
- /**
761
- * Flex Direction
762
- * @see https://tailwindcss.com/docs/flex-direction
763
- */
764
- 'flex-direction': [{
765
- flex: ['row', 'row-reverse', 'col', 'col-reverse']
766
- }],
767
- /**
768
- * Flex Wrap
769
- * @see https://tailwindcss.com/docs/flex-wrap
770
- */
771
- 'flex-wrap': [{
772
- flex: ['wrap', 'wrap-reverse', 'nowrap']
773
- }],
774
- /**
775
- * Flex
776
- * @see https://tailwindcss.com/docs/flex
777
- */
778
- flex: [{
779
- flex: ['1', 'auto', 'initial', 'none', isArbitraryValue]
780
- }],
781
- /**
782
- * Flex Grow
783
- * @see https://tailwindcss.com/docs/flex-grow
784
- */
785
- grow: [{
786
- grow: getZeroAndEmpty()
787
- }],
788
- /**
789
- * Flex Shrink
790
- * @see https://tailwindcss.com/docs/flex-shrink
791
- */
792
- shrink: [{
793
- shrink: getZeroAndEmpty()
794
- }],
795
- /**
796
- * Order
797
- * @see https://tailwindcss.com/docs/order
798
- */
799
- order: [{
800
- order: ['first', 'last', 'none', isInteger, isArbitraryValue]
801
- }],
802
- /**
803
- * Grid Template Columns
804
- * @see https://tailwindcss.com/docs/grid-template-columns
805
- */
806
- 'grid-cols': [{
807
- 'grid-cols': [isAny]
808
- }],
809
- /**
810
- * Grid Column Start / End
811
- * @see https://tailwindcss.com/docs/grid-column
812
- */
813
- 'col-start-end': [{
814
- col: ['auto', {
815
- span: ['full', isInteger, isArbitraryValue]
816
- }, isArbitraryValue]
817
- }],
818
- /**
819
- * Grid Column Start
820
- * @see https://tailwindcss.com/docs/grid-column
821
- */
822
- 'col-start': [{
823
- 'col-start': getNumberWithAutoAndArbitrary()
824
- }],
825
- /**
826
- * Grid Column End
827
- * @see https://tailwindcss.com/docs/grid-column
828
- */
829
- 'col-end': [{
830
- 'col-end': getNumberWithAutoAndArbitrary()
831
- }],
832
- /**
833
- * Grid Template Rows
834
- * @see https://tailwindcss.com/docs/grid-template-rows
835
- */
836
- 'grid-rows': [{
837
- 'grid-rows': [isAny]
838
- }],
839
- /**
840
- * Grid Row Start / End
841
- * @see https://tailwindcss.com/docs/grid-row
842
- */
843
- 'row-start-end': [{
844
- row: ['auto', {
845
- span: [isInteger, isArbitraryValue]
846
- }, isArbitraryValue]
847
- }],
848
- /**
849
- * Grid Row Start
850
- * @see https://tailwindcss.com/docs/grid-row
851
- */
852
- 'row-start': [{
853
- 'row-start': getNumberWithAutoAndArbitrary()
854
- }],
855
- /**
856
- * Grid Row End
857
- * @see https://tailwindcss.com/docs/grid-row
858
- */
859
- 'row-end': [{
860
- 'row-end': getNumberWithAutoAndArbitrary()
861
- }],
862
- /**
863
- * Grid Auto Flow
864
- * @see https://tailwindcss.com/docs/grid-auto-flow
865
- */
866
- 'grid-flow': [{
867
- 'grid-flow': ['row', 'col', 'dense', 'row-dense', 'col-dense']
868
- }],
869
- /**
870
- * Grid Auto Columns
871
- * @see https://tailwindcss.com/docs/grid-auto-columns
872
- */
873
- 'auto-cols': [{
874
- 'auto-cols': ['auto', 'min', 'max', 'fr', isArbitraryValue]
875
- }],
876
- /**
877
- * Grid Auto Rows
878
- * @see https://tailwindcss.com/docs/grid-auto-rows
879
- */
880
- 'auto-rows': [{
881
- 'auto-rows': ['auto', 'min', 'max', 'fr', isArbitraryValue]
882
- }],
883
- /**
884
- * Gap
885
- * @see https://tailwindcss.com/docs/gap
886
- */
887
- gap: [{
888
- gap: [gap]
889
- }],
890
- /**
891
- * Gap X
892
- * @see https://tailwindcss.com/docs/gap
893
- */
894
- 'gap-x': [{
895
- 'gap-x': [gap]
896
- }],
897
- /**
898
- * Gap Y
899
- * @see https://tailwindcss.com/docs/gap
900
- */
901
- 'gap-y': [{
902
- 'gap-y': [gap]
903
- }],
904
- /**
905
- * Justify Content
906
- * @see https://tailwindcss.com/docs/justify-content
907
- */
908
- 'justify-content': [{
909
- justify: ['normal', ...getAlign()]
910
- }],
911
- /**
912
- * Justify Items
913
- * @see https://tailwindcss.com/docs/justify-items
914
- */
915
- 'justify-items': [{
916
- 'justify-items': ['start', 'end', 'center', 'stretch']
917
- }],
918
- /**
919
- * Justify Self
920
- * @see https://tailwindcss.com/docs/justify-self
921
- */
922
- 'justify-self': [{
923
- 'justify-self': ['auto', 'start', 'end', 'center', 'stretch']
924
- }],
925
- /**
926
- * Align Content
927
- * @see https://tailwindcss.com/docs/align-content
928
- */
929
- 'align-content': [{
930
- content: ['normal', ...getAlign(), 'baseline']
931
- }],
932
- /**
933
- * Align Items
934
- * @see https://tailwindcss.com/docs/align-items
935
- */
936
- 'align-items': [{
937
- items: ['start', 'end', 'center', 'baseline', 'stretch']
938
- }],
939
- /**
940
- * Align Self
941
- * @see https://tailwindcss.com/docs/align-self
942
- */
943
- 'align-self': [{
944
- self: ['auto', 'start', 'end', 'center', 'stretch', 'baseline']
945
- }],
946
- /**
947
- * Place Content
948
- * @see https://tailwindcss.com/docs/place-content
949
- */
950
- 'place-content': [{
951
- 'place-content': [...getAlign(), 'baseline']
952
- }],
953
- /**
954
- * Place Items
955
- * @see https://tailwindcss.com/docs/place-items
956
- */
957
- 'place-items': [{
958
- 'place-items': ['start', 'end', 'center', 'baseline', 'stretch']
959
- }],
960
- /**
961
- * Place Self
962
- * @see https://tailwindcss.com/docs/place-self
963
- */
964
- 'place-self': [{
965
- 'place-self': ['auto', 'start', 'end', 'center', 'stretch']
966
- }],
967
- // Spacing
968
- /**
969
- * Padding
970
- * @see https://tailwindcss.com/docs/padding
971
- */
972
- p: [{
973
- p: [padding]
974
- }],
975
- /**
976
- * Padding X
977
- * @see https://tailwindcss.com/docs/padding
978
- */
979
- px: [{
980
- px: [padding]
981
- }],
982
- /**
983
- * Padding Y
984
- * @see https://tailwindcss.com/docs/padding
985
- */
986
- py: [{
987
- py: [padding]
988
- }],
989
- /**
990
- * Padding Start
991
- * @see https://tailwindcss.com/docs/padding
992
- */
993
- ps: [{
994
- ps: [padding]
995
- }],
996
- /**
997
- * Padding End
998
- * @see https://tailwindcss.com/docs/padding
999
- */
1000
- pe: [{
1001
- pe: [padding]
1002
- }],
1003
- /**
1004
- * Padding Top
1005
- * @see https://tailwindcss.com/docs/padding
1006
- */
1007
- pt: [{
1008
- pt: [padding]
1009
- }],
1010
- /**
1011
- * Padding Right
1012
- * @see https://tailwindcss.com/docs/padding
1013
- */
1014
- pr: [{
1015
- pr: [padding]
1016
- }],
1017
- /**
1018
- * Padding Bottom
1019
- * @see https://tailwindcss.com/docs/padding
1020
- */
1021
- pb: [{
1022
- pb: [padding]
1023
- }],
1024
- /**
1025
- * Padding Left
1026
- * @see https://tailwindcss.com/docs/padding
1027
- */
1028
- pl: [{
1029
- pl: [padding]
1030
- }],
1031
- /**
1032
- * Margin
1033
- * @see https://tailwindcss.com/docs/margin
1034
- */
1035
- m: [{
1036
- m: [margin]
1037
- }],
1038
- /**
1039
- * Margin X
1040
- * @see https://tailwindcss.com/docs/margin
1041
- */
1042
- mx: [{
1043
- mx: [margin]
1044
- }],
1045
- /**
1046
- * Margin Y
1047
- * @see https://tailwindcss.com/docs/margin
1048
- */
1049
- my: [{
1050
- my: [margin]
1051
- }],
1052
- /**
1053
- * Margin Start
1054
- * @see https://tailwindcss.com/docs/margin
1055
- */
1056
- ms: [{
1057
- ms: [margin]
1058
- }],
1059
- /**
1060
- * Margin End
1061
- * @see https://tailwindcss.com/docs/margin
1062
- */
1063
- me: [{
1064
- me: [margin]
1065
- }],
1066
- /**
1067
- * Margin Top
1068
- * @see https://tailwindcss.com/docs/margin
1069
- */
1070
- mt: [{
1071
- mt: [margin]
1072
- }],
1073
- /**
1074
- * Margin Right
1075
- * @see https://tailwindcss.com/docs/margin
1076
- */
1077
- mr: [{
1078
- mr: [margin]
1079
- }],
1080
- /**
1081
- * Margin Bottom
1082
- * @see https://tailwindcss.com/docs/margin
1083
- */
1084
- mb: [{
1085
- mb: [margin]
1086
- }],
1087
- /**
1088
- * Margin Left
1089
- * @see https://tailwindcss.com/docs/margin
1090
- */
1091
- ml: [{
1092
- ml: [margin]
1093
- }],
1094
- /**
1095
- * Space Between X
1096
- * @see https://tailwindcss.com/docs/space
1097
- */
1098
- 'space-x': [{
1099
- 'space-x': [space]
1100
- }],
1101
- /**
1102
- * Space Between X Reverse
1103
- * @see https://tailwindcss.com/docs/space
1104
- */
1105
- 'space-x-reverse': ['space-x-reverse'],
1106
- /**
1107
- * Space Between Y
1108
- * @see https://tailwindcss.com/docs/space
1109
- */
1110
- 'space-y': [{
1111
- 'space-y': [space]
1112
- }],
1113
- /**
1114
- * Space Between Y Reverse
1115
- * @see https://tailwindcss.com/docs/space
1116
- */
1117
- 'space-y-reverse': ['space-y-reverse'],
1118
- // Sizing
1119
- /**
1120
- * Width
1121
- * @see https://tailwindcss.com/docs/width
1122
- */
1123
- w: [{
1124
- w: ['auto', 'min', 'max', 'fit', 'svw', 'lvw', 'dvw', isArbitraryValue, spacing]
1125
- }],
1126
- /**
1127
- * Min-Width
1128
- * @see https://tailwindcss.com/docs/min-width
1129
- */
1130
- 'min-w': [{
1131
- 'min-w': [isArbitraryValue, spacing, 'min', 'max', 'fit']
1132
- }],
1133
- /**
1134
- * Max-Width
1135
- * @see https://tailwindcss.com/docs/max-width
1136
- */
1137
- 'max-w': [{
1138
- 'max-w': [isArbitraryValue, spacing, 'none', 'full', 'min', 'max', 'fit', 'prose', {
1139
- screen: [isTshirtSize]
1140
- }, isTshirtSize]
1141
- }],
1142
- /**
1143
- * Height
1144
- * @see https://tailwindcss.com/docs/height
1145
- */
1146
- h: [{
1147
- h: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']
1148
- }],
1149
- /**
1150
- * Min-Height
1151
- * @see https://tailwindcss.com/docs/min-height
1152
- */
1153
- 'min-h': [{
1154
- 'min-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']
1155
- }],
1156
- /**
1157
- * Max-Height
1158
- * @see https://tailwindcss.com/docs/max-height
1159
- */
1160
- 'max-h': [{
1161
- 'max-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']
1162
- }],
1163
- /**
1164
- * Size
1165
- * @see https://tailwindcss.com/docs/size
1166
- */
1167
- size: [{
1168
- size: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit']
1169
- }],
1170
- // Typography
1171
- /**
1172
- * Font Size
1173
- * @see https://tailwindcss.com/docs/font-size
1174
- */
1175
- 'font-size': [{
1176
- text: ['base', isTshirtSize, isArbitraryLength]
1177
- }],
1178
- /**
1179
- * Font Smoothing
1180
- * @see https://tailwindcss.com/docs/font-smoothing
1181
- */
1182
- 'font-smoothing': ['antialiased', 'subpixel-antialiased'],
1183
- /**
1184
- * Font Style
1185
- * @see https://tailwindcss.com/docs/font-style
1186
- */
1187
- 'font-style': ['italic', 'not-italic'],
1188
- /**
1189
- * Font Weight
1190
- * @see https://tailwindcss.com/docs/font-weight
1191
- */
1192
- 'font-weight': [{
1193
- font: ['thin', 'extralight', 'light', 'normal', 'medium', 'semibold', 'bold', 'extrabold', 'black', isArbitraryNumber]
1194
- }],
1195
- /**
1196
- * Font Family
1197
- * @see https://tailwindcss.com/docs/font-family
1198
- */
1199
- 'font-family': [{
1200
- font: [isAny]
1201
- }],
1202
- /**
1203
- * Font Variant Numeric
1204
- * @see https://tailwindcss.com/docs/font-variant-numeric
1205
- */
1206
- 'fvn-normal': ['normal-nums'],
1207
- /**
1208
- * Font Variant Numeric
1209
- * @see https://tailwindcss.com/docs/font-variant-numeric
1210
- */
1211
- 'fvn-ordinal': ['ordinal'],
1212
- /**
1213
- * Font Variant Numeric
1214
- * @see https://tailwindcss.com/docs/font-variant-numeric
1215
- */
1216
- 'fvn-slashed-zero': ['slashed-zero'],
1217
- /**
1218
- * Font Variant Numeric
1219
- * @see https://tailwindcss.com/docs/font-variant-numeric
1220
- */
1221
- 'fvn-figure': ['lining-nums', 'oldstyle-nums'],
1222
- /**
1223
- * Font Variant Numeric
1224
- * @see https://tailwindcss.com/docs/font-variant-numeric
1225
- */
1226
- 'fvn-spacing': ['proportional-nums', 'tabular-nums'],
1227
- /**
1228
- * Font Variant Numeric
1229
- * @see https://tailwindcss.com/docs/font-variant-numeric
1230
- */
1231
- 'fvn-fraction': ['diagonal-fractions', 'stacked-fractons'],
1232
- /**
1233
- * Letter Spacing
1234
- * @see https://tailwindcss.com/docs/letter-spacing
1235
- */
1236
- tracking: [{
1237
- tracking: ['tighter', 'tight', 'normal', 'wide', 'wider', 'widest', isArbitraryValue]
1238
- }],
1239
- /**
1240
- * Line Clamp
1241
- * @see https://tailwindcss.com/docs/line-clamp
1242
- */
1243
- 'line-clamp': [{
1244
- 'line-clamp': ['none', isNumber, isArbitraryNumber]
1245
- }],
1246
- /**
1247
- * Line Height
1248
- * @see https://tailwindcss.com/docs/line-height
1249
- */
1250
- leading: [{
1251
- leading: ['none', 'tight', 'snug', 'normal', 'relaxed', 'loose', isLength, isArbitraryValue]
1252
- }],
1253
- /**
1254
- * List Style Image
1255
- * @see https://tailwindcss.com/docs/list-style-image
1256
- */
1257
- 'list-image': [{
1258
- 'list-image': ['none', isArbitraryValue]
1259
- }],
1260
- /**
1261
- * List Style Type
1262
- * @see https://tailwindcss.com/docs/list-style-type
1263
- */
1264
- 'list-style-type': [{
1265
- list: ['none', 'disc', 'decimal', isArbitraryValue]
1266
- }],
1267
- /**
1268
- * List Style Position
1269
- * @see https://tailwindcss.com/docs/list-style-position
1270
- */
1271
- 'list-style-position': [{
1272
- list: ['inside', 'outside']
1273
- }],
1274
- /**
1275
- * Placeholder Color
1276
- * @deprecated since Tailwind CSS v3.0.0
1277
- * @see https://tailwindcss.com/docs/placeholder-color
1278
- */
1279
- 'placeholder-color': [{
1280
- placeholder: [colors]
1281
- }],
1282
- /**
1283
- * Placeholder Opacity
1284
- * @see https://tailwindcss.com/docs/placeholder-opacity
1285
- */
1286
- 'placeholder-opacity': [{
1287
- 'placeholder-opacity': [opacity]
1288
- }],
1289
- /**
1290
- * Text Alignment
1291
- * @see https://tailwindcss.com/docs/text-align
1292
- */
1293
- 'text-alignment': [{
1294
- text: ['left', 'center', 'right', 'justify', 'start', 'end']
1295
- }],
1296
- /**
1297
- * Text Color
1298
- * @see https://tailwindcss.com/docs/text-color
1299
- */
1300
- 'text-color': [{
1301
- text: [colors]
1302
- }],
1303
- /**
1304
- * Text Opacity
1305
- * @see https://tailwindcss.com/docs/text-opacity
1306
- */
1307
- 'text-opacity': [{
1308
- 'text-opacity': [opacity]
1309
- }],
1310
- /**
1311
- * Text Decoration
1312
- * @see https://tailwindcss.com/docs/text-decoration
1313
- */
1314
- 'text-decoration': ['underline', 'overline', 'line-through', 'no-underline'],
1315
- /**
1316
- * Text Decoration Style
1317
- * @see https://tailwindcss.com/docs/text-decoration-style
1318
- */
1319
- 'text-decoration-style': [{
1320
- decoration: [...getLineStyles(), 'wavy']
1321
- }],
1322
- /**
1323
- * Text Decoration Thickness
1324
- * @see https://tailwindcss.com/docs/text-decoration-thickness
1325
- */
1326
- 'text-decoration-thickness': [{
1327
- decoration: ['auto', 'from-font', isLength, isArbitraryLength]
1328
- }],
1329
- /**
1330
- * Text Underline Offset
1331
- * @see https://tailwindcss.com/docs/text-underline-offset
1332
- */
1333
- 'underline-offset': [{
1334
- 'underline-offset': ['auto', isLength, isArbitraryValue]
1335
- }],
1336
- /**
1337
- * Text Decoration Color
1338
- * @see https://tailwindcss.com/docs/text-decoration-color
1339
- */
1340
- 'text-decoration-color': [{
1341
- decoration: [colors]
1342
- }],
1343
- /**
1344
- * Text Transform
1345
- * @see https://tailwindcss.com/docs/text-transform
1346
- */
1347
- 'text-transform': ['uppercase', 'lowercase', 'capitalize', 'normal-case'],
1348
- /**
1349
- * Text Overflow
1350
- * @see https://tailwindcss.com/docs/text-overflow
1351
- */
1352
- 'text-overflow': ['truncate', 'text-ellipsis', 'text-clip'],
1353
- /**
1354
- * Text Wrap
1355
- * @see https://tailwindcss.com/docs/text-wrap
1356
- */
1357
- 'text-wrap': [{
1358
- text: ['wrap', 'nowrap', 'balance', 'pretty']
1359
- }],
1360
- /**
1361
- * Text Indent
1362
- * @see https://tailwindcss.com/docs/text-indent
1363
- */
1364
- indent: [{
1365
- indent: getSpacingWithArbitrary()
1366
- }],
1367
- /**
1368
- * Vertical Alignment
1369
- * @see https://tailwindcss.com/docs/vertical-align
1370
- */
1371
- 'vertical-align': [{
1372
- align: ['baseline', 'top', 'middle', 'bottom', 'text-top', 'text-bottom', 'sub', 'super', isArbitraryValue]
1373
- }],
1374
- /**
1375
- * Whitespace
1376
- * @see https://tailwindcss.com/docs/whitespace
1377
- */
1378
- whitespace: [{
1379
- whitespace: ['normal', 'nowrap', 'pre', 'pre-line', 'pre-wrap', 'break-spaces']
1380
- }],
1381
- /**
1382
- * Word Break
1383
- * @see https://tailwindcss.com/docs/word-break
1384
- */
1385
- break: [{
1386
- break: ['normal', 'words', 'all', 'keep']
1387
- }],
1388
- /**
1389
- * Hyphens
1390
- * @see https://tailwindcss.com/docs/hyphens
1391
- */
1392
- hyphens: [{
1393
- hyphens: ['none', 'manual', 'auto']
1394
- }],
1395
- /**
1396
- * Content
1397
- * @see https://tailwindcss.com/docs/content
1398
- */
1399
- content: [{
1400
- content: ['none', isArbitraryValue]
1401
- }],
1402
- // Backgrounds
1403
- /**
1404
- * Background Attachment
1405
- * @see https://tailwindcss.com/docs/background-attachment
1406
- */
1407
- 'bg-attachment': [{
1408
- bg: ['fixed', 'local', 'scroll']
1409
- }],
1410
- /**
1411
- * Background Clip
1412
- * @see https://tailwindcss.com/docs/background-clip
1413
- */
1414
- 'bg-clip': [{
1415
- 'bg-clip': ['border', 'padding', 'content', 'text']
1416
- }],
1417
- /**
1418
- * Background Opacity
1419
- * @deprecated since Tailwind CSS v3.0.0
1420
- * @see https://tailwindcss.com/docs/background-opacity
1421
- */
1422
- 'bg-opacity': [{
1423
- 'bg-opacity': [opacity]
1424
- }],
1425
- /**
1426
- * Background Origin
1427
- * @see https://tailwindcss.com/docs/background-origin
1428
- */
1429
- 'bg-origin': [{
1430
- 'bg-origin': ['border', 'padding', 'content']
1431
- }],
1432
- /**
1433
- * Background Position
1434
- * @see https://tailwindcss.com/docs/background-position
1435
- */
1436
- 'bg-position': [{
1437
- bg: [...getPositions(), isArbitraryPosition]
1438
- }],
1439
- /**
1440
- * Background Repeat
1441
- * @see https://tailwindcss.com/docs/background-repeat
1442
- */
1443
- 'bg-repeat': [{
1444
- bg: ['no-repeat', {
1445
- repeat: ['', 'x', 'y', 'round', 'space']
1446
- }]
1447
- }],
1448
- /**
1449
- * Background Size
1450
- * @see https://tailwindcss.com/docs/background-size
1451
- */
1452
- 'bg-size': [{
1453
- bg: ['auto', 'cover', 'contain', isArbitrarySize]
1454
- }],
1455
- /**
1456
- * Background Image
1457
- * @see https://tailwindcss.com/docs/background-image
1458
- */
1459
- 'bg-image': [{
1460
- bg: ['none', {
1461
- 'gradient-to': ['t', 'tr', 'r', 'br', 'b', 'bl', 'l', 'tl']
1462
- }, isArbitraryImage]
1463
- }],
1464
- /**
1465
- * Background Color
1466
- * @see https://tailwindcss.com/docs/background-color
1467
- */
1468
- 'bg-color': [{
1469
- bg: [colors]
1470
- }],
1471
- /**
1472
- * Gradient Color Stops From Position
1473
- * @see https://tailwindcss.com/docs/gradient-color-stops
1474
- */
1475
- 'gradient-from-pos': [{
1476
- from: [gradientColorStopPositions]
1477
- }],
1478
- /**
1479
- * Gradient Color Stops Via Position
1480
- * @see https://tailwindcss.com/docs/gradient-color-stops
1481
- */
1482
- 'gradient-via-pos': [{
1483
- via: [gradientColorStopPositions]
1484
- }],
1485
- /**
1486
- * Gradient Color Stops To Position
1487
- * @see https://tailwindcss.com/docs/gradient-color-stops
1488
- */
1489
- 'gradient-to-pos': [{
1490
- to: [gradientColorStopPositions]
1491
- }],
1492
- /**
1493
- * Gradient Color Stops From
1494
- * @see https://tailwindcss.com/docs/gradient-color-stops
1495
- */
1496
- 'gradient-from': [{
1497
- from: [gradientColorStops]
1498
- }],
1499
- /**
1500
- * Gradient Color Stops Via
1501
- * @see https://tailwindcss.com/docs/gradient-color-stops
1502
- */
1503
- 'gradient-via': [{
1504
- via: [gradientColorStops]
1505
- }],
1506
- /**
1507
- * Gradient Color Stops To
1508
- * @see https://tailwindcss.com/docs/gradient-color-stops
1509
- */
1510
- 'gradient-to': [{
1511
- to: [gradientColorStops]
1512
- }],
1513
- // Borders
1514
- /**
1515
- * Border Radius
1516
- * @see https://tailwindcss.com/docs/border-radius
1517
- */
1518
- rounded: [{
1519
- rounded: [borderRadius]
1520
- }],
1521
- /**
1522
- * Border Radius Start
1523
- * @see https://tailwindcss.com/docs/border-radius
1524
- */
1525
- 'rounded-s': [{
1526
- 'rounded-s': [borderRadius]
1527
- }],
1528
- /**
1529
- * Border Radius End
1530
- * @see https://tailwindcss.com/docs/border-radius
1531
- */
1532
- 'rounded-e': [{
1533
- 'rounded-e': [borderRadius]
1534
- }],
1535
- /**
1536
- * Border Radius Top
1537
- * @see https://tailwindcss.com/docs/border-radius
1538
- */
1539
- 'rounded-t': [{
1540
- 'rounded-t': [borderRadius]
1541
- }],
1542
- /**
1543
- * Border Radius Right
1544
- * @see https://tailwindcss.com/docs/border-radius
1545
- */
1546
- 'rounded-r': [{
1547
- 'rounded-r': [borderRadius]
1548
- }],
1549
- /**
1550
- * Border Radius Bottom
1551
- * @see https://tailwindcss.com/docs/border-radius
1552
- */
1553
- 'rounded-b': [{
1554
- 'rounded-b': [borderRadius]
1555
- }],
1556
- /**
1557
- * Border Radius Left
1558
- * @see https://tailwindcss.com/docs/border-radius
1559
- */
1560
- 'rounded-l': [{
1561
- 'rounded-l': [borderRadius]
1562
- }],
1563
- /**
1564
- * Border Radius Start Start
1565
- * @see https://tailwindcss.com/docs/border-radius
1566
- */
1567
- 'rounded-ss': [{
1568
- 'rounded-ss': [borderRadius]
1569
- }],
1570
- /**
1571
- * Border Radius Start End
1572
- * @see https://tailwindcss.com/docs/border-radius
1573
- */
1574
- 'rounded-se': [{
1575
- 'rounded-se': [borderRadius]
1576
- }],
1577
- /**
1578
- * Border Radius End End
1579
- * @see https://tailwindcss.com/docs/border-radius
1580
- */
1581
- 'rounded-ee': [{
1582
- 'rounded-ee': [borderRadius]
1583
- }],
1584
- /**
1585
- * Border Radius End Start
1586
- * @see https://tailwindcss.com/docs/border-radius
1587
- */
1588
- 'rounded-es': [{
1589
- 'rounded-es': [borderRadius]
1590
- }],
1591
- /**
1592
- * Border Radius Top Left
1593
- * @see https://tailwindcss.com/docs/border-radius
1594
- */
1595
- 'rounded-tl': [{
1596
- 'rounded-tl': [borderRadius]
1597
- }],
1598
- /**
1599
- * Border Radius Top Right
1600
- * @see https://tailwindcss.com/docs/border-radius
1601
- */
1602
- 'rounded-tr': [{
1603
- 'rounded-tr': [borderRadius]
1604
- }],
1605
- /**
1606
- * Border Radius Bottom Right
1607
- * @see https://tailwindcss.com/docs/border-radius
1608
- */
1609
- 'rounded-br': [{
1610
- 'rounded-br': [borderRadius]
1611
- }],
1612
- /**
1613
- * Border Radius Bottom Left
1614
- * @see https://tailwindcss.com/docs/border-radius
1615
- */
1616
- 'rounded-bl': [{
1617
- 'rounded-bl': [borderRadius]
1618
- }],
1619
- /**
1620
- * Border Width
1621
- * @see https://tailwindcss.com/docs/border-width
1622
- */
1623
- 'border-w': [{
1624
- border: [borderWidth]
1625
- }],
1626
- /**
1627
- * Border Width X
1628
- * @see https://tailwindcss.com/docs/border-width
1629
- */
1630
- 'border-w-x': [{
1631
- 'border-x': [borderWidth]
1632
- }],
1633
- /**
1634
- * Border Width Y
1635
- * @see https://tailwindcss.com/docs/border-width
1636
- */
1637
- 'border-w-y': [{
1638
- 'border-y': [borderWidth]
1639
- }],
1640
- /**
1641
- * Border Width Start
1642
- * @see https://tailwindcss.com/docs/border-width
1643
- */
1644
- 'border-w-s': [{
1645
- 'border-s': [borderWidth]
1646
- }],
1647
- /**
1648
- * Border Width End
1649
- * @see https://tailwindcss.com/docs/border-width
1650
- */
1651
- 'border-w-e': [{
1652
- 'border-e': [borderWidth]
1653
- }],
1654
- /**
1655
- * Border Width Top
1656
- * @see https://tailwindcss.com/docs/border-width
1657
- */
1658
- 'border-w-t': [{
1659
- 'border-t': [borderWidth]
1660
- }],
1661
- /**
1662
- * Border Width Right
1663
- * @see https://tailwindcss.com/docs/border-width
1664
- */
1665
- 'border-w-r': [{
1666
- 'border-r': [borderWidth]
1667
- }],
1668
- /**
1669
- * Border Width Bottom
1670
- * @see https://tailwindcss.com/docs/border-width
1671
- */
1672
- 'border-w-b': [{
1673
- 'border-b': [borderWidth]
1674
- }],
1675
- /**
1676
- * Border Width Left
1677
- * @see https://tailwindcss.com/docs/border-width
1678
- */
1679
- 'border-w-l': [{
1680
- 'border-l': [borderWidth]
1681
- }],
1682
- /**
1683
- * Border Opacity
1684
- * @see https://tailwindcss.com/docs/border-opacity
1685
- */
1686
- 'border-opacity': [{
1687
- 'border-opacity': [opacity]
1688
- }],
1689
- /**
1690
- * Border Style
1691
- * @see https://tailwindcss.com/docs/border-style
1692
- */
1693
- 'border-style': [{
1694
- border: [...getLineStyles(), 'hidden']
1695
- }],
1696
- /**
1697
- * Divide Width X
1698
- * @see https://tailwindcss.com/docs/divide-width
1699
- */
1700
- 'divide-x': [{
1701
- 'divide-x': [borderWidth]
1702
- }],
1703
- /**
1704
- * Divide Width X Reverse
1705
- * @see https://tailwindcss.com/docs/divide-width
1706
- */
1707
- 'divide-x-reverse': ['divide-x-reverse'],
1708
- /**
1709
- * Divide Width Y
1710
- * @see https://tailwindcss.com/docs/divide-width
1711
- */
1712
- 'divide-y': [{
1713
- 'divide-y': [borderWidth]
1714
- }],
1715
- /**
1716
- * Divide Width Y Reverse
1717
- * @see https://tailwindcss.com/docs/divide-width
1718
- */
1719
- 'divide-y-reverse': ['divide-y-reverse'],
1720
- /**
1721
- * Divide Opacity
1722
- * @see https://tailwindcss.com/docs/divide-opacity
1723
- */
1724
- 'divide-opacity': [{
1725
- 'divide-opacity': [opacity]
1726
- }],
1727
- /**
1728
- * Divide Style
1729
- * @see https://tailwindcss.com/docs/divide-style
1730
- */
1731
- 'divide-style': [{
1732
- divide: getLineStyles()
1733
- }],
1734
- /**
1735
- * Border Color
1736
- * @see https://tailwindcss.com/docs/border-color
1737
- */
1738
- 'border-color': [{
1739
- border: [borderColor]
1740
- }],
1741
- /**
1742
- * Border Color X
1743
- * @see https://tailwindcss.com/docs/border-color
1744
- */
1745
- 'border-color-x': [{
1746
- 'border-x': [borderColor]
1747
- }],
1748
- /**
1749
- * Border Color Y
1750
- * @see https://tailwindcss.com/docs/border-color
1751
- */
1752
- 'border-color-y': [{
1753
- 'border-y': [borderColor]
1754
- }],
1755
- /**
1756
- * Border Color Top
1757
- * @see https://tailwindcss.com/docs/border-color
1758
- */
1759
- 'border-color-t': [{
1760
- 'border-t': [borderColor]
1761
- }],
1762
- /**
1763
- * Border Color Right
1764
- * @see https://tailwindcss.com/docs/border-color
1765
- */
1766
- 'border-color-r': [{
1767
- 'border-r': [borderColor]
1768
- }],
1769
- /**
1770
- * Border Color Bottom
1771
- * @see https://tailwindcss.com/docs/border-color
1772
- */
1773
- 'border-color-b': [{
1774
- 'border-b': [borderColor]
1775
- }],
1776
- /**
1777
- * Border Color Left
1778
- * @see https://tailwindcss.com/docs/border-color
1779
- */
1780
- 'border-color-l': [{
1781
- 'border-l': [borderColor]
1782
- }],
1783
- /**
1784
- * Divide Color
1785
- * @see https://tailwindcss.com/docs/divide-color
1786
- */
1787
- 'divide-color': [{
1788
- divide: [borderColor]
1789
- }],
1790
- /**
1791
- * Outline Style
1792
- * @see https://tailwindcss.com/docs/outline-style
1793
- */
1794
- 'outline-style': [{
1795
- outline: ['', ...getLineStyles()]
1796
- }],
1797
- /**
1798
- * Outline Offset
1799
- * @see https://tailwindcss.com/docs/outline-offset
1800
- */
1801
- 'outline-offset': [{
1802
- 'outline-offset': [isLength, isArbitraryValue]
1803
- }],
1804
- /**
1805
- * Outline Width
1806
- * @see https://tailwindcss.com/docs/outline-width
1807
- */
1808
- 'outline-w': [{
1809
- outline: [isLength, isArbitraryLength]
1810
- }],
1811
- /**
1812
- * Outline Color
1813
- * @see https://tailwindcss.com/docs/outline-color
1814
- */
1815
- 'outline-color': [{
1816
- outline: [colors]
1817
- }],
1818
- /**
1819
- * Ring Width
1820
- * @see https://tailwindcss.com/docs/ring-width
1821
- */
1822
- 'ring-w': [{
1823
- ring: getLengthWithEmptyAndArbitrary()
1824
- }],
1825
- /**
1826
- * Ring Width Inset
1827
- * @see https://tailwindcss.com/docs/ring-width
1828
- */
1829
- 'ring-w-inset': ['ring-inset'],
1830
- /**
1831
- * Ring Color
1832
- * @see https://tailwindcss.com/docs/ring-color
1833
- */
1834
- 'ring-color': [{
1835
- ring: [colors]
1836
- }],
1837
- /**
1838
- * Ring Opacity
1839
- * @see https://tailwindcss.com/docs/ring-opacity
1840
- */
1841
- 'ring-opacity': [{
1842
- 'ring-opacity': [opacity]
1843
- }],
1844
- /**
1845
- * Ring Offset Width
1846
- * @see https://tailwindcss.com/docs/ring-offset-width
1847
- */
1848
- 'ring-offset-w': [{
1849
- 'ring-offset': [isLength, isArbitraryLength]
1850
- }],
1851
- /**
1852
- * Ring Offset Color
1853
- * @see https://tailwindcss.com/docs/ring-offset-color
1854
- */
1855
- 'ring-offset-color': [{
1856
- 'ring-offset': [colors]
1857
- }],
1858
- // Effects
1859
- /**
1860
- * Box Shadow
1861
- * @see https://tailwindcss.com/docs/box-shadow
1862
- */
1863
- shadow: [{
1864
- shadow: ['', 'inner', 'none', isTshirtSize, isArbitraryShadow]
1865
- }],
1866
- /**
1867
- * Box Shadow Color
1868
- * @see https://tailwindcss.com/docs/box-shadow-color
1869
- */
1870
- 'shadow-color': [{
1871
- shadow: [isAny]
1872
- }],
1873
- /**
1874
- * Opacity
1875
- * @see https://tailwindcss.com/docs/opacity
1876
- */
1877
- opacity: [{
1878
- opacity: [opacity]
1879
- }],
1880
- /**
1881
- * Mix Blend Mode
1882
- * @see https://tailwindcss.com/docs/mix-blend-mode
1883
- */
1884
- 'mix-blend': [{
1885
- 'mix-blend': getBlendModes()
1886
- }],
1887
- /**
1888
- * Background Blend Mode
1889
- * @see https://tailwindcss.com/docs/background-blend-mode
1890
- */
1891
- 'bg-blend': [{
1892
- 'bg-blend': getBlendModes()
1893
- }],
1894
- // Filters
1895
- /**
1896
- * Filter
1897
- * @deprecated since Tailwind CSS v3.0.0
1898
- * @see https://tailwindcss.com/docs/filter
1899
- */
1900
- filter: [{
1901
- filter: ['', 'none']
1902
- }],
1903
- /**
1904
- * Blur
1905
- * @see https://tailwindcss.com/docs/blur
1906
- */
1907
- blur: [{
1908
- blur: [blur]
1909
- }],
1910
- /**
1911
- * Brightness
1912
- * @see https://tailwindcss.com/docs/brightness
1913
- */
1914
- brightness: [{
1915
- brightness: [brightness]
1916
- }],
1917
- /**
1918
- * Contrast
1919
- * @see https://tailwindcss.com/docs/contrast
1920
- */
1921
- contrast: [{
1922
- contrast: [contrast]
1923
- }],
1924
- /**
1925
- * Drop Shadow
1926
- * @see https://tailwindcss.com/docs/drop-shadow
1927
- */
1928
- 'drop-shadow': [{
1929
- 'drop-shadow': ['', 'none', isTshirtSize, isArbitraryValue]
1930
- }],
1931
- /**
1932
- * Grayscale
1933
- * @see https://tailwindcss.com/docs/grayscale
1934
- */
1935
- grayscale: [{
1936
- grayscale: [grayscale]
1937
- }],
1938
- /**
1939
- * Hue Rotate
1940
- * @see https://tailwindcss.com/docs/hue-rotate
1941
- */
1942
- 'hue-rotate': [{
1943
- 'hue-rotate': [hueRotate]
1944
- }],
1945
- /**
1946
- * Invert
1947
- * @see https://tailwindcss.com/docs/invert
1948
- */
1949
- invert: [{
1950
- invert: [invert]
1951
- }],
1952
- /**
1953
- * Saturate
1954
- * @see https://tailwindcss.com/docs/saturate
1955
- */
1956
- saturate: [{
1957
- saturate: [saturate]
1958
- }],
1959
- /**
1960
- * Sepia
1961
- * @see https://tailwindcss.com/docs/sepia
1962
- */
1963
- sepia: [{
1964
- sepia: [sepia]
1965
- }],
1966
- /**
1967
- * Backdrop Filter
1968
- * @deprecated since Tailwind CSS v3.0.0
1969
- * @see https://tailwindcss.com/docs/backdrop-filter
1970
- */
1971
- 'backdrop-filter': [{
1972
- 'backdrop-filter': ['', 'none']
1973
- }],
1974
- /**
1975
- * Backdrop Blur
1976
- * @see https://tailwindcss.com/docs/backdrop-blur
1977
- */
1978
- 'backdrop-blur': [{
1979
- 'backdrop-blur': [blur]
1980
- }],
1981
- /**
1982
- * Backdrop Brightness
1983
- * @see https://tailwindcss.com/docs/backdrop-brightness
1984
- */
1985
- 'backdrop-brightness': [{
1986
- 'backdrop-brightness': [brightness]
1987
- }],
1988
- /**
1989
- * Backdrop Contrast
1990
- * @see https://tailwindcss.com/docs/backdrop-contrast
1991
- */
1992
- 'backdrop-contrast': [{
1993
- 'backdrop-contrast': [contrast]
1994
- }],
1995
- /**
1996
- * Backdrop Grayscale
1997
- * @see https://tailwindcss.com/docs/backdrop-grayscale
1998
- */
1999
- 'backdrop-grayscale': [{
2000
- 'backdrop-grayscale': [grayscale]
2001
- }],
2002
- /**
2003
- * Backdrop Hue Rotate
2004
- * @see https://tailwindcss.com/docs/backdrop-hue-rotate
2005
- */
2006
- 'backdrop-hue-rotate': [{
2007
- 'backdrop-hue-rotate': [hueRotate]
2008
- }],
2009
- /**
2010
- * Backdrop Invert
2011
- * @see https://tailwindcss.com/docs/backdrop-invert
2012
- */
2013
- 'backdrop-invert': [{
2014
- 'backdrop-invert': [invert]
2015
- }],
2016
- /**
2017
- * Backdrop Opacity
2018
- * @see https://tailwindcss.com/docs/backdrop-opacity
2019
- */
2020
- 'backdrop-opacity': [{
2021
- 'backdrop-opacity': [opacity]
2022
- }],
2023
- /**
2024
- * Backdrop Saturate
2025
- * @see https://tailwindcss.com/docs/backdrop-saturate
2026
- */
2027
- 'backdrop-saturate': [{
2028
- 'backdrop-saturate': [saturate]
2029
- }],
2030
- /**
2031
- * Backdrop Sepia
2032
- * @see https://tailwindcss.com/docs/backdrop-sepia
2033
- */
2034
- 'backdrop-sepia': [{
2035
- 'backdrop-sepia': [sepia]
2036
- }],
2037
- // Tables
2038
- /**
2039
- * Border Collapse
2040
- * @see https://tailwindcss.com/docs/border-collapse
2041
- */
2042
- 'border-collapse': [{
2043
- border: ['collapse', 'separate']
2044
- }],
2045
- /**
2046
- * Border Spacing
2047
- * @see https://tailwindcss.com/docs/border-spacing
2048
- */
2049
- 'border-spacing': [{
2050
- 'border-spacing': [borderSpacing]
2051
- }],
2052
- /**
2053
- * Border Spacing X
2054
- * @see https://tailwindcss.com/docs/border-spacing
2055
- */
2056
- 'border-spacing-x': [{
2057
- 'border-spacing-x': [borderSpacing]
2058
- }],
2059
- /**
2060
- * Border Spacing Y
2061
- * @see https://tailwindcss.com/docs/border-spacing
2062
- */
2063
- 'border-spacing-y': [{
2064
- 'border-spacing-y': [borderSpacing]
2065
- }],
2066
- /**
2067
- * Table Layout
2068
- * @see https://tailwindcss.com/docs/table-layout
2069
- */
2070
- 'table-layout': [{
2071
- table: ['auto', 'fixed']
2072
- }],
2073
- /**
2074
- * Caption Side
2075
- * @see https://tailwindcss.com/docs/caption-side
2076
- */
2077
- caption: [{
2078
- caption: ['top', 'bottom']
2079
- }],
2080
- // Transitions and Animation
2081
- /**
2082
- * Tranisition Property
2083
- * @see https://tailwindcss.com/docs/transition-property
2084
- */
2085
- transition: [{
2086
- transition: ['none', 'all', '', 'colors', 'opacity', 'shadow', 'transform', isArbitraryValue]
2087
- }],
2088
- /**
2089
- * Transition Duration
2090
- * @see https://tailwindcss.com/docs/transition-duration
2091
- */
2092
- duration: [{
2093
- duration: getNumberAndArbitrary()
2094
- }],
2095
- /**
2096
- * Transition Timing Function
2097
- * @see https://tailwindcss.com/docs/transition-timing-function
2098
- */
2099
- ease: [{
2100
- ease: ['linear', 'in', 'out', 'in-out', isArbitraryValue]
2101
- }],
2102
- /**
2103
- * Transition Delay
2104
- * @see https://tailwindcss.com/docs/transition-delay
2105
- */
2106
- delay: [{
2107
- delay: getNumberAndArbitrary()
2108
- }],
2109
- /**
2110
- * Animation
2111
- * @see https://tailwindcss.com/docs/animation
2112
- */
2113
- animate: [{
2114
- animate: ['none', 'spin', 'ping', 'pulse', 'bounce', isArbitraryValue]
2115
- }],
2116
- // Transforms
2117
- /**
2118
- * Transform
2119
- * @see https://tailwindcss.com/docs/transform
2120
- */
2121
- transform: [{
2122
- transform: ['', 'gpu', 'none']
2123
- }],
2124
- /**
2125
- * Scale
2126
- * @see https://tailwindcss.com/docs/scale
2127
- */
2128
- scale: [{
2129
- scale: [scale]
2130
- }],
2131
- /**
2132
- * Scale X
2133
- * @see https://tailwindcss.com/docs/scale
2134
- */
2135
- 'scale-x': [{
2136
- 'scale-x': [scale]
2137
- }],
2138
- /**
2139
- * Scale Y
2140
- * @see https://tailwindcss.com/docs/scale
2141
- */
2142
- 'scale-y': [{
2143
- 'scale-y': [scale]
2144
- }],
2145
- /**
2146
- * Rotate
2147
- * @see https://tailwindcss.com/docs/rotate
2148
- */
2149
- rotate: [{
2150
- rotate: [isInteger, isArbitraryValue]
2151
- }],
2152
- /**
2153
- * Translate X
2154
- * @see https://tailwindcss.com/docs/translate
2155
- */
2156
- 'translate-x': [{
2157
- 'translate-x': [translate]
2158
- }],
2159
- /**
2160
- * Translate Y
2161
- * @see https://tailwindcss.com/docs/translate
2162
- */
2163
- 'translate-y': [{
2164
- 'translate-y': [translate]
2165
- }],
2166
- /**
2167
- * Skew X
2168
- * @see https://tailwindcss.com/docs/skew
2169
- */
2170
- 'skew-x': [{
2171
- 'skew-x': [skew]
2172
- }],
2173
- /**
2174
- * Skew Y
2175
- * @see https://tailwindcss.com/docs/skew
2176
- */
2177
- 'skew-y': [{
2178
- 'skew-y': [skew]
2179
- }],
2180
- /**
2181
- * Transform Origin
2182
- * @see https://tailwindcss.com/docs/transform-origin
2183
- */
2184
- 'transform-origin': [{
2185
- origin: ['center', 'top', 'top-right', 'right', 'bottom-right', 'bottom', 'bottom-left', 'left', 'top-left', isArbitraryValue]
2186
- }],
2187
- // Interactivity
2188
- /**
2189
- * Accent Color
2190
- * @see https://tailwindcss.com/docs/accent-color
2191
- */
2192
- accent: [{
2193
- accent: ['auto', colors]
2194
- }],
2195
- /**
2196
- * Appearance
2197
- * @see https://tailwindcss.com/docs/appearance
2198
- */
2199
- appearance: [{
2200
- appearance: ['none', 'auto']
2201
- }],
2202
- /**
2203
- * Cursor
2204
- * @see https://tailwindcss.com/docs/cursor
2205
- */
2206
- cursor: [{
2207
- 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', isArbitraryValue]
2208
- }],
2209
- /**
2210
- * Caret Color
2211
- * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
2212
- */
2213
- 'caret-color': [{
2214
- caret: [colors]
2215
- }],
2216
- /**
2217
- * Pointer Events
2218
- * @see https://tailwindcss.com/docs/pointer-events
2219
- */
2220
- 'pointer-events': [{
2221
- 'pointer-events': ['none', 'auto']
2222
- }],
2223
- /**
2224
- * Resize
2225
- * @see https://tailwindcss.com/docs/resize
2226
- */
2227
- resize: [{
2228
- resize: ['none', 'y', 'x', '']
2229
- }],
2230
- /**
2231
- * Scroll Behavior
2232
- * @see https://tailwindcss.com/docs/scroll-behavior
2233
- */
2234
- 'scroll-behavior': [{
2235
- scroll: ['auto', 'smooth']
2236
- }],
2237
- /**
2238
- * Scroll Margin
2239
- * @see https://tailwindcss.com/docs/scroll-margin
2240
- */
2241
- 'scroll-m': [{
2242
- 'scroll-m': getSpacingWithArbitrary()
2243
- }],
2244
- /**
2245
- * Scroll Margin X
2246
- * @see https://tailwindcss.com/docs/scroll-margin
2247
- */
2248
- 'scroll-mx': [{
2249
- 'scroll-mx': getSpacingWithArbitrary()
2250
- }],
2251
- /**
2252
- * Scroll Margin Y
2253
- * @see https://tailwindcss.com/docs/scroll-margin
2254
- */
2255
- 'scroll-my': [{
2256
- 'scroll-my': getSpacingWithArbitrary()
2257
- }],
2258
- /**
2259
- * Scroll Margin Start
2260
- * @see https://tailwindcss.com/docs/scroll-margin
2261
- */
2262
- 'scroll-ms': [{
2263
- 'scroll-ms': getSpacingWithArbitrary()
2264
- }],
2265
- /**
2266
- * Scroll Margin End
2267
- * @see https://tailwindcss.com/docs/scroll-margin
2268
- */
2269
- 'scroll-me': [{
2270
- 'scroll-me': getSpacingWithArbitrary()
2271
- }],
2272
- /**
2273
- * Scroll Margin Top
2274
- * @see https://tailwindcss.com/docs/scroll-margin
2275
- */
2276
- 'scroll-mt': [{
2277
- 'scroll-mt': getSpacingWithArbitrary()
2278
- }],
2279
- /**
2280
- * Scroll Margin Right
2281
- * @see https://tailwindcss.com/docs/scroll-margin
2282
- */
2283
- 'scroll-mr': [{
2284
- 'scroll-mr': getSpacingWithArbitrary()
2285
- }],
2286
- /**
2287
- * Scroll Margin Bottom
2288
- * @see https://tailwindcss.com/docs/scroll-margin
2289
- */
2290
- 'scroll-mb': [{
2291
- 'scroll-mb': getSpacingWithArbitrary()
2292
- }],
2293
- /**
2294
- * Scroll Margin Left
2295
- * @see https://tailwindcss.com/docs/scroll-margin
2296
- */
2297
- 'scroll-ml': [{
2298
- 'scroll-ml': getSpacingWithArbitrary()
2299
- }],
2300
- /**
2301
- * Scroll Padding
2302
- * @see https://tailwindcss.com/docs/scroll-padding
2303
- */
2304
- 'scroll-p': [{
2305
- 'scroll-p': getSpacingWithArbitrary()
2306
- }],
2307
- /**
2308
- * Scroll Padding X
2309
- * @see https://tailwindcss.com/docs/scroll-padding
2310
- */
2311
- 'scroll-px': [{
2312
- 'scroll-px': getSpacingWithArbitrary()
2313
- }],
2314
- /**
2315
- * Scroll Padding Y
2316
- * @see https://tailwindcss.com/docs/scroll-padding
2317
- */
2318
- 'scroll-py': [{
2319
- 'scroll-py': getSpacingWithArbitrary()
2320
- }],
2321
- /**
2322
- * Scroll Padding Start
2323
- * @see https://tailwindcss.com/docs/scroll-padding
2324
- */
2325
- 'scroll-ps': [{
2326
- 'scroll-ps': getSpacingWithArbitrary()
2327
- }],
2328
- /**
2329
- * Scroll Padding End
2330
- * @see https://tailwindcss.com/docs/scroll-padding
2331
- */
2332
- 'scroll-pe': [{
2333
- 'scroll-pe': getSpacingWithArbitrary()
2334
- }],
2335
- /**
2336
- * Scroll Padding Top
2337
- * @see https://tailwindcss.com/docs/scroll-padding
2338
- */
2339
- 'scroll-pt': [{
2340
- 'scroll-pt': getSpacingWithArbitrary()
2341
- }],
2342
- /**
2343
- * Scroll Padding Right
2344
- * @see https://tailwindcss.com/docs/scroll-padding
2345
- */
2346
- 'scroll-pr': [{
2347
- 'scroll-pr': getSpacingWithArbitrary()
2348
- }],
2349
- /**
2350
- * Scroll Padding Bottom
2351
- * @see https://tailwindcss.com/docs/scroll-padding
2352
- */
2353
- 'scroll-pb': [{
2354
- 'scroll-pb': getSpacingWithArbitrary()
2355
- }],
2356
- /**
2357
- * Scroll Padding Left
2358
- * @see https://tailwindcss.com/docs/scroll-padding
2359
- */
2360
- 'scroll-pl': [{
2361
- 'scroll-pl': getSpacingWithArbitrary()
2362
- }],
2363
- /**
2364
- * Scroll Snap Align
2365
- * @see https://tailwindcss.com/docs/scroll-snap-align
2366
- */
2367
- 'snap-align': [{
2368
- snap: ['start', 'end', 'center', 'align-none']
2369
- }],
2370
- /**
2371
- * Scroll Snap Stop
2372
- * @see https://tailwindcss.com/docs/scroll-snap-stop
2373
- */
2374
- 'snap-stop': [{
2375
- snap: ['normal', 'always']
2376
- }],
2377
- /**
2378
- * Scroll Snap Type
2379
- * @see https://tailwindcss.com/docs/scroll-snap-type
2380
- */
2381
- 'snap-type': [{
2382
- snap: ['none', 'x', 'y', 'both']
2383
- }],
2384
- /**
2385
- * Scroll Snap Type Strictness
2386
- * @see https://tailwindcss.com/docs/scroll-snap-type
2387
- */
2388
- 'snap-strictness': [{
2389
- snap: ['mandatory', 'proximity']
2390
- }],
2391
- /**
2392
- * Touch Action
2393
- * @see https://tailwindcss.com/docs/touch-action
2394
- */
2395
- touch: [{
2396
- touch: ['auto', 'none', 'manipulation']
2397
- }],
2398
- /**
2399
- * Touch Action X
2400
- * @see https://tailwindcss.com/docs/touch-action
2401
- */
2402
- 'touch-x': [{
2403
- 'touch-pan': ['x', 'left', 'right']
2404
- }],
2405
- /**
2406
- * Touch Action Y
2407
- * @see https://tailwindcss.com/docs/touch-action
2408
- */
2409
- 'touch-y': [{
2410
- 'touch-pan': ['y', 'up', 'down']
2411
- }],
2412
- /**
2413
- * Touch Action Pinch Zoom
2414
- * @see https://tailwindcss.com/docs/touch-action
2415
- */
2416
- 'touch-pz': ['touch-pinch-zoom'],
2417
- /**
2418
- * User Select
2419
- * @see https://tailwindcss.com/docs/user-select
2420
- */
2421
- select: [{
2422
- select: ['none', 'text', 'all', 'auto']
2423
- }],
2424
- /**
2425
- * Will Change
2426
- * @see https://tailwindcss.com/docs/will-change
2427
- */
2428
- 'will-change': [{
2429
- 'will-change': ['auto', 'scroll', 'contents', 'transform', isArbitraryValue]
2430
- }],
2431
- // SVG
2432
- /**
2433
- * Fill
2434
- * @see https://tailwindcss.com/docs/fill
2435
- */
2436
- fill: [{
2437
- fill: [colors, 'none']
2438
- }],
2439
- /**
2440
- * Stroke Width
2441
- * @see https://tailwindcss.com/docs/stroke-width
2442
- */
2443
- 'stroke-w': [{
2444
- stroke: [isLength, isArbitraryLength, isArbitraryNumber]
2445
- }],
2446
- /**
2447
- * Stroke
2448
- * @see https://tailwindcss.com/docs/stroke
2449
- */
2450
- stroke: [{
2451
- stroke: [colors, 'none']
2452
- }],
2453
- // Accessibility
2454
- /**
2455
- * Screen Readers
2456
- * @see https://tailwindcss.com/docs/screen-readers
2457
- */
2458
- sr: ['sr-only', 'not-sr-only'],
2459
- /**
2460
- * Forced Color Adjust
2461
- * @see https://tailwindcss.com/docs/forced-color-adjust
2462
- */
2463
- 'forced-color-adjust': [{
2464
- 'forced-color-adjust': ['auto', 'none']
2465
- }]
2466
- },
2467
- conflictingClassGroups: {
2468
- overflow: ['overflow-x', 'overflow-y'],
2469
- overscroll: ['overscroll-x', 'overscroll-y'],
2470
- inset: ['inset-x', 'inset-y', 'start', 'end', 'top', 'right', 'bottom', 'left'],
2471
- 'inset-x': ['right', 'left'],
2472
- 'inset-y': ['top', 'bottom'],
2473
- flex: ['basis', 'grow', 'shrink'],
2474
- gap: ['gap-x', 'gap-y'],
2475
- p: ['px', 'py', 'ps', 'pe', 'pt', 'pr', 'pb', 'pl'],
2476
- px: ['pr', 'pl'],
2477
- py: ['pt', 'pb'],
2478
- m: ['mx', 'my', 'ms', 'me', 'mt', 'mr', 'mb', 'ml'],
2479
- mx: ['mr', 'ml'],
2480
- my: ['mt', 'mb'],
2481
- size: ['w', 'h'],
2482
- 'font-size': ['leading'],
2483
- 'fvn-normal': ['fvn-ordinal', 'fvn-slashed-zero', 'fvn-figure', 'fvn-spacing', 'fvn-fraction'],
2484
- 'fvn-ordinal': ['fvn-normal'],
2485
- 'fvn-slashed-zero': ['fvn-normal'],
2486
- 'fvn-figure': ['fvn-normal'],
2487
- 'fvn-spacing': ['fvn-normal'],
2488
- 'fvn-fraction': ['fvn-normal'],
2489
- 'line-clamp': ['display', 'overflow'],
2490
- 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'],
2491
- 'rounded-s': ['rounded-ss', 'rounded-es'],
2492
- 'rounded-e': ['rounded-se', 'rounded-ee'],
2493
- 'rounded-t': ['rounded-tl', 'rounded-tr'],
2494
- 'rounded-r': ['rounded-tr', 'rounded-br'],
2495
- 'rounded-b': ['rounded-br', 'rounded-bl'],
2496
- 'rounded-l': ['rounded-tl', 'rounded-bl'],
2497
- 'border-spacing': ['border-spacing-x', 'border-spacing-y'],
2498
- 'border-w': ['border-w-s', 'border-w-e', 'border-w-t', 'border-w-r', 'border-w-b', 'border-w-l'],
2499
- 'border-w-x': ['border-w-r', 'border-w-l'],
2500
- 'border-w-y': ['border-w-t', 'border-w-b'],
2501
- 'border-color': ['border-color-t', 'border-color-r', 'border-color-b', 'border-color-l'],
2502
- 'border-color-x': ['border-color-r', 'border-color-l'],
2503
- 'border-color-y': ['border-color-t', 'border-color-b'],
2504
- 'scroll-m': ['scroll-mx', 'scroll-my', 'scroll-ms', 'scroll-me', 'scroll-mt', 'scroll-mr', 'scroll-mb', 'scroll-ml'],
2505
- 'scroll-mx': ['scroll-mr', 'scroll-ml'],
2506
- 'scroll-my': ['scroll-mt', 'scroll-mb'],
2507
- 'scroll-p': ['scroll-px', 'scroll-py', 'scroll-ps', 'scroll-pe', 'scroll-pt', 'scroll-pr', 'scroll-pb', 'scroll-pl'],
2508
- 'scroll-px': ['scroll-pr', 'scroll-pl'],
2509
- 'scroll-py': ['scroll-pt', 'scroll-pb'],
2510
- touch: ['touch-x', 'touch-y', 'touch-pz'],
2511
- 'touch-x': ['touch'],
2512
- 'touch-y': ['touch'],
2513
- 'touch-pz': ['touch']
2514
- },
2515
- conflictingClassGroupModifiers: {
2516
- 'font-size': ['leading']
2517
- }
2518
- };
2519
- }
2520
- const twMerge = /*#__PURE__*/createTailwindMerge(getDefaultConfig);
2521
-
2522
- const variants = {
2523
- base: "",
2524
- primary: "bg-Background-accentEggplant-100 text-Text-textPrimaryDark rounded-sm hover:text-Text-textPrimaryDark hover:bg-Background-accentEggplant-highlight active:bg-Background-accentEggplant-darkened focus:bg-Background-accentEggplant-100 focus:border focus:border-white",
2525
- secondary: "",
2526
- tertiary: "",
2527
- quaternary: "",
2528
- small: "py-space075 px-space400",
2529
- large: "py-space150 px-space400"
2530
- };
2531
- const Button = React.forwardRef(
2532
- ({ color = "primary", size = "small", className, ...rest }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
2533
- "button",
2534
- {
2535
- ref,
2536
- className: twMerge(clsx(variants.base, variants[color], variants[size], className)),
2537
- ...rest
2538
- }
2539
- )
2540
- );
2541
- Button.displayName = "Button";
2542
-
2543
- exports.Button = Button;