jcicl 1.0.5 → 1.0.7

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/Table/Table.js CHANGED
@@ -1,10 +1,10 @@
1
- import { jsxs as l, jsx as o } from "react/jsx-runtime";
2
- import { useState as m, useMemo as T, useEffect as q } from "react";
1
+ import { jsxs as a, jsx as t } from "react/jsx-runtime";
2
+ import { useState as b, useMemo as N, useEffect as U } from "react";
3
3
  import n from "../theme.js";
4
- import { c as s } from "../.chunks/emotion-react.browser.esm.js";
5
- import { n as a } from "../.chunks/emotion-styled.browser.esm.js";
6
- import { Button as ce } from "../Button/Button.js";
7
- import { Flex as le } from "../Flex/Flex.js";
4
+ import { c as i } from "../.chunks/emotion-react.browser.esm.js";
5
+ import { n as c } from "../.chunks/emotion-styled.browser.esm.js";
6
+ import { Button as le } from "../Button/Button.js";
7
+ import { Flex as ae } from "../Flex/Flex.js";
8
8
  import { useThemeColors as de } from "../ThemeContext.js";
9
9
  import { c as S } from "../.chunks/createLucideIcon.js";
10
10
  /**
@@ -13,21 +13,21 @@ import { c as S } from "../.chunks/createLucideIcon.js";
13
13
  * This source code is licensed under the ISC license.
14
14
  * See the LICENSE file in the root directory of this source tree.
15
15
  */
16
- const he = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]], _ = S("chevron-down", he);
16
+ const he = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]], M = S("chevron-down", he);
17
17
  /**
18
18
  * @license lucide-react v0.525.0 - ISC
19
19
  *
20
20
  * This source code is licensed under the ISC license.
21
21
  * See the LICENSE file in the root directory of this source tree.
22
22
  */
23
- const pe = [["path", { d: "m18 15-6-6-6 6", key: "153udz" }]], W = S("chevron-up", pe);
23
+ const pe = [["path", { d: "m18 15-6-6-6 6", key: "153udz" }]], q = S("chevron-up", pe);
24
24
  /**
25
25
  * @license lucide-react v0.525.0 - ISC
26
26
  *
27
27
  * This source code is licensed under the ISC license.
28
28
  * See the LICENSE file in the root directory of this source tree.
29
29
  */
