@photon-ai/pho-ui 2.5.0 → 2.7.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 (120) hide show
  1. package/dist/chunks/IconChevronDown-CZilB71T.js +11 -0
  2. package/dist/chunks/IconChevronDown-CZilB71T.js.map +1 -0
  3. package/dist/chunks/IconSearch-BKAHkLyX.js +14 -0
  4. package/dist/chunks/IconSearch-BKAHkLyX.js.map +1 -0
  5. package/dist/chunks/animated-height-CCO-Ocoz.js +48 -0
  6. package/dist/chunks/animated-height-CCO-Ocoz.js.map +1 -0
  7. package/dist/chunks/basic-page-DR5szOOs.js +1373 -0
  8. package/dist/chunks/basic-page-DR5szOOs.js.map +1 -0
  9. package/dist/chunks/{button-DNNs5RsT.js → button-CdqS_t5a.js} +62 -65
  10. package/dist/chunks/button-CdqS_t5a.js.map +1 -0
  11. package/dist/chunks/checkbox-Cdm08HWG.js +129 -0
  12. package/dist/chunks/checkbox-Cdm08HWG.js.map +1 -0
  13. package/dist/chunks/{choice-card-CunOnY9l.js → choice-card-BVNP1NB6.js} +2 -2
  14. package/dist/chunks/{choice-card-CunOnY9l.js.map → choice-card-BVNP1NB6.js.map} +1 -1
  15. package/dist/chunks/data-table-DwbPU0zt.js +2970 -0
  16. package/dist/chunks/data-table-DwbPU0zt.js.map +1 -0
  17. package/dist/chunks/{dialog-8SRNi_rv.js → dialog-BxKACOj5.js} +4 -4
  18. package/dist/chunks/{dialog-8SRNi_rv.js.map → dialog-BxKACOj5.js.map} +1 -1
  19. package/dist/chunks/{error-Crs-wqMC.js → error-D0yoFxCv.js} +2 -2
  20. package/dist/chunks/{error-Crs-wqMC.js.map → error-D0yoFxCv.js.map} +1 -1
  21. package/dist/chunks/is-react-component-DSnjtBmo.js +10 -0
  22. package/dist/chunks/is-react-component-DSnjtBmo.js.map +1 -0
  23. package/dist/chunks/link-provider-DXzDQ08N.js +24 -0
  24. package/dist/chunks/link-provider-DXzDQ08N.js.map +1 -0
  25. package/dist/chunks/rolldown-runtime-DG5F_Nuu.js +27 -0
  26. package/dist/chunks/{scroll-area-Bu7egArU.js → scroll-area-BO-9PMM7.js} +27 -26
  27. package/dist/chunks/scroll-area-BO-9PMM7.js.map +1 -0
  28. package/dist/chunks/sidebar-DVzZsCts.js +223 -0
  29. package/dist/chunks/sidebar-DVzZsCts.js.map +1 -0
  30. package/dist/chunks/skeleton-DwjSl4vC.js +18 -0
  31. package/dist/chunks/skeleton-DwjSl4vC.js.map +1 -0
  32. package/dist/chunks/{toast-DoXaRPIZ.js → toast-iSf6NuAS.js} +43 -45
  33. package/dist/chunks/toast-iSf6NuAS.js.map +1 -0
  34. package/dist/chunks/use-press-pulse-IbNstUT0.js +58 -0
  35. package/dist/chunks/use-press-pulse-IbNstUT0.js.map +1 -0
  36. package/dist/components/button.js +1 -1
  37. package/dist/components/checkbox.js +4 -126
  38. package/dist/components/command.js +54 -57
  39. package/dist/components/command.js.map +1 -1
  40. package/dist/components/data-table.js +11 -0
  41. package/dist/components/dialog.js +1 -1
  42. package/dist/components/error.js +1 -1
  43. package/dist/components/phone-input.js +609 -616
  44. package/dist/components/phone-input.js.map +1 -1
  45. package/dist/components/radio-group.js +2 -2
  46. package/dist/components/scroll-area.js +1 -1
  47. package/dist/components/select.js +35 -39
  48. package/dist/components/select.js.map +1 -1
  49. package/dist/components/skeleton.js +2 -15
  50. package/dist/components/toast.js +1 -1
  51. package/dist/index.js +94 -73
  52. package/dist/motion.js +89 -0
  53. package/dist/motion.js.map +1 -0
  54. package/dist/primitives/accordion.js +1 -1
  55. package/dist/primitives/alert-dialog.js +1 -1
  56. package/dist/primitives/autocomplete.js +1 -1
  57. package/dist/primitives/avatar.js +1 -1
  58. package/dist/primitives/button.js +1 -1
  59. package/dist/primitives/checkbox-group.js +1 -1
  60. package/dist/primitives/checkbox.js +1 -1
  61. package/dist/primitives/collapsible.js +1 -1
  62. package/dist/primitives/combobox.js +1 -1
  63. package/dist/primitives/context-menu.js +1 -1
  64. package/dist/primitives/csp-provider.js +1 -1
  65. package/dist/primitives/dialog.js +1 -1
  66. package/dist/primitives/direction-provider.js +1 -1
  67. package/dist/primitives/drawer.js +1 -1
  68. package/dist/primitives/field.js +1 -1
  69. package/dist/primitives/fieldset.js +1 -1
  70. package/dist/primitives/form.js +1 -1
  71. package/dist/primitives/input.js +1 -1
  72. package/dist/primitives/menu.js +1 -1
  73. package/dist/primitives/menubar.js +1 -1
  74. package/dist/primitives/meter.js +1 -1
  75. package/dist/primitives/navigation-menu.js +1 -1
  76. package/dist/primitives/number-field.js +1 -1
  77. package/dist/primitives/otp-field.js +1 -1
  78. package/dist/primitives/popover.js +1 -1
  79. package/dist/primitives/preview-card.js +1 -1
  80. package/dist/primitives/progress.js +1 -1
  81. package/dist/primitives/radio-group.js +1 -1
  82. package/dist/primitives/radio.js +1 -1
  83. package/dist/primitives/scroll-area.js +1 -1
  84. package/dist/primitives/select.js +1 -1
  85. package/dist/primitives/separator.js +1 -1
  86. package/dist/primitives/slider.js +1 -1
  87. package/dist/primitives/switch.js +1 -1
  88. package/dist/primitives/tabs.js +1 -1
  89. package/dist/primitives/toast.js +1 -1
  90. package/dist/primitives/toggle-group.js +1 -1
  91. package/dist/primitives/toggle.js +1 -1
  92. package/dist/primitives/toolbar.js +1 -1
  93. package/dist/primitives/tooltip.js +1 -1
  94. package/dist/primitives.js +3 -3
  95. package/dist/sections/basic-page.js +16 -14
  96. package/dist/sections/sidebar.js +1 -1
  97. package/dist/src/components/data-table/data-table.d.ts +227 -0
  98. package/dist/src/components/data-table/index.d.ts +2 -0
  99. package/dist/src/index.d.ts +1 -0
  100. package/dist/src/motion/index.d.ts +149 -0
  101. package/dist/src/sections/basic-page/basic-page.d.ts +63 -14
  102. package/dist/src/sections/basic-page/index.d.ts +1 -0
  103. package/dist/utils.js +13 -12
  104. package/package.json +10 -1
  105. package/dist/chunks/animated-height-C2eQstGy.js +0 -51
  106. package/dist/chunks/animated-height-C2eQstGy.js.map +0 -1
  107. package/dist/chunks/basic-page-w6ftlo0h.js +0 -1284
  108. package/dist/chunks/basic-page-w6ftlo0h.js.map +0 -1
  109. package/dist/chunks/button-DNNs5RsT.js.map +0 -1
  110. package/dist/chunks/link-provider-9TFNyDqO.js +0 -28
  111. package/dist/chunks/link-provider-9TFNyDqO.js.map +0 -1
  112. package/dist/chunks/rolldown-runtime-wKSmTnsc.js +0 -22
  113. package/dist/chunks/scroll-area-Bu7egArU.js.map +0 -1
  114. package/dist/chunks/sidebar-DvB-G0BP.js +0 -231
  115. package/dist/chunks/sidebar-DvB-G0BP.js.map +0 -1
  116. package/dist/chunks/toast-DoXaRPIZ.js.map +0 -1
  117. package/dist/chunks/use-press-pulse-8iorQPsh.js +0 -62
  118. package/dist/chunks/use-press-pulse-8iorQPsh.js.map +0 -1
  119. package/dist/components/checkbox.js.map +0 -1
  120. package/dist/components/skeleton.js.map +0 -1
