customer-registration 0.0.111 → 0.0.113

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