mig-schema-table 5.0.20 → 5.0.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,44 +1,44 @@
1
- import { jsx as s, jsxs as B, Fragment as en } from "react/jsx-runtime";
2
- import * as tn from "react";
1
+ import { jsx as r, jsxs as B, Fragment as Kt } from "react/jsx-runtime";
2
+ import * as en from "react";
3
3
  import e from "react";
4
- import { createPortal as nn } from "react-dom";
5
- import { VariableSizeGrid as Ct, VariableSizeList as rn } from "react-window";
6
- import { format as sn, endOfDay as on, differenceInSeconds as an } from "date-fns";
7
- import { nl as ln } from "date-fns/locale";
8
- import { unCamel as cn, emptyFn as be, timeZone as Ne, localeFormatInTimeZone as Rt, parseLocationHash as wt, serializeLocationHash as He } from "mig-data-tools";
9
- import { range as un, debounce as dn, difference as mn, isEqual as Xe, isFinite as hn, sum as fn } from "lodash";
10
- import vt from "react-datepicker";
11
- import yt from "react-select";
12
- import { nl as kt } from "date-fns/locale/nl";
4
+ import { createPortal as tn } from "react-dom";
5
+ import { VariableSizeGrid as _t, VariableSizeList as nn } from "react-window";
6
+ import { format as rn, endOfDay as sn, differenceInSeconds as on } from "date-fns";
7
+ import { nl as an } from "date-fns/locale";
8
+ import { unCamel as ln, emptyFn as be, timeZone as Ne, localeFormatInTimeZone as St, parseLocationHash as Ct, serializeLocationHash as He } from "mig-data-tools";
9
+ import { range as cn, debounce as un, difference as dn, isEqual as Xe, isFinite as mn, sum as hn } from "lodash";
10
+ import wt from "react-datepicker";
11
+ import vt from "react-select";
12
+ import { nl as yt } from "date-fns/locale/nl";
13
13
  import { TZDate as Ve } from "@date-fns/tz";
