@sito/dashboard-app 0.0.51 → 0.0.52

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.
@@ -2,12 +2,12 @@ var et = Object.defineProperty;
2
2
  var tt = (n, e, t) => e in n ? et(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
3
3
  var L = (n, e, t) => tt(n, typeof e != "symbol" ? e + "" : e, t);
4
4
  import "./main.css";
5
- import { State as st, inputStateClassName as nt, labelStateClassName as rt, helperTextStateClassName as it, useTranslation as T, Button as U, Loading as ne, TextInput as ot, FileInput as at, IconButton as ct, Actions as lt, ActionsDropdown as ut, useTableOptions as dt, Badge as mt, Action as ht } from "@sito/dashboard";
5
+ import { State as st, inputStateClassName as nt, labelStateClassName as rt, helperTextStateClassName as it, useTranslation as N, Button as U, Loading as ne, TextInput as ot, FileInput as at, IconButton as ct, Actions as lt, ActionsDropdown as ut, useTableOptions as dt, Badge as mt, Action as ht } from "@sito/dashboard";
6
6
  export * from "@sito/dashboard";
7
7
  import { Action as ln, Actions as un, ActionsDropdown as dn, Button as mn } from "@sito/dashboard";
8
- import { jsxs as S, jsx as p, Fragment as ae } from "react/jsx-runtime";
9
- import { FontAwesomeIcon as P } from "@fortawesome/react-fontawesome";
10
- import { forwardRef as Ae, useState as _, useCallback as w, useEffect as O, useReducer as Le, useRef as K, useMemo as H, createContext as re, useContext as ie, useLayoutEffect as ft } from "react";
8
+ import { jsxs as k, jsx as f, Fragment as ae } from "react/jsx-runtime";
9
+ import { FontAwesomeIcon as K } from "@fortawesome/react-fontawesome";
10
+ import { forwardRef as Ae, useState as _, useCallback as w, useEffect as O, useReducer as Le, useRef as M, useMemo as Q, createContext as re, useContext as ie, useLayoutEffect as ft } from "react";
11
11
  import { faEyeSlash as pt, faEye as gt, faClose as _e, faTrash as yt, faRotateLeft as Re, faPencil as bt, faCircleNotch as Ie, faCloudArrowDown as wt, faCloudUpload as St, faArrowUp as kt, faArrowLeft as vt, faAdd as Ne, faFilter as Ct, faBars as Tt, faSearch as Nt, faCircleCheck as Et, faWarning as $t } from "@fortawesome/free-solid-svg-icons";
12
12
  import { createPortal as Fe } from "react-dom";
13
13
  import { QueryClient as xt, QueryClientProvider as At, useMutation as Z, useQueryClient as J, useQuery as Oe } from "@tanstack/react-query";
@@ -25,24 +25,24 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
25
25
  disabled: u = !1,
26
26
  required: l = !1,
27
27
  containerClassName: d = "",
28
- inputClassName: h = "",
29
- labelClassName: m = "",
30
- helperText: f = "",
28
+ inputClassName: m = "",
29
+ labelClassName: h = "",
30
+ helperText: p = "",
31
31
  helperTextClassName: y = "",
32
32
  ...g
33
- } = n, b = t !== void 0, [k, E] = _(
33
+ } = n, b = t !== void 0, [S, E] = _(
34
34
  () => Ee(s)
35
- ), N = b ? Ee(t) : k, $ = (j) => {
35
+ ), v = b ? Ee(t) : S, $ = (j) => {
36
36
  b || E(j.currentTarget.value.length > 0), r == null || r(j);
37
37
  };