30
- const xe = [
30
+ const ue = [
31
31
  [
32
32
  "path",
33
33
  {
@@ -44,14 +44,14 @@ const xe = [
44
44
  }
45
45
  ],
46
46
  ["path", { d: "m2 2 20 20", key: "1ooewy" }]
47
- ], ge = S("eye-off", xe);
47
+ ], ge = S("eye-off", ue);
48
48
  /**
49
49
  * @license lucide-react v0.525.0 - ISC
50
50
  *
51
51
  * This source code is licensed under the ISC license.
52
52
  * See the LICENSE file in the root directory of this source tree.
53
53
  */
54
- const ue = [
54
+ const xe = [
55
55
  [
56
56
  "path",
57
57
  {
@@ -60,7 +60,7 @@ const ue = [
60
60
  }
61
61
  ],
62
62
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
63
- ], be = S("eye", ue);
63
+ ], me = S("eye", xe);
64
64
  /**
65
65
  * @license lucide-react v0.525.0 - ISC
66
66
  *
@@ -70,14 +70,14 @@ const ue = [
70
70
  const fe = [
71
71
  ["path", { d: "m21 21-4.34-4.34", key: "14j7rj" }],
72
72
  ["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }]
73
- ], Q = S("search", fe);
73
+ ], K = S("search", fe);
74
74
  /**
75
75
  * @license lucide-react v0.525.0 - ISC
76
76
  *
77
77
  * This source code is licensed under the ISC license.
78
78
  * See the LICENSE file in the root directory of this source tree.
79
79
  */
80
- const me = [
80
+ const be = [
81
81
  [
82
82
  "path",
83
83
  {
@@ -86,8 +86,8 @@ const me = [
86
86
  }
87
87
  ],
88
88
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
89
- ], ye = S("settings", me), we = a("div")(() => ({
90
- ...s`
89
+ ], we = S("settings", be), ye = c("div")(() => ({
90
+ ...i`
91
91
  background-color: ${n.colors.white};
92
92
  border-radius: 8px;
93
93
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
@@ -96,8 +96,8 @@ const me = [
96
96
  width: 100%;
97
97
  overflow: auto;
98
98
  `
99
- })), Ce = a("div")(() => ({
100
- ...s`
99
+ })), Ce = c("div")(() => ({
100
+ ...i`
101
101
  display: flex;
102
102
  flex-direction: column;
103
103
  justify-content: space-between;
@@ -106,22 +106,22 @@ const me = [
106
106
  flex-wrap: wrap;
107
107
  gap: 9px;
108
108
  `
109
- })), ke = a("div")(() => ({
110
- ...s`
109
+ })), ke = c("div")(() => ({
110
+ ...i`
111
111
  display: flex;
112
112
  justify-content: space-between;
113
113
  width: 100%;
114
114
  align-items: center;
115
115
  `
116
- })), ve = a("h2")(() => ({
117
- ...s`
116
+ })), ve = c("h2")(() => ({
117
+ ...i`
118
118
  font-size: 24px;
119
119
  font-weight: bold;
120
120
  color: ${n.colors.black};
121
121
  margin: 0;
122
122
  `
123
- })), Se = a("div")(() => ({
124
- ...s`
123
+ })), Se = c("div")(() => ({
124
+ ...i`
125
125
  display: flex;
126
126
  justify-content: flex-end;
127
127
  width: 100%;
@@ -129,15 +129,17 @@ const me = [
129
129
  align-items: center;
130
130
  flex-wrap: wrap;
131
131
  `
132
- })), $e = a("div")(() => ({
133
- ...s`
132
+ })), $e = c("div")(() => ({
133
+ ...i`
134
134
  position: relative;
135
135
  display: flex;
136
136
  align-items: center;
137
137
  flex-grow: 1;
138
138
  `
139
- })), ze = a(Q)(({ customTheme: t }) => ({
140
- ...s`
139
+ })), ze = c(K, {
140
+ shouldForwardProp: (o) => !["customTheme"].includes(o)
141
+ })(({ customTheme: o }) => ({
142
+ ...i`
141
143
  position: absolute;
142
144
  left: 13px;
143
145
  top: 10px;
@@ -149,11 +151,13 @@ const me = [
149
151
  :hover,
150
152
  :focus-within {
151
153
  cursor: pointer;
152
- color: ${t.themeColor};
154
+ color: ${o.themeColor};
153
155
  }
154
156
  `
155
- })), je = a("input")(({ customTheme: t }) => ({
156
- ...s`
157
+ })), je = c("input", {
158
+ shouldForwardProp: (o) => !["customTheme"].includes(o)
159
+ })(({ customTheme: o }) => ({
160
+ ...i`
157
161
  padding: 10px 15px 10px 40px;
158
162
  border: 2px solid ${n.colors.gray4};
159
163
  border-radius: 25px;
@@ -166,18 +170,19 @@ const me = [
166
170
  :focus,
167
171
  :hover,
168
172
  :focus-within {
169
- border-color: ${t.themeColor};
170
- /* box-shadow: 0 0 0 3px rgba(0, 146, 0, 0.1); */
171
- box-shadow: 0 0 0 3px ${t.themeColor}18;
173
+ border-color: ${o.themeColor};
174
+ box-shadow: 0 0 0 3px ${o.themeColor}18; // 18 = alpha 0.1
172
175
  }
173
176
  `
174
- })), Y = a("button")(({ customTheme: t }) => ({
175
- ...s`
177
+ })), W = c("button", {
178
+ shouldForwardProp: (o) => !["customTheme"].includes(o)
179
+ })(({ customTheme: o }) => ({
180
+ ...i`
176
181
  padding: 10px 15px;
177
- border: 2px solid ${t.themeColor};
182
+ border: 2px solid ${o.themeColor};
178
183
  border-radius: 6px;
179
184
  background-color: ${n.colors.white};
180
- color: ${t.themeColor};
185
+ color: ${o.themeColor};
181
186
  cursor: pointer;
182
187
  display: flex;
183
188
  align-items: center;
@@ -189,15 +194,14 @@ const me = [
189
194
  :focus,
190
195
  :hover,
191
196
  :focus-within {
192
- background-color: ${t.themeColor};
197
+ background-color: ${o.themeColor};
193
198
  color: ${n.colors.white};
194
199
  transform: translateY(-1px);
195
- /* box-shadow: 0 4px 12px rgba(0, 146, 0, 0.3); */
196
- box-shadow: 0 4px 12px ${t.themeColor}4c;
200
+ box-shadow: 0 4px 12px ${o.themeColor}4c; // 4c = alpha 0.3
197
201
  }
198
202
  `
199
- })), G = a("div")(() => ({
200
- ...s`
203
+ })), Y = c("div")(() => ({
204
+ ...i`
201
205
  position: absolute;
202
206
  top: 100%;
203
207
  right: 0;
@@ -211,8 +215,10 @@ const me = [
211
215
  max-height: 300px;
212
216
  overflow-y: auto;
213
217
  `
214
- })), L = a("div")(({ customTheme: t }) => ({
215
- ...s`
218
+ })), _ = c("div", {
219
+ shouldForwardProp: (o) => !["customTheme"].includes(o)
220
+ })(({ customTheme: o }) => ({
221
+ ...i`
216
222
  padding: 12px 16px;
217
223
  display: flex;
218
224
  align-items: center;
@@ -224,18 +230,20 @@ const me = [
224
230
  :focus,
225
231
  :hover,
226
232
  :focus-within {
227
- background-color: ${t.themeLightB};
228
- color: ${t.themeDark};
233
+ background-color: ${o.themeLightB};
234
+ color: ${o.themeDark};
229
235
  }
230
236
  `
231
- })), E = a("input")(({ customTheme: t }) => ({
232
- ...s`
237
+ })), L = c("input", {
238
+ shouldForwardProp: (o) => !["customTheme"].includes(o)
239
+ })(({ customTheme: o }) => ({
240
+ ...i`
233
241
  width: 16px;
234
242
  height: 16px;
235
- accent-color: ${t.themeColor};
243
+ accent-color: ${o.themeColor};
236
244
  `
237
- })), De = a("table")(() => ({
238
- ...s`
245
+ })), Te = c("table")(() => ({
246
+ ...i`
239
247
  width: 100%;
240
248
  border-collapse: collapse;
241
249
  background-color: ${n.colors.white};
@@ -243,62 +251,66 @@ const me = [
243
251
  overflow: hidden;
244
252
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
245
253
  `
246
- })), Ne = a("th")(({ customTheme: t }) => ({
247
- ...s`
248
- background-color: ${n.colors.whiteBlue};
249
- color: ${n.colors.slate};
250
- padding: 16px 12px;
251
- text-align: left;
252
- font-size: 14px;
253
- font-weight: 600;
254
- border-bottom: 2px solid ${n.colors.gray4};
255
- cursor: pointer;
256
- user-select: none;
257
- transition: all 0.2s ease;
258
- position: relative;
259
- white-space: nowrap;
260
- :focus,
261
- :hover,
262
- :focus-within {
263
- background-color: ${t.themeLightC};
264
- color: ${t.themeDark};
265
- }
266
- `
267
- })), Te = a("td")(() => ({
268
- ...s`
254
+ })), De = c("th", { shouldForwardProp: (o) => !["customTheme"].includes(o) })(
255
+ ({ customTheme: o }) => ({
256
+ ...i`
257
+ background-color: ${n.colors.whiteBlue};
258
+ color: ${n.colors.slate};
259
+ padding: 16px 12px;
260
+ text-align: left;
261
+ font-size: 14px;
262
+ font-weight: 600;
263
+ border-bottom: 2px solid ${n.colors.gray4};
264
+ cursor: pointer;
265
+ user-select: none;
266
+ transition: all 0.2s ease;
267
+ position: relative;
268
+ white-space: nowrap;
269
+ :focus,
270
+ :hover,
271
+ :focus-within {
272
+ background-color: ${o.themeLightC};
273
+ color: ${o.themeDark};
274
+ }
275
+ `
276
+ })
277
+ ), Ne = c("td")(() => ({
278
+ ...i`
269
279
  padding: 14px 12px;
270
280
  border-bottom: 1px solid ${n.colors.almostWhite};
271
281
  font-size: 14px;
272
282
  color: ${n.colors.slate};
273
283
  transition: all 0.2s ease;
274
284
  `
275
- })), Ae = a("span")(() => ({
276
- ...s`
285
+ })), Ae = c("span")(() => ({
286
+ ...i`
277
287
  margin-left: 8px;
278
288
  opacity: 0.6;
279
289
  `
280
- })), J = a("tr")(({ interactableRow: t, customTheme: y }) => ({
281
- ...s`
290
+ })), G = c("tr", { shouldForwardProp: (o) => !["customTheme"].includes(o) })(({ interactableRow: o, customTheme: w }) => ({
291
+ ...i`
282
292
  transition: all 0.2s ease;
283
- ${t && s`
293
+ ${o && i`
284
294
  :focus,
285
295
  :hover,
286
296
  :focus-within {
287
- background-color: ${y.themeLightD};
297
+ background-color: ${w.themeLightD};
288
298
  cursor: pointer;
289
299
  }
290
300
  `}
291
301
  `
292
- })), Be = a("div")(() => ({
293
- ...s`
302
+ })), Fe = c("div")(() => ({
303
+ ...i`
294
304
  display: flex;
295
305
  justify-content: center;
296
306
  align-items: center;
297
307
  margin-top: 20px;
298
308
  gap: 10px;
299
309
  `
300
- })), v = a("button")(({ customTheme: t }) => ({
301
- ...s`
310
+ })), v = c("button", {
311
+ shouldForwardProp: (o) => !["customTheme"].includes(o)
312
+ })(({ customTheme: o }) => ({
313
+ ...i`
302
314
  padding: 8px 12px;
303
315
  border: 1px solid ${n.colors.gray4};
304
316
  border-radius: 4px;
@@ -311,47 +323,47 @@ const me = [
311
323
  :focus,
312
324
  :hover,
313
325
  :focus-within {
314
- background-color: ${t.themeColor};
326
+ background-color: ${o.themeColor};
315
327
  color: ${n.colors.white};
316
- border-color: ${t.themeColor};
328
+ border-color: ${o.themeColor};
317
329
  }
318
330
  :disabled {
319
331
  opacity: 0.5;
320
332
  cursor: not-allowed;
321
333
  }
322
334
  `
323
- })), Me = a("div")(() => ({
324
- ...s`
335
+ })), Be = c("div")(() => ({
336
+ ...i`
325
337
  font-size: 14px;
326
338
  color: ${n.colors.gray3};
327
339
  text-align: center;
328
340
  margin-top: 10px;
329
341
  `
330
- })), K = a("span")(() => ({
331
- ...s`
342
+ })), J = c("span")(() => ({
343
+ ...i`
332
344
  padding: 8px 4px;
333
345
  color: ${n.colors.gray3};
334
346
  font-size: 14px;
335
347
  `
336
- })), Ue = ({
337
- data: t = [],
338
- columnTitles: y = {},
339
- rowsPerPage: w = 19,
340
- title: X = "Data Table",
348
+ })), Re = ({
349
+ data: o = [],
350
+ columnTitles: w = {},
351
+ rowsPerPage: y = 19,
352
+ title: Q = "Data Table",
341
353
  onRowClick: A,
342
- hiddenColumns: Z = [],
343
- defaultSort: F = { key: "", direction: "asc" },
354
+ hiddenColumns: X = [],
355
+ defaultSort: E = { key: "", direction: "asc" },
344
356
  extraActions: I
345
357
  }) => {
346
- const [c, b] = m(1), [j, V] = m(""), [x, H] = m(F), [C, D] = m(/* @__PURE__ */ new Set()), [B, O] = m(/* @__PURE__ */ new Set()), [R, P] = m(!1), [U, ee] = m(!1), i = de(), f = {
358
+ const [l, m] = b(1), [j, V] = b(""), [u, P] = b(E), [C, T] = b(/* @__PURE__ */ new Set()), [F, H] = b(/* @__PURE__ */ new Set()), [O, Z] = b(!1), [R, ee] = b(!1), s = de(), f = {
347
359
  thActive: {
348
- backgroundColor: i.themeColor,
360
+ backgroundColor: s.themeColor,
349
361
  color: n.colors.white
350
362
  },
351
363
  paginationButtonActive: {
352
- backgroundColor: i.themeColor,
364
+ backgroundColor: s.themeColor,
353
365
  color: n.colors.white,
354
- borderColor: i.themeColor
366
+ borderColor: s.themeColor
355
367
  },
356
368
  paginationButtonDisabled: {
357
369
  opacity: 0.5,
@@ -363,68 +375,68 @@ const me = [
363
375
  textAlign: "center",
364
376
  marginTop: "10px"
365
377
  }
366
- }, h = T(() => t.length === 0 ? [] : Object.keys(t[0]).filter((e) => !Z.includes(e)), [t]);
367
- q(() => {
368
- h.length > 0 && (O(new Set(h)), D(new Set(h)));
369
- }, [h]), q(() => {
370
- V(""), H(F), b(1);
378
+ }, h = N(() => o.length === 0 ? [] : Object.keys(o[0]).filter((e) => !X.includes(e)), [o]);
379
+ U(() => {
380
+ h.length > 0 && (H(new Set(h)), T(new Set(h)));
381
+ }, [h]), U(() => {
382
+ V(""), P(E), m(1);
371
383
  }, []);
372
- const M = T(() => {
373
- if (!j) return t;
384
+ const B = N(() => {
385
+ if (!j) return o;
374
386
  const e = C.size > 0 ? C : new Set(h);
375
- return t.filter((r) => Array.from(e).some((d) => {
387
+ return o.filter((r) => Array.from(e).some((d) => {
376
388
  const g = r[d];
377
389
  return g && g.toString().toLowerCase().includes(j.toLowerCase());
378
390
  }));
379
- }, [t, j, C, h]), u = T(() => x.key ? [...M].sort((e, r) => e[x.key] < r[x.key] ? x.direction === "asc" ? -1 : 1 : e[x.key] > r[x.key] ? x.direction === "asc" ? 1 : -1 : 0) : M, [M, x]), N = h.filter((e) => B.has(e)), oe = () => {
380
- if (!Array.isArray(u) || u.length === 0) return;
381
- const e = N.map((k) => y[k] || k), r = (k) => {
391
+ }, [o, j, C, h]), x = N(() => u.key ? [...B].sort((e, r) => e[u.key] < r[u.key] ? u.direction === "asc" ? -1 : 1 : e[u.key] > r[u.key] ? u.direction === "asc" ? 1 : -1 : 0) : B, [B, u]), D = h.filter((e) => F.has(e)), oe = () => {
392
+ if (!Array.isArray(x) || x.length === 0) return;
393
+ const e = D.map((k) => w[k] || k), r = (k) => {
382
394
  const z = String(k ?? "");
383
395
  return /[",\n]/.test(z) ? `"${z.replace(/"/g, '""')}"` : z;
384
396
  }, g = [
385
397
  e.join(","),
386
398
  // header row
387
- ...u.map((k) => N.map((z) => r(k[z])).join(","))
399
+ ...x.map((k) => D.map((z) => r(k[z])).join(","))
388
400
  ].join(`
389
- `), ae = new Blob([g], { type: "text/csv;charset=utf-8;" }), $ = document.createElement("a");
390
- $.href = URL.createObjectURL(ae), $.download = "data.csv", document.body.appendChild($), $.click(), document.body.removeChild($);
391
- }, te = T(() => {
392
- const e = (c - 1) * w;
393
- return u.slice(e, e + w);
394
- }, [u, c, w]), p = Math.ceil(u.length / w), ne = (e) => {
395
- H((r) => ({
401
+ `), ce = new Blob([g], { type: "text/csv;charset=utf-8;" }), $ = document.createElement("a");
402
+ $.href = URL.createObjectURL(ce), $.download = "data.csv", document.body.appendChild($), $.click(), document.body.removeChild($);
403
+ }, te = N(() => {
404
+ const e = (l - 1) * y;
405
+ return x.slice(e, e + y);
406
+ }, [x, l, y]), p = Math.ceil(x.length / y), ne = (e) => {
407
+ P((r) => ({
396
408
  key: e,
397
409
  direction: r.key === e && r.direction === "asc" ? "desc" : "asc"
398
410
  }));
399
411
  }, re = (e) => {
400
- D((r) => {
412
+ T((r) => {
401
413
  const d = new Set(r);
402
414
  return d.has(e) ? d.delete(e) : d.add(e), d;
403
415
  });
404
- }, ie = () => {
405
- C.size === h.length ? D(/* @__PURE__ */ new Set()) : D(new Set(h));
406
- }, se = (e) => {
407
- O((r) => {
416
+ }, se = () => {
417
+ C.size === h.length ? T(/* @__PURE__ */ new Set()) : T(new Set(h));
418
+ }, ie = (e) => {
419
+ H((r) => {
408
420
  const d = new Set(r);
409
421
  return d.has(e) ? d.delete(e) : d.add(e), d;
410
422
  });
411
423
  };
412
- return /* @__PURE__ */ l(we, { className: "jcTableContainer", children: [
413
- /* @__PURE__ */ l(Ce, { className: "jcTableHeader", children: [
414
- /* @__PURE__ */ l(ke, { className: "jcTableTitleAndActions", children: [
415
- /* @__PURE__ */ o(ve, { children: X }),
416
- /* @__PURE__ */ l(le, { className: "jcTableExtraComponentsBox", gap: "9px", children: [
424
+ return /* @__PURE__ */ a(ye, { className: "jcTableContainer", children: [
425
+ /* @__PURE__ */ a(Ce, { className: "jcTableHeader", children: [
426
+ /* @__PURE__ */ a(ke, { className: "jcTableTitleAndActions", children: [
427
+ /* @__PURE__ */ t(ve, { children: Q }),
428
+ /* @__PURE__ */ a(ae, { className: "jcTableExtraComponentsBox", gap: "9px", children: [
417
429
  I && I,
418
- /* @__PURE__ */ o(ce, { onClick: oe, children: "Export to CSV" })
430
+ /* @__PURE__ */ t(le, { onClick: oe, children: "Export to CSV" })
419
431
  ] })
420
432
  ] }),
421
- /* @__PURE__ */ l(Se, { className: "jcTableControls", children: [
422
- /* @__PURE__ */ l($e, { className: "jcTableSearchContainer", children: [
423
- /* @__PURE__ */ o(ze, { customTheme: i }),
424
- /* @__PURE__ */ o(
433
+ /* @__PURE__ */ a(Se, { className: "jcTableControls", children: [
434
+ /* @__PURE__ */ a($e, { className: "jcTableSearchContainer", children: [
435
+ /* @__PURE__ */ t(ze, { customTheme: s }),
436
+ /* @__PURE__ */ t(
425
437
  je,
426
438
  {
427
- customTheme: i,
439
+ customTheme: s,
428
440
  type: "text",
429
441
  placeholder: "Search...",
430
442
  value: j,
@@ -432,90 +444,90 @@ const me = [
432
444
  }
433
445
  )
434
446
  ] }),
435
- /* @__PURE__ */ l("div", { style: { position: "relative" }, children: [
436
- /* @__PURE__ */ l(
437
- Y,
447
+ /* @__PURE__ */ a("div", { style: { position: "relative" }, children: [
448
+ /* @__PURE__ */ a(
449
+ W,
438
450
  {
439
- customTheme: i,
451
+ customTheme: s,
440
452
  className: "jcTableSearchFields",
441
- onClick: () => ee(!U),
453
+ onClick: () => ee(!R),
442
454
  children: [
443
- /* @__PURE__ */ o(Q, { size: 16 }),
455
+ /* @__PURE__ */ t(K, { size: 16 }),
444
456
  "Fields",
445
- /* @__PURE__ */ o(_, { size: 16 })
457
+ /* @__PURE__ */ t(M, { size: 16 })
446
458
  ]
447
459
  }
448
460
  ),
449
- U && /* @__PURE__ */ l(G, { className: "jcTableSearchFieldsDropdown", children: [
450
- /* @__PURE__ */ l(L, { customTheme: i, onClick: ie, children: [
451
- /* @__PURE__ */ o(
452
- E,
461
+ R && /* @__PURE__ */ a(Y, { className: "jcTableSearchFieldsDropdown", children: [
462
+ /* @__PURE__ */ a(_, { customTheme: s, onClick: se, children: [
463
+ /* @__PURE__ */ t(
464
+ L,
453
465
  {
454
- customTheme: i,
466
+ customTheme: s,
455
467
  type: "checkbox",
456
468
  checked: C.size === h.length,
457
469
  onChange: () => {
458
470
  }
459
471
  }
460
472
  ),
461
- /* @__PURE__ */ o("span", { style: { fontWeight: "bold" }, children: "All" })
473
+ /* @__PURE__ */ t("span", { style: { fontWeight: "bold" }, children: "All" })
462
474
  ] }),
463
- /* @__PURE__ */ o("div", { style: { height: "1px", backgroundColor: n.colors.gray4, margin: "4px 0" } }),
464
- h.map((e) => /* @__PURE__ */ l(
465
- L,
475
+ /* @__PURE__ */ t("div", { style: { height: "1px", backgroundColor: n.colors.gray4, margin: "4px 0" } }),
476
+ h.map((e) => /* @__PURE__ */ a(
477
+ _,
466
478
  {
467
- customTheme: i,
479
+ customTheme: s,
468
480
  onClick: () => re(e),
469
481
  children: [
470
- /* @__PURE__ */ o(
471
- E,
482
+ /* @__PURE__ */ t(
483
+ L,
472
484
  {
473
- customTheme: i,
485
+ customTheme: s,
474
486
  type: "checkbox",
475
487
  checked: C.has(e),
476
488
  onChange: () => {
477
489
  }
478
490
  }
479
491
  ),
480
- /* @__PURE__ */ o("span", { children: y[e] || e })
492
+ /* @__PURE__ */ t("span", { children: w[e] || e })
481
493
  ]
482
494
  },
483
495
  e
484
496
  ))
485
497
  ] })
486
498
  ] }),
487
- /* @__PURE__ */ l("div", { style: { position: "relative" }, children: [
488
- /* @__PURE__ */ l(
489
- Y,
499
+ /* @__PURE__ */ a("div", { style: { position: "relative" }, children: [
500
+ /* @__PURE__ */ a(
501
+ W,
490
502
  {
491
- customTheme: i,
503
+ customTheme: s,
492
504
  className: "jcTableColumnSettings",
493
- onClick: () => P(!R),
505
+ onClick: () => Z(!O),
494
506
  children: [
495
- /* @__PURE__ */ o(ye, { size: 16 }),
507
+ /* @__PURE__ */ t(we, { size: 16 }),
496
508
  "Columns",
497
- /* @__PURE__ */ o(_, { size: 16 })
509
+ /* @__PURE__ */ t(M, { size: 16 })
498
510
  ]
499
511
  }
500
512
  ),
501
- R && /* @__PURE__ */ o(G, { className: "jcTableColumnSettingsDropdown", children: h.map((e) => /* @__PURE__ */ l(
502
- L,
513
+ O && /* @__PURE__ */ t(Y, { className: "jcTableColumnSettingsDropdown", children: h.map((e) => /* @__PURE__ */ a(
514
+ _,
503
515
  {
504
- customTheme: i,
505
- onClick: () => se(e),
516
+ customTheme: s,
517
+ onClick: () => ie(e),
506
518
  children: [
507
- /* @__PURE__ */ o(
508
- E,
519
+ /* @__PURE__ */ t(
520
+ L,
509
521
  {
510
- customTheme: i,
522
+ customTheme: s,
511
523
  type: "checkbox",
512
- checked: B.has(e),
524
+ checked: F.has(e),
513
525
  onChange: () => {
514
526
  }
515
527
  }
516
528
  ),
517
- B.has(e) ? /* @__PURE__ */ o(be, { size: 16 }) : /* @__PURE__ */ o(ge, { size: 16 }),
518
- /* @__PURE__ */ o("span", { children: y[e] || e })
529
+ F.has(e) ? /* @__PURE__ */ t(me, { size: 16 }) : /* @__PURE__ */ t(ge, { size: 16 }),
530
+ /* @__PURE__ */ t("span", { children: w[e] || e })
519
531
  ]
520
532
  },
521
533
  e
@@ -523,39 +535,39 @@ const me = [
523
535
  ] })
524
536
  ] })
525
537
  ] }),
526
- /* @__PURE__ */ l(De, { className: "jcTableContent", children: [
527
- /* @__PURE__ */ o("thead", { children: /* @__PURE__ */ o(J, { customTheme: i, interactableRow: !1, children: N.map((e) => /* @__PURE__ */ l(
528
- Ne,
538
+ /* @__PURE__ */ a(Te, { className: "jcTableContent", children: [
539
+ /* @__PURE__ */ t("thead", { children: /* @__PURE__ */ t(G, { customTheme: s, interactableRow: !1, children: D.map((e) => /* @__PURE__ */ a(
540
+ De,
529
541
  {
530
- customTheme: i,
531
- style: x.key === e ? f.thActive : {},
542
+ customTheme: s,
543
+ style: u.key === e ? f.thActive : {},
532
544
  onClick: () => ne(e),
533
545
  children: [
534
- y[e] || e,
535
- /* @__PURE__ */ o(Ae, { children: x.key === e ? x.direction === "asc" ? /* @__PURE__ */ o(W, { size: 16 }) : /* @__PURE__ */ o(_, { size: 16 }) : /* @__PURE__ */ o(W, { size: 16, style: { opacity: 0.313 } }) })
546
+ w[e] || e,
547
+ /* @__PURE__ */ t(Ae, { children: u.key === e ? u.direction === "asc" ? /* @__PURE__ */ t(q, { size: 16 }) : /* @__PURE__ */ t(M, { size: 16 }) : /* @__PURE__ */ t(q, { size: 16, style: { opacity: 0.313 } }) })
536
548
  ]
537
549
  },
538
550
  e
539
551
  )) }) }),
540
- /* @__PURE__ */ o("tbody", { children: te.map((e, r) => /* @__PURE__ */ o(
541
- J,
552
+ /* @__PURE__ */ t("tbody", { children: te.map((e, r) => /* @__PURE__ */ t(
553
+ G,
542
554
  {
543
- customTheme: i,
555
+ customTheme: s,
544
556
  onClick: () => A && A(e),
545
557
  interactableRow: !!A,
546
- children: N.map((d) => /* @__PURE__ */ o(Te, { children: e[d] }, d))
558
+ children: D.map((d) => /* @__PURE__ */ t(Ne, { children: e[d] }, d))
547
559
  },
548
560
  r
549
561
  )) })
550
562
  ] }),
551
- /* @__PURE__ */ l(Be, { children: [
552
- /* @__PURE__ */ o(
563
+ /* @__PURE__ */ a(Fe, { children: [
564
+ /* @__PURE__ */ t(
553
565
  v,
554
566
  {
555
- customTheme: i,
556
- style: c === 1 ? f.paginationButtonDisabled : {},
557
- onClick: () => b(Math.max(1, c - 1)),
558
- disabled: c === 1,
567
+ customTheme: s,
568
+ style: l === 1 ? f.paginationButtonDisabled : {},
569
+ onClick: () => m(Math.max(1, l - 1)),
570
+ disabled: l === 1,
559
571
  children: "Previous"
560
572
  }
561
573
  ),
@@ -564,12 +576,12 @@ const me = [
564
576
  if (p <= 5)
565
577
  for (let r = 1; r <= p; r++)
566
578
  e.push(
567
- /* @__PURE__ */ o(
579
+ /* @__PURE__ */ t(
568
580
  v,
569
581
  {
570
- customTheme: i,
571
- style: c === r ? f.paginationButtonActive : {},
572
- onClick: () => b(r),
582
+ customTheme: s,
583
+ style: l === r ? f.paginationButtonActive : {},
584
+ onClick: () => m(r),
573
585
  children: r
574
586
  },
575
587
  r
@@ -577,38 +589,38 @@ const me = [
577
589
  );
578
590
  else {
579
591
  e.push(
580
- /* @__PURE__ */ o(
592
+ /* @__PURE__ */ t(
581
593
  v,
582
594
  {
583
- customTheme: i,
584
- style: c === 1 ? f.paginationButtonActive : {},
585
- onClick: () => b(1),
595
+ customTheme: s,
596
+ style: l === 1 ? f.paginationButtonActive : {},
597
+ onClick: () => m(1),
586
598
  children: "1"
587
599
  },
588
600
  1
589
601
  )
590
- ), c > 3 && e.push(/* @__PURE__ */ o(K, { children: "..." }, "ellipsis1"));
591
- const r = Math.max(2, c - 1), d = Math.min(p - 1, c + 1);
602
+ ), l > 3 && e.push(/* @__PURE__ */ t(J, { children: "..." }, "ellipsis1"));
603
+ const r = Math.max(2, l - 1), d = Math.min(p - 1, l + 1);
592
604
  for (let g = r; g <= d; g++)
593
605
  e.push(
594
- /* @__PURE__ */ o(
606
+ /* @__PURE__ */ t(
595
607
  v,
596
608
  {
597
- customTheme: i,
598
- style: c === g ? f.paginationButtonActive : {},
599
- onClick: () => b(g),
609
+ customTheme: s,
610
+ style: l === g ? f.paginationButtonActive : {},
611
+ onClick: () => m(g),
600
612
  children: g
601
613
  },
602
614
  g
603
615
  )
604
616
  );
605
- c < p - 2 && e.push(/* @__PURE__ */ o(K, { children: "..." }, "ellipsis2")), p > 1 && e.push(
606
- /* @__PURE__ */ o(
617
+ l < p - 2 && e.push(/* @__PURE__ */ t(J, { children: "..." }, "ellipsis2")), p > 1 && e.push(
618
+ /* @__PURE__ */ t(
607
619
  v,
608
620
  {
609
- customTheme: i,
610
- style: c === p ? f.paginationButtonActive : {},
611
- onClick: () => b(p),
621
+ customTheme: s,
622
+ style: l === p ? f.paginationButtonActive : {},
623
+ onClick: () => m(p),
612
624
  children: p
613
625
  },
614
626
  p
@@ -617,29 +629,29 @@ const me = [
617
629
  }
618
630
  return e;
619
631
  })(),
620
- /* @__PURE__ */ o(
632
+ /* @__PURE__ */ t(
621
633
  v,
622
634
  {
623
- customTheme: i,
624
- style: c === p ? f.paginationButtonDisabled : {},
625
- onClick: () => b(Math.min(p, c + 1)),
626
- disabled: c === p,
635
+ customTheme: s,
636
+ style: l === p ? f.paginationButtonDisabled : {},
637
+ onClick: () => m(Math.min(p, l + 1)),
638
+ disabled: l === p,
627
639
  children: "Next"
628
640
  }
629
641
  )
630
642
  ] }),
631
- /* @__PURE__ */ l(Me, { children: [
643
+ /* @__PURE__ */ a(Be, { children: [
632
644
  "Showing ",
633
- Math.min((c - 1) * w + 1, u.length),
645
+ Math.min((l - 1) * y + 1, x.length),
634
646
  " to",
635
647
  " ",
636
- Math.min(c * w, u.length),
648
+ Math.min(l * y, x.length),
637
649
  " of ",
638
- u.length,
650
+ x.length,
639
651
  " entries"
640
652
  ] })
641
653
  ] });
642
654
  };
643
655
  export {
644
- Ue as default
656
+ Re as default
645
657
  };