gsap-react-marquee 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,3109 @@
1
+ import require$$0, { forwardRef, useRef, useState, useMemo } from 'react';
2
+ import { useGSAP } from '@gsap/react';
3
+ import gsap from 'gsap';
4
+
5
+ var jsxRuntime = {exports: {}};
6
+
7
+ var reactJsxRuntime_production = {};
8
+
9
+ /**
10
+ * @license React
11
+ * react-jsx-runtime.production.js
12
+ *
13
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
14
+ *
15
+ * This source code is licensed under the MIT license found in the
16
+ * LICENSE file in the root directory of this source tree.
17
+ */
18
+
19
+ var hasRequiredReactJsxRuntime_production;
20
+
21
+ function requireReactJsxRuntime_production () {
22
+ if (hasRequiredReactJsxRuntime_production) return reactJsxRuntime_production;
23
+ hasRequiredReactJsxRuntime_production = 1;
24
+ var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
25
+ REACT_FRAGMENT_TYPE = Symbol.for("react.fragment");
26
+ function jsxProd(type, config, maybeKey) {
27
+ var key = null;
28
+ void 0 !== maybeKey && (key = "" + maybeKey);
29
+ void 0 !== config.key && (key = "" + config.key);
30
+ if ("key" in config) {
31
+ maybeKey = {};
32
+ for (var propName in config)
33
+ "key" !== propName && (maybeKey[propName] = config[propName]);
34
+ } else maybeKey = config;
35
+ config = maybeKey.ref;
36
+ return {
37
+ $$typeof: REACT_ELEMENT_TYPE,
38
+ type: type,
39
+ key: key,
40
+ ref: void 0 !== config ? config : null,
41
+ props: maybeKey
42
+ };
43
+ }
44
+ reactJsxRuntime_production.Fragment = REACT_FRAGMENT_TYPE;
45
+ reactJsxRuntime_production.jsx = jsxProd;
46
+ reactJsxRuntime_production.jsxs = jsxProd;
47
+ return reactJsxRuntime_production;
48
+ }
49
+
50
+ var reactJsxRuntime_development = {};
51
+
52
+ /**
53
+ * @license React
54
+ * react-jsx-runtime.development.js
55
+ *
56
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
57
+ *
58
+ * This source code is licensed under the MIT license found in the
59
+ * LICENSE file in the root directory of this source tree.
60
+ */
61
+
62
+ var hasRequiredReactJsxRuntime_development;
63
+
64
+ function requireReactJsxRuntime_development () {
65
+ if (hasRequiredReactJsxRuntime_development) return reactJsxRuntime_development;
66
+ hasRequiredReactJsxRuntime_development = 1;
67
+ "production" !== process.env.NODE_ENV &&
68
+ (function () {
69
+ function getComponentNameFromType(type) {
70
+ if (null == type) return null;
71
+ if ("function" === typeof type)
72
+ return type.$$typeof === REACT_CLIENT_REFERENCE
73
+ ? null
74
+ : type.displayName || type.name || null;
75
+ if ("string" === typeof type) return type;
76
+ switch (type) {
77
+ case REACT_FRAGMENT_TYPE:
78
+ return "Fragment";
79
+ case REACT_PROFILER_TYPE:
80
+ return "Profiler";
81
+ case REACT_STRICT_MODE_TYPE:
82
+ return "StrictMode";
83
+ case REACT_SUSPENSE_TYPE:
84
+ return "Suspense";
85
+ case REACT_SUSPENSE_LIST_TYPE:
86
+ return "SuspenseList";
87
+ case REACT_ACTIVITY_TYPE:
88
+ return "Activity";
89
+ }
90
+ if ("object" === typeof type)
91
+ switch (
92
+ ("number" === typeof type.tag &&
93
+ console.error(
94
+ "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
95
+ ),
96
+ type.$$typeof)
97
+ ) {
98
+ case REACT_PORTAL_TYPE:
99
+ return "Portal";
100
+ case REACT_CONTEXT_TYPE:
101
+ return (type.displayName || "Context") + ".Provider";
102
+ case REACT_CONSUMER_TYPE:
103
+ return (type._context.displayName || "Context") + ".Consumer";
104
+ case REACT_FORWARD_REF_TYPE:
105
+ var innerType = type.render;
106
+ type = type.displayName;
107
+ type ||
108
+ ((type = innerType.displayName || innerType.name || ""),
109
+ (type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef"));
110
+ return type;
111
+ case REACT_MEMO_TYPE:
112
+ return (
113
+ (innerType = type.displayName || null),
114
+ null !== innerType
115
+ ? innerType
116
+ : getComponentNameFromType(type.type) || "Memo"
117
+ );
118
+ case REACT_LAZY_TYPE:
119
+ innerType = type._payload;
120
+ type = type._init;
121
+ try {
122
+ return getComponentNameFromType(type(innerType));
123
+ } catch (x) {}
124
+ }
125
+ return null;
126
+ }
127
+ function testStringCoercion(value) {
128
+ return "" + value;
129
+ }
130
+ function checkKeyStringCoercion(value) {
131
+ try {
132
+ testStringCoercion(value);
133
+ var JSCompiler_inline_result = !1;
134
+ } catch (e) {
135
+ JSCompiler_inline_result = true;
136
+ }
137
+ if (JSCompiler_inline_result) {
138
+ JSCompiler_inline_result = console;
139
+ var JSCompiler_temp_const = JSCompiler_inline_result.error;
140
+ var JSCompiler_inline_result$jscomp$0 =
141
+ ("function" === typeof Symbol &&
142
+ Symbol.toStringTag &&
143
+ value[Symbol.toStringTag]) ||
144
+ value.constructor.name ||
145
+ "Object";
146
+ JSCompiler_temp_const.call(
147
+ JSCompiler_inline_result,
148
+ "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
149
+ JSCompiler_inline_result$jscomp$0
150
+ );
151
+ return testStringCoercion(value);
152
+ }
153
+ }
154
+ function getTaskName(type) {
155
+ if (type === REACT_FRAGMENT_TYPE) return "<>";
156
+ if (
157
+ "object" === typeof type &&
158
+ null !== type &&
159
+ type.$$typeof === REACT_LAZY_TYPE
160
+ )
161
+ return "<...>";
162
+ try {
163
+ var name = getComponentNameFromType(type);
164
+ return name ? "<" + name + ">" : "<...>";
165
+ } catch (x) {
166
+ return "<...>";
167
+ }
168
+ }
169
+ function getOwner() {
170
+ var dispatcher = ReactSharedInternals.A;
171
+ return null === dispatcher ? null : dispatcher.getOwner();
172
+ }
173
+ function UnknownOwner() {
174
+ return Error("react-stack-top-frame");
175
+ }
176
+ function hasValidKey(config) {
177
+ if (hasOwnProperty.call(config, "key")) {
178
+ var getter = Object.getOwnPropertyDescriptor(config, "key").get;
179
+ if (getter && getter.isReactWarning) return false;
180
+ }
181
+ return void 0 !== config.key;
182
+ }
183
+ function defineKeyPropWarningGetter(props, displayName) {
184
+ function warnAboutAccessingKey() {
185
+ specialPropKeyWarningShown ||
186
+ ((specialPropKeyWarningShown = true),
187
+ console.error(
188
+ "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
189
+ displayName
190
+ ));
191
+ }
192
+ warnAboutAccessingKey.isReactWarning = true;
193
+ Object.defineProperty(props, "key", {
194
+ get: warnAboutAccessingKey,
195
+ configurable: true
196
+ });
197
+ }
198
+ function elementRefGetterWithDeprecationWarning() {
199
+ var componentName = getComponentNameFromType(this.type);
200
+ didWarnAboutElementRef[componentName] ||
201
+ ((didWarnAboutElementRef[componentName] = true),
202
+ console.error(
203
+ "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
204
+ ));
205
+ componentName = this.props.ref;
206
+ return void 0 !== componentName ? componentName : null;
207
+ }
208
+ function ReactElement(
209
+ type,
210
+ key,
211
+ self,
212
+ source,
213
+ owner,
214
+ props,
215
+ debugStack,
216
+ debugTask
217
+ ) {
218
+ self = props.ref;
219
+ type = {
220
+ $$typeof: REACT_ELEMENT_TYPE,
221
+ type: type,
222
+ key: key,
223
+ props: props,
224
+ _owner: owner
225
+ };
226
+ null !== (void 0 !== self ? self : null)
227
+ ? Object.defineProperty(type, "ref", {
228
+ enumerable: false,
229
+ get: elementRefGetterWithDeprecationWarning
230
+ })
231
+ : Object.defineProperty(type, "ref", { enumerable: false, value: null });
232
+ type._store = {};
233
+ Object.defineProperty(type._store, "validated", {
234
+ configurable: false,
235
+ enumerable: false,
236
+ writable: true,
237
+ value: 0
238
+ });
239
+ Object.defineProperty(type, "_debugInfo", {
240
+ configurable: false,
241
+ enumerable: false,
242
+ writable: true,
243
+ value: null
244
+ });
245
+ Object.defineProperty(type, "_debugStack", {
246
+ configurable: false,
247
+ enumerable: false,
248
+ writable: true,
249
+ value: debugStack
250
+ });
251
+ Object.defineProperty(type, "_debugTask", {
252
+ configurable: false,
253
+ enumerable: false,
254
+ writable: true,
255
+ value: debugTask
256
+ });
257
+ Object.freeze && (Object.freeze(type.props), Object.freeze(type));
258
+ return type;
259
+ }
260
+ function jsxDEVImpl(
261
+ type,
262
+ config,
263
+ maybeKey,
264
+ isStaticChildren,
265
+ source,
266
+ self,
267
+ debugStack,
268
+ debugTask
269
+ ) {
270
+ var children = config.children;
271
+ if (void 0 !== children)
272
+ if (isStaticChildren)
273
+ if (isArrayImpl(children)) {
274
+ for (
275
+ isStaticChildren = 0;
276
+ isStaticChildren < children.length;
277
+ isStaticChildren++
278
+ )
279
+ validateChildKeys(children[isStaticChildren]);
280
+ Object.freeze && Object.freeze(children);
281
+ } else
282
+ console.error(
283
+ "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
284
+ );
285
+ else validateChildKeys(children);
286
+ if (hasOwnProperty.call(config, "key")) {
287
+ children = getComponentNameFromType(type);
288
+ var keys = Object.keys(config).filter(function (k) {
289
+ return "key" !== k;
290
+ });
291
+ isStaticChildren =
292
+ 0 < keys.length
293
+ ? "{key: someKey, " + keys.join(": ..., ") + ": ...}"
294
+ : "{key: someKey}";
295
+ didWarnAboutKeySpread[children + isStaticChildren] ||
296
+ ((keys =
297
+ 0 < keys.length ? "{" + keys.join(": ..., ") + ": ...}" : "{}"),
298
+ console.error(
299
+ 'A props object containing a "key" prop is being spread into JSX:\n let props = %s;\n <%s {...props} />\nReact keys must be passed directly to JSX without using spread:\n let props = %s;\n <%s key={someKey} {...props} />',
300
+ isStaticChildren,
301
+ children,
302
+ keys,
303
+ children
304
+ ),
305
+ (didWarnAboutKeySpread[children + isStaticChildren] = true));
306
+ }
307
+ children = null;
308
+ void 0 !== maybeKey &&
309
+ (checkKeyStringCoercion(maybeKey), (children = "" + maybeKey));
310
+ hasValidKey(config) &&
311
+ (checkKeyStringCoercion(config.key), (children = "" + config.key));
312
+ if ("key" in config) {
313
+ maybeKey = {};
314
+ for (var propName in config)
315
+ "key" !== propName && (maybeKey[propName] = config[propName]);
316
+ } else maybeKey = config;
317
+ children &&
318
+ defineKeyPropWarningGetter(
319
+ maybeKey,
320
+ "function" === typeof type
321
+ ? type.displayName || type.name || "Unknown"
322
+ : type
323
+ );
324
+ return ReactElement(
325
+ type,
326
+ children,
327
+ self,
328
+ source,
329
+ getOwner(),
330
+ maybeKey,
331
+ debugStack,
332
+ debugTask
333
+ );
334
+ }
335
+ function validateChildKeys(node) {
336
+ "object" === typeof node &&
337
+ null !== node &&
338
+ node.$$typeof === REACT_ELEMENT_TYPE &&
339
+ node._store &&
340
+ (node._store.validated = 1);
341
+ }
342
+ var React = require$$0,
343
+ REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
344
+ REACT_PORTAL_TYPE = Symbol.for("react.portal"),
345
+ REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"),
346
+ REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"),
347
+ REACT_PROFILER_TYPE = Symbol.for("react.profiler");
348
+ var REACT_CONSUMER_TYPE = Symbol.for("react.consumer"),
349
+ REACT_CONTEXT_TYPE = Symbol.for("react.context"),
350
+ REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"),
351
+ REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"),
352
+ REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"),
353
+ REACT_MEMO_TYPE = Symbol.for("react.memo"),
354
+ REACT_LAZY_TYPE = Symbol.for("react.lazy"),
355
+ REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
356
+ REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
357
+ ReactSharedInternals =
358
+ React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
359
+ hasOwnProperty = Object.prototype.hasOwnProperty,
360
+ isArrayImpl = Array.isArray,
361
+ createTask = console.createTask
362
+ ? console.createTask
363
+ : function () {
364
+ return null;
365
+ };
366
+ React = {
367
+ react_stack_bottom_frame: function (callStackForError) {
368
+ return callStackForError();
369
+ }
370
+ };
371
+ var specialPropKeyWarningShown;
372
+ var didWarnAboutElementRef = {};
373
+ var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(
374
+ React,
375
+ UnknownOwner
376
+ )();
377
+ var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));
378
+ var didWarnAboutKeySpread = {};
379
+ reactJsxRuntime_development.Fragment = REACT_FRAGMENT_TYPE;
380
+ reactJsxRuntime_development.jsx = function (type, config, maybeKey, source, self) {
381
+ var trackActualOwner =
382
+ 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
383
+ return jsxDEVImpl(
384
+ type,
385
+ config,
386
+ maybeKey,
387
+ false,
388
+ source,
389
+ self,
390
+ trackActualOwner
391
+ ? Error("react-stack-top-frame")
392
+ : unknownOwnerDebugStack,
393
+ trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask
394
+ );
395
+ };
396
+ reactJsxRuntime_development.jsxs = function (type, config, maybeKey, source, self) {
397
+ var trackActualOwner =
398
+ 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
399
+ return jsxDEVImpl(
400
+ type,
401
+ config,
402
+ maybeKey,
403
+ true,
404
+ source,
405
+ self,
406
+ trackActualOwner
407
+ ? Error("react-stack-top-frame")
408
+ : unknownOwnerDebugStack,
409
+ trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask
410
+ );
411
+ };
412
+ })();
413
+ return reactJsxRuntime_development;
414
+ }
415
+
416
+ if (process.env.NODE_ENV === 'production') {
417
+ jsxRuntime.exports = requireReactJsxRuntime_production();
418
+ } else {
419
+ jsxRuntime.exports = requireReactJsxRuntime_development();
420
+ }
421
+
422
+ var jsxRuntimeExports = jsxRuntime.exports;
423
+
424
+ 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}
425
+
426
+ const CLASS_PART_SEPARATOR = '-';
427
+ const createClassGroupUtils = config => {
428
+ const classMap = createClassMap(config);
429
+ const {
430
+ conflictingClassGroups,
431
+ conflictingClassGroupModifiers
432
+ } = config;
433
+ const getClassGroupId = className => {
434
+ const classParts = className.split(CLASS_PART_SEPARATOR);
435
+ // 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.
436
+ if (classParts[0] === '' && classParts.length !== 1) {
437
+ classParts.shift();
438
+ }
439
+ return getGroupRecursive(classParts, classMap) || getGroupIdForArbitraryProperty(className);
440
+ };
441
+ const getConflictingClassGroupIds = (classGroupId, hasPostfixModifier) => {
442
+ const conflicts = conflictingClassGroups[classGroupId] || [];
443
+ if (hasPostfixModifier && conflictingClassGroupModifiers[classGroupId]) {
444
+ return [...conflicts, ...conflictingClassGroupModifiers[classGroupId]];
445
+ }
446
+ return conflicts;
447
+ };
448
+ return {
449
+ getClassGroupId,
450
+ getConflictingClassGroupIds
451
+ };
452
+ };
453
+ const getGroupRecursive = (classParts, classPartObject) => {
454
+ if (classParts.length === 0) {
455
+ return classPartObject.classGroupId;
456
+ }
457
+ const currentClassPart = classParts[0];
458
+ const nextClassPartObject = classPartObject.nextPart.get(currentClassPart);
459
+ const classGroupFromNextClassPart = nextClassPartObject ? getGroupRecursive(classParts.slice(1), nextClassPartObject) : undefined;
460
+ if (classGroupFromNextClassPart) {
461
+ return classGroupFromNextClassPart;
462
+ }
463
+ if (classPartObject.validators.length === 0) {
464
+ return undefined;
465
+ }
466
+ const classRest = classParts.join(CLASS_PART_SEPARATOR);
467
+ return classPartObject.validators.find(({
468
+ validator
469
+ }) => validator(classRest))?.classGroupId;
470
+ };
471
+ const arbitraryPropertyRegex = /^\[(.+)\]$/;
472
+ const getGroupIdForArbitraryProperty = className => {
473
+ if (arbitraryPropertyRegex.test(className)) {
474
+ const arbitraryPropertyClassName = arbitraryPropertyRegex.exec(className)[1];
475
+ const property = arbitraryPropertyClassName?.substring(0, arbitraryPropertyClassName.indexOf(':'));
476
+ if (property) {
477
+ // I use two dots here because one dot is used as prefix for class groups in plugins
478
+ return 'arbitrary..' + property;
479
+ }
480
+ }
481
+ };
482
+ /**
483
+ * Exported for testing only
484
+ */
485
+ const createClassMap = config => {
486
+ const {
487
+ theme,
488
+ prefix
489
+ } = config;
490
+ const classMap = {
491
+ nextPart: new Map(),
492
+ validators: []
493
+ };
494
+ const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(config.classGroups), prefix);
495
+ prefixedClassGroupEntries.forEach(([classGroupId, classGroup]) => {
496
+ processClassesRecursively(classGroup, classMap, classGroupId, theme);
497
+ });
498
+ return classMap;
499
+ };
500
+ const processClassesRecursively = (classGroup, classPartObject, classGroupId, theme) => {
501
+ classGroup.forEach(classDefinition => {
502
+ if (typeof classDefinition === 'string') {
503
+ const classPartObjectToEdit = classDefinition === '' ? classPartObject : getPart(classPartObject, classDefinition);
504
+ classPartObjectToEdit.classGroupId = classGroupId;
505
+ return;
506
+ }
507
+ if (typeof classDefinition === 'function') {
508
+ if (isThemeGetter(classDefinition)) {
509
+ processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);
510
+ return;
511
+ }
512
+ classPartObject.validators.push({
513
+ validator: classDefinition,
514
+ classGroupId
515
+ });
516
+ return;
517
+ }
518
+ Object.entries(classDefinition).forEach(([key, classGroup]) => {
519
+ processClassesRecursively(classGroup, getPart(classPartObject, key), classGroupId, theme);
520
+ });
521
+ });
522
+ };
523
+ const getPart = (classPartObject, path) => {
524
+ let currentClassPartObject = classPartObject;
525
+ path.split(CLASS_PART_SEPARATOR).forEach(pathPart => {
526
+ if (!currentClassPartObject.nextPart.has(pathPart)) {
527
+ currentClassPartObject.nextPart.set(pathPart, {
528
+ nextPart: new Map(),
529
+ validators: []
530
+ });
531
+ }
532
+ currentClassPartObject = currentClassPartObject.nextPart.get(pathPart);
533
+ });
534
+ return currentClassPartObject;
535
+ };
536
+ const isThemeGetter = func => func.isThemeGetter;
537
+ const getPrefixedClassGroupEntries = (classGroupEntries, prefix) => {
538
+ if (!prefix) {
539
+ return classGroupEntries;
540
+ }
541
+ return classGroupEntries.map(([classGroupId, classGroup]) => {
542
+ const prefixedClassGroup = classGroup.map(classDefinition => {
543
+ if (typeof classDefinition === 'string') {
544
+ return prefix + classDefinition;
545
+ }
546
+ if (typeof classDefinition === 'object') {
547
+ return Object.fromEntries(Object.entries(classDefinition).map(([key, value]) => [prefix + key, value]));
548
+ }
549
+ return classDefinition;
550
+ });
551
+ return [classGroupId, prefixedClassGroup];
552
+ });
553
+ };
554
+
555
+ // LRU cache inspired from hashlru (https://github.com/dominictarr/hashlru/blob/v1.0.4/index.js) but object replaced with Map to improve performance
556
+ const createLruCache = maxCacheSize => {
557
+ if (maxCacheSize < 1) {
558
+ return {
559
+ get: () => undefined,
560
+ set: () => {}
561
+ };
562
+ }
563
+ let cacheSize = 0;
564
+ let cache = new Map();
565
+ let previousCache = new Map();
566
+ const update = (key, value) => {
567
+ cache.set(key, value);
568
+ cacheSize++;
569
+ if (cacheSize > maxCacheSize) {
570
+ cacheSize = 0;
571
+ previousCache = cache;
572
+ cache = new Map();
573
+ }
574
+ };
575
+ return {
576
+ get(key) {
577
+ let value = cache.get(key);
578
+ if (value !== undefined) {
579
+ return value;
580
+ }
581
+ if ((value = previousCache.get(key)) !== undefined) {
582
+ update(key, value);
583
+ return value;
584
+ }
585
+ },
586
+ set(key, value) {
587
+ if (cache.has(key)) {
588
+ cache.set(key, value);
589
+ } else {
590
+ update(key, value);
591
+ }
592
+ }
593
+ };
594
+ };
595
+ const IMPORTANT_MODIFIER = '!';
596
+ const createParseClassName = config => {
597
+ const {
598
+ separator,
599
+ experimentalParseClassName
600
+ } = config;
601
+ const isSeparatorSingleCharacter = separator.length === 1;
602
+ const firstSeparatorCharacter = separator[0];
603
+ const separatorLength = separator.length;
604
+ // parseClassName inspired by https://github.com/tailwindlabs/tailwindcss/blob/v3.2.2/src/util/splitAtTopLevelOnly.js
605
+ const parseClassName = className => {
606
+ const modifiers = [];
607
+ let bracketDepth = 0;
608
+ let modifierStart = 0;
609
+ let postfixModifierPosition;
610
+ for (let index = 0; index < className.length; index++) {
611
+ let currentCharacter = className[index];
612
+ if (bracketDepth === 0) {
613
+ if (currentCharacter === firstSeparatorCharacter && (isSeparatorSingleCharacter || className.slice(index, index + separatorLength) === separator)) {
614
+ modifiers.push(className.slice(modifierStart, index));
615
+ modifierStart = index + separatorLength;
616
+ continue;
617
+ }
618
+ if (currentCharacter === '/') {
619
+ postfixModifierPosition = index;
620
+ continue;
621
+ }
622
+ }
623
+ if (currentCharacter === '[') {
624
+ bracketDepth++;
625
+ } else if (currentCharacter === ']') {
626
+ bracketDepth--;
627
+ }
628
+ }
629
+ const baseClassNameWithImportantModifier = modifiers.length === 0 ? className : className.substring(modifierStart);
630
+ const hasImportantModifier = baseClassNameWithImportantModifier.startsWith(IMPORTANT_MODIFIER);
631
+ const baseClassName = hasImportantModifier ? baseClassNameWithImportantModifier.substring(1) : baseClassNameWithImportantModifier;
632
+ const maybePostfixModifierPosition = postfixModifierPosition && postfixModifierPosition > modifierStart ? postfixModifierPosition - modifierStart : undefined;
633
+ return {
634
+ modifiers,
635
+ hasImportantModifier,
636
+ baseClassName,
637
+ maybePostfixModifierPosition
638
+ };
639
+ };
640
+ if (experimentalParseClassName) {
641
+ return className => experimentalParseClassName({
642
+ className,
643
+ parseClassName
644
+ });
645
+ }
646
+ return parseClassName;
647
+ };
648
+ /**
649
+ * Sorts modifiers according to following schema:
650
+ * - Predefined modifiers are sorted alphabetically
651
+ * - When an arbitrary variant appears, it must be preserved which modifiers are before and after it
652
+ */
653
+ const sortModifiers = modifiers => {
654
+ if (modifiers.length <= 1) {
655
+ return modifiers;
656
+ }
657
+ const sortedModifiers = [];
658
+ let unsortedModifiers = [];
659
+ modifiers.forEach(modifier => {
660
+ const isArbitraryVariant = modifier[0] === '[';
661
+ if (isArbitraryVariant) {
662
+ sortedModifiers.push(...unsortedModifiers.sort(), modifier);
663
+ unsortedModifiers = [];
664
+ } else {
665
+ unsortedModifiers.push(modifier);
666
+ }
667
+ });
668
+ sortedModifiers.push(...unsortedModifiers.sort());
669
+ return sortedModifiers;
670
+ };
671
+ const createConfigUtils = config => ({
672
+ cache: createLruCache(config.cacheSize),
673
+ parseClassName: createParseClassName(config),
674
+ ...createClassGroupUtils(config)
675
+ });
676
+ const SPLIT_CLASSES_REGEX = /\s+/;
677
+ const mergeClassList = (classList, configUtils) => {
678
+ const {
679
+ parseClassName,
680
+ getClassGroupId,
681
+ getConflictingClassGroupIds
682
+ } = configUtils;
683
+ /**
684
+ * Set of classGroupIds in following format:
685
+ * `{importantModifier}{variantModifiers}{classGroupId}`
686
+ * @example 'float'
687
+ * @example 'hover:focus:bg-color'
688
+ * @example 'md:!pr'
689
+ */
690
+ const classGroupsInConflict = [];
691
+ const classNames = classList.trim().split(SPLIT_CLASSES_REGEX);
692
+ let result = '';
693
+ for (let index = classNames.length - 1; index >= 0; index -= 1) {
694
+ const originalClassName = classNames[index];
695
+ const {
696
+ modifiers,
697
+ hasImportantModifier,
698
+ baseClassName,
699
+ maybePostfixModifierPosition
700
+ } = parseClassName(originalClassName);
701
+ let hasPostfixModifier = Boolean(maybePostfixModifierPosition);
702
+ let classGroupId = getClassGroupId(hasPostfixModifier ? baseClassName.substring(0, maybePostfixModifierPosition) : baseClassName);
703
+ if (!classGroupId) {
704
+ if (!hasPostfixModifier) {
705
+ // Not a Tailwind class
706
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
707
+ continue;
708
+ }
709
+ classGroupId = getClassGroupId(baseClassName);
710
+ if (!classGroupId) {
711
+ // Not a Tailwind class
712
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
713
+ continue;
714
+ }
715
+ hasPostfixModifier = false;
716
+ }
717
+ const variantModifier = sortModifiers(modifiers).join(':');
718
+ const modifierId = hasImportantModifier ? variantModifier + IMPORTANT_MODIFIER : variantModifier;
719
+ const classId = modifierId + classGroupId;
720
+ if (classGroupsInConflict.includes(classId)) {
721
+ // Tailwind class omitted due to conflict
722
+ continue;
723
+ }
724
+ classGroupsInConflict.push(classId);
725
+ const conflictGroups = getConflictingClassGroupIds(classGroupId, hasPostfixModifier);
726
+ for (let i = 0; i < conflictGroups.length; ++i) {
727
+ const group = conflictGroups[i];
728
+ classGroupsInConflict.push(modifierId + group);
729
+ }
730
+ // Tailwind class not in conflict
731
+ result = originalClassName + (result.length > 0 ? ' ' + result : result);
732
+ }
733
+ return result;
734
+ };
735
+
736
+ /**
737
+ * The code in this file is copied from https://github.com/lukeed/clsx and modified to suit the needs of tailwind-merge better.
738
+ *
739
+ * Specifically:
740
+ * - Runtime code from https://github.com/lukeed/clsx/blob/v1.2.1/src/index.js
741
+ * - TypeScript types from https://github.com/lukeed/clsx/blob/v1.2.1/clsx.d.ts
742
+ *
743
+ * Original code has MIT license: Copyright (c) Luke Edwards <luke.edwards05@gmail.com> (lukeed.com)
744
+ */
745
+ function twJoin() {
746
+ let index = 0;
747
+ let argument;
748
+ let resolvedValue;
749
+ let string = '';
750
+ while (index < arguments.length) {
751
+ if (argument = arguments[index++]) {
752
+ if (resolvedValue = toValue(argument)) {
753
+ string && (string += ' ');
754
+ string += resolvedValue;
755
+ }
756
+ }
757
+ }
758
+ return string;
759
+ }
760
+ const toValue = mix => {
761
+ if (typeof mix === 'string') {
762
+ return mix;
763
+ }
764
+ let resolvedValue;
765
+ let string = '';
766
+ for (let k = 0; k < mix.length; k++) {
767
+ if (mix[k]) {
768
+ if (resolvedValue = toValue(mix[k])) {
769
+ string && (string += ' ');
770
+ string += resolvedValue;
771
+ }
772
+ }
773
+ }
774
+ return string;
775
+ };
776
+ function createTailwindMerge(createConfigFirst, ...createConfigRest) {
777
+ let configUtils;
778
+ let cacheGet;
779
+ let cacheSet;
780
+ let functionToCall = initTailwindMerge;
781
+ function initTailwindMerge(classList) {
782
+ const config = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());
783
+ configUtils = createConfigUtils(config);
784
+ cacheGet = configUtils.cache.get;
785
+ cacheSet = configUtils.cache.set;
786
+ functionToCall = tailwindMerge;
787
+ return tailwindMerge(classList);
788
+ }
789
+ function tailwindMerge(classList) {
790
+ const cachedResult = cacheGet(classList);
791
+ if (cachedResult) {
792
+ return cachedResult;
793
+ }
794
+ const result = mergeClassList(classList, configUtils);
795
+ cacheSet(classList, result);
796
+ return result;
797
+ }
798
+ return function callTailwindMerge() {
799
+ return functionToCall(twJoin.apply(null, arguments));
800
+ };
801
+ }
802
+ const fromTheme = key => {
803
+ const themeGetter = theme => theme[key] || [];
804
+ themeGetter.isThemeGetter = true;
805
+ return themeGetter;
806
+ };
807
+ const arbitraryValueRegex = /^\[(?:([a-z-]+):)?(.+)\]$/i;
808
+ const fractionRegex = /^\d+\/\d+$/;
809
+ const stringLengths = /*#__PURE__*/new Set(['px', 'full', 'screen']);
810
+ const tshirtUnitRegex = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/;
811
+ 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$/;
812
+ const colorFunctionRegex = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/;
813
+ // Shadow always begins with x and y offset separated by underscore optionally prepended by inset
814
+ const shadowRegex = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;
815
+ const imageRegex = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;
816
+ const isLength = value => isNumber(value) || stringLengths.has(value) || fractionRegex.test(value);
817
+ const isArbitraryLength = value => getIsArbitraryValue(value, 'length', isLengthOnly);
818
+ const isNumber = value => Boolean(value) && !Number.isNaN(Number(value));
819
+ const isArbitraryNumber = value => getIsArbitraryValue(value, 'number', isNumber);
820
+ const isInteger = value => Boolean(value) && Number.isInteger(Number(value));
821
+ const isPercent = value => value.endsWith('%') && isNumber(value.slice(0, -1));
822
+ const isArbitraryValue = value => arbitraryValueRegex.test(value);
823
+ const isTshirtSize = value => tshirtUnitRegex.test(value);
824
+ const sizeLabels = /*#__PURE__*/new Set(['length', 'size', 'percentage']);
825
+ const isArbitrarySize = value => getIsArbitraryValue(value, sizeLabels, isNever);
826
+ const isArbitraryPosition = value => getIsArbitraryValue(value, 'position', isNever);
827
+ const imageLabels = /*#__PURE__*/new Set(['image', 'url']);
828
+ const isArbitraryImage = value => getIsArbitraryValue(value, imageLabels, isImage);
829
+ const isArbitraryShadow = value => getIsArbitraryValue(value, '', isShadow);
830
+ const isAny = () => true;
831
+ const getIsArbitraryValue = (value, label, testValue) => {
832
+ const result = arbitraryValueRegex.exec(value);
833
+ if (result) {
834
+ if (result[1]) {
835
+ return typeof label === 'string' ? result[1] === label : label.has(result[1]);
836
+ }
837
+ return testValue(result[2]);
838
+ }
839
+ return false;
840
+ };
841
+ const isLengthOnly = value =>
842
+ // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
843
+ // For example, `hsl(0 0% 0%)` would be classified as a length without this check.
844
+ // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
845
+ lengthUnitRegex.test(value) && !colorFunctionRegex.test(value);
846
+ const isNever = () => false;
847
+ const isShadow = value => shadowRegex.test(value);
848
+ const isImage = value => imageRegex.test(value);
849
+ const getDefaultConfig = () => {
850
+ const colors = fromTheme('colors');
851
+ const spacing = fromTheme('spacing');
852
+ const blur = fromTheme('blur');
853
+ const brightness = fromTheme('brightness');
854
+ const borderColor = fromTheme('borderColor');
855
+ const borderRadius = fromTheme('borderRadius');
856
+ const borderSpacing = fromTheme('borderSpacing');
857
+ const borderWidth = fromTheme('borderWidth');
858
+ const contrast = fromTheme('contrast');
859
+ const grayscale = fromTheme('grayscale');
860
+ const hueRotate = fromTheme('hueRotate');
861
+ const invert = fromTheme('invert');
862
+ const gap = fromTheme('gap');
863
+ const gradientColorStops = fromTheme('gradientColorStops');
864
+ const gradientColorStopPositions = fromTheme('gradientColorStopPositions');
865
+ const inset = fromTheme('inset');
866
+ const margin = fromTheme('margin');
867
+ const opacity = fromTheme('opacity');
868
+ const padding = fromTheme('padding');
869
+ const saturate = fromTheme('saturate');
870
+ const scale = fromTheme('scale');
871
+ const sepia = fromTheme('sepia');
872
+ const skew = fromTheme('skew');
873
+ const space = fromTheme('space');
874
+ const translate = fromTheme('translate');
875
+ const getOverscroll = () => ['auto', 'contain', 'none'];
876
+ const getOverflow = () => ['auto', 'hidden', 'clip', 'visible', 'scroll'];
877
+ const getSpacingWithAutoAndArbitrary = () => ['auto', isArbitraryValue, spacing];
878
+ const getSpacingWithArbitrary = () => [isArbitraryValue, spacing];
879
+ const getLengthWithEmptyAndArbitrary = () => ['', isLength, isArbitraryLength];
880
+ const getNumberWithAutoAndArbitrary = () => ['auto', isNumber, isArbitraryValue];
881
+ const getPositions = () => ['bottom', 'center', 'left', 'left-bottom', 'left-top', 'right', 'right-bottom', 'right-top', 'top'];
882
+ const getLineStyles = () => ['solid', 'dashed', 'dotted', 'double', 'none'];
883
+ const getBlendModes = () => ['normal', 'multiply', 'screen', 'overlay', 'darken', 'lighten', 'color-dodge', 'color-burn', 'hard-light', 'soft-light', 'difference', 'exclusion', 'hue', 'saturation', 'color', 'luminosity'];
884
+ const getAlign = () => ['start', 'end', 'center', 'between', 'around', 'evenly', 'stretch'];
885
+ const getZeroAndEmpty = () => ['', '0', isArbitraryValue];
886
+ const getBreaks = () => ['auto', 'avoid', 'all', 'avoid-page', 'page', 'left', 'right', 'column'];
887
+ const getNumberAndArbitrary = () => [isNumber, isArbitraryValue];
888
+ return {
889
+ cacheSize: 500,
890
+ separator: ':',
891
+ theme: {
892
+ colors: [isAny],
893
+ spacing: [isLength, isArbitraryLength],
894
+ blur: ['none', '', isTshirtSize, isArbitraryValue],
895
+ brightness: getNumberAndArbitrary(),
896
+ borderColor: [colors],
897
+ borderRadius: ['none', '', 'full', isTshirtSize, isArbitraryValue],
898
+ borderSpacing: getSpacingWithArbitrary(),
899
+ borderWidth: getLengthWithEmptyAndArbitrary(),
900
+ contrast: getNumberAndArbitrary(),
901
+ grayscale: getZeroAndEmpty(),
902
+ hueRotate: getNumberAndArbitrary(),
903
+ invert: getZeroAndEmpty(),
904
+ gap: getSpacingWithArbitrary(),
905
+ gradientColorStops: [colors],
906
+ gradientColorStopPositions: [isPercent, isArbitraryLength],
907
+ inset: getSpacingWithAutoAndArbitrary(),
908
+ margin: getSpacingWithAutoAndArbitrary(),
909
+ opacity: getNumberAndArbitrary(),
910
+ padding: getSpacingWithArbitrary(),
911
+ saturate: getNumberAndArbitrary(),
912
+ scale: getNumberAndArbitrary(),
913
+ sepia: getZeroAndEmpty(),
914
+ skew: getNumberAndArbitrary(),
915
+ space: getSpacingWithArbitrary(),
916
+ translate: getSpacingWithArbitrary()
917
+ },
918
+ classGroups: {
919
+ // Layout
920
+ /**
921
+ * Aspect Ratio
922
+ * @see https://tailwindcss.com/docs/aspect-ratio
923
+ */
924
+ aspect: [{
925
+ aspect: ['auto', 'square', 'video', isArbitraryValue]
926
+ }],
927
+ /**
928
+ * Container
929
+ * @see https://tailwindcss.com/docs/container
930
+ */
931
+ container: ['container'],
932
+ /**
933
+ * Columns
934
+ * @see https://tailwindcss.com/docs/columns
935
+ */
936
+ columns: [{
937
+ columns: [isTshirtSize]
938
+ }],
939
+ /**
940
+ * Break After
941
+ * @see https://tailwindcss.com/docs/break-after
942
+ */
943
+ 'break-after': [{
944
+ 'break-after': getBreaks()
945
+ }],
946
+ /**
947
+ * Break Before
948
+ * @see https://tailwindcss.com/docs/break-before
949
+ */
950
+ 'break-before': [{
951
+ 'break-before': getBreaks()
952
+ }],
953
+ /**
954
+ * Break Inside
955
+ * @see https://tailwindcss.com/docs/break-inside
956
+ */
957
+ 'break-inside': [{
958
+ 'break-inside': ['auto', 'avoid', 'avoid-page', 'avoid-column']
959
+ }],
960
+ /**
961
+ * Box Decoration Break
962
+ * @see https://tailwindcss.com/docs/box-decoration-break
963
+ */
964
+ 'box-decoration': [{
965
+ 'box-decoration': ['slice', 'clone']
966
+ }],
967
+ /**
968
+ * Box Sizing
969
+ * @see https://tailwindcss.com/docs/box-sizing
970
+ */
971
+ box: [{
972
+ box: ['border', 'content']
973
+ }],
974
+ /**
975
+ * Display
976
+ * @see https://tailwindcss.com/docs/display
977
+ */
978
+ 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'],
979
+ /**
980
+ * Floats
981
+ * @see https://tailwindcss.com/docs/float
982
+ */
983
+ float: [{
984
+ float: ['right', 'left', 'none', 'start', 'end']
985
+ }],
986
+ /**
987
+ * Clear
988
+ * @see https://tailwindcss.com/docs/clear
989
+ */
990
+ clear: [{
991
+ clear: ['left', 'right', 'both', 'none', 'start', 'end']
992
+ }],
993
+ /**
994
+ * Isolation
995
+ * @see https://tailwindcss.com/docs/isolation
996
+ */
997
+ isolation: ['isolate', 'isolation-auto'],
998
+ /**
999
+ * Object Fit
1000
+ * @see https://tailwindcss.com/docs/object-fit
1001
+ */
1002
+ 'object-fit': [{
1003
+ object: ['contain', 'cover', 'fill', 'none', 'scale-down']
1004
+ }],
1005
+ /**
1006
+ * Object Position
1007
+ * @see https://tailwindcss.com/docs/object-position
1008
+ */
1009
+ 'object-position': [{
1010
+ object: [...getPositions(), isArbitraryValue]
1011
+ }],
1012
+ /**
1013
+ * Overflow
1014
+ * @see https://tailwindcss.com/docs/overflow
1015
+ */
1016
+ overflow: [{
1017
+ overflow: getOverflow()
1018
+ }],
1019
+ /**
1020
+ * Overflow X
1021
+ * @see https://tailwindcss.com/docs/overflow
1022
+ */
1023
+ 'overflow-x': [{
1024
+ 'overflow-x': getOverflow()
1025
+ }],
1026
+ /**
1027
+ * Overflow Y
1028
+ * @see https://tailwindcss.com/docs/overflow
1029
+ */
1030
+ 'overflow-y': [{
1031
+ 'overflow-y': getOverflow()
1032
+ }],
1033
+ /**
1034
+ * Overscroll Behavior
1035
+ * @see https://tailwindcss.com/docs/overscroll-behavior
1036
+ */
1037
+ overscroll: [{
1038
+ overscroll: getOverscroll()
1039
+ }],
1040
+ /**
1041
+ * Overscroll Behavior X
1042
+ * @see https://tailwindcss.com/docs/overscroll-behavior
1043
+ */
1044
+ 'overscroll-x': [{
1045
+ 'overscroll-x': getOverscroll()
1046
+ }],
1047
+ /**
1048
+ * Overscroll Behavior Y
1049
+ * @see https://tailwindcss.com/docs/overscroll-behavior
1050
+ */
1051
+ 'overscroll-y': [{
1052
+ 'overscroll-y': getOverscroll()
1053
+ }],
1054
+ /**
1055
+ * Position
1056
+ * @see https://tailwindcss.com/docs/position
1057
+ */
1058
+ position: ['static', 'fixed', 'absolute', 'relative', 'sticky'],
1059
+ /**
1060
+ * Top / Right / Bottom / Left
1061
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1062
+ */
1063
+ inset: [{
1064
+ inset: [inset]
1065
+ }],
1066
+ /**
1067
+ * Right / Left
1068
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1069
+ */
1070
+ 'inset-x': [{
1071
+ 'inset-x': [inset]
1072
+ }],
1073
+ /**
1074
+ * Top / Bottom
1075
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1076
+ */
1077
+ 'inset-y': [{
1078
+ 'inset-y': [inset]
1079
+ }],
1080
+ /**
1081
+ * Start
1082
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1083
+ */
1084
+ start: [{
1085
+ start: [inset]
1086
+ }],
1087
+ /**
1088
+ * End
1089
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1090
+ */
1091
+ end: [{
1092
+ end: [inset]
1093
+ }],
1094
+ /**
1095
+ * Top
1096
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1097
+ */
1098
+ top: [{
1099
+ top: [inset]
1100
+ }],
1101
+ /**
1102
+ * Right
1103
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1104
+ */
1105
+ right: [{
1106
+ right: [inset]
1107
+ }],
1108
+ /**
1109
+ * Bottom
1110
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1111
+ */
1112
+ bottom: [{
1113
+ bottom: [inset]
1114
+ }],
1115
+ /**
1116
+ * Left
1117
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
1118
+ */
1119
+ left: [{
1120
+ left: [inset]
1121
+ }],
1122
+ /**
1123
+ * Visibility
1124
+ * @see https://tailwindcss.com/docs/visibility
1125
+ */
1126
+ visibility: ['visible', 'invisible', 'collapse'],
1127
+ /**
1128
+ * Z-Index
1129
+ * @see https://tailwindcss.com/docs/z-index
1130
+ */
1131
+ z: [{
1132
+ z: ['auto', isInteger, isArbitraryValue]
1133
+ }],
1134
+ // Flexbox and Grid
1135
+ /**
1136
+ * Flex Basis
1137
+ * @see https://tailwindcss.com/docs/flex-basis
1138
+ */
1139
+ basis: [{
1140
+ basis: getSpacingWithAutoAndArbitrary()
1141
+ }],
1142
+ /**
1143
+ * Flex Direction
1144
+ * @see https://tailwindcss.com/docs/flex-direction
1145
+ */
1146
+ 'flex-direction': [{
1147
+ flex: ['row', 'row-reverse', 'col', 'col-reverse']
1148
+ }],
1149
+ /**
1150
+ * Flex Wrap
1151
+ * @see https://tailwindcss.com/docs/flex-wrap
1152
+ */
1153
+ 'flex-wrap': [{
1154
+ flex: ['wrap', 'wrap-reverse', 'nowrap']
1155
+ }],
1156
+ /**
1157
+ * Flex
1158
+ * @see https://tailwindcss.com/docs/flex
1159
+ */
1160
+ flex: [{
1161
+ flex: ['1', 'auto', 'initial', 'none', isArbitraryValue]
1162
+ }],
1163
+ /**
1164
+ * Flex Grow
1165
+ * @see https://tailwindcss.com/docs/flex-grow
1166
+ */
1167
+ grow: [{
1168
+ grow: getZeroAndEmpty()
1169
+ }],
1170
+ /**
1171
+ * Flex Shrink
1172
+ * @see https://tailwindcss.com/docs/flex-shrink
1173
+ */
1174
+ shrink: [{
1175
+ shrink: getZeroAndEmpty()
1176
+ }],
1177
+ /**
1178
+ * Order
1179
+ * @see https://tailwindcss.com/docs/order
1180
+ */
1181
+ order: [{
1182
+ order: ['first', 'last', 'none', isInteger, isArbitraryValue]
1183
+ }],
1184
+ /**
1185
+ * Grid Template Columns
1186
+ * @see https://tailwindcss.com/docs/grid-template-columns
1187
+ */
1188
+ 'grid-cols': [{
1189
+ 'grid-cols': [isAny]
1190
+ }],
1191
+ /**
1192
+ * Grid Column Start / End
1193
+ * @see https://tailwindcss.com/docs/grid-column
1194
+ */
1195
+ 'col-start-end': [{
1196
+ col: ['auto', {
1197
+ span: ['full', isInteger, isArbitraryValue]
1198
+ }, isArbitraryValue]
1199
+ }],
1200
+ /**
1201
+ * Grid Column Start
1202
+ * @see https://tailwindcss.com/docs/grid-column
1203
+ */
1204
+ 'col-start': [{
1205
+ 'col-start': getNumberWithAutoAndArbitrary()
1206
+ }],
1207
+ /**
1208
+ * Grid Column End
1209
+ * @see https://tailwindcss.com/docs/grid-column
1210
+ */
1211
+ 'col-end': [{
1212
+ 'col-end': getNumberWithAutoAndArbitrary()
1213
+ }],
1214
+ /**
1215
+ * Grid Template Rows
1216
+ * @see https://tailwindcss.com/docs/grid-template-rows
1217
+ */
1218
+ 'grid-rows': [{
1219
+ 'grid-rows': [isAny]
1220
+ }],
1221
+ /**
1222
+ * Grid Row Start / End
1223
+ * @see https://tailwindcss.com/docs/grid-row
1224
+ */
1225
+ 'row-start-end': [{
1226
+ row: ['auto', {
1227
+ span: [isInteger, isArbitraryValue]
1228
+ }, isArbitraryValue]
1229
+ }],
1230
+ /**
1231
+ * Grid Row Start
1232
+ * @see https://tailwindcss.com/docs/grid-row
1233
+ */
1234
+ 'row-start': [{
1235
+ 'row-start': getNumberWithAutoAndArbitrary()
1236
+ }],
1237
+ /**
1238
+ * Grid Row End
1239
+ * @see https://tailwindcss.com/docs/grid-row
1240
+ */
1241
+ 'row-end': [{
1242
+ 'row-end': getNumberWithAutoAndArbitrary()
1243
+ }],
1244
+ /**
1245
+ * Grid Auto Flow
1246
+ * @see https://tailwindcss.com/docs/grid-auto-flow
1247
+ */
1248
+ 'grid-flow': [{
1249
+ 'grid-flow': ['row', 'col', 'dense', 'row-dense', 'col-dense']
1250
+ }],
1251
+ /**
1252
+ * Grid Auto Columns
1253
+ * @see https://tailwindcss.com/docs/grid-auto-columns
1254
+ */
1255
+ 'auto-cols': [{
1256
+ 'auto-cols': ['auto', 'min', 'max', 'fr', isArbitraryValue]
1257
+ }],
1258
+ /**
1259
+ * Grid Auto Rows
1260
+ * @see https://tailwindcss.com/docs/grid-auto-rows
1261
+ */
1262
+ 'auto-rows': [{
1263
+ 'auto-rows': ['auto', 'min', 'max', 'fr', isArbitraryValue]
1264
+ }],
1265
+ /**
1266
+ * Gap
1267
+ * @see https://tailwindcss.com/docs/gap
1268
+ */
1269
+ gap: [{
1270
+ gap: [gap]
1271
+ }],
1272
+ /**
1273
+ * Gap X
1274
+ * @see https://tailwindcss.com/docs/gap
1275
+ */
1276
+ 'gap-x': [{
1277
+ 'gap-x': [gap]
1278
+ }],
1279
+ /**
1280
+ * Gap Y
1281
+ * @see https://tailwindcss.com/docs/gap
1282
+ */
1283
+ 'gap-y': [{
1284
+ 'gap-y': [gap]
1285
+ }],
1286
+ /**
1287
+ * Justify Content
1288
+ * @see https://tailwindcss.com/docs/justify-content
1289
+ */
1290
+ 'justify-content': [{
1291
+ justify: ['normal', ...getAlign()]
1292
+ }],
1293
+ /**
1294
+ * Justify Items
1295
+ * @see https://tailwindcss.com/docs/justify-items
1296
+ */
1297
+ 'justify-items': [{
1298
+ 'justify-items': ['start', 'end', 'center', 'stretch']
1299
+ }],
1300
+ /**
1301
+ * Justify Self
1302
+ * @see https://tailwindcss.com/docs/justify-self
1303
+ */
1304
+ 'justify-self': [{
1305
+ 'justify-self': ['auto', 'start', 'end', 'center', 'stretch']
1306
+ }],
1307
+ /**
1308
+ * Align Content
1309
+ * @see https://tailwindcss.com/docs/align-content
1310
+ */
1311
+ 'align-content': [{
1312
+ content: ['normal', ...getAlign(), 'baseline']
1313
+ }],
1314
+ /**
1315
+ * Align Items
1316
+ * @see https://tailwindcss.com/docs/align-items
1317
+ */
1318
+ 'align-items': [{
1319
+ items: ['start', 'end', 'center', 'baseline', 'stretch']
1320
+ }],
1321
+ /**
1322
+ * Align Self
1323
+ * @see https://tailwindcss.com/docs/align-self
1324
+ */
1325
+ 'align-self': [{
1326
+ self: ['auto', 'start', 'end', 'center', 'stretch', 'baseline']
1327
+ }],
1328
+ /**
1329
+ * Place Content
1330
+ * @see https://tailwindcss.com/docs/place-content
1331
+ */
1332
+ 'place-content': [{
1333
+ 'place-content': [...getAlign(), 'baseline']
1334
+ }],
1335
+ /**
1336
+ * Place Items
1337
+ * @see https://tailwindcss.com/docs/place-items
1338
+ */
1339
+ 'place-items': [{
1340
+ 'place-items': ['start', 'end', 'center', 'baseline', 'stretch']
1341
+ }],
1342
+ /**
1343
+ * Place Self
1344
+ * @see https://tailwindcss.com/docs/place-self
1345
+ */
1346
+ 'place-self': [{
1347
+ 'place-self': ['auto', 'start', 'end', 'center', 'stretch']
1348
+ }],
1349
+ // Spacing
1350
+ /**
1351
+ * Padding
1352
+ * @see https://tailwindcss.com/docs/padding
1353
+ */
1354
+ p: [{
1355
+ p: [padding]
1356
+ }],
1357
+ /**
1358
+ * Padding X
1359
+ * @see https://tailwindcss.com/docs/padding
1360
+ */
1361
+ px: [{
1362
+ px: [padding]
1363
+ }],
1364
+ /**
1365
+ * Padding Y
1366
+ * @see https://tailwindcss.com/docs/padding
1367
+ */
1368
+ py: [{
1369
+ py: [padding]
1370
+ }],
1371
+ /**
1372
+ * Padding Start
1373
+ * @see https://tailwindcss.com/docs/padding
1374
+ */
1375
+ ps: [{
1376
+ ps: [padding]
1377
+ }],
1378
+ /**
1379
+ * Padding End
1380
+ * @see https://tailwindcss.com/docs/padding
1381
+ */
1382
+ pe: [{
1383
+ pe: [padding]
1384
+ }],
1385
+ /**
1386
+ * Padding Top
1387
+ * @see https://tailwindcss.com/docs/padding
1388
+ */
1389
+ pt: [{
1390
+ pt: [padding]
1391
+ }],
1392
+ /**
1393
+ * Padding Right
1394
+ * @see https://tailwindcss.com/docs/padding
1395
+ */
1396
+ pr: [{
1397
+ pr: [padding]
1398
+ }],
1399
+ /**
1400
+ * Padding Bottom
1401
+ * @see https://tailwindcss.com/docs/padding
1402
+ */
1403
+ pb: [{
1404
+ pb: [padding]
1405
+ }],
1406
+ /**
1407
+ * Padding Left
1408
+ * @see https://tailwindcss.com/docs/padding
1409
+ */
1410
+ pl: [{
1411
+ pl: [padding]
1412
+ }],
1413
+ /**
1414
+ * Margin
1415
+ * @see https://tailwindcss.com/docs/margin
1416
+ */
1417
+ m: [{
1418
+ m: [margin]
1419
+ }],
1420
+ /**
1421
+ * Margin X
1422
+ * @see https://tailwindcss.com/docs/margin
1423
+ */
1424
+ mx: [{
1425
+ mx: [margin]
1426
+ }],
1427
+ /**
1428
+ * Margin Y
1429
+ * @see https://tailwindcss.com/docs/margin
1430
+ */
1431
+ my: [{
1432
+ my: [margin]
1433
+ }],
1434
+ /**
1435
+ * Margin Start
1436
+ * @see https://tailwindcss.com/docs/margin
1437
+ */
1438
+ ms: [{
1439
+ ms: [margin]
1440
+ }],
1441
+ /**
1442
+ * Margin End
1443
+ * @see https://tailwindcss.com/docs/margin
1444
+ */
1445
+ me: [{
1446
+ me: [margin]
1447
+ }],
1448
+ /**
1449
+ * Margin Top
1450
+ * @see https://tailwindcss.com/docs/margin
1451
+ */
1452
+ mt: [{
1453
+ mt: [margin]
1454
+ }],
1455
+ /**
1456
+ * Margin Right
1457
+ * @see https://tailwindcss.com/docs/margin
1458
+ */
1459
+ mr: [{
1460
+ mr: [margin]
1461
+ }],
1462
+ /**
1463
+ * Margin Bottom
1464
+ * @see https://tailwindcss.com/docs/margin
1465
+ */
1466
+ mb: [{
1467
+ mb: [margin]
1468
+ }],
1469
+ /**
1470
+ * Margin Left
1471
+ * @see https://tailwindcss.com/docs/margin
1472
+ */
1473
+ ml: [{
1474
+ ml: [margin]
1475
+ }],
1476
+ /**
1477
+ * Space Between X
1478
+ * @see https://tailwindcss.com/docs/space
1479
+ */
1480
+ 'space-x': [{
1481
+ 'space-x': [space]
1482
+ }],
1483
+ /**
1484
+ * Space Between X Reverse
1485
+ * @see https://tailwindcss.com/docs/space
1486
+ */
1487
+ 'space-x-reverse': ['space-x-reverse'],
1488
+ /**
1489
+ * Space Between Y
1490
+ * @see https://tailwindcss.com/docs/space
1491
+ */
1492
+ 'space-y': [{
1493
+ 'space-y': [space]
1494
+ }],
1495
+ /**
1496
+ * Space Between Y Reverse
1497
+ * @see https://tailwindcss.com/docs/space
1498
+ */
1499
+ 'space-y-reverse': ['space-y-reverse'],
1500
+ // Sizing
1501
+ /**
1502
+ * Width
1503
+ * @see https://tailwindcss.com/docs/width
1504
+ */
1505
+ w: [{
1506
+ w: ['auto', 'min', 'max', 'fit', 'svw', 'lvw', 'dvw', isArbitraryValue, spacing]
1507
+ }],
1508
+ /**
1509
+ * Min-Width
1510
+ * @see https://tailwindcss.com/docs/min-width
1511
+ */
1512
+ 'min-w': [{
1513
+ 'min-w': [isArbitraryValue, spacing, 'min', 'max', 'fit']
1514
+ }],
1515
+ /**
1516
+ * Max-Width
1517
+ * @see https://tailwindcss.com/docs/max-width
1518
+ */
1519
+ 'max-w': [{
1520
+ 'max-w': [isArbitraryValue, spacing, 'none', 'full', 'min', 'max', 'fit', 'prose', {
1521
+ screen: [isTshirtSize]
1522
+ }, isTshirtSize]
1523
+ }],
1524
+ /**
1525
+ * Height
1526
+ * @see https://tailwindcss.com/docs/height
1527
+ */
1528
+ h: [{
1529
+ h: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']
1530
+ }],
1531
+ /**
1532
+ * Min-Height
1533
+ * @see https://tailwindcss.com/docs/min-height
1534
+ */
1535
+ 'min-h': [{
1536
+ 'min-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']
1537
+ }],
1538
+ /**
1539
+ * Max-Height
1540
+ * @see https://tailwindcss.com/docs/max-height
1541
+ */
1542
+ 'max-h': [{
1543
+ 'max-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']
1544
+ }],
1545
+ /**
1546
+ * Size
1547
+ * @see https://tailwindcss.com/docs/size
1548
+ */
1549
+ size: [{
1550
+ size: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit']
1551
+ }],
1552
+ // Typography
1553
+ /**
1554
+ * Font Size
1555
+ * @see https://tailwindcss.com/docs/font-size
1556
+ */
1557
+ 'font-size': [{
1558
+ text: ['base', isTshirtSize, isArbitraryLength]
1559
+ }],
1560
+ /**
1561
+ * Font Smoothing
1562
+ * @see https://tailwindcss.com/docs/font-smoothing
1563
+ */
1564
+ 'font-smoothing': ['antialiased', 'subpixel-antialiased'],
1565
+ /**
1566
+ * Font Style
1567
+ * @see https://tailwindcss.com/docs/font-style
1568
+ */
1569
+ 'font-style': ['italic', 'not-italic'],
1570
+ /**
1571
+ * Font Weight
1572
+ * @see https://tailwindcss.com/docs/font-weight
1573
+ */
1574
+ 'font-weight': [{
1575
+ font: ['thin', 'extralight', 'light', 'normal', 'medium', 'semibold', 'bold', 'extrabold', 'black', isArbitraryNumber]
1576
+ }],
1577
+ /**
1578
+ * Font Family
1579
+ * @see https://tailwindcss.com/docs/font-family
1580
+ */
1581
+ 'font-family': [{
1582
+ font: [isAny]
1583
+ }],
1584
+ /**
1585
+ * Font Variant Numeric
1586
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1587
+ */
1588
+ 'fvn-normal': ['normal-nums'],
1589
+ /**
1590
+ * Font Variant Numeric
1591
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1592
+ */
1593
+ 'fvn-ordinal': ['ordinal'],
1594
+ /**
1595
+ * Font Variant Numeric
1596
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1597
+ */
1598
+ 'fvn-slashed-zero': ['slashed-zero'],
1599
+ /**
1600
+ * Font Variant Numeric
1601
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1602
+ */
1603
+ 'fvn-figure': ['lining-nums', 'oldstyle-nums'],
1604
+ /**
1605
+ * Font Variant Numeric
1606
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1607
+ */
1608
+ 'fvn-spacing': ['proportional-nums', 'tabular-nums'],
1609
+ /**
1610
+ * Font Variant Numeric
1611
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1612
+ */
1613
+ 'fvn-fraction': ['diagonal-fractions', 'stacked-fractions'],
1614
+ /**
1615
+ * Letter Spacing
1616
+ * @see https://tailwindcss.com/docs/letter-spacing
1617
+ */
1618
+ tracking: [{
1619
+ tracking: ['tighter', 'tight', 'normal', 'wide', 'wider', 'widest', isArbitraryValue]
1620
+ }],
1621
+ /**
1622
+ * Line Clamp
1623
+ * @see https://tailwindcss.com/docs/line-clamp
1624
+ */
1625
+ 'line-clamp': [{
1626
+ 'line-clamp': ['none', isNumber, isArbitraryNumber]
1627
+ }],
1628
+ /**
1629
+ * Line Height
1630
+ * @see https://tailwindcss.com/docs/line-height
1631
+ */
1632
+ leading: [{
1633
+ leading: ['none', 'tight', 'snug', 'normal', 'relaxed', 'loose', isLength, isArbitraryValue]
1634
+ }],
1635
+ /**
1636
+ * List Style Image
1637
+ * @see https://tailwindcss.com/docs/list-style-image
1638
+ */
1639
+ 'list-image': [{
1640
+ 'list-image': ['none', isArbitraryValue]
1641
+ }],
1642
+ /**
1643
+ * List Style Type
1644
+ * @see https://tailwindcss.com/docs/list-style-type
1645
+ */
1646
+ 'list-style-type': [{
1647
+ list: ['none', 'disc', 'decimal', isArbitraryValue]
1648
+ }],
1649
+ /**
1650
+ * List Style Position
1651
+ * @see https://tailwindcss.com/docs/list-style-position
1652
+ */
1653
+ 'list-style-position': [{
1654
+ list: ['inside', 'outside']
1655
+ }],
1656
+ /**
1657
+ * Placeholder Color
1658
+ * @deprecated since Tailwind CSS v3.0.0
1659
+ * @see https://tailwindcss.com/docs/placeholder-color
1660
+ */
1661
+ 'placeholder-color': [{
1662
+ placeholder: [colors]
1663
+ }],
1664
+ /**
1665
+ * Placeholder Opacity
1666
+ * @see https://tailwindcss.com/docs/placeholder-opacity
1667
+ */
1668
+ 'placeholder-opacity': [{
1669
+ 'placeholder-opacity': [opacity]
1670
+ }],
1671
+ /**
1672
+ * Text Alignment
1673
+ * @see https://tailwindcss.com/docs/text-align
1674
+ */
1675
+ 'text-alignment': [{
1676
+ text: ['left', 'center', 'right', 'justify', 'start', 'end']
1677
+ }],
1678
+ /**
1679
+ * Text Color
1680
+ * @see https://tailwindcss.com/docs/text-color
1681
+ */
1682
+ 'text-color': [{
1683
+ text: [colors]
1684
+ }],
1685
+ /**
1686
+ * Text Opacity
1687
+ * @see https://tailwindcss.com/docs/text-opacity
1688
+ */
1689
+ 'text-opacity': [{
1690
+ 'text-opacity': [opacity]
1691
+ }],
1692
+ /**
1693
+ * Text Decoration
1694
+ * @see https://tailwindcss.com/docs/text-decoration
1695
+ */
1696
+ 'text-decoration': ['underline', 'overline', 'line-through', 'no-underline'],
1697
+ /**
1698
+ * Text Decoration Style
1699
+ * @see https://tailwindcss.com/docs/text-decoration-style
1700
+ */
1701
+ 'text-decoration-style': [{
1702
+ decoration: [...getLineStyles(), 'wavy']
1703
+ }],
1704
+ /**
1705
+ * Text Decoration Thickness
1706
+ * @see https://tailwindcss.com/docs/text-decoration-thickness
1707
+ */
1708
+ 'text-decoration-thickness': [{
1709
+ decoration: ['auto', 'from-font', isLength, isArbitraryLength]
1710
+ }],
1711
+ /**
1712
+ * Text Underline Offset
1713
+ * @see https://tailwindcss.com/docs/text-underline-offset
1714
+ */
1715
+ 'underline-offset': [{
1716
+ 'underline-offset': ['auto', isLength, isArbitraryValue]
1717
+ }],
1718
+ /**
1719
+ * Text Decoration Color
1720
+ * @see https://tailwindcss.com/docs/text-decoration-color
1721
+ */
1722
+ 'text-decoration-color': [{
1723
+ decoration: [colors]
1724
+ }],
1725
+ /**
1726
+ * Text Transform
1727
+ * @see https://tailwindcss.com/docs/text-transform
1728
+ */
1729
+ 'text-transform': ['uppercase', 'lowercase', 'capitalize', 'normal-case'],
1730
+ /**
1731
+ * Text Overflow
1732
+ * @see https://tailwindcss.com/docs/text-overflow
1733
+ */
1734
+ 'text-overflow': ['truncate', 'text-ellipsis', 'text-clip'],
1735
+ /**
1736
+ * Text Wrap
1737
+ * @see https://tailwindcss.com/docs/text-wrap
1738
+ */
1739
+ 'text-wrap': [{
1740
+ text: ['wrap', 'nowrap', 'balance', 'pretty']
1741
+ }],
1742
+ /**
1743
+ * Text Indent
1744
+ * @see https://tailwindcss.com/docs/text-indent
1745
+ */
1746
+ indent: [{
1747
+ indent: getSpacingWithArbitrary()
1748
+ }],
1749
+ /**
1750
+ * Vertical Alignment
1751
+ * @see https://tailwindcss.com/docs/vertical-align
1752
+ */
1753
+ 'vertical-align': [{
1754
+ align: ['baseline', 'top', 'middle', 'bottom', 'text-top', 'text-bottom', 'sub', 'super', isArbitraryValue]
1755
+ }],
1756
+ /**
1757
+ * Whitespace
1758
+ * @see https://tailwindcss.com/docs/whitespace
1759
+ */
1760
+ whitespace: [{
1761
+ whitespace: ['normal', 'nowrap', 'pre', 'pre-line', 'pre-wrap', 'break-spaces']
1762
+ }],
1763
+ /**
1764
+ * Word Break
1765
+ * @see https://tailwindcss.com/docs/word-break
1766
+ */
1767
+ break: [{
1768
+ break: ['normal', 'words', 'all', 'keep']
1769
+ }],
1770
+ /**
1771
+ * Hyphens
1772
+ * @see https://tailwindcss.com/docs/hyphens
1773
+ */
1774
+ hyphens: [{
1775
+ hyphens: ['none', 'manual', 'auto']
1776
+ }],
1777
+ /**
1778
+ * Content
1779
+ * @see https://tailwindcss.com/docs/content
1780
+ */
1781
+ content: [{
1782
+ content: ['none', isArbitraryValue]
1783
+ }],
1784
+ // Backgrounds
1785
+ /**
1786
+ * Background Attachment
1787
+ * @see https://tailwindcss.com/docs/background-attachment
1788
+ */
1789
+ 'bg-attachment': [{
1790
+ bg: ['fixed', 'local', 'scroll']
1791
+ }],
1792
+ /**
1793
+ * Background Clip
1794
+ * @see https://tailwindcss.com/docs/background-clip
1795
+ */
1796
+ 'bg-clip': [{
1797
+ 'bg-clip': ['border', 'padding', 'content', 'text']
1798
+ }],
1799
+ /**
1800
+ * Background Opacity
1801
+ * @deprecated since Tailwind CSS v3.0.0
1802
+ * @see https://tailwindcss.com/docs/background-opacity
1803
+ */
1804
+ 'bg-opacity': [{
1805
+ 'bg-opacity': [opacity]
1806
+ }],
1807
+ /**
1808
+ * Background Origin
1809
+ * @see https://tailwindcss.com/docs/background-origin
1810
+ */
1811
+ 'bg-origin': [{
1812
+ 'bg-origin': ['border', 'padding', 'content']
1813
+ }],
1814
+ /**
1815
+ * Background Position
1816
+ * @see https://tailwindcss.com/docs/background-position
1817
+ */
1818
+ 'bg-position': [{
1819
+ bg: [...getPositions(), isArbitraryPosition]
1820
+ }],
1821
+ /**
1822
+ * Background Repeat
1823
+ * @see https://tailwindcss.com/docs/background-repeat
1824
+ */
1825
+ 'bg-repeat': [{
1826
+ bg: ['no-repeat', {
1827
+ repeat: ['', 'x', 'y', 'round', 'space']
1828
+ }]
1829
+ }],
1830
+ /**
1831
+ * Background Size
1832
+ * @see https://tailwindcss.com/docs/background-size
1833
+ */
1834
+ 'bg-size': [{
1835
+ bg: ['auto', 'cover', 'contain', isArbitrarySize]
1836
+ }],
1837
+ /**
1838
+ * Background Image
1839
+ * @see https://tailwindcss.com/docs/background-image
1840
+ */
1841
+ 'bg-image': [{
1842
+ bg: ['none', {
1843
+ 'gradient-to': ['t', 'tr', 'r', 'br', 'b', 'bl', 'l', 'tl']
1844
+ }, isArbitraryImage]
1845
+ }],
1846
+ /**
1847
+ * Background Color
1848
+ * @see https://tailwindcss.com/docs/background-color
1849
+ */
1850
+ 'bg-color': [{
1851
+ bg: [colors]
1852
+ }],
1853
+ /**
1854
+ * Gradient Color Stops From Position
1855
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1856
+ */
1857
+ 'gradient-from-pos': [{
1858
+ from: [gradientColorStopPositions]
1859
+ }],
1860
+ /**
1861
+ * Gradient Color Stops Via Position
1862
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1863
+ */
1864
+ 'gradient-via-pos': [{
1865
+ via: [gradientColorStopPositions]
1866
+ }],
1867
+ /**
1868
+ * Gradient Color Stops To Position
1869
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1870
+ */
1871
+ 'gradient-to-pos': [{
1872
+ to: [gradientColorStopPositions]
1873
+ }],
1874
+ /**
1875
+ * Gradient Color Stops From
1876
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1877
+ */
1878
+ 'gradient-from': [{
1879
+ from: [gradientColorStops]
1880
+ }],
1881
+ /**
1882
+ * Gradient Color Stops Via
1883
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1884
+ */
1885
+ 'gradient-via': [{
1886
+ via: [gradientColorStops]
1887
+ }],
1888
+ /**
1889
+ * Gradient Color Stops To
1890
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1891
+ */
1892
+ 'gradient-to': [{
1893
+ to: [gradientColorStops]
1894
+ }],
1895
+ // Borders
1896
+ /**
1897
+ * Border Radius
1898
+ * @see https://tailwindcss.com/docs/border-radius
1899
+ */
1900
+ rounded: [{
1901
+ rounded: [borderRadius]
1902
+ }],
1903
+ /**
1904
+ * Border Radius Start
1905
+ * @see https://tailwindcss.com/docs/border-radius
1906
+ */
1907
+ 'rounded-s': [{
1908
+ 'rounded-s': [borderRadius]
1909
+ }],
1910
+ /**
1911
+ * Border Radius End
1912
+ * @see https://tailwindcss.com/docs/border-radius
1913
+ */
1914
+ 'rounded-e': [{
1915
+ 'rounded-e': [borderRadius]
1916
+ }],
1917
+ /**
1918
+ * Border Radius Top
1919
+ * @see https://tailwindcss.com/docs/border-radius
1920
+ */
1921
+ 'rounded-t': [{
1922
+ 'rounded-t': [borderRadius]
1923
+ }],
1924
+ /**
1925
+ * Border Radius Right
1926
+ * @see https://tailwindcss.com/docs/border-radius
1927
+ */
1928
+ 'rounded-r': [{
1929
+ 'rounded-r': [borderRadius]
1930
+ }],
1931
+ /**
1932
+ * Border Radius Bottom
1933
+ * @see https://tailwindcss.com/docs/border-radius
1934
+ */
1935
+ 'rounded-b': [{
1936
+ 'rounded-b': [borderRadius]
1937
+ }],
1938
+ /**
1939
+ * Border Radius Left
1940
+ * @see https://tailwindcss.com/docs/border-radius
1941
+ */
1942
+ 'rounded-l': [{
1943
+ 'rounded-l': [borderRadius]
1944
+ }],
1945
+ /**
1946
+ * Border Radius Start Start
1947
+ * @see https://tailwindcss.com/docs/border-radius
1948
+ */
1949
+ 'rounded-ss': [{
1950
+ 'rounded-ss': [borderRadius]
1951
+ }],
1952
+ /**
1953
+ * Border Radius Start End
1954
+ * @see https://tailwindcss.com/docs/border-radius
1955
+ */
1956
+ 'rounded-se': [{
1957
+ 'rounded-se': [borderRadius]
1958
+ }],
1959
+ /**
1960
+ * Border Radius End End
1961
+ * @see https://tailwindcss.com/docs/border-radius
1962
+ */
1963
+ 'rounded-ee': [{
1964
+ 'rounded-ee': [borderRadius]
1965
+ }],
1966
+ /**
1967
+ * Border Radius End Start
1968
+ * @see https://tailwindcss.com/docs/border-radius
1969
+ */
1970
+ 'rounded-es': [{
1971
+ 'rounded-es': [borderRadius]
1972
+ }],
1973
+ /**
1974
+ * Border Radius Top Left
1975
+ * @see https://tailwindcss.com/docs/border-radius
1976
+ */
1977
+ 'rounded-tl': [{
1978
+ 'rounded-tl': [borderRadius]
1979
+ }],
1980
+ /**
1981
+ * Border Radius Top Right
1982
+ * @see https://tailwindcss.com/docs/border-radius
1983
+ */
1984
+ 'rounded-tr': [{
1985
+ 'rounded-tr': [borderRadius]
1986
+ }],
1987
+ /**
1988
+ * Border Radius Bottom Right
1989
+ * @see https://tailwindcss.com/docs/border-radius
1990
+ */
1991
+ 'rounded-br': [{
1992
+ 'rounded-br': [borderRadius]
1993
+ }],
1994
+ /**
1995
+ * Border Radius Bottom Left
1996
+ * @see https://tailwindcss.com/docs/border-radius
1997
+ */
1998
+ 'rounded-bl': [{
1999
+ 'rounded-bl': [borderRadius]
2000
+ }],
2001
+ /**
2002
+ * Border Width
2003
+ * @see https://tailwindcss.com/docs/border-width
2004
+ */
2005
+ 'border-w': [{
2006
+ border: [borderWidth]
2007
+ }],
2008
+ /**
2009
+ * Border Width X
2010
+ * @see https://tailwindcss.com/docs/border-width
2011
+ */
2012
+ 'border-w-x': [{
2013
+ 'border-x': [borderWidth]
2014
+ }],
2015
+ /**
2016
+ * Border Width Y
2017
+ * @see https://tailwindcss.com/docs/border-width
2018
+ */
2019
+ 'border-w-y': [{
2020
+ 'border-y': [borderWidth]
2021
+ }],
2022
+ /**
2023
+ * Border Width Start
2024
+ * @see https://tailwindcss.com/docs/border-width
2025
+ */
2026
+ 'border-w-s': [{
2027
+ 'border-s': [borderWidth]
2028
+ }],
2029
+ /**
2030
+ * Border Width End
2031
+ * @see https://tailwindcss.com/docs/border-width
2032
+ */
2033
+ 'border-w-e': [{
2034
+ 'border-e': [borderWidth]
2035
+ }],
2036
+ /**
2037
+ * Border Width Top
2038
+ * @see https://tailwindcss.com/docs/border-width
2039
+ */
2040
+ 'border-w-t': [{
2041
+ 'border-t': [borderWidth]
2042
+ }],
2043
+ /**
2044
+ * Border Width Right
2045
+ * @see https://tailwindcss.com/docs/border-width
2046
+ */
2047
+ 'border-w-r': [{
2048
+ 'border-r': [borderWidth]
2049
+ }],
2050
+ /**
2051
+ * Border Width Bottom
2052
+ * @see https://tailwindcss.com/docs/border-width
2053
+ */
2054
+ 'border-w-b': [{
2055
+ 'border-b': [borderWidth]
2056
+ }],
2057
+ /**
2058
+ * Border Width Left
2059
+ * @see https://tailwindcss.com/docs/border-width
2060
+ */
2061
+ 'border-w-l': [{
2062
+ 'border-l': [borderWidth]
2063
+ }],
2064
+ /**
2065
+ * Border Opacity
2066
+ * @see https://tailwindcss.com/docs/border-opacity
2067
+ */
2068
+ 'border-opacity': [{
2069
+ 'border-opacity': [opacity]
2070
+ }],
2071
+ /**
2072
+ * Border Style
2073
+ * @see https://tailwindcss.com/docs/border-style
2074
+ */
2075
+ 'border-style': [{
2076
+ border: [...getLineStyles(), 'hidden']
2077
+ }],
2078
+ /**
2079
+ * Divide Width X
2080
+ * @see https://tailwindcss.com/docs/divide-width
2081
+ */
2082
+ 'divide-x': [{
2083
+ 'divide-x': [borderWidth]
2084
+ }],
2085
+ /**
2086
+ * Divide Width X Reverse
2087
+ * @see https://tailwindcss.com/docs/divide-width
2088
+ */
2089
+ 'divide-x-reverse': ['divide-x-reverse'],
2090
+ /**
2091
+ * Divide Width Y
2092
+ * @see https://tailwindcss.com/docs/divide-width
2093
+ */
2094
+ 'divide-y': [{
2095
+ 'divide-y': [borderWidth]
2096
+ }],
2097
+ /**
2098
+ * Divide Width Y Reverse
2099
+ * @see https://tailwindcss.com/docs/divide-width
2100
+ */
2101
+ 'divide-y-reverse': ['divide-y-reverse'],
2102
+ /**
2103
+ * Divide Opacity
2104
+ * @see https://tailwindcss.com/docs/divide-opacity
2105
+ */
2106
+ 'divide-opacity': [{
2107
+ 'divide-opacity': [opacity]
2108
+ }],
2109
+ /**
2110
+ * Divide Style
2111
+ * @see https://tailwindcss.com/docs/divide-style
2112
+ */
2113
+ 'divide-style': [{
2114
+ divide: getLineStyles()
2115
+ }],
2116
+ /**
2117
+ * Border Color
2118
+ * @see https://tailwindcss.com/docs/border-color
2119
+ */
2120
+ 'border-color': [{
2121
+ border: [borderColor]
2122
+ }],
2123
+ /**
2124
+ * Border Color X
2125
+ * @see https://tailwindcss.com/docs/border-color
2126
+ */
2127
+ 'border-color-x': [{
2128
+ 'border-x': [borderColor]
2129
+ }],
2130
+ /**
2131
+ * Border Color Y
2132
+ * @see https://tailwindcss.com/docs/border-color
2133
+ */
2134
+ 'border-color-y': [{
2135
+ 'border-y': [borderColor]
2136
+ }],
2137
+ /**
2138
+ * Border Color S
2139
+ * @see https://tailwindcss.com/docs/border-color
2140
+ */
2141
+ 'border-color-s': [{
2142
+ 'border-s': [borderColor]
2143
+ }],
2144
+ /**
2145
+ * Border Color E
2146
+ * @see https://tailwindcss.com/docs/border-color
2147
+ */
2148
+ 'border-color-e': [{
2149
+ 'border-e': [borderColor]
2150
+ }],
2151
+ /**
2152
+ * Border Color Top
2153
+ * @see https://tailwindcss.com/docs/border-color
2154
+ */
2155
+ 'border-color-t': [{
2156
+ 'border-t': [borderColor]
2157
+ }],
2158
+ /**
2159
+ * Border Color Right
2160
+ * @see https://tailwindcss.com/docs/border-color
2161
+ */
2162
+ 'border-color-r': [{
2163
+ 'border-r': [borderColor]
2164
+ }],
2165
+ /**
2166
+ * Border Color Bottom
2167
+ * @see https://tailwindcss.com/docs/border-color
2168
+ */
2169
+ 'border-color-b': [{
2170
+ 'border-b': [borderColor]
2171
+ }],
2172
+ /**
2173
+ * Border Color Left
2174
+ * @see https://tailwindcss.com/docs/border-color
2175
+ */
2176
+ 'border-color-l': [{
2177
+ 'border-l': [borderColor]
2178
+ }],
2179
+ /**
2180
+ * Divide Color
2181
+ * @see https://tailwindcss.com/docs/divide-color
2182
+ */
2183
+ 'divide-color': [{
2184
+ divide: [borderColor]
2185
+ }],
2186
+ /**
2187
+ * Outline Style
2188
+ * @see https://tailwindcss.com/docs/outline-style
2189
+ */
2190
+ 'outline-style': [{
2191
+ outline: ['', ...getLineStyles()]
2192
+ }],
2193
+ /**
2194
+ * Outline Offset
2195
+ * @see https://tailwindcss.com/docs/outline-offset
2196
+ */
2197
+ 'outline-offset': [{
2198
+ 'outline-offset': [isLength, isArbitraryValue]
2199
+ }],
2200
+ /**
2201
+ * Outline Width
2202
+ * @see https://tailwindcss.com/docs/outline-width
2203
+ */
2204
+ 'outline-w': [{
2205
+ outline: [isLength, isArbitraryLength]
2206
+ }],
2207
+ /**
2208
+ * Outline Color
2209
+ * @see https://tailwindcss.com/docs/outline-color
2210
+ */
2211
+ 'outline-color': [{
2212
+ outline: [colors]
2213
+ }],
2214
+ /**
2215
+ * Ring Width
2216
+ * @see https://tailwindcss.com/docs/ring-width
2217
+ */
2218
+ 'ring-w': [{
2219
+ ring: getLengthWithEmptyAndArbitrary()
2220
+ }],
2221
+ /**
2222
+ * Ring Width Inset
2223
+ * @see https://tailwindcss.com/docs/ring-width
2224
+ */
2225
+ 'ring-w-inset': ['ring-inset'],
2226
+ /**
2227
+ * Ring Color
2228
+ * @see https://tailwindcss.com/docs/ring-color
2229
+ */
2230
+ 'ring-color': [{
2231
+ ring: [colors]
2232
+ }],
2233
+ /**
2234
+ * Ring Opacity
2235
+ * @see https://tailwindcss.com/docs/ring-opacity
2236
+ */
2237
+ 'ring-opacity': [{
2238
+ 'ring-opacity': [opacity]
2239
+ }],
2240
+ /**
2241
+ * Ring Offset Width
2242
+ * @see https://tailwindcss.com/docs/ring-offset-width
2243
+ */
2244
+ 'ring-offset-w': [{
2245
+ 'ring-offset': [isLength, isArbitraryLength]
2246
+ }],
2247
+ /**
2248
+ * Ring Offset Color
2249
+ * @see https://tailwindcss.com/docs/ring-offset-color
2250
+ */
2251
+ 'ring-offset-color': [{
2252
+ 'ring-offset': [colors]
2253
+ }],
2254
+ // Effects
2255
+ /**
2256
+ * Box Shadow
2257
+ * @see https://tailwindcss.com/docs/box-shadow
2258
+ */
2259
+ shadow: [{
2260
+ shadow: ['', 'inner', 'none', isTshirtSize, isArbitraryShadow]
2261
+ }],
2262
+ /**
2263
+ * Box Shadow Color
2264
+ * @see https://tailwindcss.com/docs/box-shadow-color
2265
+ */
2266
+ 'shadow-color': [{
2267
+ shadow: [isAny]
2268
+ }],
2269
+ /**
2270
+ * Opacity
2271
+ * @see https://tailwindcss.com/docs/opacity
2272
+ */
2273
+ opacity: [{
2274
+ opacity: [opacity]
2275
+ }],
2276
+ /**
2277
+ * Mix Blend Mode
2278
+ * @see https://tailwindcss.com/docs/mix-blend-mode
2279
+ */
2280
+ 'mix-blend': [{
2281
+ 'mix-blend': [...getBlendModes(), 'plus-lighter', 'plus-darker']
2282
+ }],
2283
+ /**
2284
+ * Background Blend Mode
2285
+ * @see https://tailwindcss.com/docs/background-blend-mode
2286
+ */
2287
+ 'bg-blend': [{
2288
+ 'bg-blend': getBlendModes()
2289
+ }],
2290
+ // Filters
2291
+ /**
2292
+ * Filter
2293
+ * @deprecated since Tailwind CSS v3.0.0
2294
+ * @see https://tailwindcss.com/docs/filter
2295
+ */
2296
+ filter: [{
2297
+ filter: ['', 'none']
2298
+ }],
2299
+ /**
2300
+ * Blur
2301
+ * @see https://tailwindcss.com/docs/blur
2302
+ */
2303
+ blur: [{
2304
+ blur: [blur]
2305
+ }],
2306
+ /**
2307
+ * Brightness
2308
+ * @see https://tailwindcss.com/docs/brightness
2309
+ */
2310
+ brightness: [{
2311
+ brightness: [brightness]
2312
+ }],
2313
+ /**
2314
+ * Contrast
2315
+ * @see https://tailwindcss.com/docs/contrast
2316
+ */
2317
+ contrast: [{
2318
+ contrast: [contrast]
2319
+ }],
2320
+ /**
2321
+ * Drop Shadow
2322
+ * @see https://tailwindcss.com/docs/drop-shadow
2323
+ */
2324
+ 'drop-shadow': [{
2325
+ 'drop-shadow': ['', 'none', isTshirtSize, isArbitraryValue]
2326
+ }],
2327
+ /**
2328
+ * Grayscale
2329
+ * @see https://tailwindcss.com/docs/grayscale
2330
+ */
2331
+ grayscale: [{
2332
+ grayscale: [grayscale]
2333
+ }],
2334
+ /**
2335
+ * Hue Rotate
2336
+ * @see https://tailwindcss.com/docs/hue-rotate
2337
+ */
2338
+ 'hue-rotate': [{
2339
+ 'hue-rotate': [hueRotate]
2340
+ }],
2341
+ /**
2342
+ * Invert
2343
+ * @see https://tailwindcss.com/docs/invert
2344
+ */
2345
+ invert: [{
2346
+ invert: [invert]
2347
+ }],
2348
+ /**
2349
+ * Saturate
2350
+ * @see https://tailwindcss.com/docs/saturate
2351
+ */
2352
+ saturate: [{
2353
+ saturate: [saturate]
2354
+ }],
2355
+ /**
2356
+ * Sepia
2357
+ * @see https://tailwindcss.com/docs/sepia
2358
+ */
2359
+ sepia: [{
2360
+ sepia: [sepia]
2361
+ }],
2362
+ /**
2363
+ * Backdrop Filter
2364
+ * @deprecated since Tailwind CSS v3.0.0
2365
+ * @see https://tailwindcss.com/docs/backdrop-filter
2366
+ */
2367
+ 'backdrop-filter': [{
2368
+ 'backdrop-filter': ['', 'none']
2369
+ }],
2370
+ /**
2371
+ * Backdrop Blur
2372
+ * @see https://tailwindcss.com/docs/backdrop-blur
2373
+ */
2374
+ 'backdrop-blur': [{
2375
+ 'backdrop-blur': [blur]
2376
+ }],
2377
+ /**
2378
+ * Backdrop Brightness
2379
+ * @see https://tailwindcss.com/docs/backdrop-brightness
2380
+ */
2381
+ 'backdrop-brightness': [{
2382
+ 'backdrop-brightness': [brightness]
2383
+ }],
2384
+ /**
2385
+ * Backdrop Contrast
2386
+ * @see https://tailwindcss.com/docs/backdrop-contrast
2387
+ */
2388
+ 'backdrop-contrast': [{
2389
+ 'backdrop-contrast': [contrast]
2390
+ }],
2391
+ /**
2392
+ * Backdrop Grayscale
2393
+ * @see https://tailwindcss.com/docs/backdrop-grayscale
2394
+ */
2395
+ 'backdrop-grayscale': [{
2396
+ 'backdrop-grayscale': [grayscale]
2397
+ }],
2398
+ /**
2399
+ * Backdrop Hue Rotate
2400
+ * @see https://tailwindcss.com/docs/backdrop-hue-rotate
2401
+ */
2402
+ 'backdrop-hue-rotate': [{
2403
+ 'backdrop-hue-rotate': [hueRotate]
2404
+ }],
2405
+ /**
2406
+ * Backdrop Invert
2407
+ * @see https://tailwindcss.com/docs/backdrop-invert
2408
+ */
2409
+ 'backdrop-invert': [{
2410
+ 'backdrop-invert': [invert]
2411
+ }],
2412
+ /**
2413
+ * Backdrop Opacity
2414
+ * @see https://tailwindcss.com/docs/backdrop-opacity
2415
+ */
2416
+ 'backdrop-opacity': [{
2417
+ 'backdrop-opacity': [opacity]
2418
+ }],
2419
+ /**
2420
+ * Backdrop Saturate
2421
+ * @see https://tailwindcss.com/docs/backdrop-saturate
2422
+ */
2423
+ 'backdrop-saturate': [{
2424
+ 'backdrop-saturate': [saturate]
2425
+ }],
2426
+ /**
2427
+ * Backdrop Sepia
2428
+ * @see https://tailwindcss.com/docs/backdrop-sepia
2429
+ */
2430
+ 'backdrop-sepia': [{
2431
+ 'backdrop-sepia': [sepia]
2432
+ }],
2433
+ // Tables
2434
+ /**
2435
+ * Border Collapse
2436
+ * @see https://tailwindcss.com/docs/border-collapse
2437
+ */
2438
+ 'border-collapse': [{
2439
+ border: ['collapse', 'separate']
2440
+ }],
2441
+ /**
2442
+ * Border Spacing
2443
+ * @see https://tailwindcss.com/docs/border-spacing
2444
+ */
2445
+ 'border-spacing': [{
2446
+ 'border-spacing': [borderSpacing]
2447
+ }],
2448
+ /**
2449
+ * Border Spacing X
2450
+ * @see https://tailwindcss.com/docs/border-spacing
2451
+ */
2452
+ 'border-spacing-x': [{
2453
+ 'border-spacing-x': [borderSpacing]
2454
+ }],
2455
+ /**
2456
+ * Border Spacing Y
2457
+ * @see https://tailwindcss.com/docs/border-spacing
2458
+ */
2459
+ 'border-spacing-y': [{
2460
+ 'border-spacing-y': [borderSpacing]
2461
+ }],
2462
+ /**
2463
+ * Table Layout
2464
+ * @see https://tailwindcss.com/docs/table-layout
2465
+ */
2466
+ 'table-layout': [{
2467
+ table: ['auto', 'fixed']
2468
+ }],
2469
+ /**
2470
+ * Caption Side
2471
+ * @see https://tailwindcss.com/docs/caption-side
2472
+ */
2473
+ caption: [{
2474
+ caption: ['top', 'bottom']
2475
+ }],
2476
+ // Transitions and Animation
2477
+ /**
2478
+ * Tranisition Property
2479
+ * @see https://tailwindcss.com/docs/transition-property
2480
+ */
2481
+ transition: [{
2482
+ transition: ['none', 'all', '', 'colors', 'opacity', 'shadow', 'transform', isArbitraryValue]
2483
+ }],
2484
+ /**
2485
+ * Transition Duration
2486
+ * @see https://tailwindcss.com/docs/transition-duration
2487
+ */
2488
+ duration: [{
2489
+ duration: getNumberAndArbitrary()
2490
+ }],
2491
+ /**
2492
+ * Transition Timing Function
2493
+ * @see https://tailwindcss.com/docs/transition-timing-function
2494
+ */
2495
+ ease: [{
2496
+ ease: ['linear', 'in', 'out', 'in-out', isArbitraryValue]
2497
+ }],
2498
+ /**
2499
+ * Transition Delay
2500
+ * @see https://tailwindcss.com/docs/transition-delay
2501
+ */
2502
+ delay: [{
2503
+ delay: getNumberAndArbitrary()
2504
+ }],
2505
+ /**
2506
+ * Animation
2507
+ * @see https://tailwindcss.com/docs/animation
2508
+ */
2509
+ animate: [{
2510
+ animate: ['none', 'spin', 'ping', 'pulse', 'bounce', isArbitraryValue]
2511
+ }],
2512
+ // Transforms
2513
+ /**
2514
+ * Transform
2515
+ * @see https://tailwindcss.com/docs/transform
2516
+ */
2517
+ transform: [{
2518
+ transform: ['', 'gpu', 'none']
2519
+ }],
2520
+ /**
2521
+ * Scale
2522
+ * @see https://tailwindcss.com/docs/scale
2523
+ */
2524
+ scale: [{
2525
+ scale: [scale]
2526
+ }],
2527
+ /**
2528
+ * Scale X
2529
+ * @see https://tailwindcss.com/docs/scale
2530
+ */
2531
+ 'scale-x': [{
2532
+ 'scale-x': [scale]
2533
+ }],
2534
+ /**
2535
+ * Scale Y
2536
+ * @see https://tailwindcss.com/docs/scale
2537
+ */
2538
+ 'scale-y': [{
2539
+ 'scale-y': [scale]
2540
+ }],
2541
+ /**
2542
+ * Rotate
2543
+ * @see https://tailwindcss.com/docs/rotate
2544
+ */
2545
+ rotate: [{
2546
+ rotate: [isInteger, isArbitraryValue]
2547
+ }],
2548
+ /**
2549
+ * Translate X
2550
+ * @see https://tailwindcss.com/docs/translate
2551
+ */
2552
+ 'translate-x': [{
2553
+ 'translate-x': [translate]
2554
+ }],
2555
+ /**
2556
+ * Translate Y
2557
+ * @see https://tailwindcss.com/docs/translate
2558
+ */
2559
+ 'translate-y': [{
2560
+ 'translate-y': [translate]
2561
+ }],
2562
+ /**
2563
+ * Skew X
2564
+ * @see https://tailwindcss.com/docs/skew
2565
+ */
2566
+ 'skew-x': [{
2567
+ 'skew-x': [skew]
2568
+ }],
2569
+ /**
2570
+ * Skew Y
2571
+ * @see https://tailwindcss.com/docs/skew
2572
+ */
2573
+ 'skew-y': [{
2574
+ 'skew-y': [skew]
2575
+ }],
2576
+ /**
2577
+ * Transform Origin
2578
+ * @see https://tailwindcss.com/docs/transform-origin
2579
+ */
2580
+ 'transform-origin': [{
2581
+ origin: ['center', 'top', 'top-right', 'right', 'bottom-right', 'bottom', 'bottom-left', 'left', 'top-left', isArbitraryValue]
2582
+ }],
2583
+ // Interactivity
2584
+ /**
2585
+ * Accent Color
2586
+ * @see https://tailwindcss.com/docs/accent-color
2587
+ */
2588
+ accent: [{
2589
+ accent: ['auto', colors]
2590
+ }],
2591
+ /**
2592
+ * Appearance
2593
+ * @see https://tailwindcss.com/docs/appearance
2594
+ */
2595
+ appearance: [{
2596
+ appearance: ['none', 'auto']
2597
+ }],
2598
+ /**
2599
+ * Cursor
2600
+ * @see https://tailwindcss.com/docs/cursor
2601
+ */
2602
+ cursor: [{
2603
+ 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]
2604
+ }],
2605
+ /**
2606
+ * Caret Color
2607
+ * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
2608
+ */
2609
+ 'caret-color': [{
2610
+ caret: [colors]
2611
+ }],
2612
+ /**
2613
+ * Pointer Events
2614
+ * @see https://tailwindcss.com/docs/pointer-events
2615
+ */
2616
+ 'pointer-events': [{
2617
+ 'pointer-events': ['none', 'auto']
2618
+ }],
2619
+ /**
2620
+ * Resize
2621
+ * @see https://tailwindcss.com/docs/resize
2622
+ */
2623
+ resize: [{
2624
+ resize: ['none', 'y', 'x', '']
2625
+ }],
2626
+ /**
2627
+ * Scroll Behavior
2628
+ * @see https://tailwindcss.com/docs/scroll-behavior
2629
+ */
2630
+ 'scroll-behavior': [{
2631
+ scroll: ['auto', 'smooth']
2632
+ }],
2633
+ /**
2634
+ * Scroll Margin
2635
+ * @see https://tailwindcss.com/docs/scroll-margin
2636
+ */
2637
+ 'scroll-m': [{
2638
+ 'scroll-m': getSpacingWithArbitrary()
2639
+ }],
2640
+ /**
2641
+ * Scroll Margin X
2642
+ * @see https://tailwindcss.com/docs/scroll-margin
2643
+ */
2644
+ 'scroll-mx': [{
2645
+ 'scroll-mx': getSpacingWithArbitrary()
2646
+ }],
2647
+ /**
2648
+ * Scroll Margin Y
2649
+ * @see https://tailwindcss.com/docs/scroll-margin
2650
+ */
2651
+ 'scroll-my': [{
2652
+ 'scroll-my': getSpacingWithArbitrary()
2653
+ }],
2654
+ /**
2655
+ * Scroll Margin Start
2656
+ * @see https://tailwindcss.com/docs/scroll-margin
2657
+ */
2658
+ 'scroll-ms': [{
2659
+ 'scroll-ms': getSpacingWithArbitrary()
2660
+ }],
2661
+ /**
2662
+ * Scroll Margin End
2663
+ * @see https://tailwindcss.com/docs/scroll-margin
2664
+ */
2665
+ 'scroll-me': [{
2666
+ 'scroll-me': getSpacingWithArbitrary()
2667
+ }],
2668
+ /**
2669
+ * Scroll Margin Top
2670
+ * @see https://tailwindcss.com/docs/scroll-margin
2671
+ */
2672
+ 'scroll-mt': [{
2673
+ 'scroll-mt': getSpacingWithArbitrary()
2674
+ }],
2675
+ /**
2676
+ * Scroll Margin Right
2677
+ * @see https://tailwindcss.com/docs/scroll-margin
2678
+ */
2679
+ 'scroll-mr': [{
2680
+ 'scroll-mr': getSpacingWithArbitrary()
2681
+ }],
2682
+ /**
2683
+ * Scroll Margin Bottom
2684
+ * @see https://tailwindcss.com/docs/scroll-margin
2685
+ */
2686
+ 'scroll-mb': [{
2687
+ 'scroll-mb': getSpacingWithArbitrary()
2688
+ }],
2689
+ /**
2690
+ * Scroll Margin Left
2691
+ * @see https://tailwindcss.com/docs/scroll-margin
2692
+ */
2693
+ 'scroll-ml': [{
2694
+ 'scroll-ml': getSpacingWithArbitrary()
2695
+ }],
2696
+ /**
2697
+ * Scroll Padding
2698
+ * @see https://tailwindcss.com/docs/scroll-padding
2699
+ */
2700
+ 'scroll-p': [{
2701
+ 'scroll-p': getSpacingWithArbitrary()
2702
+ }],
2703
+ /**
2704
+ * Scroll Padding X
2705
+ * @see https://tailwindcss.com/docs/scroll-padding
2706
+ */
2707
+ 'scroll-px': [{
2708
+ 'scroll-px': getSpacingWithArbitrary()
2709
+ }],
2710
+ /**
2711
+ * Scroll Padding Y
2712
+ * @see https://tailwindcss.com/docs/scroll-padding
2713
+ */
2714
+ 'scroll-py': [{
2715
+ 'scroll-py': getSpacingWithArbitrary()
2716
+ }],
2717
+ /**
2718
+ * Scroll Padding Start
2719
+ * @see https://tailwindcss.com/docs/scroll-padding
2720
+ */
2721
+ 'scroll-ps': [{
2722
+ 'scroll-ps': getSpacingWithArbitrary()
2723
+ }],
2724
+ /**
2725
+ * Scroll Padding End
2726
+ * @see https://tailwindcss.com/docs/scroll-padding
2727
+ */
2728
+ 'scroll-pe': [{
2729
+ 'scroll-pe': getSpacingWithArbitrary()
2730
+ }],
2731
+ /**
2732
+ * Scroll Padding Top
2733
+ * @see https://tailwindcss.com/docs/scroll-padding
2734
+ */
2735
+ 'scroll-pt': [{
2736
+ 'scroll-pt': getSpacingWithArbitrary()
2737
+ }],
2738
+ /**
2739
+ * Scroll Padding Right
2740
+ * @see https://tailwindcss.com/docs/scroll-padding
2741
+ */
2742
+ 'scroll-pr': [{
2743
+ 'scroll-pr': getSpacingWithArbitrary()
2744
+ }],
2745
+ /**
2746
+ * Scroll Padding Bottom
2747
+ * @see https://tailwindcss.com/docs/scroll-padding
2748
+ */
2749
+ 'scroll-pb': [{
2750
+ 'scroll-pb': getSpacingWithArbitrary()
2751
+ }],
2752
+ /**
2753
+ * Scroll Padding Left
2754
+ * @see https://tailwindcss.com/docs/scroll-padding
2755
+ */
2756
+ 'scroll-pl': [{
2757
+ 'scroll-pl': getSpacingWithArbitrary()
2758
+ }],
2759
+ /**
2760
+ * Scroll Snap Align
2761
+ * @see https://tailwindcss.com/docs/scroll-snap-align
2762
+ */
2763
+ 'snap-align': [{
2764
+ snap: ['start', 'end', 'center', 'align-none']
2765
+ }],
2766
+ /**
2767
+ * Scroll Snap Stop
2768
+ * @see https://tailwindcss.com/docs/scroll-snap-stop
2769
+ */
2770
+ 'snap-stop': [{
2771
+ snap: ['normal', 'always']
2772
+ }],
2773
+ /**
2774
+ * Scroll Snap Type
2775
+ * @see https://tailwindcss.com/docs/scroll-snap-type
2776
+ */
2777
+ 'snap-type': [{
2778
+ snap: ['none', 'x', 'y', 'both']
2779
+ }],
2780
+ /**
2781
+ * Scroll Snap Type Strictness
2782
+ * @see https://tailwindcss.com/docs/scroll-snap-type
2783
+ */
2784
+ 'snap-strictness': [{
2785
+ snap: ['mandatory', 'proximity']
2786
+ }],
2787
+ /**
2788
+ * Touch Action
2789
+ * @see https://tailwindcss.com/docs/touch-action
2790
+ */
2791
+ touch: [{
2792
+ touch: ['auto', 'none', 'manipulation']
2793
+ }],
2794
+ /**
2795
+ * Touch Action X
2796
+ * @see https://tailwindcss.com/docs/touch-action
2797
+ */
2798
+ 'touch-x': [{
2799
+ 'touch-pan': ['x', 'left', 'right']
2800
+ }],
2801
+ /**
2802
+ * Touch Action Y
2803
+ * @see https://tailwindcss.com/docs/touch-action
2804
+ */
2805
+ 'touch-y': [{
2806
+ 'touch-pan': ['y', 'up', 'down']
2807
+ }],
2808
+ /**
2809
+ * Touch Action Pinch Zoom
2810
+ * @see https://tailwindcss.com/docs/touch-action
2811
+ */
2812
+ 'touch-pz': ['touch-pinch-zoom'],
2813
+ /**
2814
+ * User Select
2815
+ * @see https://tailwindcss.com/docs/user-select
2816
+ */
2817
+ select: [{
2818
+ select: ['none', 'text', 'all', 'auto']
2819
+ }],
2820
+ /**
2821
+ * Will Change
2822
+ * @see https://tailwindcss.com/docs/will-change
2823
+ */
2824
+ 'will-change': [{
2825
+ 'will-change': ['auto', 'scroll', 'contents', 'transform', isArbitraryValue]
2826
+ }],
2827
+ // SVG
2828
+ /**
2829
+ * Fill
2830
+ * @see https://tailwindcss.com/docs/fill
2831
+ */
2832
+ fill: [{
2833
+ fill: [colors, 'none']
2834
+ }],
2835
+ /**
2836
+ * Stroke Width
2837
+ * @see https://tailwindcss.com/docs/stroke-width
2838
+ */
2839
+ 'stroke-w': [{
2840
+ stroke: [isLength, isArbitraryLength, isArbitraryNumber]
2841
+ }],
2842
+ /**
2843
+ * Stroke
2844
+ * @see https://tailwindcss.com/docs/stroke
2845
+ */
2846
+ stroke: [{
2847
+ stroke: [colors, 'none']
2848
+ }],
2849
+ // Accessibility
2850
+ /**
2851
+ * Screen Readers
2852
+ * @see https://tailwindcss.com/docs/screen-readers
2853
+ */
2854
+ sr: ['sr-only', 'not-sr-only'],
2855
+ /**
2856
+ * Forced Color Adjust
2857
+ * @see https://tailwindcss.com/docs/forced-color-adjust
2858
+ */
2859
+ 'forced-color-adjust': [{
2860
+ 'forced-color-adjust': ['auto', 'none']
2861
+ }]
2862
+ },
2863
+ conflictingClassGroups: {
2864
+ overflow: ['overflow-x', 'overflow-y'],
2865
+ overscroll: ['overscroll-x', 'overscroll-y'],
2866
+ inset: ['inset-x', 'inset-y', 'start', 'end', 'top', 'right', 'bottom', 'left'],
2867
+ 'inset-x': ['right', 'left'],
2868
+ 'inset-y': ['top', 'bottom'],
2869
+ flex: ['basis', 'grow', 'shrink'],
2870
+ gap: ['gap-x', 'gap-y'],
2871
+ p: ['px', 'py', 'ps', 'pe', 'pt', 'pr', 'pb', 'pl'],
2872
+ px: ['pr', 'pl'],
2873
+ py: ['pt', 'pb'],
2874
+ m: ['mx', 'my', 'ms', 'me', 'mt', 'mr', 'mb', 'ml'],
2875
+ mx: ['mr', 'ml'],
2876
+ my: ['mt', 'mb'],
2877
+ size: ['w', 'h'],
2878
+ 'font-size': ['leading'],
2879
+ 'fvn-normal': ['fvn-ordinal', 'fvn-slashed-zero', 'fvn-figure', 'fvn-spacing', 'fvn-fraction'],
2880
+ 'fvn-ordinal': ['fvn-normal'],
2881
+ 'fvn-slashed-zero': ['fvn-normal'],
2882
+ 'fvn-figure': ['fvn-normal'],
2883
+ 'fvn-spacing': ['fvn-normal'],
2884
+ 'fvn-fraction': ['fvn-normal'],
2885
+ 'line-clamp': ['display', 'overflow'],
2886
+ 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'],
2887
+ 'rounded-s': ['rounded-ss', 'rounded-es'],
2888
+ 'rounded-e': ['rounded-se', 'rounded-ee'],
2889
+ 'rounded-t': ['rounded-tl', 'rounded-tr'],
2890
+ 'rounded-r': ['rounded-tr', 'rounded-br'],
2891
+ 'rounded-b': ['rounded-br', 'rounded-bl'],
2892
+ 'rounded-l': ['rounded-tl', 'rounded-bl'],
2893
+ 'border-spacing': ['border-spacing-x', 'border-spacing-y'],
2894
+ 'border-w': ['border-w-s', 'border-w-e', 'border-w-t', 'border-w-r', 'border-w-b', 'border-w-l'],
2895
+ 'border-w-x': ['border-w-r', 'border-w-l'],
2896
+ 'border-w-y': ['border-w-t', 'border-w-b'],
2897
+ 'border-color': ['border-color-s', 'border-color-e', 'border-color-t', 'border-color-r', 'border-color-b', 'border-color-l'],
2898
+ 'border-color-x': ['border-color-r', 'border-color-l'],
2899
+ 'border-color-y': ['border-color-t', 'border-color-b'],
2900
+ 'scroll-m': ['scroll-mx', 'scroll-my', 'scroll-ms', 'scroll-me', 'scroll-mt', 'scroll-mr', 'scroll-mb', 'scroll-ml'],
2901
+ 'scroll-mx': ['scroll-mr', 'scroll-ml'],
2902
+ 'scroll-my': ['scroll-mt', 'scroll-mb'],
2903
+ 'scroll-p': ['scroll-px', 'scroll-py', 'scroll-ps', 'scroll-pe', 'scroll-pt', 'scroll-pr', 'scroll-pb', 'scroll-pl'],
2904
+ 'scroll-px': ['scroll-pr', 'scroll-pl'],
2905
+ 'scroll-py': ['scroll-pt', 'scroll-pb'],
2906
+ touch: ['touch-x', 'touch-y', 'touch-pz'],
2907
+ 'touch-x': ['touch'],
2908
+ 'touch-y': ['touch'],
2909
+ 'touch-pz': ['touch']
2910
+ },
2911
+ conflictingClassGroupModifiers: {
2912
+ 'font-size': ['leading']
2913
+ }
2914
+ };
2915
+ };
2916
+ const twMerge = /*#__PURE__*/createTailwindMerge(getDefaultConfig);
2917
+
2918
+ /**
2919
+ * Utility function to merge Tailwind classes with clsx
2920
+ */
2921
+ const cn = (...inputs) => {
2922
+ return twMerge(clsx(inputs));
2923
+ };
2924
+ /**
2925
+ * Sets up container styles and rotation handling
2926
+ */
2927
+ const setupContainerStyles = (containerMarquee, marquees, marqueesChildren, isVertical, props) => {
2928
+ const { spacing = 16, alignRotationWithY = false } = props;
2929
+ gsap.set(containerMarquee, {
2930
+ gap: `${spacing}px`,
2931
+ rotate: isVertical ? 90 : "0",
2932
+ });
2933
+ if (isVertical) {
2934
+ gsap.set(containerMarquee, { width: window.innerHeight });
2935
+ }
2936
+ if (alignRotationWithY && marquees.length > 0) {
2937
+ const marqueeHeight = marquees[0].offsetHeight;
2938
+ gsap.set(containerMarquee, {
2939
+ alignItems: "center",
2940
+ });
2941
+ gsap.set(marqueesChildren, {
2942
+ rotate: -90,
2943
+ display: "flex",
2944
+ flexWrap: "wrap",
2945
+ width: marqueeHeight,
2946
+ wordBreak: "break-all",
2947
+ whiteSpace: "break-spaces",
2948
+ });
2949
+ }
2950
+ };
2951
+ /**
2952
+ * Calculates the number of duplicates needed to fill the container
2953
+ */
2954
+ const calculateDuplicates = (marqueeChildrenWidth, containerMarqueeWidth, isVertical, props) => {
2955
+ if (!props.fill)
2956
+ return 1;
2957
+ const targetWidth = isVertical ? window.innerHeight : containerMarqueeWidth;
2958
+ return marqueeChildrenWidth < targetWidth
2959
+ ? Math.ceil(targetWidth / marqueeChildrenWidth)
2960
+ : 1;
2961
+ };
2962
+ /**
2963
+ * Determines the minimum width for marquee elements
2964
+ */
2965
+ const getMinWidth = (marqueesChildren, totalWidth, containerMarqueeWidth, props) => {
2966
+ const { fill = false, alignRotationWithY = false } = props;
2967
+ if (fill)
2968
+ return "auto";
2969
+ if (alignRotationWithY && marqueesChildren.length > 0) {
2970
+ return `${marqueesChildren[0].offsetHeight}px`;
2971
+ }
2972
+ if (totalWidth < containerMarqueeWidth)
2973
+ return "100%";
2974
+ return `${totalWidth}px`;
2975
+ };
2976
+ /**
2977
+ * Creates a simple infinite marquee animation
2978
+ */
2979
+ const simpleAnimation = (marquees, marqueeChildrenDimension, isReverse, props) => {
2980
+ const { spacing = 16, speed = 100, loop = -1 } = props;
2981
+ const tween = gsap.to(marquees, {
2982
+ xPercent: (_, el) => {
2983
+ const w = parseFloat(String(gsap.getProperty(el, "width", "px")));
2984
+ const xPercent = ((w + spacing) / w) * 100;
2985
+ return -xPercent;
2986
+ },
2987
+ duration: (marqueeChildrenDimension - spacing) / speed,
2988
+ repeat: loop,
2989
+ ease: "none",
2990
+ });
2991
+ tween.play();
2992
+ if (isReverse) {
2993
+ tween.totalTime(tween.rawTime() + tween.duration() * 100);
2994
+ tween.reverse();
2995
+ }
2996
+ };
2997
+ /**
2998
+ * Creates a complex fill-based marquee animation with seamless looping
2999
+ */
3000
+ const fillAnimation = (marqueesChildren, startX, tl, isReverse, props) => {
3001
+ const { spacing = 16, speed = 100 } = props;
3002
+ const widths = [];
3003
+ const xPercents = [];
3004
+ const latestPos = marqueesChildren.length - 1;
3005
+ // Set initial positions and calculate percentages
3006
+ gsap.set(marqueesChildren, {
3007
+ xPercent: (i, el) => {
3008
+ const w = (widths[i] = parseFloat(String(gsap.getProperty(el, "width", "px"))));
3009
+ xPercents[i] =
3010
+ (parseFloat(String(gsap.getProperty(el, "x", "px"))) / w) * 100 +
3011
+ Number(gsap.getProperty(el, "xPercent"));
3012
+ return xPercents[i];
3013
+ },
3014
+ });
3015
+ gsap.set(marqueesChildren, { x: 0 });
3016
+ // Calculate the total track length for seamless looping
3017
+ const trackLength = marqueesChildren[latestPos].offsetLeft +
3018
+ (xPercents[latestPos] / 100) * widths[latestPos] -
3019
+ startX +
3020
+ marqueesChildren[latestPos].offsetWidth +
3021
+ spacing;
3022
+ // Create animation timeline for each element
3023
+ marqueesChildren.forEach((item, i) => {
3024
+ const curX = (xPercents[i] / 100) * widths[i];
3025
+ const distanceToStart = item.offsetLeft + curX - startX;
3026
+ const distanceToLoop = distanceToStart + widths[i];
3027
+ tl.to(item, {
3028
+ xPercent: ((curX - distanceToLoop) / widths[i]) * 100,
3029
+ duration: distanceToLoop / speed,
3030
+ }, 0).fromTo(item, {
3031
+ xPercent: ((curX - distanceToLoop + trackLength) / widths[i]) * 100,
3032
+ }, {
3033
+ xPercent: xPercents[i],
3034
+ duration: (curX - distanceToLoop + trackLength - curX) / speed,
3035
+ immediateRender: false,
3036
+ }, distanceToLoop / speed);
3037
+ });
3038
+ // Pre-render for performance optimization
3039
+ tl.progress(1, true).progress(0, true);
3040
+ if (isReverse) {
3041
+ tl.totalTime(tl.rawTime() + tl.duration() * 100);
3042
+ tl.reverse();
3043
+ }
3044
+ };
3045
+
3046
+ const GSAPReactMarquee = forwardRef((props, ref) => {
3047
+ const { children, className, dir = "left", loop = -1, paused = false, fill = false, alignRotationWithY, } = props;
3048
+ const rootRef = useRef(null) || ref;
3049
+ const containerRef = rootRef;
3050
+ const marqueeRef = useRef(null);
3051
+ const [marqueeDuplicates, setMarqueeDuplicates] = useState(1);
3052
+ const isVertical = dir === "up" || dir === "down";
3053
+ const isReverse = dir === "down" || dir === "right";
3054
+ useGSAP(() => {
3055
+ if (!(marqueeRef === null || marqueeRef === void 0 ? void 0 : marqueeRef.current) || !containerRef.current)
3056
+ return;
3057
+ const containerMarquee = containerRef === null || containerRef === void 0 ? void 0 : containerRef.current;
3058
+ const marquees = gsap.utils.toArray(containerMarquee.querySelectorAll(".gsap-react-marquee"));
3059
+ const marqueesChildren = gsap.utils.toArray(containerMarquee.querySelectorAll(".gsap-react-marquee .gsap-react-marquee-content"));
3060
+ const marquee = marqueeRef.current;
3061
+ if (!marquee || !marqueesChildren)
3062
+ return;
3063
+ const tl = gsap.timeline({
3064
+ repeat: loop,
3065
+ paused: paused,
3066
+ defaults: { ease: "none" },
3067
+ onReverseComplete() {
3068
+ // start the animation from the end, when scrolling in reverse (up)
3069
+ tl.totalTime(tl.rawTime() + tl.duration() * 100);
3070
+ },
3071
+ });
3072
+ // Setup container and initial styles
3073
+ setupContainerStyles(containerMarquee, marquees, marqueesChildren, isVertical, props);
3074
+ // Calculate dimensions and duplicates
3075
+ const containerMarqueeWidth = containerMarquee.offsetWidth;
3076
+ const marqueeHeight = marquees[0].offsetHeight;
3077
+ const marqueeChildrenWidth = marqueesChildren[0].offsetWidth;
3078
+ const startX = marqueesChildren[0].offsetLeft;
3079
+ setMarqueeDuplicates(calculateDuplicates(marqueeChildrenWidth, containerMarqueeWidth, isVertical, props));
3080
+ // Calculate total width and set marquee styles
3081
+ const totalWidth = gsap.utils
3082
+ .toArray(marquee.children)
3083
+ .map((child) => child.offsetWidth)
3084
+ .reduce((a, b) => a + b, 0);
3085
+ gsap.set(marquees, {
3086
+ minWidth: getMinWidth(marqueesChildren, totalWidth, containerMarqueeWidth, props),
3087
+ flex: fill ? "0 0 auto" : "1",
3088
+ });
3089
+ // Create appropriate animation based on fill setting
3090
+ if (fill) {
3091
+ fillAnimation(marqueesChildren, startX, tl, isReverse, props);
3092
+ }
3093
+ else {
3094
+ simpleAnimation(marquees, isVertical && alignRotationWithY
3095
+ ? marqueeHeight
3096
+ : marqueeChildrenWidth, isReverse, props);
3097
+ }
3098
+ }, { dependencies: [marqueeDuplicates] });
3099
+ const clonedMarquees = useMemo(() => {
3100
+ if (!Number.isFinite(marqueeDuplicates) || marqueeDuplicates <= 0)
3101
+ return null;
3102
+ return Array.from({ length: marqueeDuplicates }, (_, i) => (jsxRuntimeExports.jsx("div", { className: cn("gsap-react-marquee"), children: jsxRuntimeExports.jsx("div", { className: cn("gsap-react-marquee-content", className), children: children }) }, i)));
3103
+ }, [marqueeDuplicates, className, children]);
3104
+ return (jsxRuntimeExports.jsxs("div", { ref: containerRef, className: cn("gsap-react-marquee-container flex w-full overflow-hidden whitespace-nowrap"), children: [jsxRuntimeExports.jsx("div", { ref: marqueeRef, className: cn("gsap-react-marquee"), children: jsxRuntimeExports.jsx("div", { className: cn("gsap-react-marquee-content", className), children: children }) }), clonedMarquees] }));
3105
+ });
3106
+ GSAPReactMarquee.displayName = "GSAPReactMarquee";
3107
+
3108
+ export { GSAPReactMarquee, calculateDuplicates, cn, fillAnimation, getMinWidth, setupContainerStyles, simpleAnimation };
3109
+ //# sourceMappingURL=index.esm.js.map