@orangecheck/app-design 1.4.1 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/chrome.d.mts +2 -2
  2. package/dist/chrome.d.ts +2 -2
  3. package/dist/chrome.js +162 -35
  4. package/dist/chrome.js.map +1 -1
  5. package/dist/chrome.mjs +163 -36
  6. package/dist/chrome.mjs.map +1 -1
  7. package/dist/components.d.mts +99 -6
  8. package/dist/components.d.ts +99 -6
  9. package/dist/components.js +546 -26
  10. package/dist/components.js.map +1 -1
  11. package/dist/components.mjs +535 -28
  12. package/dist/components.mjs.map +1 -1
  13. package/dist/index.d.mts +4 -4
  14. package/dist/index.d.ts +4 -4
  15. package/dist/index.js +737 -82
  16. package/dist/index.js.map +1 -1
  17. package/dist/index.mjs +727 -84
  18. package/dist/index.mjs.map +1 -1
  19. package/dist/mdx.js.map +1 -1
  20. package/dist/mdx.mjs.map +1 -1
  21. package/dist/primitives.d.mts +1 -0
  22. package/dist/primitives.d.ts +1 -0
  23. package/dist/primitives.js +27 -0
  24. package/dist/primitives.js.map +1 -1
  25. package/dist/primitives.mjs +27 -0
  26. package/dist/primitives.mjs.map +1 -1
  27. package/dist/session.d.mts +3 -3
  28. package/dist/session.d.ts +3 -3
  29. package/dist/session.js.map +1 -1
  30. package/dist/session.mjs.map +1 -1
  31. package/dist/styles/chart.css +76 -0
  32. package/dist/styles/theme.css +7 -0
  33. package/dist/styles/tokens.css +18 -0
  34. package/dist/styles.css +1 -0
  35. package/dist/tokens.d.mts +314 -21
  36. package/dist/tokens.d.ts +314 -21
  37. package/dist/tokens.js +166 -26
  38. package/dist/tokens.js.map +1 -1
  39. package/dist/tokens.mjs +165 -27
  40. package/dist/tokens.mjs.map +1 -1
  41. package/dist/{tool-shell-D8Q8XX11.d.mts → tool-shell-CQZNRUgH.d.mts} +8 -4
  42. package/dist/{tool-shell-gmlj47Ie.d.ts → tool-shell-CRmceGrV.d.ts} +8 -4
  43. package/dist/{tools-DFIxIj5p.d.mts → tools-Bg1gi2HO.d.mts} +1 -1
  44. package/dist/{tools-BggNN5DV.d.ts → tools-Bw7RhO92.d.ts} +1 -1
  45. package/package.json +2 -2
@@ -12,13 +12,16 @@ var SeparatorPrimitive = require('@radix-ui/react-separator');
12
12
  require('next-themes');
13
13
  require('sonner');
14
14
  var Link = require('next/link');
15
+ var DialogPrimitive = require('@radix-ui/react-dialog');
16
+ var DropdownMenuPrimitive = require('@radix-ui/react-dropdown-menu');
17
+ var PopoverPrimitive = require('@radix-ui/react-popover');
18
+ var TooltipPrimitive = require('@radix-ui/react-tooltip');
15
19
  var router = require('next/compat/router');
16
20
  var CheckboxPrimitive = require('@radix-ui/react-checkbox');
17
21
  var LabelPrimitive = require('@radix-ui/react-label');
18
22
  var RadioGroupPrimitive = require('@radix-ui/react-radio-group');
19
23
  var SelectPrimitive = require('@radix-ui/react-select');
20
24
  var SwitchPrimitive = require('@radix-ui/react-switch');
21
- var DialogPrimitive = require('@radix-ui/react-dialog');
22
25
 
23
26
  function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
24
27
 
