@ship-it-ui/ui 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1409,10 +1409,71 @@ var Kbd = forwardRef22(function Kbd2({ className, children, ...props }, ref) {
1409
1409
  });
1410
1410
  Kbd.displayName = "Kbd";
1411
1411
 
1412
+ // src/components/ScrollArea/ScrollArea.tsx
1413
+ import * as RadixScrollArea from "@radix-ui/react-scroll-area";
1414
+ import { forwardRef as forwardRef23 } from "react";
1415
+ import { jsx as jsx24, jsxs as jsxs19 } from "react/jsx-runtime";
1416
+ var scrollbarBase = "flex touch-none select-none p-[2px] transition-colors duration-(--duration-micro)";
1417
+ var thumbBase = 'relative flex-1 rounded-full bg-text-muted/40 hover:bg-text-muted/60 before:absolute before:inset-1/2 before:size-full before:min-h-[44px] before:min-w-[44px] before:-translate-x-1/2 before:-translate-y-1/2 before:content-[""]';
1418
+ var ScrollArea = forwardRef23(function ScrollArea2({
1419
+ type = "hover",
1420
+ orientation = "vertical",
1421
+ scrollHideDelay = 600,
1422
+ className,
1423
+ viewportClassName,
1424
+ viewportRef,
1425
+ children,
1426
+ ...props
1427
+ }, ref) {
1428
+ const showVertical = orientation === "vertical" || orientation === "both";
1429
+ const showHorizontal = orientation === "horizontal" || orientation === "both";
1430
+ return /* @__PURE__ */ jsxs19(
1431
+ RadixScrollArea.Root,
1432
+ {
1433
+ ref,
1434
+ type,
1435
+ scrollHideDelay,
1436
+ className: cn("relative overflow-hidden", className),
1437
+ ...props,
1438
+ children: [
1439
+ /* @__PURE__ */ jsx24(
1440
+ RadixScrollArea.Viewport,
1441
+ {
1442
+ ref: viewportRef,
1443
+ className: cn("h-full w-full rounded-[inherit]", viewportClassName),
1444
+ children
1445
+ }
1446
+ ),
1447
+ showVertical && /* @__PURE__ */ jsx24(
1448
+ RadixScrollArea.Scrollbar,
1449
+ {
1450
+ orientation: "vertical",
1451
+ className: cn(scrollbarBase, "bg-panel-2/40 hover:bg-panel-2/80 h-full w-[10px]"),
1452
+ children: /* @__PURE__ */ jsx24(RadixScrollArea.Thumb, { className: thumbBase })
1453
+ }
1454
+ ),
1455
+ showHorizontal && /* @__PURE__ */ jsx24(
1456
+ RadixScrollArea.Scrollbar,
1457
+ {
1458
+ orientation: "horizontal",
1459
+ className: cn(
1460
+ scrollbarBase,
1461
+ "bg-panel-2/40 hover:bg-panel-2/80 h-[10px] w-full flex-col"
1462
+ ),
1463
+ children: /* @__PURE__ */ jsx24(RadixScrollArea.Thumb, { className: thumbBase })
1464
+ }
1465
+ ),
1466
+ orientation === "both" && /* @__PURE__ */ jsx24(RadixScrollArea.Corner, { className: "bg-panel-2/60" })
1467
+ ]
1468
+ }
1469
+ );
1470
+ });
1471
+ ScrollArea.displayName = "ScrollArea";
1472
+
1412
1473
  // src/components/Skeleton/Skeleton.tsx
1413
1474
  import { cva as cva7 } from "class-variance-authority";
