@nextui-org/theme 2.3.0-beta.8 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-6CPZ7K75.mjs +444 -0
- package/dist/{chunk-IZOPFGDE.mjs → chunk-6KWI4IHE.mjs} +82 -1
- package/dist/chunk-AHEUDQZM.mjs +18 -0
- package/dist/{chunk-3ANIDDEW.mjs → chunk-IDHWVJY2.mjs} +1 -1
- package/dist/{chunk-MXL6JCUG.mjs → chunk-KOCBDPPO.mjs} +29 -6
- package/dist/{chunk-K6KPB2U5.mjs → chunk-PTCUE3XA.mjs} +11 -1
- package/dist/{chunk-HNRFZTEX.mjs → chunk-TK7HBD3N.mjs} +2 -1
- package/dist/{chunk-2TAKWWRG.mjs → chunk-ZZ2VSLD6.mjs} +1 -1
- package/dist/components/accordion.mjs +2 -1
- package/dist/components/alert.mjs +2 -1
- package/dist/components/autocomplete.js +1 -1
- package/dist/components/autocomplete.mjs +1 -1
- package/dist/components/avatar.mjs +2 -1
- package/dist/components/badge.mjs +2 -1
- package/dist/components/breadcrumbs.mjs +2 -1
- package/dist/components/button.mjs +2 -1
- package/dist/components/calendar.mjs +2 -1
- package/dist/components/card.mjs +2 -1
- package/dist/components/checkbox.mjs +2 -1
- package/dist/components/chip.mjs +2 -1
- package/dist/components/code.mjs +2 -1
- package/dist/components/date-input.d.ts +7 -0
- package/dist/components/date-input.js +2 -1
- package/dist/components/date-input.mjs +1 -1
- package/dist/components/dropdown.mjs +2 -1
- package/dist/components/index.d.ts +2 -2
- package/dist/components/index.js +480 -12
- package/dist/components/index.mjs +17 -14
- package/dist/components/input-otp.d.ts +603 -0
- package/dist/components/input-otp.js +518 -0
- package/dist/components/input-otp.mjs +13 -0
- package/dist/components/input.d.ts +21 -7
- package/dist/components/input.js +29 -6
- package/dist/components/input.mjs +3 -2
- package/dist/components/link.mjs +2 -1
- package/dist/components/listbox.js +11 -1
- package/dist/components/listbox.mjs +3 -2
- package/dist/components/menu.d.ts +70 -0
- package/dist/components/menu.js +11 -1
- package/dist/components/menu.mjs +3 -2
- package/dist/components/modal.mjs +2 -1
- package/dist/components/navbar.mjs +2 -1
- package/dist/components/pagination.mjs +2 -1
- package/dist/components/popover.mjs +2 -1
- package/dist/components/progress.d.ts +426 -1
- package/dist/components/progress.js +82 -0
- package/dist/components/progress.mjs +3 -1
- package/dist/components/radio.mjs +2 -1
- package/dist/components/select.js +1 -1
- package/dist/components/select.mjs +3 -2
- package/dist/components/slider.mjs +2 -1
- package/dist/components/snippet.mjs +2 -1
- package/dist/components/table.mjs +2 -1
- package/dist/components/tabs.mjs +2 -1
- package/dist/components/toggle.mjs +2 -1
- package/dist/components/user.mjs +2 -1
- package/dist/index.d.ts +3 -2
- package/dist/index.js +500 -15
- package/dist/index.mjs +20 -14
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/index.js +17 -0
- package/dist/utils/index.mjs +5 -1
- package/dist/utils/merge-classes.d.ts +12 -0
- package/dist/utils/merge-classes.js +42 -0
- package/dist/utils/merge-classes.mjs +6 -0
- package/package.json +2 -2
- package/dist/chunk-AUN4SP2F.mjs +0 -89
- package/dist/components/circular-progress.d.ts +0 -430
- package/dist/components/circular-progress.js +0 -157
- package/dist/components/circular-progress.mjs +0 -8
- /package/dist/{chunk-IV3K5WDK.mjs → chunk-CWYZ2GEH.mjs} +0 -0
|
@@ -0,0 +1,444 @@
|
|
|
1
|
+
import {
|
|
2
|
+
tv
|
|
3
|
+
} from "./chunk-UWE6H66T.mjs";
|
|
4
|
+
import {
|
|
5
|
+
dataFocusVisibleClasses
|
|
6
|
+
} from "./chunk-XHQUSKIE.mjs";
|
|
7
|
+
|
|
8
|
+
// src/components/input-otp.ts
|
|
9
|
+
var inputOtp = tv({
|
|
10
|
+
slots: {
|
|
11
|
+
base: ["relative", "flex", "flex-col", "w-fit"],
|
|
12
|
+
wrapper: ["group", "flex items-center", "has-[:disabled]:opacity-60"],
|
|
13
|
+
input: [
|
|
14
|
+
"absolute",
|
|
15
|
+
"inset-0",
|
|
16
|
+
"border-none",
|
|
17
|
+
"outline-none",
|
|
18
|
+
"bg-transparent",
|
|
19
|
+
"text-transparent"
|
|
20
|
+
],
|
|
21
|
+
segmentWrapper: ["inline-flex", "gap-x-1", "py-2"],
|
|
22
|
+
segment: [
|
|
23
|
+
"h-10",
|
|
24
|
+
"w-10",
|
|
25
|
+
"font-semibold",
|
|
26
|
+
"flex",
|
|
27
|
+
"justify-center",
|
|
28
|
+
"items-center",
|
|
29
|
+
"border-default-200",
|
|
30
|
+
"data-[active=true]:border-default-400",
|
|
31
|
+
"data-[active=true]:scale-110",
|
|
32
|
+
"shadow-sm",
|
|
33
|
+
"hover:bg-danger",
|
|
34
|
+
...dataFocusVisibleClasses
|
|
35
|
+
],
|
|
36
|
+
passwordChar: ["w-1", "h-1", "bg-default-800", "rounded-full"],
|
|
37
|
+
caret: [
|
|
38
|
+
"animate-[appearance-in_1s_infinite]",
|
|
39
|
+
"font-extralight",
|
|
40
|
+
"h-full",
|
|
41
|
+
"w-full",
|
|
42
|
+
"flex",
|
|
43
|
+
"justify-center",
|
|
44
|
+
"items-center",
|
|
45
|
+
"text-2xl",
|
|
46
|
+
"h-[50%]",
|
|
47
|
+
"w-px",
|
|
48
|
+
"bg-foreground"
|
|
49
|
+
],
|
|
50
|
+
helperWrapper: ["text-tiny", "mt-0.5", "font-extralight", ""],
|
|
51
|
+
errorMessage: ["text-tiny text-danger w-full"],
|
|
52
|
+
description: ["text-tiny text-foreground-400"]
|
|
53
|
+
},
|
|
54
|
+
variants: {
|
|
55
|
+
variant: {
|
|
56
|
+
flat: {
|
|
57
|
+
segment: ["border-transparent", "bg-default-100", "data-[active=true]:bg-default-200"]
|
|
58
|
+
},
|
|
59
|
+
faded: {
|
|
60
|
+
segment: ["bg-default-100", "border-medium"]
|
|
61
|
+
},
|
|
62
|
+
bordered: {
|
|
63
|
+
segment: ["border-medium"]
|
|
64
|
+
},
|
|
65
|
+
underlined: {
|
|
66
|
+
segment: [
|
|
67
|
+
"shadow-none",
|
|
68
|
+
"relative",
|
|
69
|
+
"box-border",
|
|
70
|
+
"!rounded-none",
|
|
71
|
+
"border-b-medium",
|
|
72
|
+
"shadow-[0_1px_0px_0_rgba(0,0,0,0.05)]",
|
|
73
|
+
"border-default-200",
|
|
74
|
+
"after:content-['']",
|
|
75
|
+
"after:w-0",
|
|
76
|
+
"after:origin-center",
|
|
77
|
+
"after:bg-default-foreground",
|
|
78
|
+
"after:absolute",
|
|
79
|
+
"after:left-1/2",
|
|
80
|
+
"after:-translate-x-1/2",
|
|
81
|
+
"after:-bottom-[2px]",
|
|
82
|
+
"after:h-[2px]",
|
|
83
|
+
"data-[active=true]:border-default-300",
|
|
84
|
+
"data-[active=true]:after:w-full",
|
|
85
|
+
"data-[active=true]:scale-100"
|
|
86
|
+
]
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
isDisabled: {
|
|
90
|
+
true: {
|
|
91
|
+
segment: "opacity-disabled pointer-events-none",
|
|
92
|
+
input: "pointer-events-none"
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
isInvalid: {
|
|
96
|
+
true: {}
|
|
97
|
+
},
|
|
98
|
+
isReadOnly: {
|
|
99
|
+
true: {
|
|
100
|
+
caret: "bg-transparent",
|
|
101
|
+
segment: "transition-none data-[active=true]:scale-100"
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
fullWidth: {
|
|
105
|
+
true: {
|
|
106
|
+
base: "w-full"
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
radius: {
|
|
110
|
+
none: {
|
|
111
|
+
segment: "rounded-none"
|
|
112
|
+
},
|
|
113
|
+
sm: {
|
|
114
|
+
segment: "rounded-sm"
|
|
115
|
+
},
|
|
116
|
+
md: {
|
|
117
|
+
segment: "rounded-md"
|
|
118
|
+
},
|
|
119
|
+
lg: {
|
|
120
|
+
segment: "rounded-lg"
|
|
121
|
+
},
|
|
122
|
+
full: {
|
|
123
|
+
segment: "rounded-full"
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
color: {
|
|
127
|
+
default: {},
|
|
128
|
+
primary: {},
|
|
129
|
+
secondary: {},
|
|
130
|
+
success: {},
|
|
131
|
+
warning: {},
|
|
132
|
+
danger: {}
|
|
133
|
+
},
|
|
134
|
+
size: {
|
|
135
|
+
sm: {
|
|
136
|
+
segment: "h-8 min-h-8 w-8 min-w-8 text-small"
|
|
137
|
+
},
|
|
138
|
+
md: {
|
|
139
|
+
segment: "h-10 min-h-10 w-10 min-w-10 text-small"
|
|
140
|
+
},
|
|
141
|
+
lg: {
|
|
142
|
+
segment: "h-12 min-h-12 w-12 min-w-12 text-medium"
|
|
143
|
+
}
|
|
144
|
+
},
|
|
145
|
+
disableAnimation: {
|
|
146
|
+
true: {
|
|
147
|
+
segment: "transition-none",
|
|
148
|
+
caret: "animate-none"
|
|
149
|
+
},
|
|
150
|
+
false: {
|
|
151
|
+
segment: "transition duration-150"
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
defaultVariants: {
|
|
156
|
+
variant: "flat",
|
|
157
|
+
color: "default",
|
|
158
|
+
radius: "md",
|
|
159
|
+
size: "md"
|
|
160
|
+
},
|
|
161
|
+
compoundVariants: [
|
|
162
|
+
{
|
|
163
|
+
variant: "flat",
|
|
164
|
+
color: "default",
|
|
165
|
+
class: {
|
|
166
|
+
segment: ["bg-default-100", "data-[active=true]:bg-default-200"]
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
variant: "flat",
|
|
171
|
+
color: "primary",
|
|
172
|
+
class: {
|
|
173
|
+
segment: ["bg-primary-100", "data-[active=true]:bg-primary-200", "text-primary"],
|
|
174
|
+
caret: ["bg-primary"],
|
|
175
|
+
passwordChar: ["bg-primary"]
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
variant: "flat",
|
|
180
|
+
color: "secondary",
|
|
181
|
+
class: {
|
|
182
|
+
segment: ["bg-secondary-100", "data-[active=true]:bg-secondary-200", "text-secondary"],
|
|
183
|
+
caret: ["bg-secondary"],
|
|
184
|
+
passwordChar: ["bg-secondary"]
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
variant: "flat",
|
|
189
|
+
color: "success",
|
|
190
|
+
class: {
|
|
191
|
+
segment: ["bg-success-100", "data-[active=true]:bg-success-200", "text-success"],
|
|
192
|
+
caret: ["bg-success"],
|
|
193
|
+
passwordChar: ["bg-success"]
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
variant: "flat",
|
|
198
|
+
color: "warning",
|
|
199
|
+
class: {
|
|
200
|
+
segment: ["bg-warning-100", "data-[active=true]:bg-warning-200", "text-warning"],
|
|
201
|
+
caret: ["bg-warning"],
|
|
202
|
+
passwordChar: ["bg-warning"]
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
variant: "flat",
|
|
207
|
+
color: "danger",
|
|
208
|
+
class: {
|
|
209
|
+
segment: ["bg-danger-100", "data-[active=true]:bg-danger-200", "text-danger"],
|
|
210
|
+
caret: ["bg-danger"],
|
|
211
|
+
passwordChar: ["bg-danger"]
|
|
212
|
+
}
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
variant: "faded",
|
|
216
|
+
color: "default",
|
|
217
|
+
class: {
|
|
218
|
+
segment: ""
|
|
219
|
+
}
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
variant: "faded",
|
|
223
|
+
color: "primary",
|
|
224
|
+
class: {
|
|
225
|
+
segment: [
|
|
226
|
+
"bg-primary-100",
|
|
227
|
+
"text-primary",
|
|
228
|
+
"border-primary-200",
|
|
229
|
+
"data-[active=true]:border-primary"
|
|
230
|
+
],
|
|
231
|
+
caret: ["bg-primary"],
|
|
232
|
+
passwordChar: ["bg-primary"]
|
|
233
|
+
}
|
|
234
|
+
},
|
|
235
|
+
{
|
|
236
|
+
variant: "faded",
|
|
237
|
+
color: "secondary",
|
|
238
|
+
class: {
|
|
239
|
+
segment: [
|
|
240
|
+
"bg-secondary-100",
|
|
241
|
+
"text-secondary",
|
|
242
|
+
"border-secondary-200",
|
|
243
|
+
"data-[active=true]:border-secondary"
|
|
244
|
+
],
|
|
245
|
+
caret: ["bg-secondary"],
|
|
246
|
+
passwordChar: ["bg-secondary"]
|
|
247
|
+
}
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
variant: "faded",
|
|
251
|
+
color: "success",
|
|
252
|
+
class: {
|
|
253
|
+
segment: [
|
|
254
|
+
"bg-success-100",
|
|
255
|
+
"text-success",
|
|
256
|
+
"border-success-200",
|
|
257
|
+
"data-[active=true]:border-success"
|
|
258
|
+
],
|
|
259
|
+
caret: ["bg-success"],
|
|
260
|
+
passwordChar: ["bg-success"]
|
|
261
|
+
}
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
variant: "faded",
|
|
265
|
+
color: "warning",
|
|
266
|
+
class: {
|
|
267
|
+
segment: [
|
|
268
|
+
"bg-warning-100",
|
|
269
|
+
"text-warning",
|
|
270
|
+
"border-warning-200",
|
|
271
|
+
"data-[active=true]:border-warning"
|
|
272
|
+
],
|
|
273
|
+
caret: ["bg-warning"],
|
|
274
|
+
passwordChar: ["bg-warning"]
|
|
275
|
+
}
|
|
276
|
+
},
|
|
277
|
+
{
|
|
278
|
+
variant: "faded",
|
|
279
|
+
color: "danger",
|
|
280
|
+
class: {
|
|
281
|
+
segment: [
|
|
282
|
+
"bg-danger-100",
|
|
283
|
+
"text-danger",
|
|
284
|
+
"border-danger-200",
|
|
285
|
+
"data-[active=true]:border-danger"
|
|
286
|
+
],
|
|
287
|
+
caret: ["bg-danger"],
|
|
288
|
+
passwordChar: ["bg-danger"]
|
|
289
|
+
}
|
|
290
|
+
},
|
|
291
|
+
{
|
|
292
|
+
variant: "bordered",
|
|
293
|
+
color: "default",
|
|
294
|
+
class: {
|
|
295
|
+
segment: "data-[has-value=true]:text-default-foreground data-[active=true]:border-foreground"
|
|
296
|
+
}
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
variant: "bordered",
|
|
300
|
+
color: "primary",
|
|
301
|
+
class: {
|
|
302
|
+
segment: ["border-primary-200", "text-primary", "data-[active=true]:border-primary"],
|
|
303
|
+
caret: ["bg-primary"],
|
|
304
|
+
passwordChar: ["bg-primary"]
|
|
305
|
+
}
|
|
306
|
+
},
|
|
307
|
+
{
|
|
308
|
+
variant: "bordered",
|
|
309
|
+
color: "secondary",
|
|
310
|
+
class: {
|
|
311
|
+
segment: ["border-secondary-200", "text-secondary", "data-[active=true]:border-secondary"],
|
|
312
|
+
caret: ["bg-secondary"],
|
|
313
|
+
passwordChar: ["bg-secondary"]
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
{
|
|
317
|
+
variant: "bordered",
|
|
318
|
+
color: "success",
|
|
319
|
+
class: {
|
|
320
|
+
segment: ["border-success-200", "text-success", "data-[active=true]:border-success"],
|
|
321
|
+
caret: ["bg-success"],
|
|
322
|
+
passwordChar: ["bg-success"]
|
|
323
|
+
}
|
|
324
|
+
},
|
|
325
|
+
{
|
|
326
|
+
variant: "bordered",
|
|
327
|
+
color: "warning",
|
|
328
|
+
class: {
|
|
329
|
+
segment: ["border-warning-200", "text-warning", "data-[active=true]:border-warning"],
|
|
330
|
+
caret: ["bg-warning"],
|
|
331
|
+
passwordChar: ["bg-warning"]
|
|
332
|
+
}
|
|
333
|
+
},
|
|
334
|
+
{
|
|
335
|
+
variant: "bordered",
|
|
336
|
+
color: "danger",
|
|
337
|
+
class: {
|
|
338
|
+
segment: ["border-danger-200", "text-danger", "data-[active=true]:border-danger"],
|
|
339
|
+
caret: ["bg-danger"],
|
|
340
|
+
passwordChar: ["bg-danger"]
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
variant: "underlined",
|
|
345
|
+
color: "default",
|
|
346
|
+
class: {
|
|
347
|
+
segment: "data-[has-value=true]:text-default-foreground after:bg-foreground"
|
|
348
|
+
}
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
variant: "underlined",
|
|
352
|
+
color: "primary",
|
|
353
|
+
class: {
|
|
354
|
+
segment: ["border-primary-200", "text-primary", "after:bg-primary"],
|
|
355
|
+
caret: ["bg-primary"],
|
|
356
|
+
passwordChar: ["bg-primary"]
|
|
357
|
+
}
|
|
358
|
+
},
|
|
359
|
+
{
|
|
360
|
+
variant: "underlined",
|
|
361
|
+
color: "secondary",
|
|
362
|
+
class: {
|
|
363
|
+
segment: ["border-secondary-200", "text-secondary", "after:bg-secondary"],
|
|
364
|
+
caret: ["bg-secondary"],
|
|
365
|
+
passwordChar: ["bg-secondary"]
|
|
366
|
+
}
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
variant: "underlined",
|
|
370
|
+
color: "success",
|
|
371
|
+
class: {
|
|
372
|
+
segment: ["border-success-200", "text-success", "after:bg-success"],
|
|
373
|
+
caret: ["bg-success"],
|
|
374
|
+
passwordChar: ["bg-success"]
|
|
375
|
+
}
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
variant: "underlined",
|
|
379
|
+
color: "warning",
|
|
380
|
+
class: {
|
|
381
|
+
segment: ["border-warning-200", "text-warning", "after:bg-warning"],
|
|
382
|
+
caret: ["bg-warning"],
|
|
383
|
+
passwordChar: ["bg-warning"]
|
|
384
|
+
}
|
|
385
|
+
},
|
|
386
|
+
{
|
|
387
|
+
variant: "underlined",
|
|
388
|
+
color: "danger",
|
|
389
|
+
class: {
|
|
390
|
+
segment: ["border-danger-200", "text-danger", "after:bg-danger"],
|
|
391
|
+
caret: ["bg-danger"],
|
|
392
|
+
passwordChar: ["bg-danger"]
|
|
393
|
+
}
|
|
394
|
+
},
|
|
395
|
+
{
|
|
396
|
+
variant: "flat",
|
|
397
|
+
isInvalid: true,
|
|
398
|
+
class: {
|
|
399
|
+
segment: ["bg-danger-50", "data-[active=true]:bg-danger-100", "text-danger"],
|
|
400
|
+
caret: ["bg-danger"]
|
|
401
|
+
}
|
|
402
|
+
},
|
|
403
|
+
{
|
|
404
|
+
variant: "faded",
|
|
405
|
+
isInvalid: true,
|
|
406
|
+
class: {
|
|
407
|
+
segment: [
|
|
408
|
+
"bg-danger-50",
|
|
409
|
+
"text-danger",
|
|
410
|
+
"border-danger-200",
|
|
411
|
+
"data-[active=true]:border-danger-400"
|
|
412
|
+
],
|
|
413
|
+
caret: ["bg-danger"]
|
|
414
|
+
}
|
|
415
|
+
},
|
|
416
|
+
{
|
|
417
|
+
variant: "bordered",
|
|
418
|
+
isInvalid: true,
|
|
419
|
+
class: {
|
|
420
|
+
segment: ["border-danger-200", "text-danger", "data-[active=true]:border-danger-400"],
|
|
421
|
+
caret: ["bg-danger"]
|
|
422
|
+
}
|
|
423
|
+
},
|
|
424
|
+
{
|
|
425
|
+
variant: "underlined",
|
|
426
|
+
isInvalid: true,
|
|
427
|
+
class: {
|
|
428
|
+
segment: ["border-danger-200", "text-danger", "data-[active=true]:after:bg-danger-400"],
|
|
429
|
+
caret: ["bg-danger"]
|
|
430
|
+
}
|
|
431
|
+
},
|
|
432
|
+
{
|
|
433
|
+
disableAnimation: false,
|
|
434
|
+
variant: "underlined",
|
|
435
|
+
class: {
|
|
436
|
+
segment: "after:transition-width motion-reduce:after:transition-none"
|
|
437
|
+
}
|
|
438
|
+
}
|
|
439
|
+
]
|
|
440
|
+
});
|
|
441
|
+
|
|
442
|
+
export {
|
|
443
|
+
inputOtp
|
|
444
|
+
};
|
|
@@ -152,7 +152,88 @@ var progress = tv(
|
|
|
152
152
|
twMerge: true
|
|
153
153
|
}
|
|
154
154
|
);
|
|
155
|
+
var circularProgress = tv({
|
|
156
|
+
slots: {
|
|
157
|
+
base: "flex flex-col justify-center gap-1 max-w-fit items-center",
|
|
158
|
+
label: "",
|
|
159
|
+
svgWrapper: "relative block",
|
|
160
|
+
svg: "z-0 relative overflow-hidden",
|
|
161
|
+
track: "h-full stroke-default-300/50",
|
|
162
|
+
indicator: "h-full stroke-current",
|
|
163
|
+
value: "absolute font-normal inset-0 flex items-center justify-center"
|
|
164
|
+
},
|
|
165
|
+
variants: {
|
|
166
|
+
color: {
|
|
167
|
+
default: {
|
|
168
|
+
svg: "text-default-400"
|
|
169
|
+
},
|
|
170
|
+
primary: {
|
|
171
|
+
svg: "text-primary"
|
|
172
|
+
},
|
|
173
|
+
secondary: {
|
|
174
|
+
svg: "text-secondary"
|
|
175
|
+
},
|
|
176
|
+
success: {
|
|
177
|
+
svg: "text-success"
|
|
178
|
+
},
|
|
179
|
+
warning: {
|
|
180
|
+
svg: "text-warning"
|
|
181
|
+
},
|
|
182
|
+
danger: {
|
|
183
|
+
svg: "text-danger"
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
size: {
|
|
187
|
+
sm: {
|
|
188
|
+
svg: "w-8 h-8",
|
|
189
|
+
label: "text-small",
|
|
190
|
+
value: "text-[0.5rem]"
|
|
191
|
+
},
|
|
192
|
+
md: {
|
|
193
|
+
svg: "w-10 h-10",
|
|
194
|
+
label: "text-small",
|
|
195
|
+
value: "text-[0.55rem]"
|
|
196
|
+
},
|
|
197
|
+
lg: {
|
|
198
|
+
svg: "w-12 h-12",
|
|
199
|
+
label: "text-medium",
|
|
200
|
+
value: "text-[0.6rem]"
|
|
201
|
+
}
|
|
202
|
+
},
|
|
203
|
+
isIndeterminate: {
|
|
204
|
+
true: {
|
|
205
|
+
svg: "animate-spinner-ease-spin"
|
|
206
|
+
}
|
|
207
|
+
},
|
|
208
|
+
isDisabled: {
|
|
209
|
+
true: {
|
|
210
|
+
base: "opacity-disabled cursor-not-allowed"
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
disableAnimation: {
|
|
214
|
+
true: {},
|
|
215
|
+
false: {
|
|
216
|
+
indicator: "transition-all !duration-500"
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
},
|
|
220
|
+
defaultVariants: {
|
|
221
|
+
color: "primary",
|
|
222
|
+
size: "md",
|
|
223
|
+
isDisabled: false
|
|
224
|
+
},
|
|
225
|
+
compoundVariants: [
|
|
226
|
+
{
|
|
227
|
+
disableAnimation: true,
|
|
228
|
+
isIndeterminate: false,
|
|
229
|
+
class: {
|
|
230
|
+
svg: "!transition-none motion-reduce:transition-none"
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
]
|
|
234
|
+
});
|
|
155
235
|
|
|
156
236
|
export {
|
|
157
|
-
progress
|
|
237
|
+
progress,
|
|
238
|
+
circularProgress
|
|
158
239
|
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// src/utils/merge-classes.ts
|
|
2
|
+
import { clsx } from "@nextui-org/shared-utils";
|
|
3
|
+
var mergeClasses = (itemClasses, itemPropsClasses) => {
|
|
4
|
+
if (!itemClasses && !itemPropsClasses)
|
|
5
|
+
return {};
|
|
6
|
+
const keys = /* @__PURE__ */ new Set([...Object.keys(itemClasses || {}), ...Object.keys(itemPropsClasses || {})]);
|
|
7
|
+
return Array.from(keys).reduce(
|
|
8
|
+
(acc, key) => ({
|
|
9
|
+
...acc,
|
|
10
|
+
[key]: clsx(itemClasses == null ? void 0 : itemClasses[key], itemPropsClasses == null ? void 0 : itemPropsClasses[key])
|
|
11
|
+
}),
|
|
12
|
+
{}
|
|
13
|
+
);
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export {
|
|
17
|
+
mergeClasses
|
|
18
|
+
};
|
|
@@ -35,10 +35,10 @@ var input = tv({
|
|
|
35
35
|
"p-2",
|
|
36
36
|
"-m-2",
|
|
37
37
|
"z-10",
|
|
38
|
-
"hidden",
|
|
39
38
|
"absolute",
|
|
40
39
|
"end-3",
|
|
41
40
|
"start-auto",
|
|
41
|
+
"pointer-events-none",
|
|
42
42
|
"appearance-none",
|
|
43
43
|
"outline-none",
|
|
44
44
|
"select-none",
|
|
@@ -127,6 +127,7 @@ var input = tv({
|
|
|
127
127
|
clearButton: "text-large"
|
|
128
128
|
},
|
|
129
129
|
lg: {
|
|
130
|
+
label: "text-medium",
|
|
130
131
|
inputWrapper: "h-12 min-h-12 rounded-large",
|
|
131
132
|
input: "text-medium",
|
|
132
133
|
clearButton: "text-large"
|
|
@@ -160,7 +161,7 @@ var input = tv({
|
|
|
160
161
|
label: "relative text-foreground pe-2 ps-2 pointer-events-auto"
|
|
161
162
|
},
|
|
162
163
|
inside: {
|
|
163
|
-
label: "
|
|
164
|
+
label: "cursor-text",
|
|
164
165
|
inputWrapper: "flex-col items-start justify-center gap-0",
|
|
165
166
|
innerWrapper: "group-data-[has-label=true]:items-end"
|
|
166
167
|
}
|
|
@@ -174,7 +175,11 @@ var input = tv({
|
|
|
174
175
|
isClearable: {
|
|
175
176
|
true: {
|
|
176
177
|
input: "peer pe-6 input-search-cancel-button-none",
|
|
177
|
-
clearButton:
|
|
178
|
+
clearButton: [
|
|
179
|
+
"peer-data-[filled=true]:pointer-events-auto",
|
|
180
|
+
"peer-data-[filled=true]:opacity-70 peer-data-[filled=true]:block",
|
|
181
|
+
"peer-data-[filled=true]:scale-100"
|
|
182
|
+
]
|
|
178
183
|
}
|
|
179
184
|
},
|
|
180
185
|
isDisabled: {
|
|
@@ -200,7 +205,8 @@ var input = tv({
|
|
|
200
205
|
label: "relative",
|
|
201
206
|
inputWrapper: "!h-auto",
|
|
202
207
|
innerWrapper: "items-start group-data-[has-label=true]:items-start",
|
|
203
|
-
input: "resize-none data-[hide-scroll=true]:scrollbar-hide"
|
|
208
|
+
input: "resize-none data-[hide-scroll=true]:scrollbar-hide",
|
|
209
|
+
clearButton: "absolute top-2 right-2 rtl:right-auto rtl:left-2 z-10"
|
|
204
210
|
}
|
|
205
211
|
},
|
|
206
212
|
disableAnimation: {
|
|
@@ -218,7 +224,14 @@ var input = tv({
|
|
|
218
224
|
"motion-reduce:transition-none",
|
|
219
225
|
"transition-[transform,color,left,opacity]"
|
|
220
226
|
],
|
|
221
|
-
clearButton: [
|
|
227
|
+
clearButton: [
|
|
228
|
+
"scale-90",
|
|
229
|
+
"ease-out",
|
|
230
|
+
"duration-150",
|
|
231
|
+
"transition-[opacity,transform]",
|
|
232
|
+
"motion-reduce:transition-none",
|
|
233
|
+
"motion-reduce:scale-100"
|
|
234
|
+
]
|
|
222
235
|
}
|
|
223
236
|
}
|
|
224
237
|
},
|
|
@@ -547,7 +560,6 @@ var input = tv({
|
|
|
547
560
|
labelPlacement: "inside",
|
|
548
561
|
size: "lg",
|
|
549
562
|
class: {
|
|
550
|
-
label: "text-small",
|
|
551
563
|
inputWrapper: "h-16 py-2.5 gap-0"
|
|
552
564
|
}
|
|
553
565
|
},
|
|
@@ -815,6 +827,17 @@ var input = tv({
|
|
|
815
827
|
class: {
|
|
816
828
|
inputWrapper: "data-[has-multiple-rows=true]:rounded-large"
|
|
817
829
|
}
|
|
830
|
+
},
|
|
831
|
+
{
|
|
832
|
+
isClearable: true,
|
|
833
|
+
isMultiline: true,
|
|
834
|
+
class: {
|
|
835
|
+
clearButton: [
|
|
836
|
+
"group-data-[has-value=true]:opacity-70 group-data-[has-value=true]:block",
|
|
837
|
+
"group-data-[has-value=true]:scale-100",
|
|
838
|
+
"group-data-[has-value=true]:pointer-events-auto"
|
|
839
|
+
]
|
|
840
|
+
}
|
|
818
841
|
}
|
|
819
842
|
]
|
|
820
843
|
});
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
// src/components/menu.ts
|
|
9
9
|
var menu = tv({
|
|
10
10
|
slots: {
|
|
11
|
-
base: "w-full relative flex flex-col gap-1 p-1",
|
|
11
|
+
base: "w-full relative flex flex-col gap-1 p-1 overflow-hidden",
|
|
12
12
|
list: "w-full flex flex-col gap-0.5 outline-none",
|
|
13
13
|
emptyContent: [
|
|
14
14
|
"h-10",
|
|
@@ -116,6 +116,16 @@ var menuItem = tv({
|
|
|
116
116
|
false: {
|
|
117
117
|
base: "data-[hover=true]:transition-colors"
|
|
118
118
|
}
|
|
119
|
+
},
|
|
120
|
+
hasTitleTextChild: {
|
|
121
|
+
true: {
|
|
122
|
+
title: "truncate"
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
hasDescriptionTextChild: {
|
|
126
|
+
true: {
|
|
127
|
+
description: "truncate"
|
|
128
|
+
}
|
|
119
129
|
}
|
|
120
130
|
},
|
|
121
131
|
defaultVariants: {
|
|
@@ -126,6 +126,7 @@ var dateInput = tv({
|
|
|
126
126
|
clearButton: "text-large"
|
|
127
127
|
},
|
|
128
128
|
lg: {
|
|
129
|
+
label: "text-medium",
|
|
129
130
|
input: "text-medium",
|
|
130
131
|
inputWrapper: "h-12 min-h-12 rounded-large"
|
|
131
132
|
}
|
|
@@ -363,7 +364,7 @@ var dateInput = tv({
|
|
|
363
364
|
labelPlacement: "inside",
|
|
364
365
|
size: "lg",
|
|
365
366
|
class: {
|
|
366
|
-
label: "text-
|
|
367
|
+
label: "text-medium",
|
|
367
368
|
inputWrapper: "h-16 py-2.5 gap-0"
|
|
368
369
|
}
|
|
369
370
|
},
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
var autocomplete = tv({
|
|
7
7
|
slots: {
|
|
8
8
|
base: "group inline-flex flex-column w-full",
|
|
9
|
-
listboxWrapper: "scroll-py-6
|
|
9
|
+
listboxWrapper: "scroll-py-6 w-full",
|
|
10
10
|
listbox: "",
|
|
11
11
|
popoverContent: "w-full p-1 overflow-hidden",
|
|
12
12
|
endContentWrapper: "relative flex h-full items-center -mr-2",
|