@@ -43,12 +46,15 @@ function _interopNamespace(e) {
43
46
  var TabsPrimitive__namespace = /*#__PURE__*/_interopNamespace(TabsPrimitive);
44
47
  var SeparatorPrimitive__namespace = /*#__PURE__*/_interopNamespace(SeparatorPrimitive);
45
48
  var Link__default = /*#__PURE__*/_interopDefault(Link);
49
+ var DialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(DialogPrimitive);
50
+ var DropdownMenuPrimitive__namespace = /*#__PURE__*/_interopNamespace(DropdownMenuPrimitive);
51
+ var PopoverPrimitive__namespace = /*#__PURE__*/_interopNamespace(PopoverPrimitive);
52
+ var TooltipPrimitive__namespace = /*#__PURE__*/_interopNamespace(TooltipPrimitive);
46
53
  var CheckboxPrimitive__namespace = /*#__PURE__*/_interopNamespace(CheckboxPrimitive);
47
54
  var LabelPrimitive__namespace = /*#__PURE__*/_interopNamespace(LabelPrimitive);
48
55
  var RadioGroupPrimitive__namespace = /*#__PURE__*/_interopNamespace(RadioGroupPrimitive);
49
56
  var SelectPrimitive__namespace = /*#__PURE__*/_interopNamespace(SelectPrimitive);
50
57
  var SwitchPrimitive__namespace = /*#__PURE__*/_interopNamespace(SwitchPrimitive);
51
- var DialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(DialogPrimitive);
52
58
 
53
59
  var merge = tailwindMerge.extendTailwindMerge({
54
60
  extend: {
@@ -564,7 +570,7 @@ var JS_TAG = /<\/?(?=[A-Za-z])/y;
564
570
  var JS_TAG_NAME = /[A-Za-z][\w$.:-]*/y;
565
571
  var JS_PUNCT = /=>|\.\.\.|[{}()[\];,.<>=+\-*/%!?:&|^~#]/y;
566
572
  var JSX_BEFORE = /* @__PURE__ */ new Set(["(", ",", "=", "?", ":", "{", "[", ";", ">", "&&", "||", "=>", "return"]);
567
- function scanJs(src, emit, jsx35) {
573
+ function scanJs(src, emit, jsx38) {
568
574
  let i = 0;
569
575
  let prev = "";
570
576
  let tagDepth = 0;
@@ -590,7 +596,7 @@ function scanJs(src, emit, jsx35) {
590
596
  sig('"');
591
597
  continue;
592
598
  }
593
- if (jsx35 && tagDepth === 0 && (m = at(JS_TAG, src, i)) && (prev === "" || JSX_BEFORE.has(prev))) {
599
+ if (jsx38 && tagDepth === 0 && (m = at(JS_TAG, src, i)) && (prev === "" || JSX_BEFORE.has(prev))) {
594
600
  const name = at(JS_TAG_NAME, src, i + m.length);
595
601
  if (name) {
596
602
  emit(m);
@@ -602,7 +608,7 @@ function scanJs(src, emit, jsx35) {
602
608
  continue;
603
609
  }
604
610
  }
605
- if (jsx35 && tagDepth > 0 && braceInTag === 0) {
611
+ if (jsx38 && tagDepth > 0 && braceInTag === 0) {
606
612
  if (src.startsWith("/>", i) || src[i] === ">") {
607
613
  const close = src[i] === ">" ? ">" : "/>";
608
614
  emit(close);
@@ -622,7 +628,7 @@ function scanJs(src, emit, jsx35) {
622
628
  continue;
623
629
  }
624
630
  if (src[i] === "{") braceInTag = 1;
625
- } else if (jsx35 && tagDepth > 0 && braceInTag > 0) {
631
+ } else if (jsx38 && tagDepth > 0 && braceInTag > 0) {
626
632
  if (src[i] === "{") braceInTag++;
627
633
  else if (src[i] === "}") braceInTag--;
628
634
  }
@@ -1207,7 +1213,22 @@ function PageHeader({
1207
1213
  ] });
1208
1214
  }
1209
1215
  var InStatGrid = react.createContext(false);
1210
- function StatCard({ label, value, hint, size, className }) {
1216
+ function Delta({ value, suffix = "", good = "up", label }) {
1217
+ const dir = value > 0 ? "up" : value < 0 ? "down" : "flat";
1218
+ const tone = dir === "flat" ? "text-muted-foreground" : dir === good ? "text-success" : "text-destructive";
1219
+ const sign = value > 0 ? "+" : value < 0 ? "\u2212" : "";
1220
+ return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: cn("inline-flex items-baseline gap-1 text-[0.8125rem] font-normal tracking-normal oca-tabular", tone), children: [
1221
+ /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, children: dir === "up" ? "\u2191" : dir === "down" ? "\u2193" : "\xB7" }),
1222
+ sign,
1223
+ Math.abs(value).toLocaleString("en-US", { maximumFractionDigits: 2 }),
1224
+ suffix,
1225
+ label ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-muted-foreground", children: [
1226
+ " ",
1227
+ label
1228
+ ] }) : null
1229
+ ] });
1230
+ }
1231
+ function StatCard({ label, value, hint, size, delta, className }) {
1211
1232
  const inGrid = react.useContext(InStatGrid);
1212
1233
  const density = useDensity();
1213
1234
  const sm = (size ?? (density === "compact" ? "sm" : "md")) === "sm";
@@ -1225,15 +1246,19 @@ function StatCard({ label, value, hint, size, className }) {
1225
1246
  ),
1226
1247
  children: [
1227
1248
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("leading-snug text-muted-foreground", sm ? "text-[0.8125rem]" : "text-[0.875rem]"), children: label }),
1228
- /* @__PURE__ */ jsxRuntime.jsx(
1249
+ /* @__PURE__ */ jsxRuntime.jsxs(
1229
1250
  "span",
1230
1251
  {
1231
1252
  className: cn(
1232
1253
  "break-words oca-tabular leading-tight tracking-[-0.02em]",
1233
1254
  sm ? "text-[1.25rem]" : "text-[1.5rem] md:text-[1.75rem]",
1234
- inGrid && "self-end"
1255
+ inGrid && "self-end",
1256
+ delta && "flex flex-wrap items-baseline gap-x-2"
1235
1257
  ),
1236
- children: value
1258
+ children: [
1259
+ value,
1260
+ delta ? /* @__PURE__ */ jsxRuntime.jsx(Delta, { ...delta }) : null
1261
+ ]
1237
1262
  }
1238
1263
  ),
1239
1264
  hint ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[0.8125rem] leading-snug text-muted-foreground", children: hint }) : inGrid ? /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true }) : null
@@ -1322,6 +1347,13 @@ function StatGrid({ columns, empty, isEmpty, className, children, ...props }) {
1322
1347
  }
1323
1348
  ) });
1324
1349
  }
1350
+ var TONE_TEXT = {
1351
+ good: "text-success",
1352
+ caution: "text-warning",
1353
+ bad: "text-destructive",
1354
+ brand: "text-oca-accent-ink",
1355
+ muted: "text-muted-foreground"
1356
+ };
1325
1357
  function KeyValueList({
1326
1358
  items,
1327
1359
  dense,
@@ -1340,15 +1372,19 @@ function KeyValueList({
1340
1372
  ),
1341
1373
  children: [
1342
1374
  /* @__PURE__ */ jsxRuntime.jsx("dt", { className: cn("shrink-0 text-muted-foreground", tight ? "text-[0.8125rem] @md:w-36" : "text-[0.875rem] @md:w-48"), children: it.label }),
1343
- /* @__PURE__ */ jsxRuntime.jsx(
1375
+ /* @__PURE__ */ jsxRuntime.jsxs(
1344
1376
  "dd",
1345
1377
  {
1346
1378
  className: cn(
1347
1379
  "min-w-0 break-words",
1348
1380
  tight ? "text-[0.875rem]" : "text-[0.9375rem]",
1349
- it.mono && (tight ? "font-mono text-[0.8125rem]" : "font-mono text-[0.875rem]")
1381
+ it.mono && (tight ? "font-mono text-[0.8125rem]" : "font-mono text-[0.875rem]"),
1382
+ it.tone && !it.note && TONE_TEXT[it.tone]
1350
1383
  ),
1351
- children: it.value
1384
+ children: [
1385
+ it.value,
1386
+ it.note ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("ml-2 font-sans text-[0.8125rem]", TONE_TEXT[it.tone ?? "muted"]), children: it.note }) : null
1387
+ ]
1352
1388
  }
1353
1389
  )
1354
1390
  ]
@@ -2506,6 +2542,460 @@ function ErrorPage({
2506
2542
  art !== null ? /* @__PURE__ */ jsxRuntime.jsx("div", { "aria-hidden": true, className: "oca-enter hidden justify-center md:col-span-5 md:flex [--enter-delay:120ms]", children: art ?? /* @__PURE__ */ jsxRuntime.jsx(MarkOutline, { className: "w-full max-w-[20rem] text-oca-hairline-strong" }) }) : null
2507
2543
  ] }) });
