@object-ui/plugin-view 3.4.0 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -4,42 +4,42 @@ import { ComponentRegistry as c, buildExpandFields as l } from "@object-ui/core"
4
4
  import { SchemaRenderer as u, SchemaRendererContext as d } from "@object-ui/react";
5
5
  import { ObjectGrid as f } from "@object-ui/plugin-grid";
6
6
  import { ObjectForm as p } from "@object-ui/plugin-form";
7
- import { Badge as m, Button as h, Checkbox as g, ConfigRow as _, ContextMenu as v, ContextMenuContent as ee, ContextMenuItem as y, ContextMenuSeparator as b, ContextMenuSub as te, ContextMenuSubContent as x, ContextMenuSubTrigger as S, ContextMenuTrigger as C, Dialog as w, DialogContent as T, DialogDescription as E, DialogFooter as ne, DialogHeader as re, DialogTitle as D, Drawer as O, DrawerContent as ie, DrawerDescription as ae, DrawerHeader as oe, DrawerTitle as se, DropdownMenu as k, DropdownMenuContent as A, DropdownMenuItem as j, DropdownMenuSeparator as M, DropdownMenuSub as ce, DropdownMenuSubContent as le, DropdownMenuSubTrigger as ue, DropdownMenuTrigger as de, FilterBuilder as fe, Input as N, Label as pe, NavigationOverlay as me, Popover as P, PopoverContent as he, PopoverTrigger as F, Select as I, SelectContent as L, SelectItem as R, SelectTrigger as z, SelectValue as B, SortBuilder as V, Switch as H, Tabs as ge, TabsList as _e, TabsTrigger as ve, Tooltip as U, TooltipContent as W, TooltipProvider as G, TooltipTrigger as K, cn as q } from "@object-ui/components";
8
- import { Activity as J, ArrowDown as ye, ArrowUp as be, Calendar as xe, Check as Se, ChevronDown as Ce, Copy as we, Eye as Te, EyeOff as Ee, FileText as De, GanttChartSquare as Oe, Globe as ke, Grid as Ae, GripVertical as je, Images as Me, LayoutGrid as Ne, List as Pe, ListOrdered as Fe, Lock as Ie, Map as Le, MoreHorizontal as Re, Pencil as ze, Pin as Y, PinOff as Be, Plus as Ve, Save as He, Search as Ue, Settings as We, Settings2 as Ge, Share2 as Ke, SlidersHorizontal as qe, Star as Je, Table as Ye, Trash2 as Xe, X as Ze, icons as Qe } from "lucide-react";
9
- import { DndContext as $e, KeyboardSensor as et, PointerSensor as tt, closestCenter as nt, useSensor as rt, useSensors as it } from "@dnd-kit/core";
10
- import { SortableContext as at, arrayMove as ot, horizontalListSortingStrategy as st, sortableKeyboardCoordinates as ct, useSortable as lt, verticalListSortingStrategy as ut } from "@dnd-kit/sortable";
11
- import { CSS as dt } from "@dnd-kit/utilities";
7
+ import { Badge as m, Button as h, Checkbox as g, ConfigRow as _, ContextMenu as v, ContextMenuContent as ee, ContextMenuItem as y, ContextMenuSeparator as b, ContextMenuSub as te, ContextMenuSubContent as x, ContextMenuSubTrigger as S, ContextMenuTrigger as C, Dialog as w, DialogContent as T, DialogDescription as E, DialogFooter as D, DialogHeader as ne, DialogTitle as re, Drawer as O, DrawerContent as ie, DrawerDescription as ae, DrawerHeader as oe, DrawerTitle as se, DropdownMenu as k, DropdownMenuContent as A, DropdownMenuItem as j, DropdownMenuSeparator as M, DropdownMenuSub as ce, DropdownMenuSubContent as le, DropdownMenuSubTrigger as ue, DropdownMenuTrigger as de, FilterBuilder as fe, GroupingEditor as N, Input as P, Label as F, NavigationOverlay as pe, Popover as me, PopoverContent as I, PopoverTrigger as he, Select as L, SelectContent as R, SelectItem as z, SelectTrigger as B, SelectValue as V, SortBuilder as ge, Switch as H, Tabs as _e, TabsList as ve, TabsTrigger as ye, Tooltip as U, TooltipContent as W, TooltipProvider as G, TooltipTrigger as K, cn as q } from "@object-ui/components";
8
+ import { Activity as J, ArrowDown as be, ArrowUp as xe, Calendar as Se, Check as Ce, ChevronDown as we, Copy as Te, Eye as Y, EyeOff as Ee, FileText as De, GanttChartSquare as Oe, Globe as ke, Grid as Ae, GripVertical as je, Images as Me, LayoutGrid as Ne, List as Pe, ListOrdered as Fe, Lock as Ie, Map as Le, MoreHorizontal as Re, Pencil as ze, Pin as Be, PinOff as Ve, Plus as He, Save as Ue, Search as We, Settings as Ge, Settings2 as Ke, Share2 as qe, SlidersHorizontal as Je, Star as Ye, Table as Xe, Trash2 as Ze, X as Qe, icons as $e } from "lucide-react";
9
+ import { DndContext as et, KeyboardSensor as tt, PointerSensor as nt, closestCenter as rt, useSensor as it, useSensors as at } from "@dnd-kit/core";
10
+ import { SortableContext as ot, arrayMove as st, horizontalListSortingStrategy as ct, sortableKeyboardCoordinates as lt, useSortable as ut, verticalListSortingStrategy as dt } from "@dnd-kit/sortable";
11
+ import { CSS as ft } from "@dnd-kit/utilities";
12
12
  //#region \0rolldown/runtime.js
13
- var ft = (e, t) => () => (t || (e((t = { exports: {} }).exports, t), e = null), t.exports);
13
+ var pt = (e, t) => () => (t || (e((t = { exports: {} }).exports, t), e = null), t.exports);
14
14
  //#endregion
15
15
  //#region ../../node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
