impact-nova 1.7.32 → 1.7.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,123 +1,135 @@
1
- import { jsxs as n, Fragment as H, jsx as t } from "react/jsx-runtime";
2
- import * as i from "react";
3
- import { ChevronDown as be, Star as P, Search as xe, Bookmark as ve, Pencil as ge, Trash2 as ye } from "lucide-react";
4
- import { cn as w } from "../../../lib/utils.js";
5
- import { Popover as Ne, PopoverTrigger as we, PopoverContent as Te } from "../popover.js";
6
- import { Tooltip as J, TooltipTrigger as W, TooltipContent as X } from "../tooltip.js";
7
- import { Button as d } from "../button.js";
8
- import { Badge as B } from "../badge.js";
9
- import { Input as Ve } from "../input.js";
10
- import { Separator as Z } from "../separator.js";
11
- import { Skeleton as O } from "../skeleton.js";
12
- import { Prompt as Ce } from "../prompt.js";
13
- import { useImpactNovaI18n as ke } from "../../../i18n/ImpactNovaI18nContext.js";
14
- function De(h) {
15
- return h.isSystemView ? "system" : h.isDefaultView ? "default" : h.isActive ? "active" : "other";
1
+ import { jsxs as i, Fragment as W, jsx as t } from "react/jsx-runtime";
2
+ import * as n from "react";
3
+ import { ChevronDown as ge, Star as O, Search as ye, Bookmark as Ne, Pencil as we, Trash2 as Te } from "lucide-react";
4
+ import { cn as V } from "../../../lib/utils.js";
5
+ import { Popover as Ve, PopoverTrigger as ke, PopoverContent as Ce } from "../popover.js";
6
+ import { Tooltip as X, TooltipTrigger as Z, TooltipContent as q } from "../tooltip.js";
7
+ import { Button as m } from "../button.js";
8
+ import { Badge as E } from "../badge.js";
9
+ import { Input as De } from "../input.js";
10
+ import { Separator as ee } from "../separator.js";
11
+ import { Skeleton as I } from "../skeleton.js";
12
+ import { Prompt as Se } from "../prompt.js";
13
+ import { useImpactNovaI18n as ze } from "../../../i18n/ImpactNovaI18nContext.js";
14
+ function Me(b) {
15
+ return b.isSystemView ? "system" : b.isDefaultView ? "default" : b.isActive ? "active" : "other";
16
16
  }
17
- const Se = ["default", "active", "system"], Fe = ({
18
- isSaveViewEnabled: h = !0,
19
- views: s,
20
- activeViewSummary: q,
21
- viewTypeOptions: ee,
22
- menuOpen: E,
23
- defaultMenuOpen: te = !1,
24
- onMenuOpenChange: j,
25
- onSearch: T,
26
- isLoadingViews: I = !1,
27
- customListContent: R,
28
- disableApply: ae = !1,
29
- className: ne,
30
- onSaveViewClick: ie,
31
- onApply: le,
32
- onCancel: re,
33
- onEditView: se,
34
- onDeleteView: oe,
35
- onSetDefaultView: _
17
+ const Ae = ["default", "active", "system"], Ye = ({
18
+ isSaveViewEnabled: b = !0,
19
+ views: o,
20
+ activeViewSummary: te,
21
+ viewTypeOptions: ae,
22
+ menuOpen: j,
23
+ defaultMenuOpen: ne = !1,
24
+ onMenuOpenChange: R,
25
+ onSearch: k,
26
+ isLoadingViews: L = !1,
27
+ customListContent: _,
28
+ disableApply: ie = !1,
29
+ className: le,
30
+ onSaveViewClick: re,
31
+ onApply: se,
32
+ onCancel: oe,
33
+ onEditView: de,
34
+ onDeleteView: ce,
35
+ onSetDefaultView: U
36
36
  }) => {
37
- const { t: a } = ke(), V = E !== void 0, [ce, de] = i.useState(
38
- te
39
- ), m = V ? !!E : ce, u = i.useCallback(
37
+ const { t: a } = ze(), C = j !== void 0, [me, y] = n.useState(null), [ue, pe] = n.useState(
38
+ ne
39
+ ), u = C ? !!j : ue, p = n.useCallback(
40
40
  (e) => {
41
- V || de(e), j?.(e);
41
+ C || pe(e), R?.(e);
42
42
  },
43
- [V, j]
44
- ), [b, C] = i.useState("All"), [g, k] = i.useState(""), [L, D] = i.useState("");
45
- i.useEffect(() => {
46
- const e = window.setTimeout(() => D(g), 300);
43
+ [C, R]
44
+ ), [v, D] = n.useState("All"), [N, S] = n.useState(""), [F, z] = n.useState("");
45
+ n.useEffect(() => {
46
+ const e = window.setTimeout(() => z(N), 300);
47
47
  return () => window.clearTimeout(e);
48
- }, [g]), i.useEffect(() => {
49
- T && T(L);
50
- }, [L, T]);
51
- const F = i.useMemo(
52
- () => s.find((e) => e.isActive),
53
- [s]
54
- ), o = F ?? null, Q = q ?? F?.viewName ?? a("dataTable.savedViewsNotApplicable"), [y, S] = i.useState(null), [x, U] = i.useState(null), Y = i.useRef(!1);
55
- i.useEffect(() => {
56
- const e = m && !Y.current;
57
- if (Y.current = m, e) {
58
- const l = s.find((c) => c.isActive);
59
- S(l?.id ?? null), C("All"), k(""), D("");
48
+ }, [N]), n.useEffect(() => {
49
+ k && k(F);
50
+ }, [F, k]);
51
+ const Q = n.useMemo(
52
+ () => o.find((e) => e.isActive),
53
+ [o]
54
+ ), d = Q ?? null, Y = te ?? Q?.viewName ?? a("dataTable.savedViewsNotApplicable"), [w, M] = n.useState(null), [x, $] = n.useState(null), K = n.useRef(!1);
55
+ n.useEffect(() => {
56
+ const e = u && !K.current;
57
+ if (K.current = u, e) {
58
+ const l = o.find((c) => c.isActive);
59
+ M(l?.id ?? null), D("All"), S(""), z("");
60
60
  }
61
- }, [m, s]);
62
- const v = i.useMemo(() => b === "All" ? s : s.filter((e) => e.viewType === b), [s, b]), p = g.trim().toLowerCase(), N = i.useCallback(
61
+ }, [u, o]);
62
+ const g = n.useMemo(() => v === "All" ? o : o.filter((e) => e.viewType === v), [o, v]), f = N.trim().toLowerCase(), T = n.useCallback(
63
63
  (e, l) => l ? (e.viewName ?? "").trim().toLowerCase().includes(l) : !0,
64
64
  []
65
- ), M = i.useMemo(() => {
66
- let e = v;
67
- return p && (e = e.filter((l) => N(l, p))), e;
68
- }, [v, p, N]), f = i.useMemo(() => {
69
- if (v.length === 0) return [];
70
- const e = Object.groupBy(v, De);
71
- return Se.flatMap((l) => {
65
+ ), A = n.useMemo(() => {
66
+ let e = g;
67
+ return f && (e = e.filter((l) => T(l, f))), e;
68
+ }, [g, f, T]), h = n.useMemo(() => {
69
+ if (g.length === 0) return [];
70
+ const e = Object.groupBy(g, Me);
71
+ return Ae.flatMap((l) => {
72
72
  const c = e[l]?.[0];
73
- return c ? p && !N(c, p) ? [] : [c] : [];
73
+ return c ? f && !T(c, f) ? [] : [c] : [];
74
74
  });
75
- }, [v, p, N]), z = i.useMemo(() => {
76
- const e = new Set(f.map((l) => l.id));
77
- return M.filter((l) => !e.has(l.id));
78
- }, [M, f]), $ = y === null ? null : s.find((e) => e.id === y) ?? null, me = () => {
79
- le?.($, { activeView: o }), u(!1);
80
- }, ue = () => {
81
- re?.({ activeView: o, pendingView: $ }), u(!1);
82
- }, pe = (e) => {
83
- u(e), e || (k(""), D(""));
75
+ }, [g, f, T]), P = n.useMemo(() => {
76
+ const e = new Set(h.map((l) => l.id));
77
+ return A.filter((l) => !e.has(l.id));
78
+ }, [A, h]), G = w === null ? null : o.find((e) => e.id === w) ?? null, fe = () => {
79
+ se?.(G, { activeView: d }), p(!1);
80
+ }, he = () => {
81
+ oe?.({ activeView: d, pendingView: G }), p(!1);
82
+ }, be = (e) => {
83
+ p(e), e || (S(""), z(""));
84
84
  };
85
- if (!h)
85
+ if (!b)
86
86
  return null;
87
- const fe = s.length > 0, K = (e, l, c) => {
88
- const A = y === e.id, G = l === "priority" && !!e.isActive, he = l === "list" && !!e.isActive;
89
- return /* @__PURE__ */ n(
87
+ const ve = o.length > 0, H = (e, l, c) => {
88
+ const B = w === e.id, s = me === e.id, J = l === "priority" && !!e.isActive, xe = l === "list" && !!e.isActive;
89
+ return /* @__PURE__ */ i(
90
90
  "div",
91
91
  {
92
92
  role: "button",
93
93
  tabIndex: 0,
94
- className: w(
95
- "mb-1 flex cursor-pointer items-center justify-between rounded-lg px-3 py-2 text-left text-sm font-medium font-['Manrope'] hover:bg-muted",
96
- G && !A && "bg-primary/10 dark:bg-primary/15",
97
- A && "bg-badge-info-muted text-badge-info-foreground",
98
- !A && !G && "text-foreground"
94
+ className: V(
95
+ "mb-1 flex cursor-pointer items-center justify-between rounded-lg px-3 py-2 text-left text-sm font-medium font-['Manrope'] transition-all duration-300 relative overflow-hidden",
96
+ !s && "hover:bg-muted",
97
+ !s && J && !B && "bg-primary/10 dark:bg-primary/15",
98
+ !s && B && "bg-badge-info-muted text-badge-info-foreground",
99
+ !s && !B && !J && "text-foreground",
100
+ s && "pointer-events-none"
99
101
  ),
100
- onClick: () => S(e.id),
102
+ onClick: () => !s && M(e.id),
101
103
  onKeyDown: (r) => {
102
- (r.key === "Enter" || r.key === " ") && (r.preventDefault(), S(e.id));
104
+ (r.key === "Enter" || r.key === " ") && (r.preventDefault(), s || M(e.id));
103
105
  },
104
106
  children: [
105
- /* @__PURE__ */ n(J, { children: [
106
- /* @__PURE__ */ t(W, { asChild: !0, children: /* @__PURE__ */ t(
107
+ s && /* @__PURE__ */ t(
108
+ "div",
109
+ {
110
+ className: "absolute inset-0 bg-gradient-to-r from-muted/80 via-primary/20 to-muted/80 opacity-80 rounded-lg",
111
+ style: {
112
+ animation: "shimmer 1.5s ease-in-out infinite",
113
+ backgroundSize: "200% 100%"
114
+ }
115
+ }
116
+ ),
117
+ /* @__PURE__ */ i(X, { children: [
118
+ /* @__PURE__ */ t(Z, { asChild: !0, children: /* @__PURE__ */ t(
107
119
  "span",
108
120
  {
109
- className: w(
110
- "min-w-0 flex-1 truncate",
111
- he && "underline decoration-primary decoration-2 underline-offset-2"
121
+ className: V(
122
+ "min-w-0 flex-1 truncate relative z-10",
123
+ xe && "underline decoration-primary decoration-2 underline-offset-2"
112
124
  ),
113
125
  children: e.viewName
114
126
  }
115
127
  ) }),
116
- /* @__PURE__ */ t(X, { variant: "tertiary", side: "right", children: e.viewName })
128
+ /* @__PURE__ */ t(q, { variant: "tertiary", side: "right", children: e.viewName })
117
129
  ] }),
118
- /* @__PURE__ */ n("div", { className: "flex shrink-0 items-center gap-0.5", children: [
130
+ /* @__PURE__ */ i("div", { className: "flex shrink-0 items-center gap-0.5 relative z-10", children: [
119
131
  e.isEditable ? /* @__PURE__ */ t(
120
- d,
132
+ m,
121
133
  {
122
134
  type: "button",
123
135
  variant: "ghost",
@@ -125,13 +137,13 @@ const Se = ["default", "active", "system"], Fe = ({
125
137
  className: "text-foreground hover:text-content-charcoal",
126
138
  "aria-label": a("dataTable.savedViewsEdit"),
127
139
  onClick: (r) => {
128
- r.stopPropagation(), r.preventDefault(), u(!1), se?.(e, { activeView: o });
140
+ r.stopPropagation(), r.preventDefault(), p(!1), de?.(e, { activeView: d });
129
141
  },
130
- children: /* @__PURE__ */ t(ge, { className: "size-3.5" })
142
+ children: /* @__PURE__ */ t(we, { className: "size-3.5" })
131
143
  }
132
144
  ) : null,
133
145
  e.isDeletable ? /* @__PURE__ */ t(
134
- d,
146
+ m,
135
147
  {
136
148
  type: "button",
137
149
  variant: "ghost",
@@ -139,36 +151,38 @@ const Se = ["default", "active", "system"], Fe = ({
139
151
  className: "text-foreground hover:text-destructive",
140
152
  "aria-label": a("dataTable.savedViewsDelete"),
141
153
  onClick: (r) => {
142
- r.stopPropagation(), r.preventDefault(), u(!1), U(e);
154
+ r.stopPropagation(), r.preventDefault(), p(!1), $(e);
143
155
  },
144
- children: /* @__PURE__ */ t(ye, { className: "size-3.5" })
156
+ children: /* @__PURE__ */ t(Te, { className: "size-3.5" })
145
157
  }
146
158
  ) : null,
147
159
  e.hideDefaultStar ? null : e.isDefaultView ? /* @__PURE__ */ t(
148
- d,
160
+ m,
149
161
  {
150
162
  type: "button",
151
163
  variant: "ghost",
152
164
  size: "iconSm",
153
- className: "text-yellow-500 hover:text-yellow-600",
165
+ className: "text-yellow-500 hover:text-yellow-600 disabled:opacity-50",
154
166
  "aria-label": a("dataTable.savedViewsDefaultAction"),
167
+ disabled: s,
155
168
  onClick: (r) => {
156
- r.stopPropagation(), r.preventDefault(), _?.(e, { activeView: o });
169
+ r.stopPropagation(), r.preventDefault(), s || (y(e.id), setTimeout(() => y(null), 1200), U?.(e, { activeView: d }));
157
170
  },
158
- children: /* @__PURE__ */ t(P, { className: "size-3.5 fill-current" })
171
+ children: s ? /* @__PURE__ */ t("div", { className: "size-3.5 animate-spin rounded-full border-2 border-yellow-500 border-t-transparent" }) : /* @__PURE__ */ t(O, { className: "size-3.5 fill-current" })
159
172
  }
160
173
  ) : /* @__PURE__ */ t(
161
- d,
174
+ m,
162
175
  {
163
176
  type: "button",
164
177
  variant: "ghost",
165
178
  size: "iconSm",
166
- className: "text-yellow-500 hover:text-yellow-600",
179
+ className: "text-yellow-500 hover:text-yellow-600 disabled:opacity-50",
167
180
  "aria-label": a("dataTable.savedViewsSetDefault"),
181
+ disabled: s,
168
182
  onClick: (r) => {
169
- r.stopPropagation(), r.preventDefault(), _?.(e, { activeView: o });
183
+ r.stopPropagation(), r.preventDefault(), s || (y(e.id), setTimeout(() => y(null), 1200), U?.(e, { activeView: d }));
170
184
  },
171
- children: /* @__PURE__ */ t(P, { className: "size-3.5" })
185
+ children: s ? /* @__PURE__ */ t("div", { className: "size-3.5 animate-spin rounded-full border-2 border-yellow-500 border-t-transparent" }) : /* @__PURE__ */ t(O, { className: "size-3.5" })
172
186
  }
173
187
  )
174
188
  ] })
@@ -177,80 +191,80 @@ const Se = ["default", "active", "system"], Fe = ({
177
191
  c
178
192
  );
179
193
  };
180
- return /* @__PURE__ */ n(H, { children: [
181
- /* @__PURE__ */ n(
194
+ return /* @__PURE__ */ i(W, { children: [
195
+ /* @__PURE__ */ i(
182
196
  "div",
183
197
  {
184
198
  "data-component": "data-table-saved-views",
185
- className: w(
199
+ className: V(
186
200
  "mb-2 mx-4 rounded-lg bg-[linear-gradient(83.74deg,#F5F9EC_72.68%,#D7E5B2_108.88%)] flex min-w-0 flex-wrap items-center justify-between gap-2 px-2 py-3",
187
- ne
201
+ le
188
202
  ),
189
203
  children: [
190
- I ? /* @__PURE__ */ n("div", { className: "flex min-w-0 flex-1 items-center gap-1", children: [
191
- /* @__PURE__ */ t(O, { className: "h-6 w-24 rounded-full bg-black/10" }),
192
- /* @__PURE__ */ t(O, { className: "h-6 w-6 rounded-md bg-black/10" })
193
- ] }) : fe ? /* @__PURE__ */ t("div", { className: "flex min-w-0 flex-1 items-center gap-1 sm:flex-initial", children: /* @__PURE__ */ n(Ne, { open: m, onOpenChange: pe, children: [
194
- /* @__PURE__ */ t(we, { asChild: !0, children: /* @__PURE__ */ n(
204
+ L ? /* @__PURE__ */ i("div", { className: "flex min-w-0 flex-1 items-center gap-1", children: [
205
+ /* @__PURE__ */ t(I, { className: "h-6 w-24 rounded-full bg-black/10" }),
206
+ /* @__PURE__ */ t(I, { className: "h-6 w-6 rounded-md bg-black/10" })
207
+ ] }) : ve ? /* @__PURE__ */ t("div", { className: "flex min-w-0 flex-1 items-center gap-1 sm:flex-initial", children: /* @__PURE__ */ i(Ve, { open: u, onOpenChange: be, children: [
208
+ /* @__PURE__ */ t(ke, { asChild: !0, children: /* @__PURE__ */ i(
195
209
  "button",
196
210
  {
197
211
  type: "button",
198
212
  className: "flex min-w-0 max-w-full cursor-pointer items-center gap-1 rounded-md border-none bg-transparent p-0 text-left outline-none focus-visible:ring-2 focus-visible:ring-focus-ring focus-visible:ring-offset-2",
199
- "aria-expanded": m,
213
+ "aria-expanded": u,
200
214
  "aria-haspopup": "dialog",
201
215
  "aria-label": a("dataTable.savedViewsOpenMenu"),
202
216
  children: [
203
- /* @__PURE__ */ n(J, { children: [
204
- /* @__PURE__ */ t(W, { asChild: !0, children: /* @__PURE__ */ t(
205
- B,
217
+ /* @__PURE__ */ i(X, { children: [
218
+ /* @__PURE__ */ t(Z, { asChild: !0, children: /* @__PURE__ */ t(
219
+ E,
206
220
  {
207
221
  color: "success",
208
222
  variant: "outline",
209
223
  className: "max-w-[min(100%,200px)] shrink font-['Manrope']",
210
- children: /* @__PURE__ */ t("span", { className: "truncate", children: Q })
224
+ children: /* @__PURE__ */ t("span", { className: "truncate", children: Y })
211
225
  }
212
226
  ) }),
213
- /* @__PURE__ */ t(X, { variant: "tertiary", side: "top", children: Q })
227
+ /* @__PURE__ */ t(q, { variant: "tertiary", side: "top", children: Y })
214
228
  ] }),
215
229
  /* @__PURE__ */ t(
216
230
  "span",
217
231
  {
218
- className: w(
232
+ className: V(
219
233
  "flex size-6 shrink-0 items-center justify-center rounded-md bg-white transition-transform duration-200",
220
- m && "rotate-180"
234
+ u && "rotate-180"
221
235
  ),
222
236
  "aria-hidden": !0,
223
- children: /* @__PURE__ */ t(be, { className: "size-3.5 text-content-charcoal" })
237
+ children: /* @__PURE__ */ t(ge, { className: "size-3.5 text-content-charcoal" })
224
238
  }
225
239
  )
226
240
  ]
227
241
  }
228
242
  ) }),
229
243
  /* @__PURE__ */ t(
230
- Te,
244
+ Ce,
231
245
  {
232
246
  align: "start",
233
247
  className: "z-[50] w-[min(100vw-24px,280px)] p-0 shadow-[0_0_4px_0_rgba(0,0,0,0.12)] overflow-visible",
234
248
  sideOffset: 8,
235
- children: /* @__PURE__ */ n("div", { className: "flex flex-col py-2", children: [
236
- /* @__PURE__ */ n("div", { className: "flex items-start justify-between gap-2 px-3 pb-2", children: [
249
+ children: /* @__PURE__ */ i("div", { className: "flex flex-col py-2", children: [
250
+ /* @__PURE__ */ i("div", { className: "flex items-start justify-between gap-2 px-3 pb-2", children: [
237
251
  /* @__PURE__ */ t("span", { className: "text-sm font-medium text-content-charcoal font-['Manrope']", children: a("dataTable.savedViewsTitle") }),
238
- /* @__PURE__ */ n("div", { className: "flex shrink-0 items-center gap-1 text-xs font-medium text-content-tertiary font-['Manrope']", children: [
239
- /* @__PURE__ */ t(P, { className: "size-3.5 text-badge-warning-ink" }),
252
+ /* @__PURE__ */ i("div", { className: "flex shrink-0 items-center gap-1 text-xs font-medium text-content-tertiary font-['Manrope']", children: [
253
+ /* @__PURE__ */ t(O, { className: "size-3.5 text-badge-warning-ink" }),
240
254
  a("dataTable.savedViewsDefault")
241
255
  ] })
242
256
  ] }),
243
- /* @__PURE__ */ n("div", { className: "flex flex-wrap gap-1.5 px-3 pb-2", children: [
257
+ /* @__PURE__ */ i("div", { className: "flex flex-wrap gap-1.5 px-3 pb-2", children: [
244
258
  /* @__PURE__ */ t(
245
259
  "button",
246
260
  {
247
261
  type: "button",
248
262
  className: "border-none bg-transparent p-0",
249
- onClick: () => C("All"),
263
+ onClick: () => D("All"),
250
264
  children: /* @__PURE__ */ t(
251
- B,
265
+ E,
252
266
  {
253
- color: b === "All" ? "primary" : "neutral",
267
+ color: v === "All" ? "primary" : "neutral",
254
268
  variant: "outline",
255
269
  size: "sm",
256
270
  className: "cursor-pointer font-['Manrope']",
@@ -259,16 +273,16 @@ const Se = ["default", "active", "system"], Fe = ({
259
273
  )
260
274
  }
261
275
  ),
262
- ee?.map((e) => /* @__PURE__ */ t(
276
+ ae?.map((e) => /* @__PURE__ */ t(
263
277
  "button",
264
278
  {
265
279
  type: "button",
266
280
  className: "border-none bg-transparent p-0",
267
- onClick: () => C(e.value),
281
+ onClick: () => D(e.value),
268
282
  children: /* @__PURE__ */ t(
269
- B,
283
+ E,
270
284
  {
271
- color: b === e.value ? "primary" : "neutral",
285
+ color: v === e.value ? "primary" : "neutral",
272
286
  variant: "outline",
273
287
  size: "sm",
274
288
  className: "cursor-pointer font-['Manrope']",
@@ -280,14 +294,14 @@ const Se = ["default", "active", "system"], Fe = ({
280
294
  ))
281
295
  ] }),
282
296
  /* @__PURE__ */ t("div", { className: "px-3 pb-2", children: /* @__PURE__ */ t(
283
- Ve,
297
+ De,
284
298
  {
285
299
  size: "sm",
286
300
  placeholder: a("dataTable.savedViewsSearchPlaceholder"),
287
- value: g,
288
- onChange: (e) => k(e.target.value),
301
+ value: N,
302
+ onChange: (e) => S(e.target.value),
289
303
  prefix: /* @__PURE__ */ t(
290
- xe,
304
+ ye,
291
305
  {
292
306
  className: "size-4 shrink-0 text-content-muted",
293
307
  "aria-hidden": !0
@@ -297,19 +311,19 @@ const Se = ["default", "active", "system"], Fe = ({
297
311
  "aria-label": a("dataTable.savedViewsSearchPlaceholder")
298
312
  }
299
313
  ) }),
300
- /* @__PURE__ */ t("div", { className: "min-h-[72px] px-1", children: R || (I ? /* @__PURE__ */ t("div", { className: "flex max-h-[160px] flex-col gap-2 overflow-y-auto px-2 py-1", children: [1, 2, 3, 4, 5].map((e) => /* @__PURE__ */ t(O, { className: "h-9 w-full rounded-lg" }, e)) }) : M.length === 0 && f.length === 0 ? /* @__PURE__ */ t("div", { className: "flex min-h-[100px] flex-col items-center justify-center px-4 py-6 text-center", children: /* @__PURE__ */ t("span", { className: "text-sm leading-relaxed text-content-tertiary font-['Manrope']", children: a("dataTable.savedViewsEmptyList") }) }) : /* @__PURE__ */ n("div", { className: "flex max-h-[220px] flex-col gap-0 overflow-y-auto", children: [
301
- f.length > 0 ? /* @__PURE__ */ t("div", { className: "flex flex-col px-1 pb-1 ", children: f.map(
302
- (e) => K(
314
+ /* @__PURE__ */ t("div", { className: "min-h-[72px] px-1", children: _ || (L ? /* @__PURE__ */ t("div", { className: "flex max-h-[160px] flex-col gap-2 overflow-y-auto px-2 py-1", children: [1, 2, 3, 4, 5].map((e) => /* @__PURE__ */ t(I, { className: "h-9 w-full rounded-lg" }, e)) }) : A.length === 0 && h.length === 0 ? /* @__PURE__ */ t("div", { className: "flex min-h-[100px] flex-col items-center justify-center px-4 py-6 text-center", children: /* @__PURE__ */ t("span", { className: "text-sm leading-relaxed text-content-tertiary font-['Manrope']", children: a("dataTable.savedViewsEmptyList") }) }) : /* @__PURE__ */ i("div", { className: "flex max-h-[220px] flex-col gap-0 overflow-y-auto", children: [
315
+ h.length > 0 ? /* @__PURE__ */ t("div", { className: "flex flex-col px-1 pb-1 ", children: h.map(
316
+ (e) => H(
303
317
  e,
304
318
  "priority",
305
319
  `priority-${e.id}`
306
320
  )
307
321
  ) }) : null,
308
- f.length > 0 && z.length > 0 ? /* @__PURE__ */ t(Z, { className: "bg-[#D9DDE7] mb-2" }) : null,
309
- z.length > 0 ? /* @__PURE__ */ n(H, { children: [
322
+ h.length > 0 && P.length > 0 ? /* @__PURE__ */ t(ee, { className: "bg-[#D9DDE7] mb-2" }) : null,
323
+ P.length > 0 ? /* @__PURE__ */ i(W, { children: [
310
324
  /* @__PURE__ */ t("div", { className: "px-3 pb-1.5 pt-0.5 text-xs font-medium tracking-wide text-[#B4BAC7] font-['Manrope']", children: a("dataTable.savedViewsAllSavedViews") }),
311
- /* @__PURE__ */ t("div", { className: "flex flex-col px-1 pb-1", children: z.map(
312
- (e) => K(
325
+ /* @__PURE__ */ t("div", { className: "flex flex-col px-1 pb-1", children: P.map(
326
+ (e) => H(
313
327
  e,
314
328
  "list",
315
329
  `list-${e.id}`
@@ -317,26 +331,26 @@ const Se = ["default", "active", "system"], Fe = ({
317
331
  ) })
318
332
  ] }) : null
319
333
  ] })) }),
320
- /* @__PURE__ */ t(Z, { className: "my-1" }),
321
- /* @__PURE__ */ n("div", { className: "flex justify-end gap-2 px-3 pt-1", children: [
334
+ /* @__PURE__ */ t(ee, { className: "my-1" }),
335
+ /* @__PURE__ */ i("div", { className: "flex justify-end gap-2 px-3 pt-1", children: [
322
336
  /* @__PURE__ */ t(
323
- d,
337
+ m,
324
338
  {
325
339
  type: "button",
326
340
  variant: "tertiary",
327
341
  size: "md",
328
- onClick: ue,
342
+ onClick: he,
329
343
  children: a("dataTable.savedViewsCancel")
330
344
  }
331
345
  ),
332
346
  /* @__PURE__ */ t(
333
- d,
347
+ m,
334
348
  {
335
349
  type: "button",
336
350
  variant: "default",
337
351
  size: "md",
338
- disabled: ae || y === o?.id,
339
- onClick: me,
352
+ disabled: ie || w === d?.id,
353
+ onClick: fe,
340
354
  children: a("dataTable.savedViewsApply")
341
355
  }
342
356
  )
@@ -344,19 +358,19 @@ const Se = ["default", "active", "system"], Fe = ({
344
358
  ] })
345
359
  }
346
360
  )
347
- ] }) }) : /* @__PURE__ */ n("div", { className: "flex min-w-0 flex-1 items-center gap-2 text-content-tertiary", children: [
348
- /* @__PURE__ */ t(ve, { className: "size-4 shrink-0", "aria-hidden": !0 }),
361
+ ] }) }) : /* @__PURE__ */ i("div", { className: "flex min-w-0 flex-1 items-center gap-2 text-content-tertiary", children: [
362
+ /* @__PURE__ */ t(Ne, { className: "size-4 shrink-0", "aria-hidden": !0 }),
349
363
  /* @__PURE__ */ t("span", { className: "text-sm font-medium font-['Manrope']", children: a("dataTable.savedViewsNoneYet") })
350
364
  ] }),
351
365
  /* @__PURE__ */ t(
352
- d,
366
+ m,
353
367
  {
354
368
  type: "button",
355
369
  variant: "tertiary",
356
370
  size: "sm",
357
371
  className: "shrink-0 font-['Manrope']",
358
372
  onClick: () => {
359
- u(!1), ie?.({ activeView: o });
373
+ p(!1), re?.({ activeView: d });
360
374
  },
361
375
  children: a("dataTable.savedViewsSave")
362
376
  }
@@ -365,12 +379,12 @@ const Se = ["default", "active", "system"], Fe = ({
365
379
  }
366
380
  ),
367
381
  /* @__PURE__ */ t(
368
- Ce,
382
+ Se,
369
383
  {
370
384
  variant: "destructive",
371
385
  open: x !== null,
372
386
  onOpenChange: (e) => {
373
- e || U(null);
387
+ e || $(null);
374
388
  },
375
389
  title: a("dataTable.savedViewsDeleteConfirmTitle"),
376
390
  description: x ? a("dataTable.savedViewsDeleteConfirmDescription", {
@@ -378,12 +392,12 @@ const Se = ["default", "active", "system"], Fe = ({
378
392
  }) : void 0,
379
393
  confirmLabel: a("dataTable.savedViewsDeleteConfirmButton"),
380
394
  onConfirm: () => {
381
- x && oe?.(x, { activeView: o });
395
+ x && ce?.(x, { activeView: d });
382
396
  }
383
397
  }
384
398
  )
385
399
  ] });
386
400
  };
387
401
  export {
388
- Fe as DataTableSavedViews
402
+ Ye as DataTableSavedViews
389
403
  };