2508
2544
  }
2545
+ function onSecond(tick) {
2546
+ const id = setInterval(tick, 1e3);
2547
+ return () => clearInterval(id);
2548
+ }
2549
+ var nowSeconds = () => Math.floor(Date.now() / 1e3);
2550
+ function CountdownRing({
2551
+ period,
2552
+ remaining,
2553
+ warnAt = 5,
2554
+ size = 18,
2555
+ showSeconds = true,
2556
+ className
2557
+ }) {
2558
+ const now = react.useSyncExternalStore(onSecond, nowSeconds, () => null);
2559
+ const left = remaining ?? (now === null ? null : period - now % period);
2560
+ const share = left === null ? 1 : Math.max(0, Math.min(1, left / period));
2561
+ const warn = left !== null && left <= warnAt;
2562
+ const r = size / 2 - 1.5;
2563
+ const c = 2 * Math.PI * r;
2564
+ return /* @__PURE__ */ jsxRuntime.jsxs(
2565
+ "span",
2566
+ {
2567
+ role: "timer",
2568
+ "aria-label": left === null ? void 0 : `${left} second${left === 1 ? "" : "s"} left`,
2569
+ className: cn("inline-flex items-center gap-1.5", warn ? "text-destructive" : "text-muted-foreground", className),
2570
+ children: [
2571
+ /* @__PURE__ */ jsxRuntime.jsxs("svg", { "aria-hidden": true, width: size, height: size, viewBox: `0 0 ${size} ${size}`, className: "-rotate-90", children: [
2572
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: size / 2, cy: size / 2, r, fill: "none", stroke: "var(--border)", strokeWidth: 2 }),
2573
+ /* @__PURE__ */ jsxRuntime.jsx(
2574
+ "circle",
2575
+ {
2576
+ cx: size / 2,
2577
+ cy: size / 2,
2578
+ r,
2579
+ fill: "none",
2580
+ stroke: "currentColor",
2581
+ strokeWidth: 2,
2582
+ strokeLinecap: "round",
2583
+ strokeDasharray: c,
2584
+ strokeDashoffset: c * (1 - share),
2585
+ className: cn(left !== null && left < period && "transition-[stroke-dashoffset] duration-1000 ease-linear motion-reduce:transition-none")
2586
+ }
2587
+ )
2588
+ ] }),
2589
+ showSeconds && left !== null ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[0.8125rem] oca-tabular", children: [
2590
+ left,
2591
+ "s"
2592
+ ] }) : null
2593
+ ]
2594
+ }
2595
+ );
2596
+ }
2597
+ function PlanCard({
2598
+ name,
2599
+ subtitle,
2600
+ price,
2601
+ period,
2602
+ footnote,
2603
+ features = [],
2604
+ action,
2605
+ badge,
2606
+ badgeTone = "neutral",
2607
+ highlight: highlight2 = false,
2608
+ className
2609
+ }) {
2610
+ return /* @__PURE__ */ jsxRuntime.jsxs(
2611
+ "section",
2612
+ {
2613
+ className: cn(
2614
+ "flex h-full flex-col gap-5 rounded-[1.25rem] border bg-card p-6",
2615
+ highlight2 ? "border-foreground shadow-sm ring-1 ring-foreground" : "border-border",
2616
+ className
2617
+ ),
2618
+ children: [
2619
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1.5", children: [
2620
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-3", children: [
2621
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-[1.0625rem] font-medium leading-snug", children: name }),
2622
+ badge ? /* @__PURE__ */ jsxRuntime.jsx(Badge, { tone: badgeTone, children: badge }) : null
2623
+ ] }),
2624
+ subtitle ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[0.875rem] leading-snug text-muted-foreground", children: subtitle }) : null
2625
+ ] }),
2626
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1", children: [
2627
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "flex flex-wrap items-baseline gap-x-1.5", children: [
2628
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "oca-display-3 oca-tabular", children: price }),
2629
+ period ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[0.9375rem] text-muted-foreground", children: period }) : null
2630
+ ] }),
2631
+ footnote ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[0.8125rem] text-muted-foreground", children: footnote }) : null
2632
+ ] }),
2633
+ features.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("ul", { className: "flex flex-col gap-2.5 text-[0.9375rem]", children: features.map((f, i) => /* @__PURE__ */ jsxRuntime.jsxs("li", { className: "flex items-start gap-2.5", children: [
2634
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { "aria-hidden": true, className: "mt-1 size-4 shrink-0 text-muted-foreground" }),
2635
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "min-w-0", children: f })
2636
+ ] }, i)) }) : null,
2637
+ action ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-auto flex flex-col pt-1 [&>*]:w-full", children: action }) : null
2638
+ ]
2639
+ }
2640
+ );
2641
+ }
2642
+ function LockedPreview({
2643
+ title,
2644
+ description,
2645
+ action,
2646
+ children,
2647
+ className
2648
+ }) {
2649
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("relative", className), children: [
2650
+ children ? /* @__PURE__ */ jsxRuntime.jsx(
2651
+ "div",
2652
+ {
2653
+ inert: true,
2654
+ "aria-hidden": true,
2655
+ "data-oca-locked": "",
2656
+ className: "pointer-events-none max-h-[28rem] select-none overflow-hidden [mask-image:linear-gradient(to_bottom,#000_25%,transparent_85%)]",
2657
+ children
2658
+ }
2659
+ ) : null,
2660
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("relative mx-auto flex max-w-md flex-col items-center gap-4 rounded-[1.25rem] border border-border bg-card px-6 py-7 text-center shadow-sm", children && "-mt-40"), children: [
2661
+ /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, className: "flex size-10 items-center justify-center rounded-full bg-muted text-foreground", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Lock, { className: "size-[1.125rem]" }) }),
2662
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1.5", children: [
2663
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[1.0625rem] font-medium leading-snug", children: title }),
2664
+ description ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[0.9375rem] leading-snug text-muted-foreground", children: description }) : null
2665
+ ] }),
2666
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap justify-center gap-2", children: action })
2667
+ ] })
2668
+ ] });
2669
+ }
2670
+ var Dialog = DialogPrimitive__namespace.Root;
2671
+ var overlayClass = "oca-animate-fade fixed inset-0 z-50 bg-[rgb(10_10_10/0.38)] backdrop-blur-[2px] data-[state=closed]:opacity-0";
2672
+ var DialogContent = react.forwardRef(function DialogContent2({ className, children, hideClose, ...props }, ref) {
2673
+ return /* @__PURE__ */ jsxRuntime.jsxs(DialogPrimitive__namespace.Portal, { children: [
2674
+ /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Overlay, { className: overlayClass }),
2675
+ /* @__PURE__ */ jsxRuntime.jsxs(
2676
+ DialogPrimitive__namespace.Content,
2677
+ {
2678
+ ref,
2679
+ className: cn(
2680
+ "oca-animate-rise fixed left-1/2 top-1/2 z-50 w-[min(92vw,34rem)] -translate-x-1/2 -translate-y-1/2",
2681
+ "max-h-[88vh] overflow-y-auto rounded-[1.5rem] border border-border bg-popover p-6 text-popover-foreground shadow-xl md:p-8",
2682
+ "outline-none",
2683
+ className
2684
+ ),
2685
+ ...props,
2686
+ children: [
2687
+ children,
2688
+ hideClose ? null : /* @__PURE__ */ jsxRuntime.jsx(
2689
+ DialogPrimitive__namespace.Close,
2690
+ {
2691
+ className: "absolute right-4 top-4 inline-flex size-9 items-center justify-center rounded-full text-muted-foreground transition-colors hover:bg-accent hover:text-foreground",
2692
+ "aria-label": "Close",
2693
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "size-4" })
2694
+ }
2695
+ )
2696
+ ]
2697
+ }
2698
+ )
2699
+ ] });
2700
+ });
2701
+ var DialogTitle = react.forwardRef(function DialogTitle2({ className, ...props }, ref) {
2702
+ return /* @__PURE__ */ jsxRuntime.jsx(
2703
+ DialogPrimitive__namespace.Title,
2704
+ {
2705
+ ref,
2706
+ className: cn("text-[1.5rem] font-normal leading-tight tracking-[-0.02em]", className),
2707
+ ...props
2708
+ }
2709
+ );
2710
+ });
2711
+ var DialogDescription = react.forwardRef(function DialogDescription2({ className, ...props }, ref) {
2712
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Description, { ref, className: cn("oca-body", className), ...props });
2713
+ });
2714
+ var sheetSide = {
2715
+ right: "inset-y-0 right-0 h-full w-[min(88vw,24rem)] border-l",
2716
+ left: "inset-y-0 left-0 h-full w-[min(88vw,24rem)] border-r",
2717
+ bottom: "inset-x-0 bottom-0 max-h-[88vh] rounded-t-[1.5rem] border-t"
2718
+ };
2719
+ react.forwardRef(function SheetContent2({ className, children, side = "right", ...props }, ref) {
2720
+ return /* @__PURE__ */ jsxRuntime.jsxs(DialogPrimitive__namespace.Portal, { children: [
2721
+ /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Overlay, { className: overlayClass }),
2722
+ /* @__PURE__ */ jsxRuntime.jsxs(
2723
+ DialogPrimitive__namespace.Content,
2724
+ {
2725
+ ref,
2726
+ className: cn(
2727
+ "oca-animate-fade fixed z-50 flex flex-col gap-4 overflow-y-auto border-border bg-popover p-6 text-popover-foreground shadow-xl outline-none",
2728
+ sheetSide[side],
2729
+ className
2730
+ ),
2731
+ ...props,
2732
+ children: [
2733
+ children,
2734
+ /* @__PURE__ */ jsxRuntime.jsx(
2735
+ DialogPrimitive__namespace.Close,
2736
+ {
2737
+ className: "absolute right-4 top-4 inline-flex size-9 items-center justify-center rounded-full text-muted-foreground hover:bg-accent hover:text-foreground",
2738
+ "aria-label": "Close",
2739
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "size-4" })
2740
+ }
2741
+ )
2742
+ ]
2743
+ }
2744
+ )
2745
+ ] });
2746
+ });
2747
+ var Popover = PopoverPrimitive__namespace.Root;
2748
+ var PopoverTrigger = PopoverPrimitive__namespace.Trigger;
2749
+ var PopoverContent = react.forwardRef(function PopoverContent2({ className, align = "center", sideOffset = 8, ...props }, ref) {
2750
+ return /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
2751
+ PopoverPrimitive__namespace.Content,
2752
+ {
2753
+ ref,
2754
+ align,
2755
+ sideOffset,
2756
+ className: cn(
2757
+ "oca-animate-fade z-50 w-72 rounded-2xl border border-border bg-popover p-4 text-popover-foreground shadow-lg outline-none",
2758
+ className
2759
+ ),
2760
+ ...props
2761
+ }
2762
+ ) });
2763
+ });
2764
+ react.forwardRef(function TooltipContent2({ className, sideOffset = 6, ...props }, ref) {
2765
+ return /* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
2766
+ TooltipPrimitive__namespace.Content,
2767
+ {
2768
+ ref,
2769
+ sideOffset,
2770
+ className: cn(
2771
+ "oca-animate-fade z-50 max-w-xs rounded-lg bg-oca-ink px-2.5 py-1.5 text-[0.8125rem] leading-snug text-oca-ink-foreground",
2772
+ className
2773
+ ),
2774
+ ...props
2775
+ }
2776
+ ) });
2777
+ });
2778
+ react.forwardRef(function DropdownMenuContent2({ className, sideOffset = 8, ...props }, ref) {
2779
+ return /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
2780
+ DropdownMenuPrimitive__namespace.Content,
2781
+ {
2782
+ ref,
2783
+ sideOffset,
2784
+ className: cn(
2785
+ "oca-animate-fade z-50 min-w-56 overflow-hidden rounded-2xl border border-border bg-popover p-1.5 text-popover-foreground shadow-lg",
2786
+ className
2787
+ ),
2788
+ ...props
2789
+ }
2790
+ ) });
2791
+ });
2792
+ react.forwardRef(function DropdownMenuItem2({ className, destructive, ...props }, ref) {
2793
+ return /* @__PURE__ */ jsxRuntime.jsx(
2794
+ DropdownMenuPrimitive__namespace.Item,
2795
+ {
2796
+ ref,
2797
+ className: cn(
2798
+ "flex h-10 cursor-default select-none items-center gap-2.5 rounded-xl px-3 text-[0.9375rem] outline-none",
2799
+ "data-[highlighted]:bg-accent data-[disabled]:opacity-50 [&_svg]:size-4 [&_svg]:text-muted-foreground",
2800
+ destructive && "text-destructive [&_svg]:text-destructive",
2801
+ className
2802
+ ),
2803
+ ...props
2804
+ }
2805
+ );
2806
+ });
2807
+ react.forwardRef(function DropdownMenuLabel2({ className, ...props }, ref) {
2808
+ return /* @__PURE__ */ jsxRuntime.jsx(
2809
+ DropdownMenuPrimitive__namespace.Label,
2810
+ {
2811
+ ref,
2812
+ className: cn("px-3 pb-1.5 pt-2 text-[0.8125rem] text-muted-foreground", className),
2813
+ ...props
2814
+ }
2815
+ );
2816
+ });
2817
+ react.forwardRef(function DropdownMenuSeparator2({ className, ...props }, ref) {
2818
+ return /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Separator, { ref, className: cn("my-1.5 h-px bg-border", className), ...props });
2819
+ });
2820
+ function chartColor(series) {
2821
+ if (typeof series === "string") return `var(--oca-chart-${series})`;
2822
+ const n = series >= 1 && series <= 4 && Number.isInteger(series) ? series : (series % 4 + 4) % 4 + 1;
2823
+ return `var(--oca-chart-${n})`;
2824
+ }
2825
+ function ChartFrame({
2826
+ legend,
2827
+ caption,
2828
+ children,
2829
+ className
2830
+ }) {
2831
+ return /* @__PURE__ */ jsxRuntime.jsxs("figure", { className: cn("oca-chart flex min-w-0 flex-col gap-3", className), children: [
2832
+ legend && legend.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("ul", { className: "oca-chart-legend", "aria-label": "Legend", children: legend.map((l, i) => {
2833
+ const c = typeof l.color === "number" || ["neutral", "up", "down"].includes(String(l.color)) ? chartColor(l.color) : String(l.color);
2834
+ return /* @__PURE__ */ jsxRuntime.jsxs("li", { children: [
2835
+ /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, "data-swatch": l.dashed ? "dashed" : "", style: { "--swatch": c } }),
2836
+ l.label
2837
+ ] }, i);
2838
+ }) }) : null,
2839
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative min-w-0", children }),
2840
+ caption ? /* @__PURE__ */ jsxRuntime.jsx("figcaption", { className: "text-[0.8125rem] leading-snug text-muted-foreground", children: caption }) : null
2841
+ ] });
2842
+ }
2843
+ function Sparkline({
2844
+ values,
2845
+ label,
2846
+ tone = "ink",
2847
+ area = false,
2848
+ width = 96,
2849
+ height = 24,
2850
+ className
2851
+ }) {
2852
+ const gradient = react.useId().replace(/[^a-zA-Z0-9]/g, "");
2853
+ const pts = values.filter((v) => Number.isFinite(v));
2854
+ const lo = Math.min(...pts);
2855
+ const hi = Math.max(...pts);
2856
+ const span = hi - lo || 1;
2857
+ const pad3 = 1.5;
2858
+ const x = (i) => pts.length < 2 ? width / 2 : i / (pts.length - 1) * width;
2859
+ const y = (v) => pad3 + (1 - (v - lo) / span) * (height - pad3 * 2);
2860
+ const line = pts.map((v, i) => `${i === 0 ? "M" : "L"}${x(i).toFixed(2)},${y(v).toFixed(2)}`).join(" ");
2861
+ const color = tone === "ink" ? "var(--foreground)" : tone === "muted" ? "var(--muted-foreground)" : tone === "trend" ? chartColor(pts.length > 1 && pts[pts.length - 1] < pts[0] ? "down" : "up") : chartColor(tone);
2862
+ return /* @__PURE__ */ jsxRuntime.jsx(
2863
+ "svg",
2864
+ {
2865
+ role: "img",
2866
+ "aria-label": label,
2867
+ viewBox: `0 0 ${width} ${height}`,
2868
+ preserveAspectRatio: "none",
2869
+ width,
2870
+ height,
2871
+ className: cn("block overflow-visible", className),
2872
+ style: { color },
2873
+ children: pts.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
2874
+ area ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
2875
+ /* @__PURE__ */ jsxRuntime.jsx("defs", { children: /* @__PURE__ */ jsxRuntime.jsxs("linearGradient", { id: gradient, x1: "0", y1: "0", x2: "0", y2: "1", children: [
2876
+ /* @__PURE__ */ jsxRuntime.jsx("stop", { offset: "0", stopColor: "currentColor", stopOpacity: 0.22 }),
2877
+ /* @__PURE__ */ jsxRuntime.jsx("stop", { offset: "1", stopColor: "currentColor", stopOpacity: 0 })
2878
+ ] }) }),
2879
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: `${line} L${x(pts.length - 1).toFixed(2)},${height} L${x(0).toFixed(2)},${height} Z`, fill: `url(#${gradient})` })
2880
+ ] }) : null,
2881
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: line, fill: "none", stroke: "currentColor", strokeWidth: 1.5, strokeLinejoin: "round", strokeLinecap: "round", vectorEffect: "non-scaling-stroke" })
2882
+ ] }) : null
2883
+ }
2884
+ );
2885
+ }
2886
+ function SourceNote({ source, href, detail, updated, variant = "popover", className }) {
2887
+ const name = href ? /* @__PURE__ */ jsxRuntime.jsxs("a", { href, className: "text-foreground underline decoration-foreground/35 underline-offset-4 hover:decoration-foreground", rel: "noreferrer", target: "_blank", children: [
2888
+ source,
2889
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: " (opens in a new tab)" })
2890
+ ] }) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground", children: source });
2891
+ if (variant === "line") {
2892
+ return /* @__PURE__ */ jsxRuntime.jsxs("p", { className: cn("text-[0.75rem] leading-snug text-muted-foreground", className), children: [
2893
+ "Source: ",
2894
+ name,
2895
+ updated ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
2896
+ " \xB7 ",
2897
+ updated
2898
+ ] }) : null
2899
+ ] });
2900
+ }
2901
+ return /* @__PURE__ */ jsxRuntime.jsxs(Popover, { children: [
2902
+ /* @__PURE__ */ jsxRuntime.jsxs(
2903
+ PopoverTrigger,
2904
+ {
2905
+ className: cn(
2906
+ "inline-flex h-7 items-center gap-1 rounded-full px-2 text-[0.75rem] text-muted-foreground transition-colors hover:bg-accent hover:text-foreground",
2907
+ className
2908
+ ),
2909
+ children: [
2910
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Info, { "aria-hidden": true, className: "size-3.5" }),
2911
+ "Source"
2912
+ ]
2913
+ }
2914
+ ),
2915
+ /* @__PURE__ */ jsxRuntime.jsxs(PopoverContent, { align: "start", className: "flex w-[min(calc(100vw-2rem),20rem)] flex-col gap-2 p-4 text-[0.875rem]", children: [
2916
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[0.75rem] text-muted-foreground", children: "Where this number comes from" }),
2917
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "font-medium", children: name }),
2918
+ detail ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-[0.8125rem] leading-snug text-muted-foreground [&_code]:font-mono", children: detail }) : null,
2919
+ updated ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[0.8125rem] text-muted-foreground", children: updated }) : null
2920
+ ] })
2921
+ ] });
2922
+ }
2923
+ function Panel({
2924
+ title,
2925
+ description,
2926
+ actions,
2927
+ source,
2928
+ expandable = false,
2929
+ children,
2930
+ className
2931
+ }) {
2932
+ const [open, setOpen] = react.useState(false);
2933
+ const body = (expanded) => typeof children === "function" ? children(expanded) : children;
2934
+ const head = (expanded) => /* @__PURE__ */ jsxRuntime.jsxs("header", { className: "flex flex-wrap items-start justify-between gap-x-4 gap-y-2", children: [
2935
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex min-w-0 flex-col gap-1", children: [
2936
+ expanded ? /* @__PURE__ */ jsxRuntime.jsx(DialogTitle, { className: "text-[1.0625rem] font-medium leading-snug", children: title }) : /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-[1rem] font-medium leading-snug", children: title }),
2937
+ description ? expanded ? /* @__PURE__ */ jsxRuntime.jsx(DialogDescription, { className: "text-[0.875rem] leading-snug text-muted-foreground", children: description }) : /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[0.875rem] leading-snug text-muted-foreground", children: description }) : null
2938
+ ] }),
2939
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex shrink-0 items-center gap-1", children: [
2940
+ actions,
2941
+ expandable && !expanded ? /* @__PURE__ */ jsxRuntime.jsx(
2942
+ "button",
2943
+ {
2944
+ type: "button",
2945
+ onClick: () => setOpen(true),
2946
+ "aria-label": "Open full screen",
2947
+ className: "inline-flex size-8 items-center justify-center rounded-full text-muted-foreground transition-colors hover:bg-accent hover:text-foreground",
2948
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Maximize2, { "aria-hidden": true, className: "size-4" })
2949
+ }
2950
+ ) : null
2951
+ ] })
2952
+ ] });
2953
+ return /* @__PURE__ */ jsxRuntime.jsxs("section", { className: cn("flex min-w-0 flex-col gap-4 rounded-[1.25rem] border border-border bg-card p-5 md:p-6", className), children: [
2954
+ head(false),
2955
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-w-0", children: body(false) }),
2956
+ source ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "-mb-1 border-t border-border pt-3", children: source }) : null,
2957
+ expandable ? /* @__PURE__ */ jsxRuntime.jsx(Dialog, { open, onOpenChange: setOpen, children: /* @__PURE__ */ jsxRuntime.jsxs(
2958
+ DialogContent,
2959
+ {
2960
+ ...description ? {} : { "aria-describedby": void 0 },
2961
+ className: "flex h-[min(92dvh,56rem)] w-[min(96vw,80rem)] max-w-none flex-col gap-4 overflow-y-auto",
2962
+ children: [
2963
+ head(true),
2964
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 min-w-0 flex-1", children: open ? body(true) : null }),
2965
+ source ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-t border-border pt-3", children: source }) : null
2966
+ ]
2967
+ }
2968
+ ) }) : null
2969
+ ] });
2970
+ }
2971
+ function HudCard({
2972
+ eyebrow,
2973
+ live = false,
2974
+ title,
2975
+ children,
2976
+ footer,
2977
+ className
2978
+ }) {
2979
+ return /* @__PURE__ */ jsxRuntime.jsxs(
2980
+ "div",
2981
+ {
2982
+ "data-oca-hud": "",
2983
+ className: cn(
2984
+ "flex w-60 max-w-[calc(100vw-2rem)] flex-col gap-2 rounded-xl border border-border bg-background/85 p-3 text-[0.8125rem] shadow-sm backdrop-blur-md",
2985
+ className
2986
+ ),
2987
+ children: [
2988
+ eyebrow ? /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "flex items-center gap-1.5 text-[0.75rem] text-muted-foreground", children: [
2989
+ live ? /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, className: "size-1.5 rounded-full bg-oca-orange-deep motion-safe:animate-pulse" }) : null,
2990
+ eyebrow
2991
+ ] }) : null,
2992
+ title ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[1.125rem] font-medium leading-tight oca-tabular", children: title }) : null,
2993
+ children,
2994
+ footer ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-t border-border pt-2", children: footer }) : null
2995
+ ]
2996
+ }
2997
+ );
2998
+ }
2509
2999
  function IsoCheck({ size = 360, settle = false, shadow = true, tilt = false, title, className }) {
2510
3000
  const ref = react.useRef(null);
2511
3001
  react.useEffect(() => {
@@ -2994,7 +3484,7 @@ var Textarea = react.forwardRef(
2994
3484
  );
2995
3485
  }
2996
3486
  );
2997
- var Label = react.forwardRef(function Label2({ className, ...props }, ref) {
3487
+ var Label2 = react.forwardRef(function Label3({ className, ...props }, ref) {
2998
3488
  return /* @__PURE__ */ jsxRuntime.jsx(
2999
3489
  LabelPrimitive__namespace.Root,
3000
3490
  {
@@ -3017,7 +3507,7 @@ function Field({ label, hint, optional, error, children, id: fixedId, className,
3017
3507
  const control = typeof children === "function" ? children(wiring) : react.isValidElement(children) ? react.cloneElement(children, { ...wiring }) : children;
3018
3508
  const hintNode = hint ? /* @__PURE__ */ jsxRuntime.jsx("p", { id: hintId, className: "text-[0.8125rem] leading-snug text-muted-foreground", children: hint }) : null;
3019
3509
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex flex-col gap-2", className), children: [
3020
- /* @__PURE__ */ jsxRuntime.jsxs(Label, { htmlFor: id, className: hideLabel ? "sr-only" : "flex items-baseline gap-2", children: [
3510
+ /* @__PURE__ */ jsxRuntime.jsxs(Label2, { htmlFor: id, className: hideLabel ? "sr-only" : "flex items-baseline gap-2", children: [
3021
3511
  label,
3022
3512
  optional ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[0.8125rem] font-normal text-muted-foreground", children: "Optional" }) : null
3023
3513
  ] }),
@@ -3966,6 +4456,7 @@ function SearchDialog({
3966
4456
  idle,
3967
4457
  defaultQuery = "",
3968
4458
  debounceMs = 120,
4459
+ browse = false,
3969
4460
  className
3970
4461
  }) {
3971
4462
  const [own, setOwn] = react.useState(false);
@@ -4002,7 +4493,7 @@ function SearchDialog({
4002
4493
  }, [hotkey]);
4003
4494
  react.useEffect(() => {
4004
4495
  const q = query.trim();
4005
- if (!q) {
4496
+ if (!q && !(browse && open)) {
4006
4497
  setGroups([]);
4007
4498
  setState("idle");
4008
4499
  return;
@@ -4024,14 +4515,15 @@ function SearchDialog({
4024
4515
  clearTimeout(t);
4025
4516
  ctl.abort();
4026
4517
  };
4027
- }, [query, debounceMs]);
4518
+ }, [query, debounceMs, browse, open]);
4028
4519
  react.useEffect(() => {
4029
4520
  listRef.current?.querySelector('[aria-selected="true"]')?.scrollIntoView({ block: "nearest" });
4030
4521
  }, [active]);
4031
4522
  const choose = (r) => {
4032
4523
  setOpen(false);
4033
- if (onSelect) onSelect(r);
4034
- else window.location.assign(r.href);
4524
+ if (r.run) r.run();
4525
+ else if (onSelect) onSelect(r);
4526
+ else if (r.href) window.location.assign(r.href);
4035
4527
  };
4036
4528
  const optionId = (i) => `${listId}-o${i}`;
4037
4529
  const showList = state === "done" && flat.length > 0;
@@ -4102,25 +4594,28 @@ function SearchDialog({
4102
4594
  index++;
4103
4595
  const i = index;
4104
4596
  const on = i === active;
4597
+ const Option = r.href ? "a" : "div";
4105
4598
  return /* @__PURE__ */ jsxRuntime.jsxs(
4106
- "a",
4599
+ Option,
4107
4600
  {
4108
4601
  id: optionId(i),
4109
- href: r.href,
4602
+ ...r.href ? { href: r.href } : {},
4110
4603
  role: "option",
4111
4604
  "aria-selected": on,
4112
4605
  tabIndex: -1,
4113
4606
  onMouseMove: () => setActive(i),
4114
4607
  onClick: (e) => {
4115
- if (e.metaKey || e.ctrlKey || e.shiftKey) return;
4608
+ if (r.href && (e.metaKey || e.ctrlKey || e.shiftKey)) return;
4116
4609
  e.preventDefault();
4117
4610
  choose(r);
4118
4611
  },
4119
4612
  className: cn(
4120
4613
  "flex items-start gap-3 rounded-xl px-3 py-2.5 transition-colors",
4121
- on ? "bg-accent" : "hover:bg-accent"
4614
+ on ? "bg-accent" : "hover:bg-accent",
4615
+ !r.href && "cursor-pointer"
4122
4616
  ),
4123
4617
  children: [
4618
+ r.icon ? /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, className: "mt-0.5 flex size-5 shrink-0 items-center justify-center text-muted-foreground [&_svg]:size-[1.0625rem]", children: r.icon }) : null,
4124
4619
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex min-w-0 flex-1 flex-col gap-0.5", children: [
4125
4620
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate text-[0.9375rem] font-medium text-foreground", children: r.title }),
4126
4621
  r.section ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate text-[0.8125rem] text-muted-foreground", children: r.section }) : null,
@@ -4132,6 +4627,7 @@ function SearchDialog({
4132
4627
  }
4133
4628
  ) : r.excerpt ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "line-clamp-2 text-[0.875rem] leading-snug text-muted-foreground", children: r.excerpt }) : null
4134
4629
  ] }),
4630
+ r.meta ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-0.5 shrink-0 text-[0.8125rem] text-muted-foreground", children: r.meta }) : null,
4135
4631
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CornerDownLeft, { "aria-hidden": true, className: cn("mt-1 size-4 shrink-0 text-muted-foreground", !on && "invisible") })
4136
4632
  ]
4137
4633
  },
@@ -4140,11 +4636,11 @@ function SearchDialog({
4140
4636
  })
4141
4637
  ] }, gi)) }),
4142
4638
  state === "idle" ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-6 text-[0.9375rem] text-muted-foreground", children: idle ?? "Type a word: a protocol, a function, an error." }) : null,
4143
- state === "done" && flat.length === 0 ? /* @__PURE__ */ jsxRuntime.jsxs("p", { role: "status", className: "px-3 py-6 text-[0.9375rem] text-muted-foreground", children: [
4639
+ state === "done" && flat.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx("p", { role: "status", className: "px-3 py-6 text-[0.9375rem] text-muted-foreground", children: query.trim() ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
4144
4640
  "No results for \u201C",
4145
4641
  query.trim(),
4146
4642
  "\u201D."
4147
- ] }) : null,
4643
+ ] }) : "Nothing here yet." }) : null,
4148
4644
  state === "error" ? /* @__PURE__ */ jsxRuntime.jsx("p", { role: "status", className: "px-3 py-6 text-[0.9375rem] text-muted-foreground", children: "Search is not available right now. Try again in a moment." }) : null
