dgz-ui-shared 1.2.29 → 1.2.30

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,146 +1,146 @@
1
1
  import { jsx as e, jsxs as N, Fragment as O } from "react/jsx-runtime";
2
2
  import { y as ee, f as te } from "../../chunks/index-E1NtSoNr.es.js";
3
- import { Button as q } from "dgz-ui/button";
4
- import { DropdownMenu as le, DropdownMenuTrigger as de, DropdownMenuContent as se, DropdownMenuItem as ie, DropdownMenuSeparator as fe, DropdownMenuCheckboxItem as re } from "dgz-ui/dropdown";
3
+ import { Button as Q } from "dgz-ui/button";
4
+ import { DropdownMenu as le, DropdownMenuTrigger as de, DropdownMenuContent as se, DropdownMenuItem as fe, DropdownMenuSeparator as ie, DropdownMenuCheckboxItem as re } from "dgz-ui/dropdown";
5
5
  import { cn as o } from "dgz-ui/utils";
6
- import { l as M } from "../../chunks/lodash-CRDOWzbs.es.js";
7
- import { XIcon as Z, ArrowDownWideNarrow as pe, ArrowUpWideNarrow as Ne, ArrowUpDown as ce, RefreshCw as xe } from "lucide-react";
8
- import { memo as we, useMemo as me, useEffect as Q, useState as ge } from "react";
6
+ import { l as z } from "../../chunks/lodash-CRDOWzbs.es.js";
7
+ import { XIcon as h, ArrowDownWideNarrow as pe, ArrowUpWideNarrow as Ne, ArrowUpDown as xe, RefreshCw as ce } from "lucide-react";
8
+ import { memo as me, useMemo as we, useEffect as Y, useState as ge } from "react";
9
9
  import { useTranslation as b } from "react-i18next";
10
10
  import { u as ne, a as Ee, b as Te } from "../../chunks/useSortable-BXNk8Wth.es.js";
11
11
  import { A as De } from "../../chunks/Actions-Du8iQ3WR.es.js";
12
- import { E as ke } from "../../chunks/ExportData-DQzwB_yW.es.js";
13
- import { S as ve, F as Ae } from "../../chunks/Search-CR54BX3a.es.js";
14
- import { ButtonGroup as Me } from "dgz-ui";
15
- import { L as ze } from "../../chunks/Loader-zvzAi0F6.es.js";
12
+ import { E as ve } from "../../chunks/ExportData-CwotVgye.es.js";
13
+ import { S as Ae, F as Me } from "../../chunks/Search-BtiKC-dt.es.js";
14
+ import { ButtonGroup as ze } from "dgz-ui";
15
+ import { L as ke } from "../../chunks/Loader-zvzAi0F6.es.js";
16
16
  import { D as I, M as Le, a as Re } from "../../chunks/MyPagination-B0czoGZK.es.js";
17
17
  import { Checkbox as U } from "dgz-ui/form";
18
- import { Table as oe, TableHeader as We, TableRow as G, TableHead as X, TableBody as Be, TableCell as H } from "dgz-ui/table";
18
+ import { Table as oe, TableHeader as We, TableRow as X, TableHead as q, TableBody as Be, TableCell as J } from "dgz-ui/table";
19
19
  import { S as j } from "../../chunks/SortOrder-CwuehjY1.es.js";
20
20
  import { E as $e } from "../../chunks/Empty-BReVQKje.es.js";
