react-luminus-components 1.3.187 → 1.3.188

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/main.es.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { j as n, c as _, t as je, a as kt, s as An, g as Bn, m as Ks, d as Bt, b as qs, e as Qs, f as We, h as Zs, i as Js, k as Xs, l as ea, n as ta, o as na, p as ra, T as Ir, q as $r, r as Vn, E as sa, u as Dr, v as kn, w as Lr, x as aa, y as he, z as Kt, A as oa, B as Tr, C as qt, D as ia, F as xn, G as Er, H as la, S as vn, N as Fr, I as Sn, J as Cn, K as ca, L as da, M as ua, O as fa, P as ma, Q as Or, R as ha, U as ga, V as pa, W as xa, X as va, Y as ja, Z as ya, _ as jn, $ as oe, a0 as zt, a1 as wa, a2 as _a, a3 as ba, a4 as Rr, a5 as St, a6 as te, a7 as In, a8 as pe, a9 as $n, aa as Ve, ab as it, ac as Na, ad as Pe, ae as K, af as Mr, ag as Ar, ah as Br, ai as Ae, aj as lt, ak as ka, al as Sa, am as Ca, an as Ia, ao as Qt, ap as Ze, aq as Lt, ar as Tt, as as Vr, at as Se, au as Pr, av as $a, aw as Da, ax as La, ay as ht, az as gt, aA as Et, aB as Ce, aC as zr, aD as Ct, aE as Je, aF as Hr, aG as Fe, aH as Ta, aI as Wr, aJ as Ea, aK as Ur, aL as Fa, aM as Oa, aN as Ra, aO as Ma, aP as Aa, aQ as Ba, aR as Ht, aS as Gr, aT as Va, aU as Pa, aV as za, aW as Ha, aX as Wa, aY as Ua, aZ as Ke, a_ as Ga, a$ as Ya, b0 as Ka, b1 as qa, b2 as Qa, b3 as sn, b4 as Pn, b5 as Za, b6 as Ja, b7 as Yr } from "./nivo-bar.es-i2iP31eh.js";
2
2
  import { bc as Zu, bd as Ju, ba as Xu, b9 as ef, b8 as tf, be as nf, bf as rf, bb as sf } from "./nivo-bar.es-i2iP31eh.js";
3
3
  import * as ie from "react";
4
- import ke, { useCallback as C, useMemo as Y, useContext as U, useRef as J, useEffect as B, useState as E, useId as Xa, Component as eo, isValidElement as zn, Suspense as to, useLayoutEffect as no } from "react";
4
+ import ke, { useCallback as S, useMemo as Y, useContext as U, useRef as J, useEffect as B, useState as E, useId as Xa, Component as eo, isValidElement as zn, Suspense as to, useLayoutEffect as no } from "react";
5
5
  import { c as Ue, L as Hn } from "./Loading-t5uR0uRd.js";
6
6
  import { InteractionType as ro } from "@azure/msal-browser";
7
7
  import { MsalAuthenticationTemplate as so } from "@azure/msal-react";
@@ -14,7 +14,7 @@ import { u as co, a as Qr, b as uo, c as Zr, d as fo } from "./useClipboard-CBAR
14
14
  import Ut from "react-dom";
15
15
  import { u as It } from "./useGetApiData-AaXTZWej.js";