4149
4645
  ] }),
4150
4646
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "aria-hidden": true, className: "hidden shrink-0 items-center gap-4 border-t border-border px-5 py-2.5 text-[0.75rem] text-muted-foreground sm:flex", children: [
@@ -4169,6 +4665,13 @@ function SearchDialog({
4169
4665
  ] }) })
4170
4666
  ] });
4171
4667
  }
4668
+ function CommandDialog({
4669
+ label = "Commands",
4670
+ placeholder = "Search, or run a command",
4671
+ ...props
4672
+ }) {
4673
+ return /* @__PURE__ */ jsxRuntime.jsx(SearchDialog, { ...props, label, placeholder, button: false, browse: true });
4674
+ }
4172
4675
  function pretty(content) {
4173
4676
  try {
4174
4677
  return JSON.stringify(JSON.parse(content), null, 2);
@@ -4597,6 +5100,13 @@ function BlockCountdown({
4597
5100
  ] }) : null
4598
5101
  ] });
4599
5102
  }
5103
+ var METER_FILL = {
5104
+ ink: "bg-foreground",
5105
+ brand: "bg-oca-orange-deep",
5106
+ good: "bg-success",
5107
+ caution: "bg-warning",
5108
+ bad: "bg-destructive"
5109
+ };
4600
5110
  function Meter({
4601
5111
  value,
4602
5112
  max,
@@ -4631,7 +5141,7 @@ function Meter({
4631
5141
  /* @__PURE__ */ jsxRuntime.jsx(
4632
5142
  "div",
4633
5143
  {
4634
- className: cn("h-full shrink-0 rounded-full", tone === "brand" ? "bg-oca-orange-deep" : "bg-foreground"),
5144
+ className: cn("h-full shrink-0 rounded-full", METER_FILL[tone]),
4635
5145
  style: { width: `${v * 100}%` }
4636
5146
  }
4637
5147
  ),
@@ -4758,12 +5268,15 @@ exports.Breadcrumbs = Breadcrumbs;
4758
5268
  exports.BrowserFrame = BrowserFrame;
4759
5269
  exports.Callout = Callout;
4760
5270
  exports.CardGrid = CardGrid;
5271
+ exports.ChartFrame = ChartFrame;
4761
5272
  exports.Closing = Closing;
4762
5273
  exports.CodeBlock = CodeBlock;
4763
5274
  exports.CodeTabs = CodeTabs;
5275
+ exports.CommandDialog = CommandDialog;
4764
5276
  exports.ComparisonTable = ComparisonTable;
4765
5277
  exports.Container = Container;
4766
5278
  exports.CopyButton = CopyButton;
5279
+ exports.CountdownRing = CountdownRing;
4767
5280
  exports.DataTable = DataTable;
4768
5281
  exports.Diagram = Diagram;
4769
5282
  exports.Display = Display;
@@ -4786,12 +5299,14 @@ exports.FloatChip = FloatChip;
4786
5299
  exports.Footnote = Footnote;
4787
5300
  exports.FormSection = FormSection;
4788
5301
  exports.HashChip = HashChip;
5302
+ exports.HudCard = HudCard;
4789
5303
  exports.InstallTabs = InstallTabs;
4790
5304
  exports.KeyValueList = KeyValueList;
4791
5305
  exports.Lead = Lead;
4792
5306
  exports.LegalDocument = LegalDocument;
4793
5307
  exports.LinkCard = LinkCard;
4794
5308
  exports.LoadingBlock = LoadingBlock;
5309
+ exports.LockedPreview = LockedPreview;
4795
5310
  exports.MdxTable = MdxTable;
4796
5311
  exports.Meter = Meter;
4797
5312
  exports.Monogram = Monogram;
@@ -4800,7 +5315,9 @@ exports.OnThisPage = OnThisPage;
4800
5315
  exports.PackageCard = PackageCard;
4801
5316
  exports.PageHeader = PageHeader;
4802
5317
  exports.PageHero = PageHero;
5318
+ exports.Panel = Panel;
4803
5319
  exports.PhoneFrame = PhoneFrame;
5320
+ exports.PlanCard = PlanCard;
4804
5321
  exports.ProgressSteps = ProgressSteps;
4805
5322
  exports.ProofStrip = ProofStrip;
4806
5323
  exports.Prose = Prose;
@@ -4817,6 +5334,8 @@ exports.Section = Section;
4817
5334
  exports.SectionHeading = SectionHeading;
4818
5335
  exports.SectionIntro = SectionIntro;
4819
5336
  exports.SignMessage = SignMessage;
5337
+ exports.SourceNote = SourceNote;
5338
+ exports.Sparkline = Sparkline;
4820
5339
  exports.SpecCard = SpecCard;
4821
5340
  exports.SplitBar = SplitBar;
4822
5341
  exports.StatCard = StatCard;
@@ -4832,6 +5351,7 @@ exports.TruthTable = TruthTable;
4832
5351
  exports.UsdApprox = UsdApprox;
4833
5352
  exports.VerifyBox = VerifyBox;
4834
5353
  exports.VerifyReport = VerifyReport;
5354
+ exports.chartColor = chartColor;
4835
5355
  exports.createStateBadge = createStateBadge;
4836
5356
  exports.languageName = languageName;
4837
5357
  exports.monogramGround = monogramGround;