@kopexa/theme 1.4.3 → 1.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,396 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/components/chip.ts
21
+ var chip_exports = {};
22
+ __export(chip_exports, {
23
+ chip: () => chip
24
+ });
25
+ module.exports = __toCommonJS(chip_exports);
26
+ var import_tailwind_variants = require("tailwind-variants");
27
+
28
+ // src/utils/variants.ts
29
+ var solid = {
30
+ default: "bg-accent text-accent-foreground",
31
+ primary: "bg-primary text-primary-foreground",
32
+ secondary: "bg-secondary text-secondary-foreground",
33
+ destructive: "bg-destructive text-destructive-foreground",
34
+ warning: "bg-warning text-warning-foreground",
35
+ success: "bg-success text-success-foreground"
36
+ };
37
+ var outline = {
38
+ default: "bg-transparent border border-accent text-accent-foreground",
39
+ primary: "bg-transparent border-primary text-primary",
40
+ secondary: "bg-transparent border-secondary text-secondary-foreground",
41
+ destructive: "bg-transparent border-destructive text-destructive",
42
+ warning: "bg-transparent border-warning text-warning",
43
+ success: "bg-transparent border-success text-success"
44
+ };
45
+ var flat = {
46
+ default: "bg-accent/40 text-accent-700",
47
+ primary: "bg-primary/20 text-primary-600",
48
+ secondary: "bg-secondary/20 text-secondary-600",
49
+ success: "bg-success/20 text-success-700 dark:text-success",
50
+ warning: "bg-warning/20 text-warning-700 dark:text-warning",
51
+ destructive: "bg-danger/20 text-danger-600 dark:text-danger-500",
52
+ foreground: "bg-foreground/10 text-foreground"
53
+ };
54
+ var faded = {
55
+ default: "border-default bg-accent/30 text-default-foreground",
56
+ primary: "border-default bg-accent/30 text-primary",
57
+ secondary: "border-default bg-accent/30 text-secondary-foreground",
58
+ success: "border-default bg-accent/30 text-success",
59
+ warning: "border-default bg-accent/30 text-warning",
60
+ destructive: "border-default bg-accent/30 text-danger",
61
+ foreground: "border-default bg-accent/30 text-foreground"
62
+ };
63
+ var ghost = {
64
+ primary: "bg-transparent text-primary",
65
+ secondary: "bg-transparent text-secondary",
66
+ destructive: "bg-transparent text-destructive",
67
+ warning: "bg-transparent text-warning",
68
+ success: "bg-transparent text-success"
69
+ };
70
+ var colorVariants = {
71
+ solid,
72
+ ghost,
73
+ outline,
74
+ flat,
75
+ faded
76
+ };
77
+
78
+ // src/components/chip.ts
79
+ var chip = (0, import_tailwind_variants.tv)({
80
+ slots: {
81
+ root: [
82
+ "relative",
83
+ "max-w-fit",
84
+ "min-w-min",
85
+ "inline-flex",
86
+ "items-center",
87
+ "justify-between",
88
+ "box-border",
89
+ "whitespace-nowrap",
90
+ "isolate"
91
+ ],
92
+ content: "flex-1 text-inherit font-normal",
93
+ indicator: "relative flex size-2 ml-1",
94
+ indicatorPulse: "absolute inline-flex h-full w-full animate-ping rounded-full opacity-75",
95
+ indicatorDot: "relative inline-flex size-2 rounded-full",
96
+ status: "flex items-center gap-2 border-r pr-1 font-medium ml-1",
97
+ closeButton: [
98
+ "z-10 appearance-none outline-none select-none transition-opacity",
99
+ "opacity-70 hover:opacity-100 cursor-pointer active:opacity-50"
100
+ ]
101
+ },
102
+ variants: {
103
+ variant: {
104
+ solid: {},
105
+ bordered: {
106
+ root: "border-2 bg-transparent"
107
+ },
108
+ faded: {
109
+ root: "border-2"
110
+ },
111
+ flat: {}
112
+ },
113
+ color: {
114
+ default: {
115
+ status: "border-default-200 dark:border-default-700"
116
+ },
117
+ primary: {
118
+ status: "border-primary-200 dark:border-primary-700"
119
+ },
120
+ secondary: {
121
+ status: "border-secondary-200 dark:border-secondary-700"
122
+ },
123
+ success: {
124
+ status: "border-success-200 dark:border-success-700"
125
+ },
126
+ destructive: {
127
+ status: "border-destructive-200 dark:border-destructive-700"
128
+ },
129
+ warning: {
130
+ status: "border-warning-200 dark:border-warning-700"
131
+ }
132
+ },
133
+ indicatorColor: {
134
+ default: {
135
+ indicatorDot: "bg-accent"
136
+ },
137
+ primary: {
138
+ indicatorDot: "bg-primary"
139
+ },
140
+ secondary: {
141
+ indicatorDot: "bg-secondary"
142
+ },
143
+ success: {
144
+ indicatorDot: "bg-success"
145
+ },
146
+ warning: {
147
+ indicatorDot: "bg-warning"
148
+ },
149
+ destructive: {
150
+ indicatorDot: "bg-destructive"
151
+ },
152
+ info: {
153
+ indicatorDot: "bg-info"
154
+ }
155
+ },
156
+ indicator: {
157
+ true: {},
158
+ false: {}
159
+ },
160
+ indicatorVariant: {
161
+ pulse: {}
162
+ },
163
+ size: {
164
+ sm: {
165
+ root: "px-1 h-6 text-[11px] [&_svg]:size-3",
166
+ status: "text-[11px]",
167
+ content: "px-1",
168
+ closeButton: ["[&_svg]:size-3", "px-1"]
169
+ },
170
+ md: {
171
+ root: "px-1 h-7 text-sm [&_svg]:size-4",
172
+ status: "text-sm",
173
+ content: "px-2",
174
+ closeButton: ["[&_svg]:size-4", "px-2"]
175
+ },
176
+ lg: {
177
+ root: "px-2 h-8 text-md [&_svg]:size-5",
178
+ status: "text-md",
179
+ content: "px-2",
180
+ closeButton: ["[&_svg]:size-5", "px-2"]
181
+ }
182
+ },
183
+ isCloseable: {
184
+ true: {},
185
+ false: {}
186
+ },
187
+ radius: {
188
+ none: {
189
+ root: "rounded-none"
190
+ },
191
+ sm: {
192
+ root: "rounded-sm"
193
+ },
194
+ md: {
195
+ root: "rounded-md"
196
+ },
197
+ lg: {
198
+ root: "rounded-lg"
199
+ },
200
+ full: {
201
+ root: "rounded-full"
202
+ }
203
+ },
204
+ disabled: {
205
+ true: {
206
+ root: "opacity-50 pointer-events-none"
207
+ },
208
+ false: {}
209
+ }
210
+ },
211
+ defaultVariants: {
212
+ color: "default",
213
+ variant: "solid",
214
+ size: "sm",
215
+ radius: "full",
216
+ indicatorVariant: "pulse",
217
+ indicatorColor: "success"
218
+ },
219
+ compoundVariants: [
220
+ // solid / color
221
+ {
222
+ variant: "solid",
223
+ color: "default",
224
+ class: {
225
+ root: colorVariants.solid.default
226
+ }
227
+ },
228
+ {
229
+ variant: "solid",
230
+ color: "primary",
231
+ class: {
232
+ root: colorVariants.solid.primary
233
+ }
234
+ },
235
+ {
236
+ variant: "solid",
237
+ color: "secondary",
238
+ class: {
239
+ root: colorVariants.solid.secondary
240
+ }
241
+ },
242
+ {
243
+ variant: "solid",
244
+ color: "success",
245
+ class: {
246
+ root: colorVariants.solid.success
247
+ }
248
+ },
249
+ {
250
+ variant: "solid",
251
+ color: "warning",
252
+ class: {
253
+ root: colorVariants.solid.warning
254
+ }
255
+ },
256
+ {
257
+ variant: "solid",
258
+ color: "destructive",
259
+ class: {
260
+ root: colorVariants.solid.destructive
261
+ }
262
+ },
263
+ // bordered / color
264
+ {
265
+ variant: "bordered",
266
+ color: "default",
267
+ class: {
268
+ root: colorVariants.outline.default
269
+ }
270
+ },
271
+ {
272
+ variant: "bordered",
273
+ color: "primary",
274
+ class: {
275
+ root: colorVariants.outline.primary
276
+ }
277
+ },
278
+ {
279
+ variant: "bordered",
280
+ color: "secondary",
281
+ class: {
282
+ root: colorVariants.outline.secondary
283
+ }
284
+ },
285
+ {
286
+ variant: "bordered",
287
+ color: "success",
288
+ class: {
289
+ root: colorVariants.outline.success
290
+ }
291
+ },
292
+ {
293
+ variant: "bordered",
294
+ color: "warning",
295
+ class: {
296
+ root: colorVariants.outline.warning
297
+ }
298
+ },
299
+ {
300
+ variant: "bordered",
301
+ color: "destructive",
302
+ class: {
303
+ root: colorVariants.outline.destructive
304
+ }
305
+ },
306
+ {
307
+ variant: "flat",
308
+ color: "default",
309
+ class: {
310
+ root: colorVariants.flat.default
311
+ }
312
+ },
313
+ {
314
+ variant: "flat",
315
+ color: "primary",
316
+ class: {
317
+ root: colorVariants.flat.primary
318
+ }
319
+ },
320
+ {
321
+ variant: "flat",
322
+ color: "secondary",
323
+ class: {
324
+ root: colorVariants.flat.secondary
325
+ }
326
+ },
327
+ {
328
+ variant: "flat",
329
+ color: "success",
330
+ class: {
331
+ root: colorVariants.flat.success
332
+ }
333
+ },
334
+ {
335
+ variant: "flat",
336
+ color: "warning",
337
+ class: {
338
+ root: colorVariants.flat.warning
339
+ }
340
+ },
341
+ {
342
+ variant: "flat",
343
+ color: "destructive",
344
+ class: {
345
+ root: colorVariants.flat.destructive
346
+ }
347
+ },
348
+ // faded / color
349
+ {
350
+ variant: "faded",
351
+ color: "default",
352
+ class: {
353
+ root: colorVariants.faded.default
354
+ }
355
+ },
356
+ {
357
+ variant: "faded",
358
+ color: "primary",
359
+ class: {
360
+ root: colorVariants.faded.primary
361
+ }
362
+ },
363
+ {
364
+ variant: "faded",
365
+ color: "secondary",
366
+ class: {
367
+ root: colorVariants.faded.secondary
368
+ }
369
+ },
370
+ {
371
+ variant: "faded",
372
+ color: "success",
373
+ class: {
374
+ root: colorVariants.faded.success
375
+ }
376
+ },
377
+ {
378
+ variant: "faded",
379
+ color: "warning",
380
+ class: {
381
+ root: colorVariants.faded.warning
382
+ }
383
+ },
384
+ {
385
+ variant: "faded",
386
+ color: "destructive",
387
+ class: {
388
+ root: colorVariants.faded.destructive
389
+ }
390
+ }
391
+ ]
392
+ });
393
+ // Annotate the CommonJS export names for ESM import in node:
394
+ 0 && (module.exports = {
395
+ chip
396
+ });
@@ -0,0 +1,7 @@
1
+ import {
2
+ chip
3
+ } from "../chunk-32L6KXLV.mjs";
4
+ import "../chunk-67PPUTSS.mjs";
5
+ export {
6
+ chip
7
+ };
@@ -7,10 +7,10 @@ declare const dropdownMenu: tailwind_variants.TVReturnType<{
7
7
  icon?: tailwind_variants.ClassValue;
8
8
  root?: tailwind_variants.ClassValue;
9
9
  label?: tailwind_variants.ClassValue;
10
+ content?: tailwind_variants.ClassValue;
10
11
  separator?: tailwind_variants.ClassValue;
11
12
  item?: tailwind_variants.ClassValue;
12
13
  shortcut?: tailwind_variants.ClassValue;
13
- content?: tailwind_variants.ClassValue;
14
14
  checkboxItem?: tailwind_variants.ClassValue;
15
15
  iconWrapper?: tailwind_variants.ClassValue;
16
16
  radioItem?: tailwind_variants.ClassValue;
@@ -26,10 +26,10 @@ declare const dropdownMenu: tailwind_variants.TVReturnType<{
26
26
  icon?: tailwind_variants.ClassValue;
27
27
  root?: tailwind_variants.ClassValue;
28
28
  label?: tailwind_variants.ClassValue;
29
+ content?: tailwind_variants.ClassValue;
29
30
  separator?: tailwind_variants.ClassValue;
30
31
  item?: tailwind_variants.ClassValue;
31
32
  shortcut?: tailwind_variants.ClassValue;
32
- content?: tailwind_variants.ClassValue;
33
33
  checkboxItem?: tailwind_variants.ClassValue;
34
34
  iconWrapper?: tailwind_variants.ClassValue;
35
35
  radioItem?: tailwind_variants.ClassValue;
@@ -60,10 +60,10 @@ declare const dropdownMenu: tailwind_variants.TVReturnType<{
60
60
  icon?: tailwind_variants.ClassValue;
61
61
  root?: tailwind_variants.ClassValue;
62
62
  label?: tailwind_variants.ClassValue;
63
+ content?: tailwind_variants.ClassValue;
63
64
  separator?: tailwind_variants.ClassValue;
64
65
  item?: tailwind_variants.ClassValue;
65
66
  shortcut?: tailwind_variants.ClassValue;
66
- content?: tailwind_variants.ClassValue;
67
67
  checkboxItem?: tailwind_variants.ClassValue;
68
68
  iconWrapper?: tailwind_variants.ClassValue;
69
69
  radioItem?: tailwind_variants.ClassValue;
@@ -7,10 +7,10 @@ declare const dropdownMenu: tailwind_variants.TVReturnType<{
7
7
  icon?: tailwind_variants.ClassValue;
8
8
  root?: tailwind_variants.ClassValue;
9
9
  label?: tailwind_variants.ClassValue;
10
+ content?: tailwind_variants.ClassValue;
10
11
  separator?: tailwind_variants.ClassValue;
11
12
  item?: tailwind_variants.ClassValue;
12
13
  shortcut?: tailwind_variants.ClassValue;
13
- content?: tailwind_variants.ClassValue;
14
14
  checkboxItem?: tailwind_variants.ClassValue;
15
15
  iconWrapper?: tailwind_variants.ClassValue;
16
16
  radioItem?: tailwind_variants.ClassValue;
@@ -26,10 +26,10 @@ declare const dropdownMenu: tailwind_variants.TVReturnType<{
26
26
  icon?: tailwind_variants.ClassValue;
27
27
  root?: tailwind_variants.ClassValue;
28
28
  label?: tailwind_variants.ClassValue;
29
+ content?: tailwind_variants.ClassValue;
29
30
  separator?: tailwind_variants.ClassValue;
30
31
  item?: tailwind_variants.ClassValue;
31
32
  shortcut?: tailwind_variants.ClassValue;
32
- content?: tailwind_variants.ClassValue;
33
33
  checkboxItem?: tailwind_variants.ClassValue;
34
34
  iconWrapper?: tailwind_variants.ClassValue;
35
35
  radioItem?: tailwind_variants.ClassValue;
@@ -60,10 +60,10 @@ declare const dropdownMenu: tailwind_variants.TVReturnType<{
60
60
  icon?: tailwind_variants.ClassValue;
61
61
  root?: tailwind_variants.ClassValue;
62
62
  label?: tailwind_variants.ClassValue;
63
+ content?: tailwind_variants.ClassValue;
63
64
  separator?: tailwind_variants.ClassValue;
64
65
  item?: tailwind_variants.ClassValue;
65
66
  shortcut?: tailwind_variants.ClassValue;
66
- content?: tailwind_variants.ClassValue;
67
67
  checkboxItem?: tailwind_variants.ClassValue;
68
68
  iconWrapper?: tailwind_variants.ClassValue;
69
69
  radioItem?: tailwind_variants.ClassValue;
@@ -1,5 +1,6 @@
1
1
  export { ButtonVariantProps, button } from './button.mjs';
2
2
  export { CalendarVariantProps, calendar } from './calendar.mjs';
3
+ export { ChipSlots, ChipVariantProps, chip } from './chip.mjs';
3
4
  export { CommandVariants, command } from './command.mjs';
4
5
  export { DialogSlots, DialogVariantProps, dialog } from './dialog.mjs';
5
6
  export { DrawerVariantProps, drawer } from './drawer.mjs';
@@ -1,5 +1,6 @@
1
1
  export { ButtonVariantProps, button } from './button.js';
2
2
  export { CalendarVariantProps, calendar } from './calendar.js';
3
+ export { ChipSlots, ChipVariantProps, chip } from './chip.js';
3
4
  export { CommandVariants, command } from './command.js';
4
5
  export { DialogSlots, DialogVariantProps, dialog } from './dialog.js';
5
6
  export { DrawerVariantProps, drawer } from './drawer.js';