@nivaro/react 0.3.111 → 0.3.112

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/dist/full.css +1 -1
  2. package/dist/hooks/useSessionRecorder.js +1 -1
  3. package/dist/index.d.ts +170 -2
  4. package/dist/index.js +745 -728
  5. package/dist/shared/components/CollectionBrowserView.js +3097 -2972
  6. package/dist/shared/components/CollectionImportBanner.js +135 -0
  7. package/dist/shared/components/ItemEditForm.js +2235 -2218
  8. package/dist/shared/components/JobsTray.js +54 -47
  9. package/dist/shared/components/ViewAsPersonButton.js +109 -0
  10. package/dist/shared/components/bulk/BulkFieldUpdate.js +228 -150
  11. package/dist/shared/components/bulk/BulkFieldUpdateButton.js +35 -41
  12. package/dist/shared/components/bulk/BulkLinksValue.js +91 -0
  13. package/dist/shared/components/bulk/bulk-field-options.js +20 -19
  14. package/dist/shared/components/bulk/bulk-update-preview.js +39 -0
  15. package/dist/shared/components/cbv/ColumnHeaderMenu.js +113 -0
  16. package/dist/shared/components/cbv/column-totals.js +66 -0
  17. package/dist/shared/components/collections-directory/CollectionHoverCard.js +108 -81
  18. package/dist/shared/components/collections-directory/CollectionRow.js +164 -148
  19. package/dist/shared/components/collections-directory/CollectionsDirectory.js +167 -166
  20. package/dist/shared/components/collections-directory/directory-data.js +70 -58
  21. package/dist/shared/components/imports/CollectionImportPanel.js +120 -118
  22. package/dist/shared/components/imports/DefinitionsPanel.js +24 -24
  23. package/dist/shared/components/imports/ImportDuplicatesNotice.js +65 -0
  24. package/dist/shared/components/item-edit/CatalogPickerField.js +631 -639
  25. package/dist/shared/components/item-edit/DuplicateNotice.js +168 -0
  26. package/dist/shared/components/item-edit/FieldRow.js +248 -246
  27. package/dist/shared/components/item-edit/InlineGridField.js +34 -33
  28. package/dist/shared/components/item-edit/InlineTableField.js +3064 -2882
  29. package/dist/shared/components/item-edit/MembershipSetField.js +165 -169
  30. package/dist/shared/components/item-edit/NestedRelationEditor.js +184 -189
  31. package/dist/shared/components/item-edit/PlanGrid.js +2 -1
  32. package/dist/shared/components/item-edit/QuickPickerDialog.js +35 -34
  33. package/dist/shared/components/item-edit/RecordLiveSync.js +32 -30
  34. package/dist/shared/components/item-edit/RelationCombobox.js +101 -100
  35. package/dist/shared/components/item-edit/RowHistorySheet.js +28 -27
  36. package/dist/shared/components/item-edit/SummaryPanel.js +133 -135
  37. package/dist/shared/components/item-edit/ViewAsRole.js +129 -52
  38. package/dist/shared/components/item-edit/grid-search.js +345 -0
  39. package/dist/shared/components/item-edit/render-stability.js +61 -54
  40. package/dist/shared/components/notifications/NotificationRulesEditor.js +25 -20
  41. package/dist/shared/components/ops-report/DigestSections.js +163 -144
  42. package/dist/shared/components/ops-report/drill.js +97 -97
  43. package/dist/shared/components/panels/AddendumLinesDiff.js +52 -51
  44. package/dist/shared/components/panels/AddendumPanel.js +92 -91
  45. package/dist/shared/components/panels/AsyncUserPicker.js +108 -0
  46. package/dist/shared/components/panels/CommentPanel.js +265 -252
  47. package/dist/shared/components/panels/OwnersSlot.js +47 -35
  48. package/dist/shared/components/panels/PipelineInsight.js +186 -0
  49. package/dist/shared/components/panels/PipelinePanel.js +1529 -1492
  50. package/dist/shared/components/panels/RecordIntegrityBanner.js +39 -38
  51. package/dist/shared/components/panels/RevisionsPanel.js +261 -260
  52. package/dist/shared/components/pipeline/FieldPicker.js +41 -40
  53. package/dist/shared/components/pipeline/OwnerMatrix.js +829 -700
  54. package/dist/shared/components/pipeline/OwnerRecordTrial.js +362 -0
  55. package/dist/shared/components/pipeline/PipelineEditorView.js +483 -467
  56. package/dist/shared/components/pipeline/PipelineStateOwners.js +65 -64
  57. package/dist/shared/components/pipeline/owner-matrix-draft.js +178 -0
  58. package/dist/shared/components/profile/MyDefaultsCard.js +36 -35
  59. package/dist/shared/components/profile/PersonHeader.js +29 -29
  60. package/dist/shared/components/profile/PersonProfile.js +30 -28
  61. package/dist/shared/components/profile/SlowScreensCard.js +286 -0
  62. package/dist/shared/components/queue/QueueWorklist.js +1090 -1071
  63. package/dist/shared/components/quick-filters/useQuickFilterEditing.js +45 -44
  64. package/dist/shared/components/support/TicketDetailSheet.js +25 -16
  65. package/dist/shared/components/support/TicketSlowScreens.js +32 -0
  66. package/dist/shared/lib/activity-sentence.js +224 -178
  67. package/dist/shared/lib/collection-import-banner.js +27 -0
  68. package/dist/shared/lib/crash-report.js +112 -0
  69. package/dist/shared/lib/export-runs.js +99 -0
  70. package/dist/shared/lib/jobs-tray.js +89 -67
  71. package/dist/shared/lib/list-link.js +76 -69
  72. package/dist/shared/lib/nav-trail.js +180 -76
  73. package/dist/shared/lib/query-keys.js +26 -0
  74. package/dist/shared/lib/view-as.js +16 -11
  75. package/package.json +1 -1