@@ -1,129 +1,7 @@
1
1
  "use client";
2
- import { t } from "../chunks/cn-ChIgwEl3.js";
3
- import { r as b } from "../chunks/use-press-pulse-8iorQPsh.js";
4
- import { n as x, r as k, t as v } from "../chunks/choice-card-CunOnY9l.js";
5
- import "react";
6
- import { jsx as e, jsxs as p } from "react/jsx-runtime";
7
- import { motion as u } from "motion/react";
8
- import { Checkbox as h } from "@base-ui/react/checkbox";
9
- import { CheckboxGroup as C } from "@base-ui/react/checkbox-group";
10
- var f = "M5 12l5 5l10 -10", y = "M5 12l14 0", N = {
11
- duration: 0.22,
12
- ease: "easeOut"
13
- };
14
- function g({ indeterminate: r, className: o }) {
15
- return /* @__PURE__ */ e("svg", {
16
- viewBox: "0 0 24 24",
17
- fill: "none",
18
- stroke: "currentColor",
19
- strokeWidth: 2,
20
- strokeLinecap: "round",
21
- strokeLinejoin: "round",
22
- className: o,
23
- "aria-hidden": "true",
24
- children: /* @__PURE__ */ e(u.path, {
25
- d: r ? y : f,
26
- initial: { pathLength: 0 },
27
- animate: { pathLength: 1 },
28
- transition: N
29
- }, r ? "minus" : "check")
30
- });
31
- }
32
- var I = {
33
- sm: "size-4",
34
- md: "size-5"
35
- }, _ = {
36
- sm: "size-3",
37
- md: "size-3.5"
38
- };
39
- function A({ className: r, label: o, size: s = "md", disabled: i, indeterminate: a, ...d }) {
40
- const { motionProps: l } = b({
41
- scale: 0.94,
42
- disabled: !!i
43
- }), { onPointerDown: c, ...n } = l, m = /* @__PURE__ */ e(h.Root, {
44
- disabled: i,
45
- indeterminate: a,
46
- render: /* @__PURE__ */ e(u.span, {
47
- ...n,
48
- onPointerDown: o ? void 0 : c
49
- }),
50
- className: t("group/cb outline-pho-brand bg-pho-primary ring-pho-primary text-pho-on-brand flex shrink-0 cursor-pointer items-center justify-center rounded-sm ring-1 ring-inset focus-visible:outline-2 focus-visible:outline-offset-2", "transition-[background-color,box-shadow,color,outline-color] duration-150 ease-out", "hover:bg-pho-primary-hover hover:ring-pho-ink group-hover:bg-pho-primary-hover group-hover:ring-pho-ink", "data-[checked]:bg-pho-brand-solid data-[checked]:ring-transparent", "data-[indeterminate]:bg-pho-brand-solid data-[indeterminate]:ring-transparent", "data-[checked]:hover:bg-pho-brand-solid-hover data-[checked]:group-hover:bg-pho-brand-solid-hover", "data-[indeterminate]:hover:bg-pho-brand-solid-hover data-[indeterminate]:group-hover:bg-pho-brand-solid-hover", "data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50", I[s], r),
51
- ...d,
52
- children: /* @__PURE__ */ e(h.Indicator, {
53
- className: t("flex items-center justify-center transition-opacity duration-100 ease-out", "data-[ending-style]:opacity-0"),
54
- children: /* @__PURE__ */ e(g, {
55
- indeterminate: a,
56
- className: _[s]
57
- })
58
- })
59
- });
60
- return o ? /* @__PURE__ */ p("label", {
61
- className: "group flex cursor-pointer items-center gap-2 select-none",
62
- onPointerDown: c,
63
- children: [m, /* @__PURE__ */ e("span", {
64
- className: "text-pho-secondary text-base",
65
- children: o
66
- })]
67
- }) : m;
68
- }
69
- A.displayName = "Checkbox";
70
- function P({ className: r, ...o }) {
71
- return /* @__PURE__ */ e(C, {
72
- className: t("flex flex-col gap-3", r),
73
- ...o
74
- });
75
- }
76
- P.displayName = "CheckboxGroup";
77
- function R({ title: r, description: o }) {
78
- return /* @__PURE__ */ p("span", { children: [/* @__PURE__ */ e("span", {
79
- className: "text-pho-primary block",
80
- children: r
81
- }), o ? /* @__PURE__ */ e("span", {
82
- className: "text-pho-description block",
83
- children: o
84
- }) : null] });
85
- }
86
- function O({ className: r, title: o, description: s, icon: i, disabled: a, indeterminate: d, ...l }) {
87
- const { motionProps: c } = b({
88
- scale: x,
89
- disabled: !!a,
90
- transition: k
91
- }), n = i != null;
92
- return /* @__PURE__ */ p(u.label, {
93
- ...c,
94
- className: t(v, n && "flex-col gap-1.5", r),
95
- "data-disabled": a ? "" : void 0,
96
- children: [
97
- /* @__PURE__ */ e(h.Root, {
98
- disabled: a,
99
- indeterminate: d,
100
- className: n ? "sr-only" : t("bg-pho-primary ring-pho-primary text-pho-on-brand mt-0.5 flex size-4 shrink-0 items-center justify-center rounded-sm ring-1 ring-inset", "group-hover:bg-pho-primary-hover group-hover:ring-pho-ink transition-[background-color,box-shadow,color] duration-150 ease-out", "data-[checked]:bg-pho-brand-solid data-[checked]:group-hover:bg-pho-brand-solid-hover data-[checked]:ring-transparent", "data-[indeterminate]:bg-pho-brand-solid data-[indeterminate]:group-hover:bg-pho-brand-solid-hover data-[indeterminate]:ring-transparent"),
101
- ...l,
102
- children: n ? null : /* @__PURE__ */ e(h.Indicator, {
103
- className: t("flex items-center justify-center transition-opacity duration-100 ease-out", "data-[ending-style]:opacity-0"),
104
- children: /* @__PURE__ */ e(g, {
105
- indeterminate: d,
106
- className: "size-2.5"
107
- })
108
- })
109
- }),
110
- n ? /* @__PURE__ */ e("span", {
111
- "aria-hidden": !0,
112
- className: "text-pho-secondary flex size-6 shrink-0 items-center justify-center [&>svg]:size-6",
113
- children: i
114
- }) : null,
115
- /* @__PURE__ */ e(R, {
116
- title: o,
117
- description: s
118
- })
119
- ]
120
- });
121
- }
122
- O.displayName = "CheckboxCard";
2
+ import { n as e, r, t as a } from "../chunks/checkbox-Cdm08HWG.js";
123
3
  export {
124
- A as Checkbox,
125
- O as CheckboxCard,
126
- P as CheckboxGroup
4
+ r as Checkbox,
5
+ a as CheckboxCard,
6
+ e as CheckboxGroup
127
7
  };
128
-
129
- //# sourceMappingURL=checkbox.js.map
@@ -1,72 +1,69 @@
1
1
  "use client";
2
2
  import { t as a } from "../chunks/cn-ChIgwEl3.js";
3
+ import { SPRING_SETTLE as j } from "../motion.js";
3
4
  import { t as z } from "../chunks/IconArrowUpRight-DGgKzQwV.js";
