@viglet/viglet-design-system 2026.3.17 → 2026.3.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/bento.es.js CHANGED
@@ -1,58 +1,58 @@
1
1
  "use client";
2
2
  import { t as e } from "./utils-Fk5jmzzb.js";
3
3
  import { a as t, c as n, d as r, g as i, o as a, p as o, u as s } from "./badge-locale-BwsfyQJT.js";
4
- import { B as c, C as l, D as u, F as d, H as f, I as p, J as m, L as h, M as g, N as _, P as v, R as y, S as b, T as x, V as S, Y as C, _ as w, b as T, d as ee, f as E, g as D, h as O, i as k, j as A, l as j, m as M, n as N, o as te, q as P, r as F, s as I, u as L, v as ne, w as re, y as ie } from "./user.context-TpXsFyGy.js";
4
+ import { $ as c, B as l, C as u, D as d, E as f, F as p, G as m, H as h, I as g, K as _, L as v, O as y, Q as b, R as x, S, V as C, W as w, Z as T, b as E, c as D, g as O, h as k, i as A, j, k as M, l as N, m as P, n as F, o as ee, p as te, r as I, s as L, u as ne, v as R, w as z, x as B, y as re, z as ie } from "./user.context-vCmnGlIb.js";
5
5
  import { r as ae, t as oe } from "./loading-provider-Dh7jdSol.js";
6
- import { Children as R, Fragment as z, isValidElement as se, useEffect as B, useId as ce, useMemo as le, useRef as V, useState as H, useSyncExternalStore as U } from "react";
7
- import { Fragment as W, jsx as G, jsxs as K } from "react/jsx-runtime";
8
- import { useTranslation as q } from "react-i18next";
9
- import { IconAdjustmentsHorizontal as ue, IconAlertTriangle as de, IconArrowBackUp as J, IconArrowDown as fe, IconArrowLeft as pe, IconArrowRight as me, IconArrowUp as he, IconArrowsSort as ge, IconBuildingCommunity as _e, IconBuildingSkyscraper as ve, IconChevronDown as ye, IconChevronLeft as be, IconChevronRight as Y, IconColumns3 as xe, IconDeviceFloppy as Se, IconDotsVertical as Ce, IconExternalLink as we, IconGripVertical as Te, IconHome as Ee, IconKeyboard as De, IconLayoutGrid as Oe, IconLogout as ke, IconPalette as Ae, IconPlus as je, IconRobot as Me, IconSearch as Ne, IconSparkles as Pe, IconTrash as Fe, IconUser as Ie, IconUserCircle as Le, IconUsers as Re, IconX as ze } from "@tabler/icons-react";
10
- import { Icon as Be } from "@iconify/react";
11
- import { useDefaultLayout as Ve } from "react-resizable-panels";
12
- import { Link as He, useInRouterContext as Ue, useLocation as We, useNavigate as Ge } from "react-router-dom";
13
- import { createCoreRowModel as Ke, createSortedRowModel as qe, rowSortingFeature as Je, useTable as Ye } from "@tanstack/react-table";
14
- import { DndContext as Xe, KeyboardSensor as Ze, PointerSensor as Qe, closestCenter as $e, useSensor as et, useSensors as tt } from "@dnd-kit/core";
15
- import { SortableContext as nt, arrayMove as rt, rectSortingStrategy as it, useSortable as at } from "@dnd-kit/sortable";
16
- import { CSS as ot } from "@dnd-kit/utilities";
6
+ import { Children as se, Fragment as ce, isValidElement as le, useCallback as ue, useEffect as V, useId as H, useLayoutEffect as de, useMemo as fe, useRef as U, useState as W, useSyncExternalStore as pe } from "react";
7
+ import { Fragment as G, jsx as K, jsxs as q } from "react/jsx-runtime";
8
+ import { useTranslation as J } from "react-i18next";
9
+ import { IconAdjustmentsHorizontal as Y, IconAlertTriangle as me, IconArrowBackUp as he, IconArrowDown as ge, IconArrowLeft as _e, IconArrowRight as X, IconArrowUp as ve, IconArrowsSort as ye, IconBuildingCommunity as be, IconBuildingSkyscraper as xe, IconChevronDown as Se, IconChevronLeft as Ce, IconChevronRight as we, IconColumns3 as Te, IconDeviceFloppy as Ee, IconDotsVertical as De, IconExternalLink as Oe, IconGripVertical as ke, IconHome as Ae, IconKeyboard as je, IconLayoutGrid as Me, IconList as Ne, IconLogout as Pe, IconPalette as Fe, IconPlus as Z, IconRobot as Ie, IconSearch as Le, IconSparkles as Re, IconTrash as ze, IconUser as Be, IconUserCircle as Ve, IconUsers as He, IconX as Ue } from "@tabler/icons-react";
10
+ import { Icon as We } from "@iconify/react";
11
+ import { useDefaultLayout as Ge } from "react-resizable-panels";
12
+ import { Link as Ke, useInRouterContext as qe, useLocation as Je, useNavigate as Ye } from "react-router-dom";
13
+ import { createCoreRowModel as Xe, createSortedRowModel as Ze, rowSortingFeature as Qe, useTable as $e } from "@tanstack/react-table";
14
+ import { DndContext as et, KeyboardSensor as tt, PointerSensor as nt, closestCenter as rt, useSensor as it, useSensors as at } from "@dnd-kit/core";
15
+ import { SortableContext as ot, arrayMove as st, rectSortingStrategy as ct, useSortable as lt } from "@dnd-kit/sortable";
16
+ import { CSS as ut } from "@dnd-kit/utilities";
17
17
  //#region src/bento/bento-actions-menu.tsx