1414
- import { forwardRef as forwardRef23 } from "react";
1415
- import { jsx as jsx24 } from "react/jsx-runtime";
1475
+ import { forwardRef as forwardRef24 } from "react";
1476
+ import { jsx as jsx25 } from "react/jsx-runtime";
1416
1477
  var skeletonStyles = cva7("block bg-panel-2 animate-[ship-skeleton_1.4s_infinite]", {
1417
1478
  variants: {
1418
1479
  shape: {
@@ -1424,11 +1485,11 @@ var skeletonStyles = cva7("block bg-panel-2 animate-[ship-skeleton_1.4s_infinite
1424
1485
  defaultVariants: { shape: "line" }
1425
1486
  });
1426
1487
  var defaultHeight = { line: 14, block: 80, circle: 40 };
1427
- var Skeleton = forwardRef23(function Skeleton2({ shape = "line", width = "100%", height, standalone = false, className, style, ...props }, ref) {
1488
+ var Skeleton = forwardRef24(function Skeleton2({ shape = "line", width = "100%", height, standalone = false, className, style, ...props }, ref) {
1428
1489
  const h = height ?? defaultHeight[shape];
1429
1490
  const w = shape === "circle" ? h : width;
1430
1491
  const a11yProps = standalone ? { role: "status", "aria-busy": true, "aria-label": "Loading" } : { "aria-hidden": true };
1431
- return /* @__PURE__ */ jsx24(
1492
+ return /* @__PURE__ */ jsx25(
1432
1493
  "div",
1433
1494
  {
1434
1495
  ref,
@@ -1440,11 +1501,11 @@ var Skeleton = forwardRef23(function Skeleton2({ shape = "line", width = "100%",
1440
1501
  );
1441
1502
  });
1442
1503
  Skeleton.displayName = "Skeleton";
1443
- var SkeletonGroup = forwardRef23(function SkeletonGroup2({ label = "Loading", loading = true, className, children, ...props }, ref) {
1504
+ var SkeletonGroup = forwardRef24(function SkeletonGroup2({ label = "Loading", loading = true, className, children, ...props }, ref) {
1444
1505
  if (!loading) {
1445
- return /* @__PURE__ */ jsx24("div", { ref, className, ...props, children });
1506
+ return /* @__PURE__ */ jsx25("div", { ref, className, ...props, children });
1446
1507
  }
1447
- return /* @__PURE__ */ jsx24(
1508
+ return /* @__PURE__ */ jsx25(
1448
1509
  "div",
1449
1510
  {
1450
1511
  ref,
@@ -1460,10 +1521,10 @@ var SkeletonGroup = forwardRef23(function SkeletonGroup2({ label = "Loading", lo
1460
1521
  SkeletonGroup.displayName = "SkeletonGroup";
1461
1522
 
1462
1523
  // src/components/Tag/Tag.tsx
1463
- import { forwardRef as forwardRef24 } from "react";
1464
- import { jsx as jsx25, jsxs as jsxs19 } from "react/jsx-runtime";
1465
- var Tag = forwardRef24(function Tag2({ onRemove, icon, size = 22, className, children, ...props }, ref) {
1466
- return /* @__PURE__ */ jsxs19(
1524
+ import { forwardRef as forwardRef25 } from "react";
1525
+ import { jsx as jsx26, jsxs as jsxs20 } from "react/jsx-runtime";
1526
+ var Tag = forwardRef25(function Tag2({ onRemove, icon, size = 22, className, children, ...props }, ref) {
1527
+ return /* @__PURE__ */ jsxs20(
1467
1528
  "span",
1468
1529
  {
1469
1530
  ref,
@@ -1475,9 +1536,9 @@ var Tag = forwardRef24(function Tag2({ onRemove, icon, size = 22, className, chi
1475
1536
  style: { height: size },
1476
1537
  ...props,
1477
1538
  children: [
1478
- icon && /* @__PURE__ */ jsx25("span", { className: "text-text-dim inline-flex", children: icon }),
1539
+ icon && /* @__PURE__ */ jsx26("span", { className: "text-text-dim inline-flex", children: icon }),
1479
1540
  children,
1480
- onRemove && /* @__PURE__ */ jsx25(
1541
+ onRemove && /* @__PURE__ */ jsx26(
1481
1542
  "button",
1482
1543
  {
1483
1544
  type: "button",
@@ -1495,14 +1556,14 @@ Tag.displayName = "Tag";
1495
1556
 
1496
1557
  // src/components/ContextMenu/ContextMenu.tsx
1497
1558
  import * as RadixContext from "@radix-ui/react-context-menu";
1498
- import { forwardRef as forwardRef25 } from "react";
1499
- import { jsx as jsx26, jsxs as jsxs20 } from "react/jsx-runtime";
1559
+ import { forwardRef as forwardRef26 } from "react";
1560
+ import { jsx as jsx27, jsxs as jsxs21 } from "react/jsx-runtime";
1500
1561
  var ContextMenuRoot = RadixContext.Root;
1501
1562
  var ContextMenuTrigger = RadixContext.Trigger;
1502
1563
  var ContextMenuPortal = RadixContext.Portal;
1503
- var ContextMenuContent = forwardRef25(
1564
+ var ContextMenuContent = forwardRef26(
1504
1565
  function ContextMenuContent2({ className, ...props }, ref) {
1505
- return /* @__PURE__ */ jsx26(RadixContext.Portal, { children: /* @__PURE__ */ jsx26(
1566
+ return /* @__PURE__ */ jsx27(RadixContext.Portal, { children: /* @__PURE__ */ jsx27(
1506
1567
  RadixContext.Content,
1507
1568
  {
1508
1569
  ref,
@@ -1522,26 +1583,26 @@ var itemBase = cn(
1522
1583
  "data-[highlighted]:bg-panel-2",
1523
1584
  "data-[disabled]:opacity-40 data-[disabled]:cursor-not-allowed"
1524
1585
  );
1525
- var ContextMenuItem = forwardRef25(
1586
+ var ContextMenuItem = forwardRef26(
1526
1587
  function ContextMenuItem2({ icon, trailing, destructive, className, children, ...props }, ref) {
1527
- return /* @__PURE__ */ jsxs20(
1588
+ return /* @__PURE__ */ jsxs21(
1528
1589
  RadixContext.Item,
1529
1590
  {
1530
1591
  ref,
1531
1592
  className: cn(itemBase, destructive ? "text-err" : "text-text", className),
1532
1593
  ...props,
1533
1594
  children: [
1534
- icon && /* @__PURE__ */ jsx26("span", { className: "w-[14px] text-[12px] opacity-70", children: icon }),
1535
- /* @__PURE__ */ jsx26("span", { className: "flex-1", children }),
1536
- trailing && /* @__PURE__ */ jsx26("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
1595
+ icon && /* @__PURE__ */ jsx27("span", { className: "w-[14px] text-[12px] opacity-70", children: icon }),
1596
+ /* @__PURE__ */ jsx27("span", { className: "flex-1", children }),
1597
+ trailing && /* @__PURE__ */ jsx27("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
1537
1598
  ]
1538
1599
  }
1539
1600
  );
1540
1601
  }
1541
1602
  );
1542
1603
  ContextMenuItem.displayName = "ContextMenuItem";
1543
- var ContextMenuSeparator = forwardRef25(function ContextMenuSeparator2({ className, ...props }, ref) {
1544
- return /* @__PURE__ */ jsx26(
1604
+ var ContextMenuSeparator = forwardRef26(function ContextMenuSeparator2({ className, ...props }, ref) {
1605
+ return /* @__PURE__ */ jsx27(
1545
1606
  RadixContext.Separator,
1546
1607
  {
1547
1608
  ref,
@@ -1555,15 +1616,15 @@ var ContextMenu = RadixContext.Root;
1555
1616
 
1556
1617
  // src/components/Dialog/Dialog.tsx
1557
1618
  import * as RadixDialog from "@radix-ui/react-dialog";
1558
- import { forwardRef as forwardRef26 } from "react";
1559
- import { jsx as jsx27, jsxs as jsxs21 } from "react/jsx-runtime";
1619
+ import { forwardRef as forwardRef27 } from "react";
1620
+ import { jsx as jsx28, jsxs as jsxs22 } from "react/jsx-runtime";
1560
1621
  var DialogRoot = RadixDialog.Root;
1561
1622
  var DialogTrigger = RadixDialog.Trigger;
1562
1623
  var DialogClose = RadixDialog.Close;
1563
1624
  var DialogPortal = RadixDialog.Portal;
1564
- var DialogOverlay = forwardRef26(
1625
+ var DialogOverlay = forwardRef27(
1565
1626
  function DialogOverlay2({ className, ...props }, ref) {
1566
- return /* @__PURE__ */ jsx27(
1627
+ return /* @__PURE__ */ jsx28(
1567
1628
  RadixDialog.Overlay,
1568
1629
  {
1569
1630
  ref,
@@ -1578,10 +1639,10 @@ var DialogOverlay = forwardRef26(
1578
1639
  }
1579
1640
  );
1580
1641
  DialogOverlay.displayName = "DialogOverlay";
1581
- var DialogContent = forwardRef26(function DialogContent2({ className, width = 460, style, children, ...props }, ref) {
1582
- return /* @__PURE__ */ jsxs21(DialogPortal, { children: [
1583
- /* @__PURE__ */ jsx27(DialogOverlay, {}),
1584
- /* @__PURE__ */ jsx27(
1642
+ var DialogContent = forwardRef27(function DialogContent2({ className, width = 460, style, children, ...props }, ref) {
1643
+ return /* @__PURE__ */ jsxs22(DialogPortal, { children: [
1644
+ /* @__PURE__ */ jsx28(DialogOverlay, {}),
1645
+ /* @__PURE__ */ jsx28(
1585
1646
  RadixDialog.Content,
1586
1647
  {
1587
1648
  ref,
@@ -1601,31 +1662,31 @@ var DialogContent = forwardRef26(function DialogContent2({ className, width = 46
1601
1662
  });
1602
1663
  DialogContent.displayName = "DialogContent";
1603
1664
  function Dialog({ title, description, footer, width, children, ...rootProps }) {
1604
- return /* @__PURE__ */ jsx27(DialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs21(DialogContent, { width, children: [
1605
- title && /* @__PURE__ */ jsx27(
1665
+ return /* @__PURE__ */ jsx28(DialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs22(DialogContent, { width, children: [
1666
+ title && /* @__PURE__ */ jsx28(
1606
1667
  RadixDialog.Title,
1607
1668
  {
1608
1669
  className: cn("text-[16px] font-medium", description ? "mb-[6px]" : "mb-4"),
1609
1670
  children: title
1610
1671
  }
1611
1672
  ),
1612
- description && /* @__PURE__ */ jsx27(RadixDialog.Description, { className: "text-text-muted mb-[18px] text-[13px] leading-[1.55]", children: description }),
1673
+ description && /* @__PURE__ */ jsx28(RadixDialog.Description, { className: "text-text-muted mb-[18px] text-[13px] leading-[1.55]", children: description }),
1613
1674
  children,
1614
- footer && /* @__PURE__ */ jsx27("div", { className: "mt-5 flex justify-end gap-2", children: footer })
1675
+ footer && /* @__PURE__ */ jsx28("div", { className: "mt-5 flex justify-end gap-2", children: footer })
1615
1676
  ] }) });
1616
1677
  }
1617
1678
 
1618
1679
  // src/components/Dialog/Drawer.tsx
1619
1680
  import * as RadixDialog2 from "@radix-ui/react-dialog";
1620
- import { forwardRef as forwardRef27 } from "react";
1621
- import { jsx as jsx28, jsxs as jsxs22 } from "react/jsx-runtime";
1681
+ import { forwardRef as forwardRef28 } from "react";
1682
+ import { jsx as jsx29, jsxs as jsxs23 } from "react/jsx-runtime";
1622
1683
  var sideClasses = {
1623
1684
  left: "left-0 border-r border-border-strong data-[state=open]:animate-[ship-slide-in-left_220ms_var(--easing-out)]",
1624
1685
  right: "right-0 border-l border-border-strong data-[state=open]:animate-[ship-slide-in-right_220ms_var(--easing-out)]"
1625
1686
  };
1626
- var DrawerHeader = ({ title, onClose }) => /* @__PURE__ */ jsxs22("div", { className: "border-border flex items-center justify-between border-b p-[16px] px-5", children: [
1627
- /* @__PURE__ */ jsx28(RadixDialog2.Title, { className: "text-[14px] font-medium", children: title }),
1628
- /* @__PURE__ */ jsx28(
1687
+ var DrawerHeader = ({ title, onClose }) => /* @__PURE__ */ jsxs23("div", { className: "border-border flex items-center justify-between border-b p-[16px] px-5", children: [
1688
+ /* @__PURE__ */ jsx29(RadixDialog2.Title, { className: "text-[14px] font-medium", children: title }),
1689
+ /* @__PURE__ */ jsx29(
1629
1690
  RadixDialog2.Close,
1630
1691
  {
1631
1692
  onClick: onClose,
@@ -1635,10 +1696,10 @@ var DrawerHeader = ({ title, onClose }) => /* @__PURE__ */ jsxs22("div", { class
1635
1696
  }
1636
1697
  )
1637
1698
  ] });
1638
- var Drawer = forwardRef27(function Drawer2({ side = "right", title, width = 420, children, ...rootProps }, ref) {
1639
- return /* @__PURE__ */ jsx28(DialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs22(DialogPortal, { children: [
1640
- /* @__PURE__ */ jsx28(DialogOverlay, {}),
1641
- /* @__PURE__ */ jsxs22(
1699
+ var Drawer = forwardRef28(function Drawer2({ side = "right", title, width = 420, children, ...rootProps }, ref) {
1700
+ return /* @__PURE__ */ jsx29(DialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs23(DialogPortal, { children: [
1701
+ /* @__PURE__ */ jsx29(DialogOverlay, {}),
1702
+ /* @__PURE__ */ jsxs23(
1642
1703
  RadixDialog2.Content,
1643
1704
  {
1644
1705
  ref,
@@ -1649,8 +1710,8 @@ var Drawer = forwardRef27(function Drawer2({ side = "right", title, width = 420,
1649
1710
  ),
1650
1711
  style: { width },
1651
1712
  children: [
1652
- title ? /* @__PURE__ */ jsx28(DrawerHeader, { title }) : /* @__PURE__ */ jsx28(RadixDialog2.Title, { className: "sr-only", children: "Drawer" }),
1653
- /* @__PURE__ */ jsx28("div", { className: "flex-1 overflow-auto p-5", children })
1713
+ title ? /* @__PURE__ */ jsx29(DrawerHeader, { title }) : /* @__PURE__ */ jsx29(RadixDialog2.Title, { className: "sr-only", children: "Drawer" }),
1714
+ /* @__PURE__ */ jsx29("div", { className: "flex-1 overflow-auto p-5", children })
1654
1715
  ]
1655
1716
  }
1656
1717
  )
@@ -1660,12 +1721,12 @@ Drawer.displayName = "Drawer";
1660
1721
 
1661
1722
  // src/components/Dialog/Sheet.tsx
1662
1723
  import * as RadixDialog3 from "@radix-ui/react-dialog";
1663
- import { forwardRef as forwardRef28 } from "react";
1664
- import { jsx as jsx29, jsxs as jsxs23 } from "react/jsx-runtime";
1665
- var Sheet = forwardRef28(function Sheet2({ title, width = "min(640px, 90vw)", children, ...rootProps }, ref) {
1666
- return /* @__PURE__ */ jsx29(DialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs23(DialogPortal, { children: [
1667
- /* @__PURE__ */ jsx29(DialogOverlay, {}),
1668
- /* @__PURE__ */ jsxs23(
1724
+ import { forwardRef as forwardRef29 } from "react";
1725
+ import { jsx as jsx30, jsxs as jsxs24 } from "react/jsx-runtime";
1726
+ var Sheet = forwardRef29(function Sheet2({ title, width = "min(640px, 90vw)", children, ...rootProps }, ref) {
1727
+ return /* @__PURE__ */ jsx30(DialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs24(DialogPortal, { children: [
1728
+ /* @__PURE__ */ jsx30(DialogOverlay, {}),
1729
+ /* @__PURE__ */ jsxs24(
1669
1730
  RadixDialog3.Content,
1670
1731
  {
1671
1732
  ref,
@@ -1677,7 +1738,7 @@ var Sheet = forwardRef28(function Sheet2({ title, width = "min(640px, 90vw)", ch
1677
1738
  ),
1678
1739
  style: { width },
1679
1740
  children: [
1680
- title ? /* @__PURE__ */ jsx29(RadixDialog3.Title, { className: "mb-1 text-[15px] font-medium", children: title }) : /* @__PURE__ */ jsx29(RadixDialog3.Title, { className: "sr-only", children: "Sheet" }),
1741
+ title ? /* @__PURE__ */ jsx30(RadixDialog3.Title, { className: "mb-1 text-[15px] font-medium", children: title }) : /* @__PURE__ */ jsx30(RadixDialog3.Title, { className: "sr-only", children: "Sheet" }),
1681
1742
  children
1682
1743
  ]
1683
1744
  }
@@ -1688,15 +1749,15 @@ Sheet.displayName = "Sheet";
1688
1749
 
1689
1750
  // src/components/Dialog/AlertDialog.tsx
1690
1751
  import * as RadixAlert from "@radix-ui/react-alert-dialog";
1691
- import { forwardRef as forwardRef29 } from "react";
1692
- import { jsx as jsx30, jsxs as jsxs24 } from "react/jsx-runtime";
1752
+ import { forwardRef as forwardRef30 } from "react";
1753
+ import { jsx as jsx31, jsxs as jsxs25 } from "react/jsx-runtime";
1693
1754
  var AlertDialogRoot = RadixAlert.Root;
1694
1755
  var AlertDialogTrigger = RadixAlert.Trigger;
1695
1756
  var AlertDialogAction = RadixAlert.Action;
1696
1757
  var AlertDialogCancel = RadixAlert.Cancel;
1697
- var AlertDialog = forwardRef29(function AlertDialog2({ title, description, footer, width = 460, children, ...rootProps }, ref) {
1698
- return /* @__PURE__ */ jsx30(AlertDialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs24(RadixAlert.Portal, { children: [
1699
- /* @__PURE__ */ jsx30(
1758
+ var AlertDialog = forwardRef30(function AlertDialog2({ title, description, footer, width = 460, children, ...rootProps }, ref) {
1759
+ return /* @__PURE__ */ jsx31(AlertDialogRoot, { ...rootProps, children: /* @__PURE__ */ jsxs25(RadixAlert.Portal, { children: [
1760
+ /* @__PURE__ */ jsx31(
1700
1761
  RadixAlert.Overlay,
1701
1762
  {
1702
1763
  className: cn(
@@ -1705,7 +1766,7 @@ var AlertDialog = forwardRef29(function AlertDialog2({ title, description, foote
1705
1766
  )
1706
1767
  }
1707
1768
  ),
1708
- /* @__PURE__ */ jsxs24(
1769
+ /* @__PURE__ */ jsxs25(
1709
1770
  RadixAlert.Content,
1710
1771
  {
1711
1772
  ref,
@@ -1716,16 +1777,16 @@ var AlertDialog = forwardRef29(function AlertDialog2({ title, description, foote
1716
1777
  "data-[state=open]:animate-[ship-dialog-in_180ms_var(--easing-out)]"
1717
1778
  ),
1718
1779
  children: [
1719
- /* @__PURE__ */ jsx30(
1780
+ /* @__PURE__ */ jsx31(
1720
1781
  RadixAlert.Title,
1721
1782
  {
1722
1783
  className: cn("text-[16px] font-medium", description ? "mb-[6px]" : "mb-4"),
1723
1784
  children: title
1724
1785
  }
1725
1786
  ),
1726
- description && /* @__PURE__ */ jsx30(RadixAlert.Description, { className: "text-text-muted mb-[18px] text-[13px] leading-[1.55]", children: description }),
1787
+ description && /* @__PURE__ */ jsx31(RadixAlert.Description, { className: "text-text-muted mb-[18px] text-[13px] leading-[1.55]", children: description }),
1727
1788
  children,
1728
- footer && /* @__PURE__ */ jsx30("div", { className: "mt-5 flex justify-end gap-2", children: footer })
1789
+ footer && /* @__PURE__ */ jsx31("div", { className: "mt-5 flex justify-end gap-2", children: footer })
1729
1790
  ]
1730
1791
  }
1731
1792
  )
@@ -1735,17 +1796,17 @@ AlertDialog.displayName = "AlertDialog";
1735
1796
 
1736
1797
  // src/components/DropdownMenu/DropdownMenu.tsx
1737
1798
  import * as RadixMenu from "@radix-ui/react-dropdown-menu";
1738
- import { forwardRef as forwardRef30 } from "react";
1739
- import { jsx as jsx31, jsxs as jsxs25 } from "react/jsx-runtime";
1799
+ import { forwardRef as forwardRef31 } from "react";
1800
+ import { jsx as jsx32, jsxs as jsxs26 } from "react/jsx-runtime";
1740
1801
  var DropdownMenuRoot = RadixMenu.Root;
1741
1802
  var DropdownMenuTrigger = RadixMenu.Trigger;
1742
1803
  var DropdownMenuPortal = RadixMenu.Portal;
1743
1804
  var DropdownMenuGroup = RadixMenu.Group;
1744
1805
  var DropdownMenuLabel = RadixMenu.Label;
1745
1806
  var DropdownMenuRadioGroup = RadixMenu.RadioGroup;
1746
- var DropdownMenuContent = forwardRef30(
1807
+ var DropdownMenuContent = forwardRef31(
1747
1808
  function DropdownMenuContent2({ className, sideOffset = 6, align = "start", ...props }, ref) {
1748
- return /* @__PURE__ */ jsx31(RadixMenu.Portal, { children: /* @__PURE__ */ jsx31(
1809
+ return /* @__PURE__ */ jsx32(RadixMenu.Portal, { children: /* @__PURE__ */ jsx32(
1749
1810
  RadixMenu.Content,
1750
1811
  {
1751
1812
  ref,
@@ -1767,32 +1828,32 @@ var itemBase2 = cn(
1767
1828
  "data-[highlighted]:bg-panel-2",
1768
1829
  "data-[disabled]:opacity-40 data-[disabled]:cursor-not-allowed"
1769
1830
  );
1770
- var MenuItem = forwardRef30(function MenuItem2({ icon, trailing, destructive, className, children, ...props }, ref) {
1771
- return /* @__PURE__ */ jsxs25(
1831
+ var MenuItem = forwardRef31(function MenuItem2({ icon, trailing, destructive, className, children, ...props }, ref) {
1832
+ return /* @__PURE__ */ jsxs26(
1772
1833
  RadixMenu.Item,
1773
1834
  {
1774
1835
  ref,
1775
1836
  className: cn(itemBase2, destructive ? "text-err" : "text-text", className),
1776
1837
  ...props,
1777
1838
  children: [
1778
- icon && /* @__PURE__ */ jsx31("span", { className: "w-[14px] text-[12px] opacity-70", children: icon }),
1779
- /* @__PURE__ */ jsx31("span", { className: "flex-1", children }),
1780
- trailing && /* @__PURE__ */ jsx31("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
1839
+ icon && /* @__PURE__ */ jsx32("span", { className: "w-[14px] text-[12px] opacity-70", children: icon }),
1840
+ /* @__PURE__ */ jsx32("span", { className: "flex-1", children }),
1841
+ trailing && /* @__PURE__ */ jsx32("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
1781
1842
  ]
1782
1843
  }
1783
1844
  );
1784
1845
  });
1785
1846
  MenuItem.displayName = "MenuItem";
1786
- var MenuCheckboxItem = forwardRef30(
1847
+ var MenuCheckboxItem = forwardRef31(
1787
1848
  function MenuCheckboxItem2({ className, children, ...props }, ref) {
1788
- return /* @__PURE__ */ jsxs25(
1849
+ return /* @__PURE__ */ jsxs26(
1789
1850
  RadixMenu.CheckboxItem,
1790
1851
  {
1791
1852
  ref,
1792
1853
  className: cn(itemBase2, "text-text relative pl-[26px]", className),
1793
1854
  ...props,
1794
1855
  children: [
1795
- /* @__PURE__ */ jsx31(RadixMenu.ItemIndicator, { className: "text-accent absolute top-1/2 left-2 -translate-y-1/2 text-[10px]", children: "\u2713" }),
1856
+ /* @__PURE__ */ jsx32(RadixMenu.ItemIndicator, { className: "text-accent absolute top-1/2 left-2 -translate-y-1/2 text-[10px]", children: "\u2713" }),
1796
1857
  children
1797
1858
  ]
1798
1859
  }
@@ -1800,9 +1861,9 @@ var MenuCheckboxItem = forwardRef30(
1800
1861
  }
1801
1862
  );
1802
1863
  MenuCheckboxItem.displayName = "MenuCheckboxItem";
1803
- var MenuSeparator = forwardRef30(
1864
+ var MenuSeparator = forwardRef31(
1804
1865
  function MenuSeparator2({ className, ...props }, ref) {
1805
- return /* @__PURE__ */ jsx31(
1866
+ return /* @__PURE__ */ jsx32(
1806
1867
  RadixMenu.Separator,
1807
1868
  {
1808
1869
  ref,
@@ -1817,14 +1878,14 @@ var DropdownMenu = RadixMenu.Root;
1817
1878
 
1818
1879
  // src/components/HoverCard/HoverCard.tsx
1819
1880
  import * as RadixHoverCard from "@radix-ui/react-hover-card";
1820
- import { forwardRef as forwardRef31 } from "react";
1821
- import { jsx as jsx32, jsxs as jsxs26 } from "react/jsx-runtime";
1881
+ import { forwardRef as forwardRef32 } from "react";
1882
+ import { jsx as jsx33, jsxs as jsxs27 } from "react/jsx-runtime";
1822
1883
  var HoverCardRoot = RadixHoverCard.Root;
1823
1884
  var HoverCardTrigger = RadixHoverCard.Trigger;
1824
1885
  var HoverCardPortal = RadixHoverCard.Portal;
1825
- var HoverCardContent = forwardRef31(
1886
+ var HoverCardContent = forwardRef32(
1826
1887
  function HoverCardContent2({ className, sideOffset = 4, ...props }, ref) {
1827
- return /* @__PURE__ */ jsx32(RadixHoverCard.Portal, { children: /* @__PURE__ */ jsx32(
1888
+ return /* @__PURE__ */ jsx33(RadixHoverCard.Portal, { children: /* @__PURE__ */ jsx33(
1828
1889
  RadixHoverCard.Content,
1829
1890
  {
1830
1891
  ref,
@@ -1841,25 +1902,25 @@ var HoverCardContent = forwardRef31(
1841
1902
  );
1842
1903
  HoverCardContent.displayName = "HoverCardContent";
1843
1904
  function HoverCard({ trigger, content, ...rootProps }) {
1844
- return /* @__PURE__ */ jsxs26(RadixHoverCard.Root, { openDelay: 200, closeDelay: 120, ...rootProps, children: [
1845
- /* @__PURE__ */ jsx32(RadixHoverCard.Trigger, { asChild: true, children: trigger }),
1846
- /* @__PURE__ */ jsx32(HoverCardContent, { children: content })
1905
+ return /* @__PURE__ */ jsxs27(RadixHoverCard.Root, { openDelay: 200, closeDelay: 120, ...rootProps, children: [
1906
+ /* @__PURE__ */ jsx33(RadixHoverCard.Trigger, { asChild: true, children: trigger }),
1907
+ /* @__PURE__ */ jsx33(HoverCardContent, { children: content })
1847
1908
  ] });
1848
1909
  }
1849
1910
 
1850
1911
  // src/components/Popover/Popover.tsx
1851
1912
  import * as RadixPopover from "@radix-ui/react-popover";
1852
- import { forwardRef as forwardRef32 } from "react";
1853
- import { jsx as jsx33 } from "react/jsx-runtime";
1913
+ import { forwardRef as forwardRef33 } from "react";
1914
+ import { jsx as jsx34 } from "react/jsx-runtime";
1854
1915
  var PopoverRoot = RadixPopover.Root;
1855
1916
  var PopoverTrigger = RadixPopover.Trigger;
1856
1917
  var PopoverAnchor = RadixPopover.Anchor;
1857
1918
  var PopoverPortal = RadixPopover.Portal;
1858
1919
  var PopoverClose = RadixPopover.Close;
1859
1920
  var PopoverArrow = RadixPopover.Arrow;
1860
- var PopoverContent = forwardRef32(
1921
+ var PopoverContent = forwardRef33(
1861
1922
  function PopoverContent2({ className, align = "start", sideOffset = 6, ...props }, ref) {
1862
- return /* @__PURE__ */ jsx33(RadixPopover.Portal, { children: /* @__PURE__ */ jsx33(
1923
+ return /* @__PURE__ */ jsx34(RadixPopover.Portal, { children: /* @__PURE__ */ jsx34(
1863
1924
  RadixPopover.Content,
1864
1925
  {
1865
1926
  ref,
@@ -1882,13 +1943,13 @@ var Popover = RadixPopover.Root;
1882
1943
  import * as RadixToast from "@radix-ui/react-toast";
1883
1944
  import {
1884
1945
  createContext,
1885
- forwardRef as forwardRef33,
1946
+ forwardRef as forwardRef34,
1886
1947
  useCallback as useCallback6,
1887
1948
  useContext,
1888
1949
  useMemo,
1889
1950
  useState as useState7
1890
1951
  } from "react";
1891
- import { jsx as jsx34, jsxs as jsxs27 } from "react/jsx-runtime";
1952
+ import { jsx as jsx35, jsxs as jsxs28 } from "react/jsx-runtime";
1892
1953
  var ToastContext = createContext(null);
1893
1954
  var variantIcon = {
1894
1955
  default: "\u25CF",
@@ -1931,10 +1992,10 @@ function ToastProvider({ children }) {
1931
1992
  setToasts((prev) => prev.filter((t) => t.id !== id));
1932
1993
  }, []);
1933
1994
  const value = useMemo(() => ({ toast, dismiss }), [toast, dismiss]);
1934
- return /* @__PURE__ */ jsx34(ToastContext.Provider, { value, children: /* @__PURE__ */ jsxs27(RadixToast.Provider, { swipeDirection: "right", children: [
1995
+ return /* @__PURE__ */ jsx35(ToastContext.Provider, { value, children: /* @__PURE__ */ jsxs28(RadixToast.Provider, { swipeDirection: "right", children: [
1935
1996
  children,
1936
- toasts.map((t) => /* @__PURE__ */ jsx34(ToastCard, { toast: t, onDismiss: () => dismiss(t.id) }, t.id)),
1937
- /* @__PURE__ */ jsx34(RadixToast.Viewport, { className: "z-toast fixed right-5 bottom-5 flex w-[380px] max-w-[calc(100vw-40px)] flex-col gap-2 outline-none" })
1997
+ toasts.map((t) => /* @__PURE__ */ jsx35(ToastCard, { toast: t, onDismiss: () => dismiss(t.id) }, t.id)),
1998
+ /* @__PURE__ */ jsx35(RadixToast.Viewport, { className: "z-toast fixed right-5 bottom-5 flex w-[380px] max-w-[calc(100vw-40px)] flex-col gap-2 outline-none" })
1938
1999
  ] }) });
1939
2000
  }
1940
2001
  function useToast() {
@@ -1942,9 +2003,9 @@ function useToast() {
1942
2003
  if (!ctx) throw new Error("useToast must be inside <ToastProvider>");
1943
2004
  return ctx;
1944
2005
  }
1945
- var ToastCard = forwardRef33(function ToastCard2({ toast, onDismiss }, ref) {
2006
+ var ToastCard = forwardRef34(function ToastCard2({ toast, onDismiss }, ref) {
1946
2007
  const variant = toast.variant ?? "default";
1947
- return /* @__PURE__ */ jsxs27(
2008
+ return /* @__PURE__ */ jsxs28(
1948
2009
  RadixToast.Root,
1949
2010
  {
1950
2011
  ref,
@@ -1959,13 +2020,13 @@ var ToastCard = forwardRef33(function ToastCard2({ toast, onDismiss }, ref) {
1959
2020
  variantBorderLeft[variant]
1960
2021
  ),
1961
2022
  children: [
1962
- /* @__PURE__ */ jsx34("span", { className: cn("mt-px text-[14px] leading-none", variantTextColor[variant]), children: variantIcon[variant] }),
1963
- /* @__PURE__ */ jsxs27("div", { className: "min-w-0 flex-1", children: [
1964
- /* @__PURE__ */ jsx34(RadixToast.Title, { className: "text-text text-[13px] font-medium", children: toast.title }),
1965
- toast.description && /* @__PURE__ */ jsx34(RadixToast.Description, { className: "text-text-muted mt-[2px] text-[12px] leading-[1.5]", children: toast.description }),
1966
- toast.action && /* @__PURE__ */ jsx34("div", { className: "mt-2", children: toast.action })
2023
+ /* @__PURE__ */ jsx35("span", { className: cn("mt-px text-[14px] leading-none", variantTextColor[variant]), children: variantIcon[variant] }),
2024
+ /* @__PURE__ */ jsxs28("div", { className: "min-w-0 flex-1", children: [
2025
+ /* @__PURE__ */ jsx35(RadixToast.Title, { className: "text-text text-[13px] font-medium", children: toast.title }),
2026
+ toast.description && /* @__PURE__ */ jsx35(RadixToast.Description, { className: "text-text-muted mt-[2px] text-[12px] leading-[1.5]", children: toast.description }),
2027
+ toast.action && /* @__PURE__ */ jsx35("div", { className: "mt-2", children: toast.action })
1967
2028
  ] }),
1968
- /* @__PURE__ */ jsx34(
2029
+ /* @__PURE__ */ jsx35(
1969
2030
  RadixToast.Close,
1970
2031
  {
1971
2032
  "aria-label": "Dismiss",
@@ -1981,16 +2042,16 @@ ToastCard.displayName = "ToastCard";
1981
2042
 
1982
2043
  // src/components/Tooltip/Tooltip.tsx
1983
2044
  import * as RadixTooltip from "@radix-ui/react-tooltip";
1984
- import { forwardRef as forwardRef34 } from "react";
1985
- import { jsx as jsx35, jsxs as jsxs28 } from "react/jsx-runtime";
2045
+ import { forwardRef as forwardRef35 } from "react";
2046
+ import { jsx as jsx36, jsxs as jsxs29 } from "react/jsx-runtime";
1986
2047
  var TooltipProvider = RadixTooltip.Provider;
1987
2048
  var TooltipRoot = RadixTooltip.Root;
1988
2049
  var TooltipTrigger = RadixTooltip.Trigger;
1989
2050
  var TooltipPortal = RadixTooltip.Portal;
1990
2051
  var TooltipArrow = RadixTooltip.Arrow;
1991
- var TooltipContent = forwardRef34(
2052
+ var TooltipContent = forwardRef35(
1992
2053
  function TooltipContent2({ className, sideOffset = 6, ...props }, ref) {
1993
- return /* @__PURE__ */ jsx35(RadixTooltip.Portal, { children: /* @__PURE__ */ jsx35(
2054
+ return /* @__PURE__ */ jsx36(RadixTooltip.Portal, { children: /* @__PURE__ */ jsx36(
1994
2055
  RadixTooltip.Content,
1995
2056
  {
1996
2057
  ref,
@@ -2008,16 +2069,16 @@ var TooltipContent = forwardRef34(
2008
2069
  );
2009
2070
  TooltipContent.displayName = "TooltipContent";
2010
2071
  function Tooltip({ content, children, side = "top", delayDuration = 400 }) {
2011
- return /* @__PURE__ */ jsx35(TooltipProvider, { delayDuration, children: /* @__PURE__ */ jsxs28(TooltipRoot, { children: [
2012
- /* @__PURE__ */ jsx35(TooltipTrigger, { asChild: true, children }),
2013
- /* @__PURE__ */ jsx35(TooltipContent, { side, children: content })
2072
+ return /* @__PURE__ */ jsx36(TooltipProvider, { delayDuration, children: /* @__PURE__ */ jsxs29(TooltipRoot, { children: [
2073
+ /* @__PURE__ */ jsx36(TooltipTrigger, { asChild: true, children }),
2074
+ /* @__PURE__ */ jsx36(TooltipContent, { side, children: content })
2014
2075
  ] }) });
2015
2076
  }
2016
2077
 
2017
2078
  // src/patterns/Alert/Alert.tsx
2018
2079
  import { cva as cva8 } from "class-variance-authority";
2019
- import { forwardRef as forwardRef35 } from "react";
2020
- import { jsx as jsx36, jsxs as jsxs29 } from "react/jsx-runtime";
2080
+ import { forwardRef as forwardRef36 } from "react";
2081
+ import { jsx as jsx37, jsxs as jsxs30 } from "react/jsx-runtime";
2021
2082
  var alertStyles = cva8("flex items-start gap-3 rounded-base border bg-panel p-3 text-[13px]", {
2022
2083
  variants: {
2023
2084
  tone: {
@@ -2041,7 +2102,7 @@ var defaultGlyph = {
2041
2102
  warn: "!",
2042
2103
  err: "\xD7"
2043
2104
  };
2044
- var Alert = forwardRef35(function Alert2({
2105
+ var Alert = forwardRef36(function Alert2({
2045
2106
  tone = "accent",
2046
2107
  title,
2047
2108
  description,
@@ -2053,7 +2114,7 @@ var Alert = forwardRef35(function Alert2({
2053
2114
  ...props
2054
2115
  }, ref) {
2055
2116
  const t = tone ?? "accent";
2056
- return /* @__PURE__ */ jsxs29(
2117
+ return /* @__PURE__ */ jsxs30(
2057
2118
  "div",
2058
2119
  {
2059
2120
  ref,
@@ -2062,13 +2123,13 @@ var Alert = forwardRef35(function Alert2({
2062
2123
  className: cn(alertStyles({ tone }), className),
2063
2124
  ...props,
2064
2125
  children: [
2065
- /* @__PURE__ */ jsx36("span", { "aria-hidden": true, className: cn("mt-[1px] text-[14px] leading-none", iconColorClass[t]), children: icon ?? defaultGlyph[t] }),
2066
- /* @__PURE__ */ jsxs29("div", { className: "min-w-0 flex-1", children: [
2067
- title && /* @__PURE__ */ jsx36("div", { className: "font-medium", children: title }),
2068
- description && /* @__PURE__ */ jsx36("div", { className: "text-text-muted mt-[2px] text-[12px]", children: description }),
2126
+ /* @__PURE__ */ jsx37("span", { "aria-hidden": true, className: cn("mt-[1px] text-[14px] leading-none", iconColorClass[t]), children: icon ?? defaultGlyph[t] }),
2127
+ /* @__PURE__ */ jsxs30("div", { className: "min-w-0 flex-1", children: [
2128
+ title && /* @__PURE__ */ jsx37("div", { className: "font-medium", children: title }),
2129
+ description && /* @__PURE__ */ jsx37("div", { className: "text-text-muted mt-[2px] text-[12px]", children: description }),
2069
2130
  children
2070
2131
  ] }),
2071
- action && /* @__PURE__ */ jsx36("div", { className: "ml-1 shrink-0", children: action })
2132
+ action && /* @__PURE__ */ jsx37("div", { className: "ml-1 shrink-0", children: action })
2072
2133
  ]
2073
2134
  }
2074
2135
  );
@@ -2077,8 +2138,8 @@ Alert.displayName = "Alert";
2077
2138
 
2078
2139
  // src/patterns/Banner/Banner.tsx
2079
2140
  import { cva as cva9 } from "class-variance-authority";
2080
- import { forwardRef as forwardRef36 } from "react";
2081
- import { jsx as jsx37, jsxs as jsxs30 } from "react/jsx-runtime";
2141
+ import { forwardRef as forwardRef37 } from "react";
2142
+ import { jsx as jsx38, jsxs as jsxs31 } from "react/jsx-runtime";
2082
2143
  var bannerStyles = cva9(
2083
2144
  "flex items-center gap-3 border-b border-border px-[14px] py-2 text-[12px]",
2084
2145
  {
@@ -2103,9 +2164,9 @@ var defaultGlyph2 = {
2103
2164
  warn: "!",
2104
2165
  err: "\xD7"
2105
2166
  };
2106
- var Banner = forwardRef36(function Banner2({ tone = "accent", sticky, icon, action, live = "polite", className, children, ...props }, ref) {
2167
+ var Banner = forwardRef37(function Banner2({ tone = "accent", sticky, icon, action, live = "polite", className, children, ...props }, ref) {
2107
2168
  const t = tone ?? "accent";
2108
- return /* @__PURE__ */ jsxs30(
2169
+ return /* @__PURE__ */ jsxs31(
2109
2170
  "div",
2110
2171
  {
2111
2172
  ref,
@@ -2114,9 +2175,9 @@ var Banner = forwardRef36(function Banner2({ tone = "accent", sticky, icon, acti
2114
2175
  className: cn(bannerStyles({ tone, sticky }), className),
2115
2176
  ...props,
2116
2177
  children: [
2117
- /* @__PURE__ */ jsx37("span", { "aria-hidden": true, className: "leading-none", children: icon ?? defaultGlyph2[t] }),
2118
- /* @__PURE__ */ jsx37("div", { className: "min-w-0 flex-1", children }),
2119
- action && /* @__PURE__ */ jsx37("div", { className: "ml-auto", children: action })
2178
+ /* @__PURE__ */ jsx38("span", { "aria-hidden": true, className: "leading-none", children: icon ?? defaultGlyph2[t] }),
2179
+ /* @__PURE__ */ jsx38("div", { className: "min-w-0 flex-1", children }),
2180
+ action && /* @__PURE__ */ jsx38("div", { className: "ml-auto", children: action })
2120
2181
  ]
2121
2182
  }
2122
2183
  );
@@ -2126,30 +2187,30 @@ Banner.displayName = "Banner";
2126
2187
  // src/patterns/Breadcrumbs/Breadcrumbs.tsx
2127
2188
  import {
2128
2189
  Children as Children2,
2129
- forwardRef as forwardRef37,
2190
+ forwardRef as forwardRef38,
2130
2191
  isValidElement as isValidElement2
2131
2192
  } from "react";
2132
- import { jsx as jsx38, jsxs as jsxs31 } from "react/jsx-runtime";
2133
- var Breadcrumbs = forwardRef37(function Breadcrumbs2({ separator = "/", className, children, ...props }, ref) {
2193
+ import { jsx as jsx39, jsxs as jsxs32 } from "react/jsx-runtime";
2194
+ var Breadcrumbs = forwardRef38(function Breadcrumbs2({ separator = "/", className, children, ...props }, ref) {
2134
2195
  const crumbs = Children2.toArray(children).filter(isValidElement2);
2135
2196
  const last = crumbs.length - 1;
2136
- return /* @__PURE__ */ jsx38("nav", { ref, "aria-label": "Breadcrumb", className: cn("text-[13px]", className), ...props, children: /* @__PURE__ */ jsx38("ol", { className: "text-text-muted flex flex-wrap items-center gap-[6px]", children: crumbs.map((crumb, i) => {
2197
+ return /* @__PURE__ */ jsx39("nav", { ref, "aria-label": "Breadcrumb", className: cn("text-[13px]", className), ...props, children: /* @__PURE__ */ jsx39("ol", { className: "text-text-muted flex flex-wrap items-center gap-[6px]", children: crumbs.map((crumb, i) => {
2137
2198
  const isCurrent = i === last;
2138
- return /* @__PURE__ */ jsxs31("li", { className: "inline-flex items-center gap-[6px]", children: [
2139
- isCurrent ? /* @__PURE__ */ jsx38(Crumb, { ...crumb.props, current: true }) : crumb,
2140
- !isCurrent && /* @__PURE__ */ jsx38("span", { "aria-hidden": true, className: "text-text-dim", children: separator })
2199
+ return /* @__PURE__ */ jsxs32("li", { className: "inline-flex items-center gap-[6px]", children: [
2200
+ isCurrent ? /* @__PURE__ */ jsx39(Crumb, { ...crumb.props, current: true }) : crumb,
2201
+ !isCurrent && /* @__PURE__ */ jsx39("span", { "aria-hidden": true, className: "text-text-dim", children: separator })
2141
2202
  ] }, i);
2142
2203
  }) }) });
2143
2204
  });
2144
2205
  Breadcrumbs.displayName = "Breadcrumbs";
2145
- var Crumb = forwardRef37(function Crumb2({ current, className, href, children, ...props }, ref) {
2206
+ var Crumb = forwardRef38(function Crumb2({ current, className, href, children, ...props }, ref) {
2146
2207
  if (current) {
2147
- return /* @__PURE__ */ jsx38("span", { "aria-current": "page", className: cn("text-text", className), children });
2208
+ return /* @__PURE__ */ jsx39("span", { "aria-current": "page", className: cn("text-text", className), children });
2148
2209
  }
2149
2210
  if (href === void 0) {
2150
- return /* @__PURE__ */ jsx38("span", { className: cn("text-text-dim", className), children });
2211
+ return /* @__PURE__ */ jsx39("span", { className: cn("text-text-dim", className), children });
2151
2212
  }
2152
- return /* @__PURE__ */ jsx38(
2213
+ return /* @__PURE__ */ jsx39(
2153
2214
  "a",
2154
2215
  {
2155
2216
  ref,
@@ -2164,14 +2225,14 @@ Crumb.displayName = "Crumb";
2164
2225
 
2165
2226
  // src/patterns/Combobox/Combobox.tsx
2166
2227
  import {
2167
- forwardRef as forwardRef38,
2228
+ forwardRef as forwardRef39,
2168
2229
  useEffect as useEffect5,
2169
2230
  useId as useId6,
2170
2231
  useMemo as useMemo2,
2171
2232
  useRef as useRef4,
2172
2233
  useState as useState8
2173
2234
  } from "react";
2174
- import { jsx as jsx39, jsxs as jsxs32 } from "react/jsx-runtime";
2235
+ import { jsx as jsx40, jsxs as jsxs33 } from "react/jsx-runtime";
2175
2236
  function normalize(option) {
2176
2237
  if (typeof option === "string") {
2177
2238
  return { value: option, label: option, searchText: option.toLowerCase() };
@@ -2187,7 +2248,7 @@ function normalize(option) {
2187
2248
  };
2188
2249
  }
2189
2250
  var defaultFilter = (option, query) => option.searchText.includes(query.toLowerCase());
2190
- var Combobox = forwardRef38(function Combobox2({
2251
+ var Combobox = forwardRef39(function Combobox2({
2191
2252
  options,
2192
2253
  value: valueProp,
2193
2254
  defaultValue,
@@ -2264,8 +2325,8 @@ var Combobox = forwardRef38(function Combobox2({
2264
2325
  setOpen(false);
2265
2326
  }
2266
2327
  };
2267
- return /* @__PURE__ */ jsxs32("div", { ref: wrapperRef, className: "relative", style: { width }, children: [
2268
- /* @__PURE__ */ jsx39(
2328
+ return /* @__PURE__ */ jsxs33("div", { ref: wrapperRef, className: "relative", style: { width }, children: [
2329
+ /* @__PURE__ */ jsx40(
2269
2330
  "input",
2270
2331
  {
2271
2332
  ref,
@@ -2299,7 +2360,7 @@ var Combobox = forwardRef38(function Combobox2({
2299
2360
  )
2300
2361
  }
2301
2362
  ),
2302
- open && /* @__PURE__ */ jsx39(
2363
+ open && /* @__PURE__ */ jsx40(
2303
2364
  "ul",
2304
2365
  {
2305
2366
  id: listboxId,
@@ -2309,9 +2370,9 @@ var Combobox = forwardRef38(function Combobox2({
2309
2370
  "z-dropdown absolute top-full right-0 left-0 mt-1 max-h-[220px] overflow-auto",
2310
2371
  "border-border bg-panel rounded-md border p-1 shadow-lg"
2311
2372
  ),
2312
- children: filtered.length === 0 ? /* @__PURE__ */ jsx39("li", { className: "text-text-dim px-2 py-3 text-center text-[12px]", role: "presentation", children: emptyState ?? "No matches" }) : filtered.map((option, i) => {
2373
+ children: filtered.length === 0 ? /* @__PURE__ */ jsx40("li", { className: "text-text-dim px-2 py-3 text-center text-[12px]", role: "presentation", children: emptyState ?? "No matches" }) : filtered.map((option, i) => {
2313
2374
  const isActive = i === cursor;
2314
- return /* @__PURE__ */ jsxs32(
2375
+ return /* @__PURE__ */ jsxs33(
2315
2376
  "li",
2316
2377
  {
2317
2378
  id: `${listboxId}-option-${i}`,
@@ -2329,8 +2390,8 @@ var Combobox = forwardRef38(function Combobox2({
2329
2390
  option.disabled && "pointer-events-none opacity-40"
2330
2391
  ),
2331
2392
  children: [
2332
- /* @__PURE__ */ jsx39("div", { children: option.label }),
2333
- option.description && /* @__PURE__ */ jsx39("div", { className: "text-text-dim text-[11px]", children: option.description })
2393
+ /* @__PURE__ */ jsx40("div", { children: option.label }),
2394
+ option.description && /* @__PURE__ */ jsx40("div", { className: "text-text-dim text-[11px]", children: option.description })
2334
2395
  ]
2335
2396
  },
2336
2397
  option.value
@@ -2338,19 +2399,19 @@ var Combobox = forwardRef38(function Combobox2({
2338
2399
  })
2339
2400
  }
2340
2401
  ),
2341
- name && /* @__PURE__ */ jsx39("input", { type: "hidden", name, value: value ?? "", readOnly: true })
2402
+ name && /* @__PURE__ */ jsx40("input", { type: "hidden", name, value: value ?? "", readOnly: true })
2342
2403
  ] });
2343
2404
  });
2344
2405
  Combobox.displayName = "Combobox";
2345
2406
 
2346
2407
  // src/patterns/CommandPalette/CommandPalette.tsx
2347
2408
  import * as RadixDialog4 from "@radix-ui/react-dialog";
2348
- import { forwardRef as forwardRef39, useEffect as useEffect6, useId as useId7, useMemo as useMemo3 } from "react";
2349
- import { Fragment, jsx as jsx40, jsxs as jsxs33 } from "react/jsx-runtime";
2409
+ import { forwardRef as forwardRef40, useEffect as useEffect6, useId as useId7, useMemo as useMemo3 } from "react";
2410
+ import { Fragment, jsx as jsx41, jsxs as jsxs34 } from "react/jsx-runtime";
2350
2411
  function flatItems(groups) {
2351
2412
  return groups.flatMap((g) => g.items);
2352
2413
  }
2353
- var CommandPalette = forwardRef39(
2414
+ var CommandPalette = forwardRef40(
2354
2415
  function CommandPalette2({
2355
2416
  open,
2356
2417
  onOpenChange,
@@ -2379,8 +2440,8 @@ var CommandPalette = forwardRef39(
2379
2440
  useEffect6(() => {
2380
2441
  setCursor(0);
2381
2442
  }, [query, groups, setCursor]);
2382
- return /* @__PURE__ */ jsx40(RadixDialog4.Root, { open, onOpenChange, children: /* @__PURE__ */ jsxs33(RadixDialog4.Portal, { children: [
2383
- /* @__PURE__ */ jsx40(
2443
+ return /* @__PURE__ */ jsx41(RadixDialog4.Root, { open, onOpenChange, children: /* @__PURE__ */ jsxs34(RadixDialog4.Portal, { children: [
2444
+ /* @__PURE__ */ jsx41(
2384
2445
  RadixDialog4.Overlay,
2385
2446
  {
2386
2447
  className: cn(
@@ -2389,7 +2450,7 @@ var CommandPalette = forwardRef39(
2389
2450
  )
2390
2451
  }
2391
2452
  ),
2392
- /* @__PURE__ */ jsxs33(
2453
+ /* @__PURE__ */ jsxs34(
2393
2454
  RadixDialog4.Content,
2394
2455
  {
2395
2456
  ref,
@@ -2403,10 +2464,10 @@ var CommandPalette = forwardRef39(
2403
2464
  ),
2404
2465
  onKeyDown,
2405
2466
  children: [
2406
- /* @__PURE__ */ jsx40(RadixDialog4.Title, { className: "sr-only", children: "Command palette" }),
2407
- /* @__PURE__ */ jsxs33("div", { className: "border-border flex items-center gap-[10px] border-b px-4 py-[14px]", children: [
2408
- /* @__PURE__ */ jsx40("span", { "aria-hidden": true, className: "text-text-dim", children: "\u2315" }),
2409
- /* @__PURE__ */ jsx40(
2467
+ /* @__PURE__ */ jsx41(RadixDialog4.Title, { className: "sr-only", children: "Command palette" }),
2468
+ /* @__PURE__ */ jsxs34("div", { className: "border-border flex items-center gap-[10px] border-b px-4 py-[14px]", children: [
2469
+ /* @__PURE__ */ jsx41("span", { "aria-hidden": true, className: "text-text-dim", children: "\u2315" }),
2470
+ /* @__PURE__ */ jsx41(
2410
2471
  "input",
2411
2472
  {
2412
2473
  autoFocus: true,
@@ -2423,9 +2484,9 @@ var CommandPalette = forwardRef39(
2423
2484
  className: "text-text placeholder:text-text-dim flex-1 border-0 bg-transparent text-[14px] outline-none"
2424
2485
  }
2425
2486
  ),
2426
- /* @__PURE__ */ jsx40("span", { className: "border-border text-text-dim rounded-xs border px-[6px] py-[2px] font-mono text-[10px]", children: "ESC" })
2487
+ /* @__PURE__ */ jsx41("span", { className: "border-border text-text-dim rounded-xs border px-[6px] py-[2px] font-mono text-[10px]", children: "ESC" })
2427
2488
  ] }),
2428
- /* @__PURE__ */ jsx40("div", { id: listboxId, className: "min-h-[220px] p-2", role: "listbox", "aria-label": "Results", children: flat.length === 0 ? emptyState ?? /* @__PURE__ */ jsx40("div", { className: "text-text-dim px-3 py-5 text-center text-[12px]", children: "No matches" }) : /* @__PURE__ */ jsx40(
2489
+ /* @__PURE__ */ jsx41("div", { id: listboxId, className: "min-h-[220px] p-2", role: "listbox", "aria-label": "Results", children: flat.length === 0 ? emptyState ?? /* @__PURE__ */ jsx41("div", { className: "text-text-dim px-3 py-5 text-center text-[12px]", children: "No matches" }) : /* @__PURE__ */ jsx41(
2429
2490
  CommandGroups,
2430
2491
  {
2431
2492
  groups,
@@ -2435,7 +2496,7 @@ var CommandPalette = forwardRef39(
2435
2496
  optionId
2436
2497
  }
2437
2498
  ) }),
2438
- footer && /* @__PURE__ */ jsx40("div", { className: "border-border text-text-dim flex gap-4 border-t px-[14px] py-[10px] font-mono text-[10px]", children: footer })
2499
+ footer && /* @__PURE__ */ jsx41("div", { className: "border-border text-text-dim flex gap-4 border-t px-[14px] py-[10px] font-mono text-[10px]", children: footer })
2439
2500
  ]
2440
2501
  }
2441
2502
  )
@@ -2445,10 +2506,10 @@ var CommandPalette = forwardRef39(
2445
2506
  CommandPalette.displayName = "CommandPalette";
2446
2507
  function CommandGroups({ groups, cursor, setCursor, onSelect, optionId }) {
2447
2508
  let runningIndex = 0;
2448
- return /* @__PURE__ */ jsx40(Fragment, { children: groups.map((group, gIdx) => {
2509
+ return /* @__PURE__ */ jsx41(Fragment, { children: groups.map((group, gIdx) => {
2449
2510
  if (group.items.length === 0) return null;
2450
- return /* @__PURE__ */ jsxs33("div", { children: [
2451
- group.label && /* @__PURE__ */ jsxs33("div", { className: "text-text-dim px-2 pt-2 pb-1 font-mono text-[9px] tracking-[1.4px] uppercase", children: [
2511
+ return /* @__PURE__ */ jsxs34("div", { children: [
2512
+ group.label && /* @__PURE__ */ jsxs34("div", { className: "text-text-dim px-2 pt-2 pb-1 font-mono text-[9px] tracking-[1.4px] uppercase", children: [
2452
2513
  group.label,
2453
2514
  " \xB7 ",
2454
2515
  group.items.length
@@ -2456,7 +2517,7 @@ function CommandGroups({ groups, cursor, setCursor, onSelect, optionId }) {
2456
2517
  group.items.map((item) => {
2457
2518
  const myIndex = runningIndex++;
2458
2519
  const isActive = cursor === myIndex;
2459
- return /* @__PURE__ */ jsxs33(
2520
+ return /* @__PURE__ */ jsxs34(
2460
2521
  "button",
2461
2522
  {
2462
2523
  id: optionId(myIndex),
@@ -2470,7 +2531,7 @@ function CommandGroups({ groups, cursor, setCursor, onSelect, optionId }) {
2470
2531
  isActive ? "bg-accent-dim text-accent" : "text-text hover:bg-panel-2"
2471
2532
  ),
2472
2533
  children: [
2473
- item.glyph != null && /* @__PURE__ */ jsx40(
2534
+ item.glyph != null && /* @__PURE__ */ jsx41(
2474
2535
  "span",
2475
2536
  {
2476
2537
  "aria-hidden": true,
@@ -2481,11 +2542,11 @@ function CommandGroups({ groups, cursor, setCursor, onSelect, optionId }) {
2481
2542
  children: item.glyph
2482
2543
  }
2483
2544
  ),
2484
- /* @__PURE__ */ jsxs33("span", { className: "min-w-0 flex-1", children: [
2485
- /* @__PURE__ */ jsx40("span", { className: "block truncate text-[13px]", children: item.label }),
2486
- item.description && /* @__PURE__ */ jsx40("span", { className: "text-text-dim block truncate text-[11px]", children: item.description })
2545
+ /* @__PURE__ */ jsxs34("span", { className: "min-w-0 flex-1", children: [
2546
+ /* @__PURE__ */ jsx41("span", { className: "block truncate text-[13px]", children: item.label }),
2547
+ item.description && /* @__PURE__ */ jsx41("span", { className: "text-text-dim block truncate text-[11px]", children: item.description })
2487
2548
  ] }),
2488
- item.trailing && /* @__PURE__ */ jsx40("span", { className: "text-text-dim font-mono text-[10px]", children: item.trailing })
2549
+ item.trailing && /* @__PURE__ */ jsx41("span", { className: "text-text-dim font-mono text-[10px]", children: item.trailing })
2489
2550
  ]
2490
2551
  },
2491
2552
  item.id
@@ -2508,7 +2569,7 @@ function filterCommandItems(query, groups) {
2508
2569
 
2509
2570
  // src/patterns/DataTable/DataTable.tsx
2510
2571
  import { useEffect as useEffect7, useMemo as useMemo4, useRef as useRef5 } from "react";
2511
- import { jsx as jsx41, jsxs as jsxs34 } from "react/jsx-runtime";
2572
+ import { jsx as jsx42, jsxs as jsxs35 } from "react/jsx-runtime";
2512
2573
  var alignClass = {
2513
2574
  left: "text-left",
2514
2575
  right: "text-right",
@@ -2596,10 +2657,10 @@ function DataTable(props) {
2596
2657
  return next;
2597
2658
  });
2598
2659
  };
2599
- return /* @__PURE__ */ jsxs34("table", { ref, className: cn("w-full border-collapse text-[12px]", className), children: [
2600
- caption && /* @__PURE__ */ jsx41("caption", { className: "sr-only", children: caption }),
2601
- /* @__PURE__ */ jsx41("thead", { className: cn("bg-panel-2", stickyHeader && "z-raised sticky top-0"), children: /* @__PURE__ */ jsxs34("tr", { children: [
2602
- selectable && /* @__PURE__ */ jsx41("th", { scope: "col", className: "border-border w-8 border-b px-3 py-2 text-left", children: /* @__PURE__ */ jsx41(
2660
+ return /* @__PURE__ */ jsxs35("table", { ref, className: cn("w-full border-collapse text-[12px]", className), children: [
2661
+ caption && /* @__PURE__ */ jsx42("caption", { className: "sr-only", children: caption }),
2662
+ /* @__PURE__ */ jsx42("thead", { className: cn("bg-panel-2", stickyHeader && "z-raised sticky top-0"), children: /* @__PURE__ */ jsxs35("tr", { children: [
2663
+ selectable && /* @__PURE__ */ jsx42("th", { scope: "col", className: "border-border w-8 border-b px-3 py-2 text-left", children: /* @__PURE__ */ jsx42(
2603
2664
  "input",
2604
2665
  {
2605
2666
  ref: headerCheckRef,
@@ -2615,8 +2676,8 @@ function DataTable(props) {
2615
2676
  const isSorted = sort?.key === col.key;
2616
2677
  const ariaSort = !sortable ? void 0 : isSorted ? sort?.direction === "asc" ? "ascending" : "descending" : "none";
2617
2678
  const align = col.align ?? "left";
2618
- const indicator = sortable && isSorted && /* @__PURE__ */ jsx41("span", { "aria-hidden": true, className: "ml-1", children: sort?.direction === "asc" ? "\u2191" : "\u2193" });
2619
- return /* @__PURE__ */ jsx41(
2679
+ const indicator = sortable && isSorted && /* @__PURE__ */ jsx42("span", { "aria-hidden": true, className: "ml-1", children: sort?.direction === "asc" ? "\u2191" : "\u2193" });
2680
+ return /* @__PURE__ */ jsx42(
2620
2681
  "th",
2621
2682
  {
2622
2683
  scope: "col",
@@ -2628,7 +2689,7 @@ function DataTable(props) {
2628
2689
  sortable && "cursor-pointer",
2629
2690
  isSorted ? "text-accent" : "text-text-dim"
2630
2691
  ),
2631
- children: sortable ? /* @__PURE__ */ jsxs34(
2692
+ children: sortable ? /* @__PURE__ */ jsxs35(
2632
2693
  "button",
2633
2694
  {
2634
2695
  type: "button",
@@ -2645,8 +2706,8 @@ function DataTable(props) {
2645
2706
  );
2646
2707
  })
2647
2708
  ] }) }),
2648
- /* @__PURE__ */ jsxs34("tbody", { children: [
2649
- sortedData.length === 0 && /* @__PURE__ */ jsx41("tr", { children: /* @__PURE__ */ jsx41(
2709
+ /* @__PURE__ */ jsxs35("tbody", { children: [
2710
+ sortedData.length === 0 && /* @__PURE__ */ jsx42("tr", { children: /* @__PURE__ */ jsx42(
2650
2711
  "td",
2651
2712
  {
2652
2713
  colSpan: columns.length + (selectable ? 1 : 0),
@@ -2657,7 +2718,7 @@ function DataTable(props) {
2657
2718
  sortedData.map((row) => {
2658
2719
  const id = rowKey(row);
2659
2720
  const isSelected = selectedSet.has(id);
2660
- return /* @__PURE__ */ jsxs34(
2721
+ return /* @__PURE__ */ jsxs35(
2661
2722
  "tr",
2662
2723
  {
2663
2724
  "data-state": isSelected ? "selected" : void 0,
@@ -2666,7 +2727,7 @@ function DataTable(props) {
2666
2727
  isSelected ? "bg-accent-dim/50" : "hover:bg-panel-2"
2667
2728
  ),
2668
2729
  children: [
2669
- selectable && /* @__PURE__ */ jsx41("td", { className: "px-3 py-[10px]", children: /* @__PURE__ */ jsx41(
2730
+ selectable && /* @__PURE__ */ jsx42("td", { className: "px-3 py-[10px]", children: /* @__PURE__ */ jsx42(
2670
2731
  "input",
2671
2732
  {
2672
2733
  type: "checkbox",
@@ -2676,7 +2737,7 @@ function DataTable(props) {
2676
2737
  className: "cursor-pointer accent-[var(--color-accent)]"
2677
2738
  }
2678
2739
  ) }),
2679
- columns.map((col) => /* @__PURE__ */ jsx41("td", { className: cn("px-3 py-[10px]", alignClass[col.align ?? "left"]), children: col.cell ? col.cell(row) : col.accessor ? String(col.accessor(row)) : null }, col.key))
2740
+ columns.map((col) => /* @__PURE__ */ jsx42("td", { className: cn("px-3 py-[10px]", alignClass[col.align ?? "left"]), children: col.cell ? col.cell(row) : col.accessor ? String(col.accessor(row)) : null }, col.key))
2680
2741
  ]
2681
2742
  },
2682
2743
  id
@@ -2688,13 +2749,13 @@ function DataTable(props) {
2688
2749
 
2689
2750
  // src/patterns/DatePicker/Calendar.tsx
2690
2751
  import {
2691
- forwardRef as forwardRef40,
2752
+ forwardRef as forwardRef41,
2692
2753
  useCallback as useCallback7,
2693
2754
  useEffect as useEffect8,
2694
2755
  useRef as useRef6,
2695
2756
  useState as useState9
2696
2757
  } from "react";
2697
- import { jsx as jsx42, jsxs as jsxs35 } from "react/jsx-runtime";
2758
+ import { jsx as jsx43, jsxs as jsxs36 } from "react/jsx-runtime";
2698
2759
  var MONTHS = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
2699
2760
  var DAYS = ["S", "M", "T", "W", "T", "F", "S"];
2700
2761
  function isSameDay(a, b) {
@@ -2705,7 +2766,7 @@ function clampDay(year, month, day) {
2705
2766
  const max = new Date(year, month + 1, 0).getDate();
2706
2767
  return Math.min(Math.max(1, day), max);
2707
2768
  }
2708
- var Calendar = forwardRef40(function Calendar2({
2769
+ var Calendar = forwardRef41(function Calendar2({
2709
2770
  value,
2710
2771
  defaultValue,
2711
2772
  onValueChange,
@@ -2836,7 +2897,7 @@ var Calendar = forwardRef40(function Calendar2({
2836
2897
  },
2837
2898
  [month, year, moveFocus]
2838
2899
  );
2839
- return /* @__PURE__ */ jsxs35(
2900
+ return /* @__PURE__ */ jsxs36(
2840
2901
  "div",
2841
2902
  {
2842
2903
  ref,
@@ -2848,14 +2909,14 @@ var Calendar = forwardRef40(function Calendar2({
2848
2909
  ),
2849
2910
  ...props,
2850
2911
  children: [
2851
- /* @__PURE__ */ jsxs35("div", { className: "mb-3 flex items-center justify-between", children: [
2852
- /* @__PURE__ */ jsxs35("span", { className: "text-[13px] font-medium", "aria-live": "polite", children: [
2912
+ /* @__PURE__ */ jsxs36("div", { className: "mb-3 flex items-center justify-between", children: [
2913
+ /* @__PURE__ */ jsxs36("span", { className: "text-[13px] font-medium", "aria-live": "polite", children: [
2853
2914
  MONTHS[month],
2854
2915
  " ",
2855
2916
  year
2856
2917
  ] }),
2857
- /* @__PURE__ */ jsxs35("div", { className: "flex gap-1", children: [
2858
- /* @__PURE__ */ jsx42(
2918
+ /* @__PURE__ */ jsxs36("div", { className: "flex gap-1", children: [
2919
+ /* @__PURE__ */ jsx43(
2859
2920
  IconButton,
2860
2921
  {
2861
2922
  size: "sm",
@@ -2865,11 +2926,11 @@ var Calendar = forwardRef40(function Calendar2({
2865
2926
  onClick: goPrev
2866
2927
  }
2867
2928
  ),
2868
- /* @__PURE__ */ jsx42(IconButton, { size: "sm", variant: "ghost", icon: "\u203A", "aria-label": "Next month", onClick: goNext })
2929
+ /* @__PURE__ */ jsx43(IconButton, { size: "sm", variant: "ghost", icon: "\u203A", "aria-label": "Next month", onClick: goNext })
2869
2930
  ] })
2870
2931
  ] }),
2871
- /* @__PURE__ */ jsxs35("div", { role: "grid", "aria-label": `${MONTHS[month]} ${year}`, className: "flex flex-col gap-[2px]", children: [
2872
- /* @__PURE__ */ jsx42("div", { role: "row", className: "grid grid-cols-7 gap-[2px]", children: DAYS.map((d, i) => /* @__PURE__ */ jsx42(
2932
+ /* @__PURE__ */ jsxs36("div", { role: "grid", "aria-label": `${MONTHS[month]} ${year}`, className: "flex flex-col gap-[2px]", children: [
2933
+ /* @__PURE__ */ jsx43("div", { role: "row", className: "grid grid-cols-7 gap-[2px]", children: DAYS.map((d, i) => /* @__PURE__ */ jsx43(
2873
2934
  "div",
2874
2935
  {
2875
2936
  role: "columnheader",
@@ -2889,7 +2950,7 @@ var Calendar = forwardRef40(function Calendar2({
2889
2950
  const cellIndex = r * 7 + c;
2890
2951
  const dayNum = cellIndex - firstDayOfMonth + 1;
2891
2952
  if (dayNum < 1 || dayNum > daysInMonth) {
2892
- cells.push(/* @__PURE__ */ jsx42("div", { role: "gridcell", "aria-hidden": true }, `pad-${r}-${c}`));
2953
+ cells.push(/* @__PURE__ */ jsx43("div", { role: "gridcell", "aria-hidden": true }, `pad-${r}-${c}`));
2893
2954
  continue;
2894
2955
  }
2895
2956
  const date = new Date(year, month, dayNum);
@@ -2899,7 +2960,7 @@ var Calendar = forwardRef40(function Calendar2({
2899
2960
  const isFocused = dayNum === effectiveFocusDay;
2900
2961
  const day = dayNum;
2901
2962
  cells.push(
2902
- /* @__PURE__ */ jsx42("div", { role: "gridcell", "aria-selected": isSelected, children: /* @__PURE__ */ jsx42(
2963
+ /* @__PURE__ */ jsx43("div", { role: "gridcell", "aria-selected": isSelected, children: /* @__PURE__ */ jsx43(
2903
2964
  "button",
2904
2965
  {
2905
2966
  ref: (node) => {
@@ -2930,7 +2991,7 @@ var Calendar = forwardRef40(function Calendar2({
2930
2991
  );
2931
2992
  }
2932
2993
  rows.push(
2933
- /* @__PURE__ */ jsx42("div", { role: "row", className: "grid grid-cols-7 gap-[2px]", children: cells }, `row-${r}`)
2994
+ /* @__PURE__ */ jsx43("div", { role: "row", className: "grid grid-cols-7 gap-[2px]", children: cells }, `row-${r}`)
2934
2995
  );
2935
2996
  }
2936
2997
  return rows;
@@ -2944,10 +3005,10 @@ Calendar.displayName = "Calendar";
2944
3005
 
2945
3006
  // src/patterns/DatePicker/DatePicker.tsx
2946
3007
  import * as RadixPopover2 from "@radix-ui/react-popover";
2947
- import { forwardRef as forwardRef41, useState as useState10 } from "react";
2948
- import { jsx as jsx43, jsxs as jsxs36 } from "react/jsx-runtime";
3008
+ import { forwardRef as forwardRef42, useState as useState10 } from "react";
3009
+ import { jsx as jsx44, jsxs as jsxs37 } from "react/jsx-runtime";
2949
3010
  var defaultFormat = (d) => d.toLocaleDateString();
2950
- var DatePicker = forwardRef41(function DatePicker2({
3011
+ var DatePicker = forwardRef42(function DatePicker2({
2951
3012
  value: valueProp,
2952
3013
  defaultValue,
2953
3014
  onValueChange,
@@ -2967,8 +3028,8 @@ var DatePicker = forwardRef41(function DatePicker2({
2967
3028
  defaultValue,
2968
3029
  onChange: onValueChange
2969
3030
  });
2970
- return /* @__PURE__ */ jsxs36(RadixPopover2.Root, { open, onOpenChange: setOpen, children: [
2971
- /* @__PURE__ */ jsx43(RadixPopover2.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs36(
3031
+ return /* @__PURE__ */ jsxs37(RadixPopover2.Root, { open, onOpenChange: setOpen, children: [
3032
+ /* @__PURE__ */ jsx44(RadixPopover2.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs37(
2972
3033
  "button",
2973
3034
  {
2974
3035
  ref,
@@ -2985,18 +3046,18 @@ var DatePicker = forwardRef41(function DatePicker2({
2985
3046
  ),
2986
3047
  style: { width },
2987
3048
  children: [
2988
- /* @__PURE__ */ jsx43("span", { "aria-hidden": true, className: "text-text-dim", children: "\u25A2" }),
2989
- /* @__PURE__ */ jsx43("span", { className: cn("flex-1 truncate", !value && "text-text-dim"), children: value ? format(value) : emptyLabel ?? placeholder })
3049
+ /* @__PURE__ */ jsx44("span", { "aria-hidden": true, className: "text-text-dim", children: "\u25A2" }),
3050
+ /* @__PURE__ */ jsx44("span", { className: cn("flex-1 truncate", !value && "text-text-dim"), children: value ? format(value) : emptyLabel ?? placeholder })
2990
3051
  ]
2991
3052
  }
2992
3053
  ) }),
2993
- /* @__PURE__ */ jsx43(RadixPopover2.Portal, { children: /* @__PURE__ */ jsx43(
3054
+ /* @__PURE__ */ jsx44(RadixPopover2.Portal, { children: /* @__PURE__ */ jsx44(
2994
3055
  RadixPopover2.Content,
2995
3056
  {
2996
3057
  align: "start",
2997
3058
  sideOffset: 6,
2998
3059
  className: "z-popover outline-none data-[state=open]:animate-[ship-pop-in_140ms_var(--easing-out)]",
2999
- children: /* @__PURE__ */ jsx43(
3060
+ children: /* @__PURE__ */ jsx44(
3000
3061
  Calendar,
3001
3062
  {
3002
3063
  value,
@@ -3011,17 +3072,17 @@ var DatePicker = forwardRef41(function DatePicker2({
3011
3072
  )
3012
3073
  }
3013
3074
  ) }),
3014
- name && /* @__PURE__ */ jsx43("input", { type: "hidden", name, value: value ? value.toISOString() : "", readOnly: true })
3075
+ name && /* @__PURE__ */ jsx44("input", { type: "hidden", name, value: value ? value.toISOString() : "", readOnly: true })
3015
3076
  ] });
3016
3077
  });
3017
3078
  DatePicker.displayName = "DatePicker";
3018
3079
 
3019
3080
  // src/patterns/Dots/Dots.tsx
3020
- import { forwardRef as forwardRef42 } from "react";
3021
- import { jsx as jsx44 } from "react/jsx-runtime";
3022
- var Dots = forwardRef42(function Dots2({ total, current, onChange, className, "aria-label": ariaLabel = "Progress", ...props }, ref) {
3081
+ import { forwardRef as forwardRef43 } from "react";
3082
+ import { jsx as jsx45 } from "react/jsx-runtime";
3083
+ var Dots = forwardRef43(function Dots2({ total, current, onChange, className, "aria-label": ariaLabel = "Progress", ...props }, ref) {
3023
3084
  const interactive = typeof onChange === "function";
3024
- return /* @__PURE__ */ jsx44(
3085
+ return /* @__PURE__ */ jsx45(
3025
3086
  "nav",
3026
3087
  {
3027
3088
  ref,
@@ -3035,7 +3096,7 @@ var Dots = forwardRef42(function Dots2({ total, current, onChange, className, "a
3035
3096
  isActive ? "w-[18px] bg-accent" : "w-[6px] bg-panel-2"
3036
3097
  );
3037
3098
  if (interactive) {
3038
- return /* @__PURE__ */ jsx44(
3099
+ return /* @__PURE__ */ jsx45(
3039
3100
  "button",
3040
3101
  {
3041
3102
  type: "button",
@@ -3052,7 +3113,7 @@ var Dots = forwardRef42(function Dots2({ total, current, onChange, className, "a
3052
3113
  i
3053
3114
  );
3054
3115
  }
3055
- return /* @__PURE__ */ jsx44("span", { "aria-hidden": true, className: sharedClass }, i);
3116
+ return /* @__PURE__ */ jsx45("span", { "aria-hidden": true, className: sharedClass }, i);
3056
3117
  })
3057
3118
  }
3058
3119
  );
@@ -3061,15 +3122,15 @@ Dots.displayName = "Dots";
3061
3122
 
3062
3123
  // src/patterns/Dropzone/Dropzone.tsx
3063
3124
  import {
3064
- forwardRef as forwardRef43,
3125
+ forwardRef as forwardRef44,
3065
3126
  useState as useState11
3066
3127
  } from "react";
3067
- import { jsx as jsx45, jsxs as jsxs37 } from "react/jsx-runtime";
3128
+ import { jsx as jsx46, jsxs as jsxs38 } from "react/jsx-runtime";
3068
3129
  function listToArray(list) {
3069
3130
  if (!list) return [];
3070
3131
  return Array.from(list);
3071
3132
  }
3072
- var Dropzone = forwardRef43(function Dropzone2({
3133
+ var Dropzone = forwardRef44(function Dropzone2({
3073
3134
  onFiles,
3074
3135
  accept,
3075
3136
  multiple = true,
@@ -3094,7 +3155,7 @@ var Dropzone = forwardRef43(function Dropzone2({
3094
3155
  const files = listToArray(e.dataTransfer.files);
3095
3156
  if (files.length) onFiles?.(files);
3096
3157
  };
3097
- return /* @__PURE__ */ jsxs37(
3158
+ return /* @__PURE__ */ jsxs38(
3098
3159
  "label",
3099
3160
  {
3100
3161
  ref,
@@ -3111,7 +3172,7 @@ var Dropzone = forwardRef43(function Dropzone2({
3111
3172
  ),
3112
3173
  ...props,
3113
3174
  children: [
3114
- /* @__PURE__ */ jsx45(
3175
+ /* @__PURE__ */ jsx46(
3115
3176
  "input",
3116
3177
  {
3117
3178
  type: "file",
@@ -3127,7 +3188,7 @@ var Dropzone = forwardRef43(function Dropzone2({
3127
3188
  }
3128
3189
  }
3129
3190
  ),
3130
- /* @__PURE__ */ jsx45(
3191
+ /* @__PURE__ */ jsx46(
3131
3192
  "div",
3132
3193
  {
3133
3194
  "aria-hidden": true,
@@ -3135,8 +3196,8 @@ var Dropzone = forwardRef43(function Dropzone2({
3135
3196
  children: icon
3136
3197
  }
3137
3198
  ),
3138
- /* @__PURE__ */ jsx45("div", { className: "mb-1 text-[13px] font-medium", children: title }),
3139
- description && /* @__PURE__ */ jsx45("div", { className: "text-text-dim text-[11px]", children: description })
3199
+ /* @__PURE__ */ jsx46("div", { className: "mb-1 text-[13px] font-medium", children: title }),
3200
+ description && /* @__PURE__ */ jsx46("div", { className: "text-text-dim text-[11px]", children: description })
3140
3201
  ]
3141
3202
  }
3142
3203
  );
@@ -3145,8 +3206,8 @@ Dropzone.displayName = "Dropzone";
3145
3206
 
3146
3207
  // src/patterns/EmptyState/EmptyState.tsx
3147
3208
  import { cva as cva10 } from "class-variance-authority";
3148
- import { forwardRef as forwardRef44 } from "react";
3149
- import { jsx as jsx46, jsxs as jsxs38 } from "react/jsx-runtime";
3209
+ import { forwardRef as forwardRef45 } from "react";
3210
+ import { jsx as jsx47, jsxs as jsxs39 } from "react/jsx-runtime";
3150
3211
  var plateStyles = cva10("grid h-12 w-12 place-items-center rounded-base text-[22px]", {
3151
3212
  variants: {
3152
3213
  tone: {
@@ -3159,8 +3220,8 @@ var plateStyles = cva10("grid h-12 w-12 place-items-center rounded-base text-[22
3159
3220
  },
3160
3221
  defaultVariants: { tone: "neutral" }
3161
3222
  });
3162
- var EmptyState = forwardRef44(function EmptyState2({ icon, title, description, action, chips, tone, className, ...props }, ref) {
3163
- return /* @__PURE__ */ jsxs38(
3223
+ var EmptyState = forwardRef45(function EmptyState2({ icon, title, description, action, chips, tone, className, ...props }, ref) {
3224
+ return /* @__PURE__ */ jsxs39(
3164
3225
  "div",
3165
3226
  {
3166
3227
  ref,
@@ -3170,10 +3231,10 @@ var EmptyState = forwardRef44(function EmptyState2({ icon, title, description, a
3170
3231
  ),
3171
3232
  ...props,
3172
3233
  children: [
3173
- icon != null && /* @__PURE__ */ jsx46("span", { "aria-hidden": true, className: plateStyles({ tone: tone ?? "neutral" }), children: icon }),
3174
- /* @__PURE__ */ jsx46("div", { className: "text-[14px] font-medium", children: title }),
3175
- description && /* @__PURE__ */ jsx46("div", { className: "text-text-muted max-w-[260px] text-[12px] leading-[1.5]", children: description }),
3176
- chips && chips.length > 0 && /* @__PURE__ */ jsx46("div", { className: "flex w-full flex-col gap-1", children: chips.map((c, i) => /* @__PURE__ */ jsx46(
3234
+ icon != null && /* @__PURE__ */ jsx47("span", { "aria-hidden": true, className: plateStyles({ tone: tone ?? "neutral" }), children: icon }),
3235
+ /* @__PURE__ */ jsx47("div", { className: "text-[14px] font-medium", children: title }),
3236
+ description && /* @__PURE__ */ jsx47("div", { className: "text-text-muted max-w-[260px] text-[12px] leading-[1.5]", children: description }),
3237
+ chips && chips.length > 0 && /* @__PURE__ */ jsx47("div", { className: "flex w-full flex-col gap-1", children: chips.map((c, i) => /* @__PURE__ */ jsx47(
3177
3238
  "button",
3178
3239
  {
3179
3240
  type: "button",
@@ -3195,18 +3256,18 @@ var EmptyState = forwardRef44(function EmptyState2({ icon, title, description, a
3195
3256
  EmptyState.displayName = "EmptyState";
3196
3257
 
3197
3258
  // src/patterns/FileChip/FileChip.tsx
3198
- import { forwardRef as forwardRef45 } from "react";
3199
- import { jsx as jsx47, jsxs as jsxs39 } from "react/jsx-runtime";
3259
+ import { forwardRef as forwardRef46 } from "react";
3260
+ import { jsx as jsx48, jsxs as jsxs40 } from "react/jsx-runtime";
3200
3261
  function deriveExt(name) {
3201
3262
  const dot = name.lastIndexOf(".");
3202
3263
  if (dot < 0) return "FILE";
3203
3264
  return name.slice(dot + 1).slice(0, 4).toUpperCase();
3204
3265
  }
3205
- var FileChip = forwardRef45(function FileChip2({ name, size, progress, icon, onRemove, failed, className, ...props }, ref) {
3266
+ var FileChip = forwardRef46(function FileChip2({ name, size, progress, icon, onRemove, failed, className, ...props }, ref) {
3206
3267
  const ext = deriveExt(name);
3207
3268
  const showProgress = typeof progress === "number";
3208
3269
  const isComplete = showProgress && progress >= 100;
3209
- return /* @__PURE__ */ jsxs39(
3270
+ return /* @__PURE__ */ jsxs40(
3210
3271
  "div",
3211
3272
  {
3212
3273
  ref,
@@ -3216,7 +3277,7 @@ var FileChip = forwardRef45(function FileChip2({ name, size, progress, icon, onR
3216
3277
  ),
3217
3278
  ...props,
3218
3279
  children: [
3219
- /* @__PURE__ */ jsx47(
3280
+ /* @__PURE__ */ jsx48(
3220
3281
  "span",
3221
3282
  {
3222
3283
  "aria-hidden": true,
@@ -3224,17 +3285,17 @@ var FileChip = forwardRef45(function FileChip2({ name, size, progress, icon, onR
3224
3285
  children: icon ?? ext
3225
3286
  }
3226
3287
  ),
3227
- /* @__PURE__ */ jsxs39("div", { className: "min-w-0 flex-1", children: [
3228
- /* @__PURE__ */ jsx47("div", { className: "truncate text-[12px] font-medium", children: name }),
3229
- /* @__PURE__ */ jsxs39("div", { className: cn("font-mono text-[10px]", failed ? "text-err" : "text-text-dim"), children: [
3288
+ /* @__PURE__ */ jsxs40("div", { className: "min-w-0 flex-1", children: [
3289
+ /* @__PURE__ */ jsx48("div", { className: "truncate text-[12px] font-medium", children: name }),
3290
+ /* @__PURE__ */ jsxs40("div", { className: cn("font-mono text-[10px]", failed ? "text-err" : "text-text-dim"), children: [
3230
3291
  size,
3231
- showProgress && !isComplete && /* @__PURE__ */ jsxs39("span", { children: [
3292
+ showProgress && !isComplete && /* @__PURE__ */ jsxs40("span", { children: [
3232
3293
  " \xB7 ",
3233
3294
  Math.round(progress),
3234
3295
  "%"
3235
3296
  ] })
3236
3297
  ] }),
3237
- showProgress && !isComplete && /* @__PURE__ */ jsx47("div", { className: "bg-panel mt-1 h-[2px] overflow-hidden rounded-full", children: /* @__PURE__ */ jsx47(
3298
+ showProgress && !isComplete && /* @__PURE__ */ jsx48("div", { className: "bg-panel mt-1 h-[2px] overflow-hidden rounded-full", children: /* @__PURE__ */ jsx48(
3238
3299
  "div",
3239
3300
  {
3240
3301
  className: cn(
@@ -3245,7 +3306,7 @@ var FileChip = forwardRef45(function FileChip2({ name, size, progress, icon, onR
3245
3306
  }
3246
3307
  ) })
3247
3308
  ] }),
3248
- onRemove && /* @__PURE__ */ jsx47(
3309
+ onRemove && /* @__PURE__ */ jsx48(
3249
3310
  "button",
3250
3311
  {
3251
3312
  type: "button",
@@ -3264,12 +3325,299 @@ var FileChip = forwardRef45(function FileChip2({ name, size, progress, icon, onR
3264
3325
  });
3265
3326
  FileChip.displayName = "FileChip";
3266
3327
 
3328
+ // src/patterns/FilterPanel/FilterPanel.tsx
3329
+ import { forwardRef as forwardRef47, useCallback as useCallback8, useState as useState12 } from "react";
3330
+ import { jsx as jsx49, jsxs as jsxs41 } from "react/jsx-runtime";
3331
+ var EMPTY = Object.freeze({});
3332
+ var FilterPanel = forwardRef47(function FilterPanel2({
3333
+ facets,
3334
+ value,
3335
+ defaultValue,
3336
+ onValueChange,
3337
+ onReset,
3338
+ counts,
3339
+ title = "Filter",
3340
+ resetLabel = "Reset",
3341
+ className,
3342
+ ...props
3343
+ }, ref) {
3344
+ const [selection, setSelection] = useControllableState({
3345
+ value,
3346
+ defaultValue: defaultValue ?? EMPTY,
3347
+ onChange: onValueChange
3348
+ });
3349
+ const total = facets.reduce((sum, facet) => sum + (selection[facet.id]?.length ?? 0), 0);
3350
+ const toggle = useCallback8(
3351
+ (facetId, optionValue, next) => {
3352
+ setSelection((prev) => {
3353
+ const current = prev?.[facetId] ?? [];
3354
+ const filtered = current.filter((v) => v !== optionValue);
3355
+ const updated = next ? [...filtered, optionValue] : filtered;
3356
+ return { ...prev ?? {}, [facetId]: updated };
3357
+ });
3358
+ },
3359
+ [setSelection]
3360
+ );
3361
+ const handleReset = useCallback8(() => {
3362
+ setSelection(EMPTY);
3363
+ onReset?.();
3364
+ }, [setSelection, onReset]);
3365
+ return /* @__PURE__ */ jsxs41(
3366
+ "div",
3367
+ {
3368
+ ref,
3369
+ role: "group",
3370
+ "aria-label": typeof title === "string" ? title : void 0,
3371
+ className: cn(
3372
+ "rounded-base border-border bg-panel flex w-[260px] flex-col gap-3 border p-4",
3373
+ className
3374
+ ),
3375
+ ...props,
3376
+ children: [
3377
+ /* @__PURE__ */ jsxs41("div", { className: "flex items-center gap-2", children: [
3378
+ /* @__PURE__ */ jsx49("span", { className: "text-text-dim font-mono text-[10px] tracking-[1.4px] uppercase", children: title }),
3379
+ total > 0 && /* @__PURE__ */ jsx49(Badge, { size: "sm", variant: "accent", children: total }),
3380
+ /* @__PURE__ */ jsx49(
3381
+ Button,
3382
+ {
3383
+ type: "button",
3384
+ variant: "ghost",
3385
+ size: "sm",
3386
+ onClick: handleReset,
3387
+ disabled: total === 0,
3388
+ className: "ml-auto",
3389
+ children: resetLabel
3390
+ }
3391
+ )
3392
+ ] }),
3393
+ facets.map((facet) => /* @__PURE__ */ jsx49(
3394
+ FilterFacetGroup,
3395
+ {
3396
+ facet,
3397
+ selected: selection[facet.id] ?? [],
3398
+ counts: counts?.[facet.id],
3399
+ onToggle: toggle
3400
+ },
3401
+ facet.id
3402
+ ))
3403
+ ]
3404
+ }
3405
+ );
3406
+ });
3407
+ FilterPanel.displayName = "FilterPanel";
3408
+ function FilterFacetGroup({ facet, selected, counts, onToggle }) {
3409
+ const collapsible = facet.collapsible ?? true;
3410
+ const [open, setOpen] = useState12(facet.defaultOpen ?? true);
3411
+ const isOpen = !collapsible || open;
3412
+ const selectedCount = selected.length;
3413
+ const headingClass = "text-text-muted flex items-center gap-[6px] font-mono text-[10px] tracking-[1.4px] uppercase";
3414
+ return /* @__PURE__ */ jsxs41("section", { className: "flex flex-col gap-1", children: [
3415
+ collapsible ? /* @__PURE__ */ jsxs41(
3416
+ "button",
3417
+ {
3418
+ type: "button",
3419
+ "aria-expanded": isOpen,
3420
+ onClick: () => setOpen((v) => !v),
3421
+ className: cn(
3422
+ headingClass,
3423
+ "cursor-pointer rounded-xs px-1 py-[2px] outline-none",
3424
+ "focus-visible:ring-accent-dim focus-visible:ring-[3px]",
3425
+ "hover:text-text"
3426
+ ),
3427
+ children: [
3428
+ /* @__PURE__ */ jsx49("span", { className: "flex-1 text-left", children: facet.label }),
3429
+ selectedCount > 0 && /* @__PURE__ */ jsx49(Badge, { size: "sm", variant: "neutral", children: selectedCount }),
3430
+ /* @__PURE__ */ jsx49("span", { "aria-hidden": true, className: "text-[10px] opacity-70", children: isOpen ? "\u25BE" : "\u25B8" })
3431
+ ]
3432
+ }
3433
+ ) : /* @__PURE__ */ jsxs41("div", { className: cn(headingClass, "px-1 py-[2px]"), children: [
3434
+ /* @__PURE__ */ jsx49("span", { className: "flex-1", children: facet.label }),
3435
+ selectedCount > 0 && /* @__PURE__ */ jsx49(Badge, { size: "sm", variant: "neutral", children: selectedCount })
3436
+ ] }),
3437
+ isOpen && /* @__PURE__ */ jsx49("ul", { className: "m-0 flex list-none flex-col gap-[2px] p-0", children: facet.options.map((option) => {
3438
+ const isSelected = selected.includes(option.value);
3439
+ const count = counts?.[option.value];
3440
+ return /* @__PURE__ */ jsxs41("li", { className: "flex items-center gap-2 px-1 py-[3px]", children: [
3441
+ /* @__PURE__ */ jsx49(
3442
+ Checkbox,
3443
+ {
3444
+ checked: isSelected,
3445
+ onCheckedChange: (next) => onToggle(facet.id, option.value, next === true),
3446
+ label: option.label
3447
+ }
3448
+ ),
3449
+ typeof count === "number" && /* @__PURE__ */ jsx49("span", { className: "text-text-dim ml-auto font-mono text-[10px] tabular-nums", children: count })
3450
+ ] }, option.value);
3451
+ }) })
3452
+ ] });
3453
+ }
3454
+
3455
+ // src/patterns/HealthScore/HealthScore.tsx
3456
+ import { forwardRef as forwardRef49 } from "react";
3457
+
3458
+ // src/patterns/RadialProgress/RadialProgress.tsx
3459
+ import { forwardRef as forwardRef48 } from "react";
3460
+ import { jsx as jsx50, jsxs as jsxs42 } from "react/jsx-runtime";
3461
+ var toneStrokeClass = {
3462
+ accent: "stroke-accent",
3463
+ ok: "stroke-ok",
3464
+ warn: "stroke-warn",
3465
+ err: "stroke-err"
3466
+ };
3467
+ var RadialProgress = forwardRef48(
3468
+ function RadialProgress2({
3469
+ value,
3470
+ max = 100,
3471
+ size = 64,
3472
+ thickness = 4,
3473
+ tone,
3474
+ children,
3475
+ className,
3476
+ "aria-label": ariaLabel,
3477
+ ...props
3478
+ }, ref) {
3479
+ const clamped = Math.min(max, Math.max(0, value));
3480
+ const pct = max > 0 ? clamped / max * 100 : 0;
3481
+ const r = (size - thickness) / 2;
3482
+ const c = 2 * Math.PI * r;
3483
+ const dash = pct / 100 * c;
3484
+ const resolvedTone = tone ?? (clamped >= max ? "ok" : "accent");
3485
+ return /* @__PURE__ */ jsxs42(
3486
+ "div",
3487
+ {
3488
+ ref,
3489
+ role: "progressbar",
3490
+ "aria-valuemin": 0,
3491
+ "aria-valuemax": max,
3492
+ "aria-valuenow": Math.round(pct),
3493
+ "aria-label": ariaLabel ?? `${Math.round(pct)}%`,
3494
+ className: cn("relative inline-grid place-items-center", className),
3495
+ style: { width: size, height: size },
3496
+ ...props,
3497
+ children: [
3498
+ /* @__PURE__ */ jsxs42("svg", { width: size, height: size, viewBox: `0 0 ${size} ${size}`, children: [
3499
+ /* @__PURE__ */ jsx50(
3500
+ "circle",
3501
+ {
3502
+ cx: size / 2,
3503
+ cy: size / 2,
3504
+ r,
3505
+ fill: "none",
3506
+ strokeWidth: thickness,
3507
+ className: "stroke-panel-2"
3508
+ }
3509
+ ),
3510
+ /* @__PURE__ */ jsx50(
3511
+ "circle",
3512
+ {
3513
+ cx: size / 2,
3514
+ cy: size / 2,
3515
+ r,
3516
+ fill: "none",
3517
+ strokeWidth: thickness,
3518
+ strokeLinecap: "round",
3519
+ strokeDasharray: `${dash} ${c}`,
3520
+ transform: `rotate(-90 ${size / 2} ${size / 2})`,
3521
+ className: cn(
3522
+ "transition-[stroke-dasharray] duration-(--duration-step)",
3523
+ toneStrokeClass[resolvedTone]
3524
+ )
3525
+ }
3526
+ )
3527
+ ] }),
3528
+ /* @__PURE__ */ jsx50("div", { className: "absolute inset-0 grid place-items-center font-mono text-[11px] font-medium tabular-nums", children: children ?? `${Math.round(pct)}%` })
3529
+ ]
3530
+ }
3531
+ );
3532
+ }
3533
+ );
3534
+ RadialProgress.displayName = "RadialProgress";
3535
+
3536
+ // src/patterns/HealthScore/HealthScore.tsx
3537
+ import { jsx as jsx51, jsxs as jsxs43 } from "react/jsx-runtime";
3538
+ function deltaTone(delta) {
3539
+ if (delta > 0) return "ok";
3540
+ if (delta < 0) return "err";
3541
+ return "accent";
3542
+ }
3543
+ function deltaGlyph(delta) {
3544
+ if (delta > 0) return "\u2191";
3545
+ if (delta < 0) return "\u2193";
3546
+ return "\xB7";
3547
+ }
3548
+ var toneTextClass = {
3549
+ accent: "text-text-muted",
3550
+ ok: "text-ok",
3551
+ warn: "text-warn",
3552
+ err: "text-err"
3553
+ };
3554
+ var HealthScore = forwardRef49(function HealthScore2({
3555
+ value,
3556
+ max = 100,
3557
+ delta,
3558
+ label,
3559
+ breakdown,
3560
+ size = 72,
3561
+ tone,
3562
+ className,
3563
+ "aria-label": ariaLabel,
3564
+ ...props
3565
+ }, ref) {
3566
+ const pct = max > 0 ? Math.round(Math.min(max, Math.max(0, value)) / max * 100) : 0;
3567
+ const resolvedTone = tone ?? (pct >= 80 ? "ok" : pct >= 50 ? "accent" : "warn");
3568
+ const indicatorTone = typeof delta === "number" ? deltaTone(delta) : "accent";
3569
+ const core = /* @__PURE__ */ jsxs43(
3570
+ "div",
3571
+ {
3572
+ ref,
3573
+ className: cn("inline-flex flex-col items-center gap-1", className),
3574
+ "aria-label": ariaLabel ?? `${pct}% health`,
3575
+ ...props,
3576
+ children: [
3577
+ /* @__PURE__ */ jsx51(RadialProgress, { value, max, size, tone: resolvedTone }),
3578
+ label && /* @__PURE__ */ jsx51("div", { className: "text-text-muted mt-1 text-[12px] leading-tight", children: label }),
3579
+ typeof delta === "number" && /* @__PURE__ */ jsxs43("div", { className: cn("font-mono text-[11px] tabular-nums", toneTextClass[indicatorTone]), children: [
3580
+ /* @__PURE__ */ jsx51("span", { "aria-hidden": true, children: deltaGlyph(delta) }),
3581
+ " ",
3582
+ Math.abs(delta)
3583
+ ] })
3584
+ ]
3585
+ }
3586
+ );
3587
+ if (!breakdown || breakdown.length === 0) {
3588
+ return core;
3589
+ }
3590
+ return /* @__PURE__ */ jsx51(
3591
+ HoverCard,
3592
+ {
3593
+ trigger: /* @__PURE__ */ jsx51("span", { className: "inline-flex", children: core }),
3594
+ content: /* @__PURE__ */ jsxs43("div", { className: "flex min-w-[180px] flex-col gap-2", children: [
3595
+ /* @__PURE__ */ jsx51("div", { className: "text-text-dim font-mono text-[9px] tracking-[1.4px] uppercase", children: "Breakdown" }),
3596
+ /* @__PURE__ */ jsx51("ul", { className: "m-0 flex list-none flex-col gap-1 p-0 text-[12px]", children: breakdown.map((entry, i) => /* @__PURE__ */ jsxs43("li", { className: "flex items-center gap-2", children: [
3597
+ /* @__PURE__ */ jsx51("span", { className: "text-text-muted flex-1 truncate", children: entry.label }),
3598
+ /* @__PURE__ */ jsx51(
3599
+ "span",
3600
+ {
3601
+ className: cn(
3602
+ "font-mono tabular-nums",
3603
+ entry.tone ? toneTextClass[entry.tone] : "text-text"
3604
+ ),
3605
+ children: entry.value
3606
+ }
3607
+ )
3608
+ ] }, i)) })
3609
+ ] })
3610
+ }
3611
+ );
3612
+ });
3613
+ HealthScore.displayName = "HealthScore";
3614
+
3267
3615
  // src/patterns/Menubar/Menubar.tsx
3268
3616
  import * as RadixMenubar from "@radix-ui/react-menubar";
3269
- import { forwardRef as forwardRef46 } from "react";
3270
- import { jsx as jsx48, jsxs as jsxs40 } from "react/jsx-runtime";
3271
- var Menubar = forwardRef46(function Menubar2({ className, ...props }, ref) {
3272
- return /* @__PURE__ */ jsx48(
3617
+ import { forwardRef as forwardRef50 } from "react";
3618
+ import { jsx as jsx52, jsxs as jsxs44 } from "react/jsx-runtime";
3619
+ var Menubar = forwardRef50(function Menubar2({ className, ...props }, ref) {
3620
+ return /* @__PURE__ */ jsx52(
3273
3621
  RadixMenubar.Root,
3274
3622
  {
3275
3623
  ref,
@@ -3283,9 +3631,9 @@ var Menubar = forwardRef46(function Menubar2({ className, ...props }, ref) {
3283
3631
  });
3284
3632
  Menubar.displayName = "Menubar";
3285
3633
  var MenubarMenu = RadixMenubar.Menu;
3286
- var MenubarTrigger = forwardRef46(
3634
+ var MenubarTrigger = forwardRef50(
3287
3635
  function MenubarTrigger2({ className, ...props }, ref) {
3288
- return /* @__PURE__ */ jsx48(
3636
+ return /* @__PURE__ */ jsx52(
3289
3637
  RadixMenubar.Trigger,
3290
3638
  {
3291
3639
  ref,
@@ -3302,9 +3650,9 @@ var MenubarTrigger = forwardRef46(
3302
3650
  }
3303
3651
  );
3304
3652
  MenubarTrigger.displayName = "MenubarTrigger";
3305
- var MenubarContent = forwardRef46(
3653
+ var MenubarContent = forwardRef50(
3306
3654
  function MenubarContent2({ className, sideOffset = 6, align = "start", ...props }, ref) {
3307
- return /* @__PURE__ */ jsx48(RadixMenubar.Portal, { children: /* @__PURE__ */ jsx48(
3655
+ return /* @__PURE__ */ jsx52(RadixMenubar.Portal, { children: /* @__PURE__ */ jsx52(
3308
3656
  RadixMenubar.Content,
3309
3657
  {
3310
3658
  ref,
@@ -3326,24 +3674,24 @@ var itemBase3 = cn(
3326
3674
  "data-[highlighted]:bg-panel-2",
3327
3675
  "data-[disabled]:opacity-40 data-[disabled]:cursor-not-allowed"
3328
3676
  );
3329
- var MenubarItem = forwardRef46(function MenubarItem2({ trailing, destructive, className, children, ...props }, ref) {
3330
- return /* @__PURE__ */ jsxs40(
3677
+ var MenubarItem = forwardRef50(function MenubarItem2({ trailing, destructive, className, children, ...props }, ref) {
3678
+ return /* @__PURE__ */ jsxs44(
3331
3679
  RadixMenubar.Item,
3332
3680
  {
3333
3681
  ref,
3334
3682
  className: cn(itemBase3, destructive ? "text-err" : "text-text", className),
3335
3683
  ...props,
3336
3684
  children: [
3337
- /* @__PURE__ */ jsx48("span", { className: "flex-1", children }),
3338
- trailing && /* @__PURE__ */ jsx48("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
3685
+ /* @__PURE__ */ jsx52("span", { className: "flex-1", children }),
3686
+ trailing && /* @__PURE__ */ jsx52("span", { className: "text-text-dim font-mono text-[10px]", children: trailing })
3339
3687
  ]
3340
3688
  }
3341
3689
  );
3342
3690
  });
3343
3691
  MenubarItem.displayName = "MenubarItem";
3344
- var MenubarSeparator = forwardRef46(
3692
+ var MenubarSeparator = forwardRef50(
3345
3693
  function MenubarSeparator2({ className, ...props }, ref) {
3346
- return /* @__PURE__ */ jsx48(
3694
+ return /* @__PURE__ */ jsx52(
3347
3695
  RadixMenubar.Separator,
3348
3696
  {
3349
3697
  ref,
@@ -3358,22 +3706,22 @@ MenubarSeparator.displayName = "MenubarSeparator";
3358
3706
  // src/patterns/NavBar/NavBar.tsx
3359
3707
  import * as RadixNav from "@radix-ui/react-navigation-menu";
3360
3708
  import {
3361
- forwardRef as forwardRef48,
3362
- useCallback as useCallback9,
3709
+ forwardRef as forwardRef52,
3710
+ useCallback as useCallback10,
3363
3711
  useEffect as useEffect9,
3364
3712
  useRef as useRef7,
3365
- useState as useState13
3713
+ useState as useState14
3366
3714
  } from "react";
3367
3715
 
3368
3716
  // src/patterns/Sidebar/Sidebar.tsx
3369
3717
  import {
3370
- forwardRef as forwardRef47,
3371
- useCallback as useCallback8,
3372
- useState as useState12
3718
+ forwardRef as forwardRef51,
3719
+ useCallback as useCallback9,
3720
+ useState as useState13
3373
3721
  } from "react";
3374
- import { Fragment as Fragment2, jsx as jsx49, jsxs as jsxs41 } from "react/jsx-runtime";
3375
- var Sidebar = forwardRef47(function Sidebar2({ width = 240, className, style, ...props }, ref) {
3376
- return /* @__PURE__ */ jsx49(
3722
+ import { Fragment as Fragment2, jsx as jsx53, jsxs as jsxs45 } from "react/jsx-runtime";
3723
+ var Sidebar = forwardRef51(function Sidebar2({ width = 240, className, style, ...props }, ref) {
3724
+ return /* @__PURE__ */ jsx53(
3377
3725
  "aside",
3378
3726
  {
3379
3727
  ref,
@@ -3387,12 +3735,12 @@ var Sidebar = forwardRef47(function Sidebar2({ width = 240, className, style, ..
3387
3735
  );
3388
3736
  });
3389
3737
  Sidebar.displayName = "Sidebar";
3390
- var NavItem = forwardRef47(
3738
+ var NavItem = forwardRef51(
3391
3739
  function NavItem2({ icon, label, active, badge, href, disabled, className, ...props }, ref) {
3392
- const inner = /* @__PURE__ */ jsxs41(Fragment2, { children: [
3393
- icon && /* @__PURE__ */ jsx49("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: icon }),
3394
- /* @__PURE__ */ jsx49("span", { className: "flex-1 truncate", children: label }),
3395
- badge != null && /* @__PURE__ */ jsx49(
3740
+ const inner = /* @__PURE__ */ jsxs45(Fragment2, { children: [
3741
+ icon && /* @__PURE__ */ jsx53("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: icon }),
3742
+ /* @__PURE__ */ jsx53("span", { className: "flex-1 truncate", children: label }),
3743
+ badge != null && /* @__PURE__ */ jsx53(
3396
3744
  "span",
3397
3745
  {
3398
3746
  className: cn(
@@ -3413,7 +3761,7 @@ var NavItem = forwardRef47(
3413
3761
  );
3414
3762
  if (href) {
3415
3763
  const anchorProps = props;
3416
- return /* @__PURE__ */ jsx49(
3764
+ return /* @__PURE__ */ jsx53(
3417
3765
  "a",
3418
3766
  {
3419
3767
  ref,
@@ -3427,7 +3775,7 @@ var NavItem = forwardRef47(
3427
3775
  );
3428
3776
  }
3429
3777
  const buttonProps = props;
3430
- return /* @__PURE__ */ jsx49(
3778
+ return /* @__PURE__ */ jsx53(
3431
3779
  "button",
3432
3780
  {
3433
3781
  ref,
@@ -3442,7 +3790,7 @@ var NavItem = forwardRef47(
3442
3790
  }
3443
3791
  );
3444
3792
  NavItem.displayName = "NavItem";
3445
- var NavSection = forwardRef47(function NavSection2({
3793
+ var NavSection = forwardRef51(function NavSection2({
3446
3794
  label,
3447
3795
  icon,
3448
3796
  action,
@@ -3456,16 +3804,16 @@ var NavSection = forwardRef47(function NavSection2({
3456
3804
  ...props
3457
3805
  }, ref) {
3458
3806
  const isControlled = open !== void 0;
3459
- const [internalOpen, setInternalOpen] = useState12(defaultOpen);
3807
+ const [internalOpen, setInternalOpen] = useState13(defaultOpen);
3460
3808
  const isOpen = !collapsible || (isControlled ? open : internalOpen);
3461
- const toggle = useCallback8(() => {
3809
+ const toggle = useCallback9(() => {
3462
3810
  const next = !isOpen;
3463
3811
  if (!isControlled) setInternalOpen(next);
3464
3812
  onOpenChange?.(next);
3465
3813
  }, [isOpen, isControlled, onOpenChange]);
3466
3814
  const eyebrowClass = "text-text-dim flex items-center gap-[6px] px-2 pt-2 font-mono text-[9px] tracking-[1.4px] uppercase";
3467
- return /* @__PURE__ */ jsxs41("div", { ref, className: cn("flex flex-col gap-1", className), ...props, children: [
3468
- collapsible ? /* @__PURE__ */ jsxs41(
3815
+ return /* @__PURE__ */ jsxs45("div", { ref, className: cn("flex flex-col gap-1", className), ...props, children: [
3816
+ collapsible ? /* @__PURE__ */ jsxs45(
3469
3817
  "button",
3470
3818
  {
3471
3819
  type: "button",
@@ -3478,18 +3826,18 @@ var NavSection = forwardRef47(function NavSection2({
3478
3826
  "hover:text-text-muted"
3479
3827
  ),
3480
3828
  children: [
3481
- icon != null && /* @__PURE__ */ jsx49("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
3482
- /* @__PURE__ */ jsx49("span", { className: "flex-1 text-left", children: label }),
3829
+ icon != null && /* @__PURE__ */ jsx53("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
3830
+ /* @__PURE__ */ jsx53("span", { className: "flex-1 text-left", children: label }),
3483
3831
  action,
3484
- /* @__PURE__ */ jsx49("span", { "aria-hidden": true, className: "text-[10px] opacity-70", children: isOpen ? "\u25BE" : "\u25B8" })
3832
+ /* @__PURE__ */ jsx53("span", { "aria-hidden": true, className: "text-[10px] opacity-70", children: isOpen ? "\u25BE" : "\u25B8" })
3485
3833
  ]
3486
3834
  }
3487
- ) : /* @__PURE__ */ jsxs41("div", { className: eyebrowClass, children: [
3488
- icon != null && /* @__PURE__ */ jsx49("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
3489
- /* @__PURE__ */ jsx49("span", { className: "flex-1", children: label }),
3835
+ ) : /* @__PURE__ */ jsxs45("div", { className: eyebrowClass, children: [
3836
+ icon != null && /* @__PURE__ */ jsx53("span", { "aria-hidden": true, className: "opacity-80", children: icon }),
3837
+ /* @__PURE__ */ jsx53("span", { className: "flex-1", children: label }),
3490
3838
  action
3491
3839
  ] }),
3492
- isOpen && /* @__PURE__ */ jsx49(
3840
+ isOpen && /* @__PURE__ */ jsx53(
3493
3841
  "div",
3494
3842
  {
3495
3843
  className: cn("flex flex-col gap-[2px]", indent > 0 && "border-border ml-2 border-l"),
@@ -3502,12 +3850,12 @@ var NavSection = forwardRef47(function NavSection2({
3502
3850
  NavSection.displayName = "NavSection";
3503
3851
 
3504
3852
  // src/patterns/NavBar/NavBar.tsx
3505
- import { Fragment as Fragment3, jsx as jsx50, jsxs as jsxs42 } from "react/jsx-runtime";
3853
+ import { Fragment as Fragment3, jsx as jsx54, jsxs as jsxs46 } from "react/jsx-runtime";
3506
3854
  function isActiveTree(item, activeId) {
3507
3855
  if (item.id === activeId) return true;
3508
3856
  return item.children?.some((c) => isActiveTree(c, activeId)) ?? false;
3509
3857
  }
3510
- var NavBar = forwardRef48(function NavBar2({
3858
+ var NavBar = forwardRef52(function NavBar2({
3511
3859
  orientation = "horizontal",
3512
3860
  items,
3513
3861
  brand,
@@ -3521,17 +3869,17 @@ var NavBar = forwardRef48(function NavBar2({
3521
3869
  ...props
3522
3870
  }, ref) {
3523
3871
  const isControlled = value !== void 0;
3524
- const [internalValue, setInternalValue] = useState13(defaultValue);
3872
+ const [internalValue, setInternalValue] = useState14(defaultValue);
3525
3873
  const activeId = isControlled ? value : internalValue;
3526
- const [drawerOpen, setDrawerOpen] = useState13(false);
3527
- const select = useCallback9(
3874
+ const [drawerOpen, setDrawerOpen] = useState14(false);
3875
+ const select = useCallback10(
3528
3876
  (id) => {
3529
3877
  if (!isControlled) setInternalValue(id);
3530
3878
  onValueChange?.(id);
3531
3879
  },
3532
3880
  [isControlled, onValueChange]
3533
3881
  );
3534
- const handleItemActivate = useCallback9(
3882
+ const handleItemActivate = useCallback10(
3535
3883
  (id) => {
3536
3884
  select(id);
3537
3885
  setDrawerOpen(false);
@@ -3543,7 +3891,7 @@ var NavBar = forwardRef48(function NavBar2({
3543
3891
  // drawer is open on a viewport that's resizing past `md`, both navs can
3544
3892
  // sit in the DOM together. Identical accessible names would trip axe's
3545
3893
  // `landmark-unique` rule.
3546
- /* @__PURE__ */ jsx50("nav", { "aria-label": "Mobile navigation", className: "flex flex-col gap-1", children: items.map((item) => /* @__PURE__ */ jsx50(
3894
+ /* @__PURE__ */ jsx54("nav", { "aria-label": "Mobile navigation", className: "flex flex-col gap-1", children: items.map((item) => /* @__PURE__ */ jsx54(
3547
3895
  VerticalItem,
3548
3896
  {
3549
3897
  item,
@@ -3553,14 +3901,14 @@ var NavBar = forwardRef48(function NavBar2({
3553
3901
  item.id
3554
3902
  )) })
3555
3903
  );
3556
- const mobileBar = responsive ? /* @__PURE__ */ jsxs42(
3904
+ const mobileBar = responsive ? /* @__PURE__ */ jsxs46(
3557
3905
  "div",
3558
3906
  {
3559
3907
  className: cn(
3560
3908
  "border-border bg-panel z-overlay sticky top-0 flex h-[52px] items-center gap-4 border-b px-5 md:hidden"
3561
3909
  ),
3562
3910
  children: [
3563
- /* @__PURE__ */ jsx50(
3911
+ /* @__PURE__ */ jsx54(
3564
3912
  "button",
3565
3913
  {
3566
3914
  type: "button",
@@ -3570,15 +3918,15 @@ var NavBar = forwardRef48(function NavBar2({
3570
3918
  children: "\u2630"
3571
3919
  }
3572
3920
  ),
3573
- brand && /* @__PURE__ */ jsx50("div", { className: "flex flex-1 items-center text-[13px] font-medium whitespace-nowrap", children: brand }),
3574
- actions && /* @__PURE__ */ jsx50("div", { className: "flex items-center gap-3", children: actions })
3921
+ brand && /* @__PURE__ */ jsx54("div", { className: "flex flex-1 items-center text-[13px] font-medium whitespace-nowrap", children: brand }),
3922
+ actions && /* @__PURE__ */ jsx54("div", { className: "flex items-center gap-3", children: actions })
3575
3923
  ]
3576
3924
  }
3577
3925
  ) : null;
3578
3926
  if (orientation === "horizontal") {
3579
- return /* @__PURE__ */ jsxs42(Fragment3, { children: [
3927
+ return /* @__PURE__ */ jsxs46(Fragment3, { children: [
3580
3928
  mobileBar,
3581
- /* @__PURE__ */ jsxs42(
3929
+ /* @__PURE__ */ jsxs46(
3582
3930
  "header",
3583
3931
  {
3584
3932
  ref,
@@ -3589,10 +3937,10 @@ var NavBar = forwardRef48(function NavBar2({
3589
3937
  ),
3590
3938
  ...props,
3591
3939
  children: [
3592
- brand && /* @__PURE__ */ jsx50("div", { className: "shrink-0 text-[13px] font-medium whitespace-nowrap", children: brand }),
3593
- /* @__PURE__ */ jsxs42(RadixNav.Root, { className: "relative flex-1", delayDuration: 120, children: [
3594
- /* @__PURE__ */ jsx50(RadixNav.List, { className: "m-0! flex list-none! items-center gap-1 p-0! [&_li]:m-0!", children: items.map(
3595
- (item) => item.children?.length ? /* @__PURE__ */ jsx50(
3940
+ brand && /* @__PURE__ */ jsx54("div", { className: "shrink-0 text-[13px] font-medium whitespace-nowrap", children: brand }),
3941
+ /* @__PURE__ */ jsxs46(RadixNav.Root, { className: "relative flex-1", delayDuration: 120, children: [
3942
+ /* @__PURE__ */ jsx54(RadixNav.List, { className: "m-0! flex list-none! items-center gap-1 p-0! [&_li]:m-0!", children: items.map(
3943
+ (item) => item.children?.length ? /* @__PURE__ */ jsx54(
3596
3944
  HorizontalDropdown,
3597
3945
  {
3598
3946
  item,
@@ -3601,7 +3949,7 @@ var NavBar = forwardRef48(function NavBar2({
3601
3949
  onActivate: handleItemActivate
3602
3950
  },
3603
3951
  item.id
3604
- ) : /* @__PURE__ */ jsx50(RadixNav.Item, { children: /* @__PURE__ */ jsx50(
3952
+ ) : /* @__PURE__ */ jsx54(RadixNav.Item, { children: /* @__PURE__ */ jsx54(
3605
3953
  HorizontalLink,
3606
3954
  {
3607
3955
  item,
@@ -3610,13 +3958,13 @@ var NavBar = forwardRef48(function NavBar2({
3610
3958
  }
3611
3959
  ) }, item.id)
3612
3960
  ) }),
3613
- /* @__PURE__ */ jsx50("div", { className: "z-popover absolute top-full left-0 flex justify-start", children: /* @__PURE__ */ jsx50(RadixNav.Viewport, { className: "origin-top-left data-[state=open]:animate-[ship-fade-in_120ms_var(--easing-out)]" }) })
3961
+ /* @__PURE__ */ jsx54("div", { className: "z-popover absolute top-full left-0 flex justify-start", children: /* @__PURE__ */ jsx54(RadixNav.Viewport, { className: "origin-top-left data-[state=open]:animate-[ship-fade-in_120ms_var(--easing-out)]" }) })
3614
3962
  ] }),
3615
- actions && /* @__PURE__ */ jsx50("div", { className: "flex items-center gap-3", children: actions })
3963
+ actions && /* @__PURE__ */ jsx54("div", { className: "flex items-center gap-3", children: actions })
3616
3964
  ]
3617
3965
  }
3618
3966
  ),
3619
- responsive && /* @__PURE__ */ jsx50(
3967
+ responsive && /* @__PURE__ */ jsx54(
3620
3968
  Drawer,
3621
3969
  {
3622
3970
  open: drawerOpen,
@@ -3629,9 +3977,9 @@ var NavBar = forwardRef48(function NavBar2({
3629
3977
  )
3630
3978
  ] });
3631
3979
  }
3632
- return /* @__PURE__ */ jsxs42(Fragment3, { children: [
3980
+ return /* @__PURE__ */ jsxs46(Fragment3, { children: [
3633
3981
  mobileBar,
3634
- /* @__PURE__ */ jsxs42(
3982
+ /* @__PURE__ */ jsxs46(
3635
3983
  "aside",
3636
3984
  {
3637
3985
  ref,
@@ -3644,8 +3992,8 @@ var NavBar = forwardRef48(function NavBar2({
3644
3992
  ),
3645
3993
  ...props,
3646
3994
  children: [
3647
- brand && /* @__PURE__ */ jsx50("div", { className: "px-2 py-1 text-[13px] font-medium", children: brand }),
3648
- /* @__PURE__ */ jsx50("nav", { "aria-label": "Sidebar navigation", className: "flex flex-1 flex-col gap-1 overflow-y-auto", children: items.map((item) => /* @__PURE__ */ jsx50(
3995
+ brand && /* @__PURE__ */ jsx54("div", { className: "px-2 py-1 text-[13px] font-medium", children: brand }),
3996
+ /* @__PURE__ */ jsx54("nav", { "aria-label": "Sidebar navigation", className: "flex flex-1 flex-col gap-1 overflow-y-auto", children: items.map((item) => /* @__PURE__ */ jsx54(
3649
3997
  VerticalItem,
3650
3998
  {
3651
3999
  item,
@@ -3654,11 +4002,11 @@ var NavBar = forwardRef48(function NavBar2({
3654
4002
  },
3655
4003
  item.id
3656
4004
  )) }),
3657
- actions && /* @__PURE__ */ jsx50("div", { className: "border-border mt-auto flex flex-col gap-2 border-t pt-3", children: actions })
4005
+ actions && /* @__PURE__ */ jsx54("div", { className: "border-border mt-auto flex flex-col gap-2 border-t pt-3", children: actions })
3658
4006
  ]
3659
4007
  }
3660
4008
  ),
3661
- responsive && /* @__PURE__ */ jsx50(
4009
+ responsive && /* @__PURE__ */ jsx54(
3662
4010
  Drawer,
3663
4011
  {
3664
4012
  open: drawerOpen,
@@ -3687,13 +4035,13 @@ function HorizontalLink({ item, active, onActivate }) {
3687
4035
  }
3688
4036
  onActivate(item.id);
3689
4037
  };
3690
- const inner = /* @__PURE__ */ jsxs42(Fragment3, { children: [
3691
- item.icon != null && /* @__PURE__ */ jsx50("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
3692
- /* @__PURE__ */ jsx50("span", { children: item.label }),
3693
- item.badge != null && /* @__PURE__ */ jsx50(ItemBadge, { active, children: item.badge })
4038
+ const inner = /* @__PURE__ */ jsxs46(Fragment3, { children: [
4039
+ item.icon != null && /* @__PURE__ */ jsx54("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4040
+ /* @__PURE__ */ jsx54("span", { children: item.label }),
4041
+ item.badge != null && /* @__PURE__ */ jsx54(ItemBadge, { active, children: item.badge })
3694
4042
  ] });
3695
4043
  if (item.href) {
3696
- return /* @__PURE__ */ jsx50(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx50(
4044
+ return /* @__PURE__ */ jsx54(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx54(
3697
4045
  "a",
3698
4046
  {
3699
4047
  href: item.href,
@@ -3705,7 +4053,7 @@ function HorizontalLink({ item, active, onActivate }) {
3705
4053
  }
3706
4054
  ) });
3707
4055
  }
3708
- return /* @__PURE__ */ jsx50(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx50(
4056
+ return /* @__PURE__ */ jsx54(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx54(
3709
4057
  "button",
3710
4058
  {
3711
4059
  type: "button",
@@ -3718,8 +4066,8 @@ function HorizontalLink({ item, active, onActivate }) {
3718
4066
  ) });
3719
4067
  }
3720
4068
  function HorizontalDropdown({ item, active, activeId, onActivate }) {
3721
- return /* @__PURE__ */ jsxs42(RadixNav.Item, { children: [
3722
- /* @__PURE__ */ jsxs42(
4069
+ return /* @__PURE__ */ jsxs46(RadixNav.Item, { children: [
4070
+ /* @__PURE__ */ jsxs46(
3723
4071
  RadixNav.Trigger,
3724
4072
  {
3725
4073
  className: cn(
@@ -3731,9 +4079,9 @@ function HorizontalDropdown({ item, active, activeId, onActivate }) {
3731
4079
  ),
3732
4080
  disabled: item.disabled,
3733
4081
  children: [
3734
- item.icon != null && /* @__PURE__ */ jsx50("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
3735
- /* @__PURE__ */ jsx50("span", { children: item.label }),
3736
- /* @__PURE__ */ jsx50(
4082
+ item.icon != null && /* @__PURE__ */ jsx54("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4083
+ /* @__PURE__ */ jsx54("span", { children: item.label }),
4084
+ /* @__PURE__ */ jsx54(
3737
4085
  "span",
3738
4086
  {
3739
4087
  "aria-hidden": true,
@@ -3744,7 +4092,7 @@ function HorizontalDropdown({ item, active, activeId, onActivate }) {
3744
4092
  ]
3745
4093
  }
3746
4094
  ),
3747
- /* @__PURE__ */ jsx50(RadixNav.Content, { className: "border-border bg-panel min-w-[220px] rounded-xs border p-2 shadow-lg", children: /* @__PURE__ */ jsx50("ul", { className: "m-0! flex list-none! flex-col gap-[2px] p-0! [&_li]:m-0!", children: item.children.map((child) => /* @__PURE__ */ jsx50("li", { children: /* @__PURE__ */ jsx50(DropdownLink, { item: child, active: child.id === activeId, onActivate }) }, child.id)) }) })
4095
+ /* @__PURE__ */ jsx54(RadixNav.Content, { className: "border-border bg-panel min-w-[220px] rounded-xs border p-2 shadow-lg", children: /* @__PURE__ */ jsx54("ul", { className: "m-0! flex list-none! flex-col gap-[2px] p-0! [&_li]:m-0!", children: item.children.map((child) => /* @__PURE__ */ jsx54("li", { children: /* @__PURE__ */ jsx54(DropdownLink, { item: child, active: child.id === activeId, onActivate }) }, child.id)) }) })
3748
4096
  ] });
3749
4097
  }
3750
4098
  function DropdownLink({ item, active, onActivate }) {
@@ -3761,13 +4109,13 @@ function DropdownLink({ item, active, onActivate }) {
3761
4109
  }
3762
4110
  onActivate(item.id);
3763
4111
  };
3764
- const inner = /* @__PURE__ */ jsxs42(Fragment3, { children: [
3765
- item.icon != null && /* @__PURE__ */ jsx50("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
3766
- /* @__PURE__ */ jsx50("span", { className: "flex-1", children: item.label }),
3767
- item.badge != null && /* @__PURE__ */ jsx50(ItemBadge, { active, children: item.badge })
4112
+ const inner = /* @__PURE__ */ jsxs46(Fragment3, { children: [
4113
+ item.icon != null && /* @__PURE__ */ jsx54("span", { "aria-hidden": true, className: "opacity-80", children: item.icon }),
4114
+ /* @__PURE__ */ jsx54("span", { className: "flex-1", children: item.label }),
4115
+ item.badge != null && /* @__PURE__ */ jsx54(ItemBadge, { active, children: item.badge })
3768
4116
  ] });
3769
4117
  if (item.href) {
3770
- return /* @__PURE__ */ jsx50(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx50(
4118
+ return /* @__PURE__ */ jsx54(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx54(
3771
4119
  "a",
3772
4120
  {
3773
4121
  href: item.href,
@@ -3779,7 +4127,7 @@ function DropdownLink({ item, active, onActivate }) {
3779
4127
  }
3780
4128
  ) });
3781
4129
  }
3782
- return /* @__PURE__ */ jsx50(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx50(
4130
+ return /* @__PURE__ */ jsx54(RadixNav.Link, { asChild: true, active, children: /* @__PURE__ */ jsx54(
3783
4131
  "button",
3784
4132
  {
3785
4133
  type: "button",
@@ -3794,7 +4142,7 @@ function DropdownLink({ item, active, onActivate }) {
3794
4142
  function VerticalItem({ item, activeId, onActivate }) {
3795
4143
  const hasChildren = (item.children?.length ?? 0) > 0;
3796
4144
  const treeActive = isActiveTree(item, activeId);
3797
- const [open, setOpen] = useState13(treeActive);
4145
+ const [open, setOpen] = useState14(treeActive);
3798
4146
  const prevTreeActive = useRef7(treeActive);
3799
4147
  useEffect9(() => {
3800
4148
  if (treeActive && !prevTreeActive.current) setOpen(true);
@@ -3808,7 +4156,7 @@ function VerticalItem({ item, activeId, onActivate }) {
3808
4156
  }
3809
4157
  onActivate(item.id);
3810
4158
  };
3811
- return /* @__PURE__ */ jsx50(
4159
+ return /* @__PURE__ */ jsx54(
3812
4160
  NavItem,
3813
4161
  {
3814
4162
  icon: item.icon,
@@ -3821,8 +4169,8 @@ function VerticalItem({ item, activeId, onActivate }) {
3821
4169
  }
3822
4170
  );
3823
4171
  }
3824
- return /* @__PURE__ */ jsxs42("div", { className: "flex flex-col", children: [
3825
- /* @__PURE__ */ jsxs42(
4172
+ return /* @__PURE__ */ jsxs46("div", { className: "flex flex-col", children: [
4173
+ /* @__PURE__ */ jsxs46(
3826
4174
  "button",
3827
4175
  {
3828
4176
  type: "button",
@@ -3838,18 +4186,18 @@ function VerticalItem({ item, activeId, onActivate }) {
3838
4186
  item.disabled && "pointer-events-none opacity-50"
3839
4187
  ),
3840
4188
  children: [
3841
- item.icon != null && /* @__PURE__ */ jsx50("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: item.icon }),
3842
- /* @__PURE__ */ jsx50("span", { className: "flex-1 truncate", children: item.label }),
3843
- item.badge != null && /* @__PURE__ */ jsx50(ItemBadge, { active: treeActive, children: item.badge }),
3844
- /* @__PURE__ */ jsx50("span", { "aria-hidden": true, className: "text-[10px] opacity-60", children: open ? "\u25BE" : "\u25B8" })
4189
+ item.icon != null && /* @__PURE__ */ jsx54("span", { "aria-hidden": true, className: "w-[14px] text-center opacity-80", children: item.icon }),
4190
+ /* @__PURE__ */ jsx54("span", { className: "flex-1 truncate", children: item.label }),
4191
+ item.badge != null && /* @__PURE__ */ jsx54(ItemBadge, { active: treeActive, children: item.badge }),
4192
+ /* @__PURE__ */ jsx54("span", { "aria-hidden": true, className: "text-[10px] opacity-60", children: open ? "\u25BE" : "\u25B8" })
3845
4193
  ]
3846
4194
  }
3847
4195
  ),
3848
- open && /* @__PURE__ */ jsx50("div", { className: "border-border mt-1 ml-[18px] flex flex-col gap-[2px] border-l pl-3", children: item.children.map((child) => /* @__PURE__ */ jsx50(VerticalItem, { item: child, activeId, onActivate }, child.id)) })
4196
+ open && /* @__PURE__ */ jsx54("div", { className: "border-border mt-1 ml-[18px] flex flex-col gap-[2px] border-l pl-3", children: item.children.map((child) => /* @__PURE__ */ jsx54(VerticalItem, { item: child, activeId, onActivate }, child.id)) })
3849
4197
  ] });
3850
4198
  }
3851
4199
  function ItemBadge({ active, children }) {
3852
- return /* @__PURE__ */ jsx50(
4200
+ return /* @__PURE__ */ jsx54(
3853
4201
  "span",
3854
4202
  {
3855
4203
  className: cn(
@@ -3861,9 +4209,105 @@ function ItemBadge({ active, children }) {
3861
4209
  );
3862
4210
  }
3863
4211
 
4212
+ // src/patterns/OnboardingChecklist/OnboardingChecklist.tsx
4213
+ import { forwardRef as forwardRef53 } from "react";
4214
+ import { Fragment as Fragment4, jsx as jsx55, jsxs as jsxs47 } from "react/jsx-runtime";
4215
+ var statusDot = {
4216
+ pending: "off",
4217
+ "in-progress": "sync",
4218
+ done: "ok"
4219
+ };
4220
+ var labelStateClass = {
4221
+ pending: "text-text",
4222
+ "in-progress": "text-text",
4223
+ done: "text-text-dim line-through"
4224
+ };
4225
+ var OnboardingChecklist = forwardRef53(
4226
+ function OnboardingChecklist2({ items, onItemClick, title = "Get started", progressLabel, hideProgress, className, ...props }, ref) {
4227
+ const total = items.length;
4228
+ const done = items.filter((i) => i.status === "done").length;
4229
+ return /* @__PURE__ */ jsxs47(
4230
+ "section",
4231
+ {
4232
+ ref,
4233
+ "aria-label": typeof title === "string" ? title : void 0,
4234
+ className: cn(
4235
+ "rounded-base border-border bg-panel flex flex-col gap-3 border p-5",
4236
+ className
4237
+ ),
4238
+ ...props,
4239
+ children: [
4240
+ /* @__PURE__ */ jsxs47("header", { className: "flex items-center gap-2", children: [
4241
+ /* @__PURE__ */ jsx55("span", { className: "text-[14px] font-medium", children: title }),
4242
+ /* @__PURE__ */ jsx55("span", { className: "text-text-dim ml-auto font-mono text-[11px] tabular-nums", children: progressLabel ?? `${done} of ${total} complete` })
4243
+ ] }),
4244
+ !hideProgress && total > 0 && /* @__PURE__ */ jsx55(
4245
+ "div",
4246
+ {
4247
+ role: "progressbar",
4248
+ "aria-valuemin": 0,
4249
+ "aria-valuemax": total,
4250
+ "aria-valuenow": done,
4251
+ "aria-label": typeof title === "string" ? `${title} progress` : "Setup progress",
4252
+ className: "bg-panel-2 h-[3px] w-full overflow-hidden rounded-full",
4253
+ children: /* @__PURE__ */ jsx55(
4254
+ "span",
4255
+ {
4256
+ "aria-hidden": true,
4257
+ className: cn(
4258
+ "block h-full rounded-full transition-[width] duration-(--duration-step)",
4259
+ done === total ? "bg-ok" : "bg-accent"
4260
+ ),
4261
+ style: { width: `${total > 0 ? done / total * 100 : 0}%` }
4262
+ }
4263
+ )
4264
+ }
4265
+ ),
4266
+ /* @__PURE__ */ jsx55("ul", { className: "m-0 flex list-none flex-col gap-1 p-0", children: items.map((item) => {
4267
+ const interactive = typeof onItemClick === "function";
4268
+ const labelBlock = /* @__PURE__ */ jsxs47(Fragment4, { children: [
4269
+ /* @__PURE__ */ jsx55(
4270
+ StatusDot,
4271
+ {
4272
+ state: statusDot[item.status],
4273
+ pulse: item.status === "in-progress",
4274
+ size: 10,
4275
+ className: "mt-[3px]"
4276
+ }
4277
+ ),
4278
+ /* @__PURE__ */ jsxs47("div", { className: "flex min-w-0 flex-1 flex-col gap-[2px]", children: [
4279
+ /* @__PURE__ */ jsx55("span", { className: cn("text-[13px]", labelStateClass[item.status]), children: item.label }),
4280
+ item.description && /* @__PURE__ */ jsx55("span", { className: "text-text-muted text-[12px] leading-[1.45]", children: item.description })
4281
+ ] })
4282
+ ] });
4283
+ const labelRegionClass = cn(
4284
+ "flex flex-1 items-start gap-3 rounded-md px-2 py-2 text-left transition-colors duration-(--duration-micro)",
4285
+ interactive && "cursor-pointer outline-none hover:bg-panel-2 focus-visible:ring-[3px] focus-visible:ring-accent-dim"
4286
+ );
4287
+ return /* @__PURE__ */ jsxs47("li", { className: "flex items-start gap-2", children: [
4288
+ interactive ? /* @__PURE__ */ jsx55(
4289
+ "button",
4290
+ {
4291
+ type: "button",
4292
+ "aria-current": item.status === "in-progress" ? "step" : void 0,
4293
+ onClick: () => onItemClick(item.id),
4294
+ className: labelRegionClass,
4295
+ children: labelBlock
4296
+ }
4297
+ ) : /* @__PURE__ */ jsx55("div", { className: labelRegionClass, children: labelBlock }),
4298
+ item.action && /* @__PURE__ */ jsx55("div", { className: "shrink-0 self-center", children: item.action })
4299
+ ] }, item.id);
4300
+ }) })
4301
+ ]
4302
+ }
4303
+ );
4304
+ }
4305
+ );
4306
+ OnboardingChecklist.displayName = "OnboardingChecklist";
4307
+
3864
4308
  // src/patterns/Pagination/Pagination.tsx
3865
- import { forwardRef as forwardRef49 } from "react";
3866
- import { jsx as jsx51, jsxs as jsxs43 } from "react/jsx-runtime";
4309
+ import { forwardRef as forwardRef54 } from "react";
4310
+ import { jsx as jsx56, jsxs as jsxs48 } from "react/jsx-runtime";
3867
4311
  function buildRange(page, total, siblings) {
3868
4312
  if (total <= 0) return [];
3869
4313
  const items = [];
@@ -3876,9 +4320,9 @@ function buildRange(page, total, siblings) {
3876
4320
  if (total > 1) items.push(total);
3877
4321
  return items;
3878
4322
  }
3879
- var Pagination = forwardRef49(function Pagination2({ page, total, onPageChange, siblings = 1, className, ...props }, ref) {
4323
+ var Pagination = forwardRef54(function Pagination2({ page, total, onPageChange, siblings = 1, className, ...props }, ref) {
3880
4324
  const items = buildRange(page, total, siblings);
3881
- return /* @__PURE__ */ jsxs43(
4325
+ return /* @__PURE__ */ jsxs48(
3882
4326
  "nav",
3883
4327
  {
3884
4328
  ref,
@@ -3886,7 +4330,7 @@ var Pagination = forwardRef49(function Pagination2({ page, total, onPageChange,
3886
4330
  className: cn("inline-flex items-center gap-1", className),
3887
4331
  ...props,
3888
4332
  children: [
3889
- /* @__PURE__ */ jsx51(
4333
+ /* @__PURE__ */ jsx56(
3890
4334
  IconButton,
3891
4335
  {
3892
4336
  size: "sm",
@@ -3899,7 +4343,7 @@ var Pagination = forwardRef49(function Pagination2({ page, total, onPageChange,
3899
4343
  ),
3900
4344
  items.map((item, i) => {
3901
4345
  if (item === "start-ellipsis" || item === "end-ellipsis") {
3902
- return /* @__PURE__ */ jsx51(
4346
+ return /* @__PURE__ */ jsx56(
3903
4347
  "span",
3904
4348
  {
3905
4349
  "aria-hidden": true,
@@ -3910,7 +4354,7 @@ var Pagination = forwardRef49(function Pagination2({ page, total, onPageChange,
3910
4354
  );
3911
4355
  }
3912
4356
  const isActive = item === page;
3913
- return /* @__PURE__ */ jsx51(
4357
+ return /* @__PURE__ */ jsx56(
3914
4358
  "button",
3915
4359
  {
3916
4360
  type: "button",
@@ -3928,7 +4372,7 @@ var Pagination = forwardRef49(function Pagination2({ page, total, onPageChange,
3928
4372
  item
3929
4373
  );
3930
4374
  }),
3931
- /* @__PURE__ */ jsx51(
4375
+ /* @__PURE__ */ jsx56(
3932
4376
  IconButton,
3933
4377
  {
3934
4378
  size: "sm",
@@ -3947,8 +4391,8 @@ Pagination.displayName = "Pagination";
3947
4391
 
3948
4392
  // src/patterns/Progress/Progress.tsx
3949
4393
  import { cva as cva11 } from "class-variance-authority";
3950
- import { forwardRef as forwardRef50 } from "react";
3951
- import { jsx as jsx52, jsxs as jsxs44 } from "react/jsx-runtime";
4394
+ import { forwardRef as forwardRef55 } from "react";
4395
+ import { jsx as jsx57, jsxs as jsxs49 } from "react/jsx-runtime";
3952
4396
  var trackStyles = cva11("w-full rounded-full bg-panel-2 overflow-hidden", {
3953
4397
  variants: {
3954
4398
  size: {
@@ -3970,7 +4414,7 @@ var fillStyles = cva11("h-full rounded-full transition-[width] duration-(--durat
3970
4414
  },
3971
4415
  defaultVariants: { tone: "accent" }
3972
4416
  });
3973
- var Progress = forwardRef50(function Progress2({
4417
+ var Progress = forwardRef55(function Progress2({
3974
4418
  value = 0,
3975
4419
  max = 100,
3976
4420
  indeterminate = false,
@@ -3984,15 +4428,15 @@ var Progress = forwardRef50(function Progress2({
3984
4428
  const clamped = Math.min(max, Math.max(0, value));
3985
4429
  const pct = max > 0 ? clamped / max * 100 : 0;
3986
4430
  const display = Math.round(pct);
3987
- return /* @__PURE__ */ jsxs44("div", { ref, className: cn("flex w-full flex-col gap-2", className), ...props, children: [
3988
- label != null && /* @__PURE__ */ jsxs44("div", { className: "flex text-[12px]", children: [
3989
- /* @__PURE__ */ jsx52("span", { className: "text-text-muted", children: label }),
3990
- showValue && !indeterminate && /* @__PURE__ */ jsxs44("span", { className: "text-text ml-auto font-mono tabular-nums", children: [
4431
+ return /* @__PURE__ */ jsxs49("div", { ref, className: cn("flex w-full flex-col gap-2", className), ...props, children: [
4432
+ label != null && /* @__PURE__ */ jsxs49("div", { className: "flex text-[12px]", children: [
4433
+ /* @__PURE__ */ jsx57("span", { className: "text-text-muted", children: label }),
4434
+ showValue && !indeterminate && /* @__PURE__ */ jsxs49("span", { className: "text-text ml-auto font-mono tabular-nums", children: [
3991
4435
  display,
3992
4436
  "%"
3993
4437
  ] })
3994
4438
  ] }),
3995
- /* @__PURE__ */ jsx52(
4439
+ /* @__PURE__ */ jsx57(
3996
4440
  "div",
3997
4441
  {
3998
4442
  role: "progressbar",
@@ -4001,7 +4445,7 @@ var Progress = forwardRef50(function Progress2({
4001
4445
  "aria-valuenow": indeterminate ? void 0 : display,
4002
4446
  "aria-label": typeof label === "string" ? label : void 0,
4003
4447
  className: trackStyles({ size }),
4004
- children: indeterminate ? /* @__PURE__ */ jsx52(
4448
+ children: indeterminate ? /* @__PURE__ */ jsx57(
4005
4449
  "span",
4006
4450
  {
4007
4451
  "aria-hidden": true,
@@ -4011,94 +4455,16 @@ var Progress = forwardRef50(function Progress2({
4011
4455
  "animate-[ship-indeterminate_1.4s_linear_infinite]"
4012
4456
  )
4013
4457
  }
4014
- ) : /* @__PURE__ */ jsx52("span", { "aria-hidden": true, className: fillStyles({ tone }), style: { width: `${pct}%` } })
4458
+ ) : /* @__PURE__ */ jsx57("span", { "aria-hidden": true, className: fillStyles({ tone }), style: { width: `${pct}%` } })
4015
4459
  }
4016
4460
  )
4017
4461
  ] });
4018
4462
  });
4019
4463
  Progress.displayName = "Progress";
4020
4464
 
4021
- // src/patterns/RadialProgress/RadialProgress.tsx
4022
- import { forwardRef as forwardRef51 } from "react";
4023
- import { jsx as jsx53, jsxs as jsxs45 } from "react/jsx-runtime";
4024
- var toneStrokeClass = {
4025
- accent: "stroke-accent",
4026
- ok: "stroke-ok",
4027
- warn: "stroke-warn",
4028
- err: "stroke-err"
4029
- };
4030
- var RadialProgress = forwardRef51(
4031
- function RadialProgress2({
4032
- value,
4033
- max = 100,
4034
- size = 64,
4035
- thickness = 4,
4036
- tone,
4037
- children,
4038
- className,
4039
- "aria-label": ariaLabel,
4040
- ...props
4041
- }, ref) {
4042
- const clamped = Math.min(max, Math.max(0, value));
4043
- const pct = max > 0 ? clamped / max * 100 : 0;
4044
- const r = (size - thickness) / 2;
4045
- const c = 2 * Math.PI * r;
4046
- const dash = pct / 100 * c;
4047
- const resolvedTone = tone ?? (clamped >= max ? "ok" : "accent");
4048
- return /* @__PURE__ */ jsxs45(
4049
- "div",
4050
- {
4051
- ref,
4052
- role: "progressbar",
4053
- "aria-valuemin": 0,
4054
- "aria-valuemax": max,
4055
- "aria-valuenow": Math.round(pct),
4056
- "aria-label": ariaLabel ?? `${Math.round(pct)}%`,
4057
- className: cn("relative inline-grid place-items-center", className),
4058
- style: { width: size, height: size },
4059
- ...props,
4060
- children: [
4061
- /* @__PURE__ */ jsxs45("svg", { width: size, height: size, viewBox: `0 0 ${size} ${size}`, children: [
4062
- /* @__PURE__ */ jsx53(
4063
- "circle",
4064
- {
4065
- cx: size / 2,
4066
- cy: size / 2,
4067
- r,
4068
- fill: "none",
4069
- strokeWidth: thickness,
4070
- className: "stroke-panel-2"
4071
- }
4072
- ),
4073
- /* @__PURE__ */ jsx53(
4074
- "circle",
4075
- {
4076
- cx: size / 2,
4077
- cy: size / 2,
4078
- r,
4079
- fill: "none",
4080
- strokeWidth: thickness,
4081
- strokeLinecap: "round",
4082
- strokeDasharray: `${dash} ${c}`,
4083
- transform: `rotate(-90 ${size / 2} ${size / 2})`,
4084
- className: cn(
4085
- "transition-[stroke-dasharray] duration-(--duration-step)",
4086
- toneStrokeClass[resolvedTone]
4087
- )
4088
- }
4089
- )
4090
- ] }),
4091
- /* @__PURE__ */ jsx53("div", { className: "absolute inset-0 grid place-items-center font-mono text-[11px] font-medium tabular-nums", children: children ?? `${Math.round(pct)}%` })
4092
- ]
4093
- }
4094
- );
4095
- }
4096
- );
4097
- RadialProgress.displayName = "RadialProgress";
4098
-
4099
4465
  // src/patterns/Sparkline/Sparkline.tsx
4100
- import { forwardRef as forwardRef52, useMemo as useMemo5 } from "react";
4101
- import { jsx as jsx54, jsxs as jsxs46 } from "react/jsx-runtime";
4466
+ import { forwardRef as forwardRef56, useMemo as useMemo5 } from "react";
4467
+ import { jsx as jsx58, jsxs as jsxs50 } from "react/jsx-runtime";
4102
4468
  function buildPath(values, w, h) {
4103
4469
  if (values.length === 0) return { line: "", area: "" };
4104
4470
  const pad = 2;
@@ -4117,7 +4483,7 @@ function buildPath(values, w, h) {
4117
4483
  )} L${pad.toFixed(2)},${(h - pad).toFixed(2)} Z`;
4118
4484
  return { line, area };
4119
4485
  }
4120
- var Sparkline = forwardRef52(function Sparkline2({
4486
+ var Sparkline = forwardRef56(function Sparkline2({
4121
4487
  values,
4122
4488
  width = 160,
4123
4489
  height = 32,
@@ -4129,7 +4495,7 @@ var Sparkline = forwardRef52(function Sparkline2({
4129
4495
  ...props
4130
4496
  }, ref) {
4131
4497
  const { line, area } = useMemo5(() => buildPath(values, width, height), [values, width, height]);
4132
- return /* @__PURE__ */ jsxs46(
4498
+ return /* @__PURE__ */ jsxs50(
4133
4499
  "svg",
4134
4500
  {
4135
4501
  ref,
@@ -4141,8 +4507,8 @@ var Sparkline = forwardRef52(function Sparkline2({
4141
4507
  className: cn("inline-block", className),
4142
4508
  ...props,
4143
4509
  children: [
4144
- fill && /* @__PURE__ */ jsx54("path", { d: area, fill: stroke, fillOpacity: 0.16, stroke: "none" }),
4145
- /* @__PURE__ */ jsx54(
4510
+ fill && /* @__PURE__ */ jsx58("path", { d: area, fill: stroke, fillOpacity: 0.16, stroke: "none" }),
4511
+ /* @__PURE__ */ jsx58(
4146
4512
  "path",
4147
4513
  {
4148
4514
  d: line,
@@ -4160,16 +4526,16 @@ var Sparkline = forwardRef52(function Sparkline2({
4160
4526
  Sparkline.displayName = "Sparkline";
4161
4527
 
4162
4528
  // src/patterns/Spinner/Spinner.tsx
4163
- import { forwardRef as forwardRef53 } from "react";
4164
- import { jsx as jsx55 } from "react/jsx-runtime";
4529
+ import { forwardRef as forwardRef57 } from "react";
4530
+ import { jsx as jsx59 } from "react/jsx-runtime";
4165
4531
  var sizes = {
4166
4532
  sm: { box: "h-3 w-3", border: "border-[2px]" },
4167
4533
  md: { box: "h-4 w-4", border: "border-[2px]" },
4168
4534
  lg: { box: "h-5 w-5", border: "border-[2px]" }
4169
4535
  };
4170
- var Spinner2 = forwardRef53(function Spinner3({ size = "md", label = "Loading", className, ...props }, ref) {
4536
+ var Spinner2 = forwardRef57(function Spinner3({ size = "md", label = "Loading", className, ...props }, ref) {
4171
4537
  const s = sizes[size];
4172
- return /* @__PURE__ */ jsx55(
4538
+ return /* @__PURE__ */ jsx59(
4173
4539
  "span",
4174
4540
  {
4175
4541
  ref,
@@ -4177,7 +4543,7 @@ var Spinner2 = forwardRef53(function Spinner3({ size = "md", label = "Loading",
4177
4543
  "aria-label": label,
4178
4544
  className: cn("inline-block", className),
4179
4545
  ...props,
4180
- children: /* @__PURE__ */ jsx55(
4546
+ children: /* @__PURE__ */ jsx59(
4181
4547
  "span",
4182
4548
  {
4183
4549
  "aria-hidden": true,
@@ -4194,15 +4560,15 @@ var Spinner2 = forwardRef53(function Spinner3({ size = "md", label = "Loading",
4194
4560
  Spinner2.displayName = "Spinner";
4195
4561
 
4196
4562
  // src/patterns/Stepper/Stepper.tsx
4197
- import { forwardRef as forwardRef54, Fragment as Fragment4 } from "react";
4198
- import { jsx as jsx56, jsxs as jsxs47 } from "react/jsx-runtime";
4563
+ import { forwardRef as forwardRef58, Fragment as Fragment5 } from "react";
4564
+ import { jsx as jsx60, jsxs as jsxs51 } from "react/jsx-runtime";
4199
4565
  var dotBase = "h-6 w-6 rounded-full grid place-items-center text-[11px] font-mono font-semibold border";
4200
4566
  var dotStateClass = {
4201
4567
  done: "bg-accent text-on-accent border-accent",
4202
4568
  current: "bg-accent-dim text-accent border-accent",
4203
4569
  upcoming: "bg-panel text-text-dim border-border"
4204
4570
  };
4205
- var labelStateClass = {
4571
+ var labelStateClass2 = {
4206
4572
  done: "text-text",
4207
4573
  current: "text-text font-medium",
4208
4574
  upcoming: "text-text-dim"
@@ -4212,8 +4578,8 @@ function stateFor(index, current) {
4212
4578
  if (index === current) return "current";
4213
4579
  return "upcoming";
4214
4580
  }
4215
- var Stepper = forwardRef54(function Stepper2({ steps, current, className, ...props }, ref) {
4216
- return /* @__PURE__ */ jsx56(
4581
+ var Stepper = forwardRef58(function Stepper2({ steps, current, className, ...props }, ref) {
4582
+ return /* @__PURE__ */ jsx60(
4217
4583
  "ol",
4218
4584
  {
4219
4585
  ref,
@@ -4225,19 +4591,19 @@ var Stepper = forwardRef54(function Stepper2({ steps, current, className, ...pro
4225
4591
  const id = typeof step === "string" ? void 0 : step.id;
4226
4592
  const state = stateFor(i, current);
4227
4593
  const connectorActive = i < current;
4228
- return /* @__PURE__ */ jsxs47(Fragment4, { children: [
4229
- /* @__PURE__ */ jsxs47(
4594
+ return /* @__PURE__ */ jsxs51(Fragment5, { children: [
4595
+ /* @__PURE__ */ jsxs51(
4230
4596
  "li",
4231
4597
  {
4232
4598
  "aria-current": state === "current" ? "step" : void 0,
4233
4599
  className: "flex items-center gap-2",
4234
4600
  children: [
4235
- /* @__PURE__ */ jsx56("span", { "aria-hidden": true, className: cn(dotBase, dotStateClass[state]), children: state === "done" ? "\u2713" : i + 1 }),
4236
- /* @__PURE__ */ jsx56("span", { className: cn("text-[12px]", labelStateClass[state]), children: label })
4601
+ /* @__PURE__ */ jsx60("span", { "aria-hidden": true, className: cn(dotBase, dotStateClass[state]), children: state === "done" ? "\u2713" : i + 1 }),
4602
+ /* @__PURE__ */ jsx60("span", { className: cn("text-[12px]", labelStateClass2[state]), children: label })
4237
4603
  ]
4238
4604
  }
4239
4605
  ),
4240
- i < steps.length - 1 && /* @__PURE__ */ jsx56(
4606
+ i < steps.length - 1 && /* @__PURE__ */ jsx60(
4241
4607
  "span",
4242
4608
  {
4243
4609
  "aria-hidden": true,
@@ -4254,8 +4620,8 @@ Stepper.displayName = "Stepper";
4254
4620
  // src/patterns/Tabs/Tabs.tsx
4255
4621
  import * as RadixTabs from "@radix-ui/react-tabs";
4256
4622
  import { cva as cva12 } from "class-variance-authority";
4257
- import { createContext as createContext2, forwardRef as forwardRef55, useContext as useContext2 } from "react";
4258
- import { jsx as jsx57 } from "react/jsx-runtime";
4623
+ import { createContext as createContext2, forwardRef as forwardRef59, useContext as useContext2 } from "react";
4624
+ import { jsx as jsx61 } from "react/jsx-runtime";
4259
4625
  var TabsVariantContext = createContext2("underline");
4260
4626
  var tabsListStyles = cva12("", {
4261
4627
  variants: {
@@ -4286,8 +4652,8 @@ var tabsTriggerStyles = cva12(
4286
4652
  }
4287
4653
  }
4288
4654
  );
4289
- var Tabs = forwardRef55(function Tabs2({ variant = "underline", className, ...props }, ref) {
4290
- return /* @__PURE__ */ jsx57(TabsVariantContext.Provider, { value: variant, children: /* @__PURE__ */ jsx57(
4655
+ var Tabs = forwardRef59(function Tabs2({ variant = "underline", className, ...props }, ref) {
4656
+ return /* @__PURE__ */ jsx61(TabsVariantContext.Provider, { value: variant, children: /* @__PURE__ */ jsx61(
4291
4657
  RadixTabs.Root,
4292
4658
  {
4293
4659
  ref,
@@ -4297,14 +4663,14 @@ var Tabs = forwardRef55(function Tabs2({ variant = "underline", className, ...pr
4297
4663
  ) });
4298
4664
  });
4299
4665
  Tabs.displayName = "Tabs";
4300
- var TabsList = forwardRef55(function TabsList2({ className, ...props }, ref) {
4666
+ var TabsList = forwardRef59(function TabsList2({ className, ...props }, ref) {
4301
4667
  const variant = useContext2(TabsVariantContext);
4302
- return /* @__PURE__ */ jsx57(RadixTabs.List, { ref, className: cn(tabsListStyles({ variant }), className), ...props });
4668
+ return /* @__PURE__ */ jsx61(RadixTabs.List, { ref, className: cn(tabsListStyles({ variant }), className), ...props });
4303
4669
  });
4304
4670
  TabsList.displayName = "TabsList";
4305
- var Tab = forwardRef55(function Tab2({ className, ...props }, ref) {
4671
+ var Tab = forwardRef59(function Tab2({ className, ...props }, ref) {
4306
4672
  const variant = useContext2(TabsVariantContext);
4307
- return /* @__PURE__ */ jsx57(
4673
+ return /* @__PURE__ */ jsx61(
4308
4674
  RadixTabs.Trigger,
4309
4675
  {
4310
4676
  ref,
@@ -4314,9 +4680,9 @@ var Tab = forwardRef55(function Tab2({ className, ...props }, ref) {
4314
4680
  );
4315
4681
  });
4316
4682
  Tab.displayName = "Tab";
4317
- var TabsContent = forwardRef55(
4683
+ var TabsContent = forwardRef59(
4318
4684
  function TabsContent2({ className, ...props }, ref) {
4319
- return /* @__PURE__ */ jsx57(
4685
+ return /* @__PURE__ */ jsx61(
4320
4686
  RadixTabs.Content,
4321
4687
  {
4322
4688
  ref,
@@ -4332,8 +4698,8 @@ var TabsContent = forwardRef55(
4332
4698
  TabsContent.displayName = "TabsContent";
4333
4699
 
4334
4700
  // src/patterns/Timeline/Timeline.tsx
4335
- import { forwardRef as forwardRef56 } from "react";
4336
- import { jsx as jsx58, jsxs as jsxs48 } from "react/jsx-runtime";
4701
+ import { forwardRef as forwardRef60 } from "react";
4702
+ import { jsx as jsx62, jsxs as jsxs52 } from "react/jsx-runtime";
4337
4703
  var ringClass = {
4338
4704
  accent: "border-accent",
4339
4705
  ok: "border-ok",
@@ -4341,8 +4707,8 @@ var ringClass = {
4341
4707
  err: "border-err",
4342
4708
  muted: "border-text-dim"
4343
4709
  };
4344
- var Timeline = forwardRef56(function Timeline2({ events, className, children, ...props }, ref) {
4345
- return /* @__PURE__ */ jsx58(
4710
+ var Timeline = forwardRef60(function Timeline2({ events, className, children, ...props }, ref) {
4711
+ return /* @__PURE__ */ jsx62(
4346
4712
  "ol",
4347
4713
  {
4348
4714
  ref,
@@ -4352,14 +4718,14 @@ var Timeline = forwardRef56(function Timeline2({ events, className, children, ..
4352
4718
  className
4353
4719
  ),
4354
4720
  ...props,
4355
- children: events ? events.map((e, i) => /* @__PURE__ */ jsx58(TimelineItem, { tone: e.tone, time: e.time, description: e.description, children: e.title }, i)) : children
4721
+ children: events ? events.map((e, i) => /* @__PURE__ */ jsx62(TimelineItem, { tone: e.tone, time: e.time, description: e.description, children: e.title }, i)) : children
4356
4722
  }
4357
4723
  );
4358
4724
  });
4359
4725
  Timeline.displayName = "Timeline";
4360
- var TimelineItem = forwardRef56(function TimelineItem2({ tone = "accent", description, time, className, children, ...props }, ref) {
4361
- return /* @__PURE__ */ jsxs48("li", { ref, className: cn("relative mb-[18px] last:mb-0", className), ...props, children: [
4362
- /* @__PURE__ */ jsx58(
4726
+ var TimelineItem = forwardRef60(function TimelineItem2({ tone = "accent", description, time, className, children, ...props }, ref) {
4727
+ return /* @__PURE__ */ jsxs52("li", { ref, className: cn("relative mb-[18px] last:mb-0", className), ...props, children: [
4728
+ /* @__PURE__ */ jsx62(
4363
4729
  "span",
4364
4730
  {
4365
4731
  "aria-hidden": true,
@@ -4369,18 +4735,107 @@ var TimelineItem = forwardRef56(function TimelineItem2({ tone = "accent", descri
4369
4735
  )
4370
4736
  }
4371
4737
  ),
4372
- /* @__PURE__ */ jsx58("div", { className: "text-[13px] font-medium", children }),
4373
- description && /* @__PURE__ */ jsx58("div", { className: "text-text-muted text-[12px]", children: description }),
4374
- time && /* @__PURE__ */ jsx58("div", { className: "text-text-dim mt-[2px] font-mono text-[10px]", children: time })
4738
+ /* @__PURE__ */ jsx62("div", { className: "text-[13px] font-medium", children }),
4739
+ description && /* @__PURE__ */ jsx62("div", { className: "text-text-muted text-[12px]", children: description }),
4740
+ time && /* @__PURE__ */ jsx62("div", { className: "text-text-dim mt-[2px] font-mono text-[10px]", children: time })
4375
4741
  ] });
4376
4742
  });
4377
4743
  TimelineItem.displayName = "TimelineItem";
4378
4744
 
4745
+ // src/patterns/Timeline/ActivityTimeline.tsx
4746
+ import { forwardRef as forwardRef61 } from "react";
4747
+
4748
+ // src/patterns/Timeline/formatRelative.ts
4749
+ var SECOND = 1e3;
4750
+ var MINUTE = 60 * SECOND;
4751
+ var HOUR = 60 * MINUTE;
4752
+ var DAY = 24 * HOUR;
4753
+ var WEEK = 7 * DAY;
4754
+ var MONTH = 30 * DAY;
4755
+ var YEAR = 365 * DAY;
4756
+ var UNITS = [
4757
+ { ms: YEAR, short: "y" },
4758
+ { ms: MONTH, short: "mo" },
4759
+ { ms: WEEK, short: "w" },
4760
+ { ms: DAY, short: "d" },
4761
+ { ms: HOUR, short: "h" },
4762
+ { ms: MINUTE, short: "m" },
4763
+ { ms: SECOND, short: "s" }
4764
+ ];
4765
+ function formatRelative(input, now = /* @__PURE__ */ new Date()) {
4766
+ const target = input instanceof Date ? input : new Date(input);
4767
+ if (Number.isNaN(target.getTime())) return "";
4768
+ const diffMs = now.getTime() - target.getTime();
4769
+ const abs = Math.abs(diffMs);
4770
+ if (abs < 5 * SECOND) return "just now";
4771
+ for (const unit of UNITS) {
4772
+ if (abs >= unit.ms) {
4773
+ const n = Math.floor(abs / unit.ms);
4774
+ return diffMs >= 0 ? `${n}${unit.short} ago` : `in ${n}${unit.short}`;
4775
+ }
4776
+ }
4777
+ return "just now";
4778
+ }
4779
+
4780
+ // src/patterns/Timeline/ActivityTimeline.tsx
4781
+ import { jsx as jsx63, jsxs as jsxs53 } from "react/jsx-runtime";
4782
+ var ringClass2 = {
4783
+ accent: "border-accent",
4784
+ ok: "border-ok",
4785
+ warn: "border-warn",
4786
+ err: "border-err",
4787
+ muted: "border-text-dim"
4788
+ };
4789
+ var ActivityTimeline = forwardRef61(
4790
+ function ActivityTimeline2({ events, relativeNow, className, ...props }, ref) {
4791
+ const now = relativeNow ?? /* @__PURE__ */ new Date();
4792
+ return /* @__PURE__ */ jsx63(
4793
+ "ol",
4794
+ {
4795
+ ref,
4796
+ className: cn(
4797
+ "relative m-0 list-none p-0 pl-6",
4798
+ "before:bg-border before:absolute before:top-[6px] before:bottom-[6px] before:left-[7px] before:w-px",
4799
+ className
4800
+ ),
4801
+ ...props,
4802
+ children: events.map((event) => {
4803
+ const tone = event.tone ?? "accent";
4804
+ const time = formatRelative(event.at, now);
4805
+ return /* @__PURE__ */ jsxs53("li", { className: "relative mb-4 last:mb-0", children: [
4806
+ /* @__PURE__ */ jsx63(
4807
+ "span",
4808
+ {
4809
+ "aria-hidden": true,
4810
+ className: cn(
4811
+ "bg-bg absolute top-[4px] -left-6 h-[14px] w-[14px] rounded-full border-2",
4812
+ ringClass2[tone]
4813
+ )
4814
+ }
4815
+ ),
4816
+ /* @__PURE__ */ jsxs53("div", { className: "flex items-baseline gap-2", children: [
4817
+ event.icon && /* @__PURE__ */ jsx63("span", { "aria-hidden": true, className: "text-text-muted font-mono text-[12px]", children: event.icon }),
4818
+ /* @__PURE__ */ jsx63("div", { className: "text-[13px] font-medium", children: event.title }),
4819
+ time && /* @__PURE__ */ jsx63("time", { className: "text-text-dim ml-auto font-mono text-[10px]", children: time })
4820
+ ] }),
4821
+ event.actor && /* @__PURE__ */ jsxs53("div", { className: "text-text-muted mt-[2px] flex items-center gap-[6px] text-[12px]", children: [
4822
+ event.actor.avatar && /* @__PURE__ */ jsx63("span", { "aria-hidden": true, className: "inline-flex", children: event.actor.avatar }),
4823
+ /* @__PURE__ */ jsx63("span", { children: event.actor.name })
4824
+ ] }),
4825
+ event.payload && /* @__PURE__ */ jsx63("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 })
4826
+ ] }, event.id);
4827
+ })
4828
+ }
4829
+ );
4830
+ }
4831
+ );
4832
+ ActivityTimeline.displayName = "ActivityTimeline";
4833
+
4379
4834
  // src/patterns/Topbar/Topbar.tsx
4380
- import { forwardRef as forwardRef57 } from "react";
4381
- import { jsx as jsx59, jsxs as jsxs49 } from "react/jsx-runtime";
4382
- var Topbar = forwardRef57(function Topbar2({ title, leading, actions, className, children, ...props }, ref) {
4383
- return /* @__PURE__ */ jsxs49(
4835
+ import { forwardRef as forwardRef62 } from "react";
4836
+ import { jsx as jsx64, jsxs as jsxs54 } from "react/jsx-runtime";
4837
+ var Topbar = forwardRef62(function Topbar2({ title, leading, actions, className, children, ...props }, ref) {
4838
+ return /* @__PURE__ */ jsxs54(
4384
4839
  "header",
4385
4840
  {
4386
4841
  ref,
@@ -4391,9 +4846,9 @@ var Topbar = forwardRef57(function Topbar2({ title, leading, actions, className,
4391
4846
  ...props,
4392
4847
  children: [
4393
4848
  leading,
4394
- title && /* @__PURE__ */ jsx59("div", { className: "text-[13px] font-medium", children: title }),
4395
- /* @__PURE__ */ jsx59("div", { className: "flex flex-1 items-center" }),
4396
- actions && /* @__PURE__ */ jsx59("div", { className: "flex items-center gap-3", children: actions }),
4849
+ title && /* @__PURE__ */ jsx64("div", { className: "text-[13px] font-medium", children: title }),
4850
+ /* @__PURE__ */ jsx64("div", { className: "flex flex-1 items-center" }),
4851
+ actions && /* @__PURE__ */ jsx64("div", { className: "flex items-center gap-3", children: actions }),
4397
4852
  children
4398
4853
  ]
4399
4854
  }
@@ -4403,14 +4858,14 @@ Topbar.displayName = "Topbar";
4403
4858
 
4404
4859
  // src/patterns/Tree/Tree.tsx
4405
4860
  import {
4406
- forwardRef as forwardRef58,
4407
- useCallback as useCallback10,
4861
+ forwardRef as forwardRef63,
4862
+ useCallback as useCallback11,
4408
4863
  useEffect as useEffect10,
4409
4864
  useMemo as useMemo6,
4410
4865
  useRef as useRef8,
4411
- useState as useState14
4866
+ useState as useState15
4412
4867
  } from "react";
4413
- import { jsx as jsx60, jsxs as jsxs50 } from "react/jsx-runtime";
4868
+ import { jsx as jsx65, jsxs as jsxs55 } from "react/jsx-runtime";
4414
4869
  var EMPTY_SET2 = /* @__PURE__ */ new Set();
4415
4870
  function flattenVisible(items, expanded, level, parentId, out) {
4416
4871
  for (const item of items) {
@@ -4421,7 +4876,7 @@ function flattenVisible(items, expanded, level, parentId, out) {
4421
4876
  }
4422
4877
  }
4423
4878
  }
4424
- var Tree = forwardRef58(function Tree2({
4879
+ var Tree = forwardRef63(function Tree2({
4425
4880
  items,
4426
4881
  expanded: expandedProp,
4427
4882
  defaultExpanded,
@@ -4449,7 +4904,7 @@ var Tree = forwardRef58(function Tree2({
4449
4904
  flattenVisible(items, expandedSet, 1, null, out);
4450
4905
  return out;
4451
4906
  }, [items, expandedSet]);
4452
- const [activeId, setActiveId] = useState14(null);
4907
+ const [activeId, setActiveId] = useState15(null);
4453
4908
  useEffect10(() => {
4454
4909
  if (activeId && !flatVisible.some((f) => f.id === activeId)) {
4455
4910
  setActiveId(null);
@@ -4461,7 +4916,7 @@ var Tree = forwardRef58(function Tree2({
4461
4916
  return flatVisible[0]?.id ?? null;
4462
4917
  }, [activeId, flatVisible, value]);
4463
4918
  const listRef = useRef8(null);
4464
- const setRefs = useCallback10(
4919
+ const setRefs = useCallback11(
4465
4920
  (node) => {
4466
4921
  listRef.current = node;
4467
4922
  if (typeof ref === "function") ref(node);
@@ -4469,20 +4924,20 @@ var Tree = forwardRef58(function Tree2({
4469
4924
  },
4470
4925
  [ref]
4471
4926
  );
4472
- const focusItem = useCallback10((id) => {
4927
+ const focusItem = useCallback11((id) => {
4473
4928
  const root = listRef.current;
4474
4929
  if (!root) return;
4475
4930
  const el = root.querySelector(`[data-treeitem-id="${CSS.escape(id)}"]`);
4476
4931
  el?.focus();
4477
4932
  }, []);
4478
- const moveActive = useCallback10(
4933
+ const moveActive = useCallback11(
4479
4934
  (id) => {
4480
4935
  setActiveId(id);
4481
4936
  queueMicrotask(() => focusItem(id));
4482
4937
  },
4483
4938
  [focusItem]
4484
4939
  );
4485
- const toggle = useCallback10(
4940
+ const toggle = useCallback11(
4486
4941
  (id) => {
4487
4942
  setExpanded((prev) => {
4488
4943
  const next = new Set(prev ?? EMPTY_SET2);
@@ -4493,7 +4948,7 @@ var Tree = forwardRef58(function Tree2({
4493
4948
  },
4494
4949
  [setExpanded]
4495
4950
  );
4496
- const expand = useCallback10(
4951
+ const expand = useCallback11(
4497
4952
  (id) => {
4498
4953
  setExpanded((prev) => {
4499
4954
  const base = prev ?? EMPTY_SET2;
@@ -4505,7 +4960,7 @@ var Tree = forwardRef58(function Tree2({
4505
4960
  },
4506
4961
  [setExpanded]
4507
4962
  );
4508
- const collapse = useCallback10(
4963
+ const collapse = useCallback11(
4509
4964
  (id) => {
4510
4965
  setExpanded((prev) => {
4511
4966
  const base = prev ?? EMPTY_SET2;
@@ -4517,13 +4972,13 @@ var Tree = forwardRef58(function Tree2({
4517
4972
  },
4518
4973
  [setExpanded]
4519
4974
  );
4520
- const selectItem = useCallback10(
4975
+ const selectItem = useCallback11(
4521
4976
  (id) => {
4522
4977
  setValue(id);
4523
4978
  },
4524
4979
  [setValue]
4525
4980
  );
4526
- const handleKeyDown = useCallback10(
4981
+ const handleKeyDown = useCallback11(
4527
4982
  (e) => {
4528
4983
  onKeyDown?.(e);
4529
4984
  if (e.defaultPrevented) return;
@@ -4603,7 +5058,7 @@ var Tree = forwardRef58(function Tree2({
4603
5058
  toggle
4604
5059
  ]
4605
5060
  );
4606
- return /* @__PURE__ */ jsx60(
5061
+ return /* @__PURE__ */ jsx65(
4607
5062
  "ul",
4608
5063
  {
4609
5064
  ref: setRefs,
@@ -4611,7 +5066,7 @@ var Tree = forwardRef58(function Tree2({
4611
5066
  className: cn("flex flex-col gap-px text-[12px]", className),
4612
5067
  onKeyDown: handleKeyDown,
4613
5068
  ...props,
4614
- children: items.map((item) => /* @__PURE__ */ jsx60(
5069
+ children: items.map((item) => /* @__PURE__ */ jsx65(
4615
5070
  TreeItemRow,
4616
5071
  {
4617
5072
  item,
@@ -4646,8 +5101,8 @@ function TreeItemRow({
4646
5101
  const isExpanded = hasChildren && expanded.has(item.id);
4647
5102
  const isSelected = selected === item.id;
4648
5103
  const isTabStop = tabStopId === item.id;
4649
- return /* @__PURE__ */ jsxs50("li", { role: "none", children: [
4650
- /* @__PURE__ */ jsxs50(
5104
+ return /* @__PURE__ */ jsxs55("li", { role: "none", children: [
5105
+ /* @__PURE__ */ jsxs55(
4651
5106
  "div",
4652
5107
  {
4653
5108
  role: "treeitem",
@@ -4670,14 +5125,14 @@ function TreeItemRow({
4670
5125
  isSelected ? "bg-accent-dim text-accent" : "text-text hover:bg-panel-2"
4671
5126
  ),
4672
5127
  children: [
4673
- /* @__PURE__ */ jsx60("span", { "aria-hidden": true, className: "text-text-dim grid w-3 place-items-center text-[10px]", children: hasChildren ? isExpanded ? "\u25BE" : "\u25B8" : "" }),
4674
- item.icon && /* @__PURE__ */ jsx60("span", { "aria-hidden": true, className: "text-[12px] opacity-80", children: item.icon }),
4675
- /* @__PURE__ */ jsx60("span", { className: "flex-1 truncate", children: item.label }),
5128
+ /* @__PURE__ */ jsx65("span", { "aria-hidden": true, className: "text-text-dim grid w-3 place-items-center text-[10px]", children: hasChildren ? isExpanded ? "\u25BE" : "\u25B8" : "" }),
5129
+ item.icon && /* @__PURE__ */ jsx65("span", { "aria-hidden": true, className: "text-[12px] opacity-80", children: item.icon }),
5130
+ /* @__PURE__ */ jsx65("span", { className: "flex-1 truncate", children: item.label }),
4676
5131
  item.trailing
4677
5132
  ]
4678
5133
  }
4679
5134
  ),
4680
- hasChildren && isExpanded && /* @__PURE__ */ jsx60("ul", { role: "group", className: "flex flex-col gap-px", children: (item.children ?? []).map((child) => /* @__PURE__ */ jsx60(
5135
+ hasChildren && isExpanded && /* @__PURE__ */ jsx65("ul", { role: "group", className: "flex flex-col gap-px", children: (item.children ?? []).map((child) => /* @__PURE__ */ jsx65(
4681
5136
  TreeItemRow,
4682
5137
  {
4683
5138
  item: child,
@@ -4693,7 +5148,83 @@ function TreeItemRow({
4693
5148
  )) })
4694
5149
  ] });
4695
5150
  }
5151
+
5152
+ // src/patterns/WizardDialog/WizardDialog.tsx
5153
+ import * as RadixDialog5 from "@radix-ui/react-dialog";
5154
+ import { forwardRef as forwardRef64, useCallback as useCallback12, useMemo as useMemo7, useState as useState16 } from "react";
5155
+ import { jsx as jsx66, jsxs as jsxs56 } from "react/jsx-runtime";
5156
+ var WizardDialog = forwardRef64(function WizardDialog2({
5157
+ open,
5158
+ defaultOpen,
5159
+ onOpenChange,
5160
+ steps,
5161
+ initialStep = 0,
5162
+ onComplete,
5163
+ title,
5164
+ description,
5165
+ width = 560,
5166
+ nextLabel = "Next",
5167
+ completeLabel = "Done",
5168
+ backLabel = "Back",
5169
+ cancelLabel,
5170
+ onCancel
5171
+ }, ref) {
5172
+ const [current, setCurrent] = useState16(initialStep);
5173
+ const total = steps.length;
5174
+ const safeCurrent = Math.min(current, Math.max(0, total - 1));
5175
+ const step = steps[safeCurrent];
5176
+ const goTo = useCallback12(
5177
+ (index) => {
5178
+ setCurrent(Math.min(Math.max(0, index), Math.max(0, total - 1)));
5179
+ },
5180
+ [total]
5181
+ );
5182
+ const goNext = useCallback12(() => setCurrent((c) => Math.min(c + 1, total - 1)), [total]);
5183
+ const goBack = useCallback12(() => setCurrent((c) => Math.max(c - 1, 0)), []);
5184
+ const ctx = useMemo7(
5185
+ () => ({
5186
+ current: safeCurrent,
5187
+ total,
5188
+ goNext,
5189
+ goBack,
5190
+ goTo,
5191
+ isFirst: safeCurrent === 0,
5192
+ isLast: safeCurrent >= total - 1
5193
+ }),
5194
+ [safeCurrent, total, goNext, goBack, goTo]
5195
+ );
5196
+ const stepperSteps = useMemo7(() => steps.map((s) => ({ id: s.id, label: s.label })), [steps]);
5197
+ if (!step) return null;
5198
+ const canAdvance = step.canAdvance ? step.canAdvance(ctx) : true;
5199
+ const body = typeof step.content === "function" ? step.content(ctx) : step.content;
5200
+ const handlePrimary = () => {
5201
+ if (ctx.isLast) {
5202
+ onComplete?.();
5203
+ } else {
5204
+ goNext();
5205
+ }
5206
+ };
5207
+ return /* @__PURE__ */ jsx66(DialogRoot, { open, defaultOpen, onOpenChange, children: /* @__PURE__ */ jsxs56(DialogContent, { ref, width, children: [
5208
+ title && /* @__PURE__ */ jsx66(WizardTitle, { children: title }),
5209
+ description && /* @__PURE__ */ jsx66(WizardDescription, { children: description }),
5210
+ /* @__PURE__ */ jsx66("div", { className: "mb-5", children: /* @__PURE__ */ jsx66(Stepper, { steps: stepperSteps, current: safeCurrent }) }),
5211
+ /* @__PURE__ */ jsx66("div", { className: "mb-5", children: body }),
5212
+ /* @__PURE__ */ jsxs56("div", { className: "flex justify-end gap-2", children: [
5213
+ cancelLabel && /* @__PURE__ */ jsx66(Button, { type: "button", variant: "ghost", onClick: onCancel, children: cancelLabel }),
5214
+ /* @__PURE__ */ jsx66(Button, { type: "button", variant: "secondary", onClick: goBack, disabled: ctx.isFirst, children: backLabel }),
5215
+ /* @__PURE__ */ jsx66(Button, { type: "button", variant: "primary", onClick: handlePrimary, disabled: !canAdvance, children: ctx.isLast ? completeLabel : nextLabel })
5216
+ ] })
5217
+ ] }) });
5218
+ });
5219
+ function WizardTitle({ children }) {
5220
+ return /* @__PURE__ */ jsx66(RadixDialog5.Title, { className: "mb-2 text-[16px] font-medium", children });
5221
+ }
5222
+ function WizardDescription({ children }) {
5223
+ return /* @__PURE__ */ jsx66(RadixDialog5.Description, { className: "text-text-muted mb-4 text-[13px] leading-[1.55]", children });
5224
+ }
5225
+ WizardDialog.displayName = "WizardDialog";
4696
5226
  export {
5227
+ ActivityTimeline,
4697
5228
  Alert,
4698
5229
  AlertDialog,
4699
5230
  AlertDialogAction,
@@ -4746,6 +5277,8 @@ export {
4746
5277
  FAB,
4747
5278
  Field,
4748
5279
  FileChip,
5280
+ FilterPanel,
5281
+ HealthScore,
4749
5282
  HoverCard,
4750
5283
  HoverCardContent,
4751
5284
  HoverCardPortal,
@@ -4767,6 +5300,7 @@ export {
4767
5300
  NavItem,
4768
5301
  NavSection,
4769
5302
  OTP,
5303
+ OnboardingChecklist,
4770
5304
  Pagination,
4771
5305
  Popover,
4772
5306
  PopoverAnchor,
@@ -4780,6 +5314,7 @@ export {
4780
5314
  RadialProgress,
4781
5315
  Radio,
4782
5316
  RadioGroup,
5317
+ ScrollArea,
4783
5318
  SearchInput,
4784
5319
  Select,
4785
5320
  SelectContent,
@@ -4820,11 +5355,13 @@ export {
4820
5355
  TooltipTrigger,
4821
5356
  Topbar,
4822
5357
  Tree,
5358
+ WizardDialog,
4823
5359
  badgeStyles,
4824
5360
  buttonStyles,
4825
5361
  cardStyles,
4826
5362
  cn,
4827
5363
  filterCommandItems,
5364
+ formatRelative,
4828
5365
  iconButtonStyles,
4829
5366
  useControllableState,
4830
5367
  useDisclosure,