@photon-ai/pho-ui 2.15.0 → 2.16.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.
@@ -1,54 +1,54 @@
1
1
  "use client";
2
2
  import { t as p } from "./cn-ChIgwEl3.js";
3
- import { n as De } from "./link-provider-DXzDQ08N.js";
4
- import { FADE_ENTRANCE as it, FADE_SWAP as st, SPRING_ENTRANCE as lt, TRAVEL_LINEAR as ot, fadeThroughBlur as ee } from "../motion.js";
5
- import { a as ie, o as pe } from "./button-CdqS_t5a.js";
6
- import { t as ct } from "./error-D0yoFxCv.js";
7
- import { t as ae } from "./IconChevronLeft-CSWMKQ4C.js";
8
- import { t as ut } from "./IconChevronRight-CzoJnYNI.js";
9
- import { a as fe, i as dt, n as pt, r as ft, s as mt } from "./data-table-CHLJfGkS.js";
10
- import { t as Ee } from "./IconSearch-BKAHkLyX.js";
11
- import { t as ht } from "./IconX-pZ9vrtSr.js";
12
- import { t as gt } from "./toast-iSf6NuAS.js";
13
- import { t as le } from "./input-group-fc9_jD4d.js";
14
- import { t as bt } from "./animated-height-CCO-Ocoz.js";
15
- import { n as He, t as Q } from "./scroll-area-BO-9PMM7.js";
16
- import { i as yt } from "./checkbox-CLPmblNA.js";
17
- import { t as vt } from "./form-AiHbbw4m.js";
3
+ import { n as He } from "./link-provider-DXzDQ08N.js";
4
+ import { FADE_ENTRANCE as st, FADE_SWAP as lt, SPRING_ENTRANCE as ot, TRAVEL_LINEAR as ct, fadeThroughBlur as Z } from "../motion.js";
5
+ import { a as ie, o as me } from "./button-CdqS_t5a.js";
6
+ import { t as ut } from "./error-D0yoFxCv.js";
7
+ import { t as te } from "./IconChevronLeft-CSWMKQ4C.js";
8
+ import { t as dt } from "./IconChevronRight-CzoJnYNI.js";
9
+ import { a as he, i as pt, n as ft, r as mt, s as ht } from "./data-table-CHLJfGkS.js";
10
+ import { t as Se } from "./IconSearch-BKAHkLyX.js";
11
+ import { t as gt } from "./IconX-pZ9vrtSr.js";
12
+ import { t as bt } from "./toast-iSf6NuAS.js";
13
+ import { t as oe } from "./input-group-fc9_jD4d.js";
14
+ import { t as yt } from "./animated-height-CCO-Ocoz.js";
15
+ import { n as ge, t as U } from "./scroll-area-BO-9PMM7.js";
16
+ import { i as vt } from "./checkbox-CLPmblNA.js";
17
+ import { t as xt } from "./form-AiHbbw4m.js";
18
18
  import { i as W } from "./menu-BQeprfxB.js";
