@declarion/react 0.6.7 → 0.6.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist-lib/index.js +638 -626
  2. package/package.json +11 -11
package/dist-lib/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { $ as e, A as t, At as n, B as r, Bt as i, C as a, Ct as o, D as s, Dt as c, E as l, Et as u, F as d, Ft as f, G as p, Gt as m, H as h, Ht as g, I as _, It as v, J as y, Jt as b, K as x, Kt as S, L as C, Lt as w, M as T, Mt as E, N as D, Nt as O, O as k, Ot as A, P as j, Pt as ee, Q as M, Qt as N, R as P, Rt as F, S as I, St as L, T as te, Tt as ne, U as R, Ut as re, V as ie, Vt as ae, W as oe, Wt as se, X as ce, Xt as z, Y as le, Yt as B, Z as ue, Zt as V, _ as de, _t as fe, a as H, at as pe, b as me, bt as he, c as ge, ct as _e, d as ve, dt as ye, et as be, f as xe, ft as Se, g as Ce, gt as we, h as Te, ht as U, i as Ee, it as De, j as Oe, jt as ke, k as Ae, kt as je, l as Me, lt as Ne, m as Pe, mt as W, n as Fe, nt as Ie, o as Le, ot as Re, p as ze, pt as Be, q as Ve, qt as He, r as Ue, rt as We, s as Ge, st as Ke, t as qe, tt as Je, u as Ye, ut as Xe, v as Ze, vt as Qe, w as $e, wt as et, x as tt, xt as nt, y as rt, yt as it, z as at, zt as ot } from "./dataTableStyles-zH3M7xdm.js";
1
+ import { $ as e, A as t, At as n, B as r, Bt as i, C as a, Ct as o, D as s, Dt as c, E as l, Et as u, F as d, Ft as f, G as p, Gt as m, H as h, Ht as g, I as _, It as v, J as y, Jt as b, K as x, Kt as S, L as C, Lt as w, M as T, Mt as E, N as D, Nt as O, O as k, Ot as A, P as j, Pt as ee, Q as te, Qt as M, R as N, Rt as P, S as F, St as I, T as ne, Tt as L, U as R, Ut as re, V as ie, Vt as ae, W as oe, Wt as se, X as ce, Xt as z, Y as le, Yt as B, Z as ue, Zt as V, _ as de, _t as fe, a as H, at as pe, b as me, bt as he, c as ge, ct as _e, d as ve, dt as ye, et as be, f as xe, ft as Se, g as Ce, gt as we, h as Te, ht as U, i as Ee, it as De, j as Oe, jt as ke, k as Ae, kt as je, l as Me, lt as Ne, m as Pe, mt as W, n as Fe, nt as Ie, o as Le, ot as Re, p as ze, pt as Be, q as Ve, qt as He, r as Ue, rt as We, s as Ge, st as Ke, t as qe, tt as Je, u as Ye, ut as Xe, v as Ze, vt as Qe, w as $e, wt as et, x as tt, xt as nt, y as rt, yt as it, z as at, zt as ot } from "./dataTableStyles-zH3M7xdm.js";
2
2
  import { A as st, B as ct, C as lt, D as ut, F as dt, G as ft, H as pt, I as mt, K as ht, L as gt, M as _t, N as vt, O as yt, P as bt, R as xt, S as St, T as Ct, U as wt, V as Tt, W as Et, _ as Dt, a as Ot, b as kt, j as At, o as jt, q as Mt, s as Nt, v as Pt, x as Ft, y as It } from "./value-CrpaObP_.js";
3
3
  import { Component as Lt, Fragment as Rt, Suspense as zt, createContext as Bt, createElement as Vt, lazy as Ht, useCallback as G, useContext as Ut, useEffect as K, useLayoutEffect as Wt, useMemo as q, useRef as J, useState as Y } from "react";
4
4
  import { BrowserRouter as Gt, Link as Kt, Navigate as qt, Outlet as Jt, Route as Yt, Routes as Xt, useLocation as Zt, useLocation as Qt, useNavigate as $t, useNavigate as en, useParams as tn, useParams as nn, useSearchParams as rn, useSearchParams as an } from "react-router-dom";
@@ -83,7 +83,7 @@ function Tn({ activeArea: e, onPick: t, onToggleAI: n, aiOpen: r, onCmdK: i, are
83
83
  onClick: i,
84
84
  title: "Command Palette (⌘K)",
85
85
  style: Dn(!1),
86
- children: N.command && /* @__PURE__ */ Z(N.command, { size: 16 })
86
+ children: M.command && /* @__PURE__ */ Z(M.command, { size: 16 })
87
87
  }),
88
88
  /* @__PURE__ */ Z("button", {
89
89
  onClick: n,
@@ -93,13 +93,13 @@ function Tn({ activeArea: e, onPick: t, onToggleAI: n, aiOpen: r, onCmdK: i, are
93
93
  background: r ? "var(--accent)" : "transparent",
94
94
  color: r ? "var(--rail-fg)" : "var(--rail-muted)"
95
95
  },
96
- children: N.sparkle && /* @__PURE__ */ Z(N.sparkle, { size: 16 })
96
+ children: M.sparkle && /* @__PURE__ */ Z(M.sparkle, { size: 16 })
97
97
  })
98
98
  ]
99
99
  });
100
100
  }
