@versini/ui-table 3.0.3 → 3.0.5

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.
Files changed (2) hide show
  1. package/dist/index.js +209 -188
  2. package/package.json +7 -5
package/dist/index.js CHANGED
@@ -1,14 +1,14 @@
1
- import s from "clsx";
2
- import { jsx as i, jsxs as y, Fragment as j } from "react/jsx-runtime";
1
+ import o from "clsx";
2
+ import { jsx as l, jsxs as y, Fragment as A } from "react/jsx-runtime";
3
3
  import T, { useContext as p } from "react";
4
4
  /*!
5
- @versini/ui-table v3.0.3
5
+ @versini/ui-table v3.0.5
6
6
  © 2025 gizmette.com
7
7
  */
8
8
  try {
9
9
  window.__VERSINI_UI_TABLE__ || (window.__VERSINI_UI_TABLE__ = {
10
- version: "3.0.3",
11
- buildTime: "01/04/2025 01:33 PM EST",
10
+ version: "3.0.5",
11
+ buildTime: "01/06/2025 08:01 PM EST",
12
12
  homepage: "https://github.com/aversini/ui-components",
13
13
  license: "MIT"
14
14
  });
@@ -17,18 +17,18 @@ try {
17
17
  const _ = "thead", C = "tfoot", u = "tbody", f = {
18
18
  ASC: "asc",
19
19
  DESC: "desc"
20
- }, A = ({
20
+ }, W = ({
21
21
  mode: e,
22
22
  className: a,
23
23
  wrapperClassName: t,
24
24
  stickyHeader: r,
25
- stickyFooter: o
25
+ stickyFooter: s
26
26
  }) => ({
27
- wrapper: s(
27
+ wrapper: o(
28
28
  "not-prose relative w-full rounded-lg shadow-md",
29
29
  {
30
- "overflow-x-auto": !r && !o,
31
- "overflow-y-scroll": r || o,
30
+ "overflow-x-auto": !r && !s,
31
+ "overflow-y-scroll": r || s,
32
32
  "bg-surface-darker": e === "dark" || e === "system",
33
33
  "bg-surface-light": e === "light" || e === "alt-system",
34
34
  "dark:bg-surface-light": e === "system",
@@ -40,23 +40,23 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
40
40
  },
41
41
  t
42
42
  ),
43
- table: s("my-0 w-full text-left text-sm", a, {
43
+ table: o("my-0 w-full text-left text-sm", a, {
44
44
  "text-copy-light": e === "dark",
45
45
  "text-copy-dark": e === "light",
46
46
  "text-copy-light dark:text-copy-dark": e === "system",
47
47
  "text-copy-dark dark:text-copy-light": e === "alt-system"
48
48
  }),
49
- caption: s("py-2 text-sm font-bold", {
49
+ caption: o("py-2 text-sm font-bold", {
50
50
  "text-copy-light": e === "dark",
51
51
  "text-copy-dark": e === "light",
52
52
  "text-copy-light dark:text-copy-dark": e === "system",
53
53
  "text-copy-dark dark:text-copy-light": e === "alt-system"
54
54
  })
55
- }), W = ({
55
+ }), D = ({
56
56
  className: e,
57
57
  stickyHeader: a,
58
58
  mode: t
59
- }) => s(
59
+ }) => o(
60
60
  {
61
61
  "sticky top-0 z-10": a,
62
62
  "shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem]": a && t === "dark",
@@ -65,11 +65,11 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
65
65
  "shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem] dark:shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem]": a && t === "alt-system"
66
66
  },
67
67
  e
68
- ), D = ({
68
+ ), F = ({
69
69
  className: e,
70
70
  stickyFooter: a,
71
71
  mode: t
72
- }) => s(
72
+ }) => o(
73
73
  {
74
74
  "sticky bottom-0 z-10": a,
75
75
  "shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem]": a && t === "dark",
@@ -78,11 +78,11 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
78
78
  "shadow-[rgb(65_65_65_/30%)_-0_0.5rem_1rem] dark:shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem]": a && t === "alt-system"
79
79
  },
80
80
  e
81
- ), F = ({
81
+ ), G = ({
82
82
  mode: e,
83
83
  className: a,
84
84
  cellWrapper: t
85
- }) => t === _ || t === C ? s(
85
+ }) => t === _ || t === C ? o(
86
86
  {
87
87
  "bg-table-head-dark": e === "dark" || e === "system",
88
88
  "bg-table-head-light": e === "light" || e === "alt-system",
@@ -90,7 +90,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
90
90
  "dark:bg-table-head-dark": e === "alt-system"
91
91
  },
92
92
  a
93
- ) : s(
93
+ ) : o(
94
94
  "border-b last:border-0",
95
95
  {
96
96
  "border-table-dark": e === "dark" || e === "system",
@@ -103,19 +103,19 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
103
103
  "odd:bg-table-light-odd even:bg-table-light-even dark:odd:bg-table-dark-odd dark:even:bg-table-dark-even": t === u && e === "alt-system"
104
104
  },
105
105
  a
106
- ), G = ({
106
+ ), Y = ({
107
107
  cellWrapper: e,
108
108
  className: a,
109
109
  compact: t,
110
110
  mode: r,
111
- align: o
111
+ align: s
112
112
  }) => ({
113
- alignClasses: s({
114
- "flex justify-start text-left": o === "left",
115
- "flex justify-center text-center": o === "center",
116
- "flex justify-end text-right": o === "right"
113
+ alignClasses: o({
114
+ "flex justify-start text-left": s === "left",
115
+ "flex justify-center text-center": s === "center",
116
+ "flex justify-end text-right": s === "right"
117
117
  }),
118
- mainClasses: s(
118
+ mainClasses: o(
119
119
  {
120
120
  "text-copy-light": r === "dark" || r === "system",
121
121
  "text-copy-dark": r === "light" || r === "alt-system",
@@ -127,29 +127,29 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
127
127
  },
128
128
  a
129
129
  )
130
- }), Y = ({
130
+ }), q = ({
131
131
  buttonClassName: e
132
- }) => s("rounded-none text-sm", e), I = "av-button", B = "icon", S = "button", N = "link", q = ({
132
+ }) => o("rounded-none text-sm", e), I = "av-button", B = "icon", S = "button", N = "link", H = ({
133
133
  type: e,
134
134
  size: a,
135
135
  labelRight: t,
136
136
  labelLeft: r,
137
- align: o
137
+ align: s
138
138
  }) => {
139
- const l = "max-h-8 py-0 px-2", c = "max-h-9 py-1 px-3", d = "max-h-12 py-2 px-4";
139
+ const i = "max-h-8 py-0 px-2", d = "max-h-9 py-1 px-3", c = "max-h-12 py-2 px-4";
140
140
  switch (e) {
141
141
  case S:
142
142
  case N:
143
- return s({
144
- [l]: a === "small",
145
- [c]: a === "medium",
146
- [d]: a === "large"
143
+ return o({
144
+ [i]: a === "small",
145
+ [d]: a === "medium",
146
+ [c]: a === "large"
147
147
  });
148
148
  case B:
149
- return s("inline-flex items-center", {
150
- "justify-center": o === "center",
151
- "justify-start": o === "left",
152
- "justify-end": o === "right",
149
+ return o("inline-flex items-center", {
150
+ "justify-center": s === "center",
151
+ "justify-start": s === "left",
152
+ "justify-end": s === "right",
153
153
  "h-6 w-6 p-0": a === "small" && !(t || r),
154
154
  "h-6 px-2": a === "small" && (t || r),
155
155
  "h-8 w-8 p-1": a === "medium" && !(t || r),
@@ -164,21 +164,21 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
164
164
  labelRight: t,
165
165
  labelLeft: r
166
166
  }) => {
167
- const o = "text-sm font-medium", l = "text-base font-medium", c = "text-lg font-medium";
167
+ const s = "text-sm font-medium", i = "text-base font-medium", d = "text-lg font-medium";
168
168
  switch (e) {
169
169
  case S:
170
170
  case N:
171
- return s({
171
+ return o({
172
172
  "text-center": e === N,
173
- [o]: a === "small",
174
- [l]: a === "medium",
175
- [c]: a === "large"
173
+ [s]: a === "small",
174
+ [i]: a === "medium",
175
+ [d]: a === "large"
176
176
  });
177
177
  case B:
178
- return s({
179
- [o]: a === "small" && (t || r),
180
- [l]: a === "medium" && (t || r),
181
- [c]: a === "large" && (t || r)
178
+ return o({
179
+ [s]: a === "small" && (t || r),
180
+ [i]: a === "medium" && (t || r),
181
+ [d]: a === "large" && (t || r)
182
182
  });
183
183
  }
184
184
  }, K = ({
@@ -190,7 +190,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
190
190
  if (a)
191
191
  return "not-prose";
192
192
  if (r === "primary")
193
- return s("not-prose", {
193
+ return o("not-prose", {
194
194
  truncate: !t,
195
195
  "text-copy-light": e === "dark" || e === "system",
196
196
  "text-copy-lighter": e === "light" || e === "alt-system",
@@ -198,7 +198,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
198
198
  "dark:text-copy-light": e === "alt-system"
199
199
  });
200
200
  if (r === "secondary")
201
- return s("not-prose", {
201
+ return o("not-prose", {
202
202
  truncate: !t,
203
203
  "text-copy-light": e === "light" || e === "system",
204
204
  "text-copy-lighter": e === "dark" || e === "alt-system",
@@ -206,7 +206,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
206
206
  "dark:text-copy-light": e === "system"
207
207
  });
208
208
  if (r === "danger")
209
- return s("not-prose", {
209
+ return o("not-prose", {
210
210
  truncate: !t,
211
211
  "text-copy-light": e === "dark" || e === "system",
212
212
  "text-copy-lighter": e === "light" || e === "alt-system",
@@ -214,7 +214,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
214
214
  "dark:text-copy-light": e === "alt-system"
215
215
  });
216
216
  if (r === "selected")
217
- return s("not-prose text-copy-lighter", {
217
+ return o("not-prose text-copy-lighter", {
218
218
  truncate: !t
219
219
  });
220
220
  }, Q = ({
@@ -224,21 +224,21 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
224
224
  }) => {
225
225
  if (!a) {
226
226
  if (t === "primary")
227
- return s({
227
+ return o({
228
228
  "bg-action-dark": e === "dark",
229
229
  "bg-action-light": e === "light",
230
230
  "bg-action-dark dark:bg-action-light": e === "system",
231
231
  "bg-action-light dark:bg-action-dark": e === "alt-system"
232
232
  });
233
233
  if (t === "secondary")
234
- return s({
234
+ return o({
235
235
  "bg-action-dark": e === "light",
236
236
  "bg-action-light": e === "dark",
237
237
  "bg-action-dark dark:bg-action-light": e === "alt-system",
238
238
  "bg-action-light dark:bg-action-dark": e === "system"
239
239
  });
240
240
  if (t === "danger")
241
- return s({
241
+ return o({
242
242
  "bg-action-danger-dark": e === "dark",
243
243
  "bg-action-danger-light": e === "light",
244
244
  "bg-action-danger-dark dark:bg-action-danger-light": e === "system",
@@ -249,7 +249,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
249
249
  }
250
250
  }, X = ({
251
251
  radius: e
252
- }) => s({
252
+ }) => o({
253
253
  "rounded-full": e === "large",
254
254
  "rounded-md": e === "medium",
255
255
  "rounded-sm": e === "small"
@@ -261,21 +261,21 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
261
261
  if (a)
262
262
  return "";
263
263
  if (t === "primary")
264
- return s("hover:text-copy-light-hover", {
264
+ return o("hover:text-copy-light-hover", {
265
265
  "hover:bg-action-dark-hover": e === "dark",
266
266
  "hover:bg-action-light-hover": e === "light",
267
267
  "hover:bg-action-dark-hover dark:hover:bg-action-light-hover": e === "system",
268
268
  "hover:bg-action-light-hover dark:hover:bg-action-dark-hover": e === "alt-system"
269
269
  });
270
270
  if (t === "secondary")
271
- return s("hover:text-copy-light-hover", {
271
+ return o("hover:text-copy-light-hover", {
272
272
  "hover:bg-action-dark-hover": e === "light",
273
273
  "hover:bg-action-light-hover": e === "dark",
274
274
  "hover:bg-action-dark-hover dark:hover:bg-action-light-hover": e === "alt-system",
275
275
  "hover:bg-action-light-hover dark:hover:bg-action-dark-hover": e === "system"
276
276
  });
277
277
  if (t === "danger")
278
- return s("hover:text-copy-light-hover", {
278
+ return o("hover:text-copy-light-hover", {
279
279
  "hover:bg-action-danger-dark-hover": e === "dark",
280
280
  "hover:bg-action-danger-light-hover": e === "light",
281
281
  "hover:bg-action-danger-dark-hover dark:hover:bg-action-danger-light-hover": e === "system",
@@ -291,21 +291,21 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
291
291
  if (a)
292
292
  return "";
293
293
  if (t === "primary")
294
- return s("active:text-copy-light-active", {
294
+ return o("active:text-copy-light-active", {
295
295
  "active:bg-action-dark-active": e === "dark",
296
296
  "active:bg-action-light-active": e === "light",
297
297
  "active:bg-action-dark-active dark:active:bg-action-light-active": e === "system",
298
298
  "active:bg-action-light-active dark:active:bg-action-dark-active": e === "alt-system"
299
299
  });
300
300
  if (t === "secondary")
301
- return s("active:text-copy-light-active", {
301
+ return o("active:text-copy-light-active", {
302
302
  "active:bg-action-dark-active": e === "light",
303
303
  "active:bg-action-light-active": e === "dark",
304
304
  "active:bg-action-dark-active dark:active:bg-action-light-active": e === "alt-system",
305
305
  "active:bg-action-light-active dark:active:bg-action-dark-active": e === "system"
306
306
  });
307
307
  if (t === "danger")
308
- return s("active:text-copy-lighter-active", {
308
+ return o("active:text-copy-lighter-active", {
309
309
  "active:bg-action-danger-dark-active": e === "dark",
310
310
  "active:bg-action-danger-light-active": e === "light",
311
311
  "active:bg-action-danger-dark-active dark:active:bg-action-danger-light-active": e === "system",
@@ -321,21 +321,21 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
321
321
  if (a)
322
322
  return "border border-transparent";
323
323
  if (t === "primary")
324
- return s("border", {
324
+ return o("border", {
325
325
  "border-border-dark": e === "dark",
326
326
  "border-border-accent": e === "light",
327
327
  "border-border-dark dark:border-border-accent": e === "system",
328
328
  "border-border-accent dark:border-border-dark": e === "alt-system"
329
329
  });
330
330
  if (t === "secondary")
331
- return s("border", {
331
+ return o("border", {
332
332
  "border-border-dark": e === "light",
333
333
  "border-border-accent": e === "dark",
334
334
  "border-border-dark dark:border-border-accent": e === "alt-system",
335
335
  "border-border-accent dark:border-border-dark": e === "system"
336
336
  });
337
337
  if (t === "danger")
338
- return s("border", {
338
+ return o("border", {
339
339
  "border-border-danger-dark": e === "dark",
340
340
  "border-border-danger-medium": e === "light",
341
341
  "border-border-danger-dark dark:border-border-danger-medium": e === "system",
@@ -345,7 +345,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
345
345
  return "border border-border-selected-dark";
346
346
  }, te = ({
347
347
  focusMode: e
348
- }) => s("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
348
+ }) => o("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
349
349
  "focus:outline-focus-dark": e === "dark",
350
350
  "focus:outline-focus-light": e === "light",
351
351
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
@@ -355,10 +355,10 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
355
355
  className: a,
356
356
  raw: t,
357
357
  mode: r,
358
- focusMode: o,
359
- disabled: l,
360
- fullWidth: c,
361
- size: d,
358
+ focusMode: s,
359
+ disabled: i,
360
+ fullWidth: d,
361
+ size: c,
362
362
  noBorder: n,
363
363
  labelRight: g,
364
364
  labelLeft: b,
@@ -367,7 +367,7 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
367
367
  noTruncate: v,
368
368
  align: x,
369
369
  radius: w
370
- }) => (h || (h = "primary"), t ? s(I, a) : s(
370
+ }) => (h || (h = "primary"), t ? o(I, a) : o(
371
371
  I,
372
372
  K({
373
373
  mode: r,
@@ -377,48 +377,48 @@ const _ = "thead", C = "tfoot", u = "tbody", f = {
377
377
  }),
378
378
  Q({ mode: r, noBackground: m, variant: h }),
379
379
  X({ radius: w }),
380
- q({
380
+ H({
381
381
  type: e,
382
- size: d,
382
+ size: c,
383
383
  labelRight: g,
384
384
  labelLeft: b,
385
385
  align: x
386
386
  }),
387
- J({ type: e, size: d, labelRight: g, labelLeft: b }),
387
+ J({ type: e, size: c, labelRight: g, labelLeft: b }),
388
388
  ee({ mode: r, variant: h, noBorder: n }),
389
- te({ focusMode: o }),
390
- Z({ mode: r, variant: h, disabled: l }),
391
- $({ mode: r, variant: h, disabled: l }),
389
+ te({ focusMode: s }),
390
+ Z({ mode: r, variant: h, disabled: i }),
391
+ $({ mode: r, variant: h, disabled: i }),
392
392
  {
393
- "w-full": c,
394
- "disabled:cursor-not-allowed disabled:opacity-50": l
393
+ "w-full": d,
394
+ "disabled:cursor-not-allowed disabled:opacity-50": i
395
395
  },
396
396
  a
397
397
  )), re = (e, a, t) => {
398
398
  var r;
399
399
  !a && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((r = e == null ? void 0 : e.currentTarget) == null ? void 0 : r.focus) == "function" && e.currentTarget.focus(), typeof t == "function" && t(e);
400
400
  }, E = T.forwardRef((e, a) => {
401
- const { onClick: t, noInternalClick: r = !1, ...o } = e;
402
- return /* @__PURE__ */ i(
401
+ const { onClick: t, noInternalClick: r = !1, ...s } = e;
402
+ return /* @__PURE__ */ l(
403
403
  "button",
404
404
  {
405
405
  ref: a,
406
- onClick: (l) => {
407
- re(l, r, t);
406
+ onClick: (i) => {
407
+ re(i, r, t);
408
408
  },
409
- ...o
409
+ ...s
410
410
  }
411
411
  );
412
412
  });
413
413
  E.displayName = "BaseButton";
414
414
  /*!
415
- @versini/ui-button v4.0.2
415
+ @versini/ui-button v4.0.4
416
416
  © 2025 gizmette.com
417
417
  */
418
418
  try {
419
419
  window.__VERSINI_UI_BUTTON__ || (window.__VERSINI_UI_BUTTON__ = {
420
- version: "4.0.2",
421
- buildTime: "01/04/2025 01:33 PM EST",
420
+ version: "4.0.4",
421
+ buildTime: "01/06/2025 08:01 PM EST",
422
422
  homepage: "https://github.com/aversini/ui-components",
423
423
  license: "MIT"
424
424
  });
@@ -430,10 +430,10 @@ const R = T.forwardRef(
430
430
  disabled: a = !1,
431
431
  mode: t = "system",
432
432
  focusMode: r = "system",
433
- fullWidth: o = !1,
434
- className: l,
435
- type: c = "button",
436
- raw: d = !1,
433
+ fullWidth: s = !1,
434
+ className: i,
435
+ type: d = "button",
436
+ raw: c = !1,
437
437
  noBorder: n = !1,
438
438
  "aria-label": g,
439
439
  label: b,
@@ -442,31 +442,31 @@ const R = T.forwardRef(
442
442
  labelLeft: v,
443
443
  noBackground: x = !1,
444
444
  align: w = "center",
445
- active: V = !1,
446
- radius: L = "large",
447
- ...M
448
- }, H) => {
449
- const U = ae({
445
+ active: L = !1,
446
+ radius: M = "large",
447
+ ...V
448
+ }, U) => {
449
+ const O = ae({
450
450
  type: B,
451
451
  mode: t,
452
452
  focusMode: r,
453
- fullWidth: o,
453
+ fullWidth: s,
454
454
  disabled: a,
455
- raw: d,
456
- className: l,
455
+ raw: c,
456
+ className: i,
457
457
  noBorder: n,
458
458
  size: m,
459
459
  labelRight: h,
460
460
  labelLeft: v,
461
461
  noBackground: x,
462
462
  align: w,
463
- radius: L
464
- }), O = s({
465
- "text-copy-accent-dark": t === "light" && !d,
466
- "text-copy-light": t === "dark" && !d,
467
- "text-copy-accent-dark dark:text-copy-light": t === "alt-system" && !d,
468
- "text-copy-light dark:text-copy-accent-dark": t === "system" && !d
469
- }), P = V ? s(
463
+ radius: M
464
+ }), P = o({
465
+ "text-copy-accent-dark": t === "light" && !c,
466
+ "text-copy-light": t === "dark" && !c,
467
+ "text-copy-accent-dark dark:text-copy-light": t === "alt-system" && !c,
468
+ "text-copy-light dark:text-copy-accent-dark": t === "system" && !c
469
+ }), j = L ? o(
470
470
  "relative",
471
471
  "focus-within:static",
472
472
  "focus-within:after:border-transparent",
@@ -483,19 +483,19 @@ const R = T.forwardRef(
483
483
  "after:border-table-light dark:after:border-table-dark": t === "alt-system"
484
484
  }
485
485
  ) : "";
486
- return /* @__PURE__ */ i("div", { className: P, children: /* @__PURE__ */ y(
486
+ return /* @__PURE__ */ l("div", { className: j, children: /* @__PURE__ */ y(
487
487
  E,
488
488
  {
489
- ref: H,
490
- className: U,
489
+ ref: U,
490
+ className: O,
491
491
  disabled: a,
492
- type: c,
492
+ type: d,
493
493
  "aria-label": g || b,
494
- ...M,
494
+ ...V,
495
495
  children: [
496
- v && /* @__PURE__ */ i("span", { className: "pr-2", children: v }),
497
- /* @__PURE__ */ i("div", { className: O, children: e }),
498
- h && /* @__PURE__ */ i("span", { className: "pl-2", children: h })
496
+ v && /* @__PURE__ */ l("span", { className: "pr-2", children: v }),
497
+ /* @__PURE__ */ l("div", { className: P, children: e }),
498
+ h && /* @__PURE__ */ l("span", { className: "pl-2", children: h })
499
499
  ]
500
500
  }
501
501
  ) });
@@ -507,50 +507,50 @@ const z = ({
507
507
  fill: a,
508
508
  viewBox: t,
509
509
  className: r,
510
- defaultViewBox: o,
511
- size: l,
512
- title: c,
513
- semantic: d = !1,
510
+ defaultViewBox: s,
511
+ size: i,
512
+ title: d,
513
+ semantic: c = !1,
514
514
  ...n
515
515
  }) => {
516
- const g = s(l, r);
517
- return /* @__PURE__ */ y(j, { children: [
518
- /* @__PURE__ */ i(
516
+ const g = o(i, r);
517
+ return /* @__PURE__ */ y(A, { children: [
518
+ /* @__PURE__ */ l(
519
519
  "svg",
520
520
  {
521
521
  xmlns: "http://www.w3.org/2000/svg",
522
522
  className: g,
523
- viewBox: t || o,
523
+ viewBox: t || s,
524
524
  fill: a || "currentColor",
525
525
  role: "img",
526
- "aria-hidden": !d,
526
+ "aria-hidden": !c,
527
527
  focusable: !1,
528
528
  ...n,
529
529
  children: e
530
530
  }
531
531
  ),
532
- c && d && /* @__PURE__ */ i("span", { className: "sr-only", children: c })
532
+ d && c && /* @__PURE__ */ l("span", { className: "sr-only", children: d })
533
533
  ] });
534
534
  };
535
535
  /*!
536
- @versini/ui-svgicon v4.0.0
536
+ @versini/ui-svgicon v4.0.1
537
537
  © 2025 gizmette.com
538
538
  */
539
539
  try {
540
540
  window.__VERSINI_UI_SVGICON__ || (window.__VERSINI_UI_SVGICON__ = {
541
- version: "4.0.0",
542
- buildTime: "01/04/2025 01:33 PM EST",
541
+ version: "4.0.1",
542
+ buildTime: "01/06/2025 08:00 PM EST",
543
543
  homepage: "https://github.com/aversini/ui-components",
544
544
  license: "MIT"
545
545
  });
546
546
  } catch {
547
547
  }
548
- const oe = ({
548
+ const se = ({
549
549
  className: e,
550
550
  viewBox: a,
551
551
  title: t,
552
552
  monotone: r,
553
- ...o
553
+ ...s
554
554
  }) => /* @__PURE__ */ y(
555
555
  z,
556
556
  {
@@ -559,24 +559,31 @@ const oe = ({
559
559
  viewBox: a,
560
560
  className: e,
561
561
  title: t || "Sort",
562
- ...o,
562
+ ...s,
563
563
  children: [
564
- /* @__PURE__ */ i(
564
+ /* @__PURE__ */ l(
565
565
  "path",
566
566
  {
567
+ className: "fa-secondary",
567
568
  opacity: r ? "1" : "0.4",
568
- d: "M393.4 41.4c12.5-12.5 32.8-12.5 45.3 0l96 96c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L448 141.3V448c0 17.7-14.3 32-32 32s-32-14.3-32-32V141.3l-41.4 41.4c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l96-96z"
569
+ d: "M297.4 137.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L384 141.3 384 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-306.7 41.4 41.4c12.5 12.5 32.8 12.5 45.3 0c6.2-6.2 9.4-14.4 9.4-22.6s-3.1-16.4-9.4-22.6l-96-96C432.4 35.1 424.2 32 416 32s-16.4 3.1-22.6 9.4l-96 96z"
569
570
  }
570
571
  ),
571
- /* @__PURE__ */ i("path", { d: "M137.4 470.6c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 370.7V64c0-17.7-14.3-32-32-32s-32 14.3-32 32V370.7L86.6 329.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96z" })
572
+ /* @__PURE__ */ l(
573
+ "path",
574
+ {
575
+ className: "fa-primary",
576
+ d: "M137.4 470.6c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 370.7 192 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 306.7L86.6 329.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96z"
577
+ }
578
+ )
572
579
  ]
573
580
  }
574
- ), se = ({
581
+ ), oe = ({
575
582
  className: e,
576
583
  viewBox: a,
577
584
  title: t,
578
585
  monotone: r,
579
- ...o
586
+ ...s
580
587
  }) => /* @__PURE__ */ y(
581
588
  z,
582
589
  {
@@ -585,24 +592,31 @@ const oe = ({
585
592
  viewBox: a,
586
593
  className: e,
587
594
  title: t || "Sort Down",
588
- ...o,
595
+ ...s,
589
596
  children: [
590
- /* @__PURE__ */ i(
597
+ /* @__PURE__ */ l(
591
598
  "path",
592
599
  {
600
+ className: "fa-secondary",
593
601
  opacity: r ? "1" : "0.4",
594
- d: "M288 448c0 17.7 14.3 32 32 32h32c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32zm0-128c0 17.7 14.3 32 32 32h96c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32zm0-128c0 17.7 14.3 32 32 32H480c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32zm0-128c0 17.7 14.3 32 32 32H544c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32z"
602
+ d: "M288 64c0-17.7 14.3-32 32-32l224 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L320 96c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32l160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-160 0c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32l32 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-32 0c-17.7 0-32-14.3-32-32z"
595
603
  }
596
604
  ),
597
- /* @__PURE__ */ i("path", { d: "M128 480c9 0 17.5-3.8 23.6-10.4l88-96c11.9-13 11.1-33.3-2-45.2s-33.3-11.1-45.2 2L160 365.7V64c0-17.7-14.3-32-32-32s-32 14.3-32 32V365.7L63.6 330.4c-11.9-13-32.2-13.9-45.2-2s-13.9 32.2-2 45.2l88 96C110.5 476.2 119 480 128 480z" })
605
+ /* @__PURE__ */ l(
606
+ "path",
607
+ {
608
+ className: "fa-primary",
609
+ d: "M128 480c9 0 17.5-3.8 23.6-10.4l88-96c11.9-13 11.1-33.3-2-45.2s-33.3-11.1-45.2 2L160 365.7 160 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 301.7L63.6 330.4c-11.9-13-32.2-13.9-45.2-2s-13.9 32.2-2 45.2l88 96C110.5 476.2 119 480 128 480z"
610
+ }
611
+ )
598
612
  ]
599
613
  }
600
- ), ie = ({
614
+ ), le = ({
601
615
  className: e,
602
616
  viewBox: a,
603
617
  title: t,
604
618
  monotone: r,
605
- ...o
619
+ ...s
606
620
  }) => /* @__PURE__ */ y(
607
621
  z,
608
622
  {
@@ -611,27 +625,34 @@ const oe = ({
611
625
  viewBox: a,
612
626
  className: e,
613
627
  title: t || "Sort Up",
614
- ...o,
628
+ ...s,
615
629
  children: [
616
- /* @__PURE__ */ i(
630
+ /* @__PURE__ */ l(
617
631
  "path",
618
632
  {
633
+ className: "fa-secondary",
619
634
  opacity: r ? "1" : "0.4",
620
- d: "M288 64c0-17.7 14.3-32 32-32h32c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32H480c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32H544c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32z"
635
+ d: "M288 64c0-17.7 14.3-32 32-32l32 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-32 0c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32l160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-160 0c-17.7 0-32-14.3-32-32zm0 128c0-17.7 14.3-32 32-32l224 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-224 0c-17.7 0-32-14.3-32-32z"
621
636
  }
622
637
  ),
623
- /* @__PURE__ */ i("path", { d: "M128 32c9 0 17.5 3.8 23.6 10.4l88 96c11.9 13 11.1 33.3-2 45.2s-33.3 11.1-45.2-2L160 146.3V448c0 17.7-14.3 32-32 32s-32-14.3-32-32V146.3L63.6 181.6c-11.9 13-32.2 13.9-45.2 2s-13.9-32.2-2-45.2l88-96C110.5 35.8 119 32 128 32z" })
638
+ /* @__PURE__ */ l(
639
+ "path",
640
+ {
641
+ className: "fa-primary",
642
+ d: "M128 32c9 0 17.5 3.8 23.6 10.4l88 96c11.9 13 11.1 33.3-2 45.2s-33.3 11.1-45.2-2L160 146.3 160 448c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-301.7L63.6 181.6c-11.9 13-32.2 13.9-45.2 2s-13.9-32.2-2-45.2l88-96C110.5 35.8 119 32 128 32z"
643
+ }
644
+ )
624
645
  ]
625
646
  }
626
647
  );
627
648
  /*!
628
- @versini/ui-icons v4.1.0
649
+ @versini/ui-icons v4.2.1
629
650
  © 2025 gizmette.com
630
651
  */
631
652
  try {
632
653
  window.__VERSINI_UI_ICONS__ || (window.__VERSINI_UI_ICONS__ = {
633
- version: "4.1.0",
634
- buildTime: "01/04/2025 01:33 PM EST",
654
+ version: "4.2.1",
655
+ buildTime: "01/06/2025 08:00 PM EST",
635
656
  homepage: "https://github.com/aversini/ui-components",
636
657
  license: "MIT"
637
658
  });
@@ -648,34 +669,34 @@ const k = T.createContext({
648
669
  mode: a = "system",
649
670
  caption: t,
650
671
  compact: r,
651
- summary: o,
652
- className: l,
653
- wrapperClassName: c,
654
- maxHeight: d,
672
+ summary: s,
673
+ className: i,
674
+ wrapperClassName: d,
675
+ maxHeight: c,
655
676
  stickyHeader: n,
656
677
  stickyFooter: g,
657
678
  ...b
658
679
  }) => {
659
- const m = A({
680
+ const m = W({
660
681
  mode: a,
661
- className: l,
662
- wrapperClassName: c,
682
+ className: i,
683
+ wrapperClassName: d,
663
684
  stickyHeader: n,
664
685
  stickyFooter: g
665
686
  });
666
- return /* @__PURE__ */ i(
687
+ return /* @__PURE__ */ l(
667
688
  k.Provider,
668
689
  {
669
690
  value: { mode: a, stickyHeader: n, stickyFooter: g, compact: r },
670
- children: /* @__PURE__ */ i(
691
+ children: /* @__PURE__ */ l(
671
692
  "div",
672
693
  {
673
694
  className: m.wrapper,
674
- ...d && {
675
- style: { maxHeight: d }
695
+ ...c && {
696
+ style: { maxHeight: c }
676
697
  },
677
- children: /* @__PURE__ */ y("table", { className: m.table, summary: o, ...b, children: [
678
- t && /* @__PURE__ */ i("caption", { className: m.caption, children: t }),
698
+ children: /* @__PURE__ */ y("table", { className: m.table, summary: s, ...b, children: [
699
+ t && /* @__PURE__ */ l("caption", { className: m.caption, children: t }),
679
700
  e
680
701
  ] })
681
702
  }
@@ -689,12 +710,12 @@ const k = T.createContext({
689
710
  }) => {
690
711
  const r = p(k);
691
712
  r.cellWrapper = _;
692
- const o = W({
713
+ const s = D({
693
714
  className: a,
694
715
  mode: r.mode,
695
716
  stickyHeader: r.stickyHeader
696
717
  });
697
- return /* @__PURE__ */ i("thead", { className: o, ...t, children: e });
718
+ return /* @__PURE__ */ l("thead", { className: s, ...t, children: e });
698
719
  }, be = ({
699
720
  children: e,
700
721
  className: a,
@@ -702,77 +723,77 @@ const k = T.createContext({
702
723
  }) => {
703
724
  const r = p(k);
704
725
  r.cellWrapper = C;
705
- const o = D({
726
+ const s = F({
706
727
  className: a,
707
728
  mode: r.mode,
708
729
  stickyFooter: r.stickyFooter
709
730
  });
710
- return /* @__PURE__ */ i("tfoot", { className: o, ...t, children: e });
731
+ return /* @__PURE__ */ l("tfoot", { className: s, ...t, children: e });
711
732
  }, me = ({ children: e, ...a }) => {
712
733
  const t = p(k);
713
- return t.cellWrapper = u, /* @__PURE__ */ i("tbody", { ...a, children: e });
734
+ return t.cellWrapper = u, /* @__PURE__ */ l("tbody", { ...a, children: e });
714
735
  }, ue = ({
715
736
  children: e,
716
737
  className: a,
717
738
  ...t
718
739
  }) => {
719
- const r = p(k), o = F({
740
+ const r = p(k), s = G({
720
741
  mode: r.mode,
721
742
  cellWrapper: r.cellWrapper,
722
743
  className: a
723
744
  });
724
- return /* @__PURE__ */ i("tr", { className: o, ...t, children: e });
725
- }, le = ({
745
+ return /* @__PURE__ */ l("tr", { className: s, ...t, children: e });
746
+ }, ie = ({
726
747
  children: e,
727
748
  component: a,
728
749
  className: t,
729
750
  align: r,
730
- ...o
751
+ ...s
731
752
  }) => {
732
- const l = p(k), c = a || (l.cellWrapper === _ ? "th" : "td"), { mainClasses: d, alignClasses: n } = G({
733
- cellWrapper: l.cellWrapper,
753
+ const i = p(k), d = a || (i.cellWrapper === _ ? "th" : "td"), { mainClasses: c, alignClasses: n } = Y({
754
+ cellWrapper: i.cellWrapper,
734
755
  className: t,
735
- mode: l.mode,
736
- compact: l.compact,
756
+ mode: i.mode,
757
+ compact: i.compact,
737
758
  align: r
738
759
  });
739
- return r ? /* @__PURE__ */ i(c, { className: d, ...o, children: /* @__PURE__ */ i("div", { className: n, children: e }) }) : /* @__PURE__ */ i(c, { className: d, ...o, children: e });
760
+ return r ? /* @__PURE__ */ l(d, { className: c, ...s, children: /* @__PURE__ */ l("div", { className: n, children: e }) }) : /* @__PURE__ */ l(d, { className: c, ...s, children: e });
740
761
  }, ye = ({
741
762
  align: e,
742
763
  children: a,
743
764
  buttonClassName: t,
744
765
  className: r,
745
- component: o,
746
- focusMode: l = "alt-system",
747
- mode: c = "alt-system",
748
- onClick: d,
766
+ component: s,
767
+ focusMode: i = "alt-system",
768
+ mode: d = "alt-system",
769
+ onClick: c,
749
770
  sortDirection: n,
750
771
  sortedCell: g,
751
772
  cellId: b,
752
773
  ...m
753
774
  }) => {
754
- const h = Y({ buttonClassName: t });
755
- return /* @__PURE__ */ i(
756
- le,
775
+ const h = q({ buttonClassName: t });
776
+ return /* @__PURE__ */ l(
777
+ ie,
757
778
  {
758
- component: o,
779
+ component: s,
759
780
  className: r,
760
781
  role: "columnheader",
761
782
  "aria-sort": n === f.ASC && g === b ? "ascending" : n === f.DESC && g === b ? "descending" : "other",
762
783
  ...m,
763
- children: /* @__PURE__ */ i(
784
+ children: /* @__PURE__ */ l(
764
785
  R,
765
786
  {
766
787
  active: g === b,
767
788
  className: h,
768
- onClick: d,
789
+ onClick: c,
769
790
  align: e,
770
791
  noBorder: !0,
771
- focusMode: l,
772
- mode: c,
792
+ focusMode: i,
793
+ mode: d,
773
794
  fullWidth: !0,
774
795
  labelRight: a,
775
- children: n === f.ASC && g === b ? /* @__PURE__ */ i(ie, { className: "size-4", monotone: !0 }) : n === f.DESC && g === b ? /* @__PURE__ */ i(se, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ i(oe, { className: "size-4", monotone: !0 })
796
+ children: n === f.ASC && g === b ? /* @__PURE__ */ l(le, { className: "size-4", monotone: !0 }) : n === f.DESC && g === b ? /* @__PURE__ */ l(oe, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ l(se, { className: "size-4", monotone: !0 })
776
797
  }
777
798
  )
778
799
  }
@@ -781,7 +802,7 @@ const k = T.createContext({
781
802
  export {
782
803
  ge as Table,
783
804
  me as TableBody,
784
- le as TableCell,
805
+ ie as TableCell,
785
806
  ye as TableCellSort,
786
807
  f as TableCellSortDirections,
787
808
  be as TableFooter,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@versini/ui-table",
3
- "version": "3.0.3",
3
+ "version": "3.0.5",
4
4
  "license": "MIT",
5
5
  "author": "Arno Versini",
6
6
  "publishConfig": {
@@ -37,16 +37,18 @@
37
37
  "react": "^18.3.1 || ^19.0.0",
38
38
  "react-dom": "^18.3.1 || ^19.0.0"
39
39
  },
40
+ "devDependencies": {
41
+ "@versini/ui-types": "4.0.0"
42
+ },
40
43
  "dependencies": {
41
44
  "@tailwindcss/typography": "0.5.15",
42
- "@versini/ui-button": "4.0.2",
43
- "@versini/ui-icons": "4.1.0",
44
- "@versini/ui-types": "4.0.0",
45
+ "@versini/ui-button": "4.0.4",
46
+ "@versini/ui-icons": "4.2.1",
45
47
  "clsx": "2.1.1",
46
48
  "tailwindcss": "3.4.17"
47
49
  },
48
50
  "sideEffects": [
49
51
  "**/*.css"
50
52
  ],
51
- "gitHead": "bf6b0d285a70c47a5efc225f32756b95cb963a49"
53
+ "gitHead": "0769d7ea2b70f5ea7b50f587faf90a079d33f9b9"
52
54
  }