14
- import { useFloating as Dt, flip as xt } from "@floating-ui/react-dom";
15
- import gn from "react-window-infinite-loader";
16
- import { saveAs as bn } from "file-saver";
17
- const ut = (n, o) => (
14
+ import { useFloating as kt, flip as Dt } from "@floating-ui/react-dom";
15
+ import fn from "react-window-infinite-loader";
16
+ import { saveAs as gn } from "file-saver";
17
+ const ct = (s, o) => (
18
18
  // replace jan. with jan
19
- sn(n, o, { locale: ln }).replace(".", "")
20
- ), pn = {
19
+ rn(s, o, { locale: an }).replace(".", "")
20
+ ), bn = {
21
21
  "Europe/Amsterdam": "AMS",
22
22
  "Europe/Berlin": "AMS",
23
23
  "Asia/Jakarta": "JKT",
24
24
  "Asia/Bangkok": "JKT",
25
25
  showingFilteredCountOfTotalCount: "Showing {0} of {1}"
26
26
  };
27
- function Tt(n, ...o) {
28
- let h = pn[n] || cn(n);
27
+ function xt(s, ...o) {
28
+ let h = bn[s] || ln(s);
29
29
  return o.forEach((p, _) => {
30
30
  h = h.replace(`{${_}}`, `${p}`);
31
31
  }), h;
32
32
  }
33
- const ee = "SELECT_ALL_COLUMN_NAME", Mt = 40, we = "__drag_handle__", At = 32, $t = "dd MMM yyyy", Ye = "dd MMM yyyy HH:mm", Ot = 25, Et = 50, _n = 3;
34
- var pe = /* @__PURE__ */ ((n) => (n.GT = "GT", n.LT = "LT", n.EQ = "EQ", n))(pe || {});
35
- const Lt = /* @__PURE__ */ new Map([
33
+ const ee = "SELECT_ALL_COLUMN_NAME", Tt = 40, we = "__drag_handle__", Mt = 32, Rt = "dd MMM yyyy", Ye = "dd MMM yyyy HH:mm", $t = 25, At = 50, pn = 3;
34
+ var pe = /* @__PURE__ */ ((s) => (s.GT = "GT", s.LT = "LT", s.EQ = "EQ", s))(pe || {});
35
+ const Et = /* @__PURE__ */ new Map([
36
36
  [!0, "✓"],
37
37
  [!1, "✕"],
38
38
  [null, "?"]
39
39
  ]);
40
- var Qe = /* @__PURE__ */ ((n) => (n.UNAVAILABLE = "UNAVAILABLE", n.AVAILABLE = "AVAILABLE", n.ACTIVE = "ACTIVE", n))(Qe || {});
41
- const Ie = tn.createContext({
40
+ var Be = /* @__PURE__ */ ((s) => (s.UNAVAILABLE = "UNAVAILABLE", s.AVAILABLE = "AVAILABLE", s.ACTIVE = "ACTIVE", s))(Be || {});
41
+ const Ie = en.createContext({
42
42
  checkedIndexes: [],
43
43
  columnNames: [],
44
44
  columnWidths: new Uint16Array(),
@@ -67,13 +67,13 @@ const Ie = tn.createContext({
67
67
  sortAsc: !1
68
68
  },
69
69
  translate: be
70
- }), Cn = { type: "boolean" }, wn = ({ columnIndex: n, rowIndex: o, style: h }) => {
70
+ }), _n = { type: "boolean" }, Cn = ({ columnIndex: s, rowIndex: o, style: h }) => {
71
71
  const {
72
72
  checkedIndexes: p,
73
73
  columnNames: _,
74
74
  config: f,
75
75
  disabledCheckedIndexes: L,
76
- displayTimezone: C,
76
+ displayTimezone: w,
77
77
  getRowClassName: O,
78
78
  getRowSelected: N,
79
79
  isItemLoaded: I,
@@ -86,43 +86,43 @@ const Ie = tn.createContext({
86
86
  setCheckedIndexes: q,
87
87
  setLastCheckChangedRowIndex: b,
88
88
  setRowDropTargetRowIndex: u,
89
- sortedRenderData: r,
89
+ sortedRenderData: n,
90
90
  sourceData: g,
91
91
  translate: oe
92
- } = e.useContext(Ie), W = _[n], ce = W === ee ? Cn : Y[W], G = f ? f[W] : void 0, v = e.useCallback(
93
- (w) => {
94
- q && q((T) => T && T.includes(w) ? T.filter((x) => x !== w) : T ? [...T, w] : [w]);
92
+ } = e.useContext(Ie), W = _[s], ce = W === ee ? _n : Y[W], G = f ? f[W] : void 0, v = e.useCallback(
93
+ (C) => {
94
+ q && q((T) => T && T.includes(C) ? T.filter((x) => x !== C) : T ? [...T, C] : [C]);
95
95
  },
96
96
  [q]
97
97
  ), J = I(o), ne = e.useCallback(
98
- (w) => {
99
- if (!g || !r || !M || !J)
98
+ (C) => {
99
+ if (!g || !n || !M || !J)
100
100
  return;
101
- const { rowIndex: T } = w.currentTarget.dataset;
101
+ const { rowIndex: T } = C.currentTarget.dataset;
102
102
  if (!T)
103
103
  return;
104
- const A = r[parseInt(T, 10)];
105
- M(g[A._index], A._index, w);
104
+ const A = n[parseInt(T, 10)];
105
+ M(g[A._index], A._index, C);
106
106
  },
107
- [J, M, r, g]
107
+ [J, M, n, g]
108
108
  ), re = e.useCallback(
109
- (w) => {
110
- if (!g || !r || !D || !J)
109
+ (C) => {
110
+ if (!g || !n || !D || !J)
111
111
  return;
112
- const { rowIndex: T } = w.currentTarget.dataset;
112
+ const { rowIndex: T } = C.currentTarget.dataset;
113
113
  if (!T)
114
114
  return;
115
- const A = r[parseInt(T, 10)];
116
- D(g[A._index], A._index, w);
115
+ const A = n[parseInt(T, 10)];
116
+ D(g[A._index], A._index, C);
117
117
  },
118
- [J, D, r, g]
119
- ), R = r ? r[o] : void 0, { showTimezones: ae, TdBody: Z } = G || {}, ue = e.useMemo(() => C ? null : Ne.startsWith("Europe/") ? "Asia/Jakarta" : "Europe/Amsterdam", [C]), j = e.useMemo(() => {
120
- if (!R || !r)
118
+ [J, D, n, g]
119
+ ), R = n ? n[o] : void 0, { showTimezones: ae, TdBody: Z } = G || {}, ue = e.useMemo(() => w ? null : Ne.startsWith("Europe/") ? "Asia/Jakarta" : "Europe/Amsterdam", [w]), j = e.useMemo(() => {
120
+ if (!R || !n)
121
121
  return;
122
- let w = W === ee ? void 0 : R[W];
122
+ let C = W === ee ? void 0 : R[W];
123
123
  if (ce?.format && ce.format === "date-time" && ae !== !1) {
124
124
  const A = g ? g[R._index] : void 0, x = A ? A[W] : void 0, Q = x ? new Date(x) : void 0;
125
- Q && ue && (w = `${Rt(
125
+ Q && ue && (C = `${St(
126
126
  Q,
127
127
  ue,
128
128
  Ye
@@ -134,7 +134,7 @@ const Ie = tn.createContext({
134
134
  `mig-schema-table__td--prop-${W}`
135
135
  ];
136
136
  switch (o === te && T.push("mig-schema-table__td--row-drop-target"), g && N && N(g[R._index], R._index) && T.push("mig-schema-table__td--selected"), g && O && T.push(
137
- O(g[R._index], R._index, r)
137
+ O(g[R._index], R._index, n)
138
138
  ), ce?.type) {
139
139
  case "boolean":
140
140
  T.push(`text-${G?.align || "center"}`);
@@ -148,16 +148,16 @@ const Ie = tn.createContext({
148
148
  }
149
149
  return {
150
150
  "data-row-index": o,
151
- "data-column-index": n,
151
+ "data-column-index": s,
152
152
  style: h,
153
153
  className: T.join(" "),
154
- title: w,
154
+ title: C,
155
155
  onClick: W === ee ? void 0 : ne,
156
156
  onDoubleClick: W === ee ? void 0 : re
157
157
  };
158
158
  }, [
159
159
  R,
160
- r,
160
+ n,
161
161
  W,
162
162
  ce,
163
163
  ae,
@@ -166,7 +166,7 @@ const Ie = tn.createContext({
166
166
  g,
167
167
  N,
168
168
  O,
169
- n,
169
+ s,
170
170
  h,
171
171
  ne,
172
172
  re,
@@ -174,19 +174,19 @@ const Ie = tn.createContext({
174
174
  oe,
175
175
  G
176
176
  ]), he = e.useCallback(
177
- (w) => {
177
+ (C) => {
178
178
  if (!v || !R)
179
179
  return;
180
- const T = parseInt(w.currentTarget.dataset.rowIndex);
181
- if (w.shiftKey && $ !== void 0) {
180
+ const T = parseInt(C.currentTarget.dataset.rowIndex);
181
+ if (C.shiftKey && $ !== void 0) {
182
182
  const A = p?.includes($) ? $ : void 0;
183
- if (A !== void 0 && r) {
183
+ if (A !== void 0 && n) {
184
184
  const x = o;
185
- for (const Q of un(
185
+ for (const Q of cn(
186
186
  x > A ? A + 1 : x,
187
187
  x > A ? x + 1 : A
188
188
  )) {
189
- const Me = r[Q]._index;
189
+ const Me = n[Q]._index;
190
190
  (!L || !L.includes(Me)) && v(Me);
191
191
  }
192
192
  }
@@ -202,40 +202,40 @@ const Ie = tn.createContext({
202
202
  R,
203
203
  o,
204
204
  b,
205
- r
205
+ n
206
206
  ]
207
207
  ), ve = e.useRef(null);
208
208
  if (!R || !j)
209
209
  return null;
210
210
  if (!I || g && !g[R._index])
211
- return /* @__PURE__ */ s("div", { ...j, children: "loading" });
211
+ return /* @__PURE__ */ r("div", { ...j, children: "loading" });
212
212
  if (W === we)
213
- return /* @__PURE__ */ s(
213
+ return /* @__PURE__ */ r(
214
214
  "div",
215
215
  {
216
216
  ...j,
217
217
  className: `${j.className} mig-schema-table__td--drag-handle`,
218
218
  draggable: !0,
219
- onDragStart: (w) => {
220
- w.dataTransfer.effectAllowed = "move", w.dataTransfer.setData("row-drag-index", String(o));
219
+ onDragStart: (C) => {
220
+ C.dataTransfer.effectAllowed = "move", C.dataTransfer.setData("row-drag-index", String(o));
221
221
  },
222
- onDragOver: (w) => {
223
- w.preventDefault(), w.dataTransfer.dropEffect = "move", u(o);
222
+ onDragOver: (C) => {
223
+ C.preventDefault(), C.dataTransfer.dropEffect = "move", u(o);
224
224
  },
225
225
  onDragEnd: () => u(-1),
226
- onDrop: (w) => {
227
- w.preventDefault(), u(-1);
226
+ onDrop: (C) => {
227
+ C.preventDefault(), u(-1);
228
228
  const T = parseInt(
229
- w.dataTransfer.getData("row-drag-index"),
229
+ C.dataTransfer.getData("row-drag-index"),
230
230
  10
231
231
  );
232
232
  isNaN(T) || S(T, o);
233
233
  },
234
- children: /* @__PURE__ */ s("span", { className: "mig-schema-table__td--drag-handle__icon", children: "⠿" })
234
+ children: /* @__PURE__ */ r("span", { className: "mig-schema-table__td--drag-handle__icon", children: "⠿" })
235
235
  }
236
236
  );
237
237
  if (W === ee)
238
- return /* @__PURE__ */ s("div", { ...j, onMouseDown: he, children: /* @__PURE__ */ s("div", { style: { textAlign: "center" }, children: /* @__PURE__ */ s(
238
+ return /* @__PURE__ */ r("div", { ...j, onMouseDown: he, children: /* @__PURE__ */ r("div", { style: { textAlign: "center" }, children: /* @__PURE__ */ r(
239
239
  "input",
240
240
  {
241
241
  ref: ve,
@@ -246,7 +246,7 @@ const Ie = tn.createContext({
246
246
  }
247
247
  ) }) });
248
248
  if (Z && g)
249
- return /* @__PURE__ */ s("div", { ...j, children: /* @__PURE__ */ s(
249
+ return /* @__PURE__ */ r("div", { ...j, children: /* @__PURE__ */ r(
250
250
  Z,
251
251
  {
252
252
  dataIndex: R._index,
@@ -256,7 +256,7 @@ const Ie = tn.createContext({
256
256
  }
257
257
  ) });
258
258
  const se = R[W];
259
- return ce?.format === "url" && se ? /* @__PURE__ */ s(
259
+ return ce?.format === "url" && se ? /* @__PURE__ */ r(
260
260
  "a",
261
261
  {
262
262
  href: se,
@@ -265,40 +265,40 @@ const Ie = tn.createContext({
265
265
  ...j,
266
266
  children: se
267
267
  }
268
- ) : /* @__PURE__ */ s("div", { ...j, children: se });
269
- }, Nt = e.memo(wn);
270
- function vn() {
271
- const { checkedIndexes: n, disabledCheckedIndexes: o, sortedRenderData: h } = e.useContext(Ie);
268
+ ) : /* @__PURE__ */ r("div", { ...j, children: se });
269
+ }, Lt = e.memo(Cn);
270
+ function wn() {
271
+ const { checkedIndexes: s, disabledCheckedIndexes: o, sortedRenderData: h } = e.useContext(Ie);
272
272
  return e.useMemo(() => {
273
273
  const p = [...h || []].filter(
274
- (_) => (n ? n.includes(_._index) : !0) || (o ? !o.includes(_._index) : !0)
274
+ (_) => (s ? s.includes(_._index) : !0) || (o ? !o.includes(_._index) : !0)
275
275
  );
276
- return n?.length !== 0 && p.length === n?.length;
277
- }, [n, o, h]);
276
+ return s?.length !== 0 && p.length === s?.length;
277
+ }, [s, o, h]);
278
278
  }
279
- function Wt(n, o, h) {
280
- return !!(n && h?.isSortable !== !1 && (o || h?.renderData || h?.sort));
279
+ function Ot(s, o, h) {
280
+ return !!(s && h?.isSortable !== !1 && (o || h?.renderData || h?.sort));
281
281
  }
282
- function jt() {
283
- const { setCustomColumnWidths: n, settingsStorageKey: o } = e.useContext(Ie);
282
+ function Wt() {
283
+ const { setCustomColumnWidths: s, settingsStorageKey: o } = e.useContext(Ie);
284
284
  return e.useCallback(
285
285
  (h) => {
286
286
  o && localStorage.setItem(
287
287
  `${o}.columnWidths`,
288
288
  JSON.stringify(Array.from(h))
289
- ), n(h);
289
+ ), s(h);
290
290
  },
291
- [n, o]
291
+ [s, o]
292
292
  );
293
293
  }
294
- const yn = ({ index: n, style: o }) => {
294
+ const vn = ({ index: s, style: o }) => {
295
295
  const {
296
296
  checkedIndexes: h,
297
297
  columnNames: p,
298
298
  columnWidths: _,
299
299
  config: f,
300
300
  disabledCheckedIndexes: L,
301
- dropTargetIndex: C,
301
+ dropTargetIndex: w,
302
302
  isColumnFilterable: O,
303
303
  isSortable: N,
304
304
  setCheckedIndexes: I,
@@ -311,12 +311,12 @@ const yn = ({ index: n, style: o }) => {
311
311
  settingsStorageKey: q,
312
312
  tableDataState: b,
313
313
  sortedRenderData: u,
314
- translate: r,
314
+ translate: n,
315
315
  displayTimezone: g
316
- } = e.useContext(Ie), [oe, W] = e.useState(!1), ce = n === C, G = jt(), v = p[n], J = v === ee ? { type: "boolean" } : $[v], ne = b.sortColumn === v ? b.sortAsc : void 0, re = f ? f[v] : void 0;
317
- let R = O && (J || re?.FilterMenu) && re?.isFilterable !== !1 ? Qe.AVAILABLE : Qe.UNAVAILABLE;
318
- b.columnFilterMap && b.columnFilterMap[v] !== void 0 && (R = Qe.ACTIVE);
319
- const ae = Wt(
316
+ } = e.useContext(Ie), [oe, W] = e.useState(!1), ce = s === w, G = Wt(), v = p[s], J = v === ee ? { type: "boolean" } : $[v], ne = b.sortColumn === v ? b.sortAsc : void 0, re = f ? f[v] : void 0;
317
+ let R = O && (J || re?.FilterMenu) && re?.isFilterable !== !1 ? Be.AVAILABLE : Be.UNAVAILABLE;
318
+ b.columnFilterMap && b.columnFilterMap[v] !== void 0 && (R = Be.ACTIVE);
319
+ const ae = Ot(
320
320
  N,
321
321
  J,
322
322
  re
@@ -333,7 +333,7 @@ const yn = ({ index: n, style: o }) => {
333
333
  defaultSortDesc: he,
334
334
  showTimezones: ve = !g,
335
335
  title: se
336
- } = re || {}, w = e.useCallback(() => {
336
+ } = re || {}, C = e.useCallback(() => {
337
337
  if (ae) {
338
338
  if (ne === void 0) {
339
339
  Y(v, !he);
@@ -361,16 +361,16 @@ const yn = ({ index: n, style: o }) => {
361
361
  });
362
362
  },
363
363
  [re, T, v, te]
364
- ), x = e.useMemo(() => se !== void 0 ? se : ue === "date-time" && ve ? `${r(v)} (${r(g || Ne)})` : r(v), [se, ue, ve, r, v, g]), Q = e.useCallback(
364
+ ), x = e.useMemo(() => se !== void 0 ? se : ue === "date-time" && ve ? `${n(v)} (${n(g || Ne)})` : n(v), [se, ue, ve, n, v, g]), Q = e.useCallback(
365
365
  (U, fe) => {
366
366
  if (!p || !_)
367
367
  return;
368
368
  const ye = p.indexOf(U), ke = [...p];
369
369
  ke.splice(ye, 1);
370
- const H = ke.indexOf(fe);
371
- ke.splice(H + 1, 0, U), D(ke);
372
- const _e = [..._], Oe = _e[ye];
373
- _e.splice(ye, 1), _e.splice(H + 1, 0, Oe), G(new Uint16Array(_e)), q && localStorage.setItem(
370
+ const X = ke.indexOf(fe);
371
+ ke.splice(X + 1, 0, U), D(ke);
372
+ const _e = [..._], ze = _e[ye];
373
+ _e.splice(ye, 1), _e.splice(X + 1, 0, ze), G(new Uint16Array(_e)), q && localStorage.setItem(
374
374
  `${q}.columnNames`,
375
375
  JSON.stringify(ke)
376
376
  );
@@ -389,11 +389,11 @@ const yn = ({ index: n, style: o }) => {
389
389
  [Q, v]
390
390
  ), Se = e.useCallback(() => {
391
391
  Q && (W(!1), S(-1));
392
- }, [Q, S]), ze = e.useCallback(
392
+ }, [Q, S]), Qe = e.useCallback(
393
393
  (U) => {
394
- Q && (U.preventDefault(), S(n));
394
+ Q && (U.preventDefault(), S(s));
395
395
  },
396
- [n, Q, S]
396
+ [s, Q, S]
397
397
  ), Re = e.useCallback(
398
398
  (U) => {
399
399
  if (S(-1), !Q || !v)
@@ -402,7 +402,7 @@ const yn = ({ index: n, style: o }) => {
402
402
  !fe || fe === v || Q(fe, v);
403
403
  },
404
404
  [Q, v, S]
405
- ), Ae = vn(), Ke = e.useCallback(() => {
405
+ ), Ae = wn(), Ke = e.useCallback(() => {
406
406
  !I || !u || I(
407
407
  Ae ? [] : u.map((U) => U._index).filter((U) => !L?.includes(U))
408
408
  );
@@ -413,7 +413,7 @@ const yn = ({ index: n, style: o }) => {
413
413
  L
414
414
  ]);
415
415
  if (v === we)
416
- return /* @__PURE__ */ s(
416
+ return /* @__PURE__ */ r(
417
417
  "div",
418
418
  {
419
419
  style: o,
@@ -421,7 +421,7 @@ const yn = ({ index: n, style: o }) => {
421
421
  }
422
422
  );
423
423
  if (v === ee)
424
- return /* @__PURE__ */ s("div", { style: o, className: Z.join(" "), children: /* @__PURE__ */ s(
424
+ return /* @__PURE__ */ r("div", { style: o, className: Z.join(" "), children: /* @__PURE__ */ r(
425
425
  "div",
426
426
  {
427
427
  style: {
@@ -429,7 +429,7 @@ const yn = ({ index: n, style: o }) => {
429
429
  textAlign: "center"
430
430
  },
431
431
  title: `${h?.length || 0} selected`,
432
- children: /* @__PURE__ */ s(
432
+ children: /* @__PURE__ */ r(
433
433
  "input",
434
434
  {
435
435
  type: "checkbox",
@@ -467,7 +467,7 @@ const yn = ({ index: n, style: o }) => {
467
467
  draggable: !0,
468
468
  onDragStart: Me,
469
469
  onDragEnd: Se,
470
- onDragOver: ze,
470
+ onDragOver: Qe,
471
471
  onDrop: Re,
472
472
  children: [
473
473
  /* @__PURE__ */ B(
@@ -475,19 +475,19 @@ const yn = ({ index: n, style: o }) => {
475
475
  {
476
476
  className: "mig-schema-table__th__label-body",
477
477
  style: { lineHeight: "44px" },
478
- onClick: w,
478
+ onClick: C,
479
479
  children: [
480
- /* @__PURE__ */ s("span", { className: "mig-schema-table__th__label-body-text", children: x }),
481
- ne === void 0 ? null : /* @__PURE__ */ s("span", { className: "mig-schema-table__th__sort-icon", children: ne ? "↓" : "↑" })
480
+ /* @__PURE__ */ r("span", { className: "mig-schema-table__th__label-body-text", children: x }),
481
+ ne === void 0 ? null : /* @__PURE__ */ r("span", { className: "mig-schema-table__th__sort-icon", children: ne ? "↓" : "↑" })
482
482
  ]
483
483
  }
484
484
  ),
485
- ae || R !== Qe.UNAVAILABLE ? /* @__PURE__ */ s(
485
+ ae || R !== Be.UNAVAILABLE ? /* @__PURE__ */ r(
486
486
  "button",
487
487
  {
488
488
  className: "mig-schema-table__th__trigger-el",
489
489
  onClick: A,
490
- children: /* @__PURE__ */ s(
490
+ children: /* @__PURE__ */ r(
491
491
  "svg",
492
492
  {
493
493
  xmlns: "http://www.w3.org/2000/svg",
@@ -499,7 +499,7 @@ const yn = ({ index: n, style: o }) => {
499
499
  strokeWidth: "2",
500
500
  strokeLinecap: "round",
501
501
  strokeLinejoin: "round",
502
- children: /* @__PURE__ */ s("polyline", { points: "6 9 12 15 18 9" })
502
+ children: /* @__PURE__ */ r("polyline", { points: "6 9 12 15 18 9" })
503
503
  }
504
504
  )
505
505
  }
@@ -507,13 +507,13 @@ const yn = ({ index: n, style: o }) => {
507
507
  ]
508
508
  }
509
509
  );
510
- }, kn = e.memo(yn), Dn = {
510
+ }, yn = e.memo(vn), kn = {
511
511
  [pe.GT]: ">",
512
512
  [pe.LT]: "<",
513
513
  [pe.EQ]: "="
514
- }, xn = e.memo(
514
+ }, Dn = e.memo(
515
515
  ({
516
- columnFilterValue: n,
516
+ columnFilterValue: s,
517
517
  onChange: o,
518
518
  onInputKeyDown: h,
519
519
  propIsRequired: p,
@@ -521,12 +521,12 @@ const yn = ({ index: n, style: o }) => {
521
521
  propSchema: f,
522
522
  translate: L
523
523
  }) => {
524
- const { displayTimezone: C } = e.useContext(Ie), { type: O, format: N, minimum: I, maximum: $ } = f || {}, M = n, D = N === "date-time";
524
+ const { displayTimezone: w } = e.useContext(Ie), { type: O, format: N, minimum: I, maximum: $ } = f || {}, M = s, D = N === "date-time";
525
525
  let S, Y;
526
526
  switch (O) {
527
527
  case "number":
528
528
  case "integer":
529
- return S = M || {}, Y = (b, u, r) => {
529
+ return S = M || {}, Y = (b, u, n) => {
530
530
  const g = {
531
531
  ...S,
532
532
  [b]: u.value === "" ? void 0 : parseInt(u.value)
@@ -535,12 +535,12 @@ const yn = ({ index: n, style: o }) => {
535
535
  );
536
536
  o(
537
537
  oe !== void 0 && (I === void 0 || oe >= I) ? g : void 0,
538
- r
538
+ n
539
539
  );
540
540
  }, /* @__PURE__ */ B("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: [
541
541
  p ? null : /* @__PURE__ */ B("li", { style: { padding: 8 }, children: [
542
542
  /* @__PURE__ */ B("label", { className: "d-flex", children: [
543
- /* @__PURE__ */ s(
543
+ /* @__PURE__ */ r(
544
544
  "input",
545
545
  {
546
546
  type: "checkbox",
@@ -557,13 +557,13 @@ const yn = ({ index: n, style: o }) => {
557
557
  ),
558
558
  "Hide empty values"
559
559
  ] }),
560
- /* @__PURE__ */ s("hr", {})
560
+ /* @__PURE__ */ r("hr", {})
561
561
  ] }),
562
562
  Object.keys(pe).map((b) => {
563
563
  const u = S[b];
564
564
  return /* @__PURE__ */ B("li", { children: [
565
- /* @__PURE__ */ s("label", { style: { width: 40, paddingLeft: 16 }, children: Dn[b] }),
566
- /* @__PURE__ */ s(
565
+ /* @__PURE__ */ r("label", { style: { width: 40, paddingLeft: 16 }, children: kn[b] }),
566
+ /* @__PURE__ */ r(
567
567
  "input",
568
568
  {
569
569
  className: "form-control",
@@ -571,17 +571,17 @@ const yn = ({ index: n, style: o }) => {
571
571
  type: "number",
572
572
  value: u !== void 0 ? u : "",
573
573
  "data-prop-name": _,
574
- onChange: (r) => {
574
+ onChange: (n) => {
575
575
  Y(
576
576
  b,
577
- r.currentTarget,
577
+ n.currentTarget,
578
578
  !1
579
579
  );
580
580
  },
581
- onBlur: (r) => {
581
+ onBlur: (n) => {
582
582
  Y(
583
583
  b,
584
- r.currentTarget,
584
+ n.currentTarget,
585
585
  !0
586
586
  );
587
587
  },
@@ -598,10 +598,10 @@ const yn = ({ index: n, style: o }) => {
598
598
  p || te.push(null);
599
599
  const q = M ? M.map((b) => ({
600
600
  value: b,
601
- label: Lt.get(b)
601
+ label: Et.get(b)
602
602
  })) : null;
603
- return /* @__PURE__ */ s("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: /* @__PURE__ */ s("li", { children: /* @__PURE__ */ s(
604
- yt,
603
+ return /* @__PURE__ */ r("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r(
604
+ vt,
605
605
  {
606
606
  autoFocus: !0,
607
607
  menuIsOpen: !0,
@@ -613,7 +613,7 @@ const yn = ({ index: n, style: o }) => {
613
613
  value: q,
614
614
  options: te.map((b) => ({
615
615
  value: b,
616
- label: Lt.get(b)
616
+ label: Et.get(b)
617
617
  })),
618
618
  styles: {
619
619
  menu: (b) => ({
@@ -622,7 +622,7 @@ const yn = ({ index: n, style: o }) => {
622
622
  })
623
623
  },
624
624
  onChange: (b) => {
625
- const u = b && b.length ? b.map(({ value: r }) => r) : void 0;
625
+ const u = b && b.length ? b.map(({ value: n }) => n) : void 0;
626
626
  o(u, !0);
627
627
  },
628
628
  onKeyDown: h
@@ -631,14 +631,14 @@ const yn = ({ index: n, style: o }) => {
631
631
  // @ts-expect-error falls through
632
632
  case "string":
633
633
  if (f?.enum) {
634
- const b = f.enum.map((r) => ({
635
- value: r,
636
- label: L(r)
634
+ const b = f.enum.map((n) => ({
635
+ value: n,
636
+ label: L(n)
637
637
  })), u = b.filter(
638
- (r) => (M || []).includes(r.value)
638
+ (n) => (M || []).includes(n.value)
639
639
  );
640
- return /* @__PURE__ */ s("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: /* @__PURE__ */ s("li", { children: /* @__PURE__ */ s(
641
- yt,
640
+ return /* @__PURE__ */ r("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r(
641
+ vt,
642
642
  {
643
643
  isMulti: !0,
644
644
  autoFocus: !0,
@@ -648,13 +648,13 @@ const yn = ({ index: n, style: o }) => {
648
648
  value: u,
649
649
  options: b,
650
650
  styles: {
651
- menu: (r) => ({
652
- ...r,
651
+ menu: (n) => ({
652
+ ...n,
653
653
  marginTop: 0
654
654
  })
655
655
  },
656
- onChange: (r) => {
657
- const g = r ? r.map(
656
+ onChange: (n) => {
657
+ const g = n ? n.map(
658
658
  (oe) => oe.value
659
659
  ) : [];
660
660
  o(g.length ? g : void 0, !0);
@@ -665,7 +665,7 @@ const yn = ({ index: n, style: o }) => {
665
665
  ) }) });
666
666
  }
667
667
  if (D || N === "date") {
668
- const b = D ? Ye : $t, u = n || {
668
+ const b = D ? Ye : Rt, u = s || {
669
669
  from: void 0,
670
670
  to: void 0,
671
671
  filterEmpty: void 0
@@ -673,14 +673,14 @@ const yn = ({ index: n, style: o }) => {
673
673
  return /* @__PURE__ */ B("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: [
674
674
  p ? null : /* @__PURE__ */ B("li", { style: { padding: 8 }, children: [
675
675
  /* @__PURE__ */ B("label", { className: "d-flex", children: [
676
- /* @__PURE__ */ s(
676
+ /* @__PURE__ */ r(
677
677
  "input",
678
678
  {
679
679
  type: "checkbox",
680
680
  checked: !!u.filterEmpty,
681
681
  onChange: () => {
682
- const { filterEmpty: r, ...g } = u;
683
- r || (g.filterEmpty = !0), o(
682
+ const { filterEmpty: n, ...g } = u;
683
+ n || (g.filterEmpty = !0), o(
684
684
  Object.keys(g).length ? g : void 0,
685
685
  !0
686
686
  );
@@ -689,30 +689,30 @@ const yn = ({ index: n, style: o }) => {
689
689
  ),
690
690
  "Hide empty values"
691
691
  ] }),
692
- /* @__PURE__ */ s("hr", {})
692
+ /* @__PURE__ */ r("hr", {})
693
693
  ] }),
694
694
  /* @__PURE__ */ B("li", { style: { padding: 8 }, children: [
695
- /* @__PURE__ */ s("label", { style: { width: 120, paddingLeft: 4 }, children: "After" }),
696
- /* @__PURE__ */ s(
697
- vt,
695
+ /* @__PURE__ */ r("label", { style: { width: 120, paddingLeft: 4 }, children: "After" }),
696
+ /* @__PURE__ */ r(
697
+ wt,
698
698
  {
699
699
  dateFormat: b,
700
700
  "data-prop-name": _,
701
- locale: kt,
701
+ locale: yt,
702
702
  selected: u.from ? new Ve(u.from).withTimeZone(
703
- C || Ne
703
+ w || Ne
704
704
  ) : null,
705
- onChange: (r) => {
706
- if (!r && !u.to) {
705
+ onChange: (n) => {
706
+ if (!n && !u.to) {
707
707
  o(void 0, !0);
708
708
  return;
709
709
  }
710
- if (u.to && r && r > u.to)
710
+ if (u.to && n && n > u.to)
711
711
  return;
712
- const g = r ? Ve.tz(C || Ne, r) : void 0;
712
+ const g = n ? Ve.tz(w || Ne, n) : void 0;
713
713
  o(
714
714
  {
715
- ...n,
715
+ ...s,
716
716
  from: g
717
717
  },
718
718
  !0
@@ -731,29 +731,29 @@ const yn = ({ index: n, style: o }) => {
731
731
  )
732
732
  ] }),
733
733
  /* @__PURE__ */ B("li", { style: { padding: 8 }, children: [
734
- /* @__PURE__ */ s("label", { style: { width: 120, paddingLeft: 4 }, children: "Before" }),
735
- /* @__PURE__ */ s(
736
- vt,
734
+ /* @__PURE__ */ r("label", { style: { width: 120, paddingLeft: 4 }, children: "Before" }),
735
+ /* @__PURE__ */ r(
736
+ wt,
737
737
  {
738
738
  id: "filter-date",
739
739
  dateFormat: b,
740
740
  "data-prop-name": _,
741
- locale: kt,
741
+ locale: yt,
742
742
  selectsEnd: !0,
743
743
  selected: u.to ? new Ve(u.to).withTimeZone(
744
- C || Ne
744
+ w || Ne
745
745
  ) : null,
746
746
  showMonthDropdown: !0,
747
747
  showYearDropdown: !0,
748
- onChange: (r) => {
749
- if (!r && !u.from) {
748
+ onChange: (n) => {
749
+ if (!n && !u.from) {
750
750
  o(void 0, !0);
751
751
  return;
752
752
  }
753
- const g = r ? D ? Ve.tz(C || Ne, r) : on(r) : void 0;
753
+ const g = n ? D ? Ve.tz(w || Ne, n) : sn(n) : void 0;
754
754
  u.from && g && g < u.from || o(
755
755
  {
756
- ...n,
756
+ ...s,
757
757
  to: g
758
758
  },
759
759
  !0
@@ -774,7 +774,7 @@ const yn = ({ index: n, style: o }) => {
774
774
  }
775
775
  // falls through
776
776
  default:
777
- return /* @__PURE__ */ s("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: /* @__PURE__ */ s("li", { children: /* @__PURE__ */ s(
777
+ return /* @__PURE__ */ r("ol", { className: "mig-schema-table-menu mig-schema-table__th-menu__filter-menu-component", children: /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r(
778
778
  "input",
779
779
  {
780
780
  autoFocus: !0,
@@ -785,17 +785,17 @@ const yn = ({ index: n, style: o }) => {
785
785
  value: Array.isArray(M) ? M.join(",") : M || "",
786
786
  "data-prop-name": _,
787
787
  onChange: (b) => {
788
- const u = b.currentTarget.value, r = u ? u.split(",") : [];
788
+ const u = b.currentTarget.value, n = u ? u.split(",") : [];
789
789
  o(
790
- (r.length > 1 ? r : r[0]) || void 0,
790
+ (n.length > 1 ? n : n[0]) || void 0,
791
791
  !1
792
792
  );
793
793
  },
794
794
  onKeyDown: h,
795
795
  onBlur: (b) => {
796
- const u = b.currentTarget.value, r = u ? u.split(",") : [];
796
+ const u = b.currentTarget.value, n = u ? u.split(",") : [];
797
797
  o(
798
- (r.length > 1 ? r : r[0]) || void 0,
798
+ (n.length > 1 ? n : n[0]) || void 0,
799
799
  !0
800
800
  );
801
801
  }
@@ -803,42 +803,42 @@ const yn = ({ index: n, style: o }) => {
803
803
  ) }) });
804
804
  }
805
805
  }
806
- ), Tn = ({
807
- isSortable: n,
806
+ ), xn = ({
807
+ isSortable: s,
808
808
  isFilterable: o,
809
809
  onChange: h,
810
810
  onClose: p,
811
811
  onInputKeyDown: _,
812
812
  propConfig: f,
813
813
  propIsRequired: L,
814
- propName: C,
814
+ propName: w,
815
815
  propSchema: O,
816
816
  referenceElement: N,
817
817
  setFilterSortColumn: I,
818
818
  translate: $,
819
819
  value: M
820
820
  }) => {
821
- const D = Dt({
821
+ const D = kt({
822
822
  placement: "bottom-start",
823
823
  elements: {
824
824
  reference: N
825
825
  },
826
- middleware: [xt()]
827
- }), S = Dt({
826
+ middleware: [Dt()]
827
+ }), S = kt({
828
828
  placement: "right-start",
829
- middleware: [xt()]
829
+ middleware: [Dt()]
830
830
  });
831
831
  e.useEffect(() => {
832
- const u = (r) => {
832
+ const u = (n) => {
833
833
  if (!D.elements.floating)
834
834
  return;
835
- let g = r.target;
835
+ let g = n.target;
836
836
  for (; g && D.elements.floating; ) {
837
837
  if (g === D.elements.floating || g === S.elements.floating)
838
838
  return;
839
839
  g = g.parentNode === window.document ? null : g.parentNode;
840
840
  }
841
- p(r);
841
+ p(n);
842
842
  };
843
843
  return window.addEventListener("click", u, { capture: !0 }), () => {
844
844
  window.removeEventListener("click", u, { capture: !0 });
@@ -848,34 +848,34 @@ const yn = ({ index: n, style: o }) => {
848
848
  p,
849
849
  S.elements.floating
850
850
  ]);
851
- const Y = f?.FilterMenu || xn, te = e.useCallback(
851
+ const Y = f?.FilterMenu || Dn, te = e.useCallback(
852
852
  (u) => {
853
- I(C, !0), p(u);
853
+ I(w, !0), p(u);
854
854
  },
855
- [p, C, I]
855
+ [p, w, I]
856
856
  ), q = e.useCallback(
857
857
  (u) => {
858
- I(C, !1), p(u);
858
+ I(w, !1), p(u);
859
859
  },
860
- [p, C, I]
860
+ [p, w, I]
861
861
  ), b = e.useCallback(() => {
862
862
  h(void 0, !0);
863
863
  }, [h]);
864
- return !n && !o ? null : /* @__PURE__ */ B(en, { children: [
865
- /* @__PURE__ */ s(
864
+ return !s && !o ? null : /* @__PURE__ */ B(Kt, { children: [
865
+ /* @__PURE__ */ r(
866
866
  "div",
867
867
  {
868
868
  className: "mig-schema-table mig-schema-table__th-menu",
869
869
  ref: D.refs.setFloating,
870
870
  style: D.floatingStyles,
871
871
  children: /* @__PURE__ */ B("ol", { className: "mig-schema-table-menu", children: [
872
- n ? /* @__PURE__ */ B("li", { onClick: te, style: { padding: 8 }, children: [
873
- /* @__PURE__ */ s("span", { className: "mig-schema-table__th-menu__icon", children: "↓" }),
872
+ s ? /* @__PURE__ */ B("li", { onClick: te, style: { padding: 8 }, children: [
873
+ /* @__PURE__ */ r("span", { className: "mig-schema-table__th-menu__icon", children: "↓" }),
874
874
  " ",
875
875
  $("sortAscending")
876
876
  ] }) : null,
877
- n ? /* @__PURE__ */ B("li", { onClick: q, style: { padding: 8 }, children: [
878
- /* @__PURE__ */ s("span", { className: "mig-schema-table__th-menu__icon", children: "↑" }),
877
+ s ? /* @__PURE__ */ B("li", { onClick: q, style: { padding: 8 }, children: [
878
+ /* @__PURE__ */ r("span", { className: "mig-schema-table__th-menu__icon", children: "↑" }),
879
879
  " ",
880
880
  $("sortDescending")
881
881
  ] }) : null,
@@ -887,7 +887,7 @@ const yn = ({ index: n, style: o }) => {
887
887
  S.refs.setReference(u.currentTarget);
888
888
  },
889
889
  children: [
890
- /* @__PURE__ */ s("span", { className: "mig-schema-table__th-menu__icon", children: /* @__PURE__ */ s(
890
+ /* @__PURE__ */ r("span", { className: "mig-schema-table__th-menu__icon", children: /* @__PURE__ */ r(
891
891
  "input",
892
892
  {
893
893
  type: "checkbox",
@@ -897,28 +897,28 @@ const yn = ({ index: n, style: o }) => {
897
897
  onChange: b
898
898
  }
899
899
  ) }),
900
- /* @__PURE__ */ s("label", { htmlFor: "mig-schema-table__th-menu__filters", children: $("filters") }),
901
- /* @__PURE__ */ s("div", { className: "mig-schema-table__th-menu__sub-menu-indicator" })
900
+ /* @__PURE__ */ r("label", { htmlFor: "mig-schema-table__th-menu__filters", children: $("filters") }),
901
+ /* @__PURE__ */ r("div", { className: "mig-schema-table__th-menu__sub-menu-indicator" })
902
902
  ]
903
903
  }
904
904
  ) : null
905
905
  ] })
906
906
  }
907
907
  ),
908
- S.elements.reference ? /* @__PURE__ */ s(
908
+ S.elements.reference ? /* @__PURE__ */ r(
909
909
  "div",
910
910
  {
911
911
  className: "mig-schema-table mig-schema-table__th-menu__sub-menu",
912
912
  ref: S.refs.setFloating,
913
913
  style: S.floatingStyles,
914
- children: /* @__PURE__ */ s(
914
+ children: /* @__PURE__ */ r(
915
915
  Y,
916
916
  {
917
917
  columnFilterValue: M,
918
918
  onChange: h,
919
919
  onInputKeyDown: _,
920
920
  propIsRequired: L,
921
- propName: C,
921
+ propName: w,
922
922
  propSchema: O,
923
923
  translate: $
924
924
  }
@@ -926,20 +926,20 @@ const yn = ({ index: n, style: o }) => {
926
926
  }
927
927
  ) : null
928
928
  ] });
929
- }, Mn = e.memo(Tn), An = ({
930
- columnWidths: n,
929
+ }, Tn = e.memo(xn), Mn = ({
930
+ columnWidths: s,
931
931
  resizeColumnIndex: o,
932
932
  setResizeColumnIndex: h,
933
933
  tableBodyHeight: p
934
934
  }) => {
935
- const [_, f] = e.useState(0), L = jt(), C = e.useCallback(
935
+ const [_, f] = e.useState(0), L = Wt(), w = e.useCallback(
936
936
  ($) => {
937
- const M = n.map(
938
- (D, S) => S === o ? Math.max(D + $, Ot) : D
937
+ const M = s.map(
938
+ (D, S) => S === o ? Math.max(D + $, $t) : D
939
939
  );
940
940
  L(M);
941
941
  },
942
- [n, o, L]
942
+ [s, o, L]
943
943
  );
944
944
  let O = 0;
945
945
  const N = e.useCallback(
@@ -949,17 +949,17 @@ const yn = ({ index: n, style: o }) => {
949
949
  [h]
950
950
  ), I = e.useCallback(
951
951
  ($) => {
952
- C($.clientX - _), f(0), h(-1);
952
+ w($.clientX - _), f(0), h(-1);
953
953
  },
954
- [_, C, h]
954
+ [_, w, h]
955
955
  );
956
- return /* @__PURE__ */ s("div", { children: [...n].map(($, M) => {
956
+ return /* @__PURE__ */ r("div", { children: [...s].map(($, M) => {
957
957
  O += $;
958
958
  const D = ["mig-schema-table__column_resizer"];
959
- return M === o && D.push("mig-schema-table__column_resizer--dragged"), /* @__PURE__ */ s(
959
+ return M === o && D.push("mig-schema-table__column_resizer--dragged"), /* @__PURE__ */ r(
960
960
  "div",
961
961
  {
962
- style: { left: O - _n, bottom: p },
962
+ style: { left: O - pn, bottom: p },
963
963
  className: D.join(" "),
964
964
  draggable: "true",
965
965
  "data-column-index": M,
@@ -969,82 +969,79 @@ const yn = ({ index: n, style: o }) => {
969
969
  M
970
970
  );
971
971
  }) });
972
- }, It = (n) => {
972
+ }, Nt = (s) => {
973
973
  const [o, h] = e.useState({ width: 0, height: 0 }), p = e.useMemo(
974
- () => dn(h, 100),
974
+ () => un(h, 100),
975
975
  []
976
976
  );
977
977
  return e.useEffect(() => {
978
- if (!n)
978
+ if (!s)
979
979
  return;
980
980
  const _ = new ResizeObserver((f) => {
981
981
  for (const L of f) {
982
- const { blockSize: C, inlineSize: O } = L.borderBoxSize[0];
982
+ const { blockSize: w, inlineSize: O } = L.borderBoxSize[0];
983
983
  p(
984
- (N) => O && C && (N.width !== O || N.height !== C) ? { width: O, height: C } : N
984
+ (N) => O && w && (N.width !== O || N.height !== w) ? { width: O, height: w } : N
985
985
  );
986
986
  }
987
987
  });
988
- return _.observe(n), () => {
988
+ return _.observe(s), () => {
989
989
  _.disconnect();
990
990
  };
991
- }, [p, n]), o;
992
- }, En = () => new Promise((n, o) => {
991
+ }, [p, s]), o;
992
+ }, An = () => new Promise((s, o) => {
993
993
  if (window.ExcelJS) {
994
- n(window.ExcelJS);
994
+ s(window.ExcelJS);
995
995
  return;
996
996
  }
997
997
  const h = document.createElement("script");
998
998
  h.src = "https://cdnjs.cloudflare.com/ajax/libs/exceljs/4.4.0/exceljs.bare.min.js", h.onload = () => {
999
- n(window.ExcelJS);
999
+ s(window.ExcelJS);
1000
1000
  }, h.onerror = () => {
1001
1001
  o(new Error("Failed to load ExcelJS library"));
1002
1002
  }, document.head.appendChild(h);
1003
- }), Ln = async (n) => {
1004
- const { Workbook: o } = await En(), h = new o(), p = h.addWorksheet("Data");
1005
- n.length && (p.addRow(
1006
- mn(Object.keys(n[0]), [
1003
+ }), En = async (s) => {
1004
+ const { Workbook: o } = await An(), h = new o(), p = h.addWorksheet("Data");
1005
+ s.length && (p.addRow(
1006
+ dn(Object.keys(s[0]), [
1007
1007
  "_index",
1008
1008
  "SELECT_ALL_COLUMN_NAME"
1009
1009
  ])
1010
1010
  ), p.getRow(1).font = { bold: !0 }, p.addRows(
1011
- n.map((_) => {
1012
- const { _index: f, SELECT_ALL_COLUMN_NAME: L, ...C } = _;
1013
- return Object.values(C);
1011
+ s.map((_) => {
1012
+ const { _index: f, SELECT_ALL_COLUMN_NAME: L, ...w } = _;
1013
+ return Object.values(w);
1014
1014
  })
1015
1015
  ), h.xlsx.writeBuffer().then((_) => {
1016
1016
  const f = new Blob([_], {
1017
1017
  type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
1018
1018
  });
1019
- bn(f, "export.xlsx");
1019
+ gn(f, "export.xlsx");
1020
1020
  }).catch((_) => {
1021
1021
  console.error("Error generating Excel file:", _);
1022
1022
  }));
1023
- }, St = /* @__PURE__ */ new Date("1000-01-01 00:00:00Z"), Nn = new Intl.NumberFormat("nl-NL"), In = new Intl.NumberFormat("nl-NL", {
1023
+ }, It = /* @__PURE__ */ new Date("1000-01-01 00:00:00Z"), Ln = new Intl.NumberFormat("nl-NL"), Nn = new Intl.NumberFormat("nl-NL", {
1024
1024
  style: "currency",
1025
1025
  currency: "EUR"
1026
1026
  });
1027
- function Sn(n, o) {
1027
+ function In(s, o) {
1028
1028
  const { TdBody: h, sortByValue: p } = o || {};
1029
1029
  if (p !== void 0)
1030
1030
  return p;
1031
- if (!n)
1031
+ if (!s)
1032
1032
  return !1;
1033
- const { format: _, type: f } = n;
1033
+ const { format: _, type: f } = s;
1034
1034
  return _?.startsWith("date") || f === "boolean" || f === "integer" || f === "number" || !!h;
1035
1035
  }
1036
- function ct(n) {
1037
- return n ? [...n.keys()] : void 0;
1038
- }
1039
- const Rn = ({
1040
- CustomElement: n,
1036
+ const Sn = ({
1037
+ CustomElement: s,
1041
1038
  CustomSearchInput: o,
1042
- Heading: h = rn,
1039
+ Heading: h = nn,
1043
1040
  autoRender: p,
1044
1041
  checkedIndexes: _,
1045
1042
  config: f,
1046
1043
  customElementProps: L,
1047
- data: C,
1044
+ data: w,
1048
1045
  defaultColumnFilters: O,
1049
1046
  defaultSortAsc: N = !1,
1050
1047
  defaultSortColumn: I,
@@ -1057,7 +1054,7 @@ const Rn = ({
1057
1054
  getSearchQueryFilterResult: q,
1058
1055
  infiniteLoaderRef: b,
1059
1056
  isDraggable: u = !1,
1060
- isColumnFilterable: r = !0,
1057
+ isColumnFilterable: n = !0,
1061
1058
  isExportable: g = !0,
1062
1059
  isResizable: oe = !0,
1063
1060
  isSearchable: W = !0,
@@ -1075,54 +1072,52 @@ const Rn = ({
1075
1072
  schema: he,
1076
1073
  searchPlaceholder: ve,
1077
1074
  setCheckedIndexes: se,
1078
- settingsStorageKey: w,
1075
+ settingsStorageKey: C,
1079
1076
  style: T,
1080
- translate: A = Tt,
1077
+ translate: A = xt,
1081
1078
  useFilterStateHash: x,
1082
1079
  width: Q
1083
1080
  }, Me) => {
1084
- const [Se, ze] = e.useState(), [Re, Ae] = e.useState(), [Ke, $e] = e.useState(-1), [U, fe] = e.useState(-1), [ye, ke] = e.useState(-1), H = C instanceof Function, [_e, Oe] = e.useState(
1085
- H ? void 0 : ct(C)
1086
- ), [X, et] = e.useState(), [Ft, Bt] = e.useState(), [y, tt] = e.useState(
1087
- H ? void 0 : C
1081
+ const [Se, Qe] = e.useState(), [Re, Ae] = e.useState(), [Ke, $e] = e.useState(-1), [U, fe] = e.useState(-1), [ye, ke] = e.useState(-1), X = w instanceof Function, [_e, ze] = e.useState(), [H, et] = e.useState(), [jt, Ft] = e.useState(), [y, tt] = e.useState(
1082
+ X ? void 0 : w
1088
1083
  ), [De, nt] = e.useState(), [c, xe] = e.useState({
1089
1084
  searchQuery: "",
1090
1085
  columnFilterMap: O || {},
1091
1086
  sortColumn: I,
1092
1087
  sortAsc: N
1093
- }), [P, Qt] = e.useState(
1094
- x ? wt(window.location.hash) : null
1088
+ }), [P, Bt] = e.useState(
1089
+ x ? Ct(window.location.hash) : null
1095
1090
  );
1096
1091
  e.useEffect(() => {
1097
- H || (tt(C), Oe(ct(C)));
1098
- }, [C, H]), e.useEffect(() => {
1099
- !H || y !== void 0 || C(
1092
+ X || tt(w);
1093
+ }, [w, X]), e.useEffect(() => {
1094
+ !X || y !== void 0 || w(
1100
1095
  P && Object.keys(P).length !== 0 ? {
1101
1096
  ...P,
1102
1097
  columnFilterMap: P.columnFilterMap || {}
1103
1098
  } : c
1104
1099
  ).then((t) => {
1105
- tt(t), Oe(ct(t));
1100
+ tt(t);
1106
1101
  });
1107
- }, [C, H, P, y, c]), e.useEffect(() => {
1102
+ }, [w, X, P, y, c]), e.useEffect(() => {
1108
1103
  De || nt(c);
1109
1104
  }, [c, De]), e.useEffect(() => {
1110
1105
  if (!x)
1111
1106
  return;
1112
1107
  const t = () => {
1113
- Qt(wt(window.location.hash));
1108
+ Bt(Ct(window.location.hash));
1114
1109
  };
1115
1110
  return window.addEventListener("hashchange", t), () => {
1116
1111
  window.removeEventListener("hashchange", t);
1117
1112
  };
1118
1113
  }, [x]);
1119
- const dt = e.useRef(O);
1120
- dt.current = O, e.useEffect(() => {
1114
+ const ut = e.useRef(O);
1115
+ ut.current = O, e.useEffect(() => {
1121
1116
  if (!x)
1122
1117
  return;
1123
1118
  const { columnFilterMap: t, searchQuery: a, sortAsc: l, sortColumn: i } = P || {}, d = {
1124
1119
  searchQuery: a || "",
1125
- columnFilterMap: t || dt.current || {},
1120
+ columnFilterMap: t || ut.current || {},
1126
1121
  sortAsc: l === void 0 ? N : l,
1127
1122
  sortColumn: i === void 0 ? I : i
1128
1123
  };
@@ -1132,19 +1127,19 @@ const Rn = ({
1132
1127
  }, [P, x, N, I]), e.useEffect(() => {
1133
1128
  Z && Z(c);
1134
1129
  }, [Z, c]);
1135
- const Ue = e.useRef(null), mt = e.useRef(null), ht = e.useRef(null), Pe = It(mt.current), ft = It(
1136
- ht.current
1137
- ), We = e.useMemo(
1130
+ const Ue = e.useRef(null), dt = e.useRef(null), mt = e.useRef(null), Pe = Nt(dt.current), ht = Nt(
1131
+ mt.current
1132
+ ), Oe = e.useMemo(
1138
1133
  () => Q || Math.floor(Pe.width || 0),
1139
1134
  [Pe.width, Q]
1140
- ), je = e.useMemo(() => !Xe(c, De) && H, [c, De, H]), { properties: ie, required: zt } = e.useMemo(
1135
+ ), We = e.useMemo(() => !Xe(c, De) && X, [c, De, X]), { properties: ie, required: Qt } = e.useMemo(
1141
1136
  () => ({
1142
1137
  properties: {},
1143
1138
  required: [],
1144
1139
  ...he
1145
1140
  }),
1146
1141
  [he]
1147
- ), Je = w ? localStorage.getItem(`${w}.columnNames`) : null, Ge = w ? localStorage.getItem(`${w}.columnWidths`) : null, K = e.useMemo(() => {
1142
+ ), Je = C ? localStorage.getItem(`${C}.columnNames`) : null, Ge = C ? localStorage.getItem(`${C}.columnWidths`) : null, K = e.useMemo(() => {
1148
1143
  if (Se)
1149
1144
  return Se;
1150
1145
  const t = Je ? JSON.parse(Je) : void 0;
@@ -1193,22 +1188,22 @@ const Rn = ({
1193
1188
  return l[i] = m === void 0 ? "?" : m ? "✓" : "✕", l;
1194
1189
  case "number":
1195
1190
  case "integer":
1196
- return m === void 0 ? (l[i] = "", l) : (l[i] = d.format === "currency" ? In.format(m) : Nn.format(m), l);
1191
+ return m === void 0 ? (l[i] = "", l) : (l[i] = d.format === "currency" ? Nn.format(m) : Ln.format(m), l);
1197
1192
  // @ts-expect-error investigate
1198
1193
  case "string":
1199
1194
  if (d.format === "date" && m)
1200
1195
  return l[i] = ["2999-12-31", "1970-01-01"].includes(
1201
1196
  m
1202
- ) ? "-" : ut(
1197
+ ) ? "-" : ct(
1203
1198
  new Date(m),
1204
- k?.dateFormat || $t
1199
+ k?.dateFormat || Rt
1205
1200
  ), l;
1206
1201
  if (d.format === "date-time" && m)
1207
- return l[i] = M ? Rt(
1202
+ return l[i] = M ? St(
1208
1203
  new Date(m),
1209
1204
  M,
1210
1205
  Ye
1211
- ) : ut(
1206
+ ) : ct(
1212
1207
  new Date(m),
1213
1208
  k?.dateFormat || Ye
1214
1209
  ), l;
@@ -1227,11 +1222,11 @@ const Rn = ({
1227
1222
  let t = 0, a = 0;
1228
1223
  return (K || []).forEach((l) => {
1229
1224
  if (l === ee) {
1230
- t += Mt;
1225
+ t += Tt;
1231
1226
  return;
1232
1227
  }
1233
1228
  if (l === we) {
1234
- t += At;
1229
+ t += Mt;
1235
1230
  return;
1236
1231
  }
1237
1232
  const i = f ? f[l] : void 0;
@@ -1242,17 +1237,17 @@ const Rn = ({
1242
1237
  return new Uint16Array(Re);
1243
1238
  const t = Ge ? new Uint16Array(JSON.parse(Ge)) : void 0, a = Math.max(
1244
1239
  Math.floor(
1245
- (We - st) / rt
1240
+ (Oe - st) / rt
1246
1241
  ),
1247
- Ot
1242
+ $t
1248
1243
  );
1249
- let l = (We - st) % rt;
1244
+ let l = (Oe - st) % rt;
1250
1245
  const i = new Uint16Array(
1251
1246
  K.map((d) => {
1252
1247
  if (d === ee)
1253
- return Mt;
1248
+ return Tt;
1254
1249
  if (d === we)
1255
- return At;
1250
+ return Mt;
1256
1251
  const k = f ? f[d] : void 0;
1257
1252
  return k?.width ? k?.width : l ? (l -= 1, a + 1) : a;
1258
1253
  })
@@ -1265,12 +1260,12 @@ const Rn = ({
1265
1260
  rt,
1266
1261
  st,
1267
1262
  Ge,
1268
- We
1263
+ Oe
1269
1264
  ]), Ze = e.useCallback(
1270
1265
  (t) => le ? le[t] : 1,
1271
1266
  [le]
1272
- ), Fe = e.useMemo(() => {
1273
- if (!Te || !r && !W || H)
1267
+ ), je = e.useMemo(() => {
1268
+ if (!Te || !n && !W || X)
1274
1269
  return Te;
1275
1270
  const { searchQuery: t } = c, a = t.toLowerCase() || "", l = (i) => y && q ? q(y[i._index], t) : !(K && !K.find(
1276
1271
  (d) => `${i[d]}`.toLowerCase().includes(a)
@@ -1292,8 +1287,6 @@ const Rn = ({
1292
1287
  const me = ie[k], E = y[i._index]?.[k];
1293
1288
  switch (me?.type) {
1294
1289
  case "boolean":
1295
- if (m === void 0)
1296
- return;
1297
1290
  if (Array.isArray(m) && m.length) {
1298
1291
  m.includes(
1299
1292
  E === void 0 ? null : E
@@ -1310,7 +1303,7 @@ const Rn = ({
1310
1303
  pe
1311
1304
  )) {
1312
1305
  const ge = m[z];
1313
- if (d && hn(ge))
1306
+ if (d && mn(ge))
1314
1307
  switch (z) {
1315
1308
  case pe.EQ:
1316
1309
  E !== ge && (d = !1);
@@ -1332,12 +1325,12 @@ const Rn = ({
1332
1325
  // @ts-expect-error investigate
1333
1326
  case "string":
1334
1327
  if (typeof m == "object" && !Array.isArray(m) && (me.format === "date" || me.format === "date-time")) {
1335
- const { from: z, to: ge, filterEmpty: _t } = m;
1328
+ const { from: z, to: ge, filterEmpty: pt } = m;
1336
1329
  if (!E)
1337
- d = !_t;
1330
+ d = !pt;
1338
1331
  else {
1339
1332
  const qe = E ? new Date(E) : void 0;
1340
- (_t === !1 || z && (!qe || qe < z) || ge && (!qe || qe > ge)) && (d = !1);
1333
+ (pt === !1 || z && (!qe || qe < z) || ge && (!qe || qe > ge)) && (d = !1);
1341
1334
  }
1342
1335
  return;
1343
1336
  }
@@ -1360,9 +1353,9 @@ const Rn = ({
1360
1353
  });
1361
1354
  }, [
1362
1355
  Te,
1363
- r,
1356
+ n,
1364
1357
  W,
1365
- H,
1358
+ X,
1366
1359
  c,
1367
1360
  q,
1368
1361
  K,
@@ -1371,11 +1364,11 @@ const Rn = ({
1371
1364
  ie
1372
1365
  ]), ot = e.useMemo(() => {
1373
1366
  const { sortAsc: t, sortColumn: a } = c;
1374
- if (!a || !Fe || !y || H)
1375
- return Fe;
1367
+ if (!a || !je || !y || X)
1368
+ return je;
1376
1369
  const l = ie[a], i = f ? f[a] : void 0, d = i?.sort;
1377
1370
  if (d)
1378
- return Fe.sort((V, me) => {
1371
+ return je.sort((V, me) => {
1379
1372
  const E = y[V._index], z = y[me._index];
1380
1373
  return E ? z ? d(
1381
1374
  E,
@@ -1383,25 +1376,25 @@ const Rn = ({
1383
1376
  t === void 0 ? N : t
1384
1377
  ) : -1 : 1;
1385
1378
  });
1386
- const k = l && l.format?.startsWith("date"), m = Sn(l, i);
1387
- return Fe.sort((V, me) => {
1379
+ const k = l && l.format?.startsWith("date"), m = In(l, i);
1380
+ return je.sort((V, me) => {
1388
1381
  let E = m && y[V._index] ? y[V._index][a] : `${V[a]}`.toLowerCase(), z = m && y[me._index] ? y[me._index][a] : `${me[a]}`.toLowerCase();
1389
- return m && k && (E = new Date(E), isNaN(E.getTime()) && (E = St), z = new Date(z), isNaN(z.getTime()) && (z = St)), E === z ? 0 : E == null ? t ? -1 : 1 : z == null ? t ? 1 : -1 : (E < z ? 1 : -1) * (t ? -1 : 1);
1382
+ return m && k && (E = new Date(E), isNaN(E.getTime()) && (E = It), z = new Date(z), isNaN(z.getTime()) && (z = It)), E === z ? 0 : E == null ? t ? -1 : 1 : z == null ? t ? 1 : -1 : (E < z ? 1 : -1) * (t ? -1 : 1);
1390
1383
  });
1391
1384
  }, [
1392
1385
  f,
1393
1386
  N,
1394
- Fe,
1395
- H,
1387
+ je,
1388
+ X,
1396
1389
  ie,
1397
1390
  y,
1398
1391
  c
1399
- ]), F = e.useMemo(() => !_e?.length || !Te || c.sortColumn ? ot : _e.map((t) => Te[t]), [_e, Te, ot, c.sortColumn]), Ut = e.useCallback(
1392
+ ]), F = e.useMemo(() => !_e?.length || !Te || c.sortColumn ? ot : _e.map((t) => Te[t]), [_e, Te, ot, c.sortColumn]), zt = e.useCallback(
1400
1393
  (t, a) => {
1401
1394
  if (!F || !y || t === a)
1402
1395
  return;
1403
1396
  const l = F.map((k) => k._index), [i] = l.splice(t, 1), d = t < a ? a - 1 : a;
1404
- l.splice(d, 0, i), Oe(l), xe((k) => ({
1397
+ l.splice(d, 0, i), ze(l), xe((k) => ({
1405
1398
  ...k,
1406
1399
  sortColumn: void 0,
1407
1400
  sortAsc: void 0
@@ -1420,12 +1413,12 @@ const Rn = ({
1420
1413
  }),
1421
1414
  [F, Ue]
1422
1415
  );
1423
- const gt = e.useRef(void 0);
1416
+ const ft = e.useRef(void 0);
1424
1417
  e.useEffect(() => {
1425
- const t = F?.map((l) => l._index), a = gt.current;
1426
- a && a.sourceData === y && Xe(a.indices, t) || (gt.current = { sourceData: y, indices: t }, ue?.(F));
1418
+ const t = F?.map((l) => l._index), a = ft.current;
1419
+ a && a.sourceData === y && Xe(a.indices, t) || (ft.current = { sourceData: y, indices: t }, ue?.(F));
1427
1420
  }, [F, ue, y]);
1428
- const bt = e.useCallback(
1421
+ const gt = e.useCallback(
1429
1422
  (t) => {
1430
1423
  const a = { ...c.columnFilterMap };
1431
1424
  delete a[t], xe({
@@ -1436,7 +1429,7 @@ const Rn = ({
1436
1429
  [c]
1437
1430
  ), at = e.useCallback(
1438
1431
  (t, a) => {
1439
- if (x) {
1432
+ if (ze(void 0), x) {
1440
1433
  window.location.hash = He({
1441
1434
  ...P,
1442
1435
  sortColumn: t,
@@ -1447,7 +1440,7 @@ const Rn = ({
1447
1440
  xe({ ...c, sortColumn: t, sortAsc: a });
1448
1441
  },
1449
1442
  [c, P, x]
1450
- ), Pt = e.useCallback(
1443
+ ), Ut = e.useCallback(
1451
1444
  (t) => {
1452
1445
  xe({
1453
1446
  ...c,
@@ -1482,59 +1475,59 @@ const Rn = ({
1482
1475
  Le,
1483
1476
  x
1484
1477
  ]);
1485
- const pt = e.useCallback(
1478
+ const bt = e.useCallback(
1486
1479
  (t) => {
1487
- t.key === "Enter" && (et(void 0), je && !x && Le(), ae && t.currentTarget.className === "mig-schema-table__search" && ae(c.searchQuery || ""));
1480
+ t.key === "Enter" && (et(void 0), We && !x && Le(), ae && t.currentTarget.className === "mig-schema-table__search" && ae(c.searchQuery || ""));
1488
1481
  },
1489
1482
  [
1490
- je,
1483
+ We,
1491
1484
  c.searchQuery,
1492
1485
  ae,
1493
1486
  Le,
1494
1487
  x
1495
1488
  ]
1496
- ), it = e.useCallback(() => j, [j]), de = e.useMemo(() => fn(le), [le]), Be = e.useMemo(
1489
+ ), it = e.useCallback(() => j, [j]), de = e.useMemo(() => hn(le), [le]), Fe = e.useMemo(
1497
1490
  () => F ? F.length : 0,
1498
1491
  [F]
1499
1492
  ), Ce = e.useMemo(() => {
1500
- const t = j * Be;
1493
+ const t = j * Fe;
1501
1494
  let a;
1502
1495
  if (J && (a = J === "100%" ? Pe.height : J, !a))
1503
1496
  return 0;
1504
- const l = a ? a - ft.height - Et : 0;
1497
+ const l = a ? a - ht.height - At : 0;
1505
1498
  return l && l < t ? l : t;
1506
1499
  }, [
1507
1500
  j,
1508
- Be,
1501
+ Fe,
1509
1502
  J,
1510
- ft,
1503
+ ht,
1511
1504
  Pe.height
1512
- ]), Jt = e.useCallback(
1505
+ ]), Pt = e.useCallback(
1513
1506
  (t) => {
1514
1507
  et(void 0), t.preventDefault(), t.stopPropagation();
1515
1508
  },
1516
1509
  []
1517
- ), Gt = e.useCallback(
1510
+ ), Jt = e.useCallback(
1518
1511
  (t, a) => {
1519
- if (!X)
1512
+ if (!H)
1520
1513
  return;
1521
1514
  if (x && a !== !1) {
1522
1515
  window.location.hash = He({
1523
1516
  ...P,
1524
1517
  columnFilterMap: {
1525
1518
  ...c.columnFilterMap,
1526
- [X.propName]: t
1519
+ [H.propName]: t
1527
1520
  }
1528
1521
  });
1529
1522
  return;
1530
1523
  }
1531
1524
  if (t === void 0) {
1532
- bt(X.propName);
1525
+ gt(H.propName);
1533
1526
  return;
1534
1527
  }
1535
1528
  const l = {
1536
1529
  ...c.columnFilterMap,
1537
- [X.propName]: t
1530
+ [H.propName]: t
1538
1531
  };
1539
1532
  xe({
1540
1533
  ...c,
@@ -1542,13 +1535,13 @@ const Rn = ({
1542
1535
  });
1543
1536
  },
1544
1537
  [
1545
- bt,
1538
+ gt,
1546
1539
  c,
1547
1540
  P,
1548
- X,
1541
+ H,
1549
1542
  x
1550
1543
  ]
1551
- ), Zt = e.useCallback(() => {
1544
+ ), Gt = e.useCallback(() => {
1552
1545
  const t = {
1553
1546
  searchQuery: "",
1554
1547
  columnFilterMap: {},
@@ -1557,21 +1550,21 @@ const Rn = ({
1557
1550
  sortAsc: N
1558
1551
  };
1559
1552
  x && (window.location.hash = He(t)), nt(t), xe(t);
1560
- }, [x, N, I]), qt = e.useCallback(() => {
1553
+ }, [x, N, I]), Zt = e.useCallback(() => {
1561
1554
  const t = P?.searchQuery || "";
1562
1555
  x && // prevent hash change for undefined vs empty string compare
1563
1556
  (c.searchQuery || t) && c.searchQuery !== t && (window.location.hash = He({
1564
1557
  ...P,
1565
1558
  searchQuery: c.searchQuery
1566
1559
  }));
1567
- }, [P, c.searchQuery, x]), Ht = e.useCallback(
1560
+ }, [P, c.searchQuery, x]), qt = e.useCallback(
1568
1561
  async (t) => {
1569
- t.preventDefault(), t.stopPropagation(), F && await Ln(F);
1562
+ t.preventDefault(), t.stopPropagation(), F && await En(F);
1570
1563
  },
1571
1564
  [F]
1572
- ), Xt = e.useCallback(() => {
1573
- w && (localStorage.removeItem(`${w}.columnNames`), localStorage.removeItem(`${w}.columnWidths`), ze(void 0), Ae(void 0));
1574
- }, [w]), lt = e.useCallback(
1565
+ ), Ht = e.useCallback(() => {
1566
+ C && (localStorage.removeItem(`${C}.columnNames`), localStorage.removeItem(`${C}.columnWidths`), Qe(void 0), Ae(void 0));
1567
+ }, [C]), lt = e.useCallback(
1575
1568
  (t) => {
1576
1569
  if (!F || !y || !v || !G)
1577
1570
  return !0;
@@ -1579,7 +1572,7 @@ const Rn = ({
1579
1572
  return a && y[a._index] !== void 0;
1580
1573
  },
1581
1574
  [G, v, F, y]
1582
- ), Vt = e.useMemo(() => Ce ? !(y && !je) && !v ? /* @__PURE__ */ s(
1575
+ ), Xt = e.useMemo(() => Ce ? !(y && !We) && !v ? /* @__PURE__ */ r(
1583
1576
  "div",
1584
1577
  {
1585
1578
  style: {
@@ -1592,17 +1585,17 @@ const Rn = ({
1592
1585
  alignItems: "center",
1593
1586
  justifyContent: "center"
1594
1587
  },
1595
- children: je ? /* @__PURE__ */ s("button", { onClick: Le, className: "btn border", children: "Refresh data" }) : /* @__PURE__ */ s("div", { children: "⌛ Loading..." })
1588
+ children: We ? /* @__PURE__ */ r("button", { onClick: Le, className: "btn border", children: "Refresh data" }) : /* @__PURE__ */ r("div", { children: "⌛ Loading..." })
1596
1589
  }
1597
- ) : v && G ? /* @__PURE__ */ s(
1598
- gn,
1590
+ ) : v && G ? /* @__PURE__ */ r(
1591
+ fn,
1599
1592
  {
1600
1593
  ref: b,
1601
1594
  isItemLoaded: lt,
1602
1595
  itemCount: G,
1603
1596
  loadMoreItems: v,
1604
- children: ({ onItemsRendered: a, ref: l }) => /* @__PURE__ */ s(
1605
- Ct,
1597
+ children: ({ onItemsRendered: a, ref: l }) => /* @__PURE__ */ r(
1598
+ _t,
1606
1599
  {
1607
1600
  className: "mig-schema-table__tbody",
1608
1601
  estimatedRowHeight: j,
@@ -1611,7 +1604,7 @@ const Rn = ({
1611
1604
  columnWidth: Ze,
1612
1605
  rowHeight: it,
1613
1606
  columnCount: Ee,
1614
- rowCount: Be,
1607
+ rowCount: Fe,
1615
1608
  ref: l,
1616
1609
  onItemsRendered: ({
1617
1610
  overscanRowStartIndex: i,
@@ -1624,15 +1617,15 @@ const Rn = ({
1624
1617
  visibleStartIndex: k,
1625
1618
  visibleStopIndex: m
1626
1619
  }),
1627
- children: Nt
1620
+ children: Lt
1628
1621
  },
1629
1622
  `tbody_${Ce}_${de}_${c.sortColumn}_${c.sortAsc}_${c.searchQuery}_${Ee}_${le.join(
1630
1623
  " "
1631
1624
  )}`
1632
1625
  )
1633
1626
  }
1634
- ) : /* @__PURE__ */ s(
1635
- Ct,
1627
+ ) : /* @__PURE__ */ r(
1628
+ _t,
1636
1629
  {
1637
1630
  className: "mig-schema-table__tbody",
1638
1631
  estimatedRowHeight: j,
@@ -1641,9 +1634,9 @@ const Rn = ({
1641
1634
  columnWidth: Ze,
1642
1635
  rowHeight: it,
1643
1636
  columnCount: Ee,
1644
- rowCount: Be,
1637
+ rowCount: Fe,
1645
1638
  ref: Ue,
1646
- children: Nt
1639
+ children: Lt
1647
1640
  },
1648
1641
  `tbody_${Ce}_${de}_${c.sortColumn}_${c.sortAsc}_${c.searchQuery}_${Ee}_${le.join(
1649
1642
  " "
@@ -1654,12 +1647,12 @@ const Rn = ({
1654
1647
  Ze,
1655
1648
  it,
1656
1649
  b,
1657
- je,
1650
+ We,
1658
1651
  lt,
1659
1652
  G,
1660
1653
  v,
1661
1654
  Le,
1662
- Be,
1655
+ Fe,
1663
1656
  j,
1664
1657
  de,
1665
1658
  c.searchQuery,
@@ -1668,16 +1661,16 @@ const Rn = ({
1668
1661
  y,
1669
1662
  Ce,
1670
1663
  Ue
1671
- ]), Yt = e.useMemo(
1664
+ ]), Vt = e.useMemo(
1672
1665
  () => ({
1673
1666
  ...T,
1674
- width: Q ? Math.min(de, We) : void 0,
1667
+ width: Q ? Math.min(de, Oe) : void 0,
1675
1668
  height: J === "100%" ? "100%" : void 0,
1676
1669
  maxHeight: J === "100%" ? "100%" : void 0
1677
1670
  }),
1678
- [J, de, T, We, Q]
1679
- ), Kt = o || "input";
1680
- return /* @__PURE__ */ s(
1671
+ [J, de, T, Oe, Q]
1672
+ ), Yt = o || "input";
1673
+ return /* @__PURE__ */ r(
1681
1674
  Ie.Provider,
1682
1675
  {
1683
1676
  value: {
@@ -1691,46 +1684,46 @@ const Rn = ({
1691
1684
  getRowClassName: Y,
1692
1685
  getRowSelected: te,
1693
1686
  isDraggable: u,
1694
- isColumnFilterable: r,
1687
+ isColumnFilterable: n,
1695
1688
  isItemLoaded: lt,
1696
1689
  isSortable: ce,
1697
- lastCheckChangedRowIndex: Ft,
1690
+ lastCheckChangedRowIndex: jt,
1698
1691
  onRowClick: ne,
1699
1692
  onRowDoubleClick: re,
1700
- onRowDrop: Ut,
1693
+ onRowDrop: zt,
1701
1694
  properties: ie,
1702
- required: zt,
1695
+ required: Qt,
1703
1696
  rowDropTargetRowIndex: ye,
1704
1697
  setCheckedIndexes: se,
1705
- setCustomColumnNames: ze,
1698
+ setCustomColumnNames: Qe,
1706
1699
  setCustomColumnWidths: Ae,
1707
1700
  setDropTargetIndex: fe,
1708
1701
  setFilterSortColumn: at,
1709
- setLastCheckChangedRowIndex: Bt,
1702
+ setLastCheckChangedRowIndex: Ft,
1710
1703
  setMenuConfig: et,
1711
1704
  setRowDropTargetRowIndex: ke,
1712
- settingsStorageKey: w,
1705
+ settingsStorageKey: C,
1713
1706
  sortedRenderData: F,
1714
1707
  sourceData: y,
1715
1708
  tableDataState: c,
1716
- translate: A || Tt
1709
+ translate: A || xt
1717
1710
  },
1718
1711
  children: /* @__PURE__ */ B(
1719
1712
  "div",
1720
1713
  {
1721
1714
  className: `mig-schema-table${ne ? " mig-schema-table--clickable-rows" : ""}`,
1722
- ref: mt,
1723
- style: Yt,
1715
+ ref: dt,
1716
+ style: Vt,
1724
1717
  role: "table",
1725
1718
  children: [
1726
1719
  /* @__PURE__ */ B(
1727
1720
  "div",
1728
1721
  {
1729
1722
  className: "mig-schema-table__action-container",
1730
- ref: ht,
1723
+ ref: mt,
1731
1724
  children: [
1732
- /* @__PURE__ */ s("div", { children: W ? /* @__PURE__ */ s(
1733
- Kt,
1725
+ /* @__PURE__ */ r("div", { children: W ? /* @__PURE__ */ r(
1726
+ Yt,
1734
1727
  {
1735
1728
  className: "mig-schema-table__search",
1736
1729
  type: "search",
@@ -1738,46 +1731,46 @@ const Rn = ({
1738
1731
  autoComplete: "off",
1739
1732
  placeholder: ve || A("search..."),
1740
1733
  value: c.searchQuery,
1741
- onChange: Pt,
1742
- onKeyDown: pt,
1734
+ onChange: Ut,
1735
+ onKeyDown: bt,
1743
1736
  autoFocus: D,
1744
- onBlur: qt
1737
+ onBlur: Zt
1745
1738
  }
1746
1739
  ) : null }),
1747
- n ? /* @__PURE__ */ s(
1748
- n,
1740
+ s ? /* @__PURE__ */ r(
1741
+ s,
1749
1742
  {
1750
1743
  ...L,
1751
1744
  renderData: ot
1752
1745
  }
1753
- ) : /* @__PURE__ */ s("div", { className: "mig-schema-table__custom_element_placeholder" }),
1754
- S && Array.isArray(C) ? /* @__PURE__ */ s("span", { className: "mig-schema-table__row_counter", children: A(
1746
+ ) : /* @__PURE__ */ r("div", { className: "mig-schema-table__custom_element_placeholder" }),
1747
+ S && Array.isArray(w) ? /* @__PURE__ */ r("span", { className: "mig-schema-table__row_counter", children: A(
1755
1748
  "showingFilteredCountOfTotalCount",
1756
1749
  F?.length || 0,
1757
- C.length
1750
+ w.length
1758
1751
  ) }) : null,
1759
- g ? /* @__PURE__ */ s(
1752
+ g ? /* @__PURE__ */ r(
1760
1753
  "button",
1761
1754
  {
1762
- onClick: Ht,
1755
+ onClick: qt,
1763
1756
  style: { marginLeft: 8 },
1764
1757
  disabled: !F?.length,
1765
1758
  children: A("exportData")
1766
1759
  }
1767
1760
  ) : null,
1768
- W || r ? /* @__PURE__ */ s(
1761
+ W || n ? /* @__PURE__ */ r(
1769
1762
  "button",
1770
1763
  {
1771
- onClick: Zt,
1764
+ onClick: Gt,
1772
1765
  style: { marginLeft: 8 },
1773
1766
  disabled: c.columnFilterMap && c.searchQuery ? Object.keys(c.columnFilterMap).length + c.searchQuery.length === 0 : !1,
1774
1767
  children: A("clearFilters")
1775
1768
  }
1776
1769
  ) : null,
1777
- w ? /* @__PURE__ */ s(
1770
+ C ? /* @__PURE__ */ r(
1778
1771
  "button",
1779
1772
  {
1780
- onClick: Xt,
1773
+ onClick: Ht,
1781
1774
  style: { marginLeft: 8 },
1782
1775
  disabled: !Je && !Ge,
1783
1776
  children: A("clearSettings")
@@ -1787,10 +1780,10 @@ const Rn = ({
1787
1780
  }
1788
1781
  ),
1789
1782
  /* @__PURE__ */ B("div", { className: "mig-schema-table__column_resize_container", children: [
1790
- /* @__PURE__ */ s(
1783
+ /* @__PURE__ */ r(
1791
1784
  h,
1792
1785
  {
1793
- height: Et,
1786
+ height: At,
1794
1787
  itemCount: Ee,
1795
1788
  itemSize: Ze,
1796
1789
  layout: "horizontal",
@@ -1800,15 +1793,15 @@ const Rn = ({
1800
1793
  sortColumn: c.sortColumn,
1801
1794
  sortedRenderData: F,
1802
1795
  className: "mig-schema-table__th-row",
1803
- children: kn
1796
+ children: yn
1804
1797
  },
1805
1798
  `thead_${de}_${c.sortColumn}_${c.sortAsc}_${c.searchQuery}_${le.join(
1806
1799
  " "
1807
1800
  )}`
1808
1801
  ),
1809
- Vt,
1810
- oe ? /* @__PURE__ */ s(
1811
- An,
1802
+ Xt,
1803
+ oe ? /* @__PURE__ */ r(
1804
+ Mn,
1812
1805
  {
1813
1806
  columnWidths: le,
1814
1807
  resizeColumnIndex: Ke,
@@ -1817,28 +1810,28 @@ const Rn = ({
1817
1810
  }
1818
1811
  ) : null
1819
1812
  ] }),
1820
- y && y.length === 0 ? /* @__PURE__ */ s("div", { className: "mig-schema-table__no_data", children: "No data found" }) : null,
1821
- X ? nn(
1822
- /* @__PURE__ */ s(
1823
- Mn,
1813
+ y && y.length === 0 ? /* @__PURE__ */ r("div", { className: "mig-schema-table__no_data", children: "No data found" }) : null,
1814
+ H ? tn(
1815
+ /* @__PURE__ */ r(
1816
+ Tn,
1824
1817
  {
1825
- isFilterable: r && X.propConfig?.isFilterable !== !1,
1826
- isSortable: Wt(
1818
+ isFilterable: n && H.propConfig?.isFilterable !== !1,
1819
+ isSortable: Ot(
1827
1820
  ce,
1828
- he.properties[X.propName],
1829
- X.propConfig
1821
+ he.properties[H.propName],
1822
+ H.propConfig
1830
1823
  ),
1831
- onChange: Gt,
1832
- onClose: Jt,
1833
- onInputKeyDown: pt,
1834
- propConfig: X.propConfig,
1835
- propIsRequired: X.propIsRequired,
1836
- propName: X.propName,
1837
- propSchema: he.properties[X.propName],
1838
- referenceElement: X.referenceElement,
1824
+ onChange: Jt,
1825
+ onClose: Pt,
1826
+ onInputKeyDown: bt,
1827
+ propConfig: H.propConfig,
1828
+ propIsRequired: H.propIsRequired,
1829
+ propName: H.propName,
1830
+ propSchema: he.properties[H.propName],
1831
+ referenceElement: H.referenceElement,
1839
1832
  setFilterSortColumn: at,
1840
1833
  translate: A,
1841
- value: c.columnFilterMap ? c.columnFilterMap[X.propName] : null
1834
+ value: c.columnFilterMap ? c.columnFilterMap[H.propName] : null
1842
1835
  }
1843
1836
  ),
1844
1837
  document.body
@@ -1848,16 +1841,16 @@ const Rn = ({
1848
1841
  )
1849
1842
  }
1850
1843
  );
1851
- }, $n = e.forwardRef(Rn), Vn = e.memo($n), Yn = e.memo(({ refresh: n, period: o = 60 }) => {
1844
+ }, Rn = e.forwardRef(Sn), Xn = e.memo(Rn), Vn = e.memo(({ refresh: s, period: o = 60 }) => {
1852
1845
  const [h, p] = e.useState(/* @__PURE__ */ new Date()), [_, f] = e.useState(/* @__PURE__ */ new Date()), L = e.useCallback(() => {
1853
- f(/* @__PURE__ */ new Date()), n();
1854
- }, [n]), C = e.useMemo(
1855
- () => an(h, _),
1846
+ f(/* @__PURE__ */ new Date()), s();
1847
+ }, [s]), w = e.useMemo(
1848
+ () => on(h, _),
1856
1849
  [h, _]
1857
1850
  );
1858
1851
  e.useEffect(() => {
1859
- C > o && L();
1860
- }, [C, h, _, o, L]), e.useEffect(() => {
1852
+ w > o && L();
1853
+ }, [w, h, _, o, L]), e.useEffect(() => {
1861
1854
  const I = setInterval(() => {
1862
1855
  p(/* @__PURE__ */ new Date());
1863
1856
  }, 1e3);
@@ -1865,7 +1858,7 @@ const Rn = ({
1865
1858
  clearInterval(I);
1866
1859
  };
1867
1860
  }, []);
1868
- const O = o - C;
1861
+ const O = o - w;
1869
1862
  return /* @__PURE__ */ B(
1870
1863
  "div",
1871
1864
  {
@@ -1873,18 +1866,18 @@ const Rn = ({
1873
1866
  title: `Refresh ${O > 0 ? `in ${O} seconds` : "NOW"}`,
1874
1867
  children: [
1875
1868
  "Last update ",
1876
- ut(_, "HH:mm")
1869
+ ct(_, "HH:mm")
1877
1870
  ]
1878
1871
  }
1879
1872
  );
1880
1873
  });
1881
1874
  export {
1882
- $t as DEFAULT_DATE_FORMAT,
1875
+ Rt as DEFAULT_DATE_FORMAT,
1883
1876
  Ye as DEFAULT_DATE_TIME_FORMAT,
1884
- Qe as EColumnFilterStatus,
1885
- Ot as MINIMUM_COLUMN_WIDTH,
1886
- _n as RESIZER_WIDTH,
1887
- Yn as Refresher,
1888
- Vn as SchemaTable,
1889
- kn as Th
1877
+ Be as EColumnFilterStatus,
1878
+ $t as MINIMUM_COLUMN_WIDTH,
1879
+ pn as RESIZER_WIDTH,
1880
+ Vn as Refresher,
1881
+ Xn as SchemaTable,
1882
+ yn as Th
1890
1883
  };