sera-components 1.7.0 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -2,16 +2,16 @@ var Dn = Object.defineProperty;
2
2
  var Vn = (e, n, t) => n in e ? Dn(e, n, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[n] = t;
3
3
  var ee = (e, n, t) => Vn(e, typeof n != "symbol" ? n + "" : n, t);
4
4
  import * as Xe from "react";
5
- import Tn, { createContext as be, useContext as U, useMemo as _, useState as M, useEffect as De } from "react";
6
- import { Paper as ie, Image as An, Text as E, Menu as ae, Button as q, Container as Nn, Alert as lt, Stack as X, Flex as B, Loader as Ee, NavLink as jt, Checkbox as de, Group as L, Input as J, useCombobox as qt, Combobox as z, Grid as A, InputBase as kn, PasswordInput as Bt, Select as On, CloseButton as Ln, Divider as zn, Tooltip as Ut, Fieldset as Kt, Table as Yt, rem as ge, Pagination as Gn, MenuTarget as Hn, MenuDropdown as qn, MenuItem as Bn, TextInput as _t, Popover as Le, ActionIcon as Ft, Tabs as Re } from "@mantine/core";
7
- import { IconCheck as Un, IconInfoCircle as at, IconChevronRight as Kn, IconSearch as ut, IconCalendar as $e, IconHelpCircle as Wt, IconPlus as Yn, IconPencil as Wn, IconReload as Xn, IconDatabaseImport as Jn, IconDownload as Qn, IconDatabaseOff as Zn, IconSelector as eo, IconCircleX as to, IconAdjustmentsHorizontal as no, IconKeyboard as oo } from "@tabler/icons-react";
5
+ import Tn, { createContext as De, useContext as U, useMemo as _, useState as M, useEffect as Ve } from "react";
6
+ import { Paper as ie, Image as An, Text as E, Menu as ae, Button as z, Container as Nn, Alert as lt, Stack as Y, Flex as B, Loader as $e, NavLink as yt, Popover as de, Group as O, Checkbox as ce, Input as J, useCombobox as qt, Combobox as G, Grid as N, InputBase as kn, PasswordInput as Bt, Select as Ln, CloseButton as On, Divider as zn, Tooltip as Ut, Fieldset as Yt, Table as Kt, rem as fe, Pagination as Gn, MenuTarget as Hn, MenuDropdown as qn, MenuItem as Bn, TextInput as _t, ActionIcon as Ft, Tabs as je } from "@mantine/core";
7
+ import { IconCheck as Un, IconInfoCircle as at, IconChevronRight as Yn, IconSearch as ut, IconCalendar as Me, IconHelpCircle as Wt, IconPlus as Kn, IconPencil as Wn, IconTrash as Xn, IconReload as Jn, IconDatabaseImport as Qn, IconDownload as Zn, IconDatabaseOff as eo, IconSelector as to, IconCircleX as no, IconAdjustmentsHorizontal as oo, IconKeyboard as ro } from "@tabler/icons-react";
8
8
  import { observer as oe } from "mobx-react-lite";
9
- import { isNestedProperty as Xt, NestedProperty as Y, isObjectProperty as se, DynamicMultiLingualString as ro, isDraftRecord as Jt, I18NStore as io, validators as It } from "sera-db";
10
- import { IMaskInput as so } from "react-imask";
9
+ import { isNestedProperty as Xt, NestedProperty as W, isObjectProperty as se, DynamicMultiLingualString as io, isDraftRecord as Jt, I18NStore as so, validators as It } from "sera-db";
10
+ import { IMaskInput as lo } from "react-imask";
11
11
  import Z from "dayjs";
12
12
  import { DatePickerInput as Je, DateTimePicker as Pt } from "@mantine/dates";
13
- import { debounce as lo } from "throttle-debounce";
14
- var ye = { exports: {} }, fe = {};
13
+ import { debounce as ao } from "throttle-debounce";
14
+ var ye = { exports: {} }, me = {};
15
15
  /**
16
16
  * @license React
17
17
  * react-jsx-runtime.production.js
@@ -22,8 +22,8 @@ var ye = { exports: {} }, fe = {};
22
22
  * LICENSE file in the root directory of this source tree.
23
23
  */
24
24
  var Et;
25
- function ao() {
26
- if (Et) return fe;
25
+ function uo() {
26
+ if (Et) return me;
27
27
  Et = 1;
28
28
  var e = Symbol.for("react.transitional.element"), n = Symbol.for("react.fragment");
29
29
  function t(o, r, i) {
@@ -41,9 +41,9 @@ function ao() {
41
41
  props: i
42
42
  };
43
43
  }
44
- return fe.Fragment = n, fe.jsx = t, fe.jsxs = t, fe;
44
+ return me.Fragment = n, me.jsx = t, me.jsxs = t, me;
45
45
  }
46
- var me = {};
46
+ var pe = {};
47
47
  /**
48
48
  * @license React
49
49
  * react-jsx-runtime.development.js
@@ -54,12 +54,12 @@ var me = {};
54
54
  * LICENSE file in the root directory of this source tree.
55
55
  */
56
56
  var $t;
57
- function uo() {
57
+ function co() {
58
58
  return $t || ($t = 1, process.env.NODE_ENV !== "production" && (function() {
59
59
  function e(C) {
60
60
  if (C == null) return null;
61
61
  if (typeof C == "function")
62
- return C.$$typeof === we ? null : C.displayName || C.name || null;
62
+ return C.$$typeof === xe ? null : C.displayName || C.name || null;
63
63
  if (typeof C == "string") return C;
64
64
  switch (C) {
65
65
  case v:
@@ -72,7 +72,7 @@ function uo() {
72
72
  return "Suspense";
73
73
  case F:
74
74
  return "SuspenseList";
75
- case Te:
75
+ case Ae:
76
76
  return "Activity";
77
77
  }
78
78
  if (typeof C == "object")
@@ -83,17 +83,17 @@ function uo() {
83
83
  return "Portal";
84
84
  case I:
85
85
  return C.displayName || "Context";
86
- case j:
86
+ case y:
87
87
  return (C._context.displayName || "Context") + ".Consumer";
88
88
  case P:
89
- var y = C.render;
90
- return C = C.displayName, C || (C = y.displayName || y.name || "", C = C !== "" ? "ForwardRef(" + C + ")" : "ForwardRef"), C;
91
- case V:
92
- return y = C.displayName || null, y !== null ? y : e(C.type) || "Memo";
93
- case G:
94
- y = C._payload, C = C._init;
89
+ var j = C.render;
90
+ return C = C.displayName, C || (C = j.displayName || j.name || "", C = C !== "" ? "ForwardRef(" + C + ")" : "ForwardRef"), C;
91
+ case T:
92
+ return j = C.displayName || null, j !== null ? j : e(C.type) || "Memo";
93
+ case H:
94
+ j = C._payload, C = C._init;
95
95
  try {
96
- return e(C(y));
96
+ return e(C(j));
97
97
  } catch {
98
98
  }
99
99
  }
@@ -105,33 +105,33 @@ function uo() {
105
105
  function t(C) {
106
106
  try {
107
107
  n(C);
108
- var y = !1;
108
+ var j = !1;
109
109
  } catch {
110
- y = !0;
110
+ j = !0;
111
111
  }
112
- if (y) {
113
- y = console;
114
- var $ = y.error, b = typeof Symbol == "function" && Symbol.toStringTag && C[Symbol.toStringTag] || C.constructor.name || "Object";
112
+ if (j) {
113
+ j = console;
114
+ var $ = j.error, D = typeof Symbol == "function" && Symbol.toStringTag && C[Symbol.toStringTag] || C.constructor.name || "Object";
115
115
  return $.call(
116
- y,
116
+ j,
117
117
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
118
- b
118
+ D
119
119
  ), n(C);
120
120
  }
121
121
  }
122
122
  function o(C) {
123
123
  if (C === v) return "<>";
124
- if (typeof C == "object" && C !== null && C.$$typeof === G)
124
+ if (typeof C == "object" && C !== null && C.$$typeof === H)
125
125
  return "<...>";
126
126
  try {
127
- var y = e(C);
128
- return y ? "<" + y + ">" : "<...>";
127
+ var j = e(C);
128
+ return j ? "<" + j + ">" : "<...>";
129
129
  } catch {
130
130
  return "<...>";
131
131
  }
132
132
  }
133
133
  function r() {
134
- var C = Ae.A;
134
+ var C = Ne.A;
135
135
  return C === null ? null : C.getOwner();
136
136
  }
137
137
  function i() {
@@ -139,16 +139,16 @@ function uo() {
139
139
  }
140
140
  function s(C) {
141
141
  if (vt.call(C, "key")) {
142
- var y = Object.getOwnPropertyDescriptor(C, "key").get;
143
- if (y && y.isReactWarning) return !1;
142
+ var j = Object.getOwnPropertyDescriptor(C, "key").get;
143
+ if (j && j.isReactWarning) return !1;
144
144
  }
145
145
  return C.key !== void 0;
146
146
  }
147
- function a(C, y) {
147
+ function a(C, j) {
148
148
  function $() {
149
149
  Ct || (Ct = !0, console.error(
150
150
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
151
- y
151
+ j
152
152
  ));
153
153
  }
154
154
  $.isReactWarning = !0, Object.defineProperty(C, "key", {
@@ -162,15 +162,15 @@ function uo() {
162
162
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
163
163
  )), C = this.props.ref, C !== void 0 ? C : null;
164
164
  }
165
- function c(C, y, $, b, xe, ke) {
166
- var D = $.ref;
165
+ function d(C, j, $, D, Re, Le) {
166
+ var V = $.ref;
167
167
  return C = {
168
168
  $$typeof: f,
169
169
  type: C,
170
- key: y,
170
+ key: j,
171
171
  props: $,
172
- _owner: b
173
- }, (D !== void 0 ? D : null) !== null ? Object.defineProperty(C, "ref", {
172
+ _owner: D
173
+ }, (V !== void 0 ? V : null) !== null ? Object.defineProperty(C, "ref", {
174
174
  enumerable: !1,
175
175
  get: u
176
176
  }) : Object.defineProperty(C, "ref", { enumerable: !1, value: null }), C._store = {}, Object.defineProperty(C._store, "validated", {
@@ -187,109 +187,109 @@ function uo() {
187
187
  configurable: !1,
188
188
  enumerable: !1,
189
189
  writable: !0,
190
- value: xe
190
+ value: Re
191
191
  }), Object.defineProperty(C, "_debugTask", {
192
192
  configurable: !1,
193
193
  enumerable: !1,
194
194
  writable: !0,
195
- value: ke
195
+ value: Le
196
196
  }), Object.freeze && (Object.freeze(C.props), Object.freeze(C)), C;
197
197
  }
198
- function g(C, y, $, b, xe, ke) {
199
- var D = y.children;
200
- if (D !== void 0)
201
- if (b)
202
- if (Mn(D)) {
203
- for (b = 0; b < D.length; b++)
204
- m(D[b]);
205
- Object.freeze && Object.freeze(D);
198
+ function g(C, j, $, D, Re, Le) {
199
+ var V = j.children;
200
+ if (V !== void 0)
201
+ if (D)
202
+ if (Mn(V)) {
203
+ for (D = 0; D < V.length; D++)
204
+ m(V[D]);
205
+ Object.freeze && Object.freeze(V);
206
206
  } else
207
207
  console.error(
208
208
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
209
209
  );
210
- else m(D);
211
- if (vt.call(y, "key")) {
212
- D = e(C);
213
- var le = Object.keys(y).filter(function(bn) {
210
+ else m(V);
211
+ if (vt.call(j, "key")) {
212
+ V = e(C);
213
+ var le = Object.keys(j).filter(function(bn) {
214
214
  return bn !== "key";
215
215
  });
216
- b = 0 < le.length ? "{key: someKey, " + le.join(": ..., ") + ": ...}" : "{key: someKey}", yt[D + b] || (le = 0 < le.length ? "{" + le.join(": ..., ") + ": ...}" : "{}", console.error(
216
+ D = 0 < le.length ? "{key: someKey, " + le.join(": ..., ") + ": ...}" : "{key: someKey}", jt[V + D] || (le = 0 < le.length ? "{" + le.join(": ..., ") + ": ...}" : "{}", console.error(
217
217
  `A props object containing a "key" prop is being spread into JSX:
218
218
  let props = %s;
219
219
  <%s {...props} />
220
220
  React keys must be passed directly to JSX without using spread:
221
221
  let props = %s;
222
222
  <%s key={someKey} {...props} />`,
223
- b,
224
223
  D,
224
+ V,
225
225
  le,
226
- D
227
- ), yt[D + b] = !0);
226
+ V
227
+ ), jt[V + D] = !0);
228
228
  }
229
- if (D = null, $ !== void 0 && (t($), D = "" + $), s(y) && (t(y.key), D = "" + y.key), "key" in y) {
229
+ if (V = null, $ !== void 0 && (t($), V = "" + $), s(j) && (t(j.key), V = "" + j.key), "key" in j) {
230
230
  $ = {};
231
- for (var Oe in y)
232
- Oe !== "key" && ($[Oe] = y[Oe]);
233
- } else $ = y;
234
- return D && a(
231
+ for (var Oe in j)
232
+ Oe !== "key" && ($[Oe] = j[Oe]);
233
+ } else $ = j;
234
+ return V && a(
235
235
  $,
236
236
  typeof C == "function" ? C.displayName || C.name || "Unknown" : C
237
- ), c(
237
+ ), d(
238
238
  C,
239
- D,
239
+ V,
240
240
  $,
241
241
  r(),
242
- xe,
243
- ke
242
+ Re,
243
+ Le
244
244
  );
245
245
  }
246
246
  function m(C) {
247
- p(C) ? C._store && (C._store.validated = 1) : typeof C == "object" && C !== null && C.$$typeof === G && (C._payload.status === "fulfilled" ? p(C._payload.value) && C._payload.value._store && (C._payload.value._store.validated = 1) : C._store && (C._store.validated = 1));
247
+ p(C) ? C._store && (C._store.validated = 1) : typeof C == "object" && C !== null && C.$$typeof === H && (C._payload.status === "fulfilled" ? p(C._payload.value) && C._payload.value._store && (C._payload.value._store.validated = 1) : C._store && (C._store.validated = 1));
248
248
  }
249
249
  function p(C) {
250
250
  return typeof C == "object" && C !== null && C.$$typeof === f;
251
251
  }
252
- var d = Tn, f = Symbol.for("react.transitional.element"), h = Symbol.for("react.portal"), v = Symbol.for("react.fragment"), S = Symbol.for("react.strict_mode"), R = Symbol.for("react.profiler"), j = Symbol.for("react.consumer"), I = Symbol.for("react.context"), P = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), F = Symbol.for("react.suspense_list"), V = Symbol.for("react.memo"), G = Symbol.for("react.lazy"), Te = Symbol.for("react.activity"), we = Symbol.for("react.client.reference"), Ae = d.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, vt = Object.prototype.hasOwnProperty, Mn = Array.isArray, Ne = console.createTask ? console.createTask : function() {
252
+ var c = Tn, f = Symbol.for("react.transitional.element"), h = Symbol.for("react.portal"), v = Symbol.for("react.fragment"), S = Symbol.for("react.strict_mode"), R = Symbol.for("react.profiler"), y = Symbol.for("react.consumer"), I = Symbol.for("react.context"), P = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), F = Symbol.for("react.suspense_list"), T = Symbol.for("react.memo"), H = Symbol.for("react.lazy"), Ae = Symbol.for("react.activity"), xe = Symbol.for("react.client.reference"), Ne = c.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, vt = Object.prototype.hasOwnProperty, Mn = Array.isArray, ke = console.createTask ? console.createTask : function() {
253
253
  return null;
254
254
  };
255
- d = {
255
+ c = {
256
256
  react_stack_bottom_frame: function(C) {
257
257
  return C();
258
258
  }
259
259
  };
260
- var Ct, wt = {}, xt = d.react_stack_bottom_frame.bind(
261
- d,
260
+ var Ct, wt = {}, xt = c.react_stack_bottom_frame.bind(
261
+ c,
262
262
  i
263
- )(), Rt = Ne(o(i)), yt = {};
264
- me.Fragment = v, me.jsx = function(C, y, $) {
265
- var b = 1e4 > Ae.recentlyCreatedOwnerStacks++;
263
+ )(), Rt = ke(o(i)), jt = {};
264
+ pe.Fragment = v, pe.jsx = function(C, j, $) {
265
+ var D = 1e4 > Ne.recentlyCreatedOwnerStacks++;
266
266
  return g(
267
267
  C,
268
- y,
268
+ j,
269
269
  $,
270
270
  !1,
271
- b ? Error("react-stack-top-frame") : xt,
272
- b ? Ne(o(C)) : Rt
271
+ D ? Error("react-stack-top-frame") : xt,
272
+ D ? ke(o(C)) : Rt
273
273
  );
274
- }, me.jsxs = function(C, y, $) {
275
- var b = 1e4 > Ae.recentlyCreatedOwnerStacks++;
274
+ }, pe.jsxs = function(C, j, $) {
275
+ var D = 1e4 > Ne.recentlyCreatedOwnerStacks++;
276
276
  return g(
277
277
  C,
278
- y,
278
+ j,
279
279
  $,
280
280
  !0,
281
- b ? Error("react-stack-top-frame") : xt,
282
- b ? Ne(o(C)) : Rt
281
+ D ? Error("react-stack-top-frame") : xt,
282
+ D ? ke(o(C)) : Rt
283
283
  );
284
284
  };
285
- })()), me;
285
+ })()), pe;
286
286
  }
287
287
  var Mt;
288
- function co() {
289
- return Mt || (Mt = 1, process.env.NODE_ENV === "production" ? ye.exports = ao() : ye.exports = uo()), ye.exports;
288
+ function go() {
289
+ return Mt || (Mt = 1, process.env.NODE_ENV === "production" ? ye.exports = uo() : ye.exports = co()), ye.exports;
290
290
  }
291
- var l = co();
292
- const T = {
291
+ var l = go();
292
+ const A = {
293
293
  UK: {
294
294
  svgFlag: "https://flagcdn.com/gb.svg",
295
295
  emojiFlag: "🇬🇧"
@@ -354,39 +354,39 @@ const T = {
354
354
  svgFlag: "https://flagcdn.com/kh.svg",
355
355
  emojiFlag: "🇰🇭"
356
356
  }
357
- }, go = ({ flag: e }) => /* @__PURE__ */ l.jsx(ie, { shadow: "xs", w: 20, h: 14, children: /* @__PURE__ */ l.jsx(An, { src: e.svgFlag, w: 20, h: 14, fit: "cover" }) }), fo = ({ flag: e }) => /* @__PURE__ */ l.jsx(
357
+ }, fo = ({ flag: e }) => /* @__PURE__ */ l.jsx(ie, { shadow: "xs", w: 20, h: 14, children: /* @__PURE__ */ l.jsx(An, { src: e.svgFlag, w: 20, h: 14, fit: "cover" }) }), mo = ({ flag: e }) => /* @__PURE__ */ l.jsx(
358
358
  E,
359
359
  {
360
360
  component: "span",
361
361
  style: (n) => ({ textShadow: n.shadows.xs }),
362
362
  children: e.emojiFlag
363
363
  }
364
- ), Qe = navigator.userAgent.includes("Windows") ? go : fo, re = be(new Intl.Locale("en-US")), Si = oe(
364
+ ), Qe = navigator.userAgent.includes("Windows") ? fo : mo, re = De(new Intl.Locale("en-US")), xi = oe(
365
365
  ({
366
366
  value: e,
367
367
  children: n
368
368
  }) => /* @__PURE__ */ l.jsx(re.Provider, { value: e.locale, children: n })
369
- ), mo = {
369
+ ), po = {
370
370
  lang2value: {
371
371
  en: "Choose Language",
372
372
  vi: "Chọn ngôn ngữ"
373
373
  }
374
- }, je = {
374
+ }, _e = {
375
375
  en: {
376
376
  name: "English",
377
- flag: T.US,
377
+ flag: A.US,
378
378
  locale: new Intl.Locale("en-US")
379
379
  },
380
380
  vi: {
381
381
  name: "Tiếng Việt",
382
- flag: T.VN,
382
+ flag: A.VN,
383
383
  locale: new Intl.Locale("vi-VN")
384
384
  }
385
- }, vi = ({
385
+ }, Ri = ({
386
386
  locale: e,
387
387
  setLocale: n
388
388
  }) => {
389
- const t = _(() => Object.entries(je).map(
389
+ const t = _(() => Object.entries(_e).map(
390
390
  ([o, { flag: r, name: i, locale: s }]) => /* @__PURE__ */ l.jsx(
391
391
  ae.Item,
392
392
  {
@@ -397,33 +397,33 @@ const T = {
397
397
  },
398
398
  o
399
399
  )
400
- ), [je, e]);
400
+ ), [_e, e]);
401
401
  return /* @__PURE__ */ l.jsxs(ae, { width: 170, children: [
402
402
  /* @__PURE__ */ l.jsx(ae.Target, { children: /* @__PURE__ */ l.jsx(
403
- q,
403
+ z,
404
404
  {
405
405
  variant: "subtle",
406
406
  size: "sm",
407
- leftSection: /* @__PURE__ */ l.jsx(Qe, { flag: je[e.language].flag }),
408
- children: /* @__PURE__ */ l.jsx(E, { size: "sm", children: je[e.language].name })
407
+ leftSection: /* @__PURE__ */ l.jsx(Qe, { flag: _e[e.language].flag }),
408
+ children: /* @__PURE__ */ l.jsx(E, { size: "sm", children: _e[e.language].name })
409
409
  }
410
410
  ) }),
411
411
  /* @__PURE__ */ l.jsxs(ae.Dropdown, { children: [
412
- /* @__PURE__ */ l.jsx(ae.Label, { children: /* @__PURE__ */ l.jsx(E, { size: "sm", children: mo.lang2value[e.language] }) }),
412
+ /* @__PURE__ */ l.jsx(ae.Label, { children: /* @__PURE__ */ l.jsx(E, { size: "sm", children: po.lang2value[e.language] }) }),
413
413
  t
414
414
  ] })
415
415
  ] });
416
- }, N = ({ value: e }) => {
416
+ }, b = ({ value: e }) => {
417
417
  const n = U(re);
418
418
  return e.lang2value[n.language] || e.lang2value[e.lang];
419
- }, Ci = (e) => {
419
+ }, ji = (e) => {
420
420
  const n = U(re);
421
421
  return e.lang2value[n.language] || e.lang2value[e.lang];
422
422
  };
423
- function he(e, n) {
423
+ function Se(e, n) {
424
424
  return n.lang2value[e.language] || n.lang2value[n.lang];
425
425
  }
426
- const wi = ({
426
+ const yi = ({
427
427
  message: e,
428
428
  navigate: n
429
429
  }) => /* @__PURE__ */ l.jsx(
@@ -443,14 +443,14 @@ const wi = ({
443
443
  title: "Not Found",
444
444
  variant: "404 - Not Found",
445
445
  icon: /* @__PURE__ */ l.jsx(at, { size: 12, stroke: 1.5 }),
446
- children: /* @__PURE__ */ l.jsxs(X, { align: "flex-start", children: [
446
+ children: /* @__PURE__ */ l.jsxs(Y, { align: "flex-start", children: [
447
447
  e || "Sorry, the page you are looking for does not exist.",
448
- /* @__PURE__ */ l.jsx(q, { variant: "filled", onClick: () => n("/"), size: "xs", children: "Back Home" })
448
+ /* @__PURE__ */ l.jsx(z, { variant: "filled", onClick: () => n("/"), size: "xs", children: "Back Home" })
449
449
  ] })
450
450
  }
451
451
  )
452
452
  }
453
- ), xi = ({ message: e }) => /* @__PURE__ */ l.jsx(
453
+ ), _i = ({ message: e }) => /* @__PURE__ */ l.jsx(
454
454
  lt,
455
455
  {
456
456
  color: "red",
@@ -459,7 +459,7 @@ const wi = ({
459
459
  icon: /* @__PURE__ */ l.jsx(at, { size: 12, stroke: 1.5 }),
460
460
  children: e || "Sorry, the page you are looking for does not exist."
461
461
  }
462
- ), Qt = ({ message: e }) => /* @__PURE__ */ l.jsx(E, { c: "red", size: "sm", children: e || "Not Found" }), Ri = ({ tip: e }) => e === void 0 ? /* @__PURE__ */ l.jsx(B, { justify: "center", align: "center", children: /* @__PURE__ */ l.jsx(Ee, { color: "blue", size: "md" }) }) : /* @__PURE__ */ l.jsxs(
462
+ ), Qt = ({ message: e }) => /* @__PURE__ */ l.jsx(E, { c: "red", size: "sm", children: e || "Not Found" }), Fi = ({ tip: e }) => e === void 0 ? /* @__PURE__ */ l.jsx(B, { justify: "center", align: "center", children: /* @__PURE__ */ l.jsx($e, { color: "blue", size: "md" }) }) : /* @__PURE__ */ l.jsxs(
463
463
  B,
464
464
  {
465
465
  gap: "md",
@@ -468,14 +468,14 @@ const wi = ({
468
468
  align: "center",
469
469
  style: { height: "100%" },
470
470
  children: [
471
- /* @__PURE__ */ l.jsx(Ee, { color: "blue", size: "md" }),
471
+ /* @__PURE__ */ l.jsx($e, { color: "blue", size: "md" }),
472
472
  e
473
473
  ]
474
474
  }
475
- ), yi = ({ tip: e }) => e === void 0 ? /* @__PURE__ */ l.jsx(Ee, { color: "blue", size: "xs" }) : /* @__PURE__ */ l.jsxs(B, { gap: "md", direction: "column", justify: "center", align: "center", children: [
476
- /* @__PURE__ */ l.jsx(Ee, { color: "blue", size: "xs" }),
475
+ ), Ii = ({ tip: e }) => e === void 0 ? /* @__PURE__ */ l.jsx($e, { color: "blue", size: "xs" }) : /* @__PURE__ */ l.jsxs(B, { gap: "md", direction: "column", justify: "center", align: "center", children: [
476
+ /* @__PURE__ */ l.jsx($e, { color: "blue", size: "xs" }),
477
477
  e
478
- ] }), ji = ({ message: e }) => /* @__PURE__ */ l.jsx(
478
+ ] }), Pi = ({ message: e }) => /* @__PURE__ */ l.jsx(
479
479
  lt,
480
480
  {
481
481
  color: "red",
@@ -485,13 +485,13 @@ const wi = ({
485
485
  children: e || "Sorry, you are not authorized to access this page."
486
486
  }
487
487
  );
488
- function _i(e, n) {
488
+ function Ei(e, n) {
489
489
  return e.reduce((t, o) => {
490
490
  const r = n(o);
491
491
  return t[r] || (t[r] = []), t[r].push(o), t;
492
492
  }, {});
493
493
  }
494
- function Fi(e, n) {
494
+ function $i(e, n) {
495
495
  const t = [];
496
496
  let o;
497
497
  return e.reduce((r, i) => {
@@ -499,14 +499,14 @@ function Fi(e, n) {
499
499
  return s === void 0 ? (o === void 0 && (o = t.length, t.push([])), t[o].push(i)) : (r[s] === void 0 && (r[s] = t.length, t.push([])), t[r[s]].push(i)), r;
500
500
  }, {}), t;
501
501
  }
502
- function Ii(e, n) {
502
+ function Mi(e, n) {
503
503
  const t = /* @__PURE__ */ new Set();
504
504
  return e.filter((o) => {
505
505
  const r = n(o);
506
506
  return t.has(r) ? !1 : (t.add(r), !0);
507
507
  });
508
508
  }
509
- class Pi {
509
+ class bi {
510
510
  constructor() {
511
511
  ee(this, "items", []);
512
512
  ee(this, "seen", /* @__PURE__ */ new Set());
@@ -571,19 +571,19 @@ function dt(e, n) {
571
571
  function Ze(e, n, t) {
572
572
  Xt(n) ? n.setValue(e, t) : e[n.updateFuncName](t);
573
573
  }
574
- const ct = be(!1), Ei = ct.Provider;
575
- function $i(e) {
574
+ const ct = De(!1), Di = ct.Provider;
575
+ function Vi(e) {
576
576
  return U(ct) ? { "data-testid": e } : {};
577
577
  }
578
- function Mi(e, n) {
578
+ function Ti(e, n) {
579
579
  return n ? { "data-testid": e } : {};
580
580
  }
581
- function W(e, n = "") {
582
- const t = U(ct), o = _(() => (n !== "" && (n = `_${n}`), e instanceof Y ? `${e.allProperties.map((r) => r.name).join(".")}${n}` : `${e.name}${n}`), [e, n]);
581
+ function X(e, n = "") {
582
+ const t = U(ct), o = _(() => (n !== "" && (n = `_${n}`), e instanceof W ? `${e.allProperties.map((r) => r.name).join(".")}${n}` : `${e.name}${n}`), [e, n]);
583
583
  return t ? { "data-testid": o } : {};
584
584
  }
585
585
  var et = /* @__PURE__ */ ((e) => (e[e.Allow = 0] = "Allow", e[e.Denied = 1] = "Denied", e[e.Pending = 2] = "Pending", e))(et || {});
586
- function po(e) {
586
+ function ho(e) {
587
587
  const n = {}, t = {}, o = {}, r = (i, s = []) => {
588
588
  i.forEach((a) => {
589
589
  const u = [...s, a.key];
@@ -592,8 +592,8 @@ function po(e) {
592
592
  };
593
593
  return r(e), { key2item: n, key2fullpath: t, key2route: o };
594
594
  }
595
- function ho(e) {
596
- const n = new vo(), t = (o) => {
595
+ function So(e) {
596
+ const n = new Co(), t = (o) => {
597
597
  o.forEach((r) => {
598
598
  if (r.route !== void 0) {
599
599
  const i = r.route.path.pathDef;
@@ -604,7 +604,7 @@ function ho(e) {
604
604
  };
605
605
  return t(e), n;
606
606
  }
607
- function So(e, n) {
607
+ function vo(e, n) {
608
608
  return e.map((t) => {
609
609
  if (t.route !== void 0)
610
610
  return n(t.route.role) === et.Allow ? t : null;
@@ -615,41 +615,41 @@ function So(e, n) {
615
615
  return t;
616
616
  }).filter((t) => t !== null);
617
617
  }
618
- const bi = (e) => {
619
- const [n, t] = M(/* @__PURE__ */ new Set()), [o, r] = M(/* @__PURE__ */ new Set()), [i, s] = M(), a = _(() => So(e.items, e.checkPermission), [e.items, e.checkPermission]), u = _(() => ho(e.items), [e.items]), { key2fullpath: c, key2route: g } = _(
620
- () => po(a),
618
+ const Ai = (e) => {
619
+ const [n, t] = M(/* @__PURE__ */ new Set()), [o, r] = M(/* @__PURE__ */ new Set()), [i, s] = M(), a = _(() => vo(e.items, e.checkPermission), [e.items, e.checkPermission]), u = _(() => So(e.items), [e.items]), { key2fullpath: d, key2route: g } = _(
620
+ () => ho(a),
621
621
  [a]
622
622
  );
623
- De(() => {
624
- const p = window.location.pathname, d = u.findMatchingKey(p);
625
- d !== void 0 && (r(new Set(c[d])), s(d));
623
+ Ve(() => {
624
+ const p = window.location.pathname, c = u.findMatchingKey(p);
625
+ c !== void 0 && (r(new Set(d[c])), s(c));
626
626
  }, [window.location.pathname, g]);
627
627
  const m = _(() => {
628
- function p(d, f) {
628
+ function p(c, f) {
629
629
  var v;
630
- const h = d.children !== void 0 && d.children.length > 0;
630
+ const h = c.children !== void 0 && c.children.length > 0;
631
631
  return h ? /* @__PURE__ */ l.jsxs(
632
632
  "div",
633
633
  {
634
634
  onMouseEnter: () => {
635
- o.has(d.key) || t((S) => {
635
+ o.has(c.key) || t((S) => {
636
636
  const R = new Set(S);
637
- return R.add(d.key), R;
637
+ return R.add(c.key), R;
638
638
  });
639
639
  },
640
640
  onMouseLeave: () => {
641
- o.has(d.key) || t((S) => {
641
+ o.has(c.key) || t((S) => {
642
642
  const R = new Set(S);
643
- return R.delete(d.key), R;
643
+ return R.delete(c.key), R;
644
644
  });
645
645
  },
646
646
  children: [
647
647
  /* @__PURE__ */ l.jsx(
648
- jt,
648
+ yt,
649
649
  {
650
- active: i === d.key,
651
- label: d.label,
652
- leftSection: d.icon,
650
+ active: i === c.key,
651
+ label: c.label,
652
+ leftSection: c.icon,
653
653
  styles: {
654
654
  label: { fontSize: "md" },
655
655
  root: {
@@ -659,34 +659,34 @@ const bi = (e) => {
659
659
  ml: f === 0 ? void 0 : f === 1 ? "md" : `calc(var(--mantine-spacing-md) * ${f})`,
660
660
  w: "unset",
661
661
  rightSection: h ? /* @__PURE__ */ l.jsx(
662
- Kn,
662
+ Yn,
663
663
  {
664
664
  size: 12,
665
665
  stroke: 1.5,
666
666
  className: "mantine-rotate-rtl"
667
667
  }
668
668
  ) : void 0,
669
- opened: n.has(d.key) || o.has(d.key),
669
+ opened: n.has(c.key) || o.has(c.key),
670
670
  onClick: (S) => {
671
671
  S.preventDefault(), r((R) => {
672
- const j = new Set(R);
673
- return R.has(d.key) ? j.delete(d.key) : j.add(d.key), j;
672
+ const y = new Set(R);
673
+ return R.has(c.key) ? y.delete(c.key) : y.add(c.key), y;
674
674
  });
675
675
  }
676
676
  },
677
- d.key
677
+ c.key
678
678
  ),
679
- (o.has(d.key) || n.has(d.key)) && d.children.map((S) => p(S, f + 1))
679
+ (o.has(c.key) || n.has(c.key)) && c.children.map((S) => p(S, f + 1))
680
680
  ]
681
681
  },
682
- `container-${d.key}`
682
+ `container-${c.key}`
683
683
  ) : /* @__PURE__ */ l.jsx(
684
- jt,
684
+ yt,
685
685
  {
686
- active: i === d.key,
687
- href: (v = d.route) == null ? void 0 : v.path.getURL(d.route.defaultPathArgs ?? {}),
688
- label: d.label,
689
- leftSection: d.icon,
686
+ active: i === c.key,
687
+ href: (v = c.route) == null ? void 0 : v.path.getURL(c.route.defaultPathArgs ?? {}),
688
+ label: c.label,
689
+ leftSection: c.icon,
690
690
  styles: {
691
691
  label: { fontSize: "md" },
692
692
  root: {
@@ -696,17 +696,17 @@ const bi = (e) => {
696
696
  ml: f === 0 ? void 0 : f === 1 ? "md" : `calc(var(--mantine-spacing-md) * ${f})`,
697
697
  w: "unset",
698
698
  onClick: (S) => {
699
- S.ctrlKey || S.metaKey || (S.preventDefault(), d.route != null && d.route.path.path(d.route.defaultPathArgs ?? {}).open(e.navigate));
699
+ S.ctrlKey || S.metaKey || (S.preventDefault(), c.route != null && c.route.path.path(c.route.defaultPathArgs ?? {}).open(e.navigate));
700
700
  }
701
701
  },
702
- d.key
702
+ c.key
703
703
  );
704
704
  }
705
- return a.map((d) => p(d, 0));
705
+ return a.map((c) => p(c, 0));
706
706
  }, [a, i, o, n, e.navigate]);
707
707
  return /* @__PURE__ */ l.jsx(l.Fragment, { children: m });
708
708
  };
709
- class vo extends Zt {
709
+ class Co extends Zt {
710
710
  constructor() {
711
711
  super(...arguments);
712
712
  ee(this, "pathToKey", /* @__PURE__ */ new Map());
@@ -742,7 +742,7 @@ class vo extends Zt {
742
742
  return this.pathToKey.get(r.match);
743
743
  }
744
744
  }
745
- const ze = 12, en = be({ gap: "sm" }), tn = ({
745
+ const ze = 12, en = De({ gap: "sm" }), tn = ({
746
746
  children: e,
747
747
  gap: n = "sm",
748
748
  align: t = "flex-start",
@@ -775,7 +775,7 @@ const ze = 12, en = be({ gap: "sm" }), tn = ({
775
775
  ...r
776
776
  };
777
777
  if (n !== void 0) {
778
- const a = n / ze * 100, u = `var(--mantine-spacing-${i})`, c = (ze - n) / ze, g = `calc(${a}% - ${c} * ${u})`;
778
+ const a = n / ze * 100, u = `var(--mantine-spacing-${i})`, d = (ze - n) / ze, g = `calc(${a}% - ${d} * ${u})`;
779
779
  s = {
780
780
  ...s,
781
781
  flex: `0 0 ${g}`,
@@ -787,8 +787,66 @@ const ze = 12, en = be({ gap: "sm" }), tn = ({
787
787
  flex: `${t ?? 1} 1 0px`
788
788
  };
789
789
  return /* @__PURE__ */ l.jsx("div", { className: o, style: s, children: e });
790
- }, _e = ({ value: e }) => /* @__PURE__ */ l.jsx(E, { size: "sm", children: e });
791
- function Ce(e, n) {
790
+ }, wo = {
791
+ lang: "en",
792
+ lang2value: {
793
+ en: "Confirm",
794
+ vi: "Xác nhận"
795
+ }
796
+ }, xo = {
797
+ lang: "en",
798
+ lang2value: {
799
+ en: "Cancel",
800
+ vi: "Hủy"
801
+ }
802
+ }, Ro = ({
803
+ children: e,
804
+ title: n,
805
+ onConfirm: t,
806
+ onCancel: o,
807
+ confirmLabel: r = wo,
808
+ cancelLabel: i = xo,
809
+ confirmProps: s,
810
+ cancelProps: a,
811
+ popoverProps: u,
812
+ disabled: d = !1
813
+ }) => {
814
+ const [g, m] = M(!1), p = () => {
815
+ m(!1), t();
816
+ }, c = () => {
817
+ m(!1), o == null || o();
818
+ };
819
+ return /* @__PURE__ */ l.jsxs(
820
+ de,
821
+ {
822
+ opened: g,
823
+ onClose: () => m(!1),
824
+ position: "bottom",
825
+ withArrow: !0,
826
+ shadow: "md",
827
+ ...u,
828
+ children: [
829
+ /* @__PURE__ */ l.jsx(de.Target, { children: /* @__PURE__ */ l.jsx(
830
+ "span",
831
+ {
832
+ onClick: (f) => {
833
+ d || (f.stopPropagation(), m(!0));
834
+ },
835
+ children: e
836
+ }
837
+ ) }),
838
+ /* @__PURE__ */ l.jsx(de.Dropdown, { children: /* @__PURE__ */ l.jsxs(Y, { gap: "xs", children: [
839
+ typeof n == "string" ? /* @__PURE__ */ l.jsx(E, { size: "sm", children: n }) : n,
840
+ /* @__PURE__ */ l.jsxs(O, { gap: "xs", justify: "flex-end", children: [
841
+ /* @__PURE__ */ l.jsx(z, { size: "xs", variant: "default", onClick: c, ...a, children: /* @__PURE__ */ l.jsx(b, { value: i }) }),
842
+ /* @__PURE__ */ l.jsx(z, { size: "xs", onClick: p, ...s, children: /* @__PURE__ */ l.jsx(b, { value: r }) })
843
+ ] })
844
+ ] }) })
845
+ ]
846
+ }
847
+ );
848
+ }, Fe = ({ value: e }) => /* @__PURE__ */ l.jsx(E, { size: "sm", children: e });
849
+ function we(e, n) {
792
850
  return n.toLocaleDateString(e.baseName, {
793
851
  year: "numeric",
794
852
  month: "short",
@@ -797,24 +855,24 @@ function Ce(e, n) {
797
855
  }
798
856
  function on(e, n, t = !0) {
799
857
  const o = n.getHours().toString().padStart(2, "0"), r = n.getMinutes().toString().padStart(2, "0"), i = n.getSeconds().toString().padStart(2, "0");
800
- return t ? Ce(e, n) + ` ${o}:${r}:${i}` : Ce(e, n) + ` ${o}:${r}`;
858
+ return t ? we(e, n) + ` ${o}:${r}:${i}` : we(e, n) + ` ${o}:${r}`;
801
859
  }
802
- const Co = ({ value: e }) => {
860
+ const jo = ({ value: e }) => {
803
861
  const n = U(re), t = _(
804
862
  () => on(n, e),
805
863
  [n, e]
806
864
  );
807
865
  return /* @__PURE__ */ l.jsx(E, { size: "sm", children: t });
808
- }, wo = ({ value: e }) => {
809
- const n = U(re), t = _(() => Ce(n, e), [n, e]);
866
+ }, yo = ({ value: e }) => {
867
+ const n = U(re), t = _(() => we(n, e), [n, e]);
810
868
  return /* @__PURE__ */ l.jsx(E, { size: "sm", children: t });
811
- }, Di = ({ value: e }) => {
869
+ }, Ni = ({ value: e }) => {
812
870
  const n = U(re), [t, o] = _(() => {
813
- const r = Ce(n, e), i = e.getHours().toString().padStart(2, "0"), s = e.getMinutes().toString().padStart(2, "0"), a = e.getSeconds().toString().padStart(2, "0");
871
+ const r = we(n, e), i = e.getHours().toString().padStart(2, "0"), s = e.getMinutes().toString().padStart(2, "0"), a = e.getSeconds().toString().padStart(2, "0");
814
872
  return [r, `${i}:${s}:${a}`];
815
873
  }, [n, e]);
816
874
  return /* @__PURE__ */ l.jsx(E, { size: "sm", title: o, children: t });
817
- }, xo = {
875
+ }, _o = {
818
876
  yes: {
819
877
  lang2value: {
820
878
  en: "Yes",
@@ -829,28 +887,27 @@ const Co = ({ value: e }) => {
829
887
  },
830
888
  lang: "en"
831
889
  }
832
- }, Ro = ({ value: e }) => /* @__PURE__ */ l.jsx(
833
- de,
890
+ }, Fo = ({ value: e }) => /* @__PURE__ */ l.jsx(
891
+ ce,
834
892
  {
835
893
  checked: e,
836
- label: /* @__PURE__ */ l.jsx(N, { value: xo[e ? "yes" : "no"] }),
894
+ label: /* @__PURE__ */ l.jsx(b, { value: _o[e ? "yes" : "no"] }),
837
895
  readOnly: !0
838
896
  }
839
- ), yo = ({ property: e, value: n }) => {
840
- const t = e;
841
- if (se(t) || t.enumType === void 0)
897
+ ), Io = ({ property: e, value: n }) => {
898
+ if (se(e) || e.enumType === void 0)
842
899
  throw new Error(
843
900
  "Invalid usage of EnumDisplay. Expect a property of type enum"
844
901
  );
845
- return /* @__PURE__ */ l.jsx(E, { size: "sm", children: /* @__PURE__ */ l.jsx(N, { value: t.enumType.label[n] }) });
846
- }, gt = be({ EntityLink: () => null, entityRoutes: {} }), Vi = ({
902
+ return /* @__PURE__ */ l.jsx(E, { size: "sm", children: /* @__PURE__ */ l.jsx(b, { value: e.enumType.label[n] }) });
903
+ }, gt = De({ EntityLink: () => null, entityRoutes: {} }), ki = ({
847
904
  EntityLink: e,
848
905
  entityRoutes: n,
849
906
  children: t
850
907
  }) => /* @__PURE__ */ l.jsx(gt.Provider, { value: { EntityLink: e, entityRoutes: n }, children: t });
851
908
  function rn(e, n, t, o) {
852
909
  const r = e.getByName(n.targetClass), i = o[n.targetClass];
853
- De(() => {
910
+ Ve(() => {
854
911
  r.fetchByIds(t);
855
912
  }, [t]);
856
913
  const s = {};
@@ -892,38 +949,38 @@ const ft = oe(
892
949
  t,
893
950
  r
894
951
  );
895
- return /* @__PURE__ */ l.jsx(L, { gap: "xs", children: t.map((a, u) => {
896
- const c = i[a];
897
- return c === void 0 ? /* @__PURE__ */ l.jsx(E, { size: "sm", children: t }, a) : c === null ? /* @__PURE__ */ l.jsx(Qt, {}, a) : s === void 0 ? /* @__PURE__ */ l.jsx(E, { size: "sm", children: c.name }, u) : /* @__PURE__ */ l.jsx(
952
+ return /* @__PURE__ */ l.jsx(O, { gap: "xs", children: t.map((a, u) => {
953
+ const d = i[a];
954
+ return d === void 0 ? /* @__PURE__ */ l.jsx(E, { size: "sm", children: t }, a) : d === null ? /* @__PURE__ */ l.jsx(Qt, {}, a) : s === void 0 ? /* @__PURE__ */ l.jsx(E, { size: "sm", children: d.name }, u) : /* @__PURE__ */ l.jsx(
898
955
  o,
899
956
  {
900
957
  path: s,
901
958
  openInNewPage: !1,
902
- args: { id: c.id },
903
- children: c.name
959
+ args: { id: d.id },
960
+ children: d.name
904
961
  },
905
962
  u
906
963
  );
907
964
  }) });
908
965
  }
909
- ), ce = {
910
- string: _e,
911
- integer: _e,
912
- float: _e,
913
- boolean: Ro,
914
- "string[]": _e,
915
- enum: yo,
916
- datetime: Co,
917
- date: wo
966
+ ), ge = {
967
+ string: Fe,
968
+ integer: Fe,
969
+ float: Fe,
970
+ boolean: Fo,
971
+ "string[]": Fe,
972
+ enum: Io,
973
+ datetime: jo,
974
+ date: yo
918
975
  }, sn = ({
919
976
  property: e,
920
977
  value: n,
921
978
  onChange: t,
922
979
  freeze: o = !1
923
980
  }) => {
924
- const r = W(e);
981
+ const r = X(e);
925
982
  return /* @__PURE__ */ l.jsx(
926
- de,
983
+ ce,
927
984
  {
928
985
  ...r,
929
986
  id: e.name,
@@ -935,13 +992,13 @@ const ft = oe(
935
992
  disabled: o
936
993
  }
937
994
  );
938
- }, Me = ({
995
+ }, be = ({
939
996
  property: e,
940
997
  value: n,
941
998
  onChange: t,
942
999
  freeze: o = !1
943
1000
  }) => {
944
- const r = W(e);
1001
+ const r = X(e);
945
1002
  return /* @__PURE__ */ l.jsx(
946
1003
  J,
947
1004
  {
@@ -956,13 +1013,13 @@ const ft = oe(
956
1013
  disabled: o
957
1014
  }
958
1015
  );
959
- }, jo = {
1016
+ }, Po = {
960
1017
  lang2value: {
961
1018
  en: "The leading zero is not necessary in international phone number format. For example, if your phone number is 0123456789, you should enter it as 123-456-789.",
962
1019
  vi: "Số 0 đầu tiên không cần thiết trong định dạng điện thoại quốc tế. Ví dụ, nếu số điện thoại của bạn là 0123456789, bạn nên nhập nó là 123-456-789."
963
1020
  },
964
1021
  lang: "en"
965
- }, _o = {
1022
+ }, Eo = {
966
1023
  lang2value: {
967
1024
  en: "No valid country code found.",
968
1025
  vi: "Không tìm thấy mã quốc gia hợp lệ. "
@@ -971,65 +1028,65 @@ const ft = oe(
971
1028
  }, ue = {
972
1029
  84: {
973
1030
  name: "Vietnam",
974
- flags: [T.VN]
1031
+ flags: [A.VN]
975
1032
  },
976
1033
  1: {
977
1034
  name: "US, Canada",
978
- flags: [T.US, T.CA]
1035
+ flags: [A.US, A.CA]
979
1036
  },
980
1037
  61: {
981
1038
  name: "Australia",
982
- flags: [T.AU]
1039
+ flags: [A.AU]
983
1040
  },
984
1041
  81: {
985
1042
  name: "Japan",
986
- flags: [T.JP]
1043
+ flags: [A.JP]
987
1044
  },
988
1045
  44: {
989
1046
  name: "UK",
990
- flags: [T.UK]
1047
+ flags: [A.UK]
991
1048
  },
992
1049
  33: {
993
1050
  name: "France",
994
- flags: [T.FR]
1051
+ flags: [A.FR]
995
1052
  },
996
1053
  49: {
997
1054
  name: "Germany",
998
- flags: [T.DE]
1055
+ flags: [A.DE]
999
1056
  },
1000
1057
  91: {
1001
1058
  name: "India",
1002
- flags: [T.IN]
1059
+ flags: [A.IN]
1003
1060
  },
1004
1061
  55: {
1005
1062
  name: "Brazil",
1006
- flags: [T.BR]
1063
+ flags: [A.BR]
1007
1064
  },
1008
1065
  34: {
1009
1066
  name: "Spain",
1010
- flags: [T.ES]
1067
+ flags: [A.ES]
1011
1068
  },
1012
1069
  39: {
1013
1070
  name: "Italy",
1014
- flags: [T.IT]
1071
+ flags: [A.IT]
1015
1072
  },
1016
1073
  64: {
1017
1074
  name: "New Zealand",
1018
- flags: [T.NZ]
1075
+ flags: [A.NZ]
1019
1076
  },
1020
1077
  52: {
1021
1078
  name: "Mexico",
1022
- flags: [T.MX]
1079
+ flags: [A.MX]
1023
1080
  },
1024
1081
  86: {
1025
1082
  name: "China",
1026
- flags: [T.CN]
1083
+ flags: [A.CN]
1027
1084
  },
1028
1085
  855: {
1029
1086
  name: "Cambodia",
1030
- flags: [T.CAM]
1087
+ flags: [A.CAM]
1031
1088
  }
1032
- }, Fo = (e, n) => {
1089
+ }, $o = (e, n) => {
1033
1090
  if (e === "" || e === void 0)
1034
1091
  return { match: "84", remaining: "" };
1035
1092
  const t = e.replace(/[^\d]/g, ""), o = n.findLongestPrefix(t);
@@ -1039,14 +1096,14 @@ const ft = oe(
1039
1096
  }, Dt = ({ value: e }) => {
1040
1097
  const n = ue[e];
1041
1098
  if (n !== void 0)
1042
- return /* @__PURE__ */ l.jsxs(L, { gap: "xs", wrap: "nowrap", align: "center", children: [
1099
+ return /* @__PURE__ */ l.jsxs(O, { gap: "xs", wrap: "nowrap", align: "center", children: [
1043
1100
  /* @__PURE__ */ l.jsxs(E, { size: "sm", children: [
1044
1101
  "+",
1045
1102
  e
1046
1103
  ] }),
1047
- /* @__PURE__ */ l.jsx(L, { gap: "xs", wrap: "nowrap", children: n.flags.map((t, o) => /* @__PURE__ */ l.jsx(Qe, { flag: t }, o)) })
1104
+ /* @__PURE__ */ l.jsx(O, { gap: "xs", wrap: "nowrap", children: n.flags.map((t, o) => /* @__PURE__ */ l.jsx(Qe, { flag: t }, o)) })
1048
1105
  ] });
1049
- }, Io = ({
1106
+ }, Mo = ({
1050
1107
  value: e,
1051
1108
  onChange: n,
1052
1109
  error: t,
@@ -1056,80 +1113,80 @@ const ft = oe(
1056
1113
  }) => {
1057
1114
  let s = {}, a = {};
1058
1115
  i !== void 0 && (s = { "data-testid": `${i}_country_code` }, a = { "data-testid": i });
1059
- const [u, c] = M(""), [g, m] = M(!1), [p, d] = M(""), [f, h] = M(!1), v = _(() => {
1116
+ const [u, d] = M(""), [g, m] = M(!1), [p, c] = M(""), [f, h] = M(!1), v = _(() => {
1060
1117
  const F = new Zt();
1061
- return Object.keys(ue).forEach((V) => {
1062
- F.insert(V);
1118
+ return Object.keys(ue).forEach((T) => {
1119
+ F.insert(T);
1063
1120
  }), F;
1064
1121
  }, [ue]), { rawInput: S } = _(() => {
1065
1122
  try {
1066
- const { match: F, remaining: V } = Fo(
1123
+ const { match: F, remaining: T } = $o(
1067
1124
  e,
1068
1125
  v
1069
1126
  );
1070
- return d(F), h(!1), {
1071
- rawInput: V
1127
+ return c(F), h(!1), {
1128
+ rawInput: T
1072
1129
  };
1073
1130
  } catch {
1074
- return h(!0), d(""), {
1131
+ return h(!0), c(""), {
1075
1132
  rawInput: e
1076
1133
  };
1077
1134
  }
1078
1135
  }, [e]), R = qt({
1079
1136
  onDropdownClose: () => {
1080
- R.resetSelectedOption(), c("");
1137
+ R.resetSelectedOption(), d("");
1081
1138
  },
1082
1139
  onDropdownOpen: () => {
1083
1140
  R.updateSelectedOptionIndex("active");
1084
1141
  }
1085
- }), j = _(() => Object.keys(ue), [ue]), I = (F, V) => {
1142
+ }), y = _(() => Object.keys(ue), [ue]), I = (F, T) => {
1086
1143
  if (F === void 0)
1087
- return `+${V}`;
1088
- const G = F.replace(/[^\d]/g, "");
1089
- return G.length === 0 ? `+${V}` : G.startsWith("0") ? (m(!0), `+${V}${G}`) : (m(!1), `+${V}${G}`);
1090
- }, P = _(() => j.filter((F) => ue[F].name.toLowerCase().includes(u.toLowerCase()) || F.includes(u)), [u, j]), k = _(() => P.map((F, V) => /* @__PURE__ */ l.jsx(z.Option, { value: F, children: /* @__PURE__ */ l.jsx(Dt, { value: F }) }, V)), [P]);
1144
+ return `+${T}`;
1145
+ const H = F.replace(/[^\d]/g, "");
1146
+ return H.length === 0 ? `+${T}` : H.startsWith("0") ? (m(!0), `+${T}${H}`) : (m(!1), `+${T}${H}`);
1147
+ }, P = _(() => y.filter((F) => ue[F].name.toLowerCase().includes(u.toLowerCase()) || F.includes(u)), [u, y]), k = _(() => P.map((F, T) => /* @__PURE__ */ l.jsx(G.Option, { value: F, children: /* @__PURE__ */ l.jsx(Dt, { value: F }) }, T)), [P]);
1091
1148
  return /* @__PURE__ */ l.jsxs("div", { children: [
1092
- /* @__PURE__ */ l.jsx(A, { gutter: "xs", children: /* @__PURE__ */ l.jsx(A.Col, { children: /* @__PURE__ */ l.jsxs(L, { gap: 5, children: [
1149
+ /* @__PURE__ */ l.jsx(N, { gutter: "xs", children: /* @__PURE__ */ l.jsx(N.Col, { children: /* @__PURE__ */ l.jsxs(O, { gap: 5, children: [
1093
1150
  /* @__PURE__ */ l.jsxs(
1094
- z,
1151
+ G,
1095
1152
  {
1096
1153
  store: R,
1097
1154
  position: "top-start",
1098
1155
  onOptionSubmit: (F) => {
1099
- c(""), R.closeDropdown(), n({
1156
+ d(""), R.closeDropdown(), n({
1100
1157
  target: { value: I(S, F) }
1101
1158
  });
1102
1159
  },
1103
1160
  disabled: r,
1104
1161
  children: [
1105
- /* @__PURE__ */ l.jsx(z.Target, { children: /* @__PURE__ */ l.jsx(
1162
+ /* @__PURE__ */ l.jsx(G.Target, { children: /* @__PURE__ */ l.jsx(
1106
1163
  kn,
1107
1164
  {
1108
1165
  ...s,
1109
1166
  component: "button",
1110
1167
  type: "button",
1111
1168
  pointer: !0,
1112
- rightSection: /* @__PURE__ */ l.jsx(z.Chevron, {}),
1169
+ rightSection: /* @__PURE__ */ l.jsx(G.Chevron, {}),
1113
1170
  onClick: () => R.toggleDropdown(),
1114
1171
  rightSectionPointerEvents: "none",
1115
1172
  disabled: r,
1116
1173
  children: /* @__PURE__ */ l.jsx(Dt, { value: p })
1117
1174
  }
1118
1175
  ) }),
1119
- /* @__PURE__ */ l.jsxs(z.Dropdown, { children: [
1176
+ /* @__PURE__ */ l.jsxs(G.Dropdown, { children: [
1120
1177
  /* @__PURE__ */ l.jsx(
1121
- z.Search,
1178
+ G.Search,
1122
1179
  {
1123
1180
  leftSection: /* @__PURE__ */ l.jsx(ut, { size: 14, stroke: 1.5 }),
1124
1181
  placeholder: ".....",
1125
1182
  value: u,
1126
1183
  onChange: (F) => {
1127
- c(F.currentTarget.value);
1184
+ d(F.currentTarget.value);
1128
1185
  },
1129
1186
  disabled: r
1130
1187
  }
1131
1188
  ),
1132
- /* @__PURE__ */ l.jsx(z.Options, { children: k.length > 0 ? k : /* @__PURE__ */ l.jsx(z.Empty, { children: /* @__PURE__ */ l.jsx(E, { size: "sm", children: "Nothing found" }) }) })
1189
+ /* @__PURE__ */ l.jsx(G.Options, { children: k.length > 0 ? k : /* @__PURE__ */ l.jsx(G.Empty, { children: /* @__PURE__ */ l.jsx(E, { size: "sm", children: "Nothing found" }) }) })
1133
1190
  ] })
1134
1191
  ]
1135
1192
  }
@@ -1156,12 +1213,12 @@ const ft = oe(
1156
1213
  value: S,
1157
1214
  type: "phone_number",
1158
1215
  onAccept: (F) => {
1159
- const V = F.replace(/[^\d]/g, ""), G = I(V, p);
1160
- G !== e && n({
1161
- target: { value: G }
1216
+ const T = F.replace(/[^\d]/g, ""), H = I(T, p);
1217
+ H !== e && n({
1218
+ target: { value: H }
1162
1219
  });
1163
1220
  },
1164
- component: so,
1221
+ component: lo,
1165
1222
  mask: "000-000-0000",
1166
1223
  error: t,
1167
1224
  flex: 1,
@@ -1169,16 +1226,16 @@ const ft = oe(
1169
1226
  }
1170
1227
  )
1171
1228
  ] }) }) }),
1172
- (g || f || t && typeof t == "string") && /* @__PURE__ */ l.jsx(A, { gutter: "xs", children: /* @__PURE__ */ l.jsx(A.Col, { children: /* @__PURE__ */ l.jsx(J.Error, { children: g ? /* @__PURE__ */ l.jsx(N, { value: jo }) : f ? /* @__PURE__ */ l.jsx(N, { value: _o }) : t }) }) })
1229
+ (g || f || t && typeof t == "string") && /* @__PURE__ */ l.jsx(N, { gutter: "xs", children: /* @__PURE__ */ l.jsx(N.Col, { children: /* @__PURE__ */ l.jsx(J.Error, { children: g ? /* @__PURE__ */ l.jsx(b, { value: Po }) : f ? /* @__PURE__ */ l.jsx(b, { value: Eo }) : t }) }) })
1173
1230
  ] });
1174
- }, Se = ({
1231
+ }, ve = ({
1175
1232
  property: e,
1176
1233
  error: n,
1177
1234
  value: t,
1178
1235
  onChange: o,
1179
1236
  freeze: r = !1
1180
1237
  }) => {
1181
- const i = W(e), [s, a] = _(() => e.constraints.includes("password") ? ["password", Bt] : e.constraints.includes("phone_number") ? ["phone_number", Io] : [e.constraints.includes("email") ? "email" : e.constraints.includes("url") ? "url" : "text", J], [e.constraints]);
1238
+ const i = X(e), [s, a] = _(() => e.constraints.includes("password") ? ["password", Bt] : e.constraints.includes("phone_number") ? ["phone_number", Mo] : [e.constraints.includes("email") ? "email" : e.constraints.includes("url") ? "url" : "text", J], [e.constraints]);
1182
1239
  return /* @__PURE__ */ l.jsx(
1183
1240
  a,
1184
1241
  {
@@ -1191,13 +1248,13 @@ const ft = oe(
1191
1248
  disabled: r
1192
1249
  }
1193
1250
  );
1194
- }, Po = ({
1251
+ }, bo = ({
1195
1252
  property: e,
1196
1253
  value: n,
1197
1254
  onChange: t,
1198
1255
  freeze: o = !1
1199
1256
  }) => {
1200
- const r = W(e);
1257
+ const r = X(e);
1201
1258
  return /* @__PURE__ */ l.jsx(
1202
1259
  Je,
1203
1260
  {
@@ -1217,69 +1274,69 @@ const ft = oe(
1217
1274
  disabled: o
1218
1275
  }
1219
1276
  );
1220
- }, Eo = ({
1277
+ }, Do = ({
1221
1278
  property: e,
1222
1279
  value: n,
1223
1280
  onChange: t,
1224
1281
  freeze: o = !1
1225
1282
  }) => {
1226
- const r = U(re), i = W(e);
1283
+ const r = U(re), i = X(e);
1227
1284
  if (se(e) || e.enumType === void 0)
1228
1285
  throw new Error(
1229
1286
  "Invalid usage of EnumInput. Expect a property of type enum"
1230
1287
  );
1231
1288
  const s = e.enumType, [a, u] = _(() => {
1232
- const c = {}, g = Object.entries(s.label).map(
1289
+ const d = {}, g = Object.entries(s.label).map(
1233
1290
  ([m, p]) => {
1234
- const d = isNaN(Number(m)) ? m : Number(m);
1235
- return c[m] = d, {
1291
+ const c = isNaN(Number(m)) ? m : Number(m);
1292
+ return d[m] = c, {
1236
1293
  value: m,
1237
- label: he(r, p)
1294
+ label: Se(r, p)
1238
1295
  };
1239
1296
  }
1240
1297
  );
1241
- return [c, g];
1298
+ return [d, g];
1242
1299
  }, [r, s]);
1243
1300
  return /* @__PURE__ */ l.jsx(
1244
- On,
1301
+ Ln,
1245
1302
  {
1246
1303
  ...i,
1247
1304
  data: u,
1248
1305
  value: n === void 0 ? null : String(n),
1249
- onChange: (c) => {
1250
- if (c === null) {
1306
+ onChange: (d) => {
1307
+ if (d === null) {
1251
1308
  t(void 0);
1252
1309
  return;
1253
1310
  }
1254
- t(a[c]);
1311
+ t(a[d]);
1255
1312
  },
1256
1313
  disabled: o,
1257
1314
  allowDeselect: !e.isRequired
1258
1315
  }
1259
1316
  );
1260
- }, $o = {
1317
+ }, Vo = {
1261
1318
  lang2value: {
1262
1319
  en: "Confirm",
1263
1320
  vi: "Xác Nhận"
1264
1321
  },
1265
1322
  lang: "en"
1266
- }, Mo = new ro(
1323
+ }, To = new io(
1267
1324
  "confirmation.valuesDoNotMatch"
1268
- ), Ti = ({ property: e }) => /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
1269
- /* @__PURE__ */ l.jsx(N, { value: $o }),
1325
+ ), Li = ({ property: e }) => /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
1326
+ /* @__PURE__ */ l.jsx(b, { value: Vo }),
1270
1327
  " ",
1271
- /* @__PURE__ */ l.jsx(N, { value: e.label })
1272
- ] }), Ai = ({
1328
+ /* @__PURE__ */ l.jsx(b, { value: e.label })
1329
+ ] }), Oi = ({
1273
1330
  property: e,
1274
1331
  error: n,
1275
1332
  value: t,
1276
1333
  onChange: o,
1277
1334
  freeze: r = !1
1278
1335
  }) => {
1279
- const i = W(e, "confirm"), [s, a] = M(""), [u, c] = M(!1), [g, m] = _(() => e.constraints.includes("password") ? ["password", Bt] : ["text", J], [e.constraints]), p = _(() => {
1336
+ const i = X(e, "confirm"), [s, a] = M(""), [u, d] = M(!1), [g, m] = _(() => e.constraints.includes("password") ? ["password", Bt] : ["text", J], [e.constraints]), p = _(() => {
1280
1337
  if (u && s !== t)
1281
- return Mo.t({ args: { name: e.label } });
1282
- }, [u, s, t, e.label]), d = n || p;
1338
+ return To.t({ args: { name: e.label } });
1339
+ }, [u, s, t, e.label]), c = n || p;
1283
1340
  return /* @__PURE__ */ l.jsx(
1284
1341
  m,
1285
1342
  {
@@ -1289,14 +1346,14 @@ const ft = oe(
1289
1346
  type: g,
1290
1347
  onChange: (f) => {
1291
1348
  const h = f.target.value;
1292
- a(h), c(!0), o(h);
1349
+ a(h), d(!0), o(h);
1293
1350
  },
1294
- error: d,
1351
+ error: c,
1295
1352
  disabled: r
1296
1353
  }
1297
1354
  );
1298
1355
  };
1299
- function bo(e, n) {
1356
+ function Ao(e, n) {
1300
1357
  const [t, o] = M(""), [r, i] = M([]);
1301
1358
  return {
1302
1359
  data: r,
@@ -1315,7 +1372,7 @@ function bo(e, n) {
1315
1372
  table: e.getByName(n.targetClass)
1316
1373
  };
1317
1374
  }
1318
- const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", children: e.name }), ln = oe(
1375
+ const No = (e) => e.name, ko = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", children: e.name }), ln = oe(
1319
1376
  (e) => /* @__PURE__ */ l.jsx("h1", { children: "SingleForeignKey" })
1320
1377
  ), an = oe(
1321
1378
  ({
@@ -1325,40 +1382,40 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1325
1382
  onChange: o,
1326
1383
  freeze: r = !1
1327
1384
  }) => {
1328
- const { table: i, data: s, query: a, setQuery: u } = bo(
1385
+ const { table: i, data: s, query: a, setQuery: u } = Ao(
1329
1386
  e,
1330
1387
  n
1331
1388
  );
1332
- return /* @__PURE__ */ l.jsxs(X, { gap: "sm", children: [
1389
+ return /* @__PURE__ */ l.jsxs(Y, { gap: "sm", children: [
1333
1390
  /* @__PURE__ */ l.jsx(
1334
- To,
1391
+ Lo,
1335
1392
  {
1336
1393
  property: n,
1337
1394
  query: a,
1338
1395
  setQuery: u,
1339
1396
  data: s,
1340
- onSelect: (c) => {
1341
- t.includes(c) || o([...t, c]);
1397
+ onSelect: (d) => {
1398
+ t.includes(d) || o([...t, d]);
1342
1399
  },
1343
- renderOption: Do,
1400
+ renderOption: No,
1344
1401
  isIdInteger: n.datatype === "integer",
1345
1402
  freeze: r
1346
1403
  }
1347
1404
  ),
1348
1405
  /* @__PURE__ */ l.jsx(
1349
- Ao,
1406
+ Oo,
1350
1407
  {
1351
- items: t.map((c) => i.get(c)).filter((c) => c != null),
1352
- onDelete: (c) => {
1353
- o(t.filter((g) => g !== c.id));
1408
+ items: t.map((d) => i.get(d)).filter((d) => d != null),
1409
+ onDelete: (d) => {
1410
+ o(t.filter((g) => g !== d.id));
1354
1411
  },
1355
- render: Vo,
1412
+ render: ko,
1356
1413
  freeze: r
1357
1414
  }
1358
1415
  )
1359
1416
  ] });
1360
1417
  }
1361
- ), To = ({
1418
+ ), Lo = ({
1362
1419
  property: e,
1363
1420
  data: n,
1364
1421
  onSelect: t,
@@ -1368,24 +1425,24 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1368
1425
  setQuery: s,
1369
1426
  freeze: a = !1
1370
1427
  }) => {
1371
- const u = W(e), c = qt({
1372
- onDropdownClose: () => c.resetSelectedOption()
1428
+ const u = X(e), d = qt({
1429
+ onDropdownClose: () => d.resetSelectedOption()
1373
1430
  }), g = _(() => n.map((m) => (
1374
1431
  // value has to be a string
1375
- /* @__PURE__ */ l.jsx(z.Option, { value: m.id.toString(), children: o(m) }, m.id)
1432
+ /* @__PURE__ */ l.jsx(G.Option, { value: m.id.toString(), children: o(m) }, m.id)
1376
1433
  )), [n]);
1377
1434
  return /* @__PURE__ */ l.jsxs(
1378
- z,
1435
+ G,
1379
1436
  {
1380
- store: c,
1437
+ store: d,
1381
1438
  onOptionSubmit: (m) => {
1382
- t(r ? parseInt(m) : m), s(""), c.closeDropdown();
1439
+ t(r ? parseInt(m) : m), s(""), d.closeDropdown();
1383
1440
  },
1384
1441
  offset: 4,
1385
1442
  shadow: "sm",
1386
1443
  disabled: a,
1387
1444
  children: [
1388
- /* @__PURE__ */ l.jsx(z.Target, { children: /* @__PURE__ */ l.jsx(
1445
+ /* @__PURE__ */ l.jsx(G.Target, { children: /* @__PURE__ */ l.jsx(
1389
1446
  J,
1390
1447
  {
1391
1448
  ...u,
@@ -1393,18 +1450,18 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1393
1450
  pointer: !a,
1394
1451
  rightSection: /* @__PURE__ */ l.jsx(ut, { size: 16, stroke: 1.5 }),
1395
1452
  rightSectionPointerEvents: "none",
1396
- onClick: () => c.toggleDropdown(),
1453
+ onClick: () => d.toggleDropdown(),
1397
1454
  placeholder: "Type to search...",
1398
1455
  value: i,
1399
1456
  onChange: (m) => s(m.currentTarget.value),
1400
1457
  disabled: a
1401
1458
  }
1402
1459
  ) }),
1403
- /* @__PURE__ */ l.jsx(z.Dropdown, { children: /* @__PURE__ */ l.jsx(z.Options, { children: g.length === 0 ? /* @__PURE__ */ l.jsx(z.Empty, { children: "Nothing found" }) : g }) })
1460
+ /* @__PURE__ */ l.jsx(G.Dropdown, { children: /* @__PURE__ */ l.jsx(G.Options, { children: g.length === 0 ? /* @__PURE__ */ l.jsx(G.Empty, { children: "Nothing found" }) : g }) })
1404
1461
  ]
1405
1462
  }
1406
1463
  );
1407
- }, Ao = ({
1464
+ }, Oo = ({
1408
1465
  items: e,
1409
1466
  onDelete: n,
1410
1467
  render: t,
@@ -1415,9 +1472,9 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1415
1472
  for (let s = 0; s < e.length; s++) {
1416
1473
  const a = e[s];
1417
1474
  i.push(
1418
- /* @__PURE__ */ l.jsxs(L, { justify: "space-between", p: "sm", children: [
1475
+ /* @__PURE__ */ l.jsxs(O, { justify: "space-between", p: "sm", children: [
1419
1476
  t(a),
1420
- !o && /* @__PURE__ */ l.jsx(Ln, { size: "sm", onClick: () => n(a) })
1477
+ !o && /* @__PURE__ */ l.jsx(On, { size: "sm", onClick: () => n(a) })
1421
1478
  ] }, s)
1422
1479
  ), s < e.length - 1 && i.push(/* @__PURE__ */ l.jsx(zn, {}, `divider-${s}`));
1423
1480
  }
@@ -1425,8 +1482,8 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1425
1482
  }, [e, o]);
1426
1483
  if (r.length !== 0)
1427
1484
  return /* @__PURE__ */ l.jsx(ie, { bd: "1px solid #ddd", children: r });
1428
- }, No = ({ property: e, value: n, onChange: t, freeze: o = !1 }) => {
1429
- const r = W(e, "start"), i = W(e, "end");
1485
+ }, zo = ({ property: e, value: n, onChange: t, freeze: o = !1 }) => {
1486
+ const r = X(e, "start"), i = X(e, "end");
1430
1487
  return /* @__PURE__ */ l.jsxs(B, { gap: "sm", justify: "space-between", direction: "row", align: "center", children: [
1431
1488
  /* @__PURE__ */ l.jsx(
1432
1489
  Je,
@@ -1446,7 +1503,7 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1446
1503
  disabled: o,
1447
1504
  popoverProps: { withinPortal: !1 },
1448
1505
  flex: 1,
1449
- leftSection: /* @__PURE__ */ l.jsx($e, { size: 16, stroke: 1.5 })
1506
+ leftSection: /* @__PURE__ */ l.jsx(Me, { size: 16, stroke: 1.5 })
1450
1507
  }
1451
1508
  ),
1452
1509
  /* @__PURE__ */ l.jsx("span", { style: { flexGrow: 0 }, children: "–" }),
@@ -1468,12 +1525,12 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1468
1525
  disabled: o,
1469
1526
  popoverProps: { withinPortal: !1 },
1470
1527
  flex: 1,
1471
- leftSection: /* @__PURE__ */ l.jsx($e, { size: 16, stroke: 1.5 })
1528
+ leftSection: /* @__PURE__ */ l.jsx(Me, { size: 16, stroke: 1.5 })
1472
1529
  }
1473
1530
  )
1474
1531
  ] });
1475
- }, ko = ({ property: e, value: n, onChange: t, freeze: o = !1 }) => {
1476
- const r = W(e, "start"), i = W(e, "end");
1532
+ }, Go = ({ property: e, value: n, onChange: t, freeze: o = !1 }) => {
1533
+ const r = X(e, "start"), i = X(e, "end");
1477
1534
  return /* @__PURE__ */ l.jsxs(B, { gap: "sm", justify: "space-between", direction: "row", align: "center", children: [
1478
1535
  /* @__PURE__ */ l.jsx(
1479
1536
  Pt,
@@ -1494,7 +1551,7 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1494
1551
  popoverProps: { withinPortal: !1 },
1495
1552
  flex: 1,
1496
1553
  withSeconds: !1,
1497
- leftSection: /* @__PURE__ */ l.jsx($e, { size: 16, stroke: 1.5 })
1554
+ leftSection: /* @__PURE__ */ l.jsx(Me, { size: 16, stroke: 1.5 })
1498
1555
  }
1499
1556
  ),
1500
1557
  /* @__PURE__ */ l.jsx("span", { style: { flexGrow: 0 }, children: "–" }),
@@ -1517,21 +1574,21 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1517
1574
  popoverProps: { withinPortal: !1 },
1518
1575
  flex: 1,
1519
1576
  withSeconds: !1,
1520
- leftSection: /* @__PURE__ */ l.jsx($e, { size: 16, stroke: 1.5 })
1577
+ leftSection: /* @__PURE__ */ l.jsx(Me, { size: 16, stroke: 1.5 })
1521
1578
  }
1522
1579
  )
1523
1580
  ] });
1524
1581
  }, Vt = {
1525
- integer: Me,
1526
- float: Me,
1527
- string: Se,
1582
+ integer: be,
1583
+ float: be,
1584
+ string: ve,
1528
1585
  boolean: sn,
1529
- "string[]": Se,
1530
- enum: Eo,
1531
- date: Po
1532
- }, Oo = "_requiredLabelLeft_l5p83_1", Lo = "_requiredLabelRight_l5p83_11", Tt = {
1533
- requiredLabelLeft: Oo,
1534
- requiredLabelRight: Lo
1586
+ "string[]": ve,
1587
+ enum: Do,
1588
+ date: bo
1589
+ }, Ho = "_requiredLabelLeft_l5p83_1", qo = "_requiredLabelRight_l5p83_11", Tt = {
1590
+ requiredLabelLeft: Ho,
1591
+ requiredLabelRight: qo
1535
1592
  }, un = ({
1536
1593
  label: e,
1537
1594
  name: n,
@@ -1541,7 +1598,7 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1541
1598
  align: i = "left"
1542
1599
  }) => {
1543
1600
  const s = t ? i === "left" ? Tt.requiredLabelRight : Tt.requiredLabelLeft : "";
1544
- return /* @__PURE__ */ l.jsx(B, { align: "center", h: 36, children: /* @__PURE__ */ l.jsx("label", { htmlFor: n, style: r, children: /* @__PURE__ */ l.jsxs(L, { gap: 4, children: [
1601
+ return /* @__PURE__ */ l.jsx(B, { align: "center", h: 36, children: /* @__PURE__ */ l.jsx("label", { htmlFor: n, style: r, children: /* @__PURE__ */ l.jsxs(O, { gap: 4, children: [
1545
1602
  /* @__PURE__ */ l.jsx(E, { size: "sm", className: s, children: e }),
1546
1603
  o !== void 0 && /* @__PURE__ */ l.jsx(Ut, { label: o, withArrow: !0, children: /* @__PURE__ */ l.jsx(
1547
1604
  Wt,
@@ -1555,7 +1612,7 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1555
1612
  }, dn = {
1556
1613
  type: "vertical",
1557
1614
  helpAlwaysVisible: !1
1558
- }, zo = oe(
1615
+ }, Bo = oe(
1559
1616
  ({
1560
1617
  store: e,
1561
1618
  record: n,
@@ -1567,7 +1624,7 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1567
1624
  onChange: a,
1568
1625
  visible: u
1569
1626
  }) => {
1570
- const [c, g] = M(void 0);
1627
+ const [d, g] = M(void 0);
1571
1628
  if (u !== void 0 && !u(n))
1572
1629
  return /* @__PURE__ */ l.jsx("div", {});
1573
1630
  const m = dt(n, t);
@@ -1579,9 +1636,9 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1579
1636
  const h = n.toDraft();
1580
1637
  Ze(h, t, p), e.setDraft(h);
1581
1638
  }
1582
- const d = t.validator(p);
1583
- d.isValid ? g(void 0) : g(
1584
- (f = d.errorMessage) == null ? void 0 : f.t({ args: { name: t.label } })
1639
+ const c = t.validator(p);
1640
+ c.isValid ? g(void 0) : g(
1641
+ (f = c.errorMessage) == null ? void 0 : f.t({ args: { name: t.label } })
1585
1642
  );
1586
1643
  }), /* @__PURE__ */ l.jsx(
1587
1644
  cn,
@@ -1592,7 +1649,7 @@ const Do = (e) => e.name, Vo = (e) => /* @__PURE__ */ l.jsx(E, { size: "sm", chi
1592
1649
  InputComponent: r,
1593
1650
  freeze: i,
1594
1651
  value: m,
1595
- error: c,
1652
+ error: d,
1596
1653
  label: s,
1597
1654
  onChange: a
1598
1655
  }
@@ -1610,10 +1667,10 @@ function cn({
1610
1667
  label: a,
1611
1668
  onChange: u
1612
1669
  }) {
1613
- return Go(n) ? /* @__PURE__ */ l.jsxs(X, { gap: 5, children: [
1614
- /* @__PURE__ */ l.jsxs(A, { gutter: "sm", children: [
1670
+ return Uo(n) ? /* @__PURE__ */ l.jsxs(Y, { gap: 5, children: [
1671
+ /* @__PURE__ */ l.jsxs(N, { gutter: "sm", children: [
1615
1672
  /* @__PURE__ */ l.jsx(
1616
- A.Col,
1673
+ N.Col,
1617
1674
  {
1618
1675
  span: n.labelCol,
1619
1676
  style: {
@@ -1623,16 +1680,16 @@ function cn({
1623
1680
  children: /* @__PURE__ */ l.jsx(
1624
1681
  un,
1625
1682
  {
1626
- label: /* @__PURE__ */ l.jsx(N, { value: t.label }),
1683
+ label: /* @__PURE__ */ l.jsx(b, { value: t.label }),
1627
1684
  name: t.name,
1628
1685
  required: t.isRequired,
1629
- tooltip: t.description !== void 0 ? /* @__PURE__ */ l.jsx(N, { value: t.description }) : void 0,
1686
+ tooltip: t.description !== void 0 ? /* @__PURE__ */ l.jsx(b, { value: t.description }) : void 0,
1630
1687
  align: n.align
1631
1688
  }
1632
1689
  )
1633
1690
  }
1634
1691
  ),
1635
- /* @__PURE__ */ l.jsx(A.Col, { span: n.itemCol, children: /* @__PURE__ */ l.jsx(
1692
+ /* @__PURE__ */ l.jsx(N.Col, { span: n.itemCol, children: /* @__PURE__ */ l.jsx(
1636
1693
  o,
1637
1694
  {
1638
1695
  db: e,
@@ -1644,16 +1701,16 @@ function cn({
1644
1701
  }
1645
1702
  ) })
1646
1703
  ] }),
1647
- s !== void 0 && /* @__PURE__ */ l.jsxs(A, { gutter: "sm", children: [
1648
- /* @__PURE__ */ l.jsx(A.Col, { span: n.labelCol }),
1649
- /* @__PURE__ */ l.jsx(A.Col, { span: n.itemCol, children: /* @__PURE__ */ l.jsx(J.Error, { children: s }) })
1704
+ s !== void 0 && /* @__PURE__ */ l.jsxs(N, { gutter: "sm", children: [
1705
+ /* @__PURE__ */ l.jsx(N.Col, { span: n.labelCol }),
1706
+ /* @__PURE__ */ l.jsx(N.Col, { span: n.itemCol, children: /* @__PURE__ */ l.jsx(J.Error, { children: s }) })
1650
1707
  ] })
1651
- ] }) : (a === void 0 && (a = /* @__PURE__ */ l.jsx(N, { value: t.label })), !n.helpAlwaysVisible && t.description !== void 0 && (a = /* @__PURE__ */ l.jsxs(L, { gap: 4, style: { display: "inline-flex" }, children: [
1708
+ ] }) : (a === void 0 && (a = /* @__PURE__ */ l.jsx(b, { value: t.label })), !n.helpAlwaysVisible && t.description !== void 0 && (a = /* @__PURE__ */ l.jsxs(O, { gap: 4, style: { display: "inline-flex" }, children: [
1652
1709
  a,
1653
1710
  /* @__PURE__ */ l.jsx(
1654
1711
  Ut,
1655
1712
  {
1656
- label: /* @__PURE__ */ l.jsx(N, { value: t.description }),
1713
+ label: /* @__PURE__ */ l.jsx(b, { value: t.description }),
1657
1714
  withArrow: !0,
1658
1715
  children: /* @__PURE__ */ l.jsx(
1659
1716
  Wt,
@@ -1669,7 +1726,7 @@ function cn({
1669
1726
  J.Wrapper,
1670
1727
  {
1671
1728
  label: a,
1672
- description: n.helpAlwaysVisible && t.description !== void 0 ? /* @__PURE__ */ l.jsx(N, { value: t.description }) : void 0,
1729
+ description: n.helpAlwaysVisible && t.description !== void 0 ? /* @__PURE__ */ l.jsx(b, { value: t.description }) : void 0,
1673
1730
  required: t.isRequired,
1674
1731
  children: /* @__PURE__ */ l.jsx(
1675
1732
  o,
@@ -1685,11 +1742,11 @@ function cn({
1685
1742
  }
1686
1743
  ));
1687
1744
  }
1688
- function Go(e) {
1745
+ function Uo(e) {
1689
1746
  return e.type === "horizontal";
1690
1747
  }
1691
- const Ni = 12, ki = (e) => {
1692
- const n = e.schema, t = _(() => e.fieldGroups.map((o, r) => Ho(
1748
+ const zi = 12, Gi = (e) => {
1749
+ const n = e.schema, t = _(() => e.fieldGroups.map((o, r) => Yo(
1693
1750
  n,
1694
1751
  e.store,
1695
1752
  e.record,
@@ -1703,10 +1760,10 @@ const Ni = 12, ki = (e) => {
1703
1760
  onSubmit: e.onSubmit === void 0 ? void 0 : (o) => {
1704
1761
  o.preventDefault(), e.onSubmit !== void 0 && Jt(e.record) && e.record.stale && e.record.isValid() && e.onSubmit(e.record);
1705
1762
  },
1706
- children: /* @__PURE__ */ l.jsxs(X, { gap: "sm", className: e.className, style: e.styles, children: [
1763
+ children: /* @__PURE__ */ l.jsxs(Y, { gap: "sm", className: e.className, style: e.styles, children: [
1707
1764
  t,
1708
- /* @__PURE__ */ l.jsx(L, { gap: "sm", justify: e.actionsAlign, children: e.actions.map((o, r) => /* @__PURE__ */ l.jsx(
1709
- q,
1765
+ /* @__PURE__ */ l.jsx(O, { gap: "sm", justify: e.actionsAlign, children: e.actions.map((o, r) => /* @__PURE__ */ l.jsx(
1766
+ z,
1710
1767
  {
1711
1768
  variant: o.variant,
1712
1769
  onClick: () => {
@@ -1721,20 +1778,20 @@ const Ni = 12, ki = (e) => {
1721
1778
  }
1722
1779
  );
1723
1780
  };
1724
- function Ho(e, n, t, o, r, i) {
1725
- var c, g;
1781
+ function Yo(e, n, t, o, r, i) {
1782
+ var d, g;
1726
1783
  const s = r.fields, a = [];
1727
1784
  for (let m = 0; m < s.length; m++) {
1728
1785
  const p = [];
1729
- for (let d = 0; d < s[m].length; d++) {
1730
- const f = s[m][d];
1786
+ for (let c = 0; c < s[m].length; c++) {
1787
+ const f = s[m][c];
1731
1788
  let h, v = {};
1732
1789
  if (typeof f == "function")
1733
1790
  h = f(n, t);
1734
1791
  else {
1735
1792
  let S;
1736
- typeof f == "object" && "prop" in f ? (S = f.prop instanceof Y ? f.prop : e.allProperties[f.prop], f.args !== void 0 && (v = f.args)) : S = f instanceof Y ? f : e.allProperties[f], h = /* @__PURE__ */ l.jsx(
1737
- zo,
1793
+ typeof f == "object" && "prop" in f ? (S = f.prop instanceof W ? f.prop : e.allProperties[f.prop], f.args !== void 0 && (v = f.args)) : S = f instanceof W ? f : e.allProperties[f], h = /* @__PURE__ */ l.jsx(
1794
+ Bo,
1738
1795
  {
1739
1796
  store: n,
1740
1797
  record: t,
@@ -1752,11 +1809,11 @@ function Ho(e, n, t, o, r, i) {
1752
1809
  /* @__PURE__ */ l.jsx(
1753
1810
  nn,
1754
1811
  {
1755
- span: (c = v.colsize) == null ? void 0 : c.span,
1812
+ span: (d = v.colsize) == null ? void 0 : d.span,
1756
1813
  grow: (g = v.colsize) == null ? void 0 : g.grow,
1757
1814
  children: h
1758
1815
  },
1759
- `${m}-${d}`
1816
+ `${m}-${c}`
1760
1817
  )
1761
1818
  );
1762
1819
  }
@@ -1764,13 +1821,13 @@ function Ho(e, n, t, o, r, i) {
1764
1821
  /* @__PURE__ */ l.jsx(tn, { children: p }, m)
1765
1822
  );
1766
1823
  }
1767
- const u = /* @__PURE__ */ l.jsx(X, { gap: "sm", children: a }, o);
1768
- return r.name !== void 0 ? /* @__PURE__ */ l.jsx(Kt, { legend: r.name, children: u }, o) : u;
1824
+ const u = /* @__PURE__ */ l.jsx(Y, { gap: "sm", children: a }, o);
1825
+ return r.name !== void 0 ? /* @__PURE__ */ l.jsx(Yt, { legend: r.name, children: u }, o) : u;
1769
1826
  }
1770
1827
  function gn(e, n) {
1771
1828
  if (n !== void 0)
1772
1829
  return n;
1773
- const t = e instanceof Y ? e.leafProperty : e;
1830
+ const t = e instanceof W ? e.leafProperty : e;
1774
1831
  if (se(t))
1775
1832
  return t.cardinality === "N:N" || t.cardinality === "1:N" ? an : ln;
1776
1833
  if (Vt[t.datatype] === void 0)
@@ -1779,7 +1836,7 @@ function gn(e, n) {
1779
1836
  );
1780
1837
  return Vt[t.datatype];
1781
1838
  }
1782
- const qo = oe(
1839
+ const Ko = oe(
1783
1840
  ({
1784
1841
  db: e,
1785
1842
  record: n,
@@ -1791,16 +1848,16 @@ const qo = oe(
1791
1848
  onChange: a,
1792
1849
  visible: u
1793
1850
  }) => {
1794
- const [c, g] = M(void 0);
1851
+ const [d, g] = M(void 0);
1795
1852
  if (u !== void 0 && !u(n))
1796
1853
  return /* @__PURE__ */ l.jsx("div", {});
1797
1854
  const m = dt(n, t);
1798
1855
  return a === void 0 && (a = (p) => {
1799
1856
  var f;
1800
1857
  Ze(n, t, p);
1801
- const d = t.validator(p);
1802
- d.isValid ? g(void 0) : g(
1803
- (f = d.errorMessage) == null ? void 0 : f.t({ args: { name: t.label } })
1858
+ const c = t.validator(p);
1859
+ c.isValid ? g(void 0) : g(
1860
+ (f = c.errorMessage) == null ? void 0 : f.t({ args: { name: t.label } })
1804
1861
  );
1805
1862
  }), /* @__PURE__ */ l.jsx(
1806
1863
  cn,
@@ -1811,14 +1868,14 @@ const qo = oe(
1811
1868
  InputComponent: r,
1812
1869
  freeze: i,
1813
1870
  value: m,
1814
- error: c,
1871
+ error: d,
1815
1872
  label: s,
1816
1873
  onChange: a
1817
1874
  }
1818
1875
  );
1819
1876
  }
1820
- ), Oi = (e) => {
1821
- const n = e.schema, t = _(() => e.fieldGroups.map((o, r) => Bo(
1877
+ ), Hi = (e) => {
1878
+ const n = e.schema, t = _(() => e.fieldGroups.map((o, r) => Wo(
1822
1879
  n,
1823
1880
  e.record,
1824
1881
  r,
@@ -1832,10 +1889,10 @@ const qo = oe(
1832
1889
  onSubmit: e.onSubmit === void 0 ? void 0 : (o) => {
1833
1890
  o.preventDefault(), e.onSubmit !== void 0 && e.record.stale && e.record.isValid() && e.onSubmit(e.record);
1834
1891
  },
1835
- children: /* @__PURE__ */ l.jsxs(X, { gap: "sm", className: e.className, style: e.styles, children: [
1892
+ children: /* @__PURE__ */ l.jsxs(Y, { gap: "sm", className: e.className, style: e.styles, children: [
1836
1893
  t,
1837
- e.actions && e.actions.length > 0 && /* @__PURE__ */ l.jsx(L, { gap: "sm", justify: e.actionsAlign, children: e.actions.map((o, r) => /* @__PURE__ */ l.jsx(
1838
- q,
1894
+ e.actions && e.actions.length > 0 && /* @__PURE__ */ l.jsx(O, { gap: "sm", justify: e.actionsAlign, children: e.actions.map((o, r) => /* @__PURE__ */ l.jsx(
1895
+ z,
1839
1896
  {
1840
1897
  variant: o.variant,
1841
1898
  onClick: () => {
@@ -1850,20 +1907,20 @@ const qo = oe(
1850
1907
  }
1851
1908
  );
1852
1909
  };
1853
- function Bo(e, n, t, o, r, i) {
1854
- var c, g;
1910
+ function Wo(e, n, t, o, r, i) {
1911
+ var d, g;
1855
1912
  const s = o.fields, a = [];
1856
1913
  for (let m = 0; m < s.length; m++) {
1857
1914
  const p = [];
1858
- for (let d = 0; d < s[m].length; d++) {
1859
- const f = s[m][d];
1915
+ for (let c = 0; c < s[m].length; c++) {
1916
+ const f = s[m][c];
1860
1917
  let h, v = {};
1861
1918
  if (typeof f == "function")
1862
1919
  h = f(n);
1863
1920
  else {
1864
1921
  let S;
1865
- typeof f == "object" && "prop" in f ? (S = f.prop instanceof Y ? f.prop : e.allProperties[f.prop], f.args !== void 0 && (v = f.args)) : S = f instanceof Y ? f : e.allProperties[f], h = /* @__PURE__ */ l.jsx(
1866
- qo,
1922
+ typeof f == "object" && "prop" in f ? (S = f.prop instanceof W ? f.prop : e.allProperties[f.prop], f.args !== void 0 && (v = f.args)) : S = f instanceof W ? f : e.allProperties[f], h = /* @__PURE__ */ l.jsx(
1923
+ Ko,
1867
1924
  {
1868
1925
  db: i,
1869
1926
  record: n,
@@ -1881,11 +1938,11 @@ function Bo(e, n, t, o, r, i) {
1881
1938
  /* @__PURE__ */ l.jsx(
1882
1939
  nn,
1883
1940
  {
1884
- span: (c = v.colsize) == null ? void 0 : c.span,
1941
+ span: (d = v.colsize) == null ? void 0 : d.span,
1885
1942
  grow: (g = v.colsize) == null ? void 0 : g.grow,
1886
1943
  children: h
1887
1944
  },
1888
- `${m}-${d}`
1945
+ `${m}-${c}`
1889
1946
  )
1890
1947
  );
1891
1948
  }
@@ -1893,8 +1950,8 @@ function Bo(e, n, t, o, r, i) {
1893
1950
  /* @__PURE__ */ l.jsx(tn, { children: p }, m)
1894
1951
  );
1895
1952
  }
1896
- const u = /* @__PURE__ */ l.jsx(X, { gap: "sm", children: a }, t);
1897
- return o.name !== void 0 ? /* @__PURE__ */ l.jsx(Kt, { legend: o.name, children: u }, t) : u;
1953
+ const u = /* @__PURE__ */ l.jsx(Y, { gap: "sm", children: a }, t);
1954
+ return o.name !== void 0 ? /* @__PURE__ */ l.jsx(Yt, { legend: o.name, children: u }, t) : u;
1898
1955
  }
1899
1956
  /**
1900
1957
  * table-core
@@ -1909,7 +1966,7 @@ function Bo(e, n, t, o, r, i) {
1909
1966
  function te(e, n) {
1910
1967
  return typeof e == "function" ? e(n) : e;
1911
1968
  }
1912
- function H(e, n) {
1969
+ function q(e, n) {
1913
1970
  return (t) => {
1914
1971
  n.setState((o) => ({
1915
1972
  ...o,
@@ -1917,13 +1974,13 @@ function H(e, n) {
1917
1974
  }));
1918
1975
  };
1919
1976
  }
1920
- function Ve(e) {
1977
+ function Te(e) {
1921
1978
  return e instanceof Function;
1922
1979
  }
1923
- function Uo(e) {
1980
+ function Xo(e) {
1924
1981
  return Array.isArray(e) && e.every((n) => typeof n == "number");
1925
1982
  }
1926
- function Ko(e, n) {
1983
+ function Jo(e, n) {
1927
1984
  const t = [], o = (r) => {
1928
1985
  r.forEach((i) => {
1929
1986
  t.push(i);
@@ -1942,14 +1999,14 @@ function w(e, n, t) {
1942
1999
  if (!(a.length !== o.length || a.some((g, m) => o[m] !== g)))
1943
2000
  return r;
1944
2001
  o = a;
1945
- let c;
1946
- if (t.key && t.debug && (c = Date.now()), r = n(...a), t == null || t.onChange == null || t.onChange(r), t.key && t.debug && t != null && t.debug()) {
1947
- const g = Math.round((Date.now() - s) * 100) / 100, m = Math.round((Date.now() - c) * 100) / 100, p = m / 16, d = (f, h) => {
2002
+ let d;
2003
+ if (t.key && t.debug && (d = Date.now()), r = n(...a), t == null || t.onChange == null || t.onChange(r), t.key && t.debug && t != null && t.debug()) {
2004
+ const g = Math.round((Date.now() - s) * 100) / 100, m = Math.round((Date.now() - d) * 100) / 100, p = m / 16, c = (f, h) => {
1948
2005
  for (f = String(f); f.length < h; )
1949
2006
  f = " " + f;
1950
2007
  return f;
1951
2008
  };
1952
- console.info(`%c⏱ ${d(m, 5)} /${d(g, 5)} ms`, `
2009
+ console.info(`%c⏱ ${c(m, 5)} /${c(g, 5)} ms`, `
1953
2010
  font-size: .6rem;
1954
2011
  font-weight: bold;
1955
2012
  color: hsl(${Math.max(0, Math.min(120 - 120 * p, 120))}deg 100% 31%);`, t == null ? void 0 : t.key);
@@ -1967,7 +2024,7 @@ function x(e, n, t, o) {
1967
2024
  onChange: o
1968
2025
  };
1969
2026
  }
1970
- function Yo(e, n, t, o) {
2027
+ function Qo(e, n, t, o) {
1971
2028
  const r = () => {
1972
2029
  var s;
1973
2030
  return (s = i.getValue()) != null ? s : e.options.renderFallbackValue;
@@ -1977,37 +2034,37 @@ function Yo(e, n, t, o) {
1977
2034
  column: t,
1978
2035
  getValue: () => n.getValue(o),
1979
2036
  renderValue: r,
1980
- getContext: w(() => [e, t, n, i], (s, a, u, c) => ({
2037
+ getContext: w(() => [e, t, n, i], (s, a, u, d) => ({
1981
2038
  table: s,
1982
2039
  column: a,
1983
2040
  row: u,
1984
- cell: c,
1985
- getValue: c.getValue,
1986
- renderValue: c.renderValue
2041
+ cell: d,
2042
+ getValue: d.getValue,
2043
+ renderValue: d.renderValue
1987
2044
  }), x(e.options, "debugCells", "cell.getContext"))
1988
2045
  };
1989
2046
  return e._features.forEach((s) => {
1990
2047
  s.createCell == null || s.createCell(i, t, n, e);
1991
2048
  }, {}), i;
1992
2049
  }
1993
- function Wo(e, n, t, o) {
2050
+ function Zo(e, n, t, o) {
1994
2051
  var r, i;
1995
2052
  const a = {
1996
2053
  ...e._getDefaultColumnDef(),
1997
2054
  ...n
1998
2055
  }, u = a.accessorKey;
1999
- let c = (r = (i = a.id) != null ? i : u ? typeof String.prototype.replaceAll == "function" ? u.replaceAll(".", "_") : u.replace(/\./g, "_") : void 0) != null ? r : typeof a.header == "string" ? a.header : void 0, g;
2056
+ let d = (r = (i = a.id) != null ? i : u ? typeof String.prototype.replaceAll == "function" ? u.replaceAll(".", "_") : u.replace(/\./g, "_") : void 0) != null ? r : typeof a.header == "string" ? a.header : void 0, g;
2000
2057
  if (a.accessorFn ? g = a.accessorFn : u && (u.includes(".") ? g = (p) => {
2001
- let d = p;
2058
+ let c = p;
2002
2059
  for (const h of u.split(".")) {
2003
2060
  var f;
2004
- d = (f = d) == null ? void 0 : f[h], process.env.NODE_ENV !== "production" && d === void 0 && console.warn(`"${h}" in deeply nested key "${u}" returned undefined.`);
2061
+ c = (f = c) == null ? void 0 : f[h], process.env.NODE_ENV !== "production" && c === void 0 && console.warn(`"${h}" in deeply nested key "${u}" returned undefined.`);
2005
2062
  }
2006
- return d;
2007
- } : g = (p) => p[a.accessorKey]), !c)
2063
+ return c;
2064
+ } : g = (p) => p[a.accessorKey]), !d)
2008
2065
  throw process.env.NODE_ENV !== "production" ? new Error(a.accessorFn ? "Columns require an id when using an accessorFn" : "Columns require an id when using a non-string header") : new Error();
2009
2066
  let m = {
2010
- id: `${String(c)}`,
2067
+ id: `${String(d)}`,
2011
2068
  accessorFn: g,
2012
2069
  parent: o,
2013
2070
  depth: t,
@@ -2015,11 +2072,11 @@ function Wo(e, n, t, o) {
2015
2072
  columns: [],
2016
2073
  getFlatColumns: w(() => [!0], () => {
2017
2074
  var p;
2018
- return [m, ...(p = m.columns) == null ? void 0 : p.flatMap((d) => d.getFlatColumns())];
2075
+ return [m, ...(p = m.columns) == null ? void 0 : p.flatMap((c) => c.getFlatColumns())];
2019
2076
  }, x(e.options, "debugColumns", "column.getFlatColumns")),
2020
2077
  getLeafColumns: w(() => [e._getOrderColumnsFn()], (p) => {
2021
- var d;
2022
- if ((d = m.columns) != null && d.length) {
2078
+ var c;
2079
+ if ((c = m.columns) != null && c.length) {
2023
2080
  let f = m.columns.flatMap((h) => h.getLeafColumns());
2024
2081
  return p(f);
2025
2082
  }
@@ -2030,7 +2087,7 @@ function Wo(e, n, t, o) {
2030
2087
  p.createColumn == null || p.createColumn(m, e);
2031
2088
  return m;
2032
2089
  }
2033
- const O = "debugHeaders";
2090
+ const L = "debugHeaders";
2034
2091
  function At(e, n, t) {
2035
2092
  var o;
2036
2093
  let i = {
@@ -2060,81 +2117,81 @@ function At(e, n, t) {
2060
2117
  s.createHeader == null || s.createHeader(i, e);
2061
2118
  }), i;
2062
2119
  }
2063
- const Xo = {
2120
+ const er = {
2064
2121
  createTable: (e) => {
2065
2122
  e.getHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, o, r) => {
2066
2123
  var i, s;
2067
- const a = (i = o == null ? void 0 : o.map((m) => t.find((p) => p.id === m)).filter(Boolean)) != null ? i : [], u = (s = r == null ? void 0 : r.map((m) => t.find((p) => p.id === m)).filter(Boolean)) != null ? s : [], c = t.filter((m) => !(o != null && o.includes(m.id)) && !(r != null && r.includes(m.id)));
2068
- return Fe(n, [...a, ...c, ...u], e);
2069
- }, x(e.options, O, "getHeaderGroups")), e.getCenterHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, o, r) => (t = t.filter((i) => !(o != null && o.includes(i.id)) && !(r != null && r.includes(i.id))), Fe(n, t, e, "center")), x(e.options, O, "getCenterHeaderGroups")), e.getLeftHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left], (n, t, o) => {
2124
+ const a = (i = o == null ? void 0 : o.map((m) => t.find((p) => p.id === m)).filter(Boolean)) != null ? i : [], u = (s = r == null ? void 0 : r.map((m) => t.find((p) => p.id === m)).filter(Boolean)) != null ? s : [], d = t.filter((m) => !(o != null && o.includes(m.id)) && !(r != null && r.includes(m.id)));
2125
+ return Ie(n, [...a, ...d, ...u], e);
2126
+ }, x(e.options, L, "getHeaderGroups")), e.getCenterHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, o, r) => (t = t.filter((i) => !(o != null && o.includes(i.id)) && !(r != null && r.includes(i.id))), Ie(n, t, e, "center")), x(e.options, L, "getCenterHeaderGroups")), e.getLeftHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left], (n, t, o) => {
2070
2127
  var r;
2071
2128
  const i = (r = o == null ? void 0 : o.map((s) => t.find((a) => a.id === s)).filter(Boolean)) != null ? r : [];
2072
- return Fe(n, i, e, "left");
2073
- }, x(e.options, O, "getLeftHeaderGroups")), e.getRightHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.right], (n, t, o) => {
2129
+ return Ie(n, i, e, "left");
2130
+ }, x(e.options, L, "getLeftHeaderGroups")), e.getRightHeaderGroups = w(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.right], (n, t, o) => {
2074
2131
  var r;
2075
2132
  const i = (r = o == null ? void 0 : o.map((s) => t.find((a) => a.id === s)).filter(Boolean)) != null ? r : [];
2076
- return Fe(n, i, e, "right");
2077
- }, x(e.options, O, "getRightHeaderGroups")), e.getFooterGroups = w(() => [e.getHeaderGroups()], (n) => [...n].reverse(), x(e.options, O, "getFooterGroups")), e.getLeftFooterGroups = w(() => [e.getLeftHeaderGroups()], (n) => [...n].reverse(), x(e.options, O, "getLeftFooterGroups")), e.getCenterFooterGroups = w(() => [e.getCenterHeaderGroups()], (n) => [...n].reverse(), x(e.options, O, "getCenterFooterGroups")), e.getRightFooterGroups = w(() => [e.getRightHeaderGroups()], (n) => [...n].reverse(), x(e.options, O, "getRightFooterGroups")), e.getFlatHeaders = w(() => [e.getHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, O, "getFlatHeaders")), e.getLeftFlatHeaders = w(() => [e.getLeftHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, O, "getLeftFlatHeaders")), e.getCenterFlatHeaders = w(() => [e.getCenterHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, O, "getCenterFlatHeaders")), e.getRightFlatHeaders = w(() => [e.getRightHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, O, "getRightFlatHeaders")), e.getCenterLeafHeaders = w(() => [e.getCenterFlatHeaders()], (n) => n.filter((t) => {
2133
+ return Ie(n, i, e, "right");
2134
+ }, x(e.options, L, "getRightHeaderGroups")), e.getFooterGroups = w(() => [e.getHeaderGroups()], (n) => [...n].reverse(), x(e.options, L, "getFooterGroups")), e.getLeftFooterGroups = w(() => [e.getLeftHeaderGroups()], (n) => [...n].reverse(), x(e.options, L, "getLeftFooterGroups")), e.getCenterFooterGroups = w(() => [e.getCenterHeaderGroups()], (n) => [...n].reverse(), x(e.options, L, "getCenterFooterGroups")), e.getRightFooterGroups = w(() => [e.getRightHeaderGroups()], (n) => [...n].reverse(), x(e.options, L, "getRightFooterGroups")), e.getFlatHeaders = w(() => [e.getHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, L, "getFlatHeaders")), e.getLeftFlatHeaders = w(() => [e.getLeftHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, L, "getLeftFlatHeaders")), e.getCenterFlatHeaders = w(() => [e.getCenterHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, L, "getCenterFlatHeaders")), e.getRightFlatHeaders = w(() => [e.getRightHeaderGroups()], (n) => n.map((t) => t.headers).flat(), x(e.options, L, "getRightFlatHeaders")), e.getCenterLeafHeaders = w(() => [e.getCenterFlatHeaders()], (n) => n.filter((t) => {
2078
2135
  var o;
2079
2136
  return !((o = t.subHeaders) != null && o.length);
2080
- }), x(e.options, O, "getCenterLeafHeaders")), e.getLeftLeafHeaders = w(() => [e.getLeftFlatHeaders()], (n) => n.filter((t) => {
2137
+ }), x(e.options, L, "getCenterLeafHeaders")), e.getLeftLeafHeaders = w(() => [e.getLeftFlatHeaders()], (n) => n.filter((t) => {
2081
2138
  var o;
2082
2139
  return !((o = t.subHeaders) != null && o.length);
2083
- }), x(e.options, O, "getLeftLeafHeaders")), e.getRightLeafHeaders = w(() => [e.getRightFlatHeaders()], (n) => n.filter((t) => {
2140
+ }), x(e.options, L, "getLeftLeafHeaders")), e.getRightLeafHeaders = w(() => [e.getRightFlatHeaders()], (n) => n.filter((t) => {
2084
2141
  var o;
2085
2142
  return !((o = t.subHeaders) != null && o.length);
2086
- }), x(e.options, O, "getRightLeafHeaders")), e.getLeafHeaders = w(() => [e.getLeftHeaderGroups(), e.getCenterHeaderGroups(), e.getRightHeaderGroups()], (n, t, o) => {
2087
- var r, i, s, a, u, c;
2088
- return [...(r = (i = n[0]) == null ? void 0 : i.headers) != null ? r : [], ...(s = (a = t[0]) == null ? void 0 : a.headers) != null ? s : [], ...(u = (c = o[0]) == null ? void 0 : c.headers) != null ? u : []].map((g) => g.getLeafHeaders()).flat();
2089
- }, x(e.options, O, "getLeafHeaders"));
2143
+ }), x(e.options, L, "getRightLeafHeaders")), e.getLeafHeaders = w(() => [e.getLeftHeaderGroups(), e.getCenterHeaderGroups(), e.getRightHeaderGroups()], (n, t, o) => {
2144
+ var r, i, s, a, u, d;
2145
+ return [...(r = (i = n[0]) == null ? void 0 : i.headers) != null ? r : [], ...(s = (a = t[0]) == null ? void 0 : a.headers) != null ? s : [], ...(u = (d = o[0]) == null ? void 0 : d.headers) != null ? u : []].map((g) => g.getLeafHeaders()).flat();
2146
+ }, x(e.options, L, "getLeafHeaders"));
2090
2147
  }
2091
2148
  };
2092
- function Fe(e, n, t, o) {
2149
+ function Ie(e, n, t, o) {
2093
2150
  var r, i;
2094
2151
  let s = 0;
2095
- const a = function(p, d) {
2096
- d === void 0 && (d = 1), s = Math.max(s, d), p.filter((f) => f.getIsVisible()).forEach((f) => {
2152
+ const a = function(p, c) {
2153
+ c === void 0 && (c = 1), s = Math.max(s, c), p.filter((f) => f.getIsVisible()).forEach((f) => {
2097
2154
  var h;
2098
- (h = f.columns) != null && h.length && a(f.columns, d + 1);
2155
+ (h = f.columns) != null && h.length && a(f.columns, c + 1);
2099
2156
  }, 0);
2100
2157
  };
2101
2158
  a(e);
2102
2159
  let u = [];
2103
- const c = (p, d) => {
2160
+ const d = (p, c) => {
2104
2161
  const f = {
2105
- depth: d,
2106
- id: [o, `${d}`].filter(Boolean).join("_"),
2162
+ depth: c,
2163
+ id: [o, `${c}`].filter(Boolean).join("_"),
2107
2164
  headers: []
2108
2165
  }, h = [];
2109
2166
  p.forEach((v) => {
2110
2167
  const S = [...h].reverse()[0], R = v.column.depth === f.depth;
2111
- let j, I = !1;
2112
- if (R && v.column.parent ? j = v.column.parent : (j = v.column, I = !0), S && (S == null ? void 0 : S.column) === j)
2168
+ let y, I = !1;
2169
+ if (R && v.column.parent ? y = v.column.parent : (y = v.column, I = !0), S && (S == null ? void 0 : S.column) === y)
2113
2170
  S.subHeaders.push(v);
2114
2171
  else {
2115
- const P = At(t, j, {
2116
- id: [o, d, j.id, v == null ? void 0 : v.id].filter(Boolean).join("_"),
2172
+ const P = At(t, y, {
2173
+ id: [o, c, y.id, v == null ? void 0 : v.id].filter(Boolean).join("_"),
2117
2174
  isPlaceholder: I,
2118
- placeholderId: I ? `${h.filter((k) => k.column === j).length}` : void 0,
2119
- depth: d,
2175
+ placeholderId: I ? `${h.filter((k) => k.column === y).length}` : void 0,
2176
+ depth: c,
2120
2177
  index: h.length
2121
2178
  });
2122
2179
  P.subHeaders.push(v), h.push(P);
2123
2180
  }
2124
2181
  f.headers.push(v), v.headerGroup = f;
2125
- }), u.push(f), d > 0 && c(h, d - 1);
2126
- }, g = n.map((p, d) => At(t, p, {
2182
+ }), u.push(f), c > 0 && d(h, c - 1);
2183
+ }, g = n.map((p, c) => At(t, p, {
2127
2184
  depth: s,
2128
- index: d
2185
+ index: c
2129
2186
  }));
2130
- c(g, s - 1), u.reverse();
2187
+ d(g, s - 1), u.reverse();
2131
2188
  const m = (p) => p.filter((f) => f.column.getIsVisible()).map((f) => {
2132
2189
  let h = 0, v = 0, S = [0];
2133
- f.subHeaders && f.subHeaders.length ? (S = [], m(f.subHeaders).forEach((j) => {
2190
+ f.subHeaders && f.subHeaders.length ? (S = [], m(f.subHeaders).forEach((y) => {
2134
2191
  let {
2135
2192
  colSpan: I,
2136
2193
  rowSpan: P
2137
- } = j;
2194
+ } = y;
2138
2195
  h += I, S.push(P);
2139
2196
  })) : h = 1;
2140
2197
  const R = Math.min(...S);
@@ -2145,7 +2202,7 @@ function Fe(e, n, t, o) {
2145
2202
  });
2146
2203
  return m((r = (i = u[0]) == null ? void 0 : i.headers) != null ? r : []), u;
2147
2204
  }
2148
- const Jo = (e, n, t, o, r, i, s) => {
2205
+ const tr = (e, n, t, o, r, i, s) => {
2149
2206
  let a = {
2150
2207
  id: n,
2151
2208
  index: o,
@@ -2157,42 +2214,42 @@ const Jo = (e, n, t, o, r, i, s) => {
2157
2214
  getValue: (u) => {
2158
2215
  if (a._valuesCache.hasOwnProperty(u))
2159
2216
  return a._valuesCache[u];
2160
- const c = e.getColumn(u);
2161
- if (c != null && c.accessorFn)
2162
- return a._valuesCache[u] = c.accessorFn(a.original, o), a._valuesCache[u];
2217
+ const d = e.getColumn(u);
2218
+ if (d != null && d.accessorFn)
2219
+ return a._valuesCache[u] = d.accessorFn(a.original, o), a._valuesCache[u];
2163
2220
  },
2164
2221
  getUniqueValues: (u) => {
2165
2222
  if (a._uniqueValuesCache.hasOwnProperty(u))
2166
2223
  return a._uniqueValuesCache[u];
2167
- const c = e.getColumn(u);
2168
- if (c != null && c.accessorFn)
2169
- return c.columnDef.getUniqueValues ? (a._uniqueValuesCache[u] = c.columnDef.getUniqueValues(a.original, o), a._uniqueValuesCache[u]) : (a._uniqueValuesCache[u] = [a.getValue(u)], a._uniqueValuesCache[u]);
2224
+ const d = e.getColumn(u);
2225
+ if (d != null && d.accessorFn)
2226
+ return d.columnDef.getUniqueValues ? (a._uniqueValuesCache[u] = d.columnDef.getUniqueValues(a.original, o), a._uniqueValuesCache[u]) : (a._uniqueValuesCache[u] = [a.getValue(u)], a._uniqueValuesCache[u]);
2170
2227
  },
2171
2228
  renderValue: (u) => {
2172
- var c;
2173
- return (c = a.getValue(u)) != null ? c : e.options.renderFallbackValue;
2229
+ var d;
2230
+ return (d = a.getValue(u)) != null ? d : e.options.renderFallbackValue;
2174
2231
  },
2175
2232
  subRows: [],
2176
- getLeafRows: () => Ko(a.subRows, (u) => u.subRows),
2233
+ getLeafRows: () => Jo(a.subRows, (u) => u.subRows),
2177
2234
  getParentRow: () => a.parentId ? e.getRow(a.parentId, !0) : void 0,
2178
2235
  getParentRows: () => {
2179
- let u = [], c = a;
2236
+ let u = [], d = a;
2180
2237
  for (; ; ) {
2181
- const g = c.getParentRow();
2238
+ const g = d.getParentRow();
2182
2239
  if (!g) break;
2183
- u.push(g), c = g;
2240
+ u.push(g), d = g;
2184
2241
  }
2185
2242
  return u.reverse();
2186
2243
  },
2187
- getAllCells: w(() => [e.getAllLeafColumns()], (u) => u.map((c) => Yo(e, a, c, c.id)), x(e.options, "debugRows", "getAllCells")),
2188
- _getAllCellsByColumnId: w(() => [a.getAllCells()], (u) => u.reduce((c, g) => (c[g.column.id] = g, c), {}), x(e.options, "debugRows", "getAllCellsByColumnId"))
2244
+ getAllCells: w(() => [e.getAllLeafColumns()], (u) => u.map((d) => Qo(e, a, d, d.id)), x(e.options, "debugRows", "getAllCells")),
2245
+ _getAllCellsByColumnId: w(() => [a.getAllCells()], (u) => u.reduce((d, g) => (d[g.column.id] = g, d), {}), x(e.options, "debugRows", "getAllCellsByColumnId"))
2189
2246
  };
2190
2247
  for (let u = 0; u < e._features.length; u++) {
2191
- const c = e._features[u];
2192
- c == null || c.createRow == null || c.createRow(a, e);
2248
+ const d = e._features[u];
2249
+ d == null || d.createRow == null || d.createRow(a, e);
2193
2250
  }
2194
2251
  return a;
2195
- }, Qo = {
2252
+ }, nr = {
2196
2253
  createColumn: (e, n) => {
2197
2254
  e._getFacetedRowModel = n.options.getFacetedRowModel && n.options.getFacetedRowModel(n, e.id), e.getFacetedRowModel = () => e._getFacetedRowModel ? e._getFacetedRowModel() : n.getPreFilteredRowModel(), e._getFacetedUniqueValues = n.options.getFacetedUniqueValues && n.options.getFacetedUniqueValues(n, e.id), e.getFacetedUniqueValues = () => e._getFacetedUniqueValues ? e._getFacetedUniqueValues() : /* @__PURE__ */ new Map(), e._getFacetedMinMaxValues = n.options.getFacetedMinMaxValues && n.options.getFacetedMinMaxValues(n, e.id), e.getFacetedMinMaxValues = () => {
2198
2255
  if (e._getFacetedMinMaxValues)
@@ -2262,7 +2319,7 @@ const Q = {
2262
2319
  function K(e) {
2263
2320
  return e == null || e === "";
2264
2321
  }
2265
- const Zo = {
2322
+ const or = {
2266
2323
  getDefaultColumnDef: () => ({
2267
2324
  filterFn: "auto"
2268
2325
  }),
@@ -2271,7 +2328,7 @@ const Zo = {
2271
2328
  ...e
2272
2329
  }),
2273
2330
  getDefaultOptions: (e) => ({
2274
- onColumnFiltersChange: H("columnFilters", e),
2331
+ onColumnFiltersChange: q("columnFilters", e),
2275
2332
  filterFromLeafRows: !1,
2276
2333
  maxLeafRowFilterDepth: 100
2277
2334
  }),
@@ -2281,7 +2338,7 @@ const Zo = {
2281
2338
  return typeof o == "string" ? Q.includesString : typeof o == "number" ? Q.inNumberRange : typeof o == "boolean" || o !== null && typeof o == "object" ? Q.equals : Array.isArray(o) ? Q.arrIncludes : Q.weakEquals;
2282
2339
  }, e.getFilterFn = () => {
2283
2340
  var t, o;
2284
- return Ve(e.columnDef.filterFn) ? e.columnDef.filterFn : e.columnDef.filterFn === "auto" ? e.getAutoFilterFn() : (
2341
+ return Te(e.columnDef.filterFn) ? e.columnDef.filterFn : e.columnDef.filterFn === "auto" ? e.getAutoFilterFn() : (
2285
2342
  // @ts-ignore
2286
2343
  (t = (o = n.options.filterFns) == null ? void 0 : o[e.columnDef.filterFn]) != null ? t : Q[e.columnDef.filterFn]
2287
2344
  );
@@ -2306,8 +2363,8 @@ const Zo = {
2306
2363
  value: s
2307
2364
  };
2308
2365
  if (i) {
2309
- var c;
2310
- return (c = o == null ? void 0 : o.map((g) => g.id === e.id ? u : g)) != null ? c : [];
2366
+ var d;
2367
+ return (d = o == null ? void 0 : o.map((g) => g.id === e.id ? u : g)) != null ? d : [];
2311
2368
  }
2312
2369
  return o != null && o.length ? [...o, u] : [u];
2313
2370
  });
@@ -2340,54 +2397,54 @@ const Zo = {
2340
2397
  function Nt(e, n, t) {
2341
2398
  return (e && e.autoRemove ? e.autoRemove(n, t) : !1) || typeof n > "u" || typeof n == "string" && !n;
2342
2399
  }
2343
- const er = (e, n, t) => t.reduce((o, r) => {
2400
+ const rr = (e, n, t) => t.reduce((o, r) => {
2344
2401
  const i = r.getValue(e);
2345
2402
  return o + (typeof i == "number" ? i : 0);
2346
- }, 0), tr = (e, n, t) => {
2403
+ }, 0), ir = (e, n, t) => {
2347
2404
  let o;
2348
2405
  return t.forEach((r) => {
2349
2406
  const i = r.getValue(e);
2350
2407
  i != null && (o > i || o === void 0 && i >= i) && (o = i);
2351
2408
  }), o;
2352
- }, nr = (e, n, t) => {
2409
+ }, sr = (e, n, t) => {
2353
2410
  let o;
2354
2411
  return t.forEach((r) => {
2355
2412
  const i = r.getValue(e);
2356
2413
  i != null && (o < i || o === void 0 && i >= i) && (o = i);
2357
2414
  }), o;
2358
- }, or = (e, n, t) => {
2415
+ }, lr = (e, n, t) => {
2359
2416
  let o, r;
2360
2417
  return t.forEach((i) => {
2361
2418
  const s = i.getValue(e);
2362
2419
  s != null && (o === void 0 ? s >= s && (o = r = s) : (o > s && (o = s), r < s && (r = s)));
2363
2420
  }), [o, r];
2364
- }, rr = (e, n) => {
2421
+ }, ar = (e, n) => {
2365
2422
  let t = 0, o = 0;
2366
2423
  if (n.forEach((r) => {
2367
2424
  let i = r.getValue(e);
2368
2425
  i != null && (i = +i) >= i && (++t, o += i);
2369
2426
  }), t) return o / t;
2370
- }, ir = (e, n) => {
2427
+ }, ur = (e, n) => {
2371
2428
  if (!n.length)
2372
2429
  return;
2373
2430
  const t = n.map((i) => i.getValue(e));
2374
- if (!Uo(t))
2431
+ if (!Xo(t))
2375
2432
  return;
2376
2433
  if (t.length === 1)
2377
2434
  return t[0];
2378
2435
  const o = Math.floor(t.length / 2), r = t.sort((i, s) => i - s);
2379
2436
  return t.length % 2 !== 0 ? r[o] : (r[o - 1] + r[o]) / 2;
2380
- }, sr = (e, n) => Array.from(new Set(n.map((t) => t.getValue(e))).values()), lr = (e, n) => new Set(n.map((t) => t.getValue(e))).size, ar = (e, n) => n.length, Ge = {
2381
- sum: er,
2382
- min: tr,
2383
- max: nr,
2384
- extent: or,
2385
- mean: rr,
2386
- median: ir,
2387
- unique: sr,
2388
- uniqueCount: lr,
2389
- count: ar
2390
- }, ur = {
2437
+ }, dr = (e, n) => Array.from(new Set(n.map((t) => t.getValue(e))).values()), cr = (e, n) => new Set(n.map((t) => t.getValue(e))).size, gr = (e, n) => n.length, Ge = {
2438
+ sum: rr,
2439
+ min: ir,
2440
+ max: sr,
2441
+ extent: lr,
2442
+ mean: ar,
2443
+ median: ur,
2444
+ unique: dr,
2445
+ uniqueCount: cr,
2446
+ count: gr
2447
+ }, fr = {
2391
2448
  getDefaultColumnDef: () => ({
2392
2449
  aggregatedCell: (e) => {
2393
2450
  var n, t;
@@ -2400,7 +2457,7 @@ const er = (e, n, t) => t.reduce((o, r) => {
2400
2457
  ...e
2401
2458
  }),
2402
2459
  getDefaultOptions: (e) => ({
2403
- onGroupingChange: H("grouping", e),
2460
+ onGroupingChange: q("grouping", e),
2404
2461
  groupedColumnMode: "reorder"
2405
2462
  }),
2406
2463
  createColumn: (e, n) => {
@@ -2430,7 +2487,7 @@ const er = (e, n, t) => t.reduce((o, r) => {
2430
2487
  var t, o;
2431
2488
  if (!e)
2432
2489
  throw new Error();
2433
- return Ve(e.columnDef.aggregationFn) ? e.columnDef.aggregationFn : e.columnDef.aggregationFn === "auto" ? e.getAutoAggregationFn() : (t = (o = n.options.aggregationFns) == null ? void 0 : o[e.columnDef.aggregationFn]) != null ? t : Ge[e.columnDef.aggregationFn];
2490
+ return Te(e.columnDef.aggregationFn) ? e.columnDef.aggregationFn : e.columnDef.aggregationFn === "auto" ? e.getAutoAggregationFn() : (t = (o = n.options.aggregationFns) == null ? void 0 : o[e.columnDef.aggregationFn]) != null ? t : Ge[e.columnDef.aggregationFn];
2434
2491
  };
2435
2492
  },
2436
2493
  createTable: (e) => {
@@ -2454,27 +2511,27 @@ const er = (e, n, t) => t.reduce((o, r) => {
2454
2511
  };
2455
2512
  }
2456
2513
  };
2457
- function dr(e, n, t) {
2514
+ function mr(e, n, t) {
2458
2515
  if (!(n != null && n.length) || !t)
2459
2516
  return e;
2460
2517
  const o = e.filter((i) => !n.includes(i.id));
2461
2518
  return t === "remove" ? o : [...n.map((i) => e.find((s) => s.id === i)).filter(Boolean), ...o];
2462
2519
  }
2463
- const cr = {
2520
+ const pr = {
2464
2521
  getInitialState: (e) => ({
2465
2522
  columnOrder: [],
2466
2523
  ...e
2467
2524
  }),
2468
2525
  getDefaultOptions: (e) => ({
2469
- onColumnOrderChange: H("columnOrder", e)
2526
+ onColumnOrderChange: q("columnOrder", e)
2470
2527
  }),
2471
2528
  createColumn: (e, n) => {
2472
- e.getIndex = w((t) => [ve(n, t)], (t) => t.findIndex((o) => o.id === e.id), x(n.options, "debugColumns", "getIndex")), e.getIsFirstColumn = (t) => {
2529
+ e.getIndex = w((t) => [Ce(n, t)], (t) => t.findIndex((o) => o.id === e.id), x(n.options, "debugColumns", "getIndex")), e.getIsFirstColumn = (t) => {
2473
2530
  var o;
2474
- return ((o = ve(n, t)[0]) == null ? void 0 : o.id) === e.id;
2531
+ return ((o = Ce(n, t)[0]) == null ? void 0 : o.id) === e.id;
2475
2532
  }, e.getIsLastColumn = (t) => {
2476
2533
  var o;
2477
- const r = ve(n, t);
2534
+ const r = Ce(n, t);
2478
2535
  return ((o = r[r.length - 1]) == null ? void 0 : o.id) === e.id;
2479
2536
  };
2480
2537
  },
@@ -2489,24 +2546,24 @@ const cr = {
2489
2546
  else {
2490
2547
  const s = [...n], a = [...r];
2491
2548
  for (; a.length && s.length; ) {
2492
- const u = s.shift(), c = a.findIndex((g) => g.id === u);
2493
- c > -1 && i.push(a.splice(c, 1)[0]);
2549
+ const u = s.shift(), d = a.findIndex((g) => g.id === u);
2550
+ d > -1 && i.push(a.splice(d, 1)[0]);
2494
2551
  }
2495
2552
  i = [...i, ...a];
2496
2553
  }
2497
- return dr(i, t, o);
2554
+ return mr(i, t, o);
2498
2555
  }, x(e.options, "debugTable", "_getOrderColumnsFn"));
2499
2556
  }
2500
2557
  }, He = () => ({
2501
2558
  left: [],
2502
2559
  right: []
2503
- }), gr = {
2560
+ }), hr = {
2504
2561
  getInitialState: (e) => ({
2505
2562
  columnPinning: He(),
2506
2563
  ...e
2507
2564
  }),
2508
2565
  getDefaultOptions: (e) => ({
2509
- onColumnPinningChange: H("columnPinning", e)
2566
+ onColumnPinningChange: q("columnPinning", e)
2510
2567
  }),
2511
2568
  createColumn: (e, n) => {
2512
2569
  e.pin = (t) => {
@@ -2521,9 +2578,9 @@ const cr = {
2521
2578
  };
2522
2579
  }
2523
2580
  if (t === "left") {
2524
- var c, g;
2581
+ var d, g;
2525
2582
  return {
2526
- left: [...((c = r == null ? void 0 : r.left) != null ? c : []).filter((m) => !(o != null && o.includes(m))), ...o],
2583
+ left: [...((d = r == null ? void 0 : r.left) != null ? d : []).filter((m) => !(o != null && o.includes(m))), ...o],
2527
2584
  right: ((g = r == null ? void 0 : r.right) != null ? g : []).filter((m) => !(o != null && o.includes(m)))
2528
2585
  };
2529
2586
  }
@@ -2577,10 +2634,10 @@ const cr = {
2577
2634
  }, x(e.options, "debugColumns", "getCenterLeafColumns"));
2578
2635
  }
2579
2636
  };
2580
- function fr(e) {
2637
+ function Sr(e) {
2581
2638
  return e || (typeof document < "u" ? document : null);
2582
2639
  }
2583
- const Ie = {
2640
+ const Pe = {
2584
2641
  size: 150,
2585
2642
  minSize: 20,
2586
2643
  maxSize: Number.MAX_SAFE_INTEGER
@@ -2591,8 +2648,8 @@ const Ie = {
2591
2648
  deltaPercentage: null,
2592
2649
  isResizingColumn: !1,
2593
2650
  columnSizingStart: []
2594
- }), mr = {
2595
- getDefaultColumnDef: () => Ie,
2651
+ }), vr = {
2652
+ getDefaultColumnDef: () => Pe,
2596
2653
  getInitialState: (e) => ({
2597
2654
  columnSizing: {},
2598
2655
  columnSizingInfo: qe(),
@@ -2601,15 +2658,15 @@ const Ie = {
2601
2658
  getDefaultOptions: (e) => ({
2602
2659
  columnResizeMode: "onEnd",
2603
2660
  columnResizeDirection: "ltr",
2604
- onColumnSizingChange: H("columnSizing", e),
2605
- onColumnSizingInfoChange: H("columnSizingInfo", e)
2661
+ onColumnSizingChange: q("columnSizing", e),
2662
+ onColumnSizingInfoChange: q("columnSizingInfo", e)
2606
2663
  }),
2607
2664
  createColumn: (e, n) => {
2608
2665
  e.getSize = () => {
2609
2666
  var t, o, r;
2610
2667
  const i = n.getState().columnSizing[e.id];
2611
- return Math.min(Math.max((t = e.columnDef.minSize) != null ? t : Ie.minSize, (o = i ?? e.columnDef.size) != null ? o : Ie.size), (r = e.columnDef.maxSize) != null ? r : Ie.maxSize);
2612
- }, e.getStart = w((t) => [t, ve(n, t), n.getState().columnSizing], (t, o) => o.slice(0, e.getIndex(t)).reduce((r, i) => r + i.getSize(), 0), x(n.options, "debugColumns", "getStart")), e.getAfter = w((t) => [t, ve(n, t), n.getState().columnSizing], (t, o) => o.slice(e.getIndex(t) + 1).reduce((r, i) => r + i.getSize(), 0), x(n.options, "debugColumns", "getAfter")), e.resetSize = () => {
2668
+ return Math.min(Math.max((t = e.columnDef.minSize) != null ? t : Pe.minSize, (o = i ?? e.columnDef.size) != null ? o : Pe.size), (r = e.columnDef.maxSize) != null ? r : Pe.maxSize);
2669
+ }, e.getStart = w((t) => [t, Ce(n, t), n.getState().columnSizing], (t, o) => o.slice(0, e.getIndex(t)).reduce((r, i) => r + i.getSize(), 0), x(n.options, "debugColumns", "getStart")), e.getAfter = w((t) => [t, Ce(n, t), n.getState().columnSizing], (t, o) => o.slice(e.getIndex(t) + 1).reduce((r, i) => r + i.getSize(), 0), x(n.options, "debugColumns", "getAfter")), e.resetSize = () => {
2613
2670
  n.setColumnSizing((t) => {
2614
2671
  let {
2615
2672
  [e.id]: o,
@@ -2645,21 +2702,21 @@ const Ie = {
2645
2702
  return (i) => {
2646
2703
  if (!o || !r || (i.persist == null || i.persist(), Be(i) && i.touches && i.touches.length > 1))
2647
2704
  return;
2648
- const s = e.getSize(), a = e ? e.getLeafHeaders().map((S) => [S.column.id, S.column.getSize()]) : [[o.id, o.getSize()]], u = Be(i) ? Math.round(i.touches[0].clientX) : i.clientX, c = {}, g = (S, R) => {
2649
- typeof R == "number" && (n.setColumnSizingInfo((j) => {
2705
+ const s = e.getSize(), a = e ? e.getLeafHeaders().map((S) => [S.column.id, S.column.getSize()]) : [[o.id, o.getSize()]], u = Be(i) ? Math.round(i.touches[0].clientX) : i.clientX, d = {}, g = (S, R) => {
2706
+ typeof R == "number" && (n.setColumnSizingInfo((y) => {
2650
2707
  var I, P;
2651
- const k = n.options.columnResizeDirection === "rtl" ? -1 : 1, F = (R - ((I = j == null ? void 0 : j.startOffset) != null ? I : 0)) * k, V = Math.max(F / ((P = j == null ? void 0 : j.startSize) != null ? P : 0), -0.999999);
2652
- return j.columnSizingStart.forEach((G) => {
2653
- let [Te, we] = G;
2654
- c[Te] = Math.round(Math.max(we + we * V, 0) * 100) / 100;
2708
+ const k = n.options.columnResizeDirection === "rtl" ? -1 : 1, F = (R - ((I = y == null ? void 0 : y.startOffset) != null ? I : 0)) * k, T = Math.max(F / ((P = y == null ? void 0 : y.startSize) != null ? P : 0), -0.999999);
2709
+ return y.columnSizingStart.forEach((H) => {
2710
+ let [Ae, xe] = H;
2711
+ d[Ae] = Math.round(Math.max(xe + xe * T, 0) * 100) / 100;
2655
2712
  }), {
2656
- ...j,
2713
+ ...y,
2657
2714
  deltaOffset: F,
2658
- deltaPercentage: V
2715
+ deltaPercentage: T
2659
2716
  };
2660
- }), (n.options.columnResizeMode === "onChange" || S === "end") && n.setColumnSizing((j) => ({
2661
- ...j,
2662
- ...c
2717
+ }), (n.options.columnResizeMode === "onChange" || S === "end") && n.setColumnSizing((y) => ({
2718
+ ...y,
2719
+ ...d
2663
2720
  })));
2664
2721
  }, m = (S) => g("move", S), p = (S) => {
2665
2722
  g("end", S), n.setColumnSizingInfo((R) => ({
@@ -2671,21 +2728,21 @@ const Ie = {
2671
2728
  deltaPercentage: null,
2672
2729
  columnSizingStart: []
2673
2730
  }));
2674
- }, d = fr(t), f = {
2731
+ }, c = Sr(t), f = {
2675
2732
  moveHandler: (S) => m(S.clientX),
2676
2733
  upHandler: (S) => {
2677
- d == null || d.removeEventListener("mousemove", f.moveHandler), d == null || d.removeEventListener("mouseup", f.upHandler), p(S.clientX);
2734
+ c == null || c.removeEventListener("mousemove", f.moveHandler), c == null || c.removeEventListener("mouseup", f.upHandler), p(S.clientX);
2678
2735
  }
2679
2736
  }, h = {
2680
2737
  moveHandler: (S) => (S.cancelable && (S.preventDefault(), S.stopPropagation()), m(S.touches[0].clientX), !1),
2681
2738
  upHandler: (S) => {
2682
2739
  var R;
2683
- d == null || d.removeEventListener("touchmove", h.moveHandler), d == null || d.removeEventListener("touchend", h.upHandler), S.cancelable && (S.preventDefault(), S.stopPropagation()), p((R = S.touches[0]) == null ? void 0 : R.clientX);
2740
+ c == null || c.removeEventListener("touchmove", h.moveHandler), c == null || c.removeEventListener("touchend", h.upHandler), S.cancelable && (S.preventDefault(), S.stopPropagation()), p((R = S.touches[0]) == null ? void 0 : R.clientX);
2684
2741
  }
2685
- }, v = pr() ? {
2742
+ }, v = Cr() ? {
2686
2743
  passive: !1
2687
2744
  } : !1;
2688
- Be(i) ? (d == null || d.addEventListener("touchmove", h.moveHandler, v), d == null || d.addEventListener("touchend", h.upHandler, v)) : (d == null || d.addEventListener("mousemove", f.moveHandler, v), d == null || d.addEventListener("mouseup", f.upHandler, v)), n.setColumnSizingInfo((S) => ({
2745
+ Be(i) ? (c == null || c.addEventListener("touchmove", h.moveHandler, v), c == null || c.addEventListener("touchend", h.upHandler, v)) : (c == null || c.addEventListener("mousemove", f.moveHandler, v), c == null || c.addEventListener("mouseup", f.upHandler, v)), n.setColumnSizingInfo((S) => ({
2689
2746
  ...S,
2690
2747
  startOffset: u,
2691
2748
  startSize: s,
@@ -2719,9 +2776,9 @@ const Ie = {
2719
2776
  };
2720
2777
  }
2721
2778
  };
2722
- let Pe = null;
2723
- function pr() {
2724
- if (typeof Pe == "boolean") return Pe;
2779
+ let Ee = null;
2780
+ function Cr() {
2781
+ if (typeof Ee == "boolean") return Ee;
2725
2782
  let e = !1;
2726
2783
  try {
2727
2784
  const n = {
@@ -2734,18 +2791,18 @@ function pr() {
2734
2791
  } catch {
2735
2792
  e = !1;
2736
2793
  }
2737
- return Pe = e, Pe;
2794
+ return Ee = e, Ee;
2738
2795
  }
2739
2796
  function Be(e) {
2740
2797
  return e.type === "touchstart";
2741
2798
  }
2742
- const hr = {
2799
+ const wr = {
2743
2800
  getInitialState: (e) => ({
2744
2801
  columnVisibility: {},
2745
2802
  ...e
2746
2803
  }),
2747
2804
  getDefaultOptions: (e) => ({
2748
- onColumnVisibilityChange: H("columnVisibility", e)
2805
+ onColumnVisibilityChange: q("columnVisibility", e)
2749
2806
  }),
2750
2807
  createColumn: (e, n) => {
2751
2808
  e.toggleVisibility = (t) => {
@@ -2784,23 +2841,23 @@ const hr = {
2784
2841
  };
2785
2842
  }
2786
2843
  };
2787
- function ve(e, n) {
2844
+ function Ce(e, n) {
2788
2845
  return n ? n === "center" ? e.getCenterVisibleLeafColumns() : n === "left" ? e.getLeftVisibleLeafColumns() : e.getRightVisibleLeafColumns() : e.getVisibleLeafColumns();
2789
2846
  }
2790
- const Sr = {
2847
+ const xr = {
2791
2848
  createTable: (e) => {
2792
2849
  e._getGlobalFacetedRowModel = e.options.getFacetedRowModel && e.options.getFacetedRowModel(e, "__global__"), e.getGlobalFacetedRowModel = () => e.options.manualFiltering || !e._getGlobalFacetedRowModel ? e.getPreFilteredRowModel() : e._getGlobalFacetedRowModel(), e._getGlobalFacetedUniqueValues = e.options.getFacetedUniqueValues && e.options.getFacetedUniqueValues(e, "__global__"), e.getGlobalFacetedUniqueValues = () => e._getGlobalFacetedUniqueValues ? e._getGlobalFacetedUniqueValues() : /* @__PURE__ */ new Map(), e._getGlobalFacetedMinMaxValues = e.options.getFacetedMinMaxValues && e.options.getFacetedMinMaxValues(e, "__global__"), e.getGlobalFacetedMinMaxValues = () => {
2793
2850
  if (e._getGlobalFacetedMinMaxValues)
2794
2851
  return e._getGlobalFacetedMinMaxValues();
2795
2852
  };
2796
2853
  }
2797
- }, vr = {
2854
+ }, Rr = {
2798
2855
  getInitialState: (e) => ({
2799
2856
  globalFilter: void 0,
2800
2857
  ...e
2801
2858
  }),
2802
2859
  getDefaultOptions: (e) => ({
2803
- onGlobalFilterChange: H("globalFilter", e),
2860
+ onGlobalFilterChange: q("globalFilter", e),
2804
2861
  globalFilterFn: "auto",
2805
2862
  getColumnCanGlobalFilter: (n) => {
2806
2863
  var t;
@@ -2820,20 +2877,20 @@ const Sr = {
2820
2877
  const {
2821
2878
  globalFilterFn: o
2822
2879
  } = e.options;
2823
- return Ve(o) ? o : o === "auto" ? e.getGlobalAutoFilterFn() : (n = (t = e.options.filterFns) == null ? void 0 : t[o]) != null ? n : Q[o];
2880
+ return Te(o) ? o : o === "auto" ? e.getGlobalAutoFilterFn() : (n = (t = e.options.filterFns) == null ? void 0 : t[o]) != null ? n : Q[o];
2824
2881
  }, e.setGlobalFilter = (n) => {
2825
2882
  e.options.onGlobalFilterChange == null || e.options.onGlobalFilterChange(n);
2826
2883
  }, e.resetGlobalFilter = (n) => {
2827
2884
  e.setGlobalFilter(n ? void 0 : e.initialState.globalFilter);
2828
2885
  };
2829
2886
  }
2830
- }, Cr = {
2887
+ }, jr = {
2831
2888
  getInitialState: (e) => ({
2832
2889
  expanded: {},
2833
2890
  ...e
2834
2891
  }),
2835
2892
  getDefaultOptions: (e) => ({
2836
- onExpandedChange: H("expanded", e),
2893
+ onExpandedChange: q("expanded", e),
2837
2894
  paginateExpandedRows: !0
2838
2895
  }),
2839
2896
  createTable: (e) => {
@@ -2917,7 +2974,7 @@ const Sr = {
2917
2974
  }, tt = 0, nt = 10, Ue = () => ({
2918
2975
  pageIndex: tt,
2919
2976
  pageSize: nt
2920
- }), wr = {
2977
+ }), yr = {
2921
2978
  getInitialState: (e) => ({
2922
2979
  ...e,
2923
2980
  pagination: {
@@ -2926,7 +2983,7 @@ const Sr = {
2926
2983
  }
2927
2984
  }),
2928
2985
  getDefaultOptions: (e) => ({
2929
- onPaginationChange: H("pagination", e)
2986
+ onPaginationChange: q("pagination", e)
2930
2987
  }),
2931
2988
  createTable: (e) => {
2932
2989
  let n = !1, t = !1;
@@ -2997,32 +3054,32 @@ const Sr = {
2997
3054
  return (o = e.options.rowCount) != null ? o : e.getPrePaginationRowModel().rows.length;
2998
3055
  };
2999
3056
  }
3000
- }, Ke = () => ({
3057
+ }, Ye = () => ({
3001
3058
  top: [],
3002
3059
  bottom: []
3003
- }), xr = {
3060
+ }), _r = {
3004
3061
  getInitialState: (e) => ({
3005
- rowPinning: Ke(),
3062
+ rowPinning: Ye(),
3006
3063
  ...e
3007
3064
  }),
3008
3065
  getDefaultOptions: (e) => ({
3009
- onRowPinningChange: H("rowPinning", e)
3066
+ onRowPinningChange: q("rowPinning", e)
3010
3067
  }),
3011
3068
  createRow: (e, n) => {
3012
3069
  e.pin = (t, o, r) => {
3013
3070
  const i = o ? e.getLeafRows().map((u) => {
3014
3071
  let {
3015
- id: c
3072
+ id: d
3016
3073
  } = u;
3017
- return c;
3074
+ return d;
3018
3075
  }) : [], s = r ? e.getParentRows().map((u) => {
3019
3076
  let {
3020
- id: c
3077
+ id: d
3021
3078
  } = u;
3022
- return c;
3079
+ return d;
3023
3080
  }) : [], a = /* @__PURE__ */ new Set([...s, e.id, ...i]);
3024
3081
  n.setRowPinning((u) => {
3025
- var c, g;
3082
+ var d, g;
3026
3083
  if (t === "bottom") {
3027
3084
  var m, p;
3028
3085
  return {
@@ -3031,14 +3088,14 @@ const Sr = {
3031
3088
  };
3032
3089
  }
3033
3090
  if (t === "top") {
3034
- var d, f;
3091
+ var c, f;
3035
3092
  return {
3036
- top: [...((d = u == null ? void 0 : u.top) != null ? d : []).filter((h) => !(a != null && a.has(h))), ...Array.from(a)],
3093
+ top: [...((c = u == null ? void 0 : u.top) != null ? c : []).filter((h) => !(a != null && a.has(h))), ...Array.from(a)],
3037
3094
  bottom: ((f = u == null ? void 0 : u.bottom) != null ? f : []).filter((h) => !(a != null && a.has(h)))
3038
3095
  };
3039
3096
  }
3040
3097
  return {
3041
- top: ((c = u == null ? void 0 : u.top) != null ? c : []).filter((h) => !(a != null && a.has(h))),
3098
+ top: ((d = u == null ? void 0 : u.top) != null ? d : []).filter((h) => !(a != null && a.has(h))),
3042
3099
  bottom: ((g = u == null ? void 0 : u.bottom) != null ? g : []).filter((h) => !(a != null && a.has(h)))
3043
3100
  };
3044
3101
  });
@@ -3071,7 +3128,7 @@ const Sr = {
3071
3128
  createTable: (e) => {
3072
3129
  e.setRowPinning = (n) => e.options.onRowPinningChange == null ? void 0 : e.options.onRowPinningChange(n), e.resetRowPinning = (n) => {
3073
3130
  var t, o;
3074
- return e.setRowPinning(n ? Ke() : (t = (o = e.initialState) == null ? void 0 : o.rowPinning) != null ? t : Ke());
3131
+ return e.setRowPinning(n ? Ye() : (t = (o = e.initialState) == null ? void 0 : o.rowPinning) != null ? t : Ye());
3075
3132
  }, e.getIsSomeRowsPinned = (n) => {
3076
3133
  var t;
3077
3134
  const o = e.getState().rowPinning;
@@ -3101,13 +3158,13 @@ const Sr = {
3101
3158
  return n.filter((i) => !r.has(i.id));
3102
3159
  }, x(e.options, "debugRows", "getCenterRows"));
3103
3160
  }
3104
- }, Rr = {
3161
+ }, Fr = {
3105
3162
  getInitialState: (e) => ({
3106
3163
  rowSelection: {},
3107
3164
  ...e
3108
3165
  }),
3109
3166
  getDefaultOptions: (e) => ({
3110
- onRowSelectionChange: H("rowSelection", e),
3167
+ onRowSelectionChange: q("rowSelection", e),
3111
3168
  enableRowSelection: !0,
3112
3169
  enableMultiRowSelection: !0,
3113
3170
  enableSubRowSelection: !0
@@ -3138,15 +3195,15 @@ const Sr = {
3138
3195
  return e.getRowModel().rows.forEach((i) => {
3139
3196
  ot(r, i.id, o, !0, e);
3140
3197
  }), r;
3141
- }), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = w(() => [e.getState().rowSelection, e.getCoreRowModel()], (n, t) => Object.keys(n).length ? Ye(e, t) : {
3198
+ }), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = w(() => [e.getState().rowSelection, e.getCoreRowModel()], (n, t) => Object.keys(n).length ? Ke(e, t) : {
3142
3199
  rows: [],
3143
3200
  flatRows: [],
3144
3201
  rowsById: {}
3145
- }, x(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = w(() => [e.getState().rowSelection, e.getFilteredRowModel()], (n, t) => Object.keys(n).length ? Ye(e, t) : {
3202
+ }, x(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = w(() => [e.getState().rowSelection, e.getFilteredRowModel()], (n, t) => Object.keys(n).length ? Ke(e, t) : {
3146
3203
  rows: [],
3147
3204
  flatRows: [],
3148
3205
  rowsById: {}
3149
- }, x(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = w(() => [e.getState().rowSelection, e.getSortedRowModel()], (n, t) => Object.keys(n).length ? Ye(e, t) : {
3206
+ }, x(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = w(() => [e.getState().rowSelection, e.getSortedRowModel()], (n, t) => Object.keys(n).length ? Ke(e, t) : {
3150
3207
  rows: [],
3151
3208
  flatRows: [],
3152
3209
  rowsById: {}
@@ -3224,12 +3281,12 @@ const Sr = {
3224
3281
  const s = r.getRow(n, !0);
3225
3282
  t ? (s.getCanMultiSelect() || Object.keys(e).forEach((a) => delete e[a]), s.getCanSelect() && (e[n] = !0)) : delete e[n], o && (i = s.subRows) != null && i.length && s.getCanSelectSubRows() && s.subRows.forEach((a) => ot(e, a.id, t, o, r));
3226
3283
  };
3227
- function Ye(e, n) {
3284
+ function Ke(e, n) {
3228
3285
  const t = e.getState().rowSelection, o = [], r = {}, i = function(s, a) {
3229
3286
  return s.map((u) => {
3230
- var c;
3287
+ var d;
3231
3288
  const g = ht(u, t);
3232
- if (g && (o.push(u), r[u.id] = u), (c = u.subRows) != null && c.length && (u = {
3289
+ if (g && (o.push(u), r[u.id] = u), (d = u.subRows) != null && d.length && (u = {
3233
3290
  ...u,
3234
3291
  subRows: i(u.subRows)
3235
3292
  }), g)
@@ -3257,10 +3314,10 @@ function rt(e, n, t) {
3257
3314
  }
3258
3315
  }), r ? "all" : i ? "some" : !1;
3259
3316
  }
3260
- const it = /([0-9]+)/gm, yr = (e, n, t) => xn(ne(e.getValue(t)).toLowerCase(), ne(n.getValue(t)).toLowerCase()), jr = (e, n, t) => xn(ne(e.getValue(t)), ne(n.getValue(t))), _r = (e, n, t) => St(ne(e.getValue(t)).toLowerCase(), ne(n.getValue(t)).toLowerCase()), Fr = (e, n, t) => St(ne(e.getValue(t)), ne(n.getValue(t))), Ir = (e, n, t) => {
3317
+ const it = /([0-9]+)/gm, Ir = (e, n, t) => xn(ne(e.getValue(t)).toLowerCase(), ne(n.getValue(t)).toLowerCase()), Pr = (e, n, t) => xn(ne(e.getValue(t)), ne(n.getValue(t))), Er = (e, n, t) => St(ne(e.getValue(t)).toLowerCase(), ne(n.getValue(t)).toLowerCase()), $r = (e, n, t) => St(ne(e.getValue(t)), ne(n.getValue(t))), Mr = (e, n, t) => {
3261
3318
  const o = e.getValue(t), r = n.getValue(t);
3262
3319
  return o > r ? 1 : o < r ? -1 : 0;
3263
- }, Pr = (e, n, t) => St(e.getValue(t), n.getValue(t));
3320
+ }, br = (e, n, t) => St(e.getValue(t), n.getValue(t));
3264
3321
  function St(e, n) {
3265
3322
  return e === n ? 0 : e > n ? 1 : -1;
3266
3323
  }
@@ -3287,14 +3344,14 @@ function xn(e, n) {
3287
3344
  }
3288
3345
  return t.length - o.length;
3289
3346
  }
3290
- const pe = {
3291
- alphanumeric: yr,
3292
- alphanumericCaseSensitive: jr,
3293
- text: _r,
3294
- textCaseSensitive: Fr,
3295
- datetime: Ir,
3296
- basic: Pr
3297
- }, Er = {
3347
+ const he = {
3348
+ alphanumeric: Ir,
3349
+ alphanumericCaseSensitive: Pr,
3350
+ text: Er,
3351
+ textCaseSensitive: $r,
3352
+ datetime: Mr,
3353
+ basic: br
3354
+ }, Dr = {
3298
3355
  getInitialState: (e) => ({
3299
3356
  sorting: [],
3300
3357
  ...e
@@ -3304,7 +3361,7 @@ const pe = {
3304
3361
  sortUndefined: 1
3305
3362
  }),
3306
3363
  getDefaultOptions: (e) => ({
3307
- onSortingChange: H("sorting", e),
3364
+ onSortingChange: q("sorting", e),
3308
3365
  isMultiSortEvent: (n) => n.shiftKey
3309
3366
  }),
3310
3367
  createColumn: (e, n) => {
@@ -3314,11 +3371,11 @@ const pe = {
3314
3371
  for (const r of t) {
3315
3372
  const i = r == null ? void 0 : r.getValue(e.id);
3316
3373
  if (Object.prototype.toString.call(i) === "[object Date]")
3317
- return pe.datetime;
3374
+ return he.datetime;
3318
3375
  if (typeof i == "string" && (o = !0, i.split(it).length > 1))
3319
- return pe.alphanumeric;
3376
+ return he.alphanumeric;
3320
3377
  }
3321
- return o ? pe.text : pe.basic;
3378
+ return o ? he.text : he.basic;
3322
3379
  }, e.getAutoSortDir = () => {
3323
3380
  const t = n.getFilteredRowModel().flatRows[0];
3324
3381
  return typeof (t == null ? void 0 : t.getValue(e.id)) == "string" ? "asc" : "desc";
@@ -3326,26 +3383,26 @@ const pe = {
3326
3383
  var t, o;
3327
3384
  if (!e)
3328
3385
  throw new Error();
3329
- return Ve(e.columnDef.sortingFn) ? e.columnDef.sortingFn : e.columnDef.sortingFn === "auto" ? e.getAutoSortingFn() : (t = (o = n.options.sortingFns) == null ? void 0 : o[e.columnDef.sortingFn]) != null ? t : pe[e.columnDef.sortingFn];
3386
+ return Te(e.columnDef.sortingFn) ? e.columnDef.sortingFn : e.columnDef.sortingFn === "auto" ? e.getAutoSortingFn() : (t = (o = n.options.sortingFns) == null ? void 0 : o[e.columnDef.sortingFn]) != null ? t : he[e.columnDef.sortingFn];
3330
3387
  }, e.toggleSorting = (t, o) => {
3331
3388
  const r = e.getNextSortingOrder(), i = typeof t < "u" && t !== null;
3332
3389
  n.setSorting((s) => {
3333
- const a = s == null ? void 0 : s.find((d) => d.id === e.id), u = s == null ? void 0 : s.findIndex((d) => d.id === e.id);
3334
- let c = [], g, m = i ? t : r === "desc";
3390
+ const a = s == null ? void 0 : s.find((c) => c.id === e.id), u = s == null ? void 0 : s.findIndex((c) => c.id === e.id);
3391
+ let d = [], g, m = i ? t : r === "desc";
3335
3392
  if (s != null && s.length && e.getCanMultiSort() && o ? a ? g = "toggle" : g = "add" : s != null && s.length && u !== s.length - 1 ? g = "replace" : a ? g = "toggle" : g = "replace", g === "toggle" && (i || r || (g = "remove")), g === "add") {
3336
3393
  var p;
3337
- c = [...s, {
3394
+ d = [...s, {
3338
3395
  id: e.id,
3339
3396
  desc: m
3340
- }], c.splice(0, c.length - ((p = n.options.maxMultiSortColCount) != null ? p : Number.MAX_SAFE_INTEGER));
3341
- } else g === "toggle" ? c = s.map((d) => d.id === e.id ? {
3342
- ...d,
3397
+ }], d.splice(0, d.length - ((p = n.options.maxMultiSortColCount) != null ? p : Number.MAX_SAFE_INTEGER));
3398
+ } else g === "toggle" ? d = s.map((c) => c.id === e.id ? {
3399
+ ...c,
3343
3400
  desc: m
3344
- } : d) : g === "remove" ? c = s.filter((d) => d.id !== e.id) : c = [{
3401
+ } : c) : g === "remove" ? d = s.filter((c) => c.id !== e.id) : d = [{
3345
3402
  id: e.id,
3346
3403
  desc: m
3347
3404
  }];
3348
- return c;
3405
+ return d;
3349
3406
  });
3350
3407
  }, e.getFirstSortDir = () => {
3351
3408
  var t, o;
@@ -3383,34 +3440,34 @@ const pe = {
3383
3440
  e.setSorting(n ? [] : (t = (o = e.initialState) == null ? void 0 : o.sorting) != null ? t : []);
3384
3441
  }, e.getPreSortedRowModel = () => e.getGroupedRowModel(), e.getSortedRowModel = () => (!e._getSortedRowModel && e.options.getSortedRowModel && (e._getSortedRowModel = e.options.getSortedRowModel(e)), e.options.manualSorting || !e._getSortedRowModel ? e.getPreSortedRowModel() : e._getSortedRowModel());
3385
3442
  }
3386
- }, $r = [
3387
- Xo,
3443
+ }, Vr = [
3444
+ er,
3445
+ wr,
3446
+ pr,
3388
3447
  hr,
3389
- cr,
3390
- gr,
3391
- Qo,
3392
- Zo,
3393
- Sr,
3448
+ nr,
3449
+ or,
3450
+ xr,
3394
3451
  //depends on ColumnFaceting
3395
- vr,
3452
+ Rr,
3396
3453
  //depends on ColumnFiltering
3397
- Er,
3398
- ur,
3454
+ Dr,
3455
+ fr,
3399
3456
  //depends on RowSorting
3400
- Cr,
3401
- wr,
3402
- xr,
3403
- Rr,
3404
- mr
3457
+ jr,
3458
+ yr,
3459
+ _r,
3460
+ Fr,
3461
+ vr
3405
3462
  ];
3406
- function Mr(e) {
3463
+ function Tr(e) {
3407
3464
  var n, t;
3408
3465
  process.env.NODE_ENV !== "production" && (e.debugAll || e.debugTable) && console.info("Creating Table Instance...");
3409
- const o = [...$r, ...(n = e._features) != null ? n : []];
3466
+ const o = [...Vr, ...(n = e._features) != null ? n : []];
3410
3467
  let r = {
3411
3468
  _features: o
3412
3469
  };
3413
- const i = r._features.reduce((p, d) => Object.assign(p, d.getDefaultOptions == null ? void 0 : d.getDefaultOptions(r)), {}), s = (p) => r.options.mergeOptions ? r.options.mergeOptions(i, p) : {
3470
+ const i = r._features.reduce((p, c) => Object.assign(p, c.getDefaultOptions == null ? void 0 : c.getDefaultOptions(r)), {}), s = (p) => r.options.mergeOptions ? r.options.mergeOptions(i, p) : {
3414
3471
  ...i,
3415
3472
  ...p
3416
3473
  };
@@ -3419,10 +3476,10 @@ function Mr(e) {
3419
3476
  ...(t = e.initialState) != null ? t : {}
3420
3477
  };
3421
3478
  r._features.forEach((p) => {
3422
- var d;
3423
- u = (d = p.getInitialState == null ? void 0 : p.getInitialState(u)) != null ? d : u;
3479
+ var c;
3480
+ u = (c = p.getInitialState == null ? void 0 : p.getInitialState(u)) != null ? c : u;
3424
3481
  });
3425
- const c = [];
3482
+ const d = [];
3426
3483
  let g = !1;
3427
3484
  const m = {
3428
3485
  _features: o,
@@ -3432,43 +3489,43 @@ function Mr(e) {
3432
3489
  },
3433
3490
  initialState: u,
3434
3491
  _queue: (p) => {
3435
- c.push(p), g || (g = !0, Promise.resolve().then(() => {
3436
- for (; c.length; )
3437
- c.shift()();
3492
+ d.push(p), g || (g = !0, Promise.resolve().then(() => {
3493
+ for (; d.length; )
3494
+ d.shift()();
3438
3495
  g = !1;
3439
- }).catch((d) => setTimeout(() => {
3440
- throw d;
3496
+ }).catch((c) => setTimeout(() => {
3497
+ throw c;
3441
3498
  })));
3442
3499
  },
3443
3500
  reset: () => {
3444
3501
  r.setState(r.initialState);
3445
3502
  },
3446
3503
  setOptions: (p) => {
3447
- const d = te(p, r.options);
3448
- r.options = s(d);
3504
+ const c = te(p, r.options);
3505
+ r.options = s(c);
3449
3506
  },
3450
3507
  getState: () => r.options.state,
3451
3508
  setState: (p) => {
3452
3509
  r.options.onStateChange == null || r.options.onStateChange(p);
3453
3510
  },
3454
- _getRowId: (p, d, f) => {
3511
+ _getRowId: (p, c, f) => {
3455
3512
  var h;
3456
- return (h = r.options.getRowId == null ? void 0 : r.options.getRowId(p, d, f)) != null ? h : `${f ? [f.id, d].join(".") : d}`;
3513
+ return (h = r.options.getRowId == null ? void 0 : r.options.getRowId(p, c, f)) != null ? h : `${f ? [f.id, c].join(".") : c}`;
3457
3514
  },
3458
3515
  getCoreRowModel: () => (r._getCoreRowModel || (r._getCoreRowModel = r.options.getCoreRowModel(r)), r._getCoreRowModel()),
3459
3516
  // The final calls start at the bottom of the model,
3460
3517
  // expanded rows, which then work their way up
3461
3518
  getRowModel: () => r.getPaginationRowModel(),
3462
3519
  //in next version, we should just pass in the row model as the optional 2nd arg
3463
- getRow: (p, d) => {
3464
- let f = (d ? r.getPrePaginationRowModel() : r.getRowModel()).rowsById[p];
3520
+ getRow: (p, c) => {
3521
+ let f = (c ? r.getPrePaginationRowModel() : r.getRowModel()).rowsById[p];
3465
3522
  if (!f && (f = r.getCoreRowModel().rowsById[p], !f))
3466
3523
  throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${p}`) : new Error();
3467
3524
  return f;
3468
3525
  },
3469
3526
  _getDefaultColumnDef: w(() => [r.options.defaultColumn], (p) => {
3470
- var d;
3471
- return p = (d = p) != null ? d : {}, {
3527
+ var c;
3528
+ return p = (c = p) != null ? c : {}, {
3472
3529
  header: (f) => {
3473
3530
  const h = f.header.column.columnDef;
3474
3531
  return h.accessorKey ? h.accessorKey : h.accessorFn ? h.id : null;
@@ -3484,29 +3541,29 @@ function Mr(e) {
3484
3541
  }, x(e, "debugColumns", "_getDefaultColumnDef")),
3485
3542
  _getColumnDefs: () => r.options.columns,
3486
3543
  getAllColumns: w(() => [r._getColumnDefs()], (p) => {
3487
- const d = function(f, h, v) {
3544
+ const c = function(f, h, v) {
3488
3545
  return v === void 0 && (v = 0), f.map((S) => {
3489
- const R = Wo(r, S, v, h), j = S;
3490
- return R.columns = j.columns ? d(j.columns, R, v + 1) : [], R;
3546
+ const R = Zo(r, S, v, h), y = S;
3547
+ return R.columns = y.columns ? c(y.columns, R, v + 1) : [], R;
3491
3548
  });
3492
3549
  };
3493
- return d(p);
3550
+ return c(p);
3494
3551
  }, x(e, "debugColumns", "getAllColumns")),
3495
- getAllFlatColumns: w(() => [r.getAllColumns()], (p) => p.flatMap((d) => d.getFlatColumns()), x(e, "debugColumns", "getAllFlatColumns")),
3496
- _getAllFlatColumnsById: w(() => [r.getAllFlatColumns()], (p) => p.reduce((d, f) => (d[f.id] = f, d), {}), x(e, "debugColumns", "getAllFlatColumnsById")),
3497
- getAllLeafColumns: w(() => [r.getAllColumns(), r._getOrderColumnsFn()], (p, d) => {
3552
+ getAllFlatColumns: w(() => [r.getAllColumns()], (p) => p.flatMap((c) => c.getFlatColumns()), x(e, "debugColumns", "getAllFlatColumns")),
3553
+ _getAllFlatColumnsById: w(() => [r.getAllFlatColumns()], (p) => p.reduce((c, f) => (c[f.id] = f, c), {}), x(e, "debugColumns", "getAllFlatColumnsById")),
3554
+ getAllLeafColumns: w(() => [r.getAllColumns(), r._getOrderColumnsFn()], (p, c) => {
3498
3555
  let f = p.flatMap((h) => h.getLeafColumns());
3499
- return d(f);
3556
+ return c(f);
3500
3557
  }, x(e, "debugColumns", "getAllLeafColumns")),
3501
3558
  getColumn: (p) => {
3502
- const d = r._getAllFlatColumnsById()[p];
3503
- return process.env.NODE_ENV !== "production" && !d && console.error(`[Table] Column with id '${p}' does not exist.`), d;
3559
+ const c = r._getAllFlatColumnsById()[p];
3560
+ return process.env.NODE_ENV !== "production" && !c && console.error(`[Table] Column with id '${p}' does not exist.`), c;
3504
3561
  }
3505
3562
  };
3506
3563
  Object.assign(r, m);
3507
3564
  for (let p = 0; p < r._features.length; p++) {
3508
- const d = r._features[p];
3509
- d == null || d.createTable == null || d.createTable(r);
3565
+ const c = r._features[p];
3566
+ c == null || c.createTable == null || c.createTable(r);
3510
3567
  }
3511
3568
  return r;
3512
3569
  }
@@ -3519,11 +3576,11 @@ function Rn() {
3519
3576
  }, o = function(r, i, s) {
3520
3577
  i === void 0 && (i = 0);
3521
3578
  const a = [];
3522
- for (let c = 0; c < r.length; c++) {
3523
- const g = Jo(e, e._getRowId(r[c], c, s), r[c], c, i, void 0, s == null ? void 0 : s.id);
3579
+ for (let d = 0; d < r.length; d++) {
3580
+ const g = tr(e, e._getRowId(r[d], d, s), r[d], d, i, void 0, s == null ? void 0 : s.id);
3524
3581
  if (t.flatRows.push(g), t.rowsById[g.id] = g, a.push(g), e.options.getSubRows) {
3525
3582
  var u;
3526
- g.originalSubRows = e.options.getSubRows(r[c], c), (u = g.originalSubRows) != null && u.length && (g.subRows = o(g.originalSubRows, i + 1, g));
3583
+ g.originalSubRows = e.options.getSubRows(r[d], d), (u = g.originalSubRows) != null && u.length && (g.subRows = o(g.originalSubRows, i + 1, g));
3527
3584
  }
3528
3585
  }
3529
3586
  return a;
@@ -3531,7 +3588,7 @@ function Rn() {
3531
3588
  return t.rows = o(n), t;
3532
3589
  }, x(e.options, "debugTable", "getRowModel", () => e._autoResetPageIndex()));
3533
3590
  }
3534
- function br(e) {
3591
+ function Ar(e) {
3535
3592
  const n = [], t = (o) => {
3536
3593
  var r;
3537
3594
  n.push(o), (r = o.subRows) != null && r.length && o.getIsExpanded() && o.subRows.forEach(t);
@@ -3542,7 +3599,7 @@ function br(e) {
3542
3599
  rowsById: e.rowsById
3543
3600
  };
3544
3601
  }
3545
- function Dr(e) {
3602
+ function Nr(e) {
3546
3603
  return (n) => w(() => [n.getState().pagination, n.getPrePaginationRowModel(), n.options.paginateExpandedRows ? void 0 : n.getState().expanded], (t, o) => {
3547
3604
  if (!o.rows.length)
3548
3605
  return o;
@@ -3555,20 +3612,20 @@ function Dr(e) {
3555
3612
  flatRows: a,
3556
3613
  rowsById: u
3557
3614
  } = o;
3558
- const c = r * i, g = c + r;
3559
- s = s.slice(c, g);
3615
+ const d = r * i, g = d + r;
3616
+ s = s.slice(d, g);
3560
3617
  let m;
3561
3618
  n.options.paginateExpandedRows ? m = {
3562
3619
  rows: s,
3563
3620
  flatRows: a,
3564
3621
  rowsById: u
3565
- } : m = br({
3622
+ } : m = Ar({
3566
3623
  rows: s,
3567
3624
  flatRows: a,
3568
3625
  rowsById: u
3569
3626
  }), m.flatRows = [];
3570
- const p = (d) => {
3571
- m.flatRows.push(d), d.subRows.length && d.subRows.forEach(p);
3627
+ const p = (c) => {
3628
+ m.flatRows.push(c), c.subRows.length && c.subRows.forEach(p);
3572
3629
  };
3573
3630
  return m.rows.forEach(p), m;
3574
3631
  }, x(n.options, "debugTable", "getPaginationRowModel"));
@@ -3584,21 +3641,21 @@ function Dr(e) {
3584
3641
  * @license MIT
3585
3642
  */
3586
3643
  function kt(e, n) {
3587
- return e ? Vr(e) ? /* @__PURE__ */ Xe.createElement(e, n) : e : null;
3644
+ return e ? kr(e) ? /* @__PURE__ */ Xe.createElement(e, n) : e : null;
3588
3645
  }
3589
- function Vr(e) {
3590
- return Tr(e) || typeof e == "function" || Ar(e);
3646
+ function kr(e) {
3647
+ return Lr(e) || typeof e == "function" || Or(e);
3591
3648
  }
3592
- function Tr(e) {
3649
+ function Lr(e) {
3593
3650
  return typeof e == "function" && (() => {
3594
3651
  const n = Object.getPrototypeOf(e);
3595
3652
  return n.prototype && n.prototype.isReactComponent;
3596
3653
  })();
3597
3654
  }
3598
- function Ar(e) {
3655
+ function Or(e) {
3599
3656
  return typeof e == "object" && typeof e.$$typeof == "symbol" && ["react.memo", "react.forward_ref"].includes(e.$$typeof.description);
3600
3657
  }
3601
- function yn(e) {
3658
+ function jn(e) {
3602
3659
  const n = {
3603
3660
  state: {},
3604
3661
  // Dummy state
@@ -3608,7 +3665,7 @@ function yn(e) {
3608
3665
  renderFallbackValue: null,
3609
3666
  ...e
3610
3667
  }, [t] = Xe.useState(() => ({
3611
- current: Mr(n)
3668
+ current: Tr(n)
3612
3669
  })), [o, r] = Xe.useState(() => t.current.initialState);
3613
3670
  return t.current.setOptions((i) => ({
3614
3671
  ...i,
@@ -3624,24 +3681,24 @@ function yn(e) {
3624
3681
  }
3625
3682
  })), t.current;
3626
3683
  }
3627
- const jn = ({
3684
+ const yn = ({
3628
3685
  actions: e,
3629
3686
  reloadData: n,
3630
3687
  selectedRowKeys: t,
3631
3688
  size: o = "xs"
3632
- }) => /* @__PURE__ */ l.jsxs(L, { gap: o, children: [
3689
+ }) => /* @__PURE__ */ l.jsxs(O, { gap: o, children: [
3633
3690
  (e == null ? void 0 : e.add) && /* @__PURE__ */ l.jsx(
3634
- q,
3691
+ z,
3635
3692
  {
3636
3693
  variant: "light",
3637
- leftSection: /* @__PURE__ */ l.jsx(Yn, { size: 16, stroke: 1.5 }),
3694
+ leftSection: /* @__PURE__ */ l.jsx(Kn, { size: 16, stroke: 1.5 }),
3638
3695
  size: o,
3639
3696
  onClick: e.add,
3640
3697
  children: "Add"
3641
3698
  }
3642
3699
  ),
3643
3700
  (e == null ? void 0 : e.edit) && /* @__PURE__ */ l.jsx(
3644
- q,
3701
+ z,
3645
3702
  {
3646
3703
  leftSection: /* @__PURE__ */ l.jsx(Wn, { size: 16, stroke: 1.5 }),
3647
3704
  size: o,
@@ -3651,10 +3708,33 @@ const jn = ({
3651
3708
  children: "Edit"
3652
3709
  }
3653
3710
  ),
3711
+ (e == null ? void 0 : e.delete) && /* @__PURE__ */ l.jsx(
3712
+ Ro,
3713
+ {
3714
+ title: `Delete ${t.length} item${t.length > 1 ? "s" : ""}?`,
3715
+ onConfirm: () => {
3716
+ var r;
3717
+ return (r = e.delete) == null ? void 0 : r.call(e, t);
3718
+ },
3719
+ confirmProps: { color: "red" },
3720
+ disabled: t.length === 0,
3721
+ children: /* @__PURE__ */ l.jsx(
3722
+ z,
3723
+ {
3724
+ leftSection: /* @__PURE__ */ l.jsx(Xn, { size: 16, stroke: 1.5 }),
3725
+ size: o,
3726
+ variant: "light",
3727
+ color: "red",
3728
+ disabled: t.length === 0,
3729
+ children: "Delete"
3730
+ }
3731
+ )
3732
+ }
3733
+ ),
3654
3734
  (e == null ? void 0 : e.reload) && /* @__PURE__ */ l.jsx(
3655
- q,
3735
+ z,
3656
3736
  {
3657
- leftSection: /* @__PURE__ */ l.jsx(Xn, { size: 16, stroke: 1.5 }),
3737
+ leftSection: /* @__PURE__ */ l.jsx(Jn, { size: 16, stroke: 1.5 }),
3658
3738
  size: o,
3659
3739
  onClick: n,
3660
3740
  variant: "light",
@@ -3662,9 +3742,9 @@ const jn = ({
3662
3742
  }
3663
3743
  ),
3664
3744
  (e == null ? void 0 : e.import) && /* @__PURE__ */ l.jsx(
3665
- q,
3745
+ z,
3666
3746
  {
3667
- leftSection: /* @__PURE__ */ l.jsx(Jn, { size: 16, stroke: 1.5 }),
3747
+ leftSection: /* @__PURE__ */ l.jsx(Qn, { size: 16, stroke: 1.5 }),
3668
3748
  size: o,
3669
3749
  variant: "light",
3670
3750
  onClick: e.import,
@@ -3672,31 +3752,31 @@ const jn = ({
3672
3752
  }
3673
3753
  ),
3674
3754
  (e == null ? void 0 : e.export) && /* @__PURE__ */ l.jsx(
3675
- q,
3755
+ z,
3676
3756
  {
3677
- leftSection: /* @__PURE__ */ l.jsx(Qn, { size: 16, stroke: 1.5 }),
3757
+ leftSection: /* @__PURE__ */ l.jsx(Zn, { size: 16, stroke: 1.5 }),
3678
3758
  size: o,
3679
3759
  variant: "light",
3680
3760
  onClick: e.export,
3681
3761
  children: "Export"
3682
3762
  }
3683
3763
  )
3684
- ] }), _n = (e) => e !== void 0 && (e.add !== void 0 || e.edit !== void 0 || e.delete !== void 0 || e.export !== void 0 || e.reload === !0 || e.import !== void 0), Fn = (e) => e !== void 0 && (e.add !== void 0 || e.edit !== void 0 || e.delete !== void 0 || e.export !== void 0), Nr = "__selectcol__", { Thead: kr, Tr: We, Th: Or, Tbody: Lr, Td: Ot } = Yt, In = (e) => {
3764
+ ] }), _n = (e) => e !== void 0 && (e.add !== void 0 || e.edit !== void 0 || e.delete !== void 0 || e.export !== void 0 || e.reload === !0 || e.import !== void 0), Fn = (e) => e !== void 0 && (e.add !== void 0 || e.edit !== void 0 || e.delete !== void 0 || e.export !== void 0), zr = "__selectcol__", { Thead: Gr, Tr: We, Th: Hr, Tbody: qr, Td: Lt } = Kt, In = (e) => {
3685
3765
  let n;
3686
- e.table.getRowCount() === 0 ? n = /* @__PURE__ */ l.jsx(We, { children: /* @__PURE__ */ l.jsx(Ot, { colSpan: e.table.getVisibleLeafColumns().length, children: /* @__PURE__ */ l.jsxs(X, { justify: "center", align: "center", gap: "xs", children: [
3687
- /* @__PURE__ */ l.jsx(Zn, { color: "var(--mantine-color-dimmed)" }),
3766
+ e.table.getRowCount() === 0 ? n = /* @__PURE__ */ l.jsx(We, { children: /* @__PURE__ */ l.jsx(Lt, { colSpan: e.table.getVisibleLeafColumns().length, children: /* @__PURE__ */ l.jsxs(Y, { justify: "center", align: "center", gap: "xs", children: [
3767
+ /* @__PURE__ */ l.jsx(eo, { color: "var(--mantine-color-dimmed)" }),
3688
3768
  /* @__PURE__ */ l.jsx(E, { c: "dimmed", fz: "sm", children: "No records found." })
3689
3769
  ] }) }) }, "empty-row") : n = e.table.getRowModel().rows.map((i, s) => {
3690
- var u, c;
3770
+ var u, d;
3691
3771
  const a = [];
3692
3772
  for (const g of i.getVisibleCells()) {
3693
- const m = g.column.columnDef.meta, p = (u = m == null ? void 0 : m.rowSpan) == null ? void 0 : u.call(m, i.original, s), d = (c = m == null ? void 0 : m.colSpan) == null ? void 0 : c.call(m, i.original, s);
3694
- p === 0 || d === 0 || a.push(
3773
+ const m = g.column.columnDef.meta, p = (u = m == null ? void 0 : m.rowSpan) == null ? void 0 : u.call(m, i.original, s), c = (d = m == null ? void 0 : m.colSpan) == null ? void 0 : d.call(m, i.original, s);
3774
+ p === 0 || c === 0 || a.push(
3695
3775
  /* @__PURE__ */ l.jsx(
3696
- Ot,
3776
+ Lt,
3697
3777
  {
3698
3778
  rowSpan: p,
3699
- colSpan: d,
3779
+ colSpan: c,
3700
3780
  children: kt(g.column.columnDef.cell, g.getContext())
3701
3781
  },
3702
3782
  g.id
@@ -3713,17 +3793,17 @@ const jn = ({
3713
3793
  );
3714
3794
  });
3715
3795
  const t = /* @__PURE__ */ l.jsxs(
3716
- Yt,
3796
+ Kt,
3717
3797
  {
3718
3798
  striped: e.striped ?? !0,
3719
3799
  highlightOnHover: !0,
3720
3800
  verticalSpacing: "xs",
3721
3801
  tabularNums: !0,
3722
3802
  children: [
3723
- /* @__PURE__ */ l.jsx(kr, { children: e.table.getHeaderGroups().map((r) => /* @__PURE__ */ l.jsx(We, { children: r.headers.map((i) => /* @__PURE__ */ l.jsx(
3724
- Or,
3803
+ /* @__PURE__ */ l.jsx(Gr, { children: e.table.getHeaderGroups().map((r) => /* @__PURE__ */ l.jsx(We, { children: r.headers.map((i) => /* @__PURE__ */ l.jsx(
3804
+ Hr,
3725
3805
  {
3726
- w: i.id === Nr ? "1%" : void 0,
3806
+ w: i.id === zr ? "1%" : void 0,
3727
3807
  children: i.isPlaceholder ? null : kt(
3728
3808
  i.column.columnDef.header,
3729
3809
  i.getContext()
@@ -3731,21 +3811,21 @@ const jn = ({
3731
3811
  },
3732
3812
  i.id
3733
3813
  )) }, r.id)) }),
3734
- /* @__PURE__ */ l.jsx(Lr, { pos: "relative", children: n })
3814
+ /* @__PURE__ */ l.jsx(qr, { pos: "relative", children: n })
3735
3815
  ]
3736
3816
  }
3737
3817
  );
3738
3818
  if (!e.bordered) return t;
3739
3819
  const o = {};
3740
3820
  return e.hasTopSection && (o.borderTopLeftRadius = 0, o.borderTopRightRadius = 0), e.hasBottomSection && (o.borderBottomLeftRadius = 0, o.borderBottomRightRadius = 0), /* @__PURE__ */ l.jsx(ie, { withBorder: !0, p: 0, style: o, children: t });
3741
- }, zr = "_pageSizeSelectorActive_1wv6j_1", Gr = {
3742
- pageSizeSelectorActive: zr
3743
- }, Hr = ["10", "20", "50", "100"], Pn = ({
3821
+ }, Br = "_pageSizeSelectorActive_1wv6j_1", Ur = {
3822
+ pageSizeSelectorActive: Br
3823
+ }, Yr = ["10", "20", "50", "100"], Pn = ({
3744
3824
  total: e,
3745
3825
  pageIndex: n,
3746
3826
  pageSize: t,
3747
3827
  allowPageSizeChange: o = !0,
3748
- pageSizeOptions: r = Hr,
3828
+ pageSizeOptions: r = Yr,
3749
3829
  onUpdatePagination: i
3750
3830
  }) => {
3751
3831
  const s = /* @__PURE__ */ l.jsx(
@@ -3757,11 +3837,11 @@ const jn = ({
3757
3837
  onChange: (a) => i(a - 1, t)
3758
3838
  }
3759
3839
  );
3760
- return o ? /* @__PURE__ */ l.jsxs(L, { gap: "sm", children: [
3840
+ return o ? /* @__PURE__ */ l.jsxs(O, { gap: "sm", children: [
3761
3841
  /* @__PURE__ */ l.jsxs("div", { children: [
3762
3842
  /* @__PURE__ */ l.jsx(E, { size: "sm", component: "span", pr: "xs", c: "dimmed", children: "Records per page" }),
3763
3843
  /* @__PURE__ */ l.jsx(
3764
- qr,
3844
+ Kr,
3765
3845
  {
3766
3846
  size: "sm",
3767
3847
  values: r,
@@ -3774,14 +3854,14 @@ const jn = ({
3774
3854
  ] }),
3775
3855
  s
3776
3856
  ] }) : s;
3777
- }, Lt = {
3778
- xs: ge(22),
3779
- sm: ge(26),
3780
- md: ge(32),
3781
- lg: ge(38),
3782
- xl: ge(44)
3857
+ }, Ot = {
3858
+ xs: fe(22),
3859
+ sm: fe(26),
3860
+ md: fe(32),
3861
+ lg: fe(38),
3862
+ xl: fe(44)
3783
3863
  };
3784
- function qr({
3864
+ function Kr({
3785
3865
  size: e,
3786
3866
  values: n,
3787
3867
  value: t,
@@ -3789,15 +3869,15 @@ function qr({
3789
3869
  }) {
3790
3870
  return /* @__PURE__ */ l.jsxs(ae, { withinPortal: !0, withArrow: !0, offset: 2, children: [
3791
3871
  /* @__PURE__ */ l.jsx(Hn, { children: /* @__PURE__ */ l.jsx(
3792
- q,
3872
+ z,
3793
3873
  {
3794
3874
  size: e,
3795
3875
  variant: "default",
3796
- rightSection: /* @__PURE__ */ l.jsx(eo, { size: 16, stroke: 1.5 }),
3876
+ rightSection: /* @__PURE__ */ l.jsx(to, { size: 16, stroke: 1.5 }),
3797
3877
  style: [
3798
3878
  { fontWeight: "normal" },
3799
3879
  (r) => ({
3800
- height: Lt[e],
3880
+ height: Ot[e],
3801
3881
  paddingLeft: r.spacing[e],
3802
3882
  paddingRight: r.spacing[e]
3803
3883
  })
@@ -3815,9 +3895,9 @@ function qr({
3815
3895
  return /* @__PURE__ */ l.jsx(
3816
3896
  Bn,
3817
3897
  {
3818
- className: i ? Gr.pageSizeSelectorActive : void 0,
3898
+ className: i ? Ur.pageSizeSelectorActive : void 0,
3819
3899
  style: [
3820
- { height: Lt[e] }
3900
+ { height: Ot[e] }
3821
3901
  // isCurrent
3822
3902
  // ? {
3823
3903
  // color: "var(--mantine-color-text)",
@@ -3835,8 +3915,8 @@ function qr({
3835
3915
  }) })
3836
3916
  ] });
3837
3917
  }
3838
- const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3839
- var S, R, j, I;
3918
+ const Wr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
3919
+ var S, R, y, I;
3840
3920
  const [n, t] = M({
3841
3921
  records: [],
3842
3922
  total: 0
@@ -3853,47 +3933,47 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3853
3933
  offset: P * k
3854
3934
  };
3855
3935
  e.query.update(F);
3856
- }, [c, g, m] = _(() => {
3936
+ }, [d, g, m] = _(() => {
3857
3937
  const P = e.query.query.limit, k = Math.floor(
3858
3938
  (e.query.query.offset || 0) / e.query.query.limit
3859
3939
  ), F = Math.ceil(n.total / e.query.query.limit);
3860
3940
  return [P, k, F];
3861
3941
  }, [e.query.query.limit, e.query.query.offset, n.total]);
3862
- De(() => (n.total == 0 && a(e.query.query), e.query.subscribe(a)), [e.query]);
3942
+ Ve(() => (n.total == 0 && a(e.query.query), e.query.subscribe(a)), [e.query]);
3863
3943
  const p = _(() => Object.keys(i).filter((P) => i[P]).map((P) => e.normalizeRowId(P)), [i]);
3864
- let d, f;
3865
- _n(e.actions) && (d = /* @__PURE__ */ l.jsx(
3866
- jn,
3944
+ let c, f;
3945
+ _n(e.actions) && (c = /* @__PURE__ */ l.jsx(
3946
+ yn,
3867
3947
  {
3868
3948
  actions: e.actions,
3869
3949
  reloadData: () => a(e.query.query),
3870
3950
  selectedRowKeys: p
3871
3951
  }
3872
3952
  ));
3873
- const h = ((S = e.pagination) == null ? void 0 : S.positions) || Br;
3953
+ const h = ((S = e.pagination) == null ? void 0 : S.positions) || Wr;
3874
3954
  if (h.size > 0) {
3875
3955
  const P = /* @__PURE__ */ l.jsx(
3876
3956
  Pn,
3877
3957
  {
3878
3958
  total: m,
3879
3959
  pageIndex: g,
3880
- pageSize: c,
3960
+ pageSize: d,
3881
3961
  onUpdatePagination: u,
3882
3962
  allowPageSizeChange: (R = e.pagination) == null ? void 0 : R.showSizeChanger,
3883
- pageSizeOptions: (I = (j = e.pagination) == null ? void 0 : j.pageSizeOptions) == null ? void 0 : I.map((k) => k.toString())
3963
+ pageSizeOptions: (I = (y = e.pagination) == null ? void 0 : y.pageSizeOptions) == null ? void 0 : I.map((k) => k.toString())
3884
3964
  }
3885
3965
  );
3886
- h.has("topRight") && (d !== void 0 ? d = /* @__PURE__ */ l.jsxs(L, { justify: "space-between", gap: "sm", children: [
3887
- d,
3966
+ h.has("topRight") && (c !== void 0 ? c = /* @__PURE__ */ l.jsxs(O, { justify: "space-between", gap: "sm", children: [
3967
+ c,
3888
3968
  P
3889
- ] }) : d = /* @__PURE__ */ l.jsx(B, { justify: "flex-end", children: P })), (h.has("bottomRight") || h.has("bottomLeft") || h.has("bottomCenter")) && (h.has("bottomLeft") ? f = /* @__PURE__ */ l.jsxs(B, { justify: "space-between", align: "center", children: [
3969
+ ] }) : c = /* @__PURE__ */ l.jsx(B, { justify: "flex-end", children: P })), (h.has("bottomRight") || h.has("bottomLeft") || h.has("bottomCenter")) && (h.has("bottomLeft") ? f = /* @__PURE__ */ l.jsxs(B, { justify: "space-between", align: "center", children: [
3890
3970
  P,
3891
3971
  /* @__PURE__ */ l.jsxs(E, { size: "sm", c: "dimmed", children: [
3892
3972
  "Showing ",
3893
- Math.min(g * c + 1, n.total),
3973
+ Math.min(g * d + 1, n.total),
3894
3974
  " to",
3895
3975
  " ",
3896
- Math.min((g + 1) * c, n.total),
3976
+ Math.min((g + 1) * d, n.total),
3897
3977
  " of ",
3898
3978
  n.total,
3899
3979
  " ",
@@ -3902,10 +3982,10 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3902
3982
  ] }) : f = /* @__PURE__ */ l.jsxs(B, { justify: "space-between", align: "center", children: [
3903
3983
  /* @__PURE__ */ l.jsxs(E, { size: "sm", c: "dimmed", children: [
3904
3984
  "Showing ",
3905
- Math.min(g * c + 1, n.total),
3985
+ Math.min(g * d + 1, n.total),
3906
3986
  " to",
3907
3987
  " ",
3908
- Math.min((g + 1) * c, n.total),
3988
+ Math.min((g + 1) * d, n.total),
3909
3989
  " of ",
3910
3990
  n.total,
3911
3991
  " ",
@@ -3917,7 +3997,7 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3917
3997
  const v = _(() => {
3918
3998
  const P = e.selectable ?? Fn(e.actions);
3919
3999
  return /* @__PURE__ */ l.jsx(
3920
- Ur,
4000
+ Xr,
3921
4001
  {
3922
4002
  data: n,
3923
4003
  loading: o,
@@ -3926,7 +4006,7 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3926
4006
  getRowId: e.getRowId,
3927
4007
  selectedRowKeys: i,
3928
4008
  setSelectedRowKeys: s,
3929
- hasTopSection: d !== void 0,
4009
+ hasTopSection: c !== void 0,
3930
4010
  hasBottomSection: f !== void 0
3931
4011
  }
3932
4012
  );
@@ -3938,11 +4018,11 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3938
4018
  e.getRowId,
3939
4019
  i,
3940
4020
  s,
3941
- d !== void 0,
4021
+ c !== void 0,
3942
4022
  f !== void 0
3943
4023
  ]);
3944
- return d === void 0 || f === void 0 ? v : /* @__PURE__ */ l.jsxs("div", { children: [
3945
- d !== void 0 && /* @__PURE__ */ l.jsx(
4024
+ return c === void 0 || f === void 0 ? v : /* @__PURE__ */ l.jsxs("div", { children: [
4025
+ c !== void 0 && /* @__PURE__ */ l.jsx(
3946
4026
  ie,
3947
4027
  {
3948
4028
  withBorder: !0,
@@ -3952,7 +4032,7 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3952
4032
  borderBottomRightRadius: 0,
3953
4033
  borderBottom: "none"
3954
4034
  },
3955
- children: d
4035
+ children: c
3956
4036
  }
3957
4037
  ),
3958
4038
  v,
@@ -3970,13 +4050,13 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3970
4050
  }
3971
4051
  )
3972
4052
  ] });
3973
- }, Ur = (e) => {
4053
+ }, Xr = (e) => {
3974
4054
  const n = _(() => {
3975
4055
  const o = [];
3976
4056
  e.isSelectable && o.push({
3977
4057
  id: "selection",
3978
4058
  header: ({ table: r }) => /* @__PURE__ */ l.jsx(
3979
- de,
4059
+ ce,
3980
4060
  {
3981
4061
  checked: r.getIsAllRowsSelected(),
3982
4062
  indeterminate: r.getIsSomeRowsSelected(),
@@ -3984,7 +4064,7 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
3984
4064
  }
3985
4065
  ),
3986
4066
  cell: ({ row: r }) => /* @__PURE__ */ l.jsx(
3987
- de,
4067
+ ce,
3988
4068
  {
3989
4069
  checked: r.getIsSelected(),
3990
4070
  disabled: !r.getCanSelect(),
@@ -4000,7 +4080,7 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
4000
4080
  cell: ({ row: i }) => r.render(i.original)
4001
4081
  });
4002
4082
  return o;
4003
- }, [e.columns, e.isSelectable]), t = yn({
4083
+ }, [e.columns, e.isSelectable]), t = jn({
4004
4084
  data: e.data.records,
4005
4085
  columns: n,
4006
4086
  enableRowSelection: e.isSelectable,
@@ -4027,35 +4107,39 @@ const Br = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Li = (e) => {
4027
4107
  function En(e, n, {
4028
4108
  title: t,
4029
4109
  nestedKey: o,
4030
- component: r
4110
+ component: r,
4111
+ rowSpan: i,
4112
+ colSpan: s
4031
4113
  } = {}) {
4032
- let i;
4114
+ let a;
4033
4115
  if (r !== void 0)
4034
- i = r;
4116
+ a = r;
4035
4117
  else if (se(n))
4036
- n.cardinality === "1:N" || n.cardinality === "N:N" ? i = mt : i = ft;
4118
+ n.cardinality === "1:N" || n.cardinality === "N:N" ? a = mt : a = ft;
4037
4119
  else {
4038
- if (ce[n.datatype] === void 0)
4120
+ if (ge[n.datatype] === void 0)
4039
4121
  throw new Error(
4040
4122
  `No display component found for datatype ${n.datatype}`
4041
4123
  );
4042
- i = ce[n.datatype];
4124
+ a = ge[n.datatype];
4043
4125
  }
4044
- const s = {
4126
+ const u = {
4045
4127
  key: n.name,
4046
- title: t || /* @__PURE__ */ l.jsx(N, { value: n.label }),
4047
- accessorFn: (a) => a[n.tsName],
4048
- render: (a) => {
4049
- const u = a[n.tsName];
4050
- return /* @__PURE__ */ l.jsx(i, { db: e, property: n, value: u });
4051
- }
4128
+ title: t || /* @__PURE__ */ l.jsx(b, { value: n.label }),
4129
+ accessorFn: (d) => d[n.tsName],
4130
+ render: (d) => {
4131
+ const g = d[n.tsName];
4132
+ return /* @__PURE__ */ l.jsx(a, { db: e, property: n, value: g });
4133
+ },
4134
+ rowSpan: i,
4135
+ colSpan: s
4052
4136
  };
4053
- return o !== void 0 && (s.accessorFn = (a) => a[o][n.tsName], s.render = (a) => {
4054
- const u = a[o][n.tsName];
4055
- return /* @__PURE__ */ l.jsx(i, { db: e, property: n, value: u });
4056
- }), s;
4137
+ return o !== void 0 && (u.accessorFn = (d) => d[o][n.tsName], u.render = (d) => {
4138
+ const g = d[o][n.tsName];
4139
+ return /* @__PURE__ */ l.jsx(a, { db: e, property: n, value: g });
4140
+ }), u;
4057
4141
  }
4058
- function zi(e, n, t, {
4142
+ function Bi(e, n, t, {
4059
4143
  title: o,
4060
4144
  nestedKey: r,
4061
4145
  component: i
@@ -4066,37 +4150,37 @@ function zi(e, n, t, {
4066
4150
  else if (se(t))
4067
4151
  t.cardinality === "1:N" || t.cardinality === "N:N" ? s = mt : s = ft;
4068
4152
  else {
4069
- if (ce[t.datatype] === void 0)
4153
+ if (ge[t.datatype] === void 0)
4070
4154
  throw new Error(
4071
4155
  `No display component found for datatype ${t.datatype}`
4072
4156
  );
4073
- s = ce[t.datatype];
4157
+ s = ge[t.datatype];
4074
4158
  }
4075
4159
  const a = {
4076
4160
  key: n + "." + t.name,
4077
- title: o || /* @__PURE__ */ l.jsx(N, { value: t.label }),
4161
+ title: o || /* @__PURE__ */ l.jsx(b, { value: t.label }),
4078
4162
  accessorFn: (u) => u[n.tsName][t.tsName],
4079
4163
  render: (u) => {
4080
- const c = u[n.tsName][t.tsName];
4081
- return /* @__PURE__ */ l.jsx(s, { db: e, property: t, value: c });
4164
+ const d = u[n.tsName][t.tsName];
4165
+ return /* @__PURE__ */ l.jsx(s, { db: e, property: t, value: d });
4082
4166
  }
4083
4167
  };
4084
4168
  return r !== void 0 && (a.accessorFn = (u) => u[r][n.tsName][t.tsName], a.render = (u) => {
4085
- const c = u[r][n.tsName][t.tsName];
4086
- return /* @__PURE__ */ l.jsx(s, { db: e, property: t, value: c });
4169
+ const d = u[r][n.tsName][t.tsName];
4170
+ return /* @__PURE__ */ l.jsx(s, { db: e, property: t, value: d });
4087
4171
  }), a;
4088
4172
  }
4089
- function Gi(e, n, t, o = {}) {
4173
+ function Ui(e, n, t, o = {}) {
4090
4174
  return t.map((r) => $n(r) ? r : En(e, n.publicProperties[r], o));
4091
4175
  }
4092
- function Hi(e, n, t = [], o = {}) {
4176
+ function Yi(e, n, t = [], o = {}) {
4093
4177
  return t.map((r) => $n(r) ? r : En(e, n.publicProperties[r], o));
4094
4178
  }
4095
4179
  function $n(e) {
4096
4180
  return typeof e == "object" && "key" in e && "title" in e;
4097
4181
  }
4098
- const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4099
- var m, p, d, f, h;
4182
+ const Jr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), Ki = (e) => {
4183
+ var m, p, c, f, h;
4100
4184
  const [n, t] = M(
4101
4185
  {}
4102
4186
  ), o = e.selectable ?? Fn(e.actions), r = _(() => {
@@ -4104,7 +4188,7 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4104
4188
  o && v.push({
4105
4189
  id: "selection",
4106
4190
  header: ({ table: S }) => /* @__PURE__ */ l.jsx(
4107
- de,
4191
+ ce,
4108
4192
  {
4109
4193
  checked: S.getIsAllRowsSelected(),
4110
4194
  indeterminate: S.getIsSomeRowsSelected(),
@@ -4112,7 +4196,7 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4112
4196
  }
4113
4197
  ),
4114
4198
  cell: ({ row: S }) => /* @__PURE__ */ l.jsx(
4115
- de,
4199
+ ce,
4116
4200
  {
4117
4201
  checked: S.getIsSelected(),
4118
4202
  disabled: !S.getCanSelect(),
@@ -4132,12 +4216,12 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4132
4216
  }
4133
4217
  });
4134
4218
  return v;
4135
- }, [e.columns, o]), i = yn({
4219
+ }, [e.columns, o]), i = jn({
4136
4220
  data: e.data,
4137
4221
  columns: r,
4138
4222
  enableRowSelection: o,
4139
4223
  getCoreRowModel: Rn(),
4140
- getPaginationRowModel: Dr(),
4224
+ getPaginationRowModel: Nr(),
4141
4225
  initialState: {
4142
4226
  pagination: {
4143
4227
  pageSize: ((m = e.pagination) == null ? void 0 : m.pageSize) ?? 10,
@@ -4151,29 +4235,29 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4151
4235
  }), s = _(() => Object.keys(n).filter((v) => n[v]).map(Number), [n]);
4152
4236
  let a, u;
4153
4237
  _n(e.actions) && (a = /* @__PURE__ */ l.jsx(
4154
- jn,
4238
+ yn,
4155
4239
  {
4156
4240
  actions: e.actions,
4157
4241
  selectedRowKeys: s
4158
4242
  }
4159
4243
  ));
4160
- const c = ((p = e.pagination) == null ? void 0 : p.positions) || Kr;
4161
- if (c.size > 0) {
4244
+ const d = ((p = e.pagination) == null ? void 0 : p.positions) || Jr;
4245
+ if (d.size > 0) {
4162
4246
  const v = i.getState().pagination, S = /* @__PURE__ */ l.jsx(
4163
4247
  Pn,
4164
4248
  {
4165
4249
  total: i.getPageCount(),
4166
4250
  pageIndex: v.pageIndex,
4167
4251
  pageSize: v.pageSize,
4168
- onUpdatePagination: (R, j) => i.setPagination({ pageIndex: R, pageSize: j }),
4169
- allowPageSizeChange: (d = e.pagination) == null ? void 0 : d.showSizeChanger,
4252
+ onUpdatePagination: (R, y) => i.setPagination({ pageIndex: R, pageSize: y }),
4253
+ allowPageSizeChange: (c = e.pagination) == null ? void 0 : c.showSizeChanger,
4170
4254
  pageSizeOptions: (h = (f = e.pagination) == null ? void 0 : f.pageSizeOptions) == null ? void 0 : h.map((R) => R.toString())
4171
4255
  }
4172
4256
  );
4173
- c.has("topRight") && (a !== void 0 ? a = /* @__PURE__ */ l.jsxs(L, { justify: "space-between", gap: "sm", children: [
4257
+ d.has("topRight") && (a !== void 0 ? a = /* @__PURE__ */ l.jsxs(O, { justify: "space-between", gap: "sm", children: [
4174
4258
  a,
4175
4259
  S
4176
- ] }) : a = /* @__PURE__ */ l.jsx(B, { justify: "flex-end", children: S })), (c.has("bottomRight") || c.has("bottomLeft") || c.has("bottomCenter")) && (c.has("bottomLeft") ? u = /* @__PURE__ */ l.jsxs(B, { justify: "space-between", align: "center", children: [
4260
+ ] }) : a = /* @__PURE__ */ l.jsx(B, { justify: "flex-end", children: S })), (d.has("bottomRight") || d.has("bottomLeft") || d.has("bottomCenter")) && (d.has("bottomLeft") ? u = /* @__PURE__ */ l.jsxs(B, { justify: "space-between", align: "center", children: [
4177
4261
  S,
4178
4262
  /* @__PURE__ */ l.jsxs(E, { size: "sm", c: "dimmed", children: [
4179
4263
  "Showing ",
@@ -4248,27 +4332,27 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4248
4332
  )
4249
4333
  ] });
4250
4334
  }, zt = {
4251
- integer: Me,
4252
- float: Me,
4253
- string: Se,
4335
+ integer: be,
4336
+ float: be,
4337
+ string: ve,
4254
4338
  boolean: sn,
4255
- "string[]": Se,
4256
- enum: Se,
4257
- date: No,
4258
- datetime: ko
4259
- }, Yr = {
4339
+ "string[]": ve,
4340
+ enum: ve,
4341
+ date: zo,
4342
+ datetime: Go
4343
+ }, Qr = {
4260
4344
  lang2value: {
4261
4345
  en: "Update",
4262
4346
  vi: "Cập Nhật"
4263
4347
  },
4264
4348
  lang: "en"
4265
- }, Wr = {
4349
+ }, Zr = {
4266
4350
  lang2value: {
4267
4351
  en: "Clear",
4268
4352
  vi: "Xóa"
4269
4353
  },
4270
4354
  lang: "en"
4271
- }, Xr = ({
4355
+ }, ei = ({
4272
4356
  db: e,
4273
4357
  property: n,
4274
4358
  InputComponent: t,
@@ -4290,13 +4374,13 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4290
4374
  t = zt[n.datatype];
4291
4375
  }
4292
4376
  const a = _(() => {
4293
- var c;
4294
- return r === void 0 || (c = r(i).errorMessage) == null ? void 0 : c.t({ args: { name: n.label } });
4377
+ var d;
4378
+ return r === void 0 || (d = r(i).errorMessage) == null ? void 0 : d.t({ args: { name: n.label } });
4295
4379
  }, [r, i, n.label]);
4296
- return /* @__PURE__ */ l.jsxs(X, { gap: 5, children: [
4297
- /* @__PURE__ */ l.jsxs(A, { gutter: "sm", children: [
4380
+ return /* @__PURE__ */ l.jsxs(Y, { gap: 5, children: [
4381
+ /* @__PURE__ */ l.jsxs(N, { gutter: "sm", children: [
4298
4382
  /* @__PURE__ */ l.jsx(
4299
- A.Col,
4383
+ N.Col,
4300
4384
  {
4301
4385
  span: o.labelCol,
4302
4386
  style: {
@@ -4306,16 +4390,16 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4306
4390
  children: /* @__PURE__ */ l.jsx(
4307
4391
  un,
4308
4392
  {
4309
- label: /* @__PURE__ */ l.jsx(N, { value: n.label }),
4393
+ label: /* @__PURE__ */ l.jsx(b, { value: n.label }),
4310
4394
  name: n.name,
4311
4395
  required: n.isRequired,
4312
- tooltip: n.description !== void 0 ? /* @__PURE__ */ l.jsx(N, { value: n.description }) : void 0,
4396
+ tooltip: n.description !== void 0 ? /* @__PURE__ */ l.jsx(b, { value: n.description }) : void 0,
4313
4397
  align: o.align
4314
4398
  }
4315
4399
  )
4316
4400
  }
4317
4401
  ),
4318
- /* @__PURE__ */ l.jsx(A.Col, { span: o.itemCol, children: /* @__PURE__ */ l.jsx(
4402
+ /* @__PURE__ */ l.jsx(N.Col, { span: o.itemCol, children: /* @__PURE__ */ l.jsx(
4319
4403
  t,
4320
4404
  {
4321
4405
  db: e,
@@ -4325,36 +4409,36 @@ const Kr = /* @__PURE__ */ new Set(["topRight", "bottomRight"]), qi = (e) => {
4325
4409
  }
4326
4410
  ) })
4327
4411
  ] }),
4328
- a !== void 0 && /* @__PURE__ */ l.jsxs(A, { gutter: "sm", children: [
4329
- /* @__PURE__ */ l.jsx(A.Col, { span: o.labelCol }),
4330
- /* @__PURE__ */ l.jsx(A.Col, { span: o.itemCol, children: /* @__PURE__ */ l.jsx(J.Error, { children: a }) })
4412
+ a !== void 0 && /* @__PURE__ */ l.jsxs(N, { gutter: "sm", children: [
4413
+ /* @__PURE__ */ l.jsx(N.Col, { span: o.labelCol }),
4414
+ /* @__PURE__ */ l.jsx(N.Col, { span: o.itemCol, children: /* @__PURE__ */ l.jsx(J.Error, { children: a }) })
4331
4415
  ] })
4332
4416
  ] });
4333
4417
  };
4334
- function Jr({
4418
+ function ti({
4335
4419
  properties: e,
4336
4420
  queryConditions: n
4337
4421
  }) {
4338
4422
  return e.reduce((t, o) => n[o.property.tsName] === void 0 ? t : t + 1, 0);
4339
4423
  }
4340
- const Qr = (e, n) => on(e, n, !1);
4341
- function Zr({
4424
+ const ni = (e, n) => on(e, n, !1);
4425
+ function oi({
4342
4426
  properties: e,
4343
4427
  queryConditions: n
4344
4428
  }) {
4345
- const t = io.getInstance().getLocale(), o = [];
4429
+ const t = so.getInstance().getLocale(), o = [];
4346
4430
  for (const r of e) {
4347
4431
  const i = n[r.property.tsName];
4348
4432
  if (i !== void 0)
4349
4433
  if (o.length > 0 && o.push(" & "), r.property.datatype === "date" || r.property.datatype === "datetime") {
4350
- const s = r.property.datatype === "date" ? Ce : Qr;
4351
- i.op === "bti" ? (o.push(s(t, Z(i.value[0]).toDate())), o.push(" ≤ "), o.push(he(t, r.property.label)), o.push(" ≤ "), o.push(s(t, Z(i.value[1]).toDate()))) : i.op === "gte" ? (o.push(he(t, r.property.label)), o.push(" ≥ "), o.push(s(t, Z(i.value).toDate()))) : i.op === "lte" && (o.push(he(t, r.property.label)), o.push(" ≤ "), o.push(s(t, Z(i.value).toDate())));
4434
+ const s = r.property.datatype === "date" ? we : ni;
4435
+ i.op === "bti" ? (o.push(s(t, Z(i.value[0]).toDate())), o.push(" ≤ "), o.push(Se(t, r.property.label)), o.push(" ≤ "), o.push(s(t, Z(i.value[1]).toDate()))) : i.op === "gte" ? (o.push(Se(t, r.property.label)), o.push(" ≥ "), o.push(s(t, Z(i.value).toDate()))) : i.op === "lte" && (o.push(Se(t, r.property.label)), o.push(" ≤ "), o.push(s(t, Z(i.value).toDate())));
4352
4436
  } else
4353
- o.push(he(t, r.property.label)), i.op === "eq" ? o.push(" = ") : o.push(` ${i.op} `), o.push(i.value.toString());
4437
+ o.push(Se(t, r.property.label)), i.op === "eq" ? o.push(" = ") : o.push(` ${i.op} `), o.push(i.value.toString());
4354
4438
  }
4355
4439
  return o.join("");
4356
4440
  }
4357
- const ei = ({
4441
+ const ri = ({
4358
4442
  db: e,
4359
4443
  properties: n,
4360
4444
  styles: t,
@@ -4364,7 +4448,7 @@ const ei = ({
4364
4448
  queryConditions: s
4365
4449
  }) => {
4366
4450
  const [a, u] = M({});
4367
- De(() => {
4451
+ Ve(() => {
4368
4452
  const f = {};
4369
4453
  for (const h of n) {
4370
4454
  const v = s[h.property.tsName];
@@ -4381,19 +4465,19 @@ const ei = ({
4381
4465
  }
4382
4466
  u(f);
4383
4467
  }, [n, s]);
4384
- const [c, g, m] = _(() => {
4468
+ const [d, g, m] = _(() => {
4385
4469
  const f = [], h = {}, v = {};
4386
4470
  for (const S of n) {
4387
- let R, j = (I) => {
4471
+ let R, y = (I) => {
4388
4472
  if (!It.isEmpty(I))
4389
4473
  return { op: "eq", value: I };
4390
4474
  };
4391
- (S.property.datatype === "date" || S.property.datatype === "datetime") && (R = It.validateTimeRange, j = (I) => I.start !== void 0 && I.end !== void 0 ? {
4475
+ (S.property.datatype === "date" || S.property.datatype === "datetime") && (R = It.validateTimeRange, y = (I) => I.start !== void 0 && I.end !== void 0 ? {
4392
4476
  op: "bti",
4393
4477
  value: [I.start.toISOString(), I.end.toISOString()]
4394
- } : I.start !== void 0 ? { op: "gte", value: I.start.toISOString() } : I.end !== void 0 ? { op: "lte", value: I.end.toISOString() } : void 0), h[S.property.tsName] = j, v[S.property.tsName] = R, f.push(
4478
+ } : I.start !== void 0 ? { op: "gte", value: I.start.toISOString() } : I.end !== void 0 ? { op: "lte", value: I.end.toISOString() } : void 0), h[S.property.tsName] = y, v[S.property.tsName] = R, f.push(
4395
4479
  /* @__PURE__ */ l.jsx(
4396
- Xr,
4480
+ ei,
4397
4481
  {
4398
4482
  db: e,
4399
4483
  property: S.property,
@@ -4418,7 +4502,7 @@ const ei = ({
4418
4502
  S !== void 0 && (h[v.property.tsName] = S);
4419
4503
  }
4420
4504
  i(h);
4421
- }, d = _(() => (f) => {
4505
+ }, c = _(() => (f) => {
4422
4506
  for (const h of n) {
4423
4507
  const v = m[h.property.tsName];
4424
4508
  if (v !== void 0 && !v(f[h.property.tsName]).isValid)
@@ -4426,11 +4510,11 @@ const ei = ({
4426
4510
  }
4427
4511
  return !0;
4428
4512
  }, [n, m]);
4429
- return /* @__PURE__ */ l.jsxs(X, { gap: "sm", className: o, style: t, children: [
4430
- c,
4431
- /* @__PURE__ */ l.jsxs(L, { gap: "sm", justify: "flex-end", children: [
4513
+ return /* @__PURE__ */ l.jsxs(Y, { gap: "sm", className: o, style: t, children: [
4514
+ d,
4515
+ /* @__PURE__ */ l.jsxs(O, { gap: "sm", justify: "flex-end", children: [
4432
4516
  /* @__PURE__ */ l.jsx(
4433
- q,
4517
+ z,
4434
4518
  {
4435
4519
  variant: "light",
4436
4520
  size: "xs",
@@ -4439,28 +4523,28 @@ const ei = ({
4439
4523
  u({}), p({});
4440
4524
  },
4441
4525
  disabled: Object.keys(a).length === 0,
4442
- children: /* @__PURE__ */ l.jsx(N, { value: Wr })
4526
+ children: /* @__PURE__ */ l.jsx(b, { value: Zr })
4443
4527
  }
4444
4528
  ),
4445
4529
  /* @__PURE__ */ l.jsx(
4446
- q,
4530
+ z,
4447
4531
  {
4448
4532
  variant: "light",
4449
4533
  size: "xs",
4450
4534
  onClick: () => p(a),
4451
- disabled: !d(a),
4452
- children: /* @__PURE__ */ l.jsx(N, { value: Yr })
4535
+ disabled: !c(a),
4536
+ children: /* @__PURE__ */ l.jsx(b, { value: Qr })
4453
4537
  }
4454
4538
  )
4455
4539
  ] })
4456
4540
  ] });
4457
- }, Gt = /* @__PURE__ */ l.jsx(oo, { size: 16, stroke: 1.5 }), Ht = /* @__PURE__ */ l.jsx(ut, { size: 16, stroke: 1.5 }), ti = {
4541
+ }, Gt = /* @__PURE__ */ l.jsx(ro, { size: 16, stroke: 1.5 }), Ht = /* @__PURE__ */ l.jsx(ut, { size: 16, stroke: 1.5 }), ii = {
4458
4542
  lang2value: {
4459
4543
  en: "Search By",
4460
4544
  vi: "Tìm Kiếm Theo"
4461
4545
  },
4462
4546
  lang: "en"
4463
- }, Bi = ({
4547
+ }, Wi = ({
4464
4548
  query: e,
4465
4549
  onChange: n,
4466
4550
  debounceTime: t = 250,
@@ -4468,16 +4552,16 @@ const ei = ({
4468
4552
  searchField: r,
4469
4553
  advancedSearch: i
4470
4554
  }) => {
4471
- const s = U(re), [a, u] = M(e), [c, g] = M(!1), [m, p] = M([!1, Date.now()]), d = _(() => lo(
4555
+ const s = U(re), [a, u] = M(e), [d, g] = M(!1), [m, p] = M([!1, Date.now()]), c = _(() => ao(
4472
4556
  t,
4473
4557
  (S) => {
4474
4558
  g(!1), n(S);
4475
4559
  },
4476
4560
  { atBegin: !1 }
4477
4561
  ), [t, n]), f = _(() => (S) => {
4478
- u(S.target.value), g(!0), d(S.target.value);
4479
- }, [u, g, d]);
4480
- o === void 0 && r !== void 0 && (o = ti);
4562
+ u(S.target.value), g(!0), c(S.target.value);
4563
+ }, [u, g, c]);
4564
+ o === void 0 && r !== void 0 && (o = ii);
4481
4565
  let h = "";
4482
4566
  if (o !== void 0 && (h = o.lang2value[s.language] || o.lang2value[o.lang]), r !== void 0 && (h.length > 0 && (h += " "), h += r.lang2value[s.language] || r.lang2value[r.lang]), i === void 0)
4483
4567
  return /* @__PURE__ */ l.jsx(
@@ -4486,14 +4570,14 @@ const ei = ({
4486
4570
  flex: 1,
4487
4571
  label: "Search",
4488
4572
  placeholder: h,
4489
- leftSection: c ? Gt : Ht,
4573
+ leftSection: d ? Gt : Ht,
4490
4574
  value: a,
4491
4575
  onChange: f
4492
4576
  }
4493
4577
  );
4494
- const v = Jr(i);
4578
+ const v = ti(i);
4495
4579
  return /* @__PURE__ */ l.jsxs(
4496
- Le,
4580
+ de,
4497
4581
  {
4498
4582
  width: "target",
4499
4583
  trapFocus: !0,
@@ -4505,13 +4589,13 @@ const ei = ({
4505
4589
  p([!1, Date.now()]);
4506
4590
  },
4507
4591
  children: [
4508
- /* @__PURE__ */ l.jsx(Le.Target, { children: /* @__PURE__ */ l.jsx(
4592
+ /* @__PURE__ */ l.jsx(de.Target, { children: /* @__PURE__ */ l.jsx(
4509
4593
  _t,
4510
4594
  {
4511
4595
  flex: 1,
4512
4596
  label: "Search",
4513
4597
  placeholder: h,
4514
- leftSection: c ? Gt : Ht,
4598
+ leftSection: d ? Gt : Ht,
4515
4599
  rightSection: /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4516
4600
  /* @__PURE__ */ l.jsx(
4517
4601
  Ft,
@@ -4521,7 +4605,7 @@ const ei = ({
4521
4605
  onClick: () => {
4522
4606
  u(""), n("");
4523
4607
  },
4524
- children: /* @__PURE__ */ l.jsx(to, { size: 16, stroke: 1.5, cursor: "pointer" })
4608
+ children: /* @__PURE__ */ l.jsx(no, { size: 16, stroke: 1.5, cursor: "pointer" })
4525
4609
  }
4526
4610
  ),
4527
4611
  /* @__PURE__ */ l.jsx(
@@ -4534,7 +4618,7 @@ const ei = ({
4534
4618
  m[1] + 200 >= Date.now() || p([!0, Date.now()]);
4535
4619
  },
4536
4620
  children: /* @__PURE__ */ l.jsx(
4537
- no,
4621
+ oo,
4538
4622
  {
4539
4623
  size: 16,
4540
4624
  stroke: v > 0 ? 2 : 1.5,
@@ -4550,12 +4634,12 @@ const ei = ({
4550
4634
  rightSectionWidth: 68,
4551
4635
  value: a,
4552
4636
  onChange: f,
4553
- description: Zr(i),
4637
+ description: oi(i),
4554
4638
  inputWrapperOrder: ["label", "input", "description", "error"]
4555
4639
  }
4556
4640
  ) }),
4557
- /* @__PURE__ */ l.jsx(Le.Dropdown, { children: /* @__PURE__ */ l.jsx(
4558
- ei,
4641
+ /* @__PURE__ */ l.jsx(de.Dropdown, { children: /* @__PURE__ */ l.jsx(
4642
+ ri,
4559
4643
  {
4560
4644
  db: i.db,
4561
4645
  properties: i.properties,
@@ -4569,7 +4653,7 @@ const ei = ({
4569
4653
  ]
4570
4654
  }
4571
4655
  );
4572
- }, ni = oe(
4656
+ }, si = oe(
4573
4657
  ({
4574
4658
  store: e,
4575
4659
  record: n,
@@ -4581,40 +4665,40 @@ const ei = ({
4581
4665
  return /* @__PURE__ */ l.jsx("div", {});
4582
4666
  const i = dt(n, t);
4583
4667
  return /* @__PURE__ */ l.jsxs("div", { children: [
4584
- /* @__PURE__ */ l.jsx(E, { size: "sm", fw: 550, children: /* @__PURE__ */ l.jsx(N, { value: t.label }) }),
4668
+ /* @__PURE__ */ l.jsx(E, { size: "sm", fw: 550, children: /* @__PURE__ */ l.jsx(b, { value: t.label }) }),
4585
4669
  i !== void 0 && /* @__PURE__ */ l.jsx(o, { db: e.db, property: t, value: i })
4586
4670
  ] });
4587
4671
  }
4588
- ), oi = 12, ri = (e) => {
4589
- const n = e.schema, t = _(() => e.fieldGroups.map((o, r) => ii(n, e.store, e.record, r, o)), [n, e.store, e.record, e.fieldGroups]);
4590
- return /* @__PURE__ */ l.jsx(X, { gap: "sm", className: e.className, style: e.styles, children: t });
4672
+ ), li = 12, ai = (e) => {
4673
+ const n = e.schema, t = _(() => e.fieldGroups.map((o, r) => ui(n, e.store, e.record, r, o)), [n, e.store, e.record, e.fieldGroups]);
4674
+ return /* @__PURE__ */ l.jsx(Y, { gap: "sm", className: e.className, style: e.styles, children: t });
4591
4675
  };
4592
- function ii(e, n, t, o, r) {
4676
+ function ui(e, n, t, o, r) {
4593
4677
  const i = r.fields, s = [];
4594
4678
  for (let a = 0; a < i.length; a++) {
4595
- const u = oi / i[a].length;
4679
+ const u = li / i[a].length;
4596
4680
  if (!Number.isInteger(u))
4597
4681
  throw new Error(`Span must be an integer, but got ${u} for row ${a}`);
4598
- for (let c = 0; c < i[a].length; c++) {
4599
- const g = i[a][c];
4682
+ for (let d = 0; d < i[a].length; d++) {
4683
+ const g = i[a][d];
4600
4684
  let m;
4601
4685
  typeof g == "function" ? m = g(n, t) : typeof g == "object" && "prop" in g ? m = st(
4602
4686
  n,
4603
4687
  t,
4604
- g.prop instanceof Y ? g.prop : e.allProperties[g.prop],
4688
+ g.prop instanceof W ? g.prop : e.allProperties[g.prop],
4605
4689
  g.args
4606
4690
  ) : m = st(
4607
4691
  n,
4608
4692
  t,
4609
- g instanceof Y ? g : e.allProperties[g]
4693
+ g instanceof W ? g : e.allProperties[g]
4610
4694
  ), s.push(
4611
- /* @__PURE__ */ l.jsx(A.Col, { span: u, children: m }, `${a}-${c}`)
4695
+ /* @__PURE__ */ l.jsx(N.Col, { span: u, children: m }, `${a}-${d}`)
4612
4696
  );
4613
4697
  }
4614
4698
  }
4615
- return /* @__PURE__ */ l.jsx(A, { gutter: "sm", children: s }, o);
4699
+ return /* @__PURE__ */ l.jsx(N, { gutter: "sm", children: s }, o);
4616
4700
  }
4617
- function Ui(e, n, t = {}) {
4701
+ function Xi(e, n, t = {}) {
4618
4702
  return (o, r) => {
4619
4703
  if (t.visible !== void 0 && !t.visible(r))
4620
4704
  return /* @__PURE__ */ l.jsx("div", {});
@@ -4623,13 +4707,13 @@ function Ui(e, n, t = {}) {
4623
4707
  if (typeof s == "function")
4624
4708
  u = s(o, r);
4625
4709
  else {
4626
- let c, g = {};
4627
- typeof s == "object" && "prop" in s ? (c = s.prop instanceof Y ? s.prop : e.allProperties[s.prop], s.args !== void 0 && (g = s.args)) : c = s instanceof Y ? s : e.allProperties[s], u = st(o, r, c, g);
4710
+ let d, g = {};
4711
+ typeof s == "object" && "prop" in s ? (d = s.prop instanceof W ? s.prop : e.allProperties[s.prop], s.args !== void 0 && (g = s.args)) : d = s instanceof W ? s : e.allProperties[s], u = st(o, r, d, g);
4628
4712
  }
4629
4713
  return /* @__PURE__ */ l.jsx("div", { children: u }, a);
4630
4714
  });
4631
4715
  return /* @__PURE__ */ l.jsx(
4632
- L,
4716
+ O,
4633
4717
  {
4634
4718
  gap: t.flexGap,
4635
4719
  grow: t.flexGrow ?? !0,
@@ -4639,19 +4723,19 @@ function Ui(e, n, t = {}) {
4639
4723
  );
4640
4724
  };
4641
4725
  }
4642
- function si(e) {
4726
+ function di(e) {
4643
4727
  if (se(e))
4644
4728
  return e.cardinality === "N:N" || e.cardinality === "1:N" ? mt : ft;
4645
- if (ce[e.datatype] === void 0)
4729
+ if (ge[e.datatype] === void 0)
4646
4730
  throw new Error(
4647
4731
  `No display component found for datatype ${e.datatype}`
4648
4732
  );
4649
- return ce[e.datatype];
4733
+ return ge[e.datatype];
4650
4734
  }
4651
4735
  function st(e, n, t, o = {}) {
4652
4736
  let r;
4653
- return o.display !== void 0 ? r = o.display : r = si(t instanceof Y ? t.leafProperty : t), /* @__PURE__ */ l.jsx(
4654
- ni,
4737
+ return o.display !== void 0 ? r = o.display : r = di(t instanceof W ? t.leafProperty : t), /* @__PURE__ */ l.jsx(
4738
+ si,
4655
4739
  {
4656
4740
  store: e,
4657
4741
  record: n,
@@ -4661,10 +4745,10 @@ function st(e, n, t, o = {}) {
4661
4745
  }
4662
4746
  );
4663
4747
  }
4664
- const Ki = (e) => /* @__PURE__ */ l.jsxs(Re, { defaultValue: e.fieldTabs[0].tabName, children: [
4665
- /* @__PURE__ */ l.jsx(Re.List, { children: e.fieldTabs.map((n, t) => /* @__PURE__ */ l.jsx(Re.Tab, { value: n.tabName, children: n.tabName }, t)) }),
4666
- e.fieldTabs.map((n, t) => /* @__PURE__ */ l.jsx(Re.Panel, { value: n.tabName, pt: "sm", children: /* @__PURE__ */ l.jsx(
4667
- ri,
4748
+ const Ji = (e) => /* @__PURE__ */ l.jsxs(je, { defaultValue: e.fieldTabs[0].tabName, children: [
4749
+ /* @__PURE__ */ l.jsx(je.List, { children: e.fieldTabs.map((n, t) => /* @__PURE__ */ l.jsx(je.Tab, { value: n.tabName, children: n.tabName }, t)) }),
4750
+ e.fieldTabs.map((n, t) => /* @__PURE__ */ l.jsx(je.Panel, { value: n.tabName, pt: "sm", children: /* @__PURE__ */ l.jsx(
4751
+ ai,
4668
4752
  {
4669
4753
  schema: e.schema,
4670
4754
  store: e.store,
@@ -4677,85 +4761,86 @@ const Ki = (e) => /* @__PURE__ */ l.jsxs(Re, { defaultValue: e.fieldTabs[0].tabN
4677
4761
  ] });
4678
4762
  export {
4679
4763
  sn as BooleanInput,
4680
- Ai as ConfirmationInput,
4681
- Ti as ConfirmationLabel,
4764
+ Oi as ConfirmationInput,
4765
+ Li as ConfirmationLabel,
4682
4766
  Qe as CountryFlagComponent,
4683
4767
  dn as DEFAULT_LAYOUT,
4684
- Br as DEFAULT_PAGINATION_POSITIONS,
4685
- ce as DataType2DisplayComponent,
4768
+ Wr as DEFAULT_PAGINATION_POSITIONS,
4769
+ ge as DataType2DisplayComponent,
4686
4770
  Vt as DataType2InputComponent,
4687
- wo as DateDisplay,
4688
- Po as DateInput,
4689
- No as DateRangeInput,
4690
- Co as DateTimeDisplay,
4691
- Di as DateTimeHideTimeDisplay,
4692
- ko as DateTimeRangeInput,
4693
- qo as EmbeddedFormItem,
4694
- fo as EmojiCountryFlag,
4695
- Eo as EnumInput,
4696
- zo as FormItem,
4771
+ yo as DateDisplay,
4772
+ bo as DateInput,
4773
+ zo as DateRangeInput,
4774
+ jo as DateTimeDisplay,
4775
+ Ni as DateTimeHideTimeDisplay,
4776
+ Go as DateTimeRangeInput,
4777
+ Ko as EmbeddedFormItem,
4778
+ mo as EmojiCountryFlag,
4779
+ Do as EnumInput,
4780
+ Bo as FormItem,
4697
4781
  cn as FormItemInner,
4698
4782
  un as FormItemLabel,
4699
- vi as LanguageSelector,
4700
- Ri as Loading,
4701
- yi as LoadingInline,
4783
+ Ri as LanguageSelector,
4784
+ Fi as Loading,
4785
+ Ii as LoadingInline,
4702
4786
  re as LocaleContext,
4703
- Si as LocaleProvider,
4704
- vo as MenuTrie,
4787
+ xi as LocaleProvider,
4788
+ Co as MenuTrie,
4705
4789
  mt as MultiForeignKeyDisplay,
4706
4790
  an as MultiForeignKeyInput,
4707
- N as MultiLingualString,
4708
- ji as NotAuthorized,
4709
- wi as NotFound,
4791
+ b as MultiLingualString,
4792
+ Pi as NotAuthorized,
4793
+ yi as NotFound,
4710
4794
  Qt as NotFoundInline,
4711
- xi as NotFoundSubPage,
4712
- Me as NumberInput,
4713
- Pi as OrderedUniqueList,
4795
+ _i as NotFoundSubPage,
4796
+ be as NumberInput,
4797
+ bi as OrderedUniqueList,
4714
4798
  et as Permission,
4715
- Ni as SPAN_COL,
4716
- go as SVGCountryFlag,
4717
- ei as SearchForm,
4718
- Xr as SearchFormItem,
4799
+ Ro as PopConfirm,
4800
+ zi as SPAN_COL,
4801
+ fo as SVGCountryFlag,
4802
+ ri as SearchForm,
4803
+ ei as SearchFormItem,
4719
4804
  nn as SeraCol,
4720
4805
  gt as SeraContext,
4721
- Vi as SeraContextProvider,
4722
- Oi as SeraEmbeddedForm,
4723
- qi as SeraEmbeddedTable,
4724
- ki as SeraForm,
4806
+ ki as SeraContextProvider,
4807
+ Hi as SeraEmbeddedForm,
4808
+ Ki as SeraEmbeddedTable,
4809
+ Gi as SeraForm,
4725
4810
  tn as SeraRow,
4726
- Bi as SeraSearch,
4727
- Li as SeraTable,
4728
- bi as SeraVerticalMenu,
4729
- ri as SeraView,
4730
- Ki as SeraViewTab,
4811
+ Wi as SeraSearch,
4812
+ qi as SeraTable,
4813
+ Ai as SeraVerticalMenu,
4814
+ ai as SeraView,
4815
+ Ji as SeraViewTab,
4731
4816
  ft as SingleForeignKeyDisplay,
4732
4817
  ln as SingleForeignKeyInput,
4733
4818
  ct as TestIdContext,
4734
- Ei as TestIdProvider,
4735
- Se as TextInput,
4819
+ Di as TestIdProvider,
4820
+ ve as TextInput,
4736
4821
  Zt as Trie,
4737
4822
  bt as TrieNode,
4738
- po as buildMenuItemIndex,
4739
- T as countryFlags,
4740
- So as filterAllowedItems,
4823
+ ho as buildMenuItemIndex,
4824
+ A as countryFlags,
4825
+ vo as filterAllowedItems,
4741
4826
  gn as getInputComponent,
4742
- Jr as getNumberOfFilters,
4827
+ ti as getNumberOfFilters,
4743
4828
  dt as getPropertyValue,
4744
- Zr as getReadableFilters,
4745
- Mi as getTestIdProps,
4746
- _i as groupBy,
4747
- Fi as groupByAsList,
4748
- Ui as groupFields,
4749
- Go as isHorizontalLayout,
4829
+ oi as getReadableFilters,
4830
+ Ti as getTestIdProps,
4831
+ Ei as groupBy,
4832
+ $i as groupByAsList,
4833
+ Xi as groupFields,
4834
+ Uo as isHorizontalLayout,
4750
4835
  $n as isSeraColumn,
4751
- Hi as makeEmbeddedTableColumns,
4836
+ Yi as makeEmbeddedTableColumns,
4752
4837
  En as makeTableColumn,
4753
- zi as makeTableColumnFromNestedProperty,
4754
- Gi as makeTableColumns,
4838
+ Bi as makeTableColumnFromNestedProperty,
4839
+ Ui as makeTableColumns,
4755
4840
  Ze as setPropertyValue,
4756
- he as translateMultiLingualString,
4757
- Ii as uniqueList,
4758
- Ci as useMultiLingualString,
4759
- W as usePropertyTestId,
4760
- $i as useTestId
4841
+ Se as translateMultiLingualString,
4842
+ Mi as uniqueList,
4843
+ ji as useMultiLingualString,
4844
+ X as usePropertyTestId,
4845
+ Vi as useTestId
4761
4846
  };