16
16
  const au = ({ fileLoader: e, fileName: t, children: r }) => {
17
- const s = C(async () => {
17
+ const s = S(async () => {
18
18
  var c, l;
19
19
  const a = await e();
20
20
  if (!a)
@@ -193,17 +193,17 @@ const _o = {
193
193
  getDimensionValue: f = wo,
194
194
  ...p
195
195
  }, x) => {
196
- const g = typeof c == "function" ? c() : c, h = Y(() => _t((S) => {
197
- S.style[g] = "0";
198
- }, e), [g, e]), y = Y(() => _t((S) => {
196
+ const g = typeof c == "function" ? c() : c, h = Y(() => _t((C) => {
197
+ C.style[g] = "0";
198
+ }, e), [g, e]), y = Y(() => _t((C) => {
199
199
  const T = `scroll${g[0].toUpperCase()}${g.slice(1)}`;
200
- S.style[g] = `${S[T]}px`;
201
- }, t), [g, t]), w = Y(() => _t((S) => {
202
- S.style[g] = null;
203
- }, r), [g, r]), b = Y(() => _t((S) => {
204
- S.style[g] = `${f(g, S)}px`, aa(S);
205
- }, s), [s, f, g]), j = Y(() => _t((S) => {
206
- S.style[g] = null;
200
+ C.style[g] = `${C[T]}px`;
201
+ }, t), [g, t]), w = Y(() => _t((C) => {
202
+ C.style[g] = null;
203
+ }, r), [g, r]), b = Y(() => _t((C) => {
204
+ C.style[g] = `${f(g, C)}px`, aa(C);
205
+ }, s), [s, f, g]), j = Y(() => _t((C) => {
206
+ C.style[g] = null;
207
207
  }, a), [g, a]);
208
208
  return /* @__PURE__ */ n.jsx(Ir, {
209
209
  ref: x,
@@ -221,9 +221,9 @@ const _o = {
221
221
  mountOnEnter: u,
222
222
  unmountOnExit: m,
223
223
  appear: v,
224
- children: (S, T) => /* @__PURE__ */ ke.cloneElement(i, {
224
+ children: (C, T) => /* @__PURE__ */ ke.cloneElement(i, {
225
225
  ...T,
226
- className: _(o, i.props.className, _o[S], g === "width" && "collapse-horizontal")
226
+ className: _(o, i.props.className, _o[C], g === "width" && "collapse-horizontal")
227
227
  })
228
228
  });
229
229
  }), es = Kt("h4");
@@ -561,9 +561,9 @@ const Zn = () => {
561
561
  const p = J(null), x = (w) => {
562
562
  const b = p.current;
563
563
  if (!b) return null;
564
- const j = ma(b, `[${Jn}]:not([aria-disabled=true])`), S = b.querySelector("[aria-selected=true]");
565
- if (!S || S !== document.activeElement) return null;
566
- const T = j.indexOf(S);
564
+ const j = ma(b, `[${Jn}]:not([aria-disabled=true])`), C = b.querySelector("[aria-selected=true]");
565
+ if (!C || C !== document.activeElement) return null;
566
+ const T = j.indexOf(C);
567
567
  if (T === -1) return null;
568
568
  let $ = T + w;
569
569
  return $ >= j.length && ($ = 0), $ < 0 && ($ = j.length - 1), j[$];
@@ -827,7 +827,7 @@ const ks = /* @__PURE__ */ ie.forwardRef(({
827
827
  onExit: w,
828
828
  onExiting: b,
829
829
  onEnter: j,
830
- onEntering: S,
830
+ onEntering: C,
831
831
  onExited: T,
832
832
  backdropClassName: $,
833
833
  manager: R,
@@ -852,7 +852,7 @@ const ks = /* @__PURE__ */ ie.forwardRef(({
852
852
  re && (re.style.visibility = "visible"), j == null || j(re, ...V);
853
853
  }, z = (re, ...V) => {
854
854
  re && (re.style.visibility = ""), T == null || T(...V);
855
- }, Z = C((re) => /* @__PURE__ */ n.jsx("div", {
855
+ }, Z = S((re) => /* @__PURE__ */ n.jsx("div", {
856
856
  ...re,
857
857
  className: _(`${e}-backdrop`, $)
858
858
  }), [$, e]), ne = (re) => /* @__PURE__ */ n.jsx("div", {
@@ -879,7 +879,7 @@ const ks = /* @__PURE__ */ ie.forwardRef(({
879
879
  onShow: m,
880
880
  onHide: N,
881
881
  onEnter: X,
882
- onEntering: S,
882
+ onEntering: C,
883
883
  onEntered: y,
884
884
  onExit: w,
885
885
  onExiting: b,
@@ -1007,7 +1007,7 @@ const Vo = /* @__PURE__ */ ie.forwardRef(({
1007
1007
  /* @__PURE__ */ n.jsx("input", { id: r, type: "file", accept: s, onChange: d, hidden: !0, multiple: c })
1008
1008
  ] });
1009
1009
  }, ou = ({ onUpload: e, accept: t, children: r, className: s, size: a = "md" }) => {
1010
- const o = C(async (c) => {
1010
+ const o = S(async (c) => {
1011
1011
  if (c.target.files)
1012
1012
  try {
1013
1013
  await e(c.target.files);
@@ -1022,7 +1022,7 @@ const Vo = /* @__PURE__ */ ie.forwardRef(({
1022
1022
  }, zo = "_select_dlv1t_1", cn = {
1023
1023
  select: zo
1024
1024
  }, Ho = ({ month: e, onChangeMonth: t, locale: r, yearMin: s = 2e3, yearMax: a = 2050 }) => {
1025
- const o = C((l) => {
1025
+ const o = S((l) => {
1026
1026
  const d = Jr(e, l);
1027
1027
  d.getFullYear() < s || d.getFullYear() > a || t(d);
1028
1028
  }, [e, t, s, a]), i = Y(() => {
@@ -1067,7 +1067,7 @@ const Vo = /* @__PURE__ */ ie.forwardRef(({
1067
1067
  for (let d = a; d <= o; d++)
1068
1068
  l.push(d);
1069
1069
  return l;
1070
- }, [s, o, a]), c = C((l) => {
1070
+ }, [s, o, a]), c = S((l) => {
1071
1071
  if (s.manualOptions) {
1072
1072
  const d = i.findIndex((u) => u === e.getFullYear());
1073
1073
  if (d !== -1) {
@@ -1151,15 +1151,15 @@ const Ko = (e) => (r) => {
1151
1151
  s && s(((f = v.target) == null ? void 0 : f.checked) ?? !1);
1152
1152
  }, className: i ?? "", hidden: a ?? !1, disabled: o ?? !1 }) });
1153
1153
  }, Qe = ({ InputContainer: e = it, type: t, value: r, onChange: s, debounceMs: a, label: o, withoutLabel: i, placeholder: c, size: l, hidden: d, disabled: u, showClearIcon: m, clearValue: v, list: f, className: p, step: x, minLength: g, maxLength: h, noSelectOnFocus: y, hint: w, onConfirm: b }) => {
1154
- const j = t === "number", S = C(() => {
1154
+ const j = t === "number", C = S(() => {
1155
1155
  if (!s)
1156
1156
  return;
1157
1157
  const N = v ?? null;
1158
1158
  s(j ? N ? Number(N) : null : (N == null ? void 0 : N.toString()) ?? "");
1159
- }, [v, j, s]), T = J(null), [$, R] = E((r == null ? void 0 : r.toString()) ?? ""), A = C((N) => {
1159
+ }, [v, j, s]), T = J(null), [$, R] = E((r == null ? void 0 : r.toString()) ?? ""), A = S((N) => {
1160
1160
  const D = N;
1161
1161
  s && (j && s(D == null || D === "" ? null : Number(D)), s(D || null));
1162
- }, [j, s]), L = C((N) => {
1162
+ }, [j, s]), L = S((N) => {
1163
1163
  var W;
1164
1164
  const D = (W = N.target) == null ? void 0 : W.value;
1165
1165
  if (!a) {
@@ -1183,7 +1183,7 @@ const Ko = (e) => (r) => {
1183
1183
  /* @__PURE__ */ n.jsx(pe.Control, { type: O, placeholder: c ?? o, size: l, value: a ? $ : (r == null ? void 0 : r.toString()) ?? "", onChange: L, className: p ?? "", hidden: d, disabled: u ?? !1, list: f, onFocus: (N) => {
1184
1184
  Q(!0), !y && N.target.select();
1185
1185
  }, onBlur: () => Q(!1), onKeyDown: P, step: x, minLength: g, maxLength: h }),
1186
- m && r !== null && s && !u && /* @__PURE__ */ n.jsx("div", { className: `luminus-input-remove-icon ${t !== "text" ? "inset" : ""}`, children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: S, children: /* @__PURE__ */ n.jsx(Pe, {}) }) })
1186
+ m && r !== null && s && !u && /* @__PURE__ */ n.jsx("div", { className: `luminus-input-remove-icon ${t !== "text" ? "inset" : ""}`, children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: C, children: /* @__PURE__ */ n.jsx(Pe, {}) }) })
1187
1187
  ] });
1188
1188
  }, Gt = ({
1189
1189
  InputContainer: e = it,
@@ -1207,9 +1207,9 @@ const Ko = (e) => (r) => {
1207
1207
  addNewOptionPath: h,
1208
1208
  refreshOptions: y
1209
1209
  }) => {
1210
- const { texts: { customSelect: w } } = U(oe), [b, j] = E(!1), [S, T] = E(""), $ = C((O) => {
1210
+ const { texts: { customSelect: w } } = U(oe), [b, j] = E(!1), [C, T] = E(""), $ = S((O) => {
1211
1211
  T(O);
1212
- }, []), R = Y(() => r.find((O) => O.id === t) ?? null, [r, t]), A = C((O) => {
1212
+ }, []), R = Y(() => r.find((O) => O.id === t) ?? null, [r, t]), A = S((O) => {
1213
1213
  var N;
1214
1214
  return O === null ? "" : !O.name || O.name.length === 0 ? ((N = O.id) == null ? void 0 : N.toString()) ?? "" : v ? `${O.name} (${O.id})` : O.name;
1215
1215
  }, [v]), L = Y(() => {
@@ -1217,11 +1217,11 @@ const Ko = (e) => (r) => {
1217
1217
  return p !== void 0 && t !== void 0 && t !== null && (O.some((N) => N.id === t) || O.push({ id: t, name: p })), O.map((N) => ({
1218
1218
  id: N.id,
1219
1219
  name: A(N)
1220
- })).filter((N) => qe(N.name, S)).sort((N, D) => u ? 0 : (N.name ?? "").localeCompare(D.name ?? ""));
1221
- }, [r, u, S, A, p, t]), P = C((O) => {
1220
+ })).filter((N) => qe(N.name, C)).sort((N, D) => u ? 0 : (N.name ?? "").localeCompare(D.name ?? ""));
1221
+ }, [r, u, C, A, p, t]), P = S((O) => {
1222
1222
  var N;
1223
1223
  s && s((O == null ? void 0 : O.id) === void 0 || (O == null ? void 0 : O.id) === null ? null : i ? Number(O.id) : (N = O.id) == null ? void 0 : N.toString());
1224
- }, [s, i]), k = C((O) => {
1224
+ }, [s, i]), k = S((O) => {
1225
1225
  j(!1), P(O);
1226
1226
  }, [P]), Q = J(null);
1227
1227
  return /* @__PURE__ */ n.jsx(n.Fragment, { children: /* @__PURE__ */ n.jsxs(e, { withoutLabel: o, label: a ?? "", hidden: l, inputContainerClassName: _({ "luminus-dropdown-select-open": b }), className: m, hint: g, children: [
@@ -1238,10 +1238,10 @@ const Ko = (e) => (r) => {
1238
1238
  ] }),
1239
1239
  Q.current && /* @__PURE__ */ n.jsx(tn, { show: b, onCancel: () => j(!1), items: L, currentSelection: R ?? null, onSelectionChange: k, onSearchQueryChange: $, texts: w, disabled: d, inputRef: Q, autoHideSearch: !0, allItemsLength: r.length, itemsNameWidth: x, addNewOptionPath: h, refreshOptions: y })
1240
1240
  ] }) });
1241
- }, iu = ({ InputContainer: e = it, items: t, selectedItemNavigateTo: r, onSearchQueryChange: s, texts: a, isLoading: o, value: i, onSelect: c, label: l, withoutLabel: d, size: u, dropdownItemsNameWidth: m, additionalColumns: v, hidden: f, disabled: p, displayIdAsName: x, CustomOnChangeComponent: g, className: h, archiveColumn: y, icon: w, hint: b, addNewOptionPath: j, refreshOptions: S }) => {
1242
- const [T, $] = E(!1), R = C((O) => {
1241
+ }, iu = ({ InputContainer: e = it, items: t, selectedItemNavigateTo: r, onSearchQueryChange: s, texts: a, isLoading: o, value: i, onSelect: c, label: l, withoutLabel: d, size: u, dropdownItemsNameWidth: m, additionalColumns: v, hidden: f, disabled: p, displayIdAsName: x, CustomOnChangeComponent: g, className: h, archiveColumn: y, icon: w, hint: b, addNewOptionPath: j, refreshOptions: C }) => {
1242
+ const [T, $] = E(!1), R = S((O) => {
1243
1243
  c && c(O);
1244
- }, [c]), A = C((O) => {
1244
+ }, [c]), A = S((O) => {
1245
1245
  $(!1), R(O);
1246
1246
  }, [R]), L = J(null), P = r !== void 0, k = P && i !== null, Q = Y(() => {
1247
1247
  var O, N;
@@ -1282,20 +1282,20 @@ const Ko = (e) => (r) => {
1282
1282
  g ?? null
1283
1283
  ] }) : null
1284
1284
  ] }),
1285
- L.current && /* @__PURE__ */ n.jsx(tn, { show: T, onCancel: () => $(!1), items: t, currentSelection: i, onSelectionChange: A, onSearchQueryChange: s, texts: a, itemsNameWidth: m, additionalColumns: v, isLoading: o, disabled: p, inputRef: L, archiveColumn: y, displayIdAsName: x, addNewOptionPath: j, refreshOptions: S })
1285
+ L.current && /* @__PURE__ */ n.jsx(tn, { show: T, onCancel: () => $(!1), items: t, currentSelection: i, onSelectionChange: A, onSearchQueryChange: s, texts: a, itemsNameWidth: m, additionalColumns: v, isLoading: o, disabled: p, inputRef: L, archiveColumn: y, displayIdAsName: x, addNewOptionPath: j, refreshOptions: C })
1286
1286
  ] }) });
1287
1287
  }, lu = ({ InputContainer: e = it, value: t, onChange: r, label: s, size: a, showClearIcon: o, clearValue: i, hidden: c, disabled: l, rows: d, withoutLabel: u, debounceMs: m, minLength: v, maxLength: f, className: p, hint: x }) => {
1288
- const g = C(() => {
1288
+ const g = S(() => {
1289
1289
  if (!r)
1290
1290
  return;
1291
- const S = i ?? null;
1292
- r((S == null ? void 0 : S.toString()) ?? "");
1293
- }, [i, r]), h = J(null), [y, w] = E((t == null ? void 0 : t.toString()) ?? ""), b = C((S) => {
1294
- const T = S;
1291
+ const C = i ?? null;
1292
+ r((C == null ? void 0 : C.toString()) ?? "");
1293
+ }, [i, r]), h = J(null), [y, w] = E((t == null ? void 0 : t.toString()) ?? ""), b = S((C) => {
1294
+ const T = C;
1295
1295
  r && r(T || null);
1296
- }, [r]), j = C((S) => {
1296
+ }, [r]), j = S((C) => {
1297
1297
  var $;
1298
- const T = ($ = S.target) == null ? void 0 : $.value;
1298
+ const T = ($ = C.target) == null ? void 0 : $.value;
1299
1299
  if (!m) {
1300
1300
  b(T);
1301
1301
  return;
@@ -1311,34 +1311,34 @@ const Ko = (e) => (r) => {
1311
1311
  o && t && r && !l && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: g, children: /* @__PURE__ */ n.jsx(Pe, {}) }) })
1312
1312
  ] });
1313
1313
  }, cu = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, label: a, withoutLabel: o, placeholder: i, size: c, hidden: l, disabled: d, showClearIcon: u, clearValue: m, className: v, step: f, stepperStep: p = 1, min: x, max: g, hint: h }) => {
1314
- const y = C(() => {
1314
+ const y = S(() => {
1315
1315
  if (!r)
1316
1316
  return;
1317
1317
  const $ = m ?? null;
1318
1318
  r($ ? Number($) : null);
1319
- }, [m, r]), w = J(null), [b, j] = E((t == null ? void 0 : t.toString()) ?? ""), S = C(($) => {
1319
+ }, [m, r]), w = J(null), [b, j] = E((t == null ? void 0 : t.toString()) ?? ""), C = S(($) => {
1320
1320
  const R = $;
1321
1321
  r && r(R == null || R === "" ? null : bt(Number(R), x, g));
1322
- }, [g, x, r]), T = C(($) => {
1322
+ }, [g, x, r]), T = S(($) => {
1323
1323
  var A;
1324
1324
  const R = (A = $.target) == null ? void 0 : A.value;
1325
1325
  if (!s) {
1326
- S(R);
1326
+ C(R);
1327
1327
  return;
1328
1328
  }
1329
1329
  j(bt(Number(R), x, g).toString()), w.current !== null && window.clearTimeout(w.current), w.current = window.setTimeout(() => {
1330
- S(R);
1330
+ C(R);
1331
1331
  }, s);
1332
- }, [s, S, g, x]);
1332
+ }, [s, C, g, x]);
1333
1333
  return B(() => {
1334
1334
  j(t === null ? "" : bt(t, x, g).toString());
1335
1335
  }, [g, x, t]), /* @__PURE__ */ n.jsx(e, { withoutLabel: o, label: a ?? "", hidden: l, hint: h, className: v, children: /* @__PURE__ */ n.jsxs("div", { className: "luminus-input-container position-relative w-100", children: [
1336
1336
  /* @__PURE__ */ n.jsx(pe.Control, { type: "number", placeholder: i ?? a, size: c, value: s ? b : t ?? "", onChange: T, className: `luminus-numeric-stepper ${v ?? ""}`, hidden: l, disabled: d ?? !1, step: f }),
1337
1337
  /* @__PURE__ */ n.jsx("div", { className: "stepper-icon left", children: !d && /* @__PURE__ */ n.jsx(te, { size: "sm", onClick: ($) => {
1338
- $.preventDefault(), $.stopPropagation(), S(((t ?? 0) - p).toString());
1338
+ $.preventDefault(), $.stopPropagation(), C(((t ?? 0) - p).toString());
1339
1339
  }, children: /* @__PURE__ */ n.jsx(Ar, {}) }) }),
1340
1340
  /* @__PURE__ */ n.jsx("div", { className: "stepper-icon right", children: !d && /* @__PURE__ */ n.jsx(te, { size: "sm", onClick: ($) => {
1341
- $.preventDefault(), $.stopPropagation(), S(((t ?? 0) + p).toString());
1341
+ $.preventDefault(), $.stopPropagation(), C(((t ?? 0) + p).toString());
1342
1342
  }, children: /* @__PURE__ */ n.jsx(Br, {}) }) }),
1343
1343
  u && t && r && !d && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: y, children: /* @__PURE__ */ n.jsx(Pe, {}) }) })
1344
1344
  ] }) });
@@ -1603,7 +1603,7 @@ function gi(e) {
1603
1603
  y === void 0 && (y = fi);
1604
1604
  var w = e.isValidInputCharacter;
1605
1605
  w === void 0 && (w = Dt);
1606
- var b = e.isCharacterSame, j = Ls(e, ["type", "displayType", "customInput", "renderText", "getInputRef", "format", "removeFormatting", "defaultValue", "valueIsNumericString", "onValueChange", "isAllowed", "onChange", "onKeyDown", "onMouseUp", "onFocus", "onBlur", "value", "getCaretBoundary", "isValidInputCharacter", "isCharacterSame"]), S = Ms(h, l, !!d, i, c, u), T = S[0], $ = T.formattedValue, R = T.numAsString, A = S[1], L = J(), P = J({ formattedValue: $, numAsString: R }), k = function(I, M) {
1606
+ var b = e.isCharacterSame, j = Ls(e, ["type", "displayType", "customInput", "renderText", "getInputRef", "format", "removeFormatting", "defaultValue", "valueIsNumericString", "onValueChange", "isAllowed", "onChange", "onKeyDown", "onMouseUp", "onFocus", "onBlur", "value", "getCaretBoundary", "isValidInputCharacter", "isCharacterSame"]), C = Ms(h, l, !!d, i, c, u), T = C[0], $ = T.formattedValue, R = T.numAsString, A = C[1], L = J(), P = J({ formattedValue: $, numAsString: R }), k = function(I, M) {
1607
1607
  P.current = { formattedValue: I.formattedValue, numAsString: I.value }, A(I, M);
1608
1608
  }, Q = E(!1), O = Q[0], N = Q[1], D = J(null), W = J({
1609
1609
  setCaretTimeout: null,
@@ -1786,8 +1786,8 @@ function ji(e, t, r) {
1786
1786
  return z && (Z = 2), Z && (D = D.substring(Z), W -= Z, G -= Z), { value: D, start: W, end: G, hasNegation: X };
1787
1787
  }, y = h(e, u, m), w = y.hasNegation;
1788
1788
  s = y, e = s.value, u = s.start, m = s.end;
1789
- var b = h(t.lastValue, l.start, l.end), j = b.start, S = b.end, T = b.value, $ = e.substring(u, m);
1790
- e.length && T.length && (j > T.length - i.length || S < o.length) && !($ && i.startsWith($)) && (e = T);
1789
+ var b = h(t.lastValue, l.start, l.end), j = b.start, C = b.end, T = b.value, $ = e.substring(u, m);
1790
+ e.length && T.length && (j > T.length - i.length || C < o.length) && !($ && i.startsWith($)) && (e = T);
1791
1791
  var R = 0;
1792
1792
  e.startsWith(o) ? R += o.length : u < o.length && (R = u), e = e.substring(R), m -= R;
1793
1793
  var A = e.length, L = e.length - i.length;
@@ -1841,9 +1841,9 @@ function _i(e) {
1841
1841
  return ji(N, D, e);
1842
1842
  }, b = ft(m) ? u : m, j = v ?? vi(b, d, t);
1843
1843
  ft(m) ? ft(u) || (j = j || typeof u == "number") : j = j || typeof m == "number";
1844
- var S = function(N) {
1844
+ var C = function(N) {
1845
1845
  return Ts(N) ? N : (typeof N == "number" && (N = Os(N)), j && typeof c == "number" ? ar(N, c, !!l) : N);
1846
- }, T = Ms(S(m), S(u), !!j, y, w, f), $ = T[0], R = $.numAsString, A = $.formattedValue, L = T[1], P = function(N) {
1846
+ }, T = Ms(C(m), C(u), !!j, y, w, f), $ = T[0], R = $.numAsString, A = $.formattedValue, L = T[1], P = function(N) {
1847
1847
  var D = N.target, W = N.key, G = D.selectionStart, X = D.selectionEnd, z = D.value;
1848
1848
  if (z === void 0 && (z = ""), (W === "Backspace" || W === "Delete") && X < d.length) {
1849
1849
  N.preventDefault();
@@ -1898,22 +1898,22 @@ function Rn(e) {
1898
1898
  return ke.createElement(gi, Object.assign({}, t));
1899
1899
  }
1900
1900
  const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, label: a, withoutLabel: o, placeholder: i, size: c, hidden: l, disabled: d, showClearIcon: u, clearValue: m, className: v, step: f, noSelectOnFocus: p, decimalScale: x, numberPrefix: g, numberSuffix: h, min: y, max: w, hint: b }) => {
1901
- const j = C(() => {
1901
+ const j = S(() => {
1902
1902
  if (!r)
1903
1903
  return;
1904
1904
  const L = m ?? null;
1905
1905
  r(L ? Number(L) : null);
1906
- }, [m, r]), S = J(null), [T, $] = E((t == null ? void 0 : t.toString()) ?? ""), R = C((L) => {
1906
+ }, [m, r]), C = J(null), [T, $] = E((t == null ? void 0 : t.toString()) ?? ""), R = S((L) => {
1907
1907
  const P = L;
1908
1908
  r && r(P == null || P === "" ? null : Number(P));
1909
- }, [r]), A = C((L) => {
1909
+ }, [r]), A = S((L) => {
1910
1910
  var k, Q;
1911
1911
  let P = parseFloat(((Q = (k = L.target) == null ? void 0 : k.value) == null ? void 0 : Q.replaceAll(" ", "").replaceAll(",", ".")) ?? 0);
1912
1912
  if (Number.isNaN(P) && (P = 0), !s) {
1913
1913
  R(P.toString());
1914
1914
  return;
1915
1915
  }
1916
- $(P.toString()), S.current !== null && window.clearTimeout(S.current), S.current = window.setTimeout(() => {
1916
+ $(P.toString()), C.current !== null && window.clearTimeout(C.current), C.current = window.setTimeout(() => {
1917
1917
  R(P.toString());
1918
1918
  }, s);
1919
1919
  }, [s, R]);
@@ -1932,7 +1932,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
1932
1932
  u && t !== null && r && !d && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon inset", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: j, children: /* @__PURE__ */ n.jsx(Pe, {}) }) })
1933
1933
  ] });
1934
1934
  }, uu = ({ InputContainer: e = Ae, label: t, options: r, disabled: s, hidden: a, className: o, value: i, onChange: c }) => {
1935
- const l = C((d) => {
1935
+ const l = S((d) => {
1936
1936
  c && c(d.target.value);
1937
1937
  }, [c]);
1938
1938
  return /* @__PURE__ */ n.jsx(e, { isForRadioInput: !0, hidden: a, withoutLabel: !t, label: `${t}`, className: o, children: r.map((d) => /* @__PURE__ */ n.jsx(pe.Check, { id: `radio-${d.id}`, label: d.name, type: "radio", value: d.id ?? "", checked: i === d.id, onChange: l, hidden: a, disabled: s, className: "w-100" }, d.id)) });
@@ -1941,8 +1941,8 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
1941
1941
  B(() => {
1942
1942
  const b = t.split(".");
1943
1943
  let j = f.errors;
1944
- b.forEach((S) => {
1945
- j !== void 0 && (j = j[S]);
1944
+ b.forEach((C) => {
1945
+ j !== void 0 && (j = j[C]);
1946
1946
  }), g(j);
1947
1947
  }, [f, t]), B(() => {
1948
1948
  f.isSubmitted && y(!0);
@@ -1961,8 +1961,8 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
1961
1961
  B(() => {
1962
1962
  const b = r.split(".");
1963
1963
  let j = m.errors;
1964
- b.forEach((S) => {
1965
- j !== void 0 && (j = j[S]);
1964
+ b.forEach((C) => {
1965
+ j !== void 0 && (j = j[C]);
1966
1966
  }), x(j);
1967
1967
  }, [m, r]), B(() => {
1968
1968
  m.isSubmitted && h(!0);
@@ -1971,20 +1971,20 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
1971
1971
  return /* @__PURE__ */ n.jsxs(e, { isForRadioInput: !0, hidden: c, withoutLabel: !t, label: `${t}${o ? " *" : ""}`, isInvalid: w, className: d, children: [
1972
1972
  y.map((b) => /* @__PURE__ */ n.jsx(pe.Check, { id: `radio-${b.id}`, label: b.name, type: "radio", value: b.id ?? "", checked: f(r) === b.id, ...u(r, {
1973
1973
  onChange: (j) => {
1974
- var S;
1975
- a && a.forEach((T) => v(T, null, { shouldDirty: !0, shouldValidate: g })), l && l((S = j.target) != null && S.value ? j.target.value.toString() : null);
1974
+ var C;
1975
+ a && a.forEach((T) => v(T, null, { shouldDirty: !0, shouldValidate: g })), l && l((C = j.target) != null && C.value ? j.target.value.toString() : null);
1976
1976
  }
1977
1977
  }), isInvalid: w, hidden: c, disabled: i, className: "w-100" }, b.id)),
1978
1978
  p && /* @__PURE__ */ n.jsx(lt, { message: p.message })
1979
1979
  ] });
1980
- }, hu = ({ InputContainer: e = Ae, formField: t, label: r, size: s, defaultSelection: a, resetsFields: o, isNumber: i, required: c, hidden: l, disabled: d, items: u, onSearchQueryChange: m, selectedItemNavigateTo: v, texts: f, dropdownItemsNameWidth: p, isLoading: x, withoutLabel: g, additionalColumns: h, CustomOnChangeComponent: y, icon: w, displayIdAsName: b, onSelect: j, className: S, archiveColumn: T, hint: $, addNewOptionPath: R, refreshOptions: A }) => {
1981
- const { formState: L, setValue: P, watch: k, control: Q } = Xe(), [O, N] = E(void 0), [D, W] = E(!1), [G, X] = E(!1), z = k(t) ?? null, Z = z === (a == null ? void 0 : a.id) ? a == null ? void 0 : a.name : k(`${t}-DropdownName`), ne = Y(() => z == null ? null : { id: z ?? null, name: Z ?? "" }, [z, Z]), re = C(() => {
1980
+ }, hu = ({ InputContainer: e = Ae, formField: t, label: r, size: s, defaultSelection: a, resetsFields: o, isNumber: i, required: c, hidden: l, disabled: d, items: u, onSearchQueryChange: m, selectedItemNavigateTo: v, texts: f, dropdownItemsNameWidth: p, isLoading: x, withoutLabel: g, additionalColumns: h, CustomOnChangeComponent: y, icon: w, displayIdAsName: b, onSelect: j, className: C, archiveColumn: T, hint: $, addNewOptionPath: R, refreshOptions: A }) => {
1981
+ const { formState: L, setValue: P, watch: k, control: Q } = Xe(), [O, N] = E(void 0), [D, W] = E(!1), [G, X] = E(!1), z = k(t) ?? null, Z = z === (a == null ? void 0 : a.id) ? a == null ? void 0 : a.name : k(`${t}-DropdownName`), ne = Y(() => z == null ? null : { id: z ?? null, name: Z ?? "" }, [z, Z]), re = S(() => {
1982
1982
  const se = t.split(".");
1983
1983
  let _e = L.errors;
1984
1984
  se.forEach((Ne) => {
1985
1985
  _e !== void 0 && (_e = _e[Ne]);
1986
1986
  }), N(_e);
1987
- }, [L, t]), V = C((se) => {
1987
+ }, [L, t]), V = S((se) => {
1988
1988
  if ((se == null ? void 0 : se.id) === z)
1989
1989
  return;
1990
1990
  if (j && j(se), o && o.forEach((Ne) => P(Ne, null, { shouldDirty: !0, shouldValidate: G })), se === null) {
@@ -1999,9 +1999,9 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
1999
1999
  shouldDirty: !0,
2000
2000
  shouldValidate: G
2001
2001
  }), P(`${t}-DropdownName`, se.name ?? "");
2002
- }, [P, t, G, i, o, z, j]), F = C((se) => {
2002
+ }, [P, t, G, i, o, z, j]), F = S((se) => {
2003
2003
  W(!1), V(se);
2004
- }, [V]), ee = C(() => {
2004
+ }, [V]), ee = S(() => {
2005
2005
  W(!1);
2006
2006
  }, []);
2007
2007
  B(() => {
@@ -2010,7 +2010,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2010
2010
  L.isSubmitted && X(!0);
2011
2011
  }, [L]);
2012
2012
  const ae = J(null), be = O !== void 0, Le = v !== void 0, ze = Le && ne !== null;
2013
- return /* @__PURE__ */ n.jsx(n.Fragment, { children: /* @__PURE__ */ n.jsxs(e, { label: `${r}${c ? " *" : ""}`, hidden: l, withoutLabel: g, isInvalid: be, inputContainerClassName: _({ "luminus-dropdown-select-open": D }), hint: $, className: S, children: [
2013
+ return /* @__PURE__ */ n.jsx(n.Fragment, { children: /* @__PURE__ */ n.jsxs(e, { label: `${r}${c ? " *" : ""}`, hidden: l, withoutLabel: g, isInvalid: be, inputContainerClassName: _({ "luminus-dropdown-select-open": D }), hint: $, className: C, children: [
2014
2014
  /* @__PURE__ */ n.jsxs(Ds, { currentSelection: ne, selectedItemNavigateTo: v, children: [
2015
2015
  b && (ne == null ? void 0 : ne.name) && /* @__PURE__ */ n.jsx(K, { variant: "caption", className: "d-flex justify-content-end mt-2 luminus-dropdown-selection-name", children: ne.name }),
2016
2016
  /* @__PURE__ */ n.jsx(Dn, { control: Q, name: t, render: () => /* @__PURE__ */ n.jsx(pe.Select, { size: s, onMouseDown: (se) => {
@@ -2033,9 +2033,9 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2033
2033
  ae.current && /* @__PURE__ */ n.jsx(tn, { show: D, onCancel: ee, items: u, currentSelection: ne, onSelectionChange: F, onSearchQueryChange: m, texts: f, itemsNameWidth: p, additionalColumns: h, displayIdAsName: b, isLoading: x, disabled: d, inputRef: ae, archiveColumn: T, addNewOptionPath: R, refreshOptions: A })
2034
2034
  ] }) });
2035
2035
  }, gu = ({ InputContainer: e = Ae, label: t, formField: r, hidden: s, required: a, placeholder: o, disabled: i, showClearIcon: c, resetsFields: l, multiple: d, accept: u, withoutLabel: m, hint: v, className: f }) => {
2036
- const { watch: p, setValue: x, register: g, formState: h } = Xe(), [y, w] = E(!1), [b, j] = E(void 0), S = C(() => {
2036
+ const { watch: p, setValue: x, register: g, formState: h } = Xe(), [y, w] = E(!1), [b, j] = E(void 0), C = S(() => {
2037
2037
  x(r, "");
2038
- }, [x, r]), T = C(() => {
2038
+ }, [x, r]), T = S(() => {
2039
2039
  const R = r.split(".");
2040
2040
  let A = h.errors;
2041
2041
  R.forEach((L) => {
@@ -2052,7 +2052,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2052
2052
  l && l.forEach((R) => x(R, null, { shouldDirty: !0, shouldValidate: y }));
2053
2053
  }
2054
2054
  }) }),
2055
- c && p(r) && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: S, children: /* @__PURE__ */ n.jsx(Pe, {}) }) }),
2055
+ c && p(r) && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: C, children: /* @__PURE__ */ n.jsx(Pe, {}) }) }),
2056
2056
  b && /* @__PURE__ */ n.jsx(lt, { message: b.message })
2057
2057
  ] });
2058
2058
  }, pu = ({ children: e, onStorno: t, noSpacer: r }) => {
@@ -2061,13 +2061,13 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2061
2061
  o(Object.keys(s.dirtyFields).length > 0);
2062
2062
  }, [s]), a ? /* @__PURE__ */ n.jsx(Po, { onStorno: t, noSpacer: r, children: e }) : null;
2063
2063
  }, xu = ({ InputContainer: e = Ae, options: t, formField: r, label: s, size: a, resetsFields: o, isNumber: i, required: c, hidden: l, disabled: d, withoutLabel: u, noSortOptions: m, suffixIdToName: v, onSelect: f, className: p, appendCurrentSelectionWithName: x, hint: g, addNewOptionPath: h, refreshOptions: y }) => {
2064
- const { texts: { customSelect: w } } = U(oe), { formState: b, setValue: j, watch: S, control: T } = Xe(), [$, R] = E(void 0), [A, L] = E(!1), [P, k] = E(!1), [Q, O] = E(""), N = S(r), D = Y(() => t.find((F) => F.id === N) ?? null, [t, N]), W = C(() => {
2064
+ const { texts: { customSelect: w } } = U(oe), { formState: b, setValue: j, watch: C, control: T } = Xe(), [$, R] = E(void 0), [A, L] = E(!1), [P, k] = E(!1), [Q, O] = E(""), N = C(r), D = Y(() => t.find((F) => F.id === N) ?? null, [t, N]), W = S(() => {
2065
2065
  const F = r.split(".");
2066
2066
  let ee = b.errors;
2067
2067
  F.forEach((ae) => {
2068
2068
  ee !== void 0 && (ee = ee[ae]);
2069
2069
  }), R(ee);
2070
- }, [b, r]), G = C((F) => {
2070
+ }, [b, r]), G = S((F) => {
2071
2071
  if ((F == null ? void 0 : F.id) === N)
2072
2072
  return;
2073
2073
  if (f && f(F), o && o.forEach((ae) => j(ae, null, { shouldDirty: !0, shouldValidate: P })), F === null) {
@@ -2082,9 +2082,9 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2082
2082
  shouldDirty: !0,
2083
2083
  shouldValidate: P
2084
2084
  });
2085
- }, [j, r, i, o, N, P, f]), X = C((F) => {
2085
+ }, [j, r, i, o, N, P, f]), X = S((F) => {
2086
2086
  L(!1), G(F);
2087
- }, [G]), z = C((F) => {
2087
+ }, [G]), z = S((F) => {
2088
2088
  O(F);
2089
2089
  }, []);
2090
2090
  B(() => {
@@ -2092,7 +2092,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2092
2092
  }, [W]), B(() => {
2093
2093
  b.isSubmitted && k(!0);
2094
2094
  }, [b]);
2095
- const Z = C((F) => {
2095
+ const Z = S((F) => {
2096
2096
  var ee;
2097
2097
  return F === null ? "" : !F.name || F.name.length === 0 ? ((ee = F.id) == null ? void 0 : ee.toString()) ?? "" : v ? `${F.name} (${F.id})` : F.name;
2098
2098
  }, [v]), ne = Y(() => {
@@ -2120,15 +2120,15 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2120
2120
  re.current && /* @__PURE__ */ n.jsx(tn, { show: A, onCancel: () => L(!1), items: ne, currentSelection: D ?? null, onSelectionChange: X, onSearchQueryChange: z, texts: w, disabled: d, inputRef: re, autoHideSearch: !0, allItemsLength: t.length, addNewOptionPath: h, refreshOptions: y })
2121
2121
  ] }) });
2122
2122
  }, vu = ({ InputContainer: e = Ae, formField: t, label: r, placeholder: s, size: a, resetsFields: o, showClearIcon: i, clearValue: c, required: l, hidden: d, disabled: u, withoutLabel: m, step: v, stepperStep: f = 1, className: p, min: x, max: g, onChange: h, hint: y }) => {
2123
- const { register: w, formState: b, setValue: j, watch: S } = Xe(), [T, $] = E(void 0), [R, A] = E(!1), L = C((N, D, W) => {
2123
+ const { register: w, formState: b, setValue: j, watch: C } = Xe(), [T, $] = E(void 0), [R, A] = E(!1), L = S((N, D, W) => {
2124
2124
  j(N, bt(D, x, g), W);
2125
- }, [g, x, j]), P = C(() => {
2125
+ }, [g, x, j]), P = S(() => {
2126
2126
  const N = c ?? null;
2127
2127
  L(t, N !== null ? Number(N) : null, {
2128
2128
  shouldDirty: !0,
2129
2129
  shouldValidate: R
2130
2130
  });
2131
- }, [c, L, t, R]), k = C(() => {
2131
+ }, [c, L, t, R]), k = S(() => {
2132
2132
  const N = t.split(".");
2133
2133
  let D = b.errors;
2134
2134
  N.forEach((W) => {
@@ -2140,7 +2140,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2140
2140
  }, [k]), B(() => {
2141
2141
  b.isSubmitted && A(!0);
2142
2142
  }, [b]);
2143
- const Q = T !== void 0, O = S(t);
2143
+ const Q = T !== void 0, O = C(t);
2144
2144
  return /* @__PURE__ */ n.jsxs(e, { label: `${r}${l ? " *" : ""}`, hidden: d, withoutLabel: m, isInvalid: Q, hint: y, className: p, children: [
2145
2145
  /* @__PURE__ */ n.jsxs("div", { className: "luminus-input-container position-relative w-100", children: [
2146
2146
  /* @__PURE__ */ n.jsx(pe.Control, { type: "number", placeholder: s ?? r, size: a, ...w(t, {
@@ -2159,17 +2159,17 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2159
2159
  N.preventDefault(), N.stopPropagation(), L(t, ((O ? Number(O) : 0) + f).toString(), { shouldDirty: !0, shouldValidate: R });
2160
2160
  }, children: /* @__PURE__ */ n.jsx(Br, {}) }) })
2161
2161
  ] }),
2162
- i && S(t) && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: P, children: /* @__PURE__ */ n.jsx(Pe, {}) }) }),
2162
+ i && C(t) && /* @__PURE__ */ n.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ n.jsx(te, { color: "secondary", size: "sm", onClick: P, children: /* @__PURE__ */ n.jsx(Pe, {}) }) }),
2163
2163
  T && /* @__PURE__ */ n.jsx(lt, { message: T.message })
2164
2164
  ] });
2165
- }, ju = ({ InputContainer: e = Ae, formField: t, label: r, placeholder: s, resetsFields: a, showClearIcon: o, clearValue: i, required: c, hidden: l, disabled: d, withoutLabel: u, step: m, size: v, CustomOnChangeComponent: f, noSelectOnFocus: p, className: x, decimalScale: g = 2, numberPrefix: h, numberSuffix: y, min: w, max: b, onChange: j, hint: S }) => {
2166
- const { formState: T, setValue: $, watch: R, control: A } = Xe(), [L, P] = E(void 0), [k, Q] = E(!1), O = C(() => {
2165
+ }, ju = ({ InputContainer: e = Ae, formField: t, label: r, placeholder: s, resetsFields: a, showClearIcon: o, clearValue: i, required: c, hidden: l, disabled: d, withoutLabel: u, step: m, size: v, CustomOnChangeComponent: f, noSelectOnFocus: p, className: x, decimalScale: g = 2, numberPrefix: h, numberSuffix: y, min: w, max: b, onChange: j, hint: C }) => {
2166
+ const { formState: T, setValue: $, watch: R, control: A } = Xe(), [L, P] = E(void 0), [k, Q] = E(!1), O = S(() => {
2167
2167
  const G = i ?? null;
2168
2168
  $(t, G !== null ? Number(G) : null, {
2169
2169
  shouldDirty: !0,
2170
2170
  shouldValidate: k
2171
2171
  });
2172
- }, [i, $, t, k]), N = C(() => {
2172
+ }, [i, $, t, k]), N = S(() => {
2173
2173
  const G = t.split(".");
2174
2174
  let X = T.errors;
2175
2175
  G.forEach((z) => {
@@ -2186,7 +2186,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2186
2186
  b !== void 0 && D > b && $(t, b), w !== void 0 && D < w && $(t, w);
2187
2187
  }, [t, D, b, w, $]);
2188
2188
  const W = L !== void 0;
2189
- return /* @__PURE__ */ n.jsxs(e, { label: `${r}${c ? " *" : ""}`, hidden: l, withoutLabel: u, isInvalid: W, hint: S, className: x, children: [
2189
+ return /* @__PURE__ */ n.jsxs(e, { label: `${r}${c ? " *" : ""}`, hidden: l, withoutLabel: u, isInvalid: W, hint: C, className: x, children: [
2190
2190
  /* @__PURE__ */ n.jsxs("div", { className: "luminus-input-container position-relative w-100", children: [
2191
2191
  /* @__PURE__ */ n.jsx(Dn, { control: A, name: t, render: ({ field: { ref: G, onChange: X, name: z, value: Z } }) => /* @__PURE__ */ n.jsx(Rn, { displayType: "input", thousandSeparator: " ", decimalSeparator: ",", decimalScale: g, prefix: h, suffix: y, defaultValue: "", name: z, value: Z ?? "", placeholder: s ?? r, onFocus: (ne) => {
2192
2192
  !p && ne.target.select();
@@ -2243,7 +2243,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2243
2243
  }, cr = (e, t) => e.hierarchy && e.hierarchy.uniqueName === t, dr = (e) => !e.member && !e.isDrillThrough, ur = (e, t) => typeof e == "function" ? e(t) : e.replace(":id", t), Ci = ({ dataSource: e, settings: t, pivotRef: r, localization: s, licenseKey: a, hyperlinkColumn: o, enabled: i = !0 }) => {
2244
2244
  const { texts: { reports: c } } = U(oe), [l, d] = E(!1), u = J(null), m = r ?? u, v = Y(() => ({
2245
2245
  localization: s
2246
- }), [s]), f = C((h) => {
2246
+ }), [s]), f = S((h) => {
2247
2247
  delete h[0], delete h[1], delete h[2];
2248
2248
  const y = [
2249
2249
  {
@@ -2276,7 +2276,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2276
2276
  }, [e, i, l, m]), B(() => {
2277
2277
  var h, y, w;
2278
2278
  if (l && i) {
2279
- const { options: b, conditions: j, formats: S, slice: T, ...$ } = (h = m.current) == null ? void 0 : h.flexmonster.getReport();
2279
+ const { options: b, conditions: j, formats: C, slice: T, ...$ } = (h = m.current) == null ? void 0 : h.flexmonster.getReport();
2280
2280
  if ($ === void 0 || typeof $ == "string")
2281
2281
  return;
2282
2282
  const R = Si(t);
@@ -2289,18 +2289,18 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2289
2289
  (w = m.current) == null || w.flexmonster.setReport(A), console.log("Refreshing flexmonster settings. New report: ", A);
2290
2290
  }
2291
2291
  }, [i, l, m, t]);
2292
- const x = C((h, y) => {
2292
+ const x = S((h, y) => {
2293
2293
  var R;
2294
2294
  if (!o || !cr(y, o.idColumn) || dr(y))
2295
2295
  return;
2296
2296
  const w = (R = y.escapedLabel) == null ? void 0 : R.toString();
2297
2297
  if (w === void 0)
2298
2298
  return;
2299
- const b = ur(o.url, w), j = "style='color: #00a45a; text-decoration: underline; cursor: pointer;'", S = y.type === "header" ? "onclick='event.stopImmediatePropagation()'" : "", T = y.isDrillThrough || y.type === "header" ? `href='${b}' target='_blank'` : "";
2299
+ const b = ur(o.url, w), j = "style='color: #00a45a; text-decoration: underline; cursor: pointer;'", C = y.type === "header" ? "onclick='event.stopImmediatePropagation()'" : "", T = y.isDrillThrough || y.type === "header" ? `href='${b}' target='_blank'` : "";
2300
2300
  h.style && (h.style["z-index"] = 1);
2301
- const $ = `<a ${T} ${j} ${S}>${y.escapedLabel}</a>`;
2301
+ const $ = `<a ${T} ${j} ${C}>${y.escapedLabel}</a>`;
2302
2302
  h.text = $;
2303
- }, [o]), g = C((h) => {
2303
+ }, [o]), g = S((h) => {
2304
2304
  if (!o || !cr(h, o.idColumn) || dr(h))
2305
2305
  return;
2306
2306
  const y = ur(o.url, h.escapedLabel ?? "");
@@ -2324,7 +2324,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2324
2324
  }
2325
2325
  ) });
2326
2326
  }, Ii = (e, t, r, s) => {
2327
- const { texts: { reports: a } } = U(oe), { prompt: o } = Ia(), { confirm: i } = Qt(), c = Ze(), { user: l } = U(Lt), { startLoading: d, stopLoading: u } = U(Tt), { addNotification: m } = Vr(), v = C(async (h) => {
2327
+ const { texts: { reports: a } } = U(oe), { prompt: o } = Ia(), { confirm: i } = Qt(), c = Ze(), { user: l } = U(Lt), { startLoading: d, stopLoading: u } = U(Tt), { addNotification: m } = Vr(), v = S(async (h) => {
2328
2328
  d("report-versionSavingAs");
2329
2329
  try {
2330
2330
  const y = await c.post("/reports/version", h);
@@ -2332,7 +2332,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2332
2332
  } finally {
2333
2333
  u("report-versionSavingAs");
2334
2334
  }
2335
- }, [m, s, c, a.saveSuccessful, d, u]), f = C(async () => {
2335
+ }, [m, s, c, a.saveSuccessful, d, u]), f = S(async () => {
2336
2336
  if (r === null) {
2337
2337
  m("none open", "warning");
2338
2338
  return;
@@ -2353,7 +2353,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2353
2353
  a.confirmOverwriteSave,
2354
2354
  v,
2355
2355
  r
2356
- ]), p = C(async () => {
2356
+ ]), p = S(async () => {
2357
2357
  const h = await o(a.enterName, { input: "input", required: !0 });
2358
2358
  if (h === null)
2359
2359
  return;
@@ -2363,7 +2363,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2363
2363
  name: h,
2364
2364
  settings: y
2365
2365
  });
2366
- }, [t, o, e, a.enterName, v]), x = C(async () => {
2366
+ }, [t, o, e, a.enterName, v]), x = S(async () => {
2367
2367
  d("report-versionSavingAs");
2368
2368
  try {
2369
2369
  await c.post("/reports/version", {
@@ -2382,7 +2382,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2382
2382
  r,
2383
2383
  d,
2384
2384
  u
2385
- ]), g = C(async () => {
2385
+ ]), g = S(async () => {
2386
2386
  d("report-versionSavingAs");
2387
2387
  try {
2388
2388
  await c.post("/reports/version-restrictions", {
@@ -2409,7 +2409,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2409
2409
  return { saveAs: p, save: f, archive: x, detach: g };
2410
2410
  }, $i = (e) => {
2411
2411
  const t = Ze(), { startLoading: r, stopLoading: s } = U(Tt);
2412
- return { changeEmployeeRights: C(async (o, i) => {
2412
+ return { changeEmployeeRights: S(async (o, i) => {
2413
2413
  let c = null;
2414
2414
  r("reportSharing-addPerson");
2415
2415
  try {
@@ -2428,17 +2428,17 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2428
2428
  return c;
2429
2429
  }, [t, e, r, s]) };
2430
2430
  }, Di = ({ isOpen: e, onHide: t, usersData: r, reportVersionId: s, EmployeePicker: a, setReportVersion: o }) => {
2431
- const { ProjectIconComponent: i, texts: { reports: c } } = U(oe), { confirm: l } = Qt(), [d, u] = E(null), { changeEmployeeRights: m } = $i(s), v = C((x) => {
2431
+ const { ProjectIconComponent: i, texts: { reports: c } } = U(oe), { confirm: l } = Qt(), [d, u] = E(null), { changeEmployeeRights: m } = $i(s), v = S((x) => {
2432
2432
  o((g) => g === null ? null : {
2433
2433
  ...g,
2434
2434
  users: x.filter((h) => h.isReportOwner === !1)
2435
2435
  });
2436
- }, [o]), f = C(async () => {
2436
+ }, [o]), f = S(async () => {
2437
2437
  if (d === null)
2438
2438
  return;
2439
2439
  const x = await m(d.id, !0);
2440
2440
  v(x), u(null);
2441
- }, [d, m, v]), p = C(async (x) => {
2441
+ }, [d, m, v]), p = S(async (x) => {
2442
2442
  if (!await l(c.removeSharingWith(x)))
2443
2443
  return;
2444
2444
  const h = await m(x, !1);
@@ -2482,57 +2482,53 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2482
2482
  });
2483
2483
  }, [t, e]), { mappings: r };
2484
2484
  }, wu = ({ reportType: e, title: t, data: r, filterElements: s, getReportRoute: a, localization: o, licenseKey: i, EmployeePicker: c, localizationJsonFile: l, localizationTransformer: d, hyperlinkColumn: u }) => {
2485
- const { texts: { reports: m } } = U(oe), { confirm: v } = Qt(), f = Kr(), [p] = ao(), { id: x } = oo(), g = Y(() => x === void 0 ? null : Number(x), [x]), h = C((V) => {
2485
+ const { texts: { reports: m } } = U(oe), { confirm: v } = Qt(), f = Kr(), [p] = ao(), { id: x } = oo(), g = Y(() => x === void 0 ? null : Number(x), [x]), h = S((V) => {
2486
2486
  const F = V === null ? "" : V.toString();
2487
2487
  f(Wt(a(e), { id: F }) + "?" + p.toString(), {
2488
2488
  replace: !0,
2489
2489
  flushSync: !0
2490
2490
  });
2491
- }, [a, f, e, p]), [y, w] = E(!1), b = J(null), { user: j } = U(Lt), { data: S, reloadData: T } = It(`/reports/${e}`), { mappings: $ } = Li(l, d), [R, A] = E({}), L = C((V) => {
2492
- if (S === null)
2493
- return;
2491
+ }, [a, f, e, p]), [y, w] = E(!1), b = J(null), { user: j } = U(Lt), { data: C, reloadData: T } = It(`/reports/${e}`), { mappings: $ } = Li(l, d), [R, A] = E({}), L = S((V) => {
2494
2492
  const F = V.target.value, ee = F === "" ? null : Number(F);
2495
2493
  h(ee);
2496
- }, [S, h]), P = C(async (V) => {
2494
+ }, [h]), P = S(async (V) => {
2497
2495
  await T(), h(V);
2498
2496
  }, [T, h]), { data: k, setData: Q } = It(`/reports/version/${g}`, { enabled: g !== null, nullStateBeforeLoad: !1, nullStateOnFail: !0 });
2499
2497
  B(() => {
2500
2498
  var F;
2501
- if (S === null)
2502
- return;
2503
2499
  if (k === null) {
2504
2500
  A({});
2505
2501
  return;
2506
2502
  }
2507
2503
  const V = ki(k) ?? {};
2508
2504
  A(V), (F = b.current) == null || F.flexmonster.refresh();
2509
- }, [S, k]);
2505
+ }, [k]);
2510
2506
  const { save: O, saveAs: N, archive: D, detach: W } = Ii(e, b, g, P), G = Y(() => ({
2511
2507
  data: r ?? [],
2512
2508
  mapping: $ ?? void 0
2513
- }), [r, $]), X = C(async () => {
2509
+ }), [r, $]), X = S(async () => {
2514
2510
  var F;
2515
2511
  await v(m.confirmRevertChanges) && ((F = b.current) == null || F.flexmonster.setReport({ dataSource: G, ...R }));
2516
2512
  }, [v, G, m.confirmRevertChanges, R]), z = Y(() => (k == null ? void 0 : k.ownerId) === j.personalNumber, [k == null ? void 0 : k.ownerId, j.personalNumber]), Z = Y(() => {
2517
2513
  var V;
2518
2514
  return (V = k == null ? void 0 : k.users) == null ? void 0 : V.some((F) => F.id === j.personalNumber && !F.isReportOwner);
2519
- }, [k == null ? void 0 : k.users, j.personalNumber]), ne = C(async () => {
2515
+ }, [k == null ? void 0 : k.users, j.personalNumber]), ne = S(async () => {
2520
2516
  await v(m.confirmDelete(k == null ? void 0 : k.name)) && (await D(), h(null), await T());
2521
- }, [D, v, T, k == null ? void 0 : k.name, m, h]), re = C(async () => {
2517
+ }, [D, v, T, k == null ? void 0 : k.name, m, h]), re = S(async () => {
2522
2518
  await v(m.confirmDetach(k == null ? void 0 : k.name)) && (await W(), h(null), await T());
2523
2519
  }, [v, W, T, k == null ? void 0 : k.name, m, h]);
2524
2520
  return B(() => {
2525
2521
  var V, F;
2526
- g === null && h(((V = S == null ? void 0 : S.reportVersions.find((ee) => ee.isSystem === !0)) == null ? void 0 : V.reportVersionId) ?? ((F = S == null ? void 0 : S.reportVersions[0]) == null ? void 0 : F.reportVersionId) ?? null);
2527
- }, [S == null ? void 0 : S.reportVersions, g, h]), /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2522
+ g === null && h(((V = C == null ? void 0 : C.reportVersions.find((ee) => ee.isSystem === !0)) == null ? void 0 : V.reportVersionId) ?? ((F = C == null ? void 0 : C.reportVersions[0]) == null ? void 0 : F.reportVersionId) ?? null);
2523
+ }, [C == null ? void 0 : C.reportVersions, g, h]), /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2528
2524
  /* @__PURE__ */ n.jsx(Pr, { variant: "fullScreen", title: /* @__PURE__ */ n.jsxs("div", { className: "d-flex justify-content-start gap-3", children: [
2529
2525
  /* @__PURE__ */ n.jsx(K, { variant: "h3", children: t }),
2530
2526
  s,
2531
2527
  /* @__PURE__ */ n.jsxs("div", { className: "d-flex gap-1 align-items-center", children: [
2532
2528
  /* @__PURE__ */ n.jsxs($a, { size: "sm", value: g ?? void 0, onChange: L, children: [
2533
- /* @__PURE__ */ n.jsx("optgroup", { label: m.versionSelectSystem, children: S == null ? void 0 : S.reportVersions.filter((V) => V.isSystem === !0).map((V) => /* @__PURE__ */ n.jsx("option", { value: V.reportVersionId, children: V.name }, V.reportVersionId)) }),
2534
- /* @__PURE__ */ n.jsx("optgroup", { label: m.versionSelectYour, children: S == null ? void 0 : S.reportVersions.filter((V) => V.ownerId === j.personalNumber).map((V) => /* @__PURE__ */ n.jsx("option", { value: V.reportVersionId, children: V.name }, V.reportVersionId)) }),
2535
- /* @__PURE__ */ n.jsx("optgroup", { label: m.versionSelectSharedWithYou, children: S == null ? void 0 : S.reportVersions.filter((V) => V.isSystem === !1 && V.ownerId !== j.personalNumber).map((V) => /* @__PURE__ */ n.jsx("option", { value: V.reportVersionId, children: `${V.name} [${V.ownerId}]` }, V.reportVersionId)) })
2529
+ /* @__PURE__ */ n.jsx("optgroup", { label: m.versionSelectSystem, children: C == null ? void 0 : C.reportVersions.filter((V) => V.isSystem === !0).map((V) => /* @__PURE__ */ n.jsx("option", { value: V.reportVersionId, children: V.name }, V.reportVersionId)) }),
2530
+ /* @__PURE__ */ n.jsx("optgroup", { label: m.versionSelectYour, children: C == null ? void 0 : C.reportVersions.filter((V) => V.ownerId === j.personalNumber).map((V) => /* @__PURE__ */ n.jsx("option", { value: V.reportVersionId, children: V.name }, V.reportVersionId)) }),
2531
+ /* @__PURE__ */ n.jsx("optgroup", { label: m.versionSelectSharedWithYou, children: C == null ? void 0 : C.reportVersions.filter((V) => V.isSystem === !1 && V.ownerId !== j.personalNumber).map((V) => /* @__PURE__ */ n.jsx("option", { value: V.reportVersionId, children: `${V.name} [${V.ownerId}]` }, V.reportVersionId)) })
2536
2532
  ] }),
2537
2533
  /* @__PURE__ */ n.jsx(Ve, { icon: /* @__PURE__ */ n.jsx(Da, {}), onClick: O, disabled: g === null || (k == null ? void 0 : k.isSystem) || !z, children: m.save }),
2538
2534
  /* @__PURE__ */ n.jsx(Ve, { icon: /* @__PURE__ */ n.jsx(La, {}), onClick: N, className: "flex-shrink-0", children: m.saveAs }),
@@ -2610,15 +2606,15 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2610
2606
  apiGet: "/messageBoard",
2611
2607
  apiDelete: "/messageBoard/"
2612
2608
  }, bu = ({ renderAsNotifPanel: e, notifIcon: t, apiUrls: { apiGet: r = un.apiGet, apiDelete: s = un.apiDelete } = un, getIcon: a, getLinksTo: o }) => {
2613
- const c = Ze(), [l, d] = E([]), [u, m] = E(!1), [v, f] = E(!1), [p, x] = E(!1), g = C(async () => {
2609
+ const c = Ze(), [l, d] = E([]), [u, m] = E(!1), [v, f] = E(!1), [p, x] = E(!1), g = S(async () => {
2614
2610
  f(!0), await c.get(r).then(({ data: j }) => {
2615
2611
  d(j), m(!0), f(!1);
2616
2612
  }).catch(() => {
2617
2613
  d([]), f(!1);
2618
2614
  });
2619
- }, [r, c]), h = C(async (j) => c.delete(`${s}${j}`).then(() => !0).catch(() => !1), [s, c]), y = C((j) => {
2620
- h(j).then((S) => {
2621
- S && d(l.filter((T) => T.id !== j));
2615
+ }, [r, c]), h = S(async (j) => c.delete(`${s}${j}`).then(() => !0).catch(() => !1), [s, c]), y = S((j) => {
2616
+ h(j).then((C) => {
2617
+ C && d(l.filter((T) => T.id !== j));
2622
2618
  });
2623
2619
  }, [h, l]);
2624
2620
  B(() => {
@@ -2692,9 +2688,9 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2692
2688
  }, qi = ({ shortcutLink: e, IconComponent: t, IconTypeArray: r, editShortcutLink: s }) => {
2693
2689
  const { ProjectIconComponent: a } = U(oe), [o, i] = E(e.icon), [c, l] = E(e.name);
2694
2690
  console.log(o, typeof o);
2695
- const d = Y(() => !(o === e.icon && c === e.name), [o, c, e.icon, e.name]), u = C(() => {
2691
+ const d = Y(() => !(o === e.icon && c === e.name), [o, c, e.icon, e.name]), u = S(() => {
2696
2692
  i(e.icon), l(e.name);
2697
- }, [e]), m = C(() => {
2693
+ }, [e]), m = S(() => {
2698
2694
  s({ ...e, icon: o, name: c });
2699
2695
  }, [s, o, c, e]);
2700
2696
  return /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
@@ -2706,7 +2702,7 @@ const du = ({ InputContainer: e = it, value: t, onChange: r, debounceMs: s, labe
2706
2702
  ] }) })
2707
2703
  ] });
2708
2704
  }, Qi = ({ shortcutLink: e, IconComponent: t, IconTypeArray: r, editShortcutLink: s, deleteShortcutLink: a }) => {
2709
- const { ProjectIconComponent: o } = U(oe), i = C(() => {
2705
+ const { ProjectIconComponent: o } = U(oe), i = S(() => {
2710
2706
  a(e.id);
2711
2707
  }, [a, e.id]);
2712
2708
  return /* @__PURE__ */ n.jsx("tr", { className: "mb-3", children: /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
@@ -2752,7 +2748,7 @@ function tl(e, t, r) {
2752
2748
  return c.current = l.current = null, o.current = A, d.current = u.current.apply(P, L);
2753
2749
  }, j = function(A, L) {
2754
2750
  f && cancelAnimationFrame(i.current), i.current = f ? requestAnimationFrame(A) : setTimeout(A, L);
2755
- }, S = function(A) {
2751
+ }, C = function(A) {
2756
2752
  if (!m.current) return !1;
2757
2753
  var L = A - a.current;
2758
2754
  return !a.current || L >= t || L < 0 || g && A - o.current >= y;
@@ -2760,14 +2756,14 @@ function tl(e, t, r) {
2760
2756
  return i.current = null, x && c.current ? b(A) : (c.current = l.current = null, d.current);
2761
2757
  }, $ = function A() {
2762
2758
  var L = Date.now();
2763
- if (S(L)) return T(L);
2759
+ if (C(L)) return T(L);
2764
2760
  if (m.current) {
2765
2761
  var P = t - (L - a.current), k = g ? Math.min(P, y - (L - o.current)) : P;
2766
2762
  j(A, k);
2767
2763
  }
2768
2764
  }, R = function() {
2769
2765
  if (v || h) {
2770
- var A = Date.now(), L = S(A);
2766
+ var A = Date.now(), L = C(A);
2771
2767
  if (c.current = [].slice.call(arguments), l.current = s, a.current = A, L) {
2772
2768
  if (!i.current && m.current) return o.current = a.current, j($, t), p ? b(a.current) : d.current;
2773
2769
  if (g) return j($, t), b(a.current);
@@ -2789,13 +2785,13 @@ function nl(e, t) {
2789
2785
  return e === t;
2790
2786
  }
2791
2787
  function en(e, t, r) {
2792
- var s = nl, a = J(e), o = E({})[1], i = tl(C(function(l) {
2788
+ var s = nl, a = J(e), o = E({})[1], i = tl(S(function(l) {
2793
2789
  a.current = l, o({});
2794
2790
  }, [o]), t, r), c = J(e);
2795
2791
  return s(c.current, e) || (i(e), c.current = e), [a.current, i];
2796
2792
  }
2797
2793
  const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconComponent: a, IconTypeArray: o }) => {
2798
- const i = io(), { texts: c } = U(oe), [l, d] = E("star-outline"), [u, m] = E(s ? document.title.replace(s, "") : document.title), v = C(async () => {
2794
+ const i = io(), { texts: c } = U(oe), [l, d] = E("star-outline"), [u, m] = E(s ? document.title.replace(s, "") : document.title), v = S(async () => {
2799
2795
  await r({ icon: l, name: u, url: i.pathname + i.search }), e();
2800
2796
  }, [e, r, l, i.pathname, i.search, u]), f = Y(() => i.pathname + i.search, [i.pathname, i.search]);
2801
2797
  return /* @__PURE__ */ n.jsxs(Se, { show: t, onHide: e, size: "sm", children: [
@@ -2832,21 +2828,21 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
2832
2828
  o && /* @__PURE__ */ n.jsx(sl, { IconComponent: e, IconTypeArray: t, pageTitlePrefix: r, createLink: a })
2833
2829
  ] }) });
2834
2830
  }, al = (e) => {
2835
- const t = Ze(), { startLoading: r, stopLoading: s } = U(Tt), a = C(async (c) => {
2831
+ const t = Ze(), { startLoading: r, stopLoading: s } = U(Tt), a = S(async (c) => {
2836
2832
  r("submit-createShortcutLink");
2837
2833
  try {
2838
2834
  await t.post(`/dynamicForms/insert?referenceId=${e}`, c);
2839
2835
  } finally {
2840
2836
  s("submit-createShortcutLink");
2841
2837
  }
2842
- }, [t, e, r, s]), o = C(async (c) => {
2838
+ }, [t, e, r, s]), o = S(async (c) => {
2843
2839
  r("submit-updateShortcutLink");
2844
2840
  try {
2845
2841
  await t.post(`/dynamicForms/update?referenceId=${e}`, c);
2846
2842
  } finally {
2847
2843
  s("submit-updateShortcutLink");
2848
2844
  }
2849
- }, [t, e, r, s]), i = C(async (c) => {
2845
+ }, [t, e, r, s]), i = S(async (c) => {
2850
2846
  r("delete-deleteShortcutLink");
2851
2847
  try {
2852
2848
  await t.delete(`/dynamicForms/delete?referenceId=${e}&pk=${c.toString()}`);
@@ -2864,19 +2860,19 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
2864
2860
  throw new Error("Tried to make operation on null shortcutLinks.");
2865
2861
  return e;
2866
2862
  }, Iu = ({ children: e, referenceId: t }) => {
2867
- const { user: r } = U(Lt), s = C((f) => f.map((p) => ({ id: p.id, icon: p.icon, name: p.name, url: p.url })), []), { data: a, reloadData: o } = It(`/dynamicForms/lookup-data-all?referenceId=${t}&employee=${r == null ? void 0 : r.personalNumber}`, {
2863
+ const { user: r } = U(Lt), s = S((f) => f.map((p) => ({ id: p.id, icon: p.icon, name: p.name, url: p.url })), []), { data: a, reloadData: o } = It(`/dynamicForms/lookup-data-all?referenceId=${t}&employee=${r == null ? void 0 : r.personalNumber}`, {
2868
2864
  silent: !0,
2869
2865
  dataTransformer: s,
2870
2866
  enabled: r !== null
2871
- }), { create: i, update: c, remove: l } = al(t), d = C(async (f) => {
2867
+ }), { create: i, update: c, remove: l } = al(t), d = S(async (f) => {
2872
2868
  const p = hr(r);
2873
2869
  if (ol(a).length >= bn)
2874
2870
  throw new Error("Cannot add more shortcut links.");
2875
2871
  await i({ ...f, employee: p.personalNumber }), await o();
2876
- }, [i, o, a, r]), u = C(async (f) => {
2872
+ }, [i, o, a, r]), u = S(async (f) => {
2877
2873
  const p = hr(r);
2878
2874
  await c({ ...f, employee: p.personalNumber }), await o();
2879
- }, [o, c, r]), m = C(async (f) => {
2875
+ }, [o, c, r]), m = S(async (f) => {
2880
2876
  await l(f), await o();
2881
2877
  }, [o, l]), v = Y(() => ({
2882
2878
  shortcutLinks: a,
@@ -2959,13 +2955,13 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
2959
2955
  const a = localStorage.getItem("dashboardConfig");
2960
2956
  a ? r(JSON.parse(a)) : e && r(e);
2961
2957
  }, [e]);
2962
- const s = C((a) => {
2958
+ const s = S((a) => {
2963
2959
  r(a), localStorage.setItem("dashboardConfig", JSON.stringify(a));
2964
2960
  }, []);
2965
2961
  return { dashboardConfig: t, onChangeDashboardConfig: s };
2966
2962
  }, $u = ({ widgetGroups: e, availableWidgets: t, editMode: r, defaultDashboardConfig: s }) => {
2967
2963
  var v;
2968
- const { texts: { homeDashboard: a } } = U(oe), { dashboardConfig: o, onChangeDashboardConfig: i } = kl(s), c = C((f, p) => {
2964
+ const { texts: { homeDashboard: a } } = U(oe), { dashboardConfig: o, onChangeDashboardConfig: i } = kl(s), c = S((f, p) => {
2969
2965
  var x, g;
2970
2966
  f === ((x = o.widgets) == null ? void 0 : x.length) ? i({
2971
2967
  ...o,
@@ -2974,19 +2970,19 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
2974
2970
  ...o,
2975
2971
  widgets: ((g = o.widgets) == null ? void 0 : g.map((h, y) => y === f ? { widgetId: p, fullWidth: !1 } : h)) ?? []
2976
2972
  });
2977
- }, [o, i]), l = C((f) => {
2973
+ }, [o, i]), l = S((f) => {
2978
2974
  var p, x;
2979
2975
  ((p = o.widgets[f]) == null ? void 0 : p.widgetId) === -1 ? i({
2980
2976
  ...o,
2981
2977
  widgets: ((x = o.widgets) == null ? void 0 : x.filter((g, h) => h !== f)) ?? []
2982
2978
  }) : c(f, -1);
2983
- }, [o, i, c]), d = C((f) => {
2979
+ }, [o, i, c]), d = S((f) => {
2984
2980
  var p;
2985
2981
  i({
2986
2982
  ...o,
2987
2983
  widgets: ((p = o.widgets) == null ? void 0 : p.map((x, g) => g === f ? { ...x, fullWidth: !x.fullWidth } : x)) ?? []
2988
2984
  });
2989
- }, [o, i]), u = C((f, p, x) => f ? /* @__PURE__ */ n.jsxs("div", { className: _(Me.widgetWrapper, {
2985
+ }, [o, i]), u = S((f, p, x) => f ? /* @__PURE__ */ n.jsxs("div", { className: _(Me.widgetWrapper, {
2990
2986
  [Me.widgetEdit]: r && f.id !== -1
2991
2987
  }, { [Me.fullWidth]: x }), children: [
2992
2988
  r && /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
@@ -3063,7 +3059,7 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
3063
3059
  actionsDropdown: Kl
3064
3060
  }, tn = ({ show: e, onCancel: t, items: r, currentSelection: s, onSelectionChange: a, onSearchQueryChange: o, texts: i, itemsNameWidth: c, additionalColumns: l, displayIdAsName: d = !1, autoHideSearch: u = !1, allItemsLength: m, disabled: v, isLoading: f = !1, inputRef: p, archiveColumn: x = "archive", addNewOptionPath: g, refreshOptions: h }) => {
3065
3061
  var ct;
3066
- const { texts: { customSelect: y } } = U(oe), w = J(null), b = J(null), j = J(null), S = J(null), T = J(null), [$, R] = E(""), [A] = en($, 500), [, L] = E(!1), { copyToClipboard: P } = co(), k = (ct = p.current) == null ? void 0 : ct.getBoundingClientRect(), Q = (k == null ? void 0 : k.x) ?? 0, O = ((k == null ? void 0 : k.x) ?? 0) + ((k == null ? void 0 : k.width) ?? 0), N = (k == null ? void 0 : k.y) ?? 0, D = ((k == null ? void 0 : k.y) ?? 0) + ((k == null ? void 0 : k.height) ?? 0), W = (k == null ? void 0 : k.width) ?? 0, G = (k == null ? void 0 : k.height) ?? 0, X = 5, z = Y(() => Q ? Q > window.innerWidth / 2 : !1, [Q]), Z = Y(() => N ? N > window.innerHeight / 2 : !1, [N]);
3062
+ const { texts: { customSelect: y } } = U(oe), w = J(null), b = J(null), j = J(null), C = J(null), T = J(null), [$, R] = E(""), [A] = en($, 500), [, L] = E(!1), { copyToClipboard: P } = co(), k = (ct = p.current) == null ? void 0 : ct.getBoundingClientRect(), Q = (k == null ? void 0 : k.x) ?? 0, O = ((k == null ? void 0 : k.x) ?? 0) + ((k == null ? void 0 : k.width) ?? 0), N = (k == null ? void 0 : k.y) ?? 0, D = ((k == null ? void 0 : k.y) ?? 0) + ((k == null ? void 0 : k.height) ?? 0), W = (k == null ? void 0 : k.width) ?? 0, G = (k == null ? void 0 : k.height) ?? 0, X = 5, z = Y(() => Q ? Q > window.innerWidth / 2 : !1, [Q]), Z = Y(() => N ? N > window.innerHeight / 2 : !1, [N]);
3067
3063
  B(() => {
3068
3064
  var I;
3069
3065
  e && ((I = j.current) == null || I.focus());
@@ -3076,27 +3072,27 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
3076
3072
  B(() => {
3077
3073
  e && r.length > 0 ? re(0) : re(null);
3078
3074
  }, [r, e]);
3079
- const V = Y(() => ne !== null ? r.at(ne) ?? null : null, [ne, r]), F = C((I, M) => {
3075
+ const V = Y(() => ne !== null ? r.at(ne) ?? null : null, [ne, r]), F = S((I, M) => {
3080
3076
  var le, ve;
3081
3077
  const H = document.getElementById(`item-${I}`);
3082
3078
  if (H) {
3083
3079
  const ce = H.clientHeight ?? 0;
3084
- M === "down" ? (le = S.current) == null || le.scrollBy({
3080
+ M === "down" ? (le = C.current) == null || le.scrollBy({
3085
3081
  left: 0,
3086
3082
  top: ce,
3087
3083
  behavior: "smooth"
3088
- }) : (ve = S.current) == null || ve.scrollBy({
3084
+ }) : (ve = C.current) == null || ve.scrollBy({
3089
3085
  left: 0,
3090
3086
  top: -ce,
3091
3087
  behavior: "smooth"
3092
3088
  });
3093
3089
  }
3094
- }, []), ee = C((I) => {
3090
+ }, []), ee = S((I) => {
3095
3091
  if (ne === null || v)
3096
3092
  return;
3097
3093
  const M = ne + I;
3098
3094
  M < 0 || M >= r.length || re((H) => (H !== null && F(H, I > 0 ? "down" : "up"), M));
3099
- }, [ne, r, v, F]), ae = C((I) => {
3095
+ }, [ne, r, v, F]), ae = S((I) => {
3100
3096
  if (e)
3101
3097
  switch (I.key) {
3102
3098
  case "Escape":
@@ -3112,7 +3108,7 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
3112
3108
  I.stopPropagation(), I.preventDefault(), ee(1);
3113
3109
  break;
3114
3110
  }
3115
- }, [t, e, ee, V, v, a]), be = C(() => {
3111
+ }, [t, e, ee, V, v, a]), be = S(() => {
3116
3112
  L((I) => !I);
3117
3113
  }, []);
3118
3114
  B(() => (window.addEventListener("scroll", be), () => {
@@ -3157,7 +3153,7 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
3157
3153
  var M;
3158
3154
  return R(((M = I.target) == null ? void 0 : M.value) ?? "");
3159
3155
  } }) }),
3160
- f ? /* @__PURE__ */ n.jsx("div", { className: we.loadingContainer, children: /* @__PURE__ */ n.jsx(Fn, { animation: "border", variant: "primary" }) }) : r.length > 0 && /* @__PURE__ */ n.jsxs("div", { ref: S, className: _("items", we.itemsContainer), children: [
3156
+ f ? /* @__PURE__ */ n.jsx("div", { className: we.loadingContainer, children: /* @__PURE__ */ n.jsx(Fn, { animation: "border", variant: "primary" }) }) : r.length > 0 && /* @__PURE__ */ n.jsxs("div", { ref: C, className: _("items", we.itemsContainer), children: [
3161
3157
  l && l.length > 0 && /* @__PURE__ */ n.jsxs("div", { className: _("header-row border-bottom", we.headerRow), children: [
3162
3158
  /* @__PURE__ */ n.jsx("div", { className: we.name }),
3163
3159
  l == null ? void 0 : l.filter((I) => I.key !== x).map((I) => /* @__PURE__ */ n.jsx("div", { className: we.columnItem, style: {
@@ -3204,7 +3200,7 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
3204
3200
  header: ic,
3205
3201
  item: lc
3206
3202
  }, cc = ({ show: e, query: t, onCancel: r, groups: s, isLoading: a, searchTypes: o }) => {
3207
- const { texts: { appSearch: i } } = U(oe), c = J(null), l = C((d) => {
3203
+ const { texts: { appSearch: i } } = U(oe), c = J(null), l = S((d) => {
3208
3204
  var m;
3209
3205
  const u = (m = o.find((v) => v.key === d.type)) == null ? void 0 : m.toPath;
3210
3206
  return u ? `${u}/${d.searchKey}` : "/not-found";
@@ -3240,7 +3236,7 @@ const rl = ({ closeModal: e, isOpen: t, createLink: r, pageTitlePrefix: s, IconC
3240
3236
  ] }, d.key.category);
3241
3237
  }) }) });
3242
3238
  }, dc = (e, t) => {
3243
- const r = Ze(), [s, a] = E(!1), [o, i] = E([]), c = !e || !e.key, l = C(() => {
3239
+ const r = Ze(), [s, a] = E(!1), [o, i] = E([]), c = !e || !e.key, l = S(() => {
3244
3240
  if (t.length < 3) {
3245
3241
  i([]);
3246
3242
  return;
@@ -3451,7 +3447,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3451
3447
  }, [s, e]), B(() => {
3452
3448
  f >= r.length && p(r.length - 1);
3453
3449
  }, [r, f]);
3454
- const y = C((w) => {
3450
+ const y = S((w) => {
3455
3451
  switch (w.key) {
3456
3452
  case "ArrowLeft":
3457
3453
  w.stopPropagation(), g && p((b) => b - 1);
@@ -3474,14 +3470,14 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3474
3470
  i && /* @__PURE__ */ n.jsx($s, { accept: ".jpg,.jpeg,.png", onUpload: (w) => {
3475
3471
  w.length > 0 && i(Array.from(w));
3476
3472
  }, icon: /* @__PURE__ */ n.jsx(Gr, { style: { fontSize: 18 } }), multiple: !0, className: "me-3", children: a ?? null }),
3477
- x && (c == null ? void 0 : c.map(({ label: w, onClick: b, ...j }, S) => /* @__PURE__ */ n.jsx(
3473
+ x && (c == null ? void 0 : c.map(({ label: w, onClick: b, ...j }, C) => /* @__PURE__ */ n.jsx(
3478
3474
  Ve,
3479
3475
  {
3480
3476
  onClick: () => b(x.id),
3481
3477
  ...j,
3482
3478
  children: w
3483
3479
  },
3484
- `action-${S}`
3480
+ `action-${C}`
3485
3481
  )))
3486
3482
  ] }),
3487
3483
  /* @__PURE__ */ n.jsx("div", { role: "button", onClick: t, children: /* @__PURE__ */ n.jsx(Pe, { style: { fontSize: "32px" } }) })
@@ -3544,7 +3540,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3544
3540
  "type-icon": "_type-icon_z9z4m_28",
3545
3541
  typeIcon: Gc
3546
3542
  }, Yc = ({ level: e, children: t, customIcon: r, noIcon: s }) => {
3547
- const { ProjectIconComponent: a } = U(oe), o = C(() => {
3543
+ const { ProjectIconComponent: a } = U(oe), o = S(() => {
3548
3544
  switch (e) {
3549
3545
  case "info":
3550
3546
  return /* @__PURE__ */ n.jsx(a, { icon: "info" });
@@ -3606,7 +3602,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3606
3602
  /* @__PURE__ */ n.jsx("div", { className: _("text-primary", st.stepIcon), children: t.icon ?? /* @__PURE__ */ n.jsx(Ua, {}) })
3607
3603
  ] }) })
3608
3604
  ] }, r)) }), sd = (e, t, r, s = !0) => {
3609
- const a = Ze({ silent: s, differentBaseUrl: t, customToken: r }), [o, i] = E(!1), [c, l] = E(null), d = C(async (u) => {
3605
+ const a = Ze({ silent: s, differentBaseUrl: t, customToken: r }), [o, i] = E(!1), [c, l] = E(null), d = S(async (u) => {
3610
3606
  i(!0), l(null), a.get(e, {
3611
3607
  signal: u,
3612
3608
  responseType: "blob"
@@ -3659,7 +3655,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3659
3655
  const r = new Date(e);
3660
3656
  return Pt(r).to === t ? "M" : Nt(r).to === t ? "Y" : (console.log(Nt(r), t), "C");
3661
3657
  }, dd = (e, t, r) => {
3662
- const s = C((i, c) => {
3658
+ const s = S((i, c) => {
3663
3659
  if (e === "C") {
3664
3660
  r((l) => ({ ...l, [i]: c }));
3665
3661
  return;
@@ -3684,7 +3680,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3684
3680
  t("C"), r((l) => ({ ...l, [i]: c }));
3685
3681
  break;
3686
3682
  }
3687
- }, [e, r, t]), a = C((i) => {
3683
+ }, [e, r, t]), a = S((i) => {
3688
3684
  r((c) => {
3689
3685
  if (c.from === null || c.to === null)
3690
3686
  return c;
@@ -3704,7 +3700,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3704
3700
  to: Ke(d.toISOString())
3705
3701
  };
3706
3702
  });
3707
- }, [e, r]), o = C((i) => {
3703
+ }, [e, r]), o = S((i) => {
3708
3704
  i === "D" ? r((c) => ({ from: c.from, to: c.from })) : i === "M" ? r((c) => {
3709
3705
  if (c.from === null)
3710
3706
  return c;
@@ -3739,12 +3735,12 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3739
3735
  }, children: /* @__PURE__ */ n.jsx(o, { icon: "chevron-right" }) })
3740
3736
  ] });
3741
3737
  }, Ru = ({ defaultMonth: e, searchKey: t = "monthFrom", yearMin: r, yearMax: s }) => {
3742
- const { localizationContext: a } = U(oe), { dateFnsLocale: o } = U(a), { searchParams: i, setSearch: c } = uo(), l = i.get(t), d = l ? Ct(l) : e, u = C((m) => {
3738
+ const { localizationContext: a } = U(oe), { dateFnsLocale: o } = U(a), { searchParams: i, setSearch: c } = uo(), l = i.get(t), d = l ? Ct(l) : e, u = S((m) => {
3743
3739
  c(t, yn(m, { representation: "date" }));
3744
3740
  }, [t, c]);
3745
3741
  return /* @__PURE__ */ n.jsx(Ho, { month: d, onChangeMonth: u, locale: o, yearMin: r, yearMax: s });
3746
3742
  }, Mu = ({ defaultYear: e, searchKey: t = "yearFrom", ...r }) => {
3747
- const [s, a] = Zr(t, yn(e, { representation: "date" })), o = s ? Ct(s) : e, i = C((c) => {
3743
+ const [s, a] = Zr(t, yn(e, { representation: "date" })), o = s ? Ct(s) : e, i = S((c) => {
3748
3744
  a(yn(c, { representation: "date" }));
3749
3745
  }, [a]);
3750
3746
  return /* @__PURE__ */ n.jsx(Go, { year: o, onChangeYear: i, ...r });
@@ -3873,7 +3869,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3873
3869
  }
3874
3870
  }
3875
3871
  }, kd = ({ schema: e, columns: t, setColumns: r, initialItem: s, onEdit: a, onDelete: o, customPickers: i }) => {
3876
- const { ProjectIconComponent: c } = U(oe), [l, d] = E(s), u = C((f, p) => {
3872
+ const { ProjectIconComponent: c } = U(oe), [l, d] = E(s), u = S((f, p) => {
3877
3873
  console.log("changeValue", f, p), d((x) => ({
3878
3874
  ...x,
3879
3875
  [f]: {
@@ -3881,7 +3877,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3881
3877
  value: p
3882
3878
  }
3883
3879
  }));
3884
- }, []), m = (f) => (f == null ? void 0 : f.value) !== (f == null ? void 0 : f.defaultValue), v = C(() => Object.keys(l).some((f) => m(l[f])), [l]);
3880
+ }, []), m = (f) => (f == null ? void 0 : f.value) !== (f == null ? void 0 : f.defaultValue), v = S(() => Object.keys(l).some((f) => m(l[f])), [l]);
3885
3881
  return B(() => {
3886
3882
  d(s);
3887
3883
  }, [s]), /* @__PURE__ */ n.jsxs("tr", { className: _("table-row", me.tableRow), children: [
@@ -3895,7 +3891,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3895
3891
  /* @__PURE__ */ n.jsx("td", { className: _("table-cell", me.tableCell, me.stickyLast), children: /* @__PURE__ */ n.jsx(te, { color: "danger", onClick: () => o(l[e.primaryKey ?? ""].value), children: /* @__PURE__ */ n.jsx(c, { icon: "delete" }) }) })
3896
3892
  ] });
3897
3893
  }, Sd = ({ schema: e, columns: t, setColumns: r, onCreate: s, customPickers: a }) => {
3898
- const { ProjectIconComponent: o } = U(oe), [i, c] = E(null), l = C(() => {
3894
+ const { ProjectIconComponent: o } = U(oe), [i, c] = E(null), l = S(() => {
3899
3895
  var m;
3900
3896
  const u = {};
3901
3897
  (m = e.columns) == null || m.forEach((v) => {
@@ -3905,7 +3901,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
3905
3901
  defaultValue: f
3906
3902
  };
3907
3903
  }), c(u);
3908
- }, [e]), d = C((u, m) => {
3904
+ }, [e]), d = S((u, m) => {
3909
3905
  c((v) => v && {
3910
3906
  ...v,
3911
3907
  [u]: {
@@ -4031,15 +4027,15 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
4031
4027
  apiExportGet: "/dynamicForms/export"
4032
4028
  }, Bu = ({ id: e, page: t, setPage: r, filters: s, setFilter: a, sortByField: o, sortByType: i, setSortBy: c, appUrls: { appDetail: l = kr.appDetail } = kr, apiUrls: { apiSchemaGet: d = at.apiSchemaGet, apiDataGet: u = at.apiDataGet, apiItemPost: m = at.apiItemPost, apiItemDelete: v = at.apiItemDelete, apiItemCreate: f = at.apiItemCreate, apiExportGet: p = at.apiExportGet } = at, customPickers: x }) => {
4033
4029
  var ce, de, Ie, Te, Ee, dt;
4034
- const { texts: { dynamicForms: g }, ProjectIconComponent: h } = U(oe), y = Ze(), { startLoading: w, stopLoading: b } = U(Tt), [j, S] = E(null), [T, $] = E(null), [R, A] = E(null), [L, P] = E(null), [k, Q] = E(!1), { addNotification: O } = Vr(), [N, D] = E([]), { confirm: W } = Qt(), G = 20, X = G + 1, z = L ? Math.ceil(L.length / G) : 1, Z = t ? t > 1 : !1, ne = t ? t < z : !1, re = t ? (t - 1) * G : 0, V = t ? t * G : G, F = Y(() => L ? L.length > X : !1, [L, X]), ee = Y(() => F ? (L == null ? void 0 : L.slice(re, V)) ?? null : L ?? null, [F, L, re, V]), [ae, be] = E(null);
4030
+ const { texts: { dynamicForms: g }, ProjectIconComponent: h } = U(oe), y = Ze(), { startLoading: w, stopLoading: b } = U(Tt), [j, C] = E(null), [T, $] = E(null), [R, A] = E(null), [L, P] = E(null), [k, Q] = E(!1), { addNotification: O } = Vr(), [N, D] = E([]), { confirm: W } = Qt(), G = 20, X = G + 1, z = L ? Math.ceil(L.length / G) : 1, Z = t ? t > 1 : !1, ne = t ? t < z : !1, re = t ? (t - 1) * G : 0, V = t ? t * G : G, F = Y(() => L ? L.length > X : !1, [L, X]), ee = Y(() => F ? (L == null ? void 0 : L.slice(re, V)) ?? null : L ?? null, [F, L, re, V]), [ae, be] = E(null);
4035
4031
  B(() => {
4036
- S(null), $(null), Q(!1), D([]), be(null);
4032
+ C(null), $(null), Q(!1), D([]), be(null);
4037
4033
  }, [e]);
4038
- const Le = C(async () => {
4034
+ const Le = S(async () => {
4039
4035
  w("dynamicFormSchema"), await y.get(`${d}?id=${e}`).then(({ data: q }) => {
4040
- S(q), b("dynamicFormSchema");
4036
+ C(q), b("dynamicFormSchema");
4041
4037
  }).catch(() => b("dynamicFormSchema"));
4042
- }, [y, e, w, b, d]), ze = C(async () => {
4038
+ }, [y, e, w, b, d]), ze = S(async () => {
4043
4039
  var q;
4044
4040
  if (!(j === null || ((q = j.id) == null ? void 0 : q.toString()) !== e)) {
4045
4041
  if (j.masterReference && !ae) {
@@ -4057,22 +4053,22 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
4057
4053
  $(ge), b("dynamicFormData");
4058
4054
  }).catch(() => b("dynamicFormData"));
4059
4055
  }
4060
- }, [y, e, j, w, b, k, ae, u]), se = C(async () => {
4056
+ }, [y, e, j, w, b, k, ae, u]), se = S(async () => {
4061
4057
  var q;
4062
4058
  j === null || ((q = j.id) == null ? void 0 : q.toString()) !== e || j.masterReference && !ae || (w("dynamicFormExport"), await y.get(`${p}?id=${e}&showArchive=${k}${j.masterReference ? `&master=${ae}` : ""}`, {
4063
4059
  responseType: "blob"
4064
4060
  }).then((ue) => Qa(ue, { fallbackName: `export-${e}` })).finally(() => b("dynamicFormExport")));
4065
- }, [y, e, j, w, b, k, ae, p]), _e = C(async (q) => (w("dynamicFormEdit"), y.post(`${m}?id=${e}`, q).then(() => (b("dynamicFormEdit"), D([]), !0)).catch((ue) => (b("dynamicFormEdit"), D(sn(ue)), !1))), [y, e, w, b, m]), Ne = C(async (q) => (w("dynamicFormDelete"), y.delete(`${v}?id=${e}&pk=${q}`).then(() => (b("dynamicFormDelete"), D([]), !0)).catch((ue) => (b("dynamicFormDelete"), D(sn(ue)), !1))), [y, e, w, b, v]), et = C(async (q) => (w("dynamicFormCreate"), y.post(`${f}?id=${e}`, q).then(({ data: ue }) => (b("dynamicFormCreate"), D([]), ue)).catch((ue) => (b("dynamicFormCreate"), D(sn(ue)), null))), [y, e, w, b, f]), ct = C(async (q) => {
4061
+ }, [y, e, j, w, b, k, ae, p]), _e = S(async (q) => (w("dynamicFormEdit"), y.post(`${m}?id=${e}`, q).then(() => (b("dynamicFormEdit"), D([]), !0)).catch((ue) => (b("dynamicFormEdit"), D(sn(ue)), !1))), [y, e, w, b, m]), Ne = S(async (q) => (w("dynamicFormDelete"), y.delete(`${v}?id=${e}&pk=${q}`).then(() => (b("dynamicFormDelete"), D([]), !0)).catch((ue) => (b("dynamicFormDelete"), D(sn(ue)), !1))), [y, e, w, b, v]), et = S(async (q) => (w("dynamicFormCreate"), y.post(`${f}?id=${e}`, q).then(({ data: ue }) => (b("dynamicFormCreate"), D([]), ue)).catch((ue) => (b("dynamicFormCreate"), D(sn(ue)), null))), [y, e, w, b, f]), ct = S(async (q) => {
4066
4062
  j && await _e(j.masterReference ? { ...q, [j.masterReferenceColumn ?? ""]: ae } : q) && (O(g.editSuccess, "success"), $((ue) => ue && ue.map((ge) => {
4067
4063
  var fe;
4068
4064
  return ((fe = ge[(j == null ? void 0 : j.primaryKey) ?? ""]) == null ? void 0 : fe.value) === q[(j == null ? void 0 : j.primaryKey) ?? ""] ? br(q, j) : ge;
4069
4065
  })));
4070
- }, [O, _e, j, ae, g]), I = C(async (q) => {
4066
+ }, [O, _e, j, ae, g]), I = S(async (q) => {
4071
4067
  await W(g.deleteConfirm) && await Ne(q) && (O(g.deleteSuccess, "success"), $((ue) => ue && ue.filter((ge) => {
4072
4068
  var fe;
4073
4069
  return ((fe = ge[(j == null ? void 0 : j.primaryKey) ?? ""]) == null ? void 0 : fe.value) !== q;
4074
4070
  })));
4075
- }, [O, Ne, g, W, j]), M = C(async (q) => {
4071
+ }, [O, Ne, g, W, j]), M = S(async (q) => {
4076
4072
  if (!j)
4077
4073
  return !1;
4078
4074
  const ue = await et(j.masterReference ? { ...q, [j.masterReferenceColumn ?? ""]: ae } : q);
@@ -4084,7 +4080,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
4084
4080
  return !1;
4085
4081
  }, [O, et, g, j, ae]), H = (q) => {
4086
4082
  q > z ? r(z) : q < 1 && r(1), r(q);
4087
- }, le = C(() => {
4083
+ }, le = S(() => {
4088
4084
  if (!T || !j) {
4089
4085
  A(null);
4090
4086
  return;
@@ -4113,7 +4109,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
4113
4109
  }
4114
4110
  }));
4115
4111
  A(q);
4116
- }, [T, s, j]), ve = C(() => {
4112
+ }, [T, s, j]), ve = S(() => {
4117
4113
  if (!R || !j) {
4118
4114
  P([]);
4119
4115
  return;
@@ -4218,7 +4214,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
4218
4214
  id: g.id,
4219
4215
  name: g.name ?? "",
4220
4216
  items: f.filter((h) => h.group === g.id)
4221
- })).filter((g) => g.items.length > 0), [r, f]), x = C(async () => {
4217
+ })).filter((g) => g.items.length > 0), [r, f]), x = S(async () => {
4222
4218
  l("dynamicForms"), await c.get(i).then(({ data: g }) => {
4223
4219
  m(g), d("dynamicForms");
4224
4220
  }).catch(() => d("dynamicForms"));
@@ -4315,7 +4311,7 @@ const Cc = "_lightbox_18t5m_1", Ic = "_show_18t5m_16", $c = "_header_18t5m_20",
4315
4311
  reportsGet: "/reports",
4316
4312
  reportsLastUsedGet: "/reports/last-used"
4317
4313
  }, Ku = ({ groups: e, apiUrls: { reportsGet: t = pn.reportsGet, reportsLastUsedGet: r = pn.reportsLastUsedGet } = pn, getReportName: s, getReportDescription: a, getGroupTitle: o, getReportRoute: i }) => {
4318
- const { texts: { reports: c } } = U(oe), [l, d] = E(""), [u] = en(l, 500), m = C((g) => g.map((h) => ({
4314
+ const { texts: { reports: c } } = U(oe), [l, d] = E(""), [u] = en(l, 500), m = S((g) => g.map((h) => ({
4319
4315
  ...h,
4320
4316
  groupId: !h.groupId || h.groupId === 0 || !e.some((y) => y === h.groupId) ? 999 : h.groupId
4321
4317
  })), [e]), { data: v } = It(t, { dataTransformer: m }), f = Y(() => {