@nivaro/react 0.3.17 → 0.3.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,69 +1,70 @@
1
1
  import { jsxs as c, jsx as t, Fragment as Ke } from "react/jsx-runtime";
2
2
  import { useQueryClient as sr, useMutation as mt, useQuery as ae, useQueries as Za } from "@tanstack/react-query";
3
- import { FileDiff as oo, RotateCw as Gn, Network as io, Map as co, Sparkles as Xn, X as Zn, Rows3 as Rl, Rows2 as uo, ChevronDown as qa, Wand2 as Pl, FileText as El, Bell as po, BellOff as mo, Loader2 as bo, Check as ho, Search as Gl, Pin as fo } from "lucide-react";
4
- import go, { useState as k, useRef as me, useEffect as ve, useMemo as we, useLayoutEffect as xo } from "react";
5
- import { createPortal as Xl } from "react-dom";
3
+ import { FileDiff as io, RotateCw as Gn, Network as co, Map as uo, Sparkles as Xn, X as Zn, Rows3 as Rl, Rows2 as po, ChevronDown as qa, Wand2 as Pl, FileText as El, Bell as mo, BellOff as bo, Loader2 as ho, Check as fo, Search as Xl, Pin as go } from "lucide-react";
4
+ import xo, { useState as k, useRef as me, useEffect as ve, useMemo as we, useLayoutEffect as vo } from "react";
5
+ import { createPortal as Zl } from "react-dom";
6
6
  import { toast as ue } from "sonner";
7
- import { useNivaroClient as lt, useItemNavigation as Zl, useOverlayState as vo, useItemEditAuth as an, useApiFetchConfig as ko } from "../context.js";
7
+ import { useNivaroClient as lt, useItemNavigation as es, useOverlayState as ko, useItemEditAuth as an, useApiFetchConfig as yo } from "../context.js";
8
8
  import { useDebounced as Ml } from "../hooks/useDebounced.js";
9
- import { useElapsedLoading as yo } from "../hooks/useElapsedLoading.js";
10
- import { useBulkProgressFeed as wo, newBulkProgressId as _o, startBulkProgress as No, endBulkProgress as So } from "../lib/bulk-progress.js";
9
+ import { useElapsedLoading as wo } from "../hooks/useElapsedLoading.js";
10
+ import { useBulkProgressFeed as _o, newBulkProgressId as No, startBulkProgress as So, endBulkProgress as Co } from "../lib/bulk-progress.js";
11
11
  import { post as be, get as Y, patch as Ga, del as en } from "../lib/commands.js";
12
- import { parseDateFilter as rr, dateFilterBounds as Co, describeDateFilter as $o, DATE_FILTER_OPS as qo, formatDateFilter as To } from "../lib/date-filter.js";
13
- import { extractExpressionTokens as Lo, evaluateNumeric as Dl } from "../lib/expression.js";
14
- import { deliverLive as Fo, releaseLiveOwner as Ro } from "../lib/focus-mode.js";
15
- import { formatValue as ia, formatMultiValue as Ol, countFromResolved as Po } from "../lib/format-value.js";
16
- import { createCursorBook as Eo, pageRequest as Mo, noteNextCursor as Do, isCursorRefusal as Oo, stopCursors as Ao } from "../lib/keyset-pager.js";
17
- import { expandCoalesced as jo, LIVE_ASPECTS as da } from "../lib/live.js";
18
- import { useRowChanges as Io, useRowLocks as Ko, lockLabel as Bo, viewerMatches as zo, conditionFields as Wo, mayAffectMatch as Uo, writerOf as Qo } from "../lib/live-list.js";
19
- import { loadErrorStatus as Vo, listLoadErrorText as Yo } from "../lib/load-error.js";
20
- import { OPEN_IN_TABS_CAP as Ho, openInTabs as Jo, openInTabsMessage as Al } from "../lib/open-in-tabs.js";
21
- import { isOwnWrite as Go } from "../lib/own-writes.js";
22
- import { useIdleNextPage as Xo, prefetchRecord as Zo } from "../lib/prefetch.js";
23
- import { useRowPresence as ei, rowPresenceKey as jl } from "../lib/presence-hooks.js";
24
- import { useOptionalRealtime as ti } from "../lib/realtime.js";
25
- import { rowHighlightDotClass as ai, rowHighlightClass as ni } from "../lib/row-highlight.js";
12
+ import { parseDateFilter as rr, dateFilterBounds as $o, describeDateFilter as qo, DATE_FILTER_OPS as To, formatDateFilter as Lo } from "../lib/date-filter.js";
13
+ import { extractExpressionTokens as Fo, evaluateNumeric as Dl } from "../lib/expression.js";
14
+ import { deliverLive as Ro, releaseLiveOwner as Po } from "../lib/focus-mode.js";
15
+ import { formatValue as ia, formatMultiValue as Ol, countFromResolved as Eo } from "../lib/format-value.js";
16
+ import { createCursorBook as Mo, pageRequest as Do, noteNextCursor as Oo, isCursorRefusal as Ao, stopCursors as jo } from "../lib/keyset-pager.js";
17
+ import { expandCoalesced as Io, LIVE_ASPECTS as da } from "../lib/live.js";
18
+ import { useRowChanges as Ko, useRowLocks as Bo, lockLabel as zo, viewerMatches as Wo, conditionFields as Qo, mayAffectMatch as Uo, writerOf as Vo } from "../lib/live-list.js";
19
+ import { loadErrorStatus as Yo, listLoadErrorText as Ho } from "../lib/load-error.js";
20
+ import { OPEN_IN_TABS_CAP as Jo, openInTabs as Go, openInTabsMessage as Al } from "../lib/open-in-tabs.js";
21
+ import { isOwnWrite as Xo } from "../lib/own-writes.js";
22
+ import { useIdleNextPage as Zo, prefetchRecord as ei } from "../lib/prefetch.js";
23
+ import { useRowPresence as ti, rowPresenceKey as jl } from "../lib/presence-hooks.js";
24
+ import { useOptionalRealtime as ai } from "../lib/realtime.js";
25
+ import { rowHighlightDotClass as ni, rowHighlightClass as ri } from "../lib/row-highlight.js";
26
26
  import { userErrorMessage as Ct } from "../lib/safe-error.js";
27
- import { logSearch as ri, logSearchOpen as li } from "../lib/search-log.js";
28
- import { useMyScopes as si, matchScopeDimension as Il, effectiveScopeSeedIds as oi, translateScopeValues as ii } from "../lib/use-my-scopes.js";
29
- import { useNewItemLayouts as di } from "../lib/use-new-item-layouts.js";
30
- import { loadUserCard as ci } from "../lib/user-cards.js";
31
- import { cn as Ot, humanHours as ui } from "../lib/utils.js";
32
- import { usePublishAskContext as pi, useAskRecordDrag as mi } from "./ai/ask-context.js";
33
- import { useAvailableBulkActions as bi, mergeBulkActions as hi, guardMatches as fi, useBuiltinGate as gi, BulkActionButtons as xi } from "./bulk/BulkActionButtons.js";
34
- import { BulkFieldUpdate as vi } from "./bulk/BulkFieldUpdate.js";
35
- import { BulkRowMark as ki } from "./bulk/BulkRowMark.js";
36
- import { useRowPushActions as yi, runRowPush as wi } from "./bulk/RowPushActions.js";
37
- import { CellCopyLayer as _i } from "./CellCopyLayer.js";
38
- import { CopyAsButton as Ni } from "./CopyAsButton.js";
39
- import { useTreeConfig as Si, CollectionTree as Ci } from "./cbv/CollectionTree.js";
40
- import { readExportRows as $i, stableSort as qi, m2oLabelPaths as Ti, resolveAllPaths as Li, userLabel as Fi, m2oLabel as Ri, localYmd as Pi } from "./cbv/export-rows.js";
41
- import { FormulaColumnAdder as Ei } from "./cbv/FormulaColumnAdder.js";
42
- import { useHierarchyScope as Mi, HierarchyScopePicker as Di } from "./cbv/HierarchyScope.js";
43
- import { splitRiskFilter as Oi, riskFilterEntry as Ai } from "./cbv/saved-view-risk.js";
44
- import { isFilterRefusal as ji, unknownFieldsOf as Kl, dropUnknownField as Ii } from "./cbv/unknown-fields.js";
45
- import { ViewDefaultMenu as Ki } from "./cbv/ViewDefaultMenu.js";
46
- import { useRecordRoomTypes as Bi, canOpenChatRoom as zi, discussRecord as Wi } from "./chat/chat-core.js";
27
+ import { logSearch as li, logSearchOpen as si } from "../lib/search-log.js";
28
+ import { useMyScopes as oi, matchScopeDimension as Il, effectiveScopeSeedIds as ii, translateScopeValues as di } from "../lib/use-my-scopes.js";
29
+ import { useNewItemLayouts as ci } from "../lib/use-new-item-layouts.js";
30
+ import { loadUserCard as ui } from "../lib/user-cards.js";
31
+ import { cn as Ot, humanHours as pi } from "../lib/utils.js";
32
+ import { usePublishAskContext as mi, useAskRecordDrag as bi } from "./ai/ask-context.js";
33
+ import { useAvailableBulkActions as hi, mergeBulkActions as fi, guardMatches as gi, useBuiltinGate as xi, BulkActionButtons as vi } from "./bulk/BulkActionButtons.js";
34
+ import { BulkFieldUpdate as ki } from "./bulk/BulkFieldUpdate.js";
35
+ import { BulkRowMark as yi } from "./bulk/BulkRowMark.js";
36
+ import { useRowPushActions as wi, runRowPush as _i } from "./bulk/RowPushActions.js";
37
+ import { CellCopyLayer as Ni } from "./CellCopyLayer.js";
38
+ import { CopyAsButton as Si } from "./CopyAsButton.js";
39
+ import { useTreeConfig as Ci, CollectionTree as $i } from "./cbv/CollectionTree.js";
40
+ import { readExportRows as qi, stableSort as Ti, m2oLabelPaths as Li, resolveAllPaths as Fi, userLabel as Ri, m2oLabel as Pi, localYmd as Ei } from "./cbv/export-rows.js";
41
+ import { FormulaColumnAdder as Mi } from "./cbv/FormulaColumnAdder.js";
42
+ import { useHierarchyScope as Di, HierarchyScopePicker as Oi } from "./cbv/HierarchyScope.js";
43
+ import { splitRiskFilter as Ai, riskFilterEntry as ji } from "./cbv/saved-view-risk.js";
44
+ import { isFilterRefusal as Ii, unknownFieldsOf as Kl, dropUnknownField as Ki } from "./cbv/unknown-fields.js";
45
+ import { ViewDefaultMenu as Bi } from "./cbv/ViewDefaultMenu.js";
46
+ import { useRecordRoomTypes as zi, canOpenChatRoom as Wi, discussRecord as Qi } from "./chat/chat-core.js";
47
47
  import { FilterControl as Ui } from "./DataTable.js";