4
5
  import { t as M } from "../chunks/IconChevronLeft-CSWMKQ4C.js";
5
- import { t as O } from "../chunks/animated-height-C2eQstGy.js";
6
- import { t as d } from "../chunks/dialog-8SRNi_rv.js";
7
- import { useEffect as P, useId as D, useLayoutEffect as V, useRef as $ } from "react";
6
+ import { t as O } from "../chunks/animated-height-CCO-Ocoz.js";
7
+ import { t as d } from "../chunks/dialog-BxKACOj5.js";
8
+ import { useEffect as T, useId as D, useLayoutEffect as V, useRef as $ } from "react";
8
9
  import { Fragment as w, jsx as t, jsxs as u } from "react/jsx-runtime";
9
10
  import { LayoutGroup as A, motion as x, useReducedMotion as F } from "motion/react";
10
- import { Command as i, useCommandState as R } from "cmdk";
11
- var H = {
12
- type: "spring",
13
- stiffness: 640,
14
- damping: 50
15
- };
16
- function k({ shouldFilter: r = !1, className: e, children: n, ...l }) {
17
- const s = D();
18
- return /* @__PURE__ */ t(i, {
11
+ import { Command as s, useCommandState as R } from "cmdk";
12
+ var H = j;
13
+ function E({ shouldFilter: r = !1, className: e, children: n, ...l }) {
14
+ const i = D();
15
+ return /* @__PURE__ */ t(s, {
19
16
  className: a("bg-pho-primary text-pho-primary flex w-full flex-col overflow-hidden outline-none", e),
20
17
  shouldFilter: r,
21
18
  ...l,
22
19
  children: /* @__PURE__ */ t(A, {
23
- id: s,
20
+ id: i,
24
21
  children: n
25
22
  })
26
23
  });
27
24
  }
28
- function T({ className: r, ...e }) {
25
+ function B({ className: r, ...e }) {
29
26
  return /* @__PURE__ */ t("div", {
30
27
  className: a("border-pho-secondary relative flex items-center border-b", r),
31
28
  ...e
32
29
  });
33
30
  }
34
- var B = typeof window > "u" ? P : V;
35
- function U(r, e) {
31
+ var U = typeof window > "u" ? T : V;
32
+ function W(r, e) {
36
33
  typeof r == "function" ? r(e) : r && (r.current = e);
37
34
  }
38
- function W({ className: r, value: e, ref: n, ...l }) {
39
- const s = $(null), c = R((o) => o.search);
40
- return B(() => {
41
- const o = s.current;
35
+ function q({ className: r, value: e, ref: n, ...l }) {
36
+ const i = $(null), c = R((o) => o.search);
37
+ return U(() => {
38
+ const o = i.current;
42
39
  e == null || o == null || e === c || (Object.getOwnPropertyDescriptor(HTMLInputElement.prototype, "value")?.set?.call(o, e), o.dispatchEvent(new Event("input", { bubbles: !0 })));
43
- }, [e, c]), /* @__PURE__ */ t(i.Input, {
40
+ }, [e, c]), /* @__PURE__ */ t(s.Input, {
44
41
  className: a("text-pho-primary placeholder:text-pho-placeholder text-display-xs w-full bg-transparent px-3 py-3 outline-none disabled:cursor-not-allowed disabled:opacity-50", r),
45
42
  ...l,
46
43
  ref: (o) => {
47
- s.current = o, U(n, o);
44
+ i.current = o, W(n, o);
48
45
  }
49
46
  });
50
47
  }
51
- function q({ className: r, children: e, ...n }) {
48
+ function J({ className: r, children: e, ...n }) {
52
49
  return /* @__PURE__ */ t(O, { children: /* @__PURE__ */ t(x.div, {
53
50
  layoutScroll: !0,
54
51
  className: "max-h-[min(24rem,60vh)] scroll-py-1 overflow-y-auto overscroll-contain",
55
- children: /* @__PURE__ */ t(i.List, {
52
+ children: /* @__PURE__ */ t(s.List, {
56
53
  className: a("relative isolate p-1", r),
57
54
  ...n,
58
55
  children: e
59
56
  })
60
57
  }) });
61
58
  }
62
- function J({ className: r, ...e }) {
63
- return /* @__PURE__ */ t(i.Empty, {
59
+ function K({ className: r, ...e }) {
60
+ return /* @__PURE__ */ t(s.Empty, {
64
61
  className: a("text-pho-description px-2.5 py-6 text-center text-base", r),
65
62
  ...e
66
63
  });
67
64
  }
68
- function K({ className: r, ...e }) {
69
- return /* @__PURE__ */ t(i.Group, {
65
+ function Q({ className: r, ...e }) {
66
+ return /* @__PURE__ */ t(s.Group, {
70
67
  className: a("[&_[cmdk-group-heading]]:text-pho-secondary [&_[cmdk-group-heading]]:px-2.5 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs", r),
71
68
  ...e
72
69
  });
@@ -77,7 +74,7 @@ function f({ className: r, ...e }) {
77
74
  ...e
78
75
  });
79
76
  }
80
- function E({ className: r, level: e = "item", ...n }) {
77
+ function k({ className: r, level: e = "item", ...n }) {
81
78
  return /* @__PURE__ */ t("span", {
82
79
  className: a("text-md block truncate", e === "item" && "text-pho-primary", r),
83
80
  ...n
@@ -89,8 +86,8 @@ function I() {
89
86
  className: "text-pho-description size-4 shrink-0"
90
87
  });
91
88
  }
92
- function Q({ className: r, level: e = "item", icon: n, iconSlot: l, title: s, path: c, scope: o, external: y, children: m, value: p, ...L }) {
93
- const G = F(), g = typeof p == "string" ? p.trim() : "", S = R((h) => h.value), _ = g !== "" && S === g, b = s != null, N = e === "result", C = N && (n != null || l), v = /* @__PURE__ */ t(i.Item, {
89
+ function X({ className: r, level: e = "item", icon: n, iconSlot: l, title: i, path: c, scope: o, external: y, children: m, value: p, ...L }) {
90
+ const S = F(), g = typeof p == "string" ? p.trim() : "", G = R((h) => h.value), _ = g !== "" && G === g, b = i != null, N = e === "result", C = N && (n != null || l), v = /* @__PURE__ */ t(s.Item, {
94
91
  "data-level": e,
95
92
  value: p,
96
93
  className: a("text-pho-secondary flex cursor-pointer items-center gap-2 rounded-[calc(var(--radius-base)-4px)] py-2 pr-2.5 text-base outline-none select-none", e === "subsubitem" ? "pl-6" : "pl-2", "data-[selected=true]:text-pho-primary data-[selected=true]:bg-pho-ghost-hover", "data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50", r),
@@ -104,14 +101,14 @@ function Q({ className: r, level: e = "item", icon: n, iconSlot: l, title: s, pa
104
101
  className: "text-md flex min-w-0 flex-1 items-center gap-1 overflow-hidden",
105
102
  children: [/* @__PURE__ */ t("span", {
106
103
  className: "text-pho-primary truncate",
107
- children: s
108
- }), (c ?? []).map((h, j) => /* @__PURE__ */ u("span", {
104
+ children: i
105
+ }), (c ?? []).map((h, P) => /* @__PURE__ */ u("span", {
109
106
  className: "text-pho-description flex shrink-0 items-center gap-0.5",
110
107
  children: [/* @__PURE__ */ t(M, {
111
108
  "aria-hidden": !0,
112
109
  className: "size-4 shrink-0"
113
110
  }), h]
114
- }, j))]
111
+ }, P))]
115
112
  }),
116
113
  o != null && o !== "" ? /* @__PURE__ */ t("span", {
117
114
  className: "text-pho-description shrink-0 text-xs",
@@ -126,16 +123,16 @@ function Q({ className: r, level: e = "item", icon: n, iconSlot: l, title: s, pa
126
123
  }),
127
124
  /* @__PURE__ */ t("span", {
128
125
  className: "min-w-0 flex-1",
129
- children: /* @__PURE__ */ t(E, {
126
+ children: /* @__PURE__ */ t(k, {
130
127
  level: e,
131
- children: s
128
+ children: i
132
129
  })
133
130
  }),
134
131
  y ? /* @__PURE__ */ t(I, {}) : null,
135
132
  m
136
133
  ] }) : m
137
134
  });
138
- return G ? v : /* @__PURE__ */ t(x.div, {
135
+ return S ? v : /* @__PURE__ */ t(x.div, {
139
136
  layout: "position",
140
137
  layoutId: typeof p == "string" ? p : void 0,
141
138
  initial: !1,
@@ -143,19 +140,19 @@ function Q({ className: r, level: e = "item", icon: n, iconSlot: l, title: s, pa
143
140
  children: v
144
141
  });
145
142
  }
146
- function X({ className: r, ...e }) {
147
- return /* @__PURE__ */ t(i.Separator, {
143
+ function Y({ className: r, ...e }) {
144
+ return /* @__PURE__ */ t(s.Separator, {
148
145
  className: a("-mx-1 my-1 h-px bg-[var(--border-color-pho-secondary)]", r),
149
146
  ...e
150
147
  });
151
148
  }
152
- function Y({ className: r, ...e }) {
153
- return /* @__PURE__ */ t(i.Loading, {
149
+ function Z({ className: r, ...e }) {
150
+ return /* @__PURE__ */ t(s.Loading, {
154
151
  className: a("text-pho-description px-2.5 py-1.5 text-base", r),
155
152
  ...e
156
153
  });
157
154
  }
158
- function Z({ open: r, onOpenChange: e, label: n, className: l, children: s, ...c }) {
155
+ function ee({ open: r, onOpenChange: e, label: n, className: l, children: i, ...c }) {
159
156
  return /* @__PURE__ */ t(d.Root, {
160
157
  open: r,
161
158
  onOpenChange: e,
@@ -164,31 +161,31 @@ function Z({ open: r, onOpenChange: e, label: n, className: l, children: s, ...c
164
161
  className: a("top-[max(4rem,18vh)] max-w-xl translate-y-0 overflow-hidden p-0", l),
165
162
  children: /* @__PURE__ */ t(x.div, {
166
163
  layoutRoot: !0,
167
- children: /* @__PURE__ */ t(k, {
164
+ children: /* @__PURE__ */ t(E, {
168
165
  label: n,
169
166
  ...c,
170
- children: s
167
+ children: i
171
168
  })
172
169
  })
173
170
  })] })
174
171
  });
175
172
  }
176
- var ce = {
177
- Root: k,
178
- InputGroup: T,
179
- Input: W,
180
- List: q,
181
- Empty: J,
182
- Group: K,
183
- Item: Q,
173
+ var ue = {
174
+ Root: E,
175
+ InputGroup: B,
176
+ Input: q,
177
+ List: J,
178
+ Empty: K,
179
+ Group: Q,
180
+ Item: X,
184
181
  ItemIcon: f,
185
- ItemTitle: E,
186
- Separator: X,
187
- Loading: Y,
188
- Dialog: Z
182
+ ItemTitle: k,
183
+ Separator: Y,
184
+ Loading: Z,
185
+ Dialog: ee
189
186
  };
190
187
  export {
191
- ce as Command,
188
+ ue as Command,
192
189
  R as useCommandState
193
190
  };
194
191
 
@@ -1 +1 @@
1
- {"version":3,"file":"command.js","names":[],"sources":["../../src/components/command/command.tsx"],"sourcesContent":["import {\n useEffect,\n useId,\n useLayoutEffect,\n useRef,\n type ComponentProps,\n type ReactNode,\n type Ref,\n} from \"react\";\nimport { IconArrowUpRight, IconChevronLeft } from \"@tabler/icons-react\";\nimport { Command as CommandPrimitive, useCommandState } from \"cmdk\";\nimport { LayoutGroup, motion, useReducedMotion } from \"motion/react\";\nimport { AnimatedHeight } from \"../../utils/animated-height\";\nimport { cn } from \"../../utils/cn\";\nimport { Dialog as PhoDialog } from \"../dialog\";\n\n/**\n * Spring for row moves (FLIP / shared-layout) — same feel as\n * `AnimatedHeight`: quick and critically damped, so rows glide to their new\n * slot without overshooting into neighbours.\n */\nconst ROW_MOVE_SPRING = {\n type: \"spring\",\n stiffness: 640,\n damping: 50,\n} as const;\n\nfunction Root({\n // Filtering is yours by default: filter in render (state above the\n // palette) so the rows' FLIP diff can glide survivors to their slots.\n // cmdk's built-in matcher reorders DOM imperatively — invisible to the\n // layout pass — so it is opt-in: pass `shouldFilter` to hand matching\n // and ranking back to cmdk at the cost of the animation.\n shouldFilter = false,\n className,\n children,\n ...props\n}: ComponentProps<typeof CommandPrimitive>) {\n // Namespace row layoutIds per palette instance — the docs page mounts the\n // inline demo and the dialog demo at once, with identical item values.\n const layoutNamespace = useId();\n return (\n <CommandPrimitive\n className={cn(\n \"bg-pho-primary text-pho-primary flex w-full flex-col overflow-hidden outline-none\",\n className,\n )}\n shouldFilter={shouldFilter}\n {...props}\n >\n <LayoutGroup id={layoutNamespace}>{children}</LayoutGroup>\n </CommandPrimitive>\n );\n}\n\n/**\n * The input row — a bottom hairline separates it from the list. Position\n * leading icons absolutely and pad the input (`pl-9`), mirroring\n * `Autocomplete.InputGroup`.\n */\nfunction InputGroup({ className, ...props }: ComponentProps<\"div\">) {\n return (\n <div\n className={cn(\n \"border-pho-secondary relative flex items-center border-b\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/** SSR-safe layout effect (same pattern cmdk uses internally). */\nconst useIsomorphicLayoutEffect =\n typeof window === \"undefined\" ? useEffect : useLayoutEffect;\n\nfunction assignRef<T>(ref: Ref<T> | undefined, value: T | null) {\n if (typeof ref === \"function\") ref(value);\n else if (ref) ref.current = value;\n}\n\nfunction Input({\n className,\n value,\n ref: consumerRef,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Input>) {\n const inputRef = useRef<HTMLInputElement>(null);\n const search = useCommandState((state) => state.search);\n\n // cmdk stays uncontrolled here on purpose. Its controlled path syncs the\n // `value` prop into the search store through a passive effect — one painted\n // frame late — so on that stale frame the old row is still \"selected\" while\n // the list has already reflowed, and the selection pill visibly rides it\n // before snapping to the re-selected first row. Uncontrolled keystrokes\n // update search + first-row selection synchronously (pre-paint), killing\n // that frame in both directions (typing and clearing).\n //\n // The consumer-facing API is still controlled: external `value` changes\n // (programmatic reset, initial query) are replayed through the native input\n // path below so store, display, and selection take the same sync route.\n useIsomorphicLayoutEffect(() => {\n const input = inputRef.current;\n if (value == null || input == null || value === search) return;\n const setNativeValue = Object.getOwnPropertyDescriptor(\n HTMLInputElement.prototype,\n \"value\",\n )?.set;\n setNativeValue?.call(input, value);\n input.dispatchEvent(new Event(\"input\", { bubbles: true }));\n }, [value, search]);\n\n return (\n <CommandPrimitive.Input\n className={cn(\n // Borderless inside the palette surface — the InputGroup hairline\n // carries the edge. display-xs (18px) keeps iOS from zooming in.\n \"text-pho-primary placeholder:text-pho-placeholder text-display-xs w-full bg-transparent px-3 py-3 outline-none disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n ref={(node) => {\n inputRef.current = node;\n assignRef(consumerRef, node);\n }}\n />\n );\n}\n\nfunction List({\n className,\n children,\n ...props\n}: ComponentProps<typeof CommandPrimitive.List>) {\n return (\n // Same spring as the onboarding / invite Card shell — list height glides\n // when idle ↔ search (or filter) changes instead of jumping.\n <AnimatedHeight>\n {/* The scroller is a motion element with layoutScroll so the rows'\n FLIP projections account for its scroll offset — without it,\n scrolling reads as a layout change and every row glides to\n compensate. scroll-py keeps a breath above and below the row\n being scrolled into view. */}\n <motion.div\n layoutScroll\n className=\"max-h-[min(24rem,60vh)] scroll-py-1 overflow-y-auto overscroll-contain\"\n >\n <CommandPrimitive.List\n className={cn(\"relative isolate p-1\", className)}\n {...props}\n >\n {children}\n </CommandPrimitive.List>\n </motion.div>\n </AnimatedHeight>\n );\n}\n\nfunction Empty({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Empty>) {\n return (\n <CommandPrimitive.Empty\n className={cn(\n \"text-pho-description px-2.5 py-6 text-center text-base\",\n className,\n )}\n {...props}\n />\n );\n}\n\nfunction Group({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Group>) {\n return (\n <CommandPrimitive.Group\n className={cn(\n // cmdk renders the `heading` prop in a [cmdk-group-heading] wrapper —\n // typography mirrors `Autocomplete.GroupLabel`.\n \"[&_[cmdk-group-heading]]:text-pho-secondary [&_[cmdk-group-heading]]:px-2.5 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/**\n * Row layout mode:\n * - `item` / `subitem` / `subsubitem` — idle hierarchy (icon column + indent)\n * - `result` — flat search hit (breadcrumb + trailing scope)\n */\nexport type CommandItemLevel = \"item\" | \"subitem\" | \"subsubitem\" | \"result\";\n\ntype ItemPrimitiveProps = ComponentProps<typeof CommandPrimitive.Item>;\n\nexport interface CommandItemProps extends Omit<\n ItemPrimitiveProps,\n \"children\" | \"title\"\n> {\n /**\n * Row depth / mode in the palette:\n * - `item` — page / top destination (icon + title)\n * - `subitem` — section under an item (label aligns with the item title)\n * - `subsubitem` — row under a section (one step deeper)\n * - `result` — flat search hit (`title` + `path` crumbs + `scope`)\n */\n level?: CommandItemLevel;\n /**\n * Leading glyph. On idle `item` rows (and reserved for sub-levels). On\n * `result` rows, pass the resolved icon (self → parent → grandparent).\n */\n icon?: ReactNode;\n /**\n * When `level=\"result\"`, force the icon column so labels align across the\n * list even if this row's `icon` is empty. Set true when any sibling result\n * has an icon; omit when the whole result set is icon-less.\n */\n iconSlot?: boolean;\n /** Primary label. Prefer this over free-form children for the shared layout. */\n title?: ReactNode;\n /**\n * Ancestors after `title` for `level=\"result\"` — parent → page\n * (e.g. `[\"Agent profile\", \"Settings\"]` → `Name < Agent profile < Settings`).\n */\n path?: ReactNode[];\n /**\n * Trailing scope for `level=\"result\"` — `Project` vs `Personal`, not a nav group.\n */\n scope?: ReactNode;\n /** Shows a trailing external-link glyph (opens outside the app). */\n external?: boolean;\n /**\n * Free-form content. When `title` is set, rendered after the label stack.\n * When `title` is omitted, becomes the row body (legacy / simple items).\n */\n children?: ReactNode;\n}\n\n/** Leading icon column — `size-4`, secondary ink. */\nfunction ItemIcon({ className, ...props }: ComponentProps<\"span\">) {\n return (\n <span\n className={cn(\n \"text-pho-secondary flex size-4 shrink-0 items-center justify-center [&>svg]:size-4\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/** Primary label — medium + primary ink on `item` rows. */\nfunction ItemTitle({\n className,\n level = \"item\",\n ...props\n}: ComponentProps<\"span\"> & { level?: CommandItemLevel }) {\n return (\n <span\n className={cn(\n \"text-md block truncate\",\n level === \"item\" && \"text-pho-primary\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/**\n * One selectable row. Idle palettes use `level` + `icon` / `title`\n * (item → subitem → subsubitem). Searching uses `level=\"result\"` with `path`\n * crumbs and a trailing `scope` (Project / Personal). No description line —\n * match via `keywords` / aliases instead.\n */\nfunction ExternalGlyph() {\n return (\n <IconArrowUpRight\n aria-hidden\n className=\"text-pho-description size-4 shrink-0\"\n />\n );\n}\n\nfunction Item({\n className,\n level = \"item\",\n icon,\n iconSlot,\n title,\n path,\n scope,\n external,\n children,\n value,\n ...props\n}: CommandItemProps) {\n const reduceMotion = useReducedMotion();\n // cmdk registers `value.trim()` and exposes the selected one as\n // `state.value` — mirrors cmdk's own `data-selected` computation.\n const trimmedValue = typeof value === \"string\" ? value.trim() : \"\";\n const selectedValue = useCommandState((state) => state.value);\n const isSelected = trimmedValue !== \"\" && selectedValue === trimmedValue;\n const structured = title != null;\n const isResult = level === \"result\";\n // Reserve the icon column when the row has an icon, or when the list asks\n // for alignment (`iconSlot`) even if this row's glyph is empty.\n const showResultIcon = isResult && (icon != null || iconSlot);\n\n const row = (\n <CommandPrimitive.Item\n data-level={level}\n value={value}\n className={cn(\n \"text-pho-secondary flex cursor-pointer items-center gap-2 rounded-[calc(var(--radius-base)-4px)] py-2 pr-2.5 text-base outline-none select-none\",\n // subsubitem steps in; item/subitem share the base gutter.\n level === \"subsubitem\" ? \"pl-6\" : \"pl-2\",\n // Secondary at rest; selection lifts to primary ink (Menu idiom).\n // The wash lands with it instantly — stepping through rows is a\n // snap, not a flight.\n \"data-[selected=true]:text-pho-primary data-[selected=true]:bg-pho-ghost-hover\",\n \"data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50\",\n className,\n )}\n {...props}\n >\n {structured && isResult ? (\n <>\n {showResultIcon ? (\n <ItemIcon aria-hidden={icon == null ? true : undefined}>\n {icon ?? null}\n </ItemIcon>\n ) : null}\n {/* Same text-md line box as idle ItemTitle so row height matches (36px). */}\n <span className=\"text-md flex min-w-0 flex-1 items-center gap-1 overflow-hidden\">\n <span className=\"text-pho-primary truncate\">{title}</span>\n {(path ?? []).map((segment, index) => (\n <span\n key={index}\n className=\"text-pho-description flex shrink-0 items-center gap-0.5\"\n >\n <IconChevronLeft aria-hidden className=\"size-4 shrink-0\" />\n {segment}\n </span>\n ))}\n </span>\n {scope != null && scope !== \"\" ? (\n <span className=\"text-pho-description shrink-0 text-xs\">\n {scope}\n </span>\n ) : null}\n {external ? <ExternalGlyph /> : null}\n {children}\n </>\n ) : structured ? (\n <>\n {/* Icon column always reserved so subitem labels share the item title edge. */}\n <ItemIcon aria-hidden={icon == null ? true : undefined}>\n {icon ?? null}\n </ItemIcon>\n <span className=\"min-w-0 flex-1\">\n <ItemTitle level={level}>{title}</ItemTitle>\n </span>\n {external ? <ExternalGlyph /> : null}\n {children}\n </>\n ) : (\n children\n )}\n </CommandPrimitive.Item>\n );\n\n if (reduceMotion) return row;\n\n return (\n // FLIP wrapper: rows that stay mounted glide when neighbours enter or\n // leave, and a row remounting elsewhere with the same `value` (idle group\n // ↔ flat search result) inherits the old bounds via its layoutId and\n // slides to the new slot — the iOS list-diff feel. Rows without a match\n // simply appear / disappear so the whole list never swarms.\n //\n // The selected row is the exception: it skips the travel and appears at\n // its final slot immediately, so the selection wash is never sitting on\n // empty space waiting for its row to fly in.\n <motion.div\n layout=\"position\"\n layoutId={typeof value === \"string\" ? value : undefined}\n initial={false}\n transition={isSelected ? { duration: 0 } : ROW_MOVE_SPRING}\n >\n {row}\n </motion.div>\n );\n}\n\nfunction Separator({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Separator>) {\n return (\n <CommandPrimitive.Separator\n className={cn(\n \"-mx-1 my-1 h-px bg-[var(--border-color-pho-secondary)]\",\n className,\n )}\n {...props}\n />\n );\n}\n\nfunction Loading({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Loading>) {\n return (\n <CommandPrimitive.Loading\n className={cn(\"text-pho-description px-2.5 py-1.5 text-base\", className)}\n {...props}\n />\n );\n}\n\ntype DialogRootProps = ComponentProps<typeof PhoDialog.Root>;\n\ninterface CommandDialogProps extends ComponentProps<typeof CommandPrimitive> {\n /** Controlled dialog state — pass straight through to `Dialog.Root`. */\n open?: DialogRootProps[\"open\"];\n onOpenChange?: DialogRootProps[\"onOpenChange\"];\n /** Accessible name for the palette (dialog and command menu). */\n label?: string;\n /** Extra classes for the dialog panel (not the command root). */\n className?: string;\n}\n\n/**\n * A command palette in a modal — Pho's `Dialog` overlay (Base UI) around a\n * `Command.Root`, raised above center. We deliberately skip cmdk's own\n * `Command.Dialog` (Radix) so overlays stay on one primitive stack.\n *\n * List height springs via `AnimatedHeight` (same feel as the Card shell on\n * onboarding / invite) — the input row stays put while results resize.\n */\nfunction Dialog({\n open,\n onOpenChange,\n label,\n className,\n children,\n ...props\n}: CommandDialogProps) {\n return (\n <PhoDialog.Root open={open} onOpenChange={onOpenChange}>\n <PhoDialog.Portal>\n <PhoDialog.Backdrop />\n <PhoDialog.Popup\n aria-label={label}\n // Palette sits above center so the list grows downward from a\n // stable top edge instead of jumping around it.\n className={cn(\n \"top-[max(4rem,18vh)] max-w-xl translate-y-0 overflow-hidden p-0\",\n className,\n )}\n >\n {/* The popup is position: fixed; layout animations inside a fixed\n element need a layoutRoot to project against, or their\n measurements drift with the page scroll. */}\n <motion.div layoutRoot>\n <Root label={label} {...props}>\n {children}\n </Root>\n </motion.div>\n </PhoDialog.Popup>\n </PhoDialog.Portal>\n </PhoDialog.Root>\n );\n}\n\n/**\n * Command menu built on `cmdk` — a filterable list of actions driven from a\n * single input, keyboard-first. Compose inline (`Command.Root`) or as a\n * ⌘K-style modal palette (`Command.Dialog`, which owns the overlay).\n * Filtering is yours by default — filter in render so the rows' diff can\n * glide; pass `shouldFilter` to hand matching and ranking to cmdk (its\n * imperative reorder skips the animation).\n *\n * Rows share one layout via `Command.Item` `level` — idle\n * `item` → `subitem` → `subsubitem`, or flat `result` while searching.\n */\nexport const Command = {\n Root,\n InputGroup,\n Input,\n List,\n Empty,\n Group,\n Item,\n ItemIcon,\n ItemTitle,\n Separator,\n Loading,\n Dialog,\n};\n\n/** Re-export of cmdk's state selector hook (search, value, filtered counts). */\nexport { useCommandState };\n"],"mappings":";;;;;;;;;;AAqBA,IAAM,IAAkB;AAAA,EACtB,MAAM;AAAA,EACN,WAAW;AAAA,EACX,SAAS;AACX;AAEA,SAAS,EAAK,EAMZ,cAAA,IAAe,IACf,WAAA,GACA,UAAA,GACA,GAAG,EAAA,GACuC;AAG1C,QAAM,IAAkB,EAAM;AAC9B,SACE,gBAAA,EAAC,GAAD;AAAA,IACE,WAAW,EACT,qFACA,CACF;AAAA,IACc,cAAA;AAAA,IACd,GAAI;AAAA,IAEJ,UAAA,gBAAA,EAAC,GAAD;AAAA,MAAa,IAAI;AAAA,MAAkB,UAAA;AAAA,IAAsB,CAAA;AAAA,EACzC,CAAA;AAEtB;AAOA,SAAS,EAAW,EAAE,WAAA,GAAW,GAAG,EAAA,GAAgC;AAClE,SACE,gBAAA,EAAC,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AA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,UAAA;AAAA,EACA,WAAA;AAAA,EACA,WAAA;AAAA,EACA,SAAA;AAAA,EACA,QAAA;AACF"}
1
+ {"version":3,"file":"command.js","names":[],"sources":["../../src/components/command/command.tsx"],"sourcesContent":["import {\n useEffect,\n useId,\n useLayoutEffect,\n useRef,\n type ComponentProps,\n type ReactNode,\n type Ref,\n} from \"react\";\nimport { IconArrowUpRight, IconChevronLeft } from \"@tabler/icons-react\";\nimport { SPRING_SETTLE } from \"../../motion\";\nimport { Command as CommandPrimitive, useCommandState } from \"cmdk\";\nimport { LayoutGroup, motion, useReducedMotion } from \"motion/react\";\nimport { AnimatedHeight } from \"../../utils/animated-height\";\nimport { cn } from \"../../utils/cn\";\nimport { Dialog as PhoDialog } from \"../dialog\";\n\n/**\n * Spring for row moves (FLIP / shared-layout) — same feel as\n * `AnimatedHeight`: quick and critically damped, so rows glide to their new\n * slot without overshooting into neighbours.\n */\nconst ROW_MOVE_SPRING = SPRING_SETTLE;\n\nfunction Root({\n // Filtering is yours by default: filter in render (state above the\n // palette) so the rows' FLIP diff can glide survivors to their slots.\n // cmdk's built-in matcher reorders DOM imperatively — invisible to the\n // layout pass — so it is opt-in: pass `shouldFilter` to hand matching\n // and ranking back to cmdk at the cost of the animation.\n shouldFilter = false,\n className,\n children,\n ...props\n}: ComponentProps<typeof CommandPrimitive>) {\n // Namespace row layoutIds per palette instance — the docs page mounts the\n // inline demo and the dialog demo at once, with identical item values.\n const layoutNamespace = useId();\n return (\n <CommandPrimitive\n className={cn(\n \"bg-pho-primary text-pho-primary flex w-full flex-col overflow-hidden outline-none\",\n className,\n )}\n shouldFilter={shouldFilter}\n {...props}\n >\n <LayoutGroup id={layoutNamespace}>{children}</LayoutGroup>\n </CommandPrimitive>\n );\n}\n\n/**\n * The input row — a bottom hairline separates it from the list. Position\n * leading icons absolutely and pad the input (`pl-9`), mirroring\n * `Autocomplete.InputGroup`.\n */\nfunction InputGroup({ className, ...props }: ComponentProps<\"div\">) {\n return (\n <div\n className={cn(\n \"border-pho-secondary relative flex items-center border-b\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/** SSR-safe layout effect (same pattern cmdk uses internally). */\nconst useIsomorphicLayoutEffect =\n typeof window === \"undefined\" ? useEffect : useLayoutEffect;\n\nfunction assignRef<T>(ref: Ref<T> | undefined, value: T | null) {\n if (typeof ref === \"function\") ref(value);\n else if (ref) ref.current = value;\n}\n\nfunction Input({\n className,\n value,\n ref: consumerRef,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Input>) {\n const inputRef = useRef<HTMLInputElement>(null);\n const search = useCommandState((state) => state.search);\n\n // cmdk stays uncontrolled here on purpose. Its controlled path syncs the\n // `value` prop into the search store through a passive effect — one painted\n // frame late — so on that stale frame the old row is still \"selected\" while\n // the list has already reflowed, and the selection pill visibly rides it\n // before snapping to the re-selected first row. Uncontrolled keystrokes\n // update search + first-row selection synchronously (pre-paint), killing\n // that frame in both directions (typing and clearing).\n //\n // The consumer-facing API is still controlled: external `value` changes\n // (programmatic reset, initial query) are replayed through the native input\n // path below so store, display, and selection take the same sync route.\n useIsomorphicLayoutEffect(() => {\n const input = inputRef.current;\n if (value == null || input == null || value === search) return;\n const setNativeValue = Object.getOwnPropertyDescriptor(\n HTMLInputElement.prototype,\n \"value\",\n )?.set;\n setNativeValue?.call(input, value);\n input.dispatchEvent(new Event(\"input\", { bubbles: true }));\n }, [value, search]);\n\n return (\n <CommandPrimitive.Input\n className={cn(\n // Borderless inside the palette surface — the InputGroup hairline\n // carries the edge. display-xs (18px) keeps iOS from zooming in.\n \"text-pho-primary placeholder:text-pho-placeholder text-display-xs w-full bg-transparent px-3 py-3 outline-none disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n ref={(node) => {\n inputRef.current = node;\n assignRef(consumerRef, node);\n }}\n />\n );\n}\n\nfunction List({\n className,\n children,\n ...props\n}: ComponentProps<typeof CommandPrimitive.List>) {\n return (\n // Same spring as the onboarding / invite Card shell — list height glides\n // when idle ↔ search (or filter) changes instead of jumping.\n <AnimatedHeight>\n {/* The scroller is a motion element with layoutScroll so the rows'\n FLIP projections account for its scroll offset — without it,\n scrolling reads as a layout change and every row glides to\n compensate. scroll-py keeps a breath above and below the row\n being scrolled into view. */}\n <motion.div\n layoutScroll\n className=\"max-h-[min(24rem,60vh)] scroll-py-1 overflow-y-auto overscroll-contain\"\n >\n <CommandPrimitive.List\n className={cn(\"relative isolate p-1\", className)}\n {...props}\n >\n {children}\n </CommandPrimitive.List>\n </motion.div>\n </AnimatedHeight>\n );\n}\n\nfunction Empty({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Empty>) {\n return (\n <CommandPrimitive.Empty\n className={cn(\n \"text-pho-description px-2.5 py-6 text-center text-base\",\n className,\n )}\n {...props}\n />\n );\n}\n\nfunction Group({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Group>) {\n return (\n <CommandPrimitive.Group\n className={cn(\n // cmdk renders the `heading` prop in a [cmdk-group-heading] wrapper —\n // typography mirrors `Autocomplete.GroupLabel`.\n \"[&_[cmdk-group-heading]]:text-pho-secondary [&_[cmdk-group-heading]]:px-2.5 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/**\n * Row layout mode:\n * - `item` / `subitem` / `subsubitem` — idle hierarchy (icon column + indent)\n * - `result` — flat search hit (breadcrumb + trailing scope)\n */\nexport type CommandItemLevel = \"item\" | \"subitem\" | \"subsubitem\" | \"result\";\n\ntype ItemPrimitiveProps = ComponentProps<typeof CommandPrimitive.Item>;\n\nexport interface CommandItemProps extends Omit<\n ItemPrimitiveProps,\n \"children\" | \"title\"\n> {\n /**\n * Row depth / mode in the palette:\n * - `item` — page / top destination (icon + title)\n * - `subitem` — section under an item (label aligns with the item title)\n * - `subsubitem` — row under a section (one step deeper)\n * - `result` — flat search hit (`title` + `path` crumbs + `scope`)\n */\n level?: CommandItemLevel;\n /**\n * Leading glyph. On idle `item` rows (and reserved for sub-levels). On\n * `result` rows, pass the resolved icon (self → parent → grandparent).\n */\n icon?: ReactNode;\n /**\n * When `level=\"result\"`, force the icon column so labels align across the\n * list even if this row's `icon` is empty. Set true when any sibling result\n * has an icon; omit when the whole result set is icon-less.\n */\n iconSlot?: boolean;\n /** Primary label. Prefer this over free-form children for the shared layout. */\n title?: ReactNode;\n /**\n * Ancestors after `title` for `level=\"result\"` — parent → page\n * (e.g. `[\"Agent profile\", \"Settings\"]` → `Name < Agent profile < Settings`).\n */\n path?: ReactNode[];\n /**\n * Trailing scope for `level=\"result\"` — `Project` vs `Personal`, not a nav group.\n */\n scope?: ReactNode;\n /** Shows a trailing external-link glyph (opens outside the app). */\n external?: boolean;\n /**\n * Free-form content. When `title` is set, rendered after the label stack.\n * When `title` is omitted, becomes the row body (legacy / simple items).\n */\n children?: ReactNode;\n}\n\n/** Leading icon column — `size-4`, secondary ink. */\nfunction ItemIcon({ className, ...props }: ComponentProps<\"span\">) {\n return (\n <span\n className={cn(\n \"text-pho-secondary flex size-4 shrink-0 items-center justify-center [&>svg]:size-4\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/** Primary label — medium + primary ink on `item` rows. */\nfunction ItemTitle({\n className,\n level = \"item\",\n ...props\n}: ComponentProps<\"span\"> & { level?: CommandItemLevel }) {\n return (\n <span\n className={cn(\n \"text-md block truncate\",\n level === \"item\" && \"text-pho-primary\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/**\n * One selectable row. Idle palettes use `level` + `icon` / `title`\n * (item → subitem → subsubitem). Searching uses `level=\"result\"` with `path`\n * crumbs and a trailing `scope` (Project / Personal). No description line —\n * match via `keywords` / aliases instead.\n */\nfunction ExternalGlyph() {\n return (\n <IconArrowUpRight\n aria-hidden\n className=\"text-pho-description size-4 shrink-0\"\n />\n );\n}\n\nfunction Item({\n className,\n level = \"item\",\n icon,\n iconSlot,\n title,\n path,\n scope,\n external,\n children,\n value,\n ...props\n}: CommandItemProps) {\n const reduceMotion = useReducedMotion();\n // cmdk registers `value.trim()` and exposes the selected one as\n // `state.value` — mirrors cmdk's own `data-selected` computation.\n const trimmedValue = typeof value === \"string\" ? value.trim() : \"\";\n const selectedValue = useCommandState((state) => state.value);\n const isSelected = trimmedValue !== \"\" && selectedValue === trimmedValue;\n const structured = title != null;\n const isResult = level === \"result\";\n // Reserve the icon column when the row has an icon, or when the list asks\n // for alignment (`iconSlot`) even if this row's glyph is empty.\n const showResultIcon = isResult && (icon != null || iconSlot);\n\n const row = (\n <CommandPrimitive.Item\n data-level={level}\n value={value}\n className={cn(\n \"text-pho-secondary flex cursor-pointer items-center gap-2 rounded-[calc(var(--radius-base)-4px)] py-2 pr-2.5 text-base outline-none select-none\",\n // subsubitem steps in; item/subitem share the base gutter.\n level === \"subsubitem\" ? \"pl-6\" : \"pl-2\",\n // Secondary at rest; selection lifts to primary ink (Menu idiom).\n // The wash lands with it instantly — stepping through rows is a\n // snap, not a flight.\n \"data-[selected=true]:text-pho-primary data-[selected=true]:bg-pho-ghost-hover\",\n \"data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50\",\n className,\n )}\n {...props}\n >\n {structured && isResult ? (\n <>\n {showResultIcon ? (\n <ItemIcon aria-hidden={icon == null ? true : undefined}>\n {icon ?? null}\n </ItemIcon>\n ) : null}\n {/* Same text-md line box as idle ItemTitle so row height matches (36px). */}\n <span className=\"text-md flex min-w-0 flex-1 items-center gap-1 overflow-hidden\">\n <span className=\"text-pho-primary truncate\">{title}</span>\n {(path ?? []).map((segment, index) => (\n <span\n key={index}\n className=\"text-pho-description flex shrink-0 items-center gap-0.5\"\n >\n <IconChevronLeft aria-hidden className=\"size-4 shrink-0\" />\n {segment}\n </span>\n ))}\n </span>\n {scope != null && scope !== \"\" ? (\n <span className=\"text-pho-description shrink-0 text-xs\">\n {scope}\n </span>\n ) : null}\n {external ? <ExternalGlyph /> : null}\n {children}\n </>\n ) : structured ? (\n <>\n {/* Icon column always reserved so subitem labels share the item title edge. */}\n <ItemIcon aria-hidden={icon == null ? true : undefined}>\n {icon ?? null}\n </ItemIcon>\n <span className=\"min-w-0 flex-1\">\n <ItemTitle level={level}>{title}</ItemTitle>\n </span>\n {external ? <ExternalGlyph /> : null}\n {children}\n </>\n ) : (\n children\n )}\n </CommandPrimitive.Item>\n );\n\n if (reduceMotion) return row;\n\n return (\n // FLIP wrapper: rows that stay mounted glide when neighbours enter or\n // leave, and a row remounting elsewhere with the same `value` (idle group\n // ↔ flat search result) inherits the old bounds via its layoutId and\n // slides to the new slot — the iOS list-diff feel. Rows without a match\n // simply appear / disappear so the whole list never swarms.\n //\n // The selected row is the exception: it skips the travel and appears at\n // its final slot immediately, so the selection wash is never sitting on\n // empty space waiting for its row to fly in.\n <motion.div\n layout=\"position\"\n layoutId={typeof value === \"string\" ? value : undefined}\n initial={false}\n transition={isSelected ? { duration: 0 } : ROW_MOVE_SPRING}\n >\n {row}\n </motion.div>\n );\n}\n\nfunction Separator({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Separator>) {\n return (\n <CommandPrimitive.Separator\n className={cn(\n \"-mx-1 my-1 h-px bg-[var(--border-color-pho-secondary)]\",\n className,\n )}\n {...props}\n />\n );\n}\n\nfunction Loading({\n className,\n ...props\n}: ComponentProps<typeof CommandPrimitive.Loading>) {\n return (\n <CommandPrimitive.Loading\n className={cn(\"text-pho-description px-2.5 py-1.5 text-base\", className)}\n {...props}\n />\n );\n}\n\ntype DialogRootProps = ComponentProps<typeof PhoDialog.Root>;\n\ninterface CommandDialogProps extends ComponentProps<typeof CommandPrimitive> {\n /** Controlled dialog state — pass straight through to `Dialog.Root`. */\n open?: DialogRootProps[\"open\"];\n onOpenChange?: DialogRootProps[\"onOpenChange\"];\n /** Accessible name for the palette (dialog and command menu). */\n label?: string;\n /** Extra classes for the dialog panel (not the command root). */\n className?: string;\n}\n\n/**\n * A command palette in a modal — Pho's `Dialog` overlay (Base UI) around a\n * `Command.Root`, raised above center. We deliberately skip cmdk's own\n * `Command.Dialog` (Radix) so overlays stay on one primitive stack.\n *\n * List height springs via `AnimatedHeight` (same feel as the Card shell on\n * onboarding / invite) — the input row stays put while results resize.\n */\nfunction Dialog({\n open,\n onOpenChange,\n label,\n className,\n children,\n ...props\n}: CommandDialogProps) {\n return (\n <PhoDialog.Root open={open} onOpenChange={onOpenChange}>\n <PhoDialog.Portal>\n <PhoDialog.Backdrop />\n <PhoDialog.Popup\n aria-label={label}\n // Palette sits above center so the list grows downward from a\n // stable top edge instead of jumping around it.\n className={cn(\n \"top-[max(4rem,18vh)] max-w-xl translate-y-0 overflow-hidden p-0\",\n className,\n )}\n >\n {/* The popup is position: fixed; layout animations inside a fixed\n element need a layoutRoot to project against, or their\n measurements drift with the page scroll. */}\n <motion.div layoutRoot>\n <Root label={label} {...props}>\n {children}\n </Root>\n </motion.div>\n </PhoDialog.Popup>\n </PhoDialog.Portal>\n </PhoDialog.Root>\n );\n}\n\n/**\n * Command menu built on `cmdk` — a filterable list of actions driven from a\n * single input, keyboard-first. Compose inline (`Command.Root`) or as a\n * ⌘K-style modal palette (`Command.Dialog`, which owns the overlay).\n * Filtering is yours by default — filter in render so the rows' diff can\n * glide; pass `shouldFilter` to hand matching and ranking to cmdk (its\n * imperative reorder skips the animation).\n *\n * Rows share one layout via `Command.Item` `level` — idle\n * `item` → `subitem` → `subsubitem`, or flat `result` while searching.\n */\nexport const Command = {\n Root,\n InputGroup,\n Input,\n List,\n Empty,\n Group,\n Item,\n ItemIcon,\n ItemTitle,\n Separator,\n Loading,\n Dialog,\n};\n\n/** Re-export of cmdk's state selector hook (search, value, filtered counts). */\nexport { useCommandState };\n"],"mappings":";;;;;;;;;;;AAsBA,IAAM,IAAkB;AAExB,SAAS,EAAK,EAMZ,cAAA,IAAe,IACf,WAAA,GACA,UAAA,GACA,GAAG,EAAA,GACuC;AAG1C,QAAM,IAAkB,E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F;AAAA,MAKA,UAAA,gBAAA,EAAC,EAAO,KAAR;AAAA,QAAY,YAAA;AAAA,QACV,UAAA,gBAAA,EAAC,GAAD;AAAA,UAAa,OAAA;AAAA,UAAO,GAAI;AAAA,UACrB,UAAA;AAAA,QACG,CAAA;AAAA,MACI,CAAA;AAAA,IACG,CAAA,CACD,EAAA,CAAA;AAAA,EACJ,CAAA;AAEpB;AAaA,IAAa,KAAU;AAAA,EACrB,MAAA;AAAA,EACA,YAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,UAAA;AAAA,EACA,WAAA;AAAA,EACA,WAAA;AAAA,EACA,SAAA;AAAA,EACA,QAAA;AACF"}
@@ -0,0 +1,11 @@
1
+ "use client";
2
+ import { a as e, i as t, n as s, o, r, s as c, t as l } from "../chunks/data-table-DwbPU0zt.js";
3
+ export {
4
+ l as DATA_TABLE_SURFACE,
5
+ s as DataTable,
6
+ r as GhostSearch,
7
+ t as TableHostContext,
8
+ e as TableSearchContext,
9
+ o as createColumns,
10
+ c as createTableSearchStore
11
+ };
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { n as i, t as o } from "../chunks/dialog-8SRNi_rv.js";
2
+ import { n as i, t as o } from "../chunks/dialog-BxKACOj5.js";
3
3
  export {
4
4
  o as Dialog,
5
5
  i as useDialogPending
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { a, c as s, i as t, l as e, n as o, o as i, r as E, s as p, t as l } from "../chunks/error-Crs-wqMC.js";
2
+ import { a, c as s, i as t, l as e, n as o, o as i, r as E, s as p, t as l } from "../chunks/error-D0yoFxCv.js";
3
3
  export {
4
4
  l as Error,
5
5
  o as ErrorView,