@@ -1,33 +1,33 @@
1
- import { jsx as r, jsxs as p, Fragment as F } from "react/jsx-runtime";
2
- import { Pencil as O, Pin as V, Star as Y, EyeOff as q, Code2 as W, Link2 as G, Workflow as Q, LayoutTemplate as X, Download as z, Square as J } from "lucide-react";
3
- import { forwardRef as Z, useState as A } from "react";
4
- import { useNavigation as ee } from "../../context.js";
5
- import { titleCase as te, cn as l, resolveCollectionIcon as ne, formatNumber as re, formatDateTime as ae } from "../../lib/utils.js";
6
- import { Checkbox as oe } from "../ui/checkbox.js";
7
- import { useHoverIntent as se, CollectionHoverCard as ie } from "./CollectionHoverCard.js";
8
- import { CollectionRowMenu as ce } from "./CollectionRowMenu.js";
9
- import { recordCollectionOpen as le } from "./directory-data.js";
10
- const de = (t) => `/collections/${encodeURIComponent(t)}`, D = Z(function({ to: e, onClick: n, ...a }, i) {
11
- const { navigate: c } = ee();
1
+ import { jsx as r, jsxs as u, Fragment as V } from "react/jsx-runtime";
2
+ import { Pencil as Y, Pin as q, Star as W, AlertTriangle as G, EyeOff as Q, Code2 as X, Link2 as z, Workflow as J, LayoutTemplate as Z, Download as A, Square as ee } from "lucide-react";
3
+ import { forwardRef as te, useState as ne } from "react";
4
+ import { useNavigation as re } from "../../context.js";
5
+ import { titleCase as ae, cn as l, resolveCollectionIcon as oe, formatNumber as j, formatDateTime as ie } from "../../lib/utils.js";
6
+ import { Checkbox as se } from "../ui/checkbox.js";
7
+ import { useHoverIntent as le, CollectionHoverCard as ce } from "./CollectionHoverCard.js";
8
+ import { CollectionRowMenu as de } from "./CollectionRowMenu.js";
9
+ import { recordCollectionOpen as ue } from "./directory-data.js";
10
+ const me = (t) => `/collections/${encodeURIComponent(t)}`, P = te(function({ to: e, onClick: n, ...a }, i) {
11
+ const { navigate: m } = re();
12
12
  return /* @__PURE__ */ r(
13
13
  "a",
14
14
  {
15
15
  ref: i,
16
16
  href: e,
17
17
  ...a,
18
- onClick: (s) => {
19
- n == null || n(s), !s.defaultPrevented && (s.button !== 0 || s.metaKey || s.ctrlKey || s.shiftKey || s.altKey || (s.preventDefault(), c(e)));
18
+ onClick: (o) => {
19
+ n == null || n(o), !o.defaultPrevented && (o.button !== 0 || o.metaKey || o.ctrlKey || o.shiftKey || o.altKey || (o.preventDefault(), m(e)));
20
20
  }
21
21
  }
22
22
  );
23
23
  }), E = 3;
24
- function ue({
24
+ function pe({
25
25
  color: t,
26
26
  name: e,
27
27
  icon: n,
28
28
  size: a = "md"
29
29
  }) {
30
- const i = ne(n);
30
+ const i = oe(n);
31
31
  return /* @__PURE__ */ r(
32
32
  "div",
33
33
  {
@@ -41,32 +41,45 @@ function ue({
41
41
  }
42
42
  );
43
43
  }
44
- function pe(t, e) {
45
- const n = [];
46
- return t.hidden && !(e != null && e.link) && n.push({ key: "hidden", label: "Hidden", icon: q, tip: "Hidden from navigation" }), e != null && e.virtual && n.push({
44
+ function fe(t) {
45
+ return `The list opens on ${t.fields.map((n) => `${n.label} (up to ${j(n.max)} per record)`).join(" and ")} — slow and unreadable. Fix it in Data model → Collection Browser.`;
46
+ }
47
+ function he(t, e, n) {
48
+ const a = [];
49
+ return n && n.fields.length > 0 && a.push({
50
+ key: "heavy-list",
51
+ label: "Heavy list",
52
+ icon: G,
53
+ tip: fe(n),
54
+ warn: !0
55
+ }), t.hidden && !(e != null && e.link) && a.push({ key: "hidden", label: "Hidden", icon: Q, tip: "Hidden from navigation" }), e != null && e.virtual && a.push({
47
56
  key: "virtual",
48
57
  label: "Virtual",
49
- icon: W,
58
+ icon: X,
50
59
  tip: "Backed by SQL — read-only"
51
- }), e != null && e.link && n.push({ key: "link", label: "Link table", icon: G, tip: "Links two collections" }), e != null && e.pipeline && n.push({ key: "pipeline", label: "Pipeline", icon: Q, tip: e.pipeline }), e && e.forms > 0 && n.push({
60
+ }), e != null && e.link && a.push({ key: "link", label: "Link table", icon: z, tip: "Links two collections" }), e != null && e.pipeline && a.push({ key: "pipeline", label: "Pipeline", icon: J, tip: e.pipeline }), e && e.forms > 0 && a.push({
52
61
  key: "forms",
53
62
  label: e.forms > 1 ? `Form ×${e.forms}` : "Form",
54
- icon: X,
63
+ icon: Z,
55
64
  tip: `${e.forms} form layout${e.forms === 1 ? "" : "s"}`
56
- }), e && e.imports > 0 && n.push({
65
+ }), e && e.imports > 0 && a.push({
57
66
  key: "imports",
58
67
  label: "Imports",
59
- icon: z,
68
+ icon: A,
60
69
  tip: `${e.imports} import${e.imports === 1 ? "" : "s"} feed this collection`
61
- }), t.singleton && n.push({ key: "singleton", label: "Singleton", icon: J, tip: "Holds a single record" }), n;
70
+ }), t.singleton && a.push({ key: "singleton", label: "Singleton", icon: ee, tip: "Holds a single record" }), a;
62
71
  }
63
- function me({ spec: t }) {
72
+ function xe({ spec: t }) {
64
73
  const e = t.icon;
65
- return /* @__PURE__ */ p(
74
+ return /* @__PURE__ */ u(
66
75
  "span",
67
76
  {
68
77
  "data-tip": t.tip,
69
- className: "inline-flex items-center gap-1 whitespace-nowrap rounded px-1.5 py-px text-[10px] font-medium bg-slate-100 text-slate-500 dark:bg-white/10 dark:text-slate-400",
78
+ "data-badge": t.key,
79
+ className: l(
80
+ "inline-flex items-center gap-1 whitespace-nowrap rounded px-1.5 py-px text-[10px] font-medium",
81
+ t.warn ? "bg-amber-50 text-amber-700 ring-1 ring-inset ring-amber-200 dark:bg-amber-400/10 dark:text-amber-300 dark:ring-amber-400/25" : "bg-slate-100 text-slate-500 dark:bg-white/10 dark:text-slate-400"
82
+ ),
70
83
  children: [
71
84
  /* @__PURE__ */ r(e, { className: "h-[11px] w-[11px] shrink-0", "aria-hidden": "true" }),
72
85
  t.label
@@ -74,12 +87,12 @@ function me({ spec: t }) {
74
87
  }
75
88
  );
76
89
  }
77
- function fe({ items: t }) {
90
+ function be({ items: t }) {
78
91
  if (t.length === 0) return null;
79
92
  const e = t.slice(0, E), n = t.slice(E);
80
- return /* @__PURE__ */ p("span", { "data-cdr": "", className: "hidden shrink-0 items-center gap-1 sm:[&[data-cdr]]:flex", children: [
81
- e.map((a) => /* @__PURE__ */ r(me, { spec: a }, a.key)),
82
- n.length > 0 && /* @__PURE__ */ p(
93
+ return /* @__PURE__ */ u("span", { "data-cdr": "", className: "hidden shrink-0 items-center gap-1 sm:[&[data-cdr]]:flex", children: [
94
+ e.map((a) => /* @__PURE__ */ r(xe, { spec: a }, a.key)),
95
+ n.length > 0 && /* @__PURE__ */ u(
83
96
  "span",
84
97
  {
85
98
  "data-tip": n.map((a) => a.label).join(" · "),
@@ -92,13 +105,13 @@ function fe({ items: t }) {
92
105
  )
93
106
  ] });
94
107
  }
95
- function he(t, e) {
108
+ function ve(t, e) {
96
109
  const n = e == null ? void 0 : e.trim().toLowerCase();
97
110
  return n ? t.toLowerCase().indexOf(n) : -1;
98
111
  }
99
- function xe({ text: t, at: e, len: n }) {
112
+ function ke({ text: t, at: e, len: n }) {
100
113
  let a = t;
101
- return e >= 0 && n > 0 && (a = /* @__PURE__ */ p(F, { children: [
114
+ return e >= 0 && n > 0 && (a = /* @__PURE__ */ u(V, { children: [
102
115
  t.slice(0, e),
103
116
  /* @__PURE__ */ r("mark", { className: "rounded-sm bg-nvr-cyan/15 text-slate-700 dark:bg-nvr-cyan/25 dark:text-slate-200", children: t.slice(e, e + n) }),
104
117
  t.slice(e + n)
@@ -111,28 +124,28 @@ function xe({ text: t, at: e, len: n }) {
111
124
  }
112
125
  );
113
126
  }
114
- function ve(t, e = Date.now()) {
127
+ function ye(t, e = Date.now()) {
115
128
  const n = new Date(t), a = n.getTime();
116
129
  if (Number.isNaN(a)) return "—";
117
130
  const i = Math.floor((e - a) / 6e4);
118
131
  if (i < 1) return "just now";
119
132
  if (i < 60) return `${i}m ago`;
120
- const c = Math.floor(i / 60);
121
- if (c < 24) return `${c}h ago`;
122
- const s = Math.floor(c / 24);
123
- if (s < 7) return `${s}d ago`;
124
- const y = n.getFullYear() === new Date(e).getFullYear();
133
+ const m = Math.floor(i / 60);
134
+ if (m < 24) return `${m}h ago`;
135
+ const o = Math.floor(m / 24);
136
+ if (o < 7) return `${o}d ago`;
137
+ const h = n.getFullYear() === new Date(e).getFullYear();
125
138
  return n.toLocaleDateString("en-US", {
126
139
  month: "short",
127
140
  day: "numeric",
128
- ...y ? {} : { year: "numeric" }
141
+ ...h ? {} : { year: "numeric" }
129
142
  });
130
143
  }
131
- function be({ stat: t }) {
132
- const e = t.rows == null ? /* @__PURE__ */ r("span", { "data-tip": "Record count unknown", className: "text-slate-400 dark:text-slate-500", children: "—" }) : t.rows === 0 ? /* @__PURE__ */ r("span", { className: "text-slate-400 dark:text-slate-500", children: "Empty" }) : /* @__PURE__ */ r("span", { "data-tip": "Approximate record count", children: re(t.rows) });
133
- return /* @__PURE__ */ p("span", { className: "flex shrink-0 items-center gap-3 text-[11px] tabular-nums text-slate-500 dark:text-slate-400", children: [
144
+ function we({ stat: t }) {
145
+ const e = t.rows == null ? /* @__PURE__ */ r("span", { "data-tip": "Record count unknown", className: "text-slate-400 dark:text-slate-500", children: "—" }) : t.rows === 0 ? /* @__PURE__ */ r("span", { className: "text-slate-400 dark:text-slate-500", children: "Empty" }) : /* @__PURE__ */ r("span", { "data-tip": "Approximate record count", children: j(t.rows) });
146
+ return /* @__PURE__ */ u("span", { className: "flex shrink-0 items-center gap-3 text-[11px] tabular-nums text-slate-500 dark:text-slate-400", children: [
134
147
  /* @__PURE__ */ r("span", { className: "w-16 text-right", children: e }),
135
- /* @__PURE__ */ r("span", { "data-cdr": "", className: "hidden w-16 whitespace-nowrap text-right md:[&[data-cdr]]:block", children: t.changed_at ? /* @__PURE__ */ r("span", { "data-tip": `Last change ${ae(t.changed_at)}`, children: ve(t.changed_at) }) : /* @__PURE__ */ r(
148
+ /* @__PURE__ */ r("span", { "data-cdr": "", className: "hidden w-16 whitespace-nowrap text-right md:[&[data-cdr]]:block", children: t.changed_at ? /* @__PURE__ */ r("span", { "data-tip": `Last change ${ie(t.changed_at)}`, children: ye(t.changed_at) }) : /* @__PURE__ */ r(
136
149
  "span",
137
150
  {
138
151
  "data-tip": "No change seen since the database last started",
@@ -142,207 +155,209 @@ function be({ stat: t }) {
142
155
  ) })
143
156
  ] });
144
157
  }
145
- const b = "opacity-0 transition-opacity duration-150 group-hover/row:opacity-100 group-focus-within/row:opacity-100 focus-visible:opacity-100 data-[state=open]:opacity-100 motion-reduce:transition-none";
146
- function ye(t) {
158
+ const k = "opacity-0 transition-opacity duration-150 group-hover/row:opacity-100 group-focus-within/row:opacity-100 focus-visible:opacity-100 data-[state=open]:opacity-100 motion-reduce:transition-none";
159
+ function ge(t) {
147
160
  try {
148
161
  return t.matches(":focus-visible");
149
162
  } catch {
150
163
  return !1;
151
164
  }
152
165
  }
153
- function Ee({
166
+ function He({
154
167
  col: t,
155
168
  stat: e,
156
- density: n,
157
- favorite: a,
158
- onToggleFavorite: i,
159
- pinnedForAll: c = !1,
160
- onTogglePinned: s,
161
- onMoveUp: y,
162
- onMoveDown: j,
163
- quietPin: S = !1,
164
- folders: R,
165
- onMove: H,
166
- recordsPath: I,
167
- editPath: k,
168
- menuExtra: M,
169
+ heavyList: n,
170
+ density: a,
171
+ favorite: i,
172
+ onToggleFavorite: m,
173
+ pinnedForAll: o = !1,
174
+ onTogglePinned: h,
175
+ onMoveUp: S,
176
+ onMoveDown: H,
177
+ quietPin: R = !1,
178
+ folders: B,
179
+ onMove: I,
180
+ recordsPath: M,
181
+ editPath: y,
182
+ menuExtra: T,
169
183
  selecting: w,
170
184
  selected: g,
171
185
  onSelect: N,
172
186
  dragHandle: C,
173
- highlight: x,
174
- isAdmin: f,
187
+ highlight: b,
188
+ isAdmin: p,
175
189
  indent: _
176
190
  }) {
177
- const m = t.collection, d = t.display_name ?? te(m), h = n === "compact", [B, v] = A(!1), u = se(f), $ = I ?? de(m), L = he(m, x), K = B || L >= 0, U = pe(t, e), T = (o) => {
178
- o.currentTarget.contains(o.relatedTarget) || v(!1);
179
- }, P = /* @__PURE__ */ r(
191
+ const f = t.collection, c = t.display_name ?? ae(f), x = a === "compact", [K, v] = ne(!1), d = le(p), $ = M ?? me(f), L = ve(f, b), U = K || L >= 0, F = he(t, e, p ? n : void 0), O = (s) => {
192
+ s.currentTarget.contains(s.relatedTarget) || v(!1);
193
+ }, D = /* @__PURE__ */ r(
180
194
  "span",
181
195
  {
182
196
  className: "min-w-0 truncate text-[13px] font-semibold tracking-[-0.003em] text-slate-800 group-hover/row:text-slate-900 dark:text-slate-200 dark:group-hover/row:text-slate-100",
183
- onPointerEnter: u.show,
184
- onPointerLeave: u.hide,
185
- children: d
197
+ onPointerEnter: d.show,
198
+ onPointerLeave: d.hide,
199
+ children: c
186
200
  }
187
201
  );
188
202
  return (
189
203
  // biome-ignore lint/a11y/noStaticElementInteractions: hover/focus only reveal the key; the link, star and menu are the controls
190
- /* @__PURE__ */ p(
204
+ /* @__PURE__ */ u(
191
205
  "div",
192
206
  {
193
- "data-collection": m,
207
+ "data-collection": f,
194
208
  className: l(
195
209
  "group/row relative flex w-full items-center gap-2 transition-colors duration-150 hover:bg-nvr-cyan/[0.04] focus-within:bg-nvr-cyan/[0.04] motion-reduce:transition-none dark:hover:bg-nvr-cyan/[0.06] dark:focus-within:bg-nvr-cyan/[0.06]",
196
210
  g && "bg-nvr-cyan/[0.07] dark:bg-nvr-cyan/[0.1]",
197
- h ? "h-7" : "min-h-10 py-1",
211
+ x ? "h-7" : "min-h-10 py-1",
198
212
  _ ? "pl-2 pr-2" : C ? "pr-2" : "pl-4 pr-2"
199
213
  ),
200
214
  onMouseEnter: () => v(!0),
201
215
  onMouseLeave: () => v(!1),
202
216
  onFocus: () => v(!0),
203
- onBlur: T,
217
+ onBlur: O,
204
218
  children: [
205
219
  C,
206
220
  w && /* @__PURE__ */ r(
207
- oe,
221
+ se,
208
222
  {
209
223
  checked: g,
210
224
  onCheckedChange: () => N(),
211
- onClick: (o) => o.stopPropagation(),
212
- "aria-label": `Select ${d}`,
225
+ onClick: (s) => s.stopPropagation(),
226
+ "aria-label": `Select ${c}`,
213
227
  className: "h-3.5 w-3.5 border-slate-300 data-[state=checked]:border-nvr-cyan data-[state=checked]:bg-nvr-cyan data-[state=checked]:text-white dark:border-slate-600 [&_svg]:h-3 [&_svg]:w-3"
214
228
  }
215
229
  ),
216
- /* @__PURE__ */ p(
217
- D,
230
+ /* @__PURE__ */ u(
231
+ P,
218
232
  {
219
233
  to: $,
220
- onClick: (o) => {
221
- if (u.close(), w) {
222
- o.preventDefault(), N();
234
+ onClick: (s) => {
235
+ if (d.close(), w) {
236
+ s.preventDefault(), N();
223
237
  return;
224
238
  }
225
- le(m);
239
+ ue(f);
226
240
  },
227
- onFocus: (o) => {
228
- ye(o.currentTarget) && u.show();
241
+ onFocus: (s) => {
242
+ ge(s.currentTarget) && d.show();
229
243
  },
230
- onBlur: u.hide,
244
+ onBlur: d.hide,
231
245
  className: l(
232
246
  "flex min-w-0 flex-1 items-center gap-2.5 self-stretch rounded-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-nvr-cyan/50",
233
- h ? "" : "py-0.5"
247
+ x ? "" : "py-0.5"
234
248
  ),
235
249
  children: [
236
250
  /* @__PURE__ */ r(
237
- ue,
251
+ pe,
238
252
  {
239
253
  color: t.color,
240
- name: d,
254
+ name: c,
241
255
  icon: t.icon,
242
- size: h ? "sm" : "md"
256
+ size: x ? "sm" : "md"
243
257
  }
244
258
  ),
245
- /* @__PURE__ */ p("span", { className: "flex min-w-0 flex-1 flex-col justify-center", children: [
246
- /* @__PURE__ */ p("span", { className: "flex min-w-0 items-baseline gap-2", children: [
247
- f ? /* @__PURE__ */ r(
248
- ie,
259
+ /* @__PURE__ */ u("span", { className: "flex min-w-0 flex-1 flex-col justify-center", children: [
260
+ /* @__PURE__ */ u("span", { className: "flex min-w-0 items-baseline gap-2", children: [
261
+ p ? /* @__PURE__ */ r(
262
+ ce,
249
263
  {
250
- collection: m,
251
- title: d,
252
- open: u.open,
253
- onClose: u.close,
254
- onCardEnter: u.cancel,
255
- onCardLeave: u.hide,
256
- children: P
264
+ collection: f,
265
+ title: c,
266
+ heavyList: n,
267
+ open: d.open,
268
+ onClose: d.close,
269
+ onCardEnter: d.cancel,
270
+ onCardLeave: d.hide,
271
+ children: D
257
272
  }
258
- ) : P,
259
- K && /* @__PURE__ */ r(xe, { text: m, at: L, len: (x == null ? void 0 : x.trim().length) ?? 0 }),
260
- h && t.note && /* @__PURE__ */ r("span", { className: "min-w-0 flex-1 truncate text-[12px] text-slate-500 dark:text-slate-400", children: t.note })
273
+ ) : D,
274
+ U && /* @__PURE__ */ r(ke, { text: f, at: L, len: (b == null ? void 0 : b.trim().length) ?? 0 }),
275
+ x && t.note && /* @__PURE__ */ r("span", { className: "min-w-0 flex-1 truncate text-[12px] text-slate-500 dark:text-slate-400", children: t.note })
261
276
  ] }),
262
- !h && t.note && /* @__PURE__ */ r("span", { className: "truncate text-[12px] leading-4 text-slate-500 dark:text-slate-400", children: t.note })
277
+ !x && t.note && /* @__PURE__ */ r("span", { className: "truncate text-[12px] leading-4 text-slate-500 dark:text-slate-400", children: t.note })
263
278
  ] }),
264
- /* @__PURE__ */ r(fe, { items: U }),
265
- e && /* @__PURE__ */ r(be, { stat: e })
279
+ /* @__PURE__ */ r(be, { items: F }),
280
+ e && /* @__PURE__ */ r(we, { stat: e })
266
281
  ]
267
282
  }
268
283
  ),
269
- f && k && /* @__PURE__ */ r(
270
- D,
284
+ p && y && /* @__PURE__ */ r(
285
+ P,
271
286
  {
272
- to: k,
273
- "aria-label": `Edit ${d}`,
287
+ to: y,
288
+ "aria-label": `Edit ${c}`,
274
289
  "data-tip": "Edit fields, forms and settings",
275
290
  "data-collection-edit": !0,
276
291
  "data-cdr": "",
277
- onClick: (o) => o.stopPropagation(),
292
+ onClick: (s) => s.stopPropagation(),
278
293
  className: l(
279
294
  // Phones: the ⋯ menu carries editing; the row keeps its width for the name.
280
295
  "hidden h-6 w-6 shrink-0 items-center justify-center rounded text-slate-400 hover:bg-slate-100 hover:text-slate-600 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-nvr-cyan/50 sm:[&[data-cdr]]:flex dark:text-slate-500 dark:hover:bg-white/10 dark:hover:text-slate-300",
281
- b
296
+ k
282
297
  ),
283
- children: /* @__PURE__ */ r(O, { className: "h-3.5 w-3.5" })
298
+ children: /* @__PURE__ */ r(Y, { className: "h-3.5 w-3.5" })
284
299
  }
285
300
  ),
286
- f && s && /* @__PURE__ */ r(
301
+ p && h && /* @__PURE__ */ r(
287
302
  "button",
288
303
  {
289
304
  type: "button",
290
- "aria-label": c ? `Unpin ${d} for everyone` : `Pin ${d} for everyone`,
291
- "aria-pressed": c,
292
- "data-tip": c ? "Unpin for everyone" : "Pin to the top for everyone",
305
+ "aria-label": o ? `Unpin ${c} for everyone` : `Pin ${c} for everyone`,
306
+ "aria-pressed": o,
307
+ "data-tip": o ? "Unpin for everyone" : "Pin to the top for everyone",
293
308
  "data-collection-pin": !0,
294
309
  "data-cdr": "",
295
- onClick: (o) => {
296
- o.preventDefault(), o.stopPropagation(), s();
310
+ onClick: (s) => {
311
+ s.preventDefault(), s.stopPropagation(), h();
297
312
  },
298
313
  className: l(
299
314
  // Phones: Pin for everyone stays in the ⋯ menu.
300
315
  "hidden sm:[&[data-cdr]]:flex h-6 w-6 shrink-0 items-center justify-center rounded hover:bg-slate-100 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-nvr-cyan/50 dark:hover:bg-white/10",
301
- c && !S ? "text-slate-600 hover:text-slate-800 dark:text-slate-300 dark:hover:text-slate-100" : l(
302
- b,
316
+ o && !R ? "text-slate-600 hover:text-slate-800 dark:text-slate-300 dark:hover:text-slate-100" : l(
317
+ k,
303
318
  "text-slate-400 hover:text-slate-600 dark:text-slate-500 dark:hover:text-slate-300"
304
319
  )
305
320
  ),
306
- children: /* @__PURE__ */ r(V, { className: l("h-3.5 w-3.5", c && "fill-current") })
321
+ children: /* @__PURE__ */ r(q, { className: l("h-3.5 w-3.5", o && "fill-current") })
307
322
  }
308
323
  ),
309
324
  /* @__PURE__ */ r(
310
325
  "button",
311
326
  {
312
327
  type: "button",
313
- "aria-label": a ? `Remove ${d} from my favorites` : `Add ${d} to my favorites`,
314
- "aria-pressed": a,
315
- "data-tip": a ? "Remove from my favorites" : "Add to my favorites",
316
- onClick: (o) => {
317
- o.preventDefault(), o.stopPropagation(), i();
328
+ "aria-label": i ? `Remove ${c} from my favorites` : `Add ${c} to my favorites`,
329
+ "aria-pressed": i,
330
+ "data-tip": i ? "Remove from my favorites" : "Add to my favorites",
331
+ onClick: (s) => {
332
+ s.preventDefault(), s.stopPropagation(), m();
318
333
  },
319
334
  className: l(
320
335
  "flex h-6 w-6 shrink-0 items-center justify-center rounded hover:bg-slate-100 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-nvr-cyan/50 dark:hover:bg-white/10",
321
- a ? "text-nvr-cyan" : l(
322
- b,
336
+ i ? "text-nvr-cyan" : l(
337
+ k,
323
338
  "text-slate-400 hover:text-slate-600 dark:text-slate-500 dark:hover:text-slate-300"
324
339
  )
325
340
  ),
326
- children: /* @__PURE__ */ r(Y, { className: l("h-3.5 w-3.5", a && "fill-current") })
341
+ children: /* @__PURE__ */ r(W, { className: l("h-3.5 w-3.5", i && "fill-current") })
327
342
  }
328
343
  ),
329
344
  /* @__PURE__ */ r(
330
- ce,
345
+ de,
331
346
  {
332
347
  col: t,
333
- displayName: d,
334
- isAdmin: f,
348
+ displayName: c,
349
+ isAdmin: p,
335
350
  recordsPath: $,
336
- extra: f ? M : void 0,
337
- favorite: a,
338
- onToggleFavorite: i,
339
- pinnedForAll: c,
340
- onTogglePinned: s,
341
- onMoveUp: y,
342
- onMoveDown: j,
343
- folders: R,
344
- onMove: H,
345
- className: l(b, "[@media(hover:none)]:[&[data-cdr]]:opacity-100")
351
+ extra: p ? T : void 0,
352
+ favorite: i,
353
+ onToggleFavorite: m,
354
+ pinnedForAll: o,
355
+ onTogglePinned: h,
356
+ onMoveUp: S,
357
+ onMoveDown: H,
358
+ folders: B,
359
+ onMove: I,
360
+ className: l(k, "[@media(hover:none)]:[&[data-cdr]]:opacity-100")
346
361
  }
347
362
  )
348
363
  ]
@@ -351,9 +366,10 @@ function Ee({
351
366
  );
352
367
  }
353
368
  export {
354
- ue as CollectionAvatar,
355
- Ee as CollectionRow,
356
- D as HostLink,
357
- de as defaultCollectionPath,
358
- ve as shortWhen
369
+ pe as CollectionAvatar,
370
+ He as CollectionRow,
371
+ P as HostLink,
372
+ me as defaultCollectionPath,
373
+ fe as heavyListTip,
374
+ ye as shortWhen
359
375
  };