19
- import { Children as Y, Fragment as xt, createContext as z, isValidElement as Fe, useCallback as Ge, useContext as T, useEffect as L, useId as wt, useLayoutEffect as V, useMemo as $, useRef as _, useState as x, useSyncExternalStore as me } from "react";
20
- import { Fragment as he, jsx as t, jsxs as v } from "react/jsx-runtime";
21
- import { AnimatePresence as G, motion as N, useIsPresent as Nt, useReducedMotion as B } from "motion/react";
22
- import { Dialog as te } from "@base-ui/react/dialog";
23
- import { createPortal as Ce } from "react-dom";
24
- var ge = "rounded-base border border-pho-secondary bg-pho-primary", ne = "divide-y divide-pho-secondary [&>:has(+[data-basic-page-alert])]:border-b-0", ze = `${ge} ${ne}`, Se = "flex min-w-0 flex-col gap-3 rounded-base border border-pho-secondary bg-pho-page p-5", At = "flex min-h-[4.25rem] min-w-0 flex-col gap-3 px-5 py-4 sm:flex-row sm:items-center sm:justify-between sm:gap-6", _t = "flex flex-col gap-3 px-5 py-4", Et = "-mx-5 -mb-4 flex items-center rounded-b-[calc(0.75rem-1px)] bg-pho-secondary py-1 pr-3 pl-5", Ct = "-mx-2 -mt-1.5 flex items-center rounded-sm bg-pho-secondary px-2 py-0.5", P = lt, M = it, q = 12, St = 768;
25
- function kt(e) {
19
+ import { Children as J, Fragment as wt, createContext as H, isValidElement as Fe, useCallback as Ge, useContext as k, useEffect as O, useId as Nt, useLayoutEffect as V, useMemo as q, useRef as _, useState as N, useSyncExternalStore as be } from "react";
20
+ import { Fragment as ye, jsx as t, jsxs as y } from "react/jsx-runtime";
21
+ import { AnimatePresence as z, motion as A, useIsPresent as At, useReducedMotion as L } from "motion/react";
22
+ import { Dialog as ee } from "@base-ui/react/dialog";
23
+ import { createPortal as ke } from "react-dom";
24
+ var ve = "rounded-base border border-pho-secondary bg-pho-primary", ae = "divide-y divide-pho-secondary [&>:has(+[data-basic-page-alert])]:border-b-0", ze = `${ve} ${ae}`, Te = "flex min-w-0 flex-col gap-3 rounded-base border border-pho-secondary bg-pho-page p-5", _t = "flex min-h-[4.25rem] min-w-0 flex-col gap-3 px-5 py-4 sm:flex-row sm:items-center sm:justify-between sm:gap-6", Et = "flex flex-col gap-3 px-5 py-4", Ct = "-mx-5 -mb-4 flex items-center rounded-b-[calc(0.75rem-1px)] bg-pho-secondary py-1 pr-3 pl-5", St = "-mx-2 -mt-1.5 flex items-center rounded-sm bg-pho-secondary px-2 py-0.5", P = ot, B = st, j = 12, Ve = H(null), kt = 768;
25
+ function Tt(e) {
26
26
  return Math.round(Math.min(Math.max(e * 0.4, 320), 448));
27
27
  }
28
- var Ve = z(null), $e = z(null);
29
- function Tt(e) {
30
- const [a, n] = x(null), [r, s] = x(!1), [l, o] = x(!1), [c, i] = x(() => ({
28
+ var $e = H(null), qe = H(null);
29
+ function Rt(e) {
30
+ const [a, n] = N(null), [r, s] = N(!1), [l, o] = N(!1), [c, i] = N(() => ({
31
31
  width: typeof window > "u" ? 0 : window.innerWidth,
32
32
  height: null
33
33
  }));
34
34
  return V(() => {
35
35
  const d = e.current;
36
36
  if (!r || d == null) return;
37
- const f = we(d), u = () => {
38
- const h = d.offsetWidth, b = f?.clientHeight ?? null;
37
+ const m = Ae(d), u = () => {
38
+ const h = d.offsetWidth, b = m?.clientHeight ?? null;
39
39
  i((g) => g.width === h && g.height === b ? g : {
40
40
  width: h,
41
41
  height: b
42
42
  });
43
43
  };
44
44
  if (u(), typeof ResizeObserver > "u") return;
45
- const m = new ResizeObserver(u);
46
- return m.observe(d), f != null && m.observe(f), () => m.disconnect();
45
+ const f = new ResizeObserver(u);
46
+ return f.observe(d), m != null && f.observe(m), () => f.disconnect();
47
47
  }, [e, r]), {
48
- host: $(() => ({
48
+ host: q(() => ({
49
49
  slot: a,
50
- presentation: c.width >= St ? "panel" : "page",
51
- width: kt(c.width),
50
+ presentation: c.width >= kt ? "panel" : "page",
51
+ width: Tt(c.width),
52
52
  paneHeight: c.height,
53
53
  setOpen: o,
54
54
  setPresent: s
@@ -57,73 +57,90 @@ function Tt(e) {
57
57
  open: l
58
58
  };
59
59
  }
60
- function Rt(e) {
60
+ function Pt(e) {
61
61
  return e == null ? window.scrollY : e.scrollTop;
62
62
  }
63
- function ke(e, a) {
63
+ function Re(e, a) {
64
64
  e == null ? window.scrollTo({ top: a }) : e.scrollTop = a;
65
65
  }
66
- function Pt({ condense: e = !0, width: a, className: n, children: r, ref: s, ...l }) {
67
- const o = T(se)?.adopt ?? !1, c = T($e), [i, d] = x(!1), f = _(0), u = Ge((H) => {
68
- f.current += H ? 1 : -1, d(f.current > 0);
69
- }, []), m = a === "wide" || a == null && i, [h] = x(mt), b = _(null), [g, E] = x(null), [y, C] = x(null), w = $(() => ({
70
- setTitle: E,
71
- setTail: C
66
+ function It({ condense: e = !0, width: a, prerendered: n = !1, className: r, children: s, ref: l, ...o }) {
67
+ const c = k(se)?.adopt ?? !1, i = k(qe), [d, m] = N(!1), u = _(0), f = Ge((w) => {
68
+ u.current += w ? 1 : -1, m(u.current > 0);
69
+ }, []), h = a === "wide" || a == null && d, [b] = N(ht), g = _(null), E = q(() => ({
70
+ ref: g,
71
+ prerendered: n
72
+ }), [n]), [v, C] = N(null), [x, R] = N(null), I = q(() => ({
73
+ setTitle: C,
74
+ setTail: R
72
75
  }), []);
73
- L(() => {
74
- if (c != null)
75
- return c.setBack(y), () => c.setBack(null);
76
- }, [c, y]);
77
- const { host: S, setSlot: O, open: R } = Tt(b), I = R && S.presentation === "page", D = _(!1), j = _(0);
76
+ O(() => {
77
+ if (i != null)
78
+ return i.setBack(x), () => i.setBack(null);
79
+ }, [i, x]);
80
+ const { host: T, setSlot: M, open: F } = Rt(g), D = F && T.presentation === "page", Q = _(!1), Y = _(0);
78
81
  V(() => {
79
- const H = b.current;
80
- if (I === D.current || H == null) return;
81
- D.current = I;
82
- const A = we(H);
83
- I ? (j.current = Rt(A), ke(A, 0)) : ke(A, j.current);
84
- }, [I]);
85
- const U = e ? /* @__PURE__ */ t(It, {
86
- title: g,
87
- tail: c == null ? y : null,
88
- silent: I || c != null
89
- }) : null, J = /* @__PURE__ */ t("div", {
82
+ const w = g.current;
83
+ if (D === Q.current || w == null) return;
84
+ Q.current = D;
85
+ const $ = Ae(w);
86
+ D ? (Y.current = Pt($), Re($, 0)) : Re($, Y.current);
87
+ }, [D]);
88
+ const le = e ? /* @__PURE__ */ t(Ot, {
89
+ title: v,
90
+ tail: i == null ? x : null,
91
+ silent: D || i != null
92
+ }) : null, S = /* @__PURE__ */ t("div", {
90
93
  "data-basic-page-column": "",
91
- className: p("mx-auto flex w-full min-w-0 flex-1 flex-col px-5 pt-12 pb-12 *:min-w-0", m ? "max-w-[84rem] md:px-8" : "max-w-[44.5rem]", o || c != null ? "[&_[data-basic-page-back]]:hidden" : "has-[[data-basic-page-back]]:pt-16"),
92
- children: e ? /* @__PURE__ */ t(ye.Provider, {
93
- value: w,
94
- children: r
95
- }) : r
94
+ className: p("mx-auto flex w-full min-w-0 flex-1 flex-col px-5 pt-12 pb-12 *:min-w-0", h ? "max-w-[84rem] md:px-8" : "max-w-[44.5rem]", c || i != null ? "[&_[data-basic-page-back]]:hidden" : "has-[[data-basic-page-back]]:pt-16"),
95
+ children: e ? /* @__PURE__ */ t(we.Provider, {
96
+ value: I,
97
+ children: s
98
+ }) : s
96
99
  });
97
100
  return /* @__PURE__ */ t("div", {
98
101
  "data-basic-page-root": "",
99
- "data-basic-page-width": m ? "wide" : void 0,
100
- className: p("relative flex min-h-full w-full min-w-0 flex-row", n),
101
- ...l,
102
- ref: (H) => {
103
- b.current = H, typeof s == "function" ? s(H) : s != null && (s.current = H);
102
+ "data-basic-page-width": h ? "wide" : void 0,
103
+ "data-basic-page-prerendered": n ? "" : void 0,
104
+ className: p("relative flex min-h-full w-full min-w-0 flex-row", r),
105
+ ...o,
106
+ ref: (w) => {
107
+ g.current = w, typeof l == "function" ? l(w) : l != null && (l.current = w);
104
108
  },
105
109
  children: /* @__PURE__ */ t(Ve.Provider, {
106
- value: S,
107
- children: /* @__PURE__ */ t(dt.Provider, {
108
- value: u,
109
- children: /* @__PURE__ */ v(fe.Provider, {
110
- value: h,
111
- children: [/* @__PURE__ */ v("div", {
112
- "data-basic-page-main": "",
113
- className: p("flex min-w-0 flex-1 flex-col", I && "hidden"),
114
- children: [U, J]
115
- }), /* @__PURE__ */ t("div", {
116
- ref: O,
117
- className: "contents"
118
- })]
110
+ value: E,
111
+ children: /* @__PURE__ */ t($e.Provider, {
112
+ value: T,
113
+ children: /* @__PURE__ */ t(pt.Provider, {
114
+ value: f,
115
+ children: /* @__PURE__ */ y(he.Provider, {
116
+ value: b,
117
+ children: [/* @__PURE__ */ y("div", {
118
+ "data-basic-page-main": "",
119
+ className: p("flex min-w-0 flex-1 flex-col", D && "hidden"),
120
+ children: [le, S]
121
+ }), /* @__PURE__ */ t("div", {
122
+ ref: M,
123
+ className: "contents"
124
+ })]
125
+ })
119
126
  })
120
127
  })
121
128
  })
122
129
  });
123
130
  }
124
- function It({ title: e, tail: a, silent: n = !1 }) {
125
- const r = B(), [s, l] = x(!1), o = T(se), c = wt();
126
- L(() => {
131
+ var ce = /* @__PURE__ */ new Set();
132
+ function Ot({ title: e, tail: a, silent: n = !1 }) {
133
+ const r = L(), [s, l] = N(() => !n && ce.size > 0), o = k(se), c = Nt();
134
+ V(() => {
135
+ if (!(!s || n))
136
+ return ce.add(c), () => {
137
+ ce.delete(c);
138
+ };
139
+ }, [
140
+ c,
141
+ s,
142
+ n
143
+ ]), O(() => {
127
144
  if (o != null) {
128
145
  if (n) {
129
146
  o.store.clear(c);
@@ -142,87 +159,103 @@ function It({ title: e, tail: a, silent: n = !1 }) {
142
159
  e,
143
160
  a,
144
161
  n
145
- ]), L(() => {
162
+ ]), O(() => {
146
163
  if (o != null)
147
164
  return () => o.store.clear(c);
148
165
  }, [o, c]);
149
166
  const i = e?.el ?? null;
150
- return L(() => {
151
- if (i == null || typeof IntersectionObserver > "u") return;
152
- const d = new IntersectionObserver(([f]) => l(f != null && !f.isIntersecting), { root: we(i) });
153
- return d.observe(i), () => d.disconnect();
154
- }, [i]), /* @__PURE__ */ t("div", {
167
+ O(() => {
168
+ if (i == null || typeof IntersectionObserver > "u") {
169
+ if (typeof requestAnimationFrame > "u") return;
170
+ const f = requestAnimationFrame(() => l(!1));
171
+ return () => cancelAnimationFrame(f);
172
+ }
173
+ const u = new IntersectionObserver(([f]) => l(f != null && !f.isIntersecting), { root: Ae(i) });
174
+ return u.observe(i), () => u.disconnect();
175
+ }, [i]);
176
+ const d = r ? 0 : -jt, m = r ? "blur(0px)" : `blur(${ge}px)`;
177
+ return /* @__PURE__ */ t("div", {
155
178
  "data-basic-page-condense": "",
156
179
  className: "sticky top-0 z-20 h-0 overflow-visible",
157
- children: /* @__PURE__ */ t(G, { children: s && !(o?.adopt ?? !1) && /* @__PURE__ */ v(N.div, {
158
- initial: {
159
- opacity: 0,
160
- y: r ? 0 : Ie
161
- },
162
- animate: {
163
- opacity: 1,
164
- y: 0
165
- },
166
- exit: {
167
- opacity: 0,
168
- y: r ? 0 : Ie
169
- },
170
- transition: {
171
- ...xe,
172
- y: $t
173
- },
174
- className: "border-pho-secondary bg-pho-page/85 relative grid h-12 grid-cols-[1fr_minmax(0,auto)_1fr] items-center border-b px-3 backdrop-blur",
175
- children: [/* @__PURE__ */ t("div", {
176
- className: "flex min-w-0 items-center justify-start",
177
- children: a != null && /* @__PURE__ */ t(pe, {
178
- variant: "ghost",
179
- size: "sm",
180
- href: a.href,
181
- onClick: a.onClick,
182
- prefix: /* @__PURE__ */ t("span", {
183
- className: "inline-flex [&>svg]:size-[1.125em] [&>svg]:shrink-0",
184
- children: /* @__PURE__ */ t(ae, {})
185
- }),
186
- className: "min-w-max",
187
- children: a.label
188
- })
189
- }), /* @__PURE__ */ t("span", {
190
- className: "text-pho-primary block max-w-full min-w-0 truncate text-center text-base font-medium",
191
- children: e?.label
192
- })]
193
- }) })
180
+ children: /* @__PURE__ */ t(z, {
181
+ initial: !1,
182
+ children: s && !(o?.adopt ?? !1) && /* @__PURE__ */ y(A.div, {
183
+ initial: { opacity: 0 },
184
+ animate: { opacity: 1 },
185
+ exit: { opacity: 0 },
186
+ transition: ne,
187
+ className: "border-pho-secondary bg-pho-page/85 relative grid h-12 grid-cols-[1fr_minmax(0,auto)_1fr] items-center border-b px-3 backdrop-blur",
188
+ children: [/* @__PURE__ */ t("div", {
189
+ className: "flex min-w-0 items-center justify-start",
190
+ children: a != null && /* @__PURE__ */ t(me, {
191
+ variant: "ghost",
192
+ size: "sm",
193
+ href: a.href,
194
+ onClick: a.onClick,
195
+ prefix: /* @__PURE__ */ t("span", {
196
+ className: "inline-flex [&>svg]:size-[1.125em] [&>svg]:shrink-0",
197
+ children: /* @__PURE__ */ t(te, {})
198
+ }),
199
+ className: "min-w-max",
200
+ children: a.label
201
+ })
202
+ }), /* @__PURE__ */ t(A.span, {
203
+ initial: {
204
+ opacity: 0,
205
+ y: d,
206
+ filter: m
207
+ },
208
+ animate: {
209
+ opacity: 1,
210
+ y: 0,
211
+ filter: "blur(0px)"
212
+ },
213
+ exit: {
214
+ opacity: 0,
215
+ y: d,
216
+ filter: m
217
+ },
218
+ transition: {
219
+ ...ne,
220
+ y: qt
221
+ },
222
+ className: "text-pho-primary block max-w-full min-w-0 truncate text-center text-base font-medium",
223
+ children: e?.label
224
+ })]
225
+ })
226
+ })
194
227
  });
195
228
  }
196
- function Ot(e) {
229
+ function Lt(e) {
197
230
  return e.normalize("NFKD").replace(/[\u0300-\u036f]/g, "").toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "");
198
231
  }
199
- function Lt(e) {
232
+ function Bt(e) {
200
233
  if (!(typeof e != "string" && typeof e != "number"))
201
- return Ot(String(e)) || void 0;
234
+ return Lt(String(e)) || void 0;
202
235
  }
203
- function be(e, a) {
236
+ function xe(e, a) {
204
237
  if (e !== "")
205
- return e ?? Lt(a);
238
+ return e ?? Bt(a);
206
239
  }
207
- var Bt = (e) => `basic-page-morph-${e}`, Mt = { layout: P }, Te = 10, Re = {
240
+ var Mt = (e) => `basic-page-morph-${e}`, Dt = { layout: P }, Pe = 10, Ie = {
208
241
  delay: 0.2,
209
242
  duration: 0.12,
210
243
  ease: "easeOut"
211
- }, Dt = {
244
+ }, Ht = {
212
245
  duration: 0.18,
213
246
  ease: "easeOut"
214
- }, Ht = -8, Ft = {
247
+ }, Ft = -8, Gt = {
215
248
  duration: 0.16,
216
249
  ease: "easeOut"
217
- }, Gt = {
250
+ }, zt = {
218
251
  delay: 0.14,
219
252
  duration: 0.16,
220
253
  ease: "easeOut"
221
- }, qe = {
254
+ }, je = {
222
255
  duration: 0.12,
223
256
  ease: "easeOut"
224
257
  }, K = [];
225
- function zt(e) {
258
+ function Vt(e) {
226
259
  const a = _({ labels: e });
227
260
  a.current.labels = e, V(() => {
228
261
  const n = a.current;
@@ -231,22 +264,22 @@ function zt(e) {
231
264
  };
232
265
  }, []);
233
266
  }
234
- function je() {
235
- const [e] = x(() => {
267
+ function We() {
268
+ const [e] = N(() => {
236
269
  const a = K[K.length - 1];
237
270
  return a ? { labels: [...a.labels] } : null;
238
271
  });
239
272
  return e;
240
273
  }
241
- var ye = z(null), ue = {
274
+ var we = H(null), pe = {
242
275
  condensed: !1,
243
276
  title: null,
244
277
  back: null
245
- }, se = z(null), ve = () => () => {
246
- }, Pe = () => ue;
247
- function Vt({ adopt: e = !0, children: a }) {
248
- const [n] = x(() => {
249
- let s = ue, l = null;
278
+ }, se = H(null), Ne = () => () => {
279
+ }, Oe = () => pe;
280
+ function $t({ adopt: e = !0, children: a }) {
281
+ const [n] = N(() => {
282
+ let s = pe, l = null;
250
283
  const o = /* @__PURE__ */ new Set(), c = () => {
251
284
  for (const i of o) i();
252
285
  };
@@ -256,13 +289,13 @@ function Vt({ adopt: e = !0, children: a }) {
256
289
  l = i, s = d, c();
257
290
  },
258
291
  clear(i) {
259
- l === i && (l = null, s = ue, c());
292
+ l === i && (l = null, s = pe, c());
260
293
  },
261
294
  subscribe(i) {
262
295
  return o.add(i), () => o.delete(i);
263
296
  }
264
297
  };
265
- }), r = $(() => ({
298
+ }), r = q(() => ({
266
299
  store: n,
267
300
  adopt: e
268
301
  }), [n, e]);
@@ -271,12 +304,12 @@ function Vt({ adopt: e = !0, children: a }) {
271
304
  children: a
272
305
  });
273
306
  }
274
- function fn() {
275
- const e = T(se);
276
- return me(e?.store.subscribe ?? ve, e?.store.get ?? Pe, e?.store.get ?? Pe);
307
+ function hn() {
308
+ const e = k(se);
309
+ return be(e?.store.subscribe ?? Ne, e?.store.get ?? Oe, e?.store.get ?? Oe);
277
310
  }
278
- var xe = st, $t = ot, Ie = -8;
279
- function we(e) {
311
+ var ne = lt, qt = ct, jt = -8;
312
+ function Ae(e) {
280
313
  if (typeof getComputedStyle != "function") return null;
281
314
  for (let a = e.parentElement; a != null && a !== document.body; a = a.parentElement) {
282
315
  const { overflowY: n } = getComputedStyle(a);
@@ -284,45 +317,45 @@ function we(e) {
284
317
  }
285
318
  return null;
286
319
  }
287
- var oe = /* @__PURE__ */ new Map(), qt = 96;
288
- function jt(e) {
320
+ var ue = /* @__PURE__ */ new Map(), Wt = 96;
321
+ function Kt(e) {
289
322
  const a = e.closest("[data-basic-page-root]"), n = a?.querySelector("[data-basic-page-column]");
290
323
  return !a || !n ? 0 : n.getBoundingClientRect().left - a.getBoundingClientRect().left;
291
324
  }
292
- function We(e) {
293
- const [a] = x(() => {
325
+ function Ke(e) {
326
+ const [a] = N(() => {
294
327
  if (e == null) return !1;
295
- const r = oe.get(e);
296
- return r != null && r.visible && r.el.isConnected && jt(r.el) <= qt;
328
+ const r = ue.get(e);
329
+ return r != null && r.visible && r.el.isConnected && Kt(r.el) <= Wt;
297
330
  }), n = _(null);
298
- return L(() => {
331
+ return O(() => {
299
332
  if (e == null || typeof IntersectionObserver > "u") return;
300
333
  const r = n.current;
301
334
  if (!r) return;
302
335
  const s = new IntersectionObserver(([l]) => {
303
- l && oe.set(e, {
336
+ l && ue.set(e, {
304
337
  visible: l.isIntersecting,
305
338
  el: r
306
339
  });
307
340
  });
308
341
  return s.observe(r), () => {
309
- s.disconnect(), oe.delete(e);
342
+ s.disconnect(), ue.delete(e);
310
343
  };
311
344
  }, [e]), {
312
345
  fly: a,
313
346
  ref: n
314
347
  };
315
348
  }
316
- var Wt = {
349
+ var Xt = {
317
350
  fade: {
318
351
  initial: { opacity: 0 },
319
352
  animate: { opacity: 1 },
320
- transition: { opacity: M }
353
+ transition: { opacity: B }
321
354
  },
322
355
  rise: {
323
356
  initial: {
324
357
  opacity: 0,
325
- y: q
358
+ y: j
326
359
  },
327
360
  animate: {
328
361
  opacity: 1,
@@ -330,23 +363,23 @@ var Wt = {
330
363
  },
331
364
  transition: {
332
365
  y: P,
333
- opacity: M
366
+ opacity: B
334
367
  }
335
368
  },
336
369
  slide: {
337
370
  initial: { x: "-100%" },
338
371
  animate: { x: 0 },
339
- transition: { x: Gt }
372
+ transition: { x: zt }
340
373
  }
341
374
  };
342
- function Ke({ morphId: e, fromClassName: a, fly: n, morphRef: r, arrival: s, className: l, children: o }) {
343
- const [c, i] = x(!1), d = !n && s != null ? Wt[s] : null;
344
- return /* @__PURE__ */ v(N.span, {
375
+ function Xe({ morphId: e, fromClassName: a, fly: n, morphRef: r, arrival: s, className: l, children: o }) {
376
+ const [c, i] = N(!1), d = !n && s != null ? Xt[s] : null;
377
+ return /* @__PURE__ */ y(A.span, {
345
378
  ref: r,
346
- layoutId: Bt(e),
379
+ layoutId: Mt(e),
347
380
  initial: d?.initial,
348
381
  animate: d?.animate,
349
- transition: n ? Mt : {
382
+ transition: n ? Dt : {
350
383
  layout: { duration: 0 },
351
384
  ...d?.transition
352
385
  },
@@ -355,20 +388,20 @@ function Ke({ morphId: e, fromClassName: a, fly: n, morphRef: r, arrival: s, cla
355
388
  },
356
389
  onLayoutAnimationComplete: () => i(!1),
357
390
  className: p("relative inline-block", l),
358
- children: [o, c && /* @__PURE__ */ t(N.span, {
391
+ children: [o, c && /* @__PURE__ */ t(A.span, {
359
392
  "aria-hidden": !0,
360
393
  initial: { opacity: 1 },
361
394
  animate: { opacity: 0 },
362
- transition: Dt,
395
+ transition: Ht,
363
396
  onAnimationComplete: () => i(!1),
364
397
  className: p("absolute inset-0", a),
365
398
  children: o
366
399
  })]
367
400
  });
368
401
  }
369
- var Oe = "max-w-full min-w-0 truncate align-top";
370
- function Kt({ id: e, morphId: a, enter: n, trailing: r, className: s, children: l, ...o }) {
371
- const c = be(e, l), i = B(), d = Ae(n === !0), f = We(a), u = je(), m = !i && (a != null || d === !0), h = d || u != null ? "rise" : void 0, b = T(ye), g = _(null);
402
+ var Le = "max-w-full min-w-0 truncate align-top";
403
+ function Qt({ id: e, morphId: a, enter: n, trailing: r, className: s, children: l, ...o }) {
404
+ const c = xe(e, l), i = L(), d = Ee(n === !0), m = Ke(a), u = We(), f = !i && (a != null || d === !0), h = d || u != null ? "rise" : void 0, b = k(we), g = _(null);
372
405
  V(() => {
373
406
  if (b != null)
374
407
  return b.setTitle({
@@ -376,22 +409,22 @@ function Kt({ id: e, morphId: a, enter: n, trailing: r, className: s, children:
376
409
  el: g.current
377
410
  }), () => b.setTitle(null);
378
411
  }, [b, l]);
379
- const [E, y] = x(f.fly && u != null);
412
+ const [E, v] = N(m.fly && u != null);
380
413
  V(() => {
381
- K.length > 0 && y(!1);
414
+ K.length > 0 && v(!1);
382
415
  }, []);
383
- const C = r != null && r !== !1, w = !i && (a != null ? f.fly || h != null : d === !0), S = a != null && !i ? /* @__PURE__ */ t(Ke, {
416
+ const C = r != null && r !== !1, x = !i && (a != null ? m.fly || h != null : d === !0), R = a != null && !i ? /* @__PURE__ */ t(Xe, {
384
417
  morphId: a,
385
418
  fromClassName: "text-pho-secondary",
386
- fly: f.fly,
387
- morphRef: f.ref,
419
+ fly: m.fly,
420
+ morphRef: m.ref,
388
421
  arrival: h,
389
- className: Oe,
422
+ className: Le,
390
423
  children: l
391
- }) : d && !i ? /* @__PURE__ */ t(N.span, {
424
+ }) : d && !i ? /* @__PURE__ */ t(A.span, {
392
425
  initial: {
393
426
  opacity: 0,
394
- y: q
427
+ y: j
395
428
  },
396
429
  animate: {
397
430
  opacity: 1,
@@ -399,31 +432,31 @@ function Kt({ id: e, morphId: a, enter: n, trailing: r, className: s, children:
399
432
  },
400
433
  transition: {
401
434
  y: P,
402
- opacity: M
435
+ opacity: B
403
436
  },
404
- className: p("inline-block", Oe),
437
+ className: p("inline-block", Le),
405
438
  children: l
406
439
  }) : C ? /* @__PURE__ */ t("span", {
407
440
  className: "min-w-0 truncate",
408
441
  children: l
409
442
  }) : l;
410
- return /* @__PURE__ */ v("h1", {
443
+ return /* @__PURE__ */ y("h1", {
411
444
  id: c,
412
445
  "data-basic-page-title": "",
413
- className: p("text-display-base text-pho-primary max-w-full min-w-0 scroll-mt-12 px-5 font-medium", m ? "whitespace-nowrap" : "truncate", s),
446
+ className: p("text-display-base text-pho-primary max-w-full min-w-0 scroll-mt-12 px-5 font-medium", f ? "whitespace-nowrap" : "truncate", s),
414
447
  ...o,
415
- ref: (O) => {
416
- g.current = O;
417
- const R = o.ref;
418
- typeof R == "function" ? R(O) : R != null && (R.current = O);
448
+ ref: (I) => {
449
+ g.current = I;
450
+ const T = o.ref;
451
+ typeof T == "function" ? T(I) : T != null && (T.current = I);
419
452
  },
420
- children: [C ? /* @__PURE__ */ v("span", {
453
+ children: [C ? /* @__PURE__ */ y("span", {
421
454
  className: "flex max-w-full min-w-0 items-center gap-2",
422
- children: [S, w ? /* @__PURE__ */ t(N.span, {
455
+ children: [R, x ? /* @__PURE__ */ t(A.span, {
423
456
  "data-basic-page-title-trailing": "",
424
457
  initial: {
425
458
  opacity: 0,
426
- y: q
459
+ y: j
427
460
  },
428
461
  animate: {
429
462
  opacity: 1,
@@ -431,7 +464,7 @@ function Kt({ id: e, morphId: a, enter: n, trailing: r, className: s, children:
431
464
  },
432
465
  transition: {
433
466
  y: P,
434
- opacity: M
467
+ opacity: B
435
468
  },
436
469
  className: "shrink-0",
437
470
  children: r
@@ -440,56 +473,56 @@ function Kt({ id: e, morphId: a, enter: n, trailing: r, className: s, children:
440
473
  className: "shrink-0",
441
474
  children: r
442
475
  })]
443
- }) : S, E && /* @__PURE__ */ t(N.span, {
476
+ }) : R, E && /* @__PURE__ */ t(A.span, {
444
477
  "aria-hidden": !0,
445
478
  initial: { opacity: 1 },
446
479
  animate: { opacity: 0 },
447
- transition: qe,
448
- onAnimationComplete: () => y(!1),
449
- className: p("text-pho-secondary pointer-events-none absolute inline-flex items-center", Ta),
450
- children: /* @__PURE__ */ t(ae, {})
480
+ transition: je,
481
+ onAnimationComplete: () => v(!1),
482
+ className: p("text-pho-secondary pointer-events-none absolute inline-flex items-center", Pa),
483
+ children: /* @__PURE__ */ t(te, {})
451
484
  })]
452
485
  });
453
486
  }
454
- var Xe = z(!1);
455
- function Xt() {
456
- const e = T(Xe), a = B(), [n] = x(() => e && !a);
487
+ var Qe = H(!1);
488
+ function Yt() {
489
+ const e = k(Qe), a = L(), [n] = N(() => e && !a);
457
490
  return n;
458
491
  }
459
- var Qt = {
492
+ var Ut = {
460
493
  height: 0,
461
494
  opacity: 0,
462
495
  paddingTop: 0,
463
496
  paddingBottom: 0,
464
497
  borderTopWidth: 0
465
- }, Yt = {
498
+ }, Jt = {
466
499
  y: P,
467
- opacity: M,
500
+ opacity: B,
468
501
  height: P,
469
502
  paddingTop: P,
470
503
  paddingBottom: P,
471
504
  borderTopWidth: P
472
505
  };
473
- function Ne() {
474
- const e = Xt(), a = Nt(), n = B();
506
+ function _e() {
507
+ const e = Yt(), a = At(), n = L();
475
508
  return {
476
509
  initial: e ? {
477
510
  opacity: 0,
478
- y: q
511
+ y: j
479
512
  } : !1,
480
513
  animate: {
481
514
  opacity: 1,
482
515
  y: 0
483
516
  },
484
- exit: Qt,
485
- transition: n ? { duration: 0 } : Yt,
517
+ exit: Ut,
518
+ transition: n ? { duration: 0 } : Jt,
486
519
  leaving: !a
487
520
  };
488
521
  }
489
- var Ut = typeof process < "u" && process.env.NODE_ENV !== "production";
490
- function Qe(e, a, n, r) {
491
- L(() => {
492
- if (!Ut || e.current == null || typeof getComputedStyle != "function") return;
522
+ var Zt = typeof process < "u" && process.env.NODE_ENV !== "production";
523
+ function Ye(e, a, n, r) {
524
+ O(() => {
525
+ if (!Zt || e.current == null || typeof getComputedStyle != "function") return;
493
526
  const s = (o) => {
494
527
  const c = getComputedStyle(o).rowGap;
495
528
  return c === "" || c === "normal" ? null : parseFloat(c);
@@ -503,27 +536,33 @@ function Qe(e, a, n, r) {
503
536
  }
504
537
  });
505
538
  }
506
- function Jt() {
507
- return typeof document > "u" ? !1 : Array.from(document.querySelectorAll("[data-basic-page-stack], [data-basic-page-title], [data-basic-page-header]")).some((e) => e.closest('[aria-busy="true"]') != null);
539
+ function ea(e) {
540
+ return Array.from(e.querySelectorAll("[data-basic-page-stack], [data-basic-page-title], [data-basic-page-header]")).some((a) => a.closest('[aria-busy="true"]') != null);
508
541
  }
509
- function Ae(e, a = !1) {
510
- const [n] = x(() => e && typeof document < "u" && (a || !Jt()));
511
- return n;
542
+ function Ee(e, a = !1) {
543
+ const n = k(Ve), [r] = N(() => {
544
+ if (typeof document > "u" || !e || n?.prerendered) return !1;
545
+ if (a) return !0;
546
+ if (document.querySelector("[data-basic-page-prerendered]") != null) return !1;
547
+ const s = n ? n.ref.current : document;
548
+ return s == null || !ea(s);
549
+ });
550
+ return r;
512
551
  }
513
- function Zt({ enter: e, className: a, children: n, ref: r, ...s }) {
514
- const l = B(), o = _(null);
515
- Qe(o, "Stack", 40, (m) => m.hasAttribute("data-basic-page-fields") ? 20 : 12);
516
- const c = Ae(e ?? !0, e === !0), i = s["aria-busy"], d = i === !0 || i === "true", f = _(d), u = f.current && !d;
517
- return L(() => {
518
- f.current = d;
519
- }), /* @__PURE__ */ t(N.div, {
520
- ref: (m) => {
521
- o.current = m, typeof r == "function" ? r(m) : r != null && (r.current = m);
552
+ function ta({ enter: e, className: a, children: n, ref: r, ...s }) {
553
+ const l = L(), o = _(null);
554
+ Ye(o, "Stack", 40, (f) => f.hasAttribute("data-basic-page-fields") ? 20 : 12);
555
+ const c = Ee(e ?? !0, e === !0), i = s["aria-busy"], d = i === !0 || i === "true", m = _(d), u = m.current && !d;
556
+ return O(() => {
557
+ m.current = d;
558
+ }), /* @__PURE__ */ t(A.div, {
559
+ ref: (f) => {
560
+ o.current = f, typeof r == "function" ? r(f) : r != null && (r.current = f);
522
561
  },
523
562
  "data-basic-page-stack": "",
524
563
  initial: l || !c ? !1 : {
525
564
  opacity: 0,
526
- y: q
565
+ y: j
527
566
  },
528
567
  animate: {
529
568
  opacity: 1,
@@ -531,23 +570,23 @@ function Zt({ enter: e, className: a, children: n, ref: r, ...s }) {
531
570
  },
532
571
  transition: {
533
572
  y: P,
534
- opacity: M
573
+ opacity: B
535
574
  },
536
575
  className: p("mt-7 flex min-w-0 flex-col gap-10", "[&:has(>*:first-child:not([data-basic-page-callout])>[data-basic-page-header]:first-child)]:mt-6 [&:has(>*:first-child:not([data-basic-page-callout])>h2:first-child)]:mt-6 [&:has(>[data-basic-page-header]:first-child)]:mt-6 [&:has(>h2:first-child)]:mt-6", "*:flex *:min-w-0 *:flex-col [&>*:not([data-basic-page-fields])]:gap-3", a),
537
576
  ...s,
538
- children: /* @__PURE__ */ t(Xe.Provider, {
577
+ children: /* @__PURE__ */ t(Qe.Provider, {
539
578
  value: u,
540
579
  children: n
541
580
  })
542
581
  });
543
582
  }
544
- var Le = "@container grid min-w-0 grid-cols-[minmax(0,1fr)_auto_auto] mb-3 [&>:not([data-basic-page-search]):not([data-basic-page-header-action])]:col-start-1 [&>:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])):nth-last-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action]))]:row-span-2 [&>:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])):nth-last-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action]))]:self-center [&>:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])):not(:nth-last-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])))]:self-end [&>:not([data-basic-page-search]):not([data-basic-page-header-action]):not(:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])))]:self-start [[data-basic-page-callout]_&]:mb-0 [[data-basic-page-stack]>*>&]:mb-0";
545
- function ea({ enter: e, className: a, ...n }) {
546
- const r = B();
547
- return Ae(e === !0) && !r ? /* @__PURE__ */ t(N.div, {
583
+ var Be = "@container grid min-w-0 grid-cols-[minmax(0,1fr)_auto_auto] mb-3 [&>:not([data-basic-page-search]):not([data-basic-page-header-action])]:col-start-1 [&>:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])):nth-last-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action]))]:row-span-2 [&>:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])):nth-last-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action]))]:self-center [&>:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])):not(:nth-last-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])))]:self-end [&>:not([data-basic-page-search]):not([data-basic-page-header-action]):not(:nth-child(1_of_:not([data-basic-page-search]):not([data-basic-page-header-action])))]:self-start [[data-basic-page-callout]_&]:mb-0 [[data-basic-page-stack]>*>&]:mb-0";
584
+ function aa({ enter: e, className: a, ...n }) {
585
+ const r = L();
586
+ return Ee(e === !0) && !r ? /* @__PURE__ */ t(A.div, {
548
587
  initial: {
549
588
  opacity: 0,
550
- y: q
589
+ y: j
551
590
  },
552
591
  animate: {
553
592
  opacity: 1,
@@ -555,26 +594,26 @@ function ea({ enter: e, className: a, ...n }) {
555
594
  },
556
595
  transition: {
557
596
  y: P,
558
- opacity: M
597
+ opacity: B
559
598
  },
560
599
  "data-basic-page-header": "",
561
- className: p(Le, a),
600
+ className: p(Be, a),
562
601
  ...n
563
602
  }) : /* @__PURE__ */ t("div", {
564
603
  "data-basic-page-header": "",
565
- className: p(Le, a),
604
+ className: p(Be, a),
566
605
  ...n
567
606
  });
568
607
  }
569
- function ta({ className: e, ...a }) {
608
+ function na({ className: e, ...a }) {
570
609
  return /* @__PURE__ */ t("div", {
571
610
  "data-basic-page-header-action": "",
572
611
  className: p("flex items-center gap-2", "[[data-basic-page-header]>&]:col-start-3 [[data-basic-page-header]>&]:row-span-2 [[data-basic-page-header]>&]:row-start-1 [[data-basic-page-header]>&]:ml-4 [[data-basic-page-header]>&]:self-start [[data-basic-page-header]>&]:justify-self-end", e),
573
612
  ...a
574
613
  });
575
614
  }
576
- function aa({ id: e, className: a, children: n, ...r }) {
577
- const s = be(e, n);
615
+ function ra({ id: e, className: a, children: n, ...r }) {
616
+ const s = xe(e, n);
578
617
  return /* @__PURE__ */ t("h2", {
579
618
  id: s,
580
619
  className: p("text-display-xs text-pho-primary max-w-full min-w-0 scroll-mt-12 truncate px-5 font-medium", "mb-3 [[data-basic-page-callout]_&]:mb-0 [[data-basic-page-header]>&]:mb-0 [[data-basic-page-stack]>*>&]:mb-0", a),
@@ -582,35 +621,35 @@ function aa({ id: e, className: a, children: n, ...r }) {
582
621
  children: n
583
622
  });
584
623
  }
585
- function Ye({ className: e, ...a }) {
624
+ function Ue({ className: e, ...a }) {
586
625
  return /* @__PURE__ */ t("p", {
587
626
  className: p("text-display-xs text-pho-description px-5 font-normal", e),
588
627
  ...a
589
628
  });
590
629
  }
591
- function na({ one: e, other: a, ...n }) {
592
- const r = T(fe), s = me(r?.subscribe ?? ve, () => r?.get().api ?? null, () => null);
630
+ function ia({ one: e, other: a, ...n }) {
631
+ const r = k(he), s = be(r?.subscribe ?? Ne, () => r?.get().api ?? null, () => null);
593
632
  if (s == null) return null;
594
633
  const l = s.query.trim() !== "" ? `${s.matched} of ${s.total}.` : `${s.total} ${s.total === 1 ? e : a}.`;
595
- return /* @__PURE__ */ t(Ye, {
634
+ return /* @__PURE__ */ t(Ue, {
596
635
  ...n,
597
636
  children: l
598
637
  });
599
638
  }
600
- function ra({ className: e, ...a }) {
639
+ function sa({ className: e, ...a }) {
601
640
  return /* @__PURE__ */ t("p", {
602
641
  className: p("text-pho-description px-5 text-xs font-normal", "mt-3 [[data-basic-page-callout]_&]:mt-0 [[data-basic-page-stack]>*>&]:mt-0", e),
603
642
  ...a
604
643
  });
605
644
  }
606
- function ia({ animateHeight: e, className: a, children: n, ...r }) {
607
- const s = /* @__PURE__ */ t(G, { children: Y.toArray(n) });
645
+ function la({ animateHeight: e, className: a, children: n, ...r }) {
646
+ const s = /* @__PURE__ */ t(z, { children: J.toArray(n) });
608
647
  return e ? /* @__PURE__ */ t("div", {
609
- className: p(ge, "min-h-0 overflow-hidden", a),
648
+ className: p(ve, "min-h-0 overflow-hidden", a),
610
649
  ...r,
611
- children: /* @__PURE__ */ t(bt, {
650
+ children: /* @__PURE__ */ t(yt, {
612
651
  transition: P,
613
- className: ne,
652
+ className: ae,
614
653
  children: s
615
654
  })
616
655
  }) : /* @__PURE__ */ t("div", {
@@ -619,33 +658,33 @@ function ia({ animateHeight: e, className: a, children: n, ...r }) {
619
658
  children: s
620
659
  });
621
660
  }
622
- function sa({ className: e, ...a }) {
623
- const { leaving: n, ...r } = Ne();
624
- return /* @__PURE__ */ t(N.div, {
661
+ function oa({ className: e, ...a }) {
662
+ const { leaving: n, ...r } = _e();
663
+ return /* @__PURE__ */ t(A.div, {
625
664
  ...r,
626
- className: p(_t, n && "overflow-hidden", e),
665
+ className: p(Et, n && "overflow-hidden", e),
627
666
  ...a
628
667
  });
629
668
  }
630
- function la({ divided: e = !1, className: a, ...n }) {
669
+ function ca({ divided: e = !1, className: a, ...n }) {
631
670
  return /* @__PURE__ */ t("div", {
632
- className: p(e ? Ct : Et, a),
671
+ className: p(e ? St : Ct, a),
633
672
  ...n
634
673
  });
635
674
  }
636
- function oa({ className: e, icon: a, children: n, ...r }) {
675
+ function ua({ className: e, icon: a, children: n, ...r }) {
637
676
  if (a == null || a === !1 || a === !0) return /* @__PURE__ */ t("div", {
638
677
  "data-basic-page-callout": "",
639
- className: p(Se, e),
678
+ className: p(Te, e),
640
679
  ...r,
641
680
  children: n
642
681
  });
643
- const [s, ...l] = Y.toArray(n);
644
- return /* @__PURE__ */ v("div", {
682
+ const [s, ...l] = J.toArray(n);
683
+ return /* @__PURE__ */ y("div", {
645
684
  "data-basic-page-callout": "",
646
- className: p(Se, e),
685
+ className: p(Te, e),
647
686
  ...r,
648
- children: [/* @__PURE__ */ v("div", {
687
+ children: [/* @__PURE__ */ y("div", {
649
688
  className: "relative",
650
689
  children: [/* @__PURE__ */ t("div", {
651
690
  className: "min-w-0 pr-16",
@@ -658,8 +697,8 @@ function oa({ className: e, icon: a, children: n, ...r }) {
658
697
  }), l]
659
698
  });
660
699
  }
661
- function ca({ id: e, className: a, children: n, ...r }) {
662
- const s = be(e, n);
700
+ function da({ id: e, className: a, children: n, ...r }) {
701
+ const s = xe(e, n);
663
702
  return /* @__PURE__ */ t("h2", {
664
703
  id: s,
665
704
  className: p("text-display-xs text-pho-primary max-w-full min-w-0 scroll-mt-12 truncate font-medium", a),
@@ -667,19 +706,19 @@ function ca({ id: e, className: a, children: n, ...r }) {
667
706
  children: n
668
707
  });
669
708
  }
670
- function ua({ className: e, ...a }) {
709
+ function pa({ className: e, ...a }) {
671
710
  return /* @__PURE__ */ t("p", {
672
711
  className: p("text-display-xs text-pho-description font-normal", e),
673
712
  ...a
674
713
  });
675
714
  }
676
- var Ue = z(null), Je = z(!1);
677
- function da({ className: e, children: a, ...n }) {
715
+ var Je = H(null), Ze = H(!1);
716
+ function fa({ className: e, children: a, ...n }) {
678
717
  let r = !1;
679
- const s = Y.toArray(a).map((l, o) => {
718
+ const s = J.toArray(a).map((l, o) => {
680
719
  if (!Fe(l)) return l;
681
720
  let c;
682
- return l.props.done ? c = "done" : r ? c = "upcoming" : (r = !0, c = l.props.working ? "working" : l.props.pending ? "pending" : "current"), /* @__PURE__ */ t(Ue.Provider, {
721
+ return l.props.done ? c = "done" : r ? c = "upcoming" : (r = !0, c = l.props.working ? "working" : l.props.pending ? "pending" : "current"), /* @__PURE__ */ t(Je.Provider, {
683
722
  value: {
684
723
  number: o + 1,
685
724
  state: c
@@ -694,56 +733,56 @@ function da({ className: e, children: a, ...n }) {
694
733
  children: s
695
734
  });
696
735
  }
697
- var pa = "relative grid size-5 shrink-0 place-items-center rounded-full border text-xs font-medium tabular-nums transition-[background-color,border-color,color] duration-200 ease-out *:[grid-area:1/1]", fa = {
736
+ var ma = "relative grid size-5 shrink-0 place-items-center rounded-full border text-xs font-medium tabular-nums transition-[background-color,border-color,color] duration-200 ease-out *:[grid-area:1/1]", ha = {
698
737
  done: "border-pho-ink text-pho-primary",
699
738
  current: "bg-pho-brand-solid text-pho-on-brand border-transparent",
700
739
  working: "border-transparent text-pho-primary",
701
740
  pending: "border-pho-ink text-pho-primary border-dashed",
702
741
  upcoming: "border-pho-primary text-pho-description"
703
- }, ma = "pointer-events-none absolute -inset-px rounded-full border border-pho-ink opacity-30", ha = "pointer-events-none absolute -inset-px rounded-full border border-pho-ink border-r-transparent border-b-transparent border-l-transparent animate-pho-spinner", ga = {
742
+ }, ga = "pointer-events-none absolute -inset-px rounded-full border border-pho-ink opacity-30", ba = "pointer-events-none absolute -inset-px rounded-full border border-pho-ink border-r-transparent border-b-transparent border-l-transparent animate-pho-spinner", ya = {
704
743
  done: "Done.",
705
744
  working: "In progress.",
706
745
  pending: "Waiting."
707
746
  };
708
- function ba({ icon: e, aside: a, title: n, description: r, done: s, working: l, pending: o, className: c, children: i, ...d }) {
709
- const f = T(Ue), u = f?.state ?? (s ? "done" : l ? "working" : o ? "pending" : "current"), m = B(), h = u === "current" || u === "working" || u === "pending", b = u === "upcoming", g = ga[u], E = i != null && i !== !1, y = e != null && e !== !1, C = a != null && a !== !1;
747
+ function va({ icon: e, aside: a, title: n, description: r, done: s, working: l, pending: o, className: c, children: i, ...d }) {
748
+ const m = k(Je), u = m?.state ?? (s ? "done" : l ? "working" : o ? "pending" : "current"), f = L(), h = u === "current" || u === "working" || u === "pending", b = u === "upcoming", g = ya[u], E = i != null && i !== !1, v = e != null && e !== !1, C = a != null && a !== !1;
710
749
  return /* @__PURE__ */ t("li", {
711
750
  "data-basic-page-step": u,
712
751
  "aria-current": h ? "step" : void 0,
713
752
  className: p("relative m-0 grid min-w-0 grid-cols-[auto_minmax(0,1fr)] grid-rows-[auto_minmax(0,1fr)] items-center gap-x-3 px-5 py-4", "transition-[background-color] duration-200 ease-out first:rounded-t-[calc(0.75rem-1px)] last:rounded-b-[calc(0.75rem-1px)] motion-reduce:transition-none", h && "bg-pho-page", c),
714
753
  ...d,
715
- children: /* @__PURE__ */ v(Je.Provider, {
754
+ children: /* @__PURE__ */ y(Ze.Provider, {
716
755
  value: !0,
717
756
  children: [
718
- /* @__PURE__ */ v("span", {
757
+ /* @__PURE__ */ y("span", {
719
758
  "aria-hidden": !0,
720
- className: p(pa, fa[u], "col-start-1 row-start-1"),
721
- children: [/* @__PURE__ */ t(G, {
759
+ className: p(ma, ha[u], "col-start-1 row-start-1"),
760
+ children: [/* @__PURE__ */ t(z, {
722
761
  initial: !1,
723
- children: u === "done" ? /* @__PURE__ */ t(N.span, {
724
- ...ee(m),
762
+ children: u === "done" ? /* @__PURE__ */ t(A.span, {
763
+ ...Z(f),
725
764
  className: "flex",
726
- children: /* @__PURE__ */ t(yt, { className: "size-3" })
727
- }, "check") : /* @__PURE__ */ t(N.span, {
728
- ...ee(m),
729
- children: f?.number ?? 1
765
+ children: /* @__PURE__ */ t(vt, { className: "size-3" })
766
+ }, "check") : /* @__PURE__ */ t(A.span, {
767
+ ...Z(f),
768
+ children: m?.number ?? 1
730
769
  }, "number")
731
- }), u === "working" ? /* @__PURE__ */ v(he, { children: [/* @__PURE__ */ t("span", { className: ma }), /* @__PURE__ */ t("span", { className: ha })] }) : null]
770
+ }), u === "working" ? /* @__PURE__ */ y(ye, { children: [/* @__PURE__ */ t("span", { className: ga }), /* @__PURE__ */ t("span", { className: ba })] }) : null]
732
771
  }),
733
- /* @__PURE__ */ v("div", {
772
+ /* @__PURE__ */ y("div", {
734
773
  "data-basic-page-step-title": "",
735
774
  className: p("text-display-xs col-start-2 row-start-1 min-w-0 font-medium transition-colors duration-200 ease-out", b ? "text-pho-description" : "text-pho-primary"),
736
- children: [g ? /* @__PURE__ */ v("span", {
775
+ children: [g ? /* @__PURE__ */ y("span", {
737
776
  className: "sr-only",
738
777
  children: [g, " "]
739
778
  }) : null, n]
740
779
  }),
741
- /* @__PURE__ */ t(_e, {
780
+ /* @__PURE__ */ t(Ce, {
742
781
  show: h,
743
782
  gap: "none",
744
783
  clip: !1,
745
784
  className: "col-start-2 row-start-2 flex min-w-0 flex-col self-stretch",
746
- children: /* @__PURE__ */ v("div", {
785
+ children: /* @__PURE__ */ y("div", {
747
786
  "data-basic-page-step-body": "",
748
787
  className: "flex min-w-0 flex-1 flex-col",
749
788
  children: [r ? /* @__PURE__ */ t("div", {
@@ -758,18 +797,18 @@ function ba({ icon: e, aside: a, title: n, description: r, done: s, working: l,
758
797
  u === "done" && E ? /* @__PURE__ */ t("div", {
759
798
  className: "col-start-3 row-start-1 flex min-w-0 items-center gap-2",
760
799
  children: i
761
- }) : C ? /* @__PURE__ */ t(G, {
800
+ }) : C ? /* @__PURE__ */ t(z, {
762
801
  initial: !1,
763
- children: h ? /* @__PURE__ */ t(N.div, {
764
- ...ee(m),
802
+ children: h ? /* @__PURE__ */ t(A.div, {
803
+ ...Z(f),
765
804
  className: "col-start-3 row-span-2 row-start-1 self-start",
766
805
  children: a
767
806
  }, "aside") : null
768
- }) : y ? /* @__PURE__ */ t(G, {
807
+ }) : v ? /* @__PURE__ */ t(z, {
769
808
  initial: !1,
770
- children: h ? /* @__PURE__ */ t(N.div, {
809
+ children: h ? /* @__PURE__ */ t(A.div, {
771
810
  "aria-hidden": !0,
772
- ...ee(m),
811
+ ...Z(f),
773
812
  className: "pointer-events-none col-start-3 row-span-2 row-start-1 size-14 self-start",
774
813
  children: /* @__PURE__ */ t("div", {
775
814
  className: "text-pho-primary size-full opacity-[0.275] [&>svg]:size-full",
@@ -781,13 +820,13 @@ function ba({ icon: e, aside: a, title: n, description: r, done: s, working: l,
781
820
  })
782
821
  });
783
822
  }
784
- function ya({ label: e, description: a, htmlFor: n, stacked: r = !1, className: s, children: l, ...o }) {
785
- const { leaving: c, ...i } = Ne();
786
- return /* @__PURE__ */ v(N.div, {
823
+ function xa({ label: e, description: a, htmlFor: n, stacked: r = !1, className: s, children: l, ...o }) {
824
+ const { leaving: c, ...i } = _e();
825
+ return /* @__PURE__ */ y(A.div, {
787
826
  ...i,
788
- className: p(At, r && "sm:flex-col sm:items-stretch sm:justify-start sm:gap-3", c && "overflow-hidden", s),
827
+ className: p(_t, r && "sm:flex-col sm:items-stretch sm:justify-start sm:gap-3", c && "overflow-hidden", s),
789
828
  ...o,
790
- children: [/* @__PURE__ */ v("div", {
829
+ children: [/* @__PURE__ */ y("div", {
791
830
  className: "min-w-0",
792
831
  children: [n ? /* @__PURE__ */ t("label", {
793
832
  htmlFor: n,
@@ -806,18 +845,18 @@ function ya({ label: e, description: a, htmlFor: n, stacked: r = !1, className:
806
845
  })]
807
846
  });
808
847
  }
809
- function va({ className: e, ...a }) {
810
- const n = T(Je);
848
+ function wa({ className: e, ...a }) {
849
+ const n = k(Ze);
811
850
  return /* @__PURE__ */ t("p", {
812
851
  className: p("text-pho-description max-w-full min-w-0 truncate", n ? "text-display-xs font-normal" : "text-base", e),
813
852
  ...a
814
853
  });
815
854
  }
816
- function xa({ error: e, show: a, className: n, children: r, ...s }) {
817
- const l = B(), o = T(X), c = e ?? o?.error ?? void 0;
818
- return /* @__PURE__ */ t(G, {
855
+ function Na({ error: e, show: a, className: n, children: r, ...s }) {
856
+ const l = L(), o = k(X), c = e ?? o?.error ?? void 0;
857
+ return /* @__PURE__ */ t(z, {
819
858
  initial: !1,
820
- children: (a ?? !0) && (c != null || r != null) ? /* @__PURE__ */ t(N.div, {
859
+ children: (a ?? !0) && (c != null || r != null) ? /* @__PURE__ */ t(A.div, {
821
860
  "data-basic-page-alert": "",
822
861
  className: "overflow-hidden",
823
862
  initial: {
@@ -834,9 +873,9 @@ function xa({ error: e, show: a, className: n, children: r, ...s }) {
834
873
  },
835
874
  transition: l ? { duration: 0 } : {
836
875
  height: P,
837
- opacity: M
876
+ opacity: B
838
877
  },
839
- children: /* @__PURE__ */ t(ct, {
878
+ children: /* @__PURE__ */ t(ut, {
840
879
  error: c,
841
880
  className: p("px-5 pb-3", n),
842
881
  ...s,
@@ -845,114 +884,114 @@ function xa({ error: e, show: a, className: n, children: r, ...s }) {
845
884
  }) : null
846
885
  });
847
886
  }
848
- function mn() {
849
- return T(X)?.requestSave ?? null;
887
+ function gn() {
888
+ return k(X)?.requestSave ?? null;
850
889
  }
851
- var hn = 800, ce = gt.createToastManager(), X = z(null);
852
- function wa({ action: e, errors: a, autoSave: n = !1, className: r, children: s, onChange: l, onBlur: o, ...c }) {
853
- const [i, d] = x(!1), [f, u] = x(!1), [m, h] = x(null), [b, g] = x(a ?? {}), [E, y] = x(null), C = _(null), w = _(null), S = _(null), O = _(!1), R = _(!1), I = _(null), D = _(async () => {
890
+ var bn = 800, de = bt.createToastManager(), X = H(null);
891
+ function Aa({ action: e, errors: a, autoSave: n = !1, className: r, children: s, onChange: l, onBlur: o, ...c }) {
892
+ const [i, d] = N(!1), [m, u] = N(!1), [f, h] = N(null), [b, g] = N(a ?? {}), [E, v] = N(null), C = _(null), x = _(null), R = _(null), I = _(!1), T = _(!1), M = _(null), F = _(async () => {
854
893
  });
855
- L(() => () => {
856
- w.current != null && clearTimeout(w.current);
894
+ O(() => () => {
895
+ x.current != null && clearTimeout(x.current);
857
896
  }, []);
858
- const j = async () => {
859
- const A = C.current;
860
- if (A == null || e == null) return;
861
- if (O.current) {
862
- R.current = !0;
897
+ const D = async () => {
898
+ const S = C.current;
899
+ if (S == null || e == null) return;
900
+ if (I.current) {
901
+ T.current = !0;
863
902
  return;
864
903
  }
865
- if (!A.checkValidity()) return;
866
- const k = Object.fromEntries(new FormData(A).entries()), Z = S.current;
867
- O.current = !0, y({
868
- field: Z,
904
+ if (!S.checkValidity()) return;
905
+ const w = Object.fromEntries(new FormData(S).entries()), $ = R.current;
906
+ I.current = !0, v({
907
+ field: $,
869
908
  phase: "saving"
870
909
  }), h(null);
871
910
  try {
872
- const F = (await e(k))?.errors;
873
- if (F != null && Object.keys(F).length > 0) {
874
- g(F), y(null);
911
+ const G = (await e(w))?.errors;
912
+ if (G != null && Object.keys(G).length > 0) {
913
+ g(G), v(null);
875
914
  return;
876
915
  }
877
- g({}), u(!1), y({
878
- field: Z,
916
+ g({}), u(!1), v({
917
+ field: $,
879
918
  phase: "saved"
880
- }), I.current != null && (ce.close(I.current), I.current = null);
881
- } catch (F) {
882
- y(null), h(F), I.current != null && ce.close(I.current), I.current = ce.add({
919
+ }), M.current != null && (de.close(M.current), M.current = null);
920
+ } catch (G) {
921
+ v(null), h(G), M.current != null && de.close(M.current), M.current = de.add({
883
922
  type: "error",
884
923
  title: "Couldn't save",
885
- description: F instanceof Error && F.message !== "" ? F.message : "The change is still here — try again.",
924
+ description: G instanceof Error && G.message !== "" ? G.message : "The change is still here — try again.",
886
925
  timeout: 0,
887
926
  actionProps: {
888
927
  children: "Retry",
889
928
  onClick: () => {
890
- D.current();
929
+ F.current();
891
930
  }
892
931
  }
893
932
  });
894
933
  } finally {
895
- O.current = !1, R.current && (R.current = !1, D.current());
934
+ I.current = !1, T.current && (T.current = !1, F.current());
896
935
  }
897
936
  };
898
- D.current = j;
899
- const U = () => {
900
- w.current != null && clearTimeout(w.current), w.current = setTimeout(() => {
901
- w.current = null, D.current();
937
+ F.current = D;
938
+ const Q = () => {
939
+ x.current != null && clearTimeout(x.current), x.current = setTimeout(() => {
940
+ x.current = null, F.current();
902
941
  }, 800);
903
- }, J = $(() => n ? (A) => {
904
- A != null && (S.current = A), u(!0), U();
905
- } : null, [n]), H = $(() => ({
942
+ }, Y = q(() => n ? (S) => {
943
+ S != null && (R.current = S), u(!0), Q();
944
+ } : null, [n]), le = q(() => ({
906
945
  pending: i,
907
- dirty: f,
908
- error: m,
946
+ dirty: m,
947
+ error: f,
909
948
  auto: E,
910
- requestSave: J
949
+ requestSave: Y
911
950
  }), [
912
951
  i,
913
- f,
914
952
  m,
953
+ f,
915
954
  E,
916
- J
955
+ Y
917
956
  ]);
918
957
  return /* @__PURE__ */ t(X.Provider, {
919
- value: H,
920
- children: /* @__PURE__ */ t(vt, {
958
+ value: le,
959
+ children: /* @__PURE__ */ t(xt, {
921
960
  errors: b,
922
- onFormSubmit: async (A) => {
961
+ onFormSubmit: async (S) => {
923
962
  if (e != null) {
924
963
  d(!0), h(null);
925
964
  try {
926
- const k = (await e(A))?.errors;
927
- if (k != null && Object.keys(k).length > 0) {
928
- g(k);
965
+ const w = (await e(S))?.errors;
966
+ if (w != null && Object.keys(w).length > 0) {
967
+ g(w);
929
968
  return;
930
969
  }
931
970
  g({}), u(!1);
932
- } catch (k) {
933
- h(k);
971
+ } catch (w) {
972
+ h(w);
934
973
  } finally {
935
974
  d(!1);
936
975
  }
937
976
  }
938
977
  },
939
- onChange: (A) => {
978
+ onChange: (S) => {
940
979
  u(!0), h(null);
941
- const k = A.target.name;
942
- k && k in b && g((Z) => {
943
- const { [k]: F, ...rt } = Z;
944
- return rt;
945
- }), n && (k && (S.current = k), U()), l?.(A);
980
+ const w = S.target.name;
981
+ w && w in b && g(($) => {
982
+ const { [w]: G, ...it } = $;
983
+ return it;
984
+ }), n && (w && (R.current = w), Q()), l?.(S);
946
985
  },
947
- onBlur: (A) => {
948
- n && f && w.current != null && (clearTimeout(w.current), w.current = null, D.current()), o?.(A);
986
+ onBlur: (S) => {
987
+ n && m && x.current != null && (clearTimeout(x.current), x.current = null, F.current()), o?.(S);
949
988
  },
950
989
  className: p("contents [[data-basic-page-stack]>&]:flex [[data-basic-page-stack]>&]:min-w-0 [[data-basic-page-stack]>&]:flex-col", r),
951
990
  ...c,
952
- ref: (A) => {
953
- C.current = A;
954
- const k = c.ref;
955
- typeof k == "function" ? k(A) : k != null && (k.current = A);
991
+ ref: (S) => {
992
+ C.current = S;
993
+ const w = c.ref;
994
+ typeof w == "function" ? w(S) : w != null && (w.current = S);
956
995
  },
957
996
  children: /* @__PURE__ */ t("fieldset", {
958
997
  disabled: i,
@@ -963,20 +1002,20 @@ function wa({ action: e, errors: a, autoSave: n = !1, className: r, children: s,
963
1002
  })
964
1003
  });
965
1004
  }
966
- function Na({ name: e, className: a, ...n }) {
967
- const r = T(X), s = B(), l = r?.auto ?? null, o = l != null && (e == null || l.field === e), [c, i] = x(!1), d = o ? l.phase : null;
968
- L(() => {
1005
+ function _a({ name: e, className: a, ...n }) {
1006
+ const r = k(X), s = L(), l = r?.auto ?? null, o = l != null && (e == null || l.field === e), [c, i] = N(!1), d = o ? l.phase : null;
1007
+ O(() => {
969
1008
  if (d !== "saved") return;
970
1009
  i(!0);
971
- const m = setTimeout(() => i(!1), 1800);
972
- return () => clearTimeout(m);
1010
+ const f = setTimeout(() => i(!1), 1800);
1011
+ return () => clearTimeout(f);
973
1012
  }, [d, l]);
974
- const f = d === "saving" ? "Saving…" : d === "saved" && c ? "Saved" : null, u = s ? "blur(0px)" : `blur(${He}px)`;
1013
+ const m = d === "saving" ? "Saving…" : d === "saved" && c ? "Saved" : null, u = s ? "blur(0px)" : `blur(${ge}px)`;
975
1014
  return /* @__PURE__ */ t("span", {
976
1015
  className: "grid justify-items-end",
977
- children: /* @__PURE__ */ t(G, {
1016
+ children: /* @__PURE__ */ t(z, {
978
1017
  initial: !1,
979
- children: f != null && /* @__PURE__ */ t(N.output, {
1018
+ children: m != null && /* @__PURE__ */ t(A.output, {
980
1019
  initial: {
981
1020
  opacity: 0,
982
1021
  filter: u
@@ -989,21 +1028,21 @@ function Na({ name: e, className: a, ...n }) {
989
1028
  opacity: 0,
990
1029
  filter: u
991
1030
  },
992
- transition: xe,
1031
+ transition: ne,
993
1032
  className: p("text-pho-description pl-8 [grid-area:1/1]", a),
994
1033
  style: { background: "linear-gradient(to left, var(--background-color-pho-primary) calc(100% - 2rem), transparent)" },
995
1034
  ...n,
996
- children: f
997
- }, f)
1035
+ children: m
1036
+ }, m)
998
1037
  })
999
1038
  });
1000
1039
  }
1001
- var Aa = "flex min-w-0 flex-col gap-5 p-5 [&>[data-basic-page-alert]]:-mx-5 [&>[data-basic-page-alert]]:-mt-2 [&>[data-basic-page-alert]]:-mb-5 [&>[data-basic-page-footer]]:pr-0 [&>[data-basic-page-reveal]]:flex [&>[data-basic-page-reveal]]:flex-col [&>[data-basic-page-reveal]]:gap-5";
1002
- function _a({ className: e, ...a }) {
1040
+ var Ea = "flex min-w-0 flex-col gap-5 p-5 [&>[data-basic-page-alert]]:-mx-5 [&>[data-basic-page-alert]]:-mt-2 [&>[data-basic-page-alert]]:-mb-5 [&>[data-basic-page-footer]]:pr-0 [&>[data-basic-page-reveal]]:flex [&>[data-basic-page-reveal]]:flex-col [&>[data-basic-page-reveal]]:gap-5";
1041
+ function Ca({ className: e, ...a }) {
1003
1042
  const n = _(null);
1004
- return Qe(n, "Fields", 20, () => null), /* @__PURE__ */ t("div", {
1043
+ return Ye(n, "Fields", 20, () => null), /* @__PURE__ */ t("div", {
1005
1044
  "data-basic-page-fields": "",
1006
- className: p(ge, Aa, e),
1045
+ className: p(ve, Ea, e),
1007
1046
  ...a,
1008
1047
  ref: (r) => {
1009
1048
  n.current = r;
@@ -1012,14 +1051,14 @@ function _a({ className: e, ...a }) {
1012
1051
  }
1013
1052
  });
1014
1053
  }
1015
- function Ea({ className: e, ...a }) {
1054
+ function Sa({ className: e, ...a }) {
1016
1055
  return /* @__PURE__ */ t("div", {
1017
1056
  className: p("flex min-w-0 flex-col gap-5 *:min-w-0 sm:flex-row sm:gap-3 sm:*:flex-1", e),
1018
1057
  ...a
1019
1058
  });
1020
1059
  }
1021
- function Ca({ children: e = "Save changes", ...a }) {
1022
- const n = T(X);
1060
+ function ka({ children: e = "Save changes", ...a }) {
1061
+ const n = k(X);
1023
1062
  return /* @__PURE__ */ t(ie, {
1024
1063
  type: "submit",
1025
1064
  variant: "effect",
@@ -1029,39 +1068,39 @@ function Ca({ children: e = "Save changes", ...a }) {
1029
1068
  children: e
1030
1069
  });
1031
1070
  }
1032
- function Sa({ show: e, className: a, ...n }) {
1033
- const r = T(X), s = e === "dirty" ? r?.dirty ?? !1 : e, l = /* @__PURE__ */ t("div", {
1071
+ function Ta({ show: e, className: a, ...n }) {
1072
+ const r = k(X), s = e === "dirty" ? r?.dirty ?? !1 : e, l = /* @__PURE__ */ t("div", {
1034
1073
  "data-basic-page-footer": "",
1035
1074
  className: p("flex items-center justify-end gap-3 pr-[calc(1.25rem+2.5px)]", a),
1036
1075
  ...n
1037
1076
  });
1038
- return s === void 0 ? l : /* @__PURE__ */ t(_e, {
1077
+ return s === void 0 ? l : /* @__PURE__ */ t(Ce, {
1039
1078
  show: s,
1040
1079
  gap: "block",
1041
1080
  clip: !1,
1042
1081
  children: l
1043
1082
  });
1044
1083
  }
1045
- var ka = {
1084
+ var Ra = {
1046
1085
  stack: "-2.5rem",
1047
1086
  block: "-0.75rem",
1048
1087
  fields: "-1.25rem",
1049
1088
  none: "0px"
1050
1089
  };
1051
- function _e({ show: e, clip: a = !0, gap: n = "stack", dividers: r, className: s, ...l }) {
1052
- const o = B(), c = ka[r ? "none" : n], i = _(null), d = _(e !== !0);
1053
- L(() => {
1090
+ function Ce({ show: e, clip: a = !0, gap: n = "stack", dividers: r, className: s, ...l }) {
1091
+ const o = L(), c = Ra[r ? "none" : n], i = _(null), d = _(e !== !0);
1092
+ O(() => {
1054
1093
  d.current = !0;
1055
1094
  }, []);
1056
- const f = () => {
1095
+ const m = () => {
1057
1096
  a && i.current && (i.current.style.overflow = "hidden");
1058
1097
  }, u = () => {
1059
1098
  i.current && (i.current.style.overflow = "");
1060
1099
  };
1061
- return e === void 0 ? /* @__PURE__ */ t(N.div, {
1100
+ return e === void 0 ? /* @__PURE__ */ t(A.div, {
1062
1101
  initial: o ? !1 : {
1063
1102
  opacity: 0,
1064
- y: q
1103
+ y: j
1065
1104
  },
1066
1105
  animate: {
1067
1106
  opacity: 1,
@@ -1069,18 +1108,18 @@ function _e({ show: e, clip: a = !0, gap: n = "stack", dividers: r, className: s
1069
1108
  },
1070
1109
  transition: {
1071
1110
  y: P,
1072
- opacity: M
1111
+ opacity: B
1073
1112
  },
1074
- className: p(r && ne, s),
1113
+ className: p(r && ae, s),
1075
1114
  ...l
1076
- }) : /* @__PURE__ */ t(G, {
1115
+ }) : /* @__PURE__ */ t(z, {
1077
1116
  initial: !1,
1078
- children: e ? /* @__PURE__ */ t(N.div, {
1117
+ children: e ? /* @__PURE__ */ t(A.div, {
1079
1118
  "data-basic-page-reveal": "",
1080
- ref: (m) => {
1081
- i.current = m, a && m && d.current && (m.style.overflow = "hidden");
1119
+ ref: (f) => {
1120
+ i.current = f, a && f && d.current && (f.style.overflow = "hidden");
1082
1121
  },
1083
- onAnimationStart: f,
1122
+ onAnimationStart: m,
1084
1123
  onAnimationComplete: u,
1085
1124
  initial: {
1086
1125
  height: 0,
@@ -1100,22 +1139,22 @@ function _e({ show: e, clip: a = !0, gap: n = "stack", dividers: r, className: s
1100
1139
  transition: o ? { duration: 0 } : {
1101
1140
  height: P,
1102
1141
  marginTop: P,
1103
- opacity: M
1142
+ opacity: B
1104
1143
  },
1105
- className: p(r && ne, s),
1144
+ className: p(r && ae, s),
1106
1145
  ...l
1107
1146
  }) : null
1108
1147
  });
1109
1148
  }
1110
- var Ta = "top-4 left-5 h-8 text-base [&>svg]:size-[1.125em] [&>svg]:shrink-0", Ra = "(min-width: 40rem)";
1111
- function Pa() {
1112
- return typeof window < "u" && typeof window.matchMedia == "function" && !window.matchMedia(Ra).matches;
1149
+ var Pa = "top-4 left-5 h-8 text-base [&>svg]:size-[1.125em] [&>svg]:shrink-0", Ia = "(min-width: 40rem)";
1150
+ function Oa() {
1151
+ return typeof window < "u" && typeof window.matchMedia == "function" && !window.matchMedia(Ia).matches;
1113
1152
  }
1114
- var Ze = z(null);
1115
- function et({ className: e, children: a, ...n }) {
1116
- const r = Y.toArray(a).filter(Fe), s = r.map((C) => C.props.children ?? null), l = je();
1117
- zt(s);
1118
- const [o] = x(Pa), c = B(), i = r.length, d = De(), f = !o && i >= Ia, u = T(ye), m = i > 0 ? r[i - 1]?.props : null, h = m?.children ?? "Back", b = m?.href, g = m?.onClick;
1153
+ var et = H(null);
1154
+ function tt({ className: e, children: a, ...n }) {
1155
+ const r = J.toArray(a).filter(Fe), s = r.map((C) => C.props.children ?? null), l = We();
1156
+ Vt(s);
1157
+ const [o] = N(Oa), c = L(), i = r.length, d = He(), m = !o && i >= La, u = k(we), f = i > 0 ? r[i - 1]?.props : null, h = f?.children ?? "Back", b = f?.href, g = f?.onClick;
1119
1158
  V(() => {
1120
1159
  if (!(u == null || b == null))
1121
1160
  return u.setTail({
@@ -1129,132 +1168,132 @@ function et({ className: e, children: a, ...n }) {
1129
1168
  b,
1130
1169
  g
1131
1170
  ]);
1132
- const [E, y] = x(!c && !o && l != null && l.labels.length > i);
1171
+ const [E, v] = N(!c && !o && l != null && l.labels.length > i);
1133
1172
  return /* @__PURE__ */ t("nav", {
1134
1173
  "aria-label": "Breadcrumb",
1135
1174
  "data-basic-page-back": "",
1136
1175
  className: p("absolute top-4 left-3 flex min-w-max items-center", e),
1137
1176
  ...n,
1138
- children: /* @__PURE__ */ v("ol", {
1177
+ children: /* @__PURE__ */ y("ol", {
1139
1178
  className: "m-0 flex list-none items-center p-0",
1140
- children: [r.map((C, w) => f && w > 0 && w < i - 2 ? null : /* @__PURE__ */ v(xt, { children: [f && w === i - 2 && /* @__PURE__ */ v("li", {
1179
+ children: [r.map((C, x) => m && x > 0 && x < i - 2 ? null : /* @__PURE__ */ y(wt, { children: [m && x === i - 2 && /* @__PURE__ */ y("li", {
1141
1180
  className: "m-0 flex items-center max-sm:hidden",
1142
1181
  children: [/* @__PURE__ */ t("span", {
1143
1182
  "aria-hidden": !0,
1144
- className: de,
1183
+ className: fe,
1145
1184
  children: re
1146
- }), /* @__PURE__ */ v(W.Root, { children: [/* @__PURE__ */ t(W.Trigger, { render: /* @__PURE__ */ t(ie, {
1185
+ }), /* @__PURE__ */ y(W.Root, { children: [/* @__PURE__ */ t(W.Trigger, { render: /* @__PURE__ */ t(ie, {
1147
1186
  variant: "ghost",
1148
1187
  size: "sm",
1149
1188
  "aria-label": "Hidden pages",
1150
1189
  className: "px-2",
1151
- children: Oa
1190
+ children: Ba
1152
1191
  }) }), /* @__PURE__ */ t(W.Portal, { children: /* @__PURE__ */ t(W.Positioner, {
1153
1192
  align: "start",
1154
1193
  sideOffset: 4,
1155
- children: /* @__PURE__ */ t(W.Popup, { children: r.slice(1, i - 2).map((S, O) => {
1156
- const R = S.props;
1194
+ children: /* @__PURE__ */ t(W.Popup, { children: r.slice(1, i - 2).map((R, I) => {
1195
+ const T = R.props;
1157
1196
  return /* @__PURE__ */ t(W.LinkItem, {
1158
1197
  render: /* @__PURE__ */ t(d, {
1159
- href: R.href,
1160
- onClick: R.onClick
1198
+ href: T.href,
1199
+ onClick: T.onClick
1161
1200
  }),
1162
- children: R.children ?? "Back"
1163
- }, S.key ?? O);
1201
+ children: T.children ?? "Back"
1202
+ }, R.key ?? I);
1164
1203
  }) })
1165
1204
  }) })] })]
1166
1205
  }), /* @__PURE__ */ t("li", {
1167
- className: p("m-0 flex items-center", w < i - 1 && "max-sm:hidden"),
1168
- children: /* @__PURE__ */ t(Ze.Provider, {
1206
+ className: p("m-0 flex items-center", x < i - 1 && "max-sm:hidden"),
1207
+ children: /* @__PURE__ */ t(et.Provider, {
1169
1208
  value: {
1170
- index: w,
1209
+ index: x,
1171
1210
  count: i,
1172
1211
  departing: l,
1173
1212
  narrow: o
1174
1213
  },
1175
1214
  children: C
1176
1215
  })
1177
- })] }, C.key ?? w)), E && /* @__PURE__ */ t("li", {
1216
+ })] }, C.key ?? x)), E && /* @__PURE__ */ t("li", {
1178
1217
  "aria-hidden": !0,
1179
1218
  className: "m-0 flex items-center max-sm:hidden",
1180
- children: /* @__PURE__ */ t(N.span, {
1219
+ children: /* @__PURE__ */ t(A.span, {
1181
1220
  initial: { opacity: 1 },
1182
1221
  animate: { opacity: 0 },
1183
- transition: qe,
1184
- onAnimationComplete: () => y(!1),
1185
- className: de,
1222
+ transition: je,
1223
+ onAnimationComplete: () => v(!1),
1224
+ className: fe,
1186
1225
  children: re
1187
1226
  })
1188
1227
  })]
1189
1228
  })
1190
1229
  });
1191
1230
  }
1192
- var de = "text-pho-description -mx-1 inline-flex shrink-0 text-base select-none", re = "/", Ia = 4, Oa = "…";
1193
- function tt({ href: e, className: a, morphId: n, children: r = "Back", ...s }) {
1194
- const l = T(Ze), o = B(), c = n != null && !o, i = We(c ? n : void 0);
1231
+ var fe = "text-pho-description -mx-1 inline-flex shrink-0 text-base select-none", re = "/", La = 4, Ba = "…";
1232
+ function at({ href: e, className: a, morphId: n, children: r = "Back", ...s }) {
1233
+ const l = k(et), o = L(), c = n != null && !o, i = Ke(c ? n : void 0);
1195
1234
  if (l == null) throw new Error("BasicPage.Crumb must be rendered inside BasicPage.Breadcrumbs");
1196
- const { index: d, count: f, departing: u, narrow: m } = l, h = d === 0, b = d === f - 1, g = u != null && u.labels.length < f, E = u != null && u.labels.length > f, y = b && (u == null || g || m), C = h || b, w = h && b ? "" : h ? "max-sm:hidden" : "sm:hidden", S = u != null, O = b ? m ? E ? "slide" : "fade" : y ? "fade" : void 0 : void 0, [R, I] = x(c && m && i.fly && u != null && !E ? u.labels[u.labels.length - 1] : null), D = c && C && !S, j = c && !h && b && (u == null || g);
1197
- return /* @__PURE__ */ v(he, { children: [!h && /* @__PURE__ */ t("span", {
1235
+ const { index: d, count: m, departing: u, narrow: f } = l, h = d === 0, b = d === m - 1, g = u != null && u.labels.length < m, E = u != null && u.labels.length > m, v = b && (u == null || g || f), C = h || b, x = h && b ? "" : h ? "max-sm:hidden" : "sm:hidden", R = u != null, I = b ? f ? E ? "slide" : "fade" : v ? "fade" : void 0 : void 0, [T, M] = N(c && f && i.fly && u != null && !E ? u.labels[u.labels.length - 1] : null), F = c && C && !R, D = c && !h && b && (u == null || g);
1236
+ return /* @__PURE__ */ y(ye, { children: [!h && /* @__PURE__ */ t("span", {
1198
1237
  "aria-hidden": !0,
1199
- className: p(de, "max-sm:hidden"),
1200
- children: j ? /* @__PURE__ */ t(N.span, {
1238
+ className: p(fe, "max-sm:hidden"),
1239
+ children: D ? /* @__PURE__ */ t(A.span, {
1201
1240
  initial: i.fly ? {
1202
1241
  opacity: 0,
1203
- x: Te
1242
+ x: Pe
1204
1243
  } : { opacity: 0 },
1205
1244
  animate: i.fly ? {
1206
1245
  opacity: 1,
1207
1246
  x: 0
1208
1247
  } : { opacity: 1 },
1209
- transition: i.fly ? Re : M,
1248
+ transition: i.fly ? Ie : B,
1210
1249
  className: "inline-flex",
1211
1250
  children: re
1212
1251
  }) : re
1213
- }), /* @__PURE__ */ t(pe, {
1252
+ }), /* @__PURE__ */ t(me, {
1214
1253
  variant: "ghost",
1215
1254
  size: "sm",
1216
1255
  href: e,
1217
- prefix: C ? D ? /* @__PURE__ */ t(N.span, {
1256
+ prefix: C ? F ? /* @__PURE__ */ t(A.span, {
1218
1257
  initial: i.fly ? {
1219
1258
  opacity: 0,
1220
- x: Te
1259
+ x: Pe
1221
1260
  } : { opacity: 0 },
1222
1261
  animate: i.fly ? {
1223
1262
  opacity: 1,
1224
1263
  x: 0
1225
1264
  } : { opacity: 1 },
1226
- transition: i.fly ? Re : M,
1227
- className: p("inline-flex [&>svg]:size-[1.125em] [&>svg]:shrink-0", w),
1228
- children: /* @__PURE__ */ t(ae, {})
1265
+ transition: i.fly ? Ie : B,
1266
+ className: p("inline-flex [&>svg]:size-[1.125em] [&>svg]:shrink-0", x),
1267
+ children: /* @__PURE__ */ t(te, {})
1229
1268
  }) : /* @__PURE__ */ t("span", {
1230
- className: p("inline-flex [&>svg]:size-[1.125em] [&>svg]:shrink-0", w),
1231
- children: /* @__PURE__ */ t(ae, {})
1269
+ className: p("inline-flex [&>svg]:size-[1.125em] [&>svg]:shrink-0", x),
1270
+ children: /* @__PURE__ */ t(te, {})
1232
1271
  }) : /* @__PURE__ */ t("span", { className: "hidden" }),
1233
1272
  className: p("min-w-max", a),
1234
1273
  ...s,
1235
- children: c && n != null ? /* @__PURE__ */ v("span", {
1236
- className: p("relative block", !i.fly && O === "slide" && "overflow-hidden", !b && "max-w-40 truncate"),
1237
- children: [/* @__PURE__ */ t(Ke, {
1274
+ children: c && n != null ? /* @__PURE__ */ y("span", {
1275
+ className: p("relative block", !i.fly && I === "slide" && "overflow-hidden", !b && "max-w-40 truncate"),
1276
+ children: [/* @__PURE__ */ t(Xe, {
1238
1277
  morphId: n,
1239
1278
  fromClassName: "text-pho-primary",
1240
1279
  fly: i.fly,
1241
1280
  morphRef: i.ref,
1242
- arrival: O,
1281
+ arrival: I,
1243
1282
  children: r
1244
- }), R != null && /* @__PURE__ */ t(N.span, {
1283
+ }), T != null && /* @__PURE__ */ t(A.span, {
1245
1284
  "aria-hidden": !0,
1246
1285
  initial: {
1247
1286
  x: 0,
1248
1287
  opacity: 1
1249
1288
  },
1250
1289
  animate: {
1251
- x: Ht,
1290
+ x: Ft,
1252
1291
  opacity: 0
1253
1292
  },
1254
- transition: Ft,
1255
- onAnimationComplete: () => I(null),
1293
+ transition: Gt,
1294
+ onAnimationComplete: () => M(null),
1256
1295
  className: "pointer-events-none absolute inset-y-0 left-0 whitespace-nowrap",
1257
- children: R
1296
+ children: T
1258
1297
  })]
1259
1298
  }) : /* @__PURE__ */ t("span", {
1260
1299
  className: p("block", !b && "max-w-40 truncate"),
@@ -1262,22 +1301,22 @@ function tt({ href: e, className: a, morphId: n, children: r = "Back", ...s }) {
1262
1301
  })
1263
1302
  })] });
1264
1303
  }
1265
- function La({ className: e, ...a }) {
1266
- return /* @__PURE__ */ t(et, {
1304
+ function Ma({ className: e, ...a }) {
1305
+ return /* @__PURE__ */ t(tt, {
1267
1306
  className: e,
1268
- children: /* @__PURE__ */ t(tt, { ...a })
1307
+ children: /* @__PURE__ */ t(at, { ...a })
1269
1308
  });
1270
1309
  }
1271
- function Ba({ label: e, description: a, leading: n, href: r, className: s, children: l, ...o }) {
1272
- const c = De(), i = $(() => N.create(c), [c]), { leaving: d, ...f } = Ne();
1273
- return /* @__PURE__ */ v(i, {
1310
+ function Da({ label: e, description: a, leading: n, href: r, className: s, children: l, ...o }) {
1311
+ const c = He(), i = q(() => A.create(c), [c]), { leaving: d, ...m } = _e();
1312
+ return /* @__PURE__ */ y(i, {
1274
1313
  href: r,
1275
- ...f,
1314
+ ...m,
1276
1315
  ...o,
1277
1316
  className: p("flex min-h-[4.25rem] min-w-0 flex-row items-center justify-between gap-6 px-5 py-4", "group outline-pho-brand hover:bg-pho-primary-hover cursor-pointer transition-colors focus-visible:outline-2 focus-visible:-outline-offset-2", "aria-[current=page]:bg-pho-primary-hover", "first:rounded-t-[calc(var(--radius-base)-1px)] last:rounded-b-[calc(var(--radius-base)-1px)]", d && "overflow-hidden", s),
1278
- children: [/* @__PURE__ */ v("div", {
1317
+ children: [/* @__PURE__ */ y("div", {
1279
1318
  className: p("flex min-w-0 flex-1 items-center", n != null && "gap-3"),
1280
- children: [n, /* @__PURE__ */ v("div", {
1319
+ children: [n, /* @__PURE__ */ y("div", {
1281
1320
  className: "min-w-0",
1282
1321
  children: [/* @__PURE__ */ t("div", {
1283
1322
  className: "flex min-w-0 items-center gap-1",
@@ -1290,40 +1329,40 @@ function Ba({ label: e, description: a, leading: n, href: r, className: s, child
1290
1329
  children: a
1291
1330
  }) : null]
1292
1331
  })]
1293
- }), /* @__PURE__ */ v("div", {
1332
+ }), /* @__PURE__ */ y("div", {
1294
1333
  className: "flex min-w-0 items-center justify-end gap-2",
1295
1334
  children: [l != null ? /* @__PURE__ */ t("div", {
1296
1335
  className: "min-w-0",
1297
1336
  children: l
1298
- }) : null, /* @__PURE__ */ t(ut, {
1337
+ }) : null, /* @__PURE__ */ t(dt, {
1299
1338
  "aria-hidden": !0,
1300
1339
  className: "text-pho-secondary group-hover:text-pho-secondary-hover size-4 shrink-0 transition-colors"
1301
1340
  })]
1302
1341
  })]
1303
1342
  });
1304
1343
  }
1305
- function Ma({ open: e, variant: a = "overlay", modal: n = !1, placeholder: r, onClose: s, children: l }) {
1306
- const o = T(Ve), c = e ?? Y.toArray(l).length > 0, i = o?.setOpen, d = o?.setPresent;
1344
+ function Ha({ open: e, variant: a = "overlay", modal: n = !1, placeholder: r, onClose: s, children: l }) {
1345
+ const o = k($e), c = e ?? J.toArray(l).length > 0, i = o?.setOpen, d = o?.setPresent;
1307
1346
  return V(() => {
1308
1347
  if (d != null)
1309
1348
  return d(!0), () => d(!1);
1310
1349
  }, [d]), V(() => {
1311
1350
  if (i != null)
1312
1351
  return i(c), () => i(!1);
1313
- }, [i, c]), L(() => {
1352
+ }, [i, c]), O(() => {
1314
1353
  o == null && typeof process < "u" && process.env.NODE_ENV !== "production" && console.warn("BasicPage.Aside: needs a `BasicPage.Root` around it.");
1315
- }, [o]), o == null || o.slot == null ? null : o.presentation === "page" ? Ce(c ? /* @__PURE__ */ t("div", {
1354
+ }, [o]), o == null || o.slot == null ? null : o.presentation === "page" ? ke(c ? /* @__PURE__ */ t("div", {
1316
1355
  "data-basic-page-aside": "page",
1317
1356
  className: "flex min-w-0 flex-1 flex-col",
1318
1357
  children: l
1319
- }) : null, o.slot) : a === "inline" ? Ce(/* @__PURE__ */ t(Da, {
1358
+ }) : null, o.slot) : a === "inline" ? ke(/* @__PURE__ */ t(Fa, {
1320
1359
  width: o.width,
1321
1360
  paneHeight: o.paneHeight,
1322
1361
  onClose: s,
1323
1362
  open: c,
1324
1363
  placeholder: r,
1325
1364
  children: l
1326
- }), o.slot) : /* @__PURE__ */ t(Ha, {
1365
+ }), o.slot) : /* @__PURE__ */ t(Ga, {
1327
1366
  container: o.slot,
1328
1367
  width: o.width,
1329
1368
  paneHeight: o.paneHeight,
@@ -1333,8 +1372,8 @@ function Ma({ open: e, variant: a = "overlay", modal: n = !1, placeholder: r, on
1333
1372
  children: l
1334
1373
  });
1335
1374
  }
1336
- function at() {
1337
- const [e, a] = x(null), n = $(() => ({ setBack: a }), []), r = _(null);
1375
+ function nt() {
1376
+ const [e, a] = N(null), n = q(() => ({ setBack: a }), []), r = _(null);
1338
1377
  return {
1339
1378
  back: e,
1340
1379
  panel: n,
@@ -1345,44 +1384,44 @@ function at() {
1345
1384
  }, [])
1346
1385
  };
1347
1386
  }
1348
- var Be = {
1387
+ var Me = {
1349
1388
  variant: "ghost",
1350
1389
  size: "sm",
1351
1390
  svgOnly: !0,
1352
1391
  "aria-label": "Close",
1353
- children: /* @__PURE__ */ t(ht, {})
1392
+ children: /* @__PURE__ */ t(gt, {})
1354
1393
  };
1355
- function nt({ back: e, onClose: a, closeRef: n, panel: r, children: s }) {
1356
- return /* @__PURE__ */ v(he, { children: [/* @__PURE__ */ t("span", {
1394
+ function rt({ back: e, onClose: a, closeRef: n, panel: r, children: s }) {
1395
+ return /* @__PURE__ */ y(ye, { children: [/* @__PURE__ */ t("span", {
1357
1396
  ref: n,
1358
1397
  className: "absolute top-2 right-2 z-30",
1359
- children: e != null ? /* @__PURE__ */ t(pe, {
1360
- ...Be,
1398
+ children: e != null ? /* @__PURE__ */ t(me, {
1399
+ ...Me,
1361
1400
  href: e.href,
1362
1401
  onClick: e.onClick
1363
1402
  }) : a != null ? /* @__PURE__ */ t(ie, {
1364
- ...Be,
1403
+ ...Me,
1365
1404
  onClick: a
1366
1405
  }) : null
1367
- }), /* @__PURE__ */ v(Q.Root, {
1406
+ }), /* @__PURE__ */ y(U.Root, {
1368
1407
  className: "min-h-0 flex-1",
1369
- children: [/* @__PURE__ */ t(Q.Viewport, { children: /* @__PURE__ */ t(Q.Content, {
1408
+ children: [/* @__PURE__ */ t(U.Viewport, { children: /* @__PURE__ */ t(U.Content, {
1370
1409
  className: "flex min-h-full flex-col",
1371
- children: /* @__PURE__ */ t($e.Provider, {
1410
+ children: /* @__PURE__ */ t(qe.Provider, {
1372
1411
  value: r,
1373
1412
  children: s
1374
1413
  })
1375
- }) }), /* @__PURE__ */ t(Q.Scrollbar, { children: /* @__PURE__ */ t(Q.Thumb, {}) })]
1414
+ }) }), /* @__PURE__ */ t(U.Scrollbar, { children: /* @__PURE__ */ t(U.Thumb, {}) })]
1376
1415
  })] });
1377
1416
  }
1378
- function Da({ width: e, paneHeight: a, onClose: n, open: r, placeholder: s, children: l }) {
1379
- const o = B(), { back: c, panel: i, closeRef: d, leave: f } = at(), u = o ? "blur(0px)" : `blur(${He}px)`, m = a ?? "100dvh";
1380
- L(() => {
1417
+ function Fa({ width: e, paneHeight: a, onClose: n, open: r, placeholder: s, children: l }) {
1418
+ const o = L(), { back: c, panel: i, closeRef: d, leave: m } = nt(), u = o ? "blur(0px)" : `blur(${ge}px)`, f = a ?? "100dvh";
1419
+ O(() => {
1381
1420
  const b = (g) => {
1382
- g.key !== "Escape" || g.defaultPrevented || f() && g.preventDefault();
1421
+ g.key !== "Escape" || g.defaultPrevented || m() && g.preventDefault();
1383
1422
  };
1384
1423
  return document.addEventListener("keydown", b), () => document.removeEventListener("keydown", b);
1385
- }, [f]);
1424
+ }, [m]);
1386
1425
  const h = {
1387
1426
  initial: {
1388
1427
  opacity: 0,
@@ -1396,7 +1435,7 @@ function Da({ width: e, paneHeight: a, onClose: n, open: r, placeholder: s, chil
1396
1435
  opacity: 0,
1397
1436
  filter: u
1398
1437
  },
1399
- transition: o ? { duration: 0 } : xe
1438
+ transition: o ? { duration: 0 } : ne
1400
1439
  };
1401
1440
  return /* @__PURE__ */ t("aside", {
1402
1441
  "data-basic-page-aside": "panel",
@@ -1404,24 +1443,24 @@ function Da({ width: e, paneHeight: a, onClose: n, open: r, placeholder: s, chil
1404
1443
  className: "relative flex shrink-0 flex-col",
1405
1444
  style: {
1406
1445
  width: e,
1407
- minHeight: m
1446
+ minHeight: f
1408
1447
  },
1409
1448
  children: /* @__PURE__ */ t("div", {
1410
1449
  className: "border-pho-secondary bg-pho-primary sticky top-0 grid border-l *:min-h-0 *:[grid-area:1/1]",
1411
- style: { height: m },
1412
- children: /* @__PURE__ */ t(G, {
1450
+ style: { height: f },
1451
+ children: /* @__PURE__ */ t(z, {
1413
1452
  initial: !1,
1414
- children: r ? /* @__PURE__ */ t(N.div, {
1453
+ children: r ? /* @__PURE__ */ t(A.div, {
1415
1454
  ...h,
1416
1455
  className: "relative flex flex-col",
1417
- children: /* @__PURE__ */ t(nt, {
1456
+ children: /* @__PURE__ */ t(rt, {
1418
1457
  back: c,
1419
1458
  onClose: n,
1420
1459
  closeRef: d,
1421
1460
  panel: i,
1422
1461
  children: l
1423
1462
  })
1424
- }, "page") : /* @__PURE__ */ t(N.div, {
1463
+ }, "page") : /* @__PURE__ */ t(A.div, {
1425
1464
  ...h,
1426
1465
  className: "flex flex-col",
1427
1466
  children: s
@@ -1430,23 +1469,23 @@ function Da({ width: e, paneHeight: a, onClose: n, open: r, placeholder: s, chil
1430
1469
  })
1431
1470
  });
1432
1471
  }
1433
- function Ha({ container: e, width: a, paneHeight: n, onClose: r, open: s, modal: l, children: o }) {
1434
- const { back: c, panel: i, closeRef: d, leave: f } = at(), u = n ?? "100dvh";
1435
- return /* @__PURE__ */ t(te.Root, {
1472
+ function Ga({ container: e, width: a, paneHeight: n, onClose: r, open: s, modal: l, children: o }) {
1473
+ const { back: c, panel: i, closeRef: d, leave: m } = nt(), u = n ?? "100dvh";
1474
+ return /* @__PURE__ */ t(ee.Root, {
1436
1475
  open: s,
1437
1476
  modal: l ? "trap-focus" : !1,
1438
1477
  disablePointerDismissal: !0,
1439
- onOpenChange: (m, h) => {
1440
- m || (h.cancel(), f());
1478
+ onOpenChange: (f, h) => {
1479
+ f || (h.cancel(), m());
1441
1480
  },
1442
- children: /* @__PURE__ */ v(te.Portal, {
1481
+ children: /* @__PURE__ */ y(ee.Portal, {
1443
1482
  container: e,
1444
1483
  className: "contents",
1445
- children: [l ? /* @__PURE__ */ t(te.Backdrop, {
1484
+ children: [l ? /* @__PURE__ */ t(ee.Backdrop, {
1446
1485
  "data-basic-page-aside-backdrop": "",
1447
1486
  className: p("bg-pho-overlay absolute inset-0 z-30 transition-opacity duration-200 ease-out motion-reduce:transition-none", "data-[ending-style]:opacity-0 data-[starting-style]:opacity-0"),
1448
- onClick: f
1449
- }) : null, /* @__PURE__ */ t(te.Popup, {
1487
+ onClick: m
1488
+ }) : null, /* @__PURE__ */ t(ee.Popup, {
1450
1489
  "data-basic-page-aside": "panel",
1451
1490
  "data-basic-page-aside-variant": "overlay",
1452
1491
  initialFocus: l ? void 0 : !1,
@@ -1456,7 +1495,7 @@ function Ha({ container: e, width: a, paneHeight: n, onClose: r, open: s, modal:
1456
1495
  children: /* @__PURE__ */ t("div", {
1457
1496
  className: "border-pho-secondary bg-pho-primary shadow-pho-xl sticky top-0 flex flex-col border-l",
1458
1497
  style: { height: u },
1459
- children: /* @__PURE__ */ t(nt, {
1498
+ children: /* @__PURE__ */ t(rt, {
1460
1499
  back: c,
1461
1500
  onClose: r,
1462
1501
  closeRef: d,
@@ -1468,14 +1507,14 @@ function Ha({ container: e, width: a, paneHeight: n, onClose: r, open: s, modal:
1468
1507
  })
1469
1508
  });
1470
1509
  }
1471
- var Fa = "14rem", Ga = "transition-[width] duration-[330ms] ease-pho-spring motion-reduce:transition-none", Me = "transition-[opacity,visibility] duration-200 ease-out motion-reduce:transition-none";
1472
- function za({ variant: e = "box", fold: a = "auto", value: n, onValueChange: r, placeholder: s, label: l, className: o, ...c }) {
1473
- const i = T(fe), d = me(i?.subscribe ?? ve, () => i?.get().api ?? null, () => null), f = n != null;
1474
- L(() => {
1475
- if (!(i == null || f))
1510
+ var za = "14rem", Va = "transition-[width] duration-[330ms] ease-pho-spring motion-reduce:transition-none", De = "transition-[opacity,visibility] duration-200 ease-out motion-reduce:transition-none";
1511
+ function $a({ variant: e = "box", fold: a = "auto", value: n, onValueChange: r, placeholder: s, label: l, className: o, ...c }) {
1512
+ const i = k(he), d = be(i?.subscribe ?? Ne, () => i?.get().api ?? null, () => null), m = n != null;
1513
+ O(() => {
1514
+ if (!(i == null || m))
1476
1515
  return i.adopt(!0), () => i.adopt(!1);
1477
- }, [i, f]);
1478
- const u = f ? {
1516
+ }, [i, m]);
1517
+ const u = m ? {
1479
1518
  query: n,
1480
1519
  setQuery: r,
1481
1520
  placeholder: s ?? "Search",
@@ -1485,27 +1524,27 @@ function za({ variant: e = "box", fold: a = "auto", value: n, onValueChange: r,
1485
1524
  setQuery: d.setQuery,
1486
1525
  placeholder: d.placeholder,
1487
1526
  label: l ?? d.placeholder
1488
- }, [m, h] = x(!1), b = _(null), g = m || (u?.query ?? "") !== "";
1489
- if (L(() => {
1490
- if (!m) return;
1491
- let y = 0, C = 0;
1492
- const w = () => {
1493
- const S = b.current;
1494
- S != null && (S.focus(), document.activeElement !== S && C++ < 5 && (y = requestAnimationFrame(w)));
1527
+ }, [f, h] = N(!1), b = _(null), g = f || (u?.query ?? "") !== "";
1528
+ if (O(() => {
1529
+ if (!f) return;
1530
+ let v = 0, C = 0;
1531
+ const x = () => {
1532
+ const R = b.current;
1533
+ R != null && (R.focus(), document.activeElement !== R && C++ < 5 && (v = requestAnimationFrame(x)));
1495
1534
  };
1496
- return y = requestAnimationFrame(w), () => cancelAnimationFrame(y);
1497
- }, [m]), e === "ghost") return /* @__PURE__ */ t("div", {
1535
+ return v = requestAnimationFrame(x), () => cancelAnimationFrame(v);
1536
+ }, [f]), e === "ghost") return /* @__PURE__ */ t("div", {
1498
1537
  "data-basic-page-search": "",
1499
1538
  "data-variant": "ghost",
1500
1539
  className: p("flex min-w-0 flex-1", u == null && "hidden", o),
1501
1540
  ...c,
1502
- children: u != null && /* @__PURE__ */ t(ft, {
1541
+ children: u != null && /* @__PURE__ */ t(mt, {
1503
1542
  value: u.query,
1504
1543
  onChange: u.setQuery,
1505
1544
  placeholder: u.placeholder,
1506
1545
  "aria-label": u.label,
1507
- onKeyDown: (y) => {
1508
- y.key === "Escape" && (y.preventDefault(), u.setQuery(""), y.currentTarget.blur());
1546
+ onKeyDown: (v) => {
1547
+ v.key === "Escape" && (v.preventDefault(), u.setQuery(""), v.currentTarget.blur());
1509
1548
  }
1510
1549
  })
1511
1550
  });
@@ -1515,9 +1554,9 @@ function za({ variant: e = "box", fold: a = "auto", value: n, onValueChange: r,
1515
1554
  "data-expanded": g || void 0,
1516
1555
  className: p("grid min-w-0 content-center", "[[data-basic-page-header]>&]:col-start-2 [[data-basic-page-header]>&]:row-span-2 [[data-basic-page-header]>&]:row-start-1 [[data-basic-page-header]>&]:ml-4 [[data-basic-page-header]>&]:justify-items-end [[data-basic-page-header]>&]:self-start", u == null && "hidden", o),
1517
1556
  ...c,
1518
- children: u != null && /* @__PURE__ */ v("div", {
1519
- className: p("grid w-9 max-w-full justify-items-end *:[grid-area:1/1]", Ga, E && "@[36rem]:w-56"),
1520
- style: g ? { width: Fa } : void 0,
1557
+ children: u != null && /* @__PURE__ */ y("div", {
1558
+ className: p("grid w-9 max-w-full justify-items-end *:[grid-area:1/1]", Va, E && "@[36rem]:w-56"),
1559
+ style: g ? { width: za } : void 0,
1521
1560
  children: [/* @__PURE__ */ t(ie, {
1522
1561
  variant: "outlined",
1523
1562
  size: "sm",
@@ -1527,24 +1566,24 @@ function za({ variant: e = "box", fold: a = "auto", value: n, onValueChange: r,
1527
1566
  "aria-hidden": g || void 0,
1528
1567
  tabIndex: g ? -1 : void 0,
1529
1568
  onClick: () => h(!0),
1530
- className: p(Me, g ? "pointer-events-none invisible opacity-0" : "visible opacity-100", E && "@[36rem]:pointer-events-none @[36rem]:invisible @[36rem]:opacity-0"),
1531
- children: /* @__PURE__ */ t(Ee, {})
1569
+ className: p(De, g ? "pointer-events-none invisible opacity-0" : "visible opacity-100", E && "@[36rem]:pointer-events-none @[36rem]:invisible @[36rem]:opacity-0"),
1570
+ children: /* @__PURE__ */ t(Se, {})
1532
1571
  }), /* @__PURE__ */ t("div", {
1533
1572
  inert: !E && !g,
1534
- className: p("w-full min-w-0", Me, g ? "visible opacity-100" : "pointer-events-none invisible opacity-0", E && "@[36rem]:pointer-events-auto @[36rem]:visible @[36rem]:opacity-100"),
1535
- children: /* @__PURE__ */ v(le.Root, {
1573
+ className: p("w-full min-w-0", De, g ? "visible opacity-100" : "pointer-events-none invisible opacity-0", E && "@[36rem]:pointer-events-auto @[36rem]:visible @[36rem]:opacity-100"),
1574
+ children: /* @__PURE__ */ y(oe.Root, {
1536
1575
  size: "sm",
1537
1576
  className: "w-full",
1538
- children: [/* @__PURE__ */ t(le.Addon, { children: /* @__PURE__ */ t(Ee, {}) }), /* @__PURE__ */ t(le.Input, {
1577
+ children: [/* @__PURE__ */ t(oe.Addon, { children: /* @__PURE__ */ t(Se, {}) }), /* @__PURE__ */ t(oe.Input, {
1539
1578
  ref: b,
1540
1579
  type: "search",
1541
1580
  value: u.query,
1542
- onChange: (y) => u.setQuery(y.target.value),
1581
+ onChange: (v) => u.setQuery(v.target.value),
1543
1582
  onBlur: () => {
1544
1583
  u.query === "" && h(!1);
1545
1584
  },
1546
- onKeyDown: (y) => {
1547
- y.key === "Escape" && (y.preventDefault(), u.setQuery(""), h(!1), y.currentTarget.blur());
1585
+ onKeyDown: (v) => {
1586
+ v.key === "Escape" && (v.preventDefault(), u.setQuery(""), h(!1), v.currentTarget.blur());
1548
1587
  },
1549
1588
  placeholder: u.placeholder,
1550
1589
  "aria-label": u.label
@@ -1554,58 +1593,58 @@ function za({ variant: e = "box", fold: a = "auto", value: n, onValueChange: r,
1554
1593
  })
1555
1594
  });
1556
1595
  }
1557
- var gn = {
1558
- Root: Pt,
1559
- Aside: Ma,
1560
- Search: za,
1561
- Table: pt,
1562
- CondenseScope: Vt,
1563
- Breadcrumbs: et,
1564
- Crumb: tt,
1565
- Back: La,
1566
- Title: Kt,
1567
- Stack: Zt,
1568
- Header: ea,
1569
- HeaderAction: ta,
1570
- SectionTitle: aa,
1571
- Description: Ye,
1572
- TableCount: na,
1573
- SectionFooter: ra,
1574
- Card: ia,
1575
- Item: sa,
1576
- ItemPanel: la,
1577
- Callout: oa,
1578
- CalloutTitle: ca,
1579
- CalloutDescription: ua,
1580
- Onboard: da,
1581
- Step: ba,
1582
- Row: ya,
1583
- RowLink: Ba,
1584
- Value: va,
1585
- Alert: xa,
1586
- Footer: Sa,
1587
- Form: wa,
1588
- Saved: Na,
1589
- Fields: _a,
1590
- Inline: Ea,
1591
- Submit: Ca,
1592
- Reveal: _e
1596
+ var yn = {
1597
+ Root: It,
1598
+ Aside: Ha,
1599
+ Search: $a,
1600
+ Table: ft,
1601
+ CondenseScope: $t,
1602
+ Breadcrumbs: tt,
1603
+ Crumb: at,
1604
+ Back: Ma,
1605
+ Title: Qt,
1606
+ Stack: ta,
1607
+ Header: aa,
1608
+ HeaderAction: na,
1609
+ SectionTitle: ra,
1610
+ Description: Ue,
1611
+ TableCount: ia,
1612
+ SectionFooter: sa,
1613
+ Card: la,
1614
+ Item: oa,
1615
+ ItemPanel: ca,
1616
+ Callout: ua,
1617
+ CalloutTitle: da,
1618
+ CalloutDescription: pa,
1619
+ Onboard: fa,
1620
+ Step: va,
1621
+ Row: xa,
1622
+ RowLink: Da,
1623
+ Value: wa,
1624
+ Alert: Na,
1625
+ Footer: Ta,
1626
+ Form: Aa,
1627
+ Saved: _a,
1628
+ Fields: Ca,
1629
+ Inline: Sa,
1630
+ Submit: ka,
1631
+ Reveal: Ce
1593
1632
  };
1594
1633
  export {
1595
- Et as a,
1596
- gn as c,
1597
- $t as d,
1598
- ce as f,
1599
- _t as i,
1600
- xe as l,
1601
- fn as m,
1602
- Se as n,
1603
- Ct as o,
1604
- mn as p,
1634
+ Ct as a,
1635
+ yn as c,
1636
+ qt as d,
1637
+ de as f,
1638
+ Et as i,
1639
+ ne as l,
1640
+ hn as m,
1641
+ Te as n,
1642
+ St as o,
1643
+ gn as p,
1605
1644
  ze as r,
1606
- At as s,
1607
- hn as t,
1608
- Ie as u
1645
+ _t as s,
1646
+ bn as t,
1647
+ jt as u
1609
1648
  };
1610
1649
 
1611
- //# sourceMappingURL=basic-page-CVZT_zaH.js.map
1650
+ //# sourceMappingURL=basic-page-CMJuM5iA.js.map