48
- import { FocusModeToggle as Qi } from "./FocusModeToggle.js";
49
- import { FULFILMENT_FILTER_OPTIONS as Vi, FulfilmentPill as Yi, fulfilmentFigures as Hi } from "./FulfilmentPill.js";
50
- import { HScrollProxy as Ji } from "./HScrollProxy.js";
51
- import { useDocumentAutofillConfig as Gi, startDocumentExtraction as Xi } from "./import/DocumentAutofillButton.js";
52
- import { INTEGRATIONS_FILTER_OPTIONS as Zi, IntegrationDots as ed } from "./integrations/IntegrationDots.js";
53
- import { useQuickPickerSteps as td, QuickPickerDialog as ad } from "./item-edit/QuickPickerDialog.js";
54
- import { UserRosterCluster as Bl, UserChip as zl } from "./item-edit/UserChip.js";
55
- import { LiveRowMark as nd } from "./LiveRowMark.js";
56
- import { MapView as rd } from "./MapView.js";
57
- import { RealtimeStaleMark as ld } from "./RealtimeStatusBanner.js";
58
- import { RecordCompareDialog as sd } from "./RecordCompare.js";
59
- import { RecordDrilldownSheet as od } from "./RecordDrilldownSheet.js";
60
- import { RowHighlightLegend as id } from "./RowHighlightLegend.js";
61
- import { RowPresence as dd } from "./RowPresence.js";
62
- import { TipLayer as cd } from "./TipLayer.js";
63
- import { UnseenDot as Wl } from "./UnseenDot.js";
64
- import { SimpleSelectXs as ca, SimpleSelect as ud } from "./ui/SimpleSelect.js";
65
- import { RevisionsPanel as pd } from "./panels/RevisionsPanel.js";
66
- import { itemActionChoiceStep as md, ItemActionChoiceList as bd } from "./panels/ItemActionChoices.js";
48
+ import { FocusModeToggle as Vi } from "./FocusModeToggle.js";
49
+ import { FULFILMENT_FILTER_OPTIONS as Yi, FulfilmentPill as Hi, fulfilmentFigures as Ji } from "./FulfilmentPill.js";
50
+ import { HScrollProxy as Gi } from "./HScrollProxy.js";
51
+ import { useDocumentAutofillConfig as Xi, startDocumentExtraction as Zi } from "./import/DocumentAutofillButton.js";
52
+ import { INTEGRATIONS_FILTER_OPTIONS as ed, IntegrationDots as td } from "./integrations/IntegrationDots.js";
53
+ import { useQuickPickerSteps as ad, QuickPickerDialog as nd } from "./item-edit/QuickPickerDialog.js";
54
+ import { invalidateRecordQueries as Bl } from "./item-edit/RecordLiveSync.js";
55
+ import { UserRosterCluster as zl, UserChip as Wl } from "./item-edit/UserChip.js";
56
+ import { LiveRowMark as rd } from "./LiveRowMark.js";
57
+ import { MapView as ld } from "./MapView.js";
58
+ import { RealtimeStaleMark as sd } from "./RealtimeStatusBanner.js";
59
+ import { RecordCompareDialog as od } from "./RecordCompare.js";
60
+ import { RecordDrilldownSheet as id } from "./RecordDrilldownSheet.js";
61
+ import { RowHighlightLegend as dd } from "./RowHighlightLegend.js";
62
+ import { RowPresence as cd } from "./RowPresence.js";
63
+ import { TipLayer as ud } from "./TipLayer.js";
64
+ import { UnseenDot as Ql } from "./UnseenDot.js";
65
+ import { SimpleSelectXs as ca, SimpleSelect as pd } from "./ui/SimpleSelect.js";
66
+ import { RevisionsPanel as md } from "./panels/RevisionsPanel.js";
67
+ import { itemActionChoiceStep as bd, ItemActionChoiceList as hd } from "./panels/ItemActionChoices.js";
67
68
  function Ta(n, i, m) {
68
69
  const o = n.find((f) => f.one_collection === i && f.one_field === m);
69
70
  if (o != null && o.many_collection)
@@ -76,7 +77,7 @@ function $a(n) {
76
77
  for (const o of or) if (i.has(o)) return o;
77
78
  return "id";
78
79
  }
79
- const Ul = (n) => typeof n == "string" ? n : n.key, Ql = {
80
+ const Ul = (n) => typeof n == "string" ? n : n.key, Vl = {
80
81
  red: "text-red-600 dark:text-red-400 font-semibold",
81
82
  amber: "text-amber-600 dark:text-amber-400 font-semibold",
82
83
  green: "text-emerald-600 dark:text-emerald-400 font-semibold",
@@ -113,7 +114,7 @@ function Xa(n, i) {
113
114
  }
114
115
  return null;
115
116
  }
116
- const hd = [
117
+ const fd = [
117
118
  { label: "None", cfg: null },
118
119
  { label: "Currency", cfg: { type: "number", decimals: 2, thousands: !0, prefix: "$" } },
119
120
  { label: "Number", cfg: { type: "number", thousands: !0 } },
@@ -142,12 +143,12 @@ function nn(n, i) {
142
143
  return f == null ? "" : String(f);
143
144
  });
144
145
  }
145
- function es(n, i, m) {
146
+ function ts(n, i, m) {
146
147
  return n.find(
147
148
  (o) => o.many_collection === i && o.many_field === m && o.junction_field === null && o.one_collection !== null
148
149
  );
149
150
  }
150
- function fd(n) {
151
+ function gd(n) {
151
152
  const i = new Date(String(n));
152
153
  if (Number.isNaN(i.getTime())) return String(n);
153
154
  const m = Date.now() - i.getTime(), o = Math.floor(m / 6e4);
@@ -158,8 +159,8 @@ function fd(n) {
158
159
  const y = Math.floor(f / 24);
159
160
  return y < 7 ? `${y}d ago` : i.toLocaleDateString("en-US", { month: "short", day: "numeric", year: "numeric" });
160
161
  }
161
- const rt = (n) => n.toLocaleString("en-US"), ts = /* @__PURE__ */ new Set(["nivaro_users", "directus_users"]), gt = (n) => n.startsWith("directus_") || n.startsWith("nivaro_"), er = /* @__PURE__ */ new Map();
162
- function gd(n, i, m) {
162
+ const rt = (n) => n.toLocaleString("en-US"), as = /* @__PURE__ */ new Set(["nivaro_users", "directus_users"]), gt = (n) => n.startsWith("directus_") || n.startsWith("nivaro_"), er = /* @__PURE__ */ new Map();
163
+ function xd(n, i, m) {
163
164
  let o = er.get(i);
164
165
  o || (o = { ids: /* @__PURE__ */ new Set(), waiters: [], promise: null }, er.set(i, o));
165
166
  const f = o;
@@ -189,16 +190,16 @@ function gd(n, i, m) {
189
190
  }, 0);
190
191
  })), f.promise.then((y) => y.get(m) ?? null);
191
192
  }
192
- const xd = {
193
+ const vd = {
193
194
  draft: "draft",
194
195
  submitted: "submitted",
195
196
  review: "in review",
196
197
  approved: "approved",
197
198
  rejected: "rejected"
198
199
  };
199
- function vd({ summary: n }) {
200
+ function kd({ summary: n }) {
200
201
  if (!n || n.total === 0) return /* @__PURE__ */ t("span", { className: "text-[12px] text-slate-300", children: "—" });
201
- const i = n.latest, m = n.active > 0, o = i ? xd[i.status] ?? i.status : "", f = i == null ? void 0 : i.cost_impact, y = f != null && f !== 0 ? `${f > 0 ? "+" : "−"}$${Math.abs(f).toLocaleString(void 0, { minimumFractionDigits: 2, maximumFractionDigits: 2 })}` : null, N = i ? `${i.title ?? "Addendum"} — ${o}${n.total > 1 ? ` (${n.total} total)` : ""}` : void 0;
202
+ const i = n.latest, m = n.active > 0, o = i ? vd[i.status] ?? i.status : "", f = i == null ? void 0 : i.cost_impact, y = f != null && f !== 0 ? `${f > 0 ? "+" : "−"}$${Math.abs(f).toLocaleString(void 0, { minimumFractionDigits: 2, maximumFractionDigits: 2 })}` : null, N = i ? `${i.title ?? "Addendum"} — ${o}${n.total > 1 ? ` (${n.total} total)` : ""}` : void 0;
202
203
  return /* @__PURE__ */ c(
203
204
  "span",
204
205
  {
@@ -222,7 +223,7 @@ function vd({ summary: n }) {
222
223
  );
223
224
  }
224
225
  function ir({ relatedCollection: n, id: i }) {
225
- const m = lt(), o = ts.has(n), f = i != null && i !== "", { data: y } = ae({
226
+ const m = lt(), o = as.has(n), f = i != null && i !== "", { data: y } = ae({
226
227
  queryKey: ["cbv-collection-meta", n],
227
228
  queryFn: () => m.request(Y(`/collections/${n}`)).then((S) => S.data),
228
229
  staleTime: 10 * 6e4,
@@ -230,7 +231,7 @@ function ir({ relatedCollection: n, id: i }) {
230
231
  retry: !1
231
232
  }), { data: N, isLoading: q } = ae({
232
233
  queryKey: ["cbv-relation-item", n, String(i)],
233
- queryFn: () => o ? m.request(Y(`/users/${i}`)).then((S) => S.data) : gd(m, n, String(i)),
234
+ queryFn: () => o ? m.request(Y(`/users/${i}`)).then((S) => S.data) : xd(m, n, String(i)),
234
235
  enabled: f && (o || !gt(n)),
235
236
  staleTime: 30 * 6e4,
236
237
  retry: !1
@@ -256,12 +257,12 @@ function tn(n, i) {
256
257
  ])
257
258
  n.invalidateQueries({ queryKey: [m, i] });
258
259
  }
259
- function kd(n, i) {
260
+ function yd(n, i) {
260
261
  return n ? n.is_admin ? !0 : (n.collections ?? []).some(
261
262
  (m) => (m.collection === i || m.collection === "*") && (m.actions.includes("delete") || m.actions.includes("*"))
262
263
  ) : !1;
263
264
  }
264
- function yd({
265
+ function wd({
265
266
  collection: n,
266
267
  id: i,
267
268
  hasPipeline: m,
@@ -274,13 +275,13 @@ function yd({
274
275
  row: S,
275
276
  bulkEnabledKeys: A
276
277
  }) {
277
- var Nt, pa, qt, ma, ba, Fa, Ae, Tt, it, Ue, ha, Vt, Yt, jt, It, Ra;
278
+ var Nt, pa, qt, ma, ba, Fa, Ae, Tt, it, Qe, ha, Vt, Yt, jt, It, Ra;
278
279
  const I = lt(), L = sr(), { isAdmin: u } = an(), [g, z] = k(!1), [P, v] = k({ x: 0, y: 0 }), T = me(null), E = me(null), { data: H } = ae({
279
280
  queryKey: ["my-permissions"],
280
281
  queryFn: () => I.request(Y("/security/my/permissions")).then((b) => b.data),
281
282
  enabled: g && !u,
282
283
  staleTime: 5 * 6e4
283
- }), W = u || kd(H, n), [O, Q] = k(!1), he = Bi(g), j = zi() && !!(he != null && he.some((b) => b.collection === n));
284
+ }), W = u || yd(H, n), [O, U] = k(!1), he = zi(g), j = Wi() && !!(he != null && he.some((b) => b.collection === n));
284
285
  ve(() => {
285
286
  if (!g) return;
286
287
  const b = (le) => {
@@ -302,7 +303,7 @@ function yd({
302
303
  }), Ye = we(
303
304
  () => ((re == null ? void 0 : re.available_transitions) ?? []).filter((b) => b.in_row_menu !== !1),
304
305
  [re]
305
- ), { data: Oe } = bi(g ? [n] : []), Re = we(() => g ? hi(Oe, [n], A).filter((b) => b.kind === "builtin" || b.kind === "transition" ? !1 : S ? fi(b.guard, S) !== !1 : !0) : [], [g, Oe, n, A, S]), { pushActions: _e, failedPartners: Le } = yi({
306
+ ), { data: Oe } = hi(g ? [n] : []), Re = we(() => g ? fi(Oe, [n], A).filter((b) => b.kind === "builtin" || b.kind === "transition" ? !1 : S ? gi(b.guard, S) !== !1 : !0) : [], [g, Oe, n, A, S]), { pushActions: _e, failedPartners: Le } = wi({
306
307
  collection: n,
307
308
  id: i,
308
309
  open: g,
@@ -339,7 +340,7 @@ function yd({
339
340
  return (w == null ? void 0 : w.color) ?? b.color ?? "#94a3b8";
340
341
  }, [_, J] = k(null), [$e, _t] = k("");
341
342
  ve(() => {
342
- g || (J(null), _t(""), Q(!1));
343
+ g || (J(null), _t(""), U(!1));
343
344
  }, [g]);
344
345
  const Fe = ((Nt = _ == null ? void 0 : _.push) == null ? void 0 : Nt.kind) === "push" && _.push.action.choose ? _.push.action : null, st = ae({
345
346
  queryKey: ["item-action-choices", (Fe == null ? void 0 : Fe.id) ?? null, n, String(i)],
@@ -348,10 +349,10 @@ function yd({
348
349
  ).then((b) => b.data ?? []),
349
350
  enabled: !!Fe,
350
351
  staleTime: 0
351
- }), [Qt, At] = k(null), sn = (Fe == null ? void 0 : Fe.id) ?? null;
352
+ }), [Ut, At] = k(null), sn = (Fe == null ? void 0 : Fe.id) ?? null;
352
353
  ve(() => At(null), [sn]);
353
- const Ze = st.data ? md(st.data) : null, ua = Ze && !Ze.ask ? Ze.value : Qt, La = !!Fe && (!Ze || Ze.ask && Qt == null);
354
- go.useLayoutEffect(() => {
354
+ const Ze = st.data ? bd(st.data) : null, ua = Ze && !Ze.ask ? Ze.value : Ut, La = !!Fe && (!Ze || Ze.ask && Ut == null);
355
+ xo.useLayoutEffect(() => {
355
356
  var je;
356
357
  if (!g) return;
357
358
  const b = E.current;
@@ -372,7 +373,7 @@ function yd({
372
373
  })
373
374
  ),
374
375
  onSuccess: () => {
375
- z(!1), ue.success("Transitioned"), tn(L, n), C == null || C();
376
+ z(!1), ue.success("Transitioned"), tn(L, n), Bl(L, n, [i]), C == null || C();
376
377
  },
377
378
  onError: (b) => ue.error(Ct(b, "Transition failed"))
378
379
  }), ot = mt({
@@ -390,14 +391,14 @@ function yd({
390
391
  ue.info(`${b.label}: nothing to change`);
391
392
  return;
392
393
  }
393
- ue.success(b.label), tn(L, n), C == null || C();
394
+ ue.success(b.label), tn(L, n), Bl(L, n, [i]), C == null || C();
394
395
  },
395
396
  onError: (b) => {
396
397
  const w = b.response;
397
398
  ue.error((w == null ? void 0 : w.error) ?? Ct(b, "Action failed"));
398
399
  }
399
400
  }), bt = mt({
400
- mutationFn: ({ op: b, note: w, pick: le }) => wi(I, n, i, b, w, le).then((pe) => ({ op: b, outcome: pe })),
401
+ mutationFn: ({ op: b, note: w, pick: le }) => _i(I, n, i, b, w, le).then((pe) => ({ op: b, outcome: pe })),
401
402
  onSuccess: ({ op: b, outcome: w }) => {
402
403
  z(!1);
403
404
  const le = b.kind === "push" ? b.action.label : "Retry";
@@ -445,7 +446,7 @@ function yd({
445
446
  ]
446
447
  }
447
448
  ),
448
- g && Xl(
449
+ g && Zl(
449
450
  /* @__PURE__ */ t(
450
451
  "div",
451
452
  {
@@ -475,11 +476,11 @@ function yd({
475
476
  }
476
477
  ),
477
478
  (Fe == null ? void 0 : Fe.choose) && (st.isError ? /* @__PURE__ */ t("p", { className: "mb-1.5 px-1 text-[11.5px] text-red-600 dark:text-red-400", children: "Could not load the options." }) : st.isLoading ? /* @__PURE__ */ t("p", { className: "mb-1.5 px-1 text-[11.5px] text-slate-500 dark:text-slate-400", children: "Loading…" }) : Ze != null && Ze.ask ? /* @__PURE__ */ t("div", { className: "mb-1.5 -mt-3 px-1", children: /* @__PURE__ */ t(
478
- bd,
479
+ hd,
479
480
  {
480
481
  choose: Fe.choose,
481
482
  options: st.data ?? [],
482
- value: Qt,
483
+ value: Ut,
483
484
  onChange: At
484
485
  }
485
486
  ) }) : null),
@@ -508,7 +509,7 @@ function yd({
508
509
  {
509
510
  value: $e,
510
511
  onChange: (b) => _t(b.target.value),
511
- placeholder: ((ma = _.push) == null ? void 0 : ma.kind) === "push" ? ((Fa = (ba = _.push.action.confirm) == null ? void 0 : ba.input) == null ? void 0 : Fa.placeholder) ?? ((Tt = (Ae = _.push.action.confirm) == null ? void 0 : Ae.input) == null ? void 0 : Tt.label) ?? "" : (it = _.action) != null && it.require_reason || ((Ue = Ye.find((b) => b.id === _.picked)) == null ? void 0 : Ue.comment_mode) === "required" ? "Reason (required — recorded on the record’s history)…" : "Reason (optional)…",
512
+ placeholder: ((ma = _.push) == null ? void 0 : ma.kind) === "push" ? ((Fa = (ba = _.push.action.confirm) == null ? void 0 : ba.input) == null ? void 0 : Fa.placeholder) ?? ((Tt = (Ae = _.push.action.confirm) == null ? void 0 : Ae.input) == null ? void 0 : Tt.label) ?? "" : (it = _.action) != null && it.require_reason || ((Qe = Ye.find((b) => b.id === _.picked)) == null ? void 0 : Qe.comment_mode) === "required" ? "Reason (required — recorded on the record’s history)…" : "Reason (optional)…",
512
513
  rows: 2,
513
514
  className: "w-full resize-none rounded-md border border-slate-200 bg-white px-2 py-1.5 text-[12px] outline-none focus:border-nvr-cyan/50 dark:border-slate-700 dark:bg-slate-800 dark:text-slate-100"
514
515
  }
@@ -548,7 +549,7 @@ function yd({
548
549
  z(!1), f();
549
550
  }),
550
551
  j && et("Discuss in chat", () => {
551
- z(!1), Wi(I, n, String(i)).then((b) => {
552
+ z(!1), Qi(I, n, String(i)).then((b) => {
552
553
  b || ue.error("This record has no chat room you can open");
553
554
  }).catch(() => ue.error("Could not open the chat room"));
554
555
  }),
@@ -687,13 +688,13 @@ function yd({
687
688
  "button",
688
689
  {
689
690
  type: "button",
690
- onClick: () => Q(!1),
691
+ onClick: () => U(!1),
691
692
  className: "h-7 rounded-md border border-slate-200 px-2.5 text-[12px] text-slate-500 dark:border-slate-700 dark:text-slate-400",
692
693
  children: "Cancel"
693
694
  }
694
695
  )
695
696
  ] })
696
- ] }) : et("Delete", () => Q(!0), !0)
697
+ ] }) : et("Delete", () => U(!0), !0)
697
698
  ] })
698
699
  ] })
699
700
  }
@@ -705,14 +706,14 @@ function yd({
705
706
  function tr(n) {
706
707
  return n === "id" || /(^|_)id$/i.test(n) || /(^|_)uuid$/i.test(n);
707
708
  }
708
- function Vl({
709
+ function Yl({
709
710
  collection: n,
710
711
  field: i,
711
712
  fieldType: m,
712
713
  value: o,
713
714
  relations: f
714
715
  }) {
715
- const y = es(f, n, i);
716
+ const y = ts(f, n, i);
716
717
  if (y != null && y.one_collection)
717
718
  return /* @__PURE__ */ t(ir, { relatedCollection: y.one_collection, id: o });
718
719
  if (o == null) return /* @__PURE__ */ t("span", { className: "text-[12px] text-slate-300", children: "—" });
@@ -733,7 +734,7 @@ function Vl({
733
734
  );
734
735
  return /* @__PURE__ */ t("span", { className: "text-[12px] tabular-nums text-slate-400", children: q });
735
736
  }
736
- return /* @__PURE__ */ t("span", { className: "text-[12px] tabular-nums text-slate-400", children: fd(o) });
737
+ return /* @__PURE__ */ t("span", { className: "text-[12px] tabular-nums text-slate-400", children: gd(o) });
737
738
  }
738
739
  return typeof o == "string" ? /* @__PURE__ */ t(
739
740
  "span",
@@ -863,7 +864,7 @@ function ln({
863
864
  ] })
864
865
  ] });
865
866
  }
866
- function wd({
867
+ function _d({
867
868
  target: n,
868
869
  label: i,
869
870
  selected: m,
@@ -879,12 +880,12 @@ function wd({
879
880
  }), u = $a(L), g = (L == null ? void 0 : L.display_template) ?? null, { data: z = [], isLoading: P } = ae({
880
881
  queryKey: ["cbv-filter-options", n, u, g ?? "", S, I],
881
882
  queryFn: () => {
882
- const W = lr(g, u), O = !!f && f.length > 0, Q = {
883
+ const W = lr(g, u), O = !!f && f.length > 0, U = {
883
884
  limit: S ? 60 : O ? 500 : 100,
884
885
  sort: S || O ? u : "-id",
885
886
  ...W ? { fields: W } : {}
886
887
  };
887
- return S ? Q.search = S : O && (Q.filter = JSON.stringify({ id: { _in: f.slice(0, 500) } })), y.request(Y(`/items/${n}`, Q)).then(
888
+ return S ? U.search = S : O && (U.filter = JSON.stringify({ id: { _in: f.slice(0, 500) } })), y.request(Y(`/items/${n}`, U)).then(
888
889
  (he) => (he.data ?? []).map((j) => ({
889
890
  value: j.id,
890
891
  label: (g ? nn(g, j) : "") || String(j[u] ?? j.id ?? "")
@@ -905,9 +906,9 @@ function wd({
905
906
  ...W ? { fields: W } : {}
906
907
  })
907
908
  ).then(
908
- (O) => (O.data ?? []).map((Q) => ({
909
- value: Q.id,
910
- label: (g ? nn(g, Q) : "") || String(Q[u] ?? Q.id ?? "")
909
+ (O) => (O.data ?? []).map((U) => ({
910
+ value: U.id,
911
+ label: (g ? nn(g, U) : "") || String(U[u] ?? U.id ?? "")
911
912
  }))
912
913
  );
913
914
  },
@@ -934,7 +935,7 @@ function wd({
934
935
  }
935
936
  );
936
937
  }
937
- function _d({
938
+ function Nd({
938
939
  collection: n,
939
940
  field: i,
940
941
  selected: m,
@@ -962,7 +963,7 @@ function _d({
962
963
  }
963
964
  );
964
965
  }
965
- function Nd({
966
+ function Sd({
966
967
  value: n,
967
968
  onChange: i
968
969
  }) {
@@ -984,7 +985,7 @@ function Nd({
984
985
  var g;
985
986
  if (!n) return "All";
986
987
  const u = rr(n);
987
- return u ? $o(u) : ((g = rn.find((z) => z.value === n)) == null ? void 0 : g.label) ?? n;
988
+ return u ? qo(u) : ((g = rn.find((z) => z.value === n)) == null ? void 0 : g.label) ?? n;
988
989
  })(), [A, I] = k("between");
989
990
  ve(() => {
990
991
  var u;
@@ -992,7 +993,7 @@ function Nd({
992
993
  }, [m, n]);
993
994
  const L = () => {
994
995
  const u = f || N;
995
- u && (i(To({ op: A, from: u, to: N || f || u })), o(!1));
996
+ u && (i(Lo({ op: A, from: u, to: N || f || u })), o(!1));
996
997
  };
997
998
  return /* @__PURE__ */ c("div", { ref: C, className: "relative w-full", children: [
998
999
  /* @__PURE__ */ c(
@@ -1037,7 +1038,7 @@ function Nd({
1037
1038
  )) }),
1038
1039
  /* @__PURE__ */ c("div", { className: "border-t border-slate-100 p-2 dark:border-slate-800", children: [
1039
1040
  /* @__PURE__ */ t("p", { className: "pb-1 text-[10px] font-semibold uppercase tracking-wide text-slate-400", children: "Date or range" }),
1040
- /* @__PURE__ */ t("div", { className: "grid grid-cols-3 gap-1 pb-1.5", children: qo.map((u) => /* @__PURE__ */ t(
1041
+ /* @__PURE__ */ t("div", { className: "grid grid-cols-3 gap-1 pb-1.5", children: To.map((u) => /* @__PURE__ */ t(
1041
1042
  "button",
1042
1043
  {
1043
1044
  type: "button",
@@ -1087,7 +1088,7 @@ function Nd({
1087
1088
  ] })
1088
1089
  ] });
1089
1090
  }
1090
- function Sd({
1091
+ function Cd({
1091
1092
  def: n,
1092
1093
  selected: i,
1093
1094
  onChange: m,
@@ -1136,7 +1137,7 @@ function Sd({
1136
1137
  }
1137
1138
  );
1138
1139
  }
1139
- const as = [
1140
+ const ns = [
1140
1141
  { value: "_eq", label: "=" },
1141
1142
  { value: "_neq", label: "≠" },
1142
1143
  { value: "_gt", label: ">" },
@@ -1150,7 +1151,7 @@ const as = [
1150
1151
  { value: "30d", label: "30 days" },
1151
1152
  { value: "90d", label: "90 days" },
1152
1153
  { value: "year", label: "This year" }
1153
- ], Cd = {
1154
+ ], $d = {
1154
1155
  _eq: "_neq",
1155
1156
  _neq: "_eq",
1156
1157
  _in: "_nin",
@@ -1164,7 +1165,7 @@ const as = [
1164
1165
  _lt: "_gte",
1165
1166
  _lte: "_gt"
1166
1167
  };
1167
- function ns(n) {
1168
+ function rs(n) {
1168
1169
  const i = /* @__PURE__ */ new Date(), m = (f) => f.toISOString().slice(0, 10), o = m(i);
1169
1170
  if (n === "today") return { from: o, to: o };
1170
1171
  if (n === "7d" || n === "30d" || n === "90d") {
@@ -1173,7 +1174,7 @@ function ns(n) {
1173
1174
  }
1174
1175
  return n === "year" ? { from: `${i.getFullYear()}-01-01`, to: o } : null;
1175
1176
  }
1176
- function Yl(n) {
1177
+ function Hl(n) {
1177
1178
  var m;
1178
1179
  const i = [];
1179
1180
  for (const o of n) {
@@ -1193,7 +1194,7 @@ function Yl(n) {
1193
1194
  continue;
1194
1195
  }
1195
1196
  if (o.op === "_preset") {
1196
- const q = ns(String(o.value));
1197
+ const q = rs(String(o.value));
1197
1198
  q && (o.not ? i.push({
1198
1199
  or: [
1199
1200
  { path: o.path, op: "_lt", value: q.from },
@@ -1203,11 +1204,11 @@ function Yl(n) {
1203
1204
  continue;
1204
1205
  }
1205
1206
  let y = o.op.includes(":") ? o.op.split(":")[0] : o.op, N = o.op.includes(":") ? o.op.split(":")[1] : o.value || null;
1206
- o.fieldType === "boolean" && (N === "true" || N === "false") && (N = N === "true"), o.not && (y = Cd[y] ?? y), i.push({ path: o.path, op: y, value: N });
1207
+ o.fieldType === "boolean" && (N === "true" || N === "false") && (N = N === "true"), o.not && (y = $d[y] ?? y), i.push({ path: o.path, op: y, value: N });
1207
1208
  }
1208
1209
  return i;
1209
1210
  }
1210
- const Hl = [
1211
+ const Jl = [
1211
1212
  { label: "Contains", value: "_contains" },
1212
1213
  { label: "Doesn't contain", value: "_ncontains" },
1213
1214
  { label: "Equals", value: "_eq" },
@@ -1231,9 +1232,9 @@ const Hl = [
1231
1232
  { label: "After", value: "_gt" },
1232
1233
  { label: "Is empty", value: "_null" },
1233
1234
  { label: "Is not empty", value: "_nnull" }
1234
- ], $d = {
1235
- string: Hl,
1236
- text: Hl,
1235
+ ], qd = {
1236
+ string: Jl,
1237
+ text: Jl,
1237
1238
  integer: ar,
1238
1239
  decimal: ar,
1239
1240
  float: ar,
@@ -1252,8 +1253,8 @@ const Hl = [
1252
1253
  { label: "Is not empty", value: "_nnull" }
1253
1254
  ]
1254
1255
  };
1255
- function qd(n) {
1256
- for (const i of Object.values($d)) {
1256
+ function Td(n) {
1257
+ for (const i of Object.values(qd)) {
1257
1258
  const m = i.find((o) => o.value === n);
1258
1259
  if (m) return m.label;
1259
1260
  }
@@ -1321,7 +1322,7 @@ function dr({
1321
1322
  }
1322
1323
  ),
1323
1324
  g && P && /* @__PURE__ */ t(
1324
- rs,
1325
+ ls,
1325
1326
  {
1326
1327
  aliasInfo: g,
1327
1328
  depth: i + 1,
@@ -1334,7 +1335,7 @@ function dr({
1334
1335
  ] }, L.field);
1335
1336
  }) });
1336
1337
  }
1337
- function rs({
1338
+ function ls({
1338
1339
  aliasInfo: n,
1339
1340
  depth: i,
1340
1341
  path: m,
@@ -1370,12 +1371,12 @@ function rs({
1370
1371
  }
1371
1372
  ) : /* @__PURE__ */ t("div", { className: "px-3 py-1.5", style: { paddingLeft: `${0.5 + i}rem` }, children: /* @__PURE__ */ t("span", { className: "inline-block h-3 w-20 animate-pulse rounded bg-slate-100 dark:bg-[hsl(var(--nvr-skeleton))]" }) });
1372
1373
  }
1373
- function Jl(n, i, m) {
1374
+ function Gl(n, i, m) {
1374
1375
  if (i) return "relation";
1375
1376
  const o = n.type ?? "string";
1376
1377
  return o === "integer" || o === "decimal" || o === "float" ? "number" : o === "datetime" || o === "timestamp" ? "date" : o;
1377
1378
  }
1378
- function Td({
1379
+ function Ld({
1379
1380
  collection: n,
1380
1381
  path: i,
1381
1382
  pathLabels: m,
@@ -1438,18 +1439,18 @@ function Td({
1438
1439
  }
1439
1440
  });
1440
1441
  else if (H) {
1441
- const Q = H.relation.many_collection;
1442
- u(T) && Q && g.push({
1442
+ const U = H.relation.many_collection;
1443
+ u(T) && U && g.push({
1443
1444
  key: v.field,
1444
1445
  label: T,
1445
1446
  hint: H.kind === "m2m" ? "list" : "items",
1446
- drillTo: f < 2 ? { collection: Q, path: W, pathLabels: O } : void 0,
1447
+ drillTo: f < 2 ? { collection: U, path: W, pathLabels: O } : void 0,
1447
1448
  leaf: H.kind === "m2m" ? { path: W, pathLabels: O, fieldType: "relation", relTarget: "" } : void 0
1448
1449
  });
1449
1450
  } else u(T) && g.push({
1450
1451
  key: v.field,
1451
1452
  label: T,
1452
- hint: Jl(v, void 0),
1453
+ hint: Gl(v, void 0),
1453
1454
  leaf: { path: W, pathLabels: O, fieldType: v.type ?? "string" }
1454
1455
  });
1455
1456
  }
@@ -1466,17 +1467,17 @@ function Td({
1466
1467
  if (W.hidden) continue;
1467
1468
  const O = Be(W.field);
1468
1469
  if (!u(O)) continue;
1469
- const Q = Ve(E.relations, T.one_collection, W.field);
1470
+ const U = Ve(E.relations, T.one_collection, W.field);
1470
1471
  z.push({
1471
1472
  key: `${v.field}.${W.field}`,
1472
1473
  label: O,
1473
1474
  breadcrumb: H,
1474
- hint: Jl(W, Q ?? void 0),
1475
+ hint: Gl(W, U ?? void 0),
1475
1476
  leaf: {
1476
1477
  path: [...i, v.field, W.field],
1477
1478
  pathLabels: [...m, H, O],
1478
- fieldType: Q != null && Q.one_collection ? "relation" : W.type ?? "string",
1479
- relTarget: (Q == null ? void 0 : Q.one_collection) ?? void 0
1479
+ fieldType: U != null && U.one_collection ? "relation" : W.type ?? "string",
1480
+ relTarget: (U == null ? void 0 : U.one_collection) ?? void 0
1480
1481
  }
1481
1482
  });
1482
1483
  }
@@ -1520,7 +1521,7 @@ function Td({
1520
1521
  v.key
1521
1522
  )) });
1522
1523
  }
1523
- function Ld({
1524
+ function Fd({
1524
1525
  target: n,
1525
1526
  selected: i,
1526
1527
  labels: m,
@@ -1586,7 +1587,7 @@ function Ld({
1586
1587
  ] })
1587
1588
  ] });
1588
1589
  }
1589
- function Fd(n) {
1590
+ function Rd(n) {
1590
1591
  var m, o;
1591
1592
  const i = n.pathLabels.join(" › ");
1592
1593
  if (Array.isArray(n.value)) {
@@ -1605,9 +1606,9 @@ function Fd(n) {
1605
1606
  const f = ((m = rn.find((y) => y.value === n.value)) == null ? void 0 : m.label) ?? String(n.value);
1606
1607
  return { field: i, op: "in the", value: `${f} (rolling)` };
1607
1608
  }
1608
- return (o = n.path[0]) != null && o.startsWith("$has_") || n.path[0] === "$missing_required" ? { field: i, op: "", value: "" } : { field: i, op: qd(n.op).toLowerCase(), value: String(n.value ?? "") };
1609
+ return (o = n.path[0]) != null && o.startsWith("$has_") || n.path[0] === "$missing_required" ? { field: i, op: "", value: "" } : { field: i, op: Td(n.op).toLowerCase(), value: String(n.value ?? "") };
1609
1610
  }
1610
- function Rd({
1611
+ function Pd({
1611
1612
  collection: n,
1612
1613
  meta: i,
1613
1614
  search: m,
@@ -1619,7 +1620,7 @@ function Rd({
1619
1620
  collection: n,
1620
1621
  path: [],
1621
1622
  pathLabels: []
1622
- }), [L, u] = k(null), [g, z] = k("_contains"), [P, v] = k(""), [T, E] = k(""), [H, W] = k([]), [O, Q] = k({}), [he, j] = k(null), re = me(null);
1623
+ }), [L, u] = k(null), [g, z] = k("_contains"), [P, v] = k(""), [T, E] = k(""), [H, W] = k([]), [O, U] = k({}), [he, j] = k(null), re = me(null);
1623
1624
  ve(() => {
1624
1625
  if (!N) return;
1625
1626
  const x = (J) => {
@@ -1633,7 +1634,7 @@ function Rd({
1633
1634
  };
1634
1635
  }, [N]);
1635
1636
  const Ye = () => {
1636
- S(""), I({ collection: n, path: [], pathLabels: [] }), u(null), z("_contains"), v(""), E(""), W([]), Q({}), j(null);
1637
+ S(""), I({ collection: n, path: [], pathLabels: [] }), u(null), z("_contains"), v(""), E(""), W([]), U({}), j(null);
1637
1638
  }, Oe = () => {
1638
1639
  Ye(), q(!0);
1639
1640
  }, Re = (x) => {
@@ -1668,7 +1669,7 @@ function Rd({
1668
1669
  x.value.forEach((J, $e) => {
1669
1670
  var _t;
1670
1671
  _[String(J)] = ((_t = x.valueLabels) == null ? void 0 : _t[$e]) ?? String(J);
1671
- }), Q(_);
1672
+ }), U(_);
1672
1673
  } else if (u({ path: x.path, pathLabels: x.pathLabels, fieldType: x.fieldType }), z(x.op), x.op === "_between") {
1673
1674
  const [_, J] = String(x.value).split("..");
1674
1675
  v(_ ?? ""), E(J ?? "");
@@ -1679,7 +1680,7 @@ function Rd({
1679
1680
  if (L.relTarget !== void 0) return "relation";
1680
1681
  const x = L.fieldType;
1681
1682
  return x === "integer" || x === "decimal" || x === "float" ? "number" : x === "date" || x === "datetime" || x === "timestamp" ? "date" : x === "boolean" ? "boolean" : "string";
1682
- })(), ke = as, te = [
1683
+ })(), ke = ns, te = [
1683
1684
  { value: "_contains", label: "Contains" },
1684
1685
  { value: "_ncontains", label: "Doesn't contain" },
1685
1686
  { value: "_eq", label: "Equals" },
@@ -1690,7 +1691,7 @@ function Rd({
1690
1691
  return /* @__PURE__ */ c("div", { className: "flex min-w-0 flex-1 flex-wrap items-center gap-2", children: [
1691
1692
  /* @__PURE__ */ c("div", { className: "relative", children: [
1692
1693
  /* @__PURE__ */ t(
1693
- Gl,
1694
+ Xl,
1694
1695
  {
1695
1696
  "aria-hidden": !0,
1696
1697
  className: "pointer-events-none absolute left-2.5 top-1/2 h-4 w-4 -translate-y-1/2 text-slate-400"
@@ -1708,7 +1709,7 @@ function Rd({
1708
1709
  )
1709
1710
  ] }),
1710
1711
  f.map((x) => {
1711
- const _ = Fd(x);
1712
+ const _ = Rd(x);
1712
1713
  return /* @__PURE__ */ c(
1713
1714
  "span",
1714
1715
  {
@@ -1819,7 +1820,7 @@ function Rd({
1819
1820
  x
1820
1821
  )) }),
1821
1822
  /* @__PURE__ */ t(
1822
- Td,
1823
+ Ld,
1823
1824
  {
1824
1825
  collection: A.collection,
1825
1826
  path: A.path,
@@ -1854,7 +1855,7 @@ function Rd({
1854
1855
  ),
1855
1856
  X === "relation" && L.relTarget ? /* @__PURE__ */ c("div", { className: "pt-2", children: [
1856
1857
  /* @__PURE__ */ t(
1857
- Ld,
1858
+ Fd,
1858
1859
  {
1859
1860
  target: L.relTarget,
1860
1861
  selected: H,
@@ -1862,7 +1863,7 @@ function Rd({
1862
1863
  onToggle: (x, _) => {
1863
1864
  W(
1864
1865
  (J) => J.map(String).includes(String(x)) ? J.filter(($e) => String($e) !== String(x)) : [...J, x]
1865
- ), Q((J) => ({ ...J, [String(x)]: _ }));
1866
+ ), U((J) => ({ ...J, [String(x)]: _ }));
1866
1867
  }
1867
1868
  }
1868
1869
  ),
@@ -2023,7 +2024,7 @@ function Rd({
2023
2024
  ] })
2024
2025
  ] });
2025
2026
  }
2026
- function Pd({
2027
+ function Ed({
2027
2028
  collection: n,
2028
2029
  meta: i,
2029
2030
  onPick: m
@@ -2064,7 +2065,7 @@ function Pd({
2064
2065
  }
2065
2066
  ),
2066
2067
  S && C && /* @__PURE__ */ t(
2067
- rs,
2068
+ ls,
2068
2069
  {
2069
2070
  aliasInfo: C,
2070
2071
  depth: 1,
@@ -2077,7 +2078,7 @@ function Pd({
2077
2078
  ] }, N.field);
2078
2079
  }) });
2079
2080
  }
2080
- function Ed({
2081
+ function Md({
2081
2082
  collection: n,
2082
2083
  ids: i,
2083
2084
  onDone: m,
@@ -2157,7 +2158,7 @@ function Ed({
2157
2158
  )
2158
2159
  ] });
2159
2160
  }
2160
- function Md({
2161
+ function Dd({
2161
2162
  collection: n,
2162
2163
  selectedIds: i,
2163
2164
  onDone: m,
@@ -2175,7 +2176,7 @@ function Md({
2175
2176
  })
2176
2177
  ),
2177
2178
  enabled: S || I
2178
- }), O = S || I ? (W == null ? void 0 : W.count) ?? null : 0, Q = async () => {
2179
+ }), O = S || I ? (W == null ? void 0 : W.count) ?? null : 0, U = async () => {
2179
2180
  if (!(!y.trim() || !q.trim())) {
2180
2181
  T(!0), H(null);
2181
2182
  try {
@@ -2200,7 +2201,7 @@ function Md({
2200
2201
  {
2201
2202
  className: "flex flex-wrap items-center gap-1.5",
2202
2203
  onSubmit: (j) => {
2203
- j.preventDefault(), Q();
2204
+ j.preventDefault(), U();
2204
2205
  },
2205
2206
  children: [
2206
2207
  /* @__PURE__ */ c("label", { className: "flex cursor-pointer items-center gap-1 text-[12px] text-slate-300 dark:text-muted-foreground", children: [
@@ -2309,7 +2310,7 @@ function Md({
2309
2310
  }
2310
2311
  );
2311
2312
  }
2312
- function Dd({
2313
+ function Od({
2313
2314
  collection: n,
2314
2315
  selectedIds: i,
2315
2316
  transitions: m,
@@ -2319,7 +2320,7 @@ function Dd({
2319
2320
  onClear: N,
2320
2321
  onSuccess: q
2321
2322
  }) {
2322
- const C = an(), S = lt(), A = sr(), I = Zl(), [L, u] = k("actions"), g = gi([n], y), { data: z = [] } = ae({
2323
+ const C = an(), S = lt(), A = sr(), I = es(), [L, u] = k("actions"), g = xi([n], y), { data: z = [] } = ae({
2323
2324
  queryKey: ["bulk-recipes", n],
2324
2325
  queryFn: () => S.request(Y("/bulk-recipes", { collection: n })).then((F) => F.data ?? []).catch(() => []),
2325
2326
  staleTime: 6e4
@@ -2369,17 +2370,17 @@ function Dd({
2369
2370
  return _.failed > 0 ? `${F.name}: ${_.succeeded} done, ${_.failed} failed` : `${F.name}: transitioned ${_.succeeded} items`;
2370
2371
  });
2371
2372
  }
2372
- }, [O, Q] = k(!1), [he, j] = k(""), [re, Ye] = k(!1), [Oe, Re] = k(null), _e = async (F) => {
2373
+ }, [O, U] = k(!1), [he, j] = k(""), [re, Ye] = k(!1), [Oe, Re] = k(null), _e = async (F) => {
2373
2374
  Ye(!0), Re(null);
2374
- const X = _o();
2375
- No(X, i);
2375
+ const X = No();
2376
+ So(X, i);
2376
2377
  try {
2377
2378
  const ke = await F(X);
2378
2379
  Re(ke), q(), N(), u("actions");
2379
2380
  } catch (ke) {
2380
2381
  Re(Ct(ke, "Bulk action failed"));
2381
2382
  } finally {
2382
- So(X), Ye(!1);
2383
+ Co(X), Ye(!1);
2383
2384
  }
2384
2385
  }, Le = (F, X) => void _e(async (ke) => {
2385
2386
  const te = await S.request(
@@ -2418,13 +2419,13 @@ function Dd({
2418
2419
  " selected"
2419
2420
  ] }),
2420
2421
  O && /* @__PURE__ */ t(
2421
- sd,
2422
+ od,
2422
2423
  {
2423
2424
  collection: n,
2424
2425
  ids: i.slice(0, 3),
2425
2426
  fields: o,
2426
- renderValue: (F, X) => Od(n, f, F, X),
2427
- onClose: () => Q(!1)
2427
+ renderValue: (F, X) => Ad(n, f, F, X),
2428
+ onClose: () => U(!1)
2428
2429
  }
2429
2430
  ),
2430
2431
  Oe && /* @__PURE__ */ t("span", { className: "text-[12px] text-slate-300 dark:text-muted-foreground", children: Oe }),
@@ -2468,13 +2469,13 @@ function Dd({
2468
2469
  {
2469
2470
  type: "button",
2470
2471
  onClick: () => {
2471
- const F = Jo(
2472
+ const F = Go(
2472
2473
  i.map((X) => I.urlFor({ collection: n, itemId: String(X) }))
2473
2474
  );
2474
2475
  F.blocked > 0 || F.capped > 0 ? ue.warning(Al(F)) : ue.success(Al(F));
2475
2476
  },
2476
2477
  "data-bulk-open-tabs": !0,
2477
- title: `Open the selected records in new tabs (up to ${Ho})`,
2478
+ title: `Open the selected records in new tabs (up to ${Jo})`,
2478
2479
  className: "h-8 rounded-md border border-white/20 dark:border-border px-3 text-[12.5px] font-medium hover:bg-white/10 dark:hover:bg-muted",
2479
2480
  children: "Open in tabs"
2480
2481
  }
@@ -2483,7 +2484,7 @@ function Dd({
2483
2484
  "button",
2484
2485
  {
2485
2486
  type: "button",
2486
- onClick: () => Q(!0),
2487
+ onClick: () => U(!0),
2487
2488
  className: "h-8 rounded-md border border-white/20 dark:border-border px-3 text-[12.5px] font-medium hover:bg-white/10 dark:hover:bg-muted",
2488
2489
  children: "Compare"
2489
2490
  }
@@ -2499,7 +2500,7 @@ function Dd({
2499
2500
  }
2500
2501
  ),
2501
2502
  /* @__PURE__ */ t(
2502
- xi,
2503
+ vi,
2503
2504
  {
2504
2505
  targets: i.map((F) => ({ collection: n, id: F })),
2505
2506
  enabledKeys: y,
@@ -2511,7 +2512,7 @@ function Dd({
2511
2512
  }
2512
2513
  ),
2513
2514
  g("update-field") && /* @__PURE__ */ t(
2514
- vi,
2515
+ ki,
2515
2516
  {
2516
2517
  collection: n,
2517
2518
  selectedIds: i,
@@ -2552,7 +2553,7 @@ function Dd({
2552
2553
  )
2553
2554
  ] }),
2554
2555
  L === "merge" && /* @__PURE__ */ t(
2555
- Ed,
2556
+ Md,
2556
2557
  {
2557
2558
  collection: n,
2558
2559
  ids: i.slice(0, 2),
@@ -2563,7 +2564,7 @@ function Dd({
2563
2564
  }
2564
2565
  ),
2565
2566
  L === "message" && /* @__PURE__ */ t(
2566
- Md,
2567
+ Dd,
2567
2568
  {
2568
2569
  collection: n,
2569
2570
  selectedIds: i,
@@ -2590,7 +2591,7 @@ function Dd({
2590
2591
  },
2591
2592
  children: [
2592
2593
  /* @__PURE__ */ t(
2593
- ud,
2594
+ pd,
2594
2595
  {
2595
2596
  value: he,
2596
2597
  onChange: j,
@@ -2711,7 +2712,7 @@ function Dd({
2711
2712
  }
2712
2713
  );
2713
2714
  }
2714
- function Jc({
2715
+ function Xc({
2715
2716
  collection: n,
2716
2717
  quickFilters: i = [],
2717
2718
  initialColumns: m,
@@ -2727,7 +2728,7 @@ function Jc({
2727
2728
  className: L
2728
2729
  }) {
2729
2730
  var vl, kl, yl, wl, _l, Nl, Sl, Cl, $l, ql, Tl;
2730
- const u = lt(), g = sr(), { open: z, urlFor: P } = Zl(), [v, T] = k(1), E = me(Eo()), [H, W] = k(y), O = Ml(H.trim(), 350), [Q, he] = k(N ?? []), [j, re] = k(o ?? ""), [Ye, Oe] = k(m ?? null), [Re, _e] = k({}), [Le, F] = k({}), [X, ke] = k(null), [te, x] = k({}), [_, J] = k({}), [$e, _t] = k({}), [Fe, st] = k({}), [Qt, At] = k(null), [sn, Ze] = k(!1), ua = me(null), [La, xt] = k({}), [ot, bt] = k({}), [et, $t] = k(q ?? []), { scopes: Nt, ready: pa } = si(), [qt, ma] = k(!1), [ba, Fa] = k(/* @__PURE__ */ new Set()), [Ae, Tt] = k({}), it = vo("drill.browser"), Ue = it.value, [ha, Vt] = k(null), [Yt, jt] = k(!1), [It, Ra] = k(() => {
2731
+ const u = lt(), g = sr(), { open: z, urlFor: P } = es(), [v, T] = k(1), E = me(Mo()), [H, W] = k(y), O = Ml(H.trim(), 350), [U, he] = k(N ?? []), [j, re] = k(o ?? ""), [Ye, Oe] = k(m ?? null), [Re, _e] = k({}), [Le, F] = k({}), [X, ke] = k(null), [te, x] = k({}), [_, J] = k({}), [$e, _t] = k({}), [Fe, st] = k({}), [Ut, At] = k(null), [sn, Ze] = k(!1), ua = me(null), [La, xt] = k({}), [ot, bt] = k({}), [et, $t] = k(q ?? []), { scopes: Nt, ready: pa } = oi(), [qt, ma] = k(!1), [ba, Fa] = k(/* @__PURE__ */ new Set()), [Ae, Tt] = k({}), it = ko("drill.browser"), Qe = it.value, [ha, Vt] = k(null), [Yt, jt] = k(!1), [It, Ra] = k(() => {
2731
2732
  try {
2732
2733
  return localStorage.getItem("nvr_table_density") === "comfortable" ? "comfortable" : "compact";
2733
2734
  } catch {
@@ -2767,7 +2768,7 @@ function Jc({
2767
2768
  const a = e.status, r = (l = e.response) == null ? void 0 : l.error;
2768
2769
  a === 503 ? ue.error("AI is not configured — add an Anthropic API key in Settings.") : ue.error(r ?? "Could not answer that question");
2769
2770
  }
2770
- }), ls = () => {
2771
+ }), ss = () => {
2771
2772
  pr(null), cn("");
2772
2773
  }, mr = me(!1);
2773
2774
  ve(() => {
@@ -2782,8 +2783,8 @@ function Jc({
2782
2783
  };
2783
2784
  }, [ie]);
2784
2785
  const [Kt, Jt] = k([]);
2785
- wo();
2786
- const [Gt, Pa] = k(null), [ss, pn] = k(!1), [Bt, mn] = k(""), [bn, hr] = k(!1), [os, fr] = k(!1), [hn, Xt] = k(!1), gr = me(null);
2786
+ _o();
2787
+ const [Gt, Pa] = k(null), [os, pn] = k(!1), [Bt, mn] = k(""), [bn, hr] = k(!1), [is, fr] = k(!1), [hn, Xt] = k(!1), gr = me(null);
2787
2788
  ve(() => {
2788
2789
  if (!hn) return;
2789
2790
  const e = (a) => {
@@ -2794,7 +2795,7 @@ function Jc({
2794
2795
  }, [hn]);
2795
2796
  const xr = me(null), vr = me(null), fn = me(!1), { isAdmin: Zt } = an(), kr = me(n);
2796
2797
  ve(() => {
2797
- kr.current !== n && (kr.current = n, T(1), W(y), he([]), re(o ?? ""), Oe(m ?? null), _e({}), F({}), x({}), J({}), Jt([]), Pa(null), xt({}), bt({}), Tt({}), $t([]), Ue != null && Ue.length && it.back(Ue.length), Vt(null), fn.current = !1);
2798
+ kr.current !== n && (kr.current = n, T(1), W(y), he([]), re(o ?? ""), Oe(m ?? null), _e({}), F({}), x({}), J({}), Jt([]), Pa(null), xt({}), bt({}), Tt({}), $t([]), Qe != null && Qe.length && it.back(Qe.length), Vt(null), fn.current = !1);
2798
2799
  }, [n]), ve(() => {
2799
2800
  if (!Yt) return;
2800
2801
  const e = (a) => {
@@ -2815,32 +2816,32 @@ function Jc({
2815
2816
  queryFn: () => u.request(Y(`/collections/${n}`)).then((e) => e.data),
2816
2817
  staleTime: 10 * 6e4,
2817
2818
  retry: !1
2818
- }), Ft = we(() => ((D == null ? void 0 : D.fields) ?? []).filter((e) => !e.hidden), [D]), De = (D == null ? void 0 : D.browser_config) ?? {}, Qe = (vl = De.fulfilment) != null && vl.shipped_field && ((kl = De.fulfilment) != null && kl.requested_field) ? De.fulfilment : null, yr = me(!1);
2819
+ }), Ft = we(() => ((D == null ? void 0 : D.fields) ?? []).filter((e) => !e.hidden), [D]), De = (D == null ? void 0 : D.browser_config) ?? {}, Ue = (vl = De.fulfilment) != null && vl.shipped_field && ((kl = De.fulfilment) != null && kl.requested_field) ? De.fulfilment : null, yr = me(!1);
2819
2820
  ve(() => {
2820
2821
  yr.current || !D || (yr.current = !0, !o && !j && De.default_sort && re(De.default_sort));
2821
2822
  }, [D]);
2822
- const Rt = De.checkbox_selection !== !1, wr = De.show_actions !== !1, Ea = I && De.allow_create !== !1, Ma = di(Ea && !(D != null && D.singleton) ? n : null), [gn, xa] = k(!1), [xn, Da] = k(null), { steps: vn } = td(
2823
+ const Rt = De.checkbox_selection !== !1, wr = De.show_actions !== !1, Ea = I && De.allow_create !== !1, Ma = ci(Ea && !(D != null && D.singleton) ? n : null), [gn, xa] = k(!1), [xn, Da] = k(null), { steps: vn } = ad(
2823
2824
  Ea && !(D != null && D.singleton) ? n : null,
2824
2825
  null
2825
2826
  ), _r = (e) => {
2826
2827
  e ? z({ collection: n, itemId: "new", layoutSlug: e }) : sa("new");
2827
- }, va = Gi(Ea && !(D != null && D.singleton) ? n : null), is = ko(), Nr = me(null), [ds, cs] = k(null), [Sr, Cr] = k(!1), $r = (e) => {
2828
+ }, va = Xi(Ea && !(D != null && D.singleton) ? n : null), ds = yo(), Nr = me(null), [cs, us] = k(null), [Sr, Cr] = k(!1), $r = (e) => {
2828
2829
  var a;
2829
- cs(e), (a = Nr.current) == null || a.click();
2830
- }, us = async (e) => {
2830
+ us(e), (a = Nr.current) == null || a.click();
2831
+ }, ps = async (e) => {
2831
2832
  const a = Array.from(e.target.files ?? []);
2832
2833
  if (e.target.value = "", !!a.length) {
2833
2834
  Cr(!0);
2834
2835
  try {
2835
- const r = await Xi(is, a, n);
2836
- z({ collection: n, itemId: "new", layoutSlug: ds, query: { autofill: r } });
2836
+ const r = await Zi(ds, a, n);
2837
+ z({ collection: n, itemId: "new", layoutSlug: cs, query: { autofill: r } });
2837
2838
  } catch (r) {
2838
2839
  ue.error(r.message);
2839
2840
  } finally {
2840
2841
  Cr(!1);
2841
2842
  }
2842
2843
  }
2843
- }, ps = (e) => Array.isArray(e == null ? void 0 : e.quick_picker) ? e.quick_picker.filter((a) => typeof a == "string") : [], kn = me(null), qr = me(null);
2844
+ }, ms = (e) => Array.isArray(e == null ? void 0 : e.quick_picker) ? e.quick_picker.filter((a) => typeof a == "string") : [], kn = me(null), qr = me(null);
2844
2845
  ve(() => {
2845
2846
  if (!gn) return;
2846
2847
  const e = (a) => {
@@ -2862,9 +2863,9 @@ function Jc({
2862
2863
  for (const l of Pt) {
2863
2864
  const s = Il(e, { key: l.key, collection: l.collection });
2864
2865
  if (!s) continue;
2865
- const d = oi(e, s.name);
2866
+ const d = ii(e, s.name);
2866
2867
  if (d.length === 0) continue;
2867
- const p = await ii(u, s, d, l.value_field).catch(
2868
+ const p = await di(u, s, d, l.value_field).catch(
2868
2869
  () => []
2869
2870
  );
2870
2871
  p.length > 0 && (r[l.key] = p);
@@ -2890,17 +2891,17 @@ function Jc({
2890
2891
  ), [Ye, Ft, vt, Le]), [yn, Oa] = k(null), ka = we(
2891
2892
  () => yn ?? (ce[0] ? { [ce[0]]: "left" } : {}),
2892
2893
  [yn, ce]
2893
- ), ht = (e) => ka[e], ms = (e) => {
2894
+ ), ht = (e) => ka[e], bs = (e) => {
2894
2895
  const a = { ...ka }, r = a[e];
2895
2896
  r ? r === "left" ? a[e] = "right" : delete a[e] : a[e] = "left", Oa(a);
2896
2897
  }, dt = (e) => Re[e] ?? (e.startsWith("__f:") ? Le[e] ?? "Formula" : e.includes(".") ? e.split(".").map(Be).join(" › ") : e === "id" ? "ID" : Be(e)), Lr = (e, a) => {
2897
2898
  var l, s, d;
2898
2899
  const r = a.includes(".") ? (d = (s = (l = ge == null ? void 0 : ge.rows) == null ? void 0 : l[String(e.id)]) == null ? void 0 : s[a]) == null ? void 0 : d.value : e[a];
2899
2900
  return typeof r == "string" && /^-?\d+(\.\d+)?$/.test(r.trim()) ? Number(r) : r;
2900
- }, bs = (e, a) => {
2901
+ }, hs = (e, a) => {
2901
2902
  const r = Le[a];
2902
2903
  return r ? Dl(r, (l) => Lr(e, l)) : null;
2903
- }, hs = (e, a) => {
2904
+ }, fs = (e, a) => {
2904
2905
  const r = Le[a];
2905
2906
  if (r)
2906
2907
  return r.replace(/\{\{\s*([^}]+?)\s*\}\}/g, (l, s) => {
@@ -2969,7 +2970,7 @@ function Jc({
2969
2970
  }
2970
2971
  }
2971
2972
  return e;
2972
- }, [Et, zt, Pr]), fs = we(() => {
2973
+ }, [Et, zt, Pr]), gs = we(() => {
2973
2974
  const e = {};
2974
2975
  for (const a of Et)
2975
2976
  if (a.info.kind === "o2m")
@@ -2981,9 +2982,9 @@ function Jc({
2981
2982
  s != null && s.one_collection && (e[a.field] = { kind: "m2m", target: s.one_collection });
2982
2983
  }
2983
2984
  return e;
2984
- }, [Et, zt]), Er = Ml(Ae, 350), [Aa, gs] = k(!1), [Mr, xs] = k(null), ya = Mi(n, Mr), [ft, Dr] = k(null), { data: wa } = Si(n), [Mt, ja] = k([]), fe = we(() => {
2985
+ }, [Et, zt]), Er = Ml(Ae, 350), [Aa, xs] = k(!1), [Mr, vs] = k(null), ya = Di(n, Mr), [ft, Dr] = k(null), { data: wa } = Ci(n), [Mt, ja] = k([]), fe = we(() => {
2985
2986
  var a;
2986
- const e = Yl(Q);
2987
+ const e = Hl(U);
2987
2988
  for (const r of Pt) {
2988
2989
  const l = ot[r.key] ?? [];
2989
2990
  l.length !== 0 && ((a = r.or_paths) != null && a.length ? e.push({
@@ -2995,8 +2996,8 @@ function Jc({
2995
2996
  if (l.kind === "in" && l.value.length) e.push({ path: [r], op: "_in", value: l.value });
2996
2997
  else if (l.kind === "state" && l.value.length)
2997
2998
  e.push({ path: ["$state"], op: "_in", value: l.value });
2998
- else if (l.kind === "fulfilment" && Qe) {
2999
- const s = Qe.shipped_field, d = Qe.remaining_field ?? null;
2999
+ else if (l.kind === "fulfilment" && Ue) {
3000
+ const s = Ue.shipped_field, d = Ue.remaining_field ?? null;
3000
3001
  l.value === "none" ? e.push({
3001
3002
  or: [
3002
3003
  { path: [s], op: "_null", value: !0 },
@@ -3020,7 +3021,7 @@ function Jc({
3020
3021
  e.push({ path: [r], op: l.op, value: Number(l.value) });
3021
3022
  else if (l.kind === "bool") e.push({ path: [r], op: "_eq", value: l.value === "true" });
3022
3023
  else if (l.kind === "date" && l.value) {
3023
- const s = rr(l.value), p = (s ? Co(s) : null) ?? ns(l.value);
3024
+ const s = rr(l.value), p = (s ? $o(s) : null) ?? rs(l.value);
3024
3025
  p && (p.from && e.push({ path: [r], op: "_gte", value: p.from }), p.to && e.push({ path: [r], op: "_lte", value: `${p.to}T23:59:59` }));
3025
3026
  }
3026
3027
  }
@@ -3036,7 +3037,7 @@ function Jc({
3036
3037
  or: Mt.map((r) => ({ path: ["$at_risk"], op: "_eq", value: r }))
3037
3038
  }), e.length > 0 ? JSON.stringify(e) : void 0;
3038
3039
  }, [
3039
- Q,
3040
+ U,
3040
3041
  Pt,
3041
3042
  ot,
3042
3043
  Er,
@@ -3050,7 +3051,7 @@ function Jc({
3050
3051
  if (!a || !r) return null;
3051
3052
  const l = e.find((s) => ["name", "title", "label", "short_name"].includes(s.toLowerCase())) ?? null;
3052
3053
  return { latField: a, lngField: r, labelField: l };
3053
- }, [D]), [Ia, Or] = k(!1), [Ar, vs] = k(!1), jr = me(fe);
3054
+ }, [D]), [Ia, Or] = k(!1), [Ar, ks] = k(!1), jr = me(fe);
3054
3055
  ve(() => {
3055
3056
  jr.current !== fe && (jr.current = fe, T(1));
3056
3057
  }, [fe]);
@@ -3082,7 +3083,7 @@ function Jc({
3082
3083
  tt,
3083
3084
  fe,
3084
3085
  _a
3085
- ]), s = E.current, d = Mo(s, l, e, j);
3086
+ ]), s = E.current, d = Do(s, l, e, j);
3086
3087
  if (d.after === void 0 && d.sort === j) return r(e);
3087
3088
  try {
3088
3089
  const p = await u.request(
@@ -3092,16 +3093,16 @@ function Jc({
3092
3093
  ...d.sort ? { sort: d.sort } : {}
3093
3094
  })
3094
3095
  );
3095
- return d.after !== void 0 && Do(s, l, e, p.next_cursor), p;
3096
+ return d.after !== void 0 && Oo(s, l, e, p.next_cursor), p;
3096
3097
  } catch (p) {
3097
- if (!Oo(p)) throw p;
3098
- return Ao(s, l), r(e);
3098
+ if (!Ao(p)) throw p;
3099
+ return jo(s, l), r(e);
3099
3100
  }
3100
3101
  }, {
3101
3102
  data: Ce,
3102
3103
  isLoading: Br,
3103
3104
  isFetching: Wt,
3104
- dataUpdatedAt: ks,
3105
+ dataUpdatedAt: ys,
3105
3106
  refetch: Nn,
3106
3107
  error: Je
3107
3108
  } = ae({
@@ -3113,7 +3114,7 @@ function Jc({
3113
3114
  refetchInterval: De.live_events === "off" ? 3e4 : !1,
3114
3115
  retry: !1
3115
3116
  });
3116
- Xo({
3117
+ Zo({
3117
3118
  qc: g,
3118
3119
  enabled: !!n && qt && !w && !O && !Wt && !!Ce && v * tt < (Ce.total ?? 0),
3119
3120
  queryKey: Ir(v + 1),
@@ -3152,37 +3153,37 @@ function Jc({
3152
3153
  ...Cn ? { conditions: Cn } : {}
3153
3154
  })
3154
3155
  ).then((e) => Number(e.total ?? 0))
3155
- }), ys = () => {
3156
+ }), ws = () => {
3156
3157
  const e = Na.map((r) => r.key), a = (r) => {
3157
3158
  const l = { ...r };
3158
3159
  for (const s of e) l[s] = [];
3159
3160
  return l;
3160
3161
  };
3161
3162
  xt(a), bt(a), T(1);
3162
- }, Ur = me(Date.now()), za = me(null);
3163
+ }, Qr = me(Date.now()), za = me(null);
3163
3164
  ve(() => {
3164
- Ur.current = Date.now();
3165
+ Qr.current = Date.now();
3165
3166
  }, [n, O]), ve(() => {
3166
3167
  var a, r;
3167
3168
  if (!n || O.length < 2 || !Ce || Wt || Me) return;
3168
3169
  const e = `${n}\0${O}`;
3169
3170
  ((a = za.current) == null ? void 0 : a.key) !== e && (za.current = {
3170
3171
  key: e,
3171
- id: ri(u, {
3172
+ id: li(u, {
3172
3173
  surface: "collection",
3173
3174
  collection: n,
3174
3175
  query: O,
3175
3176
  result_count: Ce.total ?? ((r = Ce.data) == null ? void 0 : r.length) ?? 0,
3176
- duration_ms: Date.now() - Ur.current
3177
+ duration_ms: Date.now() - Qr.current
3177
3178
  })
3178
3179
  });
3179
- }, [u, n, O, Ce, Wt, Me]), pi(
3180
+ }, [u, n, O, Ce, Wt, Me]), mi(
3180
3181
  n ? {
3181
3182
  list: {
3182
3183
  collection: n,
3183
3184
  label: (D == null ? void 0 : D.display_name) || n,
3184
3185
  ids: xe.slice(0, 100).map((e) => String(e.id)),
3185
- filters: Q.map((e) => ({
3186
+ filters: U.map((e) => ({
3186
3187
  path: e.path.join("."),
3187
3188
  op: e.op,
3188
3189
  value: e.value,
@@ -3193,12 +3194,12 @@ function Jc({
3193
3194
  }
3194
3195
  } : null
3195
3196
  );
3196
- const ws = mi(), Qr = yo(Wt), $n = ti(), { userId: qn } = an(), kt = Io(), Tn = me(/* @__PURE__ */ new Set());
3197
+ const _s = bi(), Ur = wo(Wt), $n = ai(), { userId: qn } = an(), kt = Ko(), Tn = me(/* @__PURE__ */ new Set());
3197
3198
  Tn.current = new Set(xe.map((e) => String(e.id)));
3198
- const _s = we(
3199
+ const Ns = we(
3199
3200
  () => xe.slice(0, 100).map((e) => ({ collection: n, item: String(e.id) })),
3200
3201
  [xe, n]
3201
- ), Vr = ei(_s), Yr = me([]);
3202
+ ), Vr = ti(Ns), Yr = me([]);
3202
3203
  Yr.current = [
3203
3204
  "cbv-items",
3204
3205
  n,
@@ -3221,14 +3222,14 @@ function Jc({
3221
3222
  page: v,
3222
3223
  grouped: !!w
3223
3224
  };
3224
- const Ln = me({}).current, [Ns, Ss] = k(0), [Fn, Rn] = k(0);
3225
+ const Ln = me({}).current, [Ss, Cs] = k(0), [Fn, Rn] = k(0);
3225
3226
  ve(() => {
3226
3227
  if (!$n || !n) return;
3227
3228
  const e = (ne = 1) => Rn((K) => K + ne), a = /* @__PURE__ */ new Map();
3228
3229
  let r = null;
3229
3230
  const l = (ne) => {
3230
3231
  const K = (h) => a.set(JSON.stringify(h), h);
3231
- ne.includes(da.tasks) && K(["cbv-task-counts", n]), ne.includes(da.addendums) && K(["cbv-addendum-summary", n]), ne.includes(da.integrations) && K(["cbv-integrations-summary", n]), ne.includes(da.comments) && K(["row-comment-counts", n]), ne.includes(da.state) && (K(["cbv-pipeline-instances", n]), K(["cbv-owners", n]), K(["cbv-view-count", n])), ne.includes(da.lock) && Ss((h) => h + 1), !r && (r = setTimeout(() => {
3232
+ ne.includes(da.tasks) && K(["cbv-task-counts", n]), ne.includes(da.addendums) && K(["cbv-addendum-summary", n]), ne.includes(da.integrations) && K(["cbv-integrations-summary", n]), ne.includes(da.comments) && K(["row-comment-counts", n]), ne.includes(da.state) && (K(["cbv-pipeline-instances", n]), K(["cbv-owners", n]), K(["cbv-view-count", n])), ne.includes(da.lock) && Cs((h) => h + 1), !r && (r = setTimeout(() => {
3232
3233
  r = null;
3233
3234
  for (const h of a.values()) g.invalidateQueries({ queryKey: h });
3234
3235
  a.clear();
@@ -3261,8 +3262,8 @@ function Jc({
3261
3262
  });
3262
3263
  }
3263
3264
  h && e();
3264
- const B = Tn.current, Xe = (V) => Go(n, V.item), yt = (V) => {
3265
- const oe = Qo(V);
3265
+ const B = Tn.current, Xe = (V) => Xo(n, V.item), yt = (V) => {
3266
+ const oe = Vo(V);
3266
3267
  return oe && qn && oe.toUpperCase() === qn.toUpperCase() ? "self" : oe;
3267
3268
  }, ut = [];
3268
3269
  for (const [V, oe] of K)
@@ -3276,9 +3277,9 @@ function Jc({
3276
3277
  }
3277
3278
  if (K.size === 0) return;
3278
3279
  const pt = Hr.current;
3279
- let Ut;
3280
+ let Qt;
3280
3281
  try {
3281
- Ut = await zo(
3282
+ Qt = await Wo(
3282
3283
  u,
3283
3284
  n,
3284
3285
  [...K.keys()],
@@ -3302,10 +3303,10 @@ function Jc({
3302
3303
  return;
3303
3304
  }
3304
3305
  if (M) return;
3305
- const U = Wo(pt.conditions), G = pt.page === 1 && !pt.grouped, $ = /* @__PURE__ */ new Map(), de = [], ze = [];
3306
+ const Q = Qo(pt.conditions), G = pt.page === 1 && !pt.grouped, $ = /* @__PURE__ */ new Map(), de = [], ze = [];
3306
3307
  for (const [V, oe] of K) {
3307
- const ee = Ut.get(V);
3308
- B.has(V) ? ee ? $.set(V, ee) : de.push(V) : ee && ((oe.action === "create" || !!pt.conditions && Uo(oe, U)) && G ? ze.push({ row: ee, ev: oe }) : e());
3308
+ const ee = Qt.get(V);
3309
+ B.has(V) ? ee ? $.set(V, ee) : de.push(V) : ee && ((oe.action === "create" || !!pt.conditions && Uo(oe, Q)) && G ? ze.push({ row: ee, ev: oe }) : e());
3309
3310
  }
3310
3311
  if ($.size > 0 || de.length > 0 || ze.length > 0) {
3311
3312
  const V = new Set(de);
@@ -3330,7 +3331,7 @@ function Jc({
3330
3331
  yt(V) !== "self" && kt.note([ee], yt(V), "create");
3331
3332
  }
3332
3333
  }, Z = (ne) => {
3333
- for (const K of ne.flatMap((h) => jo(h))) {
3334
+ for (const K of ne.flatMap((h) => Io(h))) {
3334
3335
  const h = K.changed_fields;
3335
3336
  if (!K.action && (h != null && h.length) && h.every((B) => B.startsWith("$"))) {
3336
3337
  (String(K.item) === "*" || Tn.current.has(String(K.item))) && l(h);
@@ -3341,16 +3342,16 @@ function Jc({
3341
3342
  d.length > 0 && !p && (p = setTimeout(() => void Se(), 300));
3342
3343
  }, se = $n.subscribeCollections(
3343
3344
  [n],
3344
- (ne) => Fo(Ln, [ne], Z)
3345
+ (ne) => Ro(Ln, [ne], Z)
3345
3346
  );
3346
3347
  return () => {
3347
- M = !0, se(), Ro(Ln), r && clearTimeout(r), p && clearTimeout(p), R && clearTimeout(R);
3348
+ M = !0, se(), Po(Ln), r && clearTimeout(r), p && clearTimeout(p), R && clearTimeout(R);
3348
3349
  };
3349
3350
  }, [$n, n, g, u, qn, kt, Ln]);
3350
- const Cs = Ko(
3351
+ const $s = Bo(
3351
3352
  n,
3352
3353
  xe.map((e) => String(e.id)),
3353
- Ns
3354
+ Ss
3354
3355
  ), { data: Pn = [] } = ae({
3355
3356
  queryKey: ["cbv-risk-rules", n],
3356
3357
  queryFn: () => u.request(
@@ -3359,10 +3360,10 @@ function Jc({
3359
3360
  enabled: !!n,
3360
3361
  staleTime: 6e4,
3361
3362
  retry: !1
3362
- }), $s = xe.map((e) => String(e.id)).join(","), {
3363
- data: qs = {}
3363
+ }), qs = xe.map((e) => String(e.id)).join(","), {
3364
+ data: Ts = {}
3364
3365
  } = ae({
3365
- queryKey: ["cbv-risk", n, $s],
3366
+ queryKey: ["cbv-risk", n, qs],
3366
3367
  queryFn: () => u.request(
3367
3368
  be("/at-risk/evaluate", {
3368
3369
  collection: n,
@@ -3405,12 +3406,12 @@ function Jc({
3405
3406
  placeholderData: (e) => e,
3406
3407
  staleTime: 3e4,
3407
3408
  retry: !1
3408
- }), { data: Ts = [] } = ae({
3409
+ }), { data: Ls = [] } = ae({
3409
3410
  queryKey: ["cbv-integrations-collections"],
3410
3411
  queryFn: () => u.request(Y("/integration-obligations/collections")).then((e) => e.data ?? []).catch(() => []),
3411
3412
  staleTime: 6e4,
3412
3413
  retry: !1
3413
- }), Gr = Ts.includes(n), { data: An } = ae({
3414
+ }), Gr = Ls.includes(n), { data: An } = ae({
3414
3415
  queryKey: ["cbv-integrations-summary", n, Pe],
3415
3416
  queryFn: () => u.request(
3416
3417
  be("/integration-obligations/summary", { collection: n, ids: Pe.split(",") })
@@ -3433,37 +3434,37 @@ function Jc({
3433
3434
  queryFn: () => u.request(Y(Zt ? `/pipelines/${Wa}` : `/pipelines/${Wa}/outline`)).then((e) => e.data),
3434
3435
  enabled: !!Wa,
3435
3436
  retry: !1
3436
- }), Ls = !!(Ne != null && Ne.binding), { data: jn } = ae({
3437
+ }), Fs = !!(Ne != null && Ne.binding), { data: jn } = ae({
3437
3438
  queryKey: ["cbv-owners", n, Pe],
3438
3439
  queryFn: () => u.request(
3439
3440
  be(`/pipelines/instance/${n}/owners/batch`, {
3440
3441
  ids: Pe.split(",").filter(Boolean)
3441
3442
  })
3442
3443
  ).then((e) => e.data ?? {}),
3443
- enabled: Ls && Pe.length > 0,
3444
+ enabled: Fs && Pe.length > 0,
3444
3445
  staleTime: 6e4,
3445
3446
  retry: !1
3446
3447
  }), Xr = we(
3447
3448
  () => ce.filter((e) => e.includes(".")),
3448
3449
  [ce]
3449
3450
  ), Zr = we(
3450
- () => ce.filter((e) => e.startsWith("__f:")).flatMap((e) => Lo(Le[e] ?? "")).filter((e) => e.includes(".")),
3451
+ () => ce.filter((e) => e.startsWith("__f:")).flatMap((e) => Fo(Le[e] ?? "")).filter((e) => e.includes(".")),
3451
3452
  [ce, Le]
3452
- ), Ua = we(
3453
+ ), Qa = we(
3453
3454
  () => [.../* @__PURE__ */ new Set([...Xr, ...Object.values(Ie), ...Zr])].slice(
3454
3455
  0,
3455
3456
  20
3456
3457
  ),
3457
3458
  [Xr, Ie, Zr]
3458
3459
  ), el = xe.map((e) => String(e.id)).join(","), { data: ge } = ae({
3459
- queryKey: ["cbv-resolved", n, el, Ua.join(",")],
3460
+ queryKey: ["cbv-resolved", n, el, Qa.join(",")],
3460
3461
  queryFn: () => u.request(
3461
3462
  Y(`/items/${n}/resolve-paths`, {
3462
3463
  ids: el,
3463
- paths: Ua.join(",")
3464
+ paths: Qa.join(",")
3464
3465
  })
3465
3466
  ).then((e) => e.data ?? { rows: {}, targets: {} }),
3466
- enabled: xe.length > 0 && Ua.length > 0,
3467
+ enabled: xe.length > 0 && Qa.length > 0,
3467
3468
  staleTime: 3e4,
3468
3469
  retry: !1
3469
3470
  }), ct = (e, a) => {
@@ -3476,7 +3477,7 @@ function Jc({
3476
3477
  var r;
3477
3478
  const a = e.includes(".") ? e : Ie[e];
3478
3479
  return a ? ((r = ge == null ? void 0 : ge.targets) == null ? void 0 : r[a]) ?? null : null;
3479
- }, Fs = (e, a) => {
3480
+ }, Rs = (e, a) => {
3480
3481
  var d, p, R, M;
3481
3482
  const r = a.includes(".") ? a : Ie[a];
3482
3483
  if (!r) return null;
@@ -3487,7 +3488,7 @@ function Jc({
3487
3488
  const a = Ve(at, n, e);
3488
3489
  if (a != null && a.one_collection)
3489
3490
  return gt(a.one_collection) && a.one_collection !== "nivaro_users" ? null : { kind: "in", target: a.one_collection };
3490
- const r = fs[e];
3491
+ const r = gs[e];
3491
3492
  if (r) {
3492
3493
  if (r.kind === "m2m") return { kind: "in", target: r.target };
3493
3494
  const s = Ie[e];
@@ -3498,7 +3499,7 @@ function Jc({
3498
3499
  }, Ee = (e, a) => Tt((r) => {
3499
3500
  const l = { ...r };
3500
3501
  return a ? l[e] = a : delete l[e], l;
3501
- }), Rs = (e) => {
3502
+ }), Ps = (e) => {
3502
3503
  var p, R, M, Se;
3503
3504
  const { key: a, row: r, cellText: l } = e, s = r.id;
3504
3505
  if (a === "__state__") {
@@ -3543,11 +3544,11 @@ function Jc({
3543
3544
  Z && Ee(a, { kind: "date", value: `r:${Z}..${Z}` });
3544
3545
  }
3545
3546
  }
3546
- }, Ps = (e, a) => {
3547
+ }, Es = (e, a) => {
3547
3548
  if (e === "__state__") return !1;
3548
3549
  const r = na(e);
3549
3550
  return r ? r.kind === "in" ? !!Ve(at, n, e) && a[e] != null : r.kind === "enum" || r.kind === "num" ? a[e] != null && a[e] !== "" : r.kind === "text" : !1;
3550
- }, Es = (e) => {
3551
+ }, Ms = (e) => {
3551
3552
  const { key: a, row: r, cellText: l } = e, s = r.id, d = na(a);
3552
3553
  if (!d) return;
3553
3554
  let p = null;
@@ -3561,7 +3562,7 @@ function Jc({
3561
3562
  M && M !== "—" && (p = { id: R, path: d.path, op: "_ncontains", value: M, label: M, field: a });
3562
3563
  }
3563
3564
  p && br((M) => [...M, p]);
3564
- }, Ms = (e) => {
3565
+ }, Ds = (e) => {
3565
3566
  var l, s, d;
3566
3567
  const a = na(e);
3567
3568
  if (!a) return null;
@@ -3574,7 +3575,7 @@ function Jc({
3574
3575
  p.add(Se);
3575
3576
  else M[e] != null && M[e] !== "" && typeof M[e] != "object" && p.add(M[e]);
3576
3577
  return /* @__PURE__ */ t(
3577
- wd,
3578
+ _d,
3578
3579
  {
3579
3580
  target: a.target,
3580
3581
  selected: (r == null ? void 0 : r.kind) === "in" ? r.value : [],
@@ -3585,7 +3586,7 @@ function Jc({
3585
3586
  }
3586
3587
  if (a.kind === "enum")
3587
3588
  return /* @__PURE__ */ t(
3588
- _d,
3589
+ Nd,
3589
3590
  {
3590
3591
  collection: n,
3591
3592
  field: e,
@@ -3615,7 +3616,7 @@ function Jc({
3615
3616
  {
3616
3617
  value: p,
3617
3618
  onChange: (M) => Ee(e, { kind: "num", op: M, value: R }),
3618
- options: as.map((M) => ({ value: M.value, label: M.label })),
3619
+ options: ns.map((M) => ({ value: M.value, label: M.label })),
3619
3620
  ariaLabel: `Filter operator ${e}`
3620
3621
  }
3621
3622
  ),
@@ -3645,13 +3646,13 @@ function Jc({
3645
3646
  className: "w-full"
3646
3647
  }
3647
3648
  ) : a.kind === "date" ? /* @__PURE__ */ t(
3648
- Nd,
3649
+ Sd,
3649
3650
  {
3650
3651
  value: (r == null ? void 0 : r.kind) === "date" ? r.value : "",
3651
3652
  onChange: (p) => Ee(e, p ? { kind: "date", value: p } : null)
3652
3653
  }
3653
3654
  ) : null;
3654
- }, Ds = ce.some((e) => na(e) != null), al = (e) => {
3655
+ }, Os = ce.some((e) => na(e) != null), al = (e) => {
3655
3656
  var r, l;
3656
3657
  if (((r = te[e]) == null ? void 0 : r.type) === "number") return !0;
3657
3658
  if (e.includes(".") || e in Ie || Ve(at, n, e)) return !1;
@@ -3661,7 +3662,7 @@ function Jc({
3661
3662
  var s, d, p;
3662
3663
  const l = te[a];
3663
3664
  if ((l == null ? void 0 : l.type) === "count") {
3664
- const R = a.includes(".") ? a : Ie[a], M = r != null && R ? (p = (d = (s = ge == null ? void 0 : ge.rows) == null ? void 0 : s[String(r)]) == null ? void 0 : d[R]) == null ? void 0 : p.ids : void 0, Se = Po(e === "—" ? "" : e, M);
3665
+ const R = a.includes(".") ? a : Ie[a], M = r != null && R ? (p = (d = (s = ge == null ? void 0 : ge.rows) == null ? void 0 : s[String(r)]) == null ? void 0 : d[R]) == null ? void 0 : p.ids : void 0, Se = Eo(e === "—" ? "" : e, M);
3665
3666
  return String(Se);
3666
3667
  }
3667
3668
  return l && e && e !== "—" ? Ol(e, l) : e;
@@ -3672,9 +3673,9 @@ function Jc({
3672
3673
  queryKey: ["cbv-views", n],
3673
3674
  queryFn: () => u.request(Y("/saved-views", { collection: n })).then((e) => e.data ?? []),
3674
3675
  staleTime: 3e4
3675
- }), la = () => g.invalidateQueries({ queryKey: ["cbv-views", n] }), Os = Za({
3676
+ }), la = () => g.invalidateQueries({ queryKey: ["cbv-views", n] }), As = Za({
3676
3677
  queries: nt.slice(0, 12).map((e) => {
3677
- const a = Yl(e.filters ?? []);
3678
+ const a = Hl(e.filters ?? []);
3678
3679
  return {
3679
3680
  queryKey: ["cbv-view-count", n, e.id, JSON.stringify(a)],
3680
3681
  queryFn: () => u.request(
@@ -3692,17 +3693,17 @@ function Jc({
3692
3693
  }), In = /* @__PURE__ */ new Map();
3693
3694
  nt.slice(0, 12).forEach((e, a) => {
3694
3695
  var r;
3695
- In.set(e.id, ((r = Os[a]) == null ? void 0 : r.data) ?? null);
3696
+ In.set(e.id, ((r = As[a]) == null ? void 0 : r.data) ?? null);
3696
3697
  });
3697
- const [rl, As] = k(() => /* @__PURE__ */ new Set()), Kn = (e) => {
3698
+ const [rl, js] = k(() => /* @__PURE__ */ new Set()), Kn = (e) => {
3698
3699
  var r, l;
3699
3700
  Pa(e.id);
3700
- const a = Oi(e.filters ?? []);
3701
+ const a = Ai(e.filters ?? []);
3701
3702
  if (he(a.filters), ja(a.riskIds), re(e.sort ?? ""), (r = e.columns) != null && r.length) {
3702
3703
  const s = new Set(
3703
3704
  e.columns.filter((B) => typeof B != "string" && B.admin_only).map(Ul)
3704
3705
  );
3705
- As(s);
3706
+ js(s);
3706
3707
  const d = e.columns.map(Ul).filter((B) => Zt || !s.has(B)), p = {};
3707
3708
  for (const B of e.columns)
3708
3709
  typeof B != "string" && B.formula && B.key.startsWith("__f:") && (p[B.key] = B.formula);
@@ -3725,9 +3726,9 @@ function Jc({
3725
3726
  return;
3726
3727
  }
3727
3728
  Pa(null), he([]), ja([]), re(o ?? ""), Oe(m ?? null), _e({}), F({}), x({}), J({}), Oa(null), T(1);
3728
- }, Qa = () => ({
3729
+ }, Ua = () => ({
3729
3730
  // The pressed highlight pills ride along as one `$at_risk` filter entry.
3730
- filters: [...Q, ...[Ai(Mt, Pn)].filter((e) => e !== null)],
3731
+ filters: [...U, ...[ji(Mt, Pn)].filter((e) => e !== null)],
3731
3732
  sort: j,
3732
3733
  columns: [
3733
3734
  ...ce.map((e, a) => {
@@ -3783,10 +3784,10 @@ function Jc({
3783
3784
  is_shared: !0
3784
3785
  })
3785
3786
  ), ol(""), g.invalidateQueries({ queryKey: ["cbv-export-presets", n] }));
3786
- }, js = (e) => {
3787
+ }, Is = (e) => {
3787
3788
  const a = new URLSearchParams();
3788
3789
  O && a.set("search", O), fe && a.set("conditions", fe), j && a.set("sort", j), window.open(`/api/export-presets/${e}/run?${a.toString()}`, "_blank");
3789
- }, Is = (e, a) => {
3790
+ }, Ks = (e, a) => {
3790
3791
  u.request(
3791
3792
  be(`/export-presets/${e}/run-async`, {
3792
3793
  ...O ? { search: O } : {},
@@ -3796,13 +3797,13 @@ function Jc({
3796
3797
  ).then(() => ue.info(`Exporting “${a}” in the background — follow it in the Jobs tray`)).catch((r) => ue.error(Ct(r, "Could not start the export")));
3797
3798
  }, Ya = mt({
3798
3799
  mutationFn: () => u.request(
3799
- be("/saved-views", { collection: n, name: Bt.trim(), ...Qa() })
3800
+ be("/saved-views", { collection: n, name: Bt.trim(), ...Ua() })
3800
3801
  ),
3801
3802
  onSuccess: (e) => {
3802
3803
  pn(!1), mn(""), Pa(e.data.id), la();
3803
3804
  }
3804
3805
  }), [Bn, dl] = k(null), St = mt({
3805
- mutationFn: (e) => u.request(Ga(`/saved-views/${e}`, Qa())),
3806
+ mutationFn: (e) => u.request(Ga(`/saved-views/${e}`, Ua())),
3806
3807
  onSuccess: (e, a) => {
3807
3808
  var l;
3808
3809
  la(), dl(a), setTimeout(() => dl((s) => s === a ? null : s), 2e3);
@@ -3810,18 +3811,18 @@ function Jc({
3810
3811
  ue.success(r ? `Saved "${r}" with the current columns and filters` : "View saved");
3811
3812
  },
3812
3813
  onError: (e) => ue.error(`Could not save the view: ${e.message}`)
3813
- }), Ks = mt({
3814
+ }), Bs = mt({
3814
3815
  mutationFn: ({ id: e, on: a }) => u.request(Ga(`/saved-views/${e}`, { is_default: a })),
3815
3816
  onSuccess: la
3816
- }), Bs = mt({
3817
+ }), zs = mt({
3817
3818
  mutationFn: ({ id: e, role: a }) => u.request(Ga(`/saved-views/${e}`, { default_for_role: a })),
3818
3819
  onSuccess: la,
3819
3820
  onError: (e) => ue.error(`Could not set the role default: ${e.message}`)
3820
3821
  }), cl = mt({
3821
3822
  mutationFn: () => {
3822
3823
  const e = nt.find((a) => a.is_default);
3823
- return e ? u.request(Ga(`/saved-views/${e.id}`, { ...Qa(), is_default: !0 })) : u.request(
3824
- be("/saved-views", { collection: n, name: "Default", is_default: !0, ...Qa() })
3824
+ return e ? u.request(Ga(`/saved-views/${e.id}`, { ...Ua(), is_default: !0 })) : u.request(
3825
+ be("/saved-views", { collection: n, name: "Default", is_default: !0, ...Ua() })
3825
3826
  );
3826
3827
  },
3827
3828
  onSuccess: () => {
@@ -3830,43 +3831,43 @@ function Jc({
3830
3831
  }), ul = mt({
3831
3832
  mutationFn: (e) => u.request(en(`/items/${n}/${e}`)),
3832
3833
  onSuccess: () => void g.invalidateQueries({ queryKey: ["cbv-items", n] })
3833
- }), zs = mt({
3834
+ }), Ws = mt({
3834
3835
  mutationFn: (e) => u.request(en(`/saved-views/${e}`)),
3835
3836
  onSuccess: (e, a) => {
3836
3837
  Gt === a && ll(), la();
3837
3838
  }
3838
- }), { data: Ws = [] } = ae({
3839
+ }), { data: Qs = [] } = ae({
3839
3840
  queryKey: ["cbv-view-subs"],
3840
3841
  queryFn: () => u.request(Y("/view-subscriptions")).then((e) => e.data ?? []).catch(() => []),
3841
3842
  staleTime: 6e4
3842
- }), Ha = (e) => Ws.find((a) => a.view_id === e), Us = mt({
3843
+ }), Ha = (e) => Qs.find((a) => a.view_id === e), Us = mt({
3843
3844
  mutationFn: async (e) => {
3844
3845
  const a = Ha(e);
3845
3846
  return a ? u.request(en(`/view-subscriptions/${a.id}`)) : u.request(be("/view-subscriptions", { view_id: e, digest: "daily" }));
3846
3847
  },
3847
3848
  onSuccess: () => g.invalidateQueries({ queryKey: ["cbv-view-subs"] })
3848
- }), Qs = async () => {
3849
+ }), Vs = async () => {
3849
3850
  var e, a;
3850
3851
  if (!bn) {
3851
3852
  hr(!0);
3852
3853
  try {
3853
- const { rows: r, truncated: l } = await $i(
3854
- (U, G) => u.request(
3854
+ const { rows: r, truncated: l } = await qi(
3855
+ (Q, G) => u.request(
3855
3856
  Y(`/items/${n}`, {
3856
3857
  limit: G,
3857
- offset: U,
3858
+ offset: Q,
3858
3859
  ...O ? { search: O } : {},
3859
- sort: qi(j),
3860
+ sort: Ti(j),
3860
3861
  ...fe ? { conditions: fe } : {}
3861
3862
  })
3862
3863
  )
3863
3864
  ), s = ce, d = [], p = [];
3864
- for (const U of s) {
3865
- if (U.includes(".") || U.startsWith("__") || U in Ie) continue;
3866
- const G = (e = Ve(at, n, U)) == null ? void 0 : e.one_collection;
3865
+ for (const Q of s) {
3866
+ if (Q.includes(".") || Q.startsWith("__") || Q in Ie) continue;
3867
+ const G = (e = Ve(at, n, Q)) == null ? void 0 : e.one_collection;
3867
3868
  if (!G) continue;
3868
- if (ts.has(G)) {
3869
- p.push(U);
3869
+ if (as.has(G)) {
3870
+ p.push(Q);
3870
3871
  continue;
3871
3872
  }
3872
3873
  if (gt(G)) continue;
@@ -3877,17 +3878,17 @@ function Jc({
3877
3878
  }).catch(() => {
3878
3879
  });
3879
3880
  d.push({
3880
- column: U,
3881
+ column: Q,
3881
3882
  template: ($ == null ? void 0 : $.display_template) ?? null,
3882
3883
  labelField: $a($)
3883
3884
  });
3884
3885
  }
3885
- const R = [.../* @__PURE__ */ new Set([...Ua, ...d.flatMap(Ti)])], M = await Li(
3886
- r.map((U) => String(U.id)),
3886
+ const R = [.../* @__PURE__ */ new Set([...Qa, ...d.flatMap(Li)])], M = await Fi(
3887
+ r.map((Q) => String(Q.id)),
3887
3888
  R,
3888
- (U, G) => u.request(
3889
+ (Q, G) => u.request(
3889
3890
  Y(`/items/${n}/resolve-paths`, {
3890
- ids: U.join(","),
3891
+ ids: Q.join(","),
3891
3892
  paths: G.join(",")
3892
3893
  })
3893
3894
  ).then(($) => {
@@ -3896,37 +3897,37 @@ function Jc({
3896
3897
  })
3897
3898
  ), Se = [
3898
3899
  ...new Set(
3899
- p.flatMap((U) => r.map((G) => G[U]).filter((G) => G != null && G !== ""))
3900
+ p.flatMap((Q) => r.map((G) => G[Q]).filter((G) => G != null && G !== ""))
3900
3901
  )
3901
3902
  ].map(String), Z = /* @__PURE__ */ new Map();
3902
3903
  await Promise.all(
3903
3904
  Se.map(
3904
- (U) => ci(u, U).then((G) => Z.set(U.toUpperCase(), Fi(G, U))).catch(() => Z.set(U.toUpperCase(), U))
3905
+ (Q) => ui(u, Q).then((G) => Z.set(Q.toUpperCase(), Ri(G, Q))).catch(() => Z.set(Q.toUpperCase(), Q))
3905
3906
  )
3906
3907
  );
3907
- const se = new Map(d.map((U) => [U.column, U])), ne = new Set(p), K = (U) => {
3908
- const G = U == null ? "" : String(typeof U == "object" ? JSON.stringify(U) : U);
3908
+ const se = new Map(d.map((Q) => [Q.column, Q])), ne = new Set(p), K = (Q) => {
3909
+ const G = Q == null ? "" : String(typeof Q == "object" ? JSON.stringify(Q) : Q);
3909
3910
  return /[",\n]/.test(G) ? `"${G.replace(/"/g, '""')}"` : G;
3910
- }, h = (U, G) => {
3911
+ }, h = (Q, G) => {
3911
3912
  var V, oe;
3912
3913
  const $ = te[G];
3913
3914
  if (G.startsWith("__f:")) {
3914
3915
  const ee = Le[G], ye = ee ? Dl(ee, (We) => {
3915
3916
  var Ll, Fl;
3916
- const wt = We.includes(".") ? (Fl = (Ll = M[String(U.id)]) == null ? void 0 : Ll[We]) == null ? void 0 : Fl.value : U[We];
3917
+ const wt = We.includes(".") ? (Fl = (Ll = M[String(Q.id)]) == null ? void 0 : Ll[We]) == null ? void 0 : Fl.value : Q[We];
3917
3918
  return typeof wt == "string" && /^-?\d+(\.\d+)?$/.test(wt.trim()) ? Number(wt) : wt;
3918
3919
  }) : null;
3919
3920
  return ye == null ? "" : $ ? ia(String(ye), $) : Math.round(ye * 100) / 100;
3920
3921
  }
3921
3922
  if (G.includes(".") || G in Ie) {
3922
- const ee = G.includes(".") ? G : Ie[G], ye = ((oe = (V = M[String(U.id)]) == null ? void 0 : V[ee]) == null ? void 0 : oe.value) ?? "";
3923
+ const ee = G.includes(".") ? G : Ie[G], ye = ((oe = (V = M[String(Q.id)]) == null ? void 0 : V[ee]) == null ? void 0 : oe.value) ?? "";
3923
3924
  return $ && ye ? Ol(ye, $) : ye;
3924
3925
  }
3925
- const de = U[G], ze = se.get(G);
3926
- return ze && de != null && de !== "" ? Ri(ze, M[String(U.id)]) || de : ne.has(G) && de != null && de !== "" ? Z.get(String(de).toUpperCase()) ?? de : $ && de != null ? ia(String(de), $) : de;
3926
+ const de = Q[G], ze = se.get(G);
3927
+ return ze && de != null && de !== "" ? Pi(ze, M[String(Q.id)]) || de : ne.has(G) && de != null && de !== "" ? Z.get(String(de).toUpperCase()) ?? de : $ && de != null ? ia(String(de), $) : de;
3927
3928
  }, B = [
3928
- ["id", ...s.map((U) => dt(U))].map(K).join(","),
3929
- ...r.map((U) => [U.id, ...s.map((G) => h(U, G))].map(K).join(","))
3929
+ ["id", ...s.map((Q) => dt(Q))].map(K).join(","),
3930
+ ...r.map((Q) => [Q.id, ...s.map((G) => h(Q, G))].map(K).join(","))
3930
3931
  ];
3931
3932
  l && (B.push(""), B.push(
3932
3933
  K(
@@ -3946,8 +3947,8 @@ function Jc({
3946
3947
  const Xe = new Blob([B.join(`
3947
3948
  `)], { type: "text/csv;charset=utf-8" }), yt = URL.createObjectURL(Xe), ut = document.createElement("a");
3948
3949
  ut.href = yt;
3949
- const pt = De.export_filename, Ut = ((a = nt.find((U) => U.id === Gt)) == null ? void 0 : a.name) ?? "all";
3950
- ut.download = pt ? `${pt.replace(/\{\{\s*collection\s*\}\}/g, n).replace(/\{\{\s*view\s*\}\}/g, Ut).replace(/\{\{\s*date\s*\}\}/g, Pi()).replace(/[^A-Za-z0-9 ._-]/g, "")}.csv` : `${n}.csv`, ut.click(), setTimeout(() => URL.revokeObjectURL(yt), 1e4), l && ue.warning(`Exported the first ${r.length.toLocaleString()} rows`, {
3950
+ const pt = De.export_filename, Qt = ((a = nt.find((Q) => Q.id === Gt)) == null ? void 0 : a.name) ?? "all";
3951
+ ut.download = pt ? `${pt.replace(/\{\{\s*collection\s*\}\}/g, n).replace(/\{\{\s*view\s*\}\}/g, Qt).replace(/\{\{\s*date\s*\}\}/g, Ei()).replace(/[^A-Za-z0-9 ._-]/g, "")}.csv` : `${n}.csv`, ut.click(), setTimeout(() => URL.revokeObjectURL(yt), 1e4), l && ue.warning(`Exported the first ${r.length.toLocaleString()} rows`, {
3951
3952
  description: `${qe.toLocaleString()} match — narrow the filter to export the rest.`
3952
3953
  });
3953
3954
  } catch (r) {
@@ -3956,18 +3957,18 @@ function Jc({
3956
3957
  hr(!1);
3957
3958
  }
3958
3959
  }
3959
- }, zn = me(null), Vs = (e) => {
3960
+ }, zn = me(null), Ys = (e) => {
3960
3961
  zn.current && clearTimeout(zn.current), zn.current = setTimeout(() => {
3961
- Zo(g, u, n, String(e));
3962
+ ei(g, u, n, String(e));
3962
3963
  }, 250);
3963
3964
  }, sa = (e) => {
3964
3965
  var a;
3965
- ((a = za.current) == null ? void 0 : a.key) === `${n}\0${O}` && li(u, za.current.id, {
3966
+ ((a = za.current) == null ? void 0 : a.key) === `${n}\0${O}` && si(u, za.current.id, {
3966
3967
  type: "record",
3967
3968
  collection: n,
3968
3969
  item: e === "new" ? null : e
3969
3970
  }), C ? C(e) : z({ collection: n, itemId: String(e) });
3970
- }, Ys = (e) => {
3971
+ }, Hs = (e) => {
3971
3972
  const a = Ve(at, n, e), r = (l) => {
3972
3973
  j === l ? re(`-${l}`) : j === `-${l}` ? re("") : re(l), T(1);
3973
3974
  };
@@ -3987,9 +3988,9 @@ function Jc({
3987
3988
  return;
3988
3989
  }
3989
3990
  r(e);
3990
- }, Wn = xe.length > 0 && xe.every((e) => Kt.includes(e.id)), Hs = () => Jt(
3991
+ }, Wn = xe.length > 0 && xe.every((e) => Kt.includes(e.id)), Js = () => Jt(
3991
3992
  Wn ? Kt.filter((e) => !xe.some((a) => a.id === e)) : [.../* @__PURE__ */ new Set([...Kt, ...xe.map((e) => e.id)])]
3992
- ), Js = (e) => Jt((a) => a.includes(e) ? a.filter((r) => r !== e) : [...a, e]), Ja = 2e3, [pl, ml] = k(!1), Gs = async () => {
3993
+ ), Gs = (e) => Jt((a) => a.includes(e) ? a.filter((r) => r !== e) : [...a, e]), Ja = 2e3, [pl, ml] = k(!1), Xs = async () => {
3993
3994
  ml(!0);
3994
3995
  try {
3995
3996
  const e = await u.request(
@@ -4004,7 +4005,7 @@ function Jc({
4004
4005
  } finally {
4005
4006
  ml(!1);
4006
4007
  }
4007
- }, Xs = qe === 0 && !ta ? 0 : (v - 1) * tt + 1, Zs = ta ? (v - 1) * tt + xe.length : Math.min(v * tt, qe), Sa = !!(Ne != null && Ne.instances), Un = (Rt ? 1 : 0) + (Sa ? 2 : 0) + (wr ? 1 : 0), Qn = [
4008
+ }, Zs = qe === 0 && !ta ? 0 : (v - 1) * tt + 1, eo = ta ? (v - 1) * tt + xe.length : Math.min(v * tt, qe), Sa = !!(Ne != null && Ne.instances), Qn = (Rt ? 1 : 0) + (Sa ? 2 : 0) + (wr ? 1 : 0), Un = [
4008
4009
  ...ce.map(
4009
4010
  (e) => e.startsWith("__f:") ? { key: e, kind: "formula" } : { key: e, kind: "data" }
4010
4011
  ),
@@ -4017,18 +4018,18 @@ function Jc({
4017
4018
  { key: "__owners__", kind: "owners" }
4018
4019
  ] : [],
4019
4020
  ...En ? [{ key: "__addendums__", kind: "addendums" }] : [],
4020
- ...Qe ? [{ key: "__fulfilment__", kind: "fulfilment" }] : [],
4021
+ ...Ue ? [{ key: "__fulfilment__", kind: "fulfilment" }] : [],
4021
4022
  ...Gr ? [{ key: "__integrations__", kind: "integrations" }] : [],
4022
4023
  ...Jr ? [{ key: "__tasks__", kind: "tasks" }] : [],
4023
4024
  ...wr ? [{ key: "__actions__", kind: "actions" }] : []
4024
4025
  ], oa = [
4025
- ...Qn.filter((e) => ht(e.key) === "left"),
4026
- ...Qn.filter((e) => !ht(e.key)),
4027
- ...Qn.filter((e) => ht(e.key) === "right")
4026
+ ...Un.filter((e) => ht(e.key) === "left"),
4027
+ ...Un.filter((e) => !ht(e.key)),
4028
+ ...Un.filter((e) => ht(e.key) === "right")
4028
4029
  ], bl = [
4029
4030
  ...Sa ? [{ key: "__state__", label: "State" }] : [],
4030
4031
  ...ce.filter((e) => Dt(e) || !Ve(at, n, e)).map((e) => ({ key: e, label: dt(e) }))
4031
- ], eo = (e) => {
4032
+ ], to = (e) => {
4032
4033
  var l;
4033
4034
  if (!w) return "";
4034
4035
  const a = e.id;
@@ -4039,11 +4040,11 @@ function Jc({
4039
4040
  if (Dt(w)) return ct(a, w) || "(empty)";
4040
4041
  const r = e[w];
4041
4042
  return r == null || r === "" ? "(empty)" : typeof r == "boolean" ? r ? "Yes" : "No" : ra(String(r), w) || String(r);
4042
- }, to = (() => {
4043
+ }, ao = (() => {
4043
4044
  if (!w) return xe.map((l) => ({ kind: "row", row: l }));
4044
4045
  const e = /* @__PURE__ */ new Map();
4045
4046
  for (const l of xe) {
4046
- const s = eo(l), d = e.get(s) ?? [];
4047
+ const s = to(l), d = e.get(s) ?? [];
4047
4048
  d.push(l), e.set(s, d);
4048
4049
  }
4049
4050
  const a = [...e.keys()].sort((l, s) => l === "(empty)" ? 1 : s === "(empty)" ? -1 : l.localeCompare(s, void 0, { numeric: !0 })), r = [];
@@ -4052,21 +4053,21 @@ function Jc({
4052
4053
  if (r.push({ kind: "header", gkey: l, label: l, count: s.length }), !fa.has(l)) for (const d of s) r.push({ kind: "row", row: d });
4053
4054
  }
4054
4055
  return r;
4055
- })(), Vn = oa.filter((e) => ht(e.key) === "left").map((e) => e.key), hl = oa.filter((e) => ht(e.key) === "right").map((e) => e.key), Yn = me(/* @__PURE__ */ new Map()), [Ca, ao] = k({});
4056
- xo(() => {
4056
+ })(), Vn = oa.filter((e) => ht(e.key) === "left").map((e) => e.key), hl = oa.filter((e) => ht(e.key) === "right").map((e) => e.key), Yn = me(/* @__PURE__ */ new Map()), [Ca, no] = k({});
4057
+ vo(() => {
4057
4058
  const e = {};
4058
4059
  for (const [r, l] of Yn.current)
4059
4060
  l != null && l.isConnected && (e[r] = l.getBoundingClientRect().width);
4060
4061
  const a = /* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(Ca)]);
4061
4062
  for (const r of a)
4062
4063
  if (Math.abs((e[r] ?? -1) - (Ca[r] ?? -1)) > 0.5) {
4063
- ao(e);
4064
+ no(e);
4064
4065
  return;
4065
4066
  }
4066
4067
  });
4067
- const no = 52, fl = (e) => {
4068
+ const ro = 52, fl = (e) => {
4068
4069
  if (ht(e) === "left") {
4069
- let l = Rt ? Ca.__checkbox__ ?? no : 0;
4070
+ let l = Rt ? Ca.__checkbox__ ?? ro : 0;
4070
4071
  for (const s of Vn) {
4071
4072
  if (s === e) break;
4072
4073
  l += Ca[s] ?? 0;
@@ -4108,40 +4109,40 @@ function Jc({
4108
4109
  window.removeEventListener("pointermove", e), window.removeEventListener("pointerup", a);
4109
4110
  };
4110
4111
  }, []);
4111
- const ro = (e) => {
4112
+ const lo = (e) => {
4112
4113
  let a = dt(e).length;
4113
4114
  for (const r of xe) {
4114
4115
  const l = Dt(e) ? ct(r.id, e) ?? "" : ra(String(r[e] ?? ""), e, r.id);
4115
4116
  l.length > a && (a = Math.min(l.length, 90));
4116
4117
  }
4117
4118
  _t((r) => ({ ...r, [e]: Math.max(60, Math.round(a * 6.6) + 28) }));
4118
- }, lo = (e) => /* @__PURE__ */ t(
4119
+ }, so = (e) => /* @__PURE__ */ t(
4119
4120
  "span",
4120
4121
  {
4121
4122
  onPointerDown: (a) => {
4122
4123
  a.preventDefault(), a.stopPropagation(), Jn.current = { key: e, startX: a.clientX, startW: $e[e] ?? 140 }, document.body.style.cursor = "col-resize";
4123
4124
  },
4124
4125
  onDoubleClick: (a) => {
4125
- a.stopPropagation(), ro(e);
4126
+ a.stopPropagation(), lo(e);
4126
4127
  },
4127
4128
  onClick: (a) => a.stopPropagation(),
4128
4129
  title: "Drag to resize · double-click to fit content",
4129
4130
  className: "absolute right-0 top-0 h-full w-1.5 cursor-col-resize opacity-0 transition-opacity hover:bg-nvr-cyan/40 hover:opacity-100 group-hover/hcell:opacity-60"
4130
4131
  }
4131
- ), so = (e) => $e[e] ? { width: $e[e], minWidth: $e[e], maxWidth: $e[e] } : void 0, xl = (e) => {
4132
+ ), oo = (e) => $e[e] ? { width: $e[e], minWidth: $e[e], maxWidth: $e[e] } : void 0, xl = (e) => {
4132
4133
  const a = ht(e);
4133
4134
  return /* @__PURE__ */ t(
4134
4135
  "button",
4135
4136
  {
4136
4137
  type: "button",
4137
4138
  onClick: (r) => {
4138
- r.stopPropagation(), ms(e);
4139
+ r.stopPropagation(), bs(e);
4139
4140
  },
4140
4141
  title: gl[a ?? "none"],
4141
4142
  "aria-label": gl[a ?? "none"],
4142
4143
  className: `ml-1 inline-flex align-middle transition-opacity ${a ? "text-[#00a5cc] opacity-100" : "text-slate-300 opacity-0 group-hover/hcell:opacity-100 dark:text-slate-600"}`,
4143
4144
  children: /* @__PURE__ */ t(
4144
- fo,
4145
+ go,
4145
4146
  {
4146
4147
  className: "h-3 w-3",
4147
4148
  style: a === "right" ? { transform: "scaleX(-1)" } : void 0
@@ -4215,9 +4216,9 @@ function Jc({
4215
4216
  [data-cbv] .cbv-overlay { animation: none; opacity: 1; }
4216
4217
  }
4217
4218
  ` }),
4218
- /* @__PURE__ */ t(cd, {}),
4219
- /* @__PURE__ */ t(_i, {}),
4220
- ie && Xl(
4219
+ /* @__PURE__ */ t(ud, {}),
4220
+ /* @__PURE__ */ t(Ni, {}),
4221
+ ie && Zl(
4221
4222
  /* @__PURE__ */ c(
4222
4223
  "div",
4223
4224
  {
@@ -4235,7 +4236,7 @@ function Jc({
4235
4236
  {
4236
4237
  type: "button",
4237
4238
  onClick: () => {
4238
- Rs(ie), Lt(null);
4239
+ Ps(ie), Lt(null);
4239
4240
  },
4240
4241
  className: "block w-full truncate px-3 py-1.5 text-left text-[12px] text-slate-700 hover:bg-slate-50 dark:text-slate-200 dark:hover:bg-slate-800",
4241
4242
  children: [
@@ -4244,12 +4245,12 @@ function Jc({
4244
4245
  ]
4245
4246
  }
4246
4247
  ),
4247
- Ps(ie.key, ie.row) && ie.cellText && ie.cellText !== "—" && /* @__PURE__ */ c(
4248
+ Es(ie.key, ie.row) && ie.cellText && ie.cellText !== "—" && /* @__PURE__ */ c(
4248
4249
  "button",
4249
4250
  {
4250
4251
  type: "button",
4251
4252
  onClick: () => {
4252
- Es(ie), Lt(null);
4253
+ Ms(ie), Lt(null);
4253
4254
  },
4254
4255
  className: "block w-full truncate px-3 py-1.5 text-left text-[12px] text-slate-700 hover:bg-slate-50 dark:text-slate-200 dark:hover:bg-slate-800",
4255
4256
  children: [
@@ -4351,7 +4352,7 @@ function Jc({
4351
4352
  }
4352
4353
  ),
4353
4354
  /* @__PURE__ */ t(
4354
- Rd,
4355
+ Pd,
4355
4356
  {
4356
4357
  collection: n,
4357
4358
  meta: D,
@@ -4359,7 +4360,7 @@ function Jc({
4359
4360
  onSearch: (e) => {
4360
4361
  W(e), T(1);
4361
4362
  },
4362
- filters: Q,
4363
+ filters: U,
4363
4364
  onFiltersChange: (e) => {
4364
4365
  he(e), T(1);
4365
4366
  }
@@ -4369,12 +4370,12 @@ function Jc({
4369
4370
  "button",
4370
4371
  {
4371
4372
  type: "button",
4372
- onClick: () => gs((e) => !e),
4373
+ onClick: () => xs((e) => !e),
4373
4374
  "aria-pressed": Aa,
4374
4375
  title: "Only records with an addendum still in review",
4375
4376
  className: `flex h-8 items-center gap-1.5 rounded-full border px-2.5 text-[12px] font-medium transition-colors ${Aa ? "border-amber-400 bg-amber-50 text-amber-800 dark:border-amber-500/60 dark:bg-amber-500/10 dark:text-amber-300" : "border-slate-200 bg-white text-slate-600 hover:border-slate-300 dark:border-slate-700 dark:bg-slate-900 dark:text-slate-300"}`,
4376
4377
  children: [
4377
- /* @__PURE__ */ t(oo, { className: "h-3.5 w-3.5" }),
4378
+ /* @__PURE__ */ t(io, { className: "h-3.5 w-3.5" }),
4378
4379
  "Active addendums"
4379
4380
  ]
4380
4381
  }
@@ -4396,7 +4397,7 @@ function Jc({
4396
4397
  /* @__PURE__ */ t(
4397
4398
  "span",
4398
4399
  {
4399
- className: `h-2 w-2 rounded-full ${ai(e.highlight_color ?? "red")}`
4400
+ className: `h-2 w-2 rounded-full ${ni(e.highlight_color ?? "red")}`
4400
4401
  }
4401
4402
  ),
4402
4403
  e.name
@@ -4405,8 +4406,8 @@ function Jc({
4405
4406
  e.id
4406
4407
  );
4407
4408
  }),
4408
- /* @__PURE__ */ t(ld, { className: "h-8" }),
4409
- /* @__PURE__ */ t(Qi, {}),
4409
+ /* @__PURE__ */ t(sd, { className: "h-8" }),
4410
+ /* @__PURE__ */ t(Vi, {}),
4410
4411
  Fn > 0 && /* @__PURE__ */ c(
4411
4412
  "button",
4412
4413
  {
@@ -4437,7 +4438,7 @@ function Jc({
4437
4438
  }
4438
4439
  ),
4439
4440
  Zt && De.copy_as !== !1 && /* @__PURE__ */ t(
4440
- Ni,
4441
+ Si,
4441
4442
  {
4442
4443
  collection: n,
4443
4444
  list: {
@@ -4451,17 +4452,17 @@ function Jc({
4451
4452
  }
4452
4453
  ),
4453
4454
  ya.parent && /* @__PURE__ */ t(
4454
- Di,
4455
+ Oi,
4455
4456
  {
4456
4457
  parent: ya.parent,
4457
4458
  value: Mr,
4458
4459
  onChange: (e) => {
4459
- xs(e), T(1);
4460
+ vs(e), T(1);
4460
4461
  }
4461
4462
  }
4462
4463
  ),
4463
4464
  [
4464
- ...wa ? [{ key: "tree", label: "Tree", icon: /* @__PURE__ */ t(io, { className: "h-3.5 w-3.5" }) }] : [],
4465
+ ...wa ? [{ key: "tree", label: "Tree", icon: /* @__PURE__ */ t(co, { className: "h-3.5 w-3.5" }) }] : [],
4465
4466
  ...(A ?? []).map((e) => ({ key: e.key, label: e.label, icon: e.icon }))
4466
4467
  ].map((e) => /* @__PURE__ */ c(
4467
4468
  "button",
@@ -4492,7 +4493,7 @@ function Jc({
4492
4493
  className: `flex h-8 items-center gap-1.5 rounded-md border px-2.5 text-[12px] font-medium ${Ia ? "border-nvr-cyan/40 bg-nvr-cyan/[0.08] text-[#007a99] dark:text-nvr-cyan" : "border-slate-200 text-slate-500 hover:text-slate-700 dark:border-slate-700 dark:text-slate-400"}`,
4493
4494
  "data-cbv-map-toggle": !0,
4494
4495
  children: [
4495
- /* @__PURE__ */ t(co, { className: "h-3.5 w-3.5" }),
4496
+ /* @__PURE__ */ t(uo, { className: "h-3.5 w-3.5" }),
4496
4497
  "Map"
4497
4498
  ]
4498
4499
  }
@@ -4574,7 +4575,7 @@ function Jc({
4574
4575
  "button",
4575
4576
  {
4576
4577
  type: "button",
4577
- onClick: ls,
4578
+ onClick: ss,
4578
4579
  "aria-label": "Clear AI result",
4579
4580
  className: "rounded-full p-0.5 hover:bg-nvr-cyan/[0.16]",
4580
4581
  children: /* @__PURE__ */ t(Zn, { className: "h-3 w-3" })
@@ -4624,7 +4625,7 @@ function Jc({
4624
4625
  "aria-label": "Row density",
4625
4626
  title: It === "compact" ? "Switch to comfortable rows" : "Switch to compact rows",
4626
4627
  className: "flex h-8 w-8 items-center justify-center rounded-md border border-slate-200 text-slate-500 hover:bg-slate-100 hover:text-slate-700 dark:border-slate-700 dark:text-slate-400 dark:hover:bg-slate-800",
4627
- children: It === "compact" ? /* @__PURE__ */ t(Rl, { className: "h-4 w-4" }) : /* @__PURE__ */ t(uo, { className: "h-4 w-4" })
4628
+ children: It === "compact" ? /* @__PURE__ */ t(Rl, { className: "h-4 w-4" }) : /* @__PURE__ */ t(po, { className: "h-4 w-4" })
4628
4629
  }
4629
4630
  ),
4630
4631
  /* @__PURE__ */ c("div", { className: "relative", ref: xr, children: [
@@ -4700,7 +4701,7 @@ function Jc({
4700
4701
  "button",
4701
4702
  {
4702
4703
  type: "button",
4703
- onClick: () => At(Qt === e ? null : e),
4704
+ onClick: () => At(Ut === e ? null : e),
4704
4705
  title: "Format column",
4705
4706
  "aria-label": `Format ${e}`,
4706
4707
  className: te[e] ? "text-[11px] font-bold text-[#00a5cc]" : "text-[11px] text-slate-300 opacity-0 hover:text-slate-500 group-hover:opacity-100",
@@ -4735,8 +4736,8 @@ function Jc({
4735
4736
  ]
4736
4737
  }
4737
4738
  ),
4738
- Qt === e && /* @__PURE__ */ c("div", { className: "mb-1 ml-5 mr-1 rounded-md border border-slate-100 bg-slate-50 p-1.5 dark:border-slate-800 dark:bg-slate-800/60", children: [
4739
- /* @__PURE__ */ t("div", { className: "flex flex-wrap gap-1", children: hd.map((l) => {
4739
+ Ut === e && /* @__PURE__ */ c("div", { className: "mb-1 ml-5 mr-1 rounded-md border border-slate-100 bg-slate-50 p-1.5 dark:border-slate-800 dark:bg-slate-800/60", children: [
4740
+ /* @__PURE__ */ t("div", { className: "flex flex-wrap gap-1", children: fd.map((l) => {
4740
4741
  const s = JSON.stringify(te[e] ?? null) === JSON.stringify(l.cfg);
4741
4742
  return /* @__PURE__ */ t(
4742
4743
  "button",
@@ -4887,7 +4888,7 @@ function Jc({
4887
4888
  D && /* @__PURE__ */ c("div", { className: "mt-1 border-t border-slate-100 pt-1.5 dark:border-slate-800", children: [
4888
4889
  /* @__PURE__ */ t("p", { className: "px-1.5 pb-1 text-[10.5px] font-semibold uppercase tracking-wide text-slate-400", children: "+ Related column" }),
4889
4890
  /* @__PURE__ */ t(
4890
- Pd,
4891
+ Ed,
4891
4892
  {
4892
4893
  collection: n,
4893
4894
  meta: D,
@@ -4901,7 +4902,7 @@ function Jc({
4901
4902
  /* @__PURE__ */ c("div", { className: "mt-1 border-t border-slate-100 pt-1.5 dark:border-slate-800", children: [
4902
4903
  /* @__PURE__ */ t("p", { className: "px-1.5 pb-1 text-[10.5px] font-semibold uppercase tracking-wide text-slate-400", children: "+ Formula column" }),
4903
4904
  /* @__PURE__ */ t(
4904
- Ei,
4905
+ Mi,
4905
4906
  {
4906
4907
  fields: Ft.map((e) => e.field),
4907
4908
  onAdd: (e, a) => {
@@ -4990,7 +4991,7 @@ function Jc({
4990
4991
  {
4991
4992
  type: "button",
4992
4993
  onClick: () => {
4993
- Xt(!1), Qs();
4994
+ Xt(!1), Vs();
4994
4995
  },
4995
4996
  className: "block w-full rounded-md px-2.5 py-1.5 text-left text-[12.5px] text-slate-700 hover:bg-muted dark:text-slate-200",
4996
4997
  children: "CSV — visible columns"
@@ -5016,7 +5017,7 @@ ${r}`).then(() => {
5016
5017
  });
5017
5018
  },
5018
5019
  className: "block w-full rounded-md px-2.5 py-1.5 text-left text-[12.5px] text-slate-700 hover:bg-muted dark:text-slate-200",
5019
- children: os ? "Copied ✓" : "Copy table to clipboard"
5020
+ children: is ? "Copied ✓" : "Copy table to clipboard"
5020
5021
  }
5021
5022
  ),
5022
5023
  sl.length > 0 && /* @__PURE__ */ t("p", { className: "border-t border-slate-100 px-2.5 pb-0.5 pt-1.5 text-[10px] font-semibold uppercase tracking-wide text-slate-400 dark:border-border/60", children: "Presets (server, current filters apply)" }),
@@ -5028,7 +5029,7 @@ ${r}`).then(() => {
5028
5029
  {
5029
5030
  type: "button",
5030
5031
  onClick: () => {
5031
- Xt(!1), js(e.id);
5032
+ Xt(!1), Is(e.id);
5032
5033
  },
5033
5034
  className: "block min-w-0 flex-1 rounded-md px-2.5 py-1.5 text-left text-[12.5px] text-slate-700 hover:bg-muted dark:text-slate-200",
5034
5035
  children: [
@@ -5044,7 +5045,7 @@ ${r}`).then(() => {
5044
5045
  "data-export-background": e.id,
5045
5046
  "data-tip": "Run in the background — a download appears in the Jobs tray",
5046
5047
  onClick: () => {
5047
- Xt(!1), Is(e.id, e.name);
5048
+ Xt(!1), Ks(e.id, e.name);
5048
5049
  },
5049
5050
  className: "mr-1 shrink-0 rounded px-1.5 py-1 text-[10.5px] font-medium text-slate-500 hover:bg-muted hover:text-slate-800 dark:text-slate-400 dark:hover:text-slate-100",
5050
5051
  children: "Background"
@@ -5105,7 +5106,7 @@ ${r}`).then(() => {
5105
5106
  slug: e.slug,
5106
5107
  label: e.create_label ?? e.name,
5107
5108
  isDefault: !1,
5108
- steps: ps(e)
5109
+ steps: ms(e)
5109
5110
  }))
5110
5111
  ].map((e) => /* @__PURE__ */ c(
5111
5112
  "div",
@@ -5218,13 +5219,13 @@ ${r}`).then(() => {
5218
5219
  accept: (((ql = va.data) == null ? void 0 : ql.accept) ?? []).join(","),
5219
5220
  multiple: !0,
5220
5221
  className: "hidden",
5221
- onChange: us,
5222
+ onChange: ps,
5222
5223
  "data-cbv-autofill-input": !0
5223
5224
  }
5224
5225
  )
5225
5226
  ] }),
5226
5227
  xn && /* @__PURE__ */ t(
5227
- ad,
5228
+ nd,
5228
5229
  {
5229
5230
  collection: n,
5230
5231
  layoutSlug: xn.slug,
@@ -5261,7 +5262,7 @@ ${r}`).then(() => {
5261
5262
  ] }),
5262
5263
  Pt.length > 0 && /* @__PURE__ */ c("div", { className: "flex shrink-0 flex-wrap items-center gap-1.5 border-b border-slate-100 bg-white px-4 py-1.5 dark:border-slate-800 dark:bg-slate-900", children: [
5263
5264
  Pt.map((e) => /* @__PURE__ */ t(
5264
- Sd,
5265
+ Cd,
5265
5266
  {
5266
5267
  def: e,
5267
5268
  allowedIds: Tr(e),
@@ -5368,7 +5369,7 @@ ${r}`).then(() => {
5368
5369
  title: Ha(e.id) ? "Subscribed — a daily digest reports records that enter this view. Click to unsubscribe." : "Subscribe — get a daily digest of records that enter this view",
5369
5370
  "aria-label": `Toggle digest subscription for ${e.name}`,
5370
5371
  className: Ha(e.id) ? "text-[#00a5cc]" : "text-slate-400 hover:text-[#00a5cc]",
5371
- children: Ha(e.id) ? /* @__PURE__ */ t(po, { className: "h-3 w-3", fill: "currentColor" }) : /* @__PURE__ */ t(mo, { className: "h-3 w-3" })
5372
+ children: Ha(e.id) ? /* @__PURE__ */ t(mo, { className: "h-3 w-3", fill: "currentColor" }) : /* @__PURE__ */ t(bo, { className: "h-3 w-3" })
5372
5373
  }
5373
5374
  ),
5374
5375
  /* @__PURE__ */ t(
@@ -5382,8 +5383,8 @@ ${r}`).then(() => {
5382
5383
  "data-view-update": e.id,
5383
5384
  "data-view-update-state": St.isPending && St.variables === e.id ? "saving" : Bn === e.id ? "saved" : "idle",
5384
5385
  className: "inline-flex h-3.5 w-3.5 items-center justify-center",
5385
- children: St.isPending && St.variables === e.id ? /* @__PURE__ */ t(bo, { className: "h-3 w-3 animate-spin" }) : Bn === e.id ? /* @__PURE__ */ t(
5386
- ho,
5386
+ children: St.isPending && St.variables === e.id ? /* @__PURE__ */ t(ho, { className: "h-3 w-3 animate-spin" }) : Bn === e.id ? /* @__PURE__ */ t(
5387
+ fo,
5387
5388
  {
5388
5389
  className: "h-3 w-3 text-emerald-600 dark:text-emerald-400",
5389
5390
  strokeWidth: 3
@@ -5392,20 +5393,20 @@ ${r}`).then(() => {
5392
5393
  }
5393
5394
  ),
5394
5395
  Zt && /* @__PURE__ */ t(
5395
- Ki,
5396
+ Bi,
5396
5397
  {
5397
5398
  name: e.name,
5398
5399
  isDefault: !!e.is_default,
5399
5400
  roleId: e.default_for_role ?? null,
5400
- onCollectionDefault: (a) => Ks.mutate({ id: e.id, on: a }),
5401
- onRoleDefault: (a) => Bs.mutate({ id: e.id, role: a })
5401
+ onCollectionDefault: (a) => Bs.mutate({ id: e.id, on: a }),
5402
+ onRoleDefault: (a) => zs.mutate({ id: e.id, role: a })
5402
5403
  }
5403
5404
  ),
5404
5405
  /* @__PURE__ */ t(
5405
5406
  "button",
5406
5407
  {
5407
5408
  type: "button",
5408
- onClick: () => zs.mutate(e.id),
5409
+ onClick: () => Ws.mutate(e.id),
5409
5410
  title: "Delete view",
5410
5411
  "aria-label": `Delete ${e.name}`,
5411
5412
  className: "hover:text-red-500",
@@ -5417,7 +5418,7 @@ ${r}`).then(() => {
5417
5418
  },
5418
5419
  e.id
5419
5420
  )),
5420
- ss ? /* @__PURE__ */ c(
5421
+ os ? /* @__PURE__ */ c(
5421
5422
  "form",
5422
5423
  {
5423
5424
  className: "flex items-center gap-1",
@@ -5467,13 +5468,13 @@ ${r}`).then(() => {
5467
5468
  )
5468
5469
  ] }),
5469
5470
  Je != null && /* @__PURE__ */ c("div", { className: "mx-4 mt-3 flex flex-wrap items-center gap-3 rounded-md border border-red-200 bg-red-50 px-4 py-2.5 text-[13px] text-red-700 dark:border-red-900/40 dark:bg-red-900/10 dark:text-red-400", children: [
5470
- /* @__PURE__ */ t("span", { className: "min-w-0 flex-1", children: Vo(Je) === 503 ? Yo(Je) : Ct(Je, "Failed to load records") }),
5471
- (Je == null ? void 0 : Je.status) === 403 && !ji(Je) && /* @__PURE__ */ t(
5471
+ /* @__PURE__ */ t("span", { className: "min-w-0 flex-1", children: Yo(Je) === 503 ? Ho(Je) : Ct(Je, "Failed to load records") }),
5472
+ (Je == null ? void 0 : Je.status) === 403 && !Ii(Je) && /* @__PURE__ */ t(
5472
5473
  "button",
5473
5474
  {
5474
5475
  type: "button",
5475
5476
  disabled: Ar,
5476
- onClick: () => void u.request(be("/access-requests", { collection: n })).then(() => vs(!0)).catch(() => {
5477
+ onClick: () => void u.request(be("/access-requests", { collection: n })).then(() => ks(!0)).catch(() => {
5477
5478
  }),
5478
5479
  className: "h-7 shrink-0 rounded-md border border-red-300 px-2.5 text-[12px] font-medium hover:bg-red-100 disabled:opacity-60 dark:border-red-500/40 dark:hover:bg-red-900/20",
5479
5480
  "data-request-access": !0,
@@ -5485,7 +5486,7 @@ ${r}`).then(() => {
5485
5486
  {
5486
5487
  type: "button",
5487
5488
  onClick: () => {
5488
- const a = Ii(e, { filters: Q, sort: j, colFilters: Ae });
5489
+ const a = Ki(e, { filters: U, sort: j, colFilters: Ae });
5489
5490
  he(a.filters), re(a.sort), Tt(a.colFilters), T(1);
5490
5491
  },
5491
5492
  title: `Remove the filter or sort on "${e}" — this list cannot filter on it`,
@@ -5510,7 +5511,7 @@ ${r}`).then(() => {
5510
5511
  )
5511
5512
  ] }),
5512
5513
  ft === "tree" && wa ? /* @__PURE__ */ t("div", { className: "flex min-h-0 flex-1 flex-col p-4 pt-3", children: /* @__PURE__ */ t("div", { className: "flex min-h-0 flex-1 flex-col overflow-hidden rounded-lg border border-slate-200 bg-white dark:border-slate-700 dark:bg-slate-900", children: /* @__PURE__ */ t(
5513
- Ci,
5514
+ $i,
5514
5515
  {
5515
5516
  collection: n,
5516
5517
  config: wa,
@@ -5523,7 +5524,7 @@ ${r}`).then(() => {
5523
5524
  }
5524
5525
  ) }) }) : ft && (A != null && A.some((e) => e.key === ft)) ? /* @__PURE__ */ t("div", { className: "flex min-h-0 flex-1 flex-col p-4 pt-3", "data-cbv-extra-view": ft, children: (Tl = A.find((e) => e.key === ft)) == null ? void 0 : Tl.render() }) : null,
5525
5526
  Ia && ea ? /* @__PURE__ */ t("div", { className: "flex min-h-0 flex-1 flex-col p-4 pt-3", children: /* @__PURE__ */ t(
5526
- rd,
5527
+ ld,
5527
5528
  {
5528
5529
  collection: n,
5529
5530
  latField: ea.latField,
@@ -5548,7 +5549,7 @@ ${r}`).then(() => {
5548
5549
  /* @__PURE__ */ t("div", { className: "cbv-progress pointer-events-none absolute inset-x-0 top-0 z-[6] h-[3px] overflow-hidden" }),
5549
5550
  /* @__PURE__ */ t("div", { className: "cbv-overlay nvr-fade-in pointer-events-none absolute inset-0 z-[5] flex items-start justify-center bg-white/40 pt-24 dark:bg-slate-950/35", children: /* @__PURE__ */ c("span", { className: "nvr-pop-in flex items-center gap-2 rounded-full border border-slate-200 bg-white px-3 py-1.5 text-[12px] font-medium text-slate-600 shadow-lg dark:border-slate-700 dark:bg-slate-900 dark:text-slate-300", children: [
5550
5551
  /* @__PURE__ */ t(Gn, { "aria-hidden": !0, className: "h-3.5 w-3.5 animate-spin text-[#00a5cc]" }),
5551
- Qr != null ? `Still working — ${Qr}s` : "Loading…"
5552
+ Ur != null ? `Still working — ${Ur}s` : "Loading…"
5552
5553
  ] }) })
5553
5554
  ] }),
5554
5555
  /* @__PURE__ */ t(
@@ -5589,13 +5590,13 @@ ${r}`).then(() => {
5589
5590
  ref: Hn("__checkbox__"),
5590
5591
  className: "sticky left-0 top-0 z-[4] h-8 w-11 bg-slate-50 py-0 pl-1.5 pr-3 dark:bg-slate-800",
5591
5592
  children: /* @__PURE__ */ c("span", { className: "flex items-center gap-1", children: [
5592
- /* @__PURE__ */ t(Wl, { change: null }),
5593
+ /* @__PURE__ */ t(Ql, { change: null }),
5593
5594
  /* @__PURE__ */ t(
5594
5595
  "input",
5595
5596
  {
5596
5597
  type: "checkbox",
5597
5598
  checked: Wn,
5598
- onChange: Hs,
5599
+ onChange: Js,
5599
5600
  "aria-label": "Select all"
5600
5601
  }
5601
5602
  )
@@ -5605,7 +5606,7 @@ ${r}`).then(() => {
5605
5606
  oa.map((e) => {
5606
5607
  const a = e.key, r = !!ht(a), l = `group/hcell sticky top-0 h-8 select-none whitespace-nowrap bg-slate-50 px-3 py-0 text-[10px] font-bold uppercase tracking-wider text-slate-500 dark:bg-slate-800 dark:text-slate-400 ${r ? "z-[4]" : "z-[2]"}`, s = Ge(a, "", "");
5607
5608
  if (e.kind !== "data") {
5608
- const ne = e.kind === "state" ? "State" : e.kind === "entered" ? "Last State Change" : e.kind === "aging" ? "Aging" : e.kind === "owners" ? "Owners" : e.kind === "addendums" ? "Addendums" : e.kind === "fulfilment" ? Qe != null && Qe.label ? `${Qe.label} shipped` : "Shipped" : e.kind === "integrations" ? "Integrations" : e.kind === "tasks" ? "Tasks" : e.kind === "formula" ? dt(a) : "";
5609
+ const ne = e.kind === "state" ? "State" : e.kind === "entered" ? "Last State Change" : e.kind === "aging" ? "Aging" : e.kind === "owners" ? "Owners" : e.kind === "addendums" ? "Addendums" : e.kind === "fulfilment" ? Ue != null && Ue.label ? `${Ue.label} shipped` : "Shipped" : e.kind === "integrations" ? "Integrations" : e.kind === "tasks" ? "Tasks" : e.kind === "formula" ? dt(a) : "";
5609
5610
  return /* @__PURE__ */ c(
5610
5611
  "th",
5611
5612
  {
@@ -5625,9 +5626,9 @@ ${r}`).then(() => {
5625
5626
  "th",
5626
5627
  {
5627
5628
  ref: r ? Hn(a) : void 0,
5628
- style: { ...so(a), ...Te(a) },
5629
+ style: { ...oo(a), ...Te(a) },
5629
5630
  onClick: () => {
5630
- R || Ys(a);
5631
+ R || Hs(a);
5631
5632
  },
5632
5633
  className: `${l} relative ${al(a) ? "text-right" : "text-left"} ${R ? "" : "cursor-pointer hover:text-slate-600"} ${s}`,
5633
5634
  children: [
@@ -5649,14 +5650,14 @@ ${r}`).then(() => {
5649
5650
  }
5650
5651
  ),
5651
5652
  xl(a),
5652
- lo(a)
5653
+ so(a)
5653
5654
  ]
5654
5655
  },
5655
5656
  a
5656
5657
  );
5657
5658
  })
5658
5659
  ] }),
5659
- (Ds || Sa) && /* @__PURE__ */ c("tr", { className: "border-b border-slate-200 dark:border-slate-700", children: [
5660
+ (Os || Sa) && /* @__PURE__ */ c("tr", { className: "border-b border-slate-200 dark:border-slate-700", children: [
5660
5661
  Rt && /* @__PURE__ */ t("th", { className: "sticky left-0 top-8 z-[4] w-11 bg-slate-50 py-1 pl-1.5 pr-3 dark:bg-slate-800" }),
5661
5662
  oa.map((e) => {
5662
5663
  var s;
@@ -5687,8 +5688,8 @@ ${r}`).then(() => {
5687
5688
  value: (d == null ? void 0 : d.kind) === "fulfilment" ? d.value : "",
5688
5689
  options: [
5689
5690
  { value: "", label: "All" },
5690
- ...Vi.filter(
5691
- (p) => p.value !== "complete" || !!(Qe != null && Qe.remaining_field)
5691
+ ...Yi.filter(
5692
+ (p) => p.value !== "complete" || !!(Ue != null && Ue.remaining_field)
5692
5693
  )
5693
5694
  ],
5694
5695
  onChange: (p) => Ee(
@@ -5748,7 +5749,7 @@ ${r}`).then(() => {
5748
5749
  value: p,
5749
5750
  options: [
5750
5751
  { value: "", label: "All" },
5751
- ...Zi
5752
+ ...ed
5752
5753
  ],
5753
5754
  onChange: (R) => Ee(
5754
5755
  "__integrations__",
@@ -5799,11 +5800,11 @@ ${r}`).then(() => {
5799
5800
  className: `${l} ${e.kind === "actions" ? "w-20" : ""}`
5800
5801
  },
5801
5802
  a
5802
- ) : /* @__PURE__ */ t("th", { style: Te(a), className: l, children: Ms(a) }, a);
5803
+ ) : /* @__PURE__ */ t("th", { style: Te(a), className: l, children: Ds(a) }, a);
5803
5804
  })
5804
5805
  ] })
5805
5806
  ] }),
5806
- /* @__PURE__ */ t("tbody", { className: "text-[12px] tabular-nums", children: Br ? Array.from({ length: 12 }, (e, a) => /* @__PURE__ */ t("tr", { className: "border-b border-slate-100 dark:border-slate-800", children: /* @__PURE__ */ t("td", { className: "px-3 py-2", colSpan: ce.length + Un, children: /* @__PURE__ */ t(
5807
+ /* @__PURE__ */ t("tbody", { className: "text-[12px] tabular-nums", children: Br ? Array.from({ length: 12 }, (e, a) => /* @__PURE__ */ t("tr", { className: "border-b border-slate-100 dark:border-slate-800", children: /* @__PURE__ */ t("td", { className: "px-3 py-2", colSpan: ce.length + Qn, children: /* @__PURE__ */ t(
5807
5808
  "span",
5808
5809
  {
5809
5810
  className: "cbv-shimmer block h-3.5 rounded",
@@ -5812,10 +5813,10 @@ ${r}`).then(() => {
5812
5813
  ) }) }, a)) : xe.length === 0 ? /* @__PURE__ */ t("tr", { children: /* @__PURE__ */ t(
5813
5814
  "td",
5814
5815
  {
5815
- colSpan: ce.length + Un,
5816
+ colSpan: ce.length + Qn,
5816
5817
  className: "nvr-fade-in py-16",
5817
5818
  children: (() => {
5818
- const e = Q.length === 0 && Object.keys(Ae).length === 0 && !Object.values(ot).some((r) => r.length > 0) && !O, a = D == null ? void 0 : D.empty_state;
5819
+ const e = U.length === 0 && Object.keys(Ae).length === 0 && !Object.values(ot).some((r) => r.length > 0) && !O, a = D == null ? void 0 : D.empty_state;
5819
5820
  if (e && a && (a.title || a.message)) {
5820
5821
  const r = a.cta_url ?? "", l = r.startsWith("/"), s = /^https?:\/\//.test(r);
5821
5822
  return /* @__PURE__ */ c("div", { className: "flex flex-col items-center gap-2 text-center", children: [
@@ -5835,7 +5836,7 @@ ${r}`).then(() => {
5835
5836
  }
5836
5837
  return Je != null ? null : /* @__PURE__ */ c("div", { className: "flex flex-col items-center gap-2 text-center", children: [
5837
5838
  /* @__PURE__ */ t("span", { className: "flex h-10 w-10 items-center justify-center rounded-full bg-slate-100 dark:bg-slate-800", children: /* @__PURE__ */ t(
5838
- Gl,
5839
+ Xl,
5839
5840
  {
5840
5841
  "aria-hidden": !0,
5841
5842
  className: "h-4.5 w-4.5 h-5 w-5 text-slate-400"
@@ -5861,7 +5862,7 @@ ${r}`).then(() => {
5861
5862
  "button",
5862
5863
  {
5863
5864
  type: "button",
5864
- onClick: ys,
5865
+ onClick: ws,
5865
5866
  className: "font-medium text-[#0284a8] underline-offset-2 hover:underline dark:text-nvr-cyan",
5866
5867
  children: "Show all"
5867
5868
  }
@@ -5869,7 +5870,7 @@ ${r}`).then(() => {
5869
5870
  ]
5870
5871
  }
5871
5872
  ) : /* @__PURE__ */ t("p", { className: "text-[12px] text-slate-400", children: "Try adjusting your search or filters." }),
5872
- (Q.length > 0 || Object.keys(Ae).length > 0 || Object.values(ot).some((r) => r.length > 0) || O) && /* @__PURE__ */ t(
5873
+ (U.length > 0 || Object.keys(Ae).length > 0 || Object.values(ot).some((r) => r.length > 0) || O) && /* @__PURE__ */ t(
5873
5874
  "button",
5874
5875
  {
5875
5876
  type: "button",
@@ -5883,7 +5884,7 @@ ${r}`).then(() => {
5883
5884
  ] });
5884
5885
  })()
5885
5886
  }
5886
- ) }) : to.map((e, a) => {
5887
+ ) }) : ao.map((e, a) => {
5887
5888
  var ne;
5888
5889
  const r = { animationDelay: `${Math.min(a, 14) * 16}ms` };
5889
5890
  if (e.kind === "header")
@@ -5900,7 +5901,7 @@ ${r}`).then(() => {
5900
5901
  "td",
5901
5902
  {
5902
5903
  className: "px-3 py-1.5",
5903
- colSpan: ce.length + Un,
5904
+ colSpan: ce.length + Qn,
5904
5905
  children: /* @__PURE__ */ c("span", { className: "flex items-center gap-1.5 text-[12px] font-medium text-slate-600 dark:text-slate-200", children: [
5905
5906
  /* @__PURE__ */ t(
5906
5907
  qa,
@@ -5916,15 +5917,15 @@ ${r}`).then(() => {
5916
5917
  },
5917
5918
  `__group__${e.gkey}`
5918
5919
  );
5919
- const l = e.row, s = l.id, d = Kt.includes(s), p = (ne = Ne == null ? void 0 : Ne.instances) == null ? void 0 : ne[String(s)], R = qs[String(s)], M = On == null ? void 0 : On[String(s)], Se = Cs.get(String(s)) ?? null, Z = !d && R ? ni(R.color) : void 0, se = d ? "bg-[#e6fafe] dark:bg-[#0c2a33]" : Z ?? "bg-white group-hover:bg-[#f2fcff] dark:bg-slate-900 dark:group-hover:bg-[#0e2d3a]";
5920
+ const l = e.row, s = l.id, d = Kt.includes(s), p = (ne = Ne == null ? void 0 : Ne.instances) == null ? void 0 : ne[String(s)], R = Ts[String(s)], M = On == null ? void 0 : On[String(s)], Se = $s.get(String(s)) ?? null, Z = !d && R ? ri(R.color) : void 0, se = d ? "bg-[#e6fafe] dark:bg-[#0c2a33]" : Z ?? "bg-white group-hover:bg-[#f2fcff] dark:bg-slate-900 dark:group-hover:bg-[#0e2d3a]";
5920
5921
  return /* @__PURE__ */ c(
5921
5922
  "tr",
5922
5923
  {
5923
- ...ws({ collection: n, id: String(s) }),
5924
+ ..._s({ collection: n, id: String(s) }),
5924
5925
  onClick: () => sa(s),
5925
- onMouseEnter: () => Vs(s),
5926
+ onMouseEnter: () => Ys(s),
5926
5927
  "data-row-key": String(s),
5927
- title: kt.titleFor(String(s)) ?? (Se && !Se.is_mine ? Bo(Se) : void 0) ?? (R ? `At risk — ${R.rule}` : void 0),
5928
+ title: kt.titleFor(String(s)) ?? (Se && !Se.is_mine ? zo(Se) : void 0) ?? (R ? `At risk — ${R.rule}` : void 0),
5928
5929
  style: r,
5929
5930
  className: `nvr-row-enter group h-8 cursor-pointer border-b border-slate-100 transition-colors duration-150 hover:bg-nvr-cyan/[0.04] dark:border-slate-800 dark:hover:bg-nvr-cyan/[0.08] ${d ? "bg-nvr-cyan/[0.08]" : Z ?? ""}`,
5930
5931
  children: [
@@ -5935,26 +5936,26 @@ ${r}`).then(() => {
5935
5936
  onClick: (K) => K.stopPropagation(),
5936
5937
  children: /* @__PURE__ */ c("span", { className: "flex items-center gap-1", children: [
5937
5938
  Se || kt.isNew(String(s)) ? /* @__PURE__ */ t(
5938
- nd,
5939
+ rd,
5939
5940
  {
5940
5941
  lock: Se,
5941
5942
  isNew: kt.isNew(String(s)),
5942
5943
  dataAttr: "data-cbv-live-mark"
5943
5944
  }
5944
5945
  ) : Vr[jl(n, String(s))] ? /* @__PURE__ */ t(
5945
- dd,
5946
+ cd,
5946
5947
  {
5947
5948
  viewers: Vr[jl(n, String(s))],
5948
5949
  dataAttr: "data-cbv-presence"
5949
5950
  }
5950
- ) : /* @__PURE__ */ t(Wl, { change: M, dataAttr: "data-cbv-unseen" }),
5951
- /* @__PURE__ */ t(ki, { rowId: s }),
5951
+ ) : /* @__PURE__ */ t(Ql, { change: M, dataAttr: "data-cbv-unseen" }),
5952
+ /* @__PURE__ */ t(yi, { rowId: s }),
5952
5953
  /* @__PURE__ */ t(
5953
5954
  "input",
5954
5955
  {
5955
5956
  type: "checkbox",
5956
5957
  checked: d,
5957
- onChange: () => Js(s),
5958
+ onChange: () => Gs(s),
5958
5959
  "aria-label": `Select ${s}`
5959
5960
  }
5960
5961
  )
@@ -5962,7 +5963,7 @@ ${r}`).then(() => {
5962
5963
  }
5963
5964
  ),
5964
5965
  oa.map((K) => {
5965
- var yt, ut, pt, Ut, U, G;
5966
+ var yt, ut, pt, Qt, Q, G;
5966
5967
  const h = K.key;
5967
5968
  if (K.kind === "state")
5968
5969
  return /* @__PURE__ */ t(
@@ -6033,7 +6034,7 @@ ${r}`).then(() => {
6033
6034
  style: Te(h),
6034
6035
  "data-tip": ze != null && ($ != null && $.entered_at) ? `In ${$.state_label ?? "this state"} since ${new Date($.entered_at).toLocaleString()}` : void 0,
6035
6036
  className: `whitespace-nowrap px-3 py-1.5 text-[12px] tabular-nums text-slate-600 dark:text-slate-300 ${Ge(h, "z-[1]", se)}`,
6036
- children: ze == null ? /* @__PURE__ */ t("span", { className: "text-slate-300 dark:text-slate-600", children: "—" }) : ui(ze)
6037
+ children: ze == null ? /* @__PURE__ */ t("span", { className: "text-slate-300 dark:text-slate-600", children: "—" }) : pi(ze)
6037
6038
  },
6038
6039
  h
6039
6040
  );
@@ -6046,7 +6047,7 @@ ${r}`).then(() => {
6046
6047
  className: `whitespace-nowrap px-3 py-1 ${Ge(h, "z-[1]", se)}`,
6047
6048
  onClick: ($) => $.stopPropagation(),
6048
6049
  children: /* @__PURE__ */ t(
6049
- Bl,
6050
+ zl,
6050
6051
  {
6051
6052
  users: (jn == null ? void 0 : jn[String(s)]) ?? [],
6052
6053
  showSingleName: !1
@@ -6062,12 +6063,12 @@ ${r}`).then(() => {
6062
6063
  {
6063
6064
  style: Te(h),
6064
6065
  className: `whitespace-nowrap px-3 py-1.5 ${Ge(h, "z-[1]", se)}`,
6065
- children: /* @__PURE__ */ t(vd, { summary: $ })
6066
+ children: /* @__PURE__ */ t(kd, { summary: $ })
6066
6067
  },
6067
6068
  h
6068
6069
  );
6069
6070
  }
6070
- if (K.kind === "fulfilment" && Qe)
6071
+ if (K.kind === "fulfilment" && Ue)
6071
6072
  return /* @__PURE__ */ t(
6072
6073
  "td",
6073
6074
  {
@@ -6075,15 +6076,15 @@ ${r}`).then(() => {
6075
6076
  className: `whitespace-nowrap px-3 py-1.5 ${Ge(h, "z-[1]", se)}`,
6076
6077
  onClick: ($) => $.stopPropagation(),
6077
6078
  children: /* @__PURE__ */ t(
6078
- Yi,
6079
+ Hi,
6079
6080
  {
6080
6081
  collection: n,
6081
6082
  itemId: String(s),
6082
- figures: Hi(
6083
- l[Qe.shipped_field],
6084
- l[Qe.requested_field]
6083
+ figures: Ji(
6084
+ l[Ue.shipped_field],
6085
+ l[Ue.requested_field]
6085
6086
  ),
6086
- label: Qe.label
6087
+ label: Ue.label
6087
6088
  }
6088
6089
  )
6089
6090
  },
@@ -6095,7 +6096,7 @@ ${r}`).then(() => {
6095
6096
  {
6096
6097
  style: Te(h),
6097
6098
  className: `whitespace-nowrap px-3 py-1.5 ${Ge(h, "z-[1]", se)}`,
6098
- children: /* @__PURE__ */ t(ed, { rows: An == null ? void 0 : An[String(s)] })
6099
+ children: /* @__PURE__ */ t(td, { rows: An == null ? void 0 : An[String(s)] })
6099
6100
  },
6100
6101
  h
6101
6102
  );
@@ -6123,13 +6124,13 @@ ${r}`).then(() => {
6123
6124
  );
6124
6125
  }
6125
6126
  if (K.kind === "formula") {
6126
- const $ = bs(l, h);
6127
+ const $ = hs(l, h);
6127
6128
  return /* @__PURE__ */ t(
6128
6129
  "td",
6129
6130
  {
6130
6131
  style: Te(h),
6131
6132
  "data-cbv-formula-cell": h,
6132
- "data-tip": hs(l, h),
6133
+ "data-tip": fs(l, h),
6133
6134
  className: `whitespace-nowrap px-3 py-1.5 text-right tabular-nums text-slate-700 dark:text-slate-200 ${Ge(h, "z-[1]", se)}`,
6134
6135
  children: $ == null ? /* @__PURE__ */ t("span", { className: "text-slate-300 dark:text-slate-600", children: "—" }) : te[h] ? ia(String($), te[h]) : rt(Math.round($ * 100) / 100)
6135
6136
  },
@@ -6144,7 +6145,7 @@ ${r}`).then(() => {
6144
6145
  className: `w-20 whitespace-nowrap px-2 py-1 text-right ${Ge(h, "z-[1]", se)}`,
6145
6146
  onClick: ($) => $.stopPropagation(),
6146
6147
  children: /* @__PURE__ */ t(
6147
- yd,
6148
+ wd,
6148
6149
  {
6149
6150
  collection: n,
6150
6151
  id: s,
@@ -6161,7 +6162,7 @@ ${r}`).then(() => {
6161
6162
  },
6162
6163
  h
6163
6164
  );
6164
- const B = Dt(h) ? Fs(s, h) : null, Xe = Dt(h) ? null : Ve(at, n, h);
6165
+ const B = Dt(h) ? Rs(s, h) : null, Xe = Dt(h) ? null : Ve(at, n, h);
6165
6166
  return /* @__PURE__ */ t(
6166
6167
  "td",
6167
6168
  {
@@ -6182,10 +6183,10 @@ ${r}`).then(() => {
6182
6183
  if (de.length === 0 || !ze || ze === "—")
6183
6184
  return /* @__PURE__ */ t("span", { className: "text-[12px] text-slate-300", children: "—" });
6184
6185
  if (de.length === 1)
6185
- return /* @__PURE__ */ t("span", { onClick: (We) => We.stopPropagation(), children: /* @__PURE__ */ t(zl, { userId: String(de[0]), size: "compact" }) });
6186
+ return /* @__PURE__ */ t("span", { onClick: (We) => We.stopPropagation(), children: /* @__PURE__ */ t(Wl, { userId: String(de[0]), size: "compact" }) });
6186
6187
  const V = ze.split(", ");
6187
6188
  return /* @__PURE__ */ t(
6188
- Bl,
6189
+ zl,
6189
6190
  {
6190
6191
  users: de.map((We, wt) => ({
6191
6192
  id: String(We),
@@ -6215,9 +6216,9 @@ ${r}`).then(() => {
6215
6216
  {
6216
6217
  className: "block max-w-[260px] truncate text-[12px] text-slate-700 dark:text-slate-200",
6217
6218
  "data-tip": ct(s, h) ?? void 0,
6218
- children: ct(s, h) != null ? `${((Ut = te[h]) == null ? void 0 : Ut.type) === "count" && nl(h) ? "📎 " : ""}${ra(ct(s, h) ?? "", h, s)}` : /* @__PURE__ */ t("span", { className: "inline-block h-3.5 w-16 animate-pulse rounded bg-slate-100 dark:bg-[hsl(var(--nvr-skeleton))]" })
6219
+ children: ct(s, h) != null ? `${((Qt = te[h]) == null ? void 0 : Qt.type) === "count" && nl(h) ? "📎 " : ""}${ra(ct(s, h) ?? "", h, s)}` : /* @__PURE__ */ t("span", { className: "inline-block h-3.5 w-16 animate-pulse rounded bg-slate-100 dark:bg-[hsl(var(--nvr-skeleton))]" })
6219
6220
  }
6220
- ) : (Xe == null ? void 0 : Xe.one_collection) === "nivaro_users" && l[h] != null ? /* @__PURE__ */ t("span", { onClick: ($) => $.stopPropagation(), children: /* @__PURE__ */ t(zl, { userId: String(l[h]), size: "compact" }) }) : Xe != null && Xe.one_collection && l[h] != null && !gt(Xe.one_collection) ? /* @__PURE__ */ t(
6221
+ ) : (Xe == null ? void 0 : Xe.one_collection) === "nivaro_users" && l[h] != null ? /* @__PURE__ */ t("span", { onClick: ($) => $.stopPropagation(), children: /* @__PURE__ */ t(Wl, { userId: String(l[h]), size: "compact" }) }) : Xe != null && Xe.one_collection && l[h] != null && !gt(Xe.one_collection) ? /* @__PURE__ */ t(
6221
6222
  "button",
6222
6223
  {
6223
6224
  type: "button",
@@ -6243,7 +6244,7 @@ ${r}`).then(() => {
6243
6244
  {
6244
6245
  className: Ot(
6245
6246
  "text-[12px] tabular-nums text-slate-700 dark:text-slate-200",
6246
- Xa(l[h], Fe[h]) && Ql[Xa(l[h], Fe[h])]
6247
+ Xa(l[h], Fe[h]) && Vl[Xa(l[h], Fe[h])]
6247
6248
  ),
6248
6249
  children: ia(String(l[h]), te[h])
6249
6250
  }
@@ -6252,21 +6253,21 @@ ${r}`).then(() => {
6252
6253
  {
6253
6254
  className: Ot(
6254
6255
  "text-[12px]",
6255
- Ql[Xa(l[h], Fe[h])]
6256
+ Vl[Xa(l[h], Fe[h])]
6256
6257
  ),
6257
6258
  children: /* @__PURE__ */ t(
6258
- Vl,
6259
+ Yl,
6259
6260
  {
6260
6261
  collection: n,
6261
6262
  field: h,
6262
- fieldType: ((U = vt.get(h)) == null ? void 0 : U.type) ?? null,
6263
+ fieldType: ((Q = vt.get(h)) == null ? void 0 : Q.type) ?? null,
6263
6264
  value: l[h],
6264
6265
  relations: at
6265
6266
  }
6266
6267
  )
6267
6268
  }
6268
6269
  ) : /* @__PURE__ */ t(
6269
- Vl,
6270
+ Yl,
6270
6271
  {
6271
6272
  collection: n,
6272
6273
  field: h,
@@ -6283,7 +6284,7 @@ ${r}`).then(() => {
6283
6284
  },
6284
6285
  String(s)
6285
6286
  );
6286
- }) }, ks),
6287
+ }) }, ys),
6287
6288
  Sn && Object.keys(Sn).length > 0 && !w && /* @__PURE__ */ t("tfoot", { className: "text-[12px] tabular-nums", children: /* @__PURE__ */ c("tr", { className: "sticky bottom-0 z-[2] border-t-2 border-slate-200 bg-slate-50 font-medium dark:border-slate-700 dark:bg-slate-800", children: [
6288
6289
  Rt && /* @__PURE__ */ t("td", { className: "sticky left-0 z-[3] w-11 bg-slate-50 py-1.5 pl-1.5 pr-3 dark:bg-slate-800" }),
6289
6290
  oa.map((e, a) => {
@@ -6305,9 +6306,9 @@ ${r}`).then(() => {
6305
6306
  )
6306
6307
  }
6307
6308
  ),
6308
- /* @__PURE__ */ t(Ji, { scrollerRef: vr }),
6309
+ /* @__PURE__ */ t(Gi, { scrollerRef: vr }),
6309
6310
  /* @__PURE__ */ t(
6310
- id,
6311
+ dd,
6311
6312
  {
6312
6313
  collections: n ? [n] : [],
6313
6314
  selectedIds: Mt,
@@ -6329,9 +6330,9 @@ ${r}`).then(() => {
6329
6330
  !w && !Me && (ta ? v > 1 || xe.length >= tt : qe > tt) && /* @__PURE__ */ c("div", { className: "flex shrink-0 items-center justify-between border-t border-slate-100 bg-white px-3 py-2 dark:border-slate-800 dark:bg-slate-900", children: [
6330
6331
  /* @__PURE__ */ c("p", { className: "text-[12px] tabular-nums text-slate-500 dark:text-slate-400", children: [
6331
6332
  /* @__PURE__ */ c("span", { className: "font-semibold text-slate-700 dark:text-slate-200", children: [
6332
- rt(Xs),
6333
+ rt(Zs),
6333
6334
  "–",
6334
- rt(Zs)
6335
+ rt(eo)
6335
6336
  ] }),
6336
6337
  " ",
6337
6338
  "of",
@@ -6406,20 +6407,20 @@ ${r}`).then(() => {
6406
6407
  )
6407
6408
  }
6408
6409
  ),
6409
- Ue != null && Ue.length ? /* @__PURE__ */ t(
6410
- od,
6410
+ Qe != null && Qe.length ? /* @__PURE__ */ t(
6411
+ id,
6411
6412
  {
6412
- collection: Ue[0].collection,
6413
- itemId: Ue[0].itemId,
6413
+ collection: Qe[0].collection,
6414
+ itemId: Qe[0].itemId,
6414
6415
  width: "85%",
6415
- stack: Ue,
6416
- onPush: (e) => it.push([...Ue, e]),
6416
+ stack: Qe,
6417
+ onPush: (e) => it.push([...Qe, e]),
6417
6418
  onPop: () => it.back(),
6418
- onClose: () => it.back(Ue.length)
6419
+ onClose: () => it.back(Qe.length)
6419
6420
  }
6420
6421
  ) : null,
6421
6422
  ha && /* @__PURE__ */ t(
6422
- pd,
6423
+ md,
6423
6424
  {
6424
6425
  collection: n,
6425
6426
  item: ha,
@@ -6441,14 +6442,14 @@ ${r}`).then(() => {
6441
6442
  {
6442
6443
  type: "button",
6443
6444
  disabled: pl,
6444
- onClick: () => void Gs(),
6445
+ onClick: () => void Xs(),
6445
6446
  className: "font-semibold text-nvr-navy underline decoration-dotted hover:text-nvr-cyan dark:text-nvr-cyan",
6446
6447
  children: pl ? "Selecting…" : qe > Ja ? `Select the first ${Ja.toLocaleString()} of ${qe.toLocaleString()} matching` : `Select all ${qe.toLocaleString()} matching rows`
6447
6448
  }
6448
6449
  )
6449
6450
  ] }),
6450
6451
  Rt && Kt.length > 0 && /* @__PURE__ */ t(
6451
- Dd,
6452
+ Od,
6452
6453
  {
6453
6454
  collection: n,
6454
6455
  selectedIds: Kt,
@@ -6464,8 +6465,8 @@ ${r}`).then(() => {
6464
6465
  }
6465
6466
  );
6466
6467
  }
6467
- function Od(n, i, m, o) {
6468
- const f = es(i, n, m);
6468
+ function Ad(n, i, m, o) {
6469
+ const f = ts(i, n, m);
6469
6470
  if (f != null && f.one_collection) return /* @__PURE__ */ t(ir, { relatedCollection: f.one_collection, id: o });
6470
6471
  if (typeof o == "boolean") return o ? "Yes" : "No";
6471
6472
  if (typeof o == "object") return JSON.stringify(o).slice(0, 80);
@@ -6473,11 +6474,11 @@ function Od(n, i, m, o) {
6473
6474
  return /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}/.test(y) ? new Date(y).toLocaleString() : y.length > 160 ? `${y.slice(0, 160)}…` : y;
6474
6475
  }
6475
6476
  export {
6476
- Jc as CollectionBrowserView,
6477
+ Xc as CollectionBrowserView,
6477
6478
  ln as MultiPick,
6478
- yd as RowActionsMenu,
6479
- Ql as TINT_TEXT,
6479
+ wd as RowActionsMenu,
6480
+ Vl as TINT_TEXT,
6480
6481
  tn as invalidateCbvRowQueries,
6481
- kd as roleMayDelete,
6482
+ yd as roleMayDelete,
6482
6483
  Xa as tintFor
6483
6484
  };