16
- function pt(e) {
16
+ function mt(e) {
17
17
  var t, n, r = "";
18
18
  if (typeof e == "string" || typeof e == "number") r += e;
19
19
  else if (typeof e == "object") if (Array.isArray(e)) {
20
20
  var i = e.length;
21
- for (t = 0; t < i; t++) e[t] && (n = pt(e[t])) && (r && (r += " "), r += n);
21
+ for (t = 0; t < i; t++) e[t] && (n = mt(e[t])) && (r && (r += " "), r += n);
22
22
  } else for (n in e) e[n] && (r && (r += " "), r += n);
23
23
  return r;
24
24
  }
25
- function mt() {
26
- for (var e, t, n = 0, r = "", i = arguments.length; n < i; n++) (e = arguments[n]) && (t = pt(e)) && (r && (r += " "), r += t);
25
+ function ht() {
26
+ for (var e, t, n = 0, r = "", i = arguments.length; n < i; n++) (e = arguments[n]) && (t = mt(e)) && (r && (r += " "), r += t);
27
27
  return r;
28
28
  }
29
29
  //#endregion
30
30
  //#region ../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.mjs
31
- var ht = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, gt = mt, _t = (e, t) => (n) => {
32
- if (t?.variants == null) return gt(e, n?.class, n?.className);
31
+ var gt = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, _t = ht, vt = (e, t) => (n) => {
32
+ if (t?.variants == null) return _t(e, n?.class, n?.className);
33
33
  let { variants: r, defaultVariants: i } = t, a = Object.keys(r).map((e) => {
34
34
  let t = n?.[e], a = i?.[e];
35
35
  if (t === null) return null;
36
- let o = ht(t) || ht(a);
36
+ let o = gt(t) || gt(a);
37
37
  return r[e][o];
38
38
  }), o = n && Object.entries(n).reduce((e, t) => {
39
39
  let [n, r] = t;
40
40
  return r === void 0 || (e[n] = r), e;
41
41
  }, {});
42
- return gt(e, a, t?.compoundVariants?.reduce((e, t) => {
42
+ return _t(e, a, t?.compoundVariants?.reduce((e, t) => {
43
43
  let { class: n, className: r, ...a } = t;
44
44
  return Object.entries(a).every((e) => {
45
45
  let [t, n] = e;
@@ -56,7 +56,7 @@ var ht = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, gt = mt, _t
56
56
  r
57
57
  ] : e;
58
58
  }, []), n?.class, n?.className);
59
- }, vt = /* @__PURE__ */ ft(((e) => {
59
+ }, yt = /* @__PURE__ */ pt(((e) => {
60
60
  var t = Symbol.for("react.transitional.element"), n = Symbol.for("react.fragment");
61
61
  function r(e, n, r) {
62
62
  var i = null;
@@ -71,9 +71,9 @@ var ht = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, gt = mt, _t
71
71
  };
72
72
  }
73
73
  e.Fragment = n, e.jsx = r, e.jsxs = r;
74
- })), X = (/* @__PURE__ */ ft(((e, t) => {
75
- t.exports = vt();
76
- })))(), yt = {
74
+ })), X = (/* @__PURE__ */ pt(((e, t) => {
75
+ t.exports = yt();
76
+ })))(), bt = {
77
77
  list: "List",
78
78
  detail: "Detail",
79
79
  grid: "Grid",
@@ -83,17 +83,17 @@ var ht = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, gt = mt, _t
83
83
  map: "Map",
84
84
  gallery: "Gallery",
85
85
  gantt: "Gantt"
86
- }, bt = {
86
+ }, xt = {
87
87
  list: Pe,
88
88
  detail: De,
89
89
  grid: Ae,
90
90
  kanban: Ne,
91
- calendar: xe,
91
+ calendar: Se,
92
92
  timeline: J,
93
93
  map: Le,
94
94
  gallery: Me,
95
95
  gantt: Oe
96
- }, xt = _t("flex gap-4", {
96
+ }, St = vt("flex gap-4", {
97
97
  variants: { position: {
98
98
  top: "flex-col",
99
99
  bottom: "flex-col-reverse",
@@ -101,55 +101,55 @@ var ht = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, gt = mt, _t
101
101
  right: "flex-row-reverse"
102
102
  } },
103
103
  defaultVariants: { position: "top" }
104
- }), St = _t("w-full", {
104
+ }), Ct = vt("w-full", {
105
105
  variants: { orientation: {
106
106
  horizontal: "w-full",
107
107
  vertical: "w-48"
108
108
  } },
109
109
  defaultVariants: { orientation: "horizontal" }
110
- }), Ct = _t("flex gap-2", {
110
+ }), wt = vt("flex gap-2", {
111
111
  variants: { orientation: {
112
112
  horizontal: "flex-row flex-wrap",
113
113
  vertical: "flex-col"
114
114
  } },
115
115
  defaultVariants: { orientation: "horizontal" }
116
- }), wt = _t("", {
116
+ }), Tt = vt("", {
117
117
  variants: { orientation: {
118
118
  horizontal: "",
119
119
  vertical: "flex h-auto flex-col items-stretch"
120
120
  } },
121
121
  defaultVariants: { orientation: "horizontal" }
122
122
  });
123
- function Tt(e) {
123
+ function Et(e) {
124
124
  return e.split("-").map((e) => e.charAt(0).toUpperCase() + e.slice(1)).join("");
125
125
  }
126
- var Et = { Home: "House" };
127
- function Dt(e) {
128
- if (!e) return null;
129
- let t = Tt(e);
130
- return Qe[Et[t] || t] || null;
131
- }
126
+ var Dt = { Home: "House" };
132
127
  function Ot(e) {
133
- return e.label ? e.label : yt[e.type] || e.type;
128
+ if (!e) return null;
129
+ let t = Et(e);
130
+ return $e[Dt[t] || t] || null;
134
131
  }
135
132
  function kt(e) {
136
- return e.icon ? Dt(e.icon) : bt[e.type] || null;
133
+ return e.label ? e.label : bt[e.type] || e.type;
137
134
  }
138
135
  function At(e) {
136
+ return e.icon ? Ot(e.icon) : xt[e.type] || null;
137
+ }
138
+ function jt(e) {
139
139
  return e.activeView ? e.activeView : e.defaultView ? e.defaultView : e.views?.[0]?.type;
140
140
  }
141
- var jt = {
142
- share: Ke,
143
- settings: We,
144
- duplicate: we,
145
- delete: Xe
146
- }, Mt = {
141
+ var Mt = {
142
+ share: qe,
143
+ settings: Ge,
144
+ duplicate: Te,
145
+ delete: Ze
146
+ }, Nt = {
147
147
  share: "Share",
148
148
  settings: "Settings",
149
149
  duplicate: "Duplicate",
150
150
  delete: "Delete"
151
- }, Nt = ({ schema: t, className: n, onViewChange: r, onCreateView: i, onViewAction: a, createViewLabel: o = "Create view", ...s }) => {
152
- let c = e.useMemo(() => t.storageKey ? t.storageKey : `view-switcher${t.id ? `-${t.id}` : ""}`, [t.id, t.storageKey]), [l, d] = e.useState(() => At(t));
151
+ }, Pt = ({ schema: t, className: n, onViewChange: r, onCreateView: i, onViewAction: a, createViewLabel: o = "Create view", ...s }) => {
152
+ let c = e.useMemo(() => t.storageKey ? t.storageKey : `view-switcher${t.id ? `-${t.id}` : ""}`, [t.id, t.storageKey]), [l, d] = e.useState(() => jt(t));
153
153
  e.useEffect(() => {
154
154
  if (t.activeView) {
155
155
  d(t.activeView);
@@ -184,13 +184,13 @@ var jt = {
184
184
  }, [f]), m = l || t.views?.[0]?.type, g = m || "", _ = t.views.find((e) => e.type === m) || t.views?.[0], v = t.variant || "tabs", ee = t.position || "top", y = ee === "left" || ee === "right", b = y ? "vertical" : "horizontal", te = t.viewActions && t.viewActions.length > 0 ? /* @__PURE__ */ (0, X.jsx)("div", {
185
185
  className: "flex items-center gap-1",
186
186
  children: t.viewActions.map((e, t) => {
187
- let n = e.icon && Dt(e.icon) || jt[e.type];
187
+ let n = e.icon && Ot(e.icon) || Mt[e.type];
188
188
  return /* @__PURE__ */ (0, X.jsx)(h, {
189
189
  type: "button",
190
190
  variant: "ghost",
191
191
  size: "icon",
192
192
  onClick: () => a?.(e.type, m),
193
- title: Mt[e.type] || e.type,
193
+ title: Nt[e.type] || e.type,
194
194
  children: n ? /* @__PURE__ */ (0, X.jsx)(n, { className: "h-3.5 w-3.5" }) : null
195
195
  }, `action-${e.type}-${t}`);
196
196
  })
@@ -200,46 +200,46 @@ var jt = {
200
200
  size: "icon",
201
201
  onClick: () => i?.(),
202
202
  title: o,
203
- children: /* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-3.5 w-3.5" })
203
+ children: /* @__PURE__ */ (0, X.jsx)(He, { className: "h-3.5 w-3.5" })
204
204
  }) : null, S = /* @__PURE__ */ (0, X.jsxs)("div", {
205
- className: q(St({ orientation: b }), "flex items-center gap-1"),
205
+ className: q(Ct({ orientation: b }), "flex items-center gap-1"),
206
206
  children: [
207
- v === "dropdown" && /* @__PURE__ */ (0, X.jsxs)(I, {
207
+ v === "dropdown" && /* @__PURE__ */ (0, X.jsxs)(L, {
208
208
  value: g,
209
209
  onValueChange: (e) => p(e),
210
- children: [/* @__PURE__ */ (0, X.jsx)(z, {
210
+ children: [/* @__PURE__ */ (0, X.jsx)(B, {
211
211
  className: q("w-full", y ? "h-10" : "h-9"),
212
- children: /* @__PURE__ */ (0, X.jsx)(B, { placeholder: "Select view" })
213
- }), /* @__PURE__ */ (0, X.jsx)(L, { children: t.views.map((e, t) => /* @__PURE__ */ (0, X.jsx)(R, {
212
+ children: /* @__PURE__ */ (0, X.jsx)(V, { placeholder: "Select view" })
213
+ }), /* @__PURE__ */ (0, X.jsx)(R, { children: t.views.map((e, t) => /* @__PURE__ */ (0, X.jsx)(z, {
214
214
  value: e.type,
215
- children: Ot(e)
215
+ children: kt(e)
216
216
  }, `${e.type}-${t}`)) })]
217
217
  }),
218
218
  v === "buttons" && /* @__PURE__ */ (0, X.jsx)("div", {
219
- className: q(Ct({ orientation: b })),
219
+ className: q(wt({ orientation: b })),
220
220
  children: t.views.map((e, t) => {
221
- let n = e.type === m, r = kt(e);
221
+ let n = e.type === m, r = At(e);
222
222
  return /* @__PURE__ */ (0, X.jsxs)(h, {
223
223
  type: "button",
224
224
  size: "sm",
225
225
  variant: n ? "secondary" : "ghost",
226
226
  className: q("justify-start gap-2", y ? "w-full" : ""),
227
227
  onClick: () => p(e.type),
228
- children: [r ? /* @__PURE__ */ (0, X.jsx)(r, { className: "h-4 w-4" }) : null, /* @__PURE__ */ (0, X.jsx)("span", { children: Ot(e) })]
228
+ children: [r ? /* @__PURE__ */ (0, X.jsx)(r, { className: "h-4 w-4" }) : null, /* @__PURE__ */ (0, X.jsx)("span", { children: kt(e) })]
229
229
  }, `${e.type}-${t}`);
230
230
  })
231
231
  }),
232
- v === "tabs" && /* @__PURE__ */ (0, X.jsx)(ge, {
232
+ v === "tabs" && /* @__PURE__ */ (0, X.jsx)(_e, {
233
233
  value: g,
234
234
  onValueChange: (e) => p(e),
235
- children: /* @__PURE__ */ (0, X.jsx)(_e, {
236
- className: q(wt({ orientation: b })),
235
+ children: /* @__PURE__ */ (0, X.jsx)(ve, {
236
+ className: q(Tt({ orientation: b })),
237
237
  children: t.views.map((e, t) => {
238
- let n = kt(e);
239
- return /* @__PURE__ */ (0, X.jsxs)(ve, {
238
+ let n = At(e);
239
+ return /* @__PURE__ */ (0, X.jsxs)(ye, {
240
240
  value: e.type,
241
241
  className: q("gap-2", y ? "justify-start" : ""),
242
- children: [n ? /* @__PURE__ */ (0, X.jsx)(n, { className: "h-4 w-4" }) : null, /* @__PURE__ */ (0, X.jsx)("span", { children: Ot(e) })]
242
+ children: [n ? /* @__PURE__ */ (0, X.jsx)(n, { className: "h-4 w-4" }) : null, /* @__PURE__ */ (0, X.jsx)("span", { children: kt(e) })]
243
243
  }, `${e.type}-${t}`);
244
244
  })
245
245
  })
@@ -258,7 +258,7 @@ var jt = {
258
258
  ...s
259
259
  }) : null;
260
260
  return /* @__PURE__ */ (0, X.jsxs)("div", {
261
- className: q(xt({ position: ee }), n),
261
+ className: q(St({ position: ee }), n),
262
262
  children: [/* @__PURE__ */ (0, X.jsx)("div", {
263
263
  className: q("shrink-0", y ? "flex flex-col" : "flex"),
264
264
  children: S
@@ -267,10 +267,10 @@ var jt = {
267
267
  children: C
268
268
  })]
269
269
  });
270
- }, Pt = u, Ft = ({ schema: e, dataSource: t, className: r, views: c, activeViewId: u, onViewChange: d, onRowClick: m, onEdit: g, renderListView: _, toolbarAddon: v, onCreateView: ee, onViewAction: y }) => {
270
+ }, Ft = u, It = ({ schema: e, dataSource: t, className: r, views: c, activeViewId: u, onViewChange: d, onRowClick: m, onEdit: g, renderListView: _, toolbarAddon: v, onCreateView: ee, onViewAction: y }) => {
271
271
  let [b, te] = s(null), x = o(null);
272
272
  x.current = b;
273
- let [S, C] = s(!1), [ne, k] = s("create"), [A, j] = s(null), [M, ce] = s(0);
273
+ let [S, C] = s(!1), [D, k] = s("create"), [A, j] = s(null), [M, ce] = s(0);
274
274
  i(() => {
275
275
  if (!(!t?.onMutation || !e.objectName) && !_) return t.onMutation((t) => {
276
276
  t.resource === e.objectName && ce((e) => e + 1);
@@ -280,15 +280,15 @@ var jt = {
280
280
  e.objectName,
281
281
  _
282
282
  ]);
283
- let [le, ue] = s([]), [de, fe] = s(!1), [N, pe] = s({}), [P, he] = s([]), F = e.listViews, I = F != null && Object.keys(F).length > 0, [L, R] = s(() => e.defaultListView && F?.[e.defaultListView] ? e.defaultListView : F && Object.keys(F)[0] || ""), z = a(() => !I || !L ? null : F[L] || null, [
284
- I,
283
+ let [le, ue] = s([]), [de, fe] = s(!1), [N, P] = s({}), [F, me] = s([]), I = e.listViews, he = I != null && Object.keys(I).length > 0, [L, R] = s(() => e.defaultListView && I?.[e.defaultListView] ? e.defaultListView : I && Object.keys(I)[0] || ""), z = a(() => !he || !L ? null : I[L] || null, [
284
+ he,
285
285
  L,
286
- F
287
- ]), B = a(() => c && c.length > 0 ? c : null, [c]), V = B != null && B.length > 0, H = u || B?.[0]?.id, U = B?.find((e) => e.id === H) || B?.[0], W = a(() => z?.type ? z.type : U?.type ? U.type : e.defaultViewType || "grid", [
286
+ I
287
+ ]), B = a(() => c && c.length > 0 ? c : null, [c]), V = B != null && B.length > 0, ge = u || B?.[0]?.id, H = B?.find((e) => e.id === ge) || B?.[0], U = a(() => z?.type ? z.type : H?.type ? H.type : e.defaultViewType || "grid", [
288
288
  z,
289
- U,
289
+ H,
290
290
  e.defaultViewType
291
- ]), G = e.navigation;
291
+ ]), W = e.navigation;
292
292
  i(() => {
293
293
  let n = !0;
294
294
  return e.objectName && t && (async () => {
@@ -304,10 +304,10 @@ var jt = {
304
304
  }, [e.objectName, t]), i(() => {
305
305
  let n = !0;
306
306
  return (async () => {
307
- if (!_ && W !== "grid" && !(!t || !e.objectName)) {
307
+ if (!_ && U !== "grid" && !(!t || !e.objectName)) {
308
308
  fe(!0);
309
309
  try {
310
- let r = z?.filter || U?.filter || e.table?.defaultFilters || [], i = Object.entries(N).filter(([, e]) => e !== void 0 && e !== "" && e !== null).map(([e, t]) => [
310
+ let r = z?.filter || H?.filter || e.table?.defaultFilters || [], i = Object.entries(N).filter(([, e]) => e !== void 0 && e !== "" && e !== null).map(([e, t]) => [
311
311
  e,
312
312
  "=",
313
313
  t
@@ -317,10 +317,10 @@ var jt = {
317
317
  ...r,
318
318
  ...i
319
319
  ] : i.length === 1 ? i[0] : i.length > 1 ? ["and", ...i] : r;
320
- let o = P.length > 0 ? P.map((e) => ({
320
+ let o = F.length > 0 ? F.map((e) => ({
321
321
  field: e.field,
322
322
  order: e.direction
323
- })) : z?.sort || U?.sort || e.table?.defaultSort || void 0, s = l(x.current?.fields), c = await t.find(e.objectName, {
323
+ })) : z?.sort || H?.sort || e.table?.defaultSort || void 0, s = l(x.current?.fields), c = await t.find(e.objectName, {
324
324
  $filter: a.length > 0 ? a : void 0,
325
325
  $orderby: o,
326
326
  $top: 100,
@@ -339,74 +339,74 @@ var jt = {
339
339
  }, [
340
340
  e.objectName,
341
341
  t,
342
- W,
342
+ U,
343
343
  N,
344
- P,
344
+ F,
345
345
  M,
346
346
  z,
347
- U,
347
+ H,
348
348
  _
349
349
  ]);
350
- let K = e.layout || "drawer", J = e.operations || e.table?.operations || {
350
+ let G = e.layout || "drawer", K = e.operations || e.table?.operations || {
351
351
  create: !0,
352
352
  read: !0,
353
353
  update: !0,
354
354
  delete: !0
355
- }, ye = n(() => {
356
- K === "page" && e.onNavigate ? e.onNavigate("new", "edit") : (k("create"), j(null), C(!0));
357
- }, [K, e]), be = n((t) => {
355
+ }, J = n(() => {
356
+ G === "page" && e.onNavigate ? e.onNavigate("new", "edit") : (k("create"), j(null), C(!0));
357
+ }, [G, e]), be = n((t) => {
358
358
  if (g) {
359
359
  g(t);
360
360
  return;
361
361
  }
362
- if (K === "page" && e.onNavigate) {
362
+ if (G === "page" && e.onNavigate) {
363
363
  let n = t.id || t._id;
364
364
  e.onNavigate(n, "edit");
365
365
  } else k("edit"), j(t), C(!0);
366
366
  }, [
367
- K,
367
+ G,
368
368
  e,
369
369
  g
370
370
  ]), xe = n((t) => {
371
- if (K === "page" && e.onNavigate) {
371
+ if (G === "page" && e.onNavigate) {
372
372
  let n = t.id || t._id;
373
373
  e.onNavigate(n, "view");
374
374
  } else k("view"), j(t), C(!0);
375
- }, [K, e]), Se = n((t) => {
375
+ }, [G, e]), Se = n((t) => {
376
376
  if (m) {
377
377
  m(t);
378
378
  return;
379
379
  }
380
- if (G) {
381
- if (G.mode === "none" || G.preventNavigation) return;
382
- if (G.mode === "new_window" || G.openNewTab) {
380
+ if (W) {
381
+ if (W.mode === "none" || W.preventNavigation) return;
382
+ if (W.mode === "new_window" || W.openNewTab) {
383
383
  let n = t.id || t._id, r = `/${e.objectName}/${encodeURIComponent(String(n))}`;
384
384
  window.open(r, "_blank");
385
385
  return;
386
386
  }
387
- if (G.mode === "drawer") {
387
+ if (W.mode === "drawer") {
388
388
  k("view"), j(t), C(!0);
389
389
  return;
390
390
  }
391
- if (G.mode === "modal") {
391
+ if (W.mode === "modal") {
392
392
  k("view"), j(t), C(!0);
393
393
  return;
394
394
  }
395
- if (G.mode === "page") {
395
+ if (W.mode === "page") {
396
396
  let n = t.id || t._id;
397
397
  e.onNavigate && e.onNavigate(n, "view");
398
398
  return;
399
399
  }
400
- if (G.mode === "split" || G.mode === "popover") {
400
+ if (W.mode === "split" || W.mode === "popover") {
401
401
  k("view"), j(t), C(!0);
402
402
  return;
403
403
  }
404
404
  }
405
- J.read !== !1 && xe(t);
405
+ K.read !== !1 && xe(t);
406
406
  }, [
407
407
  m,
408
- G,
409
- J.read,
408
+ W,
409
+ K.read,
410
410
  xe,
411
411
  e
412
412
  ]), Ce = n((e) => {
@@ -415,20 +415,20 @@ var jt = {
415
415
  ce((e) => e + 1);
416
416
  }, []), Te = n(() => {
417
417
  C(!1), j(null), ce((e) => e + 1);
418
- }, []), Ee = n(() => {
418
+ }, []), Y = n(() => {
419
419
  C(!1), j(null);
420
420
  }, []);
421
421
  n(() => {
422
422
  ce((e) => e + 1);
423
423
  }, []);
424
- let De = a(() => !V || !B || B.length <= 1 ? null : {
424
+ let Ee = a(() => !V || !B || B.length <= 1 ? null : {
425
425
  type: "view-switcher",
426
426
  variant: "tabs",
427
427
  position: "top",
428
428
  persistPreference: !0,
429
429
  storageKey: `view-pref-${e.objectName}`,
430
- defaultView: U?.type || "grid",
431
- activeView: U?.type || "grid",
430
+ defaultView: H?.type || "grid",
431
+ activeView: H?.type || "grid",
432
432
  views: B.map((e) => ({
433
433
  type: e.type,
434
434
  label: e.label,
@@ -449,15 +449,15 @@ var jt = {
449
449
  }, [
450
450
  V,
451
451
  B,
452
- U,
452
+ H,
453
453
  e.objectName,
454
454
  e.allowCreateView,
455
455
  e.viewActions
456
- ]), Oe = n((e) => {
456
+ ]), De = n((e) => {
457
457
  if (!B) return;
458
458
  let t = B.find((t) => t.type === e);
459
459
  t && d && d(t.id);
460
- }, [B, d]), ke = n((e) => {
460
+ }, [B, d]), Oe = n((e) => {
461
461
  R(e);
462
462
  }, []);
463
463
  a(() => {
@@ -498,9 +498,9 @@ var jt = {
498
498
  b,
499
499
  N
500
500
  ]);
501
- let Ae = e.showSort;
501
+ let ke = e.showSort;
502
502
  a(() => {
503
- if (Ae === !1) return null;
503
+ if (ke === !1) return null;
504
504
  let e = b?.fields || {}, t = Object.entries(e).filter(([, e]) => !e.hidden).slice(0, 10).map(([e, t]) => ({
505
505
  field: e,
506
506
  label: t.label || e
@@ -510,25 +510,25 @@ var jt = {
510
510
  variant: "dropdown",
511
511
  multiple: !1,
512
512
  fields: t,
513
- sort: P
513
+ sort: F
514
514
  };
515
515
  }, [
516
516
  b,
517
- P,
518
- Ae
517
+ F,
518
+ ke
519
519
  ]);
520
- let je = n((t) => {
520
+ let Ae = n((t) => {
521
521
  let n = {
522
522
  objectName: e.objectName,
523
- fields: z?.columns || U?.columns || e.table?.fields,
523
+ fields: z?.columns || H?.columns || e.table?.fields,
524
524
  className: "h-full w-full",
525
- showSearch: U?.showSearch ?? e.showSearch ?? !1,
526
- showSort: U?.showSort ?? e.showSort ?? !1,
527
- showFilters: U?.showFilters ?? e.showFilters ?? !1,
528
- striped: U?.striped ?? !1,
529
- bordered: U?.bordered ?? !1,
530
- color: U?.color
531
- }, r = z?.options || U || {};
525
+ showSearch: H?.showSearch ?? e.showSearch ?? !1,
526
+ showSort: H?.showSort ?? e.showSort ?? !1,
527
+ showFilters: H?.showFilters ?? e.showFilters ?? !1,
528
+ striped: H?.striped ?? !1,
529
+ bordered: H?.bordered ?? !1,
530
+ color: H?.color
531
+ }, r = z?.options || H || {};
532
532
  switch (t) {
533
533
  case "kanban": return {
534
534
  type: "object-kanban",
@@ -583,36 +583,36 @@ var jt = {
583
583
  e.objectName,
584
584
  e.table?.fields,
585
585
  z,
586
- U
587
- ]), Me = a(() => ({
586
+ H
587
+ ]), je = a(() => ({
588
588
  type: "object-grid",
589
589
  objectName: e.objectName,
590
590
  title: e.table?.title,
591
591
  description: e.table?.description,
592
- fields: z?.columns || U?.columns || e.table?.fields,
593
- columns: z?.columns || U?.columns || e.table?.columns,
592
+ fields: z?.columns || H?.columns || e.table?.fields,
593
+ columns: z?.columns || H?.columns || e.table?.columns,
594
594
  operations: {
595
- ...J,
595
+ ...K,
596
596
  create: !1
597
597
  },
598
- defaultFilters: z?.filter || U?.filter || e.table?.defaultFilters,
599
- defaultSort: z?.sort || U?.sort || e.table?.defaultSort,
598
+ defaultFilters: z?.filter || H?.filter || e.table?.defaultFilters,
599
+ defaultSort: z?.sort || H?.sort || e.table?.defaultSort,
600
600
  pageSize: e.table?.pageSize,
601
601
  selectable: e.table?.selectable,
602
- striped: U?.striped ?? e.table?.striped,
603
- bordered: U?.bordered ?? e.table?.bordered,
602
+ striped: H?.striped ?? e.table?.striped,
603
+ bordered: H?.bordered ?? e.table?.bordered,
604
604
  className: e.table?.className
605
605
  }), [
606
606
  e,
607
- J,
607
+ K,
608
608
  z,
609
- U
610
- ]), Ne = () => {
609
+ H
610
+ ]), Me = () => {
611
611
  let t = A ? A.id || A._id : void 0;
612
612
  return {
613
613
  type: "object-form",
614
614
  objectName: e.objectName,
615
- mode: ne,
615
+ mode: D,
616
616
  recordId: t,
617
617
  title: e.form?.title,
618
618
  description: e.form?.description,
@@ -627,114 +627,116 @@ var jt = {
627
627
  cancelText: e.form?.cancelText,
628
628
  showReset: e.form?.showReset,
629
629
  initialValues: e.form?.initialValues,
630
- readOnly: e.form?.readOnly || ne === "view",
630
+ readOnly: e.form?.readOnly || D === "view",
631
631
  className: e.form?.className,
632
632
  onSuccess: Te,
633
- onCancel: Ee
633
+ onCancel: Y
634
634
  };
635
- }, Pe = () => {
635
+ }, Ne = () => {
636
636
  if (e.form?.title) return e.form.title;
637
637
  let t = b?.label || e.objectName;
638
- switch (ne) {
638
+ switch (D) {
639
639
  case "create": return `Create ${t}`;
640
640
  case "edit": return `Edit ${t}`;
641
641
  case "view": return `View ${t}`;
642
642
  default: return t;
643
643
  }
644
- }, Fe = a(() => {
645
- let e = G?.width;
644
+ }, Pe = a(() => {
645
+ let e = W?.width;
646
646
  return e ? typeof e == "number" ? `max-w-[${e}px]` : `max-w-[${e}]` : "";
647
- }, [G]), Ie = () => /* @__PURE__ */ (0, X.jsx)(O, {
647
+ }, [W]), Fe = () => /* @__PURE__ */ (0, X.jsx)(O, {
648
648
  open: S,
649
649
  onOpenChange: C,
650
650
  direction: "right",
651
651
  children: /* @__PURE__ */ (0, X.jsxs)(ie, {
652
- className: q("w-full sm:max-w-2xl", Fe),
653
- children: [/* @__PURE__ */ (0, X.jsxs)(oe, { children: [/* @__PURE__ */ (0, X.jsx)(se, { children: Pe() }), e.form?.description && /* @__PURE__ */ (0, X.jsx)(ae, { children: e.form.description })] }), /* @__PURE__ */ (0, X.jsx)("div", {
652
+ className: q("w-full sm:max-w-2xl", Pe),
653
+ children: [/* @__PURE__ */ (0, X.jsxs)(oe, { children: [/* @__PURE__ */ (0, X.jsx)(se, { children: Ne() }), e.form?.description && /* @__PURE__ */ (0, X.jsx)(ae, { children: e.form.description })] }), /* @__PURE__ */ (0, X.jsx)("div", {
654
654
  className: "flex-1 overflow-y-auto px-4 pb-4",
655
655
  children: /* @__PURE__ */ (0, X.jsx)(p, {
656
- schema: Ne(),
656
+ schema: Me(),
657
657
  dataSource: t
658
658
  })
659
659
  })]
660
660
  })
661
- }), Le = () => /* @__PURE__ */ (0, X.jsx)(w, {
661
+ }), Ie = () => /* @__PURE__ */ (0, X.jsx)(w, {
662
662
  open: S,
663
663
  onOpenChange: C,
664
664
  children: /* @__PURE__ */ (0, X.jsxs)(T, {
665
- className: q("max-w-2xl max-h-[90vh] overflow-y-auto", Fe),
666
- children: [/* @__PURE__ */ (0, X.jsxs)(re, { children: [/* @__PURE__ */ (0, X.jsx)(D, { children: Pe() }), e.form?.description && /* @__PURE__ */ (0, X.jsx)(E, { children: e.form.description })] }), /* @__PURE__ */ (0, X.jsx)(p, {
667
- schema: Ne(),
665
+ className: q("max-w-2xl max-h-[90vh] overflow-y-auto", Pe),
666
+ children: [/* @__PURE__ */ (0, X.jsxs)(ne, { children: [/* @__PURE__ */ (0, X.jsx)(re, { children: Ne() }), e.form?.description && /* @__PURE__ */ (0, X.jsx)(E, { children: e.form.description })] }), /* @__PURE__ */ (0, X.jsx)(p, {
667
+ schema: Me(),
668
668
  dataSource: t
669
669
  })]
670
670
  })
671
- }), Re = a(() => Object.keys(N).some((e) => N[e] !== void 0 && N[e] !== "" && N[e] !== null) ? Object.entries(N).filter(([, e]) => e !== void 0 && e !== "" && e !== null).map(([e, t]) => ({
671
+ }), Le = a(() => Object.keys(N).some((e) => N[e] !== void 0 && N[e] !== "" && N[e] !== null) ? Object.entries(N).filter(([, e]) => e !== void 0 && e !== "" && e !== null).map(([e, t]) => ({
672
672
  field: e,
673
673
  operator: "equals",
674
674
  value: t
675
- })) : z?.filter || U?.filter || e.table?.defaultFilters, [
675
+ })) : z?.filter || H?.filter || e.table?.defaultFilters, [
676
676
  N,
677
677
  z,
678
- U,
678
+ H,
679
679
  e.table?.defaultFilters
680
- ]), ze = a(() => P.length > 0 ? P : z?.sort || U?.sort || e.table?.defaultSort, [
681
- P,
680
+ ]), Re = a(() => F.length > 0 ? F : z?.sort || H?.sort || e.table?.defaultSort, [
681
+ F,
682
682
  z,
683
- U,
683
+ H,
684
684
  e.table?.defaultSort
685
- ]), Y = () => {
686
- let n = `${e.objectName}-${L || U?.id || "default"}-${W}-${M}`;
685
+ ]), ze = () => {
686
+ let n = `${e.objectName}-${L || H?.id || "default"}-${U}-${M}`;
687
687
  if (_) return _({
688
688
  schema: {
689
689
  type: "list-view",
690
690
  objectName: e.objectName,
691
- viewType: W,
692
- fields: z?.columns || U?.columns || e.table?.fields,
693
- filters: Re,
694
- sort: ze,
695
- rowHeight: U?.rowHeight,
696
- densityMode: U?.densityMode,
697
- groupBy: U?.groupBy,
698
- options: z?.options || U,
699
- showSearch: U?.showSearch ?? e.showSearch,
700
- showFilters: U?.showFilters ?? e.showFilters,
701
- showSort: U?.showSort ?? e.showSort,
702
- showHideFields: U?.showHideFields ?? e.showHideFields,
703
- showGroup: U?.showGroup ?? e.showGroup,
704
- showColor: U?.showColor ?? e.showColor,
705
- showDensity: U?.showDensity ?? e.showDensity,
706
- allowExport: U?.allowExport ?? e.allowExport,
707
- striped: U?.striped ?? e.striped,
708
- bordered: U?.bordered ?? e.bordered,
709
- color: U?.color ?? e.color,
710
- inlineEdit: U?.inlineEdit ?? e.inlineEdit,
711
- wrapHeaders: U?.wrapHeaders ?? e.wrapHeaders,
712
- clickIntoRecordDetails: U?.clickIntoRecordDetails ?? e.clickIntoRecordDetails,
713
- addRecordViaForm: U?.addRecordViaForm ?? e.addRecordViaForm,
714
- addDeleteRecordsInline: U?.addDeleteRecordsInline ?? e.addDeleteRecordsInline,
715
- collapseAllByDefault: U?.collapseAllByDefault ?? e.collapseAllByDefault,
716
- fieldTextColor: U?.fieldTextColor ?? e.fieldTextColor,
717
- prefixField: U?.prefixField ?? e.prefixField,
718
- showDescription: U?.showDescription ?? e.showDescription,
719
- navigation: U?.navigation ?? e.navigation,
720
- selection: U?.selection ?? e.selection,
721
- pagination: U?.pagination ?? e.pagination,
722
- searchableFields: U?.searchableFields ?? e.searchableFields,
723
- filterableFields: U?.filterableFields ?? e.filterableFields,
724
- resizable: U?.resizable ?? e.resizable,
725
- hiddenFields: U?.hiddenFields ?? e.hiddenFields,
726
- rowActions: U?.rowActions ?? e.rowActions,
727
- bulkActions: U?.bulkActions ?? e.bulkActions,
728
- sharing: U?.sharing ?? e.sharing,
729
- addRecord: U?.addRecord ?? e.addRecord,
730
- conditionalFormatting: U?.conditionalFormatting ?? e.conditionalFormatting,
731
- quickFilters: U?.quickFilters ?? e.quickFilters,
732
- userFilters: U?.userFilters ?? e.userFilters,
733
- showRecordCount: U?.showRecordCount ?? e.showRecordCount,
734
- allowPrinting: U?.allowPrinting ?? e.allowPrinting,
735
- virtualScroll: U?.virtualScroll ?? e.virtualScroll,
736
- emptyState: U?.emptyState ?? e.emptyState,
737
- aria: U?.aria ?? e.aria,
691
+ viewType: U,
692
+ fields: z?.columns || H?.columns || e.table?.fields,
693
+ filters: Le,
694
+ sort: Re,
695
+ rowHeight: H?.rowHeight,
696
+ densityMode: H?.densityMode,
697
+ groupBy: H?.groupBy,
698
+ groupBy2: H?.groupBy2,
699
+ grouping: H?.grouping,
700
+ options: z?.options || H,
701
+ showSearch: H?.showSearch ?? e.showSearch,
702
+ showFilters: H?.showFilters ?? e.showFilters,
703
+ showSort: H?.showSort ?? e.showSort,
704
+ showHideFields: H?.showHideFields ?? e.showHideFields,
705
+ showGroup: H?.showGroup ?? e.showGroup,
706
+ showColor: H?.showColor ?? e.showColor,
707
+ showDensity: H?.showDensity ?? e.showDensity,
708
+ allowExport: H?.allowExport ?? e.allowExport,
709
+ striped: H?.striped ?? e.striped,
710
+ bordered: H?.bordered ?? e.bordered,
711
+ color: H?.color ?? e.color,
712
+ inlineEdit: H?.inlineEdit ?? e.inlineEdit,
713
+ wrapHeaders: H?.wrapHeaders ?? e.wrapHeaders,
714
+ clickIntoRecordDetails: H?.clickIntoRecordDetails ?? e.clickIntoRecordDetails,
715
+ addRecordViaForm: H?.addRecordViaForm ?? e.addRecordViaForm,
716
+ addDeleteRecordsInline: H?.addDeleteRecordsInline ?? e.addDeleteRecordsInline,
717
+ collapseAllByDefault: H?.collapseAllByDefault ?? e.collapseAllByDefault,
718
+ fieldTextColor: H?.fieldTextColor ?? e.fieldTextColor,
719
+ prefixField: H?.prefixField ?? e.prefixField,
720
+ showDescription: H?.showDescription ?? e.showDescription,
721
+ navigation: H?.navigation ?? e.navigation,
722
+ selection: H?.selection ?? e.selection,
723
+ pagination: H?.pagination ?? e.pagination,
724
+ searchableFields: H?.searchableFields ?? e.searchableFields,
725
+ filterableFields: H?.filterableFields ?? e.filterableFields,
726
+ resizable: H?.resizable ?? e.resizable,
727
+ hiddenFields: H?.hiddenFields ?? e.hiddenFields,
728
+ rowActions: H?.rowActions ?? e.rowActions,
729
+ bulkActions: H?.bulkActions ?? e.bulkActions,
730
+ sharing: H?.sharing ?? e.sharing,
731
+ addRecord: H?.addRecord ?? e.addRecord,
732
+ conditionalFormatting: H?.conditionalFormatting ?? e.conditionalFormatting,
733
+ quickFilters: H?.quickFilters ?? e.quickFilters,
734
+ userFilters: H?.userFilters ?? e.userFilters,
735
+ showRecordCount: H?.showRecordCount ?? e.showRecordCount,
736
+ allowPrinting: H?.allowPrinting ?? e.allowPrinting,
737
+ virtualScroll: H?.virtualScroll ?? e.virtualScroll,
738
+ emptyState: H?.emptyState ?? e.emptyState,
739
+ aria: H?.aria ?? e.aria,
738
740
  tabs: e.tabs,
739
741
  refreshTrigger: M
740
742
  },
@@ -744,58 +746,58 @@ var jt = {
744
746
  className: "h-full",
745
747
  refreshKey: M
746
748
  });
747
- if (W !== "grid") {
748
- let e = je(W);
749
- if (e && Pt) return /* @__PURE__ */ (0, X.jsx)(Pt, {
749
+ if (U !== "grid") {
750
+ let e = Ae(U);
751
+ if (e && Ft) return /* @__PURE__ */ (0, X.jsx)(Ft, {
750
752
  schema: e,
751
753
  dataSource: t,
752
754
  data: le,
753
755
  loading: de
754
756
  }, n);
755
- if (!Pt) return /* @__PURE__ */ (0, X.jsx)("div", {
757
+ if (!Ft) return /* @__PURE__ */ (0, X.jsx)("div", {
756
758
  className: "flex items-center justify-center h-40 text-muted-foreground",
757
759
  children: /* @__PURE__ */ (0, X.jsxs)("p", { children: [
758
760
  "SchemaRenderer not available. Install @object-ui/react to render ",
759
- W,
761
+ U,
760
762
  " views."
761
763
  ] })
762
764
  });
763
765
  }
764
766
  return /* @__PURE__ */ (0, X.jsx)(f, {
765
- schema: Me,
767
+ schema: je,
766
768
  dataSource: t,
767
769
  onRowClick: Se,
768
- onEdit: J.update === !1 ? void 0 : be,
769
- onDelete: J.delete === !1 ? void 0 : Ce,
770
- onBulkDelete: J.delete === !1 ? void 0 : we
770
+ onEdit: K.update === !1 ? void 0 : be,
771
+ onDelete: K.delete === !1 ? void 0 : Ce,
772
+ onBulkDelete: K.delete === !1 ? void 0 : we
771
773
  }, n);
772
774
  }, Be = () => {
773
- if (!I) return null;
774
- let e = Object.entries(F);
775
- return e.length <= 1 ? null : /* @__PURE__ */ (0, X.jsx)(ge, {
775
+ if (!he) return null;
776
+ let e = Object.entries(I);
777
+ return e.length <= 1 ? null : /* @__PURE__ */ (0, X.jsx)(_e, {
776
778
  value: L,
777
- onValueChange: ke,
779
+ onValueChange: Oe,
778
780
  className: "w-full",
779
- children: /* @__PURE__ */ (0, X.jsx)(_e, {
781
+ children: /* @__PURE__ */ (0, X.jsx)(ve, {
780
782
  className: "w-auto",
781
- children: e.map(([e, t]) => /* @__PURE__ */ (0, X.jsx)(ve, {
783
+ children: e.map(([e, t]) => /* @__PURE__ */ (0, X.jsx)(ye, {
782
784
  value: e,
783
785
  className: "text-sm",
784
786
  children: t.label || e
785
787
  }, e))
786
788
  })
787
789
  });
788
- }, He = () => {
789
- let t = e.showCreate !== !1 && J.create !== !1, n = e.showViewSwitcher === !0, r = Be();
790
+ }, Ve = () => {
791
+ let t = e.showCreate !== !1 && K.create !== !1, n = e.showViewSwitcher === !0, r = Be();
790
792
  return !r && !n && !t && !v ? null : /* @__PURE__ */ (0, X.jsxs)("div", {
791
793
  className: "flex flex-col gap-3",
792
794
  children: [r, (n || t || v) && /* @__PURE__ */ (0, X.jsxs)("div", {
793
795
  className: "flex items-center justify-between gap-4",
794
796
  children: [/* @__PURE__ */ (0, X.jsx)("div", {
795
797
  className: "flex items-center gap-2",
796
- children: n && De && /* @__PURE__ */ (0, X.jsx)(Nt, {
797
- schema: De,
798
- onViewChange: Oe,
798
+ children: n && Ee && /* @__PURE__ */ (0, X.jsx)(Pt, {
799
+ schema: Ee,
800
+ onViewChange: De,
799
801
  onCreateView: ee,
800
802
  onViewAction: y,
801
803
  className: "overflow-x-auto"
@@ -804,21 +806,21 @@ var jt = {
804
806
  className: "flex items-center gap-2",
805
807
  children: [v, t && /* @__PURE__ */ (0, X.jsxs)(h, {
806
808
  size: "sm",
807
- onClick: ye,
808
- children: [/* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-4 w-4" }), "Create"]
809
+ onClick: J,
810
+ children: [/* @__PURE__ */ (0, X.jsx)(He, { className: "h-4 w-4" }), "Create"]
809
811
  })]
810
812
  })]
811
813
  })]
812
814
  });
813
- }, Ue = G?.mode === "modal" ? "modal" : G?.mode === "drawer" ? "drawer" : G?.mode === "split" ? "split" : G?.mode === "popover" ? "popover" : K, We = (e) => /* @__PURE__ */ (0, X.jsx)("div", {
815
+ }, Ue = W?.mode === "modal" ? "modal" : W?.mode === "drawer" ? "drawer" : W?.mode === "split" ? "split" : W?.mode === "popover" ? "popover" : G, We = (e) => /* @__PURE__ */ (0, X.jsx)("div", {
814
816
  className: "space-y-3",
815
817
  children: /* @__PURE__ */ (0, X.jsx)(p, {
816
- schema: Ne(),
818
+ schema: Me(),
817
819
  dataSource: t
818
820
  })
819
821
  }), Ge = n((e) => {
820
- e || Ee();
821
- }, [Ee]);
822
+ e || Y();
823
+ }, [Y]);
822
824
  if (Ue === "split") {
823
825
  let t = b?.label || e.objectName;
824
826
  return /* @__PURE__ */ (0, X.jsxs)("div", {
@@ -836,25 +838,25 @@ var jt = {
836
838
  }),
837
839
  /* @__PURE__ */ (0, X.jsx)("div", {
838
840
  className: "mb-4 shrink-0",
839
- children: He()
841
+ children: Ve()
840
842
  }),
841
843
  /* @__PURE__ */ (0, X.jsx)("div", {
842
844
  className: "flex-1 min-h-0 min-w-0 overflow-hidden",
843
- children: S && A ? /* @__PURE__ */ (0, X.jsx)(me, {
845
+ children: S && A ? /* @__PURE__ */ (0, X.jsx)(pe, {
844
846
  isOpen: S,
845
847
  selectedRecord: A,
846
848
  mode: "split",
847
- close: Ee,
849
+ close: Y,
848
850
  setIsOpen: Ge,
849
- width: G?.width,
851
+ width: W?.width,
850
852
  isOverlay: !0,
851
853
  title: `${t} Detail`,
852
854
  mainContent: /* @__PURE__ */ (0, X.jsx)("div", {
853
855
  className: "h-full overflow-auto",
854
- children: Y()
856
+ children: ze()
855
857
  }),
856
858
  children: We
857
- }) : Y()
859
+ }) : ze()
858
860
  })
859
861
  ]
860
862
  });
@@ -874,35 +876,35 @@ var jt = {
874
876
  }),
875
877
  /* @__PURE__ */ (0, X.jsx)("div", {
876
878
  className: "mb-4 shrink-0",
877
- children: He()
879
+ children: Ve()
878
880
  }),
879
881
  /* @__PURE__ */ (0, X.jsx)("div", {
880
882
  className: "flex-1 min-h-0 min-w-0 overflow-hidden",
881
- children: Y()
883
+ children: ze()
882
884
  }),
883
- Ue === "drawer" && Ie(),
884
- Ue === "modal" && Le(),
885
- Ue === "popover" && S && A && /* @__PURE__ */ (0, X.jsx)(me, {
885
+ Ue === "drawer" && Fe(),
886
+ Ue === "modal" && Ie(),
887
+ Ue === "popover" && S && A && /* @__PURE__ */ (0, X.jsx)(pe, {
886
888
  isOpen: S,
887
889
  selectedRecord: A,
888
890
  mode: "popover",
889
- close: Ee,
891
+ close: Y,
890
892
  setIsOpen: Ge,
891
- width: G?.width,
893
+ width: W?.width,
892
894
  isOverlay: !0,
893
- title: Pe(),
895
+ title: Ne(),
894
896
  children: We
895
897
  })
896
898
  ]
897
899
  });
898
- }, It = _t("flex", {
900
+ }, Lt = vt("flex", {
899
901
  variants: { layout: {
900
902
  inline: "flex-col space-y-4",
901
903
  popover: "items-center",
902
904
  drawer: "items-center"
903
905
  } },
904
906
  defaultVariants: { layout: "inline" }
905
- }), Lt = (e) => e == null || e === "" ? !0 : Array.isArray(e) ? e.length === 0 : typeof e == "object" ? Object.values(e).every((e) => e == null || e === "") : !1, Rt = (e) => Array.isArray(e) ? {
907
+ }), Rt = (e) => e == null || e === "" ? !0 : Array.isArray(e) ? e.length === 0 : typeof e == "object" ? Object.values(e).every((e) => e == null || e === "") : !1, zt = (e) => Array.isArray(e) ? {
906
908
  start: e[0] || "",
907
909
  end: e[1] || ""
908
910
  } : e && typeof e == "object" ? {
@@ -911,7 +913,7 @@ var jt = {
911
913
  } : {
912
914
  start: "",
913
915
  end: ""
914
- }, zt = ({ schema: t, className: n, onChange: r }) => {
916
+ }, Bt = ({ schema: t, className: n, onChange: r }) => {
915
917
  let [i, a] = e.useState(t.values || {}), [o, s] = e.useState(!1);
916
918
  e.useEffect(() => {
917
919
  t.values && a(t.values);
@@ -937,10 +939,10 @@ var jt = {
937
939
  c(e);
938
940
  }, [c, t.showApply]), d = e.useCallback(() => {
939
941
  c(i), s(!1);
940
- }, [c, i]), f = e.useMemo(() => Object.values(i).filter((e) => !Lt(e)).length, [i]), p = (e) => {
942
+ }, [c, i]), f = e.useMemo(() => Object.values(i).filter((e) => !Rt(e)).length, [i]), p = (e) => {
941
943
  let t = e.label || e.field, n = e.placeholder || `Filter by ${t}`;
942
944
  switch (e.type) {
943
- case "number": return /* @__PURE__ */ (0, X.jsx)(N, {
945
+ case "number": return /* @__PURE__ */ (0, X.jsx)(P, {
944
946
  type: "number",
945
947
  value: i[e.field] ?? "",
946
948
  placeholder: n,
@@ -949,13 +951,13 @@ var jt = {
949
951
  l(e.field, r);
950
952
  }
951
953
  });
952
- case "select": return /* @__PURE__ */ (0, X.jsxs)(I, {
954
+ case "select": return /* @__PURE__ */ (0, X.jsxs)(L, {
953
955
  value: i[e.field] === void 0 ? "" : String(i[e.field]),
954
956
  onValueChange: (t) => {
955
957
  let n = e.options?.find((e) => String(e.value) === t);
956
958
  l(e.field, n ? n.value : t);
957
959
  },
958
- children: [/* @__PURE__ */ (0, X.jsx)(z, { children: /* @__PURE__ */ (0, X.jsx)(B, { placeholder: n }) }), /* @__PURE__ */ (0, X.jsx)(L, { children: e.options?.map((e) => /* @__PURE__ */ (0, X.jsx)(R, {
960
+ children: [/* @__PURE__ */ (0, X.jsx)(B, { children: /* @__PURE__ */ (0, X.jsx)(V, { placeholder: n }) }), /* @__PURE__ */ (0, X.jsx)(R, { children: e.options?.map((e) => /* @__PURE__ */ (0, X.jsx)(z, {
959
961
  value: String(e.value),
960
962
  children: e.label
961
963
  }, String(e.value))) })]
@@ -982,16 +984,16 @@ var jt = {
982
984
  })
983
985
  });
984
986
  }
985
- case "date": return /* @__PURE__ */ (0, X.jsx)(N, {
987
+ case "date": return /* @__PURE__ */ (0, X.jsx)(P, {
986
988
  type: "date",
987
989
  value: i[e.field] ?? "",
988
990
  onChange: (t) => l(e.field, t.target.value)
989
991
  });
990
992
  case "date-range": {
991
- let t = Rt(i[e.field]);
993
+ let t = zt(i[e.field]);
992
994
  return /* @__PURE__ */ (0, X.jsxs)("div", {
993
995
  className: "flex items-center gap-2",
994
- children: [/* @__PURE__ */ (0, X.jsx)(N, {
996
+ children: [/* @__PURE__ */ (0, X.jsx)(P, {
995
997
  type: "date",
996
998
  value: t.start ?? "",
997
999
  onChange: (n) => {
@@ -1000,7 +1002,7 @@ var jt = {
1000
1002
  start: n.target.value
1001
1003
  });
1002
1004
  }
1003
- }), /* @__PURE__ */ (0, X.jsx)(N, {
1005
+ }), /* @__PURE__ */ (0, X.jsx)(P, {
1004
1006
  type: "date",
1005
1007
  value: t.end ?? "",
1006
1008
  onChange: (n) => {
@@ -1022,7 +1024,7 @@ var jt = {
1022
1024
  children: "Enabled"
1023
1025
  })]
1024
1026
  });
1025
- default: return /* @__PURE__ */ (0, X.jsx)(N, {
1027
+ default: return /* @__PURE__ */ (0, X.jsx)(P, {
1026
1028
  value: i[e.field] ?? "",
1027
1029
  placeholder: n,
1028
1030
  onChange: (t) => l(e.field, t.target.value)
@@ -1034,7 +1036,7 @@ var jt = {
1034
1036
  className: "grid gap-4 sm:grid-cols-2",
1035
1037
  children: t.filters.map((e) => /* @__PURE__ */ (0, X.jsxs)("div", {
1036
1038
  className: "space-y-2",
1037
- children: [/* @__PURE__ */ (0, X.jsx)(pe, {
1039
+ children: [/* @__PURE__ */ (0, X.jsx)(F, {
1038
1040
  className: "text-xs text-muted-foreground",
1039
1041
  children: e.label || e.field
1040
1042
  }), p(e)]
@@ -1056,11 +1058,11 @@ var jt = {
1056
1058
  })]
1057
1059
  }), _ = t.layout || "inline";
1058
1060
  return _ === "popover" ? /* @__PURE__ */ (0, X.jsx)("div", {
1059
- className: q(It({ layout: _ }), n),
1060
- children: /* @__PURE__ */ (0, X.jsxs)(P, {
1061
+ className: q(Lt({ layout: _ }), n),
1062
+ children: /* @__PURE__ */ (0, X.jsxs)(me, {
1061
1063
  open: o,
1062
1064
  onOpenChange: s,
1063
- children: [/* @__PURE__ */ (0, X.jsx)(F, {
1065
+ children: [/* @__PURE__ */ (0, X.jsx)(he, {
1064
1066
  asChild: !0,
1065
1067
  children: /* @__PURE__ */ (0, X.jsxs)(h, {
1066
1068
  type: "button",
@@ -1068,7 +1070,7 @@ var jt = {
1068
1070
  size: "sm",
1069
1071
  className: "gap-2",
1070
1072
  children: [
1071
- /* @__PURE__ */ (0, X.jsx)(qe, { className: "h-4 w-4" }),
1073
+ /* @__PURE__ */ (0, X.jsx)(Je, { className: "h-4 w-4" }),
1072
1074
  "Filters",
1073
1075
  f > 0 && /* @__PURE__ */ (0, X.jsx)("span", {
1074
1076
  className: "inline-flex h-5 min-w-[20px] items-center justify-center rounded-full bg-primary/10 px-1 text-xs font-medium text-primary",
@@ -1076,14 +1078,14 @@ var jt = {
1076
1078
  })
1077
1079
  ]
1078
1080
  })
1079
- }), /* @__PURE__ */ (0, X.jsx)(he, {
1081
+ }), /* @__PURE__ */ (0, X.jsx)(I, {
1080
1082
  align: "start",
1081
1083
  className: "w-[520px] p-4",
1082
1084
  children: m
1083
1085
  })]
1084
1086
  })
1085
1087
  }) : _ === "drawer" ? /* @__PURE__ */ (0, X.jsxs)("div", {
1086
- className: q(It({ layout: _ }), n),
1088
+ className: q(Lt({ layout: _ }), n),
1087
1089
  children: [/* @__PURE__ */ (0, X.jsxs)(h, {
1088
1090
  type: "button",
1089
1091
  variant: f > 0 ? "secondary" : "outline",
@@ -1091,7 +1093,7 @@ var jt = {
1091
1093
  className: "gap-2",
1092
1094
  onClick: () => s(!0),
1093
1095
  children: [
1094
- /* @__PURE__ */ (0, X.jsx)(qe, { className: "h-4 w-4" }),
1096
+ /* @__PURE__ */ (0, X.jsx)(Je, { className: "h-4 w-4" }),
1095
1097
  "Filters",
1096
1098
  f > 0 && /* @__PURE__ */ (0, X.jsx)("span", {
1097
1099
  className: "inline-flex h-5 min-w-[20px] items-center justify-center rounded-full bg-primary/10 px-1 text-xs font-medium text-primary",
@@ -1107,38 +1109,38 @@ var jt = {
1107
1109
  })] })
1108
1110
  })]
1109
1111
  }) : /* @__PURE__ */ (0, X.jsxs)("div", {
1110
- className: q(It({ layout: _ }), n),
1112
+ className: q(Lt({ layout: _ }), n),
1111
1113
  children: [m, !t.showApply && t.showClear && /* @__PURE__ */ (0, X.jsxs)(h, {
1112
1114
  type: "button",
1113
1115
  variant: "ghost",
1114
1116
  size: "sm",
1115
1117
  className: "gap-2",
1116
1118
  onClick: u,
1117
- children: [/* @__PURE__ */ (0, X.jsx)(Ze, { className: "h-3.5 w-3.5" }), "Clear filters"]
1119
+ children: [/* @__PURE__ */ (0, X.jsx)(Qe, { className: "h-3.5 w-3.5" }), "Clear filters"]
1118
1120
  })]
1119
1121
  });
1120
- }, Bt = _t("", {
1122
+ }, Vt = vt("", {
1121
1123
  variants: { variant: {
1122
1124
  buttons: "flex flex-wrap gap-2",
1123
1125
  dropdown: "flex flex-wrap items-center gap-3",
1124
1126
  builder: "space-y-3"
1125
1127
  } },
1126
1128
  defaultVariants: { variant: "dropdown" }
1127
- }), Vt = (e) => e ? e.map((e) => ({
1129
+ }), Ht = (e) => e ? e.map((e) => ({
1128
1130
  field: e.field,
1129
1131
  direction: e.direction
1130
- })) : [], Ht = (e) => e.map((e) => ({
1132
+ })) : [], Ut = (e) => e.map((e) => ({
1131
1133
  id: `${e.field}-${e.direction}`,
1132
1134
  field: e.field,
1133
1135
  order: e.direction
1134
- })), Ut = (e) => e.filter((e) => e.field).map((e) => ({
1136
+ })), Wt = (e) => e.filter((e) => e.field).map((e) => ({
1135
1137
  field: e.field,
1136
1138
  direction: e.order
1137
- })), Wt = ({ schema: t, className: n, onChange: r }) => {
1138
- let [i, a] = e.useState(() => Vt(t.sort)), [o, s] = e.useState(() => Ht(Vt(t.sort)));
1139
+ })), Gt = ({ schema: t, className: n, onChange: r }) => {
1140
+ let [i, a] = e.useState(() => Ht(t.sort)), [o, s] = e.useState(() => Ut(Ht(t.sort)));
1139
1141
  e.useEffect(() => {
1140
- let e = Vt(t.sort);
1141
- a(e), s(Ht(e));
1142
+ let e = Ht(t.sort);
1143
+ a(e), s(Ut(e));
1142
1144
  }, [t.sort]);
1143
1145
  let c = e.useCallback((e) => {
1144
1146
  a(e), r?.(e), t.onChange && typeof window < "u" && window.dispatchEvent(new CustomEvent(t.onChange, { detail: { sort: e } }));
@@ -1168,9 +1170,9 @@ var jt = {
1168
1170
  i
1169
1171
  ]);
1170
1172
  if ((t.variant || "dropdown") === "buttons") return /* @__PURE__ */ (0, X.jsx)("div", {
1171
- className: q(Bt({ variant: "buttons" }), n),
1173
+ className: q(Vt({ variant: "buttons" }), n),
1172
1174
  children: t.fields.map((e) => {
1173
- let t = i.find((t) => t.field === e.field), n = t?.direction === "asc" ? be : ye;
1175
+ let t = i.find((t) => t.field === e.field), n = t?.direction === "asc" ? xe : be;
1174
1176
  return /* @__PURE__ */ (0, X.jsxs)(h, {
1175
1177
  type: "button",
1176
1178
  variant: t ? "secondary" : "outline",
@@ -1182,22 +1184,22 @@ var jt = {
1182
1184
  })
1183
1185
  });
1184
1186
  if (t.multiple) return /* @__PURE__ */ (0, X.jsx)("div", {
1185
- className: q(Bt({ variant: "builder" }), n),
1186
- children: /* @__PURE__ */ (0, X.jsx)(V, {
1187
+ className: q(Vt({ variant: "builder" }), n),
1188
+ children: /* @__PURE__ */ (0, X.jsx)(ge, {
1187
1189
  fields: t.fields.map((e) => ({
1188
1190
  value: e.field,
1189
1191
  label: e.label || e.field
1190
1192
  })),
1191
1193
  value: o,
1192
1194
  onChange: (e) => {
1193
- s(e), c(Ut(e));
1195
+ s(e), c(Wt(e));
1194
1196
  }
1195
1197
  })
1196
1198
  });
1197
1199
  let u = i[0];
1198
1200
  return /* @__PURE__ */ (0, X.jsxs)("div", {
1199
- className: q(Bt({ variant: "dropdown" }), n),
1200
- children: [/* @__PURE__ */ (0, X.jsxs)(I, {
1201
+ className: q(Vt({ variant: "dropdown" }), n),
1202
+ children: [/* @__PURE__ */ (0, X.jsxs)(L, {
1201
1203
  value: u?.field || "",
1202
1204
  onValueChange: (e) => {
1203
1205
  if (!e) {
@@ -1209,14 +1211,14 @@ var jt = {
1209
1211
  direction: u?.direction || "asc"
1210
1212
  }]);
1211
1213
  },
1212
- children: [/* @__PURE__ */ (0, X.jsx)(z, {
1214
+ children: [/* @__PURE__ */ (0, X.jsx)(B, {
1213
1215
  className: "w-56",
1214
- children: /* @__PURE__ */ (0, X.jsx)(B, { placeholder: "Select field" })
1215
- }), /* @__PURE__ */ (0, X.jsx)(L, { children: t.fields.map((e) => /* @__PURE__ */ (0, X.jsx)(R, {
1216
+ children: /* @__PURE__ */ (0, X.jsx)(V, { placeholder: "Select field" })
1217
+ }), /* @__PURE__ */ (0, X.jsx)(R, { children: t.fields.map((e) => /* @__PURE__ */ (0, X.jsx)(z, {
1216
1218
  value: e.field,
1217
1219
  children: e.label || e.field
1218
1220
  }, e.field)) })]
1219
- }), /* @__PURE__ */ (0, X.jsxs)(I, {
1221
+ }), /* @__PURE__ */ (0, X.jsxs)(L, {
1220
1222
  value: u?.direction || "asc",
1221
1223
  onValueChange: (e) => {
1222
1224
  u?.field && c([{
@@ -1224,13 +1226,13 @@ var jt = {
1224
1226
  direction: e
1225
1227
  }]);
1226
1228
  },
1227
- children: [/* @__PURE__ */ (0, X.jsx)(z, {
1229
+ children: [/* @__PURE__ */ (0, X.jsx)(B, {
1228
1230
  className: "w-36",
1229
- children: /* @__PURE__ */ (0, X.jsx)(B, {})
1230
- }), /* @__PURE__ */ (0, X.jsxs)(L, { children: [/* @__PURE__ */ (0, X.jsx)(R, {
1231
+ children: /* @__PURE__ */ (0, X.jsx)(V, {})
1232
+ }), /* @__PURE__ */ (0, X.jsxs)(R, { children: [/* @__PURE__ */ (0, X.jsx)(z, {
1231
1233
  value: "asc",
1232
1234
  children: "Ascending"
1233
- }), /* @__PURE__ */ (0, X.jsx)(R, {
1235
+ }), /* @__PURE__ */ (0, X.jsx)(z, {
1234
1236
  value: "desc",
1235
1237
  children: "Descending"
1236
1238
  })] })]
@@ -1239,7 +1241,7 @@ var jt = {
1239
1241
  };
1240
1242
  //#endregion
1241
1243
  //#region src/SharedViewLink.tsx
1242
- function Gt() {
1244
+ function Kt() {
1243
1245
  if (typeof crypto < "u" && typeof crypto.randomUUID == "function") return crypto.randomUUID();
1244
1246
  if (typeof crypto < "u" && typeof crypto.getRandomValues == "function") {
1245
1247
  let e = new Uint8Array(16);
@@ -1247,12 +1249,12 @@ function Gt() {
1247
1249
  }
1248
1250
  return Math.random().toString(36).slice(2) + Math.random().toString(36).slice(2);
1249
1251
  }
1250
- function Kt(e, t, n, r) {
1252
+ function qt(e, t, n, r) {
1251
1253
  return `${e}/share/${t}/${n}?mode=readonly&token=${r}`;
1252
1254
  }
1253
- var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, className: a }) => {
1255
+ var Jt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, className: a }) => {
1254
1256
  let [o, s] = e.useState(null), [c, l] = e.useState(!1), [u, d] = e.useState(!1), [f, p] = e.useState(""), [g, _] = e.useState(""), v = r ?? (typeof window < "u" ? window.location.origin : ""), ee = e.useCallback(() => {
1255
- let e = Kt(v, t, n, Gt());
1257
+ let e = qt(v, t, n, Kt());
1256
1258
  s(e), l(!1);
1257
1259
  let r = g ? new Date(Date.now() + parseInt(g, 10) * 864e5).toISOString() : void 0;
1258
1260
  i?.(e, {
@@ -1274,18 +1276,18 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1274
1276
  e.value = o, document.body.appendChild(e), e.select(), document.execCommand("copy"), document.body.removeChild(e), l(!0), setTimeout(() => l(!1), 2e3);
1275
1277
  }
1276
1278
  }, [o]);
1277
- return /* @__PURE__ */ (0, X.jsxs)(P, {
1279
+ return /* @__PURE__ */ (0, X.jsxs)(me, {
1278
1280
  open: u,
1279
1281
  onOpenChange: d,
1280
- children: [/* @__PURE__ */ (0, X.jsx)(F, {
1282
+ children: [/* @__PURE__ */ (0, X.jsx)(he, {
1281
1283
  asChild: !0,
1282
1284
  children: /* @__PURE__ */ (0, X.jsxs)(h, {
1283
1285
  variant: "outline",
1284
1286
  size: "sm",
1285
1287
  className: q("gap-2", a),
1286
- children: [/* @__PURE__ */ (0, X.jsx)(Ke, { className: "h-4 w-4" }), "Share"]
1288
+ children: [/* @__PURE__ */ (0, X.jsx)(qe, { className: "h-4 w-4" }), "Share"]
1287
1289
  })
1288
- }), /* @__PURE__ */ (0, X.jsxs)(he, {
1290
+ }), /* @__PURE__ */ (0, X.jsxs)(I, {
1289
1291
  className: "w-96 space-y-4",
1290
1292
  align: "end",
1291
1293
  children: [/* @__PURE__ */ (0, X.jsxs)("div", {
@@ -1306,7 +1308,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1306
1308
  })]
1307
1309
  }), o ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsxs)("div", {
1308
1310
  className: "flex items-center gap-2",
1309
- children: [/* @__PURE__ */ (0, X.jsx)(N, {
1311
+ children: [/* @__PURE__ */ (0, X.jsx)(P, {
1310
1312
  value: o,
1311
1313
  readOnly: !0,
1312
1314
  className: "h-8 text-xs",
@@ -1316,7 +1318,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1316
1318
  size: "sm",
1317
1319
  onClick: y,
1318
1320
  className: "shrink-0 gap-1",
1319
- children: c ? /* @__PURE__ */ (0, X.jsx)(Se, { className: "h-4 w-4 text-green-500" }) : /* @__PURE__ */ (0, X.jsx)(we, { className: "h-4 w-4" })
1321
+ children: c ? /* @__PURE__ */ (0, X.jsx)(Ce, { className: "h-4 w-4 text-green-500" }) : /* @__PURE__ */ (0, X.jsx)(Te, { className: "h-4 w-4" })
1320
1322
  })]
1321
1323
  }), (f || g) && /* @__PURE__ */ (0, X.jsxs)("div", {
1322
1324
  className: "flex items-center gap-2 flex-wrap",
@@ -1328,7 +1330,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1328
1330
  variant: "outline",
1329
1331
  className: "text-xs gap-1",
1330
1332
  children: [
1331
- /* @__PURE__ */ (0, X.jsx)(xe, { className: "h-3 w-3" }),
1333
+ /* @__PURE__ */ (0, X.jsx)(Se, { className: "h-3 w-3" }),
1332
1334
  "Expires in ",
1333
1335
  g,
1334
1336
  " day",
@@ -1343,7 +1345,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1343
1345
  children: [/* @__PURE__ */ (0, X.jsxs)("label", {
1344
1346
  className: "flex items-center gap-1.5 text-xs font-medium text-foreground",
1345
1347
  children: [/* @__PURE__ */ (0, X.jsx)(Ie, { className: "h-3.5 w-3.5" }), "Password protection (optional)"]
1346
- }), /* @__PURE__ */ (0, X.jsx)(N, {
1348
+ }), /* @__PURE__ */ (0, X.jsx)(P, {
1347
1349
  type: "password",
1348
1350
  value: f,
1349
1351
  onChange: (e) => p(e.target.value),
@@ -1355,7 +1357,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1355
1357
  className: "space-y-1.5",
1356
1358
  children: [/* @__PURE__ */ (0, X.jsxs)("label", {
1357
1359
  className: "flex items-center gap-1.5 text-xs font-medium text-foreground",
1358
- children: [/* @__PURE__ */ (0, X.jsx)(xe, { className: "h-3.5 w-3.5" }), "Expires after (optional)"]
1360
+ children: [/* @__PURE__ */ (0, X.jsx)(Se, { className: "h-3.5 w-3.5" }), "Expires after (optional)"]
1359
1361
  }), /* @__PURE__ */ (0, X.jsxs)("select", {
1360
1362
  value: g,
1361
1363
  onChange: (e) => _(e.target.value),
@@ -1388,19 +1390,19 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1388
1390
  onClick: ee,
1389
1391
  className: "w-full gap-2",
1390
1392
  size: "sm",
1391
- children: [/* @__PURE__ */ (0, X.jsx)(Ke, { className: "h-4 w-4" }), "Generate Link"]
1393
+ children: [/* @__PURE__ */ (0, X.jsx)(qe, { className: "h-4 w-4" }), "Generate Link"]
1392
1394
  })
1393
1395
  ]
1394
1396
  })]
1395
1397
  })]
1396
1398
  });
1397
- }, Jt = {
1399
+ }, Yt = {
1398
1400
  private: 0,
1399
1401
  team: 1,
1400
1402
  organization: 2,
1401
1403
  public: 3
1402
- }, Yt = 8, Xt = ({ id: e, disabled: t, children: n }) => {
1403
- let { attributes: r, listeners: i, setNodeRef: a, transform: o, transition: s, isDragging: c } = lt({
1404
+ }, Xt = 8, Zt = ({ id: e, disabled: t, children: n }) => {
1405
+ let { attributes: r, listeners: i, setNodeRef: a, transform: o, transition: s, isDragging: c } = ut({
1404
1406
  id: e,
1405
1407
  disabled: t,
1406
1408
  attributes: {
@@ -1412,7 +1414,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1412
1414
  return /* @__PURE__ */ (0, X.jsx)(X.Fragment, { children: n({
1413
1415
  setNodeRef: a,
1414
1416
  style: {
1415
- transform: dt.Transform.toString(o),
1417
+ transform: ft.Transform.toString(o),
1416
1418
  transition: s,
1417
1419
  zIndex: c ? 10 : void 0,
1418
1420
  opacity: c ? .5 : void 0
@@ -1421,15 +1423,15 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1421
1423
  attributes: r,
1422
1424
  isDragging: c
1423
1425
  }) });
1424
- }, Zt = ({ views: e, activeViewId: r, onViewChange: c, viewTypeIcons: l = {}, config: u = {}, onAddView: d, onRenameView: f, onDuplicateView: p, onDeleteView: m, onSetDefaultView: g, onShareView: _, onSaveAsView: w, onPinView: T, onReorderViews: E, onChangeViewType: ne, onConfigView: re, onManageViews: D, availableViewTypes: O, hasUnsavedChanges: ie = !1, onResetChanges: ae, className: oe }) => {
1425
- let { showAddButton: se = !0, inlineRename: fe = !0, contextMenu: pe = !0, reorderable: me = !1, maxVisibleTabs: P = 6, showIndicators: he = !0, showSaveAsView: F = !0, showPinnedSection: I = !0, showVisibilityGroups: L = !1 } = u, [R, z] = s(null), [B, V] = s(""), H = o(null);
1426
+ }, Qt = ({ views: e, activeViewId: r, onViewChange: c, viewTypeIcons: l = {}, config: u = {}, onAddView: d, onRenameView: f, onDuplicateView: p, onDeleteView: m, onSetDefaultView: g, onShareView: _, onSaveAsView: w, onPinView: T, onReorderViews: E, onChangeViewType: D, onConfigView: ne, onManageViews: re, availableViewTypes: O, hasUnsavedChanges: ie = !1, onResetChanges: ae, className: oe }) => {
1427
+ let { showAddButton: se = !0, inlineRename: fe = !0, contextMenu: N = !0, reorderable: F = !1, maxVisibleTabs: pe = 6, showIndicators: me = !0, showSaveAsView: I = !0, showPinnedSection: he = !0, showVisibilityGroups: L = !1 } = u, [R, z] = s(null), [B, V] = s(""), ge = o(null);
1426
1428
  i(() => {
1427
- R && H.current && (H.current.focus(), H.current.select());
1429
+ R && ge.current && (ge.current.focus(), ge.current.select());
1428
1430
  }, [R]);
1429
- let ge = n((t) => {
1431
+ let H = n((t) => {
1430
1432
  if (!fe || !f) return;
1431
1433
  let n = e.find((e) => e.id === t);
1432
- n && (z(t), V(n.label));
1434
+ n && (n.readonly || (z(t), V(n.label)));
1433
1435
  }, [
1434
1436
  fe,
1435
1437
  f,
@@ -1442,25 +1444,25 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1442
1444
  f
1443
1445
  ]), ve = n(() => {
1444
1446
  z(null), V("");
1445
- }, []), J = a(() => {
1447
+ }, []), ye = a(() => e.length > 0 && e.every((e) => !!e.readonly), [e]), J = a(() => {
1446
1448
  let t = [...e];
1447
1449
  return t.sort((e, t) => {
1448
- if (I) {
1450
+ if (he) {
1449
1451
  let n = +!!e.isPinned, r = +!!t.isPinned;
1450
1452
  if (n !== r) return r - n;
1451
1453
  }
1452
1454
  if (L) {
1453
- let n = Jt[e.visibility || "public"] ?? Jt.public, r = Jt[t.visibility || "public"] ?? Jt.public;
1455
+ let n = Yt[e.visibility || "public"] ?? Yt.public, r = Yt[t.visibility || "public"] ?? Yt.public;
1454
1456
  if (n !== r) return n - r;
1455
1457
  }
1456
1458
  return 0;
1457
1459
  }), t;
1458
1460
  }, [
1459
1461
  e,
1460
- I,
1462
+ he,
1461
1463
  L
1462
- ]), { visibleViews: ye, overflowViews: be } = a(() => {
1463
- let e = J.slice(0, P), t = J.slice(P), n = t.findIndex((e) => e.id === r);
1464
+ ]), { visibleViews: be, overflowViews: xe } = a(() => {
1465
+ let e = J.slice(0, pe), t = J.slice(pe), n = t.findIndex((e) => e.id === r);
1464
1466
  if (n === -1) return {
1465
1467
  visibleViews: e,
1466
1468
  overflowViews: t
@@ -1472,31 +1474,31 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1472
1474
  };
1473
1475
  }, [
1474
1476
  J,
1475
- P,
1477
+ pe,
1476
1478
  r
1477
- ]), xe = it(rt(tt, { activationConstraint: { distance: Yt } }), rt(et)), Se = n((e) => {
1479
+ ]), Se = at(it(nt, { activationConstraint: { distance: Xt } }), it(tt)), Ce = n((e) => {
1478
1480
  let { active: t, over: n } = e;
1479
1481
  if (!n || t.id === n.id || !E) return;
1480
1482
  let r = J.findIndex((e) => e.id === t.id), i = J.findIndex((e) => e.id === n.id);
1481
- r === -1 || i === -1 || E(ot(J, r, i).map((e) => e.id));
1482
- }, [J, E]), Te = Ye, Ee = n((e) => {
1483
+ r === -1 || i === -1 || E(st(J, r, i).map((e) => e.id));
1484
+ }, [J, E]), Y = Xe, Ee = n((e) => {
1483
1485
  if (!L || e === 0) return !1;
1484
- let t = ye[e - 1], n = ye[e], r = (e) => e.visibility === "private";
1486
+ let t = be[e - 1], n = be[e], r = (e) => e.visibility === "private";
1485
1487
  return r(t) && !r(n);
1486
- }, [L, ye]), De = (e, n) => {
1487
- let i = e.id === r, a = l[e.type] || Te, o = R === e.id, s = he && (e.hasActiveFilters || e.hasActiveSort), u = Ee(n), d = ((e) => L ? e.visibility === "private" ? /* @__PURE__ */ (0, X.jsx)(Ie, {
1488
+ }, [L, be]), De = (e, n) => {
1489
+ let i = e.id === r, a = l[e.type] || Y, o = R === e.id, s = me && (e.hasActiveFilters || e.hasActiveSort), u = Ee(n), d = !!e.readonly, h = ((e) => L ? e.visibility === "private" ? /* @__PURE__ */ (0, X.jsx)(Ie, {
1488
1490
  "data-testid": `view-tab-visibility-${e.id}`,
1489
1491
  className: "h-3 w-3 text-muted-foreground shrink-0"
1490
1492
  }) : e.visibility ? /* @__PURE__ */ (0, X.jsx)(ke, {
1491
1493
  "data-testid": `view-tab-visibility-${e.id}`,
1492
1494
  className: "h-3 w-3 text-muted-foreground shrink-0"
1493
- }) : null : null)(e), h = (t) => /* @__PURE__ */ (0, X.jsxs)("div", {
1495
+ }) : null : null)(e), w = (t) => /* @__PURE__ */ (0, X.jsxs)("div", {
1494
1496
  "data-testid": `view-tab-${e.id}`,
1495
1497
  role: "tab",
1496
1498
  tabIndex: 0,
1497
1499
  "aria-selected": i,
1498
1500
  onClick: () => !o && c(e.id),
1499
- onDoubleClick: () => ge(e.id),
1501
+ onDoubleClick: () => H(e.id),
1500
1502
  onKeyDown: (t) => {
1501
1503
  !o && (t.key === "Enter" || t.key === " ") && (t.preventDefault(), c(e.id));
1502
1504
  },
@@ -1504,20 +1506,20 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1504
1506
  ...t?.attributes ?? {},
1505
1507
  className: q("group/tab inline-flex items-center gap-1.5 px-3 py-2 text-sm font-medium border-b-2 transition-colors whitespace-nowrap relative outline-none focus-visible:ring-2 focus-visible:ring-ring", t?.isDragging ? "cursor-grabbing" : "cursor-pointer", i ? "border-primary text-primary" : "border-transparent text-muted-foreground hover:text-foreground hover:border-border"),
1506
1508
  children: [
1507
- me && E && /* @__PURE__ */ (0, X.jsx)("span", {
1509
+ F && E && /* @__PURE__ */ (0, X.jsx)("span", {
1508
1510
  "data-testid": `view-tab-drag-handle-${e.id}`,
1509
1511
  "aria-hidden": "true",
1510
1512
  className: q("text-muted-foreground transition-opacity pointer-events-none", "opacity-0 group-hover/tab:opacity-100", t?.isDragging && "opacity-100"),
1511
1513
  children: /* @__PURE__ */ (0, X.jsx)(je, { className: "h-3 w-3" })
1512
1514
  }),
1513
- I && e.isPinned && /* @__PURE__ */ (0, X.jsx)(Y, {
1515
+ he && e.isPinned && /* @__PURE__ */ (0, X.jsx)(Be, {
1514
1516
  "data-testid": `view-tab-pin-indicator-${e.id}`,
1515
1517
  className: "h-3 w-3 text-primary shrink-0"
1516
1518
  }),
1517
- d,
1519
+ h,
1518
1520
  /* @__PURE__ */ (0, X.jsx)(a, { className: "h-3.5 w-3.5" }),
1519
- o ? /* @__PURE__ */ (0, X.jsx)(N, {
1520
- ref: H,
1521
+ o ? /* @__PURE__ */ (0, X.jsx)(P, {
1522
+ ref: ge,
1521
1523
  "data-testid": `view-tab-rename-input-${e.id}`,
1522
1524
  value: B,
1523
1525
  onChange: (e) => V(e.target.value),
@@ -1528,6 +1530,18 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1528
1530
  className: "h-5 w-24 px-1 py-0 text-sm border-none focus-visible:ring-1",
1529
1531
  onClick: (e) => e.stopPropagation()
1530
1532
  }) : /* @__PURE__ */ (0, X.jsx)("span", { children: e.label }),
1533
+ d && !ye && /* @__PURE__ */ (0, X.jsxs)(U, { children: [/* @__PURE__ */ (0, X.jsx)(K, {
1534
+ asChild: !0,
1535
+ children: /* @__PURE__ */ (0, X.jsx)(Ie, {
1536
+ "data-testid": `view-tab-readonly-${e.id}`,
1537
+ "aria-label": "Read-only view",
1538
+ className: "h-3 w-3 text-muted-foreground shrink-0"
1539
+ })
1540
+ }), /* @__PURE__ */ (0, X.jsx)(W, {
1541
+ side: "bottom",
1542
+ className: "text-xs",
1543
+ children: e.readonlyReason || "System view — duplicate to customize."
1544
+ })] }),
1531
1545
  s && /* @__PURE__ */ (0, X.jsxs)(U, { children: [/* @__PURE__ */ (0, X.jsx)(K, {
1532
1546
  asChild: !0,
1533
1547
  children: /* @__PURE__ */ (0, X.jsx)("span", {
@@ -1540,8 +1554,8 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1540
1554
  className: "text-xs",
1541
1555
  children: [e.hasActiveFilters && "Active filters", e.hasActiveSort && "Active sort"].filter(Boolean).join(", ")
1542
1556
  })] }),
1543
- e.isDefault && /* @__PURE__ */ (0, X.jsx)(Je, { className: "h-3 w-3 text-amber-500 fill-amber-500 shrink-0" }),
1544
- i && (re || f || p || m) && /* @__PURE__ */ (0, X.jsxs)(k, { children: [/* @__PURE__ */ (0, X.jsx)(de, {
1557
+ e.isDefault && /* @__PURE__ */ (0, X.jsx)(Ye, { className: "h-3 w-3 text-amber-500 fill-amber-500 shrink-0" }),
1558
+ i && (ne || f || p || m) && /* @__PURE__ */ (0, X.jsxs)(k, { children: [/* @__PURE__ */ (0, X.jsx)(de, {
1545
1559
  asChild: !0,
1546
1560
  children: /* @__PURE__ */ (0, X.jsx)("button", {
1547
1561
  type: "button",
@@ -1551,109 +1565,109 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1551
1565
  onPointerDown: (e) => e.stopPropagation(),
1552
1566
  onMouseDown: (e) => e.stopPropagation(),
1553
1567
  "aria-label": `View actions for ${e.label}`,
1554
- children: /* @__PURE__ */ (0, X.jsx)(Ce, { className: "h-3 w-3" })
1568
+ children: /* @__PURE__ */ (0, X.jsx)(we, { className: "h-3 w-3" })
1555
1569
  })
1556
1570
  }), /* @__PURE__ */ (0, X.jsxs)(A, {
1557
1571
  align: "start",
1558
1572
  className: "min-w-[180px]",
1559
1573
  onClick: (e) => e.stopPropagation(),
1560
1574
  children: [
1561
- re && /* @__PURE__ */ (0, X.jsxs)(j, {
1575
+ ne && !d && /* @__PURE__ */ (0, X.jsxs)(j, {
1562
1576
  "data-testid": `view-tab-menu-config-${e.id}`,
1563
- onClick: () => re(e.id),
1564
- children: [/* @__PURE__ */ (0, X.jsx)(Ge, { className: "h-4 w-4 mr-2" }), " Edit view config"]
1577
+ onClick: () => ne(e.id),
1578
+ children: [/* @__PURE__ */ (0, X.jsx)(Ke, { className: "h-4 w-4 mr-2" }), " Edit view config"]
1565
1579
  }),
1566
- f && /* @__PURE__ */ (0, X.jsxs)(j, {
1580
+ f && !d && /* @__PURE__ */ (0, X.jsxs)(j, {
1567
1581
  "data-testid": `view-tab-menu-rename-${e.id}`,
1568
- onClick: () => ge(e.id),
1582
+ onClick: () => H(e.id),
1569
1583
  children: [/* @__PURE__ */ (0, X.jsx)(ze, { className: "h-4 w-4 mr-2" }), " Rename"]
1570
1584
  }),
1571
1585
  p && /* @__PURE__ */ (0, X.jsxs)(j, {
1572
1586
  "data-testid": `view-tab-menu-duplicate-${e.id}`,
1573
1587
  onClick: () => p(e.id),
1574
- children: [/* @__PURE__ */ (0, X.jsx)(we, { className: "h-4 w-4 mr-2" }), " Duplicate view"]
1588
+ children: [/* @__PURE__ */ (0, X.jsx)(Te, { className: "h-4 w-4 mr-2" }), " Duplicate view"]
1575
1589
  }),
1576
1590
  _ && /* @__PURE__ */ (0, X.jsxs)(j, {
1577
1591
  "data-testid": `view-tab-menu-share-${e.id}`,
1578
1592
  onClick: () => _(e.id),
1579
- children: [/* @__PURE__ */ (0, X.jsx)(Ke, { className: "h-4 w-4 mr-2" }), " Share view"]
1593
+ children: [/* @__PURE__ */ (0, X.jsx)(qe, { className: "h-4 w-4 mr-2" }), " Share view"]
1580
1594
  }),
1581
- g && /* @__PURE__ */ (0, X.jsxs)(j, {
1595
+ g && !d && /* @__PURE__ */ (0, X.jsxs)(j, {
1582
1596
  "data-testid": `view-tab-menu-default-${e.id}`,
1583
1597
  onClick: () => g(e.id),
1584
- children: [/* @__PURE__ */ (0, X.jsx)(Je, { className: "h-4 w-4 mr-2" }), " Set as default"]
1598
+ children: [/* @__PURE__ */ (0, X.jsx)(Ye, { className: "h-4 w-4 mr-2" }), " Set as default"]
1585
1599
  }),
1586
- T && /* @__PURE__ */ (0, X.jsx)(j, {
1600
+ T && !d && /* @__PURE__ */ (0, X.jsx)(j, {
1587
1601
  "data-testid": `view-tab-menu-pin-${e.id}`,
1588
1602
  onClick: () => T(e.id, !e.isPinned),
1589
- children: e.isPinned ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 mr-2" }), " Unpin view"] }) : /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Y, { className: "h-4 w-4 mr-2" }), " Pin view"] })
1603
+ children: e.isPinned ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-4 w-4 mr-2" }), " Unpin view"] }) : /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 mr-2" }), " Pin view"] })
1590
1604
  }),
1591
- ne && O && O.length > 0 && /* @__PURE__ */ (0, X.jsxs)(ce, { children: [/* @__PURE__ */ (0, X.jsxs)(ue, {
1605
+ D && !d && O && O.length > 0 && /* @__PURE__ */ (0, X.jsxs)(ce, { children: [/* @__PURE__ */ (0, X.jsxs)(ue, {
1592
1606
  "data-testid": `view-tab-menu-change-type-${e.id}`,
1593
1607
  children: [/* @__PURE__ */ (0, X.jsx)(Ne, { className: "h-4 w-4 mr-2" }), " Change view type"]
1594
1608
  }), /* @__PURE__ */ (0, X.jsx)(le, { children: O.map((t) => {
1595
- let n = l[t.type] || Te;
1609
+ let n = l[t.type] || Y;
1596
1610
  return /* @__PURE__ */ (0, X.jsxs)(j, {
1597
1611
  "data-testid": `view-tab-menu-type-${e.id}-${t.type}`,
1598
1612
  disabled: t.type === e.type,
1599
- onClick: () => ne(e.id, t.type),
1613
+ onClick: () => D(e.id, t.type),
1600
1614
  children: [/* @__PURE__ */ (0, X.jsx)(n, { className: "h-4 w-4 mr-2" }), /* @__PURE__ */ (0, X.jsx)("span", { children: t.label })]
1601
1615
  }, t.type);
1602
1616
  }) })] }),
1603
- m && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(M, {}), /* @__PURE__ */ (0, X.jsxs)(j, {
1617
+ m && !d && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(M, {}), /* @__PURE__ */ (0, X.jsxs)(j, {
1604
1618
  "data-testid": `view-tab-menu-delete-${e.id}`,
1605
1619
  onClick: () => m(e.id),
1606
1620
  className: "text-destructive focus:text-destructive",
1607
- children: [/* @__PURE__ */ (0, X.jsx)(Xe, { className: "h-4 w-4 mr-2" }), " Delete view"]
1621
+ children: [/* @__PURE__ */ (0, X.jsx)(Ze, { className: "h-4 w-4 mr-2" }), " Delete view"]
1608
1622
  })] }),
1609
- D && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(M, {}), /* @__PURE__ */ (0, X.jsxs)(j, {
1623
+ re && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(M, {}), /* @__PURE__ */ (0, X.jsxs)(j, {
1610
1624
  "data-testid": `view-tab-menu-manage-${e.id}`,
1611
- onClick: D,
1625
+ onClick: re,
1612
1626
  children: [/* @__PURE__ */ (0, X.jsx)(Fe, { className: "h-4 w-4 mr-2" }), " Manage all views…"]
1613
1627
  })] })
1614
1628
  ]
1615
1629
  })] })
1616
1630
  ]
1617
- }), w = (t) => !pe || o ? t : /* @__PURE__ */ (0, X.jsxs)(v, { children: [/* @__PURE__ */ (0, X.jsx)(C, {
1631
+ }), ie = (t) => !N || o ? t : /* @__PURE__ */ (0, X.jsxs)(v, { children: [/* @__PURE__ */ (0, X.jsx)(C, {
1618
1632
  asChild: !0,
1619
1633
  children: t
1620
1634
  }), /* @__PURE__ */ (0, X.jsxs)(ee, { children: [
1621
- f && /* @__PURE__ */ (0, X.jsxs)(y, {
1635
+ f && !d && /* @__PURE__ */ (0, X.jsxs)(y, {
1622
1636
  "data-testid": `context-menu-rename-${e.id}`,
1623
- onClick: () => ge(e.id),
1637
+ onClick: () => H(e.id),
1624
1638
  children: [/* @__PURE__ */ (0, X.jsx)(ze, { className: "h-4 w-4 mr-2" }), " Rename"]
1625
1639
  }),
1626
1640
  p && /* @__PURE__ */ (0, X.jsxs)(y, {
1627
1641
  "data-testid": `context-menu-duplicate-${e.id}`,
1628
1642
  onClick: () => p(e.id),
1629
- children: [/* @__PURE__ */ (0, X.jsx)(we, { className: "h-4 w-4 mr-2" }), " Duplicate View"]
1643
+ children: [/* @__PURE__ */ (0, X.jsx)(Te, { className: "h-4 w-4 mr-2" }), " Duplicate View"]
1630
1644
  }),
1631
1645
  _ && /* @__PURE__ */ (0, X.jsxs)(y, {
1632
1646
  "data-testid": `context-menu-share-${e.id}`,
1633
1647
  onClick: () => _(e.id),
1634
- children: [/* @__PURE__ */ (0, X.jsx)(Ke, { className: "h-4 w-4 mr-2" }), " Share View"]
1648
+ children: [/* @__PURE__ */ (0, X.jsx)(qe, { className: "h-4 w-4 mr-2" }), " Share View"]
1635
1649
  }),
1636
- g && /* @__PURE__ */ (0, X.jsxs)(y, {
1650
+ g && !d && /* @__PURE__ */ (0, X.jsxs)(y, {
1637
1651
  "data-testid": `context-menu-default-${e.id}`,
1638
1652
  onClick: () => g(e.id),
1639
- children: [/* @__PURE__ */ (0, X.jsx)(Je, { className: "h-4 w-4 mr-2" }), " Set as Default"]
1653
+ children: [/* @__PURE__ */ (0, X.jsx)(Ye, { className: "h-4 w-4 mr-2" }), " Set as Default"]
1640
1654
  }),
1641
- T && /* @__PURE__ */ (0, X.jsx)(y, {
1655
+ T && !d && /* @__PURE__ */ (0, X.jsx)(y, {
1642
1656
  "data-testid": `context-menu-pin-${e.id}`,
1643
1657
  onClick: () => T(e.id, !e.isPinned),
1644
- children: e.isPinned ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 mr-2" }), " Unpin View"] }) : /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Y, { className: "h-4 w-4 mr-2" }), " Pin View"] })
1658
+ children: e.isPinned ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-4 w-4 mr-2" }), " Unpin View"] }) : /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 mr-2" }), " Pin View"] })
1645
1659
  }),
1646
- ne && O && O.length > 0 && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(b, {}), /* @__PURE__ */ (0, X.jsxs)(te, { children: [/* @__PURE__ */ (0, X.jsxs)(S, {
1660
+ D && !d && O && O.length > 0 && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(b, {}), /* @__PURE__ */ (0, X.jsxs)(te, { children: [/* @__PURE__ */ (0, X.jsxs)(S, {
1647
1661
  "data-testid": `context-menu-change-type-${e.id}`,
1648
1662
  children: [/* @__PURE__ */ (0, X.jsx)(Ne, { className: "h-4 w-4 mr-2" }), " Change View Type"]
1649
1663
  }), /* @__PURE__ */ (0, X.jsx)(x, {
1650
1664
  "data-testid": `context-menu-type-submenu-${e.id}`,
1651
1665
  children: O.map((t) => {
1652
- let n = l[t.type] || Te;
1666
+ let n = l[t.type] || Y;
1653
1667
  return /* @__PURE__ */ (0, X.jsxs)(y, {
1654
1668
  "data-testid": `context-menu-type-${e.id}-${t.type}`,
1655
1669
  disabled: t.type === e.type,
1656
- onClick: () => ne(e.id, t.type),
1670
+ onClick: () => D(e.id, t.type),
1657
1671
  children: [/* @__PURE__ */ (0, X.jsx)(n, { className: "h-4 w-4 mr-2" }), /* @__PURE__ */ (0, X.jsxs)("div", {
1658
1672
  className: "flex flex-col",
1659
1673
  children: [/* @__PURE__ */ (0, X.jsx)("span", { children: t.label }), t.description && /* @__PURE__ */ (0, X.jsx)("span", {
@@ -1664,28 +1678,28 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1664
1678
  }, t.type);
1665
1679
  })
1666
1680
  })] })] }),
1667
- m && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(b, {}), /* @__PURE__ */ (0, X.jsxs)(y, {
1681
+ m && !d && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(b, {}), /* @__PURE__ */ (0, X.jsxs)(y, {
1668
1682
  "data-testid": `context-menu-delete-${e.id}`,
1669
1683
  onClick: () => m(e.id),
1670
1684
  className: "text-destructive focus:text-destructive",
1671
- children: [/* @__PURE__ */ (0, X.jsx)(Xe, { className: "h-4 w-4 mr-2" }), " Delete View"]
1685
+ children: [/* @__PURE__ */ (0, X.jsx)(Ze, { className: "h-4 w-4 mr-2" }), " Delete View"]
1672
1686
  })] }),
1673
- D && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(b, {}), /* @__PURE__ */ (0, X.jsxs)(y, {
1687
+ re && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(b, {}), /* @__PURE__ */ (0, X.jsxs)(y, {
1674
1688
  "data-testid": `context-menu-manage-${e.id}`,
1675
- onClick: D,
1689
+ onClick: re,
1676
1690
  children: [/* @__PURE__ */ (0, X.jsx)(Fe, { className: "h-4 w-4 mr-2" }), " Manage all views…"]
1677
1691
  })] })
1678
1692
  ] })] });
1679
- return me && E ? /* @__PURE__ */ (0, X.jsxs)(t.Fragment, { children: [u && /* @__PURE__ */ (0, X.jsx)("div", {
1693
+ return F && E ? /* @__PURE__ */ (0, X.jsxs)(t.Fragment, { children: [u && /* @__PURE__ */ (0, X.jsx)("div", {
1680
1694
  "data-testid": "view-tab-visibility-separator",
1681
1695
  className: "w-px h-5 bg-border mx-1 self-center shrink-0"
1682
- }), /* @__PURE__ */ (0, X.jsx)(Xt, {
1696
+ }), /* @__PURE__ */ (0, X.jsx)(Zt, {
1683
1697
  id: e.id,
1684
1698
  children: ({ setNodeRef: e, style: t, listeners: n, attributes: r, isDragging: i }) => /* @__PURE__ */ (0, X.jsx)("div", {
1685
1699
  ref: e,
1686
1700
  style: t,
1687
1701
  className: q("flex", i && "z-10"),
1688
- children: w(h({
1702
+ children: ie(w({
1689
1703
  listeners: n,
1690
1704
  attributes: r,
1691
1705
  isDragging: i
@@ -1694,19 +1708,19 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1694
1708
  })] }, e.id) : /* @__PURE__ */ (0, X.jsxs)(t.Fragment, { children: [u && /* @__PURE__ */ (0, X.jsx)("div", {
1695
1709
  "data-testid": "view-tab-visibility-separator",
1696
1710
  className: "w-px h-5 bg-border mx-1 self-center shrink-0"
1697
- }), w(h())] }, e.id);
1698
- }, Oe = /* @__PURE__ */ (0, X.jsx)(X.Fragment, { children: ye.map((e, t) => De(e, t)) });
1711
+ }), ie(w())] }, e.id);
1712
+ }, Oe = /* @__PURE__ */ (0, X.jsx)(X.Fragment, { children: be.map((e, t) => De(e, t)) });
1699
1713
  return /* @__PURE__ */ (0, X.jsx)(G, { children: /* @__PURE__ */ (0, X.jsxs)("div", {
1700
1714
  "data-testid": "view-tab-bar",
1701
1715
  className: q("flex items-center gap-0.5 -mb-px", oe),
1702
1716
  children: [
1703
- me && E ? /* @__PURE__ */ (0, X.jsx)($e, {
1704
- sensors: xe,
1705
- collisionDetection: nt,
1706
- onDragEnd: Se,
1707
- children: /* @__PURE__ */ (0, X.jsx)(at, {
1708
- items: ye.map((e) => e.id),
1709
- strategy: st,
1717
+ F && E ? /* @__PURE__ */ (0, X.jsx)(et, {
1718
+ sensors: Se,
1719
+ collisionDetection: rt,
1720
+ onDragEnd: Ce,
1721
+ children: /* @__PURE__ */ (0, X.jsx)(ot, {
1722
+ items: be.map((e) => e.id),
1723
+ strategy: ct,
1710
1724
  children: /* @__PURE__ */ (0, X.jsx)("div", {
1711
1725
  "data-testid": "view-tab-sortable-container",
1712
1726
  className: "flex items-center gap-0.5",
@@ -1714,33 +1728,33 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1714
1728
  })
1715
1729
  })
1716
1730
  }) : Oe,
1717
- be.length > 0 && /* @__PURE__ */ (0, X.jsxs)(k, { children: [/* @__PURE__ */ (0, X.jsx)(de, {
1731
+ xe.length > 0 && /* @__PURE__ */ (0, X.jsxs)(k, { children: [/* @__PURE__ */ (0, X.jsx)(de, {
1718
1732
  asChild: !0,
1719
1733
  children: /* @__PURE__ */ (0, X.jsxs)("button", {
1720
1734
  "data-testid": "view-tab-overflow",
1721
1735
  className: "inline-flex items-center gap-1 px-2 py-2 text-sm text-muted-foreground hover:text-foreground transition-colors",
1722
1736
  children: [/* @__PURE__ */ (0, X.jsx)(Re, { className: "h-4 w-4" }), /* @__PURE__ */ (0, X.jsxs)("span", {
1723
1737
  className: "text-xs",
1724
- children: [be.length, " more"]
1738
+ children: [xe.length, " more"]
1725
1739
  })]
1726
1740
  })
1727
1741
  }), /* @__PURE__ */ (0, X.jsxs)(A, {
1728
1742
  align: "end",
1729
- children: [D && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsxs)(j, {
1743
+ children: [re && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsxs)(j, {
1730
1744
  "data-testid": "view-tab-overflow-manage",
1731
- onClick: D,
1745
+ onClick: re,
1732
1746
  className: "font-medium",
1733
1747
  children: [/* @__PURE__ */ (0, X.jsx)(Fe, { className: "h-4 w-4 mr-2" }), " Manage all views…"]
1734
- }), /* @__PURE__ */ (0, X.jsx)(M, {})] }), be.map((e) => {
1735
- let t = l[e.type] || Te;
1748
+ }), /* @__PURE__ */ (0, X.jsx)(M, {})] }), xe.map((e) => {
1749
+ let t = l[e.type] || Y;
1736
1750
  return /* @__PURE__ */ (0, X.jsxs)(j, {
1737
1751
  "data-testid": `view-tab-overflow-${e.id}`,
1738
1752
  onClick: () => c(e.id),
1739
1753
  children: [
1740
- e.isPinned && /* @__PURE__ */ (0, X.jsx)(Y, { className: "h-3 w-3 mr-1 text-primary shrink-0" }),
1754
+ e.isPinned && /* @__PURE__ */ (0, X.jsx)(Be, { className: "h-3 w-3 mr-1 text-primary shrink-0" }),
1741
1755
  /* @__PURE__ */ (0, X.jsx)(t, { className: "h-4 w-4 mr-2" }),
1742
1756
  e.label,
1743
- he && (e.hasActiveFilters || e.hasActiveSort) && /* @__PURE__ */ (0, X.jsx)("span", {
1757
+ me && (e.hasActiveFilters || e.hasActiveSort) && /* @__PURE__ */ (0, X.jsx)("span", {
1744
1758
  className: "ml-auto inline-flex items-center justify-center h-4 min-w-[16px] rounded-full bg-primary/15 text-[10px] font-medium text-primary px-1",
1745
1759
  children: [e.hasActiveFilters && "F", e.hasActiveSort && "S"].filter(Boolean).join("")
1746
1760
  })
@@ -1754,14 +1768,14 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1754
1768
  "data-testid": "view-tab-add",
1755
1769
  onClick: d,
1756
1770
  className: "inline-flex items-center px-2 py-2 text-muted-foreground hover:text-foreground transition-colors",
1757
- children: /* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-4 w-4" })
1771
+ children: /* @__PURE__ */ (0, X.jsx)(He, { className: "h-4 w-4" })
1758
1772
  })
1759
1773
  }), /* @__PURE__ */ (0, X.jsx)(W, { children: "Add View" })] }),
1760
- F && ie && /* @__PURE__ */ (0, X.jsxs)("div", {
1774
+ I && ie && /* @__PURE__ */ (0, X.jsxs)("div", {
1761
1775
  "data-testid": "view-tab-save-as",
1762
1776
  className: "flex items-center gap-1 ml-2 text-xs text-amber-600 dark:text-amber-400",
1763
1777
  children: [
1764
- /* @__PURE__ */ (0, X.jsx)(He, { className: "h-3.5 w-3.5" }),
1778
+ /* @__PURE__ */ (0, X.jsx)(Ue, { className: "h-3.5 w-3.5" }),
1765
1779
  /* @__PURE__ */ (0, X.jsx)("span", {
1766
1780
  className: "hidden sm:inline",
1767
1781
  children: "Unsaved changes"
@@ -1786,18 +1800,18 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1786
1800
  })
1787
1801
  ]
1788
1802
  }) });
1789
- }, Qt = Ye, $t = ({ view: e, isActive: t, Icon: r, isRenaming: a, onStartRename: c, onCommitRename: l, onCancelRename: u, onRowClick: d, onDelete: f, onDuplicate: p, onSetDefault: m, onSetPinned: h, onConfigView: g }) => {
1790
- let { attributes: _, listeners: v, setNodeRef: ee, transform: y, transition: b, isDragging: te } = lt({ id: e.id }), x = {
1791
- transform: dt.Transform.toString(y),
1803
+ }, $t = Xe, en = ({ view: e, isActive: t, Icon: r, isRenaming: a, onStartRename: c, onCommitRename: l, onCancelRename: u, onRowClick: d, onDelete: f, onDuplicate: p, onSetDefault: m, onSetPinned: h, onConfigView: g }) => {
1804
+ let { attributes: _, listeners: v, setNodeRef: ee, transform: y, transition: b, isDragging: te } = ut({ id: e.id }), x = {
1805
+ transform: ft.Transform.toString(y),
1792
1806
  transition: b,
1793
1807
  opacity: te ? .5 : 1
1794
- }, S = o(null), [C, w] = s(e.label);
1808
+ }, S = o(null), [C, w] = s(e.label), T = !!e.readonly;
1795
1809
  i(() => {
1796
1810
  a && (w(e.label), requestAnimationFrame(() => {
1797
1811
  S.current?.focus(), S.current?.select();
1798
1812
  }));
1799
1813
  }, [a, e.label]);
1800
- let T = n(() => {
1814
+ let E = n(() => {
1801
1815
  let t = C.trim();
1802
1816
  t && t !== e.label ? l(e.id, t) : u();
1803
1817
  }, [
@@ -1829,32 +1843,43 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1829
1843
  onClick: () => {
1830
1844
  a || d?.(e.id);
1831
1845
  },
1832
- children: a ? /* @__PURE__ */ (0, X.jsx)(N, {
1846
+ children: a ? /* @__PURE__ */ (0, X.jsx)(P, {
1833
1847
  ref: S,
1834
1848
  value: C,
1835
1849
  onChange: (e) => w(e.target.value),
1836
- onBlur: T,
1850
+ onBlur: E,
1837
1851
  onKeyDown: (e) => {
1838
- e.key === "Enter" ? (e.preventDefault(), T()) : e.key === "Escape" && (e.preventDefault(), u());
1852
+ e.key === "Enter" ? (e.preventDefault(), E()) : e.key === "Escape" && (e.preventDefault(), u());
1839
1853
  },
1840
1854
  onClick: (e) => e.stopPropagation(),
1841
1855
  className: "h-7 text-sm",
1842
1856
  "data-testid": `manage-views-rename-input-${e.id}`
1843
1857
  }) : /* @__PURE__ */ (0, X.jsxs)("button", {
1844
1858
  type: "button",
1845
- className: "w-full text-left text-sm font-medium truncate cursor-pointer",
1859
+ className: "w-full text-left text-sm font-medium truncate cursor-pointer flex items-center gap-1.5",
1846
1860
  onDoubleClick: (t) => {
1847
- t.stopPropagation(), c(e.id);
1861
+ t.stopPropagation(), T || c(e.id);
1848
1862
  },
1849
1863
  title: e.label,
1850
- children: [e.label, e.isDefault && /* @__PURE__ */ (0, X.jsxs)("span", {
1851
- className: "ml-2 inline-flex items-center text-[10px] uppercase tracking-wide text-muted-foreground",
1852
- title: "Default view",
1853
- children: [/* @__PURE__ */ (0, X.jsx)(Je, { className: "h-3 w-3 mr-0.5 fill-current" }), " default"]
1854
- })]
1864
+ children: [
1865
+ /* @__PURE__ */ (0, X.jsx)("span", {
1866
+ className: "truncate",
1867
+ children: e.label
1868
+ }),
1869
+ T && /* @__PURE__ */ (0, X.jsx)(Ie, {
1870
+ "aria-label": "Read-only view",
1871
+ "data-testid": `manage-views-readonly-${e.id}`,
1872
+ className: "h-3 w-3 text-muted-foreground shrink-0"
1873
+ }),
1874
+ e.isDefault && /* @__PURE__ */ (0, X.jsxs)("span", {
1875
+ className: "ml-1 inline-flex items-center text-[10px] uppercase tracking-wide text-muted-foreground",
1876
+ title: "Default view",
1877
+ children: [/* @__PURE__ */ (0, X.jsx)(Ye, { className: "h-3 w-3 mr-0.5 fill-current" }), " default"]
1878
+ })
1879
+ ]
1855
1880
  })
1856
1881
  }),
1857
- h && !a && /* @__PURE__ */ (0, X.jsx)(G, {
1882
+ h && !a && !T && /* @__PURE__ */ (0, X.jsx)(G, {
1858
1883
  delayDuration: 300,
1859
1884
  children: /* @__PURE__ */ (0, X.jsxs)(U, { children: [/* @__PURE__ */ (0, X.jsx)(K, {
1860
1885
  asChild: !0,
@@ -1866,14 +1891,14 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1866
1891
  t.stopPropagation(), h(e.id, !e.isPinned);
1867
1892
  },
1868
1893
  className: q("shrink-0 h-7 w-7 inline-flex items-center justify-center rounded hover:bg-accent transition-colors", e.isPinned ? "text-amber-500" : "text-muted-foreground/40 opacity-0 group-hover/row:opacity-100"),
1869
- children: e.isPinned ? /* @__PURE__ */ (0, X.jsx)(Y, { className: "h-4 w-4 fill-current" }) : /* @__PURE__ */ (0, X.jsx)(Y, { className: "h-4 w-4" })
1894
+ children: e.isPinned ? /* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 fill-current" }) : /* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4" })
1870
1895
  })
1871
1896
  }), /* @__PURE__ */ (0, X.jsx)(W, {
1872
1897
  side: "top",
1873
1898
  children: e.isPinned ? "Unpin view" : "Pin view"
1874
1899
  })] })
1875
1900
  }),
1876
- m && !a && !e.isDefault && /* @__PURE__ */ (0, X.jsx)(G, {
1901
+ m && !a && !e.isDefault && !T && /* @__PURE__ */ (0, X.jsx)(G, {
1877
1902
  delayDuration: 300,
1878
1903
  children: /* @__PURE__ */ (0, X.jsxs)(U, { children: [/* @__PURE__ */ (0, X.jsx)(K, {
1879
1904
  asChild: !0,
@@ -1885,7 +1910,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1885
1910
  t.stopPropagation(), m(e.id);
1886
1911
  },
1887
1912
  className: "shrink-0 h-7 w-7 inline-flex items-center justify-center rounded hover:bg-accent text-muted-foreground/40 hover:text-foreground opacity-0 group-hover/row:opacity-100 transition-colors",
1888
- children: /* @__PURE__ */ (0, X.jsx)(Je, { className: "h-4 w-4" })
1913
+ children: /* @__PURE__ */ (0, X.jsx)(Ye, { className: "h-4 w-4" })
1889
1914
  })
1890
1915
  }), /* @__PURE__ */ (0, X.jsx)(W, {
1891
1916
  side: "top",
@@ -1906,7 +1931,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1906
1931
  align: "end",
1907
1932
  className: "min-w-[180px]",
1908
1933
  children: [
1909
- /* @__PURE__ */ (0, X.jsxs)(j, {
1934
+ !T && /* @__PURE__ */ (0, X.jsxs)(j, {
1910
1935
  "data-testid": `manage-views-action-rename-${e.id}`,
1911
1936
  onClick: () => c(e.id),
1912
1937
  children: [/* @__PURE__ */ (0, X.jsx)(ze, { className: "h-4 w-4 mr-2" }), " Rename"]
@@ -1914,28 +1939,28 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1914
1939
  p && /* @__PURE__ */ (0, X.jsxs)(j, {
1915
1940
  "data-testid": `manage-views-action-duplicate-${e.id}`,
1916
1941
  onClick: () => p(e.id),
1917
- children: [/* @__PURE__ */ (0, X.jsx)(we, { className: "h-4 w-4 mr-2" }), " Duplicate"]
1942
+ children: [/* @__PURE__ */ (0, X.jsx)(Te, { className: "h-4 w-4 mr-2" }), " Duplicate"]
1918
1943
  }),
1919
- g && /* @__PURE__ */ (0, X.jsxs)(j, {
1944
+ g && !T && /* @__PURE__ */ (0, X.jsxs)(j, {
1920
1945
  "data-testid": `manage-views-action-config-${e.id}`,
1921
1946
  onClick: () => g(e.id),
1922
1947
  children: [/* @__PURE__ */ (0, X.jsx)(ze, { className: "h-4 w-4 mr-2" }), " Edit configuration…"]
1923
1948
  }),
1924
- m && !e.isDefault && /* @__PURE__ */ (0, X.jsxs)(j, {
1949
+ m && !e.isDefault && !T && /* @__PURE__ */ (0, X.jsxs)(j, {
1925
1950
  "data-testid": `manage-views-action-default-${e.id}`,
1926
1951
  onClick: () => m(e.id),
1927
- children: [/* @__PURE__ */ (0, X.jsx)(Je, { className: "h-4 w-4 mr-2" }), " Set as default"]
1952
+ children: [/* @__PURE__ */ (0, X.jsx)(Ye, { className: "h-4 w-4 mr-2" }), " Set as default"]
1928
1953
  }),
1929
- h && /* @__PURE__ */ (0, X.jsx)(j, {
1954
+ h && !T && /* @__PURE__ */ (0, X.jsx)(j, {
1930
1955
  "data-testid": `manage-views-action-pin-${e.id}`,
1931
1956
  onClick: () => h(e.id, !e.isPinned),
1932
- children: e.isPinned ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 mr-2" }), " Unpin"] }) : /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Y, { className: "h-4 w-4 mr-2" }), " Pin"] })
1957
+ children: e.isPinned ? /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-4 w-4 mr-2" }), " Unpin"] }) : /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(Be, { className: "h-4 w-4 mr-2" }), " Pin"] })
1933
1958
  }),
1934
- f && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(M, {}), /* @__PURE__ */ (0, X.jsxs)(j, {
1959
+ f && !T && /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [/* @__PURE__ */ (0, X.jsx)(M, {}), /* @__PURE__ */ (0, X.jsxs)(j, {
1935
1960
  "data-testid": `manage-views-action-delete-${e.id}`,
1936
1961
  onClick: () => f(e.id),
1937
1962
  className: "text-destructive focus:text-destructive",
1938
- children: [/* @__PURE__ */ (0, X.jsx)(Xe, { className: "h-4 w-4 mr-2" }), " Delete"]
1963
+ children: [/* @__PURE__ */ (0, X.jsx)(Ze, { className: "h-4 w-4 mr-2" }), " Delete"]
1939
1964
  })] })
1940
1965
  ]
1941
1966
  })] }),
@@ -1945,21 +1970,21 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1945
1970
  type: "button",
1946
1971
  "aria-label": "Save name",
1947
1972
  onMouseDown: (e) => e.preventDefault(),
1948
- onClick: T,
1973
+ onClick: E,
1949
1974
  className: "h-7 w-7 inline-flex items-center justify-center rounded hover:bg-accent text-emerald-600",
1950
- children: /* @__PURE__ */ (0, X.jsx)(Se, { className: "h-4 w-4" })
1975
+ children: /* @__PURE__ */ (0, X.jsx)(Ce, { className: "h-4 w-4" })
1951
1976
  }), /* @__PURE__ */ (0, X.jsx)("button", {
1952
1977
  type: "button",
1953
1978
  "aria-label": "Cancel rename",
1954
1979
  onMouseDown: (e) => e.preventDefault(),
1955
1980
  onClick: u,
1956
1981
  className: "h-7 w-7 inline-flex items-center justify-center rounded hover:bg-accent text-muted-foreground",
1957
- children: /* @__PURE__ */ (0, X.jsx)(Ze, { className: "h-4 w-4" })
1982
+ children: /* @__PURE__ */ (0, X.jsx)(Qe, { className: "h-4 w-4" })
1958
1983
  })]
1959
1984
  })
1960
1985
  ]
1961
1986
  });
1962
- }, en = ({ open: e, onOpenChange: t, views: n, activeViewId: r, viewTypeIcons: o = {}, onRename: c, onDelete: l, onDuplicate: u, onSetDefault: d, onSetPinned: f, onReorder: p, onAddView: m, onConfigView: g }) => {
1987
+ }, tn = ({ open: e, onOpenChange: t, views: n, activeViewId: r, viewTypeIcons: o = {}, onRename: c, onDelete: l, onDuplicate: u, onSetDefault: d, onSetPinned: f, onReorder: p, onAddView: m, onConfigView: g }) => {
1963
1988
  let [_, v] = s(""), [ee, y] = s(null), [b, te] = s(() => n.map((e) => e.id));
1964
1989
  i(() => {
1965
1990
  te(n.map((e) => e.id));
@@ -1973,12 +1998,12 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1973
1998
  if (!_.trim()) return x;
1974
1999
  let e = _.toLowerCase();
1975
2000
  return x.filter((t) => t.label.toLowerCase().includes(e));
1976
- }, [x, _]), C = it(rt(tt, { activationConstraint: { distance: 5 } }), rt(et, { coordinateGetter: ct })), O = (e) => {
2001
+ }, [x, _]), C = at(it(nt, { activationConstraint: { distance: 5 } }), it(tt, { coordinateGetter: lt })), O = (e) => {
1977
2002
  let { active: t, over: n } = e;
1978
2003
  if (!n || t.id === n.id) return;
1979
2004
  let r = b.indexOf(String(t.id)), i = b.indexOf(String(n.id));
1980
2005
  if (r < 0 || i < 0) return;
1981
- let a = ot(b, r, i);
2006
+ let a = st(b, r, i);
1982
2007
  te(a), p?.(a);
1983
2008
  }, ie = (e) => {
1984
2009
  t(!1), requestAnimationFrame(() => g?.(e));
@@ -1990,9 +2015,9 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
1990
2015
  className: "sm:max-w-[560px] p-0 gap-0 overflow-hidden",
1991
2016
  "data-testid": "manage-views-dialog",
1992
2017
  children: [
1993
- /* @__PURE__ */ (0, X.jsxs)(re, {
2018
+ /* @__PURE__ */ (0, X.jsxs)(ne, {
1994
2019
  className: "px-5 pt-5 pb-3",
1995
- children: [/* @__PURE__ */ (0, X.jsx)(D, {
2020
+ children: [/* @__PURE__ */ (0, X.jsx)(re, {
1996
2021
  className: "text-base",
1997
2022
  children: "Manage views"
1998
2023
  }), /* @__PURE__ */ (0, X.jsx)(E, {
@@ -2004,7 +2029,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2004
2029
  className: "px-5 pb-3",
2005
2030
  children: /* @__PURE__ */ (0, X.jsxs)("div", {
2006
2031
  className: "relative",
2007
- children: [/* @__PURE__ */ (0, X.jsx)(Ue, { className: "absolute left-2.5 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground pointer-events-none" }), /* @__PURE__ */ (0, X.jsx)(N, {
2032
+ children: [/* @__PURE__ */ (0, X.jsx)(We, { className: "absolute left-2.5 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground pointer-events-none" }), /* @__PURE__ */ (0, X.jsx)(P, {
2008
2033
  value: _,
2009
2034
  onChange: (e) => v(e.target.value),
2010
2035
  placeholder: "Search views",
@@ -2019,18 +2044,18 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2019
2044
  children: S.length === 0 ? /* @__PURE__ */ (0, X.jsx)("div", {
2020
2045
  className: "text-center text-sm text-muted-foreground py-10",
2021
2046
  children: "No views match your search."
2022
- }) : /* @__PURE__ */ (0, X.jsx)($e, {
2047
+ }) : /* @__PURE__ */ (0, X.jsx)(et, {
2023
2048
  sensors: C,
2024
- collisionDetection: nt,
2049
+ collisionDetection: rt,
2025
2050
  onDragEnd: O,
2026
- children: /* @__PURE__ */ (0, X.jsx)(at, {
2051
+ children: /* @__PURE__ */ (0, X.jsx)(ot, {
2027
2052
  items: S.map((e) => e.id),
2028
- strategy: ut,
2053
+ strategy: dt,
2029
2054
  children: /* @__PURE__ */ (0, X.jsx)("ul", {
2030
2055
  className: "space-y-0.5",
2031
- children: S.map((e) => /* @__PURE__ */ (0, X.jsx)($t, {
2056
+ children: S.map((e) => /* @__PURE__ */ (0, X.jsx)(en, {
2032
2057
  view: e,
2033
- Icon: o[e.type] || Qt,
2058
+ Icon: o[e.type] || $t,
2034
2059
  isActive: e.id === r,
2035
2060
  isRenaming: ee === e.id,
2036
2061
  onStartRename: (e) => y(e),
@@ -2048,7 +2073,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2048
2073
  })
2049
2074
  })
2050
2075
  }),
2051
- /* @__PURE__ */ (0, X.jsxs)(ne, {
2076
+ /* @__PURE__ */ (0, X.jsxs)(D, {
2052
2077
  className: "border-t bg-muted/30 px-5 py-3 flex sm:justify-between gap-2",
2053
2078
  children: [m ? /* @__PURE__ */ (0, X.jsxs)(h, {
2054
2079
  variant: "ghost",
@@ -2058,7 +2083,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2058
2083
  },
2059
2084
  "data-testid": "manage-views-add",
2060
2085
  className: "text-sm",
2061
- children: [/* @__PURE__ */ (0, X.jsx)(Ve, { className: "h-4 w-4 mr-1.5" }), " Add new view"]
2086
+ children: [/* @__PURE__ */ (0, X.jsx)(He, { className: "h-4 w-4 mr-1.5" }), " Add new view"]
2062
2087
  }) : /* @__PURE__ */ (0, X.jsx)("span", {}), /* @__PURE__ */ (0, X.jsx)(h, {
2063
2088
  size: "sm",
2064
2089
  onClick: () => t(!1),
@@ -2069,7 +2094,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2069
2094
  ]
2070
2095
  })
2071
2096
  });
2072
- }, tn = {
2097
+ }, nn = {
2073
2098
  "=": "equals",
2074
2099
  "==": "equals",
2075
2100
  "!=": "notEquals",
@@ -2098,7 +2123,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2098
2123
  isEmpty: "isEmpty",
2099
2124
  isNotEmpty: "isNotEmpty",
2100
2125
  notIn: "notIn"
2101
- }, nn = {
2126
+ }, rn = {
2102
2127
  equals: "=",
2103
2128
  notEquals: "!=",
2104
2129
  greaterThan: ">",
@@ -2115,7 +2140,7 @@ var qt = ({ objectName: t, viewId: n = "default", baseUrl: r, onShare: i, classN
2115
2140
  after: "after",
2116
2141
  between: "between"
2117
2142
  };
2118
- function rn(e) {
2143
+ function an(e) {
2119
2144
  let t = (e || "").toLowerCase();
2120
2145
  return [
2121
2146
  "integer",
@@ -2151,39 +2176,39 @@ function rn(e) {
2151
2176
  "owner"
2152
2177
  ].includes(t) ? "select" : "text";
2153
2178
  }
2154
- function an(e) {
2179
+ function on(e) {
2155
2180
  if (!Array.isArray(e) || e.length < 2) return null;
2156
2181
  let [t, n, r] = e;
2157
2182
  return typeof t != "string" || typeof n != "string" ? null : {
2158
2183
  id: crypto.randomUUID(),
2159
2184
  field: t,
2160
- operator: tn[n] || n,
2185
+ operator: nn[n] || n,
2161
2186
  value: r ?? ""
2162
2187
  };
2163
2188
  }
2164
- function on(e) {
2189
+ function sn(e) {
2165
2190
  if (Array.isArray(e)) {
2166
- let t = an(e);
2191
+ let t = on(e);
2167
2192
  return t ? [t] : [];
2168
2193
  }
2169
2194
  return typeof e == "object" && e && e.field ? [{
2170
2195
  id: e.id || crypto.randomUUID(),
2171
2196
  field: e.field,
2172
- operator: tn[e.operator] || e.operator || "equals",
2197
+ operator: nn[e.operator] || e.operator || "equals",
2173
2198
  value: e.value ?? ""
2174
2199
  }] : [];
2175
2200
  }
2176
- function sn(e) {
2201
+ function cn(e) {
2177
2202
  if (!Array.isArray(e) || e.length === 0) return {
2178
2203
  logic: "and",
2179
2204
  conditions: []
2180
2205
  };
2181
2206
  if (typeof e[0] == "string" && (e[0] === "and" || e[0] === "or")) return {
2182
2207
  logic: e[0],
2183
- conditions: e.slice(1).flatMap((e) => on(e))
2208
+ conditions: e.slice(1).flatMap((e) => sn(e))
2184
2209
  };
2185
2210
  if (e.length >= 2 && e.length <= 3 && typeof e[0] == "string" && typeof e[1] == "string" && !Array.isArray(e[0]) && !Array.isArray(e[2])) {
2186
- let t = an(e);
2211
+ let t = on(e);
2187
2212
  return {
2188
2213
  logic: "and",
2189
2214
  conditions: t ? [t] : []
@@ -2191,29 +2216,29 @@ function sn(e) {
2191
2216
  }
2192
2217
  if (Array.isArray(e[0]) || typeof e[0] == "object" && e[0] !== null && !Array.isArray(e[0])) return {
2193
2218
  logic: "and",
2194
- conditions: e.flatMap((e) => on(e))
2219
+ conditions: e.flatMap((e) => sn(e))
2195
2220
  };
2196
- let t = an(e);
2221
+ let t = on(e);
2197
2222
  return {
2198
2223
  logic: "and",
2199
2224
  conditions: t ? [t] : []
2200
2225
  };
2201
2226
  }
2202
- function cn(e, t) {
2227
+ function ln(e, t) {
2203
2228
  let n = t.filter((e) => e.field).map((e) => [
2204
2229
  e.field,
2205
- nn[e.operator] || e.operator,
2230
+ rn[e.operator] || e.operator,
2206
2231
  e.value
2207
2232
  ]);
2208
2233
  return n.length === 0 ? [] : n.length === 1 && e === "and" ? n[0] : e === "or" ? ["or", ...n] : n;
2209
2234
  }
2210
- function ln(e) {
2235
+ function un(e) {
2211
2236
  return e.split(",").map((e) => e.trim()).filter(Boolean);
2212
2237
  }
2213
- function un(e) {
2238
+ function dn(e) {
2214
2239
  return e.split(",").map((e) => Number(e.trim())).filter((e) => !isNaN(e) && e > 0);
2215
2240
  }
2216
- var dn = {
2241
+ var fn = {
2217
2242
  grid: "Grid",
2218
2243
  kanban: "Kanban",
2219
2244
  calendar: "Calendar",
@@ -2222,7 +2247,7 @@ var dn = {
2222
2247
  gantt: "Gantt",
2223
2248
  map: "Map",
2224
2249
  chart: "Chart"
2225
- }, fn = Object.keys(dn), pn = [
2250
+ }, pn = Object.keys(fn), mn = [
2226
2251
  {
2227
2252
  value: "compact",
2228
2253
  gapClass: "gap-0"
@@ -2244,23 +2269,23 @@ var dn = {
2244
2269
  gapClass: "gap-1.5"
2245
2270
  }
2246
2271
  ];
2247
- function mn(e) {
2272
+ function hn(e) {
2248
2273
  return e.fields ? Object.entries(e.fields).map(([e, t]) => ({
2249
2274
  value: e,
2250
2275
  label: t.label || e,
2251
- type: rn(t.type),
2276
+ type: an(t.type),
2252
2277
  options: t.options
2253
2278
  })) : [];
2254
2279
  }
2255
- function hn(e) {
2256
- let t = sn(e);
2280
+ function gn(e) {
2281
+ let t = cn(e);
2257
2282
  return {
2258
2283
  id: "root",
2259
2284
  logic: t.logic,
2260
2285
  conditions: t.conditions
2261
2286
  };
2262
2287
  }
2263
- function gn(e) {
2288
+ function _n(e) {
2264
2289
  return (Array.isArray(e) ? e : []).map((e) => ({
2265
2290
  id: e.id || crypto.randomUUID(),
2266
2291
  field: e.field || "",
@@ -2273,13 +2298,13 @@ function Z({ renderSummary: e, children: n }) {
2273
2298
  let [r, i] = t.useState(!1);
2274
2299
  return /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [e(() => i((e) => !e)), r && n] });
2275
2300
  }
2276
- var _n = 5;
2277
- function vn({ colName: e, label: t, idx: n, total: r, onToggle: i, onMove: a }) {
2278
- let { attributes: o, listeners: s, setNodeRef: c, transform: l, transition: u, isDragging: d } = lt({ id: e });
2301
+ var vn = 5;
2302
+ function yn({ colName: e, label: t, idx: n, total: r, onToggle: i, onMove: a }) {
2303
+ let { attributes: o, listeners: s, setNodeRef: c, transform: l, transition: u, isDragging: d } = ut({ id: e });
2279
2304
  return /* @__PURE__ */ (0, X.jsxs)("div", {
2280
2305
  ref: c,
2281
2306
  style: {
2282
- transform: dt.Transform.toString(l),
2307
+ transform: ft.Transform.toString(l),
2283
2308
  transition: u,
2284
2309
  zIndex: d ? 10 : void 0,
2285
2310
  opacity: d ? .5 : void 0
@@ -2301,7 +2326,7 @@ function vn({ colName: e, label: t, idx: n, total: r, onToggle: i, onMove: a })
2301
2326
  className: "h-5 w-5 flex items-center justify-center rounded hover:bg-accent shrink-0",
2302
2327
  onClick: () => i(e, !1),
2303
2328
  "aria-label": `Hide ${t}`,
2304
- children: /* @__PURE__ */ (0, X.jsx)(Te, { className: "h-3.5 w-3.5 text-primary" })
2329
+ children: /* @__PURE__ */ (0, X.jsx)(Y, { className: "h-3.5 w-3.5 text-primary" })
2305
2330
  }),
2306
2331
  /* @__PURE__ */ (0, X.jsx)("span", {
2307
2332
  className: "truncate flex-1",
@@ -2328,20 +2353,20 @@ function vn({ colName: e, label: t, idx: n, total: r, onToggle: i, onMove: a })
2328
2353
  ]
2329
2354
  });
2330
2355
  }
2331
- function yn({ columns: e, fieldOptions: n, onToggle: r, onMove: i, onReorder: a }) {
2332
- return /* @__PURE__ */ (0, X.jsx)($e, {
2333
- sensors: it(rt(tt, { activationConstraint: { distance: _n } }), rt(et)),
2334
- collisionDetection: nt,
2356
+ function bn({ columns: e, fieldOptions: n, onToggle: r, onMove: i, onReorder: a }) {
2357
+ return /* @__PURE__ */ (0, X.jsx)(et, {
2358
+ sensors: at(it(nt, { activationConstraint: { distance: vn } }), it(tt)),
2359
+ collisionDetection: rt,
2335
2360
  onDragEnd: t.useCallback((t) => {
2336
2361
  let { active: n, over: r } = t;
2337
2362
  if (!r || n.id === r.id) return;
2338
2363
  let i = e.indexOf(String(n.id)), o = e.indexOf(String(r.id));
2339
- i === -1 || o === -1 || a(ot(e, i, o));
2364
+ i === -1 || o === -1 || a(st(e, i, o));
2340
2365
  }, [e, a]),
2341
- children: /* @__PURE__ */ (0, X.jsx)(at, {
2366
+ children: /* @__PURE__ */ (0, X.jsx)(ot, {
2342
2367
  items: e,
2343
- strategy: ut,
2344
- children: e.map((t, a) => /* @__PURE__ */ (0, X.jsx)(vn, {
2368
+ strategy: dt,
2369
+ children: e.map((t, a) => /* @__PURE__ */ (0, X.jsx)(yn, {
2345
2370
  colName: t,
2346
2371
  label: n.find((e) => e.value === t)?.label || t,
2347
2372
  idx: a,
@@ -2352,7 +2377,7 @@ function yn({ columns: e, fieldOptions: n, onToggle: r, onMove: i, onReorder: a
2352
2377
  })
2353
2378
  });
2354
2379
  }
2355
- var bn = [
2380
+ var xn = [
2356
2381
  "general",
2357
2382
  "data",
2358
2383
  "appearance",
@@ -2360,21 +2385,21 @@ var bn = [
2360
2385
  "userActions",
2361
2386
  "navigation",
2362
2387
  "exportPrint"
2363
- ], xn = [
2388
+ ], Sn = [
2364
2389
  "general",
2365
2390
  "data",
2366
2391
  "appearance"
2367
- ], Q = (e) => e.type == null || e.type === "grid", Sn = (e) => e.type == null || [
2392
+ ], Q = (e) => e.type == null || e.type === "grid", Cn = (e) => e.type == null || [
2368
2393
  "grid",
2369
2394
  "kanban",
2370
2395
  "gallery"
2371
- ].includes(e.type), Cn = (e) => e.type == null || [
2396
+ ].includes(e.type), wn = (e) => e.type == null || [
2372
2397
  "grid",
2373
2398
  "calendar",
2374
2399
  "timeline",
2375
2400
  "gantt"
2376
- ].includes(e.type), wn = (e) => e.type == null || ["grid", "kanban"].includes(e.type), Tn = (e) => e.type == null || ["grid", "kanban"].includes(e.type), En = (e) => e.type == null || ["grid", "gallery"].includes(e.type);
2377
- function Dn(e) {
2401
+ ].includes(e.type), Tn = (e) => e.type == null || ["grid", "kanban"].includes(e.type), En = (e) => e.type == null || ["grid", "kanban"].includes(e.type), Dn = (e) => e.type == null || ["grid", "gallery"].includes(e.type);
2402
+ function On(e) {
2378
2403
  let { t, fieldOptions: n, objectDef: r, updateField: i, filterGroupValue: a, sortItemsValue: o, essentialOnly: s = !1 } = e, c = n.map((e) => ({
2379
2404
  value: e.value,
2380
2405
  label: e.label
@@ -2382,17 +2407,17 @@ function Dn(e) {
2382
2407
  value: "",
2383
2408
  label: t("console.objectView.none")
2384
2409
  }, ...c], u = [
2385
- On(t, r),
2386
- kn(t),
2387
- An(t, i),
2410
+ kn(t, r),
2411
+ An(t),
2388
2412
  jn(t, i),
2389
2413
  Mn(t, i),
2390
- Nn(t, n, l, r, i, a, o),
2391
- Pn(t, n, l, i),
2392
- Fn(t, i),
2414
+ Nn(t, i),
2415
+ Pn(t, n, l, r, i, a, o),
2416
+ Fn(t, n, l, i),
2393
2417
  In(t, i),
2394
- Ln(t, i)
2395
- ], d = s ? u.filter((e) => bn.includes(e.key)).map((e) => xn.includes(e.key) ? e : {
2418
+ Ln(t, i),
2419
+ Rn(t, i)
2420
+ ], d = s ? u.filter((e) => xn.includes(e.key)).map((e) => Sn.includes(e.key) ? e : {
2396
2421
  ...e,
2397
2422
  collapsible: !0,
2398
2423
  defaultCollapsed: !0
@@ -2402,7 +2427,7 @@ function Dn(e) {
2402
2427
  sections: d
2403
2428
  };
2404
2429
  }
2405
- function On(e, t) {
2430
+ function kn(e, t) {
2406
2431
  return {
2407
2432
  key: "general",
2408
2433
  title: e("console.objectView.general"),
@@ -2414,7 +2439,7 @@ function On(e, t) {
2414
2439
  type: "custom",
2415
2440
  render: (t, n) => /* @__PURE__ */ (0, X.jsx)(_, {
2416
2441
  label: e("console.objectView.title"),
2417
- children: /* @__PURE__ */ (0, X.jsx)(N, {
2442
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
2418
2443
  "data-testid": "view-title-input",
2419
2444
  className: "h-7 text-xs w-32 text-right",
2420
2445
  value: t || "",
@@ -2428,7 +2453,7 @@ function On(e, t) {
2428
2453
  type: "custom",
2429
2454
  render: (n, r) => /* @__PURE__ */ (0, X.jsx)(_, {
2430
2455
  label: e("console.objectView.description"),
2431
- children: /* @__PURE__ */ (0, X.jsx)(N, {
2456
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
2432
2457
  "data-testid": "view-description-input",
2433
2458
  className: "h-7 text-xs w-32 text-right",
2434
2459
  value: n ?? "",
@@ -2448,9 +2473,9 @@ function On(e, t) {
2448
2473
  className: "text-xs h-7 rounded-md border border-input bg-background px-2 text-foreground",
2449
2474
  value: t || "grid",
2450
2475
  onChange: (e) => n(e.target.value),
2451
- children: fn.map((e) => /* @__PURE__ */ (0, X.jsx)("option", {
2476
+ children: pn.map((e) => /* @__PURE__ */ (0, X.jsx)("option", {
2452
2477
  value: e,
2453
- children: dn[e]
2478
+ children: fn[e]
2454
2479
  }, e))
2455
2480
  })
2456
2481
  })
@@ -2458,7 +2483,7 @@ function On(e, t) {
2458
2483
  ]
2459
2484
  };
2460
2485
  }
2461
- function kn(e) {
2486
+ function An(e) {
2462
2487
  let t = [
2463
2488
  "showSearch",
2464
2489
  "showSort",
@@ -2498,13 +2523,13 @@ function kn(e) {
2498
2523
  $("showSort", e("console.objectView.enableSort"), "toggle-showSort", !0),
2499
2524
  $("showFilters", e("console.objectView.enableFilter"), "toggle-showFilters", !0),
2500
2525
  $("showHideFields", e("console.objectView.enableHideFields"), "toggle-showHideFields", !0),
2501
- $("showGroup", e("console.objectView.enableGroup"), "toggle-showGroup", !0, !1, void 0, Sn),
2502
- $("showColor", e("console.objectView.enableColor"), "toggle-showColor", !0, !1, void 0, Cn),
2526
+ $("showGroup", e("console.objectView.enableGroup"), "toggle-showGroup", !0, !1, void 0, Cn),
2527
+ $("showColor", e("console.objectView.enableColor"), "toggle-showColor", !0, !1, void 0, wn),
2503
2528
  $("showDensity", e("console.objectView.enableDensity"), "toggle-showDensity", !0, !1, void 0, Q)
2504
2529
  ]
2505
2530
  };
2506
2531
  }
2507
- function An(e, t) {
2532
+ function jn(e, t) {
2508
2533
  return {
2509
2534
  key: "navigation",
2510
2535
  title: e("console.objectView.navigationSection"),
@@ -2579,7 +2604,7 @@ function An(e, t) {
2579
2604
  let a = i.navigation?.mode || "page";
2580
2605
  return /* @__PURE__ */ (0, X.jsx)(_, {
2581
2606
  label: e("console.objectView.navigationWidth"),
2582
- children: /* @__PURE__ */ (0, X.jsx)(N, {
2607
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
2583
2608
  "data-testid": "input-navigation-width",
2584
2609
  className: "h-7 text-xs w-24 text-right",
2585
2610
  value: i.navigation?.width ?? "",
@@ -2619,7 +2644,7 @@ function An(e, t) {
2619
2644
  ]
2620
2645
  };
2621
2646
  }
2622
- function jn(e, t) {
2647
+ function Mn(e, t) {
2623
2648
  return {
2624
2649
  key: "records",
2625
2650
  title: e("console.objectView.records"),
@@ -2722,7 +2747,7 @@ function jn(e, t) {
2722
2747
  }),
2723
2748
  /* @__PURE__ */ (0, X.jsx)(_, {
2724
2749
  label: e("console.objectView.addRecordFormView"),
2725
- children: /* @__PURE__ */ (0, X.jsx)(N, {
2750
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
2726
2751
  "data-testid": "input-addRecord-formView",
2727
2752
  className: "h-7 text-xs w-24 text-right",
2728
2753
  value: i.addRecord?.formView ?? "",
@@ -2738,7 +2763,7 @@ function jn(e, t) {
2738
2763
  }]
2739
2764
  };
2740
2765
  }
2741
- function Mn(e, t) {
2766
+ function Nn(e, t) {
2742
2767
  return {
2743
2768
  key: "exportPrint",
2744
2769
  title: e("console.objectView.exportPrint"),
@@ -2790,7 +2815,7 @@ function Mn(e, t) {
2790
2815
  }),
2791
2816
  /* @__PURE__ */ (0, X.jsx)(_, {
2792
2817
  label: e("console.objectView.exportMaxRecords"),
2793
- children: /* @__PURE__ */ (0, X.jsx)(N, {
2818
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
2794
2819
  "data-testid": "input-export-maxRecords",
2795
2820
  className: "h-7 text-xs w-20 text-right",
2796
2821
  type: "number",
@@ -2816,7 +2841,7 @@ function Mn(e, t) {
2816
2841
  }),
2817
2842
  /* @__PURE__ */ (0, X.jsx)(_, {
2818
2843
  label: e("console.objectView.exportFileNamePrefix"),
2819
- children: /* @__PURE__ */ (0, X.jsx)(N, {
2844
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
2820
2845
  "data-testid": "input-export-fileNamePrefix",
2821
2846
  className: "h-7 text-xs w-24 text-right",
2822
2847
  value: i.exportOptions?.fileNamePrefix ?? "",
@@ -2835,7 +2860,7 @@ function Mn(e, t) {
2835
2860
  ]
2836
2861
  };
2837
2862
  }
2838
- function Nn(e, t, n, r, i, a, o) {
2863
+ function Pn(e, t, n, r, i, a, o) {
2839
2864
  return {
2840
2865
  key: "data",
2841
2866
  title: e("console.objectView.data"),
@@ -2877,7 +2902,7 @@ function Nn(e, t, n, r, i, a, o) {
2877
2902
  children: [/* @__PURE__ */ (0, X.jsxs)("div", {
2878
2903
  className: "flex items-center gap-1 pb-1",
2879
2904
  children: [
2880
- /* @__PURE__ */ (0, X.jsx)(N, {
2905
+ /* @__PURE__ */ (0, X.jsx)(P, {
2881
2906
  "data-testid": "column-search-input",
2882
2907
  className: "h-6 text-xs flex-1",
2883
2908
  placeholder: e("console.objectView.searchFields"),
@@ -2915,7 +2940,7 @@ function Nn(e, t, n, r, i, a, o) {
2915
2940
  children: [Array.isArray(a.columns) && a.columns.length > 0 && /* @__PURE__ */ (0, X.jsx)("div", {
2916
2941
  "data-testid": "selected-columns",
2917
2942
  className: "space-y-0.5 pb-1 mb-1 border-b border-border/50",
2918
- children: /* @__PURE__ */ (0, X.jsx)(yn, {
2943
+ children: /* @__PURE__ */ (0, X.jsx)(bn, {
2919
2944
  columns: a.columns,
2920
2945
  fieldOptions: t,
2921
2946
  onToggle: c,
@@ -2971,7 +2996,7 @@ function Nn(e, t, n, r, i, a, o) {
2971
2996
  fields: t,
2972
2997
  value: a,
2973
2998
  onChange: (e) => {
2974
- i("filter", cn(e.logic, e.conditions.map((e) => ({
2999
+ i("filter", ln(e.logic, e.conditions.map((e) => ({
2975
3000
  field: e.field,
2976
3001
  operator: e.operator,
2977
3002
  value: e.value
@@ -2999,7 +3024,7 @@ function Nn(e, t, n, r, i, a, o) {
2999
3024
  children: /* @__PURE__ */ (0, X.jsx)("div", {
3000
3025
  "data-testid": "inline-sort-builder",
3001
3026
  className: "pb-2",
3002
- children: /* @__PURE__ */ (0, X.jsx)(V, {
3027
+ children: /* @__PURE__ */ (0, X.jsx)(ge, {
3003
3028
  fields: t.map((e) => ({
3004
3029
  value: e.value,
3005
3030
  label: e.label
@@ -3019,31 +3044,38 @@ function Nn(e, t, n, r, i, a, o) {
3019
3044
  }
3020
3045
  },
3021
3046
  {
3022
- key: "_groupBy",
3047
+ key: "_grouping",
3023
3048
  label: e("console.objectView.groupBy"),
3024
3049
  type: "custom",
3025
- visibleWhen: En,
3050
+ visibleWhen: Dn,
3026
3051
  render: (n, r, a) => {
3027
- let o = a.type || "grid", s = a.kanban?.groupByField || a.kanban?.groupField || a.groupBy || "";
3052
+ let o = Array.isArray(a.grouping?.fields) && a.grouping.fields.length ? { fields: a.grouping.fields.map((e) => ({
3053
+ field: e.field,
3054
+ order: e.order === "desc" ? "desc" : "asc",
3055
+ collapsed: !!e.collapsed
3056
+ })) } : a.groupBy || a.groupBy2 ? { fields: [a.groupBy && {
3057
+ field: a.groupBy,
3058
+ order: "asc",
3059
+ collapsed: !1
3060
+ }, a.groupBy2 && {
3061
+ field: a.groupBy2,
3062
+ order: "asc",
3063
+ collapsed: !1
3064
+ }].filter(Boolean) } : void 0;
3028
3065
  return /* @__PURE__ */ (0, X.jsx)(_, {
3029
3066
  label: e("console.objectView.groupBy"),
3030
- children: /* @__PURE__ */ (0, X.jsxs)("select", {
3031
- "data-testid": "data-groupBy",
3032
- className: "text-xs h-7 rounded-md border border-input bg-background px-2 text-foreground max-w-[120px]",
3033
- value: s,
3034
- onChange: (e) => {
3035
- i("groupBy", e.target.value), o === "kanban" && i("kanban", {
3036
- ...a.kanban || {},
3037
- groupByField: e.target.value
3038
- });
3067
+ children: /* @__PURE__ */ (0, X.jsx)(N, {
3068
+ value: o,
3069
+ fieldOptions: t,
3070
+ maxLevels: 3,
3071
+ labels: {
3072
+ addGroup: e("console.objectView.addGroup", "Add group field"),
3073
+ collapseTitle: e("console.objectView.collapsedByDefault", "Collapsed by default"),
3074
+ removeTitle: e("console.objectView.removeGroup", "Remove")
3039
3075
  },
3040
- children: [/* @__PURE__ */ (0, X.jsx)("option", {
3041
- value: "",
3042
- children: e("console.objectView.none")
3043
- }), t.map((e) => /* @__PURE__ */ (0, X.jsx)("option", {
3044
- value: e.value,
3045
- children: e.label
3046
- }, e.value))]
3076
+ onChange: (e) => {
3077
+ i("grouping", e), i("groupBy", e?.fields?.[0]?.field || void 0), i("groupBy2", e?.fields?.[1]?.field || void 0);
3078
+ }
3047
3079
  })
3048
3080
  });
3049
3081
  }
@@ -3054,7 +3086,7 @@ function Nn(e, t, n, r, i, a, o) {
3054
3086
  type: "custom",
3055
3087
  render: (t, n, r) => /* @__PURE__ */ (0, X.jsx)(_, {
3056
3088
  label: e("console.objectView.pageSize"),
3057
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3089
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3058
3090
  "data-testid": "input-pagination-pageSize",
3059
3091
  className: "h-7 text-xs w-20 text-right",
3060
3092
  type: "number",
@@ -3076,13 +3108,13 @@ function Nn(e, t, n, r, i, a, o) {
3076
3108
  type: "custom",
3077
3109
  render: (t, n, r) => /* @__PURE__ */ (0, X.jsx)(_, {
3078
3110
  label: e("console.objectView.pageSizeOptions"),
3079
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3111
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3080
3112
  "data-testid": "input-pagination-pageSizeOptions",
3081
3113
  className: "h-7 text-xs w-28 text-right",
3082
3114
  value: (r.pagination?.pageSizeOptions || []).join(", "),
3083
3115
  placeholder: "10, 25, 50, 100",
3084
3116
  onChange: (e) => {
3085
- let t = un(e.target.value);
3117
+ let t = dn(e.target.value);
3086
3118
  i("pagination", {
3087
3119
  ...r.pagination || {},
3088
3120
  pageSizeOptions: t.length ? t : void 0
@@ -3091,9 +3123,9 @@ function Nn(e, t, n, r, i, a, o) {
3091
3123
  })
3092
3124
  })
3093
3125
  },
3094
- Rn("searchableFields", e("console.objectView.searchableFields"), "searchable-fields-selector", "searchable-field", t, i, "selected"),
3095
- Rn("filterableFields", e("console.objectView.filterableFields"), "filterable-fields-selector", "filterable-field", t, i, "selected"),
3096
- Rn("hiddenFields", e("console.objectView.hiddenFields"), "hidden-fields-selector", "hidden-field", t, i, "hidden"),
3126
+ zn("searchableFields", e("console.objectView.searchableFields"), "searchable-fields-selector", "searchable-field", t, i, "selected"),
3127
+ zn("filterableFields", e("console.objectView.filterableFields"), "filterable-fields-selector", "filterable-field", t, i, "selected"),
3128
+ zn("hiddenFields", e("console.objectView.hiddenFields"), "hidden-fields-selector", "hidden-field", t, i, "hidden"),
3097
3129
  {
3098
3130
  key: "_quickFilters",
3099
3131
  label: e("console.objectView.quickFilters"),
@@ -3110,7 +3142,7 @@ function Nn(e, t, n, r, i, a, o) {
3110
3142
  children: [(r.quickFilters || []).map((e, t) => /* @__PURE__ */ (0, X.jsxs)("div", {
3111
3143
  className: "flex items-center gap-1 text-xs",
3112
3144
  children: [
3113
- /* @__PURE__ */ (0, X.jsx)(N, {
3145
+ /* @__PURE__ */ (0, X.jsx)(P, {
3114
3146
  "data-testid": `quick-filter-label-${t}`,
3115
3147
  className: "h-6 text-xs flex-1",
3116
3148
  value: e.label || "",
@@ -3272,7 +3304,7 @@ function Nn(e, t, n, r, i, a, o) {
3272
3304
  "data-testid": `uf-tab-${n}`,
3273
3305
  className: "flex items-center gap-1 text-xs",
3274
3306
  children: [
3275
- /* @__PURE__ */ (0, X.jsx)(N, {
3307
+ /* @__PURE__ */ (0, X.jsx)(P, {
3276
3308
  "data-testid": `uf-tab-label-${n}`,
3277
3309
  className: "h-6 text-xs flex-1",
3278
3310
  value: t.label || "",
@@ -3547,7 +3579,7 @@ function Nn(e, t, n, r, i, a, o) {
3547
3579
  ]
3548
3580
  };
3549
3581
  }
3550
- function Pn(e, t, n, r) {
3582
+ function Fn(e, t, n, r) {
3551
3583
  return {
3552
3584
  key: "appearance",
3553
3585
  title: e("console.objectView.appearance"),
@@ -3560,7 +3592,7 @@ function Pn(e, t, n, r) {
3560
3592
  key: "color",
3561
3593
  label: e("console.objectView.color"),
3562
3594
  type: "custom",
3563
- visibleWhen: Cn,
3595
+ visibleWhen: wn,
3564
3596
  render: (n, r) => /* @__PURE__ */ (0, X.jsx)(_, {
3565
3597
  label: e("console.objectView.color"),
3566
3598
  children: /* @__PURE__ */ (0, X.jsxs)("select", {
@@ -3593,7 +3625,7 @@ function Pn(e, t, n, r) {
3593
3625
  "data-testid": "appearance-rowHeight",
3594
3626
  role: "radiogroup",
3595
3627
  "aria-label": e("console.objectView.rowHeight"),
3596
- children: pn.map((e) => /* @__PURE__ */ (0, X.jsx)("button", {
3628
+ children: mn.map((e) => /* @__PURE__ */ (0, X.jsx)("button", {
3597
3629
  type: "button",
3598
3630
  role: "radio",
3599
3631
  "aria-checked": (t || "compact") === e.value,
@@ -3618,7 +3650,7 @@ function Pn(e, t, n, r) {
3618
3650
  key: "_conditionalFormatting",
3619
3651
  label: e("console.objectView.conditionalFormatting"),
3620
3652
  type: "custom",
3621
- visibleWhen: wn,
3653
+ visibleWhen: Tn,
3622
3654
  render: (n, i, a) => /* @__PURE__ */ (0, X.jsx)(Z, {
3623
3655
  renderSummary: (t) => /* @__PURE__ */ (0, X.jsx)(_, {
3624
3656
  label: e("console.objectView.conditionalFormatting"),
@@ -3688,7 +3720,7 @@ function Pn(e, t, n, r) {
3688
3720
  })
3689
3721
  ]
3690
3722
  }),
3691
- /* @__PURE__ */ (0, X.jsx)(N, {
3723
+ /* @__PURE__ */ (0, X.jsx)(P, {
3692
3724
  "data-testid": `cf-value-${n}`,
3693
3725
  className: "h-6 text-xs w-16",
3694
3726
  value: String(e.value ?? ""),
@@ -3734,7 +3766,7 @@ function Pn(e, t, n, r) {
3734
3766
  render: (t, n, i) => /* @__PURE__ */ (0, X.jsxs)(X.Fragment, { children: [
3735
3767
  /* @__PURE__ */ (0, X.jsx)(_, {
3736
3768
  label: e("console.objectView.emptyStateTitle"),
3737
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3769
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3738
3770
  "data-testid": "input-emptyState-title",
3739
3771
  className: "h-7 text-xs w-28 text-right",
3740
3772
  value: i.emptyState?.title ?? "",
@@ -3746,7 +3778,7 @@ function Pn(e, t, n, r) {
3746
3778
  }),
3747
3779
  /* @__PURE__ */ (0, X.jsx)(_, {
3748
3780
  label: e("console.objectView.emptyStateMessage"),
3749
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3781
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3750
3782
  "data-testid": "input-emptyState-message",
3751
3783
  className: "h-7 text-xs w-28 text-right",
3752
3784
  value: i.emptyState?.message ?? "",
@@ -3758,7 +3790,7 @@ function Pn(e, t, n, r) {
3758
3790
  }),
3759
3791
  /* @__PURE__ */ (0, X.jsx)(_, {
3760
3792
  label: e("console.objectView.emptyStateIcon"),
3761
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3793
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3762
3794
  "data-testid": "input-emptyState-icon",
3763
3795
  className: "h-7 text-xs w-28 text-right",
3764
3796
  value: i.emptyState?.icon ?? "",
@@ -3773,7 +3805,7 @@ function Pn(e, t, n, r) {
3773
3805
  ]
3774
3806
  };
3775
3807
  }
3776
- function Fn(e, t) {
3808
+ function In(e, t) {
3777
3809
  return {
3778
3810
  key: "userActions",
3779
3811
  title: e("console.objectView.userActions"),
@@ -3786,7 +3818,7 @@ function Fn(e, t) {
3786
3818
  key: "_rowActions",
3787
3819
  label: e("console.objectView.rowActions"),
3788
3820
  type: "custom",
3789
- visibleWhen: Tn,
3821
+ visibleWhen: En,
3790
3822
  render: (n, r, i) => /* @__PURE__ */ (0, X.jsx)(Z, {
3791
3823
  renderSummary: (t) => /* @__PURE__ */ (0, X.jsx)(_, {
3792
3824
  label: e("console.objectView.rowActions"),
@@ -3796,13 +3828,13 @@ function Fn(e, t) {
3796
3828
  children: /* @__PURE__ */ (0, X.jsx)("div", {
3797
3829
  "data-testid": "row-actions-selector",
3798
3830
  className: "pb-2 space-y-0.5 max-h-36 overflow-auto",
3799
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3831
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3800
3832
  "data-testid": "input-rowActions",
3801
3833
  className: "h-7 text-xs w-full",
3802
3834
  value: (i.rowActions || []).join(", "),
3803
3835
  placeholder: "edit, delete, duplicate",
3804
3836
  onChange: (e) => {
3805
- t("rowActions", ln(e.target.value));
3837
+ t("rowActions", un(e.target.value));
3806
3838
  }
3807
3839
  })
3808
3840
  })
@@ -3812,7 +3844,7 @@ function Fn(e, t) {
3812
3844
  key: "_bulkActions",
3813
3845
  label: e("console.objectView.bulkActions"),
3814
3846
  type: "custom",
3815
- visibleWhen: Tn,
3847
+ visibleWhen: En,
3816
3848
  render: (n, r, i) => /* @__PURE__ */ (0, X.jsx)(Z, {
3817
3849
  renderSummary: (t) => /* @__PURE__ */ (0, X.jsx)(_, {
3818
3850
  label: e("console.objectView.bulkActions"),
@@ -3822,13 +3854,13 @@ function Fn(e, t) {
3822
3854
  children: /* @__PURE__ */ (0, X.jsx)("div", {
3823
3855
  "data-testid": "bulk-actions-selector",
3824
3856
  className: "pb-2 space-y-0.5 max-h-36 overflow-auto",
3825
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3857
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3826
3858
  "data-testid": "input-bulkActions",
3827
3859
  className: "h-7 text-xs w-full",
3828
3860
  value: (i.bulkActions || []).join(", "),
3829
3861
  placeholder: "delete, export, assign",
3830
3862
  onChange: (e) => {
3831
- t("bulkActions", ln(e.target.value));
3863
+ t("bulkActions", un(e.target.value));
3832
3864
  }
3833
3865
  })
3834
3866
  })
@@ -3837,7 +3869,7 @@ function Fn(e, t) {
3837
3869
  ]
3838
3870
  };
3839
3871
  }
3840
- function In(e, t) {
3872
+ function Ln(e, t) {
3841
3873
  return {
3842
3874
  key: "sharing",
3843
3875
  title: e("console.objectView.sharing"),
@@ -3898,7 +3930,7 @@ function In(e, t) {
3898
3930
  }]
3899
3931
  };
3900
3932
  }
3901
- function Ln(e, t) {
3933
+ function Rn(e, t) {
3902
3934
  return {
3903
3935
  key: "accessibility",
3904
3936
  title: e("console.objectView.accessibility"),
@@ -3911,7 +3943,7 @@ function Ln(e, t) {
3911
3943
  type: "custom",
3912
3944
  render: (n, r, i) => /* @__PURE__ */ (0, X.jsx)(_, {
3913
3945
  label: e("console.objectView.ariaLabel"),
3914
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3946
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3915
3947
  "data-testid": "input-aria-label",
3916
3948
  className: "h-7 text-xs w-28 text-right",
3917
3949
  value: i.aria?.label ?? "",
@@ -3928,7 +3960,7 @@ function Ln(e, t) {
3928
3960
  type: "custom",
3929
3961
  render: (n, r, i) => /* @__PURE__ */ (0, X.jsx)(_, {
3930
3962
  label: e("console.objectView.ariaDescribedBy"),
3931
- children: /* @__PURE__ */ (0, X.jsx)(N, {
3963
+ children: /* @__PURE__ */ (0, X.jsx)(P, {
3932
3964
  "data-testid": "input-aria-describedBy",
3933
3965
  className: "h-7 text-xs w-28 text-right",
3934
3966
  value: i.aria?.describedBy ?? "",
@@ -3992,7 +4024,7 @@ function $(e, t, n, r = !1, i = !1, a, o) {
3992
4024
  })
3993
4025
  };
3994
4026
  }
3995
- function Rn(e, t, n, r, i, a, o, s) {
4027
+ function zn(e, t, n, r, i, a, o, s) {
3996
4028
  return {
3997
4029
  key: `_${e}`,
3998
4030
  label: t,
@@ -4028,11 +4060,11 @@ function Rn(e, t, n, r, i, a, o, s) {
4028
4060
  }
4029
4061
  //#endregion
4030
4062
  //#region src/index.tsx
4031
- var zn = d, Bn = ({ schema: e }) => /* @__PURE__ */ (0, X.jsx)(Ft, {
4063
+ var Bn = d, Vn = ({ schema: e }) => /* @__PURE__ */ (0, X.jsx)(It, {
4032
4064
  schema: e,
4033
- dataSource: r(zn)?.dataSource ?? null
4065
+ dataSource: r(Bn)?.dataSource ?? null
4034
4066
  });
4035
- c.register("object-view", Bn, {
4067
+ c.register("object-view", Vn, {
4036
4068
  namespace: "plugin-view",
4037
4069
  label: "Object View",
4038
4070
  category: "view",
@@ -4138,11 +4170,11 @@ c.register("object-view", Bn, {
4138
4170
  showRefresh: !0,
4139
4171
  showViewSwitcher: !0
4140
4172
  }
4141
- }), c.register("view", Bn, {
4173
+ }), c.register("view", Vn, {
4142
4174
  namespace: "plugin-view",
4143
4175
  label: "View",
4144
4176
  category: "view"
4145
- }), c.register("view-switcher", Nt, {
4177
+ }), c.register("view-switcher", Pt, {
4146
4178
  namespace: "view",
4147
4179
  label: "View Switcher",
4148
4180
  category: "view",
@@ -4221,7 +4253,7 @@ c.register("object-view", Bn, {
4221
4253
  }
4222
4254
  }]
4223
4255
  }
4224
- }), c.register("filter-ui", zt, {
4256
+ }), c.register("filter-ui", Bt, {
4225
4257
  namespace: "view",
4226
4258
  label: "Filter UI",
4227
4259
  category: "view",
@@ -4294,7 +4326,7 @@ c.register("object-view", Bn, {
4294
4326
  }
4295
4327
  ]
4296
4328
  }
4297
- }), c.register("sort-ui", Wt, {
4329
+ }), c.register("sort-ui", Gt, {
4298
4330
  namespace: "view",
4299
4331
  label: "Sort UI",
4300
4332
  category: "view",
@@ -4343,7 +4375,7 @@ c.register("object-view", Bn, {
4343
4375
  direction: "asc"
4344
4376
  }]
4345
4377
  }
4346
- }), c.register("shared-view-link", qt, {
4378
+ }), c.register("shared-view-link", Jt, {
4347
4379
  namespace: "view",
4348
4380
  label: "Shared View Link",
4349
4381
  category: "view",
@@ -4385,4 +4417,4 @@ c.register("object-view", Bn, {
4385
4417
  category: "view"
4386
4418
  });
4387
4419
  //#endregion
4388
- export { bn as ESSENTIAL_SECTION_KEYS, zt as FilterUI, en as ManageViewsDialog, Ft as ObjectView, qt as SharedViewLink, Wt as SortUI, dn as VIEW_TYPE_LABELS, fn as VIEW_TYPE_OPTIONS, Nt as ViewSwitcher, Zt as ViewTabBar, Dn as buildViewConfigSchema, mn as deriveFieldOptions, hn as toFilterGroup, gn as toSortItems };
4420
+ export { xn as ESSENTIAL_SECTION_KEYS, Bt as FilterUI, tn as ManageViewsDialog, It as ObjectView, Jt as SharedViewLink, Gt as SortUI, fn as VIEW_TYPE_LABELS, pn as VIEW_TYPE_OPTIONS, Pt as ViewSwitcher, Qt as ViewTabBar, On as buildViewConfigSchema, hn as deriveFieldOptions, gn as toFilterGroup, _n as toSortItems };