18
- var st = {
18
+ var dt = {
19
19
  default: "",
20
20
  destructive: "bento-item-danger"
21
- }, ct = /* @__PURE__ */ new Set();
22
- function lt(e) {
23
- process.env.NODE_ENV === "production" || ct.has(e) || (ct.add(e), console.warn(`BentoActionsMenu: the action "${e}" has no id. Give it a stable name, such as "post.delete": it is rendered as data-action-id so a console verb can be matched to an agent verb, and it becomes required in the next release.`));
21
+ }, ft = /* @__PURE__ */ new Set();
22
+ function pt(e) {
23
+ process.env.NODE_ENV === "production" || ft.has(e) || (ft.add(e), console.warn(`BentoActionsMenu: the action "${e}" has no id. Give it a stable name, such as "post.delete": it is rendered as data-action-id so a console verb can be matched to an agent verb, and it becomes required in the next release.`));
24
24
  }
25
- function ut({ actions: e, triggerLabel: t }) {
26
- let { t: n } = q();
25
+ function mt({ actions: e, triggerLabel: t }) {
26
+ let { t: n } = J();
27
27
  if (e.length === 0) return null;
28
- for (let t of e) t.id || lt(t.label);
29
- return /* @__PURE__ */ K(_, { children: [/* @__PURE__ */ G(P, {
28
+ for (let t of e) t.id || pt(t.label);
29
+ return /* @__PURE__ */ q(v, { children: [/* @__PURE__ */ K(T, {
30
30
  asChild: !0,
31
- children: /* @__PURE__ */ G("button", {
31
+ children: /* @__PURE__ */ K("button", {
32
32
  type: "button",
33
33
  "aria-label": t ?? n("forms.formActions.moreActions", { defaultValue: "More actions" }),
34
34
  className: "bento-tile-clickable inline-flex size-(--vg-control-form) items-center justify-center rounded-full border border-border/60 bg-card/60 text-muted-foreground backdrop-blur transition-colors duration-200 hover:text-foreground",
35
- children: /* @__PURE__ */ G(Ce, { size: 18 })
35
+ children: /* @__PURE__ */ K(De, { size: 18 })
36
36
  })
37
- }), /* @__PURE__ */ G(d, {
37
+ }), /* @__PURE__ */ K(ie, {
38
38
  align: "end",
39
39
  sideOffset: 8,
40
40
  className: "bento-dropdown min-w-44 p-1.5",
41
41
  children: e.map((e) => {
42
- let t = e.icon, n = st[e.tone ?? "default"];
43
- return /* @__PURE__ */ K(h, {
42
+ let t = e.icon, n = dt[e.tone ?? "default"];
43
+ return /* @__PURE__ */ q(C, {
44
44
  "data-action-id": e.id,
45
45
  onSelect: e.onSelect,
46
46
  disabled: e.disabled,
47
47
  className: `bento-dropdown-item cursor-pointer gap-2 px-3 py-2 ${n}`,
48
- children: [/* @__PURE__ */ G(t, { size: 16 }), e.label]
48
+ children: [/* @__PURE__ */ K(t, { size: 16 }), e.label]
49
49
  }, e.id ?? e.label);
50
50
  })
51
51
  })] });
52
52
  }
53
53
  //#endregion
54
54
  //#region src/bento/bento-tones.ts
55
- var dt = {
55
+ var ht = {
56
56
  blue: "bento-tone-blue",
57
57
  indigo: "bento-tone-indigo",
58
58
  violet: "bento-tone-violet",
@@ -60,143 +60,194 @@ var dt = {
60
60
  amber: "bento-tone-amber",
61
61
  rose: "bento-tone-rose",
62
62
  slate: "bento-tone-slate"
63
- }, ft = Object.keys(dt);
64
- function pt(e) {
65
- return `bento-chip ${dt[e] ?? dt.slate}`;
63
+ }, gt = Object.keys(ht);
64
+ function _t(e) {
65
+ return `bento-chip ${ht[e] ?? ht.slate}`;
66
66
  }
67
67
  //#endregion
68
68
  //#region src/bento/bento-count-tile.tsx
69
- function mt({ to: e, icon: t, tone: n, label: r, count: i, span: a }) {
70
- let o = /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G("span", {
71
- className: `grid h-9 w-9 place-items-center rounded-2xl text-white shadow-md ${pt(n)}`,
72
- children: /* @__PURE__ */ G(t, { size: 18 })
73
- }), /* @__PURE__ */ K("div", { children: [/* @__PURE__ */ G("div", {
69
+ function vt({ to: e, icon: t, tone: n, label: r, count: i, span: a }) {
70
+ let o = /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K("span", {
71
+ className: `grid h-9 w-9 place-items-center rounded-2xl text-white shadow-md ${_t(n)}`,
72
+ children: /* @__PURE__ */ K(t, { size: 18 })
73
+ }), /* @__PURE__ */ q("div", { children: [/* @__PURE__ */ K("div", {
74
74
  className: "text-3xl font-semibold tabular-nums tracking-tight",
75
75
  children: i
76
- }), /* @__PURE__ */ G("div", {
76
+ }), /* @__PURE__ */ K("div", {
77
77
  className: "text-[11px] uppercase tracking-wider text-muted-foreground",
78
78
  children: r
79
79
  })] })] }), s = `bento-tile bento-glass group relative flex flex-col justify-between overflow-hidden p-4 ${a}${e ? " bento-tile-clickable" : ""}`;
80
- return e ? /* @__PURE__ */ G(He, {
80
+ return e ? /* @__PURE__ */ K(Ke, {
81
81
  to: e,
82
82
  className: s,
83
83
  children: o
84
- }) : /* @__PURE__ */ G("div", {
84
+ }) : /* @__PURE__ */ K("div", {
85
85
  className: s,
86
86
  children: o
87
87
  });
88
88
  }
89
89
  //#endregion
90
90
  //#region src/bento/bento-data-table.tsx
91
- var ht = 6, gt = {
92
- rowSortingFeature: Je,
93
- coreRowModel: Ke(),
94
- sortedRowModel: qe()
91
+ var yt = 6;
92
+ function bt(e) {
93
+ for (let t = e.parentElement; t && t !== document.body; t = t.parentElement) {
94
+ let { overflowY: e } = getComputedStyle(t);
95
+ if (e === "auto" || e === "scroll") return t;
96
+ }
97
+ return null;
98
+ }
99
+ function xt(e) {
100
+ if (e) {
101
+ let { top: t, bottom: n } = e.getBoundingClientRect();
102
+ return {
103
+ top: t,
104
+ bottom: n
105
+ };
106
+ }
107
+ return {
108
+ top: 0,
109
+ bottom: window.innerHeight
110
+ };
111
+ }
112
+ var St = {
113
+ rowSortingFeature: Qe,
114
+ coreRowModel: Xe(),
115
+ sortedRowModel: Ze()
95
116
  };
96
- function _t({ rows: t, getRowId: n, columns: r, label: i, getRowLabel: a, rowActions: o, selectionActions: s, selectedIds: c, onSelectionChange: l, selectionScope: u, layout: f, onLayoutChange: p, onRowOpen: h, rowHeight: g = 44, height: y = 480, empty: b }) {
97
- let { t: x } = q(), [S, w] = H([]), [T, ee] = H({ hidden: [] }), [E, D] = H(/* @__PURE__ */ new Set()), [O, k] = H(null), [A, j] = H(u), [M, N] = H(void 0);
98
- A !== u && (j(u), D(/* @__PURE__ */ new Set()), N(c), k(null));
99
- let te = le(() => new Set(c ?? []), [c]), F = E;
100
- c !== void 0 && (F = c === M ? /* @__PURE__ */ new Set() : te);
101
- let I = V(u);
102
- B(() => {
103
- I.current !== u && (I.current = u, l?.([]));
104
- }, [u, l]);
105
- let [L, ne] = H(0), [re, ie] = H(0), ae = V(null), oe = V(/* @__PURE__ */ new Map()), R = V(!1), z = (s?.length ?? 0) > 0, se = (e) => a?.(e) ?? n(e), ce = le(() => r.map((e) => ({
117
+ function Ct({ rows: t, getRowId: n, columns: r, label: i, getRowLabel: a, rowActions: o, selectionActions: s, selectedIds: l, onSelectionChange: u, selectionScope: d, layout: f, onLayoutChange: p, onRowOpen: m, rowHeight: h = 44, height: g, empty: _, toolbar: y }) {
118
+ let { t: S } = J(), [C, w] = W([]), [E, D] = W({ hidden: [] }), [O, k] = W(/* @__PURE__ */ new Set()), [A, j] = W(null), [M, N] = W(d), [P, F] = W(void 0);
119
+ M !== d && (N(d), k(/* @__PURE__ */ new Set()), F(l), j(null));
120
+ let ee = fe(() => new Set(l ?? []), [l]), te = O;
121
+ l !== void 0 && (te = l === P ? /* @__PURE__ */ new Set() : ee);
122
+ let I = U(d);
123
+ V(() => {
124
+ I.current !== d && (I.current = d, u?.([]));
125
+ }, [d, u]);
126
+ let [L, ne] = W(0), [R, z] = W(0), B = g === void 0, [re, ae] = W(() => ({
127
+ size: typeof window > "u" ? 0 : window.innerHeight,
128
+ port: typeof window > "u" ? 0 : window.innerHeight
129
+ })), oe = U(null), se = U(null), ce = U(/* @__PURE__ */ new Map()), le = U(!1), H = (s?.length ?? 0) > 0, pe = (e) => a?.(e) ?? n(e), G = fe(() => r.map((e) => ({
106
130
  id: e.id,
107
131
  accessorFn: (t) => e.sortValue?.(t) ?? null,
108
132
  enableSorting: e.sortValue !== void 0
109
- })), [r]), U = Ye({
110
- features: gt,
133
+ })), [r]), Y = $e({
134
+ features: St,
111
135
  data: t,
112
- columns: ce,
113
- state: { sorting: S },
136
+ columns: G,
137
+ state: { sorting: C },
114
138
  onSortingChange: w
115
- }).getRowModel().rows.map((e) => e.original), W = f ?? T, ue = r.filter((e) => e.hideable === !1 || !W.hidden.includes(e.id)), de = [
116
- z ? "2.75rem" : null,
117
- ...ue.map((e) => e.width ?? "minmax(8rem, 1fr)"),
139
+ }).getRowModel().rows.map((e) => e.original), me = f ?? E, he = r.filter((e) => e.hideable === !1 || !me.hidden.includes(e.id)), _e = [
140
+ H ? "2.75rem" : null,
141
+ ...he.map((e) => e.width ?? "minmax(8rem, 1fr)"),
118
142
  o?.length ? "3.25rem" : null
119
- ].filter(Boolean).join(" "), J = U.length, pe = Math.min(y, J * g), me = Math.max(1, Math.floor(pe / g)), _e = Math.max(0, Math.floor(re / g) - ht), ve = Math.min(J, Math.ceil((re + pe) / g) + ht), ye = Math.min(L, Math.max(0, J - 1));
120
- B(() => {
121
- R.current && (R.current = !1, oe.current.get(ye)?.focus());
122
- }, [ye, _e]);
123
- function be(e) {
124
- c === void 0 && D(e), l?.([...e]);
143
+ ].filter(Boolean).join(" "), X = Y.length, be = Math.min(B ? re.size : g, X * h), xe = Math.max(1, Math.floor((B ? re.port : be) / h)), Se = ue(() => {
144
+ let e = oe.current;
145
+ if (!e) return;
146
+ let t = e.getBoundingClientRect(), n = xt(bt(e)), r = Math.max(0, n.top - t.top);
147
+ z(r), ae({
148
+ size: Math.max(0, n.bottom - Math.max(t.top, n.top)),
149
+ port: n.bottom - n.top
150
+ });
151
+ }, []);
152
+ de(() => {
153
+ if (!B || !oe.current) return;
154
+ Se();
155
+ let e = bt(oe.current) ?? window;
156
+ return e.addEventListener("scroll", Se, { passive: !0 }), window.addEventListener("resize", Se), () => {
157
+ e.removeEventListener("scroll", Se), window.removeEventListener("resize", Se);
158
+ };
159
+ }, [
160
+ B,
161
+ Se,
162
+ X
163
+ ]);
164
+ let Ce = Math.max(0, Math.floor(R / h) - yt), we = Math.min(X, Math.ceil((R + be) / h) + yt), Ee = Math.min(L, Math.max(0, X - 1));
165
+ V(() => {
166
+ le.current && (le.current = !1, ce.current.get(Ee)?.focus());
167
+ }, [Ee, Ce]);
168
+ function De(e) {
169
+ l === void 0 && k(e), u?.([...e]);
125
170
  }
126
- function Y(e, t) {
171
+ function Oe(e, t) {
127
172
  let [r, i] = e <= t ? [e, t] : [t, e];
128
- be(new Set(U.slice(r, i + 1).map(n)));
173
+ De(new Set(Y.slice(r, i + 1).map(n)));
129
174
  }
130
- function Se(e) {
131
- let t = n(U[e]), r = new Set(F);
132
- r.has(t) ? r.delete(t) : r.add(t), be(r), k(e);
175
+ function ke(e) {
176
+ let t = n(Y[e]), r = new Set(te);
177
+ r.has(t) ? r.delete(t) : r.add(t), De(r), j(e);
133
178
  }
134
- function Ce(e, t) {
135
- let n = Math.max(0, Math.min(J - 1, e));
136
- if (t && z) {
137
- let e = O ?? ye;
138
- k(e), Y(e, n);
179
+ function Ae(e, t) {
180
+ let n = Math.max(0, Math.min(X - 1, e));
181
+ if (t && H) {
182
+ let e = A ?? Ee;
183
+ j(e), Oe(e, n);
139
184
  }
140
- let r = ae.current, i = n * g;
141
- if (r) {
185
+ let r = oe.current, i = n * h;
186
+ if (r && B) {
187
+ let e = bt(r), t = xt(e), n = Math.max(t.top, se.current?.getBoundingClientRect().bottom ?? t.top), a = r.getBoundingClientRect().top + i, o = 0;
188
+ a < n ? o = a - n : a + h > t.bottom && (o = a + h - t.bottom), o !== 0 && ((e ?? window).scrollBy({
189
+ top: o,
190
+ behavior: "instant"
191
+ }), Se());
192
+ } else if (r) {
142
193
  let e = r.scrollTop;
143
- i < e ? e = i : i + g > e + pe && (e = i + g - pe), e !== r.scrollTop && (r.scrollTop = e, ie(e));
194
+ i < e ? e = i : i + h > e + be && (e = i + h - be), e !== r.scrollTop && (r.scrollTop = e, z(e));
144
195
  }
145
- R.current = !0, ne(n);
196
+ le.current = !0, ne(n);
146
197
  }
147
- function we(e, t) {
198
+ function je(e, t) {
148
199
  if (e.target !== e.currentTarget) return;
149
200
  let r = e.shiftKey;
150
201
  switch (e.key) {
151
202
  case "ArrowDown":
152
- Ce(t + 1, r);
203
+ Ae(t + 1, r);
153
204
  break;
154
205
  case "ArrowUp":
155
- Ce(t - 1, r);
206
+ Ae(t - 1, r);
156
207
  break;
157
208
  case "PageDown":
158
- Ce(t + me, r);
209
+ Ae(t + xe, r);
159
210
  break;
160
211
  case "PageUp":
161
- Ce(t - me, r);
212
+ Ae(t - xe, r);
162
213
  break;
163
214
  case "Home":
164
- Ce(0, r);
215
+ Ae(0, r);
165
216
  break;
166
217
  case "End":
167
- Ce(J - 1, r);
218
+ Ae(X - 1, r);
168
219
  break;
169
220
  case " ":
170
- if (!z) return;
171
- Se(t);
221
+ if (!H) return;
222
+ ke(t);
172
223
  break;
173
224
  case "Enter":
174
- if (!h) return;
175
- h(U[t]);
225
+ if (!m) return;
226
+ m(Y[t]);
176
227
  break;
177
228
  case "Escape":
178
- if (!z || F.size === 0) return;
179
- be(/* @__PURE__ */ new Set()), k(null);
229
+ if (!H || te.size === 0) return;
230
+ De(/* @__PURE__ */ new Set()), j(null);
180
231
  break;
181
232
  case "a":
182
233
  case "A":
183
- if (!z || !(e.ctrlKey || e.metaKey)) return;
184
- be(new Set(U.map(n)));
234
+ if (!H || !(e.ctrlKey || e.metaKey)) return;
235
+ De(new Set(Y.map(n)));
185
236
  break;
186
237
  default: return;
187
238
  }
188
239
  e.preventDefault();
189
240
  }
190
- function Te(e, t) {
191
- if (!e.target.closest("button, a, input, [role='checkbox']") && (ne(t), z)) {
241
+ function Me(e, t) {
242
+ if (!e.target.closest("button, a, input, [role='checkbox']") && (ne(t), H)) {
192
243
  if (e.shiftKey) {
193
- let e = O ?? ye;
194
- k(e), Y(e, t);
195
- } else e.metaKey || e.ctrlKey ? Se(t) : (be(/* @__PURE__ */ new Set([n(U[t])])), k(t));
244
+ let e = A ?? Ee;
245
+ j(e), Oe(e, t);
246
+ } else e.metaKey || e.ctrlKey ? ke(t) : (De(/* @__PURE__ */ new Set([n(Y[t])])), j(t));
196
247
  }
197
248
  }
198
- function Ee(e) {
199
- let t = S.find((t) => t.id === e);
249
+ function Ne(e) {
250
+ let t = C.find((t) => t.id === e);
200
251
  t ? t.desc ? w([]) : w([{
201
252
  id: e,
202
253
  desc: !0
@@ -205,204 +256,221 @@ function _t({ rows: t, getRowId: n, columns: r, label: i, getRowLabel: a, rowAct
205
256
  desc: !1
206
257
  }]);
207
258
  }
208
- function De(e, t) {
209
- let n = { hidden: t ? [...W.hidden, e] : W.hidden.filter((t) => t !== e) };
210
- f === void 0 && ee(n), p?.(n);
259
+ function Pe(e, t) {
260
+ let n = { hidden: t ? [...me.hidden, e] : me.hidden.filter((t) => t !== e) };
261
+ f === void 0 && D(n), p?.(n);
211
262
  }
212
- let Oe = U.filter((e) => F.has(n(e))), ke = J > 0 && Oe.length === J, Ae = r.filter((e) => e.hideable !== !1);
213
- return /* @__PURE__ */ K("div", {
263
+ let Fe = r.filter((e) => e.hideable !== !1), Z = Y.filter((e) => te.has(n(e))), Ie = X > 0 && Z.length === X, Le = B && Z.length > 0, Re = U(null), ze = U(null);
264
+ return V(() => {
265
+ let e = Re.current, t = ze.current;
266
+ if (!e || !t || !Le || typeof ResizeObserver > "u") return;
267
+ let n = new ResizeObserver(() => e.style.setProperty("--bento-table-bar", `${t.offsetHeight}px`));
268
+ return n.observe(t), () => {
269
+ n.disconnect(), e.style.removeProperty("--bento-table-bar");
270
+ };
271
+ }, [Le]), /* @__PURE__ */ q("div", {
272
+ ref: Re,
214
273
  "data-slot": "bento-data-table",
215
- className: "bento-glass overflow-hidden rounded-2xl",
216
- children: [/* @__PURE__ */ K("div", {
217
- className: "flex min-h-12 flex-wrap items-center gap-2 border-b border-border/50 px-3 py-2",
274
+ className: "bento-glass overflow-clip rounded-2xl",
275
+ children: [/* @__PURE__ */ q("div", {
276
+ ref: ze,
277
+ "data-slot": "bento-data-table-bar",
278
+ className: e("flex min-h-12 flex-wrap items-center gap-2 border-b border-border/50 px-3 py-2", Le && "sticky top-(--bento-shell-header,0px) z-20 bg-card/95 backdrop-blur", y == null && Fe.length === 0 && Z.length === 0 && "sr-only"),
218
279
  children: [
219
- /* @__PURE__ */ G("span", {
280
+ /* @__PURE__ */ K("span", {
220
281
  "aria-live": "polite",
221
- className: "text-sm font-medium",
222
- children: Oe.length > 0 ? x("bento.table.selected", {
282
+ className: e("text-sm font-medium", Z.length === 0 && "sr-only"),
283
+ children: Z.length > 0 ? S("bento.table.selected", {
223
284
  defaultValue: "{{count}} selected",
224
- count: Oe.length
285
+ count: Z.length
225
286
  }) : ""
226
287
  }),
227
- Oe.length > 0 && /* @__PURE__ */ K("div", {
288
+ Z.length === 0 && y != null && /* @__PURE__ */ K("div", {
289
+ className: "flex min-w-0 flex-1 flex-wrap items-center gap-2",
290
+ children: y
291
+ }),
292
+ Z.length > 0 && /* @__PURE__ */ q("div", {
228
293
  role: "toolbar",
229
- "aria-label": x("bento.table.selectionActions", { defaultValue: "Actions on the selection" }),
294
+ "aria-label": S("bento.table.selectionActions", { defaultValue: "Actions on the selection" }),
230
295
  className: "flex flex-wrap items-center gap-2",
231
296
  children: [s?.map((t) => {
232
297
  let n = t.icon;
233
- return /* @__PURE__ */ K(C, {
298
+ return /* @__PURE__ */ q(c, {
234
299
  variant: "outline",
235
300
  size: "sm",
236
301
  className: e("gap-1.5", t.tone === "destructive" && "bento-item-danger"),
237
- onClick: () => t.onSelect(Oe),
238
- children: [/* @__PURE__ */ G(n, { size: 16 }), t.label]
302
+ onClick: () => t.onSelect(Z),
303
+ children: [/* @__PURE__ */ K(n, { size: 16 }), t.label]
239
304
  }, t.id);
240
- }), /* @__PURE__ */ G(C, {
305
+ }), /* @__PURE__ */ K(c, {
241
306
  variant: "ghost",
242
307
  size: "sm",
243
- onClick: () => be(/* @__PURE__ */ new Set()),
244
- children: x("bento.table.clearSelection", { defaultValue: "Clear selection" })
308
+ onClick: () => De(/* @__PURE__ */ new Set()),
309
+ children: S("bento.table.clearSelection", { defaultValue: "Clear selection" })
245
310
  })]
246
311
  }),
247
- Ae.length > 0 && /* @__PURE__ */ K(_, { children: [/* @__PURE__ */ G(P, {
312
+ Fe.length > 0 && /* @__PURE__ */ q(v, { children: [/* @__PURE__ */ K(T, {
248
313
  asChild: !0,
249
- children: /* @__PURE__ */ K(C, {
314
+ children: /* @__PURE__ */ q(c, {
250
315
  variant: "ghost",
251
316
  size: "sm",
252
317
  className: "ml-auto gap-1.5",
253
- children: [/* @__PURE__ */ G(xe, {
318
+ children: [/* @__PURE__ */ K(Te, {
254
319
  size: 16,
255
320
  "aria-hidden": "true"
256
- }), x("bento.table.columns", { defaultValue: "Columns" })]
321
+ }), S("bento.table.columns", { defaultValue: "Columns" })]
257
322
  })
258
- }), /* @__PURE__ */ G(d, {
323
+ }), /* @__PURE__ */ K(ie, {
259
324
  align: "end",
260
325
  className: "bento-dropdown min-w-44 p-1.5",
261
- children: Ae.map((e) => /* @__PURE__ */ G(v, {
262
- checked: !W.hidden.includes(e.id),
263
- onCheckedChange: (t) => De(e.id, t !== !0),
326
+ children: Fe.map((e) => /* @__PURE__ */ K(x, {
327
+ checked: !me.hidden.includes(e.id),
328
+ onCheckedChange: (t) => Pe(e.id, t !== !0),
264
329
  onSelect: (e) => e.preventDefault(),
265
330
  children: e.header
266
331
  }, e.id))
267
332
  })] })
268
333
  ]
269
- }), /* @__PURE__ */ K("div", {
334
+ }), /* @__PURE__ */ q("div", {
270
335
  role: "grid",
271
336
  "aria-label": i,
272
- "aria-rowcount": J + 1,
273
- "aria-colcount": ue.length + +!!z + +!!o?.length,
274
- "aria-multiselectable": z ? "true" : void 0,
275
- children: [/* @__PURE__ */ G("div", {
337
+ "aria-rowcount": X + 1,
338
+ "aria-colcount": he.length + +!!H + +!!o?.length,
339
+ "aria-multiselectable": H ? "true" : void 0,
340
+ children: [/* @__PURE__ */ K("div", {
276
341
  role: "rowgroup",
277
- children: /* @__PURE__ */ K("div", {
342
+ ref: se,
343
+ className: e(B && "sticky top-[calc(var(--bento-shell-header,0px)+var(--bento-table-bar,0px))] z-10 bg-card/95 backdrop-blur"),
344
+ children: /* @__PURE__ */ q("div", {
278
345
  role: "row",
279
346
  "aria-rowindex": 1,
280
347
  className: "grid items-center border-b border-border/50 px-1 text-xs font-medium text-muted-foreground",
281
348
  style: {
282
- gridTemplateColumns: de,
283
- minHeight: g
349
+ gridTemplateColumns: _e,
350
+ minHeight: h
284
351
  },
285
352
  children: [
286
- z && /* @__PURE__ */ G("div", {
353
+ H && /* @__PURE__ */ K("div", {
287
354
  role: "columnheader",
288
355
  className: "grid place-items-center",
289
- children: /* @__PURE__ */ G(m, {
290
- "aria-label": x("bento.table.selectAll", { defaultValue: "Select all rows" }),
291
- checked: ke ? !0 : Oe.length > 0 && "indeterminate",
292
- onCheckedChange: () => be(ke ? /* @__PURE__ */ new Set() : new Set(U.map(n)))
356
+ children: /* @__PURE__ */ K(b, {
357
+ "aria-label": S("bento.table.selectAll", { defaultValue: "Select all rows" }),
358
+ checked: Ie ? !0 : Z.length > 0 && "indeterminate",
359
+ onCheckedChange: () => De(Ie ? /* @__PURE__ */ new Set() : new Set(Y.map(n)))
293
360
  })
294
361
  }),
295
- ue.map((e) => {
296
- let t = S.find((t) => t.id === e.id), n = t ? t.desc ? "descending" : "ascending" : "none";
297
- return /* @__PURE__ */ G("div", {
362
+ he.map((e) => {
363
+ let t = C.find((t) => t.id === e.id), n = t ? t.desc ? "descending" : "ascending" : "none";
364
+ return /* @__PURE__ */ K("div", {
298
365
  role: "columnheader",
299
366
  "aria-sort": e.sortValue ? n : void 0,
300
367
  className: "min-w-0 px-2",
301
- children: e.sortValue ? /* @__PURE__ */ K("button", {
368
+ children: e.sortValue ? /* @__PURE__ */ q("button", {
302
369
  type: "button",
303
- onClick: () => Ee(e.id),
370
+ "data-look": "text",
371
+ onClick: () => Ne(e.id),
304
372
  className: "inline-flex max-w-full items-center gap-1 rounded-md py-1 hover:text-foreground focus-visible:outline-2 focus-visible:outline-ring",
305
373
  children: [
306
- /* @__PURE__ */ G("span", {
374
+ /* @__PURE__ */ K("span", {
307
375
  className: "truncate",
308
376
  children: e.header
309
377
  }),
310
- n === "ascending" && /* @__PURE__ */ G(he, {
378
+ n === "ascending" && /* @__PURE__ */ K(ve, {
311
379
  size: 14,
312
380
  "aria-hidden": "true"
313
381
  }),
314
- n === "descending" && /* @__PURE__ */ G(fe, {
382
+ n === "descending" && /* @__PURE__ */ K(ge, {
315
383
  size: 14,
316
384
  "aria-hidden": "true"
317
385
  }),
318
- n === "none" && /* @__PURE__ */ G(ge, {
386
+ n === "none" && /* @__PURE__ */ K(ye, {
319
387
  size: 14,
320
388
  "aria-hidden": "true",
321
389
  className: "opacity-40"
322
390
  })
323
391
  ]
324
- }) : /* @__PURE__ */ G("span", {
392
+ }) : /* @__PURE__ */ K("span", {
325
393
  className: "block truncate py-1",
326
394
  children: e.header
327
395
  })
328
396
  }, e.id);
329
397
  }),
330
- o?.length ? /* @__PURE__ */ G("div", {
398
+ o?.length ? /* @__PURE__ */ K("div", {
331
399
  role: "columnheader",
332
400
  className: "px-2",
333
- children: /* @__PURE__ */ G("span", {
401
+ children: /* @__PURE__ */ K("span", {
334
402
  className: "sr-only",
335
- children: x("bento.table.actions", { defaultValue: "Actions" })
403
+ children: S("bento.table.actions", { defaultValue: "Actions" })
336
404
  })
337
405
  }) : null
338
406
  ]
339
407
  })
340
- }), J === 0 ? /* @__PURE__ */ G("div", {
408
+ }), X === 0 ? /* @__PURE__ */ K("div", {
341
409
  role: "rowgroup",
342
- children: /* @__PURE__ */ G("div", {
410
+ children: /* @__PURE__ */ K("div", {
343
411
  role: "row",
344
412
  "aria-rowindex": 2,
345
- children: /* @__PURE__ */ G("div", {
413
+ children: /* @__PURE__ */ K("div", {
346
414
  role: "gridcell",
347
415
  className: "px-4 py-10 text-center text-sm text-muted-foreground",
348
- children: b ?? x("bento.table.empty", { defaultValue: "Nothing to show" })
416
+ children: _ ?? S("bento.table.empty", { defaultValue: "Nothing to show" })
349
417
  })
350
418
  })
351
- }) : /* @__PURE__ */ G("div", {
419
+ }) : /* @__PURE__ */ K("div", {
352
420
  role: "rowgroup",
353
- ref: ae,
354
- onScroll: (e) => ie(e.currentTarget.scrollTop),
355
- className: "relative overflow-y-auto",
356
- style: { height: pe },
357
- children: /* @__PURE__ */ G("div", {
358
- style: { height: J * g },
421
+ ref: oe,
422
+ onScroll: B ? void 0 : (e) => z(e.currentTarget.scrollTop),
423
+ className: e("relative", !B && "overflow-y-auto"),
424
+ style: B ? void 0 : { height: be },
425
+ children: /* @__PURE__ */ K("div", {
426
+ style: { height: X * h },
359
427
  className: "relative",
360
- children: U.slice(_e, ve).map((t, r) => {
361
- let i = _e + r, a = n(t), s = F.has(a), c = se(t);
362
- return /* @__PURE__ */ K("div", {
428
+ children: Y.slice(Ce, we).map((t, r) => {
429
+ let i = Ce + r, a = n(t), s = te.has(a), c = pe(t);
430
+ return /* @__PURE__ */ q("div", {
363
431
  ref: (e) => {
364
- e ? oe.current.set(i, e) : oe.current.delete(i);
432
+ e ? ce.current.set(i, e) : ce.current.delete(i);
365
433
  },
366
434
  role: "row",
367
435
  "aria-rowindex": i + 2,
368
- "aria-selected": z ? s ? "true" : "false" : void 0,
369
- tabIndex: i === ye ? 0 : -1,
370
- onKeyDown: (e) => we(e, i),
371
- onClick: (e) => Te(e, i),
372
- onDoubleClick: () => h?.(t),
436
+ "aria-selected": H ? s ? "true" : "false" : void 0,
437
+ tabIndex: i === Ee ? 0 : -1,
438
+ onKeyDown: (e) => je(e, i),
439
+ onClick: (e) => Me(e, i),
440
+ onDoubleClick: () => m?.(t),
373
441
  onFocus: (e) => {
374
442
  e.target === e.currentTarget && ne(i);
375
443
  },
376
444
  className: e("absolute inset-x-0 grid items-center border-b border-border/30 px-1 text-sm outline-none transition-colors", "hover:bg-muted/40 focus-visible:bg-muted/60 focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring", s && "bg-primary/10 hover:bg-primary/15"),
377
445
  style: {
378
- top: i * g,
379
- height: g,
380
- gridTemplateColumns: de
446
+ top: i * h,
447
+ height: h,
448
+ gridTemplateColumns: _e
381
449
  },
382
450
  children: [
383
- z && /* @__PURE__ */ G("div", {
451
+ H && /* @__PURE__ */ K("div", {
384
452
  role: "gridcell",
385
453
  className: "grid place-items-center",
386
- children: /* @__PURE__ */ G(m, {
454
+ children: /* @__PURE__ */ K(b, {
387
455
  tabIndex: -1,
388
- "aria-label": x("bento.table.selectRow", {
456
+ "aria-label": S("bento.table.selectRow", {
389
457
  defaultValue: "Select {{row}}",
390
458
  row: c
391
459
  }),
392
460
  checked: s,
393
- onCheckedChange: () => Se(i)
461
+ onCheckedChange: () => ke(i)
394
462
  })
395
463
  }),
396
- ue.map((e) => /* @__PURE__ */ G("div", {
464
+ he.map((e) => /* @__PURE__ */ K("div", {
397
465
  role: "gridcell",
398
466
  className: "min-w-0 truncate px-2",
399
467
  children: e.cell(t)
400
468
  }, e.id)),
401
- o?.length ? /* @__PURE__ */ G("div", {
469
+ o?.length ? /* @__PURE__ */ K("div", {
402
470
  role: "gridcell",
403
471
  className: "grid place-items-center",
404
- children: /* @__PURE__ */ G(ut, {
405
- triggerLabel: x("bento.table.rowActions", {
472
+ children: /* @__PURE__ */ K(mt, {
473
+ triggerLabel: S("bento.table.rowActions", {
406
474
  defaultValue: "Actions for {{row}}",
407
475
  row: c
408
476
  }),
@@ -425,24 +493,24 @@ function _t({ rows: t, getRowId: n, columns: r, label: i, getRowLabel: a, rowAct
425
493
  }
426
494
  //#endregion
427
495
  //#region src/bento/bento-empty-state.tsx
428
- function vt({ icon: t = Pe, title: n, description: r, action: i, align: a = "center", titleLevel: o = 2, className: s }) {
496
+ function wt({ icon: t = Re, title: n, description: r, action: i, align: a = "center", titleLevel: o = 2, className: s }) {
429
497
  let c = a === "center", l = `h${o}`;
430
- return /* @__PURE__ */ K("div", {
498
+ return /* @__PURE__ */ q("div", {
431
499
  className: e("bento-tile bento-glass flex flex-col gap-3 rounded-3xl p-8", c ? "items-center text-center" : "items-start text-left", s),
432
500
  children: [
433
- /* @__PURE__ */ G("span", {
501
+ /* @__PURE__ */ K("span", {
434
502
  className: "bento-well grid h-12 w-12 place-items-center rounded-2xl",
435
- children: /* @__PURE__ */ G(t, { size: 24 })
503
+ children: /* @__PURE__ */ K(t, { size: 24 })
436
504
  }),
437
- /* @__PURE__ */ G(l, {
505
+ /* @__PURE__ */ K(l, {
438
506
  className: "m-0 text-lg font-semibold tracking-tight",
439
507
  children: n
440
508
  }),
441
- r && /* @__PURE__ */ G("p", {
509
+ r && /* @__PURE__ */ K("p", {
442
510
  className: e("max-w-md text-sm text-muted-foreground", c && "mx-auto"),
443
511
  children: r
444
512
  }),
445
- i && /* @__PURE__ */ G("div", {
513
+ i && /* @__PURE__ */ K("div", {
446
514
  className: e("mt-1", c && "mx-auto"),
447
515
  children: i
448
516
  })
@@ -451,31 +519,31 @@ function vt({ icon: t = Pe, title: n, description: r, action: i, align: a = "cen
451
519
  }
452
520
  //#endregion
453
521
  //#region src/bento/bento-trail.tsx
454
- var yt = 4;
455
- function bt({ steps: e }) {
456
- let { t } = q(), n = e.length > yt, r = (t) => n && t > 0 && t < e.length - 2;
457
- return /* @__PURE__ */ G("nav", {
522
+ var Tt = 4;
523
+ function Et({ steps: e }) {
524
+ let { t } = J(), n = e.length > Tt, r = (t) => n && t > 0 && t < e.length - 2;
525
+ return /* @__PURE__ */ K("nav", {
458
526
  "aria-label": t("bento.trail.label", { defaultValue: "Location" }),
459
527
  "data-slot": "bento-trail",
460
- children: /* @__PURE__ */ G("ol", {
528
+ children: /* @__PURE__ */ K("ol", {
461
529
  className: "flex min-w-0 flex-wrap items-center gap-1",
462
- children: e.map((e, t) => /* @__PURE__ */ K("li", {
530
+ children: e.map((e, t) => /* @__PURE__ */ q("li", {
463
531
  className: r(t) ? "sr-only" : "inline-flex min-w-0 items-center gap-1",
464
532
  children: [
465
- t > 0 && !r(t) && /* @__PURE__ */ G(Y, {
533
+ t > 0 && !r(t) && /* @__PURE__ */ K(we, {
466
534
  size: 12,
467
535
  "aria-hidden": !0,
468
536
  className: "shrink-0 opacity-60"
469
537
  }),
470
- /* @__PURE__ */ G(He, {
538
+ /* @__PURE__ */ K(Ke, {
471
539
  to: e.to,
472
540
  className: "max-w-[16ch] truncate hover:text-foreground",
473
541
  children: e.label
474
542
  }),
475
- n && t === 0 && /* @__PURE__ */ K("span", {
543
+ n && t === 0 && /* @__PURE__ */ q("span", {
476
544
  "aria-hidden": !0,
477
545
  className: "inline-flex items-center gap-1",
478
- children: [/* @__PURE__ */ G(Y, {
546
+ children: [/* @__PURE__ */ K(we, {
479
547
  size: 12,
480
548
  className: "shrink-0 opacity-60"
481
549
  }), "…"]
@@ -487,54 +555,54 @@ function bt({ steps: e }) {
487
555
  }
488
556
  //#endregion
489
557
  //#region src/bento/bento-hero.tsx
490
- function xt({ to: e, children: t }) {
491
- return /* @__PURE__ */ K(He, {
558
+ function Dt({ to: e, children: t }) {
559
+ return /* @__PURE__ */ q(Ke, {
492
560
  to: e,
493
561
  className: "inline-flex items-center gap-1 hover:text-foreground",
494
- children: [/* @__PURE__ */ G(pe, {
562
+ children: [/* @__PURE__ */ K(_e, {
495
563
  size: 14,
496
564
  "aria-hidden": !0
497
565
  }), t]
498
566
  });
499
567
  }
500
- function St(e, t, n) {
501
- return e && e.length > 1 ? /* @__PURE__ */ G(bt, { steps: e }) : e && e.length === 1 ? /* @__PURE__ */ G(xt, {
568
+ function Ot(e, t, n) {
569
+ return e && e.length > 1 ? /* @__PURE__ */ K(Et, { steps: e }) : e && e.length === 1 ? /* @__PURE__ */ K(Dt, {
502
570
  to: e[0].to,
503
571
  children: e[0].label
504
- }) : t == null ? null : /* @__PURE__ */ G(xt, {
572
+ }) : t == null ? null : /* @__PURE__ */ K(Dt, {
505
573
  to: t,
506
574
  children: n
507
575
  });
508
576
  }
509
- function Ct({ eyebrow: e, backTo: t, backLabel: n, trail: r, title: i, subtitle: a, leading: o, trailing: s }) {
510
- let c = e ?? St(r, t, n);
511
- return /* @__PURE__ */ G("header", {
577
+ function kt({ eyebrow: e, backTo: t, backLabel: n, trail: r, title: i, subtitle: a, leading: o, trailing: s }) {
578
+ let c = e ?? Ot(r, t, n);
579
+ return /* @__PURE__ */ K("header", {
512
580
  className: "bento-shell-header mb-6 flex flex-col items-start gap-3 md:mb-10",
513
- children: /* @__PURE__ */ K("div", {
581
+ children: /* @__PURE__ */ q("div", {
514
582
  className: "flex w-full items-start gap-4",
515
583
  children: [
516
- o && /* @__PURE__ */ G("div", {
584
+ o && /* @__PURE__ */ K("div", {
517
585
  className: "shrink-0",
518
586
  children: o
519
587
  }),
520
- /* @__PURE__ */ K("div", {
588
+ /* @__PURE__ */ q("div", {
521
589
  className: "flex flex-1 flex-col gap-1",
522
590
  children: [
523
- c && /* @__PURE__ */ G("span", {
591
+ c && /* @__PURE__ */ K("span", {
524
592
  className: "text-xs uppercase tracking-[0.18em] text-muted-foreground",
525
593
  children: c
526
594
  }),
527
- /* @__PURE__ */ G("h1", {
595
+ /* @__PURE__ */ K("h1", {
528
596
  className: "text-2xl font-semibold tracking-tight md:text-3xl",
529
597
  children: i
530
598
  }),
531
- a && /* @__PURE__ */ G("p", {
599
+ a && /* @__PURE__ */ K("p", {
532
600
  className: "max-w-2xl text-sm text-muted-foreground",
533
601
  children: a
534
602
  })
535
603
  ]
536
604
  }),
537
- s && /* @__PURE__ */ G("div", {
605
+ s && /* @__PURE__ */ K("div", {
538
606
  className: "ml-auto flex shrink-0 items-center gap-2",
539
607
  children: s
540
608
  })
@@ -544,31 +612,31 @@ function Ct({ eyebrow: e, backTo: t, backLabel: n, trail: r, title: i, subtitle:
544
612
  }
545
613
  //#endregion
546
614
  //#region src/bento/bento-hero-icon-picker.tsx
547
- function wt({ value: e, onChange: t, onClear: n, defaultIcon: r, tone: i, title: a, description: o, readOnly: s = !1 }) {
548
- let { t: c } = q(), [l, u] = H(!1);
549
- return s ? /* @__PURE__ */ G("span", {
550
- className: `grid h-12 w-12 place-items-center rounded-2xl ${pt(i)} text-white shadow-md`,
551
- children: e ? /* @__PURE__ */ G(Be, {
615
+ function At({ value: e, onChange: t, onClear: n, defaultIcon: r, tone: i, title: a, description: o, readOnly: s = !1 }) {
616
+ let { t: c } = J(), [l, u] = W(!1);
617
+ return s ? /* @__PURE__ */ K("span", {
618
+ className: `grid h-12 w-12 place-items-center rounded-2xl ${_t(i)} text-white shadow-md`,
619
+ children: e ? /* @__PURE__ */ K(We, {
552
620
  icon: e,
553
621
  className: "size-6 text-white"
554
- }) : /* @__PURE__ */ G(r, { size: 24 })
555
- }) : /* @__PURE__ */ K("div", {
622
+ }) : /* @__PURE__ */ K(r, { size: 24 })
623
+ }) : /* @__PURE__ */ q("div", {
556
624
  className: "group relative",
557
625
  children: [
558
- /* @__PURE__ */ K("button", {
626
+ /* @__PURE__ */ q("button", {
559
627
  type: "button",
560
628
  onClick: () => u(!0),
561
629
  "aria-label": c("forms.iconPicker.chooseAnIcon"),
562
- className: `group/icon relative grid h-12 w-12 cursor-pointer place-items-center overflow-hidden rounded-2xl ${pt(i)} text-white shadow-md outline-none transition-all duration-300 ease-[cubic-bezier(0.32,0.72,0,1)] hover:scale-105 focus-visible:ring-2 focus-visible:ring-ring active:scale-95`,
563
- children: [e ? /* @__PURE__ */ G(Be, {
630
+ className: `group/icon relative grid h-12 w-12 cursor-pointer place-items-center overflow-hidden rounded-2xl ${_t(i)} text-white shadow-md outline-none transition-all duration-300 ease-[cubic-bezier(0.32,0.72,0,1)] hover:scale-105 focus-visible:ring-2 focus-visible:ring-ring active:scale-95`,
631
+ children: [e ? /* @__PURE__ */ K(We, {
564
632
  icon: e,
565
633
  className: "size-6 text-white"
566
- }) : /* @__PURE__ */ G(r, { size: 24 }), /* @__PURE__ */ G("span", {
634
+ }) : /* @__PURE__ */ K(r, { size: 24 }), /* @__PURE__ */ K("span", {
567
635
  className: "pointer-events-none absolute inset-0 grid place-items-center bg-black/40 opacity-0 transition-opacity duration-200 group-hover/icon:opacity-100",
568
- children: /* @__PURE__ */ G(Ae, { className: "size-5 text-white" })
636
+ children: /* @__PURE__ */ K(Fe, { className: "size-5 text-white" })
569
637
  })]
570
638
  }),
571
- e && n && /* @__PURE__ */ G("button", {
639
+ e && n && /* @__PURE__ */ K("button", {
572
640
  type: "button",
573
641
  onClick: (e) => {
574
642
  e.stopPropagation(), n();
@@ -576,9 +644,9 @@ function wt({ value: e, onChange: t, onClear: n, defaultIcon: r, tone: i, title:
576
644
  "aria-label": c("forms.common.remove"),
577
645
  title: c("forms.common.remove"),
578
646
  className: "absolute -right-1.5 -top-1.5 grid h-5 w-5 cursor-pointer place-items-center rounded-full border border-border/60 bg-card/90 text-foreground opacity-0 shadow-md backdrop-blur transition-opacity duration-200 bento-clear focus-visible:opacity-100 group-hover:opacity-100",
579
- children: /* @__PURE__ */ G(ze, { size: 12 })
647
+ children: /* @__PURE__ */ K(Ue, { size: 12 })
580
648
  }),
581
- /* @__PURE__ */ G(g, {
649
+ /* @__PURE__ */ K(g, {
582
650
  open: l,
583
651
  onOpenChange: u,
584
652
  value: e,
@@ -592,9 +660,9 @@ function wt({ value: e, onChange: t, onClear: n, defaultIcon: r, tone: i, title:
592
660
  }
593
661
  //#endregion
594
662
  //#region src/bento/bento-inline-edit.tsx
595
- function Tt({ value: n, onSave: r, multiline: i = !1, placeholder: a, className: o, ariaLabel: s, autoFocus: c = !1, readOnly: l = !1, commitOnChange: u = !1 }) {
596
- let { t: d } = q(), [f, p] = H(c), [m, h] = H(n), [g, _] = H(!1), v = V(null), y = V(null), b = V(!1), x = V(!1), [S, C] = H(n);
597
- !f && n !== S && (C(n), h(n)), B(() => {
663
+ function jt({ value: n, onSave: r, multiline: i = !1, placeholder: a, className: o, ariaLabel: s, autoFocus: c = !1, readOnly: l = !1, commitOnChange: u = !1 }) {
664
+ let { t: d } = J(), [f, p] = W(c), [m, h] = W(n), [g, _] = W(!1), v = U(null), y = U(null), b = U(!1), x = U(!1), [S, C] = W(n);
665
+ !f && n !== S && (C(n), h(n)), V(() => {
598
666
  f && v.current ? (v.current.focus(), v.current.select()) : !f && x.current && (x.current = !1, y.current?.focus());
599
667
  }, [f]);
600
668
  function w() {
@@ -620,86 +688,87 @@ function Tt({ value: n, onSave: r, multiline: i = !1, placeholder: a, className:
620
688
  b.current = !1, _(!1), w();
621
689
  }
622
690
  }
623
- function ee() {
691
+ function E() {
624
692
  h(n), w();
625
693
  }
626
- function E(e) {
694
+ function D(e) {
627
695
  h(e), u && r(e);
628
696
  }
629
- let D = !n;
630
- if (l) return /* @__PURE__ */ G("span", {
697
+ let O = !n;
698
+ if (l) return /* @__PURE__ */ K("span", {
631
699
  className: e("block w-full", o),
632
700
  "aria-label": s,
633
- children: n || /* @__PURE__ */ G("span", {
701
+ children: n || /* @__PURE__ */ K("span", {
634
702
  className: "text-muted-foreground",
635
703
  children: a ?? "—"
636
704
  })
637
705
  });
638
- let O = "w-full bg-transparent outline-none border-b transition-colors duration-200", k = e(O, "cursor-text rounded-sm", D ? "border-dashed border-border/70 hover:border-foreground/40" : "border-transparent hover:border-border/60 focus-visible:border-border/80"), A = e(O, "bento-editing");
639
- if (!f) return /* @__PURE__ */ G("button", {
706
+ let k = "w-full bg-transparent outline-none border-b transition-colors duration-200", A = e(k, "cursor-text rounded-sm", O ? "border-dashed border-border/70 hover:border-foreground/40" : "border-transparent hover:border-border/60 focus-visible:border-border/80"), j = e(k, "bento-editing");
707
+ if (!f) return /* @__PURE__ */ K("button", {
640
708
  ref: y,
641
709
  type: "button",
710
+ "data-look": "text",
642
711
  onClick: () => p(!0),
643
- className: e(k, "text-left", o),
712
+ className: e(A, "text-left", o),
644
713
  "aria-label": s ?? d("forms.formActions.edit"),
645
- children: n || /* @__PURE__ */ G("span", {
714
+ children: n || /* @__PURE__ */ K("span", {
646
715
  className: "text-muted-foreground",
647
716
  children: a ?? "—"
648
717
  })
649
718
  });
650
- function j(e) {
719
+ function M(e) {
651
720
  if (e.key === "Escape") {
652
- e.preventDefault(), ee();
721
+ e.preventDefault(), E();
653
722
  return;
654
723
  }
655
724
  e.key === "Enter" && (!i || e.metaKey || e.ctrlKey) && (e.preventDefault(), T());
656
725
  }
657
- return i ? /* @__PURE__ */ G("textarea", {
726
+ return i ? /* @__PURE__ */ K("textarea", {
658
727
  ref: v,
659
728
  value: m,
660
- onChange: (e) => E(e.target.value),
729
+ onChange: (e) => D(e.target.value),
661
730
  onBlur: T,
662
- onKeyDown: j,
731
+ onKeyDown: M,
663
732
  placeholder: a,
664
733
  "aria-label": s,
665
734
  "aria-busy": g || void 0,
666
735
  rows: 3,
667
- className: e(A, "resize-none py-0.5 leading-snug", o)
668
- }) : /* @__PURE__ */ G(t, {
736
+ className: e(j, "resize-none py-0.5 leading-snug", o)
737
+ }) : /* @__PURE__ */ K(t, {
669
738
  ref: v,
670
739
  value: m,
671
- onChange: (e) => E(e.target.value),
740
+ onChange: (e) => D(e.target.value),
672
741
  onBlur: T,
673
- onKeyDown: j,
742
+ onKeyDown: M,
674
743
  placeholder: a,
675
744
  "aria-label": s,
676
745
  "aria-busy": g || void 0,
677
- className: e(A, "h-auto px-0 py-0 shadow-none focus-visible:ring-0", o)
746
+ className: e(j, "h-auto px-0 py-0 shadow-none focus-visible:ring-0", o)
678
747
  });
679
748
  }
680
749
  //#endregion
681
750
  //#region src/bento/bento-status-marker.tsx
682
- var Et = [
751
+ var Mt = [
683
752
  "published",
684
753
  "draft",
685
754
  "scheduled",
686
755
  "changed",
687
756
  "archived"
688
757
  ];
689
- function Dt({ titleMissing: t, dirty: n, state: r, className: i }) {
690
- let { t: a } = q();
758
+ function Nt({ titleMissing: t, dirty: n, state: r, className: i }) {
759
+ let { t: a } = J();
691
760
  if (!t && !n && !r) return null;
692
761
  let o = "inline-flex items-center gap-1 rounded-full border px-2 py-0.5 text-[10px] font-medium normal-case leading-none tracking-normal";
693
- return t ? /* @__PURE__ */ K("span", {
762
+ return t ? /* @__PURE__ */ q("span", {
694
763
  className: e(o, "bento-status bento-status-error", i),
695
- children: [/* @__PURE__ */ G(de, { className: "size-3" }), a("bento.saveBar.titleRequired", { defaultValue: "Title required" })]
696
- }) : n ? /* @__PURE__ */ K("span", {
764
+ children: [/* @__PURE__ */ K(me, { className: "size-3" }), a("bento.saveBar.titleRequired", { defaultValue: "Title required" })]
765
+ }) : n ? /* @__PURE__ */ q("span", {
697
766
  className: e(o, "bento-status bento-status-warn", i),
698
- children: [/* @__PURE__ */ G("span", { className: "h-1.5 w-1.5 rounded-full bento-status-dot bento-pulse" }), a("bento.saveBar.unsaved", { defaultValue: "Unsaved changes" })]
699
- }) : /* @__PURE__ */ K("span", {
767
+ children: [/* @__PURE__ */ K("span", { className: "h-1.5 w-1.5 rounded-full bento-status-dot bento-pulse" }), a("bento.saveBar.unsaved", { defaultValue: "Unsaved changes" })]
768
+ }) : /* @__PURE__ */ q("span", {
700
769
  "data-state": r,
701
770
  className: e("inline-flex items-center gap-1.5 text-xs font-normal normal-case leading-none tracking-normal", r === "archived" ? "text-muted-foreground" : "text-foreground/80", `bento-state-${r}`, i),
702
- children: [/* @__PURE__ */ G("span", {
771
+ children: [/* @__PURE__ */ K("span", {
703
772
  "aria-hidden": !0,
704
773
  className: "h-1.5 w-1.5 shrink-0 rounded-full bento-state-dot"
705
774
  }), a(`bento.state.${r}`)]
@@ -707,8 +776,8 @@ function Dt({ titleMissing: t, dirty: n, state: r, className: i }) {
707
776
  }
708
777
  //#endregion
709
778
  //#region src/bento/bento-scroll-fade.ts
710
- function Ot(e) {
711
- B(() => {
779
+ function Pt(e) {
780
+ V(() => {
712
781
  let t = e.current;
713
782
  if (!t) return;
714
783
  let n = document.documentElement, r = 0, i = () => {
@@ -725,98 +794,98 @@ function Ot(e) {
725
794
  }
726
795
  //#endregion
727
796
  //#region src/bento/bento-entity-shell.tsx
728
- function kt(e, t) {
797
+ function Ft(e, t) {
729
798
  let n = {};
730
799
  for (let r of Object.keys(e)) Object.assign(n, { [r]: t[r] });
731
800
  return n;
732
801
  }
733
- function At({ entity: e, isNew: t, headlineFallback: n, eyebrow: r, listRoute: i, trail: o, icon: s, tone: c, formId: l, feature: u, hasStatus: d = !1, hideIcon: f = !1, readOnly: p = !1, autosaveOnly: m = !1, badge: h, notice: g, onUpdate: _, onDelete: v, extraActions: y, children: b }) {
734
- let { t: x } = q(), S = Ge(), [C, w] = H(!1), [T, ee] = H({
802
+ function It({ entity: e, isNew: t, headlineFallback: n, eyebrow: r, listRoute: i, trail: o, icon: s, tone: c, formId: l, feature: u, hasStatus: d = !1, hideIcon: f = !1, readOnly: p = !1, autosaveOnly: m = !1, badge: h, notice: g, onUpdate: _, onDelete: v, extraActions: y, children: b }) {
803
+ let { t: x } = J(), S = Ye(), [C, w] = W(!1), [T, E] = W({
735
804
  isDirty: !1,
736
805
  isSubmitting: !1
737
- }), E = V(null);
738
- Ot(E);
739
- let D = {
806
+ }), D = U(null);
807
+ Pt(D);
808
+ let O = {
740
809
  title: e.title ?? "",
741
810
  description: e.description ?? "",
742
811
  icon: e.icon ?? null,
743
812
  enabled: e.enabled ?? 1
744
- }, [O, k] = H(D), [A, j] = H(D);
745
- (D.title !== A.title || D.description !== A.description || D.icon !== A.icon || D.enabled !== A.enabled) && (j(D), k(D));
813
+ }, [k, A] = W(O), [j, M] = W(O);
814
+ (O.title !== j.title || O.description !== j.description || O.icon !== j.icon || O.enabled !== j.enabled) && (M(O), A(O));
746
815
  async function N(n) {
747
- if (k((e) => ({
816
+ if (A((e) => ({
748
817
  ...e,
749
818
  ...n
750
819
  })), t || !_) return;
751
- let r = n.title ?? O.title;
820
+ let r = n.title ?? k.title;
752
821
  try {
753
822
  await _({
754
823
  ...e,
755
824
  ...n
756
- }), M.success(x("forms.common.updated", {
825
+ }), R.success(x("forms.common.updated", {
757
826
  name: r,
758
827
  feature: u
759
828
  }));
760
829
  } catch (e) {
761
- console.error("Failed to update entity field", e), k((e) => ({
830
+ console.error("Failed to update entity field", e), A((e) => ({
762
831
  ...e,
763
- ...kt(n, D)
764
- })), M.error(x("forms.common.notUpdated", {
765
- name: D.title || r,
832
+ ...Ft(n, O)
833
+ })), R.error(x("forms.common.notUpdated", {
834
+ name: O.title || r,
766
835
  feature: u
767
836
  }));
768
837
  }
769
838
  }
770
- async function te() {
839
+ async function P() {
771
840
  if (v) {
772
841
  try {
773
- await v() ? (M.success(x("forms.common.deleted", {
774
- name: O.title,
842
+ await v() ? (R.success(x("forms.common.deleted", {
843
+ name: k.title,
775
844
  feature: u
776
- })), S(i)) : M.error(x("forms.common.notDeleted", {
777
- name: O.title,
845
+ })), S(i)) : R.error(x("forms.common.notDeleted", {
846
+ name: k.title,
778
847
  feature: u
779
848
  }));
780
849
  } catch (e) {
781
- console.error("Failed to delete entity", e), M.error(x("forms.common.notDeleted", {
782
- name: O.title,
850
+ console.error("Failed to delete entity", e), R.error(x("forms.common.notDeleted", {
851
+ name: k.title,
783
852
  feature: u
784
853
  }));
785
854
  }
786
855
  w(!1);
787
856
  }
788
857
  }
789
- let P = O.enabled === 1, F = !p, I = !(m && !t), L = !O.title.trim(), ne = !t && !T.isDirty, re = L || ne, ie = [...y ?? [], ...v && !p ? [{
858
+ let F = k.enabled === 1, ee = !p, te = !(m && !t), I = !k.title.trim(), L = !t && !T.isDirty, ne = I || L, z = [...y ?? [], ...v && !p ? [{
790
859
  id: "entity.delete",
791
860
  label: x("forms.formActions.delete"),
792
- icon: Fe,
861
+ icon: ze,
793
862
  tone: "destructive",
794
863
  onSelect: () => w(!0)
795
864
  }] : []];
796
- return /* @__PURE__ */ K(W, { children: [
797
- /* @__PURE__ */ G(Ct, {
798
- eyebrow: /* @__PURE__ */ K("span", {
865
+ return /* @__PURE__ */ q(G, { children: [
866
+ /* @__PURE__ */ K(kt, {
867
+ eyebrow: /* @__PURE__ */ q("span", {
799
868
  className: "inline-flex items-center gap-2",
800
- children: [o && o.length > 1 ? /* @__PURE__ */ G(bt, { steps: o }) : /* @__PURE__ */ G(xt, {
869
+ children: [o && o.length > 1 ? /* @__PURE__ */ K(Et, { steps: o }) : /* @__PURE__ */ K(Dt, {
801
870
  to: i,
802
871
  children: r
803
- }), !p && /* @__PURE__ */ G(Dt, {
804
- titleMissing: L,
872
+ }), !p && /* @__PURE__ */ K(Nt, {
873
+ titleMissing: I,
805
874
  dirty: t || T.isDirty
806
875
  })]
807
876
  }),
808
- leading: /* @__PURE__ */ G(wt, {
809
- value: O.icon,
877
+ leading: /* @__PURE__ */ K(At, {
878
+ value: k.icon,
810
879
  onChange: (e) => N({ icon: e }),
811
880
  onClear: () => N({ icon: null }),
812
881
  defaultIcon: s,
813
882
  tone: c,
814
- title: O.title,
815
- description: O.description,
883
+ title: k.title,
884
+ description: k.description,
816
885
  readOnly: p || f
817
886
  }),
818
- title: /* @__PURE__ */ G(Tt, {
819
- value: O.title,
887
+ title: /* @__PURE__ */ K(jt, {
888
+ value: k.title,
820
889
  onSave: (e) => N({ title: e }),
821
890
  placeholder: n,
822
891
  className: "text-2xl font-semibold tracking-tight md:text-3xl",
@@ -825,8 +894,8 @@ function At({ entity: e, isNew: t, headlineFallback: n, eyebrow: r, listRoute: i
825
894
  commitOnChange: t,
826
895
  readOnly: p
827
896
  }),
828
- subtitle: /* @__PURE__ */ G(Tt, {
829
- value: O.description,
897
+ subtitle: /* @__PURE__ */ K(jt, {
898
+ value: k.description,
830
899
  onSave: (e) => N({ description: e }),
831
900
  multiline: !0,
832
901
  placeholder: x("forms.common.description"),
@@ -835,78 +904,78 @@ function At({ entity: e, isNew: t, headlineFallback: n, eyebrow: r, listRoute: i
835
904
  commitOnChange: t,
836
905
  readOnly: p
837
906
  }),
838
- trailing: /* @__PURE__ */ K(W, { children: [
839
- F && /* @__PURE__ */ K("div", {
907
+ trailing: /* @__PURE__ */ q(G, { children: [
908
+ ee && /* @__PURE__ */ q("div", {
840
909
  className: "bento-fade-out flex shrink-0 items-center gap-2",
841
- children: [I && /* @__PURE__ */ K(a, {
910
+ children: [te && /* @__PURE__ */ q(a, {
842
911
  type: "submit",
843
912
  form: l,
844
913
  size: "sm",
845
914
  loading: T.isSubmitting,
846
- "aria-disabled": re ? "true" : void 0,
847
- children: [/* @__PURE__ */ G(Se, { className: "size-4" }), x("forms.formActions.saveChanges")]
848
- }), /* @__PURE__ */ K(a, {
915
+ "aria-disabled": ne ? "true" : void 0,
916
+ children: [/* @__PURE__ */ K(Ee, { className: "size-4" }), x("forms.formActions.saveChanges")]
917
+ }), /* @__PURE__ */ q(a, {
849
918
  type: "button",
850
919
  size: "sm",
851
920
  variant: "outline",
852
921
  onClick: () => S(i),
853
- children: [/* @__PURE__ */ G(ze, { className: "size-4" }), x("forms.formActions.cancel")]
922
+ children: [/* @__PURE__ */ K(Ue, { className: "size-4" }), x("forms.formActions.cancel")]
854
923
  })]
855
924
  }),
856
925
  h,
857
- d && (p ? /* @__PURE__ */ K("span", {
858
- className: `flex items-center gap-1.5 rounded-full border px-2.5 py-1 text-[10px] uppercase tracking-wider ${P ? "bento-status bento-status-on" : "border-border bg-muted text-muted-foreground"}`,
859
- children: [/* @__PURE__ */ G("span", { className: `h-1.5 w-1.5 rounded-full ${P ? "bento-status-dot bento-pulse" : "bg-muted-foreground/60"}` }), P ? x("common.active", { defaultValue: "Active" }) : x("common.idle", { defaultValue: "Idle" })]
860
- }) : /* @__PURE__ */ K("button", {
926
+ d && (p ? /* @__PURE__ */ q("span", {
927
+ className: `flex h-(--vg-control-dense) items-center gap-1.5 rounded-full border px-2.5 text-[10px] uppercase tracking-wider ${F ? "bento-status bento-status-on" : "border-border bg-muted text-muted-foreground"}`,
928
+ children: [/* @__PURE__ */ K("span", { className: `h-1.5 w-1.5 rounded-full ${F ? "bento-status-dot bento-pulse" : "bg-muted-foreground/60"}` }), F ? x("common.active", { defaultValue: "Active" }) : x("common.idle", { defaultValue: "Idle" })]
929
+ }) : /* @__PURE__ */ q("button", {
861
930
  type: "button",
862
- onClick: () => N({ enabled: +!P }),
931
+ onClick: () => N({ enabled: +!F }),
863
932
  "aria-label": x("forms.common.enabled"),
864
- title: x(P ? "common.activeToggleHint" : "common.idleToggleHint"),
865
- className: `bento-tile-clickable flex items-center gap-1.5 rounded-full border px-2.5 py-1 text-[10px] uppercase tracking-wider transition-colors duration-200 ${P ? "bento-status bento-status-on" : "border-border bg-muted text-muted-foreground hover:bg-muted/80"}`,
866
- children: [/* @__PURE__ */ G("span", { className: `h-1.5 w-1.5 rounded-full ${P ? "bento-status-dot bento-pulse" : "bg-muted-foreground/60"}` }), P ? x("common.active", { defaultValue: "Active" }) : x("common.idle", { defaultValue: "Idle" })]
933
+ title: x(F ? "common.activeToggleHint" : "common.idleToggleHint"),
934
+ className: `bento-tile-clickable flex h-(--vg-control-dense) items-center gap-1.5 rounded-full border px-2.5 text-[10px] uppercase tracking-wider transition-colors duration-200 ${F ? "bento-status bento-status-on" : "border-border bg-muted text-muted-foreground hover:bg-muted/80"}`,
935
+ children: [/* @__PURE__ */ K("span", { className: `h-1.5 w-1.5 rounded-full ${F ? "bento-status-dot bento-pulse" : "bg-muted-foreground/60"}` }), F ? x("common.active", { defaultValue: "Active" }) : x("common.idle", { defaultValue: "Idle" })]
867
936
  })),
868
- !t && ie.length > 0 && /* @__PURE__ */ G(ut, { actions: ie })
937
+ !t && z.length > 0 && /* @__PURE__ */ K(mt, { actions: z })
869
938
  ] })
870
939
  }),
871
- /* @__PURE__ */ G("div", {
872
- ref: E,
940
+ /* @__PURE__ */ K("div", {
941
+ ref: D,
873
942
  "aria-hidden": !0,
874
943
  className: "h-px"
875
944
  }),
876
945
  g,
877
- !t && v && /* @__PURE__ */ G(ae, {
946
+ !t && v && /* @__PURE__ */ K(ae, {
878
947
  feature: u,
879
- name: O.title,
880
- onDelete: te,
948
+ name: k.title,
949
+ onDelete: P,
881
950
  open: C,
882
951
  setOpen: w,
883
- trigger: /* @__PURE__ */ G("span", {
952
+ trigger: /* @__PURE__ */ K("span", {
884
953
  className: "hidden",
885
954
  "aria-hidden": !0
886
955
  })
887
956
  }),
888
957
  b({
889
- staged: O,
890
- onStateChange: ee
958
+ staged: k,
959
+ onStateChange: E
891
960
  })
892
961
  ] });
893
962
  }
894
963
  //#endregion
895
964
  //#region src/bento/bento-change-mark.tsx
896
- var jt = {
965
+ var Lt = {
897
966
  added: "bento-status bento-status-on",
898
967
  removed: "bento-status bento-status-error",
899
968
  changed: "bento-status bento-status-warn",
900
969
  unchanged: !1
901
970
  };
902
- function Mt({ state: t, compact: n = !1, className: r }) {
903
- let { t: i } = q(), a = {
971
+ function Rt({ state: t, compact: n = !1, className: r }) {
972
+ let { t: i } = J(), a = {
904
973
  added: i("bento.diff.added", { defaultValue: "Added" }),
905
974
  removed: i("bento.diff.removed", { defaultValue: "Removed" }),
906
975
  changed: i("bento.diff.changed", { defaultValue: "Changed" }),
907
976
  unchanged: i("bento.diff.unchanged", { defaultValue: "Unchanged" })
908
- }[t], o = e("rounded-full border px-1.5 leading-4", n && "font-mono", jt[t], r);
909
- if (!n) return /* @__PURE__ */ G("span", {
977
+ }[t], o = e("rounded-full border px-1.5 leading-4", n && "font-mono", Lt[t], r);
978
+ if (!n) return /* @__PURE__ */ K("span", {
910
979
  "data-slot": "bento-change-mark",
911
980
  "data-state": t,
912
981
  className: o,
@@ -918,15 +987,15 @@ function Mt({ state: t, compact: n = !1, className: r }) {
918
987
  changed: i("bento.diff.changedLetter", { defaultValue: "M" }),
919
988
  unchanged: i("bento.diff.unchangedLetter", { defaultValue: "·" })
920
989
  }[t];
921
- return /* @__PURE__ */ K("span", {
990
+ return /* @__PURE__ */ q("span", {
922
991
  "data-slot": "bento-change-mark",
923
992
  "data-state": t,
924
993
  title: a,
925
994
  className: o,
926
- children: [/* @__PURE__ */ G("span", {
995
+ children: [/* @__PURE__ */ K("span", {
927
996
  "aria-hidden": "true",
928
997
  children: s
929
- }), /* @__PURE__ */ G("span", {
998
+ }), /* @__PURE__ */ K("span", {
930
999
  className: "sr-only",
931
1000
  children: a
932
1001
  })]
@@ -934,7 +1003,7 @@ function Mt({ state: t, compact: n = !1, className: r }) {
934
1003
  }
935
1004
  //#endregion
936
1005
  //#region src/bento/bento-diff.tsx
937
- function Nt(e, t, n = !0) {
1006
+ function zt(e, t, n = !0) {
938
1007
  let r = e.length, i = t.length;
939
1008
  if (r * i > 4e5) return null;
940
1009
  let a = Array.from({ length: r + 1 }, () => new Uint32Array(i + 1));
@@ -951,16 +1020,16 @@ function Nt(e, t, n = !0) {
951
1020
  for (; l < i;) s("add", t[l++]);
952
1021
  return o;
953
1022
  }
954
- var Pt = (e) => e.split(/(\s+)/).filter((e) => e !== "");
955
- function Ft(e) {
1023
+ var Bt = (e) => e.split(/(\s+)/).filter((e) => e !== "");
1024
+ function Vt(e) {
956
1025
  if (typeof DOMParser > "u") return e.split(/<\/(?:p|h[1-6]|li|blockquote|pre|div)>/i).map((e) => e.replace(/<[^>]*>/g, "").replace(/\s+/g, " ").trim()).filter(Boolean);
957
1026
  let t = new DOMParser().parseFromString(e, "text/html"), n = [...t.body.querySelectorAll("p, h1, h2, h3, h4, h5, h6, li, blockquote, pre")].filter((e) => !e.parentElement?.closest("p, h1, h2, h3, h4, h5, h6, li, blockquote, pre")).map((e) => (e.textContent ?? "").replace(/\s+/g, " ").trim()).filter(Boolean), r = (t.body.textContent ?? "").replace(/\s+/g, " ").trim();
958
1027
  return n.length > 0 ? n : r ? [r] : [];
959
1028
  }
960
- var X = (e) => e == null ? "" : String(e);
961
- function It({ before: t, after: n, fields: r, showUnchanged: i = !1, layout: a = "inline" }) {
962
- let { t: o } = q(), [s, c] = H(i), l = r.map((e) => {
963
- let r = t?.[e.id], i = n?.[e.id], a = e.kind ?? "text", o = a === "rich" ? Ft(X(r)).join("\n") === Ft(X(i)).join("\n") : a === "value" ? JSON.stringify(r ?? null) === JSON.stringify(i ?? null) : X(r) === X(i), s = "changed";
1029
+ var Q = (e) => e == null ? "" : String(e);
1030
+ function Ht({ before: t, after: n, fields: r, showUnchanged: i = !1, layout: a = "inline" }) {
1031
+ let { t: o } = J(), [s, c] = W(i), l = r.map((e) => {
1032
+ let r = t?.[e.id], i = n?.[e.id], a = e.kind ?? "text", o = a === "rich" ? Vt(Q(r)).join("\n") === Vt(Q(i)).join("\n") : a === "value" ? JSON.stringify(r ?? null) === JSON.stringify(i ?? null) : Q(r) === Q(i), s = "changed";
964
1033
  return t === null || (r == null || r === "") && !o ? s = "added" : n === null || (i == null || i === "") && !o ? s = "removed" : o && (s = "unchanged"), {
965
1034
  field: e,
966
1035
  a: r,
@@ -969,37 +1038,38 @@ function It({ before: t, after: n, fields: r, showUnchanged: i = !1, layout: a =
969
1038
  state: s
970
1039
  };
971
1040
  }), u = l.filter((e) => e.state !== "unchanged"), d = l.filter((e) => e.state === "unchanged");
972
- return /* @__PURE__ */ K("div", {
1041
+ return /* @__PURE__ */ q("div", {
973
1042
  "data-slot": "bento-diff",
974
1043
  className: "flex flex-col gap-3",
975
1044
  children: [
976
- (t === null || n === null) && /* @__PURE__ */ G("p", {
1045
+ (t === null || n === null) && /* @__PURE__ */ K("p", {
977
1046
  className: "m-0 text-sm font-medium",
978
1047
  children: t === null ? o("bento.diff.created", { defaultValue: "Created in this version" }) : o("bento.diff.deleted", { defaultValue: "Deleted in this version" })
979
1048
  }),
980
- u.length === 0 && /* @__PURE__ */ G("p", {
1049
+ u.length === 0 && /* @__PURE__ */ K("p", {
981
1050
  className: "m-0 text-sm text-muted-foreground",
982
1051
  children: o("bento.diff.noChanges", { defaultValue: "No field changed" })
983
1052
  }),
984
- /* @__PURE__ */ G("dl", {
1053
+ /* @__PURE__ */ K("dl", {
985
1054
  className: "m-0 flex flex-col gap-3",
986
- children: u.map((e) => /* @__PURE__ */ G(Lt, {
1055
+ children: u.map((e) => /* @__PURE__ */ K(Ut, {
987
1056
  label: e.field.label,
988
1057
  state: e.state,
989
- children: /* @__PURE__ */ G(Rt, {
1058
+ children: /* @__PURE__ */ K(Wt, {
990
1059
  row: e,
991
1060
  layout: a
992
1061
  })
993
1062
  }, e.field.id))
994
1063
  }),
995
- d.length > 0 && /* @__PURE__ */ K("div", {
1064
+ d.length > 0 && /* @__PURE__ */ q("div", {
996
1065
  className: "flex flex-col gap-3",
997
- children: [/* @__PURE__ */ K("button", {
1066
+ children: [/* @__PURE__ */ q("button", {
998
1067
  type: "button",
1068
+ "data-look": "text",
999
1069
  "aria-expanded": s ? "true" : "false",
1000
1070
  onClick: () => c(!s),
1001
1071
  className: "inline-flex items-center gap-1 self-start rounded-md text-sm text-muted-foreground hover:text-foreground focus-visible:outline-2 focus-visible:outline-ring",
1002
- children: [/* @__PURE__ */ G(Y, {
1072
+ children: [/* @__PURE__ */ K(we, {
1003
1073
  size: 14,
1004
1074
  "aria-hidden": "true",
1005
1075
  className: e("transition-transform", s && "rotate-90")
@@ -1007,14 +1077,14 @@ function It({ before: t, after: n, fields: r, showUnchanged: i = !1, layout: a =
1007
1077
  defaultValue: "{{count}} unchanged",
1008
1078
  count: d.length
1009
1079
  })]
1010
- }), s && /* @__PURE__ */ G("dl", {
1080
+ }), s && /* @__PURE__ */ K("dl", {
1011
1081
  className: "m-0 flex flex-col gap-3",
1012
- children: d.map((t) => /* @__PURE__ */ G(Lt, {
1082
+ children: d.map((t) => /* @__PURE__ */ K(Ut, {
1013
1083
  label: t.field.label,
1014
1084
  state: "unchanged",
1015
- children: /* @__PURE__ */ G("p", {
1085
+ children: /* @__PURE__ */ K("p", {
1016
1086
  className: e("m-0 whitespace-pre-wrap text-sm text-muted-foreground", t.kind === "lines" && "font-mono text-xs"),
1017
- children: t.kind === "rich" ? Ft(X(t.b)).join("\n\n") : t.field.format ? t.field.format(t.b) : X(t.b)
1087
+ children: t.kind === "rich" ? Vt(Q(t.b)).join("\n\n") : t.field.format ? t.field.format(t.b) : Q(t.b)
1018
1088
  })
1019
1089
  }, t.field.id))
1020
1090
  })]
@@ -1022,41 +1092,41 @@ function It({ before: t, after: n, fields: r, showUnchanged: i = !1, layout: a =
1022
1092
  ]
1023
1093
  });
1024
1094
  }
1025
- function Lt({ label: e, state: t, children: n }) {
1026
- return /* @__PURE__ */ K("div", {
1095
+ function Ut({ label: e, state: t, children: n }) {
1096
+ return /* @__PURE__ */ q("div", {
1027
1097
  className: "rounded-xl border border-border/60 bg-card/40 p-3",
1028
- children: [/* @__PURE__ */ K("dt", {
1098
+ children: [/* @__PURE__ */ q("dt", {
1029
1099
  className: "mb-1.5 flex items-center gap-2 text-xs font-medium text-muted-foreground",
1030
- children: [/* @__PURE__ */ G("span", { children: e }), /* @__PURE__ */ G(Mt, { state: t })]
1031
- }), /* @__PURE__ */ G("dd", {
1100
+ children: [/* @__PURE__ */ K("span", { children: e }), /* @__PURE__ */ K(Rt, { state: t })]
1101
+ }), /* @__PURE__ */ K("dd", {
1032
1102
  className: "m-0",
1033
1103
  children: n
1034
1104
  })]
1035
1105
  });
1036
1106
  }
1037
- function Rt({ row: e, layout: t }) {
1038
- let { t: n } = q(), { field: r, a: i, b: a, kind: o, state: s } = e;
1039
- if (o === "lines") return /* @__PURE__ */ G(Wt, {
1107
+ function Wt({ row: e, layout: t }) {
1108
+ let { t: n } = J(), { field: r, a: i, b: a, kind: o, state: s } = e;
1109
+ if (o === "lines") return /* @__PURE__ */ K(Xt, {
1040
1110
  label: r.label,
1041
- before: X(i),
1042
- after: X(a),
1111
+ before: Q(i),
1112
+ after: Q(a),
1043
1113
  layout: t
1044
1114
  });
1045
1115
  if (o === "value") {
1046
- let e = (e) => r.format ? r.format(e) : X(e);
1047
- return /* @__PURE__ */ K("p", {
1116
+ let e = (e) => r.format ? r.format(e) : Q(e);
1117
+ return /* @__PURE__ */ q("p", {
1048
1118
  className: "m-0 flex flex-wrap items-center gap-2 text-sm",
1049
1119
  children: [
1050
- s !== "added" && /* @__PURE__ */ G(nn, { children: e(i) }),
1051
- s === "changed" && /* @__PURE__ */ G("span", {
1120
+ s !== "added" && /* @__PURE__ */ K(ln, { children: e(i) }),
1121
+ s === "changed" && /* @__PURE__ */ K("span", {
1052
1122
  "aria-hidden": "true",
1053
1123
  children: "→"
1054
1124
  }),
1055
- s !== "removed" && /* @__PURE__ */ G(tn, { children: e(a) })
1125
+ s !== "removed" && /* @__PURE__ */ K(cn, { children: e(a) })
1056
1126
  ]
1057
1127
  });
1058
1128
  }
1059
- let c = o === "rich" ? Ft(X(i)) : [X(i)].filter(Boolean), l = o === "rich" ? Ft(X(a)) : [X(a)].filter(Boolean), u = Nt(c, l, !1) ?? [...c.map((e) => ({
1129
+ let c = o === "rich" ? Vt(Q(i)) : [Q(i)].filter(Boolean), l = o === "rich" ? Vt(Q(a)) : [Q(a)].filter(Boolean), u = zt(c, l, !1) ?? [...c.map((e) => ({
1060
1130
  op: "remove",
1061
1131
  text: e
1062
1132
  })), ...l.map((e) => ({
@@ -1066,35 +1136,35 @@ function Rt({ row: e, layout: t }) {
1066
1136
  for (let e = 0; e < u.length; e++) {
1067
1137
  let t = u[e], n = u[e + 1];
1068
1138
  if (t.op === "remove" && n?.op === "add") {
1069
- let r = Nt(Pt(t.text), Pt(n.text));
1070
- d.push(/* @__PURE__ */ G("p", {
1139
+ let r = zt(Bt(t.text), Bt(n.text));
1140
+ d.push(/* @__PURE__ */ K("p", {
1071
1141
  className: "m-0 whitespace-pre-wrap text-sm leading-relaxed",
1072
- children: r ? r.map((e, t) => e.op === "same" ? /* @__PURE__ */ G("span", { children: e.text }, t) : e.op === "add" ? /* @__PURE__ */ G(tn, { children: e.text }, t) : /* @__PURE__ */ G(nn, { children: e.text }, t)) : [
1073
- /* @__PURE__ */ G(nn, { children: t.text }, "r"),
1142
+ children: r ? r.map((e, t) => e.op === "same" ? /* @__PURE__ */ K("span", { children: e.text }, t) : e.op === "add" ? /* @__PURE__ */ K(cn, { children: e.text }, t) : /* @__PURE__ */ K(ln, { children: e.text }, t)) : [
1143
+ /* @__PURE__ */ K(ln, { children: t.text }, "r"),
1074
1144
  " ",
1075
- /* @__PURE__ */ G(tn, { children: n.text }, "a")
1145
+ /* @__PURE__ */ K(cn, { children: n.text }, "a")
1076
1146
  ]
1077
1147
  }, e)), e++;
1078
- } else d.push(/* @__PURE__ */ G("p", {
1148
+ } else d.push(/* @__PURE__ */ K("p", {
1079
1149
  className: "m-0 whitespace-pre-wrap text-sm leading-relaxed",
1080
- children: t.op === "same" ? t.text : t.op === "add" ? /* @__PURE__ */ G(tn, { children: t.text }) : /* @__PURE__ */ G(nn, { children: t.text })
1150
+ children: t.op === "same" ? t.text : t.op === "add" ? /* @__PURE__ */ K(cn, { children: t.text }) : /* @__PURE__ */ K(ln, { children: t.text })
1081
1151
  }, e));
1082
1152
  }
1083
- return d.length === 0 ? /* @__PURE__ */ G("p", {
1153
+ return d.length === 0 ? /* @__PURE__ */ K("p", {
1084
1154
  className: "m-0 text-sm text-muted-foreground",
1085
1155
  children: n("bento.diff.empty", { defaultValue: "Empty" })
1086
- }) : /* @__PURE__ */ G("div", {
1156
+ }) : /* @__PURE__ */ K("div", {
1087
1157
  className: "flex flex-col gap-2",
1088
1158
  children: d
1089
1159
  });
1090
1160
  }
1091
- var zt = 3, Bt = (e) => e === "" ? [] : e.replace(/\r?\n$/, "").split(/\r?\n/);
1092
- function Vt(e, t) {
1093
- let n = Bt(e), r = Bt(t), i = 0;
1161
+ var Gt = 3, Kt = (e) => e === "" ? [] : e.replace(/\r?\n$/, "").split(/\r?\n/);
1162
+ function qt(e, t) {
1163
+ let n = Kt(e), r = Kt(t), i = 0;
1094
1164
  for (; i < n.length && i < r.length && n[i] === r[i];) i++;
1095
1165
  let a = 0;
1096
1166
  for (; a < n.length - i && a < r.length - i && n[n.length - 1 - a] === r[r.length - 1 - a];) a++;
1097
- let o = Nt(n.slice(i, n.length - a), r.slice(i, r.length - a), !1);
1167
+ let o = zt(n.slice(i, n.length - a), r.slice(i, r.length - a), !1);
1098
1168
  if (o === null) return null;
1099
1169
  let s = [], c = 0, l = 0, u = (e) => s.push({
1100
1170
  op: "same",
@@ -1105,7 +1175,7 @@ function Vt(e, t) {
1105
1175
  n.slice(0, i).forEach(u);
1106
1176
  let d = [], f = [], p = () => {
1107
1177
  for (let e = 0; e < Math.min(d.length, f.length); e++) {
1108
- let t = Nt(Pt(d[e].text), Pt(f[e].text));
1178
+ let t = zt(Bt(d[e].text), Bt(f[e].text));
1109
1179
  t && (d[e].parts = t.filter((e) => e.op !== "add"), f[e].parts = t.filter((e) => e.op !== "remove"));
1110
1180
  }
1111
1181
  s.push(...d, ...f), d = [], f = [];
@@ -1121,7 +1191,7 @@ function Vt(e, t) {
1121
1191
  }) : (p(), u(e.text));
1122
1192
  return p(), n.slice(n.length - a).forEach(u), s;
1123
1193
  }
1124
- function Ht(e) {
1194
+ function Jt(e) {
1125
1195
  let t = [], n = 0;
1126
1196
  for (; n < e.length;) {
1127
1197
  if (e[n].op === "same") {
@@ -1140,10 +1210,10 @@ function Ht(e) {
1140
1210
  }
1141
1211
  return t;
1142
1212
  }
1143
- function Ut(e, t, n) {
1213
+ function Yt(e, t, n) {
1144
1214
  let r = Array(e.length).fill(!1);
1145
1215
  e.forEach((n, i) => {
1146
- if (t(n)) for (let t = Math.max(0, i - zt); t <= Math.min(e.length - 1, i + zt); t++) r[t] = !0;
1216
+ if (t(n)) for (let t = Math.max(0, i - Gt); t <= Math.min(e.length - 1, i + Gt); t++) r[t] = !0;
1147
1217
  });
1148
1218
  let i = [], a = 0;
1149
1219
  for (; a < e.length;) {
@@ -1161,13 +1231,13 @@ function Ut(e, t, n) {
1161
1231
  }
1162
1232
  return i;
1163
1233
  }
1164
- function Wt({ label: t, before: n, after: r, layout: i }) {
1165
- let { t: a } = q(), [o, s] = H(/* @__PURE__ */ new Set()), c = Vt(n, r);
1166
- if (c === null) return /* @__PURE__ */ G("p", {
1234
+ function Xt({ label: t, before: n, after: r, layout: i }) {
1235
+ let { t: a } = J(), [o, s] = W(/* @__PURE__ */ new Set()), c = qt(n, r);
1236
+ if (c === null) return /* @__PURE__ */ K("p", {
1167
1237
  className: "m-0 text-sm text-muted-foreground",
1168
1238
  children: a("bento.diff.tooLarge", { defaultValue: "Too many lines changed to compare them here" })
1169
1239
  });
1170
- if (c.length === 0) return /* @__PURE__ */ G("p", {
1240
+ if (c.length === 0) return /* @__PURE__ */ K("p", {
1171
1241
  className: "m-0 text-sm text-muted-foreground",
1172
1242
  children: a("bento.diff.empty", { defaultValue: "Empty" })
1173
1243
  });
@@ -1177,15 +1247,16 @@ function Wt({ label: t, before: n, after: r, layout: i }) {
1177
1247
  };
1178
1248
  function u(t, n, r) {
1179
1249
  let i = o.has(t.key);
1180
- return [/* @__PURE__ */ G("tr", { children: /* @__PURE__ */ G("td", {
1250
+ return [/* @__PURE__ */ K("tr", { children: /* @__PURE__ */ K("td", {
1181
1251
  colSpan: n,
1182
1252
  className: "bg-muted/40 px-2",
1183
- children: /* @__PURE__ */ K("button", {
1253
+ children: /* @__PURE__ */ q("button", {
1184
1254
  type: "button",
1255
+ "data-look": "text",
1185
1256
  "aria-expanded": i ? "true" : "false",
1186
1257
  onClick: () => l(t.key),
1187
1258
  className: "inline-flex items-center gap-1 rounded-md font-sans text-muted-foreground hover:text-foreground focus-visible:outline-2 focus-visible:outline-ring",
1188
- children: [/* @__PURE__ */ G(Y, {
1259
+ children: [/* @__PURE__ */ K(we, {
1189
1260
  size: 12,
1190
1261
  "aria-hidden": "true",
1191
1262
  className: e("transition-transform", i && "rotate-90")
@@ -1196,141 +1267,210 @@ function Wt({ label: t, before: n, after: r, layout: i }) {
1196
1267
  })
1197
1268
  }) }, `fold-${t.key}`), ...i ? t.items.map(r) : []];
1198
1269
  }
1199
- let d = (t) => /* @__PURE__ */ G("table", {
1270
+ let d = (t) => /* @__PURE__ */ K("table", {
1200
1271
  "data-layout": "inline",
1201
1272
  className: e("min-w-full border-collapse font-mono text-mono leading-5", t),
1202
- children: /* @__PURE__ */ G("tbody", { children: Ut(c, (e) => e.op !== "same", Gt).map((e) => {
1203
- let t = (e) => /* @__PURE__ */ G(Zt, { row: e }, Gt(e));
1273
+ children: /* @__PURE__ */ K("tbody", { children: Yt(c, (e) => e.op !== "same", Zt).map((e) => {
1274
+ let t = (e) => /* @__PURE__ */ K(rn, { row: e }, Zt(e));
1204
1275
  return e.fold ? u(e, 4, t) : e.items.map(t);
1205
1276
  }) })
1206
1277
  });
1207
- return /* @__PURE__ */ G("section", {
1278
+ return /* @__PURE__ */ K("section", {
1208
1279
  "aria-label": t,
1209
1280
  tabIndex: 0,
1210
1281
  className: "@container/diff overflow-x-auto rounded-md border border-border/60 focus-visible:outline-2 focus-visible:outline-ring",
1211
- children: i === "split" ? /* @__PURE__ */ K(W, { children: [d("@3xl/diff:hidden"), ((t) => /* @__PURE__ */ K("table", {
1282
+ children: i === "split" ? /* @__PURE__ */ q(G, { children: [d("@3xl/diff:hidden"), ((t) => /* @__PURE__ */ q("table", {
1212
1283
  "data-layout": "split",
1213
1284
  className: e("w-full table-fixed border-collapse font-mono text-mono leading-5", t),
1214
- children: [/* @__PURE__ */ K("colgroup", { children: [
1215
- /* @__PURE__ */ G("col", { className: "w-14" }),
1216
- /* @__PURE__ */ G("col", { className: "w-5" }),
1217
- /* @__PURE__ */ G("col", {}),
1218
- /* @__PURE__ */ G("col", { className: "w-14" }),
1219
- /* @__PURE__ */ G("col", { className: "w-5" }),
1220
- /* @__PURE__ */ G("col", {})
1221
- ] }), /* @__PURE__ */ G("tbody", { children: Ut(Ht(c), (e) => e.left?.op !== "same", Kt).map((e) => {
1222
- let t = (e) => /* @__PURE__ */ G(Qt, { pair: e }, Kt(e));
1285
+ children: [/* @__PURE__ */ q("colgroup", { children: [
1286
+ /* @__PURE__ */ K("col", { className: "w-14" }),
1287
+ /* @__PURE__ */ K("col", { className: "w-5" }),
1288
+ /* @__PURE__ */ K("col", {}),
1289
+ /* @__PURE__ */ K("col", { className: "w-14" }),
1290
+ /* @__PURE__ */ K("col", { className: "w-5" }),
1291
+ /* @__PURE__ */ K("col", {})
1292
+ ] }), /* @__PURE__ */ K("tbody", { children: Yt(Jt(c), (e) => e.left?.op !== "same", Qt).map((e) => {
1293
+ let t = (e) => /* @__PURE__ */ K(an, { pair: e }, Qt(e));
1223
1294
  return e.fold ? u(e, 6, t) : e.items.map(t);
1224
1295
  }) })]
1225
1296
  }))("hidden @3xl/diff:table")] }) : d()
1226
1297
  });
1227
1298
  }
1228
- var Gt = (e) => `${e.old ?? ""}:${e.new ?? ""}`, Kt = (e) => `${e.left?.old ?? ""}:${e.right?.new ?? ""}`, qt = (t) => e(t.op === "add" && "bento-status bento-status-on", t.op === "remove" && "bento-status bento-status-error");
1229
- function Jt(e) {
1230
- return e.parts ? e.parts.map((e, t) => e.op === "add" ? /* @__PURE__ */ G(tn, { children: e.text }, t) : e.op === "remove" ? /* @__PURE__ */ G(nn, { children: e.text }, t) : /* @__PURE__ */ G("span", { children: e.text }, t)) : e.op === "same" ? e.text : /* @__PURE__ */ G(en, {
1299
+ var Zt = (e) => `${e.old ?? ""}:${e.new ?? ""}`, Qt = (e) => `${e.left?.old ?? ""}:${e.right?.new ?? ""}`, $t = (t) => e(t.op === "add" && "bento-status bento-status-on", t.op === "remove" && "bento-status bento-status-error");
1300
+ function en(e) {
1301
+ return e.parts ? e.parts.map((e, t) => e.op === "add" ? /* @__PURE__ */ K(cn, { children: e.text }, t) : e.op === "remove" ? /* @__PURE__ */ K(ln, { children: e.text }, t) : /* @__PURE__ */ K("span", { children: e.text }, t)) : e.op === "same" ? e.text : /* @__PURE__ */ K(sn, {
1231
1302
  op: e.op,
1232
1303
  children: e.text
1233
1304
  });
1234
1305
  }
1235
- var Yt = {
1306
+ var tn = {
1236
1307
  same: " ",
1237
1308
  add: "+",
1238
1309
  remove: "−"
1239
- }, Xt = "select-none px-2 text-right align-top text-muted-foreground tabular-nums";
1240
- function Zt({ row: t }) {
1241
- let n = qt(t);
1242
- return /* @__PURE__ */ K("tr", {
1310
+ }, nn = "select-none px-2 text-right align-top text-muted-foreground tabular-nums";
1311
+ function rn({ row: t }) {
1312
+ let n = $t(t);
1313
+ return /* @__PURE__ */ q("tr", {
1243
1314
  "data-op": t.op,
1244
1315
  children: [
1245
- /* @__PURE__ */ G("td", {
1246
- className: e("w-px", Xt, n),
1316
+ /* @__PURE__ */ K("td", {
1317
+ className: e("w-px", nn, n),
1247
1318
  children: t.old
1248
1319
  }),
1249
- /* @__PURE__ */ G("td", {
1250
- className: e("w-px", Xt, n),
1320
+ /* @__PURE__ */ K("td", {
1321
+ className: e("w-px", nn, n),
1251
1322
  children: t.new
1252
1323
  }),
1253
- /* @__PURE__ */ G("td", {
1324
+ /* @__PURE__ */ K("td", {
1254
1325
  "aria-hidden": "true",
1255
1326
  className: e("w-px select-none pr-1", n),
1256
- children: Yt[t.op]
1327
+ children: tn[t.op]
1257
1328
  }),
1258
- /* @__PURE__ */ G("td", {
1329
+ /* @__PURE__ */ K("td", {
1259
1330
  className: e("whitespace-pre pr-3", !t.parts && n),
1260
- children: Jt(t)
1331
+ children: en(t)
1261
1332
  })
1262
1333
  ]
1263
1334
  });
1264
1335
  }
1265
- function Qt({ pair: e }) {
1266
- return /* @__PURE__ */ K("tr", {
1336
+ function an({ pair: e }) {
1337
+ return /* @__PURE__ */ q("tr", {
1267
1338
  "data-op": e.left?.op === "same" ? "same" : "change",
1268
- children: [/* @__PURE__ */ G($t, {
1339
+ children: [/* @__PURE__ */ K(on, {
1269
1340
  row: e.left,
1270
1341
  number: e.left?.old
1271
- }), /* @__PURE__ */ G($t, {
1342
+ }), /* @__PURE__ */ K(on, {
1272
1343
  row: e.right,
1273
1344
  number: e.right?.new,
1274
1345
  right: !0
1275
1346
  })]
1276
1347
  });
1277
1348
  }
1278
- function $t({ row: t, number: n, right: r = !1 }) {
1279
- if (t === null) return /* @__PURE__ */ G("td", {
1349
+ function on({ row: t, number: n, right: r = !1 }) {
1350
+ if (t === null) return /* @__PURE__ */ K("td", {
1280
1351
  colSpan: 3,
1281
1352
  "data-empty": "",
1282
1353
  className: e("[background-image:repeating-linear-gradient(-45deg,var(--color-border)_0_1px,transparent_0_6px)]", r && "border-l border-border/60")
1283
1354
  });
1284
- let i = qt(t);
1285
- return /* @__PURE__ */ K(W, { children: [
1286
- /* @__PURE__ */ G("td", {
1287
- className: e(Xt, i, r && "border-l border-border/60"),
1355
+ let i = $t(t);
1356
+ return /* @__PURE__ */ q(G, { children: [
1357
+ /* @__PURE__ */ K("td", {
1358
+ className: e(nn, i, r && "border-l border-border/60"),
1288
1359
  children: n
1289
1360
  }),
1290
- /* @__PURE__ */ G("td", {
1361
+ /* @__PURE__ */ K("td", {
1291
1362
  "aria-hidden": "true",
1292
1363
  className: e("select-none align-top", i),
1293
- children: Yt[t.op]
1364
+ children: tn[t.op]
1294
1365
  }),
1295
- /* @__PURE__ */ G("td", {
1366
+ /* @__PURE__ */ K("td", {
1296
1367
  className: e("whitespace-pre-wrap pr-3 [overflow-wrap:anywhere]", !t.parts && i),
1297
- children: Jt(t)
1368
+ children: en(t)
1298
1369
  })
1299
1370
  ] });
1300
1371
  }
1301
- function en({ op: e, children: t }) {
1302
- let { t: n } = q();
1303
- return /* @__PURE__ */ K(e === "add" ? "ins" : "del", {
1372
+ function sn({ op: e, children: t }) {
1373
+ let { t: n } = J();
1374
+ return /* @__PURE__ */ q(e === "add" ? "ins" : "del", {
1304
1375
  className: "no-underline",
1305
- children: [/* @__PURE__ */ K("span", {
1376
+ children: [/* @__PURE__ */ q("span", {
1306
1377
  className: "sr-only",
1307
1378
  children: [e === "add" ? n("bento.diff.addedStart", { defaultValue: "added:" }) : n("bento.diff.removedStart", { defaultValue: "removed:" }), " "]
1308
1379
  }), t]
1309
1380
  });
1310
1381
  }
1311
- function tn({ children: e }) {
1312
- let { t } = q();
1313
- return /* @__PURE__ */ K("ins", {
1382
+ function cn({ children: e }) {
1383
+ let { t } = J();
1384
+ return /* @__PURE__ */ q("ins", {
1314
1385
  className: "bento-status bento-status-on rounded-sm px-0.5 underline decoration-2 underline-offset-2",
1315
- children: [/* @__PURE__ */ K("span", {
1386
+ children: [/* @__PURE__ */ q("span", {
1316
1387
  className: "sr-only",
1317
1388
  children: [t("bento.diff.addedStart", { defaultValue: "added:" }), " "]
1318
1389
  }), e]
1319
1390
  });
1320
1391
  }
1321
- function nn({ children: e }) {
1322
- let { t } = q();
1323
- return /* @__PURE__ */ K("del", {
1392
+ function ln({ children: e }) {
1393
+ let { t } = J();
1394
+ return /* @__PURE__ */ q("del", {
1324
1395
  className: "bento-status bento-status-error rounded-sm px-0.5 line-through decoration-2",
1325
- children: [/* @__PURE__ */ K("span", {
1396
+ children: [/* @__PURE__ */ q("span", {
1326
1397
  className: "sr-only",
1327
1398
  children: [t("bento.diff.removedStart", { defaultValue: "removed:" }), " "]
1328
1399
  }), e]
1329
1400
  });
1330
1401
  }
1331
1402
  //#endregion
1403
+ //#region src/bento/bento-change-cell.tsx
1404
+ var un = 6e4, dn = 60 * un, fn = 24 * dn, pn = 30 * fn;
1405
+ function mn(e, t, n) {
1406
+ let r = e.getTime() - t, i = Math.abs(r);
1407
+ return i < un ? n.format(0, "second") : i < dn ? n.format(Math.round(r / un), "minute") : i < fn ? n.format(Math.round(r / dn), "hour") : n.format(Math.round(r / fn), "day");
1408
+ }
1409
+ function hn({ at: t, actor: n, agent: r = !1, now: i, className: a }) {
1410
+ let { t: o, i18n: s } = J(), c = new Date(t), l = !Number.isNaN(c.getTime()), [u] = W(() => Date.now()), d = i === void 0 ? u : new Date(i).getTime(), f = s?.resolvedLanguage ?? s?.language, p = String(t), m = String(t);
1411
+ return l && (m = new Intl.DateTimeFormat(f, {
1412
+ dateStyle: "long",
1413
+ timeStyle: "short"
1414
+ }).format(c), p = Math.abs(c.getTime() - d) < pn ? mn(c, d, new Intl.RelativeTimeFormat(f, { numeric: "auto" })) : new Intl.DateTimeFormat(f, { dateStyle: "medium" }).format(c)), /* @__PURE__ */ q("span", {
1415
+ "data-slot": "bento-change-cell",
1416
+ className: e("flex min-w-0 flex-col", a),
1417
+ children: [/* @__PURE__ */ q("time", {
1418
+ dateTime: l ? c.toISOString() : void 0,
1419
+ title: m,
1420
+ className: "truncate text-foreground",
1421
+ children: [/* @__PURE__ */ K("span", {
1422
+ "aria-hidden": "true",
1423
+ children: p
1424
+ }), /* @__PURE__ */ K("span", {
1425
+ className: "sr-only",
1426
+ children: m
1427
+ })]
1428
+ }), n != null && /* @__PURE__ */ q("span", {
1429
+ className: "flex min-w-0 items-center gap-1 text-xs text-muted-foreground",
1430
+ children: [r && /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K(Ie, {
1431
+ size: 12,
1432
+ "aria-hidden": "true",
1433
+ className: "shrink-0"
1434
+ }), /* @__PURE__ */ K("span", {
1435
+ className: "sr-only",
1436
+ children: o("bento.versions.agent", { defaultValue: "Agent" })
1437
+ })] }), /* @__PURE__ */ K("span", {
1438
+ className: "truncate",
1439
+ children: n
1440
+ })]
1441
+ })]
1442
+ });
1443
+ }
1444
+ //#endregion
1445
+ //#region src/bento/bento-identity-cell.tsx
1446
+ function gn(e) {
1447
+ let t = 0;
1448
+ for (let n of e) t = t * 31 + (n.codePointAt(0) ?? 0) >>> 0;
1449
+ return gt[t % gt.length];
1450
+ }
1451
+ function _n({ name: t, detail: n, tone: r, className: i }) {
1452
+ return /* @__PURE__ */ q("span", {
1453
+ "data-slot": "bento-identity-cell",
1454
+ className: e("flex min-w-0 items-center gap-2.5", i),
1455
+ children: [/* @__PURE__ */ K("span", {
1456
+ "aria-hidden": "true",
1457
+ className: e(_t(r ?? gn(t)), "grid size-8 shrink-0 place-items-center rounded-lg text-xs font-semibold text-white"),
1458
+ children: D({ name: t })
1459
+ }), /* @__PURE__ */ q("span", {
1460
+ className: "flex min-w-0 flex-col",
1461
+ children: [/* @__PURE__ */ K("span", {
1462
+ className: "truncate font-medium text-foreground",
1463
+ children: t
1464
+ }), n != null && /* @__PURE__ */ K("span", {
1465
+ className: "truncate text-xs text-muted-foreground",
1466
+ children: n
1467
+ })]
1468
+ })]
1469
+ });
1470
+ }
1471
+ //#endregion
1332
1472
  //#region src/bento/bento-split-page.tsx
1333
- var rn = ["primary", "secondary"], an = {
1473
+ var vn = ["primary", "secondary"], yn = {
1334
1474
  getItem: (e) => {
1335
1475
  try {
1336
1476
  return window.localStorage.getItem(e);
@@ -1343,69 +1483,69 @@ var rn = ["primary", "secondary"], an = {
1343
1483
  window.localStorage.setItem(e, t);
1344
1484
  } catch {}
1345
1485
  }
1346
- }, on = {
1486
+ }, bn = {
1347
1487
  getItem: () => null,
1348
1488
  setItem: () => {}
1349
1489
  };
1350
- function sn({ primary: t, secondary: n, primaryLabel: r, secondaryLabel: i, storageKey: a, defaultRatio: o = 50, className: s }) {
1351
- let { t: c } = q(), u = O(), d = Ve({
1490
+ function xn({ primary: t, secondary: n, primaryLabel: r, secondaryLabel: i, storageKey: a, defaultRatio: o = 50, className: s }) {
1491
+ let { t: c } = J(), l = re(), u = Ge({
1352
1492
  id: a ?? "bento-split-page",
1353
- panelIds: rn,
1354
- storage: a ? an : on
1493
+ panelIds: vn,
1494
+ storage: a ? yn : bn
1355
1495
  });
1356
- return u ? /* @__PURE__ */ K(j, {
1496
+ return l ? /* @__PURE__ */ q(te, {
1357
1497
  "data-slot": "bento-split-page",
1358
1498
  defaultValue: "primary",
1359
1499
  className: e("flex flex-col gap-3", s),
1360
1500
  children: [
1361
- /* @__PURE__ */ K(ee, {
1501
+ /* @__PURE__ */ q(k, {
1362
1502
  "aria-label": c("bento.split.switch", { defaultValue: "Show" }),
1363
1503
  className: "self-start",
1364
- children: [/* @__PURE__ */ G(E, {
1504
+ children: [/* @__PURE__ */ K(O, {
1365
1505
  value: "primary",
1366
1506
  children: r
1367
- }), /* @__PURE__ */ G(E, {
1507
+ }), /* @__PURE__ */ K(O, {
1368
1508
  value: "secondary",
1369
1509
  children: i
1370
1510
  })]
1371
1511
  }),
1372
- /* @__PURE__ */ G(L, {
1512
+ /* @__PURE__ */ K(P, {
1373
1513
  value: "primary",
1374
1514
  forceMount: !0,
1375
1515
  className: "data-[state=inactive]:hidden",
1376
1516
  children: t
1377
1517
  }),
1378
- /* @__PURE__ */ G(L, {
1518
+ /* @__PURE__ */ K(P, {
1379
1519
  value: "secondary",
1380
1520
  forceMount: !0,
1381
1521
  className: "data-[state=inactive]:hidden",
1382
1522
  children: n
1383
1523
  })
1384
1524
  ]
1385
- }) : /* @__PURE__ */ G("div", {
1525
+ }) : /* @__PURE__ */ K("div", {
1386
1526
  "data-slot": "bento-split-page",
1387
1527
  className: e("h-[var(--bento-split-height,calc(100dvh-12rem))] min-h-80", s),
1388
- children: /* @__PURE__ */ K(re, {
1528
+ children: /* @__PURE__ */ q(y, {
1389
1529
  orientation: "horizontal",
1390
- defaultLayout: d.defaultLayout,
1391
- onLayoutChanged: d.onLayoutChanged,
1530
+ defaultLayout: u.defaultLayout,
1531
+ onLayoutChanged: u.onLayoutChanged,
1392
1532
  children: [
1393
- /* @__PURE__ */ G(l, {
1533
+ /* @__PURE__ */ K(d, {
1394
1534
  id: "primary",
1395
1535
  defaultSize: `${o}`,
1396
1536
  minSize: "25",
1397
- children: /* @__PURE__ */ G("section", {
1537
+ children: /* @__PURE__ */ K("section", {
1398
1538
  "aria-label": r,
1399
1539
  className: "h-full overflow-y-auto pr-3",
1400
1540
  children: t
1401
1541
  })
1402
1542
  }),
1403
- /* @__PURE__ */ G(b, { withHandle: !0 }),
1404
- /* @__PURE__ */ G(l, {
1543
+ /* @__PURE__ */ K(f, { withHandle: !0 }),
1544
+ /* @__PURE__ */ K(d, {
1405
1545
  id: "secondary",
1406
1546
  defaultSize: `${100 - o}`,
1407
1547
  minSize: "25",
1408
- children: /* @__PURE__ */ G("section", {
1548
+ children: /* @__PURE__ */ K("section", {
1409
1549
  "aria-label": i,
1410
1550
  className: "h-full overflow-y-auto pl-3",
1411
1551
  children: n
@@ -1417,22 +1557,22 @@ function sn({ primary: t, secondary: n, primaryLabel: r, secondaryLabel: i, stor
1417
1557
  }
1418
1558
  //#endregion
1419
1559
  //#region src/bento/bento-calendar.tsx
1420
- var Z = ({ y: e, m: t, d: n }) => `${e}-${String(t).padStart(2, "0")}-${String(n).padStart(2, "0")}`, Q = ({ y: e, m: t, d: n }) => Date.UTC(e, t - 1, n), cn = (e) => {
1560
+ var $ = ({ y: e, m: t, d: n }) => `${e}-${String(t).padStart(2, "0")}-${String(n).padStart(2, "0")}`, Sn = ({ y: e, m: t, d: n }) => Date.UTC(e, t - 1, n), Cn = (e) => {
1421
1561
  let t = new Date(e);
1422
1562
  return {
1423
1563
  y: t.getUTCFullYear(),
1424
1564
  m: t.getUTCMonth() + 1,
1425
1565
  d: t.getUTCDate()
1426
1566
  };
1427
- }, $ = (e, t) => cn(Q(e) + t * 864e5), ln = (e, t) => {
1567
+ }, wn = (e, t) => Cn(Sn(e) + t * 864e5), Tn = (e, t) => {
1428
1568
  let n = new Date(Date.UTC(e.y, e.m - 1 + t, 1)), r = new Date(Date.UTC(n.getUTCFullYear(), n.getUTCMonth() + 1, 0)).getUTCDate();
1429
1569
  return {
1430
1570
  y: n.getUTCFullYear(),
1431
1571
  m: n.getUTCMonth() + 1,
1432
1572
  d: Math.min(e.d, r)
1433
1573
  };
1434
- }, un = (e) => new Date(Q(e)).getUTCDay();
1435
- function dn(e, t) {
1574
+ }, En = (e) => new Date(Sn(e)).getUTCDay();
1575
+ function Dn(e, t) {
1436
1576
  let n = new Intl.DateTimeFormat("en-US", {
1437
1577
  timeZone: t,
1438
1578
  year: "numeric",
@@ -1452,46 +1592,46 @@ function dn(e, t) {
1452
1592
  s: r("second")
1453
1593
  };
1454
1594
  }
1455
- function fn(e, t, n, r, i, a) {
1595
+ function On(e, t, n, r, i, a) {
1456
1596
  let o = Date.UTC(e.y, e.m - 1, e.d, t, n, r), s = (e) => {
1457
- let t = dn(e, a);
1597
+ let t = Dn(e, a);
1458
1598
  return Date.UTC(t.y, t.m - 1, t.d, t.h, t.mi, t.s) - Math.floor(e / 1e3) * 1e3;
1459
1599
  }, c = o - s(o), l = s(c);
1460
1600
  return o - l !== c && (c = o - l), new Date(c + i);
1461
1601
  }
1462
- var pn = {
1602
+ var kn = {
1463
1603
  on: "bento-status bento-status-on",
1464
1604
  warn: "bento-status bento-status-warn",
1465
1605
  error: "bento-status bento-status-error"
1466
1606
  };
1467
- function mn({ entries: t, view: n, defaultView: r = "month", onViewChange: i, defaultDate: a, timeZone: o = Intl.DateTimeFormat().resolvedOptions().timeZone, weekStartsOn: s = 0, onEntryMove: c, onEntrySelect: l, onRangeChange: u, label: d, className: f }) {
1468
- let { t: p, i18n: m } = q(), h = m?.resolvedLanguage ?? m?.language, g = (e) => {
1469
- let t = dn(new Date(e).getTime(), o);
1607
+ function An({ entries: t, view: n, defaultView: r = "month", onViewChange: i, defaultDate: a, timeZone: o = Intl.DateTimeFormat().resolvedOptions().timeZone, weekStartsOn: s = 0, onEntryMove: c, onEntrySelect: l, onRangeChange: u, label: d, className: f }) {
1608
+ let { t: p, i18n: m } = J(), h = m?.resolvedLanguage ?? m?.language, g = (e) => {
1609
+ let t = Dn(new Date(e).getTime(), o);
1470
1610
  return {
1471
1611
  y: t.y,
1472
1612
  m: t.m,
1473
1613
  d: t.d
1474
1614
  };
1475
- }, [_, v] = H(r), y = n ?? _, [b, x] = H(() => g(a ?? Date.now())), [S, C] = H(null), [w, T] = H(null), [ee, E] = H(""), D = V(/* @__PURE__ */ new Map()), O = V(!1), k = ce(), [A] = H(() => Z(g(Date.now()))), j = (e) => $(e, -((un(e) - s + 7) % 7)), M = j(y === "month" ? {
1615
+ }, [_, v] = W(r), y = n ?? _, [b, x] = W(() => g(a ?? Date.now())), [S, C] = W(null), [w, T] = W(null), [E, D] = W(""), O = U(/* @__PURE__ */ new Map()), k = U(!1), A = H(), [j] = W(() => $(g(Date.now()))), M = (e) => wn(e, -((En(e) - s + 7) % 7)), N = M(y === "month" ? {
1476
1616
  ...b,
1477
1617
  d: 1
1478
- } : b), N = y === "month" ? Math.ceil((Q(ln({
1618
+ } : b), P = y === "month" ? Math.ceil((Sn(Tn({
1479
1619
  ...b,
1480
1620
  d: 1
1481
- }, 1)) - Q(M)) / 6048e5) : 1, te = Array.from({ length: N }, (e, t) => Array.from({ length: 7 }, (e, n) => $(M, t * 7 + n))), P = $(M, N * 7), F = `${Z(M)}/${Z(P)}`;
1482
- B(() => {
1621
+ }, 1)) - Sn(N)) / 6048e5) : 1, F = Array.from({ length: P }, (e, t) => Array.from({ length: 7 }, (e, n) => wn(N, t * 7 + n))), ee = wn(N, P * 7), te = `${$(N)}/${$(ee)}`;
1622
+ V(() => {
1483
1623
  u?.({
1484
- start: fn(M, 0, 0, 0, 0, o),
1485
- end: fn(P, 0, 0, 0, 0, o)
1624
+ start: On(N, 0, 0, 0, 0, o),
1625
+ end: On(ee, 0, 0, 0, 0, o)
1486
1626
  });
1487
- }, [F, o]), B(() => {
1488
- O.current && (O.current = !1, D.current.get(Z(b))?.focus());
1627
+ }, [te, o]), V(() => {
1628
+ k.current && (k.current = !1, O.current.get($(b))?.focus());
1489
1629
  });
1490
1630
  let I = /* @__PURE__ */ new Map();
1491
1631
  for (let e of t) {
1492
1632
  let t = new Date(e.start).getTime();
1493
1633
  if (Number.isNaN(t)) continue;
1494
- let n = Z(g(t)), r = I.get(n) ?? [];
1634
+ let n = $(g(t)), r = I.get(n) ?? [];
1495
1635
  r.push({
1496
1636
  entry: e,
1497
1637
  time: t
@@ -1501,63 +1641,63 @@ function mn({ entries: t, view: n, defaultView: r = "month", onViewChange: i, de
1501
1641
  let L = (e) => new Intl.DateTimeFormat(h, {
1502
1642
  ...e,
1503
1643
  timeZone: "UTC"
1504
- }), ne = (e) => L({ dateStyle: "full" }).format(Q(e)), re = (e) => new Intl.DateTimeFormat(h, {
1644
+ }), ne = (e) => L({ dateStyle: "full" }).format(Sn(e)), R = (e) => new Intl.DateTimeFormat(h, {
1505
1645
  timeStyle: "short",
1506
1646
  timeZone: o
1507
- }).format(e), ie = y === "month" ? L({
1647
+ }).format(e), z = y === "month" ? L({
1508
1648
  month: "long",
1509
1649
  year: "numeric"
1510
- }).format(Q({
1650
+ }).format(Sn({
1511
1651
  ...b,
1512
1652
  d: 1
1513
- })) : `${L({ dateStyle: "medium" }).format(Q(M))} – ${L({ dateStyle: "medium" }).format(Q($(P, -1)))}`;
1514
- function ae(e) {
1515
- O.current = !0, x(e);
1653
+ })) : `${L({ dateStyle: "medium" }).format(Sn(N))} – ${L({ dateStyle: "medium" }).format(Sn(wn(ee, -1)))}`;
1654
+ function B(e) {
1655
+ k.current = !0, x(e);
1516
1656
  }
1517
- function oe(e) {
1657
+ function re(e) {
1518
1658
  n === void 0 && v(e), i?.(e);
1519
1659
  }
1520
- let R = (e) => y === "month" ? ln(b, e) : $(b, 7 * e);
1521
- function z(e, n) {
1660
+ let ie = (e) => y === "month" ? Tn(b, e) : wn(b, 7 * e);
1661
+ function ae(e, n) {
1522
1662
  let r = t.find((t) => t.id === e);
1523
1663
  if (!r || !c) return;
1524
- let i = new Date(r.start).getTime(), a = dn(i, o);
1525
- Z(a) !== Z(n) && c(e, fn(n, a.h, a.mi, a.s, i % 1e3, o)), E(p("bento.calendar.moved", {
1664
+ let i = new Date(r.start).getTime(), a = Dn(i, o);
1665
+ $(a) !== $(n) && c(e, On(n, a.h, a.mi, a.s, i % 1e3, o)), D(p("bento.calendar.moved", {
1526
1666
  defaultValue: "Moved {{label}} to {{day}}.",
1527
1667
  label: r.label,
1528
1668
  day: ne(n)
1529
1669
  }));
1530
1670
  }
1531
- function se(e, n) {
1671
+ function oe(e, n) {
1532
1672
  let r = {
1533
- ArrowLeft: () => $(n, -1),
1534
- ArrowRight: () => $(n, 1),
1535
- ArrowUp: () => $(n, -7),
1536
- ArrowDown: () => $(n, 7),
1537
- Home: () => j(n),
1538
- End: () => $(j(n), 6),
1539
- PageUp: () => R(-1),
1540
- PageDown: () => R(1)
1673
+ ArrowLeft: () => wn(n, -1),
1674
+ ArrowRight: () => wn(n, 1),
1675
+ ArrowUp: () => wn(n, -7),
1676
+ ArrowDown: () => wn(n, 7),
1677
+ Home: () => M(n),
1678
+ End: () => wn(M(n), 6),
1679
+ PageUp: () => ie(-1),
1680
+ PageDown: () => ie(1)
1541
1681
  }[e.key];
1542
1682
  if (r) {
1543
- e.preventDefault(), ae(r());
1683
+ e.preventDefault(), B(r());
1544
1684
  return;
1545
1685
  }
1546
- if (S && (e.key === "Enter" || e.key === " ")) e.preventDefault(), z(S, n), C(null);
1686
+ if (S && (e.key === "Enter" || e.key === " ")) e.preventDefault(), ae(S, n), C(null);
1547
1687
  else if (S && e.key === "Escape") {
1548
1688
  e.preventDefault();
1549
1689
  let n = t.find((e) => e.id === S);
1550
- C(null), E(p("bento.calendar.cancelled", {
1690
+ C(null), D(p("bento.calendar.cancelled", {
1551
1691
  defaultValue: "Put {{label}} back.",
1552
1692
  label: n?.label ?? ""
1553
1693
  }));
1554
1694
  } else e.key === "Enter" && (e.preventDefault(), e.currentTarget.querySelector("button")?.focus());
1555
1695
  }
1556
- function le(e, t) {
1696
+ function se(e, t) {
1557
1697
  let n = e.currentTarget.closest("td"), r = n ? [...n.querySelectorAll("button")] : [], i = r.indexOf(e.currentTarget), a = c && (e.key === " " || e.key === "Enter" && !l);
1558
1698
  if (e.key === "ArrowDown" || e.key === "ArrowUp") r[i + (e.key === "ArrowDown" ? 1 : -1)]?.focus();
1559
1699
  else if (e.key === "Escape") n?.focus();
1560
- else if (a) C(t.id), E(p("bento.calendar.picked", {
1700
+ else if (a) C(t.id), D(p("bento.calendar.picked", {
1561
1701
  defaultValue: "Picked up {{label}}. Choose a day and press Enter.",
1562
1702
  label: t.label
1563
1703
  })), n?.focus();
@@ -1565,86 +1705,86 @@ function mn({ entries: t, view: n, defaultView: r = "month", onViewChange: i, de
1565
1705
  else return;
1566
1706
  e.preventDefault(), e.stopPropagation();
1567
1707
  }
1568
- function U(e, t) {
1708
+ function ce(e, t) {
1569
1709
  let n = w ?? e.dataTransfer.getData("text/plain");
1570
- T(null), n && (e.preventDefault(), z(n, t));
1710
+ T(null), n && (e.preventDefault(), ae(n, t));
1571
1711
  }
1572
- let W = c ? k : void 0;
1573
- return /* @__PURE__ */ K("div", {
1712
+ let le = c ? A : void 0;
1713
+ return /* @__PURE__ */ q("div", {
1574
1714
  "data-slot": "bento-calendar",
1575
1715
  className: e("flex flex-col gap-3", f),
1576
1716
  children: [
1577
- /* @__PURE__ */ K("div", {
1717
+ /* @__PURE__ */ q("div", {
1578
1718
  className: "flex flex-wrap items-center justify-between gap-2",
1579
- children: [/* @__PURE__ */ K("div", {
1719
+ children: [/* @__PURE__ */ q("div", {
1580
1720
  className: "flex items-center gap-1",
1581
1721
  children: [
1582
- /* @__PURE__ */ G(hn, {
1722
+ /* @__PURE__ */ K(jn, {
1583
1723
  label: p("bento.calendar.previous", { defaultValue: "Previous" }),
1584
- onClick: () => x(R(-1)),
1585
- children: /* @__PURE__ */ G(be, {
1724
+ onClick: () => x(ie(-1)),
1725
+ children: /* @__PURE__ */ K(Ce, {
1586
1726
  size: 16,
1587
1727
  "aria-hidden": "true"
1588
1728
  })
1589
1729
  }),
1590
- /* @__PURE__ */ G(hn, {
1730
+ /* @__PURE__ */ K(jn, {
1591
1731
  label: p("bento.calendar.next", { defaultValue: "Next" }),
1592
- onClick: () => x(R(1)),
1593
- children: /* @__PURE__ */ G(Y, {
1732
+ onClick: () => x(ie(1)),
1733
+ children: /* @__PURE__ */ K(we, {
1594
1734
  size: 16,
1595
1735
  "aria-hidden": "true"
1596
1736
  })
1597
1737
  }),
1598
- /* @__PURE__ */ G("button", {
1738
+ /* @__PURE__ */ K("button", {
1599
1739
  type: "button",
1600
1740
  onClick: () => x(g(Date.now())),
1601
- className: "rounded-md border border-border px-2 py-1 text-sm hover:bg-muted/50 focus-visible:outline-2 focus-visible:outline-ring",
1741
+ className: "inline-flex h-(--vg-control-dense) items-center rounded-md border border-border px-3 text-sm hover:bg-muted/50 focus-visible:outline-2 focus-visible:outline-ring",
1602
1742
  children: p("bento.calendar.today", { defaultValue: "Today" })
1603
1743
  }),
1604
- /* @__PURE__ */ G("h2", {
1744
+ /* @__PURE__ */ K("h2", {
1605
1745
  className: "m-0 ml-2 text-base font-semibold",
1606
1746
  "aria-live": "polite",
1607
- children: ie
1747
+ children: z
1608
1748
  })
1609
1749
  ]
1610
- }), /* @__PURE__ */ G("div", {
1750
+ }), /* @__PURE__ */ K("div", {
1611
1751
  role: "group",
1612
1752
  "aria-label": p("bento.calendar.views", { defaultValue: "View" }),
1613
- className: "flex rounded-md border border-border p-0.5",
1614
- children: ["month", "week"].map((t) => /* @__PURE__ */ G("button", {
1753
+ className: "flex gap-1",
1754
+ children: ["month", "week"].map((t) => /* @__PURE__ */ K("button", {
1615
1755
  type: "button",
1616
1756
  "aria-pressed": y === t ? "true" : "false",
1617
- onClick: () => oe(t),
1618
- className: e("rounded-sm px-2 py-0.5 text-sm focus-visible:outline-2 focus-visible:outline-ring", y === t ? "bg-primary text-primary-foreground" : "hover:bg-muted/50"),
1757
+ onClick: () => re(t),
1758
+ className: e("inline-flex h-(--vg-control-dense) items-center rounded-md border border-border px-3 text-sm focus-visible:outline-2 focus-visible:outline-ring", y === t ? "bg-primary text-primary-foreground" : "hover:bg-muted/50"),
1619
1759
  children: t === "month" ? p("bento.calendar.month", { defaultValue: "Month" }) : p("bento.calendar.week", { defaultValue: "Week" })
1620
1760
  }, t))
1621
1761
  })]
1622
1762
  }),
1623
- /* @__PURE__ */ G("span", {
1763
+ /* @__PURE__ */ K("span", {
1624
1764
  role: "status",
1625
1765
  "aria-live": "polite",
1626
1766
  className: "sr-only",
1627
- children: ee
1767
+ children: E
1628
1768
  }),
1629
- W && /* @__PURE__ */ G("span", {
1630
- id: W,
1769
+ le && /* @__PURE__ */ K("span", {
1770
+ id: le,
1631
1771
  className: "sr-only",
1632
1772
  children: p("bento.calendar.moveHint", { defaultValue: "Space picks this up to move it: the arrow keys choose a day, Enter drops it and Escape cancels." })
1633
1773
  }),
1634
- /* @__PURE__ */ K("table", {
1774
+ /* @__PURE__ */ q("table", {
1635
1775
  role: "grid",
1636
- "aria-label": d ?? ie,
1776
+ "aria-label": d ?? z,
1637
1777
  className: "w-full table-fixed border-collapse text-sm",
1638
- children: [/* @__PURE__ */ G("thead", { children: /* @__PURE__ */ G("tr", { children: te[0].map((e) => /* @__PURE__ */ G("th", {
1778
+ children: [/* @__PURE__ */ K("thead", { children: /* @__PURE__ */ K("tr", { children: F[0].map((e) => /* @__PURE__ */ K("th", {
1639
1779
  scope: "col",
1640
- abbr: L({ weekday: "long" }).format(Q(e)),
1780
+ abbr: L({ weekday: "long" }).format(Sn(e)),
1641
1781
  className: "pb-1 text-xs font-medium text-muted-foreground",
1642
- children: L({ weekday: "short" }).format(Q(e))
1643
- }, Z(e))) }) }), /* @__PURE__ */ G("tbody", { children: te.map((t) => /* @__PURE__ */ G("tr", { children: t.map((t) => {
1644
- let n = Z(t), r = I.get(n) ?? [], i = n === Z(b), a = y === "month" && t.m !== b.m, o = r.length;
1645
- return /* @__PURE__ */ K("td", {
1782
+ children: L({ weekday: "short" }).format(Sn(e))
1783
+ }, $(e))) }) }), /* @__PURE__ */ K("tbody", { children: F.map((t) => /* @__PURE__ */ K("tr", { children: t.map((t) => {
1784
+ let n = $(t), r = I.get(n) ?? [], i = n === $(b), a = y === "month" && t.m !== b.m, o = r.length;
1785
+ return /* @__PURE__ */ q("td", {
1646
1786
  ref: (e) => {
1647
- e ? D.current.set(n, e) : D.current.delete(n);
1787
+ e ? O.current.set(n, e) : O.current.delete(n);
1648
1788
  },
1649
1789
  role: "gridcell",
1650
1790
  tabIndex: i ? 0 : -1,
@@ -1652,74 +1792,75 @@ function mn({ entries: t, view: n, defaultView: r = "month", onViewChange: i, de
1652
1792
  defaultValue: "{{count}} scheduled",
1653
1793
  count: o
1654
1794
  })}` : ne(t),
1655
- "aria-current": n === A ? "date" : void 0,
1795
+ "aria-current": n === j ? "date" : void 0,
1656
1796
  "data-day": n,
1657
- onKeyDown: (e) => se(e, t),
1797
+ onKeyDown: (e) => oe(e, t),
1658
1798
  onFocus: () => {
1659
1799
  i || x(t);
1660
1800
  },
1661
1801
  onDragOver: (e) => {
1662
1802
  w && e.preventDefault();
1663
1803
  },
1664
- onDrop: (e) => U(e, t),
1804
+ onDrop: (e) => ce(e, t),
1665
1805
  className: e("border border-border/60 p-1 align-top outline-none", y === "month" ? "h-24" : "h-48", "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring", S && i && "bg-primary/10"),
1666
- children: [/* @__PURE__ */ G("span", {
1806
+ children: [/* @__PURE__ */ K("span", {
1667
1807
  "aria-hidden": "true",
1668
- className: e("mb-1 inline-grid size-6 place-items-center rounded-full text-xs", n === A && "bg-primary font-semibold text-primary-foreground", n !== A && a && "text-muted-foreground"),
1808
+ className: e("mb-1 inline-grid size-6 place-items-center rounded-full text-xs", n === j && "bg-primary font-semibold text-primary-foreground", n !== j && a && "text-muted-foreground"),
1669
1809
  children: t.d
1670
- }), /* @__PURE__ */ G("ul", {
1810
+ }), /* @__PURE__ */ K("ul", {
1671
1811
  className: "m-0 flex list-none flex-col gap-0.5 p-0",
1672
- children: r.map(({ entry: t, time: n }) => /* @__PURE__ */ G("li", { children: /* @__PURE__ */ K("button", {
1812
+ children: r.map(({ entry: t, time: n }) => /* @__PURE__ */ K("li", { children: /* @__PURE__ */ q("button", {
1673
1813
  type: "button",
1814
+ "data-look": "text",
1674
1815
  tabIndex: -1,
1675
1816
  draggable: c ? !0 : void 0,
1676
- "aria-describedby": W,
1817
+ "aria-describedby": le,
1677
1818
  "aria-pressed": c ? S === t.id ? "true" : "false" : void 0,
1678
1819
  "data-entry": t.id,
1679
- onKeyDown: (e) => le(e, t),
1820
+ onKeyDown: (e) => se(e, t),
1680
1821
  onClick: () => l?.(t.id),
1681
1822
  onDragStart: (e) => {
1682
1823
  e.dataTransfer.setData("text/plain", t.id), e.dataTransfer.effectAllowed = "move", T(t.id);
1683
1824
  },
1684
1825
  onDragEnd: () => T(null),
1685
- className: e("flex w-full min-w-0 items-baseline gap-1 rounded-md px-1 py-0.5 text-left text-xs focus-visible:outline-2 focus-visible:outline-ring", t.tone ? pn[t.tone] : "bg-muted", S === t.id && "outline-2 outline-dashed outline-primary"),
1686
- children: [/* @__PURE__ */ G("time", {
1826
+ className: e("flex w-full min-w-0 items-baseline gap-1 rounded-md px-1 py-0.5 text-left text-xs focus-visible:outline-2 focus-visible:outline-ring", t.tone ? kn[t.tone] : "bg-muted", S === t.id && "outline-2 outline-dashed outline-primary"),
1827
+ children: [/* @__PURE__ */ K("time", {
1687
1828
  dateTime: new Date(n).toISOString(),
1688
1829
  className: "flex-none tabular-nums",
1689
- children: re(n)
1690
- }), /* @__PURE__ */ G("span", {
1830
+ children: R(n)
1831
+ }), /* @__PURE__ */ K("span", {
1691
1832
  className: "truncate",
1692
1833
  children: t.label
1693
1834
  })]
1694
1835
  }) }, t.id))
1695
1836
  })]
1696
1837
  }, n);
1697
- }) }, Z(t[0]))) })]
1838
+ }) }, $(t[0]))) })]
1698
1839
  })
1699
1840
  ]
1700
1841
  });
1701
1842
  }
1702
- function hn({ label: e, onClick: t, children: n }) {
1703
- return /* @__PURE__ */ G("button", {
1843
+ function jn({ label: e, onClick: t, children: n }) {
1844
+ return /* @__PURE__ */ K("button", {
1704
1845
  type: "button",
1705
1846
  "aria-label": e,
1706
1847
  onClick: t,
1707
- className: "grid size-7 place-items-center rounded-md border border-border hover:bg-muted/50 focus-visible:outline-2 focus-visible:outline-ring",
1848
+ className: "grid size-(--vg-control-dense) place-items-center rounded-md border border-border hover:bg-muted/50 focus-visible:outline-2 focus-visible:outline-ring",
1708
1849
  children: n
1709
1850
  });
1710
1851
  }
1711
1852
  //#endregion
1712
1853
  //#region src/bento/bento-layout.ts
1713
- var gn = {
1854
+ var Mn = {
1714
1855
  LARGE: "col-span-2 row-span-2 md:col-span-2 md:row-span-2 lg:col-span-2 lg:row-span-2",
1715
1856
  MEDIUM: "col-span-2 row-span-1 md:col-span-2 md:row-span-1 lg:col-span-2 lg:row-span-1",
1716
1857
  SMALL: "col-span-1 row-span-1"
1717
- }, _n = {
1858
+ }, Nn = {
1718
1859
  SMALL: "MEDIUM",
1719
1860
  MEDIUM: "LARGE",
1720
1861
  LARGE: "SMALL"
1721
1862
  };
1722
- function vn(e, t, n) {
1863
+ function Pn(e, t, n) {
1723
1864
  if (!n || n.length === 0) return e.map((e) => ({
1724
1865
  item: e,
1725
1866
  key: t(e),
@@ -1740,7 +1881,7 @@ function vn(e, t, n) {
1740
1881
  emphasis: i.get(t) ?? "MEDIUM"
1741
1882
  }));
1742
1883
  }
1743
- function yn(e) {
1884
+ function Fn(e) {
1744
1885
  return e.map((e, t) => ({
1745
1886
  itemId: e.key,
1746
1887
  emphasis: e.emphasis,
@@ -1749,40 +1890,40 @@ function yn(e) {
1749
1890
  }
1750
1891
  //#endregion
1751
1892
  //#region src/bento/bento-entity-tile.tsx
1752
- function bn({ to: e, emphasis: t, featured: n, defaultIcon: r, icon: i, title: a, description: o, meta: s, state: c, enabled: l, hasStatus: u = !1, viewTransitionName: d }) {
1753
- let { t: f } = q(), p = t ?? (n ? "LARGE" : "MEDIUM"), m = p === "LARGE", h = p === "SMALL", g = gn[p], _ = l === 1, v = m ? "p-6 md:p-7" : h ? "p-4" : "p-5", y = m ? "h-14 w-14" : h ? "h-8 w-8" : "h-9 w-9", b = m ? 28 : h ? 16 : 18, x = m ? "text-xl md:text-2xl" : h ? "text-sm" : "text-base md:text-lg";
1754
- return /* @__PURE__ */ K(He, {
1893
+ function In({ to: e, emphasis: t, featured: n, defaultIcon: r, icon: i, title: a, description: o, meta: s, state: c, enabled: l, hasStatus: u = !1, viewTransitionName: d }) {
1894
+ let { t: f } = J(), p = t ?? (n ? "LARGE" : "MEDIUM"), m = p === "LARGE", h = p === "SMALL", g = Mn[p], _ = l === 1, v = m ? "p-6 md:p-7" : h ? "p-4" : "p-5", y = m ? "h-14 w-14" : h ? "h-8 w-8" : "h-9 w-9", b = m ? 28 : h ? 16 : 18, x = m ? "text-xl md:text-2xl" : h ? "text-sm" : "text-base md:text-lg";
1895
+ return /* @__PURE__ */ q(Ke, {
1755
1896
  to: e,
1756
1897
  className: `bento-tile bento-tile-clickable bento-glass group relative flex flex-col ${m ? "gap-5" : "gap-4"} overflow-hidden ${v} ${g}`,
1757
1898
  style: d ? { viewTransitionName: d } : void 0,
1758
- children: [/* @__PURE__ */ K("div", {
1899
+ children: [/* @__PURE__ */ q("div", {
1759
1900
  className: "relative z-1 flex items-center justify-between",
1760
- children: [/* @__PURE__ */ G("span", {
1901
+ children: [/* @__PURE__ */ K("span", {
1761
1902
  className: `bento-well grid place-items-center rounded-2xl ${y}`,
1762
- children: i ? /* @__PURE__ */ G(Be, {
1903
+ children: i ? /* @__PURE__ */ K(We, {
1763
1904
  icon: i,
1764
1905
  className: m ? "size-7" : "size-4.5"
1765
- }) : /* @__PURE__ */ G(r, { size: b })
1766
- }), u && /* @__PURE__ */ K("span", {
1906
+ }) : /* @__PURE__ */ K(r, { size: b })
1907
+ }), u && /* @__PURE__ */ q("span", {
1767
1908
  className: `flex items-center gap-1.5 rounded-full border px-2 py-0.5 text-[10px] uppercase tracking-wider ${_ ? "bento-status bento-status-on" : "border-border bg-muted text-muted-foreground"}`,
1768
- children: [/* @__PURE__ */ G("span", { className: `h-1.5 w-1.5 rounded-full ${_ ? "bento-status-dot bento-pulse" : "bg-muted-foreground/60"}` }), _ ? f("common.active", { defaultValue: "Active" }) : f("common.idle", { defaultValue: "Idle" })]
1909
+ children: [/* @__PURE__ */ K("span", { className: `h-1.5 w-1.5 rounded-full ${_ ? "bento-status-dot bento-pulse" : "bg-muted-foreground/60"}` }), _ ? f("common.active", { defaultValue: "Active" }) : f("common.idle", { defaultValue: "Idle" })]
1769
1910
  })]
1770
- }), /* @__PURE__ */ K("div", {
1911
+ }), /* @__PURE__ */ q("div", {
1771
1912
  className: "relative z-1",
1772
1913
  children: [
1773
- /* @__PURE__ */ G("div", {
1914
+ /* @__PURE__ */ K("div", {
1774
1915
  className: `font-semibold tracking-tight ${x}`,
1775
1916
  children: a
1776
1917
  }),
1777
- !h && s && /* @__PURE__ */ G("div", {
1918
+ !h && s && /* @__PURE__ */ K("div", {
1778
1919
  className: "mt-1 flex flex-wrap items-center gap-1.5 text-xs text-muted-foreground",
1779
1920
  children: s
1780
1921
  }),
1781
- !h && o && /* @__PURE__ */ G("p", {
1922
+ !h && o && /* @__PURE__ */ K("p", {
1782
1923
  className: "mt-2 text-sm text-muted-foreground",
1783
1924
  children: o
1784
1925
  }),
1785
- c && /* @__PURE__ */ G(Dt, {
1926
+ c && /* @__PURE__ */ K(Nt, {
1786
1927
  state: c,
1787
1928
  className: "mt-3"
1788
1929
  })
@@ -1792,99 +1933,99 @@ function bn({ to: e, emphasis: t, featured: n, defaultIcon: r, icon: i, title: a
1792
1933
  }
1793
1934
  //#endregion
1794
1935
  //#region src/bento/bento-filter-bar.tsx
1795
- var xn = {
1936
+ var Ln = {
1796
1937
  query: "",
1797
1938
  facets: {}
1798
- }, Sn = (e) => typeof e == "object" && !!e && !Array.isArray(e), Cn = (e) => Array.isArray(e) ? e : [];
1799
- function wn(e, t, n) {
1939
+ }, Rn = (e) => typeof e == "object" && !!e && !Array.isArray(e), zn = (e) => Array.isArray(e) ? e : [];
1940
+ function Bn(e, t, n) {
1800
1941
  let r = { ...e.facets };
1801
- return n === void 0 || Array.isArray(n) && n.length === 0 || Sn(n) && !n.from && !n.to ? delete r[t] : r[t] = n, {
1942
+ return n === void 0 || Array.isArray(n) && n.length === 0 || Rn(n) && !n.from && !n.to ? delete r[t] : r[t] = n, {
1802
1943
  ...e,
1803
1944
  facets: r
1804
1945
  };
1805
1946
  }
1806
- function Tn({ value: e, onChange: n, facets: r, queryLabel: i, queryDelay: a = 300, views: o }) {
1807
- let { t: s } = q(), [c, l] = H({
1947
+ function Vn({ value: e, onChange: n, facets: r, queryLabel: i, queryDelay: a = 300, views: o }) {
1948
+ let { t: s } = J(), [l, u] = W({
1808
1949
  source: e.query,
1809
1950
  text: e.query
1810
- }), [u, d] = H(null);
1811
- c.source !== e.query && l({
1951
+ }), [d, f] = W(null);
1952
+ l.source !== e.query && u({
1812
1953
  source: e.query,
1813
- text: e.query === u ? c.text : e.query
1814
- }), B(() => {
1815
- if (c.text === e.query) return;
1954
+ text: e.query === d ? l.text : e.query
1955
+ }), V(() => {
1956
+ if (l.text === e.query) return;
1816
1957
  let t = setTimeout(() => {
1817
- d(c.text), n({
1958
+ f(l.text), n({
1818
1959
  ...e,
1819
- query: c.text
1960
+ query: l.text
1820
1961
  });
1821
1962
  }, a);
1822
1963
  return () => clearTimeout(t);
1823
1964
  }, [
1824
- c.text,
1965
+ l.text,
1825
1966
  e,
1826
1967
  n,
1827
1968
  a
1828
1969
  ]);
1829
- let f = [];
1970
+ let p = [];
1830
1971
  for (let t of r) {
1831
1972
  let n = e.facets[t.id];
1832
- if (t.kind === "choice") for (let r of Cn(n)) {
1973
+ if (t.kind === "choice") for (let r of zn(n)) {
1833
1974
  let i = t.options.find((e) => e.value === r);
1834
- f.push({
1975
+ p.push({
1835
1976
  key: `${t.id}:${r}`,
1836
1977
  text: `${t.label}: ${i?.label ?? r}`,
1837
- remove: () => wn(e, t.id, Cn(n).filter((e) => e !== r))
1978
+ remove: () => Bn(e, t.id, zn(n).filter((e) => e !== r))
1838
1979
  });
1839
1980
  }
1840
- else Sn(n) && (n.from || n.to) && f.push({
1981
+ else Rn(n) && (n.from || n.to) && p.push({
1841
1982
  key: t.id,
1842
1983
  text: `${t.label}: ${n.from ?? "…"} – ${n.to ?? "…"}`,
1843
- remove: () => wn(e, t.id, void 0)
1984
+ remove: () => Bn(e, t.id, void 0)
1844
1985
  });
1845
1986
  }
1846
- let p = f.length > 0 || e.query !== "", m = i ?? s("bento.filters.search", { defaultValue: "Search" });
1847
- return /* @__PURE__ */ K("div", {
1987
+ let m = p.length > 0 || e.query !== "", h = i ?? s("bento.filters.search", { defaultValue: "Search" });
1988
+ return /* @__PURE__ */ q("div", {
1848
1989
  role: "search",
1849
1990
  "aria-label": s("bento.filters.label", { defaultValue: "Filters" }),
1850
1991
  "data-slot": "bento-filter-bar",
1851
- className: "flex flex-col gap-2",
1852
- children: [/* @__PURE__ */ K("div", {
1992
+ className: "flex min-w-0 flex-1 flex-col gap-2",
1993
+ children: [/* @__PURE__ */ q("div", {
1853
1994
  className: "flex flex-wrap items-center gap-2",
1854
1995
  children: [
1855
- /* @__PURE__ */ K("div", {
1996
+ /* @__PURE__ */ q("div", {
1856
1997
  className: "relative min-w-48 flex-1",
1857
- children: [/* @__PURE__ */ G(Ne, {
1998
+ children: [/* @__PURE__ */ K(Le, {
1858
1999
  size: 16,
1859
2000
  "aria-hidden": "true",
1860
2001
  className: "pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"
1861
- }), /* @__PURE__ */ G(t, {
2002
+ }), /* @__PURE__ */ K(t, {
1862
2003
  type: "search",
1863
- value: c.text,
1864
- placeholder: m,
1865
- "aria-label": m,
1866
- onChange: (e) => l({
1867
- ...c,
2004
+ value: l.text,
2005
+ placeholder: h,
2006
+ "aria-label": h,
2007
+ onChange: (e) => u({
2008
+ ...l,
1868
2009
  text: e.target.value
1869
2010
  }),
1870
2011
  className: "pl-9"
1871
2012
  })]
1872
2013
  }),
1873
- r.map((t) => t.kind === "choice" ? /* @__PURE__ */ G(Dn, {
2014
+ r.map((t) => t.kind === "choice" ? /* @__PURE__ */ K(Un, {
1874
2015
  facet: t,
1875
2016
  value: e,
1876
2017
  onChange: n
1877
- }, t.id) : /* @__PURE__ */ G(On, {
2018
+ }, t.id) : /* @__PURE__ */ K(Wn, {
1878
2019
  facet: t,
1879
2020
  value: e,
1880
2021
  onChange: n
1881
2022
  }, t.id)),
1882
2023
  o
1883
2024
  ]
1884
- }), p && /* @__PURE__ */ K("ul", {
2025
+ }), m && /* @__PURE__ */ q("ul", {
1885
2026
  className: "m-0 flex list-none flex-wrap items-center gap-1.5 p-0",
1886
2027
  "aria-label": s("bento.filters.active", { defaultValue: "Active filters" }),
1887
- children: [f.map((e) => /* @__PURE__ */ G("li", { children: /* @__PURE__ */ K("button", {
2028
+ children: [p.map((e) => /* @__PURE__ */ K("li", { children: /* @__PURE__ */ q("button", {
1888
2029
  type: "button",
1889
2030
  "aria-label": s("bento.filters.remove", {
1890
2031
  defaultValue: "Remove filter {{filter}}",
@@ -1892,120 +2033,120 @@ function Tn({ value: e, onChange: n, facets: r, queryLabel: i, queryDelay: a = 3
1892
2033
  }),
1893
2034
  onClick: () => n(e.remove()),
1894
2035
  className: "bento-clear inline-flex items-center gap-1 rounded-full border border-border/60 bg-card/60 py-0.5 pl-2.5 pr-1.5 text-xs",
1895
- children: [e.text, /* @__PURE__ */ G(ze, {
2036
+ children: [e.text, /* @__PURE__ */ K(Ue, {
1896
2037
  size: 12,
1897
2038
  "aria-hidden": "true"
1898
2039
  })]
1899
- }) }, e.key)), /* @__PURE__ */ G("li", { children: /* @__PURE__ */ G(C, {
2040
+ }) }, e.key)), /* @__PURE__ */ K("li", { children: /* @__PURE__ */ K(c, {
1900
2041
  variant: "ghost",
1901
2042
  size: "sm",
1902
2043
  className: "h-6 px-2 text-xs",
1903
2044
  onClick: () => {
1904
- l({
2045
+ u({
1905
2046
  source: "",
1906
2047
  text: ""
1907
- }), n(xn);
2048
+ }), n(Ln);
1908
2049
  },
1909
2050
  children: s("bento.filters.clearAll", { defaultValue: "Clear all" })
1910
2051
  }) })]
1911
2052
  })]
1912
2053
  });
1913
2054
  }
1914
- function En({ label: e, count: t, ...n }) {
1915
- return /* @__PURE__ */ K(C, {
2055
+ function Hn({ label: e, count: t, ...n }) {
2056
+ return /* @__PURE__ */ q(c, {
1916
2057
  variant: "outline",
1917
2058
  size: "sm",
1918
2059
  className: "gap-1.5",
1919
2060
  ...n,
1920
2061
  children: [
1921
2062
  e,
1922
- t > 0 && /* @__PURE__ */ G("span", {
2063
+ t > 0 && /* @__PURE__ */ K("span", {
1923
2064
  className: "rounded-full bg-primary px-1.5 text-[0.6875rem] leading-4 text-primary-foreground",
1924
2065
  children: t
1925
2066
  }),
1926
- /* @__PURE__ */ G(ye, {
2067
+ /* @__PURE__ */ K(Se, {
1927
2068
  size: 14,
1928
2069
  "aria-hidden": "true"
1929
2070
  })
1930
2071
  ]
1931
2072
  });
1932
2073
  }
1933
- function Dn({ facet: e, value: t, onChange: n }) {
1934
- let r = Cn(t.facets[e.id]);
1935
- return /* @__PURE__ */ K(_, { children: [/* @__PURE__ */ G(P, {
2074
+ function Un({ facet: e, value: t, onChange: n }) {
2075
+ let r = zn(t.facets[e.id]);
2076
+ return /* @__PURE__ */ q(v, { children: [/* @__PURE__ */ K(T, {
1936
2077
  asChild: !0,
1937
- children: /* @__PURE__ */ G(En, {
2078
+ children: /* @__PURE__ */ K(Hn, {
1938
2079
  label: e.label,
1939
2080
  count: r.length
1940
2081
  })
1941
- }), /* @__PURE__ */ G(d, {
2082
+ }), /* @__PURE__ */ K(ie, {
1942
2083
  align: "start",
1943
2084
  className: "bento-dropdown min-w-44 p-1.5",
1944
- children: e.multiple ? e.options.map((i) => /* @__PURE__ */ G(v, {
2085
+ children: e.multiple ? e.options.map((i) => /* @__PURE__ */ K(x, {
1945
2086
  checked: r.includes(i.value),
1946
- onCheckedChange: (a) => n(wn(t, e.id, a === !0 ? [...r, i.value] : r.filter((e) => e !== i.value))),
2087
+ onCheckedChange: (a) => n(Bn(t, e.id, a === !0 ? [...r, i.value] : r.filter((e) => e !== i.value))),
1947
2088
  onSelect: (e) => e.preventDefault(),
1948
2089
  children: i.label
1949
- }, i.value)) : /* @__PURE__ */ G(c, {
2090
+ }, i.value)) : /* @__PURE__ */ K(w, {
1950
2091
  value: r[0] ?? "",
1951
- onValueChange: (i) => n(wn(t, e.id, i === r[0] ? [] : [i])),
1952
- children: e.options.map((e) => /* @__PURE__ */ G(S, {
2092
+ onValueChange: (i) => n(Bn(t, e.id, i === r[0] ? [] : [i])),
2093
+ children: e.options.map((e) => /* @__PURE__ */ K(m, {
1953
2094
  value: e.value,
1954
2095
  children: e.label
1955
2096
  }, e.value))
1956
2097
  })
1957
2098
  })] });
1958
2099
  }
1959
- function On({ facet: e, value: n, onChange: r }) {
1960
- let { t: i } = q(), a = n.facets[e.id], o = Sn(a) ? a : {}, [s, c] = H(!1), [l, d] = H(o.from ?? ""), [f, p] = H(o.to ?? ""), m = ce(), h = ce();
1961
- return /* @__PURE__ */ K(x, {
2100
+ function Wn({ facet: e, value: n, onChange: r }) {
2101
+ let { t: i } = J(), a = n.facets[e.id], o = Rn(a) ? a : {}, [s, l] = W(!1), [u, d] = W(o.from ?? ""), [f, m] = W(o.to ?? ""), h = H(), g = H();
2102
+ return /* @__PURE__ */ q(M, {
1962
2103
  open: s,
1963
2104
  onOpenChange: (e) => {
1964
- e && (d(o.from ?? ""), p(o.to ?? "")), c(e);
2105
+ e && (d(o.from ?? ""), m(o.to ?? "")), l(e);
1965
2106
  },
1966
- children: [/* @__PURE__ */ G(A, {
2107
+ children: [/* @__PURE__ */ K(p, {
1967
2108
  asChild: !0,
1968
- children: /* @__PURE__ */ G(En, {
2109
+ children: /* @__PURE__ */ K(Hn, {
1969
2110
  label: e.label,
1970
2111
  count: o.from || o.to ? 1 : 0
1971
2112
  })
1972
- }), /* @__PURE__ */ G(u, {
2113
+ }), /* @__PURE__ */ K(j, {
1973
2114
  align: "start",
1974
2115
  className: "bento-dropdown w-64 p-3",
1975
- children: /* @__PURE__ */ K("form", {
2116
+ children: /* @__PURE__ */ q("form", {
1976
2117
  className: "flex flex-col gap-2",
1977
2118
  onSubmit: (t) => {
1978
- t.preventDefault(), r(wn(n, e.id, {
1979
- from: l || void 0,
2119
+ t.preventDefault(), r(Bn(n, e.id, {
2120
+ from: u || void 0,
1980
2121
  to: f || void 0
1981
- })), c(!1);
2122
+ })), l(!1);
1982
2123
  },
1983
2124
  children: [
1984
- /* @__PURE__ */ G("label", {
1985
- htmlFor: m,
2125
+ /* @__PURE__ */ K("label", {
2126
+ htmlFor: h,
1986
2127
  className: "text-xs text-muted-foreground",
1987
2128
  children: i("bento.filters.from", { defaultValue: "From" })
1988
2129
  }),
1989
- /* @__PURE__ */ G(t, {
1990
- id: m,
2130
+ /* @__PURE__ */ K(t, {
2131
+ id: h,
1991
2132
  type: "date",
1992
- value: l,
2133
+ value: u,
1993
2134
  max: f || void 0,
1994
2135
  onChange: (e) => d(e.target.value)
1995
2136
  }),
1996
- /* @__PURE__ */ G("label", {
1997
- htmlFor: h,
2137
+ /* @__PURE__ */ K("label", {
2138
+ htmlFor: g,
1998
2139
  className: "text-xs text-muted-foreground",
1999
2140
  children: i("bento.filters.to", { defaultValue: "To" })
2000
2141
  }),
2001
- /* @__PURE__ */ G(t, {
2002
- id: h,
2142
+ /* @__PURE__ */ K(t, {
2143
+ id: g,
2003
2144
  type: "date",
2004
2145
  value: f,
2005
- min: l || void 0,
2006
- onChange: (e) => p(e.target.value)
2146
+ min: u || void 0,
2147
+ onChange: (e) => m(e.target.value)
2007
2148
  }),
2008
- /* @__PURE__ */ G(C, {
2149
+ /* @__PURE__ */ K(c, {
2009
2150
  type: "submit",
2010
2151
  size: "sm",
2011
2152
  className: "mt-1",
@@ -2018,128 +2159,152 @@ function On({ facet: e, value: n, onChange: r }) {
2018
2159
  }
2019
2160
  //#endregion
2020
2161
  //#region src/bento/bento-list-page.tsx
2021
- var kn = _t, An = "bento-grid grid auto-rows-[minmax(140px,auto)] grid-cols-2 gap-4 md:grid-cols-4 md:gap-5 lg:grid-cols-6";
2022
- function jn({ items: e, error: t, tryAgainUrl: n, listId: r, eyebrow: i, backTo: a, backLabel: o, trail: s, heroIcon: c, title: l, subtitle: u, headerAction: d, newRoute: f, newLabel: p, newSubtitle: m, hideNew: h = !1, itemKey: g, columns: _, rowActions: v, onRowOpen: y, getRowLabel: b, columnLayout: x, onColumnLayoutChange: S, renderTile: w, emptyTitle: T, emptyDescription: ee, layout: E }) {
2023
- let { t: D } = q(), [O, k] = H(!1), A = le(() => vn(e ?? [], g, E?.data?.entries), [
2024
- e,
2025
- g,
2026
- E?.data?.entries
2027
- ]), j = c ? /* @__PURE__ */ G("span", {
2162
+ var Gn = Ct, Kn = "bento-grid grid auto-rows-[minmax(140px,auto)] grid-cols-2 gap-4 md:grid-cols-4 md:gap-5 lg:grid-cols-6";
2163
+ function qn({ items: t, error: n, tryAgainUrl: r, listId: i, eyebrow: a, backTo: o, backLabel: s, trail: l, heroIcon: u, title: d, subtitle: f, toolbar: p, headerAction: m, newRoute: h, newLabel: g, newSubtitle: _, hideNew: v = !1, itemKey: y, columns: b, rowActions: x, onRowOpen: S, getRowLabel: C, columnLayout: w, onColumnLayoutChange: T, renderTile: E, defaultView: D = "list", view: O, onViewChange: k, emptyTitle: A, emptyDescription: j, layout: M }) {
2164
+ let { t: P } = J(), [F, ee] = W(!1), [te, I] = W(D), L = p ?? m, R = E !== void 0 && b !== void 0, z = E ? "grid" : "list";
2165
+ R && (z = O ?? te);
2166
+ let B = R ? /* @__PURE__ */ q(N, {
2167
+ type: "single",
2168
+ size: "sm",
2169
+ variant: "outline",
2170
+ value: z,
2171
+ onValueChange: (e) => {
2172
+ (e === "grid" || e === "list") && (O === void 0 && I(e), k?.(e));
2173
+ },
2174
+ "aria-label": P("bento.layout.view", { defaultValue: "View" }),
2175
+ className: "ml-auto",
2176
+ children: [/* @__PURE__ */ K(ne, {
2177
+ value: "grid",
2178
+ "aria-label": P("bento.layout.grid", { defaultValue: "Grid" }),
2179
+ children: /* @__PURE__ */ K(Me, {
2180
+ size: 16,
2181
+ "aria-hidden": "true"
2182
+ })
2183
+ }), /* @__PURE__ */ K(ne, {
2184
+ value: "list",
2185
+ "aria-label": P("bento.layout.list", { defaultValue: "List" }),
2186
+ children: /* @__PURE__ */ K(Ne, {
2187
+ size: 16,
2188
+ "aria-hidden": "true"
2189
+ })
2190
+ })]
2191
+ }) : null, re = L != null || B != null ? /* @__PURE__ */ q(G, { children: [L, B] }) : void 0, ie = fe(() => Pn(t ?? [], y, M?.data?.entries), [
2192
+ t,
2193
+ y,
2194
+ M?.data?.entries
2195
+ ]), ae = u ? /* @__PURE__ */ K("span", {
2028
2196
  className: "bento-well grid h-12 w-12 place-items-center rounded-2xl",
2029
- children: /* @__PURE__ */ G(c, { size: 24 })
2197
+ children: /* @__PURE__ */ K(u, { size: 24 })
2030
2198
  }) : void 0;
2031
- if (!w) return /* @__PURE__ */ K(oe, {
2032
- checkIsNotUndefined: e,
2033
- error: t ?? null,
2034
- tryAgainUrl: n,
2035
- children: [
2036
- /* @__PURE__ */ G(Ct, {
2037
- eyebrow: i,
2038
- backTo: a,
2039
- backLabel: o,
2040
- trail: s,
2041
- leading: j,
2042
- title: l,
2043
- subtitle: u,
2044
- trailing: h ? void 0 : /* @__PURE__ */ G(C, {
2045
- asChild: !0,
2046
- className: "gap-2",
2047
- children: /* @__PURE__ */ K(He, {
2048
- to: f,
2049
- children: [/* @__PURE__ */ G(je, { size: 16 }), p]
2050
- })
2199
+ if (z === "list" || !E) return /* @__PURE__ */ q(oe, {
2200
+ checkIsNotUndefined: t,
2201
+ error: n ?? null,
2202
+ tryAgainUrl: r,
2203
+ children: [/* @__PURE__ */ K(kt, {
2204
+ eyebrow: a,
2205
+ backTo: o,
2206
+ backLabel: s,
2207
+ trail: l,
2208
+ leading: ae,
2209
+ title: d,
2210
+ subtitle: f,
2211
+ trailing: v ? void 0 : /* @__PURE__ */ K(c, {
2212
+ asChild: !0,
2213
+ className: "gap-2",
2214
+ children: /* @__PURE__ */ q(Ke, {
2215
+ to: h,
2216
+ children: [/* @__PURE__ */ K(Z, { size: 16 }), g]
2051
2217
  })
2052
- }),
2053
- d && /* @__PURE__ */ G("div", {
2054
- className: "mb-4 flex flex-wrap items-center gap-2",
2055
- children: d
2056
- }),
2057
- e?.length === 0 ? /* @__PURE__ */ G(vt, {
2058
- icon: Pe,
2059
- title: T,
2060
- description: ee
2061
- }) : /* @__PURE__ */ G(kn, {
2062
- rows: e ?? [],
2063
- getRowId: g,
2064
- columns: _ ?? [],
2065
- label: l,
2066
- getRowLabel: b,
2067
- rowActions: v,
2068
- onRowOpen: y,
2069
- layout: x,
2070
- onLayoutChange: S
2071
2218
  })
2072
- ]
2219
+ }), t?.length === 0 ? /* @__PURE__ */ q(G, { children: [re != null && /* @__PURE__ */ K("div", {
2220
+ className: "mb-4 flex flex-wrap items-center gap-2",
2221
+ children: re
2222
+ }), /* @__PURE__ */ K(wt, {
2223
+ icon: Re,
2224
+ title: A,
2225
+ description: j
2226
+ })] }) : /* @__PURE__ */ K(Gn, {
2227
+ rows: t ?? [],
2228
+ getRowId: y,
2229
+ columns: b ?? [],
2230
+ label: d,
2231
+ getRowLabel: C,
2232
+ rowActions: x,
2233
+ onRowOpen: S,
2234
+ layout: w,
2235
+ onLayoutChange: T,
2236
+ toolbar: re
2237
+ })]
2073
2238
  });
2074
- let M = !!r && !!E && (e?.length ?? 0) > 0;
2075
- return /* @__PURE__ */ K(oe, {
2076
- checkIsNotUndefined: e,
2077
- error: t ?? null,
2078
- tryAgainUrl: n,
2239
+ let se = !!i && !!M && (t?.length ?? 0) > 0;
2240
+ return /* @__PURE__ */ q(oe, {
2241
+ checkIsNotUndefined: t,
2242
+ error: n ?? null,
2243
+ tryAgainUrl: r,
2079
2244
  children: [
2080
- /* @__PURE__ */ G(Ct, {
2081
- eyebrow: i,
2082
- backTo: a,
2083
- backLabel: o,
2084
- trail: s,
2085
- leading: j,
2086
- title: l,
2087
- subtitle: u
2245
+ /* @__PURE__ */ K(kt, {
2246
+ eyebrow: a,
2247
+ backTo: o,
2248
+ backLabel: s,
2249
+ trail: l,
2250
+ leading: ae,
2251
+ title: d,
2252
+ subtitle: f
2088
2253
  }),
2089
- (d || M && !O) && /* @__PURE__ */ K("div", {
2254
+ (re != null || se && !F) && /* @__PURE__ */ q("div", {
2090
2255
  className: "mb-4 flex flex-wrap items-center gap-2",
2091
- children: [d, M && !O && /* @__PURE__ */ K(C, {
2256
+ children: [re, se && !F && /* @__PURE__ */ q(c, {
2092
2257
  variant: "outline",
2093
2258
  size: "sm",
2094
- onClick: () => k(!0),
2095
- className: "ml-auto gap-2",
2096
- children: [/* @__PURE__ */ G(ue, { size: 16 }), D("bento.layout.customize", { defaultValue: "Customize layout" })]
2259
+ onClick: () => ee(!0),
2260
+ className: e("gap-2", B == null && "ml-auto"),
2261
+ children: [/* @__PURE__ */ K(Y, { size: 16 }), P("bento.layout.customize", { defaultValue: "Customize layout" })]
2097
2262
  })]
2098
2263
  }),
2099
- O && r && E ? /* @__PURE__ */ G(Pn, {
2100
- layout: E,
2101
- resolved: A,
2102
- canEditGlobal: E?.data?.canEditGlobal ?? !1,
2103
- isCustomized: E?.data?.source === "USER",
2104
- renderTile: w,
2105
- hideNew: h,
2106
- newRoute: f,
2107
- newLabel: p,
2108
- newSubtitle: m,
2109
- onClose: () => k(!1)
2110
- }) : /* @__PURE__ */ G(Nn, {
2111
- resolved: A,
2112
- renderTile: w,
2113
- hideNew: h,
2114
- newRoute: f,
2115
- newLabel: p,
2116
- newSubtitle: m,
2117
- isEmpty: e?.length === 0,
2118
- emptyTitle: T,
2119
- emptyDescription: ee
2264
+ F && i && M ? /* @__PURE__ */ K(Xn, {
2265
+ layout: M,
2266
+ resolved: ie,
2267
+ canEditGlobal: M?.data?.canEditGlobal ?? !1,
2268
+ isCustomized: M?.data?.source === "USER",
2269
+ renderTile: E,
2270
+ hideNew: v,
2271
+ newRoute: h,
2272
+ newLabel: g,
2273
+ newSubtitle: _,
2274
+ onClose: () => ee(!1)
2275
+ }) : /* @__PURE__ */ K(Yn, {
2276
+ resolved: ie,
2277
+ renderTile: E,
2278
+ hideNew: v,
2279
+ newRoute: h,
2280
+ newLabel: g,
2281
+ newSubtitle: _,
2282
+ isEmpty: t?.length === 0,
2283
+ emptyTitle: A,
2284
+ emptyDescription: j
2120
2285
  })
2121
2286
  ]
2122
2287
  });
2123
2288
  }
2124
- function Mn({ items: e, error: t, tryAgainUrl: n, newRoute: r, newLabel: i, newSubtitle: a, hideNew: o = !1, itemKey: s, renderTile: c, emptyTitle: l, emptyDescription: u }) {
2125
- return /* @__PURE__ */ G(oe, {
2289
+ function Jn({ items: e, error: t, tryAgainUrl: n, newRoute: r, newLabel: i, newSubtitle: a, hideNew: o = !1, itemKey: s, renderTile: c, emptyTitle: l, emptyDescription: u }) {
2290
+ return /* @__PURE__ */ K(oe, {
2126
2291
  checkIsNotUndefined: e,
2127
2292
  error: t ?? null,
2128
2293
  tryAgainUrl: n,
2129
- children: /* @__PURE__ */ K("div", {
2294
+ children: /* @__PURE__ */ q("div", {
2130
2295
  "data-slot": "bento-list-tiles",
2131
- className: An,
2296
+ className: Kn,
2132
2297
  children: [
2133
- !o && r && i ? /* @__PURE__ */ G(Rn, {
2298
+ !o && r && i ? /* @__PURE__ */ K(er, {
2134
2299
  route: r,
2135
2300
  label: i,
2136
2301
  subtitle: a
2137
2302
  }) : null,
2138
- (e ?? []).map((e) => /* @__PURE__ */ G("span", {
2303
+ (e ?? []).map((e) => /* @__PURE__ */ K("span", {
2139
2304
  className: "contents",
2140
2305
  children: c(e)
2141
2306
  }, s(e))),
2142
- e?.length === 0 && /* @__PURE__ */ G(zn, {
2307
+ e?.length === 0 && /* @__PURE__ */ K(tr, {
2143
2308
  title: l,
2144
2309
  description: u
2145
2310
  })
@@ -2147,114 +2312,114 @@ function Mn({ items: e, error: t, tryAgainUrl: n, newRoute: r, newLabel: i, newS
2147
2312
  })
2148
2313
  });
2149
2314
  }
2150
- function Nn({ resolved: t, renderTile: n, hideNew: r, newRoute: i, newLabel: a, newSubtitle: o, isEmpty: s, emptyTitle: c, emptyDescription: l }) {
2315
+ function Yn({ resolved: t, renderTile: n, hideNew: r, newRoute: i, newLabel: a, newSubtitle: o, isEmpty: s, emptyTitle: c, emptyDescription: l }) {
2151
2316
  let u = t.some((e) => e.emphasis === "SMALL");
2152
- return /* @__PURE__ */ K("div", {
2317
+ return /* @__PURE__ */ q("div", {
2153
2318
  "data-slot": "bento-list-tiles",
2154
- className: e(An, u && "grid-flow-dense"),
2319
+ className: e(Kn, u && "grid-flow-dense"),
2155
2320
  children: [
2156
- !r && /* @__PURE__ */ G(Rn, {
2321
+ !r && /* @__PURE__ */ K(er, {
2157
2322
  route: i,
2158
2323
  label: a,
2159
2324
  subtitle: o
2160
2325
  }),
2161
- t.map(({ item: e, key: t, emphasis: r }) => /* @__PURE__ */ G("span", {
2326
+ t.map(({ item: e, key: t, emphasis: r }) => /* @__PURE__ */ K("span", {
2162
2327
  className: "contents",
2163
2328
  children: n(e, r)
2164
2329
  }, t)),
2165
- s && /* @__PURE__ */ G(zn, {
2330
+ s && /* @__PURE__ */ K(tr, {
2166
2331
  title: c,
2167
2332
  description: l
2168
2333
  })
2169
2334
  ]
2170
2335
  });
2171
2336
  }
2172
- function Pn({ layout: t, resolved: n, canEditGlobal: r, isCustomized: i, renderTile: a, hideNew: o, newRoute: s, newLabel: c, newSubtitle: l, onClose: u }) {
2173
- let { t: d } = q(), [f, p] = H(n), [m, h] = H(null), g = (t.saving ?? !1) || m !== null, _ = (e) => g && m === e ? { loading: !0 } : { "aria-disabled": g || void 0 }, [v, y] = H(!1), b = (e, t) => async () => {
2337
+ function Xn({ layout: t, resolved: n, canEditGlobal: r, isCustomized: i, renderTile: a, hideNew: o, newRoute: s, newLabel: l, newSubtitle: u, onClose: d }) {
2338
+ let { t: f } = J(), [p, m] = W(n), [h, g] = W(null), _ = (t.saving ?? !1) || h !== null, v = (e) => _ && h === e ? { loading: !0 } : { "aria-disabled": _ || void 0 }, [y, b] = W(!1), x = (e, t) => async () => {
2174
2339
  if (t) {
2175
- h(e), y(!1);
2340
+ g(e), b(!1);
2176
2341
  try {
2177
- await t(), u();
2342
+ await t(), d();
2178
2343
  } catch (e) {
2179
- console.error("Failed to save the bento layout", e), y(!0);
2344
+ console.error("Failed to save the bento layout", e), b(!0);
2180
2345
  } finally {
2181
- h(null);
2346
+ g(null);
2182
2347
  }
2183
2348
  }
2184
- }, x = tt(et(Qe, { activationConstraint: { distance: 8 } }), et(Ze));
2185
- function S(e) {
2349
+ }, S = at(it(nt, { activationConstraint: { distance: 8 } }), it(tt));
2350
+ function C(e) {
2186
2351
  let { active: t, over: n } = e;
2187
- n && t.id !== n.id && p((e) => {
2352
+ n && t.id !== n.id && m((e) => {
2188
2353
  let r = e.findIndex((e) => e.key === t.id), i = e.findIndex((e) => e.key === n.id);
2189
- return r < 0 || i < 0 ? e : rt(e, r, i);
2354
+ return r < 0 || i < 0 ? e : st(e, r, i);
2190
2355
  });
2191
2356
  }
2192
2357
  function w(e, t) {
2193
- p((n) => n.map((n) => n.key === e ? {
2358
+ m((n) => n.map((n) => n.key === e ? {
2194
2359
  ...n,
2195
2360
  emphasis: t
2196
2361
  } : n));
2197
2362
  }
2198
- let T = le(() => yn(f), [f]), ee = f.some((e) => e.emphasis === "SMALL");
2199
- return /* @__PURE__ */ K("div", { children: [/* @__PURE__ */ K("div", {
2363
+ let T = fe(() => Fn(p), [p]), E = p.some((e) => e.emphasis === "SMALL");
2364
+ return /* @__PURE__ */ q("div", { children: [/* @__PURE__ */ q("div", {
2200
2365
  className: "mb-4 flex flex-wrap items-center gap-2 rounded-2xl border border-border/60 bg-card/40 p-3 backdrop-blur-md",
2201
2366
  children: [
2202
- /* @__PURE__ */ G("span", {
2367
+ /* @__PURE__ */ K("span", {
2203
2368
  className: "mr-auto text-sm text-muted-foreground",
2204
- children: d("bento.layout.editHint", { defaultValue: "Drag tiles to reorder · tap the size button to resize" })
2369
+ children: f("bento.layout.editHint", { defaultValue: "Drag tiles to reorder · tap the size button to resize" })
2205
2370
  }),
2206
- i && t.onReset && /* @__PURE__ */ K(C, {
2371
+ i && t.onReset && /* @__PURE__ */ q(c, {
2207
2372
  variant: "ghost",
2208
2373
  size: "sm",
2209
2374
  className: "gap-2",
2210
- ..._("reset"),
2211
- onClick: b("reset", t.onReset),
2212
- children: [m !== "reset" && /* @__PURE__ */ G(J, { size: 16 }), d("bento.layout.reset", { defaultValue: "Reset to default" })]
2375
+ ...v("reset"),
2376
+ onClick: x("reset", t.onReset),
2377
+ children: [h !== "reset" && /* @__PURE__ */ K(he, { size: 16 }), f("bento.layout.reset", { defaultValue: "Reset to default" })]
2213
2378
  }),
2214
- r && t.onSaveGlobal && /* @__PURE__ */ K(C, {
2379
+ r && t.onSaveGlobal && /* @__PURE__ */ q(c, {
2215
2380
  variant: "outline",
2216
2381
  size: "sm",
2217
2382
  className: "gap-2",
2218
- ..._("global"),
2219
- onClick: b("global", () => t.onSaveGlobal?.(T)),
2220
- children: [m !== "global" && /* @__PURE__ */ G(Re, { size: 16 }), d("bento.layout.saveGlobal", { defaultValue: "Set as default for everyone" })]
2383
+ ...v("global"),
2384
+ onClick: x("global", () => t.onSaveGlobal?.(T)),
2385
+ children: [h !== "global" && /* @__PURE__ */ K(He, { size: 16 }), f("bento.layout.saveGlobal", { defaultValue: "Set as default for everyone" })]
2221
2386
  }),
2222
- /* @__PURE__ */ K(C, {
2387
+ /* @__PURE__ */ q(c, {
2223
2388
  variant: "ghost",
2224
2389
  size: "sm",
2225
2390
  className: "gap-2",
2226
- ..._("cancel"),
2227
- onClick: u,
2228
- children: [/* @__PURE__ */ G(ze, { size: 16 }), d("common.cancel", { defaultValue: "Cancel" })]
2391
+ ...v("cancel"),
2392
+ onClick: d,
2393
+ children: [/* @__PURE__ */ K(Ue, { size: 16 }), f("common.cancel", { defaultValue: "Cancel" })]
2229
2394
  }),
2230
- /* @__PURE__ */ K(C, {
2395
+ /* @__PURE__ */ q(c, {
2231
2396
  size: "sm",
2232
2397
  className: "gap-2",
2233
- ..._("save"),
2234
- onClick: b("save", () => t.onSave(T)),
2235
- children: [m !== "save" && /* @__PURE__ */ G(Se, { size: 16 }), d("bento.layout.save", { defaultValue: "Save layout" })]
2398
+ ...v("save"),
2399
+ onClick: x("save", () => t.onSave(T)),
2400
+ children: [h !== "save" && /* @__PURE__ */ K(Ee, { size: 16 }), f("bento.layout.save", { defaultValue: "Save layout" })]
2236
2401
  }),
2237
- v && /* @__PURE__ */ G("p", {
2402
+ y && /* @__PURE__ */ K("p", {
2238
2403
  role: "alert",
2239
2404
  className: "w-full text-sm text-destructive",
2240
- children: d("bento.layout.saveFailed", { defaultValue: "The layout could not be saved. Nothing has changed — try again." })
2405
+ children: f("bento.layout.saveFailed", { defaultValue: "The layout could not be saved. Nothing has changed — try again." })
2241
2406
  })
2242
2407
  ]
2243
- }), /* @__PURE__ */ G(Xe, {
2244
- sensors: x,
2245
- collisionDetection: $e,
2246
- onDragEnd: S,
2247
- children: /* @__PURE__ */ G(nt, {
2248
- items: f.map((e) => e.key),
2249
- strategy: it,
2250
- children: /* @__PURE__ */ K("div", {
2408
+ }), /* @__PURE__ */ K(et, {
2409
+ sensors: S,
2410
+ collisionDetection: rt,
2411
+ onDragEnd: C,
2412
+ children: /* @__PURE__ */ K(ot, {
2413
+ items: p.map((e) => e.key),
2414
+ strategy: ct,
2415
+ children: /* @__PURE__ */ q("div", {
2251
2416
  "data-slot": "bento-list-tiles",
2252
- className: e(An, ee && "grid-flow-dense"),
2253
- children: [!o && /* @__PURE__ */ G(Rn, {
2417
+ className: e(Kn, E && "grid-flow-dense"),
2418
+ children: [!o && /* @__PURE__ */ K(er, {
2254
2419
  route: s,
2255
- label: c,
2256
- subtitle: l
2257
- }), f.map(({ item: e, key: t, emphasis: n }) => /* @__PURE__ */ G(Ln, {
2420
+ label: l,
2421
+ subtitle: u
2422
+ }), p.map(({ item: e, key: t, emphasis: n }) => /* @__PURE__ */ K($n, {
2258
2423
  id: t,
2259
2424
  emphasis: n,
2260
2425
  onSetEmphasis: (e) => w(t, e),
@@ -2264,11 +2429,11 @@ function Pn({ layout: t, resolved: n, canEditGlobal: r, isCustomized: i, renderT
2264
2429
  })
2265
2430
  })] });
2266
2431
  }
2267
- var Fn = [
2432
+ var Zn = [
2268
2433
  "SMALL",
2269
2434
  "MEDIUM",
2270
2435
  "LARGE"
2271
- ], In = {
2436
+ ], Qn = {
2272
2437
  SMALL: {
2273
2438
  key: "bento.layout.size.small",
2274
2439
  def: "Small"
@@ -2282,29 +2447,29 @@ var Fn = [
2282
2447
  def: "Large"
2283
2448
  }
2284
2449
  };
2285
- function Ln({ id: t, emphasis: n, onSetEmphasis: r, children: i }) {
2286
- let { t: a } = q(), { attributes: o, listeners: s, setNodeRef: c, transform: l, transition: u, isDragging: d } = at({ id: t }), f = {
2287
- transform: ot.Translate.toString(l),
2450
+ function $n({ id: t, emphasis: n, onSetEmphasis: r, children: i }) {
2451
+ let { t: a } = J(), { attributes: o, listeners: s, setNodeRef: c, transform: l, transition: u, isDragging: d } = lt({ id: t }), f = {
2452
+ transform: ut.Translate.toString(l),
2288
2453
  transition: u,
2289
2454
  opacity: d ? .6 : 1,
2290
2455
  zIndex: d ? 50 : void 0
2291
2456
  };
2292
- return /* @__PURE__ */ K("div", {
2457
+ return /* @__PURE__ */ q("div", {
2293
2458
  ref: c,
2294
2459
  style: f,
2295
- className: e("relative h-full", gn[n]),
2296
- children: [/* @__PURE__ */ G("div", {
2460
+ className: e("relative h-full", Mn[n]),
2461
+ children: [/* @__PURE__ */ K("div", {
2297
2462
  className: "pointer-events-none h-full select-none [&>*]:h-full [&>*]:w-full",
2298
2463
  children: i
2299
- }), /* @__PURE__ */ K("div", {
2464
+ }), /* @__PURE__ */ q("div", {
2300
2465
  className: "absolute right-2 top-2 z-10 flex items-center gap-1",
2301
- children: [/* @__PURE__ */ G("div", {
2466
+ children: [/* @__PURE__ */ K("div", {
2302
2467
  role: "group",
2303
2468
  "aria-label": a("bento.layout.sizeGroup", { defaultValue: "Tile size" }),
2304
2469
  className: "flex items-center gap-0.5 rounded-full border border-border/60 bg-background/80 p-0.5 shadow-sm backdrop-blur",
2305
- children: Fn.map((t) => {
2306
- let i = t === n, o = a(In[t].key, { defaultValue: In[t].def });
2307
- return /* @__PURE__ */ G("button", {
2470
+ children: Zn.map((t) => {
2471
+ let i = t === n, o = a(Qn[t].key, { defaultValue: Qn[t].def });
2472
+ return /* @__PURE__ */ K("button", {
2308
2473
  type: "button",
2309
2474
  onClick: () => r(t),
2310
2475
  "aria-pressed": i,
@@ -2314,13 +2479,13 @@ function Ln({ id: t, emphasis: n, onSetEmphasis: r, children: i }) {
2314
2479
  children: o.charAt(0)
2315
2480
  }, t);
2316
2481
  })
2317
- }), /* @__PURE__ */ G("button", {
2482
+ }), /* @__PURE__ */ K("button", {
2318
2483
  type: "button",
2319
2484
  ...o,
2320
2485
  ...s,
2321
2486
  "aria-label": a("bento.layout.dragToReorder", { defaultValue: "Drag to reorder" }),
2322
2487
  className: "grid size-(--vg-control-dense) cursor-grab place-items-center rounded-full border border-border/60 bg-background/80 shadow-sm backdrop-blur hover:bg-background active:cursor-grabbing",
2323
- children: /* @__PURE__ */ G(Te, {
2488
+ children: /* @__PURE__ */ K(ke, {
2324
2489
  size: 14,
2325
2490
  className: "text-muted-foreground"
2326
2491
  })
@@ -2328,32 +2493,32 @@ function Ln({ id: t, emphasis: n, onSetEmphasis: r, children: i }) {
2328
2493
  })]
2329
2494
  });
2330
2495
  }
2331
- function Rn({ route: e, label: t, subtitle: n }) {
2332
- let { t: r } = q();
2333
- return /* @__PURE__ */ K(He, {
2496
+ function er({ route: e, label: t, subtitle: n }) {
2497
+ let { t: r } = J();
2498
+ return /* @__PURE__ */ q(Ke, {
2334
2499
  to: e,
2335
2500
  className: "bento-tile bento-tile-clickable col-span-2 row-span-1 flex flex-col gap-3 rounded-3xl border-2 border-dashed border-border/60 bg-card/30 p-5 backdrop-blur-md bento-new-tile hover:bg-card/50 md:col-span-2 md:row-span-1 lg:col-span-2 lg:row-span-1",
2336
- children: [/* @__PURE__ */ K("div", {
2501
+ children: [/* @__PURE__ */ q("div", {
2337
2502
  className: "flex items-center gap-3",
2338
- children: [/* @__PURE__ */ G("span", {
2503
+ children: [/* @__PURE__ */ K("span", {
2339
2504
  className: "bento-well grid h-10 w-10 place-items-center rounded-2xl",
2340
- children: /* @__PURE__ */ G(je, { size: 20 })
2341
- }), /* @__PURE__ */ G("span", {
2505
+ children: /* @__PURE__ */ K(Z, { size: 20 })
2506
+ }), /* @__PURE__ */ K("span", {
2342
2507
  className: "text-[11px] uppercase tracking-wider text-muted-foreground",
2343
2508
  children: r("forms.formActions.new", { defaultValue: "New" })
2344
2509
  })]
2345
- }), /* @__PURE__ */ K("div", { children: [/* @__PURE__ */ G("div", {
2510
+ }), /* @__PURE__ */ q("div", { children: [/* @__PURE__ */ K("div", {
2346
2511
  className: "text-base font-semibold tracking-tight md:text-lg",
2347
2512
  children: t
2348
- }), n && /* @__PURE__ */ G("p", {
2513
+ }), n && /* @__PURE__ */ K("p", {
2349
2514
  className: "mt-1 text-sm text-muted-foreground",
2350
2515
  children: n
2351
2516
  })] })]
2352
2517
  });
2353
2518
  }
2354
- function zn({ title: e, description: t }) {
2355
- return /* @__PURE__ */ G(vt, {
2356
- icon: Pe,
2519
+ function tr({ title: e, description: t }) {
2520
+ return /* @__PURE__ */ K(wt, {
2521
+ icon: Re,
2357
2522
  title: e,
2358
2523
  description: t,
2359
2524
  align: "start",
@@ -2362,97 +2527,97 @@ function zn({ title: e, description: t }) {
2362
2527
  }
2363
2528
  //#endregion
2364
2529
  //#region src/bento/bento-save-bar.tsx
2365
- function Bn({ title: e, badges: t, actions: n, onCancel: r, loading: i, disabled: o, dirty: s, titleMissing: c }) {
2366
- let { t: l } = q();
2367
- return /* @__PURE__ */ K("div", {
2530
+ function nr({ title: e, badges: t, actions: n, onCancel: r, loading: i, disabled: o, dirty: s, titleMissing: c }) {
2531
+ let { t: l } = J();
2532
+ return /* @__PURE__ */ q("div", {
2368
2533
  className: "bento-frost flex items-center justify-between gap-4 rounded-2xl px-4 py-3 shadow-md backdrop-blur-xl",
2369
- children: [/* @__PURE__ */ K("div", {
2534
+ children: [/* @__PURE__ */ q("div", {
2370
2535
  className: "flex min-w-0 items-center gap-3",
2371
2536
  children: [
2372
- e && /* @__PURE__ */ G("p", {
2537
+ e && /* @__PURE__ */ K("p", {
2373
2538
  className: "truncate text-base font-semibold tracking-tight md:text-lg",
2374
2539
  children: e
2375
2540
  }),
2376
- /* @__PURE__ */ G(Dt, {
2541
+ /* @__PURE__ */ K(Nt, {
2377
2542
  titleMissing: c,
2378
2543
  dirty: s
2379
2544
  }),
2380
- t && /* @__PURE__ */ G("div", {
2545
+ t && /* @__PURE__ */ K("div", {
2381
2546
  className: "flex shrink-0 items-center gap-1.5",
2382
2547
  children: t
2383
2548
  })
2384
2549
  ]
2385
- }), /* @__PURE__ */ G("div", {
2550
+ }), /* @__PURE__ */ K("div", {
2386
2551
  className: "flex shrink-0 gap-2",
2387
- children: n ?? /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ K(a, {
2552
+ children: n ?? /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ q(a, {
2388
2553
  type: "submit",
2389
2554
  size: "sm",
2390
2555
  loading: i,
2391
2556
  "aria-disabled": o ? "true" : void 0,
2392
- children: [/* @__PURE__ */ G(Se, { className: "size-4" }), l("forms.formActions.saveChanges")]
2393
- }), r && /* @__PURE__ */ K(a, {
2557
+ children: [/* @__PURE__ */ K(Ee, { className: "size-4" }), l("forms.formActions.saveChanges")]
2558
+ }), r && /* @__PURE__ */ q(a, {
2394
2559
  type: "button",
2395
2560
  variant: "outline",
2396
2561
  size: "sm",
2397
2562
  onClick: r,
2398
- children: [/* @__PURE__ */ G(ze, { className: "size-4" }), l("forms.formActions.cancel")]
2563
+ children: [/* @__PURE__ */ K(Ue, { className: "size-4" }), l("forms.formActions.cancel")]
2399
2564
  })] })
2400
2565
  })]
2401
2566
  });
2402
2567
  }
2403
- function Vn({ children: e }) {
2404
- return /* @__PURE__ */ G("span", {
2568
+ function rr({ children: e }) {
2569
+ return /* @__PURE__ */ K("span", {
2405
2570
  className: "rounded-full border border-border/60 bg-card/50 px-2 py-0.5 text-[10px] uppercase tracking-wider text-muted-foreground backdrop-blur",
2406
2571
  children: e
2407
2572
  });
2408
2573
  }
2409
- Bn.Badge = Vn;
2574
+ nr.Badge = rr;
2410
2575
  //#endregion
2411
2576
  //#region src/bento/bento-scroll-save-bar.tsx
2412
- function Hn(e) {
2413
- let t = V(null);
2414
- return Ot(t), /* @__PURE__ */ K(W, { children: [
2415
- /* @__PURE__ */ G("div", {
2577
+ function ir(e) {
2578
+ let t = U(null);
2579
+ return Pt(t), /* @__PURE__ */ q(G, { children: [
2580
+ /* @__PURE__ */ K("div", {
2416
2581
  ref: t,
2417
2582
  "aria-hidden": !0,
2418
2583
  className: "h-px"
2419
2584
  }),
2420
- /* @__PURE__ */ G("div", {
2585
+ /* @__PURE__ */ K("div", {
2421
2586
  "aria-hidden": !0,
2422
2587
  className: "bento-save-bar-spacer"
2423
2588
  }),
2424
- /* @__PURE__ */ G("div", {
2589
+ /* @__PURE__ */ K("div", {
2425
2590
  className: "bento-fade-in fixed inset-x-0 top-20 z-20 mx-auto w-full max-w-7xl px-4 md:px-8",
2426
- children: /* @__PURE__ */ G(Bn, { ...e })
2591
+ children: /* @__PURE__ */ K(nr, { ...e })
2427
2592
  })
2428
2593
  ] });
2429
2594
  }
2430
2595
  //#endregion
2431
2596
  //#region src/bento/bento-form-hero.tsx
2432
- function Un({ eyebrow: e, backTo: t, backLabel: n, trail: r, leading: i, title: o, subtitle: s, trailing: c, onCancel: l, actions: u, loading: d, dirty: f, titleMissing: p, saveDisabled: m, stickyTitle: h, stickyBadges: g }) {
2433
- let { t: _ } = q(), v = m ?? (!!p || !f), y = St(r, t, n) ?? e;
2434
- return /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(Ct, {
2597
+ function ar({ eyebrow: e, backTo: t, backLabel: n, trail: r, leading: i, title: o, subtitle: s, trailing: c, onCancel: l, actions: u, loading: d, dirty: f, titleMissing: p, saveDisabled: m, stickyTitle: h, stickyBadges: g }) {
2598
+ let { t: _ } = J(), v = m ?? (!!p || !f), y = Ot(r, t, n) ?? e;
2599
+ return /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K(kt, {
2435
2600
  eyebrow: y,
2436
2601
  leading: i,
2437
2602
  title: o,
2438
2603
  subtitle: s,
2439
- trailing: /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G("div", {
2604
+ trailing: /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K("div", {
2440
2605
  className: "bento-fade-out flex shrink-0 items-center gap-2",
2441
- children: u ?? /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ K(a, {
2606
+ children: u ?? /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ q(a, {
2442
2607
  type: "submit",
2443
2608
  size: "sm",
2444
2609
  loading: d,
2445
2610
  "aria-disabled": v ? "true" : void 0,
2446
- children: [/* @__PURE__ */ G(Se, { className: "size-4" }), _("forms.formActions.saveChanges")]
2447
- }), /* @__PURE__ */ K(a, {
2611
+ children: [/* @__PURE__ */ K(Ee, { className: "size-4" }), _("forms.formActions.saveChanges")]
2612
+ }), /* @__PURE__ */ q(a, {
2448
2613
  type: "button",
2449
2614
  variant: "outline",
2450
2615
  size: "sm",
2451
2616
  onClick: l,
2452
- children: [/* @__PURE__ */ G(ze, { className: "size-4" }), _("forms.formActions.cancel")]
2617
+ children: [/* @__PURE__ */ K(Ue, { className: "size-4" }), _("forms.formActions.cancel")]
2453
2618
  })] })
2454
2619
  }), c] })
2455
- }), /* @__PURE__ */ G(Hn, {
2620
+ }), /* @__PURE__ */ K(ir, {
2456
2621
  title: h,
2457
2622
  badges: g,
2458
2623
  actions: u,
@@ -2465,32 +2630,32 @@ function Un({ eyebrow: e, backTo: t, backLabel: n, trail: r, leading: i, title:
2465
2630
  }
2466
2631
  //#endregion
2467
2632
  //#region src/bento/bento-form-section.tsx
2468
- var Wn = "bento-tile bento-glass relative flex flex-col gap-5 overflow-hidden rounded-3xl p-5 md:p-6";
2469
- function Gn({ icon: t, title: n, description: r, children: i, trailing: a, as: o = "h2", className: s }) {
2470
- return /* @__PURE__ */ K("section", {
2471
- className: e(Wn, s),
2472
- children: [/* @__PURE__ */ K("header", {
2633
+ var or = "bento-tile bento-glass relative flex flex-col gap-5 overflow-hidden rounded-3xl p-5 md:p-6";
2634
+ function sr({ icon: t, title: n, description: r, children: i, trailing: a, as: o = "h2", className: s }) {
2635
+ return /* @__PURE__ */ q("section", {
2636
+ className: e(or, s),
2637
+ children: [/* @__PURE__ */ q("header", {
2473
2638
  className: "flex items-start justify-between gap-3",
2474
- children: [/* @__PURE__ */ K("div", {
2639
+ children: [/* @__PURE__ */ q("div", {
2475
2640
  className: "flex items-center gap-3",
2476
- children: [/* @__PURE__ */ G("span", {
2641
+ children: [/* @__PURE__ */ K("span", {
2477
2642
  className: "bento-well grid h-10 w-10 place-items-center rounded-2xl",
2478
- children: /* @__PURE__ */ G(t, { size: 20 })
2479
- }), /* @__PURE__ */ K("div", {
2643
+ children: /* @__PURE__ */ K(t, { size: 20 })
2644
+ }), /* @__PURE__ */ q("div", {
2480
2645
  className: "flex flex-col gap-0.5",
2481
- children: [/* @__PURE__ */ G(o, {
2646
+ children: [/* @__PURE__ */ K(o, {
2482
2647
  className: "text-base font-semibold tracking-tight md:text-lg",
2483
2648
  children: n
2484
- }), r && /* @__PURE__ */ G("p", {
2649
+ }), r && /* @__PURE__ */ K("p", {
2485
2650
  className: "text-sm text-muted-foreground",
2486
2651
  children: r
2487
2652
  })]
2488
2653
  })]
2489
- }), a && /* @__PURE__ */ G("div", {
2654
+ }), a && /* @__PURE__ */ K("div", {
2490
2655
  className: "shrink-0",
2491
2656
  children: a
2492
2657
  })]
2493
- }), /* @__PURE__ */ G("div", {
2658
+ }), /* @__PURE__ */ K("div", {
2494
2659
  className: "flex flex-col gap-5",
2495
2660
  children: i
2496
2661
  })]
@@ -2498,10 +2663,10 @@ function Gn({ icon: t, title: n, description: r, children: i, trailing: a, as: o
2498
2663
  }
2499
2664
  //#endregion
2500
2665
  //#region src/bento/bento-panel.tsx
2501
- function Kn({ children: t, className: n, contentClassName: r }) {
2502
- return /* @__PURE__ */ G("div", {
2666
+ function cr({ children: t, className: n, contentClassName: r }) {
2667
+ return /* @__PURE__ */ K("div", {
2503
2668
  className: e("bento-glass rounded-2xl shadow-md", n),
2504
- children: /* @__PURE__ */ G("div", {
2669
+ children: /* @__PURE__ */ K("div", {
2505
2670
  className: r,
2506
2671
  children: t
2507
2672
  })
@@ -2509,16 +2674,16 @@ function Kn({ children: t, className: n, contentClassName: r }) {
2509
2674
  }
2510
2675
  //#endregion
2511
2676
  //#region src/bento/bento-back-to-top.tsx
2512
- var qn = 480;
2513
- function Jn(e) {
2677
+ var lr = 480;
2678
+ function ur(e) {
2514
2679
  return window.addEventListener("scroll", e, { passive: !0 }), () => window.removeEventListener("scroll", e);
2515
2680
  }
2516
- function Yn() {
2517
- return window.scrollY > qn;
2681
+ function dr() {
2682
+ return window.scrollY > lr;
2518
2683
  }
2519
- function Xn({ inline: e = !1 } = {}) {
2520
- let { t } = q(), n = te(), r = e || n, i = U(Jn, Yn, () => !1);
2521
- return /* @__PURE__ */ G("button", {
2684
+ function fr({ inline: e = !1 } = {}) {
2685
+ let { t } = J(), n = ee(), r = e || n, i = pe(ur, dr, () => !1);
2686
+ return /* @__PURE__ */ K("button", {
2522
2687
  type: "button",
2523
2688
  "aria-label": t("bento.backToTop", { defaultValue: "Back to top" }),
2524
2689
  tabIndex: i ? 0 : -1,
@@ -2527,28 +2692,28 @@ function Xn({ inline: e = !1 } = {}) {
2527
2692
  behavior: "smooth"
2528
2693
  }),
2529
2694
  className: `${r ? "relative" : "fixed bottom-6 right-6 z-40"} grid h-11 w-11 place-items-center rounded-full border border-border/60 bg-card/80 text-foreground shadow-lg backdrop-blur-xl transition-all duration-300 ease-[cubic-bezier(0.32,0.72,0,1)] hover:-translate-y-0.5 hover:shadow-xl active:scale-95 ${i ? "pointer-events-auto translate-y-0 scale-100 opacity-100" : "pointer-events-none translate-y-4 scale-90 opacity-0"}`,
2530
- children: /* @__PURE__ */ G(he, { size: 18 })
2695
+ children: /* @__PURE__ */ K(ve, { size: 18 })
2531
2696
  });
2532
2697
  }
2533
2698
  //#endregion
2534
2699
  //#region src/bento/bento-nav.ts
2535
- function Zn(e) {
2700
+ function pr(e) {
2536
2701
  return e.bentoRoute ?? e.fallbackRoute;
2537
2702
  }
2538
2703
  //#endregion
2539
2704
  //#region src/bento/bento-command-palette.tsx
2540
- function Qn({ label: e, children: t }) {
2541
- return e ? /* @__PURE__ */ K("div", {
2705
+ function mr({ label: e, children: t }) {
2706
+ return e ? /* @__PURE__ */ q("div", {
2542
2707
  role: "group",
2543
2708
  "aria-label": e,
2544
- children: [/* @__PURE__ */ G("p", {
2709
+ children: [/* @__PURE__ */ K("p", {
2545
2710
  className: "px-3 pt-2 pb-1 text-xs font-medium text-muted-foreground",
2546
2711
  children: e
2547
2712
  }), t]
2548
- }) : /* @__PURE__ */ G(W, { children: t });
2713
+ }) : /* @__PURE__ */ K(G, { children: t });
2549
2714
  }
2550
- function $n({ index: e, active: t, icon: n, label: r, description: i, trailing: a, onActivate: o, onChoose: s }) {
2551
- return /* @__PURE__ */ K("button", {
2715
+ function hr({ index: e, active: t, icon: n, label: r, description: i, trailing: a, onActivate: o, onChoose: s }) {
2716
+ return /* @__PURE__ */ q("button", {
2552
2717
  type: "button",
2553
2718
  id: `bento-palette-opt-${e}`,
2554
2719
  "data-index": e,
@@ -2558,18 +2723,18 @@ function $n({ index: e, active: t, icon: n, label: r, description: i, trailing:
2558
2723
  onClick: s,
2559
2724
  className: `flex w-full items-center gap-3 rounded-xl px-3 py-2.5 text-left text-sm transition-colors ${t ? "bg-accent text-accent-foreground" : "text-foreground"}`,
2560
2725
  children: [
2561
- n && /* @__PURE__ */ G(n, {
2726
+ n && /* @__PURE__ */ K(n, {
2562
2727
  size: 18,
2563
2728
  className: "shrink-0 text-muted-foreground"
2564
2729
  }),
2565
- /* @__PURE__ */ K("span", {
2730
+ /* @__PURE__ */ q("span", {
2566
2731
  className: "flex-1 truncate",
2567
- children: [r, i && /* @__PURE__ */ G("span", {
2732
+ children: [r, i && /* @__PURE__ */ K("span", {
2568
2733
  className: "ml-2 text-muted-foreground",
2569
2734
  children: i
2570
2735
  })]
2571
2736
  }),
2572
- a ?? (t && /* @__PURE__ */ G(me, {
2737
+ a ?? (t && /* @__PURE__ */ K(X, {
2573
2738
  "aria-hidden": !0,
2574
2739
  size: 15,
2575
2740
  className: "shrink-0 text-muted-foreground"
@@ -2577,8 +2742,8 @@ function $n({ index: e, active: t, icon: n, label: r, description: i, trailing:
2577
2742
  ]
2578
2743
  });
2579
2744
  }
2580
- function er({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c }) {
2581
- let { t: l } = q(), u = Ge(), [d, f] = H(""), [p, m] = H(0), h = V(null), g = le(() => {
2745
+ function gr({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c }) {
2746
+ let { t: l } = J(), u = Ye(), [d, f] = W(""), [p, m] = W(0), h = U(null), g = fe(() => {
2582
2747
  let e = d.trim().toLowerCase(), t = a.map((e) => ({
2583
2748
  item: e,
2584
2749
  label: l(e.titleKey),
@@ -2592,26 +2757,26 @@ function er({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c })
2592
2757
  a,
2593
2758
  d,
2594
2759
  l
2595
- ]), _ = le(() => [...g.map((e) => ({
2760
+ ]), _ = fe(() => [...g.map((e) => ({
2596
2761
  kind: "nav",
2597
2762
  entry: e
2598
2763
  })), ...(o?.items ?? []).map((e) => ({
2599
2764
  kind: "supplied",
2600
2765
  item: e
2601
- }))], [g, o]), v = V(c);
2602
- B(() => {
2766
+ }))], [g, o]), v = U(c);
2767
+ V(() => {
2603
2768
  v.current = c;
2604
- }), B(() => {
2769
+ }), V(() => {
2605
2770
  v.current?.(d);
2606
2771
  }, [d]);
2607
- let [y, b] = H(e);
2772
+ let [y, b] = W(e);
2608
2773
  e !== y && (b(e), e && (f(""), m(0)));
2609
2774
  let x = _.length === 0 ? 0 : _.length - 1;
2610
- p > x && m(x), B(() => {
2775
+ p > x && m(x), V(() => {
2611
2776
  (h.current?.querySelector(`[data-index="${p}"]`))?.scrollIntoView({ block: "nearest" });
2612
2777
  }, [p]);
2613
2778
  function S(e) {
2614
- t(!1), e.kind === "nav" ? u(Zn(e.entry.item)) : o?.onSelect(e.item);
2779
+ t(!1), e.kind === "nav" ? u(pr(e.entry.item)) : o?.onSelect(e.item);
2615
2780
  }
2616
2781
  function C(e) {
2617
2782
  if (e.key === "ArrowDown") e.preventDefault(), m((e) => _.length === 0 ? 0 : (e + 1) % _.length);
@@ -2622,28 +2787,28 @@ function er({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c })
2622
2787
  t && S(t);
2623
2788
  }
2624
2789
  }
2625
- return /* @__PURE__ */ G(n, {
2790
+ return /* @__PURE__ */ K(n, {
2626
2791
  open: e,
2627
2792
  onOpenChange: t,
2628
- children: /* @__PURE__ */ K(s, {
2793
+ children: /* @__PURE__ */ q(s, {
2629
2794
  showCloseButton: !1,
2630
2795
  className: "top-[15%] max-w-xl translate-y-0 gap-0 overflow-hidden p-0",
2631
2796
  onKeyDown: C,
2632
2797
  children: [
2633
- /* @__PURE__ */ G(i, {
2798
+ /* @__PURE__ */ K(i, {
2634
2799
  className: "sr-only",
2635
2800
  children: l("bento.palette.title", { defaultValue: "Command palette" })
2636
2801
  }),
2637
- /* @__PURE__ */ G(r, {
2802
+ /* @__PURE__ */ K(r, {
2638
2803
  className: "sr-only",
2639
2804
  children: l("bento.palette.description", { defaultValue: "Search and jump to any area" })
2640
2805
  }),
2641
- /* @__PURE__ */ K("div", {
2806
+ /* @__PURE__ */ q("div", {
2642
2807
  className: "flex items-center gap-3 border-b border-border/60 px-4",
2643
- children: [/* @__PURE__ */ G(Ne, {
2808
+ children: [/* @__PURE__ */ K(Le, {
2644
2809
  size: 18,
2645
2810
  className: "shrink-0 text-muted-foreground"
2646
- }), /* @__PURE__ */ G("input", {
2811
+ }), /* @__PURE__ */ K("input", {
2647
2812
  autoFocus: !0,
2648
2813
  type: "text",
2649
2814
  role: "combobox",
@@ -2656,41 +2821,41 @@ function er({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c })
2656
2821
  className: "h-12 w-full bg-transparent text-sm outline-none placeholder:text-muted-foreground"
2657
2822
  })]
2658
2823
  }),
2659
- /* @__PURE__ */ K("div", {
2824
+ /* @__PURE__ */ q("div", {
2660
2825
  ref: h,
2661
2826
  id: "bento-palette-list",
2662
2827
  role: "listbox",
2663
2828
  "aria-label": l("bento.palette.title", { defaultValue: "Command palette" }),
2664
2829
  className: "max-h-80 overflow-y-auto p-2",
2665
2830
  children: [
2666
- _.length === 0 && !o?.pending && /* @__PURE__ */ G("p", {
2831
+ _.length === 0 && !o?.pending && /* @__PURE__ */ K("p", {
2667
2832
  className: "px-3 py-6 text-center text-sm text-muted-foreground",
2668
2833
  children: l("bento.palette.noResults", { defaultValue: "No matches" })
2669
2834
  }),
2670
- /* @__PURE__ */ G(Qn, {
2835
+ /* @__PURE__ */ K(mr, {
2671
2836
  label: o && g.length > 0 ? l("bento.palette.areas", { defaultValue: "Areas" }) : void 0,
2672
- children: g.map(({ item: e, label: t }, n) => /* @__PURE__ */ G($n, {
2837
+ children: g.map(({ item: e, label: t }, n) => /* @__PURE__ */ K(hr, {
2673
2838
  index: n,
2674
2839
  active: n === p,
2675
2840
  icon: e.icon,
2676
2841
  label: t,
2677
2842
  onActivate: () => m(n),
2678
2843
  onChoose: () => S(_[n]),
2679
- trailing: e.bentoRoute ? void 0 : /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(we, {
2844
+ trailing: e.bentoRoute ? void 0 : /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K(Oe, {
2680
2845
  "aria-hidden": !0,
2681
2846
  size: 15,
2682
2847
  className: "shrink-0 text-muted-foreground/70"
2683
- }), /* @__PURE__ */ G("span", {
2848
+ }), /* @__PURE__ */ K("span", {
2684
2849
  className: "sr-only",
2685
2850
  children: l("bento.palette.opensConsole", { defaultValue: "Opens in console" })
2686
2851
  })] })
2687
2852
  }, e.id))
2688
2853
  }),
2689
- o && /* @__PURE__ */ K(Qn, {
2854
+ o && /* @__PURE__ */ q(mr, {
2690
2855
  label: o.label,
2691
2856
  children: [o.items.map((e, t) => {
2692
2857
  let n = g.length + t;
2693
- return /* @__PURE__ */ G($n, {
2858
+ return /* @__PURE__ */ K(hr, {
2694
2859
  index: n,
2695
2860
  active: n === p,
2696
2861
  icon: e.icon,
@@ -2699,7 +2864,7 @@ function er({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c })
2699
2864
  onActivate: () => m(n),
2700
2865
  onChoose: () => S(_[n])
2701
2866
  }, e.id);
2702
- }), o.pending && /* @__PURE__ */ G("p", {
2867
+ }), o.pending && /* @__PURE__ */ K("p", {
2703
2868
  className: "px-3 py-2.5 text-sm text-muted-foreground",
2704
2869
  children: l("bento.palette.searching", { defaultValue: "Searching…" })
2705
2870
  })]
@@ -2712,22 +2877,32 @@ function er({ open: e, onOpenChange: t, items: a, group: o, onQueryChange: c })
2712
2877
  }
2713
2878
  //#endregion
2714
2879
  //#region src/bento/bento-shell.tsx
2715
- function tr({ rail: t, headerStart: n, headerEnd: r, column: i = "default", dock: a, backToTop: o = !0, children: s }) {
2716
- let { t: c } = q(), l = Ue(), u = ce(), d = V(null), f = V(null), p = i === "full", m = n != null || r != null, h = O(), g = null;
2880
+ function _r({ rail: t, headerStart: n, headerEnd: r, column: i = "default", dock: a, backToTop: o = !0, children: s }) {
2881
+ let { t: c } = J(), l = qe(), u = H(), d = U(null), f = U(null), p = i === "full", m = n != null || r != null, h = re(), g = null;
2717
2882
  a != null && (g = h ? m ? "header" : "corner" : t == null ? "corner" : "rail");
2718
- let _ = o || g === "corner", v = (e) => /* @__PURE__ */ G(F.Provider, {
2883
+ let _ = o || g === "corner", v = U(null), y = U(null);
2884
+ V(() => {
2885
+ let e = v.current, t = y.current;
2886
+ if (!e || !t || p || typeof ResizeObserver > "u") return;
2887
+ let n = new ResizeObserver(() => e.style.setProperty("--bento-shell-header", `${t.offsetHeight}px`));
2888
+ return n.observe(t), () => {
2889
+ n.disconnect(), e.style.removeProperty("--bento-shell-header");
2890
+ };
2891
+ }, [p, m]);
2892
+ let b = (e) => /* @__PURE__ */ K(I.Provider, {
2719
2893
  value: !0,
2720
- children: /* @__PURE__ */ G(k.Provider, {
2894
+ children: /* @__PURE__ */ K(A.Provider, {
2721
2895
  value: e,
2722
2896
  children: a
2723
2897
  })
2724
2898
  });
2725
- return /* @__PURE__ */ K("div", {
2899
+ return /* @__PURE__ */ q("div", {
2900
+ ref: v,
2726
2901
  "data-slot": "bento-shell",
2727
2902
  className: e("relative w-full bg-background text-foreground", t != null && "bento-rail-gutter", p ? "flex h-svh flex-col overflow-hidden" : "min-h-svh"),
2728
2903
  style: g === "rail" ? { "--bento-rail-foot": "4.5rem" } : void 0,
2729
2904
  children: [
2730
- /* @__PURE__ */ G("a", {
2905
+ /* @__PURE__ */ K("a", {
2731
2906
  href: `#${u}`,
2732
2907
  onClick: (e) => {
2733
2908
  e.preventDefault(), d.current?.focus();
@@ -2735,37 +2910,38 @@ function tr({ rail: t, headerStart: n, headerEnd: r, column: i = "default", dock
2735
2910
  className: "sr-only rounded-full border border-border/60 bg-card px-4 py-2 text-sm shadow-lg focus:not-sr-only focus:fixed focus:left-4 focus:top-4 focus:z-[60]",
2736
2911
  children: c("bento.shell.skip", { defaultValue: "Skip to content" })
2737
2912
  }),
2738
- /* @__PURE__ */ G("span", {
2913
+ /* @__PURE__ */ K("span", {
2739
2914
  ref: f,
2740
2915
  role: "status",
2741
2916
  "aria-live": "polite",
2742
2917
  className: "sr-only"
2743
2918
  }),
2744
- l && /* @__PURE__ */ G(nr, {
2919
+ l && /* @__PURE__ */ K(vr, {
2745
2920
  main: d,
2746
2921
  announcer: f
2747
2922
  }),
2748
2923
  t,
2749
- g === "rail" && /* @__PURE__ */ G("div", {
2924
+ g === "rail" && /* @__PURE__ */ K("div", {
2750
2925
  "data-slot": "bento-shell-dock",
2751
2926
  className: "pointer-events-none fixed bottom-4 left-[18px] z-50 flex flex-col items-start",
2752
- children: v("rail")
2927
+ children: b("rail")
2753
2928
  }),
2754
- m && /* @__PURE__ */ K("header", {
2929
+ m && /* @__PURE__ */ q("header", {
2930
+ ref: y,
2755
2931
  className: "bento-shell-header bento-shell-bar sticky top-0 z-30 flex shrink-0 items-center justify-between gap-3 border-b border-border/40 bg-background/55 py-3 backdrop-blur-xl backdrop-saturate-150",
2756
- children: [/* @__PURE__ */ G("div", {
2932
+ children: [/* @__PURE__ */ K("div", {
2757
2933
  className: "flex min-w-0 items-center gap-3",
2758
2934
  children: n
2759
- }), /* @__PURE__ */ K("div", {
2935
+ }), /* @__PURE__ */ q("div", {
2760
2936
  className: "flex items-center gap-2",
2761
- children: [r, g === "header" && /* @__PURE__ */ G("div", {
2937
+ children: [r, g === "header" && /* @__PURE__ */ K("div", {
2762
2938
  "data-slot": "bento-shell-dock",
2763
2939
  className: "relative flex",
2764
- children: v("header")
2940
+ children: b("header")
2765
2941
  })]
2766
2942
  })]
2767
2943
  }),
2768
- /* @__PURE__ */ G("main", {
2944
+ /* @__PURE__ */ K("main", {
2769
2945
  ref: d,
2770
2946
  id: u,
2771
2947
  tabIndex: -1,
@@ -2774,20 +2950,20 @@ function tr({ rail: t, headerStart: n, headerEnd: r, column: i = "default", dock
2774
2950
  className: "bento-shell-main",
2775
2951
  children: s
2776
2952
  }),
2777
- _ && /* @__PURE__ */ G("div", {
2953
+ _ && /* @__PURE__ */ K("div", {
2778
2954
  "data-slot": "bento-shell-corner",
2779
2955
  className: "pointer-events-none fixed bottom-5 right-5 z-50 flex flex-col items-end gap-3",
2780
- children: /* @__PURE__ */ K(F.Provider, {
2956
+ children: /* @__PURE__ */ q(I.Provider, {
2781
2957
  value: !0,
2782
- children: [o && /* @__PURE__ */ G(Xn, {}), g === "corner" && v("corner")]
2958
+ children: [o && /* @__PURE__ */ K(fr, {}), g === "corner" && b("corner")]
2783
2959
  })
2784
2960
  })
2785
2961
  ]
2786
2962
  });
2787
2963
  }
2788
- function nr({ main: e, announcer: t }) {
2789
- let { pathname: n } = We(), r = V(n);
2790
- return B(() => {
2964
+ function vr({ main: e, announcer: t }) {
2965
+ let { pathname: n } = Je(), r = U(n);
2966
+ return V(() => {
2791
2967
  if (r.current === n) return;
2792
2968
  r.current = n;
2793
2969
  let i = 0, a, o = () => {
@@ -2807,7 +2983,7 @@ function nr({ main: e, announcer: t }) {
2807
2983
  }
2808
2984
  //#endregion
2809
2985
  //#region src/bento/bento-shell-shortcuts.ts
2810
- var rr = Object.freeze([
2986
+ var yr = Object.freeze([
2811
2987
  {
2812
2988
  action: "palette",
2813
2989
  key: "k",
@@ -2822,14 +2998,14 @@ var rr = Object.freeze([
2822
2998
  key: "?"
2823
2999
  }
2824
3000
  ]);
2825
- function ir() {
3001
+ function br() {
2826
3002
  return typeof navigator > "u" ? !1 : /Mac|iPhone|iPad|iPod/.test(navigator.platform || navigator.userAgent || "");
2827
3003
  }
2828
- function ar(e, t) {
3004
+ function xr(e, t) {
2829
3005
  let n = e.key.length === 1 ? e.key.toUpperCase() : e.key;
2830
3006
  return e.mod ? [t ? "⌘" : "Ctrl", n] : [n];
2831
3007
  }
2832
- function or(e) {
3008
+ function Sr(e) {
2833
3009
  if (!(e instanceof HTMLElement)) return !1;
2834
3010
  if ([
2835
3011
  "INPUT",
@@ -2839,24 +3015,24 @@ function or(e) {
2839
3015
  let t = e.closest("[contenteditable]");
2840
3016
  return t !== null && t.getAttribute("contenteditable") !== "false";
2841
3017
  }
2842
- function sr(e, t) {
3018
+ function Cr(e, t) {
2843
3019
  if (e.defaultPrevented || e.isComposing || e.repeat) return;
2844
3020
  let n = e.key.toLowerCase();
2845
- return rr.find((r) => n === r.key ? r.mod ? (t ? e.metaKey && !e.ctrlKey : e.ctrlKey && !e.metaKey) && !e.altKey && !e.shiftKey : e.metaKey || or(e.target) ? !1 : e.ctrlKey === e.altKey : !1);
3021
+ return yr.find((r) => n === r.key ? r.mod ? (t ? e.metaKey && !e.ctrlKey : e.ctrlKey && !e.metaKey) && !e.altKey && !e.shiftKey : e.metaKey || Sr(e.target) ? !1 : e.ctrlKey === e.altKey : !1);
2846
3022
  }
2847
- function cr({ onPalette: e, onShortcuts: t, isMac: n = ir() }) {
2848
- let r = V({
3023
+ function wr({ onPalette: e, onShortcuts: t, isMac: n = br() }) {
3024
+ let r = U({
2849
3025
  onPalette: e,
2850
3026
  onShortcuts: t
2851
3027
  });
2852
- B(() => {
3028
+ V(() => {
2853
3029
  r.current = {
2854
3030
  onPalette: e,
2855
3031
  onShortcuts: t
2856
3032
  };
2857
- }), B(() => {
3033
+ }), V(() => {
2858
3034
  function e(e) {
2859
- let t = sr(e, n), i = t?.action === "palette" ? r.current.onPalette : t && r.current.onShortcuts;
3035
+ let t = Cr(e, n), i = t?.action === "palette" ? r.current.onPalette : t && r.current.onShortcuts;
2860
3036
  i && (e.preventDefault(), i());
2861
3037
  }
2862
3038
  return globalThis.addEventListener("keydown", e), () => globalThis.removeEventListener("keydown", e);
@@ -2864,42 +3040,42 @@ function cr({ onPalette: e, onShortcuts: t, isMac: n = ir() }) {
2864
3040
  }
2865
3041
  //#endregion
2866
3042
  //#region src/bento/bento-palette-trigger.tsx
2867
- function lr({ onClick: t, isMac: n = ir(), className: r }) {
2868
- let { t: i } = q(), a = rr.filter((e) => e.action === "palette"), o = a.find((e) => e.mod);
2869
- return /* @__PURE__ */ K("button", {
3043
+ function Tr({ onClick: t, isMac: n = br(), className: r }) {
3044
+ let { t: i } = J(), a = yr.filter((e) => e.action === "palette"), o = a.find((e) => e.mod);
3045
+ return /* @__PURE__ */ q("button", {
2870
3046
  type: "button",
2871
3047
  onClick: t,
2872
3048
  "aria-keyshortcuts": a.map((e) => e.mod ? `${n ? "Meta" : "Control"}+${e.key.toUpperCase()}` : e.key).join(" "),
2873
3049
  className: e("bento-tile bento-tile-clickable inline-flex items-center gap-2 rounded-full border border-border/60 bg-card/60 py-1.5 pl-3 pr-2 text-sm text-muted-foreground backdrop-blur hover:text-foreground", r),
2874
3050
  children: [
2875
- /* @__PURE__ */ G(Ne, {
3051
+ /* @__PURE__ */ K(Le, {
2876
3052
  "aria-hidden": !0,
2877
3053
  size: 16
2878
3054
  }),
2879
- /* @__PURE__ */ G("span", {
3055
+ /* @__PURE__ */ K("span", {
2880
3056
  className: "sr-only sm:not-sr-only",
2881
3057
  children: i("bento.palette.search", { defaultValue: "Search" })
2882
3058
  }),
2883
- o && /* @__PURE__ */ G("kbd", {
3059
+ o && /* @__PURE__ */ K("kbd", {
2884
3060
  "aria-hidden": !0,
2885
3061
  className: "hidden rounded-sm border border-border/60 bg-muted px-1.5 py-0.5 text-[10px] font-medium tracking-wide sm:inline",
2886
- children: ar(o, n).join(n ? "" : " ")
3062
+ children: xr(o, n).join(n ? "" : " ")
2887
3063
  })
2888
3064
  ]
2889
3065
  });
2890
3066
  }
2891
3067
  //#endregion
2892
3068
  //#region src/bento/bento-shortcuts-dialog.tsx
2893
- function ur({ open: e, onOpenChange: t, isMac: a = ir() }) {
2894
- let { t: c } = q(), l = {
3069
+ function Er({ open: e, onOpenChange: t, isMac: a = br() }) {
3070
+ let { t: c } = J(), l = {
2895
3071
  palette: c("bento.palette.open", { defaultValue: "Open command palette" }),
2896
3072
  shortcuts: c("bento.shortcuts.openGuide", { defaultValue: "Show keyboard shortcuts" })
2897
- }, u = [...new Set(rr.map((e) => e.action))], d = [{
3073
+ }, u = [...new Set(yr.map((e) => e.action))], d = [{
2898
3074
  heading: c("bento.shortcuts.global", { defaultValue: "Global" }),
2899
3075
  rows: u.map((e) => ({
2900
3076
  id: e,
2901
3077
  label: l[e],
2902
- combos: rr.filter((t) => t.action === e).map((e) => ar(e, a))
3078
+ combos: yr.filter((t) => t.action === e).map((e) => xr(e, a))
2903
3079
  }))
2904
3080
  }, {
2905
3081
  heading: c("bento.shortcuts.palette", { defaultValue: "Command palette" }),
@@ -2921,36 +3097,36 @@ function ur({ open: e, onOpenChange: t, isMac: a = ir() }) {
2921
3097
  }
2922
3098
  ]
2923
3099
  }];
2924
- return /* @__PURE__ */ G(n, {
3100
+ return /* @__PURE__ */ K(n, {
2925
3101
  open: e,
2926
3102
  onOpenChange: t,
2927
- children: /* @__PURE__ */ K(s, {
3103
+ children: /* @__PURE__ */ q(s, {
2928
3104
  className: "max-w-md",
2929
- children: [/* @__PURE__ */ K(o, { children: [/* @__PURE__ */ K(i, {
3105
+ children: [/* @__PURE__ */ q(o, { children: [/* @__PURE__ */ q(i, {
2930
3106
  className: "flex items-center gap-2",
2931
- children: [/* @__PURE__ */ G(De, {
3107
+ children: [/* @__PURE__ */ K(je, {
2932
3108
  size: 20,
2933
3109
  className: "bento-accent-icon"
2934
3110
  }), c("bento.shortcuts.title", { defaultValue: "Keyboard shortcuts" })]
2935
- }), /* @__PURE__ */ G(r, { children: c("bento.shortcuts.description", { defaultValue: "Move around without leaving the keyboard." }) })] }), /* @__PURE__ */ G("div", {
3111
+ }), /* @__PURE__ */ K(r, { children: c("bento.shortcuts.description", { defaultValue: "Move around without leaving the keyboard." }) })] }), /* @__PURE__ */ K("div", {
2936
3112
  className: "flex flex-col gap-5",
2937
- children: d.map((e) => /* @__PURE__ */ K("section", { children: [/* @__PURE__ */ G("h3", {
3113
+ children: d.map((e) => /* @__PURE__ */ q("section", { children: [/* @__PURE__ */ K("h3", {
2938
3114
  className: "mb-2 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",
2939
3115
  children: e.heading
2940
- }), /* @__PURE__ */ G("ul", {
3116
+ }), /* @__PURE__ */ K("ul", {
2941
3117
  className: "flex flex-col gap-1.5",
2942
- children: e.rows.map((e) => /* @__PURE__ */ K("li", {
3118
+ children: e.rows.map((e) => /* @__PURE__ */ q("li", {
2943
3119
  "data-shortcut": e.id,
2944
3120
  className: "flex items-center justify-between gap-4",
2945
- children: [/* @__PURE__ */ G("span", {
3121
+ children: [/* @__PURE__ */ K("span", {
2946
3122
  className: "text-sm text-foreground",
2947
3123
  children: e.label
2948
- }), /* @__PURE__ */ G("span", {
3124
+ }), /* @__PURE__ */ K("span", {
2949
3125
  className: "flex shrink-0 items-center gap-1",
2950
- children: e.combos.map((e, t) => /* @__PURE__ */ K(z, { children: [t > 0 && /* @__PURE__ */ G("span", {
3126
+ children: e.combos.map((e, t) => /* @__PURE__ */ q(ce, { children: [t > 0 && /* @__PURE__ */ K("span", {
2951
3127
  className: "px-0.5 text-[11px] text-muted-foreground",
2952
3128
  children: c("bento.shortcuts.or", { defaultValue: "or" })
2953
- }), e.map((e) => /* @__PURE__ */ G("kbd", {
3129
+ }), e.map((e) => /* @__PURE__ */ K("kbd", {
2954
3130
  className: "inline-flex min-w-6 items-center justify-center rounded-md border border-border/60 bg-muted px-1.5 py-0.5 text-[11px] font-medium tracking-wide",
2955
3131
  children: e
2956
3132
  }, e))] }, e.join("+")))
@@ -2963,171 +3139,171 @@ function ur({ open: e, onOpenChange: t, isMac: a = ir() }) {
2963
3139
  }
2964
3140
  //#endregion
2965
3141
  //#region src/bento/bento-nav-rail.tsx
2966
- var dr = Oe;
2967
- function fr(e, t) {
3142
+ var Dr = Me;
3143
+ function Or(e, t) {
2968
3144
  return e === t || e.startsWith(`${t}/`);
2969
3145
  }
2970
- function pr(e, t) {
2971
- return t.section.areaRoute && fr(e, t.section.areaRoute) ? !0 : t.items.some((t) => t.bentoRoute && fr(e, t.bentoRoute));
3146
+ function kr(e, t) {
3147
+ return t.section.areaRoute && Or(e, t.section.areaRoute) ? !0 : t.items.some((t) => t.bentoRoute && Or(e, t.bentoRoute));
2972
3148
  }
2973
- function mr(e) {
3149
+ function Ar(e) {
2974
3150
  return e.items.reduce((e, t) => e + (t.count && t.count > 0 ? t.count : 0), 0);
2975
3151
  }
2976
- function hr({ groups: e, homeRoute: t, homeAliases: n, homeLabel: r }) {
2977
- let { t: i } = q(), { pathname: a } = We(), o = le(() => e.filter((e) => !!e.section.areaRoute), [e]), s = a === t || (n?.includes(a) ?? !1);
2978
- return /* @__PURE__ */ G(ne, {
3152
+ function jr({ groups: e, homeRoute: t, homeAliases: n, homeLabel: r }) {
3153
+ let { t: i } = J(), { pathname: a } = Je(), o = fe(() => e.filter((e) => !!e.section.areaRoute), [e]), s = a === t || (n?.includes(a) ?? !1);
3154
+ return /* @__PURE__ */ K(S, {
2979
3155
  delayDuration: 200,
2980
- children: /* @__PURE__ */ K("nav", {
3156
+ children: /* @__PURE__ */ q("nav", {
2981
3157
  "aria-label": i("bento.nav.label", { defaultValue: "Primary" }),
2982
3158
  className: "fixed inset-y-0 left-0 z-40 hidden w-20 flex-col items-center gap-1 overflow-y-auto overflow-x-hidden border-r border-border/40 bg-background/55 pt-20 pb-[calc(1rem+var(--bento-rail-foot,0px))] backdrop-blur-xl backdrop-saturate-150 md:flex",
2983
3159
  children: [
2984
- /* @__PURE__ */ G(gr, {
3160
+ /* @__PURE__ */ K(Mr, {
2985
3161
  to: t,
2986
- icon: Ee,
3162
+ icon: Ae,
2987
3163
  label: r ?? i("home.title", { defaultValue: "Home" }),
2988
3164
  shown: !0,
2989
3165
  active: s
2990
3166
  }),
2991
- o.length > 0 && /* @__PURE__ */ G("span", {
3167
+ o.length > 0 && /* @__PURE__ */ K("span", {
2992
3168
  "aria-hidden": !0,
2993
3169
  className: "my-1 h-px w-6 bg-border/60"
2994
3170
  }),
2995
- o.map((e) => /* @__PURE__ */ G(gr, {
3171
+ o.map((e) => /* @__PURE__ */ K(Mr, {
2996
3172
  to: e.section.areaRoute,
2997
- icon: e.section.icon ?? dr,
3173
+ icon: e.section.icon ?? Dr,
2998
3174
  label: e.section.labelKey ? i(e.section.labelKey) : e.section.id,
2999
3175
  shown: !!e.section.labelKey,
3000
- count: mr(e),
3001
- active: pr(a, e)
3176
+ count: Ar(e),
3177
+ active: kr(a, e)
3002
3178
  }, e.section.id))
3003
3179
  ]
3004
3180
  })
3005
3181
  });
3006
3182
  }
3007
- function gr({ to: e, icon: t, label: n, shown: r, count: i = 0, active: a }) {
3008
- let { t: o } = q(), s = i > 0 ? o("bento.nav.count", {
3183
+ function Mr({ to: e, icon: t, label: n, shown: r, count: i = 0, active: a }) {
3184
+ let { t: o } = J(), s = i > 0 ? o("bento.nav.count", {
3009
3185
  count: i,
3010
3186
  defaultValue: "{{count}} waiting"
3011
- }) : null, c = /* @__PURE__ */ K(He, {
3187
+ }) : null, c = /* @__PURE__ */ q(Ke, {
3012
3188
  to: e,
3013
3189
  "aria-label": s ? `${n}, ${s}` : n,
3014
3190
  "aria-current": a ? "page" : void 0,
3015
3191
  className: `group flex w-full shrink-0 flex-col items-center gap-1 px-1 py-0.5 ${a ? "text-primary" : "text-muted-foreground hover:text-foreground"}`,
3016
- children: [/* @__PURE__ */ K("span", {
3192
+ children: [/* @__PURE__ */ q("span", {
3017
3193
  className: `bento-tile-clickable relative grid h-11 w-11 place-items-center rounded-2xl border transition-colors duration-200 ${a ? "bento-rail-active" : "border-transparent group-hover:border-border/60 group-hover:bg-card/60"}`,
3018
- children: [/* @__PURE__ */ G(t, { size: 20 }), i > 0 && /* @__PURE__ */ G("span", {
3194
+ children: [/* @__PURE__ */ K(t, { size: 20 }), i > 0 && /* @__PURE__ */ K("span", {
3019
3195
  "aria-hidden": !0,
3020
3196
  "data-slot": "bento-rail-count",
3021
3197
  className: "absolute -right-1 -top-1 min-w-4 rounded-full bg-primary px-1 text-center text-[0.6875rem] leading-4 text-primary-foreground",
3022
3198
  children: i > 99 ? "99+" : i
3023
3199
  })]
3024
- }), r && /* @__PURE__ */ G("span", {
3200
+ }), r && /* @__PURE__ */ K("span", {
3025
3201
  "aria-hidden": !0,
3026
3202
  title: n,
3027
3203
  className: "w-full truncate text-center text-[0.6875rem] leading-4",
3028
3204
  children: n
3029
3205
  })]
3030
3206
  });
3031
- return r ? c : /* @__PURE__ */ K(D, { children: [/* @__PURE__ */ G(ie, {
3207
+ return r ? c : /* @__PURE__ */ q(E, { children: [/* @__PURE__ */ K(u, {
3032
3208
  asChild: !0,
3033
3209
  children: c
3034
- }), /* @__PURE__ */ G(w, {
3210
+ }), /* @__PURE__ */ K(B, {
3035
3211
  side: "right",
3036
3212
  children: n
3037
3213
  })] });
3038
3214
  }
3039
3215
  //#endregion
3040
3216
  //#region src/bento/bento-user-menu.tsx
3041
- function _r({ accountRoute: e, logoutUrl: t, organizationsRoute: n, tenantAdminRoute: r, onOpenShortcuts: i, onReplayTour: a }) {
3042
- let { user: o, status: s } = N(), { t: c } = q(), l = Ge(), u = `${o.firstName ?? ""} ${o.lastName ?? ""}`.trim() || o.username || "";
3043
- return s === "loading" ? /* @__PURE__ */ G("div", {
3217
+ function Nr({ accountRoute: e, logoutUrl: t, organizationsRoute: n, tenantAdminRoute: r, onOpenShortcuts: i, onReplayTour: a }) {
3218
+ let { user: o, status: s } = F(), { t: c } = J(), u = Ye(), d = `${o.firstName ?? ""} ${o.lastName ?? ""}`.trim() || o.username || "";
3219
+ return s === "loading" ? /* @__PURE__ */ K("div", {
3044
3220
  className: "h-9 w-9 rounded-full bg-muted/40",
3045
3221
  "aria-hidden": !0
3046
- }) : /* @__PURE__ */ K(_, { children: [/* @__PURE__ */ G(P, {
3222
+ }) : /* @__PURE__ */ q(v, { children: [/* @__PURE__ */ K(T, {
3047
3223
  asChild: !0,
3048
- children: /* @__PURE__ */ G("button", {
3224
+ children: /* @__PURE__ */ K("button", {
3049
3225
  type: "button",
3050
- title: u || o.username,
3226
+ title: d || o.username,
3051
3227
  className: "bento-tile-clickable cursor-pointer rounded-full p-0.5 ring-1 ring-border/60 outline-none transition-shadow duration-300 ease-[cubic-bezier(0.32,0.72,0,1)] bento-ring hover:ring-2 focus-visible:ring-2 focus-visible:ring-ring",
3052
- children: /* @__PURE__ */ G(I, {
3228
+ children: /* @__PURE__ */ K(L, {
3053
3229
  givenName: o.firstName,
3054
3230
  familyName: o.lastName,
3055
- name: u || o.username,
3231
+ name: d || o.username,
3056
3232
  src: o.avatarUrl || void 0,
3057
3233
  alt: o.username
3058
3234
  })
3059
3235
  })
3060
- }), /* @__PURE__ */ K(d, {
3236
+ }), /* @__PURE__ */ q(ie, {
3061
3237
  align: "end",
3062
3238
  sideOffset: 10,
3063
3239
  className: "bento-dropdown min-w-64 p-2",
3064
3240
  children: [
3065
- /* @__PURE__ */ G(y, {
3241
+ /* @__PURE__ */ K(h, {
3066
3242
  className: "p-0 font-normal",
3067
- children: /* @__PURE__ */ K("div", {
3243
+ children: /* @__PURE__ */ q("div", {
3068
3244
  className: "flex items-center gap-3 rounded-xl px-2 py-2 text-left text-sm",
3069
- children: [/* @__PURE__ */ G("span", {
3245
+ children: [/* @__PURE__ */ K("span", {
3070
3246
  className: "rounded-full p-0.5 ring-1 ring-border/60",
3071
- children: /* @__PURE__ */ G(I, {
3247
+ children: /* @__PURE__ */ K(L, {
3072
3248
  givenName: o.firstName,
3073
3249
  familyName: o.lastName,
3074
- name: u || o.username,
3250
+ name: d || o.username,
3075
3251
  src: o.avatarUrl || void 0,
3076
3252
  alt: o.username
3077
3253
  })
3078
- }), /* @__PURE__ */ K("div", {
3254
+ }), /* @__PURE__ */ q("div", {
3079
3255
  className: "grid flex-1 text-left text-sm leading-tight",
3080
- children: [u && /* @__PURE__ */ G("span", {
3256
+ children: [d && /* @__PURE__ */ K("span", {
3081
3257
  className: "truncate font-medium",
3082
- children: u
3083
- }), o.email && /* @__PURE__ */ G("span", {
3258
+ children: d
3259
+ }), o.email && /* @__PURE__ */ K("span", {
3084
3260
  className: "truncate text-xs text-muted-foreground",
3085
3261
  children: o.email
3086
3262
  })]
3087
3263
  })]
3088
3264
  })
3089
3265
  }),
3090
- /* @__PURE__ */ G(f, { className: "my-1.5 bg-border/50" }),
3091
- /* @__PURE__ */ K(p, { children: [
3092
- /* @__PURE__ */ K(h, {
3093
- onSelect: () => l(e),
3266
+ /* @__PURE__ */ K(_, { className: "my-1.5 bg-border/50" }),
3267
+ /* @__PURE__ */ q(l, { children: [
3268
+ /* @__PURE__ */ q(C, {
3269
+ onSelect: () => u(e),
3094
3270
  className: "bento-dropdown-item cursor-pointer gap-2 px-3 py-2",
3095
- children: [/* @__PURE__ */ G(Le, { size: 18 }), c("nav.account")]
3271
+ children: [/* @__PURE__ */ K(Ve, { size: 18 }), c("nav.account")]
3096
3272
  }),
3097
- n && /* @__PURE__ */ K(h, {
3098
- onSelect: () => l(n),
3273
+ n && /* @__PURE__ */ q(C, {
3274
+ onSelect: () => u(n),
3099
3275
  className: "bento-dropdown-item cursor-pointer gap-2 px-3 py-2",
3100
- children: [/* @__PURE__ */ G(_e, { size: 18 }), c("nav.organizations", { defaultValue: "Organizations" })]
3276
+ children: [/* @__PURE__ */ K(be, { size: 18 }), c("nav.organizations", { defaultValue: "Organizations" })]
3101
3277
  }),
3102
- r && /* @__PURE__ */ K(h, {
3103
- onSelect: () => l(r),
3278
+ r && /* @__PURE__ */ q(C, {
3279
+ onSelect: () => u(r),
3104
3280
  className: "bento-dropdown-item cursor-pointer gap-2 px-3 py-2",
3105
- children: [/* @__PURE__ */ G(ve, { size: 18 }), c("nav.tenantAdmin", { defaultValue: "Tenant administration" })]
3281
+ children: [/* @__PURE__ */ K(xe, { size: 18 }), c("nav.tenantAdmin", { defaultValue: "Tenant administration" })]
3106
3282
  })
3107
3283
  ] }),
3108
- (i || a) && /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(f, { className: "my-1.5 bg-border/50" }), /* @__PURE__ */ K(p, { children: [a && /* @__PURE__ */ K(h, {
3284
+ (i || a) && /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K(_, { className: "my-1.5 bg-border/50" }), /* @__PURE__ */ q(l, { children: [a && /* @__PURE__ */ q(C, {
3109
3285
  onSelect: () => a(),
3110
3286
  className: "bento-dropdown-item cursor-pointer gap-2 px-3 py-2",
3111
- children: [/* @__PURE__ */ G(Pe, { size: 18 }), c("bento.tour.replay", { defaultValue: "Take the tour" })]
3112
- }), i && /* @__PURE__ */ K(h, {
3287
+ children: [/* @__PURE__ */ K(Re, { size: 18 }), c("bento.tour.replay", { defaultValue: "Take the tour" })]
3288
+ }), i && /* @__PURE__ */ q(C, {
3113
3289
  onSelect: () => i(),
3114
3290
  className: "bento-dropdown-item cursor-pointer gap-2 px-3 py-2",
3115
- children: [/* @__PURE__ */ G(De, { size: 18 }), c("bento.shortcuts.title", { defaultValue: "Keyboard shortcuts" })]
3291
+ children: [/* @__PURE__ */ K(je, { size: 18 }), c("bento.shortcuts.title", { defaultValue: "Keyboard shortcuts" })]
3116
3292
  })] })] }),
3117
- /* @__PURE__ */ G(f, { className: "my-1.5 bg-border/50" }),
3118
- /* @__PURE__ */ K(h, {
3293
+ /* @__PURE__ */ K(_, { className: "my-1.5 bg-border/50" }),
3294
+ /* @__PURE__ */ q(C, {
3119
3295
  onSelect: () => {
3120
3296
  globalThis.location.href = t;
3121
3297
  },
3122
3298
  className: "bento-dropdown-item cursor-pointer gap-2 px-3 py-2 bento-item-danger",
3123
- children: [/* @__PURE__ */ G(ke, { size: 18 }), c("nav.logOut")]
3299
+ children: [/* @__PURE__ */ K(Pe, { size: 18 }), c("nav.logOut")]
3124
3300
  })
3125
3301
  ]
3126
3302
  })] });
3127
3303
  }
3128
3304
  //#endregion
3129
3305
  //#region src/bento/bento-section-chrome.tsx
3130
- var vr = {
3306
+ var Pr = {
3131
3307
  blue: "blue",
3132
3308
  violet: "violet",
3133
3309
  emerald: "emerald",
@@ -3137,62 +3313,62 @@ var vr = {
3137
3313
  cyan: "blue",
3138
3314
  orange: "amber"
3139
3315
  };
3140
- function yr({ variant: t = "blue", className: n, children: r }) {
3316
+ function Fr({ variant: t = "blue", className: n, children: r }) {
3141
3317
  let i;
3142
- R.forEach(r, (e) => {
3143
- if (!se(e)) return;
3318
+ se.forEach(r, (e) => {
3319
+ if (!le(e)) return;
3144
3320
  let { type: t } = e;
3145
- (t === T.Header || t === T.StaticHeader) && (i ??= e.props);
3321
+ (t === z.Header || t === z.StaticHeader) && (i ??= e.props);
3146
3322
  });
3147
- let a = R.map(r, (e) => {
3148
- if (!se(e)) return e;
3323
+ let a = se.map(r, (e) => {
3324
+ if (!le(e)) return e;
3149
3325
  let { type: t } = e;
3150
- return t === T.Header || t === T.StaticHeader ? null : t === T.Content ? e.props.children : e;
3326
+ return t === z.Header || t === z.StaticHeader ? null : t === z.Content ? e.props.children : e;
3151
3327
  });
3152
- return i ? /* @__PURE__ */ G(Gn, {
3328
+ return i ? /* @__PURE__ */ K(sr, {
3153
3329
  icon: i.icon,
3154
- tone: vr[t] ?? "blue",
3330
+ tone: Pr[t] ?? "blue",
3155
3331
  title: i.title,
3156
3332
  description: i.description,
3157
3333
  className: n,
3158
3334
  children: a
3159
- }) : /* @__PURE__ */ G("section", {
3160
- className: e(Wn, n),
3335
+ }) : /* @__PURE__ */ K("section", {
3336
+ className: e(or, n),
3161
3337
  children: a
3162
3338
  });
3163
3339
  }
3164
- yr.Header = T.Header, yr.StaticHeader = T.StaticHeader, yr.Content = T.Content;
3340
+ Fr.Header = z.Header, Fr.StaticHeader = z.StaticHeader, Fr.Content = z.Content;
3165
3341
  //#endregion
3166
3342
  //#region src/bento/bento-section.tsx
3167
- var br = "bento-grid grid auto-rows-[minmax(140px,auto)] grid-cols-2 gap-4 md:grid-cols-4 md:gap-5 lg:grid-cols-6";
3168
- function xr({ eyebrow: e, title: t, description: n, titleHref: r, children: i, gridClassName: a = br }) {
3169
- let o = /* @__PURE__ */ G("h2", {
3343
+ var Ir = "bento-grid grid auto-rows-[minmax(140px,auto)] grid-cols-2 gap-4 md:grid-cols-4 md:gap-5 lg:grid-cols-6";
3344
+ function Lr({ eyebrow: e, title: t, description: n, titleHref: r, children: i, gridClassName: a = Ir }) {
3345
+ let o = /* @__PURE__ */ K("h2", {
3170
3346
  className: "text-xl font-semibold tracking-tight md:text-2xl",
3171
3347
  children: t
3172
3348
  });
3173
- return /* @__PURE__ */ K("section", {
3349
+ return /* @__PURE__ */ q("section", {
3174
3350
  className: "mb-8 md:mb-10",
3175
- children: [/* @__PURE__ */ K("header", {
3351
+ children: [/* @__PURE__ */ q("header", {
3176
3352
  className: "bento-shell-header mb-4 flex flex-col gap-0.5",
3177
3353
  children: [
3178
- e && /* @__PURE__ */ G("span", {
3354
+ e && /* @__PURE__ */ K("span", {
3179
3355
  className: "text-xs uppercase tracking-[0.18em] text-muted-foreground",
3180
3356
  children: e
3181
3357
  }),
3182
- r ? /* @__PURE__ */ K(He, {
3358
+ r ? /* @__PURE__ */ q(Ke, {
3183
3359
  to: r,
3184
3360
  className: "group inline-flex w-fit items-center gap-1 text-foreground transition-colors hover:text-primary",
3185
- children: [o, /* @__PURE__ */ G(Y, {
3361
+ children: [o, /* @__PURE__ */ K(we, {
3186
3362
  size: 20,
3187
3363
  className: "text-muted-foreground transition-transform duration-300 ease-[cubic-bezier(0.32,0.72,0,1)] group-hover:translate-x-1"
3188
3364
  })]
3189
3365
  }) : o,
3190
- n && /* @__PURE__ */ G("p", {
3366
+ n && /* @__PURE__ */ K("p", {
3191
3367
  className: "max-w-2xl text-sm text-muted-foreground",
3192
3368
  children: n
3193
3369
  })
3194
3370
  ]
3195
- }), /* @__PURE__ */ G("div", {
3371
+ }), /* @__PURE__ */ K("div", {
3196
3372
  className: a,
3197
3373
  children: i
3198
3374
  })]
@@ -3200,66 +3376,66 @@ function xr({ eyebrow: e, title: t, description: n, titleHref: r, children: i, g
3200
3376
  }
3201
3377
  //#endregion
3202
3378
  //#region src/bento/bento-tile.tsx
3203
- function Sr({ to: t, onClick: n, disabled: r = !1, disabledHint: i, icon: a, tone: o, eyebrow: s, title: c, span: l, featured: u = !1, children: d }) {
3204
- let f = !r && !!(t || n), p = u ? "h-14 w-14 rounded-2xl" : "h-9 w-9 rounded-2xl", m = u ? 28 : 18, h = u ? "text-xl font-semibold tracking-tight md:text-2xl" : "text-base font-semibold tracking-tight md:text-lg", g = /* @__PURE__ */ K(W, { children: [
3205
- u && /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G("div", {
3379
+ function Rr({ to: t, onClick: n, disabled: r = !1, disabledHint: i, icon: a, tone: o, eyebrow: s, title: c, span: l, featured: u = !1, children: d }) {
3380
+ let f = !r && !!(t || n), p = u ? "h-14 w-14 rounded-2xl" : "h-9 w-9 rounded-2xl", m = u ? 28 : 18, h = u ? "text-xl font-semibold tracking-tight md:text-2xl" : "text-base font-semibold tracking-tight md:text-lg", g = /* @__PURE__ */ q(G, { children: [
3381
+ u && /* @__PURE__ */ q(G, { children: [/* @__PURE__ */ K("div", {
3206
3382
  "aria-hidden": !0,
3207
- className: `pointer-events-none absolute -bottom-10 -right-10 h-64 w-64 rounded-full ${pt(o)} opacity-40 blur-2xl dark:opacity-50`
3208
- }), /* @__PURE__ */ G("div", {
3383
+ className: `pointer-events-none absolute -bottom-10 -right-10 h-64 w-64 rounded-full ${_t(o)} opacity-40 blur-2xl dark:opacity-50`
3384
+ }), /* @__PURE__ */ K("div", {
3209
3385
  "aria-hidden": !0,
3210
- className: `pointer-events-none absolute right-12 top-1/3 h-32 w-32 rounded-full ${pt(o)} bento-chip-tr opacity-20 blur-2xl dark:opacity-30`
3386
+ className: `pointer-events-none absolute right-12 top-1/3 h-32 w-32 rounded-full ${_t(o)} bento-chip-tr opacity-20 blur-2xl dark:opacity-30`
3211
3387
  })] }),
3212
- /* @__PURE__ */ K("div", {
3388
+ /* @__PURE__ */ q("div", {
3213
3389
  className: "relative z-1 flex items-center justify-between",
3214
- children: [/* @__PURE__ */ G("span", {
3215
- className: `grid place-items-center ${pt(o)} text-white shadow-md ${p}`,
3216
- children: /* @__PURE__ */ G(a, { size: m })
3217
- }), f && /* @__PURE__ */ G(Y, {
3390
+ children: [/* @__PURE__ */ K("span", {
3391
+ className: `grid place-items-center ${_t(o)} text-white shadow-md ${p}`,
3392
+ children: /* @__PURE__ */ K(a, { size: m })
3393
+ }), f && /* @__PURE__ */ K(we, {
3218
3394
  size: u ? 18 : 16,
3219
3395
  className: "text-muted-foreground transition-transform duration-300 ease-[cubic-bezier(0.32,0.72,0,1)] group-hover:translate-x-1"
3220
3396
  })]
3221
3397
  }),
3222
- /* @__PURE__ */ K("div", {
3398
+ /* @__PURE__ */ q("div", {
3223
3399
  className: "relative z-1",
3224
3400
  children: [
3225
- /* @__PURE__ */ G("div", {
3401
+ /* @__PURE__ */ K("div", {
3226
3402
  className: "text-[11px] uppercase tracking-wider text-muted-foreground",
3227
3403
  children: s
3228
3404
  }),
3229
- /* @__PURE__ */ G("div", {
3405
+ /* @__PURE__ */ K("div", {
3230
3406
  className: `mt-0.5 ${h}`,
3231
3407
  children: c
3232
3408
  }),
3233
- d && /* @__PURE__ */ G("div", {
3409
+ d && /* @__PURE__ */ K("div", {
3234
3410
  className: "mt-2",
3235
3411
  children: d
3236
3412
  })
3237
3413
  ]
3238
3414
  })
3239
3415
  ] }), _ = `bento-tile bento-glass group relative flex flex-col ${u ? "gap-5" : "gap-4"} overflow-hidden text-left ${u ? "p-6 md:p-7" : "p-5"} ${l}${f ? " bento-tile-clickable" : ""}${r ? " cursor-not-allowed opacity-60" : ""}`;
3240
- return r ? /* @__PURE__ */ G("div", {
3416
+ return r ? /* @__PURE__ */ K("div", {
3241
3417
  className: _,
3242
3418
  "aria-disabled": "true",
3243
3419
  title: i,
3244
3420
  children: g
3245
- }) : t ? /* @__PURE__ */ G(He, {
3421
+ }) : t ? /* @__PURE__ */ K(Ke, {
3246
3422
  to: t,
3247
3423
  className: _,
3248
3424
  children: g
3249
- }) : n ? /* @__PURE__ */ G("button", {
3425
+ }) : n ? /* @__PURE__ */ K("button", {
3250
3426
  type: "button",
3251
3427
  onClick: n,
3252
3428
  className: e("w-full", _),
3253
3429
  children: g
3254
- }) : /* @__PURE__ */ G("div", {
3430
+ }) : /* @__PURE__ */ K("div", {
3255
3431
  className: _,
3256
3432
  children: g
3257
3433
  });
3258
3434
  }
3259
3435
  //#endregion
3260
3436
  //#region src/bento/bento-version-rail.tsx
3261
- function Cr({ versions: t, selected: n, onSelect: r, label: i }) {
3262
- let { t: a, i18n: o } = q(), [s, c] = H(0), [l, u] = H([]), d = V(/* @__PURE__ */ new Map()), f = (e) => [...e].sort((e, n) => t.findIndex((e) => e.id === n) - t.findIndex((t) => t.id === e));
3437
+ function zr({ versions: t, selected: n, onSelect: r, label: i }) {
3438
+ let { t: a, i18n: o } = J(), [s, c] = W(0), [l, u] = W([]), d = U(/* @__PURE__ */ new Map()), f = (e) => [...e].sort((e, n) => t.findIndex((e) => e.id === n) - t.findIndex((t) => t.id === e));
3263
3439
  function p(e) {
3264
3440
  if (n.includes(e)) {
3265
3441
  u(l.filter((t) => t !== e)), r(n.filter((t) => t !== e));
@@ -3307,15 +3483,15 @@ function Cr({ versions: t, selected: n, onSelect: r, label: i }) {
3307
3483
  }).format(t)
3308
3484
  };
3309
3485
  };
3310
- return /* @__PURE__ */ G("ul", {
3486
+ return /* @__PURE__ */ K("ul", {
3311
3487
  role: "listbox",
3312
3488
  "aria-label": i ?? a("bento.versions.label", { defaultValue: "Versions" }),
3313
3489
  "aria-multiselectable": "true",
3314
3490
  "data-slot": "bento-version-rail",
3315
3491
  className: "m-0 flex list-none flex-col gap-1 p-0",
3316
3492
  children: t.map((r, i) => {
3317
- let o = n.includes(r.id), l = g(r.at), u = r.actor === "agent" ? Me : Ie, f = o ? "text-foreground/80" : "text-muted-foreground";
3318
- return /* @__PURE__ */ K("li", {
3493
+ let o = n.includes(r.id), l = g(r.at), u = r.actor === "agent" ? Ie : Be, f = o ? "text-foreground/80" : "text-muted-foreground";
3494
+ return /* @__PURE__ */ q("li", {
3319
3495
  ref: (e) => {
3320
3496
  e ? d.current.set(i, e) : d.current.delete(i);
3321
3497
  },
@@ -3328,26 +3504,26 @@ function Cr({ versions: t, selected: n, onSelect: r, label: i }) {
3328
3504
  },
3329
3505
  className: e("flex cursor-pointer flex-col gap-0.5 rounded-xl border px-3 py-2 text-sm outline-none transition-colors", "focus-visible:ring-2 focus-visible:ring-ring", o ? "border-primary/50 bg-primary/10" : "border-transparent hover:bg-muted/50"),
3330
3506
  children: [
3331
- /* @__PURE__ */ K("span", {
3507
+ /* @__PURE__ */ q("span", {
3332
3508
  className: "flex items-center gap-1.5 font-medium",
3333
3509
  children: [
3334
- /* @__PURE__ */ G(u, {
3510
+ /* @__PURE__ */ K(u, {
3335
3511
  size: 14,
3336
3512
  "aria-hidden": "true"
3337
3513
  }),
3338
3514
  r.author,
3339
- /* @__PURE__ */ G("span", {
3515
+ /* @__PURE__ */ K("span", {
3340
3516
  className: e("text-xs font-normal", f),
3341
3517
  children: r.actor === "agent" ? a("bento.versions.agent", { defaultValue: "Agent" }) : a("bento.versions.human", { defaultValue: "Person" })
3342
3518
  })
3343
3519
  ]
3344
3520
  }),
3345
- /* @__PURE__ */ G("time", {
3521
+ /* @__PURE__ */ K("time", {
3346
3522
  dateTime: l.iso,
3347
3523
  className: e("text-xs", f),
3348
3524
  children: l.text
3349
3525
  }),
3350
- r.summary && /* @__PURE__ */ G("span", {
3526
+ r.summary && /* @__PURE__ */ K("span", {
3351
3527
  className: "text-xs",
3352
3528
  children: r.summary
3353
3529
  })
@@ -3357,4 +3533,4 @@ function Cr({ versions: t, selected: n, onSelect: r, label: i }) {
3357
3533
  });
3358
3534
  }
3359
3535
  //#endregion
3360
- export { yr as AdaptiveSectionCard, _n as BENTO_EMPHASIS_NEXT, gn as BENTO_EMPHASIS_SPAN, Et as BENTO_RECORD_STATES, rr as BENTO_SHELL_SHORTCUTS, ft as BENTO_TONES, dt as BENTO_TONE_CLASS, ut as BentoActionsMenu, xt as BentoBackLink, Xn as BentoBackToTop, mn as BentoCalendar, Mt as BentoChangeMark, er as BentoCommandPalette, mt as BentoCountTile, _t as BentoDataTable, It as BentoDiff, vt as BentoEmptyState, At as BentoEntityShell, bn as BentoEntityTile, Tn as BentoFilterBar, Un as BentoFormHero, Gn as BentoFormSection, Ct as BentoHero, wt as BentoHeroIconPicker, Tt as BentoInlineEdit, jn as BentoListPage, hr as BentoNavRail, lr as BentoPaletteTrigger, Kn as BentoPanel, Bn as BentoSaveBar, Hn as BentoScrollSaveBar, xr as BentoSection, tr as BentoShell, ur as BentoShortcutsDialog, sn as BentoSplitPage, Dt as BentoStatusMarker, Sr as BentoTile, Mn as BentoTileGrid, bt as BentoTrail, _r as BentoUserMenu, Cr as BentoVersionRail, xn as EMPTY_FILTERS, pt as bentoChipClass, Zn as bentoNavTarget, vn as resolveBentoLayout, yn as toBentoLayoutEntries, Ot as useBentoScrollFade, cr as useBentoShellShortcuts };
3536
+ export { Fr as AdaptiveSectionCard, Nn as BENTO_EMPHASIS_NEXT, Mn as BENTO_EMPHASIS_SPAN, Mt as BENTO_RECORD_STATES, yr as BENTO_SHELL_SHORTCUTS, gt as BENTO_TONES, ht as BENTO_TONE_CLASS, mt as BentoActionsMenu, Dt as BentoBackLink, fr as BentoBackToTop, An as BentoCalendar, hn as BentoChangeCell, Rt as BentoChangeMark, gr as BentoCommandPalette, vt as BentoCountTile, Ct as BentoDataTable, Ht as BentoDiff, wt as BentoEmptyState, It as BentoEntityShell, In as BentoEntityTile, Vn as BentoFilterBar, ar as BentoFormHero, sr as BentoFormSection, kt as BentoHero, At as BentoHeroIconPicker, _n as BentoIdentityCell, jt as BentoInlineEdit, qn as BentoListPage, jr as BentoNavRail, Tr as BentoPaletteTrigger, cr as BentoPanel, nr as BentoSaveBar, ir as BentoScrollSaveBar, Lr as BentoSection, _r as BentoShell, Er as BentoShortcutsDialog, xn as BentoSplitPage, Nt as BentoStatusMarker, Rr as BentoTile, Jn as BentoTileGrid, Et as BentoTrail, Nr as BentoUserMenu, zr as BentoVersionRail, Ln as EMPTY_FILTERS, _t as bentoChipClass, pr as bentoNavTarget, Pn as resolveBentoLayout, Fn as toBentoLayoutEntries, Pt as useBentoScrollFade, wr as useBentoShellShortcuts };