@docyrus/shadcn 0.1.6 → 0.1.7

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 (61) hide show
  1. package/dist/default/index.js +4 -4
  2. package/dist/default/index.js.map +1 -1
  3. package/dist/default/resizable.d.ts +4 -21
  4. package/dist/default/resizable.js +4 -4
  5. package/dist/default/resizable.js.map +1 -1
  6. package/dist/default/sheet.d.ts +1 -1
  7. package/dist/default/sidebar.js.map +1 -1
  8. package/dist/hooks/index.js +1 -1
  9. package/dist/hooks/index.js.map +1 -1
  10. package/dist/index.js +4 -4
  11. package/dist/index.js.map +1 -1
  12. package/dist/new-york/alert-dialog.d.ts +10 -4
  13. package/dist/new-york/alert-dialog.js +63 -12
  14. package/dist/new-york/alert-dialog.js.map +1 -1
  15. package/dist/new-york/avatar.d.ts +7 -2
  16. package/dist/new-york/avatar.js +50 -3
  17. package/dist/new-york/avatar.js.map +1 -1
  18. package/dist/new-york/badge.d.ts +1 -1
  19. package/dist/new-york/badge.js +9 -6
  20. package/dist/new-york/badge.js.map +1 -1
  21. package/dist/new-york/button.d.ts +1 -1
  22. package/dist/new-york/button.js +6 -2
  23. package/dist/new-york/button.js.map +1 -1
  24. package/dist/new-york/calendar.js +6 -2
  25. package/dist/new-york/calendar.js.map +1 -1
  26. package/dist/new-york/carousel.js +6 -2
  27. package/dist/new-york/carousel.js.map +1 -1
  28. package/dist/new-york/command.js +32 -1
  29. package/dist/new-york/command.js.map +1 -1
  30. package/dist/new-york/dialog.d.ts +3 -1
  31. package/dist/new-york/dialog.js +63 -4
  32. package/dist/new-york/dialog.js.map +1 -1
  33. package/dist/new-york/form.js.map +1 -1
  34. package/dist/new-york/index.d.ts +4 -4
  35. package/dist/new-york/index.js +198 -40
  36. package/dist/new-york/index.js.map +1 -1
  37. package/dist/new-york/input-group.d.ts +1 -1
  38. package/dist/new-york/input-group.js +6 -2
  39. package/dist/new-york/input-group.js.map +1 -1
  40. package/dist/new-york/pagination.js +2 -0
  41. package/dist/new-york/pagination.js.map +1 -1
  42. package/dist/new-york/popover.d.ts +4 -1
  43. package/dist/new-york/popover.js +34 -1
  44. package/dist/new-york/popover.js.map +1 -1
  45. package/dist/new-york/resizable.d.ts +4 -5
  46. package/dist/new-york/resizable.js +4 -4
  47. package/dist/new-york/resizable.js.map +1 -1
  48. package/dist/new-york/select.js +9 -2
  49. package/dist/new-york/select.js.map +1 -1
  50. package/dist/new-york/sheet.d.ts +2 -1
  51. package/dist/new-york/sheet.js +2 -1
  52. package/dist/new-york/sheet.js.map +1 -1
  53. package/dist/new-york/sidebar.js +8 -3
  54. package/dist/new-york/sidebar.js.map +1 -1
  55. package/dist/new-york/switch.d.ts +3 -1
  56. package/dist/new-york/switch.js +4 -2
  57. package/dist/new-york/switch.js.map +1 -1
  58. package/dist/new-york/tabs.d.ts +8 -3
  59. package/dist/new-york/tabs.js +30 -7
  60. package/dist/new-york/tabs.js.map +1 -1
  61. package/package.json +8 -8
@@ -30,7 +30,7 @@ import * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';
30
30
  import * as PopoverPrimitive from '@radix-ui/react-popover';
31
31
  import * as ProgressPrimitive from '@radix-ui/react-progress';
32
32
  import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
33
- import * as ResizablePrimitive from 'react-resizable-panels';
33
+ import { Group, Panel, Separator as Separator$1 } from 'react-resizable-panels';
34
34
  import * as ScrollAreaPrimitive from '@radix-ui/react-scroll-area';
