affiliate-front-shared 1.3.27 → 1.3.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -4,9 +4,9 @@ var lt = (r, e, t) => Mn(r, typeof e != "symbol" ? e + "" : e, t);
4
4
  import { jsx as s, Fragment as oe, jsxs as v } from "react/jsx-runtime";
5
5
  import * as $ from "react";
6
6
  import ft, { createContext as At, useContext as xt, useEffect as K, useState as M, useRef as wt, useMemo as we } from "react";
7
- import { Menu as Fr, DatePicker as jr, Table as Vt, Dropdown as Me, Select as Ft, Button as Oe, Input as _e, Modal as Br, notification as ht, Form as Ae, Checkbox as Pn, Skeleton as zn, Pagination as Hn, Spin as Ct, Breadcrumb as Rn, Empty as _r, Tabs as Ur, Tooltip as Nn, Upload as An } from "antd";
7
+ import { Menu as Fr, DatePicker as jr, Table as Vt, Dropdown as Me, Select as Ft, Button as Oe, Input as Be, Modal as Br, notification as ht, Form as Ne, Checkbox as Pn, Skeleton as zn, Pagination as Hn, Spin as Ct, Breadcrumb as Rn, Empty as _r, Tabs as Ur, Tooltip as Nn, Upload as An } from "antd";
8
8
  import m, { keyframes as Vn } from "styled-components";
9
- import { useNavigate as Pe, useLocation as Ue, useSearchParams as Fn, useParams as jn, UNSAFE_NavigationContext as Bn } from "react-router";
9
+ import { useNavigate as Pe, useLocation as _e, useSearchParams as Fn, useParams as jn, UNSAFE_NavigationContext as Bn } from "react-router";
10
10
  import { create as Gr, useStore as _n } from "zustand";
11
11
  import { useTranslation as Un, initReactI18next as Gn } from "react-i18next";
12
12
  import * as Wn from "echarts";
@@ -22,14 +22,14 @@ function Cl({
22
22
  }) {
23
23
  return /* @__PURE__ */ s(Wr.Provider, { value: r, children: e });
24
24
  }