38
- return /* @__PURE__ */ S("div", { className: `form-paragraph-container group ${d}`, children: [
39
- /* @__PURE__ */ p(
38
+ return /* @__PURE__ */ k("div", { className: `form-paragraph-container group ${d}`, children: [
39
+ /* @__PURE__ */ f(
40
40
  "textarea",
41
41
  {
42
42
  ref: e,
43
43
  name: o,
44
44
  id: c,
45
- className: `text-input text-area form-paragraph-textarea peer ${nt(i)} ${N ? "has-value" : ""} ${g.placeholder ? "has-placeholder" : ""} ${h}`,
45
+ className: `text-input text-area form-paragraph-textarea peer ${nt(i)} ${v ? "has-value" : ""} ${g.placeholder ? "has-placeholder" : ""} ${m}`,
46
46
  required: l,
47
47
  defaultValue: s,
48
48
  ...b ? { value: t } : {},
@@ -51,27 +51,27 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
51
51
  ...g
52
52
  }
53
53
  ),
54
- /* @__PURE__ */ S(
54
+ /* @__PURE__ */ k(
55
55
  "label",
56
56
  {
57
57
  htmlFor: c,
58
- className: `text-input-label ${rt(i)} ${m}`,
58
+ className: `text-input-label ${rt(i)} ${h}`,
59
59
  children: [
60
60
  a,
61
61
  l ? " *" : ""
62
62
  ]
63
63
  }
64
64
  ),
65
- !!f && /* @__PURE__ */ p(
65
+ !!p && /* @__PURE__ */ f(
66
66
  "p",
67
67
  {
68
68
  className: `text-input-helper-text ${it(i)} ${y}`,
69
- children: f
69
+ children: p
70
70
  }
71
71
  )
72
72
  ] });
73
73
  }), ws = (n) => {
74
- const { t: e } = T(), {
74
+ const { t: e } = N(), {
75
75
  children: t,
76
76
  handleSubmit: s,
77
77
  onSubmit: r,
@@ -79,10 +79,10 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
79
79
  buttonEnd: o = !0,
80
80
  reset: c
81
81
  } = n;
82
- return /* @__PURE__ */ S("form", { className: "form-container", onSubmit: s(r), children: [
82
+ return /* @__PURE__ */ k("form", { className: "form-container", onSubmit: s(r), children: [
83
83
  t,
84
- /* @__PURE__ */ S("div", { className: `form-actions ${o ? "end" : ""}`, children: [
85
- /* @__PURE__ */ S(
84
+ /* @__PURE__ */ k("div", { className: `form-actions ${o ? "end" : ""}`, children: [
85
+ /* @__PURE__ */ k(
86
86
  U,
87
87
  {
88
88
  type: "submit",
@@ -92,7 +92,7 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
92
92
  name: e("_accessibility:buttons.submit"),
93
93
  "aria-label": e("_accessibility:ariaLabels.submit"),
94
94
  children: [
95
- i ? /* @__PURE__ */ p(
95
+ i ? /* @__PURE__ */ f(
96
96
  ne,
97
97
  {
98
98
  color: "stroke-base",
@@ -104,7 +104,7 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
104
104
  ]
105
105
  }
106
106
  ),
107
- /* @__PURE__ */ p(
107
+ /* @__PURE__ */ f(
108
108
  U,
109
109
  {
110
110
  type: "button",
@@ -118,8 +118,8 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
118
118
  ] })
119
119
  ] });
120
120
  }, Ss = Ae(function(n, e) {
121
- const { t } = T(), [s, r] = _(!1);
122
- return /* @__PURE__ */ p(ot, { ...n, type: s ? "text" : "password", ref: e, children: /* @__PURE__ */ p(
121
+ const { t } = N(), [s, r] = _(!1);
122
+ return /* @__PURE__ */ f(ot, { ...n, type: s ? "text" : "password", ref: e, children: /* @__PURE__ */ f(
123
123
  G,
124
124
  {
125
125
  type: "button",
@@ -133,7 +133,7 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
133
133
  }
134
134
  ) });
135
135
  }), ke = (n) => {
136
- const { t: e } = T(), {
136
+ const { t: e } = N(), {
137
137
  title: t,
138
138
  children: s,
139
139
  handleClose: r,
@@ -157,28 +157,28 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
157
157
  [r]
158
158
  );
159
159
  return O(() => {
160
- const d = (h) => {
161
- h ? document.body.style.overflow = "hidden" : document.body.style.overflow = "auto";
160
+ const d = (m) => {
161
+ m ? document.body.style.overflow = "hidden" : document.body.style.overflow = "auto";
162
162
  };
163
163
  return d(i), () => {
164
164
  d(!1);
165
165
  };
166
166
  }, [i]), Fe(
167
- /* @__PURE__ */ p(
167
+ /* @__PURE__ */ f(
168
168
  "div",
169
169
  {
170
170
  "aria-label": e("_accessibility:ariaLabels.closeDialog"),
171
171
  "aria-hidden": !i,
172
172
  onClick: l,
173
173
  className: `dialog-backdrop animated ${i ? `opened ${a}` : "closed"} ${o}`,
174
- children: /* @__PURE__ */ S(
174
+ children: /* @__PURE__ */ k(
175
175
  "div",
176
176
  {
177
177
  className: `dialog elevated animated ${i ? `opened ${a}` : "closed"} ${c}`,
178
178
  children: [
179
- /* @__PURE__ */ S("div", { className: "dialog-header", children: [
180
- /* @__PURE__ */ p("h3", { className: "dialog-title", children: t }),
181
- /* @__PURE__ */ p(
179
+ /* @__PURE__ */ k("div", { className: "dialog-header", children: [
180
+ /* @__PURE__ */ f("h3", { className: "dialog-title", children: t }),
181
+ /* @__PURE__ */ f(
182
182
  G,
183
183
  {
184
184
  icon: _e,
@@ -214,16 +214,16 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
214
214
  primaryClassName: u = "",
215
215
  alignEnd: l = !1,
216
216
  primaryName: d,
217
- primaryAriaLabel: h,
218
- cancelName: m,
219
- cancelAriaLabel: f
217
+ primaryAriaLabel: m,
218
+ cancelName: h,
219
+ cancelAriaLabel: p
220
220
  } = n;
221
- return /* @__PURE__ */ S(
221
+ return /* @__PURE__ */ k(
222
222
  "div",
223
223
  {
224
224
  className: `dialog-actions ${l ? "end" : ""} ${a}`,
225
225
  children: [
226
- /* @__PURE__ */ S(
226
+ /* @__PURE__ */ k(
227
227
  U,
228
228
  {
229
229
  type: c,
@@ -233,9 +233,9 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
233
233
  disabled: o,
234
234
  onClick: s,
235
235
  name: d,
236
- "aria-label": h,
236
+ "aria-label": m,
237
237
  children: [
238
- i ? /* @__PURE__ */ p(
238
+ i ? /* @__PURE__ */ f(
239
239
  ne,
240
240
  {
241
241
  color: "stroke-base",
@@ -247,15 +247,15 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
247
247
  ]
248
248
  }
249
249
  ),
250
- /* @__PURE__ */ p(
250
+ /* @__PURE__ */ f(
251
251
  U,
252
252
  {
253
253
  type: "button",
254
254
  variant: "outlined",
255
255
  disabled: o,
256
256
  onClick: r,
257
- name: m,
258
- "aria-label": f,
257
+ name: h,
258
+ "aria-label": p,
259
259
  children: t
260
260
  }
261
261
  )
@@ -263,7 +263,7 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
263
263
  }
264
264
  );
265
265
  }, ks = (n) => {
266
- const { t: e } = T(), {
266
+ const { t: e } = N(), {
267
267
  children: t,
268
268
  handleSubmit: s,
269
269
  onSubmit: r,
@@ -272,9 +272,9 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
272
272
  buttonEnd: c = !0,
273
273
  ...a
274
274
  } = n;
275
- return /* @__PURE__ */ p(ke, { ...a, handleClose: i, children: /* @__PURE__ */ S("form", { onSubmit: s(r), children: [
276
- /* @__PURE__ */ p("div", { className: "form-container", children: t }),
277
- /* @__PURE__ */ p(
275
+ return /* @__PURE__ */ f(ke, { ...a, handleClose: i, children: /* @__PURE__ */ k("form", { onSubmit: s(r), children: [
276
+ /* @__PURE__ */ f("div", { className: "form-container", children: t }),
277
+ /* @__PURE__ */ f(
278
278
  ve,
279
279
  {
280
280
  primaryType: "submit",
@@ -293,16 +293,16 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
293
293
  )
294
294
  ] }) });
295
295
  }, vs = (n) => {
296
- const { t: e } = T(), {
296
+ const { t: e } = N(), {
297
297
  children: t,
298
298
  handleSubmit: s,
299
299
  handleClose: r,
300
300
  isLoading: i = !1,
301
301
  ...o
302
302
  } = n;
303
- return /* @__PURE__ */ S(ke, { ...o, handleClose: r, children: [
303
+ return /* @__PURE__ */ k(ke, { ...o, handleClose: r, children: [
304
304
  t,
305
- /* @__PURE__ */ p(
305
+ /* @__PURE__ */ f(
306
306
  ve,
307
307
  {
308
308
  primaryText: e("_accessibility:buttons.ok"),
@@ -322,30 +322,30 @@ const Ee = (n) => n == null ? !1 : `${n}`.length > 0, bs = Ae(function(n, e) {
322
322
  ] });
323
323
  };
324
324
  function _t(n) {
325
- const { message: e, className: t = "" } = n, { t: s } = T();
326
- return /* @__PURE__ */ p("p", { className: `import-error-message ${t}`, children: e ?? s("_messages:errors.parseFile", {
325
+ const { message: e, className: t = "" } = n, { t: s } = N();
326
+ return /* @__PURE__ */ f("p", { className: `import-error-message ${t}`, children: e ?? s("_messages:errors.parseFile", {
327
327
  defaultValue: "Failed to process file"
328
328
  }) });
329
329
  }
330
330
  function Rt(n) {
331
- const { message: e, className: t = "" } = n, { t: s } = T();
332
- return /* @__PURE__ */ S("div", { className: `import-loading ${t}`, children: [
333
- /* @__PURE__ */ p(ne, { loaderClass: "w-5 h-5", className: "!w-auto" }),
334
- /* @__PURE__ */ p("span", { children: e ?? s("_messages:loading.processingFile", {
331
+ const { message: e, className: t = "" } = n, { t: s } = N();
332
+ return /* @__PURE__ */ k("div", { className: `import-loading ${t}`, children: [
333
+ /* @__PURE__ */ f(ne, { loaderClass: "w-5 h-5", className: "!w-auto" }),
334
+ /* @__PURE__ */ f("span", { children: e ?? s("_messages:loading.processingFile", {
335
335
  defaultValue: "Processing file..."
336
336
  }) })
337
337
  ] });
338
338
  }
339
339
  function It(n) {
340
- const { items: e, max: t = 5, className: s = "" } = n, { t: r } = T();
340
+ const { items: e, max: t = 5, className: s = "" } = n, { t: r } = N();
341
341
  if (!e || e.length === 0) return null;
342
342
  const i = e.slice(0, t);
343
- return /* @__PURE__ */ S("div", { className: `import-preview ${s}`, children: [
344
- /* @__PURE__ */ p("p", { className: "import-preview-count", children: r("_pages:common.actions.import.previewCount", {
343
+ return /* @__PURE__ */ k("div", { className: `import-preview ${s}`, children: [
344
+ /* @__PURE__ */ f("p", { className: "import-preview-count", children: r("_pages:common.actions.import.previewCount", {
345
345
  count: e.length,
346
346
  defaultValue: `Preview: ${e.length} items`
347
347
  }) }),
348
- /* @__PURE__ */ p("pre", { className: "import-preview-content", children: JSON.stringify(i, null, 2) })
348
+ /* @__PURE__ */ f("pre", { className: "import-preview-content", children: JSON.stringify(i, null, 2) })
349
349
  ] });
350
350
  }
351
351
  const De = () => ({
@@ -389,7 +389,7 @@ function Ft(n, e) {
389
389
  }
390
390
  }
391
391
  const Cs = (n) => {
392
- const { t: e } = T(), {
392
+ const { t: e } = N(), {
393
393
  children: t,
394
394
  handleSubmit: s,
395
395
  handleClose: r,
@@ -400,83 +400,83 @@ const Cs = (n) => {
400
400
  onOverrideChange: u,
401
401
  open: l,
402
402
  ...d
403
- } = n, [h, m] = Le(
403
+ } = n, [m, h] = Le(
404
404
  Ft,
405
405
  De()
406
406
  ), {
407
- file: f,
407
+ file: p,
408
408
  previewItems: y,
409
409
  parseError: g,
410
410
  processing: b,
411
- overrideExisting: k,
411
+ overrideExisting: S,
412
412
  inputKey: E
413
- } = h, N = K(c), $ = K(o);
413
+ } = m, v = M(c), $ = M(o);
414
414
  O(() => {
415
- N.current = c;
415
+ v.current = c;
416
416
  }, [c]), O(() => {
417
417
  $.current = o;
418
418
  }, [o]), O(() => {
419
- l || m({ type: "RESET" });
419
+ l || h({ type: "RESET" });
420
420
  }, [l]);
421
421
  const j = w(
422
- async (I, v) => {
422
+ async (I, C) => {
423
423
  var A;
424
424
  if ($.current) {
425
- m({ type: "START_PROCESSING" });
425
+ h({ type: "START_PROCESSING" });
426
426
  try {
427
- const x = await $.current(I, { override: v });
428
- m({ type: "SET_PREVIEW", items: x ?? [] }), (A = N.current) == null || A.call(N, x ?? []);
427
+ const x = await $.current(I, { override: C });
428
+ h({ type: "SET_PREVIEW", items: x ?? [] }), (A = v.current) == null || A.call(v, x ?? []);
429
429
  } catch (x) {
430
430
  console.error(x);
431
431
  const q = x instanceof Error ? x.message : "Failed to parse file";
432
- m({ type: "SET_ERROR", message: q });
432
+ h({ type: "SET_ERROR", message: q });
433
433
  }
434
434
  }
435
435
  },
436
436
  []
437
437
  );
438
- return /* @__PURE__ */ S(ke, { ...d, open: l, handleClose: r, children: [
439
- /* @__PURE__ */ p(
438
+ return /* @__PURE__ */ k(ke, { ...d, open: l, handleClose: r, children: [
439
+ /* @__PURE__ */ f(
440
440
  at,
441
441
  {
442
442
  onClear: () => {
443
443
  var I;
444
- m({ type: "SET_FILE", file: null }), (I = N.current) == null || I.call(N, []);
444
+ h({ type: "SET_FILE", file: null }), (I = v.current) == null || I.call(v, []);
445
445
  },
446
446
  onChange: (I) => {
447
447
  var A, x;
448
- const v = (A = I.target.files) == null ? void 0 : A[0];
449
- if (!v) {
450
- m({ type: "SET_FILE", file: null }), (x = N.current) == null || x.call(N, []);
448
+ const C = (A = I.target.files) == null ? void 0 : A[0];
449
+ if (!C) {
450
+ h({ type: "SET_FILE", file: null }), (x = v.current) == null || x.call(v, []);
451
451
  return;
452
452
  }
453
- m({ type: "SET_FILE", file: v }), j(v, k);
453
+ h({ type: "SET_FILE", file: C }), j(C, S);
454
454
  },
455
455
  label: e("_accessibility:labels.file")
456
456
  },
457
457
  E
458
458
  ),
459
- /* @__PURE__ */ S("label", { className: "import-override-label", children: [
460
- /* @__PURE__ */ p(
459
+ /* @__PURE__ */ k("label", { className: "import-override-label", children: [
460
+ /* @__PURE__ */ f(
461
461
  "input",
462
462
  {
463
463
  type: "checkbox",
464
- checked: k,
464
+ checked: S,
465
465
  onChange: (I) => {
466
- const v = I.target.checked;
467
- m({ type: "SET_OVERRIDE", value: v }), u == null || u(v), f && j(f, v);
466
+ const C = I.target.checked;
467
+ h({ type: "SET_OVERRIDE", value: C }), u == null || u(C), p && j(p, C);
468
468
  }
469
469
  }
470
470
  ),
471
- /* @__PURE__ */ p("span", { children: e("_pages:common.actions.import.override", {
471
+ /* @__PURE__ */ f("span", { children: e("_pages:common.actions.import.override", {
472
472
  defaultValue: "Override existing items"
473
473
  }) })
474
474
  ] }),
475
- /* @__PURE__ */ p(_t, { message: g }),
476
- b && /* @__PURE__ */ p(Rt, {}),
477
- a ? a(y) : !!y && y.length > 0 && /* @__PURE__ */ p(It, { items: y }),
475
+ /* @__PURE__ */ f(_t, { message: g }),
476
+ b && /* @__PURE__ */ f(Rt, {}),
477
+ a ? a(y) : !!y && y.length > 0 && /* @__PURE__ */ f(It, { items: y }),
478
478
  t,
479
- /* @__PURE__ */ p(
479
+ /* @__PURE__ */ f(
480
480
  ve,
481
481
  {
482
482
  primaryText: e("_accessibility:buttons.ok"),
@@ -624,12 +624,12 @@ const Pe = (n, e, t) => {
624
624
  return Number.isNaN(s) ? !1 : Date.now() >= s - this.refreshExpirySkewMs;
625
625
  }
626
626
  clearStoredSession() {
627
- D(this.userKey), D(this.rememberKey), D(this.refreshTokenKey), D(this.accessTokenExpiresAtKey);
627
+ P(this.userKey), P(this.rememberKey), P(this.refreshTokenKey), P(this.accessTokenExpiresAtKey);
628
628
  }
629
629
  storeSession(e, t) {
630
630
  W(this.userKey, e.token);
631
631
  const s = e.refreshToken === void 0 ? t : e.refreshToken;
632
- typeof s == "string" && s.length ? W(this.refreshTokenKey, s) : D(this.refreshTokenKey), typeof e.accessTokenExpiresAt == "string" && e.accessTokenExpiresAt.length ? W(this.accessTokenExpiresAtKey, e.accessTokenExpiresAt) : D(this.accessTokenExpiresAtKey);
632
+ typeof s == "string" && s.length ? W(this.refreshTokenKey, s) : P(this.refreshTokenKey), typeof e.accessTokenExpiresAt == "string" && e.accessTokenExpiresAt.length ? W(this.accessTokenExpiresAtKey, e.accessTokenExpiresAt) : P(this.accessTokenExpiresAtKey);
633
633
  }
634
634
  async refreshAccessTokenWithMutex() {
635
635
  const e = this.getRefreshToken();
@@ -1025,13 +1025,13 @@ class Es {
1025
1025
  return await this.request(i.put(r)), r;
1026
1026
  }
1027
1027
  async get(e, t) {
1028
- var m;
1029
- const s = await this.transaction("readonly"), r = await this.request(s.getAll()), i = this.applyFilter(r, t), o = (e == null ? void 0 : e.sortingBy) ?? "id", c = ((m = e == null ? void 0 : e.sortingOrder) == null ? void 0 : m.toLowerCase()) ?? "asc";
1030
- i.sort((f, y) => {
1031
- const g = f[o], b = y[o];
1028
+ var h;
1029
+ const s = await this.transaction("readonly"), r = await this.request(s.getAll()), i = this.applyFilter(r, t), o = (e == null ? void 0 : e.sortingBy) ?? "id", c = ((h = e == null ? void 0 : e.sortingOrder) == null ? void 0 : h.toLowerCase()) ?? "asc";
1030
+ i.sort((p, y) => {
1031
+ const g = p[o], b = y[o];
1032
1032
  return g < b ? c === "asc" ? -1 : 1 : g > b ? c === "asc" ? 1 : -1 : 0;
1033
1033
  });
1034
- const a = (e == null ? void 0 : e.pageSize) ?? 10, u = (e == null ? void 0 : e.currentPage) ?? 0, l = i.length, d = Math.ceil(l / a), h = i.slice(
1034
+ const a = (e == null ? void 0 : e.pageSize) ?? 10, u = (e == null ? void 0 : e.currentPage) ?? 0, l = i.length, d = Math.ceil(l / a), m = i.slice(
1035
1035
  u * a,
1036
1036
  u * a + a
1037
1037
  );
@@ -1042,7 +1042,7 @@ class Es {
1042
1042
  pageSize: a,
1043
1043
  totalElements: l,
1044
1044
  totalPages: d,
1045
- items: h
1045
+ items: m
1046
1046
  };
1047
1047
  }
1048
1048
  async export(e) {
@@ -1126,7 +1126,7 @@ const X = (n, e = "") => {
1126
1126
  }, W = (n, e) => localStorage.setItem(
1127
1127
  n,
1128
1128
  typeof e == "object" ? JSON.stringify(e) : e
1129
- ), D = (n) => localStorage.removeItem(n);
1129
+ ), P = (n) => localStorage.removeItem(n);
1130
1130
  function xs(n) {
1131
1131
  const e = n ? new Date(n) : /* @__PURE__ */ new Date(), t = {
1132
1132
  weekday: "long",
@@ -1181,38 +1181,38 @@ const Ke = re(
1181
1181
  void 0
1182
1182
  );
1183
1183
  function Rs(n) {
1184
- const { children: e } = n, t = K(0), [s, r] = Le(
1185
- (h, m) => {
1186
- const { type: f, items: y, id: g } = m;
1187
- switch (f) {
1184
+ const { children: e } = n, t = M(0), [s, r] = Le(
1185
+ (m, h) => {
1186
+ const { type: p, items: y, id: g } = h;
1187
+ switch (p) {
1188
1188
  case "set":
1189
1189
  return y ?? [];
1190
1190
  case "remove":
1191
- return g !== void 0 ? h.filter((b) => b.id !== g) : [];
1191
+ return g !== void 0 ? m.filter((b) => b.id !== g) : [];
1192
1192
  }
1193
- return h;
1193
+ return m;
1194
1194
  },
1195
1195
  [],
1196
1196
  () => []
1197
- ), i = (h) => h.map((m) => ({ ...m, id: t.current++ })), o = w(
1198
- (h) => r({
1197
+ ), i = (m) => m.map((h) => ({ ...h, id: t.current++ })), o = w(
1198
+ (m) => r({
1199
1199
  type: "set",
1200
- items: i([{ ...h, type: R.error }])
1200
+ items: i([{ ...m, type: R.error }])
1201
1201
  }),
1202
1202
  []
1203
1203
  ), c = w(
1204
- (h) => r({ type: "set", items: i([{ ...h }]) }),
1204
+ (m) => r({ type: "set", items: i([{ ...m }]) }),
1205
1205
  []
1206
1206
  ), a = w(
1207
- (h) => r({ type: "set", items: i(h) }),
1207
+ (m) => r({ type: "set", items: i(m) }),
1208
1208
  []
1209
1209
  ), u = w(
1210
- (h) => r({
1210
+ (m) => r({
1211
1211
  type: "set",
1212
- items: i([{ ...h, type: R.success }])
1212
+ items: i([{ ...m, type: R.success }])
1213
1213
  }),
1214
1214
  []
1215
- ), l = (h) => r({ type: "remove", id: h }), d = H(() => ({
1215
+ ), l = (m) => r({ type: "remove", id: m }), d = Q(() => ({
1216
1216
  notification: s,
1217
1217
  removeNotification: l,
1218
1218
  showErrorNotification: o,
@@ -1226,7 +1226,7 @@ function Rs(n) {
1226
1226
  a,
1227
1227
  u
1228
1228
  ]);
1229
- return /* @__PURE__ */ p(Ke.Provider, { value: d, children: e });
1229
+ return /* @__PURE__ */ f(Ke.Provider, { value: d, children: e });
1230
1230
  }
1231
1231
  const ee = () => {
1232
1232
  const n = ie(Ke);
@@ -1249,7 +1249,7 @@ const ee = () => {
1249
1249
  void 0
1250
1250
  ), Fs = (n) => {
1251
1251
  const { children: e, manager: t, queryClient: s } = n, [r] = _(qe), i = s ?? r;
1252
- return /* @__PURE__ */ p(Ue.Provider, { value: { client: t }, children: /* @__PURE__ */ p(At, { client: i, children: e }) });
1252
+ return /* @__PURE__ */ f(Ue.Provider, { value: { client: t }, children: /* @__PURE__ */ f(At, { client: i, children: e }) });
1253
1253
  }, Ut = () => {
1254
1254
  const n = ie(Ue);
1255
1255
  if (!n)
@@ -1266,25 +1266,25 @@ const ee = () => {
1266
1266
  refreshTokenKey: i = "refreshToken",
1267
1267
  accessTokenExpiresAtKey: o = "accessTokenExpiresAt"
1268
1268
  } = n, c = Ut(), [a, u] = _({}), l = w(() => {
1269
- D(s), D(r), D(i), D(o);
1270
- }, [o, i, r, s]), d = w(() => !!X(t, "boolean") && a.token === void 0, [a.token, t]), h = w(
1269
+ P(s), P(r), P(i), P(o);
1270
+ }, [o, i, r, s]), d = w(() => !!X(t, "boolean") && a.token === void 0, [a.token, t]), m = w(
1271
1271
  (b) => {
1272
1272
  W(t, b);
1273
1273
  },
1274
1274
  [t]
1275
- ), m = w(
1276
- (b, k) => {
1275
+ ), h = w(
1276
+ (b, S) => {
1277
1277
  if (!b) return;
1278
- const E = X(r, "boolean"), N = k ?? (typeof E == "boolean" ? E : !1);
1279
- u(b), D(t), W(s, b.token), W(r, N), typeof b.refreshToken == "string" && b.refreshToken.length ? W(i, b.refreshToken) : D(i), typeof b.accessTokenExpiresAt == "string" && b.accessTokenExpiresAt.length ? W(o, b.accessTokenExpiresAt) : D(o);
1278
+ const E = X(r, "boolean"), v = S ?? (typeof E == "boolean" ? E : !1);
1279
+ u(b), P(t), W(s, b.token), W(r, v), typeof b.refreshToken == "string" && b.refreshToken.length ? W(i, b.refreshToken) : P(i), typeof b.accessTokenExpiresAt == "string" && b.accessTokenExpiresAt.length ? W(o, b.accessTokenExpiresAt) : P(o);
1280
1280
  },
1281
1281
  [o, t, i, r, s]
1282
- ), f = w(async () => {
1283
- const b = X(s) ?? a.token, k = X(i) ?? (typeof a.refreshToken == "string" ? a.refreshToken : void 0);
1282
+ ), p = w(async () => {
1283
+ const b = X(s) ?? a.token, S = X(i) ?? (typeof a.refreshToken == "string" ? a.refreshToken : void 0);
1284
1284
  try {
1285
1285
  await c.Auth.logout({
1286
1286
  accessToken: b,
1287
- refreshToken: k
1287
+ refreshToken: S
1288
1288
  });
1289
1289
  } catch (E) {
1290
1290
  console.error(E);
@@ -1300,41 +1300,41 @@ const ee = () => {
1300
1300
  ]), y = w(async () => {
1301
1301
  try {
1302
1302
  const b = await c.Auth.getSession();
1303
- m(b);
1303
+ h(b);
1304
1304
  } catch (b) {
1305
- console.error(b), f();
1305
+ console.error(b), p();
1306
1306
  }
1307
- }, [m, f, c.Auth]), g = H(() => ({
1307
+ }, [h, p, c.Auth]), g = Q(() => ({
1308
1308
  account: a,
1309
- logUser: m,
1310
- logoutUser: f,
1309
+ logUser: h,
1310
+ logoutUser: p,
1311
1311
  logUserFromLocal: y,
1312
1312
  isInGuestMode: d,
1313
- setGuestMode: h
1313
+ setGuestMode: m
1314
1314
  }), [
1315
1315
  a,
1316
- m,
1317
- f,
1316
+ h,
1317
+ p,
1318
1318
  y,
1319
1319
  d,
1320
- h
1320
+ m
1321
1321
  ]);
1322
- return /* @__PURE__ */ p(je.Provider, { value: g, children: e });
1323
- }, Qe = () => {
1322
+ return /* @__PURE__ */ f(je.Provider, { value: g, children: e });
1323
+ }, He = () => {
1324
1324
  const n = ie(je);
1325
1325
  if (!n) throw new Error("authContext must be used within a Provider");
1326
1326
  return n;
1327
- }, He = re({}), Ms = (n) => {
1327
+ }, Qe = re({}), Ms = (n) => {
1328
1328
  const { children: e, location: t, navigate: s, linkComponent: r, searchComponent: i } = n;
1329
- return /* @__PURE__ */ p(
1330
- He.Provider,
1329
+ return /* @__PURE__ */ f(
1330
+ Qe.Provider,
1331
1331
  {
1332
1332
  value: { location: t, navigate: s, linkComponent: r, searchComponent: i },
1333
1333
  children: e
1334
1334
  }
1335
1335
  );
1336
1336
  }, ce = () => {
1337
- const n = ie(He);
1337
+ const n = ie(Qe);
1338
1338
  if (n === void 0 || Object.keys(n).length === 0)
1339
1339
  throw new Error(
1340
1340
  "Config provider has not been set. This step is required and cannot be skipped."
@@ -1360,7 +1360,7 @@ const ee = () => {
1360
1360
  ), i = w(
1361
1361
  (a, u) => s((l) => ({
1362
1362
  ...l,
1363
- [a]: (l[a] ?? []).filter((d, h) => h !== u)
1363
+ [a]: (l[a] ?? []).filter((d, m) => m !== u)
1364
1364
  })),
1365
1365
  []
1366
1366
  ), o = w((a) => {
@@ -1368,7 +1368,7 @@ const ee = () => {
1368
1368
  ...u,
1369
1369
  [a]: []
1370
1370
  }) : {});
1371
- }, []), c = H(
1371
+ }, []), c = Q(
1372
1372
  () => ({
1373
1373
  dynamicItems: t,
1374
1374
  addChildItem: r,
@@ -1377,36 +1377,36 @@ const ee = () => {
1377
1377
  }),
1378
1378
  [t, o, i, r]
1379
1379
  );
1380
- return /* @__PURE__ */ p(
1380
+ return /* @__PURE__ */ f(
1381
1381
  Ve.Provider,
1382
1382
  {
1383
1383
  value: c,
1384
1384
  children: e
1385
1385
  }
1386
1386
  );
1387
- }, Qt = () => ie(Ve);
1387
+ }, Ht = () => ie(Ve);
1388
1388
  function Ps(n) {
1389
- const { t: e } = T(), { open: t, onClose: s, menuMap: r, logo: i } = n, { account: o } = Qe(), { dynamicItems: c } = Qt(), { linkComponent: a, location: u } = ce(), l = a, d = H(() => r.filter((g) => {
1390
- const b = g.auth, k = !!(o != null && o.email);
1391
- return b == null || b && k || !b && !k;
1392
- }), [o == null ? void 0 : o.email, r]), h = w(
1389
+ const { t: e } = N(), { open: t, onClose: s, menuMap: r, logo: i } = n, { account: o } = He(), { dynamicItems: c } = Ht(), { linkComponent: a, location: u } = ce(), l = a, d = Q(() => r.filter((g) => {
1390
+ const b = g.auth, S = !!(o != null && o.email);
1391
+ return b == null || b && S || !b && !S;
1392
+ }), [o == null ? void 0 : o.email, r]), m = w(
1393
1393
  (g) => {
1394
1394
  g.key === "Escape" && t && s();
1395
1395
  },
1396
1396
  [s, t]
1397
1397
  );
1398
- O(() => (document.addEventListener("keydown", h), () => {
1399
- document.removeEventListener("keydown", h);
1400
- }), [h]);
1401
- const m = w(
1398
+ O(() => (document.addEventListener("keydown", m), () => {
1399
+ document.removeEventListener("keydown", m);
1400
+ }), [m]);
1401
+ const h = w(
1402
1402
  (g, b) => b ? g === `${u.pathname}${u.search}` : g === u.pathname,
1403
1403
  [u.pathname, u.search]
1404
- ), f = w(
1405
- (g) => /* @__PURE__ */ p(
1404
+ ), p = w(
1405
+ (g) => /* @__PURE__ */ f(
1406
1406
  "li",
1407
1407
  {
1408
- className: `drawer-list-item-child ${m(g.path, !0) ? "active" : ""} animated`,
1409
- children: g.path ? /* @__PURE__ */ p(
1408
+ className: `drawer-list-item-child ${h(g.path, !0) ? "active" : ""} animated`,
1409
+ children: g.path ? /* @__PURE__ */ f(
1410
1410
  l,
1411
1411
  {
1412
1412
  tabIndex: t ? 0 : -1,
@@ -1421,14 +1421,14 @@ function Ps(n) {
1421
1421
  },
1422
1422
  g.id
1423
1423
  ),
1424
- [l, t, e, m]
1425
- ), y = H(() => d.map((g, b) => {
1426
- const k = g.page ?? String(b), E = `drawer-list-item ${m(g.path) ? "active" : ""} animated`;
1424
+ [l, t, e, h]
1425
+ ), y = Q(() => d.map((g, b) => {
1426
+ const S = g.page ?? String(b), E = `drawer-list-item ${h(g.path) ? "active" : ""} animated`;
1427
1427
  if (g.type === "divider")
1428
- return /* @__PURE__ */ p("li", { className: E, children: /* @__PURE__ */ p("hr", { className: "drawer-divider" }) }, k);
1429
- const N = g.children ?? (g.page && c ? c[g.page] : null);
1430
- return /* @__PURE__ */ S("li", { className: E, children: [
1431
- /* @__PURE__ */ S(
1428
+ return /* @__PURE__ */ f("li", { className: E, children: /* @__PURE__ */ f("hr", { className: "drawer-divider" }) }, S);
1429
+ const v = g.children ?? (g.page && c ? c[g.page] : null);
1430
+ return /* @__PURE__ */ k("li", { className: E, children: [
1431
+ /* @__PURE__ */ k(
1432
1432
  l,
1433
1433
  {
1434
1434
  tabIndex: t ? 0 : -1,
@@ -1443,29 +1443,29 @@ function Ps(n) {
1443
1443
  ]
1444
1444
  }
1445
1445
  ),
1446
- N && /* @__PURE__ */ p("ul", { className: "drawer-children-list", children: N.map(f) })
1447
- ] }, k);
1448
- }), [l, c, m, t, d, f, e]);
1449
- return /* @__PURE__ */ p(
1446
+ v && /* @__PURE__ */ f("ul", { className: "drawer-children-list", children: v.map(p) })
1447
+ ] }, S);
1448
+ }), [l, c, h, t, d, p, e]);
1449
+ return /* @__PURE__ */ f(
1450
1450
  "div",
1451
1451
  {
1452
1452
  "aria-label": e("_accessibility:ariaLabels.closeMenu"),
1453
1453
  "aria-disabled": !t,
1454
1454
  className: `${t ? "opened" : "closed"} drawer-backdrop`,
1455
1455
  onClick: () => s(),
1456
- children: /* @__PURE__ */ S("aside", { className: `${t ? "opened" : "closed"} drawer animated`, children: [
1457
- /* @__PURE__ */ S("div", { className: "drawer-header-container", children: [
1456
+ children: /* @__PURE__ */ k("aside", { className: `${t ? "opened" : "closed"} drawer animated`, children: [
1457
+ /* @__PURE__ */ k("div", { className: "drawer-header-container", children: [
1458
1458
  i,
1459
- /* @__PURE__ */ p("h2", { className: "drawer-header poppins", children: e("_pages:home.appName") })
1459
+ /* @__PURE__ */ f("h2", { className: "drawer-header poppins", children: e("_pages:home.appName") })
1460
1460
  ] }),
1461
- /* @__PURE__ */ p("ul", { className: "drawer-menu-list", children: y })
1461
+ /* @__PURE__ */ f("ul", { className: "drawer-menu-list", children: y })
1462
1462
  ] })
1463
1463
  }
1464
1464
  );
1465
1465
  }
1466
- const G = ({ icon: n, ...e }) => /* @__PURE__ */ p(ct, { icon: /* @__PURE__ */ p(P, { icon: n }), ...e });
1466
+ const G = ({ icon: n, ...e }) => /* @__PURE__ */ f(ct, { icon: /* @__PURE__ */ f(K, { icon: n }), ...e });
1467
1467
  var we, $e;
1468
- function Ht() {
1468
+ function Qt() {
1469
1469
  if ($e) return we;
1470
1470
  $e = 1;
1471
1471
  const n = (c, a = "local", u = void 0) => {
@@ -1478,8 +1478,8 @@ function Ht() {
1478
1478
  }, e = (c) => {
1479
1479
  const a = {};
1480
1480
  return c.substring(1).split("&").forEach((l) => {
1481
- const [d, h] = l.split("=");
1482
- a[d] = h;
1481
+ const [d, m] = l.split("=");
1482
+ a[d] = m;
1483
1483
  }), a;
1484
1484
  }, t = (c = "") => {
1485
1485
  if (i(c) && c.length) return i(c);
@@ -1494,18 +1494,18 @@ function Ht() {
1494
1494
  left: a,
1495
1495
  behavior: l
1496
1496
  }), r = (c, a, u, l = "/", d = "Lax") => {
1497
- var h = /* @__PURE__ */ new Date();
1498
- h.setTime(h.getTime() + a * 24 * 60 * 60 * 1e3);
1499
- const m = "; expires=" + h.toUTCString();
1500
- document.cookie = `${c}=${u || ""}${m};path=${l};SameSite=${d}`;
1497
+ var m = /* @__PURE__ */ new Date();
1498
+ m.setTime(m.getTime() + a * 24 * 60 * 60 * 1e3);
1499
+ const h = "; expires=" + m.toUTCString();
1500
+ document.cookie = `${c}=${u || ""}${h};path=${l};SameSite=${d}`;
1501
1501
  }, i = (c) => {
1502
1502
  const a = `${c}=`, l = decodeURIComponent(document.cookie).split(";");
1503
1503
  for (let d = 0; d < l.length; d += 1) {
1504
- let h = l[d];
1505
- for (; h.charAt(0) === " "; )
1506
- h = h.substring(1);
1507
- if (h.indexOf(a) === 0)
1508
- return h.substring(a.length, h.length);
1504
+ let m = l[d];
1505
+ for (; m.charAt(0) === " "; )
1506
+ m = m.substring(1);
1507
+ if (m.indexOf(a) === 0)
1508
+ return m.substring(a.length, m.length);
1509
1509
  }
1510
1510
  return "";
1511
1511
  };
@@ -1519,13 +1519,13 @@ function Ht() {
1519
1519
  validation: n
1520
1520
  }, we;
1521
1521
  }
1522
- var Vt = Ht();
1522
+ var Vt = Qt();
1523
1523
  function Ks() {
1524
- const { t: n, language: e } = T();
1524
+ const { t: n, language: e } = N();
1525
1525
  return { timeAge: w(
1526
1526
  (s) => {
1527
- const i = /* @__PURE__ */ new Date() - s, o = Math.floor(i / (1e3 * 60)), c = Math.floor(o / 60), a = e === "es", u = n("_accessibility:labels.ago"), l = n("_accessibility:labels.minute"), d = n("_accessibility:labels.minutes"), h = n("_accessibility:labels.hour"), m = n("_accessibility:labels.hours"), f = n("_accessibility:labels.yesterday"), y = n("_accessibility:labels.justNow");
1528
- return i < 1e3 * 60 ? y : o < 60 ? `${a ? u : ""} ${o} ${o === 1 ? l : d} ${a ? "" : u}` : c < 24 ? `${a ? u : ""} ${c} ${c === 1 ? h : m} ${a ? "" : u}` : c < 48 ? f : s.toLocaleDateString(navigator.language || "es-ES", {
1527
+ const i = /* @__PURE__ */ new Date() - s, o = Math.floor(i / (1e3 * 60)), c = Math.floor(o / 60), a = e === "es", u = n("_accessibility:labels.ago"), l = n("_accessibility:labels.minute"), d = n("_accessibility:labels.minutes"), m = n("_accessibility:labels.hour"), h = n("_accessibility:labels.hours"), p = n("_accessibility:labels.yesterday"), y = n("_accessibility:labels.justNow");
1528
+ return i < 1e3 * 60 ? y : o < 60 ? `${a ? u : ""} ${o} ${o === 1 ? l : d} ${a ? "" : u}` : c < 24 ? `${a ? u : ""} ${c} ${c === 1 ? m : h} ${a ? "" : u}` : c < 48 ? p : s.toLocaleDateString(navigator.language || "es-ES", {
1529
1529
  day: "2-digit",
1530
1530
  month: "2-digit",
1531
1531
  year: "numeric"
@@ -1537,24 +1537,24 @@ function Ks() {
1537
1537
  const Be = (n) => {
1538
1538
  const { showSuccessNotification: e } = ee(), { mutationFn: t, onError: s, onSuccess: r, onSuccessMessage: i } = n, [o, c] = _([]), { open: a, handleClose: u, handleOpen: l } = We(), d = () => {
1539
1539
  u(), c([]);
1540
- }, h = async (f) => {
1541
- c(f), l();
1542
- }, m = Z({
1540
+ }, m = async (p) => {
1541
+ c(p), l();
1542
+ }, h = Z({
1543
1543
  mutationFn: () => t(
1544
1544
  Array.isArray(o) ? o : [o]
1545
1545
  ),
1546
- onError: (f) => {
1547
- console.error(f), s && s(f), d();
1546
+ onError: (p) => {
1547
+ console.error(p), s && s(p), d();
1548
1548
  },
1549
- onSuccess: async (f) => {
1550
- r && r(f), e({
1549
+ onSuccess: async (p) => {
1550
+ r && r(p), e({
1551
1551
  message: i
1552
1552
  }), d();
1553
1553
  }
1554
1554
  });
1555
- return { open: a, onClick: h, close: d, dialogFn: m, isLoading: m.isPending };
1555
+ return { open: a, onClick: m, close: d, dialogFn: h, isLoading: h.isPending };
1556
1556
  }, qs = (n) => {
1557
- const { t: e } = T(), {
1557
+ const { t: e } = N(), {
1558
1558
  showStackNotifications: t,
1559
1559
  showSuccessNotification: s,
1560
1560
  showErrorNotification: r
@@ -1565,19 +1565,19 @@ const Be = (n) => {
1565
1565
  onError: u,
1566
1566
  onSuccess: l,
1567
1567
  queryKey: d,
1568
- onSuccessMessage: h
1569
- } = n, { control: m, handleSubmit: f, reset: y, setError: g, getValues: b, setValue: k } = Me({
1568
+ onSuccessMessage: m
1569
+ } = n, { control: h, handleSubmit: p, reset: y, setError: g, getValues: b, setValue: S } = Me({
1570
1570
  defaultValues: o
1571
- }), E = K(null), N = w(() => {
1572
- const v = document.activeElement;
1573
- if (!(v instanceof HTMLElement)) {
1571
+ }), E = M(null), v = w(() => {
1572
+ const C = document.activeElement;
1573
+ if (!(C instanceof HTMLElement)) {
1574
1574
  E.current = null;
1575
1575
  return;
1576
1576
  }
1577
- E.current = v.closest("form");
1577
+ E.current = C.closest("form");
1578
1578
  }, []), $ = w(
1579
- (v) => {
1580
- const A = v == null ? void 0 : v.errors, x = [], q = E.current;
1579
+ (C) => {
1580
+ const A = C == null ? void 0 : C.errors, x = [], q = E.current;
1581
1581
  if (!q) return x;
1582
1582
  let V = !1;
1583
1583
  return A && A.forEach(([le, ge]) => {
@@ -1587,18 +1587,18 @@ const Be = (n) => {
1587
1587
  },
1588
1588
  [e, d]
1589
1589
  ), j = w(() => {
1590
- const v = E.current;
1591
- if (!v) return;
1592
- v.querySelectorAll("input, textarea, select").forEach((x) => {
1590
+ const C = E.current;
1591
+ if (!C) return;
1592
+ C.querySelectorAll("input, textarea, select").forEach((x) => {
1593
1593
  x.classList.remove("error");
1594
1594
  });
1595
1595
  }, []), I = Z(
1596
1596
  {
1597
1597
  mutationFn: c,
1598
- onError: (v) => {
1599
- console.error(v);
1600
- const A = v;
1601
- if (u) u(v);
1598
+ onError: (C) => {
1599
+ console.error(C);
1600
+ const A = C;
1601
+ if (u) u(C);
1602
1602
  else if (he(A)) {
1603
1603
  const x = $(A);
1604
1604
  t(
@@ -1615,21 +1615,21 @@ const Be = (n) => {
1615
1615
  } else
1616
1616
  r({ message: e("_accessibility:errors.500") });
1617
1617
  },
1618
- onSuccess: async (v) => {
1619
- await i.invalidateQueries({ queryKey: d }), l && l(v), h && s({
1620
- message: h
1618
+ onSuccess: async (C) => {
1619
+ await i.invalidateQueries({ queryKey: d }), l && l(C), m && s({
1620
+ message: m
1621
1621
  });
1622
1622
  }
1623
1623
  }
1624
1624
  );
1625
1625
  return {
1626
- control: m,
1626
+ control: h,
1627
1627
  getValues: b,
1628
- setValue: k,
1629
- handleSubmit: f,
1630
- onSubmit: (v) => {
1631
- N(), j(), I.mutate(
1632
- a ? a(v) : v
1628
+ setValue: S,
1629
+ handleSubmit: p,
1630
+ onSubmit: (C) => {
1631
+ v(), j(), I.mutate(
1632
+ a ? a(C) : C
1633
1633
  );
1634
1634
  },
1635
1635
  reset: y,
@@ -1637,7 +1637,7 @@ const Be = (n) => {
1637
1637
  isLoading: I.isPending
1638
1638
  };
1639
1639
  }, Bt = (n) => {
1640
- const { t: e } = T(), {
1640
+ const { t: e } = N(), {
1641
1641
  onClick: t,
1642
1642
  icon: s = yt,
1643
1643
  sticky: r = !0,
@@ -1657,14 +1657,14 @@ const Be = (n) => {
1657
1657
  onClick: () => t([d == null ? void 0 : d.id]),
1658
1658
  hidden: !!d.deletedAt || i,
1659
1659
  disabled: !!d.deletedAt || c,
1660
- icon: /* @__PURE__ */ p(P, { className: "text-bg-error", icon: s }),
1661
- onMultipleClick: (h) => t(h.map((m) => m.id))
1660
+ icon: /* @__PURE__ */ f(K, { className: "text-bg-error", icon: s }),
1661
+ onMultipleClick: (m) => t(m.map((h) => h.id))
1662
1662
  }),
1663
1663
  [c, i, s, a, o, t, r, u]
1664
1664
  )
1665
1665
  };
1666
1666
  }, Wt = (n) => {
1667
- const { t: e } = T(), {
1667
+ const { t: e } = N(), {
1668
1668
  onClick: t,
1669
1669
  sticky: s = !0,
1670
1670
  hidden: r = !1,
@@ -1684,14 +1684,14 @@ const Be = (n) => {
1684
1684
  onClick: () => t([d == null ? void 0 : d.id]),
1685
1685
  hidden: !d.deletedAt || r,
1686
1686
  disabled: !d.deletedAt || i,
1687
- icon: /* @__PURE__ */ p(P, { className: "text-bg-error", icon: c }),
1688
- onMultipleClick: (h) => t(h.map((m) => m.id))
1687
+ icon: /* @__PURE__ */ f(K, { className: "text-bg-error", icon: c }),
1688
+ onMultipleClick: (m) => t(m.map((h) => h.id))
1689
1689
  }),
1690
1690
  [i, r, c, a, o, t, s, u]
1691
1691
  )
1692
1692
  };
1693
1693
  }, Us = (n) => {
1694
- const { t: e } = T(), {
1694
+ const { t: e } = N(), {
1695
1695
  onClick: t,
1696
1696
  hidden: s = !1,
1697
1697
  sticky: r = !0,
@@ -1709,7 +1709,7 @@ const Be = (n) => {
1709
1709
  onClick: () => t(l == null ? void 0 : l.id),
1710
1710
  hidden: !!l.deletedAt || s,
1711
1711
  disabled: !!l.deletedAt || i,
1712
- icon: /* @__PURE__ */ p(P, { className: "primary", icon: c })
1712
+ icon: /* @__PURE__ */ f(K, { className: "primary", icon: c })
1713
1713
  }),
1714
1714
  [i, s, c, o, t, r, a]
1715
1715
  )
@@ -1717,7 +1717,7 @@ const Be = (n) => {
1717
1717
  };
1718
1718
  var z = /* @__PURE__ */ ((n) => (n.Add = "add", n.Edit = "edit", n.Delete = "delete", n.Restore = "restore", n.Refresh = "refresh", n.Export = "export", n.Import = "import", n))(z || {});
1719
1719
  const Gt = (n) => {
1720
- const { t: e } = T(), {
1720
+ const { t: e } = N(), {
1721
1721
  onClick: t,
1722
1722
  hidden: s = !1,
1723
1723
  disabled: r = !1,
@@ -1729,8 +1729,8 @@ const Gt = (n) => {
1729
1729
  id: z.Export,
1730
1730
  hidden: s,
1731
1731
  disabled: r,
1732
- icon: /* @__PURE__ */ p(
1733
- P,
1732
+ icon: /* @__PURE__ */ f(
1733
+ K,
1734
1734
  {
1735
1735
  className: `${i ? "rotate" : ""}`,
1736
1736
  icon: i ? Ie : wt
@@ -1743,7 +1743,7 @@ const Gt = (n) => {
1743
1743
  )
1744
1744
  };
1745
1745
  }, zt = (n) => {
1746
- const { t: e } = T(), {
1746
+ const { t: e } = N(), {
1747
1747
  onClick: t,
1748
1748
  hidden: s = !1,
1749
1749
  disabled: r = !1,
@@ -1755,8 +1755,8 @@ const Gt = (n) => {
1755
1755
  id: z.Import,
1756
1756
  hidden: s,
1757
1757
  disabled: r,
1758
- icon: /* @__PURE__ */ p(
1759
- P,
1758
+ icon: /* @__PURE__ */ f(
1759
+ K,
1760
1760
  {
1761
1761
  className: `${i ? "rotate" : ""}`,
1762
1762
  icon: i ? Ie : St
@@ -1769,21 +1769,21 @@ const Gt = (n) => {
1769
1769
  )
1770
1770
  };
1771
1771
  }, js = (n) => {
1772
- const { queryKey: e, onSuccess: t, ...s } = n, r = J(), { showStackNotifications: i } = ee(), { t: o } = T(), { open: c, onClick: a, close: u, dialogFn: l, isLoading: d } = Be({
1772
+ const { queryKey: e, onSuccess: t, ...s } = n, r = J(), { showStackNotifications: i } = ee(), { t: o } = N(), { open: c, onClick: a, close: u, dialogFn: l, isLoading: d } = Be({
1773
1773
  onSuccessMessage: o("_pages:common.actions.delete.successMessage"),
1774
- onError: (m) => {
1775
- const f = m;
1776
- if (he(f))
1774
+ onError: (h) => {
1775
+ const p = h;
1776
+ if (he(p))
1777
1777
  i(
1778
- f.errors.map(
1778
+ p.errors.map(
1779
1779
  ([y, g]) => ({
1780
1780
  message: o(`_pages:${y}.errors.${g}`),
1781
1781
  type: R.error
1782
1782
  })
1783
1783
  )
1784
1784
  );
1785
- else if (fe(f)) {
1786
- const y = f.message || o("_accessibility:errors.500"), g = o(`_accessibility:errors.${f.status}`);
1785
+ else if (fe(p)) {
1786
+ const y = p.message || o("_accessibility:errors.500"), g = o(`_accessibility:errors.${p.status}`);
1787
1787
  i([
1788
1788
  {
1789
1789
  message: g || y,
@@ -1792,11 +1792,11 @@ const Gt = (n) => {
1792
1792
  ]);
1793
1793
  }
1794
1794
  },
1795
- onSuccess: async (m) => {
1796
- await r.invalidateQueries({ queryKey: e }), t && t(m);
1795
+ onSuccess: async (h) => {
1796
+ await r.invalidateQueries({ queryKey: e }), t && t(h);
1797
1797
  },
1798
1798
  ...s
1799
- }), { action: h } = Bt({ onClick: a });
1799
+ }), { action: m } = Bt({ onClick: a });
1800
1800
  return {
1801
1801
  onClick: a,
1802
1802
  title: o("_pages:common.actions.delete.dialog.title"),
@@ -1804,25 +1804,25 @@ const Gt = (n) => {
1804
1804
  isLoading: d,
1805
1805
  handleSubmit: () => l.mutate(),
1806
1806
  handleClose: u,
1807
- action: h
1807
+ action: m
1808
1808
  };
1809
1809
  }, We = () => {
1810
1810
  const [n, e] = _(!1);
1811
1811
  return { open: n, setOpen: e, handleClose: () => e(!1), handleOpen: () => e(!0) };
1812
1812
  }, Jt = (n) => "mutationFn" in n && "queryKey" in n, pe = (n) => {
1813
- const e = Jt(n), t = e ? n : void 0, s = e ? void 0 : n, r = e ? "entity" : (s == null ? void 0 : s.mode) ?? "state", { t: i } = T(), o = J(), {
1813
+ const e = Jt(n), t = e ? n : void 0, s = e ? void 0 : n, r = e ? "entity" : (s == null ? void 0 : s.mode) ?? "state", { t: i } = N(), o = J(), {
1814
1814
  showErrorNotification: c,
1815
1815
  showStackNotifications: a,
1816
1816
  showSuccessNotification: u
1817
- } = ee(), [l, d] = _(), [h, m] = _(!1), f = K(!1), y = K(), { open: g, handleClose: b, handleOpen: k } = We(), { control: E, handleSubmit: N, reset: $, setError: j, getValues: I, setValue: v } = Me({
1817
+ } = ee(), [l, d] = _(), [m, h] = _(!1), p = M(!1), y = M(), { open: g, handleClose: b, handleOpen: S } = We(), { control: E, handleSubmit: v, reset: $, setError: j, getValues: I, setValue: C } = Me({
1818
1818
  defaultValues: (t == null ? void 0 : t.defaultValues) || (s == null ? void 0 : s.defaultValues) || {}
1819
- }), A = K(null), x = w(() => {
1820
- const C = document.activeElement;
1821
- if (!(C instanceof HTMLElement)) {
1819
+ }), A = M(null), x = w(() => {
1820
+ const T = document.activeElement;
1821
+ if (!(T instanceof HTMLElement)) {
1822
1822
  A.current = null;
1823
1823
  return;
1824
1824
  }
1825
- A.current = C.closest("form");
1825
+ A.current = T.closest("form");
1826
1826
  }, []), q = t ? [...t.queryKey, l ?? 0] : ["__legacy-form-dialog-disabled__", l ?? 0], { data: V, isLoading: le } = Oe({
1827
1827
  queryFn: async () => {
1828
1828
  if (!(!(t != null && t.getFunction) || !l))
@@ -1836,11 +1836,11 @@ const Gt = (n) => {
1836
1836
  }, [V, t, $]), O(() => {
1837
1837
  if (s) {
1838
1838
  if (!g) {
1839
- f.current = !1;
1839
+ p.current = !1;
1840
1840
  return;
1841
1841
  }
1842
- if (!f.current) {
1843
- if (f.current = !0, s.reinitializeOnOpen && s.mapIn) {
1842
+ if (!p.current) {
1843
+ if (p.current = !0, s.reinitializeOnOpen && s.mapIn) {
1844
1844
  $(s.mapIn());
1845
1845
  return;
1846
1846
  }
@@ -1853,109 +1853,109 @@ const Gt = (n) => {
1853
1853
  }
1854
1854
  }, [s, g, $]);
1855
1855
  const ge = w(
1856
- (C) => {
1857
- const M = C == null ? void 0 : C.errors, Q = [], te = A.current;
1858
- if (!te || !t) return Q;
1856
+ (T) => {
1857
+ const D = T == null ? void 0 : T.errors, H = [], te = A.current;
1858
+ if (!te || !t) return H;
1859
1859
  let Ce = !1;
1860
- return M && M.forEach(([Te, Ze]) => {
1860
+ return D && D.forEach(([Te, Ze]) => {
1861
1861
  const oe = te.querySelector(`[name="${Te}"]`);
1862
- (oe instanceof HTMLInputElement || oe instanceof HTMLTextAreaElement || oe instanceof HTMLSelectElement) && (Ce || (oe.focus(), Ce = !0), oe.classList.add("error"), Q.push(
1862
+ (oe instanceof HTMLInputElement || oe instanceof HTMLTextAreaElement || oe instanceof HTMLSelectElement) && (Ce || (oe.focus(), Ce = !0), oe.classList.add("error"), H.push(
1863
1863
  i(`_entities:${t.queryKey}.${Te}.${Ze}`)
1864
1864
  ));
1865
- }), Q;
1865
+ }), H;
1866
1866
  },
1867
1867
  [t, i]
1868
1868
  ), B = w(() => {
1869
- const C = A.current;
1870
- if (!C) return;
1871
- C.querySelectorAll("input, textarea, select").forEach((Q) => {
1872
- Q.classList.remove("error");
1869
+ const T = A.current;
1870
+ if (!T) return;
1871
+ T.querySelectorAll("input, textarea, select").forEach((H) => {
1872
+ H.classList.remove("error");
1873
1873
  });
1874
1874
  }, []), Y = w(() => {
1875
1875
  B(), A.current = null, b(), $();
1876
1876
  }, [b, B, $]), ze = w(
1877
- (C) => {
1878
- d(C), k();
1877
+ (T) => {
1878
+ d(T), S();
1879
1879
  },
1880
- [k]
1880
+ [S]
1881
1881
  ), ye = Z({
1882
- mutationFn: async (C) => {
1882
+ mutationFn: async (T) => {
1883
1883
  if (t)
1884
- return t.mutationFn(C);
1884
+ return t.mutationFn(T);
1885
1885
  },
1886
- onError: (C) => {
1886
+ onError: (T) => {
1887
1887
  if (t)
1888
- if (t.onError) t.onError(C);
1888
+ if (t.onError) t.onError(T);
1889
1889
  else {
1890
- const M = C;
1891
- if (he(M)) {
1892
- const Q = ge(M);
1890
+ const D = T;
1891
+ if (he(D)) {
1892
+ const H = ge(D);
1893
1893
  a(
1894
- Q.map(
1894
+ H.map(
1895
1895
  (te) => ({
1896
1896
  message: te,
1897
1897
  type: R.error
1898
1898
  })
1899
1899
  )
1900
1900
  );
1901
- } else if (fe(M)) {
1902
- const Q = M.message || i("_accessibility:errors.500"), te = i(`_accessibility:errors.${M.status}`);
1903
- c({ message: te || Q });
1901
+ } else if (fe(D)) {
1902
+ const H = D.message || i("_accessibility:errors.500"), te = i(`_accessibility:errors.${D.status}`);
1903
+ c({ message: te || H });
1904
1904
  } else
1905
1905
  c({ message: i("_accessibility:errors.500") });
1906
1906
  }
1907
1907
  },
1908
- onSuccess: async (C) => {
1909
- t && (await o.invalidateQueries({ queryKey: t.queryKey }), t.onSuccess && await t.onSuccess(C), u({
1908
+ onSuccess: async (T) => {
1909
+ t && (await o.invalidateQueries({ queryKey: t.queryKey }), t.onSuccess && await t.onSuccess(T), u({
1910
1910
  message: t.onSuccessMessage
1911
1911
  }), Y());
1912
1912
  }
1913
1913
  }), ue = w(
1914
- (C) => t ? C : s != null && s.mapOut ? s.mapOut(C, { id: l }) : C,
1914
+ (T) => t ? T : s != null && s.mapOut ? s.mapOut(T, { id: l }) : T,
1915
1915
  [s, l, t]
1916
1916
  ), Je = w(async () => {
1917
1917
  if (!(s != null && s.onApply)) return;
1918
- const C = I(), M = ue(C);
1919
- m(!0);
1918
+ const T = I(), D = ue(T);
1919
+ h(!0);
1920
1920
  try {
1921
- await s.onApply(M, {
1921
+ await s.onApply(D, {
1922
1922
  close: Y,
1923
1923
  id: l,
1924
- values: C
1924
+ values: T
1925
1925
  });
1926
1926
  } finally {
1927
- m(!1);
1927
+ h(!1);
1928
1928
  }
1929
1929
  }, [Y, s, I, l, ue]), Ye = w(async () => {
1930
1930
  if (s) {
1931
1931
  if (s.onClear) {
1932
- m(!0);
1932
+ h(!0);
1933
1933
  try {
1934
1934
  await s.onClear();
1935
1935
  } finally {
1936
- m(!1);
1936
+ h(!1);
1937
1937
  }
1938
1938
  }
1939
1939
  $(s.defaultValues || {});
1940
1940
  }
1941
1941
  }, [s, $]), Xe = w(
1942
- async (C) => {
1942
+ async (T) => {
1943
1943
  if (t) {
1944
1944
  x(), ye.mutate(
1945
- t.formToDto ? t.formToDto(C) : C
1945
+ t.formToDto ? t.formToDto(T) : T
1946
1946
  );
1947
1947
  return;
1948
1948
  }
1949
- const M = ue(C);
1950
- m(!0);
1949
+ const D = ue(T);
1950
+ h(!0);
1951
1951
  try {
1952
- s != null && s.onSubmit && await s.onSubmit(M, {
1952
+ s != null && s.onSubmit && await s.onSubmit(D, {
1953
1953
  close: Y,
1954
1954
  id: l,
1955
- values: C
1955
+ values: T
1956
1956
  }), ((s == null ? void 0 : s.closeOnSubmit) ?? !0) && Y();
1957
1957
  } finally {
1958
- m(!1);
1958
+ h(!1);
1959
1959
  }
1960
1960
  },
1961
1961
  [
@@ -1976,18 +1976,18 @@ const Gt = (n) => {
1976
1976
  handleClose: Y,
1977
1977
  control: E,
1978
1978
  getValues: I,
1979
- setValue: v,
1980
- handleSubmit: N,
1979
+ setValue: C,
1980
+ handleSubmit: v,
1981
1981
  onSubmit: Xe,
1982
1982
  reset: $,
1983
1983
  setError: j,
1984
1984
  title: n.title,
1985
- isSubmitting: h,
1985
+ isSubmitting: m,
1986
1986
  onApply: Je,
1987
1987
  onClear: Ye,
1988
- isLoading: le || ye.isPending || h
1988
+ isLoading: le || ye.isPending || m
1989
1989
  };
1990
- }, Qs = pe, Hs = (n) => pe(n), Vs = (n) => {
1990
+ }, Hs = pe, Qs = (n) => pe(n), Vs = (n) => {
1991
1991
  const e = J(), { mutationFn: t, queryKey: s, onSuccess: r, onError: i, mapOut: o, ...c } = n, a = Z({
1992
1992
  mutationFn: t
1993
1993
  });
@@ -2005,64 +2005,68 @@ const Gt = (n) => {
2005
2005
  }
2006
2006
  });
2007
2007
  }, Bs = (n) => {
2008
- const e = J(), t = K(), {
2009
- mutationFn: s,
2010
- queryKey: r,
2011
- onSuccess: i,
2012
- onError: o,
2013
- mapOut: c,
2014
- getFunction: a,
2015
- dtoToForm: u,
2016
- title: l,
2017
- ...d
2018
- } = n, h = Z({
2019
- mutationFn: s
2020
- }), m = pe({
2021
- ...d,
2008
+ const e = J(), t = M(), s = M(), {
2009
+ mutationFn: r,
2010
+ queryKey: i,
2011
+ onSuccess: o,
2012
+ onError: c,
2013
+ mapOut: a,
2014
+ getFunction: u,
2015
+ dtoToForm: l,
2016
+ title: d,
2017
+ ...m
2018
+ } = n, h = M(l);
2019
+ O(() => {
2020
+ h.current = l;
2021
+ }, [l]);
2022
+ const p = Z({
2023
+ mutationFn: r
2024
+ }), y = pe({
2025
+ ...m,
2022
2026
  mode: "entity",
2023
- title: l,
2024
- onSubmit: async (b) => {
2027
+ title: d,
2028
+ onSubmit: async (E) => {
2025
2029
  try {
2026
- const k = await h.mutateAsync(b);
2027
- r && await e.invalidateQueries({ queryKey: r }), i && await i(k);
2028
- } catch (k) {
2029
- throw o && o(k), k;
2030
+ const v = await p.mutateAsync(E);
2031
+ i && await e.invalidateQueries({ queryKey: i }), o && await o(v);
2032
+ } catch (v) {
2033
+ throw c && c(v), v;
2030
2034
  }
2031
2035
  },
2032
- mapOut: (b) => c ? c(b, t.current) : b
2033
- }), { reset: f } = m, g = Oe({
2034
- queryFn: () => a(m.id),
2035
- queryKey: [...r || ["put-dialog", l], m.id],
2036
- enabled: m.open && !!m.id
2036
+ mapOut: (E) => a ? a(E, t.current) : E
2037
+ }), { reset: g } = y, S = Oe({
2038
+ queryFn: () => u(y.id),
2039
+ queryKey: [...i || ["put-dialog", d], y.id],
2040
+ enabled: y.open && !!y.id
2037
2041
  });
2038
2042
  return O(() => {
2039
- if (g.data) {
2040
- if (t.current = g.data, u && f) {
2041
- f(u(g.data));
2043
+ if (S.data && s.current !== S.data) {
2044
+ if (t.current = S.data, s.current = S.data, h.current && g) {
2045
+ g(h.current(S.data));
2042
2046
  return;
2043
2047
  }
2044
- f == null || f(g.data);
2048
+ g == null || g(S.data);
2045
2049
  }
2046
- }, [u, g.data, f]), {
2047
- ...m,
2048
- isLoading: m.isLoading || h.isPending || g.isFetching || g.isLoading
2050
+ }, [S.data, g]), {
2051
+ ...y,
2052
+ isLoading: y.isLoading || p.isPending || S.isFetching || S.isLoading
2049
2053
  };
2050
2054
  }, Ws = (n) => {
2051
- const { queryKey: e, onSuccess: t, ...s } = n, r = J(), { showStackNotifications: i } = ee(), { t: o } = T(), { open: c, onClick: a, close: u, dialogFn: l, isLoading: d } = Be({
2055
+ const { queryKey: e, onSuccess: t, ...s } = n, r = J(), { showStackNotifications: i } = ee(), { t: o } = N(), { open: c, onClick: a, close: u, dialogFn: l, isLoading: d } = Be({
2052
2056
  onSuccessMessage: o("_pages:common.actions.restore.successMessage"),
2053
- onError: (m) => {
2054
- const f = m;
2055
- if (he(f))
2057
+ onError: (h) => {
2058
+ const p = h;
2059
+ if (he(p))
2056
2060
  i(
2057
- f.errors.map(
2061
+ p.errors.map(
2058
2062
  ([y, g]) => ({
2059
2063
  message: o(`_pages:${y}.errors.${g}`),
2060
2064
  type: R.error
2061
2065
  })
2062
2066
  )
2063
2067
  );
2064
- else if (fe(f)) {
2065
- const y = f.message || o("_accessibility:errors.500"), g = o(`_accessibility:errors.${f.status}`);
2068
+ else if (fe(p)) {
2069
+ const y = p.message || o("_accessibility:errors.500"), g = o(`_accessibility:errors.${p.status}`);
2066
2070
  i([
2067
2071
  {
2068
2072
  message: g || y,
@@ -2071,11 +2075,11 @@ const Gt = (n) => {
2071
2075
  ]);
2072
2076
  }
2073
2077
  },
2074
- onSuccess: async (m) => {
2075
- await r.invalidateQueries({ queryKey: e }), t && t(m);
2078
+ onSuccess: async (h) => {
2079
+ await r.invalidateQueries({ queryKey: e }), t && t(h);
2076
2080
  },
2077
2081
  ...s
2078
- }), { action: h } = Wt({ onClick: a });
2082
+ }), { action: m } = Wt({ onClick: a });
2079
2083
  return {
2080
2084
  onClick: a,
2081
2085
  title: o("_pages:common.actions.restore.dialog.title"),
@@ -2083,18 +2087,18 @@ const Gt = (n) => {
2083
2087
  isLoading: d,
2084
2088
  handleSubmit: () => l.mutate(),
2085
2089
  handleClose: u,
2086
- action: h
2090
+ action: m
2087
2091
  };
2088
2092
  };
2089
2093
  function Gs(n) {
2090
- const { t: e } = T(), t = J(), {
2094
+ const { t: e } = N(), t = J(), {
2091
2095
  queryKey: s,
2092
2096
  mutationFn: r,
2093
2097
  entity: i,
2094
2098
  fileProcessor: o,
2095
2099
  renderCustomPreview: c,
2096
2100
  onError: a
2097
- } = n, [u, l] = _(!1), [d, h] = _(null), [m, f] = _(!1), y = Z({
2101
+ } = n, [u, l] = _(!1), [d, m] = _(null), [h, p] = _(!1), y = Z({
2098
2102
  mutationFn: r,
2099
2103
  onError: (b) => {
2100
2104
  console.error(b), a == null || a(b);
@@ -2111,29 +2115,29 @@ function Gs(n) {
2111
2115
  try {
2112
2116
  await y.mutateAsync({
2113
2117
  items: d,
2114
- override: m
2115
- }), l(!1), h(null), f(!1);
2118
+ override: h
2119
+ }), l(!1), m(null), p(!1);
2116
2120
  } catch (b) {
2117
2121
  console.error(b);
2118
2122
  }
2119
2123
  },
2120
2124
  isLoading: y.isPending,
2121
2125
  fileProcessor: o,
2122
- onFileProcessed: (b) => h(b),
2126
+ onFileProcessed: (b) => m(b),
2123
2127
  renderCustomPreview: c,
2124
- onOverrideChange: (b) => f(b),
2128
+ onOverrideChange: (b) => p(b),
2125
2129
  open: u,
2126
2130
  title: e("_pages:common.actions.import.dialog.title", {
2127
2131
  entity: e(`_pages:${i}.title`)
2128
2132
  }),
2129
2133
  handleClose: () => {
2130
- l(!1), h(null), f(!1);
2134
+ l(!1), m(null), p(!1);
2131
2135
  },
2132
2136
  action: g
2133
2137
  };
2134
2138
  }
2135
2139
  const zs = (n) => {
2136
- const { showSuccessNotification: e } = ee(), { t } = T(), {
2140
+ const { showSuccessNotification: e } = ee(), { t } = N(), {
2137
2141
  entity: s,
2138
2142
  mutationFn: r,
2139
2143
  onError: i,
@@ -2145,8 +2149,8 @@ const zs = (n) => {
2145
2149
  console.error(d), i && i(d);
2146
2150
  },
2147
2151
  onSuccess: async (d) => {
2148
- const h = JSON.stringify(d, null, 2), m = new Blob([h], { type: "application/json" }), f = URL.createObjectURL(m), y = document.createElement("a");
2149
- y.href = f, y.download = `${s}.json`, y.click(), URL.revokeObjectURL(f), o && o(d), e({
2152
+ const m = JSON.stringify(d, null, 2), h = new Blob([m], { type: "application/json" }), p = URL.createObjectURL(h), y = document.createElement("a");
2153
+ y.href = p, y.download = `${s}.json`, y.click(), URL.revokeObjectURL(p), o && o(d), e({
2150
2154
  message: c
2151
2155
  });
2152
2156
  }
@@ -2169,7 +2173,7 @@ function Yt(n) {
2169
2173
  }), [s]), e > n;
2170
2174
  }
2171
2175
  const Js = (n) => {
2172
- const { t: e } = T(), {
2176
+ const { t: e } = N(), {
2173
2177
  icon: t = kt,
2174
2178
  threshold: s = 200,
2175
2179
  scrollTop: r = 0,
@@ -2180,9 +2184,9 @@ const Js = (n) => {
2180
2184
  className: u = "",
2181
2185
  variant: l = "submit",
2182
2186
  color: d = "primary",
2183
- ...h
2184
- } = n, m = Yt(s);
2185
- return /* @__PURE__ */ p(
2187
+ ...m
2188
+ } = n, h = Yt(s);
2189
+ return /* @__PURE__ */ f(
2186
2190
  G,
2187
2191
  {
2188
2192
  variant: l,
@@ -2192,17 +2196,17 @@ const Js = (n) => {
2192
2196
  onClick: () => {
2193
2197
  a == null || a(), c && Vt.scrollTo(i, r);
2194
2198
  },
2195
- className: `to-top ${m ? "show" : "hide"} ${u}`.trim(),
2199
+ className: `to-top ${h ? "show" : "hide"} ${u}`.trim(),
2196
2200
  "data-tooltip-content": o,
2197
- ...h
2201
+ ...m
2198
2202
  }
2199
2203
  );
2200
2204
  };
2201
2205
  function Ys(n) {
2202
- const { t: e } = T();
2206
+ const { t: e } = N();
2203
2207
  if ("children" in n) {
2204
- const { children: N, className: $ } = n;
2205
- return /* @__PURE__ */ p("div", { className: `error-container${$ ? ` ${$}` : ""}`, children: N });
2208
+ const { children: v, className: $ } = n;
2209
+ return /* @__PURE__ */ f("div", { className: `error-container${$ ? ` ${$}` : ""}`, children: v });
2206
2210
  }
2207
2211
  const {
2208
2212
  error: s,
@@ -2214,50 +2218,50 @@ function Ys(n) {
2214
2218
  messageProps: u,
2215
2219
  className: l,
2216
2220
  resetErrorBoundary: d
2217
- } = n, h = o ?? d, {
2218
- className: m,
2219
- children: f,
2221
+ } = n, m = o ?? d, {
2222
+ className: h,
2223
+ children: p,
2220
2224
  onClick: y,
2221
2225
  ...g
2222
- } = a ?? {}, { className: b, ...k } = u ?? {}, E = i !== null;
2223
- return /* @__PURE__ */ S("div", { className: `error-container${l ? ` ${l}` : ""}`, children: [
2224
- E && /* @__PURE__ */ p(
2225
- P,
2226
+ } = a ?? {}, { className: b, ...S } = u ?? {}, E = i !== null;
2227
+ return /* @__PURE__ */ k("div", { className: `error-container${l ? ` ${l}` : ""}`, children: [
2228
+ E && /* @__PURE__ */ f(
2229
+ K,
2226
2230
  {
2227
2231
  ...i,
2228
2232
  icon: (i == null ? void 0 : i.icon) ?? Lt,
2229
2233
  className: `error-icon${i != null && i.className ? ` ${i.className}` : ""}`
2230
2234
  }
2231
2235
  ),
2232
- /* @__PURE__ */ p(
2236
+ /* @__PURE__ */ f(
2233
2237
  "p",
2234
2238
  {
2235
- ...k,
2239
+ ...S,
2236
2240
  className: `error-message${b ? ` ${b}` : ""}`,
2237
2241
  children: r ?? (s == null ? void 0 : s.message) ?? e("_accessibility:errors.unknownError")
2238
2242
  }
2239
2243
  ),
2240
- h && /* @__PURE__ */ p(
2244
+ m && /* @__PURE__ */ f(
2241
2245
  U,
2242
2246
  {
2243
2247
  type: "button",
2244
2248
  variant: "submit",
2245
2249
  color: "primary",
2246
2250
  ...g,
2247
- className: `error-retry ${m ? ` ${m}` : ""}`,
2248
- onClick: (N) => {
2249
- y == null || y(N), N.defaultPrevented || h();
2251
+ className: `error-retry ${h ? ` ${h}` : ""}`,
2252
+ onClick: (v) => {
2253
+ y == null || y(v), v.defaultPrevented || m();
2250
2254
  },
2251
- children: f ?? c ?? e("_accessibility:actions.retry", { defaultValue: "Retry" })
2255
+ children: p ?? c ?? e("_accessibility:actions.retry", { defaultValue: "Retry" })
2252
2256
  }
2253
2257
  )
2254
2258
  ] });
2255
2259
  }
2256
2260
  const Xt = (n) => {
2257
- const { showBackButton: e, title: t, actions: s } = n, { t: r } = T(), { navigate: i } = ce();
2258
- return /* @__PURE__ */ S("div", { className: "page-header", children: [
2259
- /* @__PURE__ */ S("div", { className: "page-header-left", children: [
2260
- e && /* @__PURE__ */ p(
2261
+ const { showBackButton: e, title: t, actions: s } = n, { t: r } = N(), { navigate: i } = ce();
2262
+ return /* @__PURE__ */ k("div", { className: "page-header", children: [
2263
+ /* @__PURE__ */ k("div", { className: "page-header-left", children: [
2264
+ e && /* @__PURE__ */ f(
2261
2265
  G,
2262
2266
  {
2263
2267
  icon: vt,
@@ -2268,17 +2272,17 @@ const Xt = (n) => {
2268
2272
  "data-tooltip-content": r("_accessibility:buttons.back")
2269
2273
  }
2270
2274
  ),
2271
- /* @__PURE__ */ p("h2", { className: "page-header-title", children: t })
2275
+ /* @__PURE__ */ f("h2", { className: "page-header-title", children: t })
2272
2276
  ] }),
2273
- /* @__PURE__ */ S("div", { children: [
2274
- /* @__PURE__ */ p(
2277
+ /* @__PURE__ */ k("div", { children: [
2278
+ /* @__PURE__ */ f(
2275
2279
  lt,
2276
2280
  {
2277
2281
  className: "page-header-actions-desktop",
2278
2282
  actions: s ?? []
2279
2283
  }
2280
2284
  ),
2281
- /* @__PURE__ */ p(
2285
+ /* @__PURE__ */ f(
2282
2286
  ut,
2283
2287
  {
2284
2288
  className: "page-header-actions-mobile",
@@ -2298,76 +2302,76 @@ const Xt = (n) => {
2298
2302
  isLoading: c = !1,
2299
2303
  isAnimated: a = !0,
2300
2304
  showBackButton: u = !1
2301
- } = n, { t: l } = T(), d = J(), { countOfFilters: h } = dt(), m = H(() => {
2302
- const f = Array.isArray(i) ? [...i] : [];
2305
+ } = n, { t: l } = N(), d = J(), { countOfFilters: m } = dt(), h = Q(() => {
2306
+ const p = Array.isArray(i) ? [...i] : [];
2303
2307
  if (o) {
2304
2308
  const y = {
2305
2309
  id: z.Refresh,
2306
2310
  onClick: () => d.invalidateQueries({ queryKey: o }),
2307
- icon: /* @__PURE__ */ p(P, { icon: Re }),
2311
+ icon: /* @__PURE__ */ f(K, { icon: Re }),
2308
2312
  tooltip: l("_pages:common.actions.refresh.text")
2309
2313
  };
2310
- f.unshift(y);
2314
+ p.unshift(y);
2311
2315
  }
2312
2316
  if (s) {
2313
2317
  const y = {
2314
2318
  ...s,
2315
2319
  id: z.Add,
2316
- icon: /* @__PURE__ */ p(P, { icon: Ne })
2320
+ icon: /* @__PURE__ */ f(K, { icon: Ne })
2317
2321
  };
2318
- f.unshift(y);
2322
+ p.unshift(y);
2319
2323
  }
2320
2324
  if (r) {
2321
2325
  const y = {
2322
2326
  ...r,
2323
2327
  id: "filter",
2324
- icon: /* @__PURE__ */ p(P, { icon: Ct }),
2325
- children: /* @__PURE__ */ p(
2328
+ icon: /* @__PURE__ */ f(K, { icon: Ct }),
2329
+ children: /* @__PURE__ */ f(
2326
2330
  mt,
2327
2331
  {
2328
- className: `${h > 0 ? "show" : "hide"} `,
2329
- count: h
2332
+ className: `${m > 0 ? "show" : "hide"} `,
2333
+ count: m
2330
2334
  }
2331
2335
  )
2332
2336
  };
2333
- f.push(y);
2337
+ p.push(y);
2334
2338
  }
2335
- return f;
2339
+ return p;
2336
2340
  }, [
2337
2341
  i,
2338
2342
  s,
2339
- h,
2343
+ m,
2340
2344
  r,
2341
2345
  d,
2342
2346
  o,
2343
2347
  l
2344
2348
  ]);
2345
- return /* @__PURE__ */ S("main", { className: "page-main", children: [
2346
- /* @__PURE__ */ p(
2349
+ return /* @__PURE__ */ k("main", { className: "page-main", children: [
2350
+ /* @__PURE__ */ f(
2347
2351
  Xt,
2348
2352
  {
2349
2353
  showBackButton: u,
2350
- actions: m,
2354
+ actions: h,
2351
2355
  title: e
2352
2356
  }
2353
2357
  ),
2354
- /* @__PURE__ */ p("div", { className: `page-main-content ${a ? "appear" : ""}`, children: c ? /* @__PURE__ */ p(ne, { className: "page-loading" }) : t }),
2355
- s && /* @__PURE__ */ p(
2358
+ /* @__PURE__ */ f("div", { className: `page-main-content ${a ? "appear" : ""}`, children: c ? /* @__PURE__ */ f(ne, { className: "page-loading" }) : t }),
2359
+ s && /* @__PURE__ */ f(
2356
2360
  G,
2357
2361
  {
2358
2362
  icon: s.icon ?? Ne,
2359
2363
  color: s.color ?? "primary",
2360
2364
  variant: s.variant ?? "submit",
2361
2365
  onClick: () => {
2362
- var f;
2363
- return (f = s.onClick) == null ? void 0 : f.call(s);
2366
+ var p;
2367
+ return (p = s.onClick) == null ? void 0 : p.call(s);
2364
2368
  },
2365
2369
  className: `button page-fab ${s.className ?? ""}`
2366
2370
  }
2367
2371
  )
2368
2372
  ] });
2369
2373
  }, Zs = (n) => {
2370
- const { t: e } = T(), {
2374
+ const { t: e } = N(), {
2371
2375
  className: t = "",
2372
2376
  itemClassName: s = "",
2373
2377
  loading: r = !1,
@@ -2378,10 +2382,10 @@ const Xt = (n) => {
2378
2382
  hasMore: u = !1,
2379
2383
  loadingMore: l = !1,
2380
2384
  onLoadMore: d,
2381
- loadMoreComponent: h = null,
2382
- observerRootMargin: m = "0px 0px 200px 0px",
2383
- observerThreshold: f = 0
2384
- } = n, y = K(!1), g = K(null), b = w(async () => {
2385
+ loadMoreComponent: m = null,
2386
+ observerRootMargin: h = "0px 0px 200px 0px",
2387
+ observerThreshold: p = 0
2388
+ } = n, y = M(!1), g = M(null), b = w(async () => {
2385
2389
  if (!(!u || !d) && !(l || y.current)) {
2386
2390
  y.current = !0;
2387
2391
  try {
@@ -2393,26 +2397,26 @@ const Xt = (n) => {
2393
2397
  }, [u, l, d]);
2394
2398
  return O(() => {
2395
2399
  if (!u || !d || !g.current || typeof IntersectionObserver > "u") return;
2396
- const k = new IntersectionObserver(
2400
+ const S = new IntersectionObserver(
2397
2401
  (E) => {
2398
- E.some((N) => N.isIntersecting) && b();
2402
+ E.some((v) => v.isIntersecting) && b();
2399
2403
  },
2400
2404
  {
2401
- rootMargin: m,
2402
- threshold: f
2405
+ rootMargin: h,
2406
+ threshold: p
2403
2407
  }
2404
2408
  );
2405
- return k.observe(g.current), () => k.disconnect();
2409
+ return S.observe(g.current), () => S.disconnect();
2406
2410
  }, [
2407
2411
  u,
2408
2412
  d,
2409
- m,
2410
- f,
2413
+ h,
2414
+ p,
2411
2415
  b
2412
- ]), r ? /* @__PURE__ */ p(ne, {}) : /* @__PURE__ */ p(ae, { children: a != null && a.length ? /* @__PURE__ */ S("ul", { className: `pretty-grid-main ${t}`, children: [
2413
- a == null ? void 0 : a.map((k) => /* @__PURE__ */ p("li", { className: `pretty-grid-item ${s}`, children: c(k) }, k.id)),
2414
- u && d && /* @__PURE__ */ p("li", { className: "pretty-grid-load-more", ref: g, children: h })
2415
- ] }) : /* @__PURE__ */ p(ae, { children: i || /* @__PURE__ */ p(os, { message: o }) }) });
2416
+ ]), r ? /* @__PURE__ */ f(ne, {}) : /* @__PURE__ */ f(ae, { children: a != null && a.length ? /* @__PURE__ */ k("ul", { className: `pretty-grid-main ${t}`, children: [
2417
+ a == null ? void 0 : a.map((S) => /* @__PURE__ */ f("li", { className: `pretty-grid-item ${s}`, children: c(S) }, S.id)),
2418
+ u && d && /* @__PURE__ */ f("li", { className: "pretty-grid-load-more", ref: g, children: m })
2419
+ ] }) : /* @__PURE__ */ f(ae, { children: i || /* @__PURE__ */ f(os, { message: o }) }) });
2416
2420
  }, Ge = re({
2417
2421
  title: "",
2418
2422
  setTitle: () => {
@@ -2425,7 +2429,7 @@ const Xt = (n) => {
2425
2429
  s(u);
2426
2430
  }, []), c = w((u) => {
2427
2431
  i(u);
2428
- }, []), a = H(
2432
+ }, []), a = Q(
2429
2433
  () => ({
2430
2434
  title: t,
2431
2435
  setTitle: o,
@@ -2434,40 +2438,40 @@ const Xt = (n) => {
2434
2438
  }),
2435
2439
  [t, o, r, c]
2436
2440
  );
2437
- return /* @__PURE__ */ p(Ge.Provider, { value: a, children: e });
2441
+ return /* @__PURE__ */ f(Ge.Provider, { value: a, children: e });
2438
2442
  }, Zt = () => ie(Ge);
2439
2443
  function tn(n) {
2440
- const { t: e } = T(), { openDrawer: t, showSearch: s = !0, menuButtonProps: r } = n, { searchComponent: i, location: o } = ce(), { title: c, rightContent: a } = Zt(), [u, l] = _(!1), d = w((f) => {
2441
- (qt() ? f.metaKey : f.ctrlKey) && f.shiftKey && f.key.toLowerCase() === "f" && (l(!0), f.preventDefault());
2444
+ const { t: e } = N(), { openDrawer: t, showSearch: s = !0, menuButtonProps: r } = n, { searchComponent: i, location: o } = ce(), { title: c, rightContent: a } = Zt(), [u, l] = _(!1), d = w((p) => {
2445
+ (qt() ? p.metaKey : p.ctrlKey) && p.shiftKey && p.key.toLowerCase() === "f" && (l(!0), p.preventDefault());
2442
2446
  }, []);
2443
2447
  O(() => (window.addEventListener("keydown", d), () => {
2444
2448
  window.removeEventListener("keydown", d);
2445
2449
  }), [d]);
2446
- const h = i, m = s && !!h;
2447
- return /* @__PURE__ */ S(ae, { children: [
2448
- o.pathname !== "/" && !!h && /* @__PURE__ */ p(h, { open: u, onClose: () => l(!1) }),
2449
- /* @__PURE__ */ S("header", { id: "header", className: "header", children: [
2450
- /* @__PURE__ */ S("div", { className: "navbar-left", children: [
2451
- /* @__PURE__ */ p(
2450
+ const m = i, h = s && !!m;
2451
+ return /* @__PURE__ */ k(ae, { children: [
2452
+ o.pathname !== "/" && !!m && /* @__PURE__ */ f(m, { open: u, onClose: () => l(!1) }),
2453
+ /* @__PURE__ */ k("header", { id: "header", className: "header", children: [
2454
+ /* @__PURE__ */ k("div", { className: "navbar-left", children: [
2455
+ /* @__PURE__ */ f(
2452
2456
  G,
2453
2457
  {
2454
2458
  ...r,
2455
2459
  type: (r == null ? void 0 : r.type) ?? "button",
2456
2460
  icon: (r == null ? void 0 : r.icon) ?? Tt,
2457
- onClick: (f) => {
2461
+ onClick: (p) => {
2458
2462
  var y;
2459
- (y = r == null ? void 0 : r.onClick) == null || y.call(r, f), t();
2463
+ (y = r == null ? void 0 : r.onClick) == null || y.call(r, p), t();
2460
2464
  },
2461
2465
  name: (r == null ? void 0 : r.name) ?? e("_accessibility:buttons.openMenu"),
2462
2466
  "aria-label": (r == null ? void 0 : r["aria-label"]) ?? e("_accessibility:ariaLabels.openMenu"),
2463
2467
  className: `navbar-menu animated ${(r == null ? void 0 : r.className) ?? ""}`
2464
2468
  }
2465
2469
  ),
2466
- /* @__PURE__ */ p("h1", { className: "poppins navbar-title", children: c || e("_pages:home.appName") })
2470
+ /* @__PURE__ */ f("h1", { className: "poppins navbar-title", children: c || e("_pages:home.appName") })
2467
2471
  ] }),
2468
- /* @__PURE__ */ S("div", { className: "navbar-right", children: [
2472
+ /* @__PURE__ */ k("div", { className: "navbar-right", children: [
2469
2473
  a,
2470
- m && /* @__PURE__ */ p(
2474
+ h && /* @__PURE__ */ f(
2471
2475
  G,
2472
2476
  {
2473
2477
  icon: Nt,
@@ -2510,11 +2514,11 @@ const de = 300, es = (n) => n ?? R.error, ts = (n) => {
2510
2514
  }
2511
2515
  };
2512
2516
  function sn() {
2513
- const { t: n } = T(), { notification: e, removeNotification: t } = ee(), [s, r] = _([]), i = K(s);
2517
+ const { t: n } = N(), { notification: e, removeNotification: t } = ee(), [s, r] = _([]), i = M(s);
2514
2518
  ft(() => {
2515
2519
  i.current = s;
2516
2520
  });
2517
- const o = K(null), c = w(
2521
+ const o = M(null), c = w(
2518
2522
  (a) => {
2519
2523
  r(
2520
2524
  (u) => a !== void 0 ? u.map((l) => l.id === a ? { ...l, closing: !0 } : l) : u.map((l) => ({ ...l, closing: !0 }))
@@ -2533,30 +2537,30 @@ function sn() {
2533
2537
  };
2534
2538
  if (e.length === 0)
2535
2539
  return i.current.length === 0 ? void 0 : (o.current && clearTimeout(o.current), a = setTimeout(() => {
2536
- r((m) => m.map((f) => ({ ...f, closing: !0 }))), a = null;
2540
+ r((h) => h.map((p) => ({ ...p, closing: !0 }))), a = null;
2537
2541
  }, 0), o.current = setTimeout(() => {
2538
2542
  r([]), o.current = null;
2539
2543
  }, de), u);
2540
- const l = new Set(i.current.map((m) => m.id));
2544
+ const l = new Set(i.current.map((h) => h.id));
2541
2545
  if (!e.some(
2542
- (m) => m.id !== void 0 && !l.has(m.id)
2546
+ (h) => h.id !== void 0 && !l.has(h.id)
2543
2547
  )) return;
2544
2548
  if (i.current.length === 0) {
2545
- const m = [...e];
2549
+ const h = [...e];
2546
2550
  return a = setTimeout(() => {
2547
- r(m.map((f) => ({ ...f, closing: !1 }))), a = null;
2551
+ r(h.map((p) => ({ ...p, closing: !1 }))), a = null;
2548
2552
  }, 0), () => {
2549
2553
  a && clearTimeout(a);
2550
2554
  };
2551
2555
  }
2552
2556
  o.current && clearTimeout(o.current), a = setTimeout(() => {
2553
2557
  r(
2554
- (m) => m.every((f) => f.closing) ? m : m.map((f) => ({ ...f, closing: !0 }))
2558
+ (h) => h.every((p) => p.closing) ? h : h.map((p) => ({ ...p, closing: !0 }))
2555
2559
  ), a = null;
2556
2560
  }, 0);
2557
- const h = [...e];
2561
+ const m = [...e];
2558
2562
  return o.current = setTimeout(() => {
2559
- r(h.map((m) => ({ ...m, closing: !1 }))), o.current = null;
2563
+ r(m.map((h) => ({ ...h, closing: !1 }))), o.current = null;
2560
2564
  }, de), u;
2561
2565
  }, [e]), O(() => {
2562
2566
  if (!s.length) return;
@@ -2570,35 +2574,35 @@ function sn() {
2570
2574
  window.clearTimeout(u), a && window.removeEventListener("click", a), window.removeEventListener("keydown", l);
2571
2575
  };
2572
2576
  }, [s.length, c]), Fe(
2573
- /* @__PURE__ */ p("div", { className: `notification-portal ${s.length ? "active" : ""}`, children: s.map(({ id: a, type: u, message: l, closing: d }) => {
2574
- const h = es(u);
2575
- return /* @__PURE__ */ S(
2577
+ /* @__PURE__ */ f("div", { className: `notification-portal ${s.length ? "active" : ""}`, children: s.map(({ id: a, type: u, message: l, closing: d }) => {
2578
+ const m = es(u);
2579
+ return /* @__PURE__ */ k(
2576
2580
  "div",
2577
2581
  {
2578
- className: `notification ${d ? "closing" : ""} ${ss(h)}`,
2579
- onClick: (m) => m.stopPropagation(),
2582
+ className: `notification ${d ? "closing" : ""} ${ss(m)}`,
2583
+ onClick: (h) => h.stopPropagation(),
2580
2584
  children: [
2581
- /* @__PURE__ */ S("div", { className: "notification-body", children: [
2582
- /* @__PURE__ */ p(
2583
- P,
2585
+ /* @__PURE__ */ k("div", { className: "notification-body", children: [
2586
+ /* @__PURE__ */ f(
2587
+ K,
2584
2588
  {
2585
- icon: ts(h),
2586
- className: `notification-icon ${Se(h)}`
2589
+ icon: ts(m),
2590
+ className: `notification-icon ${Se(m)}`
2587
2591
  }
2588
2592
  ),
2589
- /* @__PURE__ */ p("p", { className: `notification-text ${Se(h)}`, children: l })
2593
+ /* @__PURE__ */ f("p", { className: `notification-text ${Se(m)}`, children: l })
2590
2594
  ] }),
2591
- /* @__PURE__ */ p(
2595
+ /* @__PURE__ */ f(
2592
2596
  G,
2593
2597
  {
2594
2598
  type: "button",
2595
2599
  icon: _e,
2596
2600
  color: "error",
2597
2601
  className: "notification-close group",
2598
- onClick: (m) => {
2599
- m.stopPropagation(), a !== void 0 && c(a);
2602
+ onClick: (h) => {
2603
+ h.stopPropagation(), a !== void 0 && c(a);
2600
2604
  },
2601
- iconClassName: `${Se(h)} notification-close-icon`,
2605
+ iconClassName: `${Se(m)} notification-close-icon`,
2602
2606
  name: n("_accessibility:buttons.closeNotification"),
2603
2607
  "aria-label": n("_accessibility:ariaLabels.closeNotification")
2604
2608
  }
@@ -2613,7 +2617,7 @@ function sn() {
2613
2617
  }
2614
2618
  function nn(n) {
2615
2619
  const { className: e, ...t } = n;
2616
- return /* @__PURE__ */ p("div", { className: "splash-screen", children: /* @__PURE__ */ p(
2620
+ return /* @__PURE__ */ f("div", { className: "splash-screen", children: /* @__PURE__ */ f(
2617
2621
  ne,
2618
2622
  {
2619
2623
  className: `blur-appear ${e ? ` ${e}` : ""}`,
@@ -2634,25 +2638,25 @@ const ns = (n) => {
2634
2638
  if (!o) {
2635
2639
  const {
2636
2640
  className: d = "",
2637
- variant: h = t ? "submit" : "outlined",
2638
- color: m = t ? "primary" : "default",
2639
- ...f
2641
+ variant: m = t ? "submit" : "outlined",
2642
+ color: h = t ? "primary" : "default",
2643
+ ...p
2640
2644
  } = c ?? {};
2641
- return /* @__PURE__ */ p(
2645
+ return /* @__PURE__ */ f(
2642
2646
  U,
2643
2647
  {
2644
2648
  type: "button",
2645
- variant: h,
2646
- color: m,
2649
+ variant: m,
2650
+ color: h,
2647
2651
  className: `tab ${d}`,
2648
2652
  onClick: s,
2649
- ...f,
2653
+ ...p,
2650
2654
  children: r
2651
2655
  }
2652
2656
  );
2653
2657
  }
2654
2658
  const l = `button submit tab ${t ? "primary" : "outlined"} ${(c == null ? void 0 : c.className) ?? ""}`.trim();
2655
- return /* @__PURE__ */ p(
2659
+ return /* @__PURE__ */ f(
2656
2660
  u,
2657
2661
  {
2658
2662
  to: i ?? `#${e}`,
@@ -2662,7 +2666,7 @@ const ns = (n) => {
2662
2666
  }
2663
2667
  );
2664
2668
  }, rs = (n) => {
2665
- var m;
2669
+ var h;
2666
2670
  const {
2667
2671
  tabs: e = [],
2668
2672
  defaultTab: t,
@@ -2672,30 +2676,30 @@ const ns = (n) => {
2672
2676
  tabsContainerClassName: o = "",
2673
2677
  useLinks: c = !0,
2674
2678
  tabButtonProps: a
2675
- } = n, [u, l] = _(t ?? ((m = e[0]) == null ? void 0 : m.id)), d = s ?? u, h = H(() => e.find((f) => f.id === d), [e, d]);
2676
- return /* @__PURE__ */ S("div", { className: `tabs-layout-main ${i}`, children: [
2677
- /* @__PURE__ */ p(
2679
+ } = n, [u, l] = _(t ?? ((h = e[0]) == null ? void 0 : h.id)), d = s ?? u, m = Q(() => e.find((p) => p.id === d), [e, d]);
2680
+ return /* @__PURE__ */ k("div", { className: `tabs-layout-main ${i}`, children: [
2681
+ /* @__PURE__ */ f(
2678
2682
  "ul",
2679
2683
  {
2680
2684
  className: `horizontal tabs tabs-container ${o}`,
2681
- children: e.map(({ id: f, to: y, label: g }) => /* @__PURE__ */ p("li", { children: /* @__PURE__ */ p(
2685
+ children: e.map(({ id: p, to: y, label: g }) => /* @__PURE__ */ f("li", { children: /* @__PURE__ */ f(
2682
2686
  ns,
2683
2687
  {
2684
2688
  onClick: () => {
2685
- s === void 0 && l(f), r == null || r(f);
2689
+ s === void 0 && l(p), r == null || r(p);
2686
2690
  },
2687
- id: f,
2691
+ id: p,
2688
2692
  to: y,
2689
2693
  siblings: e.length > 1,
2690
- active: d === f,
2694
+ active: d === p,
2691
2695
  useLinks: c,
2692
2696
  tabButtonProps: a,
2693
2697
  children: g
2694
2698
  }
2695
- ) }, f))
2699
+ ) }, p))
2696
2700
  }
2697
2701
  ),
2698
- h == null ? void 0 : h.content
2702
+ m == null ? void 0 : m.content
2699
2703
  ] });
2700
2704
  }, is = (n) => {
2701
2705
  const {
@@ -2709,14 +2713,14 @@ const ns = (n) => {
2709
2713
  image: a = "",
2710
2714
  alt: u = "",
2711
2715
  final: l = !1
2712
- } = n, { t: d } = T();
2713
- return /* @__PURE__ */ S("div", { className: "big-appear step-container", children: [
2714
- a && /* @__PURE__ */ p("img", { src: a, alt: u }),
2715
- e != null && /* @__PURE__ */ p("h2", { className: "step-title", children: e }),
2716
- t != null && /* @__PURE__ */ p("div", { className: "step-body", children: t }),
2717
- s != null && /* @__PURE__ */ p("div", { className: "step-content", children: s }),
2718
- /* @__PURE__ */ p("div", { className: "step-actions", children: l ? /* @__PURE__ */ S(ae, { children: [
2719
- /* @__PURE__ */ p(
2716
+ } = n, { t: d } = N();
2717
+ return /* @__PURE__ */ k("div", { className: "big-appear step-container", children: [
2718
+ a && /* @__PURE__ */ f("img", { src: a, alt: u }),
2719
+ e != null && /* @__PURE__ */ f("h2", { className: "step-title", children: e }),
2720
+ t != null && /* @__PURE__ */ f("div", { className: "step-body", children: t }),
2721
+ s != null && /* @__PURE__ */ f("div", { className: "step-content", children: s }),
2722
+ /* @__PURE__ */ f("div", { className: "step-actions", children: l ? /* @__PURE__ */ k(ae, { children: [
2723
+ /* @__PURE__ */ f(
2720
2724
  U,
2721
2725
  {
2722
2726
  color: "primary",
@@ -2727,7 +2731,7 @@ const ns = (n) => {
2727
2731
  children: d("_accessibility:buttons.startAsGuest")
2728
2732
  }
2729
2733
  ),
2730
- /* @__PURE__ */ p(
2734
+ /* @__PURE__ */ f(
2731
2735
  U,
2732
2736
  {
2733
2737
  color: "primary",
@@ -2738,8 +2742,8 @@ const ns = (n) => {
2738
2742
  children: d("_accessibility:buttons.signIn")
2739
2743
  }
2740
2744
  )
2741
- ] }) : /* @__PURE__ */ S(ae, { children: [
2742
- /* @__PURE__ */ p(
2745
+ ] }) : /* @__PURE__ */ k(ae, { children: [
2746
+ /* @__PURE__ */ f(
2743
2747
  U,
2744
2748
  {
2745
2749
  color: "primary",
@@ -2750,7 +2754,7 @@ const ns = (n) => {
2750
2754
  children: d("_accessibility:buttons.skip")
2751
2755
  }
2752
2756
  ),
2753
- /* @__PURE__ */ p(
2757
+ /* @__PURE__ */ f(
2754
2758
  U,
2755
2759
  {
2756
2760
  color: "primary",
@@ -2771,45 +2775,45 @@ const ns = (n) => {
2771
2775
  onSkip: r,
2772
2776
  onSignIn: i,
2773
2777
  onStartAsGuest: o
2774
- } = n, { setGuestMode: c } = Qe(), { navigate: a } = ce(), [u, l] = _(1), d = w(() => {
2778
+ } = n, { setGuestMode: c } = He(), { navigate: a } = ce(), [u, l] = _(1), d = w(() => {
2775
2779
  if (r) {
2776
2780
  r();
2777
2781
  return;
2778
2782
  }
2779
2783
  a(t);
2780
- }, [a, r, t]), h = w(() => {
2784
+ }, [a, r, t]), m = w(() => {
2781
2785
  if (i) {
2782
2786
  i();
2783
2787
  return;
2784
2788
  }
2785
2789
  a(t);
2786
- }, [a, i, t]), m = w(() => {
2790
+ }, [a, i, t]), h = w(() => {
2787
2791
  if (o) {
2788
2792
  o();
2789
2793
  return;
2790
2794
  }
2791
2795
  c(!0), a(s);
2792
- }, [s, a, o, c]), f = H(() => e.map((y, g) => ({
2796
+ }, [s, a, o, c]), p = Q(() => e.map((y, g) => ({
2793
2797
  id: g + 1,
2794
2798
  label: "",
2795
- content: /* @__PURE__ */ p(
2799
+ content: /* @__PURE__ */ f(
2796
2800
  is,
2797
2801
  {
2798
2802
  ...y,
2799
2803
  final: g === e.length - 1,
2800
2804
  onClickNext: () => l((b) => b + 1),
2801
2805
  onSkip: d,
2802
- onStartAsGuest: m,
2803
- onSignIn: h
2806
+ onStartAsGuest: h,
2807
+ onSignIn: m
2804
2808
  }
2805
2809
  )
2806
- })), [h, d, m, e]);
2807
- return /* @__PURE__ */ p("div", { className: "onboarding-main", children: /* @__PURE__ */ p(
2810
+ })), [m, d, h, e]);
2811
+ return /* @__PURE__ */ f("div", { className: "onboarding-main", children: /* @__PURE__ */ f(
2808
2812
  rs,
2809
2813
  {
2810
2814
  currentTab: u,
2811
2815
  onTabChange: (y) => l(Number(y)),
2812
- tabs: f,
2816
+ tabs: p,
2813
2817
  useLinks: !1
2814
2818
  }
2815
2819
  ) });
@@ -2820,10 +2824,10 @@ const ns = (n) => {
2820
2824
  action: s,
2821
2825
  iconProps: r
2822
2826
  } = n;
2823
- return /* @__PURE__ */ S("div", { className: "empty-container", children: [
2824
- r && /* @__PURE__ */ p(P, { ...r }),
2825
- /* @__PURE__ */ p("p", { ...t, children: e }),
2826
- s && /* @__PURE__ */ p(ht, { showTooltips: !1, showText: !0, ...s })
2827
+ return /* @__PURE__ */ k("div", { className: "empty-container", children: [
2828
+ r && /* @__PURE__ */ f(K, { ...r }),
2829
+ /* @__PURE__ */ f("p", { ...t, children: e }),
2830
+ s && /* @__PURE__ */ f(ht, { showTooltips: !1, showText: !0, ...s })
2827
2831
  ] });
2828
2832
  };
2829
2833
  export {
@@ -2884,21 +2888,21 @@ export {
2884
2888
  _s as mapValidationErrors,
2885
2889
  Pe as parseQueries,
2886
2890
  Is as queryClient,
2887
- D as removeFromLocal,
2891
+ P as removeFromLocal,
2888
2892
  W as toLocal,
2889
- Qe as useAuth,
2893
+ He as useAuth,
2890
2894
  ce as useConfig,
2891
2895
  Be as useConfirmationForm,
2892
2896
  Bt as useDeleteAction,
2893
2897
  js as useDeleteDialog,
2894
2898
  We as useDialog,
2895
- Qt as useDrawerMenu,
2899
+ Ht as useDrawerMenu,
2896
2900
  Us as useEditAction,
2897
- Hs as useEntityFormDialog,
2901
+ Qs as useEntityFormDialog,
2898
2902
  Gt as useExportAction,
2899
2903
  zs as useExportActionMutate,
2900
2904
  pe as useFormDialog,
2901
- Qs as useFormDialogLegacy,
2905
+ Hs as useFormDialogLegacy,
2902
2906
  zt as useImportAction,
2903
2907
  Gs as useImportDialog,
2904
2908
  Ut as useManager,