@ship-it-ui/ui 0.0.4 → 0.0.6

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.cjs CHANGED
@@ -95,6 +95,7 @@ __export(index_exports, {
95
95
  IconButton: () => IconButton,
96
96
  Input: () => Input,
97
97
  Kbd: () => Kbd,
98
+ LargeTitle: () => LargeTitle,
98
99
  MenuCheckboxItem: () => MenuCheckboxItem,
99
100
  MenuItem: () => MenuItem,
100
101
  MenuSeparator: () => MenuSeparator,
@@ -119,6 +120,7 @@ __export(index_exports, {
119
120
  PopoverRoot: () => PopoverRoot,
120
121
  PopoverTrigger: () => PopoverTrigger,
121
122
  Progress: () => Progress,
123
+ PullToRefresh: () => PullToRefresh,
122
124
  RadialProgress: () => RadialProgress,
123
125
  Radio: () => Radio,
124
126
  RadioGroup: () => RadioGroup,
@@ -134,6 +136,7 @@ __export(index_exports, {
134
136
  SelectValue: () => SelectValue,
135
137
  Sheet: () => Sheet,
136
138
  Sidebar: () => Sidebar,
139
+ SimpleTooltip: () => SimpleTooltip,
137
140
  Skeleton: () => Skeleton,
138
141
  SkeletonGroup: () => SkeletonGroup,
139
142
  Slider: () => Slider,
@@ -145,6 +148,7 @@ __export(index_exports, {
145
148
  Stepper: () => Stepper,
146
149
  Switch: () => Switch,
147
150
  Tab: () => Tab,
151
+ TabBar: () => TabBar,
148
152
  Tabs: () => Tabs,
149
153
  TabsContent: () => TabsContent,
150
154
  TabsList: () => TabsList,
@@ -159,7 +163,6 @@ __export(index_exports, {
159
163
  TooltipContent: () => TooltipContent,
160
164
  TooltipPortal: () => TooltipPortal,
161
165
  TooltipProvider: () => TooltipProvider,
162
- TooltipRoot: () => TooltipRoot,
163
166
  TooltipTrigger: () => TooltipTrigger,
164
167
  Topbar: () => Topbar,
165
168
  Tree: () => Tree,
@@ -383,14 +386,29 @@ var buttonStyles = (0, import_class_variance_authority.cva)(
383
386
  md: "h-[32px] px-3 text-[12px] gap-[6px] rounded-md",
384
387
  lg: "h-[38px] px-4 text-[13px] gap-[7px] rounded-[7px]"
385
388
  },
389
+ density: {
390
+ comfortable: "",
391
+ touch: ""
392
+ },
386
393
  fullWidth: {
387
394
  true: "w-full",
388
395
  false: ""
389
396
  }
390
397
  },
398
+ compoundVariants: [
399
+ // Mobile density — bumps every size to meet 44pt minimum touch target.
400
+ {
401
+ size: "sm",
402
+ density: "touch",
403
+ class: "h-[36px] px-[14px] text-[13px] gap-[7px] rounded-base"
404
+ },
405
+ { size: "md", density: "touch", class: "h-touch px-[18px] text-m-body gap-2 rounded-base" },
406
+ { size: "lg", density: "touch", class: "h-[52px] px-[22px] text-[16px] gap-2 rounded-base" }
407
+ ],
391
408
  defaultVariants: {
392
409
  variant: "primary",
393
410
  size: "md",
411
+ density: "comfortable",
394
412
  fullWidth: false
395
413
  }
396
414
  }
@@ -405,10 +423,14 @@ function Spinner({ size }) {
405
423
  }
406
424
  );
407
425
  }
408
- var iconSize = { sm: 11, md: 12, lg: 13 };
426
+ var iconSize = {
427
+ comfortable: { sm: 11, md: 12, lg: 13 },
428
+ touch: { sm: 13, md: 15, lg: 16 }
429
+ };
409
430
  var Button = (0, import_react8.forwardRef)(function Button2({
410
431
  variant,
411
432
  size,
433
+ density,
412
434
  fullWidth,
413
435
  icon,
414
436
  trailing,
@@ -421,8 +443,8 @@ var Button = (0, import_react8.forwardRef)(function Button2({
421
443
  ...props
422
444
  }, ref) {
423
445
  const isDisabled = disabled || loading;
424
- const iconPx = iconSize[size ?? "md"];
425
- const composedClassName = cn(buttonStyles({ variant, size, fullWidth }), className);
446
+ const iconPx = iconSize[density ?? "comfortable"][size ?? "md"];
447
+ const composedClassName = cn(buttonStyles({ variant, size, density, fullWidth }), className);
426
448
  if (asChild) {
427
449
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
428
450
  import_react_slot.Slot,
@@ -483,18 +505,28 @@ var iconButtonStyles = (0, import_class_variance_authority2.cva)(
483
505
  sm: "h-[26px] w-[26px] text-[12px] rounded-[5px]",
484
506
  md: "h-[32px] w-[32px] text-[13px] rounded-md",
485
507
  lg: "h-[38px] w-[38px] text-[15px] rounded-[7px]"
508
+ },
509
+ density: {
510
+ comfortable: "",
511
+ touch: ""
486
512
  }
487
513
  },
488
- defaultVariants: { variant: "secondary", size: "md" }
514
+ compoundVariants: [
515
+ // Mobile density — 44pt minimum touch target, circular tap.
516
+ { size: "sm", density: "touch", class: "h-[36px] w-[36px] text-[14px] rounded-full" },
517
+ { size: "md", density: "touch", class: "h-touch w-touch text-[16px] rounded-full" },
518
+ { size: "lg", density: "touch", class: "h-[52px] w-[52px] text-[18px] rounded-full" }
519
+ ],
520
+ defaultVariants: { variant: "secondary", size: "md", density: "comfortable" }
489
521
  }
490
522
  );
491
- var IconButton = (0, import_react9.forwardRef)(function IconButton2({ variant, size, icon, type, className, ...props }, ref) {
523
+ var IconButton = (0, import_react9.forwardRef)(function IconButton2({ variant, size, density, icon, type, className, ...props }, ref) {
492
524
  return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
493
525
  "button",
494
526
  {
495
527
  ref,
496
528
  type: type ?? "button",
497
- className: cn(iconButtonStyles({ variant, size }), className),
529
+ className: cn(iconButtonStyles({ variant, size, density }), className),
498
530
  ...props,
499
531
  children: icon
500
532
  }
@@ -609,14 +641,16 @@ FAB.displayName = "FAB";
609
641
  var RadixCheckbox = __toESM(require("@radix-ui/react-checkbox"), 1);
610
642
  var import_react13 = require("react");
611
643
  var import_jsx_runtime6 = require("react/jsx-runtime");
612
- var Checkbox = (0, import_react13.forwardRef)(function Checkbox2({ label, className, id: idProp, ...props }, ref) {
644
+ var Checkbox = (0, import_react13.forwardRef)(function Checkbox2({ label, density = "comfortable", className, id: idProp, ...props }, ref) {
613
645
  const reactId = (0, import_react13.useId)();
614
646
  const id = idProp ?? `cb-${reactId}`;
647
+ const isTouch = density === "touch";
615
648
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
616
649
  "span",
617
650
  {
618
651
  className: cn(
619
- "inline-flex items-center gap-2 select-none",
652
+ "inline-flex items-center select-none",
653
+ isTouch ? "min-h-touch gap-3" : "gap-2",
620
654
  props.disabled && "cursor-not-allowed opacity-40",
621
655
  className
622
656
  ),
@@ -627,18 +661,32 @@ var Checkbox = (0, import_react13.forwardRef)(function Checkbox2({ label, classN
627
661
  ref,
628
662
  id,
629
663
  className: cn(
630
- "grid h-4 w-4 place-items-center rounded-xs",
631
- "bg-panel border-border-strong border",
664
+ "grid place-items-center",
665
+ isTouch ? "h-[22px] w-[22px] rounded-sm border-[1.5px]" : "h-4 w-4 rounded-xs border",
666
+ "bg-panel border-border-strong",
632
667
  "data-[state=checked]:bg-accent data-[state=checked]:border-accent",
633
668
  "data-[state=indeterminate]:bg-accent data-[state=indeterminate]:border-accent",
634
669
  "transition-[background,border-color] duration-(--duration-micro)",
635
670
  "focus-visible:ring-accent-dim outline-none focus-visible:ring-[3px]"
636
671
  ),
637
672
  ...props,
638
- children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RadixCheckbox.Indicator, { className: "text-on-accent text-[11px] leading-none", children: props.checked === "indeterminate" ? "\u2212" : "\u2713" })
673
+ children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
674
+ RadixCheckbox.Indicator,
675
+ {
676
+ className: cn("text-on-accent leading-none", isTouch ? "text-[14px]" : "text-[11px]"),
677
+ children: props.checked === "indeterminate" ? "\u2212" : "\u2713"
678
+ }
679
+ )
639
680
  }
640
681
  ),
641
- label && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("label", { htmlFor: id, className: "cursor-pointer text-[13px]", children: label })
682
+ label && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
683
+ "label",
684
+ {
685
+ htmlFor: id,
686
+ className: cn("cursor-pointer", isTouch ? "text-m-body" : "text-[13px]"),
687
+ children: label
688
+ }
689
+ )
642
690
  ]
643
691
  }
644
692
  );
@@ -689,17 +737,28 @@ var inputWrapperStyles = (0, import_class_variance_authority3.cva)(
689
737
  tone: {
690
738
  default: "bg-panel border-border focus-within:border-accent focus-within:ring-accent-dim",
691
739
  err: "bg-panel border-err focus-within:border-err focus-within:ring-err/30"
740
+ },
741
+ density: {
742
+ comfortable: "",
743
+ touch: ""
692
744
  }
693
745
  },
694
- defaultVariants: { size: "md", tone: "default" }
746
+ compoundVariants: [
747
+ // Mobile density — 52px standard input height (MInput in the canvas);
748
+ // sm collapses to 44pt min, lg pushes to 56pt for prominent forms.
749
+ { size: "sm", density: "touch", class: "h-touch px-3 text-m-body rounded-m-tab" },
750
+ { size: "md", density: "touch", class: "h-[52px] px-[14px] text-m-body rounded-m-tab" },
751
+ { size: "lg", density: "touch", class: "h-row px-4 text-m-body-lg rounded-m-tab" }
752
+ ],
753
+ defaultVariants: { size: "md", tone: "default", density: "comfortable" }
695
754
  }
696
755
  );
697
- var Input = (0, import_react15.forwardRef)(function Input2({ size, tone, icon, trailing, error, width, className, style, disabled, ...props }, ref) {
756
+ var Input = (0, import_react15.forwardRef)(function Input2({ size, tone, density, icon, trailing, error, width, className, style, disabled, ...props }, ref) {
698
757
  const computedTone = error ? "err" : tone;
699
758
  return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
700
759
  "div",
701
760
  {
702
- className: cn(inputWrapperStyles({ size, tone: computedTone }), className),
761
+ className: cn(inputWrapperStyles({ size, tone: computedTone, density }), className),
703
762
  style: { width, ...style },
704
763
  children: [
705
764
  icon && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "text-text-dim leading-none", children: icon }),
@@ -728,27 +787,32 @@ Input.displayName = "Input";
728
787
  var import_react16 = require("react");
729
788
  var import_jsx_runtime9 = require("react/jsx-runtime");
730
789
  var SearchInput = (0, import_react16.forwardRef)(function SearchInput2({
731
- shortcut = "\u2318K",
732
- width = 360,
790
+ shortcut,
791
+ width,
792
+ density = "comfortable",
733
793
  className,
734
794
  style,
735
795
  placeholder = "Search\u2026",
736
796
  "aria-label": ariaLabel,
737
797
  ...props
738
798
  }, ref) {
799
+ const isTouch = density === "touch";
800
+ const resolvedWidth = width ?? (isTouch ? "100%" : 360);
801
+ const resolvedShortcut = shortcut ?? (isTouch ? void 0 : "\u2318K");
739
802
  return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
740
803
  "div",
741
804
  {
742
805
  className: cn(
743
- "rounded-base flex h-9 items-center gap-2 px-3 font-sans",
806
+ "flex items-center gap-2 font-sans",
807
+ isTouch ? "h-touch rounded-m-tab px-[14px]" : "rounded-base h-9 px-3",
744
808
  "bg-panel-2 border-border border",
745
809
  "focus-within:border-accent focus-within:ring-accent-dim focus-within:ring-[3px]",
746
810
  "transition-[border-color,box-shadow] duration-(--duration-micro)",
747
811
  className
748
812
  ),
749
- style: { width, ...style },
813
+ style: { width: resolvedWidth, ...style },
750
814
  children: [
751
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("span", { className: "text-text-dim leading-none", "aria-hidden": true, children: "\u2315" }),
815
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("span", { className: cn("text-text-dim leading-none", isTouch && "text-[18px]"), "aria-hidden": true, children: "\u2315" }),
752
816
  /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
753
817
  "input",
754
818
  {
@@ -756,11 +820,14 @@ var SearchInput = (0, import_react16.forwardRef)(function SearchInput2({
756
820
  type: "search",
757
821
  placeholder,
758
822
  "aria-label": ariaLabel ?? (typeof placeholder === "string" ? placeholder : "Search"),
759
- className: "text-text placeholder:text-text-dim min-w-0 flex-1 border-none bg-transparent text-[13px] outline-none",
823
+ className: cn(
824
+ "text-text placeholder:text-text-dim min-w-0 flex-1 border-none bg-transparent outline-none",
825
+ isTouch ? "text-m-body" : "text-[13px]"
826
+ ),
760
827
  ...props
761
828
  }
762
829
  ),
763
- shortcut && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("kbd", { className: "text-text-dim border-border rounded-xs border px-[6px] py-[2px] font-mono text-[10px]", children: shortcut })
830
+ resolvedShortcut && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("kbd", { className: "text-text-dim border-border rounded-xs border px-[6px] py-[2px] font-mono text-[10px]", children: resolvedShortcut })
764
831
  ]
765
832
  }
766
833
  );
@@ -1088,14 +1155,26 @@ var RadixSwitch = __toESM(require("@radix-ui/react-switch"), 1);
1088
1155
  var import_react21 = require("react");
1089
1156
  var import_jsx_runtime14 = require("react/jsx-runtime");
1090
1157
  var trackClasses = {
1091
- sm: "h-4 w-7",
1092
- md: "h-5 w-9"
1158
+ comfortable: {
1159
+ sm: "h-4 w-7",
1160
+ md: "h-5 w-9"
1161
+ },
1162
+ touch: {
1163
+ sm: "h-[26px] w-[44px]",
1164
+ md: "h-[30px] w-[50px]"
1165
+ }
1093
1166
  };
1094
1167
  var thumbClasses = {
1095
- sm: "h-3 w-3 data-[state=checked]:translate-x-3",
1096
- md: "h-4 w-4 data-[state=checked]:translate-x-4"
1168
+ comfortable: {
1169
+ sm: "h-3 w-3 data-[state=checked]:translate-x-3",
1170
+ md: "h-4 w-4 data-[state=checked]:translate-x-4"
1171
+ },
1172
+ touch: {
1173
+ sm: "h-[22px] w-[22px] data-[state=checked]:translate-x-[18px]",
1174
+ md: "h-[26px] w-[26px] data-[state=checked]:translate-x-5"
1175
+ }
1097
1176
  };
1098
- var Switch = (0, import_react21.forwardRef)(function Switch2({ label, size = "md", className, id: idProp, ...props }, ref) {
1177
+ var Switch = (0, import_react21.forwardRef)(function Switch2({ label, size = "md", density = "comfortable", className, id: idProp, ...props }, ref) {
1099
1178
  const reactId = (0, import_react21.useId)();
1100
1179
  const id = idProp ?? `sw-${reactId}`;
1101
1180
  return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
@@ -1117,7 +1196,7 @@ var Switch = (0, import_react21.forwardRef)(function Switch2({ label, size = "md
1117
1196
  "bg-panel-2 border-border data-[state=checked]:bg-accent data-[state=checked]:border-accent",
1118
1197
  "focus-visible:ring-accent-dim outline-none focus-visible:ring-[3px]",
1119
1198
  "disabled:cursor-not-allowed",
1120
- trackClasses[size]
1199
+ trackClasses[density][size]
1121
1200
  ),
1122
1201
  ...props,
1123
1202
  children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
@@ -1126,13 +1205,20 @@ var Switch = (0, import_react21.forwardRef)(function Switch2({ label, size = "md
1126
1205
  className: cn(
1127
1206
  "bg-text absolute top-1/2 left-[1px] -translate-y-1/2 rounded-full shadow-sm",
1128
1207
  "data-[state=checked]:bg-on-accent transition-transform duration-(--duration-micro)",
1129
- thumbClasses[size]
1208
+ thumbClasses[density][size]
1130
1209
  )
1131
1210
  }
1132
1211
  )
1133
1212
  }
1134
1213
  ),
1135
- label && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("label", { htmlFor: id, className: "cursor-pointer text-[13px]", children: label })
1214
+ label && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
1215
+ "label",
1216
+ {
1217
+ htmlFor: id,
1218
+ className: cn("cursor-pointer", density === "touch" ? "text-m-body" : "text-[13px]"),
1219
+ children: label
1220
+ }
1221
+ )
1136
1222
  ]
1137
1223
  }
1138
1224
  );
@@ -1400,7 +1486,7 @@ var import_class_variance_authority6 = require("class-variance-authority");
1400
1486
  var import_react27 = require("react");
1401
1487
  var import_jsx_runtime20 = require("react/jsx-runtime");
1402
1488
  var cardStyles = (0, import_class_variance_authority6.cva)(
1403
- "block bg-panel border border-border rounded-base transition-[border-color,transform,box-shadow] duration-(--duration-step)",
1489
+ "block bg-panel border border-border transition-[border-color,transform,box-shadow] duration-(--duration-step)",
1404
1490
  {
1405
1491
  variants: {
1406
1492
  variant: {
@@ -1411,14 +1497,19 @@ var cardStyles = (0, import_class_variance_authority6.cva)(
1411
1497
  interactive: {
1412
1498
  true: "cursor-pointer hover:border-border-strong hover:-translate-y-px hover:shadow",
1413
1499
  false: ""
1500
+ },
1501
+ density: {
1502
+ comfortable: "rounded-base",
1503
+ touch: "rounded-m-card"
1414
1504
  }
1415
1505
  },
1416
- defaultVariants: { variant: "default", interactive: false }
1506
+ defaultVariants: { variant: "default", interactive: false, density: "comfortable" }
1417
1507
  }
1418
1508
  );
1419
1509
  var Card = (0, import_react27.forwardRef)(function Card2({
1420
1510
  variant,
1421
1511
  interactive,
1512
+ density,
1422
1513
  title,
1423
1514
  description,
1424
1515
  actions,
@@ -1455,7 +1546,11 @@ var Card = (0, import_react27.forwardRef)(function Card2({
1455
1546
  onKeyDown: handleKeyDown,
1456
1547
  role: isInteractive ? "button" : void 0,
1457
1548
  tabIndex: isInteractive ? 0 : void 0,
1458
- className: cn(cardStyles({ variant, interactive: wantsInteractive }), "p-[18px]", className),
1549
+ className: cn(
1550
+ cardStyles({ variant, interactive: wantsInteractive, density }),
1551
+ density === "touch" ? "p-4" : "p-[18px]",
1552
+ className
1553
+ ),
1459
1554
  ...props,
1460
1555
  children: [
1461
1556
  (title || actions) && /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: cn("flex items-start gap-3", (description || children) && "mb-[10px]"), children: [
@@ -1470,15 +1565,16 @@ var Card = (0, import_react27.forwardRef)(function Card2({
1470
1565
  );
1471
1566
  });
1472
1567
  Card.displayName = "Card";
1473
- var CardLink = (0, import_react27.forwardRef)(function CardLink2({ variant, title, description, footer, className, children, href, ...props }, ref) {
1568
+ var CardLink = (0, import_react27.forwardRef)(function CardLink2({ variant, density, title, description, footer, className, children, href, ...props }, ref) {
1474
1569
  return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(
1475
1570
  "a",
1476
1571
  {
1477
1572
  ref,
1478
1573
  href,
1479
1574
  className: cn(
1480
- cardStyles({ variant, interactive: true }),
1481
- "focus-visible:ring-accent-dim p-[18px] no-underline outline-none focus-visible:ring-[3px]",
1575
+ cardStyles({ variant, interactive: true, density }),
1576
+ "focus-visible:ring-accent-dim no-underline outline-none focus-visible:ring-[3px]",
1577
+ density === "touch" ? "p-4" : "p-[18px]",
1482
1578
  className
1483
1579
  ),
1484
1580
  ...props,
@@ -1529,19 +1625,21 @@ StatCard.displayName = "StatCard";
1529
1625
  // src/components/Chip/Chip.tsx
1530
1626
  var import_react29 = require("react");
1531
1627
  var import_jsx_runtime22 = require("react/jsx-runtime");
1532
- var Chip = (0, import_react29.forwardRef)(function Chip2({ icon, onRemove, className, children, ...props }, ref) {
1628
+ var Chip = (0, import_react29.forwardRef)(function Chip2({ icon, onRemove, density = "comfortable", className, children, ...props }, ref) {
1629
+ const isTouch = density === "touch";
1533
1630
  return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
1534
1631
  "span",
1535
1632
  {
1536
1633
  ref,
1537
1634
  className: cn(
1538
- "inline-flex h-[26px] items-center gap-[6px] py-[4px] pr-1 pl-[10px] font-sans text-[12px]",
1635
+ "inline-flex items-center gap-[6px] font-sans",
1636
+ isTouch ? "text-m-mono h-8 py-[5px] pr-[6px] pl-3" : "h-[26px] py-[4px] pr-1 pl-[10px] text-[12px]",
1539
1637
  "bg-panel-2 text-text border-border rounded-full border",
1540
1638
  className
1541
1639
  ),
1542
1640
  ...props,
1543
1641
  children: [
1544
- icon && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "text-text-dim inline-flex text-[10px]", children: icon }),
1642
+ icon && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: cn("text-text-dim inline-flex", isTouch ? "text-[12px]" : "text-[10px]"), children: icon }),
1545
1643
  children,
1546
1644
  onRemove && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
1547
1645
  "button",
@@ -1549,7 +1647,10 @@ var Chip = (0, import_react29.forwardRef)(function Chip2({ icon, onRemove, class
1549
1647
  type: "button",
1550
1648
  onClick: onRemove,
1551
1649
  "aria-label": "Remove",
1552
- className: "bg-panel text-text-dim hover:text-text grid h-[18px] w-[18px] place-items-center rounded-full text-[10px] leading-none",
1650
+ className: cn(
1651
+ "bg-panel text-text-dim hover:text-text grid place-items-center rounded-full leading-none",
1652
+ isTouch ? "h-[22px] w-[22px] text-[12px]" : "h-[18px] w-[18px] text-[10px]"
1653
+ ),
1553
1654
  children: "\xD7"
1554
1655
  }
1555
1656
  )
@@ -1852,8 +1953,9 @@ var RadixDialog2 = __toESM(require("@radix-ui/react-dialog"), 1);
1852
1953
  var import_react36 = require("react");
1853
1954
  var import_jsx_runtime29 = require("react/jsx-runtime");
1854
1955
  var sideClasses = {
1855
- left: "left-0 border-r border-border-strong data-[state=open]:animate-[ship-slide-in-left_220ms_var(--easing-out)]",
1856
- right: "right-0 border-l border-border-strong data-[state=open]:animate-[ship-slide-in-right_220ms_var(--easing-out)]"
1956
+ left: "top-0 bottom-0 left-0 border-r border-border-strong data-[state=open]:animate-[ship-slide-in-left_220ms_var(--easing-out)]",
1957
+ right: "top-0 bottom-0 right-0 border-l border-border-strong data-[state=open]:animate-[ship-slide-in-right_220ms_var(--easing-out)]",
1958
+ bottom: "bottom-0 left-0 right-0 border-t border-border-strong rounded-t-m-sheet data-[state=open]:animate-[ship-slide-in-bottom_240ms_var(--easing-out)]"
1857
1959
  };
1858
1960
  var DrawerHeader = ({ title, onClose }) => /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "border-border flex items-center justify-between border-b p-[16px] px-5", children: [
1859
1961
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(RadixDialog2.Title, { className: "text-[14px] font-medium", children: title }),
@@ -1867,7 +1969,12 @@ var DrawerHeader = ({ title, onClose }) => /* @__PURE__ */ (0, import_jsx_runtim
1867
1969
  }
1868
1970
  )
1869
1971
  ] });
1870
- var Drawer = (0, import_react36.forwardRef)(function Drawer2({ side = "right", title, width = 420, children, ...rootProps }, ref) {
1972
+ var SheetHeader = ({ title }) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "px-5 pb-3", children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(RadixDialog2.Title, { className: "text-m-body-lg font-semibold tracking-tight", children: title }) });
1973
+ var DragHandle = () => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "flex justify-center pt-3 pb-2", "aria-hidden": true, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("span", { className: "bg-border-strong h-1 w-9 rounded-full" }) });
1974
+ var Drawer = (0, import_react36.forwardRef)(function Drawer2({ side = "right", title, width = 420, height = "85vh", handle, children, ...rootProps }, ref) {
1975
+ const isBottom = side === "bottom";
1976
+ const showHandle = isBottom && (handle ?? true);
1977
+ const dimensionStyle = isBottom ? { height } : { width };
1871
1978
  return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(DialogRoot, { ...rootProps, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(DialogPortal, { children: [
1872
1979
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(DialogOverlay, {}),
1873
1980
  /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
@@ -1876,13 +1983,14 @@ var Drawer = (0, import_react36.forwardRef)(function Drawer2({ side = "right", t
1876
1983
  ref,
1877
1984
  "aria-describedby": void 0,
1878
1985
  className: cn(
1879
- "bg-panel z-modal fixed top-0 bottom-0 flex flex-col shadow-lg outline-none",
1986
+ "bg-panel z-modal fixed flex flex-col shadow-lg outline-none",
1880
1987
  sideClasses[side]
1881
1988
  ),
1882
- style: { width },
1989
+ style: dimensionStyle,
1883
1990
  children: [
1884
- title ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(DrawerHeader, { title }) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(RadixDialog2.Title, { className: "sr-only", children: "Drawer" }),
1885
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "flex-1 overflow-auto p-5", children })
1991
+ showHandle && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(DragHandle, {}),
1992
+ title ? isBottom ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(SheetHeader, { title }) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(DrawerHeader, { title }) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(RadixDialog2.Title, { className: "sr-only", children: isBottom ? "Sheet" : "Drawer" }),
1993
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: cn("flex-1 overflow-auto", isBottom ? "px-5 pb-6" : "p-5"), children })
1886
1994
  ]
1887
1995
  }
1888
1996
  )
@@ -2209,7 +2317,7 @@ var RadixTooltip = __toESM(require("@radix-ui/react-tooltip"), 1);
2209
2317
  var import_react43 = require("react");
2210
2318
  var import_jsx_runtime36 = require("react/jsx-runtime");
2211
2319
  var TooltipProvider = RadixTooltip.Provider;
2212
- var TooltipRoot = RadixTooltip.Root;
2320
+ var Tooltip = RadixTooltip.Root;
2213
2321
  var TooltipTrigger = RadixTooltip.Trigger;
2214
2322
  var TooltipPortal = RadixTooltip.Portal;
2215
2323
  var TooltipArrow = RadixTooltip.Arrow;
@@ -2232,8 +2340,13 @@ var TooltipContent = (0, import_react43.forwardRef)(
2232
2340
  }
2233
2341
  );
2234
2342
  TooltipContent.displayName = "TooltipContent";
2235
- function Tooltip({ content, children, side = "top", delayDuration = 400 }) {
2236
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TooltipProvider, { delayDuration, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(TooltipRoot, { children: [
2343
+ function SimpleTooltip({
2344
+ content,
2345
+ children,
2346
+ side = "top",
2347
+ delayDuration = 400
2348
+ }) {
2349
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TooltipProvider, { delayDuration, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(Tooltip, { children: [
2237
2350
  /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TooltipTrigger, { asChild: true, children }),
2238
2351
  /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TooltipContent, { side, children: content })
2239
2352
  ] }) });
@@ -3756,12 +3869,34 @@ var HealthScore = (0, import_react58.forwardRef)(function HealthScore2({
3756
3869
  });
3757
3870
  HealthScore.displayName = "HealthScore";
3758
3871
 
3759
- // src/patterns/Menubar/Menubar.tsx
3760
- var RadixMenubar = __toESM(require("@radix-ui/react-menubar"), 1);
3872
+ // src/patterns/LargeTitle/LargeTitle.tsx
3761
3873
  var import_react59 = require("react");
3762
3874
  var import_jsx_runtime52 = require("react/jsx-runtime");
3763
- var Menubar = (0, import_react59.forwardRef)(function Menubar2({ className, ...props }, ref) {
3764
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
3875
+ var LargeTitle = (0, import_react59.forwardRef)(function LargeTitle2({ title, eyebrow, trailing, className, ...props }, ref) {
3876
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
3877
+ "header",
3878
+ {
3879
+ ref,
3880
+ className: cn("px-screen flex items-end justify-between gap-3 py-3 pb-4", className),
3881
+ ...props,
3882
+ children: [
3883
+ /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "min-w-0 flex-1", children: [
3884
+ eyebrow && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "text-m-eyebrow text-accent mb-[6px] font-mono tracking-wide uppercase", children: eyebrow }),
3885
+ /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("h1", { className: "text-m-h1 m-0 truncate leading-tight font-medium tracking-tight", children: title })
3886
+ ] }),
3887
+ trailing && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "shrink-0", children: trailing })
3888
+ ]
3889
+ }
3890
+ );
3891
+ });
3892
+ LargeTitle.displayName = "LargeTitle";
3893
+
3894
+ // src/patterns/Menubar/Menubar.tsx
3895
+ var RadixMenubar = __toESM(require("@radix-ui/react-menubar"), 1);
3896
+ var import_react60 = require("react");
3897
+ var import_jsx_runtime53 = require("react/jsx-runtime");
3898
+ var Menubar = (0, import_react60.forwardRef)(function Menubar2({ className, ...props }, ref) {
3899
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
3765
3900
  RadixMenubar.Root,
3766
3901
  {
3767
3902
  ref,
@@ -3775,9 +3910,9 @@ var Menubar = (0, import_react59.forwardRef)(function Menubar2({ className, ...p
3775
3910
  });
3776
3911
  Menubar.displayName = "Menubar";
3777
3912
  var MenubarMenu = RadixMenubar.Menu;
3778
- var MenubarTrigger = (0, import_react59.forwardRef)(
3913
+ var MenubarTrigger = (0, import_react60.forwardRef)(
3779
3914
  function MenubarTrigger2({ className, ...props }, ref) {
3780
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
3915
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
3781
3916
  RadixMenubar.Trigger,
3782
3917
  {
3783
3918
  ref,
@@ -3794,9 +3929,9 @@ var MenubarTrigger = (0, import_react59.forwardRef)(
3794
3929
  }
3795
3930
  );
3796
3931
  MenubarTrigger.displayName = "MenubarTrigger";
3797
- var MenubarContent = (0, import_react59.forwardRef)(
3932
+ var MenubarContent = (0, import_react60.forwardRef)(
3798
3933
  function MenubarContent2({ className, sideOffset = 6, align = "start", ...props }, ref) {
3799
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(RadixMenubar.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
3934
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(RadixMenubar.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
3800
3935
  RadixMenubar.Content,
3801
3936
  {
3802
3937
  ref,
@@ -3818,24 +3953,24 @@ var itemBase3 = cn(
3818
3953
  "data-[highlighted]:bg-panel-2",
3819
3954
  "data-[disabled]:opacity-40 data-[disabled]:cursor-not-allowed"
3820
3955
  );
3821
- var MenubarItem = (0, import_react59.forwardRef)(function MenubarItem2({ trailing, destructive, className, children, ...props }, ref) {
3822
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
3956
+ var MenubarItem = (0, import_react60.forwardRef)(function MenubarItem2({ trailing, destructive, className, children, ...props }, ref) {
3957
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
3823
3958
  RadixMenubar.Item,
3824
3959
  {
3825
3960
  ref,
3826
3961
  className: cn(itemBase3, destructive ? "text-err" : "text-text", className),
3827
3962
  ...props,
3828
3963
  children: [
3829
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1", children }),
3830
- trailing && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
3964
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1", children }),
3965
+ trailing && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
3831
3966
  ]
3832
3967
  }
3833
3968
  );
3834
3969
  });
3835
3970
  MenubarItem.displayName = "MenubarItem";
3836
- var MenubarSeparator = (0, import_react59.forwardRef)(
3971
+ var MenubarSeparator = (0, import_react60.forwardRef)(
3837
3972
  function MenubarSeparator2({ className, ...props }, ref) {
3838
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
3973
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
3839
3974
  RadixMenubar.Separator,
3840
3975
  {
3841
3976
  ref,
@@ -3849,13 +3984,13 @@ MenubarSeparator.displayName = "MenubarSeparator";
3849
3984
 
3850
3985
  // src/patterns/NavBar/NavBar.tsx
3851
3986
  var RadixNav = __toESM(require("@radix-ui/react-navigation-menu"), 1);
3852
- var import_react61 = require("react");
3987
+ var import_react62 = require("react");
3853
3988
 
3854
3989
  // src/patterns/Sidebar/Sidebar.tsx
3855
- var import_react60 = require("react");
3856
- var import_jsx_runtime53 = require("react/jsx-runtime");
3857
- var Sidebar = (0, import_react60.forwardRef)(function Sidebar2({ width = 240, className, style, ...props }, ref) {
3858
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
3990
+ var import_react61 = require("react");
3991
+ var import_jsx_runtime54 = require("react/jsx-runtime");
3992
+ var Sidebar = (0, import_react61.forwardRef)(function Sidebar2({ width = 240, className, style, ...props }, ref) {
3993
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3859
3994
  "aside",
3860
3995
  {
3861
3996
  ref,
@@ -3869,12 +4004,12 @@ var Sidebar = (0, import_react60.forwardRef)(function Sidebar2({ width = 240, cl
3869
4004
  );
3870
4005
  });
3871
4006
  Sidebar.displayName = "Sidebar";
3872
- var NavItem = (0, import_react60.forwardRef)(
4007
+ var NavItem = (0, import_react61.forwardRef)(
3873
4008
  function NavItem2({ icon, label, active, badge, href, disabled, className, ...props }, ref) {
3874
- const inner = /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_jsx_runtime53.Fragment, { children: [
3875
- icon && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: icon }),
3876
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 truncate", children: label }),
3877
- badge != null && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
4009
+ const inner = /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
4010
+ icon && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: icon }),
4011
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "flex-1 truncate", children: label }),
4012
+ badge != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3878
4013
  "span",
3879
4014
  {
3880
4015
  className: cn(
@@ -3895,7 +4030,7 @@ var NavItem = (0, import_react60.forwardRef)(
3895
4030
  );
3896
4031
  if (href) {
3897
4032
  const anchorProps = props;
3898
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
4033
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3899
4034
  "a",
3900
4035
  {
3901
4036
  ref,
@@ -3909,7 +4044,7 @@ var NavItem = (0, import_react60.forwardRef)(
3909
4044
  );
3910
4045
  }
3911
4046
  const buttonProps = props;
3912
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
4047
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3913
4048
  "button",
3914
4049
  {
3915
4050
  ref,
@@ -3924,7 +4059,7 @@ var NavItem = (0, import_react60.forwardRef)(
3924
4059
  }
3925
4060
  );
3926
4061
  NavItem.displayName = "NavItem";
3927
- var NavSection = (0, import_react60.forwardRef)(function NavSection2({
4062
+ var NavSection = (0, import_react61.forwardRef)(function NavSection2({
3928
4063
  label,
3929
4064
  icon,
3930
4065
  action,
@@ -3938,16 +4073,16 @@ var NavSection = (0, import_react60.forwardRef)(function NavSection2({
3938
4073
  ...props
3939
4074
  }, ref) {
3940
4075
  const isControlled = open !== void 0;
3941
- const [internalOpen, setInternalOpen] = (0, import_react60.useState)(defaultOpen);
4076
+ const [internalOpen, setInternalOpen] = (0, import_react61.useState)(defaultOpen);
3942
4077
  const isOpen = !collapsible || (isControlled ? open : internalOpen);
3943
- const toggle = (0, import_react60.useCallback)(() => {
4078
+ const toggle = (0, import_react61.useCallback)(() => {
3944
4079
  const next = !isOpen;
3945
4080
  if (!isControlled) setInternalOpen(next);
3946
4081
  onOpenChange?.(next);
3947
4082
  }, [isOpen, isControlled, onOpenChange]);
3948
4083
  const eyebrowClass = "text-text-dim flex items-center gap-[6px] px-2 pt-2 font-mono text-[9px] tracking-[1.4px] uppercase";
3949
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { ref, className: cn("flex flex-col gap-1", className), ...props, children: [
3950
- collapsible ? /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
4084
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { ref, className: cn("flex flex-col gap-1", className), ...props, children: [
4085
+ collapsible ? /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
3951
4086
  "button",
3952
4087
  {
3953
4088
  type: "button",
@@ -3960,18 +4095,18 @@ var NavSection = (0, import_react60.forwardRef)(function NavSection2({
3960
4095
  "hover:text-text-muted"
3961
4096
  ),
3962
4097
  children: [
3963
- icon != null && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
3964
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-left", children: label }),
4098
+ icon != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
4099
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "flex-1 text-left", children: label }),
3965
4100
  action,
3966
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { "aria-hidden": true, className: "text-[10px] opacity-70", children: isOpen ? "\u25BE" : "\u25B8" })
4101
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "text-[10px] opacity-70", children: isOpen ? "\u25BE" : "\u25B8" })
3967
4102
  ]
3968
4103
  }
3969
- ) : /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: eyebrowClass, children: [
3970
- icon != null && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
3971
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1", children: label }),
4104
+ ) : /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: eyebrowClass, children: [
4105
+ icon != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
4106
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "flex-1", children: label }),
3972
4107
  action
3973
4108
  ] }),
3974
- isOpen && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
4109
+ isOpen && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3975
4110
  "div",
3976
4111
  {
3977
4112
  className: cn("flex flex-col gap-[2px]", indent > 0 && "border-border ml-2 border-l"),
@@ -3984,12 +4119,12 @@ var NavSection = (0, import_react60.forwardRef)(function NavSection2({
3984
4119
  NavSection.displayName = "NavSection";
3985
4120
 
3986
4121
  // src/patterns/NavBar/NavBar.tsx
3987
- var import_jsx_runtime54 = require("react/jsx-runtime");
4122
+ var import_jsx_runtime55 = require("react/jsx-runtime");
3988
4123
  function isActiveTree(item, activeId) {
3989
4124
  if (item.id === activeId) return true;
3990
4125
  return item.children?.some((c) => isActiveTree(c, activeId)) ?? false;
3991
4126
  }
3992
- var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4127
+ var NavBar = (0, import_react62.forwardRef)(function NavBar2({
3993
4128
  orientation = "horizontal",
3994
4129
  items,
3995
4130
  brand,
@@ -4003,17 +4138,17 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4003
4138
  ...props
4004
4139
  }, ref) {
4005
4140
  const isControlled = value !== void 0;
4006
- const [internalValue, setInternalValue] = (0, import_react61.useState)(defaultValue);
4141
+ const [internalValue, setInternalValue] = (0, import_react62.useState)(defaultValue);
4007
4142
  const activeId = isControlled ? value : internalValue;
4008
- const [drawerOpen, setDrawerOpen] = (0, import_react61.useState)(false);
4009
- const select = (0, import_react61.useCallback)(
4143
+ const [drawerOpen, setDrawerOpen] = (0, import_react62.useState)(false);
4144
+ const select = (0, import_react62.useCallback)(
4010
4145
  (id) => {
4011
4146
  if (!isControlled) setInternalValue(id);
4012
4147
  onValueChange?.(id);
4013
4148
  },
4014
4149
  [isControlled, onValueChange]
4015
4150
  );
4016
- const handleItemActivate = (0, import_react61.useCallback)(
4151
+ const handleItemActivate = (0, import_react62.useCallback)(
4017
4152
  (id) => {
4018
4153
  select(id);
4019
4154
  setDrawerOpen(false);
@@ -4025,7 +4160,7 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4025
4160
  // drawer is open on a viewport that's resizing past `md`, both navs can
4026
4161
  // sit in the DOM together. Identical accessible names would trip axe's
4027
4162
  // `landmark-unique` rule.
4028
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("nav", { "aria-label": "Mobile navigation", className: "flex flex-col gap-1", children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4163
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("nav", { "aria-label": "Mobile navigation", className: "flex flex-col gap-1", children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4029
4164
  VerticalItem,
4030
4165
  {
4031
4166
  item,
@@ -4035,14 +4170,14 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4035
4170
  item.id
4036
4171
  )) })
4037
4172
  );
4038
- const mobileBar = responsive ? /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
4173
+ const mobileBar = responsive ? /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4039
4174
  "div",
4040
4175
  {
4041
4176
  className: cn(
4042
4177
  "border-border bg-panel z-overlay sticky top-0 flex h-[52px] items-center gap-4 border-b px-5 md:hidden"
4043
4178
  ),
4044
4179
  children: [
4045
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4180
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4046
4181
  "button",
4047
4182
  {
4048
4183
  type: "button",
@@ -4052,15 +4187,15 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4052
4187
  children: "\u2630"
4053
4188
  }
4054
4189
  ),
4055
- brand && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex flex-1 items-center text-[13px] font-medium whitespace-nowrap", children: brand }),
4056
- actions && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex items-center gap-3", children: actions })
4190
+ brand && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "flex flex-1 items-center text-[13px] font-medium whitespace-nowrap", children: brand }),
4191
+ actions && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "flex items-center gap-3", children: actions })
4057
4192
  ]
4058
4193
  }
4059
4194
  ) : null;
4060
4195
  if (orientation === "horizontal") {
4061
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
4196
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_jsx_runtime55.Fragment, { children: [
4062
4197
  mobileBar,
4063
- /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
4198
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4064
4199
  "header",
4065
4200
  {
4066
4201
  ref,
@@ -4071,10 +4206,10 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4071
4206
  ),
4072
4207
  ...props,
4073
4208
  children: [
4074
- brand && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "shrink-0 text-[13px] font-medium whitespace-nowrap", children: brand }),
4075
- /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(RadixNav.Root, { className: "relative flex-1", delayDuration: 120, children: [
4076
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.List, { className: "m-0! flex list-none! items-center gap-1 p-0! [&_li]:m-0!", children: items.map(
4077
- (item) => item.children?.length ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4209
+ brand && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "shrink-0 text-[13px] font-medium whitespace-nowrap", children: brand }),
4210
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(RadixNav.Root, { className: "relative flex-1", delayDuration: 120, children: [
4211
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.List, { className: "m-0! flex list-none! items-center gap-1 p-0! [&_li]:m-0!", children: items.map(
4212
+ (item) => item.children?.length ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4078
4213
  HorizontalDropdown,
4079
4214
  {
4080
4215
  item,
@@ -4083,7 +4218,7 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4083
4218
  onActivate: handleItemActivate
4084
4219
  },
4085
4220
  item.id
4086
- ) : /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Item, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4221
+ ) : /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Item, { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4087
4222
  HorizontalLink,
4088
4223
  {
4089
4224
  item,
@@ -4092,13 +4227,13 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4092
4227
  }
4093
4228
  ) }, item.id)
4094
4229
  ) }),
4095
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "z-popover absolute top-full left-0 flex justify-start", children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Viewport, { className: "origin-top-left data-[state=open]:animate-[ship-fade-in_120ms_var(--easing-out)]" }) })
4230
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "z-popover absolute top-full left-0 flex justify-start", children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Viewport, { className: "origin-top-left data-[state=open]:animate-[ship-fade-in_120ms_var(--easing-out)]" }) })
4096
4231
  ] }),
4097
- actions && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex items-center gap-3", children: actions })
4232
+ actions && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "flex items-center gap-3", children: actions })
4098
4233
  ]
4099
4234
  }
4100
4235
  ),
4101
- responsive && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4236
+ responsive && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4102
4237
  Drawer,
4103
4238
  {
4104
4239
  open: drawerOpen,
@@ -4111,9 +4246,9 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4111
4246
  )
4112
4247
  ] });
4113
4248
  }
4114
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
4249
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_jsx_runtime55.Fragment, { children: [
4115
4250
  mobileBar,
4116
- /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
4251
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4117
4252
  "aside",
4118
4253
  {
4119
4254
  ref,
@@ -4126,8 +4261,8 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4126
4261
  ),
4127
4262
  ...props,
4128
4263
  children: [
4129
- brand && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "px-2 py-1 text-[13px] font-medium", children: brand }),
4130
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("nav", { "aria-label": "Sidebar navigation", className: "flex flex-1 flex-col gap-1 overflow-y-auto", children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4264
+ brand && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "px-2 py-1 text-[13px] font-medium", children: brand }),
4265
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("nav", { "aria-label": "Sidebar navigation", className: "flex flex-1 flex-col gap-1 overflow-y-auto", children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4131
4266
  VerticalItem,
4132
4267
  {
4133
4268
  item,
@@ -4136,11 +4271,11 @@ var NavBar = (0, import_react61.forwardRef)(function NavBar2({
4136
4271
  },
4137
4272
  item.id
4138
4273
  )) }),
4139
- actions && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "border-border mt-auto flex flex-col gap-2 border-t pt-3", children: actions })
4274
+ actions && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "border-border mt-auto flex flex-col gap-2 border-t pt-3", children: actions })
4140
4275
  ]
4141
4276
  }
4142
4277
  ),
4143
- responsive && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4278
+ responsive && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4144
4279
  Drawer,
4145
4280
  {
4146
4281
  open: drawerOpen,
@@ -4169,13 +4304,13 @@ function HorizontalLink({ item, active, onActivate }) {
4169
4304
  }
4170
4305
  onActivate(item.id);
4171
4306
  };
4172
- const inner = /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
4173
- item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4174
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { children: item.label }),
4175
- item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(ItemBadge, { active, children: item.badge })
4307
+ const inner = /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_jsx_runtime55.Fragment, { children: [
4308
+ item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4309
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { children: item.label }),
4310
+ item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(ItemBadge, { active, children: item.badge })
4176
4311
  ] });
4177
4312
  if (item.href) {
4178
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4313
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4179
4314
  "a",
4180
4315
  {
4181
4316
  href: item.href,
@@ -4187,7 +4322,7 @@ function HorizontalLink({ item, active, onActivate }) {
4187
4322
  }
4188
4323
  ) });
4189
4324
  }
4190
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4325
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4191
4326
  "button",
4192
4327
  {
4193
4328
  type: "button",
@@ -4200,8 +4335,8 @@ function HorizontalLink({ item, active, onActivate }) {
4200
4335
  ) });
4201
4336
  }
4202
4337
  function HorizontalDropdown({ item, active, activeId, onActivate }) {
4203
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(RadixNav.Item, { children: [
4204
- /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
4338
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(RadixNav.Item, { children: [
4339
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4205
4340
  RadixNav.Trigger,
4206
4341
  {
4207
4342
  className: cn(
@@ -4213,9 +4348,9 @@ function HorizontalDropdown({ item, active, activeId, onActivate }) {
4213
4348
  ),
4214
4349
  disabled: item.disabled,
4215
4350
  children: [
4216
- item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4217
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { children: item.label }),
4218
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4351
+ item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4352
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { children: item.label }),
4353
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4219
4354
  "span",
4220
4355
  {
4221
4356
  "aria-hidden": true,
@@ -4226,7 +4361,7 @@ function HorizontalDropdown({ item, active, activeId, onActivate }) {
4226
4361
  ]
4227
4362
  }
4228
4363
  ),
4229
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Content, { className: "border-border bg-panel min-w-[220px] rounded-xs border p-2 shadow-lg", children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("ul", { className: "m-0! flex list-none! flex-col gap-[2px] p-0! [&_li]:m-0!", children: item.children.map((child) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(DropdownLink, { item: child, active: child.id === activeId, onActivate }) }, child.id)) }) })
4364
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Content, { className: "border-border bg-panel min-w-[220px] rounded-xs border p-2 shadow-lg", children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("ul", { className: "m-0! flex list-none! flex-col gap-[2px] p-0! [&_li]:m-0!", children: item.children.map((child) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(DropdownLink, { item: child, active: child.id === activeId, onActivate }) }, child.id)) }) })
4230
4365
  ] });
4231
4366
  }
4232
4367
  function DropdownLink({ item, active, onActivate }) {
@@ -4243,13 +4378,13 @@ function DropdownLink({ item, active, onActivate }) {
4243
4378
  }
4244
4379
  onActivate(item.id);
4245
4380
  };
4246
- const inner = /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
4247
- item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4248
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "flex-1", children: item.label }),
4249
- item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(ItemBadge, { active, children: item.badge })
4381
+ const inner = /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_jsx_runtime55.Fragment, { children: [
4382
+ item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4383
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "flex-1", children: item.label }),
4384
+ item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(ItemBadge, { active, children: item.badge })
4250
4385
  ] });
4251
4386
  if (item.href) {
4252
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4387
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4253
4388
  "a",
4254
4389
  {
4255
4390
  href: item.href,
@@ -4261,7 +4396,7 @@ function DropdownLink({ item, active, onActivate }) {
4261
4396
  }
4262
4397
  ) });
4263
4398
  }
4264
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4399
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4265
4400
  "button",
4266
4401
  {
4267
4402
  type: "button",
@@ -4276,9 +4411,9 @@ function DropdownLink({ item, active, onActivate }) {
4276
4411
  function VerticalItem({ item, activeId, onActivate }) {
4277
4412
  const hasChildren = (item.children?.length ?? 0) > 0;
4278
4413
  const treeActive = isActiveTree(item, activeId);
4279
- const [open, setOpen] = (0, import_react61.useState)(treeActive);
4280
- const prevTreeActive = (0, import_react61.useRef)(treeActive);
4281
- (0, import_react61.useEffect)(() => {
4414
+ const [open, setOpen] = (0, import_react62.useState)(treeActive);
4415
+ const prevTreeActive = (0, import_react62.useRef)(treeActive);
4416
+ (0, import_react62.useEffect)(() => {
4282
4417
  if (treeActive && !prevTreeActive.current) setOpen(true);
4283
4418
  prevTreeActive.current = treeActive;
4284
4419
  }, [treeActive]);
@@ -4290,7 +4425,7 @@ function VerticalItem({ item, activeId, onActivate }) {
4290
4425
  }
4291
4426
  onActivate(item.id);
4292
4427
  };
4293
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4428
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4294
4429
  NavItem,
4295
4430
  {
4296
4431
  icon: item.icon,
@@ -4303,8 +4438,8 @@ function VerticalItem({ item, activeId, onActivate }) {
4303
4438
  }
4304
4439
  );
4305
4440
  }
4306
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col", children: [
4307
- /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
4441
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("div", { className: "flex flex-col", children: [
4442
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4308
4443
  "button",
4309
4444
  {
4310
4445
  type: "button",
@@ -4320,18 +4455,18 @@ function VerticalItem({ item, activeId, onActivate }) {
4320
4455
  item.disabled && "pointer-events-none opacity-50"
4321
4456
  ),
4322
4457
  children: [
4323
- item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: item.icon }),
4324
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "flex-1 truncate", children: item.label }),
4325
- item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(ItemBadge, { active: treeActive, children: item.badge }),
4326
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { "aria-hidden": true, className: "text-[10px] opacity-60", children: open ? "\u25BE" : "\u25B8" })
4458
+ item.icon != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: item.icon }),
4459
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "flex-1 truncate", children: item.label }),
4460
+ item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(ItemBadge, { active: treeActive, children: item.badge }),
4461
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { "aria-hidden": true, className: "text-[10px] opacity-60", children: open ? "\u25BE" : "\u25B8" })
4327
4462
  ]
4328
4463
  }
4329
4464
  ),
4330
- open && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "border-border mt-1 ml-[18px] flex flex-col gap-[2px] border-l pl-3", children: item.children.map((child) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(VerticalItem, { item: child, activeId, onActivate }, child.id)) })
4465
+ open && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "border-border mt-1 ml-[18px] flex flex-col gap-[2px] border-l pl-3", children: item.children.map((child) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(VerticalItem, { item: child, activeId, onActivate }, child.id)) })
4331
4466
  ] });
4332
4467
  }
4333
4468
  function ItemBadge({ active, children }) {
4334
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4469
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4335
4470
  "span",
4336
4471
  {
4337
4472
  className: cn(
@@ -4344,8 +4479,8 @@ function ItemBadge({ active, children }) {
4344
4479
  }
4345
4480
 
4346
4481
  // src/patterns/OnboardingChecklist/OnboardingChecklist.tsx
4347
- var import_react62 = require("react");
4348
- var import_jsx_runtime55 = require("react/jsx-runtime");
4482
+ var import_react63 = require("react");
4483
+ var import_jsx_runtime56 = require("react/jsx-runtime");
4349
4484
  var statusDot = {
4350
4485
  pending: "off",
4351
4486
  "in-progress": "sync",
@@ -4356,11 +4491,11 @@ var labelStateClass = {
4356
4491
  "in-progress": "text-text",
4357
4492
  done: "text-text-dim line-through"
4358
4493
  };
4359
- var OnboardingChecklist = (0, import_react62.forwardRef)(
4494
+ var OnboardingChecklist = (0, import_react63.forwardRef)(
4360
4495
  function OnboardingChecklist2({ items, onItemClick, title = "Get started", progressLabel, hideProgress, className, ...props }, ref) {
4361
4496
  const total = items.length;
4362
4497
  const done = items.filter((i) => i.status === "done").length;
4363
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4498
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4364
4499
  "section",
4365
4500
  {
4366
4501
  ref,
@@ -4371,11 +4506,11 @@ var OnboardingChecklist = (0, import_react62.forwardRef)(
4371
4506
  ),
4372
4507
  ...props,
4373
4508
  children: [
4374
- /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("header", { className: "flex items-center gap-2", children: [
4375
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "text-[14px] font-medium", children: title }),
4376
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "text-text-dim ml-auto font-mono text-[11px] tabular-nums", children: progressLabel ?? `${done} of ${total} complete` })
4509
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("header", { className: "flex items-center gap-2", children: [
4510
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: "text-[14px] font-medium", children: title }),
4511
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: "text-text-dim ml-auto font-mono text-[11px] tabular-nums", children: progressLabel ?? `${done} of ${total} complete` })
4377
4512
  ] }),
4378
- !hideProgress && total > 0 && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4513
+ !hideProgress && total > 0 && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4379
4514
  "div",
4380
4515
  {
4381
4516
  role: "progressbar",
@@ -4384,7 +4519,7 @@ var OnboardingChecklist = (0, import_react62.forwardRef)(
4384
4519
  "aria-valuenow": done,
4385
4520
  "aria-label": typeof title === "string" ? `${title} progress` : "Setup progress",
4386
4521
  className: "bg-panel-2 h-[3px] w-full overflow-hidden rounded-full",
4387
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4522
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4388
4523
  "span",
4389
4524
  {
4390
4525
  "aria-hidden": true,
@@ -4397,10 +4532,10 @@ var OnboardingChecklist = (0, import_react62.forwardRef)(
4397
4532
  )
4398
4533
  }
4399
4534
  ),
4400
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("ul", { className: "m-0 flex list-none flex-col gap-1 p-0", children: items.map((item) => {
4535
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("ul", { className: "m-0 flex list-none flex-col gap-1 p-0", children: items.map((item) => {
4401
4536
  const interactive = typeof onItemClick === "function";
4402
- const labelBlock = /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_jsx_runtime55.Fragment, { children: [
4403
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4537
+ const labelBlock = /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_jsx_runtime56.Fragment, { children: [
4538
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4404
4539
  StatusDot,
4405
4540
  {
4406
4541
  state: statusDot[item.status],
@@ -4409,17 +4544,17 @@ var OnboardingChecklist = (0, import_react62.forwardRef)(
4409
4544
  className: "mt-[3px]"
4410
4545
  }
4411
4546
  ),
4412
- /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("div", { className: "flex min-w-0 flex-1 flex-col gap-[2px]", children: [
4413
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: cn("text-[13px]", labelStateClass[item.status]), children: item.label }),
4414
- item.description && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "text-text-muted text-[12px] leading-[1.45]", children: item.description })
4547
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { className: "flex min-w-0 flex-1 flex-col gap-[2px]", children: [
4548
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: cn("text-[13px]", labelStateClass[item.status]), children: item.label }),
4549
+ item.description && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: "text-text-muted text-[12px] leading-[1.45]", children: item.description })
4415
4550
  ] })
4416
4551
  ] });
4417
4552
  const labelRegionClass = cn(
4418
4553
  "flex flex-1 items-start gap-3 rounded-md px-2 py-2 text-left transition-colors duration-(--duration-micro)",
4419
4554
  interactive && "cursor-pointer outline-none hover:bg-panel-2 focus-visible:ring-[3px] focus-visible:ring-accent-dim"
4420
4555
  );
4421
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("li", { className: "flex items-start gap-2", children: [
4422
- interactive ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4556
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("li", { className: "flex items-start gap-2", children: [
4557
+ interactive ? /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4423
4558
  "button",
4424
4559
  {
4425
4560
  type: "button",
@@ -4428,8 +4563,8 @@ var OnboardingChecklist = (0, import_react62.forwardRef)(
4428
4563
  className: labelRegionClass,
4429
4564
  children: labelBlock
4430
4565
  }
4431
- ) : /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: labelRegionClass, children: labelBlock }),
4432
- item.action && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "shrink-0 self-center", children: item.action })
4566
+ ) : /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: labelRegionClass, children: labelBlock }),
4567
+ item.action && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "shrink-0 self-center", children: item.action })
4433
4568
  ] }, item.id);
4434
4569
  }) })
4435
4570
  ]
@@ -4440,8 +4575,8 @@ var OnboardingChecklist = (0, import_react62.forwardRef)(
4440
4575
  OnboardingChecklist.displayName = "OnboardingChecklist";
4441
4576
 
4442
4577
  // src/patterns/Pagination/Pagination.tsx
4443
- var import_react63 = require("react");
4444
- var import_jsx_runtime56 = require("react/jsx-runtime");
4578
+ var import_react64 = require("react");
4579
+ var import_jsx_runtime57 = require("react/jsx-runtime");
4445
4580
  function buildRange(page, total, siblings) {
4446
4581
  if (total <= 0) return [];
4447
4582
  const items = [];
@@ -4454,9 +4589,9 @@ function buildRange(page, total, siblings) {
4454
4589
  if (total > 1) items.push(total);
4455
4590
  return items;
4456
4591
  }
4457
- var Pagination = (0, import_react63.forwardRef)(function Pagination2({ page, total, onPageChange, siblings = 1, className, ...props }, ref) {
4592
+ var Pagination = (0, import_react64.forwardRef)(function Pagination2({ page, total, onPageChange, siblings = 1, className, ...props }, ref) {
4458
4593
  const items = buildRange(page, total, siblings);
4459
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4594
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
4460
4595
  "nav",
4461
4596
  {
4462
4597
  ref,
@@ -4464,7 +4599,7 @@ var Pagination = (0, import_react63.forwardRef)(function Pagination2({ page, tot
4464
4599
  className: cn("inline-flex items-center gap-1", className),
4465
4600
  ...props,
4466
4601
  children: [
4467
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4602
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4468
4603
  IconButton,
4469
4604
  {
4470
4605
  size: "sm",
@@ -4477,7 +4612,7 @@ var Pagination = (0, import_react63.forwardRef)(function Pagination2({ page, tot
4477
4612
  ),
4478
4613
  items.map((item, i) => {
4479
4614
  if (item === "start-ellipsis" || item === "end-ellipsis") {
4480
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4615
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4481
4616
  "span",
4482
4617
  {
4483
4618
  "aria-hidden": true,
@@ -4488,7 +4623,7 @@ var Pagination = (0, import_react63.forwardRef)(function Pagination2({ page, tot
4488
4623
  );
4489
4624
  }
4490
4625
  const isActive = item === page;
4491
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4626
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4492
4627
  "button",
4493
4628
  {
4494
4629
  type: "button",
@@ -4506,7 +4641,7 @@ var Pagination = (0, import_react63.forwardRef)(function Pagination2({ page, tot
4506
4641
  item
4507
4642
  );
4508
4643
  }),
4509
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4644
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4510
4645
  IconButton,
4511
4646
  {
4512
4647
  size: "sm",
@@ -4525,8 +4660,8 @@ Pagination.displayName = "Pagination";
4525
4660
 
4526
4661
  // src/patterns/Progress/Progress.tsx
4527
4662
  var import_class_variance_authority11 = require("class-variance-authority");
4528
- var import_react64 = require("react");
4529
- var import_jsx_runtime57 = require("react/jsx-runtime");
4663
+ var import_react65 = require("react");
4664
+ var import_jsx_runtime58 = require("react/jsx-runtime");
4530
4665
  var trackStyles = (0, import_class_variance_authority11.cva)("w-full rounded-full bg-panel-2 overflow-hidden", {
4531
4666
  variants: {
4532
4667
  size: {
@@ -4548,7 +4683,7 @@ var fillStyles = (0, import_class_variance_authority11.cva)("h-full rounded-full
4548
4683
  },
4549
4684
  defaultVariants: { tone: "accent" }
4550
4685
  });
4551
- var Progress = (0, import_react64.forwardRef)(function Progress2({
4686
+ var Progress = (0, import_react65.forwardRef)(function Progress2({
4552
4687
  value = 0,
4553
4688
  max = 100,
4554
4689
  indeterminate = false,
@@ -4562,15 +4697,15 @@ var Progress = (0, import_react64.forwardRef)(function Progress2({
4562
4697
  const clamped = Math.min(max, Math.max(0, value));
4563
4698
  const pct = max > 0 ? clamped / max * 100 : 0;
4564
4699
  const display = Math.round(pct);
4565
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { ref, className: cn("flex w-full flex-col gap-2", className), ...props, children: [
4566
- label != null && /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "flex text-[12px]", children: [
4567
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-text-muted", children: label }),
4568
- showValue && !indeterminate && /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("span", { className: "text-text ml-auto font-mono tabular-nums", children: [
4700
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { ref, className: cn("flex w-full flex-col gap-2", className), ...props, children: [
4701
+ label != null && /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex text-[12px]", children: [
4702
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-text-muted", children: label }),
4703
+ showValue && !indeterminate && /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("span", { className: "text-text ml-auto font-mono tabular-nums", children: [
4569
4704
  display,
4570
4705
  "%"
4571
4706
  ] })
4572
4707
  ] }),
4573
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4708
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4574
4709
  "div",
4575
4710
  {
4576
4711
  role: "progressbar",
@@ -4579,7 +4714,7 @@ var Progress = (0, import_react64.forwardRef)(function Progress2({
4579
4714
  "aria-valuenow": indeterminate ? void 0 : display,
4580
4715
  "aria-label": typeof label === "string" ? label : void 0,
4581
4716
  className: trackStyles({ size }),
4582
- children: indeterminate ? /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4717
+ children: indeterminate ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4583
4718
  "span",
4584
4719
  {
4585
4720
  "aria-hidden": true,
@@ -4589,16 +4724,61 @@ var Progress = (0, import_react64.forwardRef)(function Progress2({
4589
4724
  "animate-[ship-indeterminate_1.4s_linear_infinite]"
4590
4725
  )
4591
4726
  }
4592
- ) : /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { "aria-hidden": true, className: fillStyles({ tone }), style: { width: `${pct}%` } })
4727
+ ) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { "aria-hidden": true, className: fillStyles({ tone }), style: { width: `${pct}%` } })
4593
4728
  }
4594
4729
  )
4595
4730
  ] });
4596
4731
  });
4597
4732
  Progress.displayName = "Progress";
4598
4733
 
4734
+ // src/patterns/PullToRefresh/PullToRefresh.tsx
4735
+ var import_react66 = require("react");
4736
+ var import_jsx_runtime59 = require("react/jsx-runtime");
4737
+ var labels = {
4738
+ idle: "Pull to refresh",
4739
+ pulling: "Pull to refresh",
4740
+ ready: "Release to refresh",
4741
+ loading: "Refreshing\u2026"
4742
+ };
4743
+ var PullToRefresh = (0, import_react66.forwardRef)(function PullToRefresh2({ state = "idle", label, className, ...props }, ref) {
4744
+ const isLoading = state === "loading";
4745
+ const transform = state === "ready" ? "rotate(180deg)" : state === "pulling" ? "rotate(90deg)" : "rotate(0deg)";
4746
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
4747
+ "div",
4748
+ {
4749
+ ref,
4750
+ role: "status",
4751
+ "aria-live": "polite",
4752
+ "aria-busy": isLoading || void 0,
4753
+ className: cn("text-text-muted flex flex-col items-center gap-[6px] py-3", className),
4754
+ ...props,
4755
+ children: [
4756
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4757
+ "div",
4758
+ {
4759
+ "aria-hidden": true,
4760
+ className: cn(
4761
+ "border-border border-t-accent rounded-full border-2",
4762
+ isLoading && "animate-[ship-spin_700ms_linear_infinite]"
4763
+ ),
4764
+ style: {
4765
+ width: 22,
4766
+ height: 22,
4767
+ transform: isLoading ? void 0 : transform,
4768
+ transition: isLoading ? void 0 : "transform 200ms var(--easing-out)"
4769
+ }
4770
+ }
4771
+ ),
4772
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-m-eyebrow font-mono tracking-wide uppercase", children: label ?? labels[state] })
4773
+ ]
4774
+ }
4775
+ );
4776
+ });
4777
+ PullToRefresh.displayName = "PullToRefresh";
4778
+
4599
4779
  // src/patterns/Sparkline/Sparkline.tsx
4600
- var import_react65 = require("react");
4601
- var import_jsx_runtime58 = require("react/jsx-runtime");
4780
+ var import_react67 = require("react");
4781
+ var import_jsx_runtime60 = require("react/jsx-runtime");
4602
4782
  function buildPath(values, w, h) {
4603
4783
  if (values.length === 0) return { line: "", area: "" };
4604
4784
  const pad = 2;
@@ -4617,7 +4797,7 @@ function buildPath(values, w, h) {
4617
4797
  )} L${pad.toFixed(2)},${(h - pad).toFixed(2)} Z`;
4618
4798
  return { line, area };
4619
4799
  }
4620
- var Sparkline = (0, import_react65.forwardRef)(function Sparkline2({
4800
+ var Sparkline = (0, import_react67.forwardRef)(function Sparkline2({
4621
4801
  values,
4622
4802
  width = 160,
4623
4803
  height = 32,
@@ -4628,8 +4808,8 @@ var Sparkline = (0, import_react65.forwardRef)(function Sparkline2({
4628
4808
  "aria-label": ariaLabel = "Trend",
4629
4809
  ...props
4630
4810
  }, ref) {
4631
- const { line, area } = (0, import_react65.useMemo)(() => buildPath(values, width, height), [values, width, height]);
4632
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
4811
+ const { line, area } = (0, import_react67.useMemo)(() => buildPath(values, width, height), [values, width, height]);
4812
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
4633
4813
  "svg",
4634
4814
  {
4635
4815
  ref,
@@ -4641,8 +4821,8 @@ var Sparkline = (0, import_react65.forwardRef)(function Sparkline2({
4641
4821
  className: cn("inline-block", className),
4642
4822
  ...props,
4643
4823
  children: [
4644
- fill && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("path", { d: area, fill: stroke, fillOpacity: 0.16, stroke: "none" }),
4645
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4824
+ fill && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("path", { d: area, fill: stroke, fillOpacity: 0.16, stroke: "none" }),
4825
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4646
4826
  "path",
4647
4827
  {
4648
4828
  d: line,
@@ -4660,16 +4840,16 @@ var Sparkline = (0, import_react65.forwardRef)(function Sparkline2({
4660
4840
  Sparkline.displayName = "Sparkline";
4661
4841
 
4662
4842
  // src/patterns/Spinner/Spinner.tsx
4663
- var import_react66 = require("react");
4664
- var import_jsx_runtime59 = require("react/jsx-runtime");
4843
+ var import_react68 = require("react");
4844
+ var import_jsx_runtime61 = require("react/jsx-runtime");
4665
4845
  var sizes = {
4666
4846
  sm: { box: "h-3 w-3", border: "border-[2px]" },
4667
4847
  md: { box: "h-4 w-4", border: "border-[2px]" },
4668
4848
  lg: { box: "h-5 w-5", border: "border-[2px]" }
4669
4849
  };
4670
- var Spinner2 = (0, import_react66.forwardRef)(function Spinner3({ size = "md", label = "Loading", className, ...props }, ref) {
4850
+ var Spinner2 = (0, import_react68.forwardRef)(function Spinner3({ size = "md", label = "Loading", className, ...props }, ref) {
4671
4851
  const s = sizes[size];
4672
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4852
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
4673
4853
  "span",
4674
4854
  {
4675
4855
  ref,
@@ -4677,7 +4857,7 @@ var Spinner2 = (0, import_react66.forwardRef)(function Spinner3({ size = "md", l
4677
4857
  "aria-label": label,
4678
4858
  className: cn("inline-block", className),
4679
4859
  ...props,
4680
- children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4860
+ children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
4681
4861
  "span",
4682
4862
  {
4683
4863
  "aria-hidden": true,
@@ -4694,8 +4874,8 @@ var Spinner2 = (0, import_react66.forwardRef)(function Spinner3({ size = "md", l
4694
4874
  Spinner2.displayName = "Spinner";
4695
4875
 
4696
4876
  // src/patterns/Stepper/Stepper.tsx
4697
- var import_react67 = require("react");
4698
- var import_jsx_runtime60 = require("react/jsx-runtime");
4877
+ var import_react69 = require("react");
4878
+ var import_jsx_runtime62 = require("react/jsx-runtime");
4699
4879
  var dotBase = "h-6 w-6 rounded-full grid place-items-center text-[11px] font-mono font-semibold border";
4700
4880
  var dotStateClass = {
4701
4881
  done: "bg-accent text-on-accent border-accent",
@@ -4712,8 +4892,8 @@ function stateFor(index, current) {
4712
4892
  if (index === current) return "current";
4713
4893
  return "upcoming";
4714
4894
  }
4715
- var Stepper = (0, import_react67.forwardRef)(function Stepper2({ steps, current, className, ...props }, ref) {
4716
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4895
+ var Stepper = (0, import_react69.forwardRef)(function Stepper2({ steps, current, className, ...props }, ref) {
4896
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
4717
4897
  "ol",
4718
4898
  {
4719
4899
  ref,
@@ -4725,19 +4905,19 @@ var Stepper = (0, import_react67.forwardRef)(function Stepper2({ steps, current,
4725
4905
  const id = typeof step === "string" ? void 0 : step.id;
4726
4906
  const state = stateFor(i, current);
4727
4907
  const connectorActive = i < current;
4728
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(import_react67.Fragment, { children: [
4729
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
4908
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(import_react69.Fragment, { children: [
4909
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
4730
4910
  "li",
4731
4911
  {
4732
4912
  "aria-current": state === "current" ? "step" : void 0,
4733
4913
  className: "flex items-center gap-2",
4734
4914
  children: [
4735
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { "aria-hidden": true, className: cn(dotBase, dotStateClass[state]), children: state === "done" ? "\u2713" : i + 1 }),
4736
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: cn("text-[12px]", labelStateClass2[state]), children: label })
4915
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { "aria-hidden": true, className: cn(dotBase, dotStateClass[state]), children: state === "done" ? "\u2713" : i + 1 }),
4916
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: cn("text-[12px]", labelStateClass2[state]), children: label })
4737
4917
  ]
4738
4918
  }
4739
4919
  ),
4740
- i < steps.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4920
+ i < steps.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
4741
4921
  "span",
4742
4922
  {
4743
4923
  "aria-hidden": true,
@@ -4751,12 +4931,110 @@ var Stepper = (0, import_react67.forwardRef)(function Stepper2({ steps, current,
4751
4931
  });
4752
4932
  Stepper.displayName = "Stepper";
4753
4933
 
4934
+ // src/patterns/TabBar/TabBar.tsx
4935
+ var import_react70 = require("react");
4936
+ var import_jsx_runtime63 = require("react/jsx-runtime");
4937
+ var TabBar = (0, import_react70.forwardRef)(function TabBar2({ items, value, defaultValue, onValueChange, className, ...props }, ref) {
4938
+ const isControlled = value !== void 0;
4939
+ const [internalValue, setInternalValue] = (0, import_react70.useState)(defaultValue);
4940
+ const activeId = isControlled ? value : internalValue;
4941
+ const handleSelect = (0, import_react70.useCallback)(
4942
+ (id, e) => {
4943
+ if (!isControlled) setInternalValue(id);
4944
+ onValueChange?.(id);
4945
+ e.stopPropagation();
4946
+ },
4947
+ [isControlled, onValueChange]
4948
+ );
4949
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
4950
+ "nav",
4951
+ {
4952
+ ref,
4953
+ "aria-label": "Primary",
4954
+ className: cn(
4955
+ "border-border bg-panel h-tabbar grid items-center border-t",
4956
+ "pb-[env(safe-area-inset-bottom)]",
4957
+ className
4958
+ ),
4959
+ style: { gridTemplateColumns: `repeat(${items.length}, minmax(0, 1fr))` },
4960
+ ...props,
4961
+ children: items.map((item) => {
4962
+ const isActive = item.id === activeId;
4963
+ if (item.elevated) {
4964
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "grid place-items-center", children: /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(
4965
+ "button",
4966
+ {
4967
+ type: "button",
4968
+ "aria-current": isActive ? "page" : void 0,
4969
+ disabled: item.disabled,
4970
+ onClick: (e) => handleSelect(item.id, e),
4971
+ className: cn(
4972
+ "bg-accent text-on-accent grid place-items-center rounded-2xl shadow-lg",
4973
+ "-mt-[10px] h-[52px] w-[52px]",
4974
+ "transition-[filter,transform] duration-(--duration-micro)",
4975
+ "hover:brightness-110 active:scale-95",
4976
+ "focus-visible:ring-accent-dim outline-none focus-visible:ring-[3px]",
4977
+ "disabled:cursor-not-allowed disabled:opacity-40"
4978
+ ),
4979
+ children: [
4980
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { "aria-hidden": true, children: item.icon }),
4981
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "sr-only", children: item.label })
4982
+ ]
4983
+ }
4984
+ ) }, item.id);
4985
+ }
4986
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(
4987
+ "button",
4988
+ {
4989
+ type: "button",
4990
+ "aria-current": isActive ? "page" : void 0,
4991
+ disabled: item.disabled,
4992
+ onClick: (e) => handleSelect(item.id, e),
4993
+ className: cn(
4994
+ "flex flex-col items-center justify-center gap-[3px] border-0 bg-transparent",
4995
+ "h-full cursor-pointer outline-none",
4996
+ "focus-visible:ring-accent-dim focus-visible:ring-[3px]",
4997
+ "disabled:cursor-not-allowed disabled:opacity-40",
4998
+ isActive ? "text-accent-text" : "text-text-muted hover:text-text"
4999
+ ),
5000
+ children: [
5001
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("span", { className: "relative inline-flex", "aria-hidden": true, children: [
5002
+ item.icon,
5003
+ item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
5004
+ "span",
5005
+ {
5006
+ className: cn(
5007
+ "absolute -top-1 -right-2 rounded-full font-mono leading-none",
5008
+ "bg-err text-on-accent min-w-[16px] px-[5px] py-[2px] text-center text-[9px]"
5009
+ ),
5010
+ children: item.badge
5011
+ }
5012
+ )
5013
+ ] }),
5014
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("span", { className: "text-[10px] font-medium tracking-tight", children: [
5015
+ item.label,
5016
+ item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("span", { className: "sr-only", children: [
5017
+ ", ",
5018
+ item.badge,
5019
+ " unread"
5020
+ ] })
5021
+ ] })
5022
+ ]
5023
+ },
5024
+ item.id
5025
+ );
5026
+ })
5027
+ }
5028
+ );
5029
+ });
5030
+ TabBar.displayName = "TabBar";
5031
+
4754
5032
  // src/patterns/Tabs/Tabs.tsx
4755
5033
  var RadixTabs = __toESM(require("@radix-ui/react-tabs"), 1);
4756
5034
  var import_class_variance_authority12 = require("class-variance-authority");
4757
- var import_react68 = require("react");
4758
- var import_jsx_runtime61 = require("react/jsx-runtime");
4759
- var TabsVariantContext = (0, import_react68.createContext)("underline");
5035
+ var import_react71 = require("react");
5036
+ var import_jsx_runtime64 = require("react/jsx-runtime");
5037
+ var TabsVariantContext = (0, import_react71.createContext)("underline");
4760
5038
  var tabsListStyles = (0, import_class_variance_authority12.cva)("", {
4761
5039
  variants: {
4762
5040
  variant: {
@@ -4786,8 +5064,8 @@ var tabsTriggerStyles = (0, import_class_variance_authority12.cva)(
4786
5064
  }
4787
5065
  }
4788
5066
  );
4789
- var Tabs = (0, import_react68.forwardRef)(function Tabs2({ variant = "underline", className, ...props }, ref) {
4790
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TabsVariantContext.Provider, { value: variant, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
5067
+ var Tabs = (0, import_react71.forwardRef)(function Tabs2({ variant = "underline", className, ...props }, ref) {
5068
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(TabsVariantContext.Provider, { value: variant, children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
4791
5069
  RadixTabs.Root,
4792
5070
  {
4793
5071
  ref,
@@ -4797,14 +5075,14 @@ var Tabs = (0, import_react68.forwardRef)(function Tabs2({ variant = "underline"
4797
5075
  ) });
4798
5076
  });
4799
5077
  Tabs.displayName = "Tabs";
4800
- var TabsList = (0, import_react68.forwardRef)(function TabsList2({ className, ...props }, ref) {
4801
- const variant = (0, import_react68.useContext)(TabsVariantContext);
4802
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(RadixTabs.List, { ref, className: cn(tabsListStyles({ variant }), className), ...props });
5078
+ var TabsList = (0, import_react71.forwardRef)(function TabsList2({ className, ...props }, ref) {
5079
+ const variant = (0, import_react71.useContext)(TabsVariantContext);
5080
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(RadixTabs.List, { ref, className: cn(tabsListStyles({ variant }), className), ...props });
4803
5081
  });
4804
5082
  TabsList.displayName = "TabsList";
4805
- var Tab = (0, import_react68.forwardRef)(function Tab2({ className, ...props }, ref) {
4806
- const variant = (0, import_react68.useContext)(TabsVariantContext);
4807
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
5083
+ var Tab = (0, import_react71.forwardRef)(function Tab2({ className, ...props }, ref) {
5084
+ const variant = (0, import_react71.useContext)(TabsVariantContext);
5085
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
4808
5086
  RadixTabs.Trigger,
4809
5087
  {
4810
5088
  ref,
@@ -4814,9 +5092,9 @@ var Tab = (0, import_react68.forwardRef)(function Tab2({ className, ...props },
4814
5092
  );
4815
5093
  });
4816
5094
  Tab.displayName = "Tab";
4817
- var TabsContent = (0, import_react68.forwardRef)(
5095
+ var TabsContent = (0, import_react71.forwardRef)(
4818
5096
  function TabsContent2({ className, ...props }, ref) {
4819
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
5097
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
4820
5098
  RadixTabs.Content,
4821
5099
  {
4822
5100
  ref,
@@ -4832,8 +5110,8 @@ var TabsContent = (0, import_react68.forwardRef)(
4832
5110
  TabsContent.displayName = "TabsContent";
4833
5111
 
4834
5112
  // src/patterns/Timeline/Timeline.tsx
4835
- var import_react69 = require("react");
4836
- var import_jsx_runtime62 = require("react/jsx-runtime");
5113
+ var import_react72 = require("react");
5114
+ var import_jsx_runtime65 = require("react/jsx-runtime");
4837
5115
  var ringClass = {
4838
5116
  accent: "border-accent",
4839
5117
  ok: "border-ok",
@@ -4841,8 +5119,8 @@ var ringClass = {
4841
5119
  err: "border-err",
4842
5120
  muted: "border-text-dim"
4843
5121
  };
4844
- var Timeline = (0, import_react69.forwardRef)(function Timeline2({ events, className, children, ...props }, ref) {
4845
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
5122
+ var Timeline = (0, import_react72.forwardRef)(function Timeline2({ events, className, children, ...props }, ref) {
5123
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
4846
5124
  "ol",
4847
5125
  {
4848
5126
  ref,
@@ -4852,14 +5130,14 @@ var Timeline = (0, import_react69.forwardRef)(function Timeline2({ events, class
4852
5130
  className
4853
5131
  ),
4854
5132
  ...props,
4855
- children: events ? events.map((e, i) => /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TimelineItem, { tone: e.tone, time: e.time, description: e.description, children: e.title }, i)) : children
5133
+ children: events ? events.map((e, i) => /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(TimelineItem, { tone: e.tone, time: e.time, description: e.description, children: e.title }, i)) : children
4856
5134
  }
4857
5135
  );
4858
5136
  });
4859
5137
  Timeline.displayName = "Timeline";
4860
- var TimelineItem = (0, import_react69.forwardRef)(function TimelineItem2({ tone = "accent", description, time, className, children, ...props }, ref) {
4861
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("li", { ref, className: cn("relative mb-[18px] last:mb-0", className), ...props, children: [
4862
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
5138
+ var TimelineItem = (0, import_react72.forwardRef)(function TimelineItem2({ tone = "accent", description, time, className, children, ...props }, ref) {
5139
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("li", { ref, className: cn("relative mb-[18px] last:mb-0", className), ...props, children: [
5140
+ /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
4863
5141
  "span",
4864
5142
  {
4865
5143
  "aria-hidden": true,
@@ -4869,15 +5147,15 @@ var TimelineItem = (0, import_react69.forwardRef)(function TimelineItem2({ tone
4869
5147
  )
4870
5148
  }
4871
5149
  ),
4872
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "text-[13px] font-medium", children }),
4873
- description && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "text-text-muted text-[12px]", children: description }),
4874
- time && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "text-text-dim mt-[2px] font-mono text-[10px]", children: time })
5150
+ /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "text-[13px] font-medium", children }),
5151
+ description && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "text-text-muted text-[12px]", children: description }),
5152
+ time && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "text-text-dim mt-[2px] font-mono text-[10px]", children: time })
4875
5153
  ] });
4876
5154
  });
4877
5155
  TimelineItem.displayName = "TimelineItem";
4878
5156
 
4879
5157
  // src/patterns/Timeline/ActivityTimeline.tsx
4880
- var import_react70 = require("react");
5158
+ var import_react73 = require("react");
4881
5159
 
4882
5160
  // src/patterns/Timeline/formatRelative.ts
4883
5161
  var SECOND = 1e3;
@@ -4912,7 +5190,7 @@ function formatRelative(input, now = /* @__PURE__ */ new Date()) {
4912
5190
  }
4913
5191
 
4914
5192
  // src/patterns/Timeline/ActivityTimeline.tsx
4915
- var import_jsx_runtime63 = require("react/jsx-runtime");
5193
+ var import_jsx_runtime66 = require("react/jsx-runtime");
4916
5194
  var ringClass2 = {
4917
5195
  accent: "border-accent",
4918
5196
  ok: "border-ok",
@@ -4920,10 +5198,10 @@ var ringClass2 = {
4920
5198
  err: "border-err",
4921
5199
  muted: "border-text-dim"
4922
5200
  };
4923
- var ActivityTimeline = (0, import_react70.forwardRef)(
5201
+ var ActivityTimeline = (0, import_react73.forwardRef)(
4924
5202
  function ActivityTimeline2({ events, relativeNow, className, ...props }, ref) {
4925
5203
  const now = relativeNow ?? /* @__PURE__ */ new Date();
4926
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
5204
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
4927
5205
  "ol",
4928
5206
  {
4929
5207
  ref,
@@ -4936,8 +5214,8 @@ var ActivityTimeline = (0, import_react70.forwardRef)(
4936
5214
  children: events.map((event) => {
4937
5215
  const tone = event.tone ?? "accent";
4938
5216
  const time = formatRelative(event.at, now);
4939
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("li", { className: "relative mb-4 last:mb-0", children: [
4940
- /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
5217
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("li", { className: "relative mb-4 last:mb-0", children: [
5218
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
4941
5219
  "span",
4942
5220
  {
4943
5221
  "aria-hidden": true,
@@ -4947,16 +5225,16 @@ var ActivityTimeline = (0, import_react70.forwardRef)(
4947
5225
  )
4948
5226
  }
4949
5227
  ),
4950
- /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "flex items-baseline gap-2", children: [
4951
- event.icon && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { "aria-hidden": true, className: "text-text-muted font-mono text-[12px]", children: event.icon }),
4952
- /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "text-[13px] font-medium", children: event.title }),
4953
- time && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("time", { className: "text-text-dim ml-auto font-mono text-[10px]", children: time })
5228
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "flex items-baseline gap-2", children: [
5229
+ event.icon && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { "aria-hidden": true, className: "text-text-muted font-mono text-[12px]", children: event.icon }),
5230
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "text-[13px] font-medium", children: event.title }),
5231
+ time && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("time", { className: "text-text-dim ml-auto font-mono text-[10px]", children: time })
4954
5232
  ] }),
4955
- event.actor && /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "text-text-muted mt-[2px] flex items-center gap-[6px] text-[12px]", children: [
4956
- event.actor.avatar && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { "aria-hidden": true, className: "inline-flex", children: event.actor.avatar }),
4957
- /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { children: event.actor.name })
5233
+ event.actor && /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "text-text-muted mt-[2px] flex items-center gap-[6px] text-[12px]", children: [
5234
+ event.actor.avatar && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { "aria-hidden": true, className: "inline-flex", children: event.actor.avatar }),
5235
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { children: event.actor.name })
4958
5236
  ] }),
4959
- event.payload && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "border-border bg-panel-2 mt-2 rounded-md border px-3 py-2 font-mono text-[11px] leading-[1.5]", children: event.payload })
5237
+ event.payload && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "border-border bg-panel-2 mt-2 rounded-md border px-3 py-2 font-mono text-[11px] leading-[1.5]", children: event.payload })
4960
5238
  ] }, event.id);
4961
5239
  })
4962
5240
  }
@@ -4966,23 +5244,77 @@ var ActivityTimeline = (0, import_react70.forwardRef)(
4966
5244
  ActivityTimeline.displayName = "ActivityTimeline";
4967
5245
 
4968
5246
  // src/patterns/Topbar/Topbar.tsx
4969
- var import_react71 = require("react");
4970
- var import_jsx_runtime64 = require("react/jsx-runtime");
4971
- var Topbar = (0, import_react71.forwardRef)(function Topbar2({ title, leading, actions, className, children, ...props }, ref) {
4972
- return /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)(
5247
+ var import_react74 = require("react");
5248
+ var import_jsx_runtime67 = require("react/jsx-runtime");
5249
+ var Topbar = (0, import_react74.forwardRef)(function Topbar2({
5250
+ title,
5251
+ eyebrow,
5252
+ leading,
5253
+ back,
5254
+ onBack,
5255
+ actions,
5256
+ density = "comfortable",
5257
+ className,
5258
+ children,
5259
+ ...props
5260
+ }, ref) {
5261
+ const isTouch = density === "touch";
5262
+ const backHandler = typeof back === "function" ? back : back ? onBack : void 0;
5263
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
4973
5264
  "header",
4974
5265
  {
4975
5266
  ref,
4976
5267
  className: cn(
4977
- "border-border bg-panel flex h-[52px] items-center gap-4 border-b px-5",
5268
+ "border-border bg-panel flex items-center border-b",
5269
+ isTouch ? "h-navbar gap-2 px-3" : "h-[52px] gap-4 px-5",
4978
5270
  className
4979
5271
  ),
4980
5272
  ...props,
4981
5273
  children: [
5274
+ isTouch && back && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
5275
+ "button",
5276
+ {
5277
+ type: "button",
5278
+ onClick: backHandler,
5279
+ "aria-label": "Back",
5280
+ className: cn(
5281
+ "text-text inline-grid place-items-center rounded-md bg-transparent",
5282
+ // The back button is only rendered in touch density — use the
5283
+ // touch token (44pt) instead of `h-9 w-9` (36px) so it meets the
5284
+ // HIG minimum the rest of the touch surface enforces.
5285
+ "hover:bg-panel-2 h-touch w-touch",
5286
+ "focus-visible:ring-accent-dim outline-none focus-visible:ring-[3px]"
5287
+ ),
5288
+ children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
5289
+ "svg",
5290
+ {
5291
+ width: "20",
5292
+ height: "20",
5293
+ viewBox: "0 0 24 24",
5294
+ fill: "none",
5295
+ stroke: "currentColor",
5296
+ strokeWidth: "2",
5297
+ "aria-hidden": true,
5298
+ children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("path", { d: "m15 18-6-6 6-6" })
5299
+ }
5300
+ )
5301
+ }
5302
+ ),
4982
5303
  leading,
4983
- title && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "text-[13px] font-medium", children: title }),
4984
- /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "flex flex-1 items-center" }),
4985
- actions && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "flex items-center gap-3", children: actions }),
5304
+ (title || isTouch && eyebrow) && /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: cn("min-w-0", isTouch && "flex-1"), children: [
5305
+ isTouch && eyebrow && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "text-m-eyebrow text-accent font-mono tracking-wide uppercase", children: eyebrow }),
5306
+ title && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
5307
+ "div",
5308
+ {
5309
+ className: cn(
5310
+ isTouch ? "text-m-body-lg truncate font-semibold tracking-tight" : "text-[13px] font-medium"
5311
+ ),
5312
+ children: title
5313
+ }
5314
+ )
5315
+ ] }),
5316
+ !isTouch && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "flex flex-1 items-center" }),
5317
+ actions && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: cn("flex items-center", isTouch ? "gap-1" : "gap-3"), children: actions }),
4986
5318
  children
4987
5319
  ]
4988
5320
  }
@@ -4991,8 +5323,8 @@ var Topbar = (0, import_react71.forwardRef)(function Topbar2({ title, leading, a
4991
5323
  Topbar.displayName = "Topbar";
4992
5324
 
4993
5325
  // src/patterns/Tree/Tree.tsx
4994
- var import_react72 = require("react");
4995
- var import_jsx_runtime65 = require("react/jsx-runtime");
5326
+ var import_react75 = require("react");
5327
+ var import_jsx_runtime68 = require("react/jsx-runtime");
4996
5328
  var EMPTY_SET2 = /* @__PURE__ */ new Set();
4997
5329
  function flattenVisible(items, expanded, level, parentId, out) {
4998
5330
  for (const item of items) {
@@ -5003,7 +5335,7 @@ function flattenVisible(items, expanded, level, parentId, out) {
5003
5335
  }
5004
5336
  }
5005
5337
  }
5006
- var Tree = (0, import_react72.forwardRef)(function Tree2({
5338
+ var Tree = (0, import_react75.forwardRef)(function Tree2({
5007
5339
  items,
5008
5340
  expanded: expandedProp,
5009
5341
  defaultExpanded,
@@ -5026,24 +5358,24 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5026
5358
  onChange: onValueChange
5027
5359
  });
5028
5360
  const expandedSet = expanded ?? EMPTY_SET2;
5029
- const flatVisible = (0, import_react72.useMemo)(() => {
5361
+ const flatVisible = (0, import_react75.useMemo)(() => {
5030
5362
  const out = [];
5031
5363
  flattenVisible(items, expandedSet, 1, null, out);
5032
5364
  return out;
5033
5365
  }, [items, expandedSet]);
5034
- const [activeId, setActiveId] = (0, import_react72.useState)(null);
5035
- (0, import_react72.useEffect)(() => {
5366
+ const [activeId, setActiveId] = (0, import_react75.useState)(null);
5367
+ (0, import_react75.useEffect)(() => {
5036
5368
  if (activeId && !flatVisible.some((f) => f.id === activeId)) {
5037
5369
  setActiveId(null);
5038
5370
  }
5039
5371
  }, [activeId, flatVisible]);
5040
- const tabStopId = (0, import_react72.useMemo)(() => {
5372
+ const tabStopId = (0, import_react75.useMemo)(() => {
5041
5373
  if (activeId && flatVisible.some((f) => f.id === activeId)) return activeId;
5042
5374
  if (value && flatVisible.some((f) => f.id === value)) return value;
5043
5375
  return flatVisible[0]?.id ?? null;
5044
5376
  }, [activeId, flatVisible, value]);
5045
- const listRef = (0, import_react72.useRef)(null);
5046
- const setRefs = (0, import_react72.useCallback)(
5377
+ const listRef = (0, import_react75.useRef)(null);
5378
+ const setRefs = (0, import_react75.useCallback)(
5047
5379
  (node) => {
5048
5380
  listRef.current = node;
5049
5381
  if (typeof ref === "function") ref(node);
@@ -5051,20 +5383,20 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5051
5383
  },
5052
5384
  [ref]
5053
5385
  );
5054
- const focusItem = (0, import_react72.useCallback)((id) => {
5386
+ const focusItem = (0, import_react75.useCallback)((id) => {
5055
5387
  const root = listRef.current;
5056
5388
  if (!root) return;
5057
5389
  const el = root.querySelector(`[data-treeitem-id="${CSS.escape(id)}"]`);
5058
5390
  el?.focus();
5059
5391
  }, []);
5060
- const moveActive = (0, import_react72.useCallback)(
5392
+ const moveActive = (0, import_react75.useCallback)(
5061
5393
  (id) => {
5062
5394
  setActiveId(id);
5063
5395
  queueMicrotask(() => focusItem(id));
5064
5396
  },
5065
5397
  [focusItem]
5066
5398
  );
5067
- const toggle = (0, import_react72.useCallback)(
5399
+ const toggle = (0, import_react75.useCallback)(
5068
5400
  (id) => {
5069
5401
  setExpanded((prev) => {
5070
5402
  const next = new Set(prev ?? EMPTY_SET2);
@@ -5075,7 +5407,7 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5075
5407
  },
5076
5408
  [setExpanded]
5077
5409
  );
5078
- const expand = (0, import_react72.useCallback)(
5410
+ const expand = (0, import_react75.useCallback)(
5079
5411
  (id) => {
5080
5412
  setExpanded((prev) => {
5081
5413
  const base = prev ?? EMPTY_SET2;
@@ -5087,7 +5419,7 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5087
5419
  },
5088
5420
  [setExpanded]
5089
5421
  );
5090
- const collapse = (0, import_react72.useCallback)(
5422
+ const collapse = (0, import_react75.useCallback)(
5091
5423
  (id) => {
5092
5424
  setExpanded((prev) => {
5093
5425
  const base = prev ?? EMPTY_SET2;
@@ -5099,13 +5431,13 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5099
5431
  },
5100
5432
  [setExpanded]
5101
5433
  );
5102
- const selectItem = (0, import_react72.useCallback)(
5434
+ const selectItem = (0, import_react75.useCallback)(
5103
5435
  (id) => {
5104
5436
  setValue(id);
5105
5437
  },
5106
5438
  [setValue]
5107
5439
  );
5108
- const handleKeyDown = (0, import_react72.useCallback)(
5440
+ const handleKeyDown = (0, import_react75.useCallback)(
5109
5441
  (e) => {
5110
5442
  onKeyDown?.(e);
5111
5443
  if (e.defaultPrevented) return;
@@ -5185,7 +5517,7 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5185
5517
  toggle
5186
5518
  ]
5187
5519
  );
5188
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
5520
+ return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
5189
5521
  "ul",
5190
5522
  {
5191
5523
  ref: setRefs,
@@ -5193,7 +5525,7 @@ var Tree = (0, import_react72.forwardRef)(function Tree2({
5193
5525
  className: cn("flex flex-col gap-px text-[12px]", className),
5194
5526
  onKeyDown: handleKeyDown,
5195
5527
  ...props,
5196
- children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
5528
+ children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
5197
5529
  TreeItemRow,
5198
5530
  {
5199
5531
  item,
@@ -5228,8 +5560,8 @@ function TreeItemRow({
5228
5560
  const isExpanded = hasChildren && expanded.has(item.id);
5229
5561
  const isSelected = selected === item.id;
5230
5562
  const isTabStop = tabStopId === item.id;
5231
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("li", { role: "none", children: [
5232
- /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)(
5563
+ return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("li", { role: "none", children: [
5564
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(
5233
5565
  "div",
5234
5566
  {
5235
5567
  role: "treeitem",
@@ -5252,14 +5584,14 @@ function TreeItemRow({
5252
5584
  isSelected ? "bg-accent-dim text-accent" : "text-text hover:bg-panel-2"
5253
5585
  ),
5254
5586
  children: [
5255
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("span", { "aria-hidden": true, className: "text-text-dim grid w-3 place-items-center text-[10px]", children: hasChildren ? isExpanded ? "\u25BE" : "\u25B8" : "" }),
5256
- item.icon && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("span", { "aria-hidden": true, className: "text-[12px] opacity-80", children: item.icon }),
5257
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("span", { className: "flex-1 truncate", children: item.label }),
5587
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { "aria-hidden": true, className: "text-text-dim grid w-3 place-items-center text-[10px]", children: hasChildren ? isExpanded ? "\u25BE" : "\u25B8" : "" }),
5588
+ item.icon && /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { "aria-hidden": true, className: "text-[12px] opacity-80", children: item.icon }),
5589
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { className: "flex-1 truncate", children: item.label }),
5258
5590
  item.trailing
5259
5591
  ]
5260
5592
  }
5261
5593
  ),
5262
- hasChildren && isExpanded && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("ul", { role: "group", className: "flex flex-col gap-px", children: (item.children ?? []).map((child) => /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
5594
+ hasChildren && isExpanded && /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("ul", { role: "group", className: "flex flex-col gap-px", children: (item.children ?? []).map((child) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
5263
5595
  TreeItemRow,
5264
5596
  {
5265
5597
  item: child,
@@ -5278,9 +5610,9 @@ function TreeItemRow({
5278
5610
 
5279
5611
  // src/patterns/WizardDialog/WizardDialog.tsx
5280
5612
  var RadixDialog5 = __toESM(require("@radix-ui/react-dialog"), 1);
5281
- var import_react73 = require("react");
5282
- var import_jsx_runtime66 = require("react/jsx-runtime");
5283
- var WizardDialog = (0, import_react73.forwardRef)(function WizardDialog2({
5613
+ var import_react76 = require("react");
5614
+ var import_jsx_runtime69 = require("react/jsx-runtime");
5615
+ var WizardDialog = (0, import_react76.forwardRef)(function WizardDialog2({
5284
5616
  open,
5285
5617
  defaultOpen,
5286
5618
  onOpenChange,
@@ -5296,19 +5628,19 @@ var WizardDialog = (0, import_react73.forwardRef)(function WizardDialog2({
5296
5628
  cancelLabel,
5297
5629
  onCancel
5298
5630
  }, ref) {
5299
- const [current, setCurrent] = (0, import_react73.useState)(initialStep);
5631
+ const [current, setCurrent] = (0, import_react76.useState)(initialStep);
5300
5632
  const total = steps.length;
5301
5633
  const safeCurrent = Math.min(current, Math.max(0, total - 1));
5302
5634
  const step = steps[safeCurrent];
5303
- const goTo = (0, import_react73.useCallback)(
5635
+ const goTo = (0, import_react76.useCallback)(
5304
5636
  (index) => {
5305
5637
  setCurrent(Math.min(Math.max(0, index), Math.max(0, total - 1)));
5306
5638
  },
5307
5639
  [total]
5308
5640
  );
5309
- const goNext = (0, import_react73.useCallback)(() => setCurrent((c) => Math.min(c + 1, total - 1)), [total]);
5310
- const goBack = (0, import_react73.useCallback)(() => setCurrent((c) => Math.max(c - 1, 0)), []);
5311
- const ctx = (0, import_react73.useMemo)(
5641
+ const goNext = (0, import_react76.useCallback)(() => setCurrent((c) => Math.min(c + 1, total - 1)), [total]);
5642
+ const goBack = (0, import_react76.useCallback)(() => setCurrent((c) => Math.max(c - 1, 0)), []);
5643
+ const ctx = (0, import_react76.useMemo)(
5312
5644
  () => ({
5313
5645
  current: safeCurrent,
5314
5646
  total,
@@ -5320,7 +5652,7 @@ var WizardDialog = (0, import_react73.forwardRef)(function WizardDialog2({
5320
5652
  }),
5321
5653
  [safeCurrent, total, goNext, goBack, goTo]
5322
5654
  );
5323
- const stepperSteps = (0, import_react73.useMemo)(() => steps.map((s) => ({ id: s.id, label: s.label })), [steps]);
5655
+ const stepperSteps = (0, import_react76.useMemo)(() => steps.map((s) => ({ id: s.id, label: s.label })), [steps]);
5324
5656
  if (!step) return null;
5325
5657
  const canAdvance = step.canAdvance ? step.canAdvance(ctx) : true;
5326
5658
  const body = typeof step.content === "function" ? step.content(ctx) : step.content;
@@ -5331,23 +5663,23 @@ var WizardDialog = (0, import_react73.forwardRef)(function WizardDialog2({
5331
5663
  goNext();
5332
5664
  }
5333
5665
  };
5334
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(DialogRoot, { open, defaultOpen, onOpenChange, children: /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(DialogContent, { ref, width, children: [
5335
- title && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(WizardTitle, { children: title }),
5336
- description && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(WizardDescription, { children: description }),
5337
- /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "mb-5", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Stepper, { steps: stepperSteps, current: safeCurrent }) }),
5338
- /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "mb-5", children: body }),
5339
- /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "flex justify-end gap-2", children: [
5340
- cancelLabel && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Button, { type: "button", variant: "ghost", onClick: onCancel, children: cancelLabel }),
5341
- /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Button, { type: "button", variant: "secondary", onClick: goBack, disabled: ctx.isFirst, children: backLabel }),
5342
- /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Button, { type: "button", variant: "primary", onClick: handlePrimary, disabled: !canAdvance, children: ctx.isLast ? completeLabel : nextLabel })
5666
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(DialogRoot, { open, defaultOpen, onOpenChange, children: /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(DialogContent, { ref, width, children: [
5667
+ title && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(WizardTitle, { children: title }),
5668
+ description && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(WizardDescription, { children: description }),
5669
+ /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { className: "mb-5", children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Stepper, { steps: stepperSteps, current: safeCurrent }) }),
5670
+ /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { className: "mb-5", children: body }),
5671
+ /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "flex justify-end gap-2", children: [
5672
+ cancelLabel && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Button, { type: "button", variant: "ghost", onClick: onCancel, children: cancelLabel }),
5673
+ /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Button, { type: "button", variant: "secondary", onClick: goBack, disabled: ctx.isFirst, children: backLabel }),
5674
+ /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Button, { type: "button", variant: "primary", onClick: handlePrimary, disabled: !canAdvance, children: ctx.isLast ? completeLabel : nextLabel })
5343
5675
  ] })
5344
5676
  ] }) });
5345
5677
  });
5346
5678
  function WizardTitle({ children }) {
5347
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(RadixDialog5.Title, { className: "mb-2 text-[16px] font-medium", children });
5679
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(RadixDialog5.Title, { className: "mb-2 text-[16px] font-medium", children });
5348
5680
  }
5349
5681
  function WizardDescription({ children }) {
5350
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(RadixDialog5.Description, { className: "text-text-muted mb-4 text-[13px] leading-[1.55]", children });
5682
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(RadixDialog5.Description, { className: "text-text-muted mb-4 text-[13px] leading-[1.55]", children });
5351
5683
  }
5352
5684
  WizardDialog.displayName = "WizardDialog";
5353
5685
  // Annotate the CommonJS export names for ESM import in node:
@@ -5415,6 +5747,7 @@ WizardDialog.displayName = "WizardDialog";
5415
5747
  IconButton,
5416
5748
  Input,
5417
5749
  Kbd,
5750
+ LargeTitle,
5418
5751
  MenuCheckboxItem,
5419
5752
  MenuItem,
5420
5753
  MenuSeparator,
@@ -5439,6 +5772,7 @@ WizardDialog.displayName = "WizardDialog";
5439
5772
  PopoverRoot,
5440
5773
  PopoverTrigger,
5441
5774
  Progress,
5775
+ PullToRefresh,
5442
5776
  RadialProgress,
5443
5777
  Radio,
5444
5778
  RadioGroup,
@@ -5454,6 +5788,7 @@ WizardDialog.displayName = "WizardDialog";
5454
5788
  SelectValue,
5455
5789
  Sheet,
5456
5790
  Sidebar,
5791
+ SimpleTooltip,
5457
5792
  Skeleton,
5458
5793
  SkeletonGroup,
5459
5794
  Slider,
@@ -5465,6 +5800,7 @@ WizardDialog.displayName = "WizardDialog";
5465
5800
  Stepper,
5466
5801
  Switch,
5467
5802
  Tab,
5803
+ TabBar,
5468
5804
  Tabs,
5469
5805
  TabsContent,
5470
5806
  TabsList,
@@ -5479,7 +5815,6 @@ WizardDialog.displayName = "WizardDialog";
5479
5815
  TooltipContent,
5480
5816
  TooltipPortal,
5481
5817
  TooltipProvider,
5482
- TooltipRoot,
5483
5818
  TooltipTrigger,
5484
5819
  Topbar,
5485
5820
  Tree,