21
- const ye = we(function({
22
- filters: w,
21
+ const He = me(function({
22
+ filters: m,
23
23
  params: E,
24
- onFilter: c,
25
- className: m,
26
- ...z
24
+ onFilter: x,
25
+ className: w,
26
+ ...k
27
27
  }) {
28
- const { t: T } = b(), s = me(
28
+ const { t: T } = b(), s = we(
29
29
  () => Object.fromEntries(
30
- (w == null ? void 0 : w.map((i) => {
31
- var x;
30
+ (m == null ? void 0 : m.map((f) => {
31
+ var c;
32
32
  return [
33
- i.name,
33
+ f.name,
34
34
  Object.fromEntries(
35
- ((x = i.options) == null ? void 0 : x.map(({ label: t, value: n }) => [n, t])) || []
35
+ ((c = f.options) == null ? void 0 : c.map(({ label: t, value: n }) => [n, t])) || []
36
36
  )
37
37
  ];
38
38
  })) || []
39
39
  ),
40
- [w]
40
+ [m]
41
41
  );
42
- return /* @__PURE__ */ e("div", { ...z, className: o("flex flex-wrap gap-2", m), children: Object.entries(E || {}).filter(([i, x]) => !!(s != null && s[i]) && !M.isEmpty(x)).map(
43
- ([i, x]) => {
42
+ return /* @__PURE__ */ e("div", { ...k, className: o("flex flex-wrap gap-2", w), children: Object.entries(E || {}).filter(([f, c]) => !!(s != null && s[f]) && !z.isEmpty(c)).map(
43
+ ([f, c]) => {
44
44
  var t;
45
- return Array.isArray(x) ? /* @__PURE__ */ e(Me, { children: x.filter((n) => {
45
+ return Array.isArray(c) ? /* @__PURE__ */ e(ze, { children: c.filter((n) => {
46
46
  var L;
47
- return ((L = s == null ? void 0 : s[i]) == null ? void 0 : L[n]) && n;
47
+ return ((L = s == null ? void 0 : s[f]) == null ? void 0 : L[n]) && n;
48
48
  }).map((n, L) => {
49
49
  var p;
50
50
  return /* @__PURE__ */ N(
51
- q,
51
+ Q,
52
52
  {
53
53
  size: "sm",
54
54
  onClick: () => {
55
- c == null || c({
55
+ x == null || x({
56
56
  ...E,
57
- [i]: x.filter((A) => A !== n)
57
+ [f]: c.filter((M) => M !== n)
58
58
  });
59
59
  },
60
60
  children: [
61
- T(String(((p = s == null ? void 0 : s[i]) == null ? void 0 : p[n]) || "")),
61
+ T(String(((p = s == null ? void 0 : s[f]) == null ? void 0 : p[n]) || "")),
62
62
  " ",
63
- /* @__PURE__ */ e(Z, {})
63
+ /* @__PURE__ */ e(h, {})
64
64
  ]
65
65
  },
66
66
  L
67
67
  );
68
- }) }, i) : /* @__PURE__ */ N(
69
- q,
68
+ }) }, f) : /* @__PURE__ */ N(
69
+ Q,
70
70
  {
71
71
  size: "sm",
72
72
  onClick: () => {
73
- c == null || c(M.omit(E, i));
73
+ x == null || x(z.omit(E, f));
74
74
  },
75
75
  children: [
76
- T(String(((t = s == null ? void 0 : s[i]) == null ? void 0 : t[x]) || "")),
76
+ T(String(((t = s == null ? void 0 : s[f]) == null ? void 0 : t[c]) || "")),
77
77
  " ",
78
- /* @__PURE__ */ e(Z, {})
78
+ /* @__PURE__ */ e(h, {})
79
79
  ]
80
80
  }
81
81
  );
82
82
  }
83
83
  ) });
84
- }), He = ({
84
+ }), Je = ({
85
85
  rows: l = [],
86
- columns: w,
86
+ columns: m,
87
87
  onRowClick: E,
88
- rowKey: c,
89
- params: m = {
88
+ rowKey: x,
89
+ params: w = {
90
90
  page: 1,
91
91
  limit: I
92
92
  },
93
- hasNumbers: z = !1,
93
+ hasNumbers: k = !1,
94
94
  hasCheckbox: T = !1,
95
95
  selectedItems: s,
96
- onSelectedItemsChange: i,
97
- onSortOrderChange: x,
96
+ onSelectedItemsChange: f,
97
+ onSortOrderChange: c,
98
98
  isStickyHeader: t,
99
99
  className: n,
100
100
  ...L
101
101
  }) => {
102
- const { sortObject: p, handleSort: A } = ne({
103
- sortField: m == null ? void 0 : m.sortField,
104
- sortOrder: m == null ? void 0 : m.sortOrder,
105
- onSortOrderChange: x
102
+ const { sortObject: p, handleSort: M } = ne({
103
+ sortField: w == null ? void 0 : w.sortField,
104
+ sortOrder: w == null ? void 0 : w.sortOrder,
105
+ onSortOrderChange: c
106
106
  }), {
107
107
  selectedRows: R,
108
108
  isRowSelected: D,
109
- isAllRowsSelected: k,
110
- handleSelectAllRows: J,
109
+ isAllRowsSelected: v,
110
+ handleSelectAllRows: _,
111
111
  handleSelectRow: W
112
112
  } = Ee({ rows: l, defaultSelectedRows: s });
113
- return Q(() => {
114
- JSON.stringify(s) !== JSON.stringify(R) && R && (i == null || i(R));
115
- }, [R, s, i]), /* @__PURE__ */ N(oe, { ...L, className: o("relative", n), children: [
113
+ return Y(() => {
114
+ JSON.stringify(s) !== JSON.stringify(R) && R && (f == null || f(R));
115
+ }, [R, s, f]), /* @__PURE__ */ N(oe, { ...L, className: o("relative", n), children: [
116
116
  /* @__PURE__ */ e(
117
117
  We,
118
118
  {
119
119
  className: o("bg-bg", t && "sticky top-0 z-1"),
120
- children: /* @__PURE__ */ N(G, { children: [
121
- T && /* @__PURE__ */ e(X, { className: "w-12 p-3", children: /* @__PURE__ */ e(
120
+ children: /* @__PURE__ */ N(X, { children: [
121
+ T && /* @__PURE__ */ e(q, { className: "w-12 p-3", children: /* @__PURE__ */ e(
122
122
  U,
123
123
  {
124
124
  className: "mt-1",
125
- checked: k(c),
126
- onCheckedChange: (d) => J(c, !!d),
125
+ checked: v(x),
126
+ onCheckedChange: (d) => _(x, !!d),
127
127
  "aria-label": "Select all"
128
128
  }
129
129
  ) }),
130
- z && /* @__PURE__ */ e(X, { className: "w-12 p-2", children: "#" }),
131
- w.filter((d) => !d.hidden).map((d) => /* @__PURE__ */ e(
132
- X,
130
+ k && /* @__PURE__ */ e(q, { className: "w-12 p-2", children: "#" }),
131
+ m.filter((d) => !d.hidden).map((d) => /* @__PURE__ */ e(
132
+ q,
133
133
  {
134
134
  style: d.styles,
135
135
  className: o("p-2", d.sortable && "cursor-pointer"),
136
- onClick: () => d.sortable && A(d.dataIndex),
136
+ onClick: () => d.sortable && M(d.dataIndex),
137
137
  children: /* @__PURE__ */ N("div", { className: "flex items-center gap-2", children: [
138
138
  d.name,
139
139
  " ",
140
140
  d.sortable && ((p == null ? void 0 : p.sortField) === d.key ? /* @__PURE__ */ N(O, { children: [
141
141
  (p == null ? void 0 : p.sortOrder) === j.DESC && /* @__PURE__ */ e(pe, { size: 15 }),
142
142
  (p == null ? void 0 : p.sortOrder) === j.ASC && /* @__PURE__ */ e(Ne, { size: 15 })
143
- ] }) : /* @__PURE__ */ e(ce, { size: 15 }))
143
+ ] }) : /* @__PURE__ */ e(xe, { size: 15 }))
144
144
  ] })
145
145
  },
146
146
  d.key
@@ -149,14 +149,14 @@ const ye = we(function({
149
149
  }
150
150
  ),
151
151
  /* @__PURE__ */ e(Be, { className: "[&>tr:nth-child(even)]:bg-bg-secondary", children: l.length ? l.map((d, B) => /* @__PURE__ */ N(
152
- G,
152
+ X,
153
153
  {
154
154
  onClick: () => E == null ? void 0 : E(d),
155
155
  className: o(E && "cursor-pointer"),
156
- "data-state": D(d[c]) && "selected",
156
+ "data-state": D(d[x]) && "selected",
157
157
  children: [
158
158
  T && /* @__PURE__ */ e(
159
- H,
159
+ J,
160
160
  {
161
161
  className: "w-12 p-3",
162
162
  onClick: (r) => r.stopPropagation(),
@@ -164,54 +164,54 @@ const ye = we(function({
164
164
  U,
165
165
  {
166
166
  className: "mt-1",
167
- checked: D(d[c]),
168
- onCheckedChange: (r) => W(d[c], !!r),
167
+ checked: D(d[x]),
168
+ onCheckedChange: (r) => W(d[x], !!r),
169
169
  "aria-label": "Select row"
170
170
  }
171
171
  )
172
172
  }
173
173
  ),
174
- z && /* @__PURE__ */ e(H, { className: "w-12 p-2", children: (m.page - 1) * (m.limit || I) + B + 1 }),
175
- w.filter((r) => !r.hidden).map((r) => /* @__PURE__ */ e(
176
- H,
174
+ k && /* @__PURE__ */ e(J, { className: "w-12 p-2", children: (w.page - 1) * (w.limit || I) + B + 1 }),
175
+ m.filter((r) => !r.hidden).map((r) => /* @__PURE__ */ e(
176
+ J,
177
177
  {
178
178
  className: "text-body-xs-medium max-w-xs p-2",
179
179
  style: r.styles,
180
- children: r.render ? r.render(M.get(d, r.dataIndex), d) : M.get(d, r.dataIndex, "")
180
+ children: r.render ? r.render(z.get(d, r.dataIndex), d) : z.get(d, r.dataIndex, "")
181
181
  },
182
182
  `${B}-${r.key}`
183
183
  ))
184
184
  ]
185
185
  },
186
- `${d[c]}`
187
- )) : /* @__PURE__ */ e(G, { children: /* @__PURE__ */ e(
188
- H,
186
+ `${d[x]}`
187
+ )) : /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(
188
+ J,
189
189
  {
190
- colSpan: z ? T ? w.length + 2 : w.length + 1 : w.length,
190
+ colSpan: k ? T ? m.length + 2 : m.length + 1 : m.length,
191
191
  children: /* @__PURE__ */ e($e, {})
192
192
  }
193
193
  ) }) })
194
194
  ] });
195
195
  }, Ce = ({
196
196
  dataSource: l,
197
- columns: w,
197
+ columns: m,
198
198
  onRowClick: E,
199
- rowKey: c,
200
- hasNumbers: m,
201
- hasSearch: z,
199
+ rowKey: x,
200
+ hasNumbers: w,
201
+ hasSearch: k,
202
202
  exportOptions: T,
203
203
  hasCheckbox: s,
204
- hasPagination: i,
205
- isStickyHeader: x,
204
+ hasPagination: f,
205
+ isStickyHeader: c,
206
206
  onParamChange: t,
207
207
  dataKey: n = "docs",
208
208
  loading: L,
209
209
  tableKey: p,
210
- filters: A,
210
+ filters: M,
211
211
  actions: R,
212
212
  handleFilterChange: D,
213
- params: k,
214
- exportLoading: J = !1,
213
+ params: v,
214
+ exportLoading: _ = !1,
215
215
  onColumnsUpdate: W,
216
216
  hasColumnsVisibilityDropdown: d,
217
217
  showAppliedFilters: B = !1,
@@ -220,179 +220,173 @@ const ye = we(function({
220
220
  filterWrapperProps: F,
221
221
  exportOptionsProps: S,
222
222
  columnsVisibilityProps: g,
223
- paginationProps: u,
224
- searchProps: v,
225
- ...V
223
+ paginationProps: V,
224
+ searchProps: A,
225
+ ...u
226
226
  }) => {
227
- var Y;
228
- const { t: _ } = b(), [$, a] = ge([]), { formattedColumns: y, handleColumnsChange: C, resetColumns: P } = Te({ key: p, columns: w });
229
- return Q(() => {
230
- W == null || W(y);
231
- }, [y, W]), Q(() => {
227
+ var Z;
228
+ const { t: y } = b(), [$, a] = ge([]), { formattedColumns: H, handleColumnsChange: C, resetColumns: P } = Te({ key: p, columns: m });
229
+ return Y(() => {
230
+ W == null || W(H);
231
+ }, [H, W]), Y(() => {
232
232
  r == null || r($);
233
233
  }, [$, r]), /* @__PURE__ */ N(
234
234
  "div",
235
235
  {
236
236
  className: "border-border-alpha-light flex grow flex-col overflow-auto rounded-xl border shadow-xs",
237
237
  children: [
238
- /* @__PURE__ */ N("div", { className: "space-y-4 p-4", children: [
239
- (z || d && p || !M.isEmpty(T) || !M.isEmpty(A)) && /* @__PURE__ */ N("div", { className: "flex shrink-0 flex-col items-center justify-between gap-3 lg:flex-row", children: [
240
- /* @__PURE__ */ e("div", { className: "w-full shrink-0 grow lg:w-auto", children: z && /* @__PURE__ */ e(
241
- ve,
238
+ /* @__PURE__ */ N("div", { className: "flex flex-col gap-4 p-4", children: [
239
+ (k || d && p || !z.isEmpty(T) || !z.isEmpty(M)) && /* @__PURE__ */ N("div", { className: "flex flex-col justify-between gap-3 lg:flex-row lg:items-center", children: [
240
+ /* @__PURE__ */ e("div", { className: "grow", children: k && /* @__PURE__ */ e(
241
+ Ae,
242
242
  {
243
- ...v,
243
+ ...A,
244
244
  inputProps: {
245
- ...v == null ? void 0 : v.inputProps,
245
+ ...A == null ? void 0 : A.inputProps,
246
246
  className: o(
247
247
  "h-8 grow",
248
- (Y = v == null ? void 0 : v.inputProps) == null ? void 0 : Y.className
248
+ (Z = A == null ? void 0 : A.inputProps) == null ? void 0 : Z.className
249
249
  )
250
250
  },
251
251
  className: o(
252
- "max-w-full lg:max-w-78 [&_button]:-top-1",
253
- v == null ? void 0 : v.className
252
+ "max-w-full lg:max-w-80 [&_button]:-top-1",
253
+ A == null ? void 0 : A.className
254
254
  ),
255
- defaultValue: M.get(k, "search", ""),
256
- onSearchChange: (f) => t == null ? void 0 : t({ ...k, search: f, page: 1 })
255
+ defaultValue: z.get(v, "search", ""),
256
+ onSearchChange: (i) => t == null ? void 0 : t({ ...v, search: i, page: 1 })
257
257
  }
258
258
  ) }),
259
- /* @__PURE__ */ N(
260
- "div",
261
- {
262
- className: "flex w-full shrink items-center justify-end gap-3 lg:w-auto",
263
- children: [
264
- T && /* @__PURE__ */ e(
265
- ke,
266
- {
267
- ...S,
268
- options: T,
269
- loading: J
270
- }
271
- ),
272
- d && p && /* @__PURE__ */ N(le, { children: [
273
- /* @__PURE__ */ e(
274
- de,
275
- {
276
- asChild: !0,
277
- className: "grow",
278
- ...g == null ? void 0 : g.triggerProps,
279
- children: /* @__PURE__ */ e(
280
- q,
281
- {
282
- variant: "secondary",
283
- size: "sm",
284
- className: "ml-auto rounded-lg px-3",
285
- children: (g == null ? void 0 : g.title) || /* @__PURE__ */ N(O, { children: [
286
- /* @__PURE__ */ e(ee, {}),
287
- " ",
288
- /* @__PURE__ */ e("span", { className: "hidden md:inline!", children: _("Customize columns") }),
289
- /* @__PURE__ */ e(te, {})
290
- ] })
291
- }
292
- )
293
- }
294
- ),
295
- /* @__PURE__ */ N(
296
- se,
259
+ /* @__PURE__ */ N("div", { className: "flex items-center justify-end gap-3", children: [
260
+ T && /* @__PURE__ */ e(
261
+ ve,
262
+ {
263
+ ...S,
264
+ options: T,
265
+ loading: _
266
+ }
267
+ ),
268
+ d && p && /* @__PURE__ */ N(le, { children: [
269
+ /* @__PURE__ */ e(
270
+ de,
271
+ {
272
+ asChild: !0,
273
+ className: "grow",
274
+ ...g == null ? void 0 : g.triggerProps,
275
+ children: /* @__PURE__ */ e(
276
+ Q,
297
277
  {
298
- align: "end",
299
- ...g == null ? void 0 : g.contentProps,
300
- children: [
301
- /* @__PURE__ */ N(
302
- ie,
303
- {
304
- className: "capitalize",
305
- onClick: P,
306
- children: [
307
- /* @__PURE__ */ e(xe, {}),
308
- " ",
309
- (g == null ? void 0 : g.resetText) || _("Reset columns")
310
- ]
311
- }
312
- ),
313
- /* @__PURE__ */ e(fe, {}),
314
- y.map((f) => /* @__PURE__ */ e(
315
- re,
316
- {
317
- className: "capitalize",
318
- checked: !f.hidden,
319
- onCheckedChange: (h) => C(f, !h),
320
- children: f.name
321
- },
322
- f.key
323
- ))
324
- ]
278
+ variant: "secondary",
279
+ size: "sm",
280
+ className: "ml-auto rounded-lg px-3",
281
+ children: (g == null ? void 0 : g.title) || /* @__PURE__ */ N(O, { children: [
282
+ /* @__PURE__ */ e(ee, {}),
283
+ " ",
284
+ /* @__PURE__ */ e("span", { className: "hidden md:inline!", children: y("Customize columns") }),
285
+ /* @__PURE__ */ e(te, {})
286
+ ] })
325
287
  }
326
288
  )
327
- ] }),
328
- R && /* @__PURE__ */ e(De, { ...K, actions: R }),
329
- A && /* @__PURE__ */ e(
330
- Ae,
331
- {
332
- ...F,
333
- filters: A,
334
- params: k,
335
- onChange: D,
336
- onFilter: (f) => {
337
- t == null || t({ ...f, page: 1 }), D == null || D(f);
338
- }
339
- }
340
- )
341
- ]
342
- }
343
- )
289
+ }
290
+ ),
291
+ /* @__PURE__ */ N(
292
+ se,
293
+ {
294
+ align: "end",
295
+ ...g == null ? void 0 : g.contentProps,
296
+ children: [
297
+ /* @__PURE__ */ N(
298
+ fe,
299
+ {
300
+ className: "capitalize",
301
+ onClick: P,
302
+ children: [
303
+ /* @__PURE__ */ e(ce, {}),
304
+ " ",
305
+ (g == null ? void 0 : g.resetText) || y("Reset columns")
306
+ ]
307
+ }
308
+ ),
309
+ /* @__PURE__ */ e(ie, {}),
310
+ H.map((i) => /* @__PURE__ */ e(
311
+ re,
312
+ {
313
+ className: "capitalize",
314
+ checked: !i.hidden,
315
+ onCheckedChange: (G) => C(i, !G),
316
+ children: i.name
317
+ },
318
+ i.key
319
+ ))
320
+ ]
321
+ }
322
+ )
323
+ ] }),
324
+ R && /* @__PURE__ */ e(De, { ...K, actions: R }),
325
+ M && /* @__PURE__ */ e(
326
+ Me,
327
+ {
328
+ ...F,
329
+ filters: M,
330
+ params: v,
331
+ onChange: D,
332
+ onFilter: (i) => {
333
+ t == null || t({ ...i, page: 1 }), D == null || D(i);
334
+ }
335
+ }
336
+ )
337
+ ] })
344
338
  ] }),
345
- B && !M.isEmpty(A) && /* @__PURE__ */ e(
346
- ye,
339
+ B && !z.isEmpty(M) && /* @__PURE__ */ e(
340
+ He,
347
341
  {
348
- filters: A,
349
- params: k,
350
- onFilter: (f) => {
351
- t == null || t({ ...f, page: 1 }), D == null || D(f);
342
+ filters: M,
343
+ params: v,
344
+ onFilter: (i) => {
345
+ t == null || t({ ...i, page: 1 }), D == null || D(i);
352
346
  }
353
347
  }
354
348
  )
355
349
  ] }),
356
- /* @__PURE__ */ e("div", { className: "flex flex-col overflow-auto border-y", children: L ? /* @__PURE__ */ e(ze, {}) : /* @__PURE__ */ e(
357
- He,
350
+ /* @__PURE__ */ e("div", { className: "flex flex-col overflow-auto border-y", children: L ? /* @__PURE__ */ e(ke, {}) : /* @__PURE__ */ e(
351
+ Je,
358
352
  {
359
- ...V,
353
+ ...u,
360
354
  params: {
361
355
  page: (l == null ? void 0 : l.page) || 1,
362
356
  limit: l == null ? void 0 : l.limit,
363
- ...k
357
+ ...v
364
358
  },
365
- rows: M.get(l, n, []),
366
- rowKey: c,
359
+ rows: z.get(l, n, []),
360
+ rowKey: x,
367
361
  selectedItems: $,
368
- isStickyHeader: x,
369
- columns: y,
362
+ isStickyHeader: c,
363
+ columns: H,
370
364
  hasCheckbox: s,
371
- hasNumbers: m,
365
+ hasNumbers: w,
372
366
  onRowClick: E,
373
367
  onSelectedItemsChange: a,
374
- onSortOrderChange: ({ sortField: f, sortOrder: h }) => {
375
- t == null || t({ ...k, sortField: f, sortOrder: h });
368
+ onSortOrderChange: ({ sortField: i, sortOrder: G }) => {
369
+ t == null || t({ ...v, sortField: i, sortOrder: G });
376
370
  }
377
371
  }
378
372
  ) }),
379
- i && /* @__PURE__ */ N("div", { className: "flex shrink-0 flex-wrap items-center justify-center gap-3 p-4 lg:justify-between", children: [
373
+ f && /* @__PURE__ */ N("div", { className: "flex shrink-0 flex-wrap items-center justify-center gap-3 p-4 lg:justify-between", children: [
380
374
  /* @__PURE__ */ e("div", { className: "text-sm", children: /* @__PURE__ */ e(
381
375
  Le,
382
376
  {
383
- onLimitChange: (f) => t == null ? void 0 : t({ ...k, limit: f, page: 1 }),
377
+ onLimitChange: (i) => t == null ? void 0 : t({ ...v, limit: i, page: 1 }),
384
378
  defaultValue: l == null ? void 0 : l.limit
385
379
  }
386
380
  ) }),
387
- /* @__PURE__ */ e("div", { className: "text-muted-foreground text-sm", children: _("{{selectedCount}} of {{total}} row(s) selected", {
381
+ /* @__PURE__ */ e("div", { className: "text-muted-foreground text-sm", children: y("{{selectedCount}} of {{total}} row(s) selected", {
388
382
  selectedCount: $.length,
389
383
  total: (l == null ? void 0 : l.total) || 0
390
384
  }) }),
391
385
  /* @__PURE__ */ e("div", { children: /* @__PURE__ */ e(
392
386
  Re,
393
387
  {
394
- ...u,
395
- onPageChange: (f) => t == null ? void 0 : t({ ...k, page: f }),
388
+ ...V,
389
+ onPageChange: (i) => t == null ? void 0 : t({ ...v, page: i }),
396
390
  currentPage: l == null ? void 0 : l.page,
397
391
  totalPages: l == null ? void 0 : l.totalPages
398
392
  }
@@ -404,6 +398,6 @@ const ye = we(function({
404
398
  };
405
399
  export {
406
400
  Ce as DataTable,
407
- He as MyTable
401
+ Je as MyTable
408
402
  };
409
403
  //# sourceMappingURL=index.es.js.map