101
101
  function En({ item: e, active: t, onPick: n }) {
102
- let [r, i] = Y(!1), a = e.icon ? N[e.icon] : void 0;
102
+ let [r, i] = Y(!1), a = e.icon ? M[e.icon] : void 0;
103
103
  e.icon && !a && console.error(`[declarion] area "${e.id}" uses unknown icon "${e.icon}"`);
104
104
  let o = t ? "var(--rail-active)" : r ? "var(--rail-hover)" : "transparent", s = t || r ? "var(--rail-fg)" : "var(--rail-muted)";
105
105
  return /* @__PURE__ */ Q("button", {
@@ -687,21 +687,21 @@ function Dr(e, t = window.location) {
687
687
  return n.protocol !== "http:" && n.protocol !== "https:" || n.origin !== t.origin ? null : n.pathname + n.search + n.hash;
688
688
  }
689
689
  function Or() {
690
- let e = Mr(), t = J(e);
691
- t.current = e, K(() => {
690
+ let e = Mr(), t = rr().enabled, n = J(e);
691
+ n.current = e, K(() => {
692
692
  let e = (e) => {
693
- let n = Er(e);
694
- n != null && (e.preventDefault(), t.current(n));
693
+ let t = Er(e);
694
+ t != null && (e.preventDefault(), n.current(t));
695
695
  };
696
696
  document.addEventListener("click", e, { capture: !0 });
697
- let n = window.navigation, r = (e) => {
698
- let n = Dr(e);
699
- n != null && e.cancelable && (e.preventDefault(), t.current(n));
697
+ let r = window.navigation, i = (e) => {
698
+ let t = Dr(e);
699
+ t != null && e.cancelable && (e.preventDefault(), n.current(t));
700
700
  };
701
- return n?.addEventListener("navigate", r), () => {
702
- document.removeEventListener("click", e, { capture: !0 }), n?.removeEventListener("navigate", r);
701
+ return t && r?.addEventListener("navigate", i), () => {
702
+ document.removeEventListener("click", e, { capture: !0 }), t && r?.removeEventListener("navigate", i);
703
703
  };
704
- }, []);
704
+ }, [t]);
705
705
  }
706
706
  //#endregion
707
707
  //#region src/embed/EmbedLocationReporter.tsx
@@ -768,7 +768,7 @@ function Ar({ open: e, onOpenChange: t, title: n, description: r, confirmLabel:
768
768
  justifyContent: "center",
769
769
  flexShrink: 0
770
770
  },
771
- children: Z(o ? N.trash : N.info, { size: 15 })
771
+ children: Z(o ? M.trash : M.info, { size: 15 })
772
772
  }),
773
773
  /* @__PURE__ */ Q("div", {
774
774
  style: {
@@ -792,7 +792,7 @@ function Ar({ open: e, onOpenChange: t, title: n, description: r, confirmLabel:
792
792
  })]
793
793
  }),
794
794
  /* @__PURE__ */ Z(z, {
795
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
795
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
796
796
  onClick: () => t(!1)
797
797
  })
798
798
  ]
@@ -1021,7 +1021,7 @@ function Nr({ activeArea: e }) {
1021
1021
  color: "var(--text-3)",
1022
1022
  cursor: "pointer"
1023
1023
  },
1024
- children: Z(o ? N.right : N.left, { size: 14 })
1024
+ children: Z(o ? M.right : M.left, { size: 14 })
1025
1025
  }), !o && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z("span", {
1026
1026
  style: {
1027
1027
  flex: 1,
@@ -1058,7 +1058,7 @@ function Fr(e, t) {
1058
1058
  return (e.area || "default") === t;
1059
1059
  }
1060
1060
  function Ir({ item: e, href: t, collapsed: n, active: r, hasKids: i, expanded: a, onToggleExpand: o, onPick: s, onPickChild: c, resolveChild: l }) {
1061
- let [u, d] = Y(!1), f = N, p = e.icon && f[e.icon] ? f[e.icon] : void 0;
1061
+ let [u, d] = Y(!1), f = M, p = e.icon && f[e.icon] ? f[e.icon] : void 0;
1062
1062
  e.icon && !p && console.error(`[declarion] nav item "${e.screen ?? W(e.name)}" uses unknown icon "${e.icon}"`);
1063
1063
  let m = W(e.name) || e.screen || "";
1064
1064
  if (n) {
@@ -1140,7 +1140,7 @@ function Ir({ item: e, href: t, collapsed: n, active: r, hasKids: i, expanded: a
1140
1140
  padding: 2,
1141
1141
  cursor: "pointer"
1142
1142
  },
1143
- children: /* @__PURE__ */ Z(N.down, {
1143
+ children: /* @__PURE__ */ Z(M.down, {
1144
1144
  size: 11,
1145
1145
  style: {
1146
1146
  transform: a ? "rotate(0)" : "rotate(-90deg)",
@@ -1248,10 +1248,10 @@ function Br({ type: e }) {
1248
1248
  ...t,
1249
1249
  animation: "dz-toast-spin 0.9s linear infinite"
1250
1250
  },
1251
- children: /* @__PURE__ */ Z(N.loader, { size: 11 })
1251
+ children: /* @__PURE__ */ Z(M.loader, { size: 11 })
1252
1252
  }) : /* @__PURE__ */ Z("span", {
1253
1253
  style: t,
1254
- children: /* @__PURE__ */ Z(e === "success" ? N.check : e === "error" ? N.x : e === "warning" ? N.warning : N.info, { size: 11 })
1254
+ children: /* @__PURE__ */ Z(e === "success" ? M.check : e === "error" ? M.x : e === "warning" ? M.warning : M.info, { size: 11 })
1255
1255
  });
1256
1256
  }
1257
1257
  function Vr({ model: e, onClose: t }) {
@@ -1405,7 +1405,7 @@ function Vr({ model: e, onClose: t }) {
1405
1405
  alignItems: "center",
1406
1406
  gap: 4
1407
1407
  },
1408
- children: [/* @__PURE__ */ Z(N.down, {
1408
+ children: [/* @__PURE__ */ Z(M.down, {
1409
1409
  size: 10,
1410
1410
  style: {
1411
1411
  transform: c ? "rotate(180deg)" : "none",
@@ -1473,7 +1473,7 @@ function Vr({ model: e, onClose: t }) {
1473
1473
  cursor: "pointer",
1474
1474
  fontWeight: 500
1475
1475
  },
1476
- children: [Z(o ? N.check : N.copy, { size: 11 }), o ? "Copied" : "Copy"]
1476
+ children: [Z(o ? M.check : M.copy, { size: 11 }), o ? "Copied" : "Copy"]
1477
1477
  })]
1478
1478
  })
1479
1479
  ]
@@ -1497,7 +1497,7 @@ function Vr({ model: e, onClose: t }) {
1497
1497
  alignItems: "center",
1498
1498
  justifyContent: "center"
1499
1499
  },
1500
- children: /* @__PURE__ */ Z(N.x, { size: 12 })
1500
+ children: /* @__PURE__ */ Z(M.x, { size: 12 })
1501
1501
  })
1502
1502
  ]
1503
1503
  }), g && /* @__PURE__ */ Z("div", {
@@ -1734,7 +1734,7 @@ function ri({ tenant: e, tenants: t, onSwitch: n, busy: r, locked: i, lockedReas
1734
1734
  title: i ? a || "Tenant switching is disabled" : "Current tenant / environment",
1735
1735
  disabled: r || i,
1736
1736
  children: [
1737
- /* @__PURE__ */ Z(N.tenant, {
1737
+ /* @__PURE__ */ Z(M.tenant, {
1738
1738
  size: 13,
1739
1739
  style: { color: "var(--text-3)" }
1740
1740
  }),
@@ -1757,7 +1757,7 @@ function ri({ tenant: e, tenants: t, onSwitch: n, busy: r, locked: i, lockedReas
1757
1757
  },
1758
1758
  children: d
1759
1759
  }),
1760
- /* @__PURE__ */ Z(N.down, {
1760
+ /* @__PURE__ */ Z(M.down, {
1761
1761
  size: 11,
1762
1762
  style: { color: "var(--text-3)" }
1763
1763
  })
@@ -1793,7 +1793,7 @@ function ri({ tenant: e, tenants: t, onSwitch: n, busy: r, locked: i, lockedReas
1793
1793
  marginTop: 4
1794
1794
  },
1795
1795
  children: [
1796
- /* @__PURE__ */ Z(N.tenant, {
1796
+ /* @__PURE__ */ Z(M.tenant, {
1797
1797
  size: 13,
1798
1798
  style: { color: "var(--accent)" }
1799
1799
  }),
@@ -1911,7 +1911,7 @@ function ri({ tenant: e, tenants: t, onSwitch: n, busy: r, locked: i, lockedReas
1911
1911
  alignItems: "flex-start",
1912
1912
  gap: 6
1913
1913
  },
1914
- children: [/* @__PURE__ */ Z(N.info, {
1914
+ children: [/* @__PURE__ */ Z(M.info, {
1915
1915
  size: 11,
1916
1916
  style: {
1917
1917
  marginTop: 2,
@@ -1959,7 +1959,7 @@ function ai({ tenant: e, tone: t, active: n, onPick: r }) {
1959
1959
  textAlign: "left"
1960
1960
  },
1961
1961
  children: [
1962
- /* @__PURE__ */ Z(N.tenant, {
1962
+ /* @__PURE__ */ Z(M.tenant, {
1963
1963
  size: 12,
1964
1964
  style: { color: "var(--text-3)" }
1965
1965
  }),
@@ -2004,7 +2004,7 @@ function ai({ tenant: e, tone: t, active: n, onPick: r }) {
2004
2004
  },
2005
2005
  children: e.role
2006
2006
  }),
2007
- n && /* @__PURE__ */ Z(N.check, {
2007
+ n && /* @__PURE__ */ Z(M.check, {
2008
2008
  size: 12,
2009
2009
  style: {
2010
2010
  color: "var(--accent)",
@@ -2034,7 +2034,7 @@ function oi({ items: e, onCrumbClick: t }) {
2034
2034
  color: "var(--text-4)",
2035
2035
  padding: "0 4px"
2036
2036
  },
2037
- children: /* @__PURE__ */ Z(N.right, { size: 11 })
2037
+ children: /* @__PURE__ */ Z(M.right, { size: 11 })
2038
2038
  }), /* @__PURE__ */ Z(si, {
2039
2039
  crumb: n,
2040
2040
  last: i,
@@ -2045,7 +2045,7 @@ function oi({ items: e, onCrumbClick: t }) {
2045
2045
  });
2046
2046
  }
2047
2047
  function si({ crumb: e, last: t, clickable: n, onClick: r }) {
2048
- let [i, a] = Y(!1), o = e.icon && N[e.icon] ? N[e.icon] : N.folder;
2048
+ let [i, a] = Y(!1), o = e.icon && M[e.icon] ? M[e.icon] : M.folder;
2049
2049
  return /* @__PURE__ */ Q("button", {
2050
2050
  onClick: () => {
2051
2051
  n && (r ? r(e) : e.onClick && e.onClick());
@@ -2132,14 +2132,14 @@ function ci({ breadcrumbs: e, onCrumbClick: t, onCmdK: n, onToggleAI: r, aiOpen:
2132
2132
  textTransform: "uppercase",
2133
2133
  letterSpacing: "0.05em"
2134
2134
  },
2135
- children: [/* @__PURE__ */ Z(N.users, { size: 11 }), " Impersonating"]
2135
+ children: [/* @__PURE__ */ Z(M.users, { size: 11 }), " Impersonating"]
2136
2136
  }),
2137
2137
  /* @__PURE__ */ Z("span", {
2138
2138
  style: {
2139
2139
  color: "var(--text-4)",
2140
2140
  fontSize: 11
2141
2141
  },
2142
- children: /* @__PURE__ */ Z(N.right, { size: 10 })
2142
+ children: /* @__PURE__ */ Z(M.right, { size: 10 })
2143
2143
  }),
2144
2144
  /* @__PURE__ */ Z(oi, {
2145
2145
  items: e ?? [],
@@ -2163,7 +2163,7 @@ function ci({ breadcrumbs: e, onCrumbClick: t, onCmdK: n, onToggleAI: r, aiOpen:
2163
2163
  minWidth: 240
2164
2164
  },
2165
2165
  children: [
2166
- /* @__PURE__ */ Z(N.search, { size: 13 }),
2166
+ /* @__PURE__ */ Z(M.search, { size: 13 }),
2167
2167
  /* @__PURE__ */ Z("span", {
2168
2168
  style: {
2169
2169
  flex: 1,
@@ -2175,16 +2175,16 @@ function ci({ breadcrumbs: e, onCrumbClick: t, onCmdK: n, onToggleAI: r, aiOpen:
2175
2175
  ]
2176
2176
  }),
2177
2177
  /* @__PURE__ */ Z(z, {
2178
- icon: /* @__PURE__ */ Z(N.bell, { size: 15 }),
2178
+ icon: /* @__PURE__ */ Z(M.bell, { size: 15 }),
2179
2179
  title: "Notifications"
2180
2180
  }),
2181
2181
  /* @__PURE__ */ Z(z, {
2182
- icon: Z(_ === "dark" ? N.sun : N.moon, { size: 15 }),
2182
+ icon: Z(_ === "dark" ? M.sun : M.moon, { size: 15 }),
2183
2183
  title: "Theme",
2184
2184
  onClick: D
2185
2185
  }),
2186
2186
  /* @__PURE__ */ Z(z, {
2187
- icon: /* @__PURE__ */ Z(N.sparkle, { size: 15 }),
2187
+ icon: /* @__PURE__ */ Z(M.sparkle, { size: 15 }),
2188
2188
  title: "AI Assistant",
2189
2189
  onClick: r,
2190
2190
  active: i
@@ -2222,7 +2222,7 @@ function ci({ breadcrumbs: e, onCrumbClick: t, onCmdK: n, onToggleAI: r, aiOpen:
2222
2222
  },
2223
2223
  children: T
2224
2224
  }),
2225
- /* @__PURE__ */ Z(N.down, {
2225
+ /* @__PURE__ */ Z(M.down, {
2226
2226
  size: 11,
2227
2227
  style: { color: "var(--text-3)" }
2228
2228
  })
@@ -2291,36 +2291,36 @@ function ci({ breadcrumbs: e, onCrumbClick: t, onCmdK: n, onToggleAI: r, aiOpen:
2291
2291
  })]
2292
2292
  })]
2293
2293
  }),
2294
- h && /* @__PURE__ */ Z(F, {
2295
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
2294
+ h && /* @__PURE__ */ Z(P, {
2295
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
2296
2296
  onClick: () => {
2297
2297
  x(!1), g();
2298
2298
  },
2299
2299
  "data-testid": "exit-impersonation-menu-item",
2300
2300
  children: "Exit impersonation"
2301
2301
  }),
2302
- /* @__PURE__ */ Z(F, {
2303
- icon: /* @__PURE__ */ Z(N.users, { size: 13 }),
2302
+ /* @__PURE__ */ Z(P, {
2303
+ icon: /* @__PURE__ */ Z(M.users, { size: 13 }),
2304
2304
  onClick: () => {
2305
2305
  x(!1), a?.();
2306
2306
  },
2307
2307
  children: "My profile"
2308
2308
  }),
2309
- /* @__PURE__ */ Z(F, {
2310
- icon: /* @__PURE__ */ Z(N.settings, { size: 13 }),
2309
+ /* @__PURE__ */ Z(P, {
2310
+ icon: /* @__PURE__ */ Z(M.settings, { size: 13 }),
2311
2311
  onClick: () => {
2312
2312
  x(!1), o?.();
2313
2313
  },
2314
2314
  children: "Preferences"
2315
2315
  }),
2316
- /* @__PURE__ */ Z(F, {
2317
- icon: /* @__PURE__ */ Z(N.moon, { size: 13 }),
2316
+ /* @__PURE__ */ Z(P, {
2317
+ icon: /* @__PURE__ */ Z(M.moon, { size: 13 }),
2318
2318
  onClick: D,
2319
2319
  children: "Toggle theme"
2320
2320
  }),
2321
- /* @__PURE__ */ Z(F, { divider: !0 }),
2322
- /* @__PURE__ */ Z(F, {
2323
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
2321
+ /* @__PURE__ */ Z(P, { divider: !0 }),
2322
+ /* @__PURE__ */ Z(P, {
2323
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
2324
2324
  danger: !0,
2325
2325
  onClick: () => {
2326
2326
  x(!1), f();
@@ -2497,7 +2497,7 @@ function li({ onNew: e, onCloseRequest: t } = {}) {
2497
2497
  onMouseLeave: (e) => {
2498
2498
  e.currentTarget.style.background = "transparent", e.currentTarget.style.color = "var(--text-4)";
2499
2499
  },
2500
- children: /* @__PURE__ */ Z(N.x, { size: 11 })
2500
+ children: /* @__PURE__ */ Z(M.x, { size: 11 })
2501
2501
  })
2502
2502
  ]
2503
2503
  }, e.id);
@@ -2516,7 +2516,7 @@ function li({ onNew: e, onCloseRequest: t } = {}) {
2516
2516
  alignItems: "center",
2517
2517
  justifyContent: "center"
2518
2518
  },
2519
- children: /* @__PURE__ */ Z(N.plus, { size: 13 })
2519
+ children: /* @__PURE__ */ Z(M.plus, { size: 13 })
2520
2520
  })]
2521
2521
  }), /* @__PURE__ */ Q("div", {
2522
2522
  className: "tabstrip-utility",
@@ -2585,7 +2585,7 @@ function li({ onNew: e, onCloseRequest: t } = {}) {
2585
2585
  onMouseLeave: (e) => {
2586
2586
  e.currentTarget.style.background = "transparent";
2587
2587
  },
2588
- children: /* @__PURE__ */ Z(N.more, { size: 13 })
2588
+ children: /* @__PURE__ */ Z(M.more, { size: 13 })
2589
2589
  }),
2590
2590
  /* @__PURE__ */ Z(ui, {
2591
2591
  open: s,
@@ -2608,30 +2608,30 @@ function ui({ open: e, anchor: t, onClose: n, canCloseCurrent: r, canCloseOthers
2608
2608
  align: "end",
2609
2609
  width: 230,
2610
2610
  children: [
2611
- /* @__PURE__ */ Z(F, {
2612
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
2611
+ /* @__PURE__ */ Z(P, {
2612
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
2613
2613
  disabled: !r,
2614
2614
  title: r ? void 0 : "No current tab can be closed",
2615
2615
  onClick: () => o("current"),
2616
2616
  children: "Close current tab"
2617
2617
  }),
2618
- /* @__PURE__ */ Z(F, {
2619
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
2618
+ /* @__PURE__ */ Z(P, {
2619
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
2620
2620
  disabled: !i,
2621
2621
  title: i ? void 0 : "No other tabs",
2622
2622
  onClick: () => o("others"),
2623
2623
  children: "Close others"
2624
2624
  }),
2625
- /* @__PURE__ */ Z(F, {
2626
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
2625
+ /* @__PURE__ */ Z(P, {
2626
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
2627
2627
  disabled: !a,
2628
2628
  title: a ? void 0 : "No tabs to the right",
2629
2629
  onClick: () => o("right"),
2630
2630
  children: "Close tabs to the right"
2631
2631
  }),
2632
- /* @__PURE__ */ Z(F, { divider: !0 }),
2633
- /* @__PURE__ */ Z(F, {
2634
- icon: /* @__PURE__ */ Z(N.trash, { size: 13 }),
2632
+ /* @__PURE__ */ Z(P, { divider: !0 }),
2633
+ /* @__PURE__ */ Z(P, {
2634
+ icon: /* @__PURE__ */ Z(M.trash, { size: 13 }),
2635
2635
  danger: !0,
2636
2636
  onClick: () => o("all"),
2637
2637
  children: "Close all tabs"
@@ -2698,7 +2698,7 @@ function di({ pending: e, onCancel: t, onCloseClean: n, onDiscardAll: r }) {
2698
2698
  justifyContent: "center",
2699
2699
  flexShrink: 0
2700
2700
  },
2701
- children: /* @__PURE__ */ Z(N.warning, { size: 15 })
2701
+ children: /* @__PURE__ */ Z(M.warning, { size: 15 })
2702
2702
  }),
2703
2703
  /* @__PURE__ */ Q("div", {
2704
2704
  style: {
@@ -2727,7 +2727,7 @@ function di({ pending: e, onCancel: t, onCloseClean: n, onDiscardAll: r }) {
2727
2727
  })]
2728
2728
  }),
2729
2729
  /* @__PURE__ */ Z(z, {
2730
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
2730
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
2731
2731
  onClick: t,
2732
2732
  title: "Cancel"
2733
2733
  })
@@ -3007,7 +3007,7 @@ function xi(e) {
3007
3007
  //#region src/components/shell/CommandPalette.tsx
3008
3008
  function Si(e, t = 14) {
3009
3009
  if (!e) return null;
3010
- let n = N[e];
3010
+ let n = M[e];
3011
3011
  return n ? /* @__PURE__ */ Z(n, { size: t }) : /* @__PURE__ */ Z(ie, {
3012
3012
  name: e,
3013
3013
  size: t
@@ -3032,7 +3032,7 @@ function Ci(e, t, n) {
3032
3032
  actionType: "nav"
3033
3033
  }), i.type === "list" && i.entity && r.push({
3034
3034
  group: "Create",
3035
- icon: /* @__PURE__ */ Z(N.plus, { size: 14 }),
3035
+ icon: /* @__PURE__ */ Z(M.plus, { size: 14 }),
3036
3036
  label: `New ${t}`,
3037
3037
  act: () => n({
3038
3038
  type: "new",
@@ -3058,7 +3058,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3058
3058
  let e = [];
3059
3059
  return e.push(...Ci(i, a, n)), o && e.push({
3060
3060
  group: "AI",
3061
- icon: /* @__PURE__ */ Z(N.sparkle, { size: 14 }),
3061
+ icon: /* @__PURE__ */ Z(M.sparkle, { size: 14 }),
3062
3062
  label: "Draft YAML for new entity…",
3063
3063
  hint: "✨",
3064
3064
  act: () => n({
@@ -3068,21 +3068,21 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3068
3068
  actionType: "ai"
3069
3069
  }, {
3070
3070
  group: "AI",
3071
- icon: /* @__PURE__ */ Z(N.sparkle, { size: 14 }),
3071
+ icon: /* @__PURE__ */ Z(M.sparkle, { size: 14 }),
3072
3072
  label: "Explain this record with AI",
3073
3073
  hint: "✨",
3074
3074
  act: () => n({ type: "ai-panel" }),
3075
3075
  actionType: "ai-panel"
3076
3076
  }, {
3077
3077
  group: "AI",
3078
- icon: /* @__PURE__ */ Z(N.sparkle, { size: 14 }),
3078
+ icon: /* @__PURE__ */ Z(M.sparkle, { size: 14 }),
3079
3079
  label: "Summarize activity on selected rows",
3080
3080
  hint: "✨",
3081
3081
  act: () => n({ type: "ai-panel" }),
3082
3082
  actionType: "ai-panel"
3083
3083
  }), e.push({
3084
3084
  group: "Tabs",
3085
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
3085
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
3086
3086
  label: "Close all tabs",
3087
3087
  act: () => n({
3088
3088
  type: "tab-close",
@@ -3091,7 +3091,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3091
3091
  actionType: "tab-close"
3092
3092
  }, {
3093
3093
  group: "Tabs",
3094
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
3094
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
3095
3095
  label: "Close other tabs",
3096
3096
  act: () => n({
3097
3097
  type: "tab-close",
@@ -3100,7 +3100,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3100
3100
  actionType: "tab-close"
3101
3101
  }, {
3102
3102
  group: "Tabs",
3103
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
3103
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
3104
3104
  label: "Close tabs to the right",
3105
3105
  act: () => n({
3106
3106
  type: "tab-close",
@@ -3109,7 +3109,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3109
3109
  actionType: "tab-close"
3110
3110
  }, {
3111
3111
  group: "Settings",
3112
- icon: /* @__PURE__ */ Z(N.settings, { size: 14 }),
3112
+ icon: /* @__PURE__ */ Z(M.settings, { size: 14 }),
3113
3113
  label: "Open Preferences",
3114
3114
  act: () => n({
3115
3115
  type: "nav",
@@ -3119,7 +3119,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3119
3119
  actionType: "nav"
3120
3120
  }, {
3121
3121
  group: "Settings",
3122
- icon: /* @__PURE__ */ Z(N.moon, { size: 14 }),
3122
+ icon: /* @__PURE__ */ Z(M.moon, { size: 14 }),
3123
3123
  label: "Toggle dark mode",
3124
3124
  act: () => n({ type: "theme" }),
3125
3125
  actionType: "theme"
@@ -3177,7 +3177,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3177
3177
  borderBottom: "1px solid var(--divider)"
3178
3178
  },
3179
3179
  children: [
3180
- /* @__PURE__ */ Z(N.command, {
3180
+ /* @__PURE__ */ Z(M.command, {
3181
3181
  size: 15,
3182
3182
  style: { color: "var(--text-3)" }
3183
3183
  }),
@@ -3266,7 +3266,7 @@ function wi({ open: e, onClose: t, onAction: n, mode: r = "default", navigation:
3266
3266
  fontSize: 12.5
3267
3267
  },
3268
3268
  children: [
3269
- /* @__PURE__ */ Z(N.sparkle, {
3269
+ /* @__PURE__ */ Z(M.sparkle, {
3270
3270
  size: 20,
3271
3271
  style: {
3272
3272
  color: "var(--accent)",
@@ -3764,13 +3764,13 @@ function ia(e) {
3764
3764
  break;
3765
3765
  }
3766
3766
  case "text.delta": {
3767
- let n = L(t.payload?.text), r = ra(t);
3767
+ let n = I(t.payload?.text), r = ra(t);
3768
3768
  if (!r || !n) break;
3769
3769
  o((t) => Qi(t, e, r, n));
3770
3770
  break;
3771
3771
  }
3772
3772
  case "elicit.pending": {
3773
- let e = L(t.payload?.tool_use_id), n = L(t.payload?.message), r = t.payload?.schema ?? {};
3773
+ let e = I(t.payload?.tool_use_id), n = I(t.payload?.message), r = t.payload?.schema ?? {};
3774
3774
  if (!e) break;
3775
3775
  c((t) => ({
3776
3776
  ...t,
@@ -3787,8 +3787,8 @@ function ia(e) {
3787
3787
  c((r) => ({
3788
3788
  ...r,
3789
3789
  pendingTools: [...r.pendingTools, {
3790
- id: L(t.payload?.invocation_id),
3791
- name: L(t.payload?.tool),
3790
+ id: I(t.payload?.invocation_id),
3791
+ name: I(t.payload?.tool),
3792
3792
  params: t.payload?.params ?? {},
3793
3793
  reason: e,
3794
3794
  confidence: n
@@ -3820,7 +3820,7 @@ function ia(e) {
3820
3820
  c((e) => ({
3821
3821
  ...e,
3822
3822
  hints: [...e.hints, {
3823
- kind: L(t.payload?.kind),
3823
+ kind: I(t.payload?.kind),
3824
3824
  target: t.payload?.target,
3825
3825
  ttlMs: typeof t.payload?.ttl_ms == "number" ? Number(t.payload.ttl_ms) : void 0
3826
3826
  }]
@@ -3840,7 +3840,7 @@ function ia(e) {
3840
3840
  o((e) => Xi(e)), c((e) => ({
3841
3841
  ...e,
3842
3842
  streaming: !1,
3843
- error: L(t.payload?.message ?? "stream error")
3843
+ error: I(t.payload?.message ?? "stream error")
3844
3844
  }));
3845
3845
  break;
3846
3846
  }
@@ -3991,7 +3991,7 @@ function oa({ name: e, prop: t, required: n, value: r, onChange: i }) {
3991
3991
  label: a,
3992
3992
  help: o,
3993
3993
  children: /* @__PURE__ */ Q("select", {
3994
- value: L(r),
3994
+ value: I(r),
3995
3995
  onChange: (e) => i(e.target.value),
3996
3996
  className: "w-full rounded-md border border-border bg-card p-2 text-sm",
3997
3997
  children: [/* @__PURE__ */ Z("option", {
@@ -4033,7 +4033,7 @@ function oa({ name: e, prop: t, required: n, value: r, onChange: i }) {
4033
4033
  step: t.type === "integer" ? 1 : "any",
4034
4034
  min: t.minimum,
4035
4035
  max: t.maximum,
4036
- value: r == null ? "" : L(r),
4036
+ value: r == null ? "" : I(r),
4037
4037
  onChange: (e) => {
4038
4038
  i(e.target.value === "" ? void 0 : Number(e.target.value));
4039
4039
  },
@@ -4044,7 +4044,7 @@ function oa({ name: e, prop: t, required: n, value: r, onChange: i }) {
4044
4044
  help: o,
4045
4045
  children: /* @__PURE__ */ Z("textarea", {
4046
4046
  rows: 3,
4047
- value: L(r),
4047
+ value: I(r),
4048
4048
  onChange: (e) => i(e.target.value),
4049
4049
  className: "w-full rounded-md border border-border bg-card p-2 text-sm"
4050
4050
  })
@@ -4053,7 +4053,7 @@ function oa({ name: e, prop: t, required: n, value: r, onChange: i }) {
4053
4053
  help: o,
4054
4054
  children: /* @__PURE__ */ Z("input", {
4055
4055
  type: t.format === "email" ? "email" : t.format === "url" ? "url" : t.format === "date-time" ? "datetime-local" : "text",
4056
- value: L(r),
4056
+ value: I(r),
4057
4057
  onChange: (e) => i(e.target.value),
4058
4058
  className: "w-full rounded-md border border-border bg-card p-2 text-sm"
4059
4059
  })
@@ -4153,7 +4153,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4153
4153
  alignItems: "center",
4154
4154
  justifyContent: "center"
4155
4155
  },
4156
- children: /* @__PURE__ */ Z(N.sparkle, {
4156
+ children: /* @__PURE__ */ Z(M.sparkle, {
4157
4157
  size: 13,
4158
4158
  style: { color: "var(--accent-foreground)" }
4159
4159
  })
@@ -4192,24 +4192,24 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4192
4192
  }),
4193
4193
  i.messages.length > 0 && /* @__PURE__ */ Z(z, {
4194
4194
  size: 24,
4195
- icon: /* @__PURE__ */ Z(N.copy, { size: 12 }),
4195
+ icon: /* @__PURE__ */ Z(M.copy, { size: 12 }),
4196
4196
  onClick: () => void Ca(i.messages),
4197
4197
  title: "Copy entire conversation"
4198
4198
  }),
4199
4199
  i.conversationId && /* @__PURE__ */ Z(z, {
4200
4200
  size: 24,
4201
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
4201
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
4202
4202
  onClick: i.startNew,
4203
4203
  title: "New conversation"
4204
4204
  }),
4205
4205
  /* @__PURE__ */ Z(z, {
4206
4206
  size: 24,
4207
- icon: /* @__PURE__ */ Z(N.settings, { size: 12 }),
4207
+ icon: /* @__PURE__ */ Z(M.settings, { size: 12 }),
4208
4208
  title: "Preferences"
4209
4209
  }),
4210
4210
  /* @__PURE__ */ Z(z, {
4211
4211
  size: 24,
4212
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
4212
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
4213
4213
  onClick: t,
4214
4214
  title: "Close"
4215
4215
  })
@@ -4275,7 +4275,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4275
4275
  children: /* @__PURE__ */ Z(V, {
4276
4276
  size: "xs",
4277
4277
  kind: "primary",
4278
- icon: /* @__PURE__ */ Z(N.refresh, { size: 11 }),
4278
+ icon: /* @__PURE__ */ Z(M.refresh, { size: 11 }),
4279
4279
  onClick: () => void i.retry(),
4280
4280
  children: "Retry"
4281
4281
  })
@@ -4318,7 +4318,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4318
4318
  gap: 4,
4319
4319
  zIndex: 1
4320
4320
  },
4321
- children: [/* @__PURE__ */ Z(N.arrowDown, { size: 11 }), "Jump to latest"]
4321
+ children: [/* @__PURE__ */ Z(M.arrowDown, { size: 11 }), "Jump to latest"]
4322
4322
  }),
4323
4323
  /* @__PURE__ */ Q("div", {
4324
4324
  style: {
@@ -4359,7 +4359,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4359
4359
  }),
4360
4360
  /* @__PURE__ */ Z(z, {
4361
4361
  size: 26,
4362
- icon: /* @__PURE__ */ Z(N.paperclip, { size: 12 }),
4362
+ icon: /* @__PURE__ */ Z(M.paperclip, { size: 12 }),
4363
4363
  title: "Attach context"
4364
4364
  }),
4365
4365
  y ? /* @__PURE__ */ Z("button", {
@@ -4378,7 +4378,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4378
4378
  alignItems: "center",
4379
4379
  justifyContent: "center"
4380
4380
  },
4381
- children: /* @__PURE__ */ Z(N.x, { size: 13 })
4381
+ children: /* @__PURE__ */ Z(M.x, { size: 13 })
4382
4382
  }) : /* @__PURE__ */ Z("button", {
4383
4383
  onClick: () => void h(a),
4384
4384
  disabled: !x,
@@ -4395,7 +4395,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4395
4395
  alignItems: "center",
4396
4396
  justifyContent: "center"
4397
4397
  },
4398
- children: /* @__PURE__ */ Z(N.arrowUp, { size: 13 })
4398
+ children: /* @__PURE__ */ Z(M.arrowUp, { size: 13 })
4399
4399
  })
4400
4400
  ]
4401
4401
  }), /* @__PURE__ */ Q("div", {
@@ -4407,7 +4407,7 @@ function fa({ open: e, onClose: t, context: n, title: r = "" }) {
4407
4407
  fontSize: 10.5,
4408
4408
  color: "var(--text-4)"
4409
4409
  },
4410
- children: [/* @__PURE__ */ Z(N.shield, { size: 10 }), /* @__PURE__ */ Z("span", { children: "Runs within your permissions. All actions audit-logged." })]
4410
+ children: [/* @__PURE__ */ Z(M.shield, { size: 10 }), /* @__PURE__ */ Z("span", { children: "Runs within your permissions. All actions audit-logged." })]
4411
4411
  })]
4412
4412
  })
4413
4413
  ]
@@ -4449,7 +4449,7 @@ function ma({ children: e, dataMessageId: t, dataStreaming: n }) {
4449
4449
  flexShrink: 0,
4450
4450
  marginTop: 2
4451
4451
  },
4452
- children: /* @__PURE__ */ Z(N.sparkle, { size: 11 })
4452
+ children: /* @__PURE__ */ Z(M.sparkle, { size: 11 })
4453
4453
  }), /* @__PURE__ */ Z("div", {
4454
4454
  style: {
4455
4455
  flex: 1,
@@ -4853,7 +4853,7 @@ function Ta({ tool: e, onApprove: t, onReject: n }) {
4853
4853
  marginBottom: 6
4854
4854
  },
4855
4855
  children: [
4856
- /* @__PURE__ */ Z(N.bolt, {
4856
+ /* @__PURE__ */ Z(M.bolt, {
4857
4857
  size: 11,
4858
4858
  style: { color: "var(--accent)" }
4859
4859
  }),
@@ -4990,7 +4990,7 @@ function Ta({ tool: e, onApprove: t, onReject: n }) {
4990
4990
  }), /* @__PURE__ */ Z(V, {
4991
4991
  size: "xs",
4992
4992
  kind: "primary",
4993
- icon: /* @__PURE__ */ Z(N.check, { size: 11 }),
4993
+ icon: /* @__PURE__ */ Z(M.check, { size: 11 }),
4994
4994
  onClick: g,
4995
4995
  disabled: m,
4996
4996
  children: "Approve"
@@ -5021,7 +5021,7 @@ function Ma(e, t) {
5021
5021
  }
5022
5022
  return e.replace(ka, (e, n) => {
5023
5023
  let r = Na(n, t);
5024
- return r === ja ? e : L(r);
5024
+ return r === ja ? e : I(r);
5025
5025
  });
5026
5026
  }
5027
5027
  function Na(e, t) {
@@ -5076,7 +5076,7 @@ function La(e, t) {
5076
5076
  return typeof e == "string" ? Ma(e, t) : e;
5077
5077
  }
5078
5078
  function Ra(e, t) {
5079
- return L(Ma(e, t));
5079
+ return I(Ma(e, t));
5080
5080
  }
5081
5081
  function za(e) {
5082
5082
  let t = e.indexOf(".");
@@ -5240,7 +5240,7 @@ function Ja({ row: e, onChange: t, onRemove: n }) {
5240
5240
  onChange: t
5241
5241
  }),
5242
5242
  /* @__PURE__ */ Z(z, {
5243
- icon: /* @__PURE__ */ Z(N.x, { size: 12 }),
5243
+ icon: /* @__PURE__ */ Z(M.x, { size: 12 }),
5244
5244
  onClick: n,
5245
5245
  title: "Remove target"
5246
5246
  })
@@ -5326,7 +5326,7 @@ function Za({ targets: e, onPick: t }) {
5326
5326
  kind: "ghost",
5327
5327
  onClick: () => i(!0),
5328
5328
  style: { alignSelf: "flex-start" },
5329
- children: [/* @__PURE__ */ Z(N.plus, { size: 12 }), " Add target"]
5329
+ children: [/* @__PURE__ */ Z(M.plus, { size: 12 }), " Add target"]
5330
5330
  });
5331
5331
  }
5332
5332
  function Qa(e, t) {
@@ -5368,7 +5368,7 @@ function to(e) {
5368
5368
  function no(e, t) {
5369
5369
  if (!e.includes("${")) return e;
5370
5370
  let n = Ma(e, { params: t });
5371
- return n == null ? "" : L(n);
5371
+ return n == null ? "" : I(n);
5372
5372
  }
5373
5373
  var ro = /\$\{\s*([^}]+?)\s*\}/g;
5374
5374
  function io(e, t) {
@@ -5528,7 +5528,7 @@ function so({ open: e, onOpenChange: t, action: n, actionName: r, onSubmit: i, i
5528
5528
  justifyContent: "center",
5529
5529
  flexShrink: 0
5530
5530
  },
5531
- children: /* @__PURE__ */ Z(N.bolt, { size: 15 })
5531
+ children: /* @__PURE__ */ Z(M.bolt, { size: 15 })
5532
5532
  }),
5533
5533
  /* @__PURE__ */ Q("div", {
5534
5534
  style: {
@@ -5552,7 +5552,7 @@ function so({ open: e, onOpenChange: t, action: n, actionName: r, onSubmit: i, i
5552
5552
  })]
5553
5553
  }),
5554
5554
  /* @__PURE__ */ Z(z, {
5555
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
5555
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
5556
5556
  onClick: () => t(!1)
5557
5557
  })
5558
5558
  ]
@@ -5595,7 +5595,7 @@ function so({ open: e, onOpenChange: t, action: n, actionName: r, onSubmit: i, i
5595
5595
  onChange: (t) => y(e, t),
5596
5596
  locale: l
5597
5597
  }), /* @__PURE__ */ Q("div", { children: [
5598
- /* @__PURE__ */ Z(ne, {
5598
+ /* @__PURE__ */ Z(L, {
5599
5599
  required: t.required,
5600
5600
  children: n
5601
5601
  }),
@@ -5630,7 +5630,7 @@ function so({ open: e, onOpenChange: t, action: n, actionName: r, onSubmit: i, i
5630
5630
  }),
5631
5631
  /* @__PURE__ */ Z(V, {
5632
5632
  kind: "primary",
5633
- icon: Z(a ? v : N.bolt, { size: 13 }),
5633
+ icon: Z(a ? v : M.bolt, { size: 13 }),
5634
5634
  onClick: b,
5635
5635
  disabled: a,
5636
5636
  children: a ? "Executing…" : "Execute"
@@ -5687,7 +5687,7 @@ function co({ open: e, onClose: t, display: n }) {
5687
5687
  justifyContent: "center",
5688
5688
  flexShrink: 0
5689
5689
  },
5690
- children: /* @__PURE__ */ Z(N.check, { size: 15 })
5690
+ children: /* @__PURE__ */ Z(M.check, { size: 15 })
5691
5691
  }),
5692
5692
  /* @__PURE__ */ Q("div", {
5693
5693
  style: {
@@ -5711,7 +5711,7 @@ function co({ open: e, onClose: t, display: n }) {
5711
5711
  })]
5712
5712
  }),
5713
5713
  /* @__PURE__ */ Z(z, {
5714
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
5714
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
5715
5715
  onClick: t
5716
5716
  })
5717
5717
  ]
@@ -6017,7 +6017,7 @@ function bo({ state: e, onClose: t, onExecute: n }) {
6017
6017
  alignItems: "center",
6018
6018
  justifyContent: "center"
6019
6019
  },
6020
- children: Z(c ? N.trash : N.bolt, { size: 15 })
6020
+ children: Z(c ? M.trash : M.bolt, { size: 15 })
6021
6021
  }),
6022
6022
  /* @__PURE__ */ Q("div", {
6023
6023
  style: { flex: 1 },
@@ -6037,7 +6037,7 @@ function bo({ state: e, onClose: t, onExecute: n }) {
6037
6037
  })]
6038
6038
  }),
6039
6039
  /* @__PURE__ */ Z(z, {
6040
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
6040
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
6041
6041
  onClick: t
6042
6042
  })
6043
6043
  ]
@@ -6059,7 +6059,7 @@ function bo({ state: e, onClose: t, onExecute: n }) {
6059
6059
  /* @__PURE__ */ Z(V, {
6060
6060
  kind: "primary",
6061
6061
  danger: c,
6062
- icon: Z(a ? v : N.bolt, { size: 13 }),
6062
+ icon: Z(a ? v : M.bolt, { size: 13 }),
6063
6063
  onClick: async () => {
6064
6064
  o(!0);
6065
6065
  try {
@@ -6257,9 +6257,9 @@ function Po() {
6257
6257
  var Fo = "default";
6258
6258
  function Io() {
6259
6259
  Or();
6260
- let { isAuthenticated: e, isLoading: t, user: n, activeTenant: r } = p(), i = rr(), a = en(), o = Qt(), { data: s } = oe(), c = R((e) => e.sidebar), l = R((e) => e.tabsPosition), u = R((e) => e.aiSurface), d = R((e) => e.theme), f = R((e) => e.set), m = R((e) => e.hydrateFromParams), { data: h } = gi(), g = Bn((e) => e.tabs), _ = Bn((e) => e.activeTabId), v = Bn((e) => e.closeTabs), y = Bn((e) => e.setScope), b = Bn((e) => e.hydrate), [x, S] = Y(Fo), [C, w] = Y(!1), [T, E] = Y("default"), [D, O] = Y(!1), [k, A] = Y(null), j = u !== "off", ee = u === "panel" || u === "both", M = u === "command" || u === "both", N = s?.branding?.ai_name?.trim() ?? "", P = G((e = "default") => {
6260
+ let { isAuthenticated: e, isLoading: t, user: n, activeTenant: r } = p(), i = rr(), a = en(), o = Qt(), { data: s } = oe(), c = R((e) => e.sidebar), l = R((e) => e.tabsPosition), u = R((e) => e.aiSurface), d = R((e) => e.theme), f = R((e) => e.set), m = R((e) => e.hydrateFromParams), { data: h } = gi(), g = Bn((e) => e.tabs), _ = Bn((e) => e.activeTabId), v = Bn((e) => e.closeTabs), y = Bn((e) => e.setScope), b = Bn((e) => e.hydrate), [x, S] = Y(Fo), [C, w] = Y(!1), [T, E] = Y("default"), [D, O] = Y(!1), [k, A] = Y(null), j = u !== "off", ee = u === "panel" || u === "both", te = u === "command" || u === "both", M = s?.branding?.ai_name?.trim() ?? "", N = G((e = "default") => {
6261
6261
  j && (E(e), w(!0));
6262
- }, [j]), F = G((e) => {
6262
+ }, [j]), P = G((e) => {
6263
6263
  if (e.length === 0) return;
6264
6264
  let t = Bn.getState(), n = !t.activeTabId || e.includes(t.activeTabId), r = v(e);
6265
6265
  if (!n) return;
@@ -6268,22 +6268,22 @@ function Io() {
6268
6268
  pathname: i.pathname,
6269
6269
  search: i.search
6270
6270
  }, { replace: i.replace });
6271
- }, [v, a]), I = G((e, t) => {
6271
+ }, [v, a]), F = G((e, t) => {
6272
6272
  let n = Bn.getState(), r = bi(n.tabs, n.activeTabId, e, t);
6273
6273
  if (r) {
6274
6274
  if (r.dirtyTabs.length > 0) {
6275
6275
  A(r);
6276
6276
  return;
6277
6277
  }
6278
- F(r.ids);
6278
+ P(r.ids);
6279
6279
  }
6280
- }, [F]), L = G(() => {
6280
+ }, [P]), I = G(() => {
6281
6281
  A(null);
6282
- }, []), te = G(() => {
6283
- k && (A(null), F(k.cleanIds));
6284
- }, [k, F]), ne = G(() => {
6285
- k && (A(null), F(k.ids));
6286
- }, [k, F]);
6282
+ }, []), ne = G(() => {
6283
+ k && (A(null), P(k.cleanIds));
6284
+ }, [k, P]), L = G(() => {
6285
+ k && (A(null), P(k.ids));
6286
+ }, [k, P]);
6287
6287
  Po(), K(() => {
6288
6288
  i.enabled || !t && !e && a(pt(`${o.pathname}${o.search}${o.hash}`), { replace: !0 });
6289
6289
  }, [
@@ -6325,12 +6325,12 @@ function Io() {
6325
6325
  ]), K(() => {
6326
6326
  let e = (e) => {
6327
6327
  let t = document.activeElement, n = !!t && (t.tagName === "INPUT" || t.tagName === "TEXTAREA" || t.isContentEditable), r = e.metaKey || e.ctrlKey;
6328
- r && e.key.toLowerCase() === "k" ? (e.preventDefault(), P("default")) : r && e.key.toLowerCase() === "t" ? (e.preventDefault(), P("new")) : r && e.key.toLowerCase() === "b" ? (e.preventDefault(), f("sidebar", c === "collapsed" ? "wide" : "collapsed")) : r && e.key.toLowerCase() === "w" ? (e.preventDefault(), I("current")) : r && e.key === "/" ? (e.preventDefault(), ee && O((e) => !e)) : e.key === "/" && !n ? (e.preventDefault(), P("default")) : e.key === "Escape" && w(!1);
6328
+ r && e.key.toLowerCase() === "k" ? (e.preventDefault(), N("default")) : r && e.key.toLowerCase() === "t" ? (e.preventDefault(), N("new")) : r && e.key.toLowerCase() === "b" ? (e.preventDefault(), f("sidebar", c === "collapsed" ? "wide" : "collapsed")) : r && e.key.toLowerCase() === "w" ? (e.preventDefault(), F("current")) : r && e.key === "/" ? (e.preventDefault(), ee && O((e) => !e)) : e.key === "/" && !n ? (e.preventDefault(), N("default")) : e.key === "Escape" && w(!1);
6329
6329
  };
6330
6330
  return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
6331
6331
  }, [
6332
- P,
6333
- I,
6332
+ N,
6333
+ F,
6334
6334
  f,
6335
6335
  c,
6336
6336
  ee
@@ -6377,7 +6377,7 @@ function Io() {
6377
6377
  f("theme", d === "dark" ? "light" : "dark");
6378
6378
  break;
6379
6379
  case "tab-close":
6380
- e.tabCloseScope && I(e.tabCloseScope);
6380
+ e.tabCloseScope && F(e.tabCloseScope);
6381
6381
  break;
6382
6382
  }
6383
6383
  };
@@ -6401,7 +6401,7 @@ function Io() {
6401
6401
  /* @__PURE__ */ Z(ci, {
6402
6402
  breadcrumbs: re,
6403
6403
  onCrumbClick: (e) => e.onClick && e.onClick(),
6404
- onCmdK: () => P("default"),
6404
+ onCmdK: () => N("default"),
6405
6405
  onToggleAI: () => ee && O((e) => !e),
6406
6406
  aiOpen: D,
6407
6407
  onOpenProfile: () => a("/profile"),
@@ -6412,7 +6412,7 @@ function Io() {
6412
6412
  onPick: ie,
6413
6413
  onToggleAI: () => ee && O((e) => !e),
6414
6414
  aiOpen: D,
6415
- onCmdK: () => P("default"),
6415
+ onCmdK: () => N("default"),
6416
6416
  areas: s?.areas,
6417
6417
  branding: h?.branding
6418
6418
  }),
@@ -6427,8 +6427,8 @@ function Io() {
6427
6427
  },
6428
6428
  children: [
6429
6429
  l === "top" && /* @__PURE__ */ Z(li, {
6430
- onNew: () => P("new"),
6431
- onCloseRequest: I
6430
+ onNew: () => N("new"),
6431
+ onCloseRequest: F
6432
6432
  }),
6433
6433
  /* @__PURE__ */ Z("div", {
6434
6434
  style: {
@@ -6441,8 +6441,8 @@ function Io() {
6441
6441
  children: /* @__PURE__ */ Z(Jt, {})
6442
6442
  }),
6443
6443
  l === "bottom" && /* @__PURE__ */ Z(li, {
6444
- onNew: () => P("new"),
6445
- onCloseRequest: I
6444
+ onNew: () => N("new"),
6445
+ onCloseRequest: F
6446
6446
  })
6447
6447
  ]
6448
6448
  }),
@@ -6453,19 +6453,19 @@ function Io() {
6453
6453
  onAction: (e) => ae(e),
6454
6454
  navigation: s?.navigation,
6455
6455
  screens: s?.screens,
6456
- includeAI: M,
6457
- aiName: N
6456
+ includeAI: te,
6457
+ aiName: M
6458
6458
  }),
6459
6459
  ee && D && /* @__PURE__ */ Z(fa, {
6460
6460
  open: D,
6461
6461
  onClose: () => O(!1),
6462
- title: N
6462
+ title: M
6463
6463
  }),
6464
6464
  /* @__PURE__ */ Z(di, {
6465
6465
  pending: k,
6466
- onCancel: L,
6467
- onCloseClean: te,
6468
- onDiscardAll: ne
6466
+ onCancel: I,
6467
+ onCloseClean: ne,
6468
+ onDiscardAll: L
6469
6469
  })
6470
6470
  ]
6471
6471
  }) });
@@ -6650,7 +6650,7 @@ function Uo({ children: e, tenantSlug: t, tagline: n, subTagline: r, version: i,
6650
6650
  }),
6651
6651
  /* @__PURE__ */ Z("div", { style: { flex: 1 } }),
6652
6652
  /* @__PURE__ */ Z(z, {
6653
- icon: Z(s === "dark" ? N.sun : N.moon, { size: 14 }),
6653
+ icon: Z(s === "dark" ? M.sun : M.moon, { size: 14 }),
6654
6654
  onClick: u,
6655
6655
  title: "Toggle theme"
6656
6656
  })
@@ -6798,7 +6798,7 @@ function Uo({ children: e, tenantSlug: t, tagline: n, subTagline: r, version: i,
6798
6798
  color: "var(--auth-panel-fg-dim)"
6799
6799
  },
6800
6800
  children: _.map(([e, t]) => {
6801
- let n = N[t];
6801
+ let n = M[t];
6802
6802
  return /* @__PURE__ */ Q("div", {
6803
6803
  style: {
6804
6804
  display: "flex",
@@ -7014,7 +7014,7 @@ function ss() {
7014
7014
  queryFn: Ve
7015
7015
  }), { data: v } = un({
7016
7016
  queryKey: ["sso-providers"],
7017
- queryFn: () => M(),
7017
+ queryFn: () => te(),
7018
7018
  staleTime: 6e4
7019
7019
  });
7020
7020
  K(() => {
@@ -7081,7 +7081,7 @@ function ss() {
7081
7081
  children: v.map((e) => {
7082
7082
  let t = os[e.slug.toLowerCase()] ?? {
7083
7083
  label: `Continue with ${e.name}`,
7084
- icon: /* @__PURE__ */ Z(N.shield, { size: 13 })
7084
+ icon: /* @__PURE__ */ Z(M.shield, { size: 13 })
7085
7085
  };
7086
7086
  return /* @__PURE__ */ Z(V, {
7087
7087
  size: "md",
@@ -7132,10 +7132,10 @@ function ss() {
7132
7132
  gap: 12
7133
7133
  },
7134
7134
  children: [
7135
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Email" }), /* @__PURE__ */ Z(O, {
7135
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Email" }), /* @__PURE__ */ Z(O, {
7136
7136
  value: s,
7137
7137
  onChange: l,
7138
- prefix: /* @__PURE__ */ Z(N.email, { size: 13 }),
7138
+ prefix: /* @__PURE__ */ Z(M.email, { size: 13 }),
7139
7139
  placeholder: "you@company.com",
7140
7140
  autoFocus: !0,
7141
7141
  required: !0
@@ -7146,7 +7146,7 @@ function ss() {
7146
7146
  alignItems: "center"
7147
7147
  },
7148
7148
  children: [
7149
- /* @__PURE__ */ Z(ne, { children: "Password" }),
7149
+ /* @__PURE__ */ Z(L, { children: "Password" }),
7150
7150
  /* @__PURE__ */ Z("div", { style: { flex: 1 } }),
7151
7151
  /* @__PURE__ */ Z(Kt, {
7152
7152
  to: "/forgot",
@@ -7282,27 +7282,27 @@ function us() {
7282
7282
  gridTemplateColumns: "1fr 1fr",
7283
7283
  gap: 10
7284
7284
  },
7285
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "First name" }), /* @__PURE__ */ Z(O, {
7285
+ children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "First name" }), /* @__PURE__ */ Z(O, {
7286
7286
  value: i,
7287
7287
  onChange: a
7288
- })] }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Last name" }), /* @__PURE__ */ Z(O, {
7288
+ })] }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Last name" }), /* @__PURE__ */ Z(O, {
7289
7289
  value: o,
7290
7290
  onChange: s
7291
7291
  })] })]
7292
7292
  }),
7293
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Work email" }), /* @__PURE__ */ Z(O, {
7293
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Work email" }), /* @__PURE__ */ Z(O, {
7294
7294
  value: l,
7295
7295
  onChange: u,
7296
- prefix: /* @__PURE__ */ Z(N.email, { size: 13 }),
7296
+ prefix: /* @__PURE__ */ Z(M.email, { size: 13 }),
7297
7297
  placeholder: "name@company.com",
7298
7298
  required: !0
7299
7299
  })] }),
7300
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Company" }), /* @__PURE__ */ Z(O, {
7300
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Company" }), /* @__PURE__ */ Z(O, {
7301
7301
  value: d,
7302
7302
  onChange: f,
7303
- prefix: /* @__PURE__ */ Z(N.building, { size: 13 })
7303
+ prefix: /* @__PURE__ */ Z(M.building, { size: 13 })
7304
7304
  })] }),
7305
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Workspace URL" }), /* @__PURE__ */ Q("div", {
7305
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Workspace URL" }), /* @__PURE__ */ Q("div", {
7306
7306
  style: {
7307
7307
  display: "flex",
7308
7308
  alignItems: "stretch",
@@ -7331,7 +7331,7 @@ function us() {
7331
7331
  children: [".", x]
7332
7332
  })]
7333
7333
  })] }),
7334
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Password" }), /* @__PURE__ */ Z(c, {
7334
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Password" }), /* @__PURE__ */ Z(c, {
7335
7335
  value: h,
7336
7336
  onChange: g,
7337
7337
  placeholder: "At least 12 characters",
@@ -7465,7 +7465,7 @@ function fs() {
7465
7465
  gap: 8,
7466
7466
  alignItems: "flex-start"
7467
7467
  },
7468
- children: [/* @__PURE__ */ Z(N.check, { size: 14 }), /* @__PURE__ */ Z("div", { children: "If that email is in our system, we've sent a reset link. Check your inbox — it expires in 30 minutes." })]
7468
+ children: [/* @__PURE__ */ Z(M.check, { size: 14 }), /* @__PURE__ */ Z("div", { children: "If that email is in our system, we've sent a reset link. Check your inbox — it expires in 30 minutes." })]
7469
7469
  }) : /* @__PURE__ */ Q("div", {
7470
7470
  style: {
7471
7471
  display: "flex",
@@ -7473,10 +7473,10 @@ function fs() {
7473
7473
  gap: 12
7474
7474
  },
7475
7475
  children: [
7476
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Email" }), /* @__PURE__ */ Z(O, {
7476
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Email" }), /* @__PURE__ */ Z(O, {
7477
7477
  value: e,
7478
7478
  onChange: t,
7479
- prefix: /* @__PURE__ */ Z(N.email, { size: 13 }),
7479
+ prefix: /* @__PURE__ */ Z(M.email, { size: 13 }),
7480
7480
  placeholder: "you@company.com",
7481
7481
  autoFocus: !0,
7482
7482
  required: !0,
@@ -7613,23 +7613,23 @@ function ys() {
7613
7613
  gap: 12
7614
7614
  },
7615
7615
  children: [
7616
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Email" }), /* @__PURE__ */ Z(O, {
7616
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Email" }), /* @__PURE__ */ Z(O, {
7617
7617
  value: n,
7618
7618
  onChange: r,
7619
- prefix: /* @__PURE__ */ Z(N.email, { size: 13 }),
7619
+ prefix: /* @__PURE__ */ Z(M.email, { size: 13 }),
7620
7620
  placeholder: "you@company.com",
7621
7621
  autoFocus: !0,
7622
7622
  required: !0,
7623
7623
  type: "email",
7624
7624
  "aria-label": "Email"
7625
7625
  })] }),
7626
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "New password" }), /* @__PURE__ */ Z(c, {
7626
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "New password" }), /* @__PURE__ */ Z(c, {
7627
7627
  value: i,
7628
7628
  onChange: a,
7629
7629
  placeholder: "At least 8 characters",
7630
7630
  showStrength: !0
7631
7631
  })] }),
7632
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, { children: "Confirm new password" }), /* @__PURE__ */ Z(c, {
7632
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, { children: "Confirm new password" }), /* @__PURE__ */ Z(c, {
7633
7633
  value: o,
7634
7634
  onChange: s,
7635
7635
  placeholder: "Re-enter new password"
@@ -7922,7 +7922,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
7922
7922
  alignItems: "center",
7923
7923
  justifyContent: "center"
7924
7924
  },
7925
- children: /* @__PURE__ */ Z(N.key, { size: 15 })
7925
+ children: /* @__PURE__ */ Z(M.key, { size: 15 })
7926
7926
  }),
7927
7927
  /* @__PURE__ */ Q("div", {
7928
7928
  style: { flex: 1 },
@@ -7942,7 +7942,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
7942
7942
  })]
7943
7943
  }),
7944
7944
  /* @__PURE__ */ Z(z, {
7945
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
7945
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
7946
7946
  onClick: h
7947
7947
  })
7948
7948
  ]
@@ -7955,7 +7955,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
7955
7955
  gap: 12
7956
7956
  },
7957
7957
  children: [
7958
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, {
7958
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, {
7959
7959
  required: !0,
7960
7960
  children: "Current password"
7961
7961
  }), /* @__PURE__ */ Z(c, {
@@ -7963,7 +7963,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
7963
7963
  onChange: i,
7964
7964
  placeholder: "Enter your current password"
7965
7965
  })] }),
7966
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, {
7966
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, {
7967
7967
  required: !0,
7968
7968
  children: "New password"
7969
7969
  }), /* @__PURE__ */ Z(c, {
@@ -7972,7 +7972,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
7972
7972
  placeholder: "At least 8 characters",
7973
7973
  showStrength: !0
7974
7974
  })] }),
7975
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, {
7975
+ /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, {
7976
7976
  required: !0,
7977
7977
  children: "Confirm new password"
7978
7978
  }), /* @__PURE__ */ Z(c, {
@@ -7990,7 +7990,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
7990
7990
  display: "flex",
7991
7991
  gap: 6
7992
7992
  },
7993
- children: [/* @__PURE__ */ Z(N.info, { size: 13 }), /* @__PURE__ */ Z("span", { children: f })]
7993
+ children: [/* @__PURE__ */ Z(M.info, { size: 13 }), /* @__PURE__ */ Z("span", { children: f })]
7994
7994
  })
7995
7995
  ]
7996
7996
  }),
@@ -8019,7 +8019,7 @@ function Cs({ open: e, onClose: t, onSubmit: n }) {
8019
8019
  }),
8020
8020
  /* @__PURE__ */ Z(V, {
8021
8021
  kind: "primary",
8022
- icon: Z(u ? v : N.key, { size: 13 }),
8022
+ icon: Z(u ? v : M.key, { size: 13 }),
8023
8023
  onClick: async () => {
8024
8024
  if (!g) {
8025
8025
  a.length < 8 ? p("New password must be at least 8 characters.") : p(s === a ? "Fill in all fields." : "Passwords do not match.");
@@ -8123,7 +8123,7 @@ function Ts({ open: e, onOpenChange: t, actionName: n, message: r, onConfirm: i,
8123
8123
  justifyContent: "center",
8124
8124
  flexShrink: 0
8125
8125
  },
8126
- children: /* @__PURE__ */ Z(N.bolt, { size: 15 })
8126
+ children: /* @__PURE__ */ Z(M.bolt, { size: 15 })
8127
8127
  }),
8128
8128
  /* @__PURE__ */ Q("div", {
8129
8129
  style: {
@@ -8147,7 +8147,7 @@ function Ts({ open: e, onOpenChange: t, actionName: n, message: r, onConfirm: i,
8147
8147
  })]
8148
8148
  }),
8149
8149
  /* @__PURE__ */ Z(z, {
8150
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
8150
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
8151
8151
  onClick: () => !a && t(!1)
8152
8152
  })
8153
8153
  ]
@@ -8169,7 +8169,7 @@ function Ts({ open: e, onOpenChange: t, actionName: n, message: r, onConfirm: i,
8169
8169
  }),
8170
8170
  /* @__PURE__ */ Z(V, {
8171
8171
  kind: "primary",
8172
- icon: Z(a ? v : N.bolt, { size: 13 }),
8172
+ icon: Z(a ? v : M.bolt, { size: 13 }),
8173
8173
  onClick: i,
8174
8174
  disabled: a,
8175
8175
  children: a ? "Executing…" : "Confirm"
@@ -8267,10 +8267,10 @@ function Ns(e, t) {
8267
8267
  function Ps(e, t) {
8268
8268
  let n = t[e.field], r = e.op || "eq";
8269
8269
  if (r === "in" || r === "not_in") {
8270
- let t = Array.isArray(e.value) ? e.value : [e.value], i = L(n), a = t.some((e) => L(e) === i);
8270
+ let t = Array.isArray(e.value) ? e.value : [e.value], i = I(n), a = t.some((e) => I(e) === i);
8271
8271
  return r === "in" ? a : !a;
8272
8272
  }
8273
- return typeof e.value == "boolean" && r === "eq" ? Fs(n) === e.value : typeof n == "number" && typeof e.value == "number" ? Is(n, e.value, r) : Is(L(n), L(e.value), r);
8273
+ return typeof e.value == "boolean" && r === "eq" ? Fs(n) === e.value : typeof n == "number" && typeof e.value == "number" ? Is(n, e.value, r) : Is(I(n), I(e.value), r);
8274
8274
  }
8275
8275
  function Fs(e) {
8276
8276
  return e == null ? !1 : typeof e == "boolean" ? e : typeof e == "string" ? e !== "" : typeof e == "number" ? e !== 0 : !0;
@@ -8447,7 +8447,7 @@ function ec({ actionCode: e, action: n, entityCode: r, objectIds: i = [], row: a
8447
8447
  if (!(!n.association || i.length === 0)) {
8448
8448
  _(!0);
8449
8449
  try {
8450
- let e = await P(r ? `${r}.${n.association}` : n.association, i), t = Vs(x, e.target_entity);
8450
+ let e = await N(r ? `${r}.${n.association}` : n.association, i), t = Vs(x, e.target_entity);
8451
8451
  if (!t) {
8452
8452
  $.error(`No list screen found for ${e.target_entity}`);
8453
8453
  return;
@@ -8539,7 +8539,7 @@ function ec({ actionCode: e, action: n, entityCode: r, objectIds: i = [], row: a
8539
8539
  l,
8540
8540
  u,
8541
8541
  c
8542
- ]), M = G(() => {
8542
+ ]), te = G(() => {
8543
8543
  l?.(i.length), b.mutate({
8544
8544
  actionCode: O,
8545
8545
  body: t(A, k)
@@ -8556,7 +8556,7 @@ function ec({ actionCode: e, action: n, entityCode: r, objectIds: i = [], row: a
8556
8556
  j,
8557
8557
  l,
8558
8558
  u
8559
- ]), F = G((e) => {
8559
+ ]), P = G((e) => {
8560
8560
  l?.(i.length), b.mutate({
8561
8561
  actionCode: O,
8562
8562
  body: t(e, k)
@@ -8572,41 +8572,41 @@ function ec({ actionCode: e, action: n, entityCode: r, objectIds: i = [], row: a
8572
8572
  j,
8573
8573
  l,
8574
8574
  u
8575
- ]), I = W(n.display?.name), L = n.display?.icon, te = L && N[L], ne = te ? /* @__PURE__ */ Z(te, { size: 13 }) : L ? /* @__PURE__ */ Z(ie, {
8576
- name: L,
8575
+ ]), F = W(n.display?.name), I = n.display?.icon, ne = I && M[I], L = ne ? /* @__PURE__ */ Z(ne, { size: 13 }) : I ? /* @__PURE__ */ Z(ie, {
8576
+ name: I,
8577
8577
  size: 13
8578
8578
  }) : null, R = !E || b.isPending || g;
8579
8579
  return /* @__PURE__ */ Q(X, { children: [
8580
8580
  s === "icon" ? /* @__PURE__ */ Z(z, {
8581
- icon: ne ?? /* @__PURE__ */ Z(N.bolt, { size: 13 }),
8581
+ icon: L ?? /* @__PURE__ */ Z(M.bolt, { size: 13 }),
8582
8582
  onClick: ee,
8583
- title: I
8583
+ title: F
8584
8584
  }) : /* @__PURE__ */ Z(V, {
8585
8585
  kind: o === "default" ? "primary" : o === "ghost" ? "ghost" : "default",
8586
8586
  size: "sm",
8587
- icon: ne,
8587
+ icon: L,
8588
8588
  danger: n.destructive,
8589
8589
  onClick: ee,
8590
8590
  disabled: R,
8591
- title: I,
8592
- "aria-label": I,
8593
- children: I
8591
+ title: F,
8592
+ "aria-label": F,
8593
+ children: F
8594
8594
  }),
8595
8595
  w && /* @__PURE__ */ Z(so, {
8596
8596
  open: f,
8597
8597
  onOpenChange: p,
8598
8598
  action: n,
8599
- actionName: I,
8600
- onSubmit: F,
8599
+ actionName: F,
8600
+ onSubmit: P,
8601
8601
  isPending: b.isPending,
8602
8602
  row: a
8603
8603
  }),
8604
8604
  T && /* @__PURE__ */ Z(Ts, {
8605
8605
  open: m,
8606
8606
  onOpenChange: h,
8607
- actionName: I,
8607
+ actionName: F,
8608
8608
  message: W(n.confirmation),
8609
- onConfirm: M,
8609
+ onConfirm: te,
8610
8610
  isPending: b.isPending
8611
8611
  }),
8612
8612
  v && /* @__PURE__ */ Z(co, {
@@ -8637,7 +8637,7 @@ function tc({ actions: e, objectIds: n, row: r, onSuccess: i, preMenu: a, divide
8637
8637
  children: [/* @__PURE__ */ Z(z, {
8638
8638
  ref: l,
8639
8639
  size: s,
8640
- icon: /* @__PURE__ */ Z(N.more, { size: Math.round(s * .55) }),
8640
+ icon: /* @__PURE__ */ Z(M.more, { size: Math.round(s * .55) }),
8641
8641
  onClick: () => d((e) => !e),
8642
8642
  title: "Actions"
8643
8643
  }), /* @__PURE__ */ Q(m, {
@@ -8648,10 +8648,10 @@ function tc({ actions: e, objectIds: n, row: r, onSuccess: i, preMenu: a, divide
8648
8648
  align: c,
8649
8649
  children: [
8650
8650
  a,
8651
- a && o && e.length > 0 && /* @__PURE__ */ Z(F, { divider: !0 }),
8651
+ a && o && e.length > 0 && /* @__PURE__ */ Z(P, { divider: !0 }),
8652
8652
  e.map(({ code: e, action: a }) => {
8653
- let o = r ? Ns(a.conditions, r) : !0, s = W(a.display?.name) || e, c = a.display?.icon, l = c && N[c] ? N[c] : void 0;
8654
- return /* @__PURE__ */ Z(F, {
8653
+ let o = r ? Ns(a.conditions, r) : !0, s = W(a.display?.name) || e, c = a.display?.icon, l = c && M[c] ? M[c] : void 0;
8654
+ return /* @__PURE__ */ Z(P, {
8655
8655
  icon: l ? /* @__PURE__ */ Z(l, { size: 12 }) : null,
8656
8656
  danger: a.destructive,
8657
8657
  onClick: p(() => {
@@ -8693,7 +8693,7 @@ function nc({ entity: e, searchable: t, filterFields: r, searchValue: i, onSearc
8693
8693
  value: i,
8694
8694
  onChange: a,
8695
8695
  placeholder: "Search…",
8696
- prefix: /* @__PURE__ */ Z(N.search, { size: 12 })
8696
+ prefix: /* @__PURE__ */ Z(M.search, { size: 12 })
8697
8697
  })
8698
8698
  }), u && r.map((t) => {
8699
8699
  let r = e.fields.get(t);
@@ -8723,16 +8723,16 @@ function nc({ entity: e, searchable: t, filterFields: r, searchValue: i, onSearc
8723
8723
  });
8724
8724
  }
8725
8725
  function rc({ field: e, label: t, value: r, onChange: i }) {
8726
- let a = I(e.ref?.entity), o = e.display?.ref_display_field ?? a?.display?.display_field, s = q(() => a ? [...a.fields].find(([, e]) => e.primary)?.[0] ?? "id" : "id", [a]), { data: c } = $e(e.ref?.entity, {
8726
+ let a = F(e.ref?.entity), o = e.display?.ref_display_field ?? a?.display?.display_field, s = q(() => a ? [...a.fields].find(([, e]) => e.primary)?.[0] ?? "id" : "id", [a]), { data: c } = $e(e.ref?.entity, {
8727
8727
  per_page: 200,
8728
8728
  sort: o ? `${o}:asc` : void 0
8729
8729
  }), l = c?.data ?? [], u = (e) => {
8730
8730
  if (e == null) return "—";
8731
8731
  if (typeof e == "object" && !Array.isArray(e)) {
8732
8732
  let t = Object.values(e)[0];
8733
- return t == null ? "—" : L(t);
8733
+ return t == null ? "—" : I(t);
8734
8734
  }
8735
- return L(e);
8735
+ return I(e);
8736
8736
  };
8737
8737
  return /* @__PURE__ */ Z("div", {
8738
8738
  style: { width: 160 },
@@ -8767,7 +8767,7 @@ function oc(e, t) {
8767
8767
  return fe(t, Ne(t, e));
8768
8768
  } catch {}
8769
8769
  let n = e.id;
8770
- return typeof n == "string" ? n : n == null ? "" : L(n);
8770
+ return typeof n == "string" ? n : n == null ? "" : I(n);
8771
8771
  }
8772
8772
  function sc(e, t, n, r, i) {
8773
8773
  let a = ac(t), o = oc(n, r?.entity), s = r?.entityCode ?? "";
@@ -8900,7 +8900,7 @@ function gc({ group: e, entityActions: t, globalActions: n, onRun: r, loading: i
8900
8900
  name: e.icon,
8901
8901
  size: 12
8902
8902
  }) : void 0 : /* @__PURE__ */ Z(v, { size: 12 }),
8903
- iconRight: /* @__PURE__ */ Z(N.down, { size: 10 }),
8903
+ iconRight: /* @__PURE__ */ Z(M.down, { size: 10 }),
8904
8904
  "aria-haspopup": "menu",
8905
8905
  "aria-expanded": l ? "true" : "false",
8906
8906
  title: d,
@@ -9039,7 +9039,7 @@ function yc({ layout: e, entityActions: t, globalActions: n, onRun: r, trailingN
9039
9039
  },
9040
9040
  children: [/* @__PURE__ */ Z(z, {
9041
9041
  ref: l,
9042
- icon: Z(f == null ? N.more : v, { size: 14 }),
9042
+ icon: Z(f == null ? M.more : v, { size: 14 }),
9043
9043
  title: "Actions",
9044
9044
  size: 28,
9045
9045
  onClick: () => d((e) => !e)
@@ -9075,7 +9075,7 @@ function yc({ layout: e, entityActions: t, globalActions: n, onRun: r, trailingN
9075
9075
  onActionClick: c
9076
9076
  }, e.icon ?? "group")),
9077
9077
  g && i,
9078
- x && /* @__PURE__ */ Z(F, { divider: !0 }),
9078
+ x && /* @__PURE__ */ Z(P, { divider: !0 }),
9079
9079
  b.map((e) => /* @__PURE__ */ Z(_c, {
9080
9080
  leaf: e,
9081
9081
  entityActions: t,
@@ -9234,7 +9234,7 @@ function wc({ layout: e, entityActions: t, globalActions: n, onRun: r, reservedR
9234
9234
  let t = e.name ? W(e.name) : "Actions";
9235
9235
  return /* @__PURE__ */ Z(V, {
9236
9236
  "data-node-key": r,
9237
- iconRight: /* @__PURE__ */ Z(N.down, { size: 10 }),
9237
+ iconRight: /* @__PURE__ */ Z(M.down, { size: 10 }),
9238
9238
  tabIndex: -1,
9239
9239
  children: t
9240
9240
  }, r);
@@ -9276,7 +9276,7 @@ function wc({ layout: e, entityActions: t, globalActions: n, onRun: r, reservedR
9276
9276
  j && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(V, {
9277
9277
  ref: C,
9278
9278
  kind: "default",
9279
- iconRight: /* @__PURE__ */ Z(N.down, { size: 10 }),
9279
+ iconRight: /* @__PURE__ */ Z(M.down, { size: 10 }),
9280
9280
  "aria-haspopup": "menu",
9281
9281
  "aria-expanded": w ? "true" : "false",
9282
9282
  onClick: () => T((e) => !e),
@@ -9568,7 +9568,7 @@ function Fc({ node: e, ctx: n, assocCode: r, assocEntity: i, fkField: a }) {
9568
9568
  }, e)), l && /* @__PURE__ */ Z(V, {
9569
9569
  kind: "ghost",
9570
9570
  size: "xs",
9571
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
9571
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
9572
9572
  onClick: () => w((e) => e + 1),
9573
9573
  children: "Add row"
9574
9574
  })]
@@ -9756,7 +9756,7 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9756
9756
  for (let t of Object.values(e)) clearTimeout(t);
9757
9757
  };
9758
9758
  }, []);
9759
- let [M, N] = Y(null), [P, F] = Y([]), [I, L] = Y(!1), [te, ne] = Y(null), [R, re] = Y(/* @__PURE__ */ new Set()), ie = G(async (t, n, i) => {
9759
+ let [te, M] = Y(null), [N, P] = Y([]), [F, I] = Y(!1), [ne, L] = Y(null), [R, re] = Y(/* @__PURE__ */ new Set()), ie = G(async (t, n, i) => {
9760
9760
  A((e) => ({
9761
9761
  ...e,
9762
9762
  [t]: {
@@ -9823,7 +9823,7 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9823
9823
  let r = t.fields.get(n);
9824
9824
  r && (r.default === void 0 ? r.type === "bool" && (e[n] = !1) : e[n] = r.default);
9825
9825
  }
9826
- N(e), F([]);
9826
+ M(e), P([]);
9827
9827
  }, [
9828
9828
  i,
9829
9829
  n,
@@ -9831,29 +9831,29 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9831
9831
  t.fields
9832
9832
  ]), se = J(m);
9833
9833
  K(() => {
9834
- m !== void 0 && m !== se.current && (se.current = m, !M && oe());
9834
+ m !== void 0 && m !== se.current && (se.current = m, !te && oe());
9835
9835
  }, [
9836
9836
  m,
9837
- M,
9837
+ te,
9838
9838
  oe
9839
9839
  ]);
9840
9840
  let ce = G(async () => {
9841
- if (!M) return;
9842
- let n = Nc(M, a, t, i);
9841
+ if (!te) return;
9842
+ let n = Nc(te, a, t, i);
9843
9843
  if (n.length > 0) {
9844
- F(n);
9844
+ P(n);
9845
9845
  return;
9846
9846
  }
9847
- L(!0);
9847
+ I(!0);
9848
9848
  try {
9849
- await Oe(e, M), N(null), F([]), p();
9849
+ await Oe(e, te), M(null), P([]), p();
9850
9850
  } catch (e) {
9851
- F([`_error:${e instanceof Error ? e.message : "Create failed"}`]);
9851
+ P([`_error:${e instanceof Error ? e.message : "Create failed"}`]);
9852
9852
  } finally {
9853
- L(!1);
9853
+ I(!1);
9854
9854
  }
9855
9855
  }, [
9856
- M,
9856
+ te,
9857
9857
  a,
9858
9858
  t,
9859
9859
  i,
@@ -9889,7 +9889,7 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9889
9889
  return r;
9890
9890
  }), O([]), w(null);
9891
9891
  }, []), ue = G(async (t) => {
9892
- ne(null), re((e) => new Set(e).add(t));
9892
+ L(null), re((e) => new Set(e).add(t));
9893
9893
  try {
9894
9894
  await T(e, y.get(t) ?? t), p();
9895
9895
  } catch {} finally {
@@ -9928,7 +9928,7 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9928
9928
  borderRadius: 6
9929
9929
  } })]
9930
9930
  });
9931
- let V = l.length === 0 && !M;
9931
+ let V = l.length === 0 && !te;
9932
9932
  return /* @__PURE__ */ Q("div", { children: [
9933
9933
  V && !o && /* @__PURE__ */ Z("div", {
9934
9934
  style: {
@@ -9978,7 +9978,7 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9978
9978
  rowState: l,
9979
9979
  onCellChange: ae,
9980
9980
  onDeleteClick: (e) => {
9981
- ne({
9981
+ L({
9982
9982
  show: !0,
9983
9983
  rowId: e,
9984
9984
  label: ye(n, t) ?? ""
@@ -9994,33 +9994,33 @@ function Rc({ entityCode: e, entity: t, parentId: n, foreignKey: i, columns: a,
9994
9994
  entityCode: e,
9995
9995
  onRowActionSuccess: p
9996
9996
  }, r);
9997
- }), M && /* @__PURE__ */ Z(Vc, {
9998
- draftRow: M,
9997
+ }), te && /* @__PURE__ */ Z(Vc, {
9998
+ draftRow: te,
9999
9999
  entity: t,
10000
10000
  columns: a,
10001
10001
  editableColumns: v,
10002
10002
  foreignKey: i,
10003
- draftErrors: P,
10004
- draftSaving: I,
10005
- onChange: (e, t) => N((n) => n && {
10003
+ draftErrors: N,
10004
+ draftSaving: F,
10005
+ onChange: (e, t) => M((n) => n && {
10006
10006
  ...n,
10007
10007
  [e]: t
10008
10008
  }),
10009
10009
  onConfirm: ce,
10010
10010
  onCancel: () => {
10011
- N(null), F([]);
10011
+ M(null), P([]);
10012
10012
  },
10013
10013
  refs: u
10014
10014
  })] })]
10015
10015
  })
10016
10016
  }),
10017
- te && /* @__PURE__ */ Z(Ar, {
10018
- open: te.show,
10019
- onOpenChange: (e) => !e && ne(null),
10017
+ ne && /* @__PURE__ */ Z(Ar, {
10018
+ open: ne.show,
10019
+ onOpenChange: (e) => !e && L(null),
10020
10020
  title: "Delete record",
10021
- description: te.label ? `Are you sure you want to delete "${te.label}"?` : "Are you sure you want to delete this record?",
10021
+ description: ne.label ? `Are you sure you want to delete "${ne.label}"?` : "Are you sure you want to delete this record?",
10022
10022
  confirmLabel: "Delete",
10023
- onConfirm: () => ue(te.rowId),
10023
+ onConfirm: () => ue(ne.rowId),
10024
10024
  destructive: !0
10025
10025
  })
10026
10026
  ] });
@@ -10064,7 +10064,7 @@ function zc({ rowId: e, row: t, entity: n, entities: r, screens: i, columns: a,
10064
10064
  refs: x,
10065
10065
  compact: !0,
10066
10066
  locale: E
10067
- }) : L(D[t])
10067
+ }) : I(D[t])
10068
10068
  }, t);
10069
10069
  let c = C && t === S, l = a ? H({
10070
10070
  field: a,
@@ -10077,7 +10077,7 @@ function zc({ rowId: e, row: t, entity: n, entities: r, screens: i, columns: a,
10077
10077
  entities: r,
10078
10078
  screens: c ? void 0 : i,
10079
10079
  locale: E
10080
- }) : L(D[t]), u = A && s && !d;
10080
+ }) : I(D[t]), u = A && s && !d;
10081
10081
  return /* @__PURE__ */ Z("td", {
10082
10082
  style: {
10083
10083
  ...O,
@@ -10124,13 +10124,13 @@ function zc({ rowId: e, row: t, entity: n, entities: r, screens: i, columns: a,
10124
10124
  }),
10125
10125
  c === "row_edit" && /* @__PURE__ */ Z(z, {
10126
10126
  size: 24,
10127
- icon: /* @__PURE__ */ Z(N.edit, { size: 12 }),
10127
+ icon: /* @__PURE__ */ Z(M.edit, { size: 12 }),
10128
10128
  onClick: () => _(e),
10129
10129
  title: "Edit row"
10130
10130
  }),
10131
10131
  /* @__PURE__ */ Z(z, {
10132
10132
  size: 24,
10133
- icon: /* @__PURE__ */ Z(N.trash, { size: 12 }),
10133
+ icon: /* @__PURE__ */ Z(M.trash, { size: 12 }),
10134
10134
  onClick: () => g(e),
10135
10135
  title: "Delete row"
10136
10136
  })
@@ -10192,14 +10192,14 @@ function Bc({ values: e, entity: t, columns: n, editableColumns: r, errors: i, s
10192
10192
  refs: l,
10193
10193
  compact: !0,
10194
10194
  locale: d
10195
- }) : L(e[n])
10195
+ }) : I(e[n])
10196
10196
  })
10197
10197
  }, n) : /* @__PURE__ */ Z("td", {
10198
10198
  style: {
10199
10199
  ...m,
10200
10200
  color: "var(--text-3)"
10201
10201
  },
10202
- children: i?.auto ? "—" : L(e[n])
10202
+ children: i?.auto ? "—" : I(e[n])
10203
10203
  }, n);
10204
10204
  }), /* @__PURE__ */ Z("td", {
10205
10205
  style: m,
@@ -10221,13 +10221,13 @@ function Bc({ values: e, entity: t, columns: n, editableColumns: r, errors: i, s
10221
10221
  }),
10222
10222
  /* @__PURE__ */ Z(z, {
10223
10223
  size: 24,
10224
- icon: Z(a ? v : N.check, { size: 12 }),
10224
+ icon: Z(a ? v : M.check, { size: 12 }),
10225
10225
  onClick: s,
10226
10226
  title: "Confirm (Enter)"
10227
10227
  }),
10228
10228
  /* @__PURE__ */ Z(z, {
10229
10229
  size: 24,
10230
- icon: /* @__PURE__ */ Z(N.x, { size: 12 }),
10230
+ icon: /* @__PURE__ */ Z(M.x, { size: 12 }),
10231
10231
  onClick: c,
10232
10232
  title: "Cancel (Esc)"
10233
10233
  })
@@ -10337,7 +10337,7 @@ function Wc() {
10337
10337
  transition: "opacity 0.15s"
10338
10338
  },
10339
10339
  className: "avatar-upload-overlay",
10340
- children: u ? /* @__PURE__ */ Z(v, { size: 18 }) : /* @__PURE__ */ Z(N.upload, {
10340
+ children: u ? /* @__PURE__ */ Z(v, { size: 18 }) : /* @__PURE__ */ Z(M.upload, {
10341
10341
  size: 16,
10342
10342
  style: { color: "var(--profile-avatar-upload-fg)" }
10343
10343
  })
@@ -10432,12 +10432,12 @@ function Wc() {
10432
10432
  ]
10433
10433
  }),
10434
10434
  /* @__PURE__ */ Z(V, {
10435
- icon: /* @__PURE__ */ Z(N.edit, { size: 13 }),
10435
+ icon: /* @__PURE__ */ Z(M.edit, { size: 13 }),
10436
10436
  onClick: () => l(!0),
10437
10437
  children: "Edit profile"
10438
10438
  }),
10439
10439
  /* @__PURE__ */ Z(V, {
10440
- icon: /* @__PURE__ */ Z(N.settings, { size: 13 }),
10440
+ icon: /* @__PURE__ */ Z(M.settings, { size: 13 }),
10441
10441
  onClick: () => e("/preferences"),
10442
10442
  children: "Preferences"
10443
10443
  })
@@ -10452,7 +10452,7 @@ function Wc() {
10452
10452
  children: [
10453
10453
  /* @__PURE__ */ Z(g, {
10454
10454
  title: "Personal info",
10455
- icon: /* @__PURE__ */ Z(N.users, { size: 14 }),
10455
+ icon: /* @__PURE__ */ Z(M.users, { size: 14 }),
10456
10456
  children: /* @__PURE__ */ Q("div", {
10457
10457
  style: {
10458
10458
  display: "grid",
@@ -10499,7 +10499,7 @@ function Wc() {
10499
10499
  }),
10500
10500
  /* @__PURE__ */ Z(g, {
10501
10501
  title: "Security",
10502
- icon: /* @__PURE__ */ Z(N.shield, { size: 14 }),
10502
+ icon: /* @__PURE__ */ Z(M.shield, { size: 14 }),
10503
10503
  children: /* @__PURE__ */ Q("div", {
10504
10504
  style: {
10505
10505
  display: "flex",
@@ -10508,7 +10508,7 @@ function Wc() {
10508
10508
  },
10509
10509
  children: [
10510
10510
  /* @__PURE__ */ Z(Kc, {
10511
- icon: /* @__PURE__ */ Z(N.key, { size: 13 }),
10511
+ icon: /* @__PURE__ */ Z(M.key, { size: 13 }),
10512
10512
  label: "Password",
10513
10513
  hint: "Update at any time",
10514
10514
  action: /* @__PURE__ */ Z(V, {
@@ -10518,7 +10518,7 @@ function Wc() {
10518
10518
  })
10519
10519
  }),
10520
10520
  /* @__PURE__ */ Z(Kc, {
10521
- icon: /* @__PURE__ */ Z(N.shield, { size: 13 }),
10521
+ icon: /* @__PURE__ */ Z(M.shield, { size: 13 }),
10522
10522
  label: "Two-factor authentication",
10523
10523
  hint: "Authenticator app recommended",
10524
10524
  action: /* @__PURE__ */ Z(B, {
@@ -10528,7 +10528,7 @@ function Wc() {
10528
10528
  })
10529
10529
  }),
10530
10530
  /* @__PURE__ */ Z(Kc, {
10531
- icon: /* @__PURE__ */ Z(N.device, { size: 13 }),
10531
+ icon: /* @__PURE__ */ Z(M.device, { size: 13 }),
10532
10532
  label: "Trusted devices",
10533
10533
  hint: "Sign-in sessions by device",
10534
10534
  action: /* @__PURE__ */ Z(V, {
@@ -10538,7 +10538,7 @@ function Wc() {
10538
10538
  })
10539
10539
  }),
10540
10540
  /* @__PURE__ */ Z(Kc, {
10541
- icon: /* @__PURE__ */ Z(N.activity, { size: 13 }),
10541
+ icon: /* @__PURE__ */ Z(M.activity, { size: 13 }),
10542
10542
  label: "Sign-in history",
10543
10543
  hint: "Audit trail of recent logins",
10544
10544
  action: /* @__PURE__ */ Z(V, {
@@ -10552,7 +10552,7 @@ function Wc() {
10552
10552
  }),
10553
10553
  /* @__PURE__ */ Z(g, {
10554
10554
  title: "Access",
10555
- icon: /* @__PURE__ */ Z(N.key, { size: 14 }),
10555
+ icon: /* @__PURE__ */ Z(M.key, { size: 14 }),
10556
10556
  children: /* @__PURE__ */ Q("div", {
10557
10557
  style: {
10558
10558
  display: "flex",
@@ -10606,7 +10606,7 @@ function Wc() {
10606
10606
  }),
10607
10607
  /* @__PURE__ */ Z(g, {
10608
10608
  title: "Notifications",
10609
- icon: /* @__PURE__ */ Z(N.bell, { size: 14 }),
10609
+ icon: /* @__PURE__ */ Z(M.bell, { size: 14 }),
10610
10610
  children: /* @__PURE__ */ Z("div", {
10611
10611
  style: {
10612
10612
  display: "flex",
@@ -10758,7 +10758,7 @@ function Gc({ open: e, initialName: t, userId: n, onClose: i, onSaved: a }) {
10758
10758
  alignItems: "center",
10759
10759
  justifyContent: "center"
10760
10760
  },
10761
- children: /* @__PURE__ */ Z(N.edit, { size: 15 })
10761
+ children: /* @__PURE__ */ Z(M.edit, { size: 15 })
10762
10762
  }),
10763
10763
  /* @__PURE__ */ Q("div", {
10764
10764
  style: { flex: 1 },
@@ -10778,7 +10778,7 @@ function Gc({ open: e, initialName: t, userId: n, onClose: i, onSaved: a }) {
10778
10778
  })]
10779
10779
  }),
10780
10780
  /* @__PURE__ */ Z(z, {
10781
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
10781
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
10782
10782
  onClick: f
10783
10783
  })
10784
10784
  ]
@@ -10790,7 +10790,7 @@ function Gc({ open: e, initialName: t, userId: n, onClose: i, onSaved: a }) {
10790
10790
  flexDirection: "column",
10791
10791
  gap: 12
10792
10792
  },
10793
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(ne, {
10793
+ children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(L, {
10794
10794
  required: !0,
10795
10795
  children: "Display name"
10796
10796
  }), /* @__PURE__ */ Z(O, {
@@ -10808,7 +10808,7 @@ function Gc({ open: e, initialName: t, userId: n, onClose: i, onSaved: a }) {
10808
10808
  display: "flex",
10809
10809
  gap: 6
10810
10810
  },
10811
- children: [/* @__PURE__ */ Z(N.info, { size: 13 }), /* @__PURE__ */ Z("span", { children: u })]
10811
+ children: [/* @__PURE__ */ Z(M.info, { size: 13 }), /* @__PURE__ */ Z("span", { children: u })]
10812
10812
  })]
10813
10813
  }),
10814
10814
  /* @__PURE__ */ Q("div", {
@@ -10828,7 +10828,7 @@ function Gc({ open: e, initialName: t, userId: n, onClose: i, onSaved: a }) {
10828
10828
  }),
10829
10829
  /* @__PURE__ */ Z(V, {
10830
10830
  kind: "primary",
10831
- icon: Z(c ? v : N.check, { size: 13 }),
10831
+ icon: Z(c ? v : M.check, { size: 13 }),
10832
10832
  onClick: async () => {
10833
10833
  if (!o.trim()) {
10834
10834
  d("Display name is required.");
@@ -11029,7 +11029,7 @@ function el() {
11029
11029
  }),
11030
11030
  /* @__PURE__ */ Z(g, {
11031
11031
  title: "Appearance",
11032
- icon: /* @__PURE__ */ Z(N.moon, { size: 14 }),
11032
+ icon: /* @__PURE__ */ Z(M.moon, { size: 14 }),
11033
11033
  children: /* @__PURE__ */ Q("div", {
11034
11034
  style: {
11035
11035
  display: "flex",
@@ -11138,7 +11138,7 @@ function el() {
11138
11138
  /* @__PURE__ */ Z("div", { style: { height: 12 } }),
11139
11139
  /* @__PURE__ */ Z(g, {
11140
11140
  title: "Keyboard",
11141
- icon: /* @__PURE__ */ Z(N.command, { size: 14 }),
11141
+ icon: /* @__PURE__ */ Z(M.command, { size: 14 }),
11142
11142
  children: /* @__PURE__ */ Z("div", {
11143
11143
  style: {
11144
11144
  display: "grid",
@@ -11462,7 +11462,7 @@ function ol({ code: e, param: t }) {
11462
11462
  fontSize: 11,
11463
11463
  color: "var(--text-3)"
11464
11464
  },
11465
- children: ["default: ", L(t.default)]
11465
+ children: ["default: ", I(t.default)]
11466
11466
  }),
11467
11467
  n && /* @__PURE__ */ Z("span", {
11468
11468
  style: {
@@ -11657,8 +11657,8 @@ function ml(e) {
11657
11657
  }
11658
11658
  if (f === "selection-menu-item") {
11659
11659
  let e = _ || o.length === 0;
11660
- return /* @__PURE__ */ Z(F, {
11661
- icon: /* @__PURE__ */ Z(N.download, { size: 12 }),
11660
+ return /* @__PURE__ */ Z(P, {
11661
+ icon: /* @__PURE__ */ Z(M.download, { size: 12 }),
11662
11662
  "data-testid": "export-selection-menu-item",
11663
11663
  onClick: e ? void 0 : () => {
11664
11664
  p?.(), w("selected_rows");
@@ -11671,7 +11671,7 @@ function ml(e) {
11671
11671
  ref: x,
11672
11672
  kind: "ghost",
11673
11673
  size: "sm",
11674
- icon: /* @__PURE__ */ Z(N.download, { size: 12 }),
11674
+ icon: /* @__PURE__ */ Z(M.download, { size: 12 }),
11675
11675
  onClick: () => {
11676
11676
  p?.(), g((e) => !e);
11677
11677
  },
@@ -11684,23 +11684,23 @@ function ml(e) {
11684
11684
  align: u,
11685
11685
  width: 260,
11686
11686
  children: [
11687
- /* @__PURE__ */ Q(F, {
11688
- icon: /* @__PURE__ */ Z(N.download, { size: 12 }),
11687
+ /* @__PURE__ */ Q(P, {
11688
+ icon: /* @__PURE__ */ Z(M.download, { size: 12 }),
11689
11689
  onClick: _ ? void 0 : () => void w("current_view"),
11690
11690
  children: ["Current view (CSV) · ", pl(s)]
11691
11691
  }),
11692
- T && /* @__PURE__ */ Q(F, {
11693
- icon: /* @__PURE__ */ Z(N.check, { size: 12 }),
11692
+ T && /* @__PURE__ */ Q(P, {
11693
+ icon: /* @__PURE__ */ Z(M.check, { size: 12 }),
11694
11694
  onClick: _ ? void 0 : () => void w("selected_rows"),
11695
11695
  children: ["Selected rows (CSV) · ", o.length]
11696
11696
  }),
11697
- /* @__PURE__ */ Q(F, {
11698
- icon: /* @__PURE__ */ Z(N.columns, { size: 12 }),
11697
+ /* @__PURE__ */ Q(P, {
11698
+ icon: /* @__PURE__ */ Z(M.columns, { size: 12 }),
11699
11699
  onClick: _ ? void 0 : () => void w("current_page"),
11700
11700
  children: ["Current page (CSV) · ", c ? `${c} rows` : "page window"]
11701
11701
  }),
11702
- /* @__PURE__ */ Z(F, {
11703
- icon: /* @__PURE__ */ Z(N.grid, { size: 12 }),
11702
+ /* @__PURE__ */ Z(P, {
11703
+ icon: /* @__PURE__ */ Z(M.grid, { size: 12 }),
11704
11704
  children: "XLSX (coming soon)"
11705
11705
  }),
11706
11706
  y && /* @__PURE__ */ Q("div", {
@@ -11989,7 +11989,7 @@ function Ml(e) {
11989
11989
  function Nl(e) {
11990
11990
  if (!e.field || !e.op) return "";
11991
11991
  let t = Dl[e.op] || e.op;
11992
- return El.has(e.op) ? `${t}` : `${t} ${Array.isArray(e.value) ? e.value.join(", ") : L(e.value)}`;
11992
+ return El.has(e.op) ? `${t}` : `${t} ${Array.isArray(e.value) ? e.value.join(", ") : I(e.value)}`;
11993
11993
  }
11994
11994
  function Pl(e, t) {
11995
11995
  return {
@@ -12143,12 +12143,12 @@ function zl({ field: e, fieldName: t, label: n, value: r, record: i, refs: a, re
12143
12143
  children: x
12144
12144
  }), !p && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(z, {
12145
12145
  size: 24,
12146
- icon: /* @__PURE__ */ Z(N.check, { size: 13 }),
12146
+ icon: /* @__PURE__ */ Z(M.check, { size: 13 }),
12147
12147
  onClick: () => h(),
12148
12148
  title: "Save"
12149
12149
  }), /* @__PURE__ */ Z(z, {
12150
12150
  size: 24,
12151
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
12151
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
12152
12152
  onClick: g,
12153
12153
  title: "Cancel"
12154
12154
  })] })]
@@ -12169,7 +12169,7 @@ function zl({ field: e, fieldName: t, label: n, value: r, record: i, refs: a, re
12169
12169
  className: "peek-pencil",
12170
12170
  children: /* @__PURE__ */ Z(z, {
12171
12171
  size: 20,
12172
- icon: /* @__PURE__ */ Z(N.edit, { size: 12 }),
12172
+ icon: /* @__PURE__ */ Z(M.edit, { size: 12 }),
12173
12173
  onClick: (e) => {
12174
12174
  e.stopPropagation(), m();
12175
12175
  },
@@ -12183,7 +12183,7 @@ function zl({ field: e, fieldName: t, label: n, value: r, record: i, refs: a, re
12183
12183
  function Bl(e, t = 12) {
12184
12184
  let n = e.display?.icon;
12185
12185
  if (!n) return null;
12186
- let r = N[n];
12186
+ let r = M[n];
12187
12187
  return r ? /* @__PURE__ */ Z(r, { size: t }) : /* @__PURE__ */ Z(ie, {
12188
12188
  name: n,
12189
12189
  size: t
@@ -12283,12 +12283,12 @@ function Vl({ entity: e, entityCode: t, record: n, title: r, recordId: i, avatar
12283
12283
  })]
12284
12284
  }),
12285
12285
  /* @__PURE__ */ Z(z, {
12286
- icon: /* @__PURE__ */ Z(N.external, { size: 13 }),
12286
+ icon: /* @__PURE__ */ Z(M.external, { size: 13 }),
12287
12287
  title: v ? "Open in tab (keeps unsaved changes)" : "Open in tab",
12288
12288
  onClick: () => f(v ? g : null)
12289
12289
  }),
12290
12290
  /* @__PURE__ */ Z(z, {
12291
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
12291
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
12292
12292
  onClick: d
12293
12293
  })
12294
12294
  ]
@@ -12314,7 +12314,7 @@ function Vl({ entity: e, entityCode: t, record: n, title: r, recordId: i, avatar
12314
12314
  gap: 6
12315
12315
  },
12316
12316
  children: [
12317
- /* @__PURE__ */ Z(N.sparkle, { size: 12 }),
12317
+ /* @__PURE__ */ Z(M.sparkle, { size: 12 }),
12318
12318
  " Inline quick-edit — click any field to change.",
12319
12319
  /* @__PURE__ */ Z(b, { children: "Tab" }),
12320
12320
  " to move, ",
@@ -12375,8 +12375,8 @@ function Vl({ entity: e, entityCode: t, record: n, title: r, recordId: i, avatar
12375
12375
  children: [/* @__PURE__ */ Z(V, {
12376
12376
  ref: C,
12377
12377
  kind: "default",
12378
- icon: /* @__PURE__ */ Z(N.bolt, { size: 13 }),
12379
- iconRight: /* @__PURE__ */ Z(N.down, {
12378
+ icon: /* @__PURE__ */ Z(M.bolt, { size: 13 }),
12379
+ iconRight: /* @__PURE__ */ Z(M.down, {
12380
12380
  size: 10,
12381
12381
  style: { opacity: .6 }
12382
12382
  }),
@@ -12388,7 +12388,7 @@ function Vl({ entity: e, entityCode: t, record: n, title: r, recordId: i, avatar
12388
12388
  onClose: () => S(!1),
12389
12389
  width: 220,
12390
12390
  align: "end",
12391
- children: D.map(({ code: e, action: t }) => /* @__PURE__ */ Z(F, {
12391
+ children: D.map(({ code: e, action: t }) => /* @__PURE__ */ Z(P, {
12392
12392
  icon: Bl(t),
12393
12393
  danger: t.destructive,
12394
12394
  onClick: () => {
@@ -12409,7 +12409,7 @@ function Vl({ entity: e, entityCode: t, record: n, title: r, recordId: i, avatar
12409
12409
  }),
12410
12410
  /* @__PURE__ */ Z(V, {
12411
12411
  kind: "primary",
12412
- icon: /* @__PURE__ */ Z(N.edit, { size: 13 }),
12412
+ icon: /* @__PURE__ */ Z(M.edit, { size: 13 }),
12413
12413
  onClick: () => f(v ? g : null),
12414
12414
  children: "Open full"
12415
12415
  })
@@ -12586,7 +12586,7 @@ function iu({ filters: e, onRemove: t, onClearAll: n, onChipClick: r, fieldLabel
12586
12586
  }, `${e.field}-${n}`) : null), /* @__PURE__ */ Z(V, {
12587
12587
  kind: "ghost",
12588
12588
  size: "xs",
12589
- icon: /* @__PURE__ */ Z(N.x, { size: 11 }),
12589
+ icon: /* @__PURE__ */ Z(M.x, { size: 11 }),
12590
12590
  onClick: n,
12591
12591
  children: "Clear all"
12592
12592
  })]
@@ -12606,7 +12606,7 @@ function iu({ filters: e, onRemove: t, onClearAll: n, onChipClick: r, fieldLabel
12606
12606
  }, `${e.field}-${n}`)), /* @__PURE__ */ Z(V, {
12607
12607
  kind: "ghost",
12608
12608
  size: "xs",
12609
- icon: /* @__PURE__ */ Z(N.x, { size: 11 }),
12609
+ icon: /* @__PURE__ */ Z(M.x, { size: 11 }),
12610
12610
  onClick: n,
12611
12611
  children: "Clear all"
12612
12612
  })]
@@ -12615,7 +12615,7 @@ function iu({ filters: e, onRemove: t, onClearAll: n, onChipClick: r, fieldLabel
12615
12615
  function au({ node: e, fieldLabel: t, onRemove: n, onClick: r }) {
12616
12616
  return /* @__PURE__ */ Z(re, {
12617
12617
  tone: "slate",
12618
- icon: /* @__PURE__ */ Z(N.filter, { size: 11 }),
12618
+ icon: /* @__PURE__ */ Z(M.filter, { size: 11 }),
12619
12619
  onClick: r,
12620
12620
  onRemove: n,
12621
12621
  children: /* @__PURE__ */ Q("span", { children: [
@@ -12696,7 +12696,7 @@ function ou({ open: e, onClose: t, filters: n, onApply: r, availableFields: i })
12696
12696
  alignItems: "center",
12697
12697
  gap: 8
12698
12698
  },
12699
- children: [/* @__PURE__ */ Z(N.filter, { size: 14 }), /* @__PURE__ */ Z("h3", {
12699
+ children: [/* @__PURE__ */ Z(M.filter, { size: 14 }), /* @__PURE__ */ Z("h3", {
12700
12700
  style: {
12701
12701
  margin: 0,
12702
12702
  fontSize: 13,
@@ -12706,7 +12706,7 @@ function ou({ open: e, onClose: t, filters: n, onApply: r, availableFields: i })
12706
12706
  children: "Filters"
12707
12707
  })]
12708
12708
  }), /* @__PURE__ */ Z(z, {
12709
- icon: /* @__PURE__ */ Z(N.x, { size: 14 }),
12709
+ icon: /* @__PURE__ */ Z(M.x, { size: 14 }),
12710
12710
  onClick: t,
12711
12711
  title: "Close"
12712
12712
  })]
@@ -12761,12 +12761,12 @@ function ou({ open: e, onClose: t, filters: n, onApply: r, availableFields: i })
12761
12761
  onSelect: d,
12762
12762
  onCancel: () => c(!1)
12763
12763
  }) : /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(V, {
12764
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
12764
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
12765
12765
  onClick: () => c(!0),
12766
12766
  children: "Add filter"
12767
12767
  }), !l && a.some((e) => e.field) && /* @__PURE__ */ Z(V, {
12768
12768
  kind: "ghost",
12769
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
12769
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
12770
12770
  onClick: () => {
12771
12771
  let e = a.filter((e) => e.field && e.op);
12772
12772
  o([...a.filter((e) => !e.field || !e.op), { or: [e.length > 0 ? e : [], []] }]);
@@ -12851,7 +12851,7 @@ function su({ node: e, meta: t, onUpdate: r, onRemove: i }) {
12851
12851
  }),
12852
12852
  a ? /* @__PURE__ */ Z("span", {}) : t.options ? /* @__PURE__ */ Z(n, {
12853
12853
  "aria-label": `${t.label} filter value`,
12854
- value: L(e.value),
12854
+ value: I(e.value),
12855
12855
  options: t.options.map((e) => ({
12856
12856
  value: e.value,
12857
12857
  label: e.label
@@ -12860,13 +12860,13 @@ function su({ node: e, meta: t, onUpdate: r, onRemove: i }) {
12860
12860
  placeholder: "Select…"
12861
12861
  }) : /* @__PURE__ */ Z(O, {
12862
12862
  "aria-label": `${t.label} filter value`,
12863
- value: L(e.value),
12863
+ value: I(e.value),
12864
12864
  onChange: (e) => r({ value: e }),
12865
12865
  placeholder: "Value…"
12866
12866
  }),
12867
12867
  /* @__PURE__ */ Z(z, {
12868
12868
  size: 24,
12869
- icon: /* @__PURE__ */ Z(N.x, { size: 12 }),
12869
+ icon: /* @__PURE__ */ Z(M.x, { size: 12 }),
12870
12870
  onClick: i,
12871
12871
  title: "Remove"
12872
12872
  })
@@ -12945,7 +12945,7 @@ function cu({ groups: e, availableFields: t, onChange: n }) {
12945
12945
  /* @__PURE__ */ Z(V, {
12946
12946
  kind: "ghost",
12947
12947
  size: "xs",
12948
- icon: /* @__PURE__ */ Z(N.plus, { size: 11 }),
12948
+ icon: /* @__PURE__ */ Z(M.plus, { size: 11 }),
12949
12949
  onClick: () => {
12950
12950
  let a = new Set(r.map((e) => e.field)), o = t.find((e) => !a.has(e.code));
12951
12951
  o && n(e.map((e, t) => t === i ? [...e, {
@@ -12959,7 +12959,7 @@ function cu({ groups: e, availableFields: t, onChange: n }) {
12959
12959
  })] }, i)), /* @__PURE__ */ Z(V, {
12960
12960
  kind: "ghost",
12961
12961
  size: "xs",
12962
- icon: /* @__PURE__ */ Z(N.plus, { size: 11 }),
12962
+ icon: /* @__PURE__ */ Z(M.plus, { size: 11 }),
12963
12963
  onClick: () => n([...e, []]),
12964
12964
  children: "Add OR group"
12965
12965
  })]
@@ -12982,7 +12982,7 @@ function lu({ fields: e, activeFields: t, onSelect: n, onCancel: r }) {
12982
12982
  value: i,
12983
12983
  onChange: a,
12984
12984
  placeholder: "Search fields…",
12985
- prefix: /* @__PURE__ */ Z(N.search, { size: 12 }),
12985
+ prefix: /* @__PURE__ */ Z(M.search, { size: 12 }),
12986
12986
  autoFocus: !0
12987
12987
  }),
12988
12988
  /* @__PURE__ */ Q("div", {
@@ -13460,7 +13460,7 @@ function mu({ selectedIds: e, floatbarActions: n, screenActionLayout: r, entityA
13460
13460
  borderRadius: 6
13461
13461
  },
13462
13462
  title: "Clear selection",
13463
- children: /* @__PURE__ */ Z(N.x, { size: 14 })
13463
+ children: /* @__PURE__ */ Z(M.x, { size: 14 })
13464
13464
  })
13465
13465
  ]
13466
13466
  });
@@ -13576,7 +13576,7 @@ function Cu({ row: e, rowId: n, screen: r, fullScreen: i, entity: a, entityCode:
13576
13576
  },
13577
13577
  children: [d && /* @__PURE__ */ Z(z, {
13578
13578
  size: 22,
13579
- icon: /* @__PURE__ */ Z(N.eye, { size: 12 }),
13579
+ icon: /* @__PURE__ */ Z(M.eye, { size: 12 }),
13580
13580
  onClick: (e) => {
13581
13581
  e.stopPropagation(), d();
13582
13582
  },
@@ -13602,7 +13602,7 @@ function wu(e, t, n) {
13602
13602
  title: i,
13603
13603
  "aria-label": i,
13604
13604
  className: "inline-flex items-center gap-1"
13605
- }, Vt(N.lock, { size: 12 }), e);
13605
+ }, Vt(M.lock, { size: 12 }), e);
13606
13606
  }
13607
13607
  function Tu(e) {
13608
13608
  let { visibleCols: t, entity: n, screen: r, schema: i, entityCode: a, rowActions: o, hasBatchActions: s, hasExplicitRowActions: c, canUpdate: l, canDelete: u, peekEnabled: d, userLocale: f, tabNavigate: p, refsRef: m, rowSelectionKey: h, setPeekRow: g } = e;
@@ -13652,7 +13652,7 @@ function Tu(e) {
13652
13652
  enableSorting: !1,
13653
13653
  cell: ({ row: e }) => {
13654
13654
  let n = e.original.$properties?.find((e) => e.property_code === t);
13655
- return !n || n.value == null ? Vt("span", { className: "text-sm text-muted-foreground" }, "-") : Vt("span", { className: "text-sm" }, L(n.value));
13655
+ return !n || n.value == null ? Vt("span", { className: "text-sm text-muted-foreground" }, "-") : Vt("span", { className: "text-sm" }, I(n.value));
13656
13656
  }
13657
13657
  });
13658
13658
  continue;
@@ -13724,7 +13724,7 @@ function Eu({ availableColumns: e, visibleColumns: t, onToggle: n, onReset: r, o
13724
13724
  let o = J(null), [s, c] = Y(!1);
13725
13725
  return /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(V, {
13726
13726
  ref: o,
13727
- icon: /* @__PURE__ */ Z(N.columns, { size: 13 }),
13727
+ icon: /* @__PURE__ */ Z(M.columns, { size: 13 }),
13728
13728
  onClick: () => c((e) => !e),
13729
13729
  active: s,
13730
13730
  children: "Columns"
@@ -13746,22 +13746,22 @@ function Eu({ availableColumns: e, visibleColumns: t, onToggle: n, onReset: r, o
13746
13746
  },
13747
13747
  children: "Show columns"
13748
13748
  }),
13749
- e.map((e) => /* @__PURE__ */ Z(F, {
13750
- icon: t.includes(e) ? /* @__PURE__ */ Z(N.check, { size: 12 }) : /* @__PURE__ */ Z("span", { style: {
13749
+ e.map((e) => /* @__PURE__ */ Z(P, {
13750
+ icon: t.includes(e) ? /* @__PURE__ */ Z(M.check, { size: 12 }) : /* @__PURE__ */ Z("span", { style: {
13751
13751
  width: 12,
13752
13752
  display: "inline-block"
13753
13753
  } }),
13754
13754
  onClick: () => n(e),
13755
13755
  children: a(e)
13756
13756
  }, e)),
13757
- /* @__PURE__ */ Z(F, { divider: !0 }),
13758
- /* @__PURE__ */ Z(F, {
13759
- icon: /* @__PURE__ */ Z(N.refresh, { size: 12 }),
13757
+ /* @__PURE__ */ Z(P, { divider: !0 }),
13758
+ /* @__PURE__ */ Z(P, {
13759
+ icon: /* @__PURE__ */ Z(M.refresh, { size: 12 }),
13760
13760
  onClick: r,
13761
13761
  children: "Reset"
13762
13762
  }),
13763
- /* @__PURE__ */ Z(F, {
13764
- icon: /* @__PURE__ */ Z(N.eye, { size: 12 }),
13763
+ /* @__PURE__ */ Z(P, {
13764
+ icon: /* @__PURE__ */ Z(M.eye, { size: 12 }),
13765
13765
  onClick: i,
13766
13766
  children: "Show all"
13767
13767
  })
@@ -13809,7 +13809,7 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13809
13809
  onClick: () => c((e) => !e),
13810
13810
  style: Du,
13811
13811
  children: [
13812
- /* @__PURE__ */ Z(N.star, { size: 12 }),
13812
+ /* @__PURE__ */ Z(M.star, { size: 12 }),
13813
13813
  /* @__PURE__ */ Z("span", { children: p }),
13814
13814
  n && /* @__PURE__ */ Z("span", { style: {
13815
13815
  display: "inline-block",
@@ -13819,7 +13819,7 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13819
13819
  background: "var(--warn)",
13820
13820
  marginLeft: 2
13821
13821
  } }),
13822
- /* @__PURE__ */ Z(N.down, { size: 11 })
13822
+ /* @__PURE__ */ Z(M.down, { size: 11 })
13823
13823
  ]
13824
13824
  }),
13825
13825
  /* @__PURE__ */ Q(m, {
@@ -13828,8 +13828,8 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13828
13828
  onClose: () => c(!1),
13829
13829
  width: 280,
13830
13830
  children: [
13831
- /* @__PURE__ */ Z(F, {
13832
- icon: t ? void 0 : /* @__PURE__ */ Z(N.check, { size: 12 }),
13831
+ /* @__PURE__ */ Z(P, {
13832
+ icon: t ? void 0 : /* @__PURE__ */ Z(M.check, { size: 12 }),
13833
13833
  active: !t,
13834
13834
  onClick: () => {
13835
13835
  r({
@@ -13841,8 +13841,8 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13841
13841
  children: "Default view"
13842
13842
  }),
13843
13843
  u.length > 0 && h("Presets"),
13844
- u.map((e) => /* @__PURE__ */ Z(F, {
13845
- icon: t === e.id ? /* @__PURE__ */ Z(N.check, { size: 12 }) : void 0,
13844
+ u.map((e) => /* @__PURE__ */ Z(P, {
13845
+ icon: t === e.id ? /* @__PURE__ */ Z(M.check, { size: 12 }) : void 0,
13846
13846
  active: t === e.id,
13847
13847
  onClick: () => {
13848
13848
  r(e), c(!1);
@@ -13850,8 +13850,8 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13850
13850
  children: W(e.name)
13851
13851
  }, e.id)),
13852
13852
  d.length > 0 && h("My Views"),
13853
- d.map((e) => /* @__PURE__ */ Z(F, {
13854
- icon: t === e.id ? /* @__PURE__ */ Z(N.check, { size: 12 }) : e.is_default ? /* @__PURE__ */ Z(N.star, { size: 12 }) : void 0,
13853
+ d.map((e) => /* @__PURE__ */ Z(P, {
13854
+ icon: t === e.id ? /* @__PURE__ */ Z(M.check, { size: 12 }) : e.is_default ? /* @__PURE__ */ Z(M.star, { size: 12 }) : void 0,
13855
13855
  active: t === e.id,
13856
13856
  onClick: () => {
13857
13857
  r(e), c(!1);
@@ -13859,16 +13859,16 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13859
13859
  children: W(e.name)
13860
13860
  }, e.id)),
13861
13861
  f.length > 0 && h("Shared"),
13862
- f.map((e) => /* @__PURE__ */ Z(F, {
13863
- icon: t === e.id ? /* @__PURE__ */ Z(N.check, { size: 12 }) : /* @__PURE__ */ Z(N.globe, { size: 12 }),
13862
+ f.map((e) => /* @__PURE__ */ Z(P, {
13863
+ icon: t === e.id ? /* @__PURE__ */ Z(M.check, { size: 12 }) : /* @__PURE__ */ Z(M.globe, { size: 12 }),
13864
13864
  active: t === e.id,
13865
13865
  onClick: () => {
13866
13866
  r(e), c(!1);
13867
13867
  },
13868
13868
  children: W(e.name)
13869
13869
  }, e.id)),
13870
- a && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(F, { divider: !0 }), /* @__PURE__ */ Z(F, {
13871
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
13870
+ a && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(P, { divider: !0 }), /* @__PURE__ */ Z(P, {
13871
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
13872
13872
  onClick: () => {
13873
13873
  a(), c(!1);
13874
13874
  },
@@ -13877,7 +13877,7 @@ function Ou({ views: e, activeViewId: t, isDirty: n, onSelect: r, onSave: i, onS
13877
13877
  ]
13878
13878
  }),
13879
13879
  n && t && i && /* @__PURE__ */ Z(V, {
13880
- icon: /* @__PURE__ */ Z(N.save, { size: 12 }),
13880
+ icon: /* @__PURE__ */ Z(M.save, { size: 12 }),
13881
13881
  onClick: i,
13882
13882
  children: "Save"
13883
13883
  })
@@ -13924,7 +13924,7 @@ function Au(e, t) {
13924
13924
  let r = t && String(n.user_id) === t;
13925
13925
  e.push({
13926
13926
  id: String(n.id),
13927
- name: typeof n.name == "object" && n.name !== null ? n.name : { en: L(n.name) },
13927
+ name: typeof n.name == "object" && n.name !== null ? n.name : { en: I(n.name) },
13928
13928
  icon: n.icon,
13929
13929
  source: r ? "personal" : "shared",
13930
13930
  is_default: n.is_default === !0,
@@ -13983,25 +13983,25 @@ function Nu({ field: e, activeDir: t, activeNulls: n, inMultiSort: r, canAppend:
13983
13983
  label: "Sort ascending, empty last",
13984
13984
  dir: "asc",
13985
13985
  nulls: "last",
13986
- icon: N.arrowUp
13986
+ icon: M.arrowUp
13987
13987
  },
13988
13988
  {
13989
13989
  label: "Sort ascending, empty first",
13990
13990
  dir: "asc",
13991
13991
  nulls: "first",
13992
- icon: N.arrowUp
13992
+ icon: M.arrowUp
13993
13993
  },
13994
13994
  {
13995
13995
  label: "Sort descending, empty last",
13996
13996
  dir: "desc",
13997
13997
  nulls: "last",
13998
- icon: N.arrowDown
13998
+ icon: M.arrowDown
13999
13999
  },
14000
14000
  {
14001
14001
  label: "Sort descending, empty first",
14002
14002
  dir: "desc",
14003
14003
  nulls: "first",
14004
- icon: N.arrowDown
14004
+ icon: M.arrowDown
14005
14005
  }
14006
14006
  ], p = n ?? "last", h = !r && i;
14007
14007
  return /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z("button", {
@@ -14025,7 +14025,7 @@ function Nu({ field: e, activeDir: t, activeNulls: n, inMultiSort: r, canAppend:
14025
14025
  cursor: "pointer",
14026
14026
  opacity: u ? 1 : .55
14027
14027
  },
14028
- children: /* @__PURE__ */ Z(N.cheveron, { size: 12 })
14028
+ children: /* @__PURE__ */ Z(M.cheveron, { size: 12 })
14029
14029
  }), /* @__PURE__ */ Q(m, {
14030
14030
  open: u,
14031
14031
  anchor: l.current,
@@ -14035,14 +14035,14 @@ function Nu({ field: e, activeDir: t, activeNulls: n, inMultiSort: r, canAppend:
14035
14035
  children: [
14036
14036
  f.map((e) => {
14037
14037
  let n = t === e.dir && p === e.nulls, r = e.icon;
14038
- return /* @__PURE__ */ Z(F, {
14038
+ return /* @__PURE__ */ Z(P, {
14039
14039
  icon: /* @__PURE__ */ Q("span", {
14040
14040
  style: {
14041
14041
  display: "inline-flex",
14042
14042
  alignItems: "center",
14043
14043
  gap: 2
14044
14044
  },
14045
- children: [/* @__PURE__ */ Z(r, { size: 11 }), n ? /* @__PURE__ */ Z(N.check, { size: 11 }) : null]
14045
+ children: [/* @__PURE__ */ Z(r, { size: 11 }), n ? /* @__PURE__ */ Z(M.check, { size: 11 }) : null]
14046
14046
  }),
14047
14047
  onClick: () => {
14048
14048
  d(!1), a(e.dir, e.nulls);
@@ -14050,23 +14050,23 @@ function Nu({ field: e, activeDir: t, activeNulls: n, inMultiSort: r, canAppend:
14050
14050
  children: e.label
14051
14051
  }, `${e.dir}:${e.nulls}`);
14052
14052
  }),
14053
- h ? /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(F, { divider: !0 }), /* @__PURE__ */ Z(F, {
14054
- icon: /* @__PURE__ */ Z(N.plus, { size: 11 }),
14053
+ h ? /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(P, { divider: !0 }), /* @__PURE__ */ Z(P, {
14054
+ icon: /* @__PURE__ */ Z(M.plus, { size: 11 }),
14055
14055
  onClick: () => {
14056
14056
  d(!1), o("asc", n);
14057
14057
  },
14058
14058
  children: "Add to multi-sort (Shift-click shortcut)"
14059
14059
  })] }) : null,
14060
- /* @__PURE__ */ Z(F, { divider: !0 }),
14061
- /* @__PURE__ */ Z(F, {
14060
+ /* @__PURE__ */ Z(P, { divider: !0 }),
14061
+ /* @__PURE__ */ Z(P, {
14062
14062
  disabled: t === !1,
14063
14063
  onClick: () => {
14064
14064
  d(!1), t !== !1 && s();
14065
14065
  },
14066
14066
  children: "Clear sort on this column"
14067
14067
  }),
14068
- /* @__PURE__ */ Z(F, { divider: !0 }),
14069
- /* @__PURE__ */ Z(F, {
14068
+ /* @__PURE__ */ Z(P, { divider: !0 }),
14069
+ /* @__PURE__ */ Z(P, {
14070
14070
  disabled: t === !1,
14071
14071
  onClick: () => {
14072
14072
  d(!1), c();
@@ -14134,20 +14134,20 @@ function Uu({ screenCode: e }) {
14134
14134
  return /* @__PURE__ */ Z(Ot, { children: /* @__PURE__ */ Z(Wu, { screenCode: e }) });
14135
14135
  }
14136
14136
  function Wu({ screenCode: e }) {
14137
- let n = Mr(), r = dn(), [i, o] = an(), { data: s } = oe(), c = Ee(), [l, u] = Y(null), [d, f] = Y({}), [m, h] = Y(!1), [g, _] = Y(!1), [y, x] = Y(null), { filters: S, activeCount: C, setFilters: w, clearFilters: T } = Il(), E = p((e) => e.user), D = p((e) => e.activeTenant), k = Au(e, E?.id), A = Nt(), ee = `dcl:smartlist:default-view-cleared:${e}`, M = J(!1);
14137
+ let n = Mr(), r = dn(), [i, o] = an(), { data: s } = oe(), c = Ee(), [l, u] = Y(null), [d, f] = Y({}), [m, h] = Y(!1), [g, _] = Y(!1), [y, x] = Y(null), { filters: S, activeCount: C, setFilters: w, clearFilters: T } = Il(), E = p((e) => e.user), D = p((e) => e.activeTenant), k = Au(e, E?.id), A = Nt(), ee = `dcl:smartlist:default-view-cleared:${e}`, te = J(!1);
14138
14138
  K(() => {
14139
- if (M.current || !k || k.length === 0) return;
14139
+ if (te.current || !k || k.length === 0) return;
14140
14140
  if (i.get("view")) {
14141
- M.current = !0;
14141
+ te.current = !0;
14142
14142
  return;
14143
14143
  }
14144
14144
  if (typeof window < "u" && window.sessionStorage?.getItem(ee)) {
14145
- M.current = !0;
14145
+ te.current = !0;
14146
14146
  return;
14147
14147
  }
14148
14148
  let e = k.find((e) => e.source === "personal" && e.is_default);
14149
14149
  if (!e || !e.id) return;
14150
- M.current = !0;
14150
+ te.current = !0;
14151
14151
  let t = Bu(i);
14152
14152
  t.set("view", e.id), e.filters && Array.isArray(e.filters) && e.filters.length > 0 && t.set("filters", JSON.stringify(e.filters)), e.columns && e.columns.length > 0 && t.set("columns", e.columns.join(",")), e.sort && t.set("sort", e.sort), o(t, { replace: !0 });
14153
14153
  }, [
@@ -14156,24 +14156,24 @@ function Wu({ screenCode: e }) {
14156
14156
  o,
14157
14157
  ee
14158
14158
  ]);
14159
- let P = s?.screens[e], I = P?.entity ? s?.entities[P.entity] : void 0, te = P?.entity, ne = _e(I, "create"), re = _e(I, "update"), ie = _e(I, "delete"), ae = s?.actions, se = q(() => Rs(I?.actions, P?.actions, "list_toolbar", ae), [
14160
- I?.actions,
14161
- P?.actions,
14159
+ let N = s?.screens[e], F = N?.entity ? s?.entities[N.entity] : void 0, ne = N?.entity, L = _e(F, "create"), re = _e(F, "update"), ie = _e(F, "delete"), ae = s?.actions, se = q(() => Rs(F?.actions, N?.actions, "list_toolbar", ae), [
14160
+ F?.actions,
14161
+ N?.actions,
14162
14162
  ae
14163
- ]), ce = q(() => Rs(I?.actions, void 0, "list_floatbar", ae), [I?.actions, ae]), le = q(() => Rs(I?.actions, P?.row_actions, "list_row", ae), [
14164
- I?.actions,
14165
- P?.row_actions,
14163
+ ]), ce = q(() => Rs(F?.actions, void 0, "list_floatbar", ae), [F?.actions, ae]), le = q(() => Rs(F?.actions, N?.row_actions, "list_row", ae), [
14164
+ F?.actions,
14165
+ N?.row_actions,
14166
14166
  ae
14167
- ]), ue = P?.row_actions !== void 0, de = q(() => ce.length > 0 || I?.export?.enabled !== !1 && P?.export?.enabled !== !1, [
14167
+ ]), ue = N?.row_actions !== void 0, de = q(() => ce.length > 0 || F?.export?.enabled !== !1 && N?.export?.enabled !== !1, [
14168
14168
  ce,
14169
- I?.export?.enabled,
14170
- P?.export?.enabled
14171
- ]), H = !!I?.soft_delete, me = H && (E?.permissions ?? []).some((e) => e === "feature:view_deleted" || e === "feature:*" || e === "*"), he = me && i.get("include_deleted") === "true", ve = rr(), { openTab: be, updateTabSearch: Se, findTabByPathname: Ce } = Bn();
14169
+ F?.export?.enabled,
14170
+ N?.export?.enabled
14171
+ ]), H = !!F?.soft_delete, me = H && (E?.permissions ?? []).some((e) => e === "feature:view_deleted" || e === "feature:*" || e === "*"), he = me && i.get("include_deleted") === "true", ve = rr(), { openTab: be, updateTabSearch: Se, findTabByPathname: Ce } = Bn();
14172
14172
  K(() => {
14173
- if (P?.route && I && !ve.enabled) {
14174
- let e = W(P.display?.name) || W(I.display.name_plural), t = P.display?.icon || I.display.icon;
14173
+ if (N?.route && F && !ve.enabled) {
14174
+ let e = W(N.display?.name) || W(F.display.name_plural), t = N.display?.icon || F.display.icon;
14175
14175
  be({
14176
- pathname: P.route,
14176
+ pathname: N.route,
14177
14177
  search: i.toString(),
14178
14178
  title: e,
14179
14179
  icon: t,
@@ -14181,39 +14181,39 @@ function Wu({ screenCode: e }) {
14181
14181
  });
14182
14182
  }
14183
14183
  }, [
14184
- P?.route,
14185
- P?.display?.name?.en,
14186
- I?.display.name_plural?.en,
14187
- P?.display?.icon,
14188
- I?.display.icon,
14184
+ N?.route,
14185
+ N?.display?.name?.en,
14186
+ F?.display.name_plural?.en,
14187
+ N?.display?.icon,
14188
+ F?.display.icon,
14189
14189
  ve.enabled
14190
14190
  ]), K(() => {
14191
- if (!P?.route || ve.enabled) return;
14192
- let e = Ce(P.route);
14191
+ if (!N?.route || ve.enabled) return;
14192
+ let e = Ce(N.route);
14193
14193
  e && Se(e.id, i.toString());
14194
14194
  }, [
14195
14195
  i,
14196
- P?.route,
14196
+ N?.route,
14197
14197
  ve.enabled
14198
14198
  ]);
14199
14199
  let we = parseInt(i.get("page") ?? "1", 10), Te = (() => {
14200
14200
  let e = parseInt(i.get("per_page") ?? "", 10);
14201
14201
  return !Number.isFinite(e) || e <= 0 || e > 1e3 ? 200 : e;
14202
- })(), U = i.get("search") ?? "", De = i.get("sort") ?? P?.sort_default ?? "", Oe = q(() => Jl(De), [De]), ke = q(() => {
14202
+ })(), U = i.get("search") ?? "", De = i.get("sort") ?? N?.sort_default ?? "", Oe = q(() => Jl(De), [De]), ke = q(() => {
14203
14203
  let e = /* @__PURE__ */ new Map();
14204
14204
  for (let t of Oe) t.nulls && e.set(t.field, t.nulls);
14205
14205
  return e;
14206
14206
  }, [Oe]), Ae = q(() => Yl(De), [De]), je = _l(U, 300), Me = q(() => {
14207
14207
  let e = i.get("columns");
14208
- return e ? e.split(",").filter(Boolean) : P?.default_columns ?? P?.columns ?? [];
14208
+ return e ? e.split(",").filter(Boolean) : N?.default_columns ?? N?.columns ?? [];
14209
14209
  }, [
14210
14210
  i,
14211
- P?.default_columns,
14212
- P?.columns
14211
+ N?.default_columns,
14212
+ N?.columns
14213
14213
  ]), Pe = q(() => {
14214
- let e = [], t = [...P?.columns ?? [], ...Me];
14214
+ let e = [], t = [...N?.columns ?? [], ...Me];
14215
14215
  return t.some((e) => e.startsWith("$status.")) && e.push("statuses"), t.some((e) => e.startsWith("$property.")) && e.push("properties"), e.length > 0 && e.unshift("refs"), e.length > 0 ? e : void 0;
14216
- }, [P?.columns, Me]), Fe = q(() => {
14216
+ }, [N?.columns, Me]), Fe = q(() => {
14217
14217
  let e = Me.filter((e) => e && !e.startsWith("$"));
14218
14218
  return e.length > 0 ? e : void 0;
14219
14219
  }, [Me]), Ie = {
@@ -14226,24 +14226,24 @@ function Wu({ screenCode: e }) {
14226
14226
  expand: Pe,
14227
14227
  select: Fe,
14228
14228
  preview: !0,
14229
- screen: P?.fixed_filters ? e : void 0
14230
- }, { data: Le, isLoading: Be, isFetching: Ve, isError: He, error: Ue, refetch: We } = $e(te, Ie), { data: Ke, isLoading: qe, isError: Je } = a(te, Ie), Ze = Ke?.meta?.total, Qe = Ke?.meta?.count_mode, et = Iu(Be, `${te ?? ""}|${i.toString()}`), tt = G(() => {
14231
- te && r.cancelQueries({ queryKey: ["entity-data", te] }), We();
14229
+ screen: N?.fixed_filters ? e : void 0
14230
+ }, { data: Le, isLoading: Be, isFetching: Ve, isError: He, error: Ue, refetch: We } = $e(ne, Ie), { data: Ke, isLoading: qe, isError: Je } = a(ne, Ie), Ze = Ke?.meta?.total, Qe = Ke?.meta?.count_mode, et = Iu(Be, `${ne ?? ""}|${i.toString()}`), tt = G(() => {
14231
+ ne && r.cancelQueries({ queryKey: ["entity-data", ne] }), We();
14232
14232
  }, [
14233
- te,
14233
+ ne,
14234
14234
  r,
14235
14235
  We
14236
- ]), nt = Co((e) => e.degradedEntities), rt = wo(I?.realtime, nt, te ?? ""), it = As(te ?? ""), at = ks(te ?? ""), ot = Os("view"), st = q(() => Oe.map((e) => ({
14236
+ ]), nt = Co((e) => e.degradedEntities), rt = wo(F?.realtime, nt, ne ?? ""), it = As(ne ?? ""), at = ks(ne ?? ""), ot = Os("view"), st = q(() => Oe.map((e) => ({
14237
14237
  id: e.field,
14238
14238
  desc: e.dir === "desc"
14239
- })), [Oe]), ct = q(() => I?.fields.names().find((e) => I.fields.get(e)?.primary) ?? "id", [I]), lt = G((e) => I ? Vu(I, e) : L(e[ct]), [I, ct]), ut = Le?.$refs, dt = J(ut);
14239
+ })), [Oe]), ct = q(() => F?.fields.names().find((e) => F.fields.get(e)?.primary) ?? "id", [F]), lt = G((e) => F ? Vu(F, e) : I(e[ct]), [F, ct]), ut = Le?.$refs, dt = J(ut);
14240
14240
  dt.current = ut;
14241
- let [ft, pt] = Y(null), mt = P?.on_row_click === "peek" && P.quick_peek?.enabled !== !1, ht = q(() => Tu({
14241
+ let [ft, pt] = Y(null), mt = N?.on_row_click === "peek" && N.quick_peek?.enabled !== !1, ht = q(() => Tu({
14242
14242
  visibleCols: Me,
14243
- entity: I,
14244
- screen: P,
14243
+ entity: F,
14244
+ screen: N,
14245
14245
  schema: s,
14246
- entityCode: te,
14246
+ entityCode: ne,
14247
14247
  rowActions: le,
14248
14248
  hasBatchActions: de,
14249
14249
  hasExplicitRowActions: ue,
@@ -14256,14 +14256,14 @@ function Wu({ screenCode: e }) {
14256
14256
  rowSelectionKey: Vu,
14257
14257
  setPeekRow: pt
14258
14258
  }), [
14259
- P,
14260
- I,
14259
+ N,
14260
+ F,
14261
14261
  Me,
14262
14262
  n,
14263
14263
  de,
14264
14264
  le,
14265
14265
  ue,
14266
- te,
14266
+ ne,
14267
14267
  mt,
14268
14268
  s,
14269
14269
  c,
@@ -14301,8 +14301,8 @@ function Wu({ screenCode: e }) {
14301
14301
  onRowSelectionChange: f,
14302
14302
  getRowId: lt,
14303
14303
  rowCount: Ze ?? gt.length
14304
- }), xt = q(() => Object.keys(d).filter((e) => d[e]), [d]), St = q(() => Hu(I, gt, xt), [
14305
- I,
14304
+ }), xt = q(() => Object.keys(d).filter((e) => d[e]), [d]), St = q(() => Hu(F, gt, xt), [
14305
+ F,
14306
14306
  gt,
14307
14307
  xt
14308
14308
  ]), Ct = G((e) => {
@@ -14382,27 +14382,27 @@ function Wu({ screenCode: e }) {
14382
14382
  let n = new URLSearchParams(t);
14383
14383
  return n.set("per_page", String(e)), n.set("page", "1"), n;
14384
14384
  });
14385
- }, [o]), zt = q(() => !P || !I ? !1 : pe(P, "_", I, s?.screens) !== null, [
14386
- P,
14387
- I,
14385
+ }, [o]), zt = q(() => !N || !F ? !1 : pe(N, "_", F, s?.screens) !== null, [
14386
+ N,
14387
+ F,
14388
14388
  s?.screens
14389
14389
  ]), Bt = G((e, t) => {
14390
- if (!I || !P) return;
14391
- let r = Ne(I, e), i = fe(I, r), a = Re(P, I, s?.screens, r);
14390
+ if (!F || !N) return;
14391
+ let r = Ne(F, e), i = fe(F, r), a = Re(N, F, s?.screens, r);
14392
14392
  if (!a) return;
14393
14393
  if (t?.draft) {
14394
14394
  Wl(i, t.draft);
14395
14395
  let [e, n] = a.split("?", 2), r = new URLSearchParams(n ?? "");
14396
14396
  r.set("edit", "true"), a = `${e}?${r.toString()}`;
14397
14397
  }
14398
- let o = ye(e, I) ?? W(I.display.name), c = P.display?.icon || I.display.icon;
14398
+ let o = ye(e, F) ?? W(F.display.name), c = N.display?.icon || F.display.icon;
14399
14399
  n(a, {
14400
14400
  title: o,
14401
14401
  icon: c
14402
14402
  });
14403
14403
  }, [
14404
- I,
14405
- P,
14404
+ F,
14405
+ N,
14406
14406
  s,
14407
14407
  n
14408
14408
  ]), Vt = G((e, t) => {
@@ -14414,11 +14414,11 @@ function Wu({ screenCode: e }) {
14414
14414
  Bt(t);
14415
14415
  }
14416
14416
  }, [mt, Bt]), Ht = q(() => {
14417
- if (!mt || !I || !ft) return [];
14418
- let e = P?.quick_peek?.fields, t = P?.quick_peek?.sections, n;
14419
- if (e && e.length > 0) n = e.filter((e) => I.fields.get(e) || I.files?.get(e));
14417
+ if (!mt || !F || !ft) return [];
14418
+ let e = N?.quick_peek?.fields, t = N?.quick_peek?.sections, n;
14419
+ if (e && e.length > 0) n = e.filter((e) => F.fields.get(e) || F.files?.get(e));
14420
14420
  else if (t && t.length > 0) {
14421
- let e = Object.values(s?.screens ?? {}).find((e) => e.type === "detail" && e.entity === P?.entity)?.items ?? [], r = [], i = (e) => {
14421
+ let e = Object.values(s?.screens ?? {}).find((e) => e.type === "detail" && e.entity === N?.entity)?.items ?? [], r = [], i = (e) => {
14422
14422
  if (Array.isArray(e)) {
14423
14423
  for (let n of e) if (n && typeof n == "object" && "section" in n) {
14424
14424
  let e = n.section, r = typeof e?.name == "string" ? e.name : e?.name && typeof e.name == "object" ? Object.values(e.name)[0] : "";
@@ -14429,16 +14429,16 @@ function Wu({ screenCode: e }) {
14429
14429
  }
14430
14430
  }
14431
14431
  };
14432
- i(e), n = r.filter((e) => I.fields.get(e) || I.files?.get(e)), n.length === 0 && (n = Mu(I));
14433
- } else n = Mu(I);
14432
+ i(e), n = r.filter((e) => F.fields.get(e) || F.files?.get(e)), n.length === 0 && (n = Mu(F));
14433
+ } else n = Mu(F);
14434
14434
  return n.map((e) => {
14435
- if (I.files?.get(e)) return {
14435
+ if (F.files?.get(e)) return {
14436
14436
  key: e,
14437
- label: xe(I, e, s?.entities),
14437
+ label: xe(F, e, s?.entities),
14438
14438
  kind: "file",
14439
14439
  readOnly: !re
14440
14440
  };
14441
- let t = I.fields.get(e), n = re && !t.primary && !t.auto && !t.ref && t.files?.mode !== "rich_text_inline";
14441
+ let t = F.fields.get(e), n = re && !t.primary && !t.auto && !t.ref && t.files?.mode !== "rich_text_inline";
14442
14442
  return {
14443
14443
  key: e,
14444
14444
  label: Xe(t, e, s?.entities),
@@ -14450,15 +14450,15 @@ function Wu({ screenCode: e }) {
14450
14450
  }, [
14451
14451
  mt,
14452
14452
  ft,
14453
- I,
14454
- P,
14453
+ F,
14454
+ N,
14455
14455
  s?.entities,
14456
14456
  s?.screens,
14457
14457
  re
14458
- ]), Ut = q(() => I?.actions ? I.actions : {}, [I?.actions]), Wt = G(async (e, n, r) => {
14459
- let i = I?.fields.names().find((e) => I.fields.get(e)?.primary), a = i && ft ? [L(ft[i])] : void 0;
14458
+ ]), Ut = q(() => F?.actions ? F.actions : {}, [F?.actions]), Wt = G(async (e, n, r) => {
14459
+ let i = F?.fields.names().find((e) => F.fields.get(e)?.primary), a = i && ft ? [I(ft[i])] : void 0;
14460
14460
  return j(n.entity ? `${n.entity}.${e}` : e, t(r, a));
14461
- }, [I, ft]), Gt = G(async () => {
14461
+ }, [F, ft]), Gt = G(async () => {
14462
14462
  if (!l || l.ids.length === 0) return;
14463
14463
  u(null);
14464
14464
  let e = await Promise.allSettled(l.ids.map((e) => it.mutateAsync(e))), t = e.filter((e) => e.status === "rejected").length;
@@ -14472,18 +14472,18 @@ function Wu({ screenCode: e }) {
14472
14472
  }), $.warning(`${t} of ${l.ids.length} deletes failed`);
14473
14473
  }
14474
14474
  }, [l, it]);
14475
- if (!P || !I) return null;
14476
- let Kt = I.display, qt = W(P.display?.name) || W(Kt.name), Jt = P.display?.icon || Kt.icon, Yt = St.map((e) => fe(I, e)), Xt = [];
14475
+ if (!N || !F) return null;
14476
+ let Kt = F.display, qt = W(N.display?.name) || W(Kt.name), Jt = N.display?.icon || Kt.icon, Yt = St.map((e) => fe(F, e)), Xt = [];
14477
14477
  if (xt.length > 0) {
14478
14478
  let e = /* @__PURE__ */ new Map();
14479
14479
  for (let t of gt) e.set(lt(t), t);
14480
14480
  Xt = xt.map((t) => e.get(t)).filter((e) => e !== void 0);
14481
14481
  }
14482
14482
  let Zt = {
14483
- entity: I,
14484
- entityCode: te ?? "",
14485
- screen: P,
14486
- screenRoute: P.route,
14483
+ entity: F,
14484
+ entityCode: ne ?? "",
14485
+ screen: N,
14486
+ screenRoute: N.route,
14487
14487
  selectedRows: Xt,
14488
14488
  selectedIds: Yt,
14489
14489
  locale: c,
@@ -14494,7 +14494,7 @@ function Wu({ screenCode: e }) {
14494
14494
  }),
14495
14495
  runActionApi: (e, t) => j(e, t)
14496
14496
  }, Qt = (e, t, n) => {
14497
- let r = H && e.original[I.soft_delete] != null, i = e.getIsSelected(), a = Mt && t % 2 == 1, o = i ? "var(--row-selected-bg)" : a ? "var(--surface-2)" : "transparent";
14497
+ let r = H && e.original[F.soft_delete] != null, i = e.getIsSelected(), a = Mt && t % 2 == 1, o = i ? "var(--row-selected-bg)" : a ? "var(--surface-2)" : "transparent";
14498
14498
  return /* @__PURE__ */ Z("tr", {
14499
14499
  "data-index": n ? t : void 0,
14500
14500
  ref: n ? (e) => Pt.measureElement(e) : void 0,
@@ -14546,8 +14546,8 @@ function Wu({ screenCode: e }) {
14546
14546
  countPending: qe && !Je,
14547
14547
  loaded: gt.length,
14548
14548
  toolbarActions: se,
14549
- screenActionLayout: P.action_layout,
14550
- entityActionLayout: I.action_layout,
14549
+ screenActionLayout: N.action_layout,
14550
+ entityActionLayout: F.action_layout,
14551
14551
  selectedIds: xt,
14552
14552
  data: gt,
14553
14553
  rowKey: lt,
@@ -14586,7 +14586,7 @@ function Wu({ screenCode: e }) {
14586
14586
  value: U,
14587
14587
  onChange: Ft,
14588
14588
  placeholder: `Search ${qt.toLowerCase()}…`,
14589
- prefix: /* @__PURE__ */ Z(N.search, { size: 13 })
14589
+ prefix: /* @__PURE__ */ Z(M.search, { size: 13 })
14590
14590
  }), /* @__PURE__ */ Z("span", {
14591
14591
  style: {
14592
14592
  position: "absolute",
@@ -14599,7 +14599,7 @@ function Wu({ screenCode: e }) {
14599
14599
  })]
14600
14600
  }),
14601
14601
  /* @__PURE__ */ Q(V, {
14602
- icon: /* @__PURE__ */ Z(N.filter, { size: 13 }),
14602
+ icon: /* @__PURE__ */ Z(M.filter, { size: 13 }),
14603
14603
  onClick: () => h(!0),
14604
14604
  active: C > 0,
14605
14605
  children: ["Filters", C > 0 && /* @__PURE__ */ Z(B, {
@@ -14610,7 +14610,7 @@ function Wu({ screenCode: e }) {
14610
14610
  })]
14611
14611
  }),
14612
14612
  /* @__PURE__ */ Z(Eu, {
14613
- availableColumns: P.columns ?? [],
14613
+ availableColumns: N.columns ?? [],
14614
14614
  visibleColumns: Me,
14615
14615
  onToggle: (e) => {
14616
14616
  let t = new URLSearchParams(i), n = Me.includes(e) ? Me.filter((t) => t !== e) : [...Me, e];
@@ -14622,18 +14622,18 @@ function Wu({ screenCode: e }) {
14622
14622
  },
14623
14623
  onShowAll: () => {
14624
14624
  let e = new URLSearchParams(i);
14625
- e.set("columns", (P.columns ?? []).join(",")), o(e);
14625
+ e.set("columns", (N.columns ?? []).join(",")), o(e);
14626
14626
  },
14627
14627
  columnLabel: (e) => {
14628
14628
  if (e.startsWith("$status.")) {
14629
- let t = e.slice(8), n = I.status_groups?.[t];
14629
+ let t = e.slice(8), n = F.status_groups?.[t];
14630
14630
  return n ? W(n.name) || t : e;
14631
14631
  }
14632
14632
  if (e.startsWith("$property.")) {
14633
- let t = e.slice(10), n = I.properties?.[t];
14633
+ let t = e.slice(10), n = F.properties?.[t];
14634
14634
  return n ? W(n.name) || t : e;
14635
14635
  }
14636
- return xe(I, e, s?.entities);
14636
+ return xe(F, e, s?.entities);
14637
14637
  }
14638
14638
  }),
14639
14639
  /* @__PURE__ */ Z("span", { style: {
@@ -14642,7 +14642,7 @@ function Wu({ screenCode: e }) {
14642
14642
  background: "var(--divider)"
14643
14643
  } }),
14644
14644
  /* @__PURE__ */ Z(z, {
14645
- icon: /* @__PURE__ */ Z(N.grid, { size: 14 }),
14645
+ icon: /* @__PURE__ */ Z(M.grid, { size: 14 }),
14646
14646
  title: "Density",
14647
14647
  active: jt !== "compact",
14648
14648
  onClick: () => {
@@ -14655,7 +14655,7 @@ function Wu({ screenCode: e }) {
14655
14655
  "data-testid": "refresh-spinner",
14656
14656
  style: { display: "inline-flex" },
14657
14657
  children: /* @__PURE__ */ Z(v, { size: 14 })
14658
- }) : /* @__PURE__ */ Z(N.refresh, { size: 14 }),
14658
+ }) : /* @__PURE__ */ Z(M.refresh, { size: 14 }),
14659
14659
  title: "Refresh",
14660
14660
  disabled: Be || Ve,
14661
14661
  onClick: tt
@@ -14674,15 +14674,15 @@ function Wu({ screenCode: e }) {
14674
14674
  me && /* @__PURE__ */ Z(V, {
14675
14675
  kind: "ghost",
14676
14676
  size: "sm",
14677
- icon: Z(he ? N.eyeOff : N.eye, { size: 12 }),
14677
+ icon: Z(he ? M.eyeOff : M.eye, { size: 12 }),
14678
14678
  onClick: It,
14679
14679
  active: he,
14680
14680
  children: he ? "Hide deleted" : "Show deleted"
14681
14681
  }),
14682
- te && I && /* @__PURE__ */ Z(ml, {
14683
- entityCode: te,
14684
- entity: I,
14685
- screen: P,
14682
+ ne && F && /* @__PURE__ */ Z(ml, {
14683
+ entityCode: ne,
14684
+ entity: F,
14685
+ screen: N,
14686
14686
  viewState: {
14687
14687
  screenCode: e,
14688
14688
  jsonFilters: S,
@@ -14709,14 +14709,14 @@ function Wu({ screenCode: e }) {
14709
14709
  onChipClick: () => h(!0),
14710
14710
  fieldLabel: (e) => {
14711
14711
  if (e.startsWith("$status.")) {
14712
- let t = e.slice(8), n = I.status_groups?.[t];
14712
+ let t = e.slice(8), n = F.status_groups?.[t];
14713
14713
  return n ? W(n.name) || t : e;
14714
14714
  }
14715
14715
  if (e.startsWith("$property.")) {
14716
- let t = e.slice(10), n = I.properties?.[t];
14716
+ let t = e.slice(10), n = F.properties?.[t];
14717
14717
  return n ? W(n.name) || t : e;
14718
14718
  }
14719
- let t = I.fields.get(e);
14719
+ let t = F.fields.get(e);
14720
14720
  return t ? Xe(t, e, s?.entities) : e;
14721
14721
  }
14722
14722
  })
@@ -14735,7 +14735,7 @@ function Wu({ screenCode: e }) {
14735
14735
  children: "Retry"
14736
14736
  })
14737
14737
  })
14738
- }) : Be ? /* @__PURE__ */ Z(wl, { cols: P.columns?.length ?? 4 }) : He ? /* @__PURE__ */ Z("div", {
14738
+ }) : Be ? /* @__PURE__ */ Z(wl, { cols: N.columns?.length ?? 4 }) : He ? /* @__PURE__ */ Z("div", {
14739
14739
  style: { padding: "0 20px" },
14740
14740
  children: /* @__PURE__ */ Z(vl, {
14741
14741
  icon: "alert-circle",
@@ -14757,7 +14757,7 @@ function Wu({ screenCode: e }) {
14757
14757
  target: "_blank",
14758
14758
  rel: "noopener noreferrer",
14759
14759
  children: "Learn more"
14760
- })] })] }) : ne ? `Create your first ${W(Kt.name).toLowerCase()} to get started` : void 0, /* @__PURE__ */ Z(vl, {
14760
+ })] })] }) : L ? `Create your first ${W(Kt.name).toLowerCase()} to get started` : void 0, /* @__PURE__ */ Z(vl, {
14761
14761
  icon: Jt,
14762
14762
  title: a,
14763
14763
  description: o
@@ -14804,7 +14804,7 @@ function Wu({ screenCode: e }) {
14804
14804
  background: "var(--surface-2)"
14805
14805
  },
14806
14806
  children: e.headers.map((e) => {
14807
- let t = zu(e.id, I), n = e.column.getIsSorted(), r = e.id === "_select", i = e.id === "_actions", a = n ? Oe.findIndex((t) => t.field === e.id) + 1 : 0, o = Oe.length > 1 && a > 0, s = a > 0, c = Oe.length < 5, l = t ? e.column.getToggleSortingHandler() : void 0;
14807
+ let t = zu(e.id, F), n = e.column.getIsSorted(), r = e.id === "_select", i = e.id === "_actions", a = n ? Oe.findIndex((t) => t.field === e.id) + 1 : 0, o = Oe.length > 1 && a > 0, s = a > 0, c = Oe.length < 5, l = t ? e.column.getToggleSortingHandler() : void 0;
14808
14808
  return /* @__PURE__ */ Z("th", {
14809
14809
  onClick: t ? (t) => {
14810
14810
  if (t.shiftKey) {
@@ -14849,7 +14849,7 @@ function Wu({ screenCode: e }) {
14849
14849
  alignItems: "center",
14850
14850
  lineHeight: 0
14851
14851
  },
14852
- children: [n === "asc" ? /* @__PURE__ */ Z(N.arrowUp, { size: 11 }) : n === "desc" ? /* @__PURE__ */ Z(N.arrowDown, { size: 11 }) : /* @__PURE__ */ Z(N.sort, {
14852
+ children: [n === "asc" ? /* @__PURE__ */ Z(M.arrowUp, { size: 11 }) : n === "desc" ? /* @__PURE__ */ Z(M.arrowDown, { size: 11 }) : /* @__PURE__ */ Z(M.sort, {
14853
14853
  size: 11,
14854
14854
  style: { opacity: .35 }
14855
14855
  }), n && ke.get(e.id) === "first" ? /* @__PURE__ */ Z("span", {
@@ -14977,7 +14977,7 @@ function Wu({ screenCode: e }) {
14977
14977
  children: [
14978
14978
  /* @__PURE__ */ Z(z, {
14979
14979
  size: 22,
14980
- icon: /* @__PURE__ */ Z(N.left, { size: 12 }),
14980
+ icon: /* @__PURE__ */ Z(M.left, { size: 12 }),
14981
14981
  onClick: () => Lt(we - 1),
14982
14982
  disabled: we <= 1
14983
14983
  }),
@@ -14992,7 +14992,7 @@ function Wu({ screenCode: e }) {
14992
14992
  }),
14993
14993
  /* @__PURE__ */ Z(z, {
14994
14994
  size: 22,
14995
- icon: /* @__PURE__ */ Z(N.right, { size: 12 }),
14995
+ icon: /* @__PURE__ */ Z(M.right, { size: 12 }),
14996
14996
  onClick: () => Lt(we + 1),
14997
14997
  disabled: vt === void 0 ? !yt : we >= vt
14998
14998
  })
@@ -15007,7 +15007,7 @@ function Wu({ screenCode: e }) {
15007
15007
  onClose: () => h(!1),
15008
15008
  filters: S,
15009
15009
  onApply: w,
15010
- availableFields: uu(P, I, s?.entities)
15010
+ availableFields: uu(N, F, s?.entities)
15011
15011
  }),
15012
15012
  /* @__PURE__ */ Z(fu, {
15013
15013
  open: g,
@@ -15015,7 +15015,7 @@ function Wu({ screenCode: e }) {
15015
15015
  onClose: () => _(!1),
15016
15016
  onSave: async (t) => {
15017
15017
  if (!E?.id || !D?.id) return;
15018
- let n = L((await ot.mutateAsync({
15018
+ let n = I((await ot.mutateAsync({
15019
15019
  tenant_id: D.id,
15020
15020
  screen_code: e,
15021
15021
  user_id: E.id,
@@ -15045,16 +15045,16 @@ function Wu({ screenCode: e }) {
15045
15045
  xt.length > 0 && /* @__PURE__ */ Z(mu, {
15046
15046
  selectedIds: xt,
15047
15047
  floatbarActions: ce,
15048
- screenActionLayout: P.action_layout,
15049
- entityActionLayout: I.action_layout,
15048
+ screenActionLayout: N.action_layout,
15049
+ entityActionLayout: F.action_layout,
15050
15050
  data: gt,
15051
15051
  rowKey: lt,
15052
- entityCode: te,
15052
+ entityCode: ne,
15053
15053
  onClear: () => f({}),
15054
15054
  onActionSuccess: () => f({}),
15055
15055
  widgetContext: Zt
15056
15056
  }),
15057
- y && I && /* @__PURE__ */ Q("div", {
15057
+ y && F && /* @__PURE__ */ Q("div", {
15058
15058
  style: {
15059
15059
  position: "fixed",
15060
15060
  top: y.y,
@@ -15072,25 +15072,25 @@ function Wu({ screenCode: e }) {
15072
15072
  width: 200
15073
15073
  },
15074
15074
  children: [
15075
- mt && /* @__PURE__ */ Z(F, {
15076
- icon: /* @__PURE__ */ Z(N.eye, { size: 13 }),
15075
+ mt && /* @__PURE__ */ Z(P, {
15076
+ icon: /* @__PURE__ */ Z(M.eye, { size: 13 }),
15077
15077
  onClick: () => {
15078
15078
  pt(y.row), x(null);
15079
15079
  },
15080
15080
  children: "Quick peek"
15081
15081
  }),
15082
- /* @__PURE__ */ Z(F, {
15083
- icon: /* @__PURE__ */ Z(N.external, { size: 13 }),
15082
+ /* @__PURE__ */ Z(P, {
15083
+ icon: /* @__PURE__ */ Z(M.external, { size: 13 }),
15084
15084
  onClick: () => {
15085
15085
  Bt(y.row), x(null);
15086
15086
  },
15087
15087
  children: "Open"
15088
15088
  }),
15089
- ie && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(F, { divider: !0 }), /* @__PURE__ */ Z(F, {
15090
- icon: /* @__PURE__ */ Z(N.trash, { size: 13 }),
15089
+ ie && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(P, { divider: !0 }), /* @__PURE__ */ Z(P, {
15090
+ icon: /* @__PURE__ */ Z(M.trash, { size: 13 }),
15091
15091
  danger: !0,
15092
15092
  onClick: () => {
15093
- let e = I.fields.names()?.find((e) => I.fields.get(e)?.primary), t = e ? L(y.row[e]) : "";
15093
+ let e = F.fields.names()?.find((e) => F.fields.get(e)?.primary), t = e ? I(y.row[e]) : "";
15094
15094
  x(null), t && u({ ids: [t] });
15095
15095
  },
15096
15096
  children: "Delete"
@@ -15108,26 +15108,26 @@ function Wu({ screenCode: e }) {
15108
15108
  }
15109
15109
  })]
15110
15110
  }),
15111
- mt && ft && I && /* @__PURE__ */ Z(Vl, {
15112
- entity: I,
15113
- entityCode: te,
15111
+ mt && ft && F && /* @__PURE__ */ Z(Vl, {
15112
+ entity: F,
15113
+ entityCode: ne,
15114
15114
  record: ft,
15115
15115
  title: (() => {
15116
- let e = P.columns?.find((e) => !e.startsWith("$status.") && !e.startsWith("$property."));
15117
- return e ? L(ft[e] ?? W(I.display.name)) : W(I.display.name);
15116
+ let e = N.columns?.find((e) => !e.startsWith("$status.") && !e.startsWith("$property."));
15117
+ return e ? I(ft[e] ?? W(F.display.name)) : W(F.display.name);
15118
15118
  })(),
15119
15119
  recordId: (() => {
15120
- let e = I.fields.names()?.find((e) => I.fields.get(e)?.primary);
15121
- return e ? L(ft[e]) : void 0;
15120
+ let e = F.fields.names()?.find((e) => F.fields.get(e)?.primary);
15121
+ return e ? I(ft[e]) : void 0;
15122
15122
  })(),
15123
15123
  fields: Ht,
15124
- screen: P,
15124
+ screen: N,
15125
15125
  actions: Ut,
15126
15126
  executeAction: Wt,
15127
15127
  onClose: () => {
15128
- if (I && ft) {
15129
- let e = I.fields.names()?.find((e) => I.fields.get(e)?.primary);
15130
- e && Kl(L(ft[e]));
15128
+ if (F && ft) {
15129
+ let e = F.fields.names()?.find((e) => F.fields.get(e)?.primary);
15130
+ e && Kl(I(ft[e]));
15131
15131
  }
15132
15132
  pt(null);
15133
15133
  },
@@ -15137,15 +15137,15 @@ function Wu({ screenCode: e }) {
15137
15137
  },
15138
15138
  onSave: (e) => {
15139
15139
  pt(e);
15140
- let t = I.fields.names()?.find((e) => I.fields.get(e)?.primary);
15140
+ let t = F.fields.names()?.find((e) => F.fields.get(e)?.primary);
15141
15141
  if (!t) return;
15142
- let n = L(e[t]), r = {};
15143
- for (let t of I.fields.names()) {
15144
- let n = Ye(I, e, t), i = Ye(I, ft, t), a = ze(I, t, n), o = ze(I, t, i);
15142
+ let n = I(e[t]), r = {};
15143
+ for (let t of F.fields.names()) {
15144
+ let n = Ye(F, e, t), i = Ye(F, ft, t), a = ze(F, t, n), o = ze(F, t, i);
15145
15145
  (a === "" ? null : a) !== (o === "" || o === void 0 ? null : o) && (r[t] = a);
15146
15146
  }
15147
15147
  let i = Ge({
15148
- entity: I,
15148
+ entity: F,
15149
15149
  formData: e,
15150
15150
  record: ft,
15151
15151
  isNew: !1
@@ -15238,7 +15238,7 @@ function qu({ entityCode: e, recordId: t, assocKey: n, association: r, schema: i
15238
15238
  s,
15239
15239
  t
15240
15240
  ],
15241
- queryFn: () => P(s, [t])
15241
+ queryFn: () => N(s, [t])
15242
15242
  }), u = c?.target_entity ?? r.target, d = i.entities[u], f = q(() => c?.ids ?? [], [c?.ids]), p = q(() => d?.fields.names().find((e) => d.fields.get(e)?.primary) ?? "id", [d]), m = q(() => f.slice(0, 50), [f]), { data: h, isLoading: g } = un({
15243
15243
  queryKey: [
15244
15244
  "association-records",
@@ -15318,7 +15318,7 @@ function qu({ entityCode: e, recordId: t, assocKey: n, association: r, schema: i
15318
15318
  textAlign: "center"
15319
15319
  },
15320
15320
  children: /* @__PURE__ */ Q(V, {
15321
- icon: /* @__PURE__ */ Z(N.external, { size: 12 }),
15321
+ icon: /* @__PURE__ */ Z(M.external, { size: 12 }),
15322
15322
  onClick: b,
15323
15323
  children: [
15324
15324
  "View all ",
@@ -15334,7 +15334,7 @@ function qu({ entityCode: e, recordId: t, assocKey: n, association: r, schema: i
15334
15334
  },
15335
15335
  children: /* @__PURE__ */ Z(V, {
15336
15336
  kind: "ghost",
15337
- icon: /* @__PURE__ */ Z(N.external, { size: 12 }),
15337
+ icon: /* @__PURE__ */ Z(M.external, { size: 12 }),
15338
15338
  onClick: b,
15339
15339
  children: "Open in list view"
15340
15340
  })
@@ -15570,7 +15570,7 @@ function id({ config: e, ctx: t }) {
15570
15570
  ...t,
15571
15571
  withinCard: !0,
15572
15572
  ...a ? { columns: a } : null
15573
- }, u = o ? N[o] : void 0, d = u ? /* @__PURE__ */ Z(u, { size: 14 }) : void 0, f = s ? {
15573
+ }, u = o ? M[o] : void 0, d = u ? /* @__PURE__ */ Z(u, { size: 14 }) : void 0, f = s ? {
15574
15574
  text: W(s.text),
15575
15575
  tone: s.tone,
15576
15576
  dot: s.dot
@@ -15837,7 +15837,7 @@ function Sd({ config: e, parentEntity: t, parentId: n, schema: r }) {
15837
15837
  /* @__PURE__ */ Z(V, {
15838
15838
  type: "submit",
15839
15839
  kind: "primary",
15840
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
15840
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
15841
15841
  disabled: s || !l,
15842
15842
  children: "Add"
15843
15843
  }),
@@ -15917,7 +15917,7 @@ function Cd({ config: e, parentEntity: t, parentId: n, schema: r }) {
15917
15917
  "data-testid": "children-refresh-spinner",
15918
15918
  style: { display: "inline-flex" },
15919
15919
  children: /* @__PURE__ */ Z(v, { size: 13 })
15920
- }) : /* @__PURE__ */ Z(N.refresh, { size: 13 }),
15920
+ }) : /* @__PURE__ */ Z(M.refresh, { size: 13 }),
15921
15921
  title: "Refresh",
15922
15922
  size: 24,
15923
15923
  disabled: u,
@@ -15982,9 +15982,9 @@ function Cd({ config: e, parentEntity: t, parentId: n, schema: r }) {
15982
15982
  children: t ? Xe(t, e, r.entities) : e
15983
15983
  }, e);
15984
15984
  }) }) }), /* @__PURE__ */ Z("tbody", { children: f.map((e, t) => {
15985
- let n = b ? L(e[b]) : "", r = g && y && n ? y.replace(/:\w+/, n) : void 0;
15985
+ let n = b ? I(e[b]) : "", r = g && y && n ? y.replace(/:\w+/, n) : void 0;
15986
15986
  return /* @__PURE__ */ Z("tr", { children: h.map((t) => {
15987
- let n = t === _, i = x.get(t), a = i ? i(e[t], e) : L(e[t]);
15987
+ let n = t === _, i = x.get(t), a = i ? i(e[t], e) : I(e[t]);
15988
15988
  return /* @__PURE__ */ Z("td", {
15989
15989
  title: typeof a == "string" ? a : void 0,
15990
15990
  style: qe,
@@ -16000,7 +16000,7 @@ function Cd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16000
16000
  children: a
16001
16001
  }) : a
16002
16002
  }, t);
16003
- }) }, L(e.id ?? t));
16003
+ }) }, I(e.id ?? t));
16004
16004
  }) })]
16005
16005
  })
16006
16006
  })
@@ -16100,7 +16100,7 @@ function wd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16100
16100
  record: e,
16101
16101
  refs: u,
16102
16102
  locale: a
16103
- }) : p && e[p] != null ? L(e[p]) : null)
16103
+ }) : p && e[p] != null ? I(e[p]) : null)
16104
16104
  }), d.length > 1 && (() => {
16105
16105
  let t = d.slice(1, 3).filter((t) => e[t] != null);
16106
16106
  return t.length === 0 ? null : /* @__PURE__ */ Z("div", {
@@ -16123,7 +16123,7 @@ function wd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16123
16123
  });
16124
16124
  })()]
16125
16125
  })
16126
- }, L(e.id ?? t)))
16126
+ }, I(e.id ?? t)))
16127
16127
  })] });
16128
16128
  }
16129
16129
  //#endregion
@@ -16223,7 +16223,7 @@ function Td({ config: e, parentEntity: t, parentId: n, schema: r }) {
16223
16223
  record: t,
16224
16224
  refs: u,
16225
16225
  locale: a
16226
- }) : L(t[m])
16226
+ }) : I(t[m])
16227
16227
  })]
16228
16228
  }), v.length > 0 && /* @__PURE__ */ Z("div", {
16229
16229
  style: {
@@ -16266,7 +16266,7 @@ function Td({ config: e, parentEntity: t, parentId: n, schema: r }) {
16266
16266
  }, n) : null;
16267
16267
  })
16268
16268
  })]
16269
- }, L(t.id ?? n)))
16269
+ }, I(t.id ?? n)))
16270
16270
  })] });
16271
16271
  }
16272
16272
  //#endregion
@@ -16486,7 +16486,7 @@ function Nd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16486
16486
  }), /* @__PURE__ */ Z(V, {
16487
16487
  type: "submit",
16488
16488
  kind: "primary",
16489
- icon: /* @__PURE__ */ Z(N.plus, { size: 13 }),
16489
+ icon: /* @__PURE__ */ Z(M.plus, { size: 13 }),
16490
16490
  disabled: s || !l,
16491
16491
  children: "Add"
16492
16492
  })]
@@ -16510,7 +16510,7 @@ function Nd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16510
16510
  var Pd = 80, Fd = 200;
16511
16511
  function Id(e) {
16512
16512
  let t = e.id;
16513
- return t == null ? "" : L(t);
16513
+ return t == null ? "" : I(t);
16514
16514
  }
16515
16515
  function Ld(e) {
16516
16516
  return e.__optimistic === !0;
@@ -16588,8 +16588,8 @@ function Rd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16588
16588
  ref: y,
16589
16589
  "aria-hidden": "true",
16590
16590
  style: { height: 1 }
16591
- }), M;
16592
- if (d) M = /* @__PURE__ */ Z("div", {
16591
+ }), te;
16592
+ if (d) te = /* @__PURE__ */ Z("div", {
16593
16593
  style: {
16594
16594
  fontSize: 12.5,
16595
16595
  color: "var(--danger)",
@@ -16597,7 +16597,7 @@ function Rd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16597
16597
  },
16598
16598
  children: "Failed to load."
16599
16599
  });
16600
- else if (u) M = /* @__PURE__ */ Q("div", {
16600
+ else if (u) te = /* @__PURE__ */ Q("div", {
16601
16601
  style: {
16602
16602
  display: "flex",
16603
16603
  flexDirection: "column",
@@ -16614,7 +16614,7 @@ function Rd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16614
16614
  borderRadius: 8
16615
16615
  } })]
16616
16616
  });
16617
- else if (h.length === 0) M = /* @__PURE__ */ Q(X, { children: [ee, /* @__PURE__ */ Z("div", {
16617
+ else if (h.length === 0) te = /* @__PURE__ */ Q(X, { children: [ee, /* @__PURE__ */ Z("div", {
16618
16618
  style: {
16619
16619
  fontSize: 12.5,
16620
16620
  color: "var(--text-3)",
@@ -16670,7 +16670,7 @@ function Rd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16670
16670
  }), e.rows.map(({ row: e, idx: t }) => a(e, t))]
16671
16671
  }, `day-${e.key}`));
16672
16672
  } else c = h.map((e, t) => a(e, t));
16673
- M = /* @__PURE__ */ Q(X, { children: [
16673
+ te = /* @__PURE__ */ Q(X, { children: [
16674
16674
  ee,
16675
16675
  j,
16676
16676
  c
@@ -16712,7 +16712,7 @@ function Rd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16712
16712
  flexDirection: "column",
16713
16713
  gap: 8
16714
16714
  },
16715
- children: M
16715
+ children: te
16716
16716
  }),
16717
16717
  /* @__PURE__ */ Z(Nd, {
16718
16718
  config: e,
@@ -16727,7 +16727,7 @@ function Rd({ config: e, parentEntity: t, parentId: n, schema: r }) {
16727
16727
  flexDirection: "column",
16728
16728
  gap: 8
16729
16729
  },
16730
- children: M
16730
+ children: te
16731
16731
  }), /* @__PURE__ */ Z(Nd, {
16732
16732
  config: e,
16733
16733
  parentEntity: t,
@@ -16773,7 +16773,7 @@ function zd({ row: e, rowId: t, childEntity: n, entityCode: i, parentEntity: a,
16773
16773
  ...n,
16774
16774
  [e]: t
16775
16775
  }));
16776
- }, []), D = s?.time_field, O = s?.type_field, k = s?.summary_field, A = s?.content_field, j = s?.author_field, ee = s?.direction_field, M = s?.intent_field;
16776
+ }, []), D = s?.time_field, O = s?.type_field, k = s?.summary_field, A = s?.content_field, j = s?.author_field, ee = s?.direction_field, te = s?.intent_field;
16777
16777
  return u ? /* @__PURE__ */ Q("div", {
16778
16778
  style: {
16779
16779
  borderRadius: 10,
@@ -16813,13 +16813,13 @@ function zd({ row: e, rowId: t, childEntity: n, entityCode: i, parentEntity: a,
16813
16813
  children: [/* @__PURE__ */ Z(V, {
16814
16814
  kind: "primary",
16815
16815
  size: "xs",
16816
- icon: S.isPending ? /* @__PURE__ */ Z(v, { size: 12 }) : /* @__PURE__ */ Z(N.check, { size: 12 }),
16816
+ icon: S.isPending ? /* @__PURE__ */ Z(v, { size: 12 }) : /* @__PURE__ */ Z(M.check, { size: 12 }),
16817
16817
  onClick: () => S.mutate(y),
16818
16818
  disabled: S.isPending,
16819
16819
  children: S.isPending ? "Saving…" : "Save"
16820
16820
  }), /* @__PURE__ */ Z(V, {
16821
16821
  size: "xs",
16822
- icon: /* @__PURE__ */ Z(N.x, { size: 12 }),
16822
+ icon: /* @__PURE__ */ Z(M.x, { size: 12 }),
16823
16823
  onClick: () => {
16824
16824
  b({}), f();
16825
16825
  },
@@ -16880,13 +16880,13 @@ function zd({ row: e, rowId: t, childEntity: n, entityCode: i, parentEntity: a,
16880
16880
  value: e[ee],
16881
16881
  field: n.fields.get(ee)
16882
16882
  }),
16883
- M && e[M] != null && n.fields.get(M) && /* @__PURE__ */ Z(B, {
16883
+ te && e[te] != null && n.fields.get(te) && /* @__PURE__ */ Z(B, {
16884
16884
  tone: "slate",
16885
16885
  size: "xs",
16886
16886
  children: H({
16887
- field: n.fields.get(M),
16888
- fieldName: M,
16889
- value: e[M],
16887
+ field: n.fields.get(te),
16888
+ fieldName: te,
16889
+ value: e[te],
16890
16890
  mode: "display",
16891
16891
  record: e,
16892
16892
  refs: l,
@@ -16915,12 +16915,12 @@ function zd({ row: e, rowId: t, childEntity: n, entityCode: i, parentEntity: a,
16915
16915
  },
16916
16916
  children: [/* @__PURE__ */ Z(z, {
16917
16917
  size: 22,
16918
- icon: /* @__PURE__ */ Z(N.edit, { size: 11 }),
16918
+ icon: /* @__PURE__ */ Z(M.edit, { size: 11 }),
16919
16919
  onClick: w,
16920
16920
  title: "Edit"
16921
16921
  }), /* @__PURE__ */ Z(z, {
16922
16922
  size: 22,
16923
- icon: /* @__PURE__ */ Z(N.trash, { size: 11 }),
16923
+ icon: /* @__PURE__ */ Z(M.trash, { size: 11 }),
16924
16924
  onClick: () => C.mutate(),
16925
16925
  title: "Delete"
16926
16926
  })]
@@ -16964,12 +16964,12 @@ function zd({ row: e, rowId: t, childEntity: n, entityCode: i, parentEntity: a,
16964
16964
  }
16965
16965
  function Bd(e) {
16966
16966
  if (e == null) return "";
16967
- let t = new Date(L(e));
16967
+ let t = new Date(I(e));
16968
16968
  return Number.isNaN(t.getTime()) ? "" : `${t.getFullYear()}-${t.getMonth()}-${t.getDate()}`;
16969
16969
  }
16970
16970
  function Vd(e) {
16971
16971
  if (e == null) return "—";
16972
- let t = new Date(L(e));
16972
+ let t = new Date(I(e));
16973
16973
  if (Number.isNaN(t.getTime())) return "—";
16974
16974
  let n = /* @__PURE__ */ new Date(), r = /* @__PURE__ */ new Date();
16975
16975
  r.setDate(n.getDate() - 1);
@@ -17031,7 +17031,7 @@ function Ud({ value: e, field: t }) {
17031
17031
  background: n ? "var(--accent-soft)" : "var(--info-soft)",
17032
17032
  color: n ? "var(--accent)" : "var(--info)"
17033
17033
  },
17034
- children: [Z(n ? N.arrowUp : N.arrowDown, { size: 10 }), n ? "Out" : "In"]
17034
+ children: [Z(n ? M.arrowUp : M.arrowDown, { size: 10 }), n ? "Out" : "In"]
17035
17035
  });
17036
17036
  }
17037
17037
  function Wd(e, t) {
@@ -17156,7 +17156,7 @@ function Gd({ config: e, childEntity: t, schema: n, rows: r, onChange: i, valida
17156
17156
  record: e,
17157
17157
  refs: o,
17158
17158
  locale: s
17159
- }) : L(e[i])
17159
+ }) : I(e[i])
17160
17160
  }, i) : /* @__PURE__ */ Z("td", {
17161
17161
  style: {
17162
17162
  padding: "4px 4px",
@@ -17177,7 +17177,7 @@ function Gd({ config: e, childEntity: t, schema: n, rows: r, onChange: i, valida
17177
17177
  refs: o,
17178
17178
  compact: !0,
17179
17179
  locale: s
17180
- }) : L(e[i])
17180
+ }) : I(e[i])
17181
17181
  }, i);
17182
17182
  }), /* @__PURE__ */ Z("td", {
17183
17183
  style: {
@@ -17187,12 +17187,12 @@ function Gd({ config: e, childEntity: t, schema: n, rows: r, onChange: i, valida
17187
17187
  },
17188
17188
  children: n ? /* @__PURE__ */ Z(z, {
17189
17189
  size: 24,
17190
- icon: /* @__PURE__ */ Z(N.refresh, { size: 12 }),
17190
+ icon: /* @__PURE__ */ Z(M.refresh, { size: 12 }),
17191
17191
  onClick: () => g(e._key),
17192
17192
  title: "Undo delete"
17193
17193
  }) : /* @__PURE__ */ Z(z, {
17194
17194
  size: 24,
17195
- icon: /* @__PURE__ */ Z(N.trash, { size: 12 }),
17195
+ icon: /* @__PURE__ */ Z(M.trash, { size: 12 }),
17196
17196
  onClick: () => h(e._key),
17197
17197
  title: "Delete row"
17198
17198
  })
@@ -17205,7 +17205,7 @@ function Gd({ config: e, childEntity: t, schema: n, rows: r, onChange: i, valida
17205
17205
  children: /* @__PURE__ */ Z(V, {
17206
17206
  kind: "ghost",
17207
17207
  size: "xs",
17208
- icon: /* @__PURE__ */ Z(N.plus, { size: 12 }),
17208
+ icon: /* @__PURE__ */ Z(M.plus, { size: 12 }),
17209
17209
  onClick: m,
17210
17210
  children: "Add row"
17211
17211
  })
@@ -17395,7 +17395,7 @@ function tf({ label: e, children: t, span: n = !1, required: r, error: i, hint:
17395
17395
  alignItems: "center",
17396
17396
  gap: 4
17397
17397
  },
17398
- children: [h && /* @__PURE__ */ Z(N.warning, { size: 11 }), /* @__PURE__ */ Z("span", { children: h ? i : a })]
17398
+ children: [h && /* @__PURE__ */ Z(M.warning, { size: 11 }), /* @__PURE__ */ Z("span", { children: h ? i : a })]
17399
17399
  })]
17400
17400
  })]
17401
17401
  });
@@ -17435,7 +17435,7 @@ function nf({ fields: e, ctx: t }) {
17435
17435
  row: i,
17436
17436
  variant: "ghost",
17437
17437
  size: "icon"
17438
- }, t)) }) : void 0, C = !!m && Qd.has(m.type), w = i?.[l], T = b === "display" && (m?.copyable || m?.type === "uuid") && w != null && w !== "" ? L(w) : void 0;
17438
+ }, t)) }) : void 0, C = !!m && Qd.has(m.type), w = i?.[l], T = b === "display" && (m?.copyable || m?.type === "uuid") && w != null && w !== "" ? I(w) : void 0;
17439
17439
  return u ? /* @__PURE__ */ Z("div", {
17440
17440
  style: { gridColumn: "1 / -1" },
17441
17441
  children: x
@@ -17575,7 +17575,7 @@ function cf({ stages: e, current: t, selectable: n, onSelect: r, compact: i = !1
17575
17575
  fontSize: 9.5,
17576
17576
  fontWeight: 700
17577
17577
  },
17578
- children: s ? /* @__PURE__ */ Z(N.check, { size: 10 }) : o + 1
17578
+ children: s ? /* @__PURE__ */ Z(M.check, { size: 10 }) : o + 1
17579
17579
  }), /* @__PURE__ */ Z("span", {
17580
17580
  style: {
17581
17581
  overflow: "hidden",
@@ -17781,7 +17781,7 @@ function mf({ errors: e, onJump: t }) {
17781
17781
  marginTop: 1,
17782
17782
  display: "flex"
17783
17783
  },
17784
- children: /* @__PURE__ */ Z(N.warning, { size: 14 })
17784
+ children: /* @__PURE__ */ Z(M.warning, { size: 14 })
17785
17785
  }), /* @__PURE__ */ Q("div", {
17786
17786
  style: {
17787
17787
  flex: 1,
@@ -18040,7 +18040,7 @@ function xf({ icon: e, avatarName: t, title: n, recordId: r, highlights: i, mode
18040
18040
  },
18041
18041
  children: /* @__PURE__ */ Z(z, {
18042
18042
  size: 26,
18043
- icon: /* @__PURE__ */ Z(N.back, { size: 14 }),
18043
+ icon: /* @__PURE__ */ Z(M.back, { size: 14 }),
18044
18044
  title: "Back",
18045
18045
  onClick: c
18046
18046
  })
@@ -18202,7 +18202,7 @@ function kf(e, t) {
18202
18202
  let n = Qe(Ne(e, t));
18203
18203
  if (n.replace(/^\|+|\|+$/g, "")) return n;
18204
18204
  }
18205
- return t.id == null ? crypto.randomUUID() : L(t.id);
18205
+ return t.id == null ? crypto.randomUUID() : I(t.id);
18206
18206
  }
18207
18207
  function Af({ screenCode: e }) {
18208
18208
  return /* @__PURE__ */ Z(Ot, { children: /* @__PURE__ */ Z(jf, { screenCode: e }) });
@@ -18231,7 +18231,7 @@ function jf({ screenCode: e }) {
18231
18231
  u
18232
18232
  ]), S = q(() => {
18233
18233
  if (x) return typeof x == "string" ? x : Qe(x);
18234
- }, [x]), { data: C, isLoading: w } = Gu(d, x), T = Os(d ?? ""), E = ks(d ?? ""), D = As(d ?? ""), O = js(d ?? ""), k = Object.keys(u?.status_groups ?? {}).length > 0, A = C?.data, j = A?.$statuses, ee = A?.$properties, M = r.get("edit") === "true", [P, F] = Y(b || M), [I, L] = Y({}), [ne, R] = Y({}), [re, ie] = Y({}), [ae, se] = Y(void 0), [ce, le] = Y(!1), [B, ue] = Y(void 0), [V, de] = Y({ show: !1 }), [fe, H] = Y(!1), pe = b ? f : m, me = P && pe, he = rr();
18234
+ }, [x]), { data: C, isLoading: w } = Gu(d, x), T = Os(d ?? ""), E = ks(d ?? ""), D = As(d ?? ""), O = js(d ?? ""), k = Object.keys(u?.status_groups ?? {}).length > 0, A = C?.data, j = A?.$statuses, ee = A?.$properties, te = r.get("edit") === "true", [N, P] = Y(b || te), [F, I] = Y({}), [L, R] = Y({}), [re, ie] = Y({}), [ae, se] = Y(void 0), [ce, le] = Y(!1), [B, ue] = Y(void 0), [V, de] = Y({ show: !1 }), [fe, H] = Y(!1), pe = b ? f : m, me = N && pe, he = rr();
18235
18235
  sr(me && !b, he.enabled);
18236
18236
  let [ve, be] = Y(() => {
18237
18237
  let e = parseInt(c?.sidebar_width || "380", 10);
@@ -18257,8 +18257,8 @@ function jf({ screenCode: e }) {
18257
18257
  K(() => {
18258
18258
  if (!De) return;
18259
18259
  let e = ke.current;
18260
- ke.current = De, e && e !== De && P && le(!0);
18261
- }, [P, De]);
18260
+ ke.current = De, e && e !== De && N && le(!0);
18261
+ }, [N, De]);
18262
18262
  let Ae = !!u?.soft_delete, je = Ae && U != null && U[u.soft_delete] != null, Pe = Qt(), { openTab: Fe, updateTabTitle: Ie, findTabByPathname: Le } = Bn();
18263
18263
  K(() => {
18264
18264
  if (!u || v || he.enabled) return;
@@ -18302,8 +18302,8 @@ function jf({ screenCode: e }) {
18302
18302
  return e;
18303
18303
  }, [u, pe]);
18304
18304
  K(() => {
18305
- if (!(!M || !U || !u || !m)) {
18306
- if (P || F(!0), Object.keys(I).length === 0) {
18305
+ if (!(!te || !U || !u || !m)) {
18306
+ if (N || P(!0), Object.keys(F).length === 0) {
18307
18307
  let e = y ? Gl(y) : null;
18308
18308
  e && ge(Ge({
18309
18309
  entity: u,
@@ -18325,7 +18325,7 @@ function jf({ screenCode: e }) {
18325
18325
  }
18326
18326
  let i = Ye(u, U, n);
18327
18327
  t[n] = Me(u, n) ? i ?? null : i ?? "";
18328
- }), L(t);
18328
+ }), I(t);
18329
18329
  }
18330
18330
  if (u.children !== void 0 && u.children.length > 0 && ae === void 0) {
18331
18331
  let e = U.$children;
@@ -18347,7 +18347,7 @@ function jf({ screenCode: e }) {
18347
18347
  }, { replace: !0 });
18348
18348
  }
18349
18349
  }, [
18350
- M,
18350
+ te,
18351
18351
  U,
18352
18352
  Re,
18353
18353
  m,
@@ -18362,14 +18362,14 @@ function jf({ screenCode: e }) {
18362
18362
  u?.children
18363
18363
  ]);
18364
18364
  let Be = G(async () => {
18365
- await s.flushAllDrafts(), b ? n(c?.route?.replace("/:id", "") ?? "/") : (F(!1), L({}), R({}), ie({}), se(void 0), ue(void 0), H(!1));
18365
+ await s.flushAllDrafts(), b ? n(c?.route?.replace("/:id", "") ?? "/") : (P(!1), I({}), R({}), ie({}), se(void 0), ue(void 0), H(!1));
18366
18366
  }, [
18367
18367
  s,
18368
18368
  b,
18369
18369
  c,
18370
18370
  n
18371
18371
  ]), Ve = G((e, t) => {
18372
- L((n) => ({
18372
+ I((n) => ({
18373
18373
  ...n,
18374
18374
  [e]: t
18375
18375
  }));
@@ -18377,39 +18377,51 @@ function jf({ screenCode: e }) {
18377
18377
  if (!c?.route) return "/";
18378
18378
  let e = c.route.split("/");
18379
18379
  return e.pop(), e.join("/") || "/";
18380
- }, [c]), Ue = q(() => !a?.screens || !He || He === "/" ? !1 : Object.values(a.screens).some((e) => e.route === He), [a, He]), We = Ee(), Ke = q(() => {
18380
+ }, [c]), Ue = q(() => !a?.screens || !He || He === "/" ? !1 : Object.values(a.screens).some((e) => e.route === He), [a, He]), We = G(() => {
18381
+ if (!Ue) {
18382
+ n("/");
18383
+ return;
18384
+ }
18385
+ let e = Le(He)?.search ?? "";
18386
+ n(e ? `${He}?${e}` : He);
18387
+ }, [
18388
+ Ue,
18389
+ He,
18390
+ Le,
18391
+ n
18392
+ ]), Ke = Ee(), qe = q(() => {
18381
18393
  if (!u) return {};
18382
18394
  let e = {};
18383
- for (let t of Sf(u, I, b)) Re.has(t) && (e[t] = "Required");
18384
- for (let t of wf(u, I)) Re.has(t) && (e[t] = "Invalid email address");
18395
+ for (let t of Sf(u, F, b)) Re.has(t) && (e[t] = "Required");
18396
+ for (let t of wf(u, F)) Re.has(t) && (e[t] = "Invalid email address");
18385
18397
  return e;
18386
18398
  }, [
18387
18399
  u,
18388
- I,
18400
+ F,
18389
18401
  b,
18390
18402
  Re
18391
- ]), qe = Object.keys(Ke).length > 0, Je = G(() => {
18392
- if (!d || !u || b && !f || !b && !m || (H(!0), qe)) return;
18403
+ ]), Je = Object.keys(qe).length > 0, Ze = G(() => {
18404
+ if (!d || !u || b && !f || !b && !m || (H(!0), Je)) return;
18393
18405
  let e = {}, t = Ge({
18394
18406
  entity: u,
18395
- formData: I,
18407
+ formData: F,
18396
18408
  record: U,
18397
18409
  isNew: b
18398
18410
  }), r = ge(t);
18399
- if (b) for (let [t, n] of Object.entries(I)) {
18411
+ if (b) for (let [t, n] of Object.entries(F)) {
18400
18412
  if (u.files?.has(t)) continue;
18401
18413
  let r = ze(u, t, n);
18402
18414
  r !== "" && r != null && (e[t] = r);
18403
18415
  }
18404
18416
  else {
18405
- for (let [t, n] of Object.entries(I)) {
18417
+ for (let [t, n] of Object.entries(F)) {
18406
18418
  if (u.files?.has(t)) continue;
18407
18419
  let r = U ? Ye(u, U, t) : void 0, i = ze(u, t, n), a = ze(u, t, r);
18408
18420
  (i === "" ? null : i) !== (a === "" || a === void 0 ? null : a) && (e[t] = i);
18409
18421
  }
18410
18422
  De && (e.$row_version = De);
18411
18423
  }
18412
- if (Object.keys(t).length > 0 && (e.$files = t), Object.keys(ne).length > 0 && (e.$statuses = Object.entries(ne).map(([e, t]) => ({
18424
+ if (Object.keys(t).length > 0 && (e.$files = t), Object.keys(L).length > 0 && (e.$statuses = Object.entries(L).map(([e, t]) => ({
18413
18425
  status_group_code: e,
18414
18426
  status_code: t
18415
18427
  }))), Object.keys(re).length > 0 && (e.$properties = Object.entries(re).map(([e, t]) => ({
@@ -18427,11 +18439,11 @@ function jf({ screenCode: e }) {
18427
18439
  Object.keys(t).length > 0 && (e.$children = t);
18428
18440
  }
18429
18441
  if (!b && Object.keys(e).length === 0) {
18430
- F(!1), R({}), ie({}), se(void 0), ue(void 0), H(!1);
18442
+ P(!1), R({}), ie({}), se(void 0), ue(void 0), H(!1);
18431
18443
  return;
18432
18444
  }
18433
18445
  let i = () => {
18434
- F(!1), le(!1), H(!1), R({}), ie({}), se(void 0), ue(void 0);
18446
+ P(!1), le(!1), H(!1), R({}), ie({}), se(void 0), ue(void 0);
18435
18447
  };
18436
18448
  b ? T.mutate(e, { onSuccess: (e) => {
18437
18449
  r.forEach((e) => s.markCommitted(e));
@@ -18454,9 +18466,9 @@ function jf({ screenCode: e }) {
18454
18466
  f,
18455
18467
  m,
18456
18468
  d,
18457
- I,
18458
- qe,
18459
- ne,
18469
+ F,
18470
+ Je,
18471
+ L,
18460
18472
  re,
18461
18473
  ae,
18462
18474
  B,
@@ -18468,12 +18480,12 @@ function jf({ screenCode: e }) {
18468
18480
  U,
18469
18481
  De,
18470
18482
  x
18471
- ]), Ze = G((e, t) => {
18483
+ ]), $e = G((e, t) => {
18472
18484
  se((n) => ({
18473
18485
  ...n ?? {},
18474
18486
  [e]: t
18475
18487
  }));
18476
- }, []), $e = G(() => {
18488
+ }, []), et = G(() => {
18477
18489
  !x || b || !h || D.mutate(x, { onSuccess: () => n(He, { replace: !0 }) });
18478
18490
  }, [
18479
18491
  x,
@@ -18482,14 +18494,14 @@ function jf({ screenCode: e }) {
18482
18494
  D,
18483
18495
  n,
18484
18496
  He
18485
- ]), et = G(() => {
18497
+ ]), tt = G(() => {
18486
18498
  !x || b || !g || O.mutate(x);
18487
18499
  }, [
18488
18500
  x,
18489
18501
  b,
18490
18502
  g,
18491
18503
  O
18492
- ]), tt = q(() => Ef(ae, a), [ae, a]), nt = Object.keys(tt).length > 0;
18504
+ ]), nt = q(() => Ef(ae, a), [ae, a]), rt = Object.keys(nt).length > 0;
18493
18505
  if (!c || !u) return null;
18494
18506
  if (!b && w) return /* @__PURE__ */ Z(Tl, {});
18495
18507
  if (!b && !U) return /* @__PURE__ */ Q("div", {
@@ -18502,8 +18514,8 @@ function jf({ screenCode: e }) {
18502
18514
  marginBottom: 8
18503
18515
  },
18504
18516
  children: [Ue && /* @__PURE__ */ Z(z, {
18505
- icon: /* @__PURE__ */ Z(N.back, { size: 14 }),
18506
- onClick: () => n(He),
18517
+ icon: /* @__PURE__ */ Z(M.back, { size: 14 }),
18518
+ onClick: We,
18507
18519
  title: "Back"
18508
18520
  }), /* @__PURE__ */ Z("h1", {
18509
18521
  style: {
@@ -18519,14 +18531,14 @@ function jf({ screenCode: e }) {
18519
18531
  children: "Record not found."
18520
18532
  })]
18521
18533
  });
18522
- let rt = u.display, it = W(c.display?.name) || W(rt.name), at = ye(U, u), ot = b ? `New ${it}` : at ? String(at) : it, st = T.isPending || E.isPending, ct = {
18534
+ let it = u.display, at = W(c.display?.name) || W(it.name), ot = ye(U, u), st = b ? `New ${at}` : ot ? String(ot) : at, ct = T.isPending || E.isPending, lt = {
18523
18535
  schema: a,
18524
18536
  entity: u,
18525
18537
  entityCode: d,
18526
18538
  recordId: S ?? y ?? "",
18527
18539
  record: me ? {
18528
18540
  ...U ?? {},
18529
- ...I
18541
+ ...F
18530
18542
  } : U ?? {},
18531
18543
  isNew: b,
18532
18544
  mode: me ? "edit" : "display",
@@ -18554,12 +18566,12 @@ function jf({ screenCode: e }) {
18554
18566
  isPropertyPending: !1,
18555
18567
  objectStatuses: (() => {
18556
18568
  let e = j ?? [];
18557
- if (!me || Object.keys(ne).length === 0) return e.length > 0 ? e : void 0;
18558
- let t = e.map((e) => ne[e.group_code] === void 0 ? e : {
18569
+ if (!me || Object.keys(L).length === 0) return e.length > 0 ? e : void 0;
18570
+ let t = e.map((e) => L[e.group_code] === void 0 ? e : {
18559
18571
  ...e,
18560
- status_code: ne[e.group_code]
18572
+ status_code: L[e.group_code]
18561
18573
  });
18562
- for (let [n, r] of Object.entries(ne)) e.some((e) => e.group_code === n) || t.push({
18574
+ for (let [n, r] of Object.entries(L)) e.some((e) => e.group_code === n) || t.push({
18563
18575
  group_code: n,
18564
18576
  status_code: r,
18565
18577
  status_name: {},
@@ -18573,10 +18585,10 @@ function jf({ screenCode: e }) {
18573
18585
  })) : void 0,
18574
18586
  isStatusPending: !1,
18575
18587
  pendingChildren: me ? ae : void 0,
18576
- onChildrenChange: me ? Ze : void 0,
18577
- childValidationErrors: me ? tt : void 0,
18578
- fieldErrors: me && fe ? Ke : void 0
18579
- }, lt = c.sidebar && c.sidebar.length > 0, ut = !b && U ? /* @__PURE__ */ Z(gf, {
18588
+ onChildrenChange: me ? $e : void 0,
18589
+ childValidationErrors: me ? nt : void 0,
18590
+ fieldErrors: me && fe ? qe : void 0
18591
+ }, ut = c.sidebar && c.sidebar.length > 0, dt = !b && U ? /* @__PURE__ */ Z(gf, {
18580
18592
  screen: c,
18581
18593
  entity: u,
18582
18594
  entityCode: d,
@@ -18584,18 +18596,18 @@ function jf({ screenCode: e }) {
18584
18596
  refs: Oe,
18585
18597
  objectStatuses: j,
18586
18598
  schema: a,
18587
- locale: We
18588
- }) : void 0, dt = /* @__PURE__ */ Z(Mf, {
18589
- title: ot,
18599
+ locale: Ke
18600
+ }) : void 0, ft = /* @__PURE__ */ Z(Mf, {
18601
+ title: st,
18590
18602
  recordId: y,
18591
18603
  editing: me,
18592
18604
  isNew: b,
18593
18605
  isSingletonByCaller: !!v,
18594
18606
  isRecordDeleted: je,
18595
- dirty: P,
18596
- isSaving: st,
18597
- hasChildErrors: nt,
18598
- hasFieldErrors: fe && qe,
18607
+ dirty: N,
18608
+ isSaving: ct,
18609
+ hasChildErrors: rt,
18610
+ hasFieldErrors: fe && Je,
18599
18611
  canRestore: g,
18600
18612
  entity: u,
18601
18613
  screen: c,
@@ -18605,13 +18617,13 @@ function jf({ screenCode: e }) {
18605
18617
  id: y,
18606
18618
  listRoute: He,
18607
18619
  listRouteExists: !!Ue,
18608
- highlights: ut,
18609
- onBack: () => n(Ue ? He : "/"),
18620
+ highlights: dt,
18621
+ onBack: We,
18610
18622
  onCancelEdit: Be,
18611
- onSave: Je,
18612
- onRestore: et,
18623
+ onSave: Ze,
18624
+ onRestore: tt,
18613
18625
  isRestoring: O.isPending
18614
- }), ft = je && /* @__PURE__ */ Q("div", {
18626
+ }), pt = je && /* @__PURE__ */ Q("div", {
18615
18627
  style: {
18616
18628
  display: "flex",
18617
18629
  alignItems: "center",
@@ -18624,8 +18636,8 @@ function jf({ screenCode: e }) {
18624
18636
  color: "var(--danger)",
18625
18637
  fontSize: 12.5
18626
18638
  },
18627
- children: [/* @__PURE__ */ Z(N.warning, { size: 14 }), /* @__PURE__ */ Q("span", { children: ["This record was deleted on ", te(String(U[u.soft_delete]))] })]
18628
- }), pt = ce && /* @__PURE__ */ Q("div", {
18639
+ children: [/* @__PURE__ */ Z(M.warning, { size: 14 }), /* @__PURE__ */ Q("span", { children: ["This record was deleted on ", ne(String(U[u.soft_delete]))] })]
18640
+ }), mt = ce && /* @__PURE__ */ Q("div", {
18629
18641
  style: {
18630
18642
  display: "flex",
18631
18643
  alignItems: "center",
@@ -18638,9 +18650,9 @@ function jf({ screenCode: e }) {
18638
18650
  color: "var(--warn)",
18639
18651
  fontSize: 12.5
18640
18652
  },
18641
- children: [/* @__PURE__ */ Z(N.warning, { size: 14 }), /* @__PURE__ */ Z("span", { children: "This record changed on the server while you were viewing or editing it." })]
18642
- }), mt = me && fe && qe && /* @__PURE__ */ Z(mf, {
18643
- errors: Object.entries(Ke).map(([e, t]) => {
18653
+ children: [/* @__PURE__ */ Z(M.warning, { size: 14 }), /* @__PURE__ */ Z("span", { children: "This record changed on the server while you were viewing or editing it." })]
18654
+ }), ht = me && fe && Je && /* @__PURE__ */ Z(mf, {
18655
+ errors: Object.entries(qe).map(([e, t]) => {
18644
18656
  let n = u.fields.get(e);
18645
18657
  return {
18646
18658
  name: e,
@@ -18655,11 +18667,11 @@ function jf({ screenCode: e }) {
18655
18667
  behavior: "smooth"
18656
18668
  }), t.focus?.());
18657
18669
  }
18658
- }), ht = k && !b && !(c.items && c.items.length > 0) && /* @__PURE__ */ Z("div", {
18670
+ }), gt = k && !b && !(c.items && c.items.length > 0) && /* @__PURE__ */ Z("div", {
18659
18671
  className: "mb-4",
18660
18672
  children: /* @__PURE__ */ Z(lf, {
18661
18673
  statusGroups: u.status_groups ?? {},
18662
- objectStatuses: ct.objectStatuses,
18674
+ objectStatuses: lt.objectStatuses,
18663
18675
  onSetStatus: m && me ? (e, t) => R((n) => ({
18664
18676
  ...n,
18665
18677
  [e]: t
@@ -18667,10 +18679,10 @@ function jf({ screenCode: e }) {
18667
18679
  isPending: !1,
18668
18680
  mode: me ? "edit" : "display"
18669
18681
  })
18670
- }), gt = /* @__PURE__ */ Q(X, { children: [
18682
+ }), _t = /* @__PURE__ */ Q(X, { children: [
18671
18683
  c.items && c.items.length > 0 && (U || b) && a && /* @__PURE__ */ Z(ff, {
18672
18684
  nodes: c.items,
18673
- ctx: ct
18685
+ ctx: lt
18674
18686
  }),
18675
18687
  !b && y && d && u.associations && Object.keys(u.associations).length > 0 && a && /* @__PURE__ */ Z(Ku, {
18676
18688
  entityCode: d,
@@ -18685,18 +18697,18 @@ function jf({ screenCode: e }) {
18685
18697
  record: U,
18686
18698
  refs: Oe,
18687
18699
  schema: a,
18688
- locale: We
18700
+ locale: Ke
18689
18701
  })
18690
- ] }), _t = /* @__PURE__ */ Z(Ar, {
18702
+ ] }), vt = /* @__PURE__ */ Z(Ar, {
18691
18703
  open: V.show,
18692
18704
  onOpenChange: (e) => !e && de({ show: !1 }),
18693
- title: `Delete ${it}`,
18694
- description: V.confirmation ? V.confirmation : Ae ? `Are you sure you want to delete this ${it.toLowerCase()}? It can be restored later by an admin.` : `Are you sure you want to delete this ${it.toLowerCase()}? This action cannot be undone.`,
18705
+ title: `Delete ${at}`,
18706
+ description: V.confirmation ? V.confirmation : Ae ? `Are you sure you want to delete this ${at.toLowerCase()}? It can be restored later by an admin.` : `Are you sure you want to delete this ${at.toLowerCase()}? This action cannot be undone.`,
18695
18707
  confirmLabel: "Delete",
18696
- onConfirm: $e,
18708
+ onConfirm: et,
18697
18709
  destructive: !0
18698
18710
  });
18699
- return lt ? /* @__PURE__ */ Q("div", {
18711
+ return ut ? /* @__PURE__ */ Q("div", {
18700
18712
  style: {
18701
18713
  height: "100%",
18702
18714
  display: "flex",
@@ -18718,11 +18730,11 @@ function jf({ screenCode: e }) {
18718
18730
  padding: "14px 20px 8px"
18719
18731
  },
18720
18732
  children: [
18721
- dt,
18722
- pt,
18723
18733
  ft,
18724
18734
  mt,
18725
- ht
18735
+ pt,
18736
+ ht,
18737
+ gt
18726
18738
  ]
18727
18739
  }), /* @__PURE__ */ Z("div", {
18728
18740
  style: {
@@ -18734,7 +18746,7 @@ function jf({ screenCode: e }) {
18734
18746
  flexDirection: "column",
18735
18747
  gap: 16
18736
18748
  },
18737
- children: gt
18749
+ children: _t
18738
18750
  })]
18739
18751
  }),
18740
18752
  /* @__PURE__ */ Z("div", {
@@ -18760,10 +18772,10 @@ function jf({ screenCode: e }) {
18760
18772
  },
18761
18773
  children: (U || b) && a && /* @__PURE__ */ Z(ff, {
18762
18774
  nodes: c.sidebar,
18763
- ctx: ct
18775
+ ctx: lt
18764
18776
  })
18765
18777
  }),
18766
- _t
18778
+ vt
18767
18779
  ]
18768
18780
  }) : /* @__PURE__ */ Q("div", {
18769
18781
  style: {
@@ -18777,23 +18789,23 @@ function jf({ screenCode: e }) {
18777
18789
  /* @__PURE__ */ Q("div", {
18778
18790
  className: "shrink-0 px-6 pt-6 pb-2",
18779
18791
  children: [
18780
- dt,
18781
- pt,
18782
18792
  ft,
18783
18793
  mt,
18784
- ht
18794
+ pt,
18795
+ ht,
18796
+ gt
18785
18797
  ]
18786
18798
  }),
18787
18799
  /* @__PURE__ */ Z("div", {
18788
18800
  className: "flex-1 min-h-0 overflow-y-auto px-6 pb-6 space-y-4",
18789
- children: gt
18801
+ children: _t
18790
18802
  }),
18791
- _t
18803
+ vt
18792
18804
  ]
18793
18805
  });
18794
18806
  }
18795
18807
  function Mf({ title: e, recordId: n, editing: r, isNew: i, isSingletonByCaller: a, isRecordDeleted: o, dirty: s, isSaving: c, hasChildErrors: l, hasFieldErrors: u, canRestore: d, entity: f, screen: p, globalActions: m, entityCode: h, record: g, id: _, listRoute: y, listRouteExists: b, highlights: x, onBack: S, onCancelEdit: C, onSave: w, onRestore: T, isRestoring: E }) {
18796
- let { run: D } = go(), O = Mr(), k = yr(), A = Ee(), ee = p?.action_layout ?? null, M = f?.action_layout ?? null, P = ee ?? M, F = Hs(P ? Xs(P, f?.actions, m, "detail") : $s(f?.actions, "detail"), f?.actions, m, g ?? {}, []), I = q(() => {
18808
+ let { run: D } = go(), O = Mr(), k = yr(), A = Ee(), ee = p?.action_layout ?? null, te = f?.action_layout ?? null, N = ee ?? te, P = Hs(N ? Xs(N, f?.actions, m, "detail") : $s(f?.actions, "detail"), f?.actions, m, g ?? {}, []), F = q(() => {
18797
18809
  if (!f) return;
18798
18810
  let e = _ ? [_] : [];
18799
18811
  return {
@@ -18819,26 +18831,26 @@ function Mf({ title: e, recordId: n, editing: r, isNew: i, isSingletonByCaller:
18819
18831
  g,
18820
18832
  A,
18821
18833
  O
18822
- ]), L = o ? d ? /* @__PURE__ */ Z(V, {
18834
+ ]), I = o ? d ? /* @__PURE__ */ Z(V, {
18823
18835
  kind: "primary",
18824
- icon: Z(E ? v : N.refresh, { size: 13 }),
18836
+ icon: Z(E ? v : M.refresh, { size: 13 }),
18825
18837
  onClick: T,
18826
18838
  disabled: E,
18827
18839
  children: E ? "Restoring…" : "Restore"
18828
18840
  }) : null : r ? /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(V, {
18829
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
18841
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
18830
18842
  onClick: C,
18831
18843
  disabled: c,
18832
18844
  children: "Cancel"
18833
18845
  }), /* @__PURE__ */ Z(V, {
18834
18846
  kind: "primary",
18835
- icon: Z(c ? v : N.save, { size: 13 }),
18847
+ icon: Z(c ? v : M.save, { size: 13 }),
18836
18848
  onClick: w,
18837
18849
  disabled: c || l || u,
18838
18850
  title: l ? "Fix errors in child rows" : u ? "Fix the highlighted fields" : void 0,
18839
18851
  children: c ? "Saving…" : "Save"
18840
- })] }) : !i && _ && F.length > 0 ? /* @__PURE__ */ Z(Ec, {
18841
- layout: F,
18852
+ })] }) : !i && _ && P.length > 0 ? /* @__PURE__ */ Z(Ec, {
18853
+ layout: P,
18842
18854
  row: g,
18843
18855
  onRun: (e, n) => {
18844
18856
  let r = Dc(e, n, { row: g ?? void 0 });
@@ -18855,7 +18867,7 @@ function Mf({ title: e, recordId: n, editing: r, isNew: i, isSingletonByCaller:
18855
18867
  entityActions: f?.actions,
18856
18868
  globalActions: m,
18857
18869
  reservedRightWidth: 0,
18858
- widgetContext: I
18870
+ widgetContext: F
18859
18871
  }) : null;
18860
18872
  return /* @__PURE__ */ Z(xf, {
18861
18873
  icon: f?.display.icon ? /* @__PURE__ */ Z(ie, {
@@ -18869,7 +18881,7 @@ function Mf({ title: e, recordId: n, editing: r, isNew: i, isSingletonByCaller:
18869
18881
  dirty: s,
18870
18882
  showBack: !a && b,
18871
18883
  onBack: S,
18872
- right: L
18884
+ right: I
18873
18885
  });
18874
18886
  }
18875
18887
  //#endregion
@@ -19055,7 +19067,7 @@ function zf({ screenCode: e }) {
19055
19067
  value: u,
19056
19068
  onChange: b,
19057
19069
  placeholder: `Search ${W(o.display.name_plural)}…`,
19058
- prefix: /* @__PURE__ */ Z(N.search, { size: 13 })
19070
+ prefix: /* @__PURE__ */ Z(M.search, { size: 13 })
19059
19071
  }),
19060
19072
  a.filters && a.filters.length > 0 && /* @__PURE__ */ Z("div", {
19061
19073
  style: {
@@ -19142,8 +19154,8 @@ function zf({ screenCode: e }) {
19142
19154
  pkField: v,
19143
19155
  refs: _,
19144
19156
  isSelected: e[v] === l,
19145
- onClick: () => y(L(e[v]))
19146
- }, L(e[v])))
19157
+ onClick: () => y(I(e[v]))
19158
+ }, I(e[v])))
19147
19159
  })]
19148
19160
  }),
19149
19161
  S && /* @__PURE__ */ Z("div", {
@@ -19344,7 +19356,7 @@ function Hf({ entityCode: e, recordId: t, items: n, schema: r, entity: i }) {
19344
19356
  }, []);
19345
19357
  if (s) return /* @__PURE__ */ Z(Tl, {});
19346
19358
  if (!m) return null;
19347
- let T = ye(m, i), E = i.display?.display_field, D = T ? void 0 : E ? m[E] : m[i.fields.names()[0]], O = T || (D != null && typeof D != "object" ? L(D) : W(i.display.name)), k = m?.$refs, A = {
19359
+ let T = ye(m, i), E = i.display?.display_field, D = T ? void 0 : E ? m[E] : m[i.fields.names()[0]], O = T || (D != null && typeof D != "object" ? I(D) : W(i.display.name)), k = m?.$refs, A = {
19348
19360
  schema: r,
19349
19361
  entity: i,
19350
19362
  entityCode: e,
@@ -19407,19 +19419,19 @@ function Hf({ entityCode: e, recordId: t, items: n, schema: r, entity: i }) {
19407
19419
  },
19408
19420
  children: a && (u ? /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(V, {
19409
19421
  size: "xs",
19410
- icon: /* @__PURE__ */ Z(N.x, { size: 12 }),
19422
+ icon: /* @__PURE__ */ Z(M.x, { size: 12 }),
19411
19423
  onClick: S,
19412
19424
  children: "Cancel"
19413
19425
  }), /* @__PURE__ */ Z(V, {
19414
19426
  kind: "primary",
19415
19427
  size: "xs",
19416
- icon: c.isPending ? /* @__PURE__ */ Z(v, { size: 12 }) : /* @__PURE__ */ Z(N.save, { size: 12 }),
19428
+ icon: c.isPending ? /* @__PURE__ */ Z(v, { size: 12 }) : /* @__PURE__ */ Z(M.save, { size: 12 }),
19417
19429
  onClick: C,
19418
19430
  disabled: c.isPending,
19419
19431
  children: c.isPending ? "Saving…" : "Save"
19420
19432
  })] }) : /* @__PURE__ */ Z(V, {
19421
19433
  size: "xs",
19422
- icon: /* @__PURE__ */ Z(N.edit, { size: 12 }),
19434
+ icon: /* @__PURE__ */ Z(M.edit, { size: 12 }),
19423
19435
  onClick: x,
19424
19436
  children: "Edit"
19425
19437
  }))
@@ -20090,7 +20102,7 @@ function Sp({ title: e, backTo: t, actions: n }) {
20090
20102
  minWidth: 0
20091
20103
  },
20092
20104
  children: [t && /* @__PURE__ */ Z(z, {
20093
- icon: /* @__PURE__ */ Z(N.back, { size: 14 }),
20105
+ icon: /* @__PURE__ */ Z(M.back, { size: 14 }),
20094
20106
  onClick: o,
20095
20107
  title: "Back"
20096
20108
  }), /* @__PURE__ */ Z("h1", {
@@ -20140,45 +20152,45 @@ function Cp({ x: e, y: t, onClose: n, onPeek: r, onOpen: i, onEditInline: a, onD
20140
20152
  width: 200
20141
20153
  },
20142
20154
  children: [
20143
- r && /* @__PURE__ */ Z(F, {
20144
- icon: /* @__PURE__ */ Z(N.eye, { size: 13 }),
20155
+ r && /* @__PURE__ */ Z(P, {
20156
+ icon: /* @__PURE__ */ Z(M.eye, { size: 13 }),
20145
20157
  kbd: "Space",
20146
20158
  onClick: u(r),
20147
20159
  children: "Quick peek"
20148
20160
  }),
20149
- i && /* @__PURE__ */ Z(F, {
20150
- icon: /* @__PURE__ */ Z(N.external, { size: 13 }),
20161
+ i && /* @__PURE__ */ Z(P, {
20162
+ icon: /* @__PURE__ */ Z(M.external, { size: 13 }),
20151
20163
  kbd: "⏎",
20152
20164
  onClick: u(i),
20153
20165
  children: "Open"
20154
20166
  }),
20155
- a && /* @__PURE__ */ Z(F, {
20156
- icon: /* @__PURE__ */ Z(N.edit, { size: 13 }),
20167
+ a && /* @__PURE__ */ Z(P, {
20168
+ icon: /* @__PURE__ */ Z(M.edit, { size: 13 }),
20157
20169
  kbd: "E",
20158
20170
  onClick: u(a),
20159
20171
  children: "Edit inline"
20160
20172
  }),
20161
- o && /* @__PURE__ */ Z(F, {
20162
- icon: /* @__PURE__ */ Z(N.copy, { size: 13 }),
20173
+ o && /* @__PURE__ */ Z(P, {
20174
+ icon: /* @__PURE__ */ Z(M.copy, { size: 13 }),
20163
20175
  kbd: "⌘D",
20164
20176
  onClick: u(o),
20165
20177
  children: "Duplicate"
20166
20178
  }),
20167
- s && /* @__PURE__ */ Z(F, {
20168
- icon: /* @__PURE__ */ Z(N.link, { size: 13 }),
20179
+ s && /* @__PURE__ */ Z(P, {
20180
+ icon: /* @__PURE__ */ Z(M.link, { size: 13 }),
20169
20181
  onClick: u(s),
20170
20182
  children: "Copy link"
20171
20183
  }),
20172
- d && f && /* @__PURE__ */ Z(F, { divider: !0 }),
20173
- l?.map((e) => /* @__PURE__ */ Z(F, {
20184
+ d && f && /* @__PURE__ */ Z(P, { divider: !0 }),
20185
+ l?.map((e) => /* @__PURE__ */ Z(P, {
20174
20186
  icon: e.icon,
20175
20187
  danger: e.destructive,
20176
20188
  kbd: e.kbd,
20177
20189
  onClick: u(e.onRun),
20178
20190
  children: e.label
20179
20191
  }, e.id)),
20180
- c && /* @__PURE__ */ Q(X, { children: [(d || f) && /* @__PURE__ */ Z(F, { divider: !0 }), /* @__PURE__ */ Z(F, {
20181
- icon: /* @__PURE__ */ Z(N.trash, { size: 13 }),
20192
+ c && /* @__PURE__ */ Q(X, { children: [(d || f) && /* @__PURE__ */ Z(P, { divider: !0 }), /* @__PURE__ */ Z(P, {
20193
+ icon: /* @__PURE__ */ Z(M.trash, { size: 13 }),
20182
20194
  danger: !0,
20183
20195
  onClick: u(c),
20184
20196
  children: "Delete"
@@ -20256,12 +20268,12 @@ function Tp({ value: e, onSave: t, type: r = "text", options: i, trigger: a = "a
20256
20268
  placeholder: s
20257
20269
  }), r !== "select" && r !== "bool" && /* @__PURE__ */ Q(X, { children: [/* @__PURE__ */ Z(z, {
20258
20270
  size: 24,
20259
- icon: /* @__PURE__ */ Z(N.check, { size: 13 }),
20271
+ icon: /* @__PURE__ */ Z(M.check, { size: 13 }),
20260
20272
  onClick: b,
20261
20273
  title: "Save"
20262
20274
  }), /* @__PURE__ */ Z(z, {
20263
20275
  size: 24,
20264
- icon: /* @__PURE__ */ Z(N.x, { size: 13 }),
20276
+ icon: /* @__PURE__ */ Z(M.x, { size: 13 }),
20265
20277
  onClick: y,
20266
20278
  title: "Cancel"
20267
20279
  })] })]
@@ -20446,7 +20458,7 @@ function kp({ onOpenNav: e, greeting: t = "Good afternoon, Konstantin", tenantLa
20446
20458
  },
20447
20459
  children: [/* @__PURE__ */ Z(g, {
20448
20460
  title: "Quick access",
20449
- icon: /* @__PURE__ */ Z(N.bolt, { size: 14 }),
20461
+ icon: /* @__PURE__ */ Z(M.bolt, { size: 14 }),
20450
20462
  children: /* @__PURE__ */ Z("div", {
20451
20463
  style: {
20452
20464
  display: "grid",
@@ -20454,7 +20466,7 @@ function kp({ onOpenNav: e, greeting: t = "Good afternoon, Konstantin", tenantLa
20454
20466
  gap: 8
20455
20467
  },
20456
20468
  children: Op.map(([t, n, r]) => {
20457
- let i = N[r];
20469
+ let i = M[r];
20458
20470
  return /* @__PURE__ */ Q("button", {
20459
20471
  onClick: () => e?.(t),
20460
20472
  style: {
@@ -20481,7 +20493,7 @@ function kp({ onOpenNav: e, greeting: t = "Good afternoon, Konstantin", tenantLa
20481
20493
  children: n
20482
20494
  }),
20483
20495
  /* @__PURE__ */ Z("span", { style: { flex: 1 } }),
20484
- /* @__PURE__ */ Z(N.right, {
20496
+ /* @__PURE__ */ Z(M.right, {
20485
20497
  size: 12,
20486
20498
  style: { color: "var(--text-4)" }
20487
20499
  })
@@ -20491,7 +20503,7 @@ function kp({ onOpenNav: e, greeting: t = "Good afternoon, Konstantin", tenantLa
20491
20503
  })
20492
20504
  }), /* @__PURE__ */ Z(g, {
20493
20505
  title: "Recent activity",
20494
- icon: /* @__PURE__ */ Z(N.activity, { size: 14 }),
20506
+ icon: /* @__PURE__ */ Z(M.activity, { size: 14 }),
20495
20507
  children: /* @__PURE__ */ Z("div", {
20496
20508
  style: {
20497
20509
  display: "flex",
@@ -20971,7 +20983,7 @@ function Lp() {
20971
20983
  },
20972
20984
  children: /* @__PURE__ */ Z(z, {
20973
20985
  size: 22,
20974
- icon: /* @__PURE__ */ Z(N.more, { size: 12 })
20986
+ icon: /* @__PURE__ */ Z(M.more, { size: 12 })
20975
20987
  })
20976
20988
  })
20977
20989
  ]
@@ -21195,7 +21207,7 @@ function Bp({ open: e, onClose: t, conversations: n, activeId: r, onSelect: i, o
21195
21207
  }), /* @__PURE__ */ Q(V, {
21196
21208
  kind: "ghost",
21197
21209
  onClick: a,
21198
- children: [/* @__PURE__ */ Z(N.plus, {}), " New"]
21210
+ children: [/* @__PURE__ */ Z(M.plus, {}), " New"]
21199
21211
  })]
21200
21212
  }),
21201
21213
  /* @__PURE__ */ Q("div", {
@@ -21233,8 +21245,8 @@ function Bp({ open: e, onClose: t, conversations: n, activeId: r, onSelect: i, o
21233
21245
  }
21234
21246
  function Vp(e) {
21235
21247
  if (!e) return "";
21236
- let t = e.entity ? L(e.entity) : "", n = e.pk ? `:${L(e.pk).slice(0, 6)}` : "";
21248
+ let t = e.entity ? I(e.entity) : "", n = e.pk ? `:${I(e.pk).slice(0, 6)}` : "";
21237
21249
  return t ? `${t}${n}` : "";
21238
21250
  }
21239
21251
  //#endregion
21240
- export { Ae as ActionBatchError, vo as ActionRunnerProvider, fa as AgentChatPanel, Bp as AgentConversationDrawer, aa as AgentElicitForm, zp as AgentVisualHints, ip as App, ip as Declarion, Uo as AuthShell, He as Avatar, hp as Batch, ot as BoolToggle, S as BrandGlyph, oi as Breadcrumbs, V as Btn, ft as CURSOR_LOCALE_CHANGED, ht as CURSOR_SEMANTICS_MISMATCH, Cs as ChangePasswordDialog, w as Check, re as Chip, Te as CircleImage, f as ClassifiedFieldLocked, Eu as ColumnPicker, wi as CommandPalette, Ar as ConfirmDialog, et as DateInput, m as Dropdown, ie as DynamicIcon, vl as EmptyState, up as EntityClient, ne as FieldLabel, Ot as FileDraftScope, iu as FilterChips, ou as FilterDrawer, fs as Forgot, kp as HomeStub, se as HoverCard, N as Icon, z as IconBtn, fi as ImpersonationBanner, yi as ImpersonationFrame, Rp as ImpersonationStartModal, Tp as InlineEditCell, Lp as JobsStub, u as JsonField, b as Kbd, Ka as MULTIPLE_VALUES, F as MenuItem, El as NO_VALUE_OPS, Dl as OP_LABELS, Sp as PageHeader, c as PasswordInput, B as Pill, Np as PipelineStub, el as Preferences, Wc as Profile, qa as PropertyGridEditor, Hl as QEField, A as QuickEditCell, Vl as QuickPeek, Tn as Rail, ae as RecordIdBadge, cp as RefCache, je as RefField, ys as Reset, i as RowField, Cp as RowMenu, g as SectionCard, n as Select, Nr as Sidebar, ss as SignIn, us as SignUp, Af as SmartDetailPage, Uu as SmartListPage, zf as SmartRecordListPage, v as Spinner, Ce as SquareImage, li as TabStrip, ke as TagsInput, ri as TenantChip, E as TextArea, O as TextInput, ci as TopBar, bs as TwoFA, Dt as UploadError, ee as ViewField, Ou as ViewSwitcher, Pe as WideBanner, Oi as approveInvocation, t as buildActionBody, pe as buildDetailHrefFromId, Re as buildEntityDetailHref, Ha as buildMassEditTargets, Ke as buildRowDetailHref, Pr as buildSections, Ai as cancelConversation, bu as classificationTier, L as coerceDisplayString, Ml as countActiveFilters, Ti as createConversation, T as deleteEntity, Qa as detectCommonValue, Pt as discardFile, mp as entityClient, ni as envTone, j as executeAction, Ne as extractPkValues, Su as fieldAccessInfo, vu as fieldClassification, Xe as fieldDisplayName, yu as fieldRequiredPermission, It as formatBytes, ru as formatCount, tu as formatEstimatedCount, nu as formatExactCount, rt as getFileWidget, de as getImageCropper, Se as getPrimaryKeyFields, me as hasFileWidget, Al as hasOrGroups, Mt as isCursorStaleError, gu as isFieldReadable, xu as isFieldSoDProtected, _u as isFieldWritable, ji as listConversations, Ni as listPendingInvocations, Pi as loadHistory, W as loc, Ol as parseFiltersFromURL, Va as parseTargetFilter, U as pkValuePartsToId, we as pkValuesFromId, fe as pkValuesToDetailId, Qe as pkValuesToId, tt as registerFileWidget, Xf as registerScreen, ki as rejectInvocation, Mi as rerunMessageTurn, he as resolveDetailRoute, at as restoreEntity, Di as sendElicitResponse, Ei as sendMessage, kl as setFiltersInURL, Ze as setImageCropper, kt as uploadFile, go as useActionRunner, ia as useAgentConversation, yp as useAllEntityData, Xr as useAuth, bp as useColumns, Os as useCreateEntity, _l as useDebounce, As as useDeleteEntity, Rf as useDeleteProperty, jt as useDraftRegistration, I as useEntity, a as useEntityCount, $e as useEntityData, Gu as useEntityItem, Nt as useFileDraftScope, Il as useFilters, Zr as useImpersonation, Zt as useLocation, $t as useNavigate, vi as useParam, tn as useParams, gi as usePublicParams, _i as useResolvedParam, oe as useSchema, ku as useScreen, rn as useSearchParams, Lf as useSetProperty, Pf as useSetStatus, Mr as useTabNavigate, Bn as useTabStore, ks as useUpdateEntity, Au as useViews, Ft as validateClientSide };
21252
+ export { Ae as ActionBatchError, vo as ActionRunnerProvider, fa as AgentChatPanel, Bp as AgentConversationDrawer, aa as AgentElicitForm, zp as AgentVisualHints, ip as App, ip as Declarion, Uo as AuthShell, He as Avatar, hp as Batch, ot as BoolToggle, S as BrandGlyph, oi as Breadcrumbs, V as Btn, ft as CURSOR_LOCALE_CHANGED, ht as CURSOR_SEMANTICS_MISMATCH, Cs as ChangePasswordDialog, w as Check, re as Chip, Te as CircleImage, f as ClassifiedFieldLocked, Eu as ColumnPicker, wi as CommandPalette, Ar as ConfirmDialog, et as DateInput, m as Dropdown, ie as DynamicIcon, vl as EmptyState, up as EntityClient, L as FieldLabel, Ot as FileDraftScope, iu as FilterChips, ou as FilterDrawer, fs as Forgot, kp as HomeStub, se as HoverCard, M as Icon, z as IconBtn, fi as ImpersonationBanner, yi as ImpersonationFrame, Rp as ImpersonationStartModal, Tp as InlineEditCell, Lp as JobsStub, u as JsonField, b as Kbd, Ka as MULTIPLE_VALUES, P as MenuItem, El as NO_VALUE_OPS, Dl as OP_LABELS, Sp as PageHeader, c as PasswordInput, B as Pill, Np as PipelineStub, el as Preferences, Wc as Profile, qa as PropertyGridEditor, Hl as QEField, A as QuickEditCell, Vl as QuickPeek, Tn as Rail, ae as RecordIdBadge, cp as RefCache, je as RefField, ys as Reset, i as RowField, Cp as RowMenu, g as SectionCard, n as Select, Nr as Sidebar, ss as SignIn, us as SignUp, Af as SmartDetailPage, Uu as SmartListPage, zf as SmartRecordListPage, v as Spinner, Ce as SquareImage, li as TabStrip, ke as TagsInput, ri as TenantChip, E as TextArea, O as TextInput, ci as TopBar, bs as TwoFA, Dt as UploadError, ee as ViewField, Ou as ViewSwitcher, Pe as WideBanner, Oi as approveInvocation, t as buildActionBody, pe as buildDetailHrefFromId, Re as buildEntityDetailHref, Ha as buildMassEditTargets, Ke as buildRowDetailHref, Pr as buildSections, Ai as cancelConversation, bu as classificationTier, I as coerceDisplayString, Ml as countActiveFilters, Ti as createConversation, T as deleteEntity, Qa as detectCommonValue, Pt as discardFile, mp as entityClient, ni as envTone, j as executeAction, Ne as extractPkValues, Su as fieldAccessInfo, vu as fieldClassification, Xe as fieldDisplayName, yu as fieldRequiredPermission, It as formatBytes, ru as formatCount, tu as formatEstimatedCount, nu as formatExactCount, rt as getFileWidget, de as getImageCropper, Se as getPrimaryKeyFields, me as hasFileWidget, Al as hasOrGroups, Mt as isCursorStaleError, gu as isFieldReadable, xu as isFieldSoDProtected, _u as isFieldWritable, ji as listConversations, Ni as listPendingInvocations, Pi as loadHistory, W as loc, Ol as parseFiltersFromURL, Va as parseTargetFilter, U as pkValuePartsToId, we as pkValuesFromId, fe as pkValuesToDetailId, Qe as pkValuesToId, tt as registerFileWidget, Xf as registerScreen, ki as rejectInvocation, Mi as rerunMessageTurn, he as resolveDetailRoute, at as restoreEntity, Di as sendElicitResponse, Ei as sendMessage, kl as setFiltersInURL, Ze as setImageCropper, kt as uploadFile, go as useActionRunner, ia as useAgentConversation, yp as useAllEntityData, Xr as useAuth, bp as useColumns, Os as useCreateEntity, _l as useDebounce, As as useDeleteEntity, Rf as useDeleteProperty, jt as useDraftRegistration, F as useEntity, a as useEntityCount, $e as useEntityData, Gu as useEntityItem, Nt as useFileDraftScope, Il as useFilters, Zr as useImpersonation, Zt as useLocation, $t as useNavigate, vi as useParam, tn as useParams, gi as usePublicParams, _i as useResolvedParam, oe as useSchema, ku as useScreen, rn as useSearchParams, Lf as useSetProperty, Pf as useSetStatus, Mr as useTabNavigate, Bn as useTabStore, ks as useUpdateEntity, Au as useViews, Ft as validateClientSide };