25
- function ze() {
25
+ function Ue() {
26
26
  return xt(Wr);
27
27
  }
28
28
  let Ce = (r) => r;
29
29
  function tr(r) {
30
30
  Ce = r;
31
31
  }
32
- const j = (r, e) => Ce(`general.${r}`, e), J = (r, e) => Ce(`actions.${r}`, e), G = (r, e) => Ce(`authentication.${r}`, e), de = (r, e) => Ce(`months.${r}`, e), Re = (r, e) => Ce(`date.${r}`, e), Ee = (r, e) => Ce(`weekDays.${r}`, e), Jn = (r, e) => Ce(`noData.${r}`, e), rr = (r, e) => Ce(`comingSoon.${r}`, e);
32
+ const j = (r, e) => Ce(`general.${r}`, e), J = (r, e) => Ce(`actions.${r}`, e), G = (r, e) => Ce(`authentication.${r}`, e), de = (r, e) => Ce(`months.${r}`, e), He = (r, e) => Ce(`date.${r}`, e), Ee = (r, e) => Ce(`weekDays.${r}`, e), Jn = (r, e) => Ce(`noData.${r}`, e), rr = (r, e) => Ce(`comingSoon.${r}`, e);
33
33
  function Sl({ t: r, children: e }) {
34
34
  return tr(r), K(() => {
35
35
  tr(r);
@@ -149,29 +149,30 @@ const jt = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16
149
149
  margin-left: 1.5rem !important;
150
150
  }
151
151
  }
152
- `, Yr = (r, e = []) => {
153
- const [t, n] = M(null), [i, o] = M(null), [a, l] = M(!0), [d, c] = M(null), u = async () => {
154
- var p;
155
- try {
156
- l(!0), n(null);
157
- const f = await r();
158
- n(f), (p = f == null ? void 0 : f.data) != null && p.items && o(f.data.items);
159
- } catch {
160
- c("Failed to fetch data");
161
- } finally {
162
- l(!1);
163
- }
152
+ `, Yr = (r, e = [], t = !0) => {
153
+ const [n, i] = M(null), [o, a] = M(null), [l, d] = M(!0), [c, u] = M(null), p = async () => {
154
+ var h;
155
+ if (t)
156
+ try {
157
+ d(!0), i(null);
158
+ const f = await r();
159
+ i(f), (h = f == null ? void 0 : f.data) != null && h.items && a(f.data.items);
160
+ } catch {
161
+ u("Failed to fetch data");
162
+ } finally {
163
+ d(!1);
164
+ }
164
165
  };
165
166
  return K(() => {
166
- u();
167
+ p();
167
168
  }, [...e]), {
168
- response: t,
169
- loading: a,
170
- error: d,
171
- fetchData: u,
172
- listItems: i
169
+ response: n,
170
+ loading: l,
171
+ error: c,
172
+ fetchData: p,
173
+ listItems: o
173
174
  };
174
- }, He = Gr((r, e) => ({
175
+ }, ze = Gr((r, e) => ({
175
176
  user: localStorage.getItem("userData") ? JSON.parse(localStorage.getItem("userData")) : null,
176
177
  prefersDark: !1,
177
178
  storedThemeMode: null,
@@ -272,7 +273,7 @@ const jt = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16
272
273
  position: absolute !important;
273
274
  z-index: 10000;
274
275
  `, si = ({ closeProfileDropdown: r }) => {
275
- const e = Pe(), { getCustomers: t, postSelectedCustomer: n } = ze(), { storedThemeMode: i, logout: o, setThemeMode: a, user: l } = He(), { i18n: d } = Un();
276
+ const e = Pe(), { getCustomers: t, postSelectedCustomer: n } = Ue(), { storedThemeMode: i, logout: o, setThemeMode: a, user: l } = ze(), { i18n: d } = Un();
276
277
  function c() {
277
278
  o(), e("/authorization/login");
278
279
  }
@@ -282,8 +283,8 @@ const jt = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16
282
283
  const p = (y, O) => /* @__PURE__ */ v(ii, { children: [
283
284
  /* @__PURE__ */ s(oi, { children: y }),
284
285
  O && /* @__PURE__ */ s("span", { children: /* @__PURE__ */ s(ni, {}) })
285
- ] }), { response: f } = Yr(t ?? (() => Promise.resolve({ data: [] })), []);
286
- async function h(y) {
286
+ ] }), { response: h } = Yr(t ?? (() => Promise.resolve({ data: [] })), []);
287
+ async function f(y) {
287
288
  if (!n) return;
288
289
  const P = (await n(y)).data.value;
289
290
  localStorage.setItem("useToken", P.token), localStorage.setItem("userData", JSON.stringify(P));
@@ -321,7 +322,7 @@ const jt = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16
321
322
  ) }, "30-3")
322
323
  ] }, "30"),
323
324
  /* @__PURE__ */ s(te.Divider, {}),
324
- /* @__PURE__ */ s(te.SubMenu, { title: "ConnectedAccounts", children: ((f == null ? void 0 : f.data) || []).map((y) => /* @__PURE__ */ s(te.Item, { onClick: () => h(y.id), children: p(y.name) }, y.id)) }, "40"),
325
+ /* @__PURE__ */ s(te.SubMenu, { title: "ConnectedAccounts", children: ((h == null ? void 0 : h.data) || []).map((y) => /* @__PURE__ */ s(te.Item, { onClick: () => f(y.id), children: p(y.name) }, y.id)) }, "40"),
325
326
  /* @__PURE__ */ s(te.Divider, {}),
326
327
  /* @__PURE__ */ s(te.Item, { onClick: c, children: "LogOut" }, "100")
327
328
  ]
@@ -329,7 +330,7 @@ const jt = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16
329
330
  "10"
330
331
  ) });
331
332
  }, Bt = ({ items: r, topLogoPrimaryUrl: e, shortName: t }) => {
332
- const n = Ue(), [i, o] = M(!1), a = wt(null), l = () => o((d) => !d);
333
+ const n = _e(), [i, o] = M(!1), a = wt(null), l = () => o((d) => !d);
333
334
  return K(() => {
334
335
  function d(c) {
335
336
  a.current && !a.current.contains(c.target) && o(!1);
@@ -657,14 +658,14 @@ const Di = m.span`
657
658
  /* @__PURE__ */ s(vi, { backgroundcolor: i, children: /* @__PURE__ */ s("img", { src: t, alt: "logo" }) })
658
659
  ] });
659
660
  };
660
- var Le = /* @__PURE__ */ ((r) => (r[r.TABLE = 0] = "TABLE", r[r.LIST = 1] = "LIST", r[r.BOARD = 2] = "BOARD", r))(Le || {}), se = /* @__PURE__ */ ((r) => (r[r.ASC = 0] = "ASC", r[r.DESC = 1] = "DESC", r))(se || {}), Ve = /* @__PURE__ */ ((r) => (r[r.NONE = 0] = "NONE", r[r.COLUMN = 1] = "COLUMN", r[r.TYPE = 2] = "TYPE", r[r.VALUE = 3] = "VALUE", r))(Ve || {}), be = /* @__PURE__ */ ((r) => (r[r.INPUT = 0] = "INPUT", r[r.SELECT = 1] = "SELECT", r[r.TwoComponentSelect = 2] = "TwoComponentSelect", r[r.DATEPICKER = 3] = "DATEPICKER", r[r.MULTISELECT = 4] = "MULTISELECT", r))(be || {});
661
+ var Le = /* @__PURE__ */ ((r) => (r[r.TABLE = 0] = "TABLE", r[r.LIST = 1] = "LIST", r[r.BOARD = 2] = "BOARD", r))(Le || {}), se = /* @__PURE__ */ ((r) => (r[r.ASC = 0] = "ASC", r[r.DESC = 1] = "DESC", r))(se || {}), Ae = /* @__PURE__ */ ((r) => (r[r.NONE = 0] = "NONE", r[r.COLUMN = 1] = "COLUMN", r[r.TYPE = 2] = "TYPE", r[r.VALUE = 3] = "VALUE", r))(Ae || {}), be = /* @__PURE__ */ ((r) => (r[r.INPUT = 0] = "INPUT", r[r.SELECT = 1] = "SELECT", r[r.TwoComponentSelect = 2] = "TwoComponentSelect", r[r.DATEPICKER = 3] = "DATEPICKER", r[r.MULTISELECT = 4] = "MULTISELECT", r))(be || {});
661
662
  const ir = (r) => {
662
663
  let e;
663
664
  const t = /* @__PURE__ */ new Set(), n = (c, u) => {
664
665
  const p = typeof c == "function" ? c(e) : c;
665
666
  if (!Object.is(p, e)) {
666
- const f = e;
667
- e = u ?? (typeof p != "object" || p === null) ? p : Object.assign({}, e, p), t.forEach((h) => h(e, f));
667
+ const h = e;
668
+ e = u ?? (typeof p != "object" || p === null) ? p : Object.assign({}, e, p), t.forEach((f) => f(e, h));
668
669
  }
669
670
  }, i = () => e, l = { setState: n, getState: i, getInitialState: () => d, subscribe: (c) => (t.add(c), () => t.delete(c)) }, d = e = r(n, i, l);
670
671
  return l;
@@ -766,7 +767,7 @@ const ir = (r) => {
766
767
  if (!e) throw new Error("GridViewStoreProvider is missing");
767
768
  return _n(e, r);
768
769
  }, Mi = () => {
769
- const r = T((u) => u.hydrateFromStorage), e = T((u) => u.isHydrated), t = T((u) => u.filters), n = T((u) => u.filterItems), i = T((u) => u.sortItems), o = T((u) => u.hideItems), a = T((u) => u.groupByArr), l = T((u) => u.activeTableView), d = T((u) => u.selectedConfig), c = Ue();
770
+ const r = T((u) => u.hydrateFromStorage), e = T((u) => u.isHydrated), t = T((u) => u.filters), n = T((u) => u.filterItems), i = T((u) => u.sortItems), o = T((u) => u.hideItems), a = T((u) => u.groupByArr), l = T((u) => u.activeTableView), d = T((u) => u.selectedConfig), c = _e();
770
771
  K(() => (r(`grid-filters:${c.pathname}`), sessionStorage.clear()), []), K(() => {
771
772
  e && sessionStorage.setItem(
772
773
  `grid-filters:${c.pathname}`,
@@ -1214,27 +1215,27 @@ const _t = m.div`
1214
1215
  }
1215
1216
  );
1216
1217
  }, tn = ({ placement: r, children: e }) => {
1217
- const t = T((h) => h.columns), n = T((h) => h.sortItems), i = T((h) => h.setSortItems), o = n[0], [a, l] = M(""), [d, c] = M(
1218
+ const t = T((f) => f.columns), n = T((f) => f.sortItems), i = T((f) => f.setSortItems), o = n[0], [a, l] = M(""), [d, c] = M(
1218
1219
  (o == null ? void 0 : o.direction) === se.ASC ? se.ASC : se.DESC
1219
1220
  ), u = t.filter(
1220
- (h) => h.title.toLowerCase().includes(a.toLowerCase()) && h.sortable !== !1
1221
+ (f) => f.title.toLowerCase().includes(a.toLowerCase()) && f.sortable !== !1
1221
1222
  );
1222
- function p(h, g) {
1223
+ function p(f, g) {
1223
1224
  i([
1224
1225
  {
1225
- title: h.title,
1226
- dataIndex: h.dataIndex.charAt(0).toUpperCase() + h.dataIndex.slice(1),
1226
+ title: f.title,
1227
+ dataIndex: f.dataIndex.charAt(0).toUpperCase() + f.dataIndex.slice(1),
1227
1228
  direction: g
1228
1229
  }
1229
1230
  ]);
1230
1231
  }
1231
- function f() {
1232
+ function h() {
1232
1233
  i([]);
1233
1234
  }
1234
1235
  return /* @__PURE__ */ s(
1235
1236
  Wi,
1236
1237
  {
1237
- overlay: (h) => /* @__PURE__ */ v(_t, { children: [
1238
+ overlay: (f) => /* @__PURE__ */ v(_t, { children: [
1238
1239
  /* @__PURE__ */ s(
1239
1240
  "input",
1240
1241
  {
@@ -1248,7 +1249,7 @@ const _t = m.div`
1248
1249
  "button",
1249
1250
  {
1250
1251
  onClick: () => {
1251
- g.title == (o == null ? void 0 : o.title) ? f() : p(g, d);
1252
+ g.title == (o == null ? void 0 : o.title) ? h() : p(g, d);
1252
1253
  },
1253
1254
  children: [
1254
1255
  g.title,
@@ -1291,13 +1292,13 @@ const _t = m.div`
1291
1292
  }
1292
1293
  );
1293
1294
  }, Wt = ({ placement: r, children: e, onSelect: t, CustomFilters: n }) => {
1294
- const [i, o] = M(!1), [a, l] = M(""), d = T((f) => f.columns), c = T((f) => f.filterItems), u = T((f) => f.setFilterItems);
1295
- function p(f) {
1296
- t ? t(f) : u([
1295
+ const [i, o] = M(!1), [a, l] = M(""), d = T((h) => h.columns), c = T((h) => h.filterItems), u = T((h) => h.setFilterItems);
1296
+ function p(h) {
1297
+ t ? t(h) : u([
1297
1298
  ...c,
1298
1299
  {
1299
- ...f,
1300
- selectType: Ve.VALUE
1300
+ ...h,
1301
+ selectType: Ae.VALUE
1301
1302
  }
1302
1303
  ]), o(!1);
1303
1304
  }
@@ -1314,10 +1315,10 @@ const _t = m.div`
1314
1315
  type: "text",
1315
1316
  placeholder: J("Search") + "...",
1316
1317
  value: a,
1317
- onChange: (f) => l(f.target.value)
1318
+ onChange: (h) => l(h.target.value)
1318
1319
  }
1319
1320
  ),
1320
- /* @__PURE__ */ s("div", { children: d.filter((f) => f.filterable !== !1).filter((f) => !c.some((h) => h.title == f.title)).filter((f) => f.filterable !== !1).filter((f) => f.title.toLowerCase().includes(a)).map((f, h) => /* @__PURE__ */ s("button", { onClick: () => p(f), children: f.title }, h)) }),
1321
+ /* @__PURE__ */ s("div", { children: d.filter((h) => h.filterable !== !1).filter((h) => !c.some((f) => f.title == h.title)).filter((h) => h.filterable !== !1).filter((h) => h.title.toLowerCase().includes(a)).map((h, f) => /* @__PURE__ */ s("button", { onClick: () => p(h), children: h.title }, f)) }),
1321
1322
  n && /* @__PURE__ */ s(
1322
1323
  n,
1323
1324
  {
@@ -1437,7 +1438,7 @@ const _t = m.div`
1437
1438
  "/tags": 13
1438
1439
  /* Tag */
1439
1440
  }, rn = () => {
1440
- const { pathname: r } = Ue(), e = Object.keys(sr).find(
1441
+ const { pathname: r } = _e(), e = Object.keys(sr).find(
1441
1442
  (t) => r === t || r.startsWith(t + "/")
1442
1443
  );
1443
1444
  return e ? sr[e] : void 0;
@@ -1456,7 +1457,7 @@ const Zi = ({
1456
1457
  GridPageTopLeftComponent: l,
1457
1458
  noNeedSidebarResponsiveButton: d
1458
1459
  }) => {
1459
- const c = Pe(), u = T((x) => x.filters), p = T((x) => x.hasCreateBtn), f = T((x) => x.setFilters), h = T((x) => x.setFilterItems), g = T((x) => x.setSortItems), [y, O] = M(() => {
1460
+ const c = Pe(), u = T((x) => x.filters), p = T((x) => x.hasCreateBtn), h = T((x) => x.setFilters), f = T((x) => x.setFilterItems), g = T((x) => x.setSortItems), [y, O] = M(() => {
1460
1461
  var x, C;
1461
1462
  try {
1462
1463
  const I = sessionStorage.getItem(`grid-filters:${window.location.pathname}`);
@@ -1464,7 +1465,7 @@ const Zi = ({
1464
1465
  } catch {
1465
1466
  return !1;
1466
1467
  }
1467
- }), [P, S] = M(!1), { open: E } = $e(), [k, H] = M(!1), { getMyFilters: U } = ze(), Y = rn(), [B, F] = M([]), R = T((x) => x.selectedConfig), b = T((x) => x.setSelectedConfig), N = T((x) => x.configsVersion);
1468
+ }), [P, S] = M(!1), { open: E } = $e(), [k, H] = M(!1), { getMyFilters: U } = Ue(), Y = rn(), [B, F] = M([]), R = T((x) => x.selectedConfig), b = T((x) => x.setSelectedConfig), N = T((x) => x.configsVersion);
1468
1469
  K(() => {
1469
1470
  Y == null || !U || U(String(Y)).then((x) => F(x.data ?? []));
1470
1471
  }, [Y, N, U]);
@@ -1472,10 +1473,10 @@ const Zi = ({
1472
1473
  const C = B.find((V) => V.id === x);
1473
1474
  if (!C) return;
1474
1475
  const { filterItems: I, sortItems: z } = JSON.parse(C.value);
1475
- h(I, !0), g(z), b({ id: C.id, name: C.name });
1476
+ f(I, !0), g(z), b({ id: C.id, name: C.name });
1476
1477
  }
1477
1478
  const D = en((x) => {
1478
- f({
1479
+ h({
1479
1480
  ...u,
1480
1481
  QuickSearch: x.target.value
1481
1482
  });
@@ -2085,7 +2086,7 @@ const Qi = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16
2085
2086
  color: var(--color-text-inverse-primary, #fff) !important;
2086
2087
  background: var(--color-bg-status-error, #fd7f60) !important;
2087
2088
  }
2088
- `, qt = m(_e)`
2089
+ `, qt = m(Be)`
2089
2090
  input[type='number'] {
2090
2091
  &::-webkit-outer-spin-button,
2091
2092
  &::-webkit-inner-spin-button {
@@ -2198,7 +2199,7 @@ const oo = ({
2198
2199
  postMyFilter: i,
2199
2200
  putMyFilter: o
2200
2201
  }) => {
2201
- const [a] = Ae.useForm(), l = $e((c) => c.setOnOk), d = $e((c) => c.close);
2202
+ const [a] = Ne.useForm(), l = $e((c) => c.setOnOk), d = $e((c) => c.close);
2202
2203
  return K(() => {
2203
2204
  t && a.setFieldsValue({ name: t.name });
2204
2205
  }, [t, a]), K(() => {
@@ -2216,9 +2217,9 @@ const oo = ({
2216
2217
  a.setFields(u);
2217
2218
  }
2218
2219
  });
2219
- }, [r, e, t, n, a, l, d]), /* @__PURE__ */ v(Ae, { form: a, children: [
2220
+ }, [r, e, t, n, a, l, d]), /* @__PURE__ */ v(Ne, { form: a, children: [
2220
2221
  /* @__PURE__ */ s(pe, { children: j("ConfigurationName") }),
2221
- /* @__PURE__ */ s(Ae.Item, { name: "name", children: /* @__PURE__ */ s(qt, {}) })
2222
+ /* @__PURE__ */ s(Ne.Item, { name: "name", children: /* @__PURE__ */ s(qt, {}) })
2222
2223
  ] });
2223
2224
  }, ao = (r) => /* @__PURE__ */ $.createElement("svg", { width: 20, height: 20, viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...r }, /* @__PURE__ */ $.createElement("path", { d: "M11.6666 4.65485L10.4881 5.83336L13.8215 9.16669H3.33331V10.8334H13.8215L10.4881 14.1667L11.6666 15.3452L17.0118 10L11.6666 4.65485Z", fill: "currentColor" })), ce = m(ao)`
2224
2225
  cursor: pointer;
@@ -2257,7 +2258,7 @@ const oo = ({
2257
2258
  }
2258
2259
  `, co = ({ item: r }) => {
2259
2260
  var S, E, k, H, U, Y, B, F, R;
2260
- const e = wt(null), t = T((b) => b.filterItems), n = T((b) => b.setFilterItems), [i, o] = M(r.selectType == Ve.VALUE);
2261
+ const e = wt(null), t = T((b) => b.filterItems), n = T((b) => b.setFilterItems), [i, o] = M(r.selectType == Ae.VALUE);
2261
2262
  function a() {
2262
2263
  var b;
2263
2264
  (b = e == null ? void 0 : e.current) == null || b.focus();
@@ -2299,14 +2300,14 @@ const oo = ({
2299
2300
  !0
2300
2301
  );
2301
2302
  };
2302
- function f(b) {
2303
+ function h(b) {
2303
2304
  n(
2304
2305
  t.map(
2305
- (N) => N.title == r.title ? { ...b, selectType: Ve.VALUE } : N
2306
+ (N) => N.title == r.title ? { ...b, selectType: Ae.VALUE } : N
2306
2307
  )
2307
2308
  );
2308
2309
  }
2309
- const h = en((b) => {
2310
+ const f = en((b) => {
2310
2311
  const N = b.target.value;
2311
2312
  n(
2312
2313
  t.map((_) => _.title == r.title ? { ..._, filterValue: N } : _),
@@ -2316,7 +2317,7 @@ const oo = ({
2316
2317
  function g(b) {
2317
2318
  n(
2318
2319
  t.map(
2319
- (N) => N.title == r.title ? { ...N, selectType: Ve.NONE } : N
2320
+ (N) => N.title == r.title ? { ...N, selectType: Ae.NONE } : N
2320
2321
  )
2321
2322
  ), o(b);
2322
2323
  }
@@ -2340,7 +2341,7 @@ const oo = ({
2340
2341
  type: "text",
2341
2342
  placeholder: "Search...",
2342
2343
  className: "filter-item-search",
2343
- onChange: h
2344
+ onChange: f
2344
2345
  }
2345
2346
  ),
2346
2347
  [be.SELECT]: /* @__PURE__ */ s("div", { children: (E = (S = r == null ? void 0 : r.filters) == null ? void 0 : S.options) == null ? void 0 : E.map((b) => /* @__PURE__ */ s("button", { onClick: () => l(b), children: b.name }, b.id)) }),
@@ -2417,7 +2418,7 @@ const oo = ({
2417
2418
  }
2418
2419
  );
2419
2420
  return /* @__PURE__ */ v(It, { children: [
2420
- /* @__PURE__ */ s(Wt, { placement: "bottomLeft", onSelect: f, children: /* @__PURE__ */ v("span", { children: [
2421
+ /* @__PURE__ */ s(Wt, { placement: "bottomLeft", onSelect: h, children: /* @__PURE__ */ v("span", { children: [
2421
2422
  /* @__PURE__ */ s(Qr, {}),
2422
2423
  r.title
2423
2424
  ] }) }),
@@ -2440,7 +2441,7 @@ const oo = ({
2440
2441
  /* @__PURE__ */ s("span", { onClick: y, children: /* @__PURE__ */ s(Yt, {}) })
2441
2442
  ] });
2442
2443
  }, po = () => {
2443
- const r = T((g) => g.filterItems), e = T((g) => g.sortItems), t = T((g) => g.setSelectedConfig), n = T((g) => g.resetStore), i = T((g) => g.selectedConfig), { deleteMyFilter: o } = ze(), a = T((g) => g.bumpConfigsVersion), { open: l, store: d, close: c } = $e(), u = rn();
2444
+ const r = T((g) => g.filterItems), e = T((g) => g.sortItems), t = T((g) => g.setSelectedConfig), n = T((g) => g.resetStore), i = T((g) => g.selectedConfig), { deleteMyFilter: o } = Ue(), a = T((g) => g.bumpConfigsVersion), { open: l, store: d, close: c } = $e(), u = rn();
2444
2445
  async function p() {
2445
2446
  try {
2446
2447
  if (!i || !o) return;
@@ -2449,7 +2450,7 @@ const oo = ({
2449
2450
  console.log(g, "Error happened deleting configuration");
2450
2451
  }
2451
2452
  }
2452
- function f() {
2453
+ function h() {
2453
2454
  d({
2454
2455
  component: so,
2455
2456
  title: i ? "UpdateConfiguration" : "NameYourConfiguration",
@@ -2470,7 +2471,7 @@ const oo = ({
2470
2471
  }
2471
2472
  }), l();
2472
2473
  }
2473
- function h() {
2474
+ function f() {
2474
2475
  const g = JSON.stringify({ filterItems: r, sortItems: e });
2475
2476
  d({
2476
2477
  component: oo,
@@ -2503,8 +2504,8 @@ const oo = ({
2503
2504
  "AddFilter"
2504
2505
  ] }) }) }),
2505
2506
  /* @__PURE__ */ v(Vi, { children: [
2506
- /* @__PURE__ */ s("button", { onClick: h, children: i ? "UpdateConfiguration" : "SaveConfiguration" }),
2507
- i && /* @__PURE__ */ s("button", { onClick: f, children: "DeleteConfiguration" }),
2507
+ /* @__PURE__ */ s("button", { onClick: f, children: i ? "UpdateConfiguration" : "SaveConfiguration" }),
2508
+ i && /* @__PURE__ */ s("button", { onClick: h, children: "DeleteConfiguration" }),
2508
2509
  /* @__PURE__ */ v("button", { onClick: n, children: [
2509
2510
  /* @__PURE__ */ s(nn, {}),
2510
2511
  "ResetConditions"
@@ -3019,33 +3020,33 @@ function Co({
3019
3020
  }
3020
3021
  const So = (r) => /* @__PURE__ */ $.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...r }, /* @__PURE__ */ $.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M13.6094 3.33333L5.1263 11.8158C5.12139 11.8211 5.11638 11.8263 5.11133 11.8314L3.33333 13.6094L2.39062 12.6667L3.66211 11.3939C2.75363 10.5112 1.95159 9.31206 1.41341 8.31706L1.24219 8L1.41341 7.68294C2.08047 6.44895 3.05011 5.21371 4.17253 4.2793C5.28611 3.35227 6.61809 2.66667 8 2.66667C9.16616 2.66667 10.294 3.10021 11.291 3.76562L12.6667 2.39062L13.6094 3.33333ZM8 4C7.05196 4 6.01458 4.48114 5.02604 5.30404C4.14063 6.04112 3.34853 7.00907 2.76562 8C3.26512 8.86691 3.9209 9.79039 4.60482 10.4512L5.63021 9.42643C4.98911 8.36284 5.12669 6.96121 6.04427 6.04362C6.96186 5.12604 8.36349 4.98846 9.42708 5.62956L10.3255 4.73047C9.55755 4.26174 8.76273 4 8 4ZM8.42513 6.63151C7.93343 6.47928 7.37623 6.59708 6.98698 6.98633C6.59773 7.37558 6.47993 7.93278 6.63216 8.42448L8.42513 6.63151Z", fill: "currentColor", fillOpacity: 0.75 }), /* @__PURE__ */ $.createElement("path", { d: "M13.2266 5.51432L13.4199 5.75651C13.8705 6.35556 14.306 7.16405 14.5866 7.68294L14.7578 8L14.5866 8.31706C13.9196 9.55061 12.9498 10.7856 11.8275 11.7201C10.714 12.6471 9.38194 13.3333 8 13.3333C7.42626 13.3333 6.86164 13.2272 6.32031 13.0423L6.08984 12.9583L5.5332 12.7422L6.5638 11.7116L6.57161 11.7148L6.75195 11.7806C7.17263 11.9243 7.59142 12 8 12C8.94792 12 9.98545 11.5189 10.974 10.696C11.8609 9.95749 12.6538 8.98668 13.237 7.99414C12.9701 7.50763 12.6616 6.96796 12.3665 6.57357L12.2122 6.38021L12.0664 6.20898L13.0124 5.26302L13.2266 5.51432Z", fill: "currentColor", fillOpacity: 0.75 }));
3021
3022
  function ko({ col: r }) {
3022
- const [e, t] = M(!1), n = T((h) => h.filterItems), i = T((h) => h.hideItems), o = T((h) => h.setFilterItems), a = T((h) => h.setSortItems), l = T((h) => h.setHideItems);
3023
- function d(h, g) {
3023
+ const [e, t] = M(!1), n = T((f) => f.filterItems), i = T((f) => f.hideItems), o = T((f) => f.setFilterItems), a = T((f) => f.setSortItems), l = T((f) => f.setHideItems);
3024
+ function d(f, g) {
3024
3025
  a([
3025
3026
  {
3026
- title: h.title,
3027
- dataIndex: h.dataIndex.charAt(0).toUpperCase() + h.dataIndex.slice(1),
3027
+ title: f.title,
3028
+ dataIndex: f.dataIndex.charAt(0).toUpperCase() + f.dataIndex.slice(1),
3028
3029
  direction: g
3029
3030
  }
3030
3031
  ]);
3031
3032
  }
3032
- function c(h) {
3033
- const g = n.filter((y) => h.title != y.title);
3033
+ function c(f) {
3034
+ const g = n.filter((y) => f.title != y.title);
3034
3035
  o([
3035
3036
  ...g,
3036
3037
  {
3037
- ...h,
3038
- selectType: Ve.VALUE
3038
+ ...f,
3039
+ selectType: Ae.VALUE
3039
3040
  }
3040
3041
  ]);
3041
3042
  }
3042
- function u(h, g) {
3043
+ function u(f, g) {
3043
3044
  l({
3044
3045
  ...i,
3045
- [h.dataIndex]: !0
3046
+ [f.dataIndex]: !0
3046
3047
  });
3047
3048
  }
3048
- const p = () => t(!1), f = [
3049
+ const p = () => t(!1), h = [
3049
3050
  { icon: /* @__PURE__ */ s(gt, {}), text: j("Filter"), action: () => c(r) },
3050
3051
  {
3051
3052
  icon: /* @__PURE__ */ s(Ut, {}),
@@ -3067,14 +3068,14 @@ function ko({ col: r }) {
3067
3068
  Me,
3068
3069
  {
3069
3070
  placement: "bottomLeft",
3070
- popupRender: () => /* @__PURE__ */ s(fo, { children: f.map(({ icon: h, text: g, action: y }) => /* @__PURE__ */ v(
3071
+ popupRender: () => /* @__PURE__ */ s(fo, { children: h.map(({ icon: f, text: g, action: y }) => /* @__PURE__ */ v(
3071
3072
  "button",
3072
3073
  {
3073
3074
  onClick: () => {
3074
3075
  y(), p();
3075
3076
  },
3076
3077
  children: [
3077
- h,
3078
+ f,
3078
3079
  g
3079
3080
  ]
3080
3081
  },
@@ -3083,7 +3084,7 @@ function ko({ col: r }) {
3083
3084
  trigger: ["click"],
3084
3085
  open: e,
3085
3086
  onOpenChange: t,
3086
- getPopupContainer: (h) => (h == null ? void 0 : h.parentElement) ?? document.body,
3087
+ getPopupContainer: (f) => (f == null ? void 0 : f.parentElement) ?? document.body,
3087
3088
  children: /* @__PURE__ */ s("th", { className: e ? "active" : "", children: /* @__PURE__ */ s("span", { children: r.title }) })
3088
3089
  }
3089
3090
  );
@@ -3184,7 +3185,7 @@ const $o = ({ title: r, description: e, button: t, helpSpan: n }) => /* @__PURE_
3184
3185
  noPagination: d,
3185
3186
  noDataProps: c
3186
3187
  }) => {
3187
- const u = T((E) => E.filters), p = T((E) => E.groupByArr), f = T((E) => E.setFilters), h = we(() => p.length > 0 ? e.filter(
3188
+ const u = T((E) => E.filters), p = T((E) => E.groupByArr), h = T((E) => E.setFilters), f = we(() => p.length > 0 ? e.filter(
3188
3189
  (E) => !p.some((k) => k.dataIndex == E.dataIndex)
3189
3190
  ) : e, [e, p]), { isTableGroupped: g, isTableSubGroupped: y } = we(
3190
3191
  () => ({
@@ -3206,14 +3207,14 @@ const $o = ({ title: r, description: e, button: t, helpSpan: n }) => /* @__PURE_
3206
3207
  return n;
3207
3208
  }, [n, p]);
3208
3209
  function P(E) {
3209
- f({
3210
+ h({
3210
3211
  ...u,
3211
3212
  PageSize: E,
3212
3213
  Page: 1
3213
3214
  });
3214
3215
  }
3215
3216
  function S(E) {
3216
- f({
3217
+ h({
3217
3218
  ...u,
3218
3219
  Page: E
3219
3220
  });
@@ -3221,20 +3222,20 @@ const $o = ({ title: r, description: e, button: t, helpSpan: n }) => /* @__PURE_
3221
3222
  return /* @__PURE__ */ v(uo, { children: [
3222
3223
  /* @__PURE__ */ v("table", { children: [
3223
3224
  r != Le.LIST && /* @__PURE__ */ s("thead", { children: /* @__PURE__ */ v("tr", { children: [
3224
- h.map((E) => /* @__PURE__ */ s(ko, { col: E }, E.dataIndex)),
3225
+ f.map((E) => /* @__PURE__ */ s(ko, { col: E }, E.dataIndex)),
3225
3226
  /* @__PURE__ */ s("th", {})
3226
3227
  ] }) }),
3227
3228
  /* @__PURE__ */ s("tbody", { children: i ? /* @__PURE__ */ s(
3228
3229
  yo,
3229
3230
  {
3230
3231
  rowLength: o.pageSize,
3231
- columnLength: h.length
3232
+ columnLength: f.length
3232
3233
  }
3233
- ) : (O == null ? void 0 : O.length) == 0 && c ? /* @__PURE__ */ s("tr", { children: /* @__PURE__ */ s("td", { colSpan: h.length, children: /* @__PURE__ */ s($o, { ...c }) }) }) : /* @__PURE__ */ s(oe, { children: g ? /* @__PURE__ */ s(
3234
+ ) : (O == null ? void 0 : O.length) == 0 && c ? /* @__PURE__ */ s("tr", { children: /* @__PURE__ */ s("td", { colSpan: f.length, children: /* @__PURE__ */ s($o, { ...c }) }) }) : /* @__PURE__ */ s(oe, { children: g ? /* @__PURE__ */ s(
3234
3235
  wo,
3235
3236
  {
3236
3237
  dataSource: O,
3237
- columns: h,
3238
+ columns: f,
3238
3239
  isSubGroupped: y,
3239
3240
  getGroupLength: mo,
3240
3241
  rowKey: t,
@@ -3244,7 +3245,7 @@ const $o = ({ title: r, description: e, button: t, helpSpan: n }) => /* @__PURE_
3244
3245
  Zt,
3245
3246
  {
3246
3247
  rows: O,
3247
- columns: h,
3248
+ columns: f,
3248
3249
  rowKey: t,
3249
3250
  onRowClick: l
3250
3251
  }
@@ -3646,10 +3647,10 @@ function jo(r) {
3646
3647
  }
3647
3648
  return e;
3648
3649
  }
3649
- function je(r) {
3650
+ function Fe(r) {
3650
3651
  return Object.entries(r).map(([e, t]) => ({ name: e.replace(/\[(\d+)\]/g, ".$1").split(".").map((i) => isNaN(i) ? jo(i) : Number(i)), errors: t }));
3651
3652
  }
3652
- m(Ae.Item)`
3653
+ m(Ne.Item)`
3653
3654
  margin-bottom: 2.5rem;
3654
3655
  padding: 0 1.5rem;
3655
3656
  display: flex;
@@ -3910,7 +3911,7 @@ const an = m.span`
3910
3911
  color: var(--color-text-inverse-primary, #131412) !important;
3911
3912
  }
3912
3913
  }
3913
- `, Wo = m(_e.Password)`
3914
+ `, Wo = m(Be.Password)`
3914
3915
  input[type='number'] {
3915
3916
  &::-webkit-outer-spin-button,
3916
3917
  &::-webkit-inner-spin-button {
@@ -4023,12 +4024,12 @@ const an = m.span`
4023
4024
  }) => {
4024
4025
  const [a, l] = M(), [d, c] = M([]);
4025
4026
  async function u() {
4026
- var p, f, h;
4027
+ var p, h, f;
4027
4028
  try {
4028
4029
  const g = await e({ confirmationToken: r, code: a, id: i });
4029
4030
  (p = g == null ? void 0 : g.data) != null && p.success && (n(!1), o((y) => !y));
4030
4031
  } catch (g) {
4031
- const y = je((h = (f = g == null ? void 0 : g.response) == null ? void 0 : f.data) == null ? void 0 : h.errors);
4032
+ const y = Fe((f = (h = g == null ? void 0 : g.response) == null ? void 0 : h.data) == null ? void 0 : f.errors);
4032
4033
  c(y), console.log(g);
4033
4034
  }
4034
4035
  }
@@ -4118,7 +4119,7 @@ const Zo = {
4118
4119
  isBlocked: o,
4119
4120
  onBlockStateClose: a
4120
4121
  }) => {
4121
- const { confirmContactInfo: l, confirmContactInfoBackup: d } = ze(), { setUser: c } = He(), [u, p] = M(""), [f, h] = M([]), [g, y] = M(!1);
4122
+ const { confirmContactInfo: l, confirmContactInfoBackup: d } = Ue(), { setUser: c } = ze(), [u, p] = M(""), [h, f] = M([]), [g, y] = M(!1);
4122
4123
  function O(k) {
4123
4124
  p(k);
4124
4125
  }
@@ -4126,13 +4127,13 @@ const Zo = {
4126
4127
  const k = l;
4127
4128
  if (k)
4128
4129
  try {
4129
- h([]);
4130
+ f([]);
4130
4131
  const H = await k(t, u, i);
4131
4132
  c(H.data.value), E();
4132
4133
  } catch (H) {
4133
4134
  if (console.log(H), H.status === 400) {
4134
- const U = H.response.data, Y = je(U.errors);
4135
- h(Y);
4135
+ const U = H.response.data, Y = Fe(U.errors);
4136
+ f(Y);
4136
4137
  }
4137
4138
  }
4138
4139
  }
@@ -4140,18 +4141,18 @@ const Zo = {
4140
4141
  const H = d;
4141
4142
  if (H)
4142
4143
  try {
4143
- h([]);
4144
+ f([]);
4144
4145
  const U = await H(k);
4145
4146
  c(U.data.value);
4146
4147
  } catch (U) {
4147
4148
  if (console.log(U), U.status === 400) {
4148
- const Y = U.response.data, B = je(Y.errors);
4149
- h(B);
4149
+ const Y = U.response.data, B = Fe(Y.errors);
4150
+ f(B);
4150
4151
  }
4151
4152
  }
4152
4153
  }
4153
4154
  function E() {
4154
- p(""), e(!1), h([]);
4155
+ p(""), e(!1), f([]);
4155
4156
  }
4156
4157
  return o ? /* @__PURE__ */ s(pr, { isOpen: o, onClose: a, children: /* @__PURE__ */ v(Ro, { children: [
4157
4158
  /* @__PURE__ */ v(No, { children: [
@@ -4181,15 +4182,15 @@ const Zo = {
4181
4182
  /* @__PURE__ */ v(
4182
4183
  zo,
4183
4184
  {
4184
- className: f.length > 0 ? "verification-error" : "",
4185
+ className: h.length > 0 ? "verification-error" : "",
4185
4186
  children: [
4186
- /* @__PURE__ */ s(_e.OTP, { value: u, onChange: O }),
4187
+ /* @__PURE__ */ s(Be.OTP, { value: u, onChange: O }),
4187
4188
  /* @__PURE__ */ v(Ho, { children: [
4188
4189
  G("DidnReceiveCode"),
4189
4190
  " ",
4190
4191
  /* @__PURE__ */ s(an, { onClick: () => y(!0), children: G("EnterBackupCode") })
4191
4192
  ] }),
4192
- f.map((k) => /* @__PURE__ */ v("span", { children: [
4193
+ h.map((k) => /* @__PURE__ */ v("span", { children: [
4193
4194
  /* @__PURE__ */ s(it, {}),
4194
4195
  k.errors[0]
4195
4196
  ] }, k.name))
@@ -4210,14 +4211,14 @@ const Zo = {
4210
4211
  ] })
4211
4212
  ] }) });
4212
4213
  }, Qo = () => {
4213
- const { enableContactInfo: r, disableContactInfo: e } = ze(), { setUser: t } = He(), [n, i] = M(!1), [o, a] = M(null), [l, d] = M(!1), c = async () => {
4214
- var f, h, g, y, O, P, S;
4214
+ const { enableContactInfo: r, disableContactInfo: e } = Ue(), { setUser: t } = ze(), [n, i] = M(!1), [o, a] = M(null), [l, d] = M(!1), c = async () => {
4215
+ var h, f, g, y, O, P, S;
4215
4216
  if (r)
4216
4217
  try {
4217
4218
  d(!1);
4218
4219
  const E = await r();
4219
4220
  a({
4220
- token: (h = (f = E.data) == null ? void 0 : f.value) == null ? void 0 : h.token,
4221
+ token: (f = (h = E.data) == null ? void 0 : h.value) == null ? void 0 : f.token,
4221
4222
  id: (y = (g = E.data) == null ? void 0 : g.value) == null ? void 0 : y.id,
4222
4223
  mfaType: (P = (O = E.data) == null ? void 0 : O.value) == null ? void 0 : P.mfaType
4223
4224
  }), i(!0);
@@ -4228,8 +4229,8 @@ const Zo = {
4228
4229
  };
4229
4230
  async function u() {
4230
4231
  if (!e) return;
4231
- const f = await e();
4232
- t(f.data.value);
4232
+ const h = await e();
4233
+ t(h.data.value);
4233
4234
  }
4234
4235
  const p = () => {
4235
4236
  d(!1), i(!1);
@@ -4254,8 +4255,8 @@ const Zo = {
4254
4255
  };
4255
4256
  }, Xo = ({ close: r }) => {
4256
4257
  var P;
4257
- const { user: e } = He(), t = T((S) => S.columns), n = T((S) => S.groupByArr), i = T((S) => S.hideItems), o = T((S) => S.activeTableView), a = T((S) => S.setActiveTableView), l = T((S) => S.setGroupByArr), d = T((S) => S.setHideItems), c = T((S) => S.resetStore), { handleEnableContactInfo: u, handleDisableContactInfo: p, ContactInfoModalProps: f } = Qo();
4258
- function h(S) {
4258
+ const { user: e } = ze(), t = T((S) => S.columns), n = T((S) => S.groupByArr), i = T((S) => S.hideItems), o = T((S) => S.activeTableView), a = T((S) => S.setActiveTableView), l = T((S) => S.setGroupByArr), d = T((S) => S.setHideItems), c = T((S) => S.resetStore), { handleEnableContactInfo: u, handleDisableContactInfo: p, ContactInfoModalProps: h } = Qo();
4259
+ function f(S) {
4259
4260
  const E = t.find((k) => k.dataIndex == S.value);
4260
4261
  l([E]);
4261
4262
  }
@@ -4319,7 +4320,7 @@ const Zo = {
4319
4320
  j("NoGrouping")
4320
4321
  ] }),
4321
4322
  value: ((P = n[0]) == null ? void 0 : P.dataIndex) || null,
4322
- onChange: h
4323
+ onChange: f
4323
4324
  }
4324
4325
  )
4325
4326
  ] }) }),
@@ -4353,7 +4354,7 @@ const Zo = {
4353
4354
  /* @__PURE__ */ s(nn, {})
4354
4355
  ] })
4355
4356
  ] }),
4356
- /* @__PURE__ */ s(Jo, { ...f })
4357
+ /* @__PURE__ */ s(Jo, { ...h })
4357
4358
  ] });
4358
4359
  }, ea = ({
4359
4360
  columns: r,
@@ -4368,8 +4369,8 @@ const Zo = {
4368
4369
  pagination: c,
4369
4370
  CustomFilters: u,
4370
4371
  initialFilterValues: p,
4371
- tableAdditionalFields: f,
4372
- createIsModal: h,
4372
+ tableAdditionalFields: h,
4373
+ createIsModal: f,
4373
4374
  editButton: g,
4374
4375
  noPagination: y,
4375
4376
  noDataProps: O,
@@ -4383,7 +4384,7 @@ const Zo = {
4383
4384
  }
4384
4385
  }) => {
4385
4386
  var X, me, fe;
4386
- const { user: B } = He(), F = T((Z) => Z.filters), R = T((Z) => Z.filterItems), b = T((Z) => Z.sortItems), N = T((Z) => Z.hideItems), _ = T((Z) => Z.activeTableView), D = T((Z) => Z.setColumns), L = T((Z) => Z.setHasCreateBtn), w = T((Z) => Z.setHasSelect), x = T((Z) => Z.setCheckedValue), { response: C, loading: I } = Yr(
4387
+ const { user: B } = ze(), F = T((Z) => Z.filters), R = T((Z) => Z.filterItems), b = T((Z) => Z.sortItems), N = T((Z) => Z.hideItems), _ = T((Z) => Z.activeTableView), D = T((Z) => Z.setColumns), L = T((Z) => Z.setHasCreateBtn), w = T((Z) => Z.setHasSelect), x = T((Z) => Z.setCheckedValue), { response: C, loading: I } = Yr(
4387
4388
  () => e({ ...F, ...p }),
4388
4389
  [F, B, t]
4389
4390
  );
@@ -4408,8 +4409,8 @@ const Zo = {
4408
4409
  exportButton: P,
4409
4410
  setisSettingPopupVisible: V,
4410
4411
  CustomFilters: u,
4411
- tableAdditionalFields: f,
4412
- createIsModal: h,
4412
+ tableAdditionalFields: h,
4413
+ createIsModal: f,
4413
4414
  GridPageTopLeftComponent: i
4414
4415
  }
4415
4416
  ),
@@ -4441,7 +4442,7 @@ const Zo = {
4441
4442
  {
4442
4443
  noPagination: y,
4443
4444
  editButton: g,
4444
- createIsModal: h,
4445
+ createIsModal: f,
4445
4446
  rowKey: d || "id",
4446
4447
  columns: [
4447
4448
  {
@@ -4466,7 +4467,7 @@ const Zo = {
4466
4467
  z && /* @__PURE__ */ s(Xo, { close: () => V(!1) })
4467
4468
  ] });
4468
4469
  }, Tl = (r) => /* @__PURE__ */ s(Ii, { children: /* @__PURE__ */ s(ea, { ...r }) }), $l = () => {
4469
- const r = $e((y) => y.isOpen), e = $e((y) => y.options), t = $e((y) => y.close), n = Ue();
4470
+ const r = $e((y) => y.isOpen), e = $e((y) => y.options), t = $e((y) => y.close), n = _e();
4470
4471
  if (K(() => {
4471
4472
  r && t();
4472
4473
  }, [n.pathname]), !e || !r) return null;
@@ -4479,9 +4480,9 @@ const Zo = {
4479
4480
  hideFooter: c,
4480
4481
  showCloseButton: u,
4481
4482
  onOk: p,
4482
- onCancel: f
4483
- } = e, h = () => {
4484
- f == null || f();
4483
+ onCancel: h
4484
+ } = e, f = () => {
4485
+ h == null || h();
4485
4486
  }, g = () => {
4486
4487
  p == null || p();
4487
4488
  };
@@ -4497,7 +4498,7 @@ const Zo = {
4497
4498
  children: [
4498
4499
  o && /* @__PURE__ */ s(o, { ...a }),
4499
4500
  !c && /* @__PURE__ */ v(et, { children: [
4500
- /* @__PURE__ */ s(re, { onClick: h, children: d == null ? void 0 : d.cancelText }),
4501
+ /* @__PURE__ */ s(re, { onClick: f, children: d == null ? void 0 : d.cancelText }),
4501
4502
  /* @__PURE__ */ s(
4502
4503
  to,
4503
4504
  {
@@ -4545,10 +4546,10 @@ const Zo = {
4545
4546
  const l = n;
4546
4547
  if (l)
4547
4548
  try {
4548
- const f = await l();
4549
- (c = (d = f.data) == null ? void 0 : d.value) != null && c.isTwoFactorRequired ? (t(f.data.value.token), o(f.data.value.id), e(Be.VERIFY_EMAIL_CODE)) : ((u = f == null ? void 0 : f.data) != null && u.success && !((p = f == null ? void 0 : f.data) != null && p.value) && i((h) => !h), r());
4550
- } catch (f) {
4551
- console.error("Failed to toggle 2FA:", f);
4549
+ const h = await l();
4550
+ (c = (d = h.data) == null ? void 0 : d.value) != null && c.isTwoFactorRequired ? (t(h.data.value.token), o(h.data.value.id), e(je.VERIFY_EMAIL_CODE)) : ((u = h == null ? void 0 : h.data) != null && u.success && !((p = h == null ? void 0 : h.data) != null && p.value) && i((f) => !f), r());
4551
+ } catch (h) {
4552
+ console.error("Failed to toggle 2FA:", h);
4552
4553
  }
4553
4554
  }
4554
4555
  return /* @__PURE__ */ v("div", { children: [
@@ -4560,28 +4561,34 @@ const Zo = {
4560
4561
  /* @__PURE__ */ s("span", { children: j("Email") }),
4561
4562
  /* @__PURE__ */ s(ce, {})
4562
4563
  ] }) }) }),
4563
- /* @__PURE__ */ s(ue, { onClick: () => e(Be.SELECT_AUTHENTICATOR_APP), children: /* @__PURE__ */ s(et, { children: /* @__PURE__ */ v(re, { children: [
4564
+ /* @__PURE__ */ s(ue, { onClick: () => e(je.SELECT_AUTHENTICATOR_APP), children: /* @__PURE__ */ s(et, { children: /* @__PURE__ */ v(re, { children: [
4564
4565
  /* @__PURE__ */ s("span", { children: G("AuthenticatorApp") }),
4565
4566
  /* @__PURE__ */ s(ce, {})
4566
4567
  ] }) }) }),
4567
4568
  /* @__PURE__ */ s(ue, { children: /* @__PURE__ */ s(re, { onClick: r, children: J("Cancel") }) })
4568
4569
  ] });
4569
- }, ra = ({ onClose: r, setCurrentStep: e, setBackupCodes: t, setRefetch: n }) => {
4570
- const { verifyMFA: i } = ze(), [o, a] = M(""), [l, d] = M([]);
4570
+ }, ra = ({
4571
+ onClose: r,
4572
+ setCurrentStep: e,
4573
+ setBackupCodes: t,
4574
+ setRefetch: n,
4575
+ confirmTwoFactorService: i
4576
+ }) => {
4577
+ const [o, a] = M(""), [l, d] = M([]);
4571
4578
  function c(p) {
4572
4579
  a(p);
4573
4580
  }
4574
4581
  async function u() {
4575
- var f;
4582
+ var h;
4576
4583
  const p = i;
4577
4584
  if (p)
4578
4585
  try {
4579
- const h = await p(o);
4580
- (f = h.data) != null && f.success && (e(Be.BACKUP_CODES), t(h.data.value.recoveryCodes));
4581
- } catch (h) {
4582
- console.log(h);
4586
+ const f = await p(o);
4587
+ (h = f.data) != null && h.success && (e(je.BACKUP_CODES), t(f.data.value.recoveryCodes));
4588
+ } catch (f) {
4589
+ console.log(f);
4583
4590
  } finally {
4584
- n((h) => h + 1);
4591
+ n((f) => f + 1);
4585
4592
  }
4586
4593
  }
4587
4594
  return /* @__PURE__ */ v("div", { children: [
@@ -4590,7 +4597,7 @@ const Zo = {
4590
4597
  /* @__PURE__ */ s(pe, { children: G("YouMaySeeVerificationCode") })
4591
4598
  ] }),
4592
4599
  /* @__PURE__ */ v(ln, { children: [
4593
- /* @__PURE__ */ s(_e.OTP, { value: o, onChange: c }),
4600
+ /* @__PURE__ */ s(Be.OTP, { value: o, onChange: c }),
4594
4601
  l.map((p) => /* @__PURE__ */ v("span", { children: [
4595
4602
  /* @__PURE__ */ s(it, {}),
4596
4603
  p.errors[0]
@@ -4621,7 +4628,7 @@ const Zo = {
4621
4628
  t.map((n) => /* @__PURE__ */ s(
4622
4629
  ue,
4623
4630
  {
4624
- onClick: () => e(Be.CONNECT_AUTHENTICATOR),
4631
+ onClick: () => e(je.CONNECT_AUTHENTICATOR),
4625
4632
  children: /* @__PURE__ */ s(et, { children: /* @__PURE__ */ v(re, { children: [
4626
4633
  /* @__PURE__ */ s("span", { children: n }),
4627
4634
  /* @__PURE__ */ s(ce, {})
@@ -4815,7 +4822,7 @@ function Ye(r, e) {
4815
4822
  const t = e || 255;
4816
4823
  return r > t ? t : r < 0 ? 0 : r;
4817
4824
  }
4818
- class Ne {
4825
+ class Re {
4819
4826
  constructor(e) {
4820
4827
  ie(this, "isValid", !0), ie(this, "r", 0), ie(this, "g", 0), ie(this, "b", 0), ie(this, "a", 1), ie(this, "_h", void 0), ie(this, "_s", void 0), ie(this, "_l", void 0), ie(this, "_v", void 0), ie(this, "_max", void 0), ie(this, "_min", void 0), ie(this, "_brightness", void 0);
4821
4828
  function t(n) {
@@ -4827,7 +4834,7 @@ class Ne {
4827
4834
  };
4828
4835
  const n = e.trim();
4829
4836
  /^#?[A-F\d]{3,8}$/i.test(n) ? this.fromHexString(n) : i("rgb") ? this.fromRgbString(n) : i("hsl") ? this.fromHslString(n) : (i("hsv") || i("hsb")) && this.fromHsvString(n);
4830
- } else if (e instanceof Ne)
4837
+ } else if (e instanceof Re)
4831
4838
  this.r = e.r, this.g = e.g, this.b = e.b, this.a = e.a, this._h = e._h, this._s = e._s, this._l = e._l, this._v = e._v;
4832
4839
  else if (t("rgb"))
4833
4840
  this.r = Ye(e.r), this.g = Ye(e.g), this.b = Ye(e.b), this.a = typeof e.a == "number" ? Ye(e.a, 1) : 1;
@@ -5057,8 +5064,8 @@ class Ne {
5057
5064
  a: i
5058
5065
  }) {
5059
5066
  if (this._h = e % 360, this._s = t, this._l = n, this.a = typeof i == "number" ? i : 1, t <= 0) {
5060
- const f = ee(n * 255);
5061
- this.r = f, this.g = f, this.b = f;
5067
+ const h = ee(n * 255);
5068
+ this.r = h, this.g = h, this.b = h;
5062
5069
  }
5063
5070
  let o = 0, a = 0, l = 0;
5064
5071
  const d = e / 60, c = (1 - Math.abs(2 * n - 1)) * t, u = c * (1 - Math.abs(d % 2 - 1));
@@ -5171,8 +5178,8 @@ function br(r, e, t) {
5171
5178
  return t ? n = r.v + xa * e : n = r.v - wa * e, n = Math.max(0, Math.min(1, n)), Math.round(n * 100) / 100;
5172
5179
  }
5173
5180
  function Sa(r) {
5174
- for (var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = [], n = new Ne(r), i = n.toHsv(), o = hn; o > 0; o -= 1) {
5175
- var a = new Ne({
5181
+ for (var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = [], n = new Re(r), i = n.toHsv(), o = hn; o > 0; o -= 1) {
5182
+ var a = new Re({
5176
5183
  h: vr(i, o, !0),
5177
5184
  s: yr(i, o, !0),
5178
5185
  v: br(i, o, !0)
@@ -5181,7 +5188,7 @@ function Sa(r) {
5181
5188
  }
5182
5189
  t.push(n);
5183
5190
  for (var l = 1; l <= gn; l += 1) {
5184
- var d = new Ne({
5191
+ var d = new Re({
5185
5192
  h: vr(i, l),
5186
5193
  s: yr(i, l),
5187
5194
  v: br(i, l)
@@ -5190,7 +5197,7 @@ function Sa(r) {
5190
5197
  }
5191
5198
  return e.theme === "dark" ? Ca.map(function(c) {
5192
5199
  var u = c.index, p = c.amount;
5193
- return new Ne(e.backgroundColor || "#141414").mix(t[u], p).toHexString();
5200
+ return new Re(e.backgroundColor || "#141414").mix(t[u], p).toHexString();
5194
5201
  }) : t.map(function(c) {
5195
5202
  return c.toHexString();
5196
5203
  });
@@ -5261,11 +5268,11 @@ function vn(r) {
5261
5268
  var c = Qt(e), u = c.firstChild;
5262
5269
  if (n) {
5263
5270
  if (l) {
5264
- var p = (e.styles || Xt(c)).filter(function(f) {
5265
- if (!["prepend", "prependQueue"].includes(f.getAttribute(wr)))
5271
+ var p = (e.styles || Xt(c)).filter(function(h) {
5272
+ if (!["prepend", "prependQueue"].includes(h.getAttribute(wr)))
5266
5273
  return !1;
5267
- var h = Number(f.getAttribute(Cr) || 0);
5268
- return o >= h;
5274
+ var f = Number(h.getAttribute(Cr) || 0);
5275
+ return o >= f;
5269
5276
  });
5270
5277
  if (p.length)
5271
5278
  return c.insertBefore(d, p[p.length - 1].nextSibling), d;
@@ -5510,7 +5517,7 @@ function Ga() {
5510
5517
  var Wa = ["className", "icon", "spin", "rotate", "tabIndex", "onClick", "twoToneColor"];
5511
5518
  Cn(Mt.primary);
5512
5519
  var ot = /* @__PURE__ */ $.forwardRef(function(r, e) {
5513
- var t = r.className, n = r.icon, i = r.spin, o = r.rotate, a = r.tabIndex, l = r.onClick, d = r.twoToneColor, c = un(r, Wa), u = $.useContext(dn), p = u.prefixCls, f = p === void 0 ? "anticon" : p, h = u.rootClassName, g = ya(h, f, ie(ie({}, "".concat(f, "-").concat(n.name), !!n.name), "".concat(f, "-spin"), !!i || n.name === "loading"), t), y = a;
5520
+ var t = r.className, n = r.icon, i = r.spin, o = r.rotate, a = r.tabIndex, l = r.onClick, d = r.twoToneColor, c = un(r, Wa), u = $.useContext(dn), p = u.prefixCls, h = p === void 0 ? "anticon" : p, f = u.rootClassName, g = ya(f, h, ie(ie({}, "".concat(h, "-").concat(n.name), !!n.name), "".concat(h, "-spin"), !!i || n.name === "loading"), t), y = a;
5514
5521
  y === void 0 && l && (y = -1);
5515
5522
  var O = o ? {
5516
5523
  msTransform: "rotate(".concat(o, "deg)"),
@@ -5549,7 +5556,7 @@ var qa = { icon: { tag: "svg", attrs: { viewBox: "64 64 896 896", focusable: "fa
5549
5556
  }, kn = /* @__PURE__ */ $.forwardRef(Za);
5550
5557
  process.env.NODE_ENV !== "production" && (kn.displayName = "DownloadOutlined");
5551
5558
  const Ja = ({ onClose: r, setCurrentStep: e }) => {
5552
- const { initiateMFA: t } = ze(), [n, i] = M(null);
5559
+ const { initiateMFA: t } = Ue(), [n, i] = M(null);
5553
5560
  async function o() {
5554
5561
  if (t)
5555
5562
  try {
@@ -5580,7 +5587,7 @@ const Ja = ({ onClose: r, setCurrentStep: e }) => {
5580
5587
  /* @__PURE__ */ v(
5581
5588
  re,
5582
5589
  {
5583
- onClick: () => e(Be.VERIFY_AUTHENTICATOR_CODE),
5590
+ onClick: () => e(je.VERIFY_AUTHENTICATOR_CODE),
5584
5591
  children: [
5585
5592
  /* @__PURE__ */ s("span", { children: J("Continue") }),
5586
5593
  /* @__PURE__ */ s(ce, {})
@@ -5659,7 +5666,7 @@ const Ja = ({ onClose: r, setCurrentStep: e }) => {
5659
5666
  /* @__PURE__ */ s(pe, { children: G("BackupCodesDesc") })
5660
5667
  ] }),
5661
5668
  /* @__PURE__ */ v(ln, { children: [
5662
- /* @__PURE__ */ s(_e.OTP, { value: o, onChange: c }),
5669
+ /* @__PURE__ */ s(Be.OTP, { value: o, onChange: c }),
5663
5670
  l.map((p) => /* @__PURE__ */ v("span", { children: [
5664
5671
  /* @__PURE__ */ s(it, {}),
5665
5672
  p.errors[0]
@@ -5695,7 +5702,7 @@ const Ja = ({ onClose: r, setCurrentStep: e }) => {
5695
5702
  /* @__PURE__ */ s(ue, { children: /* @__PURE__ */ s(re, { onClick: r, children: J("Cancel") }) })
5696
5703
  ] });
5697
5704
  };
5698
- var Be = /* @__PURE__ */ ((r) => (r[r.SELECT_MFA_OPTION = 0] = "SELECT_MFA_OPTION", r[r.SELECT_AUTHENTICATOR_APP = 1] = "SELECT_AUTHENTICATOR_APP", r[r.CONNECT_AUTHENTICATOR = 2] = "CONNECT_AUTHENTICATOR", r[r.VERIFY_AUTHENTICATOR_CODE = 3] = "VERIFY_AUTHENTICATOR_CODE", r[r.VERIFY_EMAIL_CODE = 4] = "VERIFY_EMAIL_CODE", r[r.DISABLE_AUTHENTICATOR = 5] = "DISABLE_AUTHENTICATOR", r[r.BACKUP_CODES = 6] = "BACKUP_CODES", r[r.ENTER_BACKUP_CODE = 7] = "ENTER_BACKUP_CODE", r))(Be || {});
5705
+ var je = /* @__PURE__ */ ((r) => (r[r.SELECT_MFA_OPTION = 0] = "SELECT_MFA_OPTION", r[r.SELECT_AUTHENTICATOR_APP = 1] = "SELECT_AUTHENTICATOR_APP", r[r.CONNECT_AUTHENTICATOR = 2] = "CONNECT_AUTHENTICATOR", r[r.VERIFY_AUTHENTICATOR_CODE = 3] = "VERIFY_AUTHENTICATOR_CODE", r[r.VERIFY_EMAIL_CODE = 4] = "VERIFY_EMAIL_CODE", r[r.DISABLE_AUTHENTICATOR = 5] = "DISABLE_AUTHENTICATOR", r[r.BACKUP_CODES = 6] = "BACKUP_CODES", r[r.ENTER_BACKUP_CODE = 7] = "ENTER_BACKUP_CODE", r))(je || {});
5699
5706
  const Il = ({
5700
5707
  isOpen: r,
5701
5708
  setIsOpen: e,
@@ -5705,7 +5712,7 @@ const Il = ({
5705
5712
  disableMFAService: o,
5706
5713
  confirmTwoFactorService: a
5707
5714
  }) => {
5708
- const [l, d] = M(t), [c, u] = M(""), [p, f] = M(), [h, g] = M("");
5715
+ const [l, d] = M(t), [c, u] = M(""), [p, h] = M(), [f, g] = M("");
5709
5716
  function y() {
5710
5717
  e(!1);
5711
5718
  }
@@ -5736,7 +5743,7 @@ const Il = ({
5736
5743
  setCurrentStep: d,
5737
5744
  setConfirmationToken: u,
5738
5745
  setRefetch: n,
5739
- setIdOf2FA: f,
5746
+ setIdOf2FA: h,
5740
5747
  enableTwoFactorService: i,
5741
5748
  disableMFAService: o
5742
5749
  };
@@ -5745,7 +5752,13 @@ const Il = ({
5745
5752
  case 2:
5746
5753
  return { onClose: y, setCurrentStep: d };
5747
5754
  case 3:
5748
- return { onClose: y, setCurrentStep: d, setBackupCodes: g, setRefetch: n };
5755
+ return {
5756
+ onClose: y,
5757
+ setCurrentStep: d,
5758
+ setBackupCodes: g,
5759
+ setRefetch: n,
5760
+ confirmTwoFactorService: a
5761
+ };
5749
5762
  case 4:
5750
5763
  return {
5751
5764
  onClose: y,
@@ -5758,13 +5771,13 @@ const Il = ({
5758
5771
  case 5:
5759
5772
  return { onClose: y, setRefetch: n, disableMFAService: o };
5760
5773
  case 6:
5761
- return { onClose: y, backupCodes: h };
5774
+ return { onClose: y, backupCodes: f };
5762
5775
  case 7:
5763
5776
  return { onClose: y, confirmationToken: c, setRefetch: n, idOf2FA: p };
5764
5777
  default:
5765
5778
  return { onClose: y };
5766
5779
  }
5767
- }, [l, c, h]);
5780
+ }, [l, c, f]);
5768
5781
  return /* @__PURE__ */ s(ta, { displayAddRuleModal: r, onClose: y, hideFooter: !0, children: /* @__PURE__ */ s(O, { ...P }) });
5769
5782
  }, ts = m.div`
5770
5783
  height: var(--size-800, 4rem);
@@ -5867,7 +5880,7 @@ const as = {
5867
5880
  setVisible: d,
5868
5881
  visible: c
5869
5882
  }) => {
5870
- const [u, p] = M(""), [f, h] = M(!0), [g, y] = M(60), [O, P] = M([]), [S, E] = M(!1);
5883
+ const [u, p] = M(""), [h, f] = M(!0), [g, y] = M(60), [O, P] = M([]), [S, E] = M(!1);
5871
5884
  async function k() {
5872
5885
  var B, F, R;
5873
5886
  if (u)
@@ -5875,7 +5888,7 @@ const as = {
5875
5888
  const b = await r({ confirmationToken: t, code: u, id: o });
5876
5889
  (B = b == null ? void 0 : b.data) != null && B.success && (d(!1), a && a((N) => !N));
5877
5890
  } catch (b) {
5878
- const N = je((R = (F = b == null ? void 0 : b.response) == null ? void 0 : F.data) == null ? void 0 : R.errors);
5891
+ const N = Fe((R = (F = b == null ? void 0 : b.response) == null ? void 0 : F.data) == null ? void 0 : R.errors);
5879
5892
  P(N), console.log("Error in Save OTP", b);
5880
5893
  }
5881
5894
  }
@@ -5883,7 +5896,7 @@ const as = {
5883
5896
  if (e)
5884
5897
  try {
5885
5898
  const B = await e(t, o);
5886
- B.data.success && (n(B), h(!0), y(60));
5899
+ B.data.success && (n(B), f(!0), y(60));
5887
5900
  } catch (B) {
5888
5901
  console.log("Error in OTP resend", B);
5889
5902
  }
@@ -5895,12 +5908,12 @@ const as = {
5895
5908
  p(B);
5896
5909
  }
5897
5910
  return K(() => {
5898
- if (!f) return;
5911
+ if (!h) return;
5899
5912
  const B = setInterval(() => {
5900
- y((F) => F <= 1 ? (clearInterval(B), h(!1), 0) : F - 1);
5913
+ y((F) => F <= 1 ? (clearInterval(B), f(!1), 0) : F - 1);
5901
5914
  }, 1e3);
5902
5915
  return () => clearInterval(B);
5903
- }, [f]), /* @__PURE__ */ s(Kt, { open: c, onCancel: U, footer: [null], children: t ? /* @__PURE__ */ s(oe, { children: S ? /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(
5916
+ }, [h]), /* @__PURE__ */ s(Kt, { open: c, onCancel: U, footer: [null], children: t ? /* @__PURE__ */ s(oe, { children: S ? /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(
5904
5917
  cn,
5905
5918
  {
5906
5919
  setBackupActivated: E,
@@ -5920,7 +5933,7 @@ const as = {
5920
5933
  {
5921
5934
  className: O.length > 0 ? "verification-error" : "",
5922
5935
  children: [
5923
- /* @__PURE__ */ s(_e.OTP, { value: u, onChange: Y }),
5936
+ /* @__PURE__ */ s(Be.OTP, { value: u, onChange: Y }),
5924
5937
  O.map((B) => /* @__PURE__ */ v("span", { children: [
5925
5938
  /* @__PURE__ */ s(it, {}),
5926
5939
  B.errors[0]
@@ -5937,9 +5950,9 @@ const as = {
5937
5950
  i !== Rt.TOTP && /* @__PURE__ */ s(
5938
5951
  re,
5939
5952
  {
5940
- disabled: f,
5953
+ disabled: h,
5941
5954
  onClick: H,
5942
- children: f ? `${G("ResendAvailable")} ${g} ${j("Second")}` : `${G("Resend")}`
5955
+ children: h ? `${G("ResendAvailable")} ${g} ${j("Second")}` : `${G("Resend")}`
5943
5956
  }
5944
5957
  ),
5945
5958
  /* @__PURE__ */ v(
@@ -6248,11 +6261,11 @@ const ls = m(Ct)`
6248
6261
  loading: d,
6249
6262
  pagination: c
6250
6263
  }) => {
6251
- const [u, p] = M([]), f = t || n;
6264
+ const [u, p] = M([]), h = t || n;
6252
6265
  K(() => {
6253
6266
  a && a.length > 0 && p((g) => [...a, ...g]);
6254
6267
  }, [a]);
6255
- function h(g) {
6268
+ function f(g) {
6256
6269
  p(g), l && l([]);
6257
6270
  }
6258
6271
  return /* @__PURE__ */ s(
@@ -6265,9 +6278,9 @@ const ls = m(Ct)`
6265
6278
  emptyText: /* @__PURE__ */ s(_r, { description: Jn("NoData") })
6266
6279
  },
6267
6280
  loading: d,
6268
- columns: f,
6281
+ columns: h,
6269
6282
  expandedRowKeys: u,
6270
- onExpandedRowsChange: h,
6283
+ onExpandedRowsChange: f,
6271
6284
  expandable: {
6272
6285
  expandedRowRender: (g) => /* @__PURE__ */ s(e, { ...o, record: g }),
6273
6286
  expandIcon: ({ expanded: g }) => /* @__PURE__ */ s(oe, { children: g ? /* @__PURE__ */ s("span", { className: "arrow-svg", children: /* @__PURE__ */ s(vs, {}) }) : /* @__PURE__ */ s("span", { className: "arrow-svg", children: /* @__PURE__ */ s(jt, {}) }) }),
@@ -6670,7 +6683,7 @@ function Ms() {
6670
6683
  return (o = t == null ? void 0 : t.revoke) == null || o.call(t), i === Dn ? r : (r.push(i), t = Proxy.revocable(n, e), t.proxy);
6671
6684
  }, Proxy.revocable(/* @__PURE__ */ Object.create(null), e).proxy;
6672
6685
  }
6673
- function Fe(r, e) {
6686
+ function Ve(r, e) {
6674
6687
  const {
6675
6688
  [Dn]: t
6676
6689
  } = r(Ms()), n = (e == null ? void 0 : e.keySeparator) ?? ".", i = (e == null ? void 0 : e.nsSeparator) ?? ":";
@@ -6729,10 +6742,10 @@ class bt extends kt {
6729
6742
  if (typeof i != "object" && this.options.overloadTranslationOptionHandler && (i = this.options.overloadTranslationOptionHandler(arguments)), typeof i == "object" && (i = {
6730
6743
  ...i
6731
6744
  }), i || (i = {}), e == null) return "";
6732
- typeof e == "function" && (e = Fe(e, {
6745
+ typeof e == "function" && (e = Ve(e, {
6733
6746
  ...this.options,
6734
6747
  ...i
6735
- })), Array.isArray(e) || (e = [String(e)]), e = e.map((_) => typeof _ == "function" ? Fe(_, {
6748
+ })), Array.isArray(e) || (e = [String(e)]), e = e.map((_) => typeof _ == "function" ? Ve(_, {
6736
6749
  ...this.options,
6737
6750
  ...i
6738
6751
  }) : String(_));
@@ -6742,9 +6755,9 @@ class bt extends kt {
6742
6755
  } = this.extractFromKey(e[e.length - 1], i), c = d[d.length - 1];
6743
6756
  let u = i.nsSeparator !== void 0 ? i.nsSeparator : this.options.nsSeparator;
6744
6757
  u === void 0 && (u = ":");
6745
- const p = i.lng || this.language, f = i.appendNamespaceToCIMode || this.options.appendNamespaceToCIMode;
6758
+ const p = i.lng || this.language, h = i.appendNamespaceToCIMode || this.options.appendNamespaceToCIMode;
6746
6759
  if ((p == null ? void 0 : p.toLowerCase()) === "cimode")
6747
- return f ? o ? {
6760
+ return h ? o ? {
6748
6761
  res: `${c}${u}${l}`,
6749
6762
  usedKey: l,
6750
6763
  exactUsedKey: l,
@@ -6759,9 +6772,9 @@ class bt extends kt {
6759
6772
  usedNS: c,
6760
6773
  usedParams: this.getUsedParamsDetails(i)
6761
6774
  } : l;
6762
- const h = this.resolve(e, i);
6763
- let g = h == null ? void 0 : h.res;
6764
- const y = (h == null ? void 0 : h.usedKey) || l, O = (h == null ? void 0 : h.exactUsedKey) || l, P = ["[object Number]", "[object Function]", "[object RegExp]"], S = i.joinArrays !== void 0 ? i.joinArrays : this.options.joinArrays, E = !this.i18nFormat || this.i18nFormat.handleAsObject, k = i.count !== void 0 && !A(i.count), H = bt.hasDefaultValue(i), U = k ? this.pluralResolver.getSuffix(p, i.count, i) : "", Y = i.ordinal && k ? this.pluralResolver.getSuffix(p, i.count, {
6775
+ const f = this.resolve(e, i);
6776
+ let g = f == null ? void 0 : f.res;
6777
+ const y = (f == null ? void 0 : f.usedKey) || l, O = (f == null ? void 0 : f.exactUsedKey) || l, P = ["[object Number]", "[object Function]", "[object RegExp]"], S = i.joinArrays !== void 0 ? i.joinArrays : this.options.joinArrays, E = !this.i18nFormat || this.i18nFormat.handleAsObject, k = i.count !== void 0 && !A(i.count), H = bt.hasDefaultValue(i), U = k ? this.pluralResolver.getSuffix(p, i.count, i) : "", Y = i.ordinal && k ? this.pluralResolver.getSuffix(p, i.count, {
6765
6778
  ordinal: !1
6766
6779
  }) : "", B = k && !i.ordinal && i.count === 0, F = B && i[`defaultValue${this.options.pluralSeparator}zero`] || i[`defaultValue${U}`] || i[`defaultValue${Y}`] || i.defaultValue;
6767
6780
  let R = g;
@@ -6774,7 +6787,7 @@ class bt extends kt {
6774
6787
  ...i,
6775
6788
  ns: d
6776
6789
  }) : `key '${l} (${this.language})' returned an object instead of string.`;
6777
- return o ? (h.res = _, h.usedParams = this.getUsedParamsDetails(i), h) : _;
6790
+ return o ? (f.res = _, f.usedParams = this.getUsedParamsDetails(i), f) : _;
6778
6791
  }
6779
6792
  if (a) {
6780
6793
  const _ = Array.isArray(R), D = _ ? [] : {}, L = _ ? O : y;
@@ -6826,9 +6839,9 @@ class bt extends kt {
6826
6839
  });
6827
6840
  }) : z(C, l, F));
6828
6841
  }
6829
- g = this.extendTranslation(g, e, i, h, n), D && g === l && this.options.appendNamespaceToMissingKey && (g = `${c}${u}${l}`), (D || _) && this.options.parseMissingKeyHandler && (g = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${c}${u}${l}` : l, _ ? g : void 0, i));
6842
+ g = this.extendTranslation(g, e, i, f, n), D && g === l && this.options.appendNamespaceToMissingKey && (g = `${c}${u}${l}`), (D || _) && this.options.parseMissingKeyHandler && (g = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${c}${u}${l}` : l, _ ? g : void 0, i));
6830
6843
  }
6831
- return o ? (h.res = g, h.usedParams = this.getUsedParamsDetails(i), h) : g;
6844
+ return o ? (f.res = g, f.usedParams = this.getUsedParamsDetails(i), f) : g;
6832
6845
  }
6833
6846
  extendTranslation(e, t, n, i, o) {
6834
6847
  var d, c;
@@ -6850,18 +6863,18 @@ class bt extends kt {
6850
6863
  const u = A(e) && (((c = n == null ? void 0 : n.interpolation) == null ? void 0 : c.skipOnVariables) !== void 0 ? n.interpolation.skipOnVariables : this.options.interpolation.skipOnVariables);
6851
6864
  let p;
6852
6865
  if (u) {
6853
- const h = e.match(this.interpolator.nestingRegexp);
6854
- p = h && h.length;
6866
+ const f = e.match(this.interpolator.nestingRegexp);
6867
+ p = f && f.length;
6855
6868
  }
6856
- let f = n.replace && !A(n.replace) ? n.replace : n;
6857
- if (this.options.interpolation.defaultVariables && (f = {
6869
+ let h = n.replace && !A(n.replace) ? n.replace : n;
6870
+ if (this.options.interpolation.defaultVariables && (h = {
6858
6871
  ...this.options.interpolation.defaultVariables,
6859
- ...f
6860
- }), e = this.interpolator.interpolate(e, f, n.lng || this.language || i.usedLng, n), u) {
6861
- const h = e.match(this.interpolator.nestingRegexp), g = h && h.length;
6872
+ ...h
6873
+ }), e = this.interpolator.interpolate(e, h, n.lng || this.language || i.usedLng, n), u) {
6874
+ const f = e.match(this.interpolator.nestingRegexp), g = f && f.length;
6862
6875
  p < g && (n.nest = !1);
6863
6876
  }
6864
- !n.lng && i && i.res && (n.lng = this.language || i.usedLng), n.nest !== !1 && (e = this.interpolator.nest(e, (...h) => (o == null ? void 0 : o[0]) === h[0] && !n.context ? (this.logger.warn(`It seems you are nesting recursively key: ${h[0]} in key: ${t[0]}`), null) : this.translate(...h, t), n)), n.interpolation && this.interpolator.reset();
6877
+ !n.lng && i && i.res && (n.lng = this.language || i.usedLng), n.nest !== !1 && (e = this.interpolator.nest(e, (...f) => (o == null ? void 0 : o[0]) === f[0] && !n.context ? (this.logger.warn(`It seems you are nesting recursively key: ${f[0]} in key: ${t[0]}`), null) : this.translate(...f, t), n)), n.interpolation && this.interpolator.reset();
6865
6878
  }
6866
6879
  const a = n.postProcess || this.options.postProcess, l = A(a) ? [a] : a;
6867
6880
  return e != null && (l != null && l.length) && n.applyPostProcessor !== !1 && (e = On.handle(l, e, t, this.options && this.options.postProcessPassResolved ? {
@@ -6874,7 +6887,7 @@ class bt extends kt {
6874
6887
  }
6875
6888
  resolve(e, t = {}) {
6876
6889
  let n, i, o, a, l;
6877
- return A(e) && (e = [e]), Array.isArray(e) && (e = e.map((d) => typeof d == "function" ? Fe(d, {
6890
+ return A(e) && (e = [e]), Array.isArray(e) && (e = e.map((d) => typeof d == "function" ? Ve(d, {
6878
6891
  ...this.options,
6879
6892
  ...t
6880
6893
  }) : d)), e.forEach((d) => {
@@ -6883,7 +6896,7 @@ class bt extends kt {
6883
6896
  i = u;
6884
6897
  let p = c.namespaces;
6885
6898
  this.options.fallbackNS && (p = p.concat(this.options.fallbackNS));
6886
- const f = t.count !== void 0 && !A(t.count), h = f && !t.ordinal && t.count === 0, g = t.context !== void 0 && (A(t.context) || typeof t.context == "number") && t.context !== "", y = t.lngs ? t.lngs : this.languageUtils.toResolveHierarchy(t.lng || this.language, t.fallbackLng);
6899
+ const h = t.count !== void 0 && !A(t.count), f = h && !t.ordinal && t.count === 0, g = t.context !== void 0 && (A(t.context) || typeof t.context == "number") && t.context !== "", y = t.lngs ? t.lngs : this.languageUtils.toResolveHierarchy(t.lng || this.language, t.fallbackLng);
6887
6900
  p.forEach((O) => {
6888
6901
  var P, S;
6889
6902
  this.isValidLookup(n) || (l = O, !this.checkedLoadedFor[`${y[0]}-${O}`] && ((P = this.utils) != null && P.hasLoadedNamespace) && !((S = this.utils) != null && S.hasLoadedNamespace(l)) && (this.checkedLoadedFor[`${y[0]}-${O}`] = !0, this.logger.warn(`key "${i}" for languages "${y.join(", ")}" won't get resolved as namespace "${l}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), y.forEach((E) => {
@@ -6895,11 +6908,11 @@ class bt extends kt {
6895
6908
  this.i18nFormat.addLookupKeys(k, u, E, O, t);
6896
6909
  else {
6897
6910
  let Y;
6898
- f && (Y = this.pluralResolver.getSuffix(E, t.count, t));
6911
+ h && (Y = this.pluralResolver.getSuffix(E, t.count, t));
6899
6912
  const B = `${this.options.pluralSeparator}zero`, F = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
6900
- if (f && (t.ordinal && Y.startsWith(F) && k.push(u + Y.replace(F, this.options.pluralSeparator)), k.push(u + Y), h && k.push(u + B)), g) {
6913
+ if (h && (t.ordinal && Y.startsWith(F) && k.push(u + Y.replace(F, this.options.pluralSeparator)), k.push(u + Y), f && k.push(u + B)), g) {
6901
6914
  const R = `${u}${this.options.contextSeparator || "_"}${t.context}`;
6902
- k.push(R), f && (t.ordinal && Y.startsWith(F) && k.push(R + Y.replace(F, this.options.pluralSeparator)), k.push(R + Y), h && k.push(R + B));
6915
+ k.push(R), h && (t.ordinal && Y.startsWith(F) && k.push(R + Y.replace(F, this.options.pluralSeparator)), k.push(R + Y), f && k.push(R + B));
6903
6916
  }
6904
6917
  }
6905
6918
  let H;
@@ -7086,15 +7099,15 @@ class Rr {
7086
7099
  formatSeparator: c,
7087
7100
  unescapeSuffix: u,
7088
7101
  unescapePrefix: p,
7089
- nestingPrefix: f,
7090
- nestingPrefixEscaped: h,
7102
+ nestingPrefix: h,
7103
+ nestingPrefixEscaped: f,
7091
7104
  nestingSuffix: g,
7092
7105
  nestingSuffixEscaped: y,
7093
7106
  nestingOptionsSeparator: O,
7094
7107
  maxReplaces: P,
7095
7108
  alwaysFormat: S
7096
7109
  } = e.interpolation;
7097
- this.escape = t !== void 0 ? t : Os, this.escapeValue = n !== void 0 ? n : !0, this.useRawValueToEscape = i !== void 0 ? i : !1, this.prefix = o ? Te(o) : a || "{{", this.suffix = l ? Te(l) : d || "}}", this.formatSeparator = c || ",", this.unescapePrefix = u ? "" : p || "-", this.unescapeSuffix = this.unescapePrefix ? "" : u || "", this.nestingPrefix = f ? Te(f) : h || Te("$t("), this.nestingSuffix = g ? Te(g) : y || Te(")"), this.nestingOptionsSeparator = O || ",", this.maxReplaces = P || 1e3, this.alwaysFormat = S !== void 0 ? S : !1, this.resetRegExp();
7110
+ this.escape = t !== void 0 ? t : Os, this.escapeValue = n !== void 0 ? n : !0, this.useRawValueToEscape = i !== void 0 ? i : !1, this.prefix = o ? Te(o) : a || "{{", this.suffix = l ? Te(l) : d || "}}", this.formatSeparator = c || ",", this.unescapePrefix = u ? "" : p || "-", this.unescapeSuffix = this.unescapePrefix ? "" : u || "", this.nestingPrefix = h ? Te(h) : f || Te("$t("), this.nestingSuffix = g ? Te(g) : y || Te(")"), this.nestingOptionsSeparator = O || ",", this.maxReplaces = P || 1e3, this.alwaysFormat = S !== void 0 ? S : !1, this.resetRegExp();
7098
7111
  }
7099
7112
  reset() {
7100
7113
  this.options && this.init(this.options);
@@ -7104,7 +7117,7 @@ class Rr {
7104
7117
  this.regexp = e(this.regexp, `${this.prefix}(.+?)${this.suffix}`), this.regexpUnescape = e(this.regexpUnescape, `${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`), this.nestingRegexp = e(this.nestingRegexp, `${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`);
7105
7118
  }
7106
7119
  interpolate(e, t, n, i) {
7107
- var h;
7120
+ var f;
7108
7121
  let o, a, l;
7109
7122
  const d = this.options && this.options.interpolation && this.options.interpolation.defaultVariables || {}, c = (g) => {
7110
7123
  if (!g.includes(this.formatSeparator)) {
@@ -7123,7 +7136,7 @@ class Rr {
7123
7136
  });
7124
7137
  };
7125
7138
  this.resetRegExp();
7126
- const u = (i == null ? void 0 : i.missingInterpolationHandler) || this.options.missingInterpolationHandler, p = ((h = i == null ? void 0 : i.interpolation) == null ? void 0 : h.skipOnVariables) !== void 0 ? i.interpolation.skipOnVariables : this.options.interpolation.skipOnVariables;
7139
+ const u = (i == null ? void 0 : i.missingInterpolationHandler) || this.options.missingInterpolationHandler, p = ((f = i == null ? void 0 : i.interpolation) == null ? void 0 : f.skipOnVariables) !== void 0 ? i.interpolation.skipOnVariables : this.options.interpolation.skipOnVariables;
7127
7140
  return [{
7128
7141
  regex: this.regexpUnescape,
7129
7142
  safeValue: (g) => Tt(g)
@@ -7157,17 +7170,17 @@ class Rr {
7157
7170
  const u = this.nestingOptionsSeparator;
7158
7171
  if (!d.includes(u)) return d;
7159
7172
  const p = d.split(new RegExp(`${Te(u)}[ ]*{`));
7160
- let f = `{${p[1]}`;
7161
- d = p[0], f = this.interpolate(f, a);
7162
- const h = f.match(/'/g), g = f.match(/"/g);
7163
- (((h == null ? void 0 : h.length) ?? 0) % 2 === 0 && !g || ((g == null ? void 0 : g.length) ?? 0) % 2 !== 0) && (f = f.replace(/'/g, '"'));
7173
+ let h = `{${p[1]}`;
7174
+ d = p[0], h = this.interpolate(h, a);
7175
+ const f = h.match(/'/g), g = h.match(/"/g);
7176
+ (((f == null ? void 0 : f.length) ?? 0) % 2 === 0 && !g || ((g == null ? void 0 : g.length) ?? 0) % 2 !== 0) && (h = h.replace(/'/g, '"'));
7164
7177
  try {
7165
- a = JSON.parse(f), c && (a = {
7178
+ a = JSON.parse(h), c && (a = {
7166
7179
  ...c,
7167
7180
  ...a
7168
7181
  });
7169
7182
  } catch (y) {
7170
- return this.logger.warn(`failed parsing options string in nesting for key ${d}`, y), `${d}${u}${f}`;
7183
+ return this.logger.warn(`failed parsing options string in nesting for key ${d}`, y), `${d}${u}${h}`;
7171
7184
  }
7172
7185
  return a.defaultValue && a.defaultValue.includes(this.prefix) && delete a.defaultValue, d;
7173
7186
  };
@@ -7280,18 +7293,18 @@ class Rs {
7280
7293
  formatOptions: u
7281
7294
  } = zs(d);
7282
7295
  if (this.formats[c]) {
7283
- let f = l;
7296
+ let h = l;
7284
7297
  try {
7285
- const h = ((p = i == null ? void 0 : i.formatParams) == null ? void 0 : p[i.interpolationkey]) || {}, g = h.locale || h.lng || i.locale || i.lng || n;
7286
- f = this.formats[c](l, g, {
7298
+ const f = ((p = i == null ? void 0 : i.formatParams) == null ? void 0 : p[i.interpolationkey]) || {}, g = f.locale || f.lng || i.locale || i.lng || n;
7299
+ h = this.formats[c](l, g, {
7287
7300
  ...u,
7288
7301
  ...i,
7289
- ...h
7302
+ ...f
7290
7303
  });
7291
- } catch (h) {
7292
- this.logger.warn(h);
7304
+ } catch (f) {
7305
+ this.logger.warn(f);
7293
7306
  }
7294
- return f;
7307
+ return h;
7295
7308
  } else
7296
7309
  this.logger.warn(`there was no format function for ${c}`);
7297
7310
  return l;
@@ -7311,8 +7324,8 @@ class As extends kt {
7311
7324
  return e.forEach((c) => {
7312
7325
  let u = !0;
7313
7326
  t.forEach((p) => {
7314
- const f = `${c}|${p}`;
7315
- !n.reload && this.store.hasResourceBundle(c, p) ? this.state[f] = 2 : this.state[f] < 0 || (this.state[f] === 1 ? a[f] === void 0 && (a[f] = !0) : (this.state[f] = 1, u = !1, a[f] === void 0 && (a[f] = !0), o[f] === void 0 && (o[f] = !0), d[p] === void 0 && (d[p] = !0)));
7327
+ const h = `${c}|${p}`;
7328
+ !n.reload && this.store.hasResourceBundle(c, p) ? this.state[h] = 2 : this.state[h] < 0 || (this.state[h] === 1 ? a[h] === void 0 && (a[h] = !0) : (this.state[h] = 1, u = !1, a[h] === void 0 && (a[h] = !0), o[h] === void 0 && (o[h] = !0), d[p] === void 0 && (d[p] = !0)));
7316
7329
  }), u || (l[c] = !0);
7317
7330
  }), (Object.keys(o).length || Object.keys(a).length) && this.queue.push({
7318
7331
  pending: a,
@@ -7408,26 +7421,26 @@ class As extends kt {
7408
7421
  }
7409
7422
  saveMissing(e, t, n, i, o, a = {}, l = () => {
7410
7423
  }) {
7411
- var d, c, u, p, f;
7424
+ var d, c, u, p, h;
7412
7425
  if ((c = (d = this.services) == null ? void 0 : d.utils) != null && c.hasLoadedNamespace && !((p = (u = this.services) == null ? void 0 : u.utils) != null && p.hasLoadedNamespace(t))) {
7413
7426
  this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");
7414
7427
  return;
7415
7428
  }
7416
7429
  if (!(n == null || n === "")) {
7417
- if ((f = this.backend) != null && f.create) {
7418
- const h = {
7430
+ if ((h = this.backend) != null && h.create) {
7431
+ const f = {
7419
7432
  ...a,
7420
7433
  isUpdate: o
7421
7434
  }, g = this.backend.create.bind(this.backend);
7422
7435
  if (g.length < 6)
7423
7436
  try {
7424
7437
  let y;
7425
- g.length === 5 ? y = g(e, t, n, i, h) : y = g(e, t, n, i), y && typeof y.then == "function" ? y.then((O) => l(null, O)).catch(l) : l(null, y);
7438
+ g.length === 5 ? y = g(e, t, n, i, f) : y = g(e, t, n, i), y && typeof y.then == "function" ? y.then((O) => l(null, O)).catch(l) : l(null, y);
7426
7439
  } catch (y) {
7427
7440
  l(y);
7428
7441
  }
7429
7442
  else
7430
- g(e, t, n, i, l, h);
7443
+ g(e, t, n, i, l, f);
7431
7444
  }
7432
7445
  !e || !e[0] || this.store.addResource(e[0], t, n, i);
7433
7446
  }
@@ -7529,12 +7542,12 @@ class Xe extends kt {
7529
7542
  prepend: this.options.pluralSeparator
7530
7543
  }), c && (p.formatter = i(c), p.formatter.init && p.formatter.init(p, this.options), this.options.interpolation.format = p.formatter.format.bind(p.formatter)), p.interpolator = new Rr(this.options), p.utils = {
7531
7544
  hasLoadedNamespace: this.hasLoadedNamespace.bind(this)
7532
- }, p.backendConnector = new As(i(this.modules.backend), p.resourceStore, p, this.options), p.backendConnector.on("*", (f, ...h) => {
7533
- this.emit(f, ...h);
7534
- }), this.modules.languageDetector && (p.languageDetector = i(this.modules.languageDetector), p.languageDetector.init && p.languageDetector.init(p, this.options.detection, this.options)), this.modules.i18nFormat && (p.i18nFormat = i(this.modules.i18nFormat), p.i18nFormat.init && p.i18nFormat.init(this)), this.translator = new bt(this.services, this.options), this.translator.on("*", (f, ...h) => {
7535
- this.emit(f, ...h);
7536
- }), this.modules.external.forEach((f) => {
7537
- f.init && f.init(this);
7545
+ }, p.backendConnector = new As(i(this.modules.backend), p.resourceStore, p, this.options), p.backendConnector.on("*", (h, ...f) => {
7546
+ this.emit(h, ...f);
7547
+ }), this.modules.languageDetector && (p.languageDetector = i(this.modules.languageDetector), p.languageDetector.init && p.languageDetector.init(p, this.options.detection, this.options)), this.modules.i18nFormat && (p.i18nFormat = i(this.modules.i18nFormat), p.i18nFormat.init && p.i18nFormat.init(this)), this.translator = new bt(this.services, this.options), this.translator.on("*", (h, ...f) => {
7548
+ this.emit(h, ...f);
7549
+ }), this.modules.external.forEach((h) => {
7550
+ h.init && h.init(this);
7538
7551
  });
7539
7552
  }
7540
7553
  if (this.format = this.options.interpolation.format, t || (t = pt), this.options.fallbackLng && !this.services.languageDetector && !this.options.lng) {
@@ -7608,8 +7621,8 @@ class Xe extends kt {
7608
7621
  var u, p;
7609
7622
  !e && !l && this.services.languageDetector && (l = []);
7610
7623
  const d = A(l) ? l : l && l[0], c = this.store.hasLanguageSomeTranslations(d) ? d : this.services.languageUtils.getBestMatchFromCodes(A(l) ? [l] : l);
7611
- c && (this.language || i(c), this.translator.language || this.translator.changeLanguage(c), (p = (u = this.services.languageDetector) == null ? void 0 : u.cacheUserLanguage) == null || p.call(u, c)), this.loadResources(c, (f) => {
7612
- o(f, c);
7624
+ c && (this.language || i(c), this.translator.language || this.translator.changeLanguage(c), (p = (u = this.services.languageDetector) == null ? void 0 : u.cacheUserLanguage) == null || p.call(u, c)), this.loadResources(c, (h) => {
7625
+ o(h, c);
7613
7626
  });
7614
7627
  };
7615
7628
  return !e && this.services.languageDetector && !this.services.languageDetector.async ? a(this.services.languageDetector.detect()) : !e && this.services.languageDetector && this.services.languageDetector.async ? this.services.languageDetector.detect.length === 0 ? this.services.languageDetector.detect().then(a) : this.services.languageDetector.detect(a) : a(e), n;
@@ -7624,10 +7637,10 @@ class Xe extends kt {
7624
7637
  ...this.options,
7625
7638
  ...d
7626
7639
  };
7627
- typeof d.keyPrefix == "function" && (d.keyPrefix = Fe(d.keyPrefix, c));
7640
+ typeof d.keyPrefix == "function" && (d.keyPrefix = Ve(d.keyPrefix, c));
7628
7641
  const u = this.options.keySeparator || ".";
7629
7642
  let p;
7630
- return d.keyPrefix && Array.isArray(o) ? p = o.map((f) => (typeof f == "function" && (f = Fe(f, c)), `${d.keyPrefix}${u}${f}`)) : (typeof o == "function" && (o = Fe(o, c)), p = d.keyPrefix ? `${d.keyPrefix}${u}${o}` : o), this.t(p, d);
7643
+ return d.keyPrefix && Array.isArray(o) ? p = o.map((h) => (typeof h == "function" && (h = Ve(h, c)), `${d.keyPrefix}${u}${h}`)) : (typeof o == "function" && (o = Ve(o, c)), p = d.keyPrefix ? `${d.keyPrefix}${u}${o}` : o), this.t(p, d);
7631
7644
  };
7632
7645
  return A(e) ? i.lng = e : i.lngs = e, i.ns = t, i.keyPrefix = n, i;
7633
7646
  }
@@ -7777,7 +7790,7 @@ function js() {
7777
7790
  (function(t, n) {
7778
7791
  r.exports = n();
7779
7792
  })(Fs, (function() {
7780
- var t = 1e3, n = 6e4, i = 36e5, o = "millisecond", a = "second", l = "minute", d = "hour", c = "day", u = "week", p = "month", f = "quarter", h = "year", g = "date", y = "Invalid Date", O = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, P = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, S = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(D) {
7793
+ var t = 1e3, n = 6e4, i = 36e5, o = "millisecond", a = "second", l = "minute", d = "hour", c = "day", u = "week", p = "month", h = "quarter", f = "year", g = "date", y = "Invalid Date", O = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, P = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, S = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(D) {
7781
7794
  var L = ["th", "st", "nd", "rd"], w = D % 100;
7782
7795
  return "[" + D + (L[(w - 20) % 10] || L[w] || L[0]) + "]";
7783
7796
  } }, E = function(D, L, w) {
@@ -7793,7 +7806,7 @@ function js() {
7793
7806
  }, a: function(D) {
7794
7807
  return D < 0 ? Math.ceil(D) || 0 : Math.floor(D);
7795
7808
  }, p: function(D) {
7796
- return { M: p, y: h, w: u, d: c, D: g, h: d, m: l, s: a, ms: o, Q: f }[D] || String(D || "").toLowerCase().replace(/s$/, "");
7809
+ return { M: p, y: f, w: u, d: c, D: g, h: d, m: l, s: a, ms: o, Q: h }[D] || String(D || "").toLowerCase().replace(/s$/, "");
7797
7810
  }, u: function(D) {
7798
7811
  return D === void 0;
7799
7812
  } }, H = "en", U = {};
@@ -7869,7 +7882,7 @@ function js() {
7869
7882
  return b.w(C.toDate()[ve].apply(C.toDate("s"), (I ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(ae)), C);
7870
7883
  }, q = this.$W, Q = this.$M, X = this.$D, me = "set" + (this.$u ? "UTC" : "");
7871
7884
  switch (z) {
7872
- case h:
7885
+ case f:
7873
7886
  return I ? V(1, 0) : V(31, 11);
7874
7887
  case p:
7875
7888
  return I ? V(1, Q) : V(0, Q + 1);
@@ -7891,8 +7904,8 @@ function js() {
7891
7904
  }, L.endOf = function(w) {
7892
7905
  return this.startOf(w, !1);
7893
7906
  }, L.$set = function(w, x) {
7894
- var C, I = b.p(w), z = "set" + (this.$u ? "UTC" : ""), V = (C = {}, C[c] = z + "Date", C[g] = z + "Date", C[p] = z + "Month", C[h] = z + "FullYear", C[d] = z + "Hours", C[l] = z + "Minutes", C[a] = z + "Seconds", C[o] = z + "Milliseconds", C)[I], W = I === c ? this.$D + (x - this.$W) : x;
7895
- if (I === p || I === h) {
7907
+ var C, I = b.p(w), z = "set" + (this.$u ? "UTC" : ""), V = (C = {}, C[c] = z + "Date", C[g] = z + "Date", C[p] = z + "Month", C[f] = z + "FullYear", C[d] = z + "Hours", C[l] = z + "Minutes", C[a] = z + "Seconds", C[o] = z + "Milliseconds", C)[I], W = I === c ? this.$D + (x - this.$W) : x;
7908
+ if (I === p || I === f) {
7896
7909
  var q = this.clone().set(g, 1);
7897
7910
  q.$d[V](W), q.init(), this.$d = q.set(g, Math.min(this.$D, q.daysInMonth())).$d;
7898
7911
  } else V && this.$d[V](W);
@@ -7909,7 +7922,7 @@ function js() {
7909
7922
  return b.w(X.date(X.date() + Math.round(Q * w)), I);
7910
7923
  };
7911
7924
  if (z === p) return this.set(p, this.$M + w);
7912
- if (z === h) return this.set(h, this.$y + w);
7925
+ if (z === f) return this.set(f, this.$y + w);
7913
7926
  if (z === c) return V(1);
7914
7927
  if (z === u) return V(7);
7915
7928
  var W = (C = {}, C[l] = n, C[d] = i, C[a] = t, C)[z] || 1, q = this.$d.getTime() + w * W;
@@ -7989,13 +8002,13 @@ function js() {
7989
8002
  return b.m(z, W);
7990
8003
  };
7991
8004
  switch (V) {
7992
- case h:
8005
+ case f:
7993
8006
  I = X() / 12;
7994
8007
  break;
7995
8008
  case p:
7996
8009
  I = X();
7997
8010
  break;
7998
- case f:
8011
+ case h:
7999
8012
  I = X() / 3;
8000
8013
  break;
8001
8014
  case u:
@@ -8037,7 +8050,7 @@ function js() {
8037
8050
  return this.$d.toUTCString();
8038
8051
  }, D;
8039
8052
  })(), _ = N.prototype;
8040
- return R.prototype = _, [["$ms", o], ["$s", a], ["$m", l], ["$H", d], ["$W", c], ["$M", p], ["$y", h], ["$D", g]].forEach((function(D) {
8053
+ return R.prototype = _, [["$ms", o], ["$s", a], ["$m", l], ["$H", d], ["$W", c], ["$M", p], ["$y", f], ["$D", g]].forEach((function(D) {
8041
8054
  _[D[1]] = function(L) {
8042
8055
  return this.$g(L, D[0], D[1]);
8043
8056
  };
@@ -8307,16 +8320,16 @@ const En = /* @__PURE__ */ fn(Bs), _s = ({ setDateFilter: r, setShowRange: e, se
8307
8320
  hasAllFilter: e = !1
8308
8321
  }) => {
8309
8322
  const [t, n] = M([]), i = [
8310
- { key: "week", label: Re("7D"), ...le.getCommonDateRange("week") },
8311
- { key: "month", label: Re("30D"), ...le.getCommonDateRange("month") },
8312
- { key: "threeMonth", label: Re("3M"), ...le.getCommonDateRange("threeMonth") },
8313
- { key: "sixMonth", label: Re("6M"), ...le.getCommonDateRange("sixMonth") },
8323
+ { key: "week", label: He("7D"), ...le.getCommonDateRange("week") },
8324
+ { key: "month", label: He("30D"), ...le.getCommonDateRange("month") },
8325
+ { key: "threeMonth", label: He("3M"), ...le.getCommonDateRange("threeMonth") },
8326
+ { key: "sixMonth", label: He("6M"), ...le.getCommonDateRange("sixMonth") },
8314
8327
  {
8315
8328
  key: "twelveMonth",
8316
- label: Re("12M"),
8329
+ label: He("12M"),
8317
8330
  ...le.getCommonDateRange("twelveMonth")
8318
8331
  },
8319
- { key: "year", label: Re("YTD"), ...le.getCommonDateRange("year") },
8332
+ { key: "year", label: He("YTD"), ...le.getCommonDateRange("year") },
8320
8333
  {
8321
8334
  key: "custom",
8322
8335
  label: t.length === 2 && t[0] !== "" ? `${j("Custom")}: ${t[0]} / ${t[1]}` : j("Custom"),
@@ -8461,26 +8474,26 @@ const En = /* @__PURE__ */ fn(Bs), _s = ({ setDateFilter: r, setShowRange: e, se
8461
8474
  }
8462
8475
  );
8463
8476
  }, Ks = (r, e, t) => {
8464
- const n = r.filter((p) => e[p.id]), i = Object.keys(n[0]), o = n.map((p) => i.map((f) => {
8465
- const h = p[f];
8466
- return h == null ? "" : typeof h == "object" ? Object.values(h).find((y) => typeof y != "object") ?? "" : h;
8477
+ const n = r.filter((p) => e[p.id]), i = Object.keys(n[0]), o = n.map((p) => i.map((h) => {
8478
+ const f = p[h];
8479
+ return f == null ? "" : typeof f == "object" ? Object.values(f).find((y) => typeof y != "object") ?? "" : f;
8467
8480
  })), a = [i, ...o].map(
8468
- (p) => p.map((f) => `"${(f || "").toString().replace(/"/g, '""')}"`).join(",")
8481
+ (p) => p.map((h) => `"${(h || "").toString().replace(/"/g, '""')}"`).join(",")
8469
8482
  ).join(`\r
8470
8483
  `), l = "\uFEFF", d = new Blob([l + a], { type: "text/csv;charset=utf-8;" }), c = document.createElement("a"), u = URL.createObjectURL(d);
8471
8484
  c.setAttribute("href", u), c.setAttribute("download", t), document.body.appendChild(c), c.click(), document.body.removeChild(c), URL.revokeObjectURL(u);
8472
8485
  }, qs = (r, e, t) => {
8473
8486
  const i = r.filter((p) => e[p.id]).map((p) => {
8474
- const f = {};
8475
- return Object.entries(p).forEach(([h, g]) => {
8487
+ const h = {};
8488
+ return Object.entries(p).forEach(([f, g]) => {
8476
8489
  if (g == null)
8477
- f[h] = "";
8490
+ h[f] = "";
8478
8491
  else if (typeof g == "object") {
8479
8492
  const y = Object.values(g).find((O) => typeof O != "object");
8480
- f[h] = y ?? "";
8493
+ h[f] = y ?? "";
8481
8494
  } else
8482
- f[h] = g;
8483
- }), f;
8495
+ h[f] = g;
8496
+ }), h;
8484
8497
  }), o = ct.utils.json_to_sheet(i), a = ct.utils.book_new();
8485
8498
  ct.utils.book_append_sheet(a, o, "Data");
8486
8499
  const l = ct.write(a, { bookType: "xlsx", type: "array" }), d = new Blob([l], { type: "application/octet-stream" }), c = URL.createObjectURL(d), u = document.createElement("a");
@@ -8634,29 +8647,29 @@ const Ul = ({
8634
8647
  ...o
8635
8648
  }) => {
8636
8649
  const a = async (d) => {
8637
- var h, g;
8638
- const { file: c } = d, u = URL.createObjectURL(c), p = { name: c.name, uid: c.uid, status: "uploading", url: u }, f = [...r, p];
8639
- e(f);
8650
+ var f, g;
8651
+ const { file: c } = d, u = URL.createObjectURL(c), p = { name: c.name, uid: c.uid, status: "uploading", url: u }, h = [...r, p];
8652
+ e(h);
8640
8653
  try {
8641
8654
  const y = new FormData();
8642
8655
  y.append("files", c);
8643
8656
  const O = await i(y);
8644
- if ((h = O == null ? void 0 : O.data) != null && h.success) {
8657
+ if ((f = O == null ? void 0 : O.data) != null && f.success) {
8645
8658
  const P = (g = O == null ? void 0 : O.data) == null ? void 0 : g.value[0];
8646
8659
  e(
8647
- f.map(
8660
+ h.map(
8648
8661
  (S) => S.uid === c.uid ? { ...S, status: "done", ...P } : S
8649
8662
  )
8650
8663
  );
8651
8664
  } else
8652
- e(f.filter((P) => P.uid !== c.uid)), ht.error({
8665
+ e(h.filter((P) => P.uid !== c.uid)), ht.error({
8653
8666
  className: "bottom-right-notification",
8654
8667
  placement: "bottomRight",
8655
8668
  message: "Error",
8656
8669
  description: "Upload failed"
8657
8670
  });
8658
8671
  } catch {
8659
- e(f.filter((O) => O.uid !== c.uid)), ht.error({
8672
+ e(h.filter((O) => O.uid !== c.uid)), ht.error({
8660
8673
  className: "bottom-right-notification",
8661
8674
  placement: "bottomRight",
8662
8675
  message: "Error",
@@ -8819,16 +8832,16 @@ const Ul = ({
8819
8832
  needsBreadcrumb: a,
8820
8833
  customTabFilter: l
8821
8834
  }) => {
8822
- const { hasPermission: d } = He(), { id: c } = jn(), u = Ue(), p = Pe(), f = we(() => {
8835
+ const { hasPermission: d } = ze(), { id: c } = jn(), u = _e(), p = Pe(), h = we(() => {
8823
8836
  const k = u.pathname.split("/");
8824
8837
  return k[k.length - 1] || n;
8825
- }, [u.pathname, n]), [h, g] = M(null), [y, O] = M(null), P = (k) => {
8838
+ }, [u.pathname, n]), [f, g] = M(null), [y, O] = M(null), P = (k) => {
8826
8839
  p(`${r}/${c}/${k}`);
8827
8840
  }, S = () => l ? l(e) : e.filter((k) => {
8828
8841
  var H;
8829
8842
  return (H = k.permission) == null ? void 0 : H.some((U) => d(U));
8830
8843
  }), E = () => {
8831
- const k = t[f] || t[n];
8844
+ const k = t[h] || t[n];
8832
8845
  return k ? typeof k == "object" && k !== null && "type" in k ? {
8833
8846
  ...k,
8834
8847
  props: {
@@ -8844,7 +8857,7 @@ const Ul = ({
8844
8857
  /* @__PURE__ */ s(
8845
8858
  el,
8846
8859
  {
8847
- activeKey: f,
8860
+ activeKey: h,
8848
8861
  onChange: P,
8849
8862
  tabBarExtraContent: {
8850
8863
  right: /* @__PURE__ */ v(rl, { children: [
@@ -8854,7 +8867,7 @@ const Ul = ({
8854
8867
  className: "partner-tab-select",
8855
8868
  placeholder: "Modules",
8856
8869
  onChange: (k) => P(k),
8857
- value: f,
8870
+ value: h,
8858
8871
  options: e.filter((k) => (k == null ? void 0 : k.label) !== "Details").map((k) => ({
8859
8872
  value: k.key,
8860
8873
  label: k.label
@@ -8863,7 +8876,7 @@ const Ul = ({
8863
8876
  ) }),
8864
8877
  /* @__PURE__ */ v(tl, { children: [
8865
8878
  y,
8866
- h
8879
+ f
8867
8880
  ] })
8868
8881
  ] })
8869
8882
  },
@@ -8881,7 +8894,7 @@ const Ul = ({
8881
8894
  getItemById: o,
8882
8895
  onSetFormValues: a
8883
8896
  }) => {
8884
- const l = Pe(), [d] = Ae.useForm(), [c, u] = M(r == "new"), [p, f] = M(null), h = async (y) => {
8897
+ const l = Pe(), [d] = Ne.useForm(), [c, u] = M(r == "new"), [p, h] = M(null), f = async (y) => {
8885
8898
  const O = window.location.pathname, P = O.substring(0, O.lastIndexOf("/"));
8886
8899
  try {
8887
8900
  if (p) {
@@ -8893,14 +8906,14 @@ const Ul = ({
8893
8906
  }
8894
8907
  } catch (S) {
8895
8908
  if (S.status === 400) {
8896
- const E = S.response.data, k = je(E.errors);
8909
+ const E = S.response.data, k = Fe(E.errors);
8897
8910
  d.setFields(k);
8898
8911
  }
8899
8912
  }
8900
8913
  }, g = async (y) => {
8901
8914
  try {
8902
8915
  const O = await o(y), P = a ? a(O.data) : O.data;
8903
- f(P), d.setFieldsValue(P);
8916
+ h(P), d.setFieldsValue(P);
8904
8917
  } catch (O) {
8905
8918
  console.log(O, "Error in Form Controller.");
8906
8919
  }
@@ -8912,24 +8925,24 @@ const Ul = ({
8912
8925
  item: p,
8913
8926
  getItemById: o,
8914
8927
  isAddingForm: c,
8915
- handleSave: h
8928
+ handleSave: f
8916
8929
  };
8917
8930
  }, Yl = ({ id: r, formItem: e, updateItem: t, addItem: n, getItemById: i }) => {
8918
- const [o] = Ae.useForm(), [a, l] = M(null), d = async (u) => {
8931
+ const [o] = Ne.useForm(), [a, l] = M(null), d = async (u) => {
8919
8932
  try {
8920
8933
  let p;
8921
8934
  return r ? p = await t({ ...u }) : p = await n(u), p;
8922
8935
  } catch (p) {
8923
8936
  if (p.status === 400) {
8924
- const f = p.response.data, h = je(f.errors);
8925
- o.setFields(h);
8937
+ const h = p.response.data, f = Fe(h.errors);
8938
+ o.setFields(f);
8926
8939
  }
8927
8940
  throw p;
8928
8941
  }
8929
8942
  }, c = async (u) => {
8930
8943
  try {
8931
- const f = (await i(u)).data;
8932
- l(f), o.setFieldsValue(f);
8944
+ const h = (await i(u)).data;
8945
+ l(h), o.setFieldsValue(h);
8933
8946
  } catch (p) {
8934
8947
  console.log(p, "Error in Form Controller.");
8935
8948
  }
@@ -8949,7 +8962,7 @@ const Ul = ({
8949
8962
  handleSave: d
8950
8963
  };
8951
8964
  }, Kl = () => {
8952
- const r = Pe(), { setUser: e } = He(), [t, n] = M({
8965
+ const r = Pe(), { setUser: e } = ze(), [t, n] = M({
8953
8966
  visible: !1,
8954
8967
  token: ""
8955
8968
  }), i = (a) => {
@@ -8977,7 +8990,7 @@ const Ul = ({
8977
8990
  };
8978
8991
  };
8979
8992
  function ql(r) {
8980
- const { navigator: e } = xt(Bn), t = Ue();
8993
+ const { navigator: e } = xt(Bn), t = _e();
8981
8994
  K(() => {
8982
8995
  if (!r) return;
8983
8996
  const n = e.push, i = e.replace, o = (a) => (...l) => {
@@ -9090,14 +9103,14 @@ export {
9090
9103
  Bl as ExcelExportSelected,
9091
9104
  Rl as ExpandableTable,
9092
9105
  oo as FilterConfiguration,
9093
- Ve as FilterSelectTypes,
9106
+ Ae as FilterSelectTypes,
9094
9107
  qt as GeneralInput,
9095
9108
  pr as GenericModal,
9096
9109
  Gl as GenericTabsPage,
9097
9110
  Tl as GridViewPage,
9098
9111
  pe as LabelText,
9099
9112
  Il as MFAModalManager,
9100
- Be as MFA_STEP,
9113
+ je as MFA_STEP,
9101
9114
  $l as ModalHost,
9102
9115
  to as ModalHostButtonWrapper,
9103
9116
  $o as NoData,
@@ -9131,7 +9144,7 @@ export {
9131
9144
  Ql as numberFormatterWithComma,
9132
9145
  Xl as parseCommissionErrors,
9133
9146
  jo as parseErrorMessageKey,
9134
- je as parseServerErrors,
9147
+ Fe as parseServerErrors,
9135
9148
  Zl as useAutofillStartDetection,
9136
9149
  Qo as useContactInfoController,
9137
9150
  en as useDebounce,
@@ -9142,8 +9155,8 @@ export {
9142
9155
  $e as useModalStore,
9143
9156
  ql as useNavigationGuard,
9144
9157
  Yl as useNewDesignFormController,
9145
- ze as usePackageServices,
9158
+ Ue as usePackageServices,
9146
9159
  Kl as useTwoFactor,
9147
- He as useUserStore
9160
+ ze as useUserStore
9148
9161
  };
9149
9162
  //# sourceMappingURL=index.mjs.map