35
35
  import * as SelectPrimitive from '@radix-ui/react-select';
36
36
  import * as TooltipPrimitive from '@radix-ui/react-tooltip';
@@ -114,9 +114,11 @@ var buttonVariants = cva(
114
114
  },
115
115
  size: {
116
116
  default: "h-9 px-4 py-2 has-[>svg]:px-3",
117
+ xs: "h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",
117
118
  sm: "h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",
118
119
  lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
119
120
  icon: "size-9",
121
+ "icon-xs": "size-6 rounded-md [&_svg:not([class*='size-'])]:size-3",
120
122
  "icon-sm": "size-8",
121
123
  "icon-lg": "size-10"
122
124
  }
@@ -129,8 +131,8 @@ var buttonVariants = cva(
129
131
  );
130
132
  function Button({
131
133
  className,
132
- variant,
133
- size,
134
+ variant = "default",
135
+ size = "default",
134
136
  asChild = false,
135
137
  ...props
136
138
  }) {
@@ -139,6 +141,8 @@ function Button({
139
141
  Comp,
140
142
  {
141
143
  "data-slot": "button",
144
+ "data-variant": variant,
145
+ "data-size": size,
142
146
  className: cn(buttonVariants({ variant, size, className })),
143
147
  ...props
144
148
  }
@@ -177,6 +181,7 @@ function AlertDialogOverlay({
177
181
  }
178
182
  function AlertDialogContent({
179
183
  className,
184
+ size = "default",
180
185
  ...props
181
186
  }) {
182
187
  return /* @__PURE__ */ jsxs(AlertDialogPortal, { children: [
@@ -185,8 +190,9 @@ function AlertDialogContent({
185
190
  AlertDialogPrimitive.Content,
186
191
  {
187
192
  "data-slot": "alert-dialog-content",
193
+ "data-size": size,
188
194
  className: cn(
189
- "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",
195
+ "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 group/alert-dialog-content fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-lg",
190
196
  className
191
197
  ),
192
198
  ...props
@@ -202,7 +208,10 @@ function AlertDialogHeader({
202
208
  "div",
203
209
  {
204
210
  "data-slot": "alert-dialog-header",
205
- className: cn("flex flex-col gap-2 text-center sm:text-left", className),
211
+ className: cn(
212
+ "grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-6 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]",
213
+ className
214
+ ),
206
215
  ...props
207
216
  }
208
217
  );
@@ -216,7 +225,7 @@ function AlertDialogFooter({
216
225
  {
217
226
  "data-slot": "alert-dialog-footer",
218
227
  className: cn(
219
- "flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",
228
+ "flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end",
220
229
  className
221
230
  ),
222
231
  ...props
@@ -231,7 +240,10 @@ function AlertDialogTitle({
231
240
  AlertDialogPrimitive.Title,
232
241
  {
233
242
  "data-slot": "alert-dialog-title",
234
- className: cn("text-lg font-semibold", className),
243
+ className: cn(
244
+ "text-lg font-semibold sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2",
245
+ className
246
+ ),
235
247
  ...props
236
248
  }
237
249
  );
@@ -249,29 +261,51 @@ function AlertDialogDescription({
249
261
  }
250
262
  );
251
263
  }
252
- function AlertDialogAction({
264
+ function AlertDialogMedia({
253
265
  className,
254
266
  ...props
255
267
  }) {
256
268
  return /* @__PURE__ */ jsx(
257
- AlertDialogPrimitive.Action,
269
+ "div",
258
270
  {
259
- className: cn(buttonVariants(), className),
271
+ "data-slot": "alert-dialog-media",
272
+ className: cn(
273
+ "bg-muted mb-2 inline-flex size-16 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-8",
274
+ className
275
+ ),
260
276
  ...props
261
277
  }
262
278
  );
263
279
  }
280
+ function AlertDialogAction({
281
+ className,
282
+ variant = "default",
283
+ size = "default",
284
+ ...props
285
+ }) {
286
+ return /* @__PURE__ */ jsx(Button, { variant, size, asChild: true, children: /* @__PURE__ */ jsx(
287
+ AlertDialogPrimitive.Action,
288
+ {
289
+ "data-slot": "alert-dialog-action",
290
+ className: cn(className),
291
+ ...props
292
+ }
293
+ ) });
294
+ }
264
295
  function AlertDialogCancel({
265
296
  className,
297
+ variant = "outline",
298
+ size = "default",
266
299
  ...props
267
300
  }) {
268
- return /* @__PURE__ */ jsx(
301
+ return /* @__PURE__ */ jsx(Button, { variant, size, asChild: true, children: /* @__PURE__ */ jsx(
269
302
  AlertDialogPrimitive.Cancel,
270
303
  {
271
- className: cn(buttonVariants({ variant: "outline" }), className),
304
+ "data-slot": "alert-dialog-cancel",
305
+ className: cn(className),
272
306
  ...props
273
307
  }
274
- );
308
+ ) });
275
309
  }
276
310
  var alertVariants = cva(
277
311
  "relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",
@@ -338,14 +372,16 @@ function AspectRatio({
338
372
  }
339
373
  function Avatar({
340
374
  className,
375
+ size = "default",
341
376
  ...props
342
377
  }) {
343
378
  return /* @__PURE__ */ jsx(
344
379
  AvatarPrimitive.Root,
345
380
  {
346
381
  "data-slot": "avatar",
382
+ "data-size": size,
347
383
  className: cn(
348
- "relative flex size-8 shrink-0 overflow-hidden rounded-full",
384
+ "group/avatar relative flex size-8 shrink-0 overflow-hidden rounded-full select-none data-[size=lg]:size-10 data-[size=sm]:size-6",
349
385
  className
350
386
  ),
351
387
  ...props
@@ -374,7 +410,52 @@ function AvatarFallback({
374
410
  {
375
411
  "data-slot": "avatar-fallback",
376
412
  className: cn(
377
- "bg-muted flex size-full items-center justify-center rounded-full",
413
+ "bg-muted text-muted-foreground flex size-full items-center justify-center rounded-full text-sm group-data-[size=sm]/avatar:text-xs",
414
+ className
415
+ ),
416
+ ...props
417
+ }
418
+ );
419
+ }
420
+ function AvatarBadge({ className, ...props }) {
421
+ return /* @__PURE__ */ jsx(
422
+ "span",
423
+ {
424
+ "data-slot": "avatar-badge",
425
+ className: cn(
426
+ "bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full ring-2 select-none",
427
+ "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",
428
+ "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",
429
+ "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",
430
+ className
431
+ ),
432
+ ...props
433
+ }
434
+ );
435
+ }
436
+ function AvatarGroup({ className, ...props }) {
437
+ return /* @__PURE__ */ jsx(
438
+ "div",
439
+ {
440
+ "data-slot": "avatar-group",
441
+ className: cn(
442
+ "*:data-[slot=avatar]:ring-background group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2",
443
+ className
444
+ ),
445
+ ...props
446
+ }
447
+ );
448
+ }
449
+ function AvatarGroupCount({
450
+ className,
451
+ ...props
452
+ }) {
453
+ return /* @__PURE__ */ jsx(
454
+ "div",
455
+ {
456
+ "data-slot": "avatar-group-count",
457
+ className: cn(
458
+ "bg-muted text-muted-foreground ring-background relative flex size-8 shrink-0 items-center justify-center rounded-full text-sm ring-2 group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3",
378
459
  className
379
460
  ),
380
461
  ...props
@@ -382,14 +463,16 @@ function AvatarFallback({
382
463
  );
383
464
  }
384
465
  var badgeVariants = cva(
385
- "inline-flex items-center justify-center rounded-full border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",
466
+ "inline-flex items-center justify-center rounded-full border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",
386
467
  {
387
468
  variants: {
388
469
  variant: {
389
- default: "border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90",
390
- secondary: "border-transparent bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",
391
- destructive: "border-transparent bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
392
- outline: "text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"
470
+ default: "bg-primary text-primary-foreground [a&]:hover:bg-primary/90",
471
+ secondary: "bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",
472
+ destructive: "bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
473
+ outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
474
+ ghost: "[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
475
+ link: "text-primary underline-offset-4 [a&]:hover:underline"
393
476
  }
394
477
  },
395
478
  defaultVariants: {
@@ -399,7 +482,7 @@ var badgeVariants = cva(
399
482
  );
400
483
  function Badge({
401
484
  className,
402
- variant,
485
+ variant = "default",
403
486
  asChild = false,
404
487
  ...props
405
488
  }) {
@@ -408,6 +491,7 @@ function Badge({
408
491
  Comp,
409
492
  {
410
493
  "data-slot": "badge",
494
+ "data-variant": variant,
411
495
  className: cn(badgeVariants({ variant }), className),
412
496
  ...props
413
497
  }
@@ -1359,7 +1443,7 @@ function DialogContent({
1359
1443
  {
1360
1444
  "data-slot": "dialog-content",
1361
1445
  className: cn(
1362
- "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",
1446
+ "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 outline-none sm:max-w-lg",
1363
1447
  className
1364
1448
  ),
1365
1449
  ...props,
@@ -1391,8 +1475,13 @@ function DialogHeader({ className, ...props }) {
1391
1475
  }
1392
1476
  );
1393
1477
  }
1394
- function DialogFooter({ className, ...props }) {
1395
- return /* @__PURE__ */ jsx(
1478
+ function DialogFooter({
1479
+ className,
1480
+ showCloseButton = false,
1481
+ children,
1482
+ ...props
1483
+ }) {
1484
+ return /* @__PURE__ */ jsxs(
1396
1485
  "div",
1397
1486
  {
1398
1487
  "data-slot": "dialog-footer",
@@ -1400,7 +1489,11 @@ function DialogFooter({ className, ...props }) {
1400
1489
  "flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",
1401
1490
  className
1402
1491
  ),
1403
- ...props
1492
+ ...props,
1493
+ children: [
1494
+ children,
1495
+ showCloseButton && /* @__PURE__ */ jsx(DialogPrimitive.Close, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Close" }) })
1496
+ ]
1404
1497
  }
1405
1498
  );
1406
1499
  }
@@ -3499,6 +3592,39 @@ function PopoverAnchor({
3499
3592
  }) {
3500
3593
  return /* @__PURE__ */ jsx(PopoverPrimitive.Anchor, { "data-slot": "popover-anchor", ...props });
3501
3594
  }
3595
+ function PopoverHeader({ className, ...props }) {
3596
+ return /* @__PURE__ */ jsx(
3597
+ "div",
3598
+ {
3599
+ "data-slot": "popover-header",
3600
+ className: cn("flex flex-col gap-1 text-sm", className),
3601
+ ...props
3602
+ }
3603
+ );
3604
+ }
3605
+ function PopoverTitle({ className, ...props }) {
3606
+ return /* @__PURE__ */ jsx(
3607
+ "div",
3608
+ {
3609
+ "data-slot": "popover-title",
3610
+ className: cn("font-medium", className),
3611
+ ...props
3612
+ }
3613
+ );
3614
+ }
3615
+ function PopoverDescription({
3616
+ className,
3617
+ ...props
3618
+ }) {
3619
+ return /* @__PURE__ */ jsx(
3620
+ "p",
3621
+ {
3622
+ "data-slot": "popover-description",
3623
+ className: cn("text-muted-foreground", className),
3624
+ ...props
3625
+ }
3626
+ );
3627
+ }
3502
3628
  function Progress({
3503
3629
  className,
3504
3630
  value,
@@ -3566,7 +3692,7 @@ function ResizablePanelGroup({
3566
3692
  ...props
3567
3693
  }) {
3568
3694
  return /* @__PURE__ */ jsx(
3569
- ResizablePrimitive.PanelGroup,
3695
+ Group,
3570
3696
  {
3571
3697
  "data-slot": "resizable-panel-group",
3572
3698
  className: cn(
@@ -3580,7 +3706,7 @@ function ResizablePanelGroup({
3580
3706
  function ResizablePanel({
3581
3707
  ...props
3582
3708
  }) {
3583
- return /* @__PURE__ */ jsx(ResizablePrimitive.Panel, { "data-slot": "resizable-panel", ...props });
3709
+ return /* @__PURE__ */ jsx(Panel, { "data-slot": "resizable-panel", ...props });
3584
3710
  }
3585
3711
  function ResizableHandle({
3586
3712
  withHandle,
@@ -3588,7 +3714,7 @@ function ResizableHandle({
3588
3714
  ...props
3589
3715
  }) {
3590
3716
  return /* @__PURE__ */ jsx(
3591
- ResizablePrimitive.PanelResizeHandle,
3717
+ Separator$1,
3592
3718
  {
3593
3719
  "data-slot": "resizable-handle",
3594
3720
  className: cn(
@@ -3694,7 +3820,7 @@ function SelectTrigger({
3694
3820
  function SelectContent({
3695
3821
  className,
3696
3822
  children,
3697
- position = "popper",
3823
+ position = "item-aligned",
3698
3824
  align = "center",
3699
3825
  ...props
3700
3826
  }) {
@@ -3755,7 +3881,14 @@ function SelectItem({
3755
3881
  ),
3756
3882
  ...props,
3757
3883
  children: [
3758
- /* @__PURE__ */ jsx("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, { className: "size-4" }) }) }),
3884
+ /* @__PURE__ */ jsx(
3885
+ "span",
3886
+ {
3887
+ "data-slot": "select-item-indicator",
3888
+ className: "absolute right-2 flex size-3.5 items-center justify-center",
3889
+ children: /* @__PURE__ */ jsx(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, { className: "size-4" }) })
3890
+ }
3891
+ ),
3759
3892
  /* @__PURE__ */ jsx(SelectPrimitive.ItemText, { children })
3760
3893
  ]
3761
3894
  }
@@ -3846,6 +3979,7 @@ function SheetContent({
3846
3979
  className,
3847
3980
  children,
3848
3981
  side = "right",
3982
+ showCloseButton = true,
3849
3983
  ...props
3850
3984
  }) {
3851
3985
  return /* @__PURE__ */ jsxs(SheetPortal, { children: [
@@ -3865,7 +3999,7 @@ function SheetContent({
3865
3999
  ...props,
3866
4000
  children: [
3867
4001
  children,
3868
- /* @__PURE__ */ jsxs(DialogPrimitive.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none", children: [
4002
+ showCloseButton && /* @__PURE__ */ jsxs(DialogPrimitive.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none", children: [
3869
4003
  /* @__PURE__ */ jsx(XIcon, { className: "size-4" }),
3870
4004
  /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Close" })
3871
4005
  ] })
@@ -4682,14 +4816,16 @@ function Spinner({ className, ...props }) {
4682
4816
  }
4683
4817
  function Switch({
4684
4818
  className,
4819
+ size = "default",
4685
4820
  ...props
4686
4821
  }) {
4687
4822
  return /* @__PURE__ */ jsx(
4688
4823
  SwitchPrimitive.Root,
4689
4824
  {
4690
4825
  "data-slot": "switch",
4826
+ "data-size": size,
4691
4827
  className: cn(
4692
- "peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/50 dark:data-[state=unchecked]:bg-input/80 inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",
4828
+ "peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/50 dark:data-[state=unchecked]:bg-input/80 group/switch inline-flex shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-[1.15rem] data-[size=default]:w-8 data-[size=sm]:h-3.5 data-[size=sm]:w-6",
4693
4829
  className
4694
4830
  ),
4695
4831
  ...props,
@@ -4698,7 +4834,7 @@ function Switch({
4698
4834
  {
4699
4835
  "data-slot": "switch-thumb",
4700
4836
  className: cn(
4701
- "bg-background dark:data-[state=unchecked]:bg-foreground dark:data-[state=checked]:bg-primary-foreground pointer-events-none block size-4 rounded-full ring-0 transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0"
4837
+ "bg-background dark:data-[state=unchecked]:bg-foreground dark:data-[state=checked]:bg-primary-foreground pointer-events-none block rounded-full ring-0 transition-transform group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0"
4702
4838
  )
4703
4839
  }
4704
4840
  )
@@ -4809,29 +4945,48 @@ function TableCaption({
4809
4945
  }
4810
4946
  function Tabs({
4811
4947
  className,
4948
+ orientation = "horizontal",
4812
4949
  ...props
4813
4950
  }) {
4814
4951
  return /* @__PURE__ */ jsx(
4815
4952
  TabsPrimitive.Root,
4816
4953
  {
4817
4954
  "data-slot": "tabs",
4818
- className: cn("flex flex-col gap-2", className),
4955
+ "data-orientation": orientation,
4956
+ orientation,
4957
+ className: cn(
4958
+ "group/tabs flex gap-2 data-[orientation=horizontal]:flex-col",
4959
+ className
4960
+ ),
4819
4961
  ...props
4820
4962
  }
4821
4963
  );
4822
4964
  }
4965
+ var tabsListVariants = cva(
4966
+ "rounded-lg p-[3px] group-data-[orientation=horizontal]/tabs:h-9 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col",
4967
+ {
4968
+ variants: {
4969
+ variant: {
4970
+ default: "bg-muted",
4971
+ line: "gap-1 bg-transparent"
4972
+ }
4973
+ },
4974
+ defaultVariants: {
4975
+ variant: "default"
4976
+ }
4977
+ }
4978
+ );
4823
4979
  function TabsList({
4824
4980
  className,
4981
+ variant = "default",
4825
4982
  ...props
4826
4983
  }) {
4827
4984
  return /* @__PURE__ */ jsx(
4828
4985
  TabsPrimitive.List,
4829
4986
  {
4830
4987
  "data-slot": "tabs-list",
4831
- className: cn(
4832
- "bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",
4833
- className
4834
- ),
4988
+ "data-variant": variant,
4989
+ className: cn(tabsListVariants({ variant }), className),
4835
4990
  ...props
4836
4991
  }
4837
4992
  );
@@ -4845,7 +5000,10 @@ function TabsTrigger({
4845
5000
  {
4846
5001
  "data-slot": "tabs-trigger",
4847
5002
  className: cn(
4848
- "data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
5003
+ "focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground/60 hover:text-foreground dark:text-muted-foreground dark:hover:text-foreground relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-all group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 group-data-[variant=default]/tabs-list:data-[state=active]:shadow-sm group-data-[variant=line]/tabs-list:data-[state=active]:shadow-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
5004
+ "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-[state=active]:bg-transparent dark:group-data-[variant=line]/tabs-list:data-[state=active]:border-transparent dark:group-data-[variant=line]/tabs-list:data-[state=active]:bg-transparent",
5005
+ "data-[state=active]:bg-background dark:data-[state=active]:text-foreground dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 data-[state=active]:text-foreground",
5006
+ "after:bg-foreground after:absolute after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-right-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-[state=active]:after:opacity-100",
4849
5007
  className
4850
5008
  ),
4851
5009
  ...props
@@ -4960,6 +5118,6 @@ function ToggleGroupItem({
4960
5118
  );
4961
5119
  }
4962
5120
 
4963
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, Avatar, AvatarFallback, AvatarImage, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HoverCard, HoverCardContent, HoverCardTrigger, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Item4 as Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Kbd, KbdGroup, Label3 as Label, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, Progress, RadioGroup4 as RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip2 as Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, badgeVariants, buttonGroupVariants, buttonVariants, navigationMenuTriggerStyle, toggleVariants, useFormField, useSidebar };
5121
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HoverCard, HoverCardContent, HoverCardTrigger, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Item4 as Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Kbd, KbdGroup, Label3 as Label, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Progress, RadioGroup4 as RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip2 as Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, badgeVariants, buttonGroupVariants, buttonVariants, navigationMenuTriggerStyle, tabsListVariants, toggleVariants, useFormField, useSidebar };
4964
5122
  //# sourceMappingURL=index.js.map
4965
5123
  //# sourceMappingURL=index.js.map