@hex-core/components 0.1.0 → 1.0.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/index.js CHANGED
@@ -16,8 +16,10 @@ function cn(...inputs) {
16
16
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
17
17
  var buttonVariants = cva(
18
18
  [
19
- "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium",
20
- "transition-all duration-200 ease-out",
19
+ // Tokens consumed (fall back to Tailwind defaults when no theme is loaded):
20
+ // --gap-sm, --duration-normal, --control-height-{sm,md,lg}, --space-{2,3,4,8}
21
+ "inline-flex items-center justify-center gap-[var(--gap-sm,0.5rem)] whitespace-nowrap rounded-md text-sm font-medium",
22
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
21
23
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
22
24
  "disabled:pointer-events-none disabled:opacity-50",
23
25
  "active:scale-[0.98]",
@@ -50,10 +52,10 @@ var buttonVariants = cva(
50
52
  link: "text-primary underline-offset-4 hover:underline"
51
53
  },
52
54
  size: {
53
- default: "h-10 px-4 py-2",
54
- sm: "h-9 rounded-md px-3",
55
- lg: "h-11 rounded-md px-8 text-base",
56
- icon: "h-10 w-10"
55
+ default: "h-[var(--control-height-md,2.5rem)] px-[var(--space-4,1rem)] py-[var(--space-2,0.5rem)]",
56
+ sm: "h-[var(--control-height-sm,2.25rem)] rounded-md px-[var(--space-3,0.75rem)]",
57
+ lg: "h-[var(--control-height-lg,2.75rem)] rounded-md px-[var(--space-8,2rem)] text-base",
58
+ icon: "h-[var(--control-height-md,2.5rem)] w-[var(--control-height-md,2.5rem)]"
57
59
  }
58
60
  },
59
61
  defaultVariants: {
@@ -123,8 +125,8 @@ var Input = React2.forwardRef(
123
125
  {
124
126
  type,
125
127
  className: cn(
126
- "flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm",
127
- "transition-all duration-200 ease-out",
128
+ "flex h-[var(--control-height-md,2.5rem)] w-full rounded-md border border-input bg-background px-[var(--space-3,0.75rem)] py-[var(--space-2,0.5rem)] text-sm",
129
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
128
130
  "shadow-sm",
129
131
  "file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground",
130
132
  "placeholder:text-muted-foreground",
@@ -164,8 +166,8 @@ var Textarea = React4.forwardRef(
164
166
  "textarea",
165
167
  {
166
168
  className: cn(
167
- "flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm",
168
- "transition-all duration-200 ease-out",
169
+ "flex min-h-[80px] w-full rounded-md border border-input bg-background px-[var(--space-3,0.75rem)] py-[var(--space-2,0.5rem)] text-sm",
170
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
169
171
  "shadow-sm",
170
172
  "placeholder:text-muted-foreground",
171
173
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
@@ -192,7 +194,7 @@ var Checkbox = React5.forwardRef(({ className, ...props }, ref) => /* @__PURE__
192
194
  ref,
193
195
  className: cn(
194
196
  "group h-4 w-4 shrink-0 rounded-sm border border-input",
195
- "transition-all duration-200 ease-out",
197
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
196
198
  "shadow-sm",
197
199
  "hover:border-ring/50 hover:shadow-md",
198
200
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
@@ -247,8 +249,8 @@ var Switch = React6.forwardRef(
247
249
  SwitchPrimitive.Root,
248
250
  {
249
251
  className: cn(
250
- "peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent",
251
- "transition-all duration-200 ease-out",
252
+ "peer inline-flex h-6 w-[var(--control-height-lg,2.75rem)] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent",
253
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
252
254
  "shadow-sm",
253
255
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
254
256
  "disabled:cursor-not-allowed disabled:opacity-50",
@@ -263,7 +265,7 @@ var Switch = React6.forwardRef(
263
265
  {
264
266
  className: cn(
265
267
  "pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0",
266
- "transition-transform duration-200 ease-out",
268
+ "transition-transform duration-[var(--duration-normal,200ms)] ease-out",
267
269
  "data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0"
268
270
  )
269
271
  }
@@ -279,7 +281,7 @@ import { jsx as jsx7 } from "react/jsx-runtime";
279
281
  var badgeVariants = cva3(
280
282
  [
281
283
  "inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold",
282
- "transition-all duration-200 ease-out",
284
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
283
285
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2"
284
286
  ].join(" "),
285
287
  {
@@ -332,8 +334,8 @@ var SelectTrigger = React8.forwardRef(({ className, children, ...props }, ref) =
332
334
  {
333
335
  ref,
334
336
  className: cn(
335
- "flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm",
336
- "transition-all duration-200 ease-out shadow-sm",
337
+ "flex h-[var(--control-height-md,2.5rem)] w-full items-center justify-between rounded-md border border-input bg-background px-[var(--space-3,0.75rem)] py-[var(--space-2,0.5rem)] text-sm",
338
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out shadow-sm",
337
339
  "placeholder:text-muted-foreground",
338
340
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
339
341
  "focus-visible:shadow-md focus-visible:border-ring/50",
@@ -386,7 +388,7 @@ var SelectContent = React8.forwardRef(({ className, children, position = "popper
386
388
  SelectPrimitive.Viewport,
387
389
  {
388
390
  className: cn(
389
- "p-1",
391
+ "p-[var(--space-1,0.25rem)]",
390
392
  position === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
391
393
  ),
392
394
  children
@@ -399,7 +401,7 @@ var SelectLabel = React8.forwardRef(({ className, ...props }, ref) => /* @__PURE
399
401
  SelectPrimitive.Label,
400
402
  {
401
403
  ref,
402
- className: cn("py-1.5 pl-8 pr-2 text-sm font-semibold", className),
404
+ className: cn("py-1.5 pl-[var(--space-8,2rem)] pr-[var(--space-2,0.5rem)] text-sm font-semibold", className),
403
405
  ...props
404
406
  }
405
407
  ));
@@ -409,8 +411,8 @@ var SelectItem = React8.forwardRef(({ className, children, ...props }, ref) => /
409
411
  {
410
412
  ref,
411
413
  className: cn(
412
- "relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none",
413
- "transition-all duration-200 ease-out",
414
+ "relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-[var(--space-8,2rem)] pr-[var(--space-2,0.5rem)] text-sm outline-none",
415
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
414
416
  "focus:bg-accent focus:text-accent-foreground",
415
417
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
416
418
  className
@@ -441,7 +443,7 @@ var SelectSeparator = React8.forwardRef(({ className, ...props }, ref) => /* @__
441
443
  SelectPrimitive.Separator,
442
444
  {
443
445
  ref,
444
- className: cn("-mx-1 my-1 h-px bg-muted", className),
446
+ className: cn("-mx-[var(--space-1,0.25rem)] my-[var(--space-1,0.25rem)] h-px bg-muted", className),
445
447
  ...props
446
448
  }
447
449
  ));
@@ -455,7 +457,7 @@ var RadioGroup = React9.forwardRef(({ className, ...props }, ref) => /* @__PURE_
455
457
  RadioGroupPrimitive.Root,
456
458
  {
457
459
  className: cn(
458
- "grid gap-2 data-[orientation=horizontal]:flex data-[orientation=horizontal]:flex-row",
460
+ "grid gap-[var(--gap-sm,0.5rem)] data-[orientation=horizontal]:flex data-[orientation=horizontal]:flex-row",
459
461
  className
460
462
  ),
461
463
  ref,
@@ -469,7 +471,7 @@ var RadioGroupItem = React9.forwardRef(({ className, ...props }, ref) => /* @__P
469
471
  ref,
470
472
  className: cn(
471
473
  "aspect-square h-4 w-4 rounded-full border border-input",
472
- "transition-all duration-200 ease-out shadow-sm",
474
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out shadow-sm",
473
475
  "hover:border-ring/50 hover:shadow-md",
474
476
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
475
477
  "disabled:cursor-not-allowed disabled:opacity-50",
@@ -486,30 +488,46 @@ RadioGroupItem.displayName = "RadioGroupItem";
486
488
  import * as SliderPrimitive from "@radix-ui/react-slider";
487
489
  import * as React10 from "react";
488
490
  import { jsx as jsx11, jsxs as jsxs4 } from "react/jsx-runtime";
489
- var Slider = React10.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxs4(
490
- SliderPrimitive.Root,
491
- {
492
- ref,
493
- className: cn("relative flex w-full touch-none select-none items-center", className),
494
- ...props,
495
- children: [
496
- /* @__PURE__ */ jsx11(SliderPrimitive.Track, { className: "relative h-2 w-full grow overflow-hidden rounded-full bg-secondary", children: /* @__PURE__ */ jsx11(SliderPrimitive.Range, { className: "absolute h-full bg-primary" }) }),
497
- (props.value ?? props.defaultValue ?? [0]).map((_, i) => /* @__PURE__ */ jsx11(
498
- SliderPrimitive.Thumb,
499
- {
500
- className: cn(
501
- "block h-5 w-5 rounded-full border-2 border-primary bg-background",
502
- "transition-all duration-200 ease-out shadow-md",
503
- "hover:shadow-lg hover:scale-110",
504
- "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
505
- "disabled:pointer-events-none disabled:opacity-50"
506
- )
507
- },
508
- i
509
- ))
510
- ]
491
+ var Slider = React10.forwardRef(({ className, thumbLabels, ...props }, ref) => {
492
+ const values = props.value ?? props.defaultValue ?? [0];
493
+ const rootLabel = props["aria-label"];
494
+ const rootLabelledBy = props["aria-labelledby"];
495
+ if (typeof process !== "undefined" && process.env?.NODE_ENV !== "production" && thumbLabels && thumbLabels.length !== values.length) {
496
+ console.warn(
497
+ `Slider: thumbLabels.length (${thumbLabels.length}) does not match value.length (${values.length}). Missing labels fall back to indexed names; extra labels are ignored.`
498
+ );
511
499
  }
512
- ));
500
+ return /* @__PURE__ */ jsxs4(
501
+ SliderPrimitive.Root,
502
+ {
503
+ ref,
504
+ className: cn("relative flex w-full touch-none select-none items-center", className),
505
+ ...props,
506
+ children: [
507
+ /* @__PURE__ */ jsx11(SliderPrimitive.Track, { className: "relative h-2 w-full grow overflow-hidden rounded-full bg-secondary", children: /* @__PURE__ */ jsx11(SliderPrimitive.Range, { className: "absolute h-full bg-primary" }) }),
508
+ values.map((_, i) => {
509
+ const explicit = thumbLabels?.[i];
510
+ const fallback = values.length === 1 ? rootLabel : rootLabel ? `${rootLabel} (${i + 1} of ${values.length})` : void 0;
511
+ return /* @__PURE__ */ jsx11(
512
+ SliderPrimitive.Thumb,
513
+ {
514
+ "aria-label": explicit ?? fallback,
515
+ "aria-labelledby": explicit || fallback ? void 0 : rootLabelledBy,
516
+ className: cn(
517
+ "block h-5 w-5 rounded-full border-2 border-primary bg-background",
518
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out shadow-md",
519
+ "hover:shadow-lg hover:scale-110",
520
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
521
+ "disabled:pointer-events-none disabled:opacity-50"
522
+ )
523
+ },
524
+ i
525
+ );
526
+ })
527
+ ]
528
+ }
529
+ );
530
+ });
513
531
  Slider.displayName = "Slider";
514
532
 
515
533
  // src/primitives/toggle/toggle.tsx
@@ -520,7 +538,7 @@ import { jsx as jsx12 } from "react/jsx-runtime";
520
538
  var toggleVariants = cva4(
521
539
  [
522
540
  "inline-flex items-center justify-center rounded-md text-sm font-medium",
523
- "transition-all duration-200 ease-out",
541
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
524
542
  "hover:bg-muted hover:text-muted-foreground",
525
543
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
526
544
  "disabled:pointer-events-none disabled:opacity-50",
@@ -534,9 +552,9 @@ var toggleVariants = cva4(
534
552
  outline: "border border-input bg-transparent shadow-sm hover:bg-accent hover:text-accent-foreground"
535
553
  },
536
554
  size: {
537
- default: "h-10 px-3 min-w-10",
538
- sm: "h-9 px-2.5 min-w-9",
539
- lg: "h-11 px-5 min-w-11"
555
+ default: "h-[var(--control-height-md,2.5rem)] px-[var(--space-3,0.75rem)] min-w-[var(--control-height-md,2.5rem)]",
556
+ sm: "h-[var(--control-height-sm,2.25rem)] px-2.5 min-w-[var(--control-height-sm,2.25rem)]",
557
+ lg: "h-[var(--control-height-lg,2.75rem)] px-5 min-w-[var(--control-height-lg,2.75rem)]"
540
558
  }
541
559
  },
542
560
  defaultVariants: { variant: "default", size: "default" }
@@ -598,7 +616,7 @@ var Avatar = React13.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
598
616
  AvatarPrimitive.Root,
599
617
  {
600
618
  ref,
601
- className: cn("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full", className),
619
+ className: cn("relative flex h-[var(--control-height-md,2.5rem)] w-[var(--control-height-md,2.5rem)] shrink-0 overflow-hidden rounded-full", className),
602
620
  ...props
603
621
  }
604
622
  ));
@@ -664,14 +682,24 @@ Progress.displayName = "Progress";
664
682
  import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
665
683
  import * as React15 from "react";
666
684
  import { jsx as jsx17, jsxs as jsxs5 } from "react/jsx-runtime";
667
- var ScrollArea = React15.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs5(
685
+ var ScrollArea = React15.forwardRef(({ className, children, viewportTabIndex = 0, ...props }, ref) => /* @__PURE__ */ jsxs5(
668
686
  ScrollAreaPrimitive.Root,
669
687
  {
670
688
  ref,
671
689
  className: cn("relative overflow-hidden", className),
672
690
  ...props,
673
691
  children: [
674
- /* @__PURE__ */ jsx17(ScrollAreaPrimitive.Viewport, { className: "h-full w-full rounded-[inherit]", children }),
692
+ /* @__PURE__ */ jsx17(
693
+ ScrollAreaPrimitive.Viewport,
694
+ {
695
+ tabIndex: viewportTabIndex,
696
+ className: cn(
697
+ "h-full w-full rounded-[inherit]",
698
+ viewportTabIndex >= 0 && "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2"
699
+ ),
700
+ children
701
+ }
702
+ ),
675
703
  /* @__PURE__ */ jsx17(ScrollBar, { orientation: "vertical" }),
676
704
  /* @__PURE__ */ jsx17(ScrollBar, { orientation: "horizontal" }),
677
705
  /* @__PURE__ */ jsx17(ScrollAreaPrimitive.Corner, {})
@@ -685,7 +713,7 @@ var ScrollBar = React15.forwardRef(({ className, orientation = "vertical", ...pr
685
713
  ref,
686
714
  orientation,
687
715
  className: cn(
688
- "flex touch-none select-none transition-all duration-200 ease-out",
716
+ "flex touch-none select-none transition-all duration-[var(--duration-normal,200ms)] ease-out",
689
717
  orientation === "vertical" && "h-full w-2.5 border-l border-l-transparent p-[1px]",
690
718
  orientation === "horizontal" && "h-2.5 flex-col border-t border-t-transparent p-[1px]",
691
719
  className
@@ -710,7 +738,7 @@ var Card = React16.forwardRef(
710
738
  ref,
711
739
  className: cn(
712
740
  "rounded-lg border bg-card text-card-foreground",
713
- "shadow-sm transition-all duration-200 ease-out",
741
+ "shadow-sm transition-all duration-[var(--duration-normal,200ms)] ease-out",
714
742
  "hover:shadow-md",
715
743
  className
716
744
  ),
@@ -720,7 +748,14 @@ var Card = React16.forwardRef(
720
748
  );
721
749
  Card.displayName = "Card";
722
750
  var CardHeader = React16.forwardRef(
723
- ({ className, ...props }, ref) => /* @__PURE__ */ jsx18("div", { ref, className: cn("flex flex-col space-y-1.5 p-6", className), ...props })
751
+ ({ className, ...props }, ref) => /* @__PURE__ */ jsx18(
752
+ "div",
753
+ {
754
+ ref,
755
+ className: cn("flex flex-col space-y-1.5 p-[var(--space-6,1.5rem)]", className),
756
+ ...props
757
+ }
758
+ )
724
759
  );
725
760
  CardHeader.displayName = "CardHeader";
726
761
  var CardTitle = React16.forwardRef(
@@ -737,11 +772,18 @@ CardTitle.displayName = "CardTitle";
737
772
  var CardDescription = React16.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx18("p", { ref, className: cn("text-sm text-muted-foreground", className), ...props }));
738
773
  CardDescription.displayName = "CardDescription";
739
774
  var CardContent = React16.forwardRef(
740
- ({ className, ...props }, ref) => /* @__PURE__ */ jsx18("div", { ref, className: cn("p-6 pt-0", className), ...props })
775
+ ({ className, ...props }, ref) => /* @__PURE__ */ jsx18("div", { ref, className: cn("p-[var(--space-6,1.5rem)] pt-0", className), ...props })
741
776
  );
742
777
  CardContent.displayName = "CardContent";
743
778
  var CardFooter = React16.forwardRef(
744
- ({ className, ...props }, ref) => /* @__PURE__ */ jsx18("div", { ref, className: cn("flex items-center p-6 pt-0", className), ...props })
779
+ ({ className, ...props }, ref) => /* @__PURE__ */ jsx18(
780
+ "div",
781
+ {
782
+ ref,
783
+ className: cn("flex items-center p-[var(--space-6,1.5rem)] pt-0", className),
784
+ ...props
785
+ }
786
+ )
745
787
  );
746
788
  CardFooter.displayName = "CardFooter";
747
789
 
@@ -755,7 +797,7 @@ var TabsList = React17.forwardRef(({ className, ...props }, ref) => /* @__PURE__
755
797
  {
756
798
  ref,
757
799
  className: cn(
758
- "inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",
800
+ "inline-flex h-[var(--control-height-md,2.5rem)] items-center justify-center rounded-md bg-muted p-[var(--space-1,0.25rem)] text-muted-foreground",
759
801
  className
760
802
  ),
761
803
  ...props
@@ -767,8 +809,8 @@ var TabsTrigger = React17.forwardRef(({ className, ...props }, ref) => /* @__PUR
767
809
  {
768
810
  ref,
769
811
  className: cn(
770
- "inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium",
771
- "transition-all duration-200 ease-out",
812
+ "inline-flex items-center justify-center whitespace-nowrap rounded-sm px-[var(--space-3,0.75rem)] py-1.5 text-sm font-medium",
813
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
772
814
  "ring-offset-background hover:text-foreground",
773
815
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
774
816
  "disabled:pointer-events-none disabled:opacity-50",
@@ -784,7 +826,7 @@ var TabsContent = React17.forwardRef(({ className, ...props }, ref) => /* @__PUR
784
826
  {
785
827
  ref,
786
828
  className: cn(
787
- "mt-2 ring-offset-background",
829
+ "mt-[var(--space-2,0.5rem)] ring-offset-background",
788
830
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
789
831
  className
790
832
  ),
@@ -805,8 +847,8 @@ var AccordionTrigger = React18.forwardRef(({ className, children, ...props }, re
805
847
  {
806
848
  ref,
807
849
  className: cn(
808
- "flex flex-1 items-center justify-between py-4 font-medium",
809
- "transition-all duration-200 ease-out",
850
+ "flex flex-1 items-center justify-between py-[var(--space-4,1rem)] font-medium",
851
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
810
852
  "hover:underline",
811
853
  "[&[data-state=open]>svg]:rotate-180",
812
854
  className
@@ -826,7 +868,7 @@ var AccordionTrigger = React18.forwardRef(({ className, children, ...props }, re
826
868
  strokeWidth: "2",
827
869
  strokeLinecap: "round",
828
870
  strokeLinejoin: "round",
829
- className: "h-4 w-4 shrink-0 transition-transform duration-200",
871
+ className: "h-4 w-4 shrink-0 transition-transform duration-[var(--duration-normal,200ms)]",
830
872
  "aria-hidden": "true",
831
873
  children: /* @__PURE__ */ jsx20("polyline", { points: "6 9 12 15 18 9" })
832
874
  }
@@ -841,7 +883,7 @@ var AccordionContent = React18.forwardRef(({ className, children, ...props }, re
841
883
  ref,
842
884
  className: "overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",
843
885
  ...props,
844
- children: /* @__PURE__ */ jsx20("div", { className: cn("pb-4 pt-0", className), children })
886
+ children: /* @__PURE__ */ jsx20("div", { className: cn("pb-[var(--space-4,1rem)] pt-0", className), children })
845
887
  }
846
888
  ));
847
889
  AccordionContent.displayName = "AccordionContent";
@@ -868,29 +910,29 @@ var DialogOverlay = React19.forwardRef(({ className, ...props }, ref) => /* @__P
868
910
  }
869
911
  ));
870
912
  DialogOverlay.displayName = "DialogOverlay";
871
- var DialogContent = React19.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs7(DialogPortal, { children: [
913
+ var DialogContent = React19.forwardRef(({ className, children, scrollable = true, ...props }, ref) => /* @__PURE__ */ jsxs7(DialogPortal, { children: [
872
914
  /* @__PURE__ */ jsx21(DialogOverlay, {}),
873
915
  /* @__PURE__ */ jsxs7(
874
916
  DialogPrimitive.Content,
875
917
  {
876
918
  ref,
877
919
  className: cn(
878
- "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4",
879
- "border bg-background p-6 shadow-lg rounded-lg",
880
- "duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out",
920
+ "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%]",
921
+ scrollable ? "max-h-[calc(100vh-2rem)] border bg-background shadow-lg rounded-lg" : "gap-[var(--gap-md,1rem)] border bg-background p-[var(--space-6,1.5rem)] shadow-lg rounded-lg",
922
+ "duration-[var(--duration-normal,200ms)] data-[state=open]:animate-in data-[state=closed]:animate-out",
881
923
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
882
924
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
883
925
  className
884
926
  ),
885
927
  ...props,
886
928
  children: [
887
- children,
929
+ scrollable ? /* @__PURE__ */ jsx21("div", { className: "grid gap-[var(--gap-md,1rem)] overflow-y-auto p-[var(--space-6,1.5rem)]", children }) : children,
888
930
  /* @__PURE__ */ jsxs7(
889
931
  DialogPrimitive.Close,
890
932
  {
891
933
  className: cn(
892
- "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background",
893
- "transition-all duration-200 ease-out hover:opacity-100",
934
+ "absolute right-4 top-4 z-10 rounded-sm opacity-70 ring-offset-background bg-background/80 backdrop-blur-sm",
935
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out hover:opacity-100",
894
936
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
895
937
  "disabled:pointer-events-none"
896
938
  ),
@@ -990,9 +1032,9 @@ var AlertDialogContent = React20.forwardRef(({ className, ...props }, ref) => /*
990
1032
  {
991
1033
  ref,
992
1034
  className: cn(
993
- "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4",
994
- "border bg-background p-6 shadow-lg rounded-lg",
995
- "duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out",
1035
+ "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-[var(--gap-md,1rem)]",
1036
+ "border bg-background p-[var(--space-6,1.5rem)] shadow-lg rounded-lg",
1037
+ "duration-[var(--duration-normal,200ms)] data-[state=open]:animate-in data-[state=closed]:animate-out",
996
1038
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
997
1039
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
998
1040
  className
@@ -1046,9 +1088,9 @@ var AlertDialogAction = React20.forwardRef(({ className, ...props }, ref) => /*
1046
1088
  {
1047
1089
  ref,
1048
1090
  className: cn(
1049
- "inline-flex h-10 items-center justify-center rounded-md px-4 py-2 text-sm font-medium",
1091
+ "inline-flex h-[var(--control-height-md,2.5rem)] items-center justify-center rounded-md px-[var(--space-4,1rem)] py-[var(--space-2,0.5rem)] text-sm font-medium",
1050
1092
  "bg-destructive text-destructive-foreground shadow-sm",
1051
- "transition-all duration-200 ease-out",
1093
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1052
1094
  "hover:bg-destructive/90 hover:shadow-md",
1053
1095
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
1054
1096
  "disabled:pointer-events-none disabled:opacity-50",
@@ -1064,12 +1106,12 @@ var AlertDialogCancel = React20.forwardRef(({ className, ...props }, ref) => /*
1064
1106
  {
1065
1107
  ref,
1066
1108
  className: cn(
1067
- "inline-flex h-10 items-center justify-center rounded-md px-4 py-2 text-sm font-medium",
1109
+ "inline-flex h-[var(--control-height-md,2.5rem)] items-center justify-center rounded-md px-[var(--space-4,1rem)] py-[var(--space-2,0.5rem)] text-sm font-medium",
1068
1110
  "border border-input bg-background shadow-sm",
1069
- "transition-all duration-200 ease-out",
1111
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1070
1112
  "hover:bg-accent hover:text-accent-foreground hover:shadow-md",
1071
1113
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
1072
- "mt-2 sm:mt-0",
1114
+ "mt-[var(--space-2,0.5rem)] sm:mt-0",
1073
1115
  "active:scale-[0.98]",
1074
1116
  className
1075
1117
  ),
@@ -1094,7 +1136,7 @@ var DropdownMenuContent = React21.forwardRef(({ className, sideOffset = 4, ...pr
1094
1136
  ref,
1095
1137
  sideOffset,
1096
1138
  className: cn(
1097
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md",
1139
+ "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-[var(--space-1,0.25rem)] text-popover-foreground shadow-md",
1098
1140
  "data-[state=open]:animate-in data-[state=closed]:animate-out",
1099
1141
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
1100
1142
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
@@ -1110,11 +1152,11 @@ var DropdownMenuItem = React21.forwardRef(({ className, inset, ...props }, ref)
1110
1152
  {
1111
1153
  ref,
1112
1154
  className: cn(
1113
- "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none",
1114
- "transition-all duration-200 ease-out",
1155
+ "relative flex cursor-default select-none items-center gap-[var(--gap-sm,0.5rem)] rounded-sm px-[var(--space-2,0.5rem)] py-1.5 text-sm outline-none",
1156
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1115
1157
  "focus:bg-accent focus:text-accent-foreground",
1116
1158
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1117
- inset && "pl-8",
1159
+ inset && "pl-[var(--space-8,2rem)]",
1118
1160
  className
1119
1161
  ),
1120
1162
  ...props
@@ -1126,8 +1168,8 @@ var DropdownMenuCheckboxItem = React21.forwardRef(({ className, children, checke
1126
1168
  {
1127
1169
  ref,
1128
1170
  className: cn(
1129
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none",
1130
- "transition-all duration-200 ease-out",
1171
+ "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-[var(--space-8,2rem)] pr-[var(--space-2,0.5rem)] text-sm outline-none",
1172
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1131
1173
  "focus:bg-accent focus:text-accent-foreground",
1132
1174
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1133
1175
  className
@@ -1160,8 +1202,8 @@ var DropdownMenuRadioItem = React21.forwardRef(({ className, children, ...props
1160
1202
  {
1161
1203
  ref,
1162
1204
  className: cn(
1163
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none",
1164
- "transition-all duration-200 ease-out",
1205
+ "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-[var(--space-8,2rem)] pr-[var(--space-2,0.5rem)] text-sm outline-none",
1206
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1165
1207
  "focus:bg-accent focus:text-accent-foreground",
1166
1208
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1167
1209
  className
@@ -1178,7 +1220,7 @@ var DropdownMenuLabel = React21.forwardRef(({ className, inset, ...props }, ref)
1178
1220
  DropdownMenuPrimitive.Label,
1179
1221
  {
1180
1222
  ref,
1181
- className: cn("px-2 py-1.5 text-sm font-semibold", inset && "pl-8", className),
1223
+ className: cn("px-[var(--space-2,0.5rem)] py-1.5 text-sm font-semibold", inset && "pl-[var(--space-8,2rem)]", className),
1182
1224
  ...props
1183
1225
  }
1184
1226
  ));
@@ -1187,7 +1229,7 @@ var DropdownMenuSeparator = React21.forwardRef(({ className, ...props }, ref) =>
1187
1229
  DropdownMenuPrimitive.Separator,
1188
1230
  {
1189
1231
  ref,
1190
- className: cn("-mx-1 my-1 h-px bg-muted", className),
1232
+ className: cn("-mx-[var(--space-1,0.25rem)] my-[var(--space-1,0.25rem)] h-px bg-muted", className),
1191
1233
  ...props
1192
1234
  }
1193
1235
  ));
@@ -1216,7 +1258,7 @@ var PopoverContent = React22.forwardRef(({ className, align = "center", sideOffs
1216
1258
  align,
1217
1259
  sideOffset,
1218
1260
  className: cn(
1219
- "z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none",
1261
+ "z-50 w-72 rounded-md border bg-popover p-[var(--space-4,1rem)] text-popover-foreground shadow-md outline-none",
1220
1262
  "data-[state=open]:animate-in data-[state=closed]:animate-out",
1221
1263
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
1222
1264
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
@@ -1241,7 +1283,7 @@ var TooltipContent = React23.forwardRef(({ className, sideOffset = 4, ...props }
1241
1283
  ref,
1242
1284
  sideOffset,
1243
1285
  className: cn(
1244
- "z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground shadow-md",
1286
+ "z-50 overflow-hidden rounded-md bg-primary px-[var(--space-3,0.75rem)] py-1.5 text-xs text-primary-foreground shadow-md",
1245
1287
  "animate-in fade-in-0 zoom-in-95",
1246
1288
  "data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
1247
1289
  "data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
@@ -1359,8 +1401,8 @@ import * as React25 from "react";
1359
1401
  import { jsx as jsx27 } from "react/jsx-runtime";
1360
1402
  var alertVariants = cva5(
1361
1403
  [
1362
- "relative w-full rounded-lg border px-4 py-3 text-sm",
1363
- "transition-all duration-200 ease-out",
1404
+ "relative w-full rounded-lg border px-[var(--space-4,1rem)] py-[var(--space-3,0.75rem)] text-sm",
1405
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1364
1406
  "[&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:h-4 [&>svg]:w-4 [&>svg]:text-foreground",
1365
1407
  "[&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px]"
1366
1408
  ].join(" "),
@@ -1388,7 +1430,7 @@ var AlertTitle = React25.forwardRef(({ className, ...props }, ref) => /* @__PURE
1388
1430
  "h5",
1389
1431
  {
1390
1432
  ref,
1391
- className: cn("mb-1 font-medium leading-none tracking-tight", className),
1433
+ className: cn("mb-[var(--space-1,0.25rem)] font-medium leading-none tracking-tight", className),
1392
1434
  ...props
1393
1435
  }
1394
1436
  ));
@@ -1439,7 +1481,7 @@ var HoverCardContent = React26.forwardRef(({ className, align = "center", sideOf
1439
1481
  align,
1440
1482
  sideOffset,
1441
1483
  className: cn(
1442
- "z-50 w-64 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none",
1484
+ "z-50 w-64 rounded-md border bg-popover p-[var(--space-4,1rem)] text-popover-foreground shadow-md outline-none",
1443
1485
  "data-[state=open]:animate-in data-[state=closed]:animate-out",
1444
1486
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
1445
1487
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
@@ -1465,7 +1507,7 @@ var ContextMenuContent = React27.forwardRef(({ className, ...props }, ref) => /*
1465
1507
  {
1466
1508
  ref,
1467
1509
  className: cn(
1468
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md",
1510
+ "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-[var(--space-1,0.25rem)] text-popover-foreground shadow-md",
1469
1511
  "data-[state=open]:animate-in data-[state=closed]:animate-out",
1470
1512
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
1471
1513
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
@@ -1480,11 +1522,11 @@ var ContextMenuItem = React27.forwardRef(({ className, inset, ...props }, ref) =
1480
1522
  {
1481
1523
  ref,
1482
1524
  className: cn(
1483
- "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none",
1484
- "transition-all duration-200 ease-out",
1525
+ "relative flex cursor-default select-none items-center gap-[var(--gap-sm,0.5rem)] rounded-sm px-[var(--space-2,0.5rem)] py-1.5 text-sm outline-none",
1526
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1485
1527
  "focus:bg-accent focus:text-accent-foreground",
1486
1528
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1487
- inset && "pl-8",
1529
+ inset && "pl-[var(--space-8,2rem)]",
1488
1530
  className
1489
1531
  ),
1490
1532
  ...props
@@ -1496,8 +1538,8 @@ var ContextMenuCheckboxItem = React27.forwardRef(({ className, children, checked
1496
1538
  {
1497
1539
  ref,
1498
1540
  className: cn(
1499
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none",
1500
- "transition-all duration-200 ease-out",
1541
+ "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-[var(--space-8,2rem)] pr-[var(--space-2,0.5rem)] text-sm outline-none",
1542
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1501
1543
  "focus:bg-accent focus:text-accent-foreground",
1502
1544
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1503
1545
  className
@@ -1530,8 +1572,8 @@ var ContextMenuRadioItem = React27.forwardRef(({ className, children, ...props }
1530
1572
  {
1531
1573
  ref,
1532
1574
  className: cn(
1533
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none",
1534
- "transition-all duration-200 ease-out",
1575
+ "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-[var(--space-8,2rem)] pr-[var(--space-2,0.5rem)] text-sm outline-none",
1576
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1535
1577
  "focus:bg-accent focus:text-accent-foreground",
1536
1578
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1537
1579
  className
@@ -1548,7 +1590,7 @@ var ContextMenuLabel = React27.forwardRef(({ className, inset, ...props }, ref)
1548
1590
  ContextMenuPrimitive.Label,
1549
1591
  {
1550
1592
  ref,
1551
- className: cn("px-2 py-1.5 text-sm font-semibold text-foreground", inset && "pl-8", className),
1593
+ className: cn("px-[var(--space-2,0.5rem)] py-1.5 text-sm font-semibold text-foreground", inset && "pl-[var(--space-8,2rem)]", className),
1552
1594
  ...props
1553
1595
  }
1554
1596
  ));
@@ -1557,7 +1599,7 @@ var ContextMenuSeparator = React27.forwardRef(({ className, ...props }, ref) =>
1557
1599
  ContextMenuPrimitive.Separator,
1558
1600
  {
1559
1601
  ref,
1560
- className: cn("-mx-1 my-1 h-px bg-border", className),
1602
+ className: cn("-mx-[var(--space-1,0.25rem)] my-[var(--space-1,0.25rem)] h-px bg-border", className),
1561
1603
  ...props
1562
1604
  }
1563
1605
  ));
@@ -1581,7 +1623,7 @@ var Menubar = React28.forwardRef(({ className, ...props }, ref) => /* @__PURE__
1581
1623
  {
1582
1624
  ref,
1583
1625
  className: cn(
1584
- "flex h-10 items-center space-x-1 rounded-md border bg-background p-1",
1626
+ "flex h-[var(--control-height-md,2.5rem)] items-center space-x-1 rounded-md border bg-background p-[var(--space-1,0.25rem)]",
1585
1627
  className
1586
1628
  ),
1587
1629
  ...props
@@ -1597,8 +1639,8 @@ var MenubarTrigger = React28.forwardRef(({ className, ...props }, ref) => /* @__
1597
1639
  {
1598
1640
  ref,
1599
1641
  className: cn(
1600
- "flex cursor-default select-none items-center rounded-sm px-3 py-1.5 text-sm font-medium outline-none",
1601
- "transition-all duration-200 ease-out",
1642
+ "flex cursor-default select-none items-center rounded-sm px-[var(--space-3,0.75rem)] py-1.5 text-sm font-medium outline-none",
1643
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1602
1644
  "focus:bg-accent focus:text-accent-foreground",
1603
1645
  "data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
1604
1646
  className
@@ -1615,7 +1657,7 @@ var MenubarContent = React28.forwardRef(({ className, align = "start", alignOffs
1615
1657
  alignOffset,
1616
1658
  sideOffset,
1617
1659
  className: cn(
1618
- "z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md",
1660
+ "z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-[var(--space-1,0.25rem)] text-popover-foreground shadow-md",
1619
1661
  "data-[state=open]:animate-in data-[state=closed]:animate-out",
1620
1662
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
1621
1663
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
@@ -1630,11 +1672,11 @@ var MenubarItem = React28.forwardRef(({ className, inset, ...props }, ref) => /*
1630
1672
  {
1631
1673
  ref,
1632
1674
  className: cn(
1633
- "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none",
1634
- "transition-all duration-200 ease-out",
1675
+ "relative flex cursor-default select-none items-center gap-[var(--gap-sm,0.5rem)] rounded-sm px-[var(--space-2,0.5rem)] py-1.5 text-sm outline-none",
1676
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
1635
1677
  "focus:bg-accent focus:text-accent-foreground",
1636
1678
  "data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
1637
- inset && "pl-8",
1679
+ inset && "pl-[var(--space-8,2rem)]",
1638
1680
  className
1639
1681
  ),
1640
1682
  ...props
@@ -1645,7 +1687,7 @@ var MenubarLabel = React28.forwardRef(({ className, inset, ...props }, ref) => /
1645
1687
  MenubarPrimitive.Label,
1646
1688
  {
1647
1689
  ref,
1648
- className: cn("px-2 py-1.5 text-sm font-semibold", inset && "pl-8", className),
1690
+ className: cn("px-[var(--space-2,0.5rem)] py-1.5 text-sm font-semibold", inset && "pl-[var(--space-8,2rem)]", className),
1649
1691
  ...props
1650
1692
  }
1651
1693
  ));
@@ -1654,7 +1696,7 @@ var MenubarSeparator = React28.forwardRef(({ className, ...props }, ref) => /* @
1654
1696
  MenubarPrimitive.Separator,
1655
1697
  {
1656
1698
  ref,
1657
- className: cn("-mx-1 my-1 h-px bg-muted", className),
1699
+ className: cn("-mx-[var(--space-1,0.25rem)] my-[var(--space-1,0.25rem)] h-px bg-muted", className),
1658
1700
  ...props
1659
1701
  }
1660
1702
  ));
@@ -1698,7 +1740,7 @@ var NavigationMenuList = React29.forwardRef(({ className, ...props }, ref) => /*
1698
1740
  NavigationMenuList.displayName = "NavigationMenuList";
1699
1741
  var NavigationMenuItem = NavigationMenuPrimitive.Item;
1700
1742
  var navigationMenuTriggerStyle = cva6(
1701
- "group inline-flex h-10 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-all duration-200 ease-out hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50"
1743
+ "group inline-flex h-[var(--control-height-md,2.5rem)] w-max items-center justify-center rounded-md bg-background px-[var(--space-4,1rem)] py-[var(--space-2,0.5rem)] text-sm font-medium transition-all duration-[var(--duration-normal,200ms)] ease-out hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50"
1702
1744
  );
1703
1745
  var NavigationMenuTrigger = React29.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs11(
1704
1746
  NavigationMenuPrimitive.Trigger,
@@ -1718,7 +1760,7 @@ var NavigationMenuTrigger = React29.forwardRef(({ className, children, ...props
1718
1760
  strokeWidth: "2",
1719
1761
  strokeLinecap: "round",
1720
1762
  strokeLinejoin: "round",
1721
- className: "relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180",
1763
+ className: "relative top-[1px] ml-[var(--space-1,0.25rem)] h-3 w-3 transition duration-[var(--duration-normal,200ms)] group-data-[state=open]:rotate-180",
1722
1764
  "aria-hidden": "true",
1723
1765
  children: /* @__PURE__ */ jsx32("polyline", { points: "6 9 12 15 18 9" })
1724
1766
  }
@@ -1782,7 +1824,7 @@ var BreadcrumbList = React30.forwardRef(
1782
1824
  {
1783
1825
  ref,
1784
1826
  className: cn(
1785
- "flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5",
1827
+ "flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-[var(--gap-sm,0.5rem)].5",
1786
1828
  className
1787
1829
  ),
1788
1830
  ...props
@@ -1807,7 +1849,7 @@ var BreadcrumbLink = React30.forwardRef(({ asChild, className, ...props }, ref)
1807
1849
  Comp,
1808
1850
  {
1809
1851
  ref,
1810
- className: cn("transition-all duration-200 ease-out hover:text-foreground", className),
1852
+ className: cn("transition-all duration-[var(--duration-normal,200ms)] ease-out hover:text-foreground", className),
1811
1853
  ...props
1812
1854
  }
1813
1855
  );
@@ -1851,7 +1893,7 @@ function BreadcrumbEllipsis({ className, ...props }) {
1851
1893
  return /* @__PURE__ */ jsxs12(
1852
1894
  "span",
1853
1895
  {
1854
- className: cn("flex h-9 w-9 items-center justify-center", className),
1896
+ className: cn("flex h-[var(--control-height-sm,2.25rem)] w-[var(--control-height-sm,2.25rem)] items-center justify-center", className),
1855
1897
  ...props,
1856
1898
  children: [
1857
1899
  /* @__PURE__ */ jsxs12(
@@ -1914,7 +1956,7 @@ var TableRow = React31.forwardRef(({ className, ...props }, ref) => /* @__PURE__
1914
1956
  {
1915
1957
  ref,
1916
1958
  className: cn(
1917
- "border-b transition-all duration-200 ease-out hover:bg-muted/50 data-[state=selected]:bg-muted",
1959
+ "border-b transition-all duration-[var(--duration-normal,200ms)] ease-out hover:bg-muted/50 data-[state=selected]:bg-muted",
1918
1960
  className
1919
1961
  ),
1920
1962
  ...props
@@ -1926,7 +1968,7 @@ var TableHead = React31.forwardRef(({ className, ...props }, ref) => /* @__PURE_
1926
1968
  {
1927
1969
  ref,
1928
1970
  className: cn(
1929
- "h-10 px-4 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0",
1971
+ "h-[var(--control-height-md,2.5rem)] px-[var(--space-4,1rem)] text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0",
1930
1972
  className
1931
1973
  ),
1932
1974
  ...props
@@ -1937,7 +1979,7 @@ var TableCell = React31.forwardRef(({ className, ...props }, ref) => /* @__PURE_
1937
1979
  "td",
1938
1980
  {
1939
1981
  ref,
1940
- className: cn("p-4 align-middle [&:has([role=checkbox])]:pr-0", className),
1982
+ className: cn("p-[var(--space-4,1rem)] align-middle [&:has([role=checkbox])]:pr-0", className),
1941
1983
  ...props
1942
1984
  }
1943
1985
  ));
@@ -1946,7 +1988,10 @@ var TableCaption = React31.forwardRef(({ className, ...props }, ref) => /* @__PU
1946
1988
  "caption",
1947
1989
  {
1948
1990
  ref,
1949
- className: cn("mt-4 text-sm text-muted-foreground", className),
1991
+ className: cn(
1992
+ "caption-bottom mt-[var(--space-4,1rem)] text-sm text-muted-foreground",
1993
+ className
1994
+ ),
1950
1995
  ...props
1951
1996
  }
1952
1997
  ));
@@ -1959,13 +2004,19 @@ import {
1959
2004
  useReactTable
1960
2005
  } from "@tanstack/react-table";
1961
2006
  import { jsx as jsx35, jsxs as jsxs13 } from "react/jsx-runtime";
1962
- function DataTable({ columns, data }) {
2007
+ function DataTable({
2008
+ columns,
2009
+ data,
2010
+ caption,
2011
+ "aria-label": ariaLabel
2012
+ }) {
1963
2013
  const table = useReactTable({
1964
2014
  data,
1965
2015
  columns,
1966
2016
  getCoreRowModel: getCoreRowModel()
1967
2017
  });
1968
- return /* @__PURE__ */ jsx35("div", { className: "rounded-md border", children: /* @__PURE__ */ jsxs13(Table, { children: [
2018
+ return /* @__PURE__ */ jsx35("div", { className: "rounded-md border", children: /* @__PURE__ */ jsxs13(Table, { "aria-label": ariaLabel, children: [
2019
+ caption ? /* @__PURE__ */ jsx35(TableCaption, { children: caption }) : null,
1969
2020
  /* @__PURE__ */ jsx35(TableHeader, { children: table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ jsx35(TableRow, { children: headerGroup.headers.map((header) => /* @__PURE__ */ jsx35(TableHead, { children: header.isPlaceholder ? null : flexRender(header.column.columnDef.header, header.getContext()) }, header.id)) }, headerGroup.id)) }),
1970
2021
  /* @__PURE__ */ jsx35(TableBody, { children: table.getRowModel().rows?.length ? table.getRowModel().rows.map((row) => /* @__PURE__ */ jsx35(TableRow, { "data-state": row.getIsSelected() && "selected", children: row.getVisibleCells().map((cell) => /* @__PURE__ */ jsx35(TableCell, { children: flexRender(cell.column.columnDef.cell, cell.getContext()) }, cell.id)) }, row.id)) : /* @__PURE__ */ jsx35(TableRow, { children: /* @__PURE__ */ jsx35(TableCell, { colSpan: columns.length, className: "h-24 text-center", children: "No results." }) }) })
1971
2022
  ] }) });
@@ -2080,7 +2131,7 @@ function PaginationEllipsis({ className, ...props }) {
2080
2131
  return /* @__PURE__ */ jsxs14(
2081
2132
  "span",
2082
2133
  {
2083
- className: cn("flex h-9 w-9 items-center justify-center", className),
2134
+ className: cn("flex h-[var(--control-height-sm,2.25rem)] w-[var(--control-height-sm,2.25rem)] items-center justify-center", className),
2084
2135
  ...props,
2085
2136
  children: [
2086
2137
  /* @__PURE__ */ jsxs14(
@@ -2121,25 +2172,25 @@ function Calendar({
2121
2172
  DayPicker,
2122
2173
  {
2123
2174
  showOutsideDays,
2124
- className: cn("relative p-3", className),
2175
+ className: cn("relative p-[var(--space-3,0.75rem)]", className),
2125
2176
  classNames: {
2126
- months: "flex flex-col sm:flex-row gap-4",
2127
- month: "flex flex-col gap-4",
2177
+ months: "flex flex-col sm:flex-row gap-[var(--gap-md,1rem)]",
2178
+ month: "flex flex-col gap-[var(--gap-md,1rem)]",
2128
2179
  month_caption: "flex h-7 items-center justify-center",
2129
2180
  caption_label: "text-sm font-medium",
2130
2181
  nav: "absolute inset-x-3 top-3 z-10 flex items-center justify-between pointer-events-none [&>button]:pointer-events-auto",
2131
2182
  button_previous: cn(
2132
- "inline-flex h-7 w-7 items-center justify-center rounded-md border bg-transparent p-0 opacity-60 transition-all duration-200 ease-out hover:opacity-100 disabled:pointer-events-none disabled:opacity-30"
2183
+ "inline-flex h-7 w-7 items-center justify-center rounded-md border bg-transparent p-0 opacity-60 transition-all duration-[var(--duration-normal,200ms)] ease-out hover:opacity-100 disabled:pointer-events-none disabled:opacity-30"
2133
2184
  ),
2134
2185
  button_next: cn(
2135
- "inline-flex h-7 w-7 items-center justify-center rounded-md border bg-transparent p-0 opacity-60 transition-all duration-200 ease-out hover:opacity-100 disabled:pointer-events-none disabled:opacity-30"
2186
+ "inline-flex h-7 w-7 items-center justify-center rounded-md border bg-transparent p-0 opacity-60 transition-all duration-[var(--duration-normal,200ms)] ease-out hover:opacity-100 disabled:pointer-events-none disabled:opacity-30"
2136
2187
  ),
2137
2188
  month_grid: "w-full border-collapse space-y-1",
2138
2189
  weekdays: "flex",
2139
- weekday: "text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",
2140
- week: "flex w-full mt-2",
2190
+ weekday: "text-muted-foreground rounded-md w-[var(--control-height-sm,2.25rem)] font-normal text-[0.8rem]",
2191
+ week: "flex w-full mt-[var(--space-2,0.5rem)]",
2141
2192
  day: "relative p-0 text-center text-sm focus-within:relative focus-within:z-20 [&:has([aria-selected])]:bg-accent [&:has([aria-selected].range-end)]:rounded-r-md [&:has([aria-selected].range-start)]:rounded-l-md first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md",
2142
- day_button: "inline-flex h-9 w-9 items-center justify-center rounded-md p-0 text-sm font-normal transition-all duration-200 ease-out hover:bg-accent hover:text-accent-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 aria-selected:opacity-100",
2193
+ day_button: "inline-flex h-[var(--control-height-sm,2.25rem)] w-[var(--control-height-sm,2.25rem)] items-center justify-center rounded-md p-0 text-sm font-normal transition-all duration-[var(--duration-normal,200ms)] ease-out hover:bg-accent hover:text-accent-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 aria-selected:opacity-100",
2143
2194
  selected: "bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",
2144
2195
  today: "bg-accent text-accent-foreground",
2145
2196
  outside: "day-outside text-muted-foreground aria-selected:bg-accent/50 aria-selected:text-muted-foreground",
@@ -2198,7 +2249,7 @@ function DatePicker({
2198
2249
  disabled,
2199
2250
  "aria-label": ariaLabel ?? placeholder,
2200
2251
  className: cn(
2201
- "inline-flex h-10 w-[240px] items-center justify-start gap-2 rounded-md border border-input bg-background px-3 py-2 text-left text-sm font-normal transition-all duration-200 ease-out",
2252
+ "inline-flex h-[var(--control-height-md,2.5rem)] w-[240px] items-center justify-start gap-[var(--gap-sm,0.5rem)] rounded-md border border-input bg-background px-[var(--space-3,0.75rem)] py-[var(--space-2,0.5rem)] text-left text-sm font-normal transition-all duration-[var(--duration-normal,200ms)] ease-out",
2202
2253
  "hover:bg-accent hover:text-accent-foreground",
2203
2254
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
2204
2255
  "disabled:pointer-events-none disabled:opacity-50",
@@ -2256,7 +2307,7 @@ var InputOTP = React34.forwardRef(
2256
2307
  {
2257
2308
  ref,
2258
2309
  containerClassName: cn(
2259
- "flex items-center gap-2 has-[:disabled]:opacity-50",
2310
+ "flex items-center gap-[var(--gap-sm,0.5rem)] has-[:disabled]:opacity-50",
2260
2311
  containerClassName
2261
2312
  ),
2262
2313
  className: cn("disabled:cursor-not-allowed", className),
@@ -2279,7 +2330,7 @@ var InputOTPSlot = React34.forwardRef(
2279
2330
  {
2280
2331
  ref,
2281
2332
  className: cn(
2282
- "relative flex h-10 w-10 items-center justify-center border-y border-r border-input text-sm transition-all duration-200 ease-out",
2333
+ "relative flex h-[var(--control-height-md,2.5rem)] w-[var(--control-height-md,2.5rem)] items-center justify-center border-y border-r border-input text-sm transition-all duration-[var(--duration-normal,200ms)] ease-out",
2283
2334
  "first:rounded-l-md first:border-l last:rounded-r-md",
2284
2335
  isActive && "z-10 ring-2 ring-ring ring-offset-2 ring-offset-background",
2285
2336
  className
@@ -2334,10 +2385,10 @@ function CommandDialog({
2334
2385
  /* @__PURE__ */ jsx40(DialogTitle, { children: title }),
2335
2386
  /* @__PURE__ */ jsx40(DialogDescription, { children: description })
2336
2387
  ] }),
2337
- /* @__PURE__ */ jsx40(DialogContent, { className: "overflow-hidden p-0", children: /* @__PURE__ */ jsx40(Command, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children }) })
2388
+ /* @__PURE__ */ jsx40(DialogContent, { className: "overflow-hidden p-0", scrollable: false, children: /* @__PURE__ */ jsx40(Command, { className: "[&_[cmdk-group-heading]]:px-[var(--space-2,0.5rem)] [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-[var(--space-2,0.5rem)] [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-[var(--space-2,0.5rem)] [&_[cmdk-item]]:py-[var(--space-3,0.75rem)] [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children }) })
2338
2389
  ] });
2339
2390
  }
2340
- var CommandInput = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxs17("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
2391
+ var CommandInput = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxs17("div", { className: "flex items-center border-b px-[var(--space-3,0.75rem)]", "cmdk-input-wrapper": "", children: [
2341
2392
  /* @__PURE__ */ jsxs17(
2342
2393
  "svg",
2343
2394
  {
@@ -2348,7 +2399,7 @@ var CommandInput = React35.forwardRef(({ className, ...props }, ref) => /* @__PU
2348
2399
  strokeWidth: "2",
2349
2400
  strokeLinecap: "round",
2350
2401
  strokeLinejoin: "round",
2351
- className: "mr-2 h-4 w-4 shrink-0 opacity-50",
2402
+ className: "mr-[var(--space-2,0.5rem)] h-4 w-4 shrink-0 opacity-50",
2352
2403
  "aria-hidden": "true",
2353
2404
  children: [
2354
2405
  /* @__PURE__ */ jsx40("circle", { cx: "11", cy: "11", r: "8" }),
@@ -2361,7 +2412,7 @@ var CommandInput = React35.forwardRef(({ className, ...props }, ref) => /* @__PU
2361
2412
  {
2362
2413
  ref,
2363
2414
  className: cn(
2364
- "flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",
2415
+ "flex h-[var(--control-height-lg,2.75rem)] w-full rounded-md bg-transparent py-[var(--space-3,0.75rem)] text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",
2365
2416
  className
2366
2417
  ),
2367
2418
  ...props
@@ -2378,14 +2429,14 @@ var CommandList = React35.forwardRef(({ className, ...props }, ref) => /* @__PUR
2378
2429
  }
2379
2430
  ));
2380
2431
  CommandList.displayName = "CommandList";
2381
- var CommandEmpty = React35.forwardRef((props, ref) => /* @__PURE__ */ jsx40(CommandPrimitive.Empty, { ref, className: "py-6 text-center text-sm", ...props }));
2432
+ var CommandEmpty = React35.forwardRef((props, ref) => /* @__PURE__ */ jsx40(CommandPrimitive.Empty, { ref, className: "py-[var(--space-6,1.5rem)] text-center text-sm", ...props }));
2382
2433
  CommandEmpty.displayName = "CommandEmpty";
2383
2434
  var CommandGroup = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx40(
2384
2435
  CommandPrimitive.Group,
2385
2436
  {
2386
2437
  ref,
2387
2438
  className: cn(
2388
- "overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
2439
+ "overflow-hidden p-[var(--space-1,0.25rem)] text-foreground [&_[cmdk-group-heading]]:px-[var(--space-2,0.5rem)] [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
2389
2440
  className
2390
2441
  ),
2391
2442
  ...props
@@ -2393,10 +2444,12 @@ var CommandGroup = React35.forwardRef(({ className, ...props }, ref) => /* @__PU
2393
2444
  ));
2394
2445
  CommandGroup.displayName = "CommandGroup";
2395
2446
  var CommandSeparator = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx40(
2396
- CommandPrimitive.Separator,
2447
+ "div",
2397
2448
  {
2398
2449
  ref,
2399
- className: cn("-mx-1 h-px bg-border", className),
2450
+ role: "none",
2451
+ "data-cmdk-separator": "",
2452
+ className: cn("-mx-[var(--space-1,0.25rem)] h-px bg-border", className),
2400
2453
  ...props
2401
2454
  }
2402
2455
  ));
@@ -2406,7 +2459,7 @@ var CommandItem = React35.forwardRef(({ className, ...props }, ref) => /* @__PUR
2406
2459
  {
2407
2460
  ref,
2408
2461
  className: cn(
2409
- "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-all duration-200 ease-out",
2462
+ "relative flex cursor-default select-none items-center gap-[var(--gap-sm,0.5rem)] rounded-sm px-[var(--space-2,0.5rem)] py-1.5 text-sm outline-none transition-all duration-[var(--duration-normal,200ms)] ease-out",
2410
2463
  "data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50",
2411
2464
  "data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground",
2412
2465
  "[&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
@@ -2442,9 +2495,11 @@ function Combobox({
2442
2495
  emptyText = "No results found.",
2443
2496
  disabled,
2444
2497
  className,
2445
- "aria-label": ariaLabel
2498
+ "aria-label": ariaLabel,
2499
+ "aria-labelledby": ariaLabelledBy
2446
2500
  }) {
2447
2501
  const [open, setOpen] = React36.useState(false);
2502
+ const listboxId = React36.useId();
2448
2503
  const selected = options.find((o) => o.value === value);
2449
2504
  return /* @__PURE__ */ jsxs18(Popover, { open, onOpenChange: setOpen, children: [
2450
2505
  /* @__PURE__ */ jsx41(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxs18(
@@ -2454,10 +2509,12 @@ function Combobox({
2454
2509
  role: "combobox",
2455
2510
  "aria-expanded": open,
2456
2511
  "aria-haspopup": "listbox",
2512
+ "aria-controls": open ? listboxId : void 0,
2457
2513
  "aria-label": ariaLabel,
2514
+ "aria-labelledby": ariaLabelledBy,
2458
2515
  disabled,
2459
2516
  className: cn(
2460
- "inline-flex h-10 w-[240px] items-center justify-between gap-2 rounded-md border border-input bg-background px-3 py-2 text-sm font-normal transition-all duration-200 ease-out",
2517
+ "inline-flex h-[var(--control-height-md,2.5rem)] w-[240px] items-center justify-between gap-[var(--gap-sm,0.5rem)] rounded-md border border-input bg-background px-[var(--space-3,0.75rem)] py-[var(--space-2,0.5rem)] text-sm font-normal transition-all duration-[var(--duration-normal,200ms)] ease-out",
2461
2518
  "hover:bg-accent hover:text-accent-foreground",
2462
2519
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
2463
2520
  "disabled:pointer-events-none disabled:opacity-50",
@@ -2486,7 +2543,7 @@ function Combobox({
2486
2543
  ) }),
2487
2544
  /* @__PURE__ */ jsx41(PopoverContent, { className: "w-[240px] p-0", align: "start", children: /* @__PURE__ */ jsxs18(Command, { children: [
2488
2545
  /* @__PURE__ */ jsx41(CommandInput, { placeholder: searchPlaceholder }),
2489
- /* @__PURE__ */ jsxs18(CommandList, { children: [
2546
+ /* @__PURE__ */ jsxs18(CommandList, { id: listboxId, children: [
2490
2547
  /* @__PURE__ */ jsx41(CommandEmpty, { children: emptyText }),
2491
2548
  /* @__PURE__ */ jsx41(CommandGroup, { children: options.map((option) => /* @__PURE__ */ jsxs18(
2492
2549
  CommandItem,
@@ -2509,7 +2566,7 @@ function Combobox({
2509
2566
  strokeLinecap: "round",
2510
2567
  strokeLinejoin: "round",
2511
2568
  className: cn(
2512
- "mr-2 h-4 w-4",
2569
+ "mr-[var(--space-2,0.5rem)] h-4 w-4",
2513
2570
  value === option.value ? "opacity-100" : "opacity-0"
2514
2571
  ),
2515
2572
  "aria-hidden": "true",
@@ -2552,9 +2609,9 @@ var SheetOverlay = React37.forwardRef(({ className, ...props }, ref) => /* @__PU
2552
2609
  SheetOverlay.displayName = "SheetOverlay";
2553
2610
  var sheetVariants = cva7(
2554
2611
  cn(
2555
- "fixed z-50 gap-4 bg-background p-6 shadow-lg",
2612
+ "fixed z-50 gap-[var(--gap-md,1rem)] bg-background p-[var(--space-6,1.5rem)] shadow-lg",
2556
2613
  "transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out",
2557
- "data-[state=closed]:duration-300 data-[state=open]:duration-500"
2614
+ "data-[state=closed]:duration-[var(--duration-slow,300ms)] data-[state=open]:duration-500"
2558
2615
  ),
2559
2616
  {
2560
2617
  variants: {
@@ -2585,7 +2642,7 @@ var SheetContent = React37.forwardRef(({ side = "right", className, children, ..
2585
2642
  {
2586
2643
  className: cn(
2587
2644
  "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background",
2588
- "transition-all duration-200 ease-out hover:opacity-100",
2645
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out hover:opacity-100",
2589
2646
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
2590
2647
  "disabled:pointer-events-none"
2591
2648
  ),
@@ -2692,7 +2749,7 @@ var DrawerContent = React38.forwardRef(({ className, children, ...props }, ref)
2692
2749
  ),
2693
2750
  ...props,
2694
2751
  children: [
2695
- /* @__PURE__ */ jsx43("div", { className: "mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted", "aria-hidden": "true" }),
2752
+ /* @__PURE__ */ jsx43("div", { className: "mx-auto mt-[var(--space-4,1rem)] h-2 w-[100px] rounded-full bg-muted", "aria-hidden": "true" }),
2696
2753
  children
2697
2754
  ]
2698
2755
  }
@@ -2703,13 +2760,13 @@ function DrawerHeader({ className, ...props }) {
2703
2760
  return /* @__PURE__ */ jsx43(
2704
2761
  "div",
2705
2762
  {
2706
- className: cn("grid gap-1.5 p-4 text-center sm:text-left", className),
2763
+ className: cn("grid gap-1.5 p-[var(--space-4,1rem)] text-center sm:text-left", className),
2707
2764
  ...props
2708
2765
  }
2709
2766
  );
2710
2767
  }
2711
2768
  function DrawerFooter({ className, ...props }) {
2712
- return /* @__PURE__ */ jsx43("div", { className: cn("mt-auto flex flex-col gap-2 p-4", className), ...props });
2769
+ return /* @__PURE__ */ jsx43("div", { className: cn("mt-auto flex flex-col gap-[var(--gap-sm,0.5rem)] p-[var(--space-4,1rem)]", className), ...props });
2713
2770
  }
2714
2771
  var DrawerTitle = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx43(
2715
2772
  DrawerPrimitive.Title,
@@ -2759,7 +2816,7 @@ function ResizableHandle({ withHandle, className, ...props }) {
2759
2816
  ResizablePrimitiveSeparator,
2760
2817
  {
2761
2818
  className: cn(
2762
- "relative flex w-px items-center justify-center bg-border transition-all duration-200 ease-out hover:bg-ring data-[separator=active]:bg-ring",
2819
+ "relative flex w-px items-center justify-center bg-border transition-all duration-[var(--duration-normal,200ms)] ease-out hover:bg-ring data-[separator=active]:bg-ring",
2763
2820
  "after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2",
2764
2821
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
2765
2822
  "aria-[orientation=horizontal]:h-px aria-[orientation=horizontal]:w-full",
@@ -2837,7 +2894,7 @@ SidebarProvider.displayName = "SidebarProvider";
2837
2894
  var sidebarVariants = cva8(
2838
2895
  cn(
2839
2896
  "flex h-full shrink-0 flex-col border-r bg-background text-foreground",
2840
- "transition-[width] duration-200 ease-out"
2897
+ "transition-[width] duration-[var(--duration-normal,200ms)] ease-out"
2841
2898
  ),
2842
2899
  {
2843
2900
  variants: {
@@ -2893,8 +2950,8 @@ var SidebarTrigger = React39.forwardRef(
2893
2950
  }
2894
2951
  },
2895
2952
  className: cn(
2896
- "inline-flex h-9 w-9 items-center justify-center rounded-md text-muted-foreground",
2897
- "transition-all duration-200 ease-out hover:bg-accent hover:text-accent-foreground",
2953
+ "inline-flex h-[var(--control-height-sm,2.25rem)] w-[var(--control-height-sm,2.25rem)] items-center justify-center rounded-md text-muted-foreground",
2954
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out hover:bg-accent hover:text-accent-foreground",
2898
2955
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
2899
2956
  className
2900
2957
  ),
@@ -2930,7 +2987,7 @@ var SidebarHeader = React39.forwardRef(
2930
2987
  "div",
2931
2988
  {
2932
2989
  ref,
2933
- className: cn("flex items-center gap-2 border-b p-4", className),
2990
+ className: cn("flex items-center gap-[var(--gap-sm,0.5rem)] border-b p-[var(--space-4,1rem)]", className),
2934
2991
  ...props
2935
2992
  }
2936
2993
  )
@@ -2941,7 +2998,7 @@ var SidebarContent = React39.forwardRef(
2941
2998
  "div",
2942
2999
  {
2943
3000
  ref,
2944
- className: cn("flex-1 overflow-auto p-2", className),
3001
+ className: cn("flex-1 overflow-auto p-[var(--space-2,0.5rem)]", className),
2945
3002
  ...props
2946
3003
  }
2947
3004
  )
@@ -2952,7 +3009,7 @@ var SidebarFooter = React39.forwardRef(
2952
3009
  "div",
2953
3010
  {
2954
3011
  ref,
2955
- className: cn("mt-auto border-t p-4", className),
3012
+ className: cn("mt-auto border-t p-[var(--space-4,1rem)]", className),
2956
3013
  ...props
2957
3014
  }
2958
3015
  )
@@ -2969,8 +3026,8 @@ var SidebarItem = React39.forwardRef(
2969
3026
  "aria-current": active ? "page" : void 0,
2970
3027
  "data-active": active ? "" : void 0,
2971
3028
  className: cn(
2972
- "inline-flex w-full items-center gap-2 rounded-md px-3 py-2 text-sm font-medium",
2973
- "transition-all duration-200 ease-out",
3029
+ "inline-flex w-full items-center gap-[var(--gap-sm,0.5rem)] rounded-md px-[var(--space-3,0.75rem)] py-[var(--space-2,0.5rem)] text-sm font-medium",
3030
+ "transition-all duration-[var(--duration-normal,200ms)] ease-out",
2974
3031
  "hover:bg-accent hover:text-accent-foreground",
2975
3032
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
2976
3033
  "data-[active]:bg-accent data-[active]:text-accent-foreground",
@@ -3690,7 +3747,7 @@ var dialogSchema = {
3690
3747
  "Putting too many primary actions in DialogFooter"
3691
3748
  ],
3692
3749
  relatedComponents: ["alert-dialog", "popover", "sheet"],
3693
- accessibilityNotes: "Radix traps focus, handles Escape to close, and wires aria-labelledby/describedby to DialogTitle/DialogDescription. Always include a DialogTitle.",
3750
+ accessibilityNotes: "Radix traps focus, handles Escape to close, and wires aria-labelledby/describedby to DialogTitle/DialogDescription. Always include a DialogTitle. DialogContent is constrained to `max-h-[calc(100vh-2rem)]` and scrolls internally so long content stays inside the focus trap.",
3694
3751
  tokenBudget: 600
3695
3752
  },
3696
3753
  tags: ["dialog", "modal", "overlay", "popup", "form"]
@@ -4208,6 +4265,24 @@ var sliderSchema = {
4208
4265
  default: "horizontal",
4209
4266
  description: "Slider direction",
4210
4267
  enumValues: ["horizontal", "vertical"]
4268
+ },
4269
+ {
4270
+ name: "aria-label",
4271
+ type: "string",
4272
+ required: false,
4273
+ description: "Accessible label for the slider as a whole. Mirrored onto a single thumb automatically; for range sliders prefer thumbLabels."
4274
+ },
4275
+ {
4276
+ name: "aria-labelledby",
4277
+ type: "string",
4278
+ required: false,
4279
+ description: "Id of an external visible label that names the slider."
4280
+ },
4281
+ {
4282
+ name: "thumbLabels",
4283
+ type: "object",
4284
+ required: false,
4285
+ description: "Per-thumb accessible labels (string[]). Required for range sliders so each thumb has a meaningful name (e.g. ['Minimum price', 'Maximum price']). For a single-thumb slider, the Root's aria-label is mirrored onto the thumb automatically and thumbLabels is only needed when overriding that default."
4211
4286
  }
4212
4287
  ],
4213
4288
  variants: [],
@@ -4237,10 +4312,12 @@ var sliderSchema = {
4237
4312
  "Using Slider for exact values without showing the number",
4238
4313
  "Missing min/max bounds",
4239
4314
  "Using step=1 for fractional values (set step=0.01)",
4240
- "Not providing aria-label when there's no visible label"
4315
+ "Not providing aria-label / aria-labelledby when there's no visible label",
4316
+ "Range slider with only Root aria-label and no thumbLabels \u2014 both thumbs fall back to '(N of 2)' indexed names instead of meaningful per-thumb labels",
4317
+ "thumbLabels.length !== value.length \u2014 extra labels are ignored, missing labels fall back to indexed names (dev-mode warning)"
4241
4318
  ],
4242
4319
  relatedComponents: ["input"],
4243
- accessibilityNotes: "Arrow keys step by step, Home/End jump to min/max, PageUp/PageDown step larger. Radix handles aria-valuemin/max/now. Add aria-label if no visible label.",
4320
+ accessibilityNotes: "Arrow keys step by step, Home/End jump to min/max, PageUp/PageDown step larger. Radix handles aria-valuemin/max/now. Each thumb has its own accessible name: explicit via thumbLabels[i], else mirrored from the Root's aria-label (single thumb) or indexed '(i of N)' fallback (range). Add aria-label / aria-labelledby on the Root when there's no visible label.",
4244
4321
  tokenBudget: 450
4245
4322
  },
4246
4323
  tags: ["slider", "range", "form", "numeric", "input"]
@@ -4667,7 +4744,14 @@ var scrollAreaSchema = {
4667
4744
  description: "When scrollbars are visible",
4668
4745
  enumValues: ["auto", "always", "scroll", "hover"]
4669
4746
  },
4670
- { name: "className", type: "string", required: false, description: "Set dimensions via Tailwind (e.g. h-72 w-48)" }
4747
+ { name: "className", type: "string", required: false, description: "Set dimensions via Tailwind (e.g. h-72 w-48)" },
4748
+ {
4749
+ name: "viewportTabIndex",
4750
+ type: "number",
4751
+ required: false,
4752
+ default: 0,
4753
+ description: "tabIndex applied to the scroll viewport. Defaults to 0 so keyboard users can scroll without a pointer; pass -1 to skip the viewport in the tab order when wrapping decorative or already-keyboard-reachable content."
4754
+ }
4671
4755
  ],
4672
4756
  variants: [],
4673
4757
  slots: [
@@ -4697,10 +4781,11 @@ var scrollAreaSchema = {
4697
4781
  commonMistakes: [
4698
4782
  "Forgetting to set height/width \u2014 scrollbars don't appear",
4699
4783
  "Using for the whole page",
4700
- "Nesting ScrollAreas (confusing UX)"
4784
+ "Nesting ScrollAreas (confusing UX)",
4785
+ "Wrapping decorative or already-keyboard-reachable content without setting viewportTabIndex={-1} \u2014 adds an unnecessary tab stop"
4701
4786
  ],
4702
4787
  relatedComponents: [],
4703
- accessibilityNotes: "Radix doesn't make the viewport focusable by default \u2014 add tabIndex={0} on a focusable child or the viewport to enable keyboard scrolling (arrow keys, PgUp/PgDn, Home/End). For long lists, consider pagination or virtualization.",
4788
+ accessibilityNotes: "The viewport is keyboard-focusable by default (viewportTabIndex=0) so users can scroll long content via arrow keys / PgUp / PgDn / Home / End without a pointer. Pass viewportTabIndex={-1} when the contents are already in the tab order or purely decorative. For very long lists, consider pagination or virtualization.",
4704
4789
  tokenBudget: 350
4705
4790
  },
4706
4791
  tags: ["scroll-area", "scroll", "overflow", "scrollbar", "layout"]
@@ -5234,7 +5319,19 @@ var dataTableSchema = {
5234
5319
  subcategory: "data",
5235
5320
  props: [
5236
5321
  { name: "columns", type: "object", required: true, description: "ColumnDef<TData, TValue>[] from @tanstack/react-table" },
5237
- { name: "data", type: "object", required: true, description: "Array of row data" }
5322
+ { name: "data", type: "object", required: true, description: "Array of row data" },
5323
+ {
5324
+ name: "caption",
5325
+ type: "ReactNode",
5326
+ required: false,
5327
+ description: "Visible caption rendered below the table; announced by screen readers when entering the table"
5328
+ },
5329
+ {
5330
+ name: "aria-label",
5331
+ type: "string",
5332
+ required: false,
5333
+ description: "Accessible label forwarded as aria-label on the underlying <table>; use when no visible caption is shown"
5334
+ }
5238
5335
  ],
5239
5336
  variants: [],
5240
5337
  slots: [],
@@ -5258,10 +5355,11 @@ var dataTableSchema = {
5258
5355
  "Forgetting getCoreRowModel() (table renders nothing)",
5259
5356
  "Recreating columns array on every render (breaks memoization \u2014 wrap in useMemo or define outside the component)",
5260
5357
  "Using accessorKey with nested paths without accessorFn",
5261
- "Not adding filter/sort row models when those features are needed"
5358
+ "Not adding filter/sort row models when those features are needed",
5359
+ "Shipping a table without `caption` or `aria-label` \u2014 the table is unlabelled to assistive tech"
5262
5360
  ],
5263
5361
  relatedComponents: ["table", "pagination"],
5264
- accessibilityNotes: "Uses semantic <table> via Hex UI Table primitives. Add aria-sort to sortable column headers. Announce filter/sort changes via aria-live for dynamic updates.",
5362
+ accessibilityNotes: "Pass either `caption` (visible) or `aria-label` so screen readers announce the table when the user enters it. Add aria-sort to sortable column headers. Announce filter/sort changes via aria-live for dynamic updates.",
5265
5363
  tokenBudget: 900
5266
5364
  },
5267
5365
  tags: ["data-table", "tanstack", "sortable", "filterable", "paginated"]
@@ -5675,10 +5773,11 @@ var commandSchema = {
5675
5773
  "Forgetting CommandList \u2014 items won't be scrollable or grouped properly",
5676
5774
  "Giving CommandItem non-unique values (breaks filtering and controlled state)",
5677
5775
  "Overriding CommandInput className to remove the border/padding \u2014 breaks the \u2318K icon layout",
5678
- "Not rendering CommandEmpty \u2014 the list looks broken when a search has no matches"
5776
+ "Not rendering CommandEmpty \u2014 the list looks broken when a search has no matches",
5777
+ "Querying CommandSeparator via cmdk's internal Separator state \u2014 Hex UI renders it as a presentational div with role='none' (and the `data-cmdk-separator` attribute preserved for selector compatibility) so it can sit inside CommandList's role=listbox without violating ARIA"
5679
5778
  ],
5680
5779
  relatedComponents: ["combobox", "dialog", "dropdown-menu"],
5681
- accessibilityNotes: "cmdk wires role=listbox/option and aria-activedescendant. Use the `label` prop on Command for a screen-reader-only name when no visible heading exists.",
5780
+ accessibilityNotes: "cmdk wires role=listbox/option and aria-activedescendant. Use the `label` prop on Command for a screen-reader-only name when no visible heading exists. CommandSeparator renders with role='none' (still selectable via `[data-cmdk-separator]`) so listbox-children rules are satisfied.",
5682
5781
  tokenBudget: 900
5683
5782
  },
5684
5783
  tags: ["command", "cmdk", "palette", "search", "launcher"]
@@ -5742,7 +5841,13 @@ var comboboxSchema = {
5742
5841
  name: "aria-label",
5743
5842
  type: "string",
5744
5843
  required: false,
5745
- description: "Accessible label \u2014 required when no adjacent visible <label> is used"
5844
+ description: "Accessible label \u2014 required when no adjacent visible label is used"
5845
+ },
5846
+ {
5847
+ name: "aria-labelledby",
5848
+ type: "string",
5849
+ required: false,
5850
+ description: "Id of an external visible label that names the combobox"
5746
5851
  }
5747
5852
  ],
5748
5853
  variants: [],
@@ -5773,10 +5878,10 @@ var comboboxSchema = {
5773
5878
  "Using the label as the value \u2014 fine if stable, but prefer a short stable `value` string",
5774
5879
  "Forgetting to bind value + onChange \u2014 uncontrolled mode doesn't exist on this wrapper",
5775
5880
  "Mixing translated labels without keying on value \u2014 label changes won't update selection",
5776
- "Missing aria-label when there's no adjacent visible <label>"
5881
+ "Missing aria-label / aria-labelledby \u2014 role='combobox' does not allow name from contents, so without one of these the trigger has no accessible name"
5777
5882
  ],
5778
5883
  relatedComponents: ["command", "popover", "select"],
5779
- accessibilityNotes: "Trigger has role='combobox' + aria-expanded. Popover traps focus inside the CommandInput. Options are announced via cmdk's aria-activedescendant wiring.",
5884
+ accessibilityNotes: "Trigger has role='combobox' + aria-expanded + aria-haspopup='listbox'. aria-controls points at the inner CommandList (a useId-stabilized listbox). Pass aria-label or aria-labelledby \u2014 combobox does not derive its name from contents.",
5780
5885
  tokenBudget: 900
5781
5886
  },
5782
5887
  tags: ["combobox", "select", "search", "cmdk", "input"]