@versini/ui-table 4.0.5 → 4.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.
@@ -1,21 +1,21 @@
1
- import l from "clsx";
2
- import { jsx as i, jsxs as _, Fragment as se } from "react/jsx-runtime";
3
- import R, { useRef as w, useLayoutEffect as D, useState as le, useMemo as q, useEffect as G, useCallback as oe, useContext as N } from "react";
4
- const I = "thead", A = "tfoot", p = "tbody", T = {
1
+ import s from "clsx";
2
+ import { jsx as i, jsxs as N, Fragment as ne } from "react/jsx-runtime";
3
+ import S, { useRef as w, useLayoutEffect as G, useEffect as U, useState as ce, useMemo as J, useCallback as de, useContext as B } from "react";
4
+ const z = "thead", W = "tfoot", x = "tbody", R = {
5
5
  ASC: "asc",
6
6
  DESC: "desc"
7
- }, ie = ({
7
+ }, ge = ({
8
8
  mode: e,
9
- className: a,
9
+ className: r,
10
10
  wrapperClassName: t,
11
- stickyHeader: r,
12
- stickyFooter: s
11
+ stickyHeader: a,
12
+ stickyFooter: l
13
13
  }) => ({
14
- wrapper: l(
14
+ wrapper: s(
15
15
  "not-prose relative w-full rounded-lg shadow-md",
16
16
  {
17
- "overflow-x-auto": !r && !s,
18
- "overflow-y-scroll": r || s,
17
+ "overflow-x-auto": !a && !l,
18
+ "overflow-y-scroll": a || l,
19
19
  "bg-surface-darker": e === "dark" || e === "system",
20
20
  "bg-surface-light": e === "light" || e === "alt-system",
21
21
  "dark:bg-surface-light": e === "system",
@@ -27,212 +27,212 @@ const I = "thead", A = "tfoot", p = "tbody", T = {
27
27
  },
28
28
  t
29
29
  ),
30
- table: l("my-0 w-full text-left text-sm", a, {
30
+ table: s("my-0 w-full text-left text-sm", r, {
31
31
  "text-copy-light": e === "dark",
32
32
  "text-copy-dark": e === "light",
33
33
  "text-copy-light dark:text-copy-dark": e === "system",
34
34
  "text-copy-dark dark:text-copy-light": e === "alt-system"
35
35
  }),
36
- caption: l("py-2 text-sm font-bold", {
36
+ caption: s("py-2 text-sm font-bold", {
37
37
  "text-copy-light": e === "dark",
38
38
  "text-copy-dark": e === "light",
39
39
  "text-copy-light dark:text-copy-dark": e === "system",
40
40
  "text-copy-dark dark:text-copy-light": e === "alt-system"
41
41
  })
42
- }), ne = ({
42
+ }), he = ({
43
43
  className: e,
44
- stickyHeader: a,
44
+ stickyHeader: r,
45
45
  mode: t
46
- }) => l(
46
+ }) => s(
47
47
  {
48
- "sticky top-0 z-10": a,
49
- "shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem]": a && t === "dark",
50
- "shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem] dark:shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem]": a && t === "system",
51
- "shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem]": a && t === "light",
52
- "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"
48
+ "sticky top-0 z-10": r,
49
+ "shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem]": r && t === "dark",
50
+ "shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem] dark:shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem]": r && t === "system",
51
+ "shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem]": r && t === "light",
52
+ "shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem] dark:shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem]": r && t === "alt-system"
53
53
  },
54
54
  e
55
- ), ce = ({
55
+ ), be = ({
56
56
  className: e,
57
- stickyFooter: a,
57
+ stickyFooter: r,
58
58
  mode: t
59
- }) => l(
59
+ }) => s(
60
60
  {
61
- "sticky bottom-0 z-10": a,
62
- "shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem]": a && t === "dark",
63
- "shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem] dark:shadow-[rgb(65_65_65_/30%)_0_-0.5rem_1rem]": a && t === "system",
64
- "shadow-[rgb(65_65_65_/30%)_0_-0.5rem_1rem]": a && t === "light",
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"
61
+ "sticky bottom-0 z-10": r,
62
+ "shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem]": r && t === "dark",
63
+ "shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem] dark:shadow-[rgb(65_65_65_/30%)_0_-0.5rem_1rem]": r && t === "system",
64
+ "shadow-[rgb(65_65_65_/30%)_0_-0.5rem_1rem]": r && t === "light",
65
+ "shadow-[rgb(65_65_65_/30%)_-0_0.5rem_1rem] dark:shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem]": r && t === "alt-system"
66
66
  },
67
67
  e
68
- ), de = ({
68
+ ), ue = ({
69
69
  mode: e,
70
- className: a,
70
+ className: r,
71
71
  cellWrapper: t
72
- }) => t === I || t === A ? l(
72
+ }) => t === z || t === W ? s(
73
73
  {
74
74
  "bg-table-head-dark": e === "dark" || e === "system",
75
75
  "bg-table-head-light": e === "light" || e === "alt-system",
76
76
  "dark:bg-table-head-light": e === "system",
77
77
  "dark:bg-table-head-dark": e === "alt-system"
78
78
  },
79
- a
80
- ) : l(
79
+ r
80
+ ) : s(
81
81
  "border-b last:border-0",
82
82
  {
83
83
  "border-table-dark": e === "dark" || e === "system",
84
- "odd:bg-table-dark-odd even:bg-table-dark-even": t === p && e === "dark",
84
+ "odd:bg-table-dark-odd even:bg-table-dark-even": t === x && e === "dark",
85
85
  "border-table-light": e === "light" || e === "alt-system",
86
- "odd:bg-table-light-odd even:bg-table-light-even": t === p && e === "light",
86
+ "odd:bg-table-light-odd even:bg-table-light-even": t === x && e === "light",
87
87
  "dark:border-table-light": e === "system",
88
- "odd:bg-table-dark-odd even:bg-table-dark-even dark:odd:bg-table-light-odd dark:even:bg-table-light-even": t === p && e === "system",
88
+ "odd:bg-table-dark-odd even:bg-table-dark-even dark:odd:bg-table-light-odd dark:even:bg-table-light-even": t === x && e === "system",
89
89
  "dark:border-table-dark": e === "alt-system",
90
- "odd:bg-table-light-odd even:bg-table-light-even dark:odd:bg-table-dark-odd dark:even:bg-table-dark-even": t === p && e === "alt-system"
90
+ "odd:bg-table-light-odd even:bg-table-light-even dark:odd:bg-table-dark-odd dark:even:bg-table-dark-even": t === x && e === "alt-system"
91
91
  },
92
- a
93
- ), ge = ({
92
+ r
93
+ ), me = ({
94
94
  cellWrapper: e,
95
- className: a,
95
+ className: r,
96
96
  compact: t,
97
- mode: r,
98
- align: s
97
+ mode: a,
98
+ align: l
99
99
  }) => ({
100
- alignClasses: l({
101
- "flex justify-start text-left": s === "left",
102
- "flex justify-center text-center": s === "center",
103
- "flex justify-end text-right": s === "right"
100
+ alignClasses: s({
101
+ "flex justify-start text-left": l === "left",
102
+ "flex justify-center text-center": l === "center",
103
+ "flex justify-end text-right": l === "right"
104
104
  }),
105
- mainClasses: l(
105
+ mainClasses: s(
106
106
  {
107
- "text-copy-light": r === "dark" || r === "system",
108
- "text-copy-dark": r === "light" || r === "alt-system",
109
- "dark:text-copy-dark": r === "system",
110
- "dark:text-copy-light": r === "alt-system",
111
- "px-4 py-3": !t && (e === I || e === A),
112
- "p-4": !t && e === p,
107
+ "text-copy-light": a === "dark" || a === "system",
108
+ "text-copy-dark": a === "light" || a === "alt-system",
109
+ "dark:text-copy-dark": a === "system",
110
+ "dark:text-copy-light": a === "alt-system",
111
+ "px-4 py-3": !t && (e === z || e === W),
112
+ "p-4": !t && e === x,
113
113
  "px-2 py-1.5": t
114
114
  },
115
- a
115
+ r
116
116
  )
117
- }), he = ({
117
+ }), ye = ({
118
118
  buttonClassName: e
119
- }) => l("rounded-none text-sm", e), F = "av-button", j = "icon", $ = "button", O = "link", be = ({
119
+ }) => s("rounded-none text-sm", e), q = "av-button", D = "icon", K = "button", P = "link", fe = ({
120
120
  type: e,
121
- size: a,
121
+ size: r,
122
122
  labelRight: t,
123
- labelLeft: r,
124
- align: s,
123
+ labelLeft: a,
124
+ align: l,
125
125
  animated: o
126
126
  }) => {
127
127
  const n = "max-h-8 py-0 px-2", d = "max-h-9 h-8 px-3", c = "max-h-12 py-2 px-4";
128
128
  switch (e) {
129
- case $:
130
- case O:
131
- return l({
132
- [n]: a === "small",
133
- [d]: a === "medium",
134
- [c]: a === "large"
129
+ case K:
130
+ case P:
131
+ return s({
132
+ [n]: r === "small",
133
+ [d]: r === "medium",
134
+ [c]: r === "large"
135
135
  });
136
- case j:
137
- return l("flex items-center", {
138
- "justify-center": s === "center",
139
- "justify-start": s === "left",
140
- "justify-end": s === "right",
141
- "h-6 w-6 p-0": a === "small" && !o && !(t || r),
142
- "h-6 px-2": a === "small" && !o && (t || r),
143
- "h-8 w-8 p-1": a === "medium" && !o && !(t || r),
144
- "h-8 px-3": a === "medium" && !o && (t || r),
145
- "h-12 w-12 p-2": a === "large" && !o && !(t || r),
146
- "h-12 px-4": a === "large" && !o && (t || r),
147
- "h-6 py-0": a === "small" && o && !(t || r),
148
- "h-6": a === "small" && o && (t || r),
149
- "h-8 py-1": a === "medium" && o && !(t || r),
150
- "h-8": a === "medium" && o && (t || r),
151
- "h-12 py-2": a === "large" && o && !(t || r),
152
- "h-12": a === "large" && o && (t || r)
136
+ case D:
137
+ return s("flex items-center", {
138
+ "justify-center": l === "center",
139
+ "justify-start": l === "left",
140
+ "justify-end": l === "right",
141
+ "h-6 w-6 p-0": r === "small" && !o && !(t || a),
142
+ "h-6 px-2": r === "small" && !o && (t || a),
143
+ "h-8 w-8 p-1": r === "medium" && !o && !(t || a),
144
+ "h-8 px-3": r === "medium" && !o && (t || a),
145
+ "h-12 w-12 p-2": r === "large" && !o && !(t || a),
146
+ "h-12 px-4": r === "large" && !o && (t || a),
147
+ "h-6 py-0": r === "small" && o && !(t || a),
148
+ "h-6": r === "small" && o && (t || a),
149
+ "h-8 py-1": r === "medium" && o && !(t || a),
150
+ "h-8": r === "medium" && o && (t || a),
151
+ "h-12 py-2": r === "large" && o && !(t || a),
152
+ "h-12": r === "large" && o && (t || a)
153
153
  });
154
154
  }
155
- }, me = ({
155
+ }, ke = ({
156
156
  type: e,
157
- size: a,
157
+ size: r,
158
158
  labelRight: t,
159
- labelLeft: r
159
+ labelLeft: a
160
160
  }) => {
161
- const s = "text-sm font-medium", o = "text-base font-medium", n = "text-lg font-medium";
161
+ const l = "text-sm font-medium", o = "text-base font-medium", n = "text-lg font-medium";
162
162
  switch (e) {
163
- case $:
164
- case O:
165
- return l({
166
- "text-center": e === O,
167
- [s]: a === "small",
168
- [o]: a === "medium",
169
- [n]: a === "large"
163
+ case K:
164
+ case P:
165
+ return s({
166
+ "text-center": e === P,
167
+ [l]: r === "small",
168
+ [o]: r === "medium",
169
+ [n]: r === "large"
170
170
  });
171
- case j:
172
- return l({
173
- [s]: a === "small" && (t || r),
174
- [o]: a === "medium" && (t || r),
175
- [n]: a === "large" && (t || r)
171
+ case D:
172
+ return s({
173
+ [l]: r === "small" && (t || a),
174
+ [o]: r === "medium" && (t || a),
175
+ [n]: r === "large" && (t || a)
176
176
  });
177
177
  }
178
- }, ue = ({
178
+ }, ve = ({
179
179
  mode: e,
180
- noBackground: a,
180
+ noBackground: r,
181
181
  truncate: t,
182
- variant: r
182
+ variant: a
183
183
  }) => {
184
- if (a)
184
+ if (r)
185
185
  return "not-prose";
186
- if (r === "primary")
187
- return l("not-prose", {
186
+ if (a === "primary")
187
+ return s("not-prose", {
188
188
  truncate: t,
189
189
  "text-copy-light": e === "dark" || e === "system",
190
190
  "text-copy-lighter": e === "light" || e === "alt-system",
191
191
  "dark:text-copy-lighter": e === "system",
192
192
  "dark:text-copy-light": e === "alt-system"
193
193
  });
194
- if (r === "secondary")
195
- return l("not-prose", {
194
+ if (a === "secondary")
195
+ return s("not-prose", {
196
196
  truncate: t,
197
197
  "text-copy-light": e === "light" || e === "system",
198
198
  "text-copy-lighter": e === "dark" || e === "alt-system",
199
199
  "dark:text-copy-lighter": e === "alt-system",
200
200
  "dark:text-copy-light": e === "system"
201
201
  });
202
- if (r === "danger")
203
- return l("not-prose", {
202
+ if (a === "danger")
203
+ return s("not-prose", {
204
204
  truncate: t,
205
205
  "text-copy-light": e === "dark" || e === "system",
206
206
  "text-copy-lighter": e === "light" || e === "alt-system",
207
207
  "dark:text-copy-lighter": e === "system",
208
208
  "dark:text-copy-light": e === "alt-system"
209
209
  });
210
- if (r === "selected")
211
- return l("not-prose text-copy-lighter", {
210
+ if (a === "selected")
211
+ return s("not-prose text-copy-lighter", {
212
212
  truncate: t
213
213
  });
214
- }, ye = ({
214
+ }, pe = ({
215
215
  mode: e,
216
- noBackground: a,
216
+ noBackground: r,
217
217
  variant: t
218
218
  }) => {
219
- if (!a) {
219
+ if (!r) {
220
220
  if (t === "primary")
221
- return l({
221
+ return s({
222
222
  "bg-action-dark": e === "dark",
223
223
  "bg-action-light": e === "light",
224
224
  "bg-action-dark dark:bg-action-light": e === "system",
225
225
  "bg-action-light dark:bg-action-dark": e === "alt-system"
226
226
  });
227
227
  if (t === "secondary")
228
- return l({
228
+ return s({
229
229
  "bg-action-dark": e === "light",
230
230
  "bg-action-light": e === "dark",
231
231
  "bg-action-dark dark:bg-action-light": e === "alt-system",
232
232
  "bg-action-light dark:bg-action-dark": e === "system"
233
233
  });
234
234
  if (t === "danger")
235
- return l({
235
+ return s({
236
236
  "bg-action-danger-dark": e === "dark",
237
237
  "bg-action-danger-light": e === "light",
238
238
  "bg-action-danger-dark dark:bg-action-danger-light": e === "system",
@@ -241,35 +241,35 @@ const I = "thead", A = "tfoot", p = "tbody", T = {
241
241
  if (t === "selected")
242
242
  return "bg-action-selected-dark";
243
243
  }
244
- }, ke = ({
244
+ }, _e = ({
245
245
  radius: e
246
- }) => l({
246
+ }) => s({
247
247
  "rounded-full": e === "large",
248
248
  "rounded-md": e === "medium",
249
249
  "rounded-xs": e === "small"
250
- }), fe = ({
250
+ }), xe = ({
251
251
  mode: e,
252
- disabled: a,
252
+ disabled: r,
253
253
  variant: t
254
254
  }) => {
255
- if (a)
255
+ if (r)
256
256
  return "";
257
257
  if (t === "primary")
258
- return l("hover:text-copy-light-hover", {
258
+ return s("hover:text-copy-light-hover", {
259
259
  "hover:bg-action-dark-hover": e === "dark",
260
260
  "hover:bg-action-light-hover": e === "light",
261
261
  "hover:bg-action-dark-hover dark:hover:bg-action-light-hover": e === "system",
262
262
  "hover:bg-action-light-hover dark:hover:bg-action-dark-hover": e === "alt-system"
263
263
  });
264
264
  if (t === "secondary")
265
- return l("hover:text-copy-light-hover", {
265
+ return s("hover:text-copy-light-hover", {
266
266
  "hover:bg-action-dark-hover": e === "light",
267
267
  "hover:bg-action-light-hover": e === "dark",
268
268
  "hover:bg-action-dark-hover dark:hover:bg-action-light-hover": e === "alt-system",
269
269
  "hover:bg-action-light-hover dark:hover:bg-action-dark-hover": e === "system"
270
270
  });
271
271
  if (t === "danger")
272
- return l("hover:text-copy-light-hover", {
272
+ return s("hover:text-copy-light-hover", {
273
273
  "hover:bg-action-danger-dark-hover": e === "dark",
274
274
  "hover:bg-action-danger-light-hover": e === "light",
275
275
  "hover:bg-action-danger-dark-hover dark:hover:bg-action-danger-light-hover": e === "system",
@@ -277,29 +277,29 @@ const I = "thead", A = "tfoot", p = "tbody", T = {
277
277
  });
278
278
  if (t === "selected")
279
279
  return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
280
- }, ve = ({
280
+ }, we = ({
281
281
  mode: e,
282
- disabled: a,
282
+ disabled: r,
283
283
  variant: t
284
284
  }) => {
285
- if (a)
285
+ if (r)
286
286
  return "";
287
287
  if (t === "primary")
288
- return l("active:text-copy-light-active", {
288
+ return s("active:text-copy-light-active", {
289
289
  "active:bg-action-dark-active": e === "dark",
290
290
  "active:bg-action-light-active": e === "light",
291
291
  "active:bg-action-dark-active dark:active:bg-action-light-active": e === "system",
292
292
  "active:bg-action-light-active dark:active:bg-action-dark-active": e === "alt-system"
293
293
  });
294
294
  if (t === "secondary")
295
- return l("active:text-copy-light-active", {
295
+ return s("active:text-copy-light-active", {
296
296
  "active:bg-action-dark-active": e === "light",
297
297
  "active:bg-action-light-active": e === "dark",
298
298
  "active:bg-action-dark-active dark:active:bg-action-light-active": e === "alt-system",
299
299
  "active:bg-action-light-active dark:active:bg-action-dark-active": e === "system"
300
300
  });
301
301
  if (t === "danger")
302
- return l("active:text-copy-lighter-active", {
302
+ return s("active:text-copy-lighter-active", {
303
303
  "active:bg-action-danger-dark-active": e === "dark",
304
304
  "active:bg-action-danger-light-active": e === "light",
305
305
  "active:bg-action-danger-dark-active dark:active:bg-action-danger-light-active": e === "system",
@@ -307,29 +307,29 @@ const I = "thead", A = "tfoot", p = "tbody", T = {
307
307
  });
308
308
  if (t === "selected")
309
309
  return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
310
- }, pe = ({
310
+ }, Ne = ({
311
311
  mode: e,
312
- noBorder: a,
312
+ noBorder: r,
313
313
  variant: t
314
314
  }) => {
315
- if (a)
315
+ if (r)
316
316
  return "border border-transparent";
317
317
  if (t === "primary")
318
- return l("border", {
318
+ return s("border", {
319
319
  "border-border-dark": e === "dark",
320
320
  "border-border-accent": e === "light",
321
321
  "border-border-dark dark:border-border-accent": e === "system",
322
322
  "border-border-accent dark:border-border-dark": e === "alt-system"
323
323
  });
324
324
  if (t === "secondary")
325
- return l("border", {
325
+ return s("border", {
326
326
  "border-border-dark": e === "light",
327
327
  "border-border-accent": e === "dark",
328
328
  "border-border-dark dark:border-border-accent": e === "alt-system",
329
329
  "border-border-accent dark:border-border-dark": e === "system"
330
330
  });
331
331
  if (t === "danger")
332
- return l("border", {
332
+ return s("border", {
333
333
  "border-border-danger-dark": e === "dark",
334
334
  "border-border-danger-medium": e === "light",
335
335
  "border-border-danger-dark dark:border-border-danger-medium": e === "system",
@@ -337,18 +337,18 @@ const I = "thead", A = "tfoot", p = "tbody", T = {
337
337
  });
338
338
  if (t === "selected")
339
339
  return "border border-border-selected-dark";
340
- }, _e = ({
340
+ }, Ce = ({
341
341
  focusMode: e
342
- }) => l("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
342
+ }) => s("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
343
343
  "focus:outline-focus-dark": e === "dark",
344
344
  "focus:outline-focus-light": e === "light",
345
345
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
346
346
  "focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
347
- }), xe = ({
347
+ }), Be = ({
348
348
  mode: e,
349
- raw: a,
349
+ raw: r,
350
350
  iconClassName: t
351
- }) => a ? "" : l(
351
+ }) => r ? "" : s(
352
352
  {
353
353
  "text-copy-accent-dark": e === "light" || e === "alt-system",
354
354
  "text-copy-light": e === "dark" || e === "system",
@@ -356,91 +356,91 @@ const I = "thead", A = "tfoot", p = "tbody", T = {
356
356
  "dark:text-copy-accent-dark": e === "system"
357
357
  },
358
358
  t
359
- ), we = ({
359
+ ), Te = ({
360
360
  animated: e
361
- }) => l({
362
- "transition-opacity duration-300 ease-in": e
363
- }), Ne = ({
361
+ }) => s({
362
+ "transition-opacity duration-300 ease-in-out": e
363
+ }), Ie = ({
364
364
  type: e,
365
- className: a,
365
+ className: r,
366
366
  raw: t,
367
- mode: r,
368
- focusMode: s,
367
+ mode: a,
368
+ focusMode: l,
369
369
  disabled: o,
370
370
  fullWidth: n,
371
371
  size: d,
372
372
  noBorder: c,
373
- labelRight: g,
374
- labelLeft: m,
375
- noBackground: h,
373
+ labelRight: h,
374
+ labelLeft: u,
375
+ noBackground: g,
376
376
  variant: b,
377
- truncate: y,
378
- align: E,
379
- radius: S,
380
- animated: C
381
- }) => (b || (b = "primary"), t ? l(F, a) : l(
382
- F,
383
- ue({
384
- mode: r,
377
+ truncate: v,
378
+ align: L,
379
+ radius: M,
380
+ animated: T
381
+ }) => (b || (b = "primary"), t ? s(q, r) : s(
382
+ q,
383
+ ve({
384
+ mode: a,
385
385
  variant: b,
386
- noBackground: h,
387
- truncate: y
386
+ noBackground: g,
387
+ truncate: v
388
388
  }),
389
- ye({ mode: r, noBackground: h, variant: b }),
390
- ke({ radius: S }),
391
- be({
389
+ pe({ mode: a, noBackground: g, variant: b }),
390
+ _e({ radius: M }),
391
+ fe({
392
392
  type: e,
393
393
  size: d,
394
- labelRight: g,
395
- labelLeft: m,
396
- align: E,
397
- animated: C
394
+ labelRight: h,
395
+ labelLeft: u,
396
+ align: L,
397
+ animated: T
398
398
  }),
399
- me({ type: e, size: d, labelRight: g, labelLeft: m }),
400
- pe({ mode: r, variant: b, noBorder: c }),
401
- _e({ focusMode: s }),
402
- fe({ mode: r, variant: b, disabled: o }),
403
- ve({ mode: r, variant: b, disabled: o }),
399
+ ke({ type: e, size: d, labelRight: h, labelLeft: u }),
400
+ Ne({ mode: a, variant: b, noBorder: c }),
401
+ Ce({ focusMode: l }),
402
+ xe({ mode: a, variant: b, disabled: o }),
403
+ we({ mode: a, variant: b, disabled: o }),
404
404
  {
405
405
  "w-full": n,
406
406
  "disabled:cursor-not-allowed disabled:opacity-50": o
407
407
  },
408
- l({
409
- "transition-[width] duration-300 ease-in-out": C
408
+ s({
409
+ "transition-[width] duration-300 ease-in": T
410
410
  }),
411
- a
412
- )), Ce = (e, a, t) => {
413
- var r;
414
- !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);
415
- }, X = R.forwardRef((e, a) => {
416
- const { onClick: t, noInternalClick: r = !1, ...s } = e;
411
+ r
412
+ )), Re = (e, r, t) => {
413
+ var a;
414
+ !r && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof t == "function" && t(e);
415
+ }, Q = S.forwardRef((e, r) => {
416
+ const { onClick: t, noInternalClick: a = !1, ...l } = e;
417
417
  return /* @__PURE__ */ i(
418
418
  "button",
419
419
  {
420
- ref: a,
420
+ ref: r,
421
421
  onClick: (o) => {
422
- Ce(o, r, t);
422
+ Re(o, a, t);
423
423
  },
424
- ...s
424
+ ...l
425
425
  }
426
426
  );
427
427
  });
428
- X.displayName = "BaseButton";
429
- function Be() {
428
+ Q.displayName = "BaseButton";
429
+ function Ee() {
430
430
  const e = w(!1);
431
- return G(() => (e.current = !0, () => {
431
+ return U(() => (e.current = !0, () => {
432
432
  e.current = !1;
433
- }), []), oe(() => e.current, []);
433
+ }), []), de(() => e.current, []);
434
434
  }
435
- function Te(e) {
436
- return q(() => e.every((a) => a == null) ? () => {
437
- } : (a) => {
435
+ function Se(e) {
436
+ return J(() => e.every((r) => r == null) ? () => {
437
+ } : (r) => {
438
438
  e.forEach((t) => {
439
- typeof t == "function" ? t(a) : t != null && (t.current = a);
439
+ typeof t == "function" ? t(r) : t != null && (t.current = r);
440
440
  });
441
- }, e);
441
+ }, [...e]);
442
442
  }
443
- const Re = {
443
+ const ze = {
444
444
  x: 0,
445
445
  y: 0,
446
446
  width: 0,
@@ -450,148 +450,166 @@ const Re = {
450
450
  bottom: 0,
451
451
  right: 0
452
452
  };
453
- function L(e) {
454
- const a = Be(), t = w(0), r = w(null), [s, o] = le(Re), n = q(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((d) => {
453
+ function A(e) {
454
+ const r = Ee(), t = w(0), a = w(null), [l, o] = ce(ze), n = J(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((d) => {
455
455
  const c = d[0];
456
456
  c && (cancelAnimationFrame(t.current), t.current = requestAnimationFrame(() => {
457
- r.current && a() && o(c.contentRect);
457
+ a.current && r() && o(c.contentRect);
458
458
  }));
459
- }), [a]);
460
- return G(() => (r.current && (n == null || n.observe(r.current, e)), () => {
459
+ }), [r]);
460
+ return U(() => (a.current && (n == null || n.observe(a.current, e)), () => {
461
461
  n == null || n.disconnect(), t.current && cancelAnimationFrame(t.current);
462
- }), [n, e]), [r, s];
462
+ }), [n, e]), [a, l];
463
463
  }
464
- const Ie = {
464
+ const E = {
465
465
  small: 24,
466
466
  // w-6
467
467
  medium: 32,
468
468
  // w-8
469
469
  large: 48
470
470
  // w-12
471
- }, Ee = {
471
+ }, Le = {
472
472
  small: 8 * 2,
473
473
  // px-2 x 2
474
474
  medium: 12 * 2,
475
475
  // px-3 x 2
476
476
  large: 16 * 2
477
477
  // px-4 x 2
478
- }, Se = 2, Y = R.forwardRef(
478
+ }, Me = 2, Ve = 300, X = S.forwardRef(
479
479
  ({
480
480
  children: e,
481
- disabled: a = !1,
481
+ disabled: r = !1,
482
482
  mode: t = "system",
483
- focusMode: r = "system",
484
- fullWidth: s = !1,
483
+ focusMode: a = "system",
484
+ fullWidth: l = !1,
485
485
  className: o,
486
486
  type: n = "button",
487
487
  raw: d = !1,
488
488
  noBorder: c = !1,
489
- "aria-label": g,
490
- label: m,
491
- size: h = "medium",
489
+ "aria-label": h,
490
+ label: u,
491
+ size: g = "medium",
492
492
  labelRight: b,
493
- labelLeft: y,
494
- noBackground: E = !1,
495
- align: S = "center",
496
- radius: C = "large",
497
- variant: J = "primary",
498
- iconClassName: K,
499
- animated: k = !1,
500
- ...Q
501
- }, ee) => {
502
- const te = Ne({
503
- type: j,
493
+ labelLeft: v,
494
+ noBackground: L = !1,
495
+ align: M = "center",
496
+ radius: T = "large",
497
+ variant: ee = "primary",
498
+ iconClassName: te,
499
+ animated: f = !1,
500
+ ...re
501
+ }, ae) => {
502
+ const le = Ie({
503
+ type: D,
504
504
  mode: t,
505
- focusMode: r,
506
- fullWidth: s,
507
- disabled: a,
505
+ focusMode: a,
506
+ fullWidth: l,
507
+ disabled: r,
508
508
  raw: d,
509
509
  className: o,
510
510
  noBorder: c,
511
- size: h,
511
+ size: g,
512
512
  labelRight: b,
513
- labelLeft: y,
514
- noBackground: E,
515
- align: S,
516
- radius: C,
517
- variant: J,
518
- animated: k
519
- }), ae = xe({ mode: t, raw: d, iconClassName: K }), U = we({ animated: k }), [u, z] = L(), [f, V] = L(), [B, W] = L(), M = w(0), v = w(null), re = Te([ee, v]);
520
- return D(() => {
521
- B && B.current && k && (M.current = W.width + Ee[h] + (c ? 0 : Se));
522
- }, [W, B, h, c, k]), D(() => {
523
- v && v.current && k && (b && u && z.width > 0 ? (u.current && (u.current.style.opacity = "100"), v.current.style.width = `${z.width + M.current}px`) : y && V.width > 0 ? (f.current && (f.current.style.opacity = "100"), v.current.style.width = `${V.width + M.current}px`) : (u.current && (u.current.style.opacity = "0"), f.current && (f.current.style.opacity = "0"), v.current.style.width = `${Ie[h]}px`));
513
+ labelLeft: v,
514
+ noBackground: L,
515
+ align: M,
516
+ radius: T,
517
+ variant: ee,
518
+ animated: f
519
+ }), se = Be({ mode: t, raw: d, iconClassName: te }), $ = Te({ animated: f }), oe = "flex items-center justify-center relative w-full h-full overflow-hidden", [m, V] = A(), [y, O] = A(), [I, F] = A(), j = w(0), k = w(null), p = w(null), ie = Se([ae, k]);
520
+ return G(() => {
521
+ I && I.current && f && (j.current = F.width + Le[g] + (c ? 0 : Me), k.current && !k.current.style.width && (k.current.style.width = `${E[g]}px`));
522
+ }, [F, I, g, c, f]), G(() => {
523
+ if (k && k.current && f) {
524
+ let _ = E[g];
525
+ b && m && V.width > 0 ? _ = V.width + j.current : v && y && O.width > 0 && (_ = O.width + j.current), p.current && clearTimeout(p.current), _ !== parseInt(k.current.style.width || "0", 10) && (m.current && (m.current.style.opacity = "0"), y.current && (y.current.style.opacity = "0"), k.current.style.width = `${_}px`, _ > E[g] && (p.current = setTimeout(() => {
526
+ m.current && b && (m.current.style.opacity = "1"), y.current && v && (y.current.style.opacity = "1"), p.current = null;
527
+ }, Ve * 0.8))), _ === E[g] && (m.current && (m.current.style.opacity = "0"), y.current && (y.current.style.opacity = "0"));
528
+ }
524
529
  }, [
525
- z,
526
- b,
527
- u,
528
530
  V,
531
+ b,
532
+ m,
533
+ O,
534
+ v,
529
535
  y,
530
- f,
531
- h,
532
- k
533
- ]), /* @__PURE__ */ _(
534
- X,
536
+ g,
537
+ f
538
+ ]), U(() => () => {
539
+ p.current && clearTimeout(p.current);
540
+ }, []), /* @__PURE__ */ i(
541
+ Q,
535
542
  {
536
- ref: re,
537
- className: te,
538
- disabled: a,
543
+ ref: ie,
544
+ className: le,
545
+ disabled: r,
539
546
  type: n,
540
- "aria-label": g || m,
541
- ...Q,
542
- children: [
547
+ "aria-label": h || u,
548
+ ...re,
549
+ children: /* @__PURE__ */ N("div", { className: oe, children: [
543
550
  /* @__PURE__ */ i(
544
- H,
551
+ Y,
545
552
  {
546
- label: y,
547
- labelRef: f,
548
- labelClass: U,
549
- labelInnerClass: "pr-2"
553
+ label: v,
554
+ labelRef: y,
555
+ labelClass: $,
556
+ labelInnerClass: "pr-2",
557
+ initiallyHidden: f
550
558
  }
551
559
  ),
552
- /* @__PURE__ */ i("span", { ref: B, className: ae, children: e }),
560
+ /* @__PURE__ */ i("span", { ref: I, className: se, children: e }),
553
561
  /* @__PURE__ */ i(
554
- H,
562
+ Y,
555
563
  {
556
564
  label: b,
557
- labelRef: u,
558
- labelClass: U,
559
- labelInnerClass: "pl-2"
565
+ labelRef: m,
566
+ labelClass: $,
567
+ labelInnerClass: "pl-2",
568
+ initiallyHidden: f
560
569
  }
561
570
  )
562
- ]
571
+ ] })
563
572
  }
564
573
  );
565
574
  }
566
- ), H = ({
575
+ ), Y = ({
567
576
  labelRef: e,
568
- labelClass: a,
577
+ labelClass: r,
569
578
  label: t,
570
- labelInnerClass: r
571
- }) => /* @__PURE__ */ i("span", { ref: e, className: a, children: t && /* @__PURE__ */ i("span", { className: r, children: t }) });
572
- Y.displayName = "ButtonIcon";
579
+ labelInnerClass: a,
580
+ initiallyHidden: l = !1
581
+ }) => /* @__PURE__ */ i(
582
+ "span",
583
+ {
584
+ ref: e,
585
+ className: r,
586
+ style: l ? { opacity: 0 } : void 0,
587
+ children: t && /* @__PURE__ */ i("span", { className: a, children: t })
588
+ }
589
+ );
590
+ X.displayName = "ButtonIcon";
573
591
  /*!
574
- @versini/ui-button v6.0.5
592
+ @versini/ui-button v6.0.7
575
593
  © 2025 gizmette.com
576
594
  */
577
595
  try {
578
596
  window.__VERSINI_UI_BUTTON__ || (window.__VERSINI_UI_BUTTON__ = {
579
- version: "6.0.5",
580
- buildTime: "04/12/2025 09:18 AM EDT",
597
+ version: "6.0.7",
598
+ buildTime: "06/20/2025 05:21 PM EDT",
581
599
  homepage: "https://github.com/aversini/ui-components",
582
600
  license: "MIT"
583
601
  });
584
602
  } catch {
585
603
  }
586
- const Z = R.forwardRef(
604
+ const Z = S.forwardRef(
587
605
  ({
588
606
  children: e,
589
- mode: a = "system",
607
+ mode: r = "system",
590
608
  className: t,
591
- active: r = !1,
592
- ...s
609
+ active: a = !1,
610
+ ...l
593
611
  }, o) => {
594
- const n = r ? l(
612
+ const n = a ? s(
595
613
  "relative",
596
614
  "focus-within:static",
597
615
  "focus-within:after:border-transparent",
@@ -602,45 +620,45 @@ const Z = R.forwardRef(
602
620
  "after:left-0",
603
621
  "after:right-0",
604
622
  {
605
- "after:border-table-dark": a === "dark",
606
- "after:border-table-light": a === "light",
607
- "after:border-table-dark dark:after:border-table-light": a === "system",
608
- "after:border-table-light dark:after:border-table-dark": a === "alt-system"
623
+ "after:border-table-dark": r === "dark",
624
+ "after:border-table-light": r === "light",
625
+ "after:border-table-dark dark:after:border-table-light": r === "system",
626
+ "after:border-table-light dark:after:border-table-dark": r === "alt-system"
609
627
  }
610
628
  ) : "";
611
629
  return /* @__PURE__ */ i("div", { className: n, children: /* @__PURE__ */ i(
612
- Y,
630
+ X,
613
631
  {
614
- className: l("justify-center", t),
632
+ className: s("justify-center", t),
615
633
  ref: o,
616
- mode: a,
634
+ mode: r,
617
635
  radius: "small",
618
- ...s,
636
+ ...l,
619
637
  children: e
620
638
  }
621
639
  ) });
622
640
  }
623
641
  );
624
642
  Z.displayName = "ButtonSort";
625
- const P = ({
643
+ const H = ({
626
644
  children: e,
627
- fill: a,
645
+ fill: r,
628
646
  viewBox: t,
629
- className: r,
630
- defaultViewBox: s,
647
+ className: a,
648
+ defaultViewBox: l,
631
649
  size: o,
632
650
  title: n,
633
651
  semantic: d = !1,
634
652
  ...c
635
653
  }) => {
636
- const g = l(o, r);
637
- return /* @__PURE__ */ i(se, { children: /* @__PURE__ */ _(
654
+ const h = s(o, a);
655
+ return /* @__PURE__ */ i(ne, { children: /* @__PURE__ */ N(
638
656
  "svg",
639
657
  {
640
658
  xmlns: "http://www.w3.org/2000/svg",
641
- className: g,
642
- viewBox: t || s,
643
- fill: a || "currentColor",
659
+ className: h,
660
+ viewBox: t || l,
661
+ fill: r || "currentColor",
644
662
  role: "img",
645
663
  "aria-hidden": !d,
646
664
  focusable: !1,
@@ -659,85 +677,85 @@ const P = ({
659
677
  try {
660
678
  window.__VERSINI_UI_SVGICON__ || (window.__VERSINI_UI_SVGICON__ = {
661
679
  version: "4.2.0",
662
- buildTime: "04/05/2025 07:49 PM EDT",
680
+ buildTime: "05/17/2025 06:18 PM EDT",
663
681
  homepage: "https://github.com/aversini/ui-components",
664
682
  license: "MIT"
665
683
  });
666
684
  } catch {
667
685
  }
668
- const ze = ({
686
+ const Oe = ({
669
687
  className: e,
670
- viewBox: a,
688
+ viewBox: r,
671
689
  title: t,
672
- monotone: r,
673
- ...s
674
- }) => /* @__PURE__ */ _(
675
- P,
690
+ monotone: a,
691
+ ...l
692
+ }) => /* @__PURE__ */ N(
693
+ H,
676
694
  {
677
695
  defaultViewBox: "0 0 576 512",
678
696
  size: "size-5",
679
- viewBox: a,
697
+ viewBox: r,
680
698
  className: e,
681
699
  title: t || "Sort",
682
- ...s,
700
+ ...l,
683
701
  children: [
684
702
  /* @__PURE__ */ i(
685
703
  "path",
686
704
  {
687
705
  d: "M297.4 137.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l41.3-41.4V448c0 17.7 14.3 32 32 32s32-14.3 32-32V141.3l41.4 41.4c12.5 12.5 32.8 12.5 45.3 0 6.2-6.2 9.4-14.4 9.4-22.6s-3.1-16.4-9.4-22.6l-96-96c-6.3-6.4-14.5-9.5-22.7-9.5s-16.4 3.1-22.6 9.4z",
688
- opacity: r ? "1" : "0.4"
706
+ opacity: a ? "1" : "0.4"
689
707
  }
690
708
  ),
691
709
  /* @__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 32v306.7l-41.4-41.3c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96z" })
692
710
  ]
693
711
  }
694
- ), Ve = ({
712
+ ), je = ({
695
713
  className: e,
696
- viewBox: a,
714
+ viewBox: r,
697
715
  title: t,
698
- monotone: r,
699
- ...s
700
- }) => /* @__PURE__ */ _(
701
- P,
716
+ monotone: a,
717
+ ...l
718
+ }) => /* @__PURE__ */ N(
719
+ H,
702
720
  {
703
721
  defaultViewBox: "0 0 576 512",
704
722
  size: "size-5",
705
- viewBox: a,
723
+ viewBox: r,
706
724
  className: e,
707
725
  title: t || "Sort Down",
708
- ...s,
726
+ ...l,
709
727
  children: [
710
728
  /* @__PURE__ */ i(
711
729
  "path",
712
730
  {
713
731
  d: "M288 64c0-17.7 14.3-32 32-32h224c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h160c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32h-96c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h32c17.7 0 32 14.3 32 32s-14.3 32-32 32h-32c-17.7 0-32-14.3-32-32",
714
- opacity: r ? "1" : "0.4"
732
+ opacity: a ? "1" : "0.4"
715
733
  }
716
734
  ),
717
735
  /* @__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-32S96 46.3 96 64v301.7l-32.4-35.3c-11.9-13-32.2-13.9-45.2-2s-13.9 32.2-2 45.2l88 96c6.1 6.6 14.6 10.4 23.6 10.4" })
718
736
  ]
719
737
  }
720
- ), Me = ({
738
+ ), Ae = ({
721
739
  className: e,
722
- viewBox: a,
740
+ viewBox: r,
723
741
  title: t,
724
- monotone: r,
725
- ...s
726
- }) => /* @__PURE__ */ _(
727
- P,
742
+ monotone: a,
743
+ ...l
744
+ }) => /* @__PURE__ */ N(
745
+ H,
728
746
  {
729
747
  defaultViewBox: "0 0 576 512",
730
748
  size: "size-5",
731
- viewBox: a,
749
+ viewBox: r,
732
750
  className: e,
733
751
  title: t || "Sort Up",
734
- ...s,
752
+ ...l,
735
753
  children: [
736
754
  /* @__PURE__ */ i(
737
755
  "path",
738
756
  {
739
757
  d: "M288 64c0-17.7 14.3-32 32-32h32c17.7 0 32 14.3 32 32s-14.3 32-32 32h-32c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32h-96c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h160c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h224c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32",
740
- opacity: r ? "1" : "0.4"
758
+ opacity: a ? "1" : "0.4"
741
759
  }
742
760
  ),
743
761
  /* @__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.3l-32.4 35.3c-11.9 13-32.2 13.9-45.2 2s-13.9-32.2-2-45.2l88-96C110.5 35.8 119 32 128 32" })
@@ -745,145 +763,145 @@ const ze = ({
745
763
  }
746
764
  );
747
765
  /*!
748
- @versini/ui-icons v4.9.0
766
+ @versini/ui-icons v4.10.0
749
767
  © 2025 gizmette.com
750
768
  */
751
769
  try {
752
770
  window.__VERSINI_UI_ICONS__ || (window.__VERSINI_UI_ICONS__ = {
753
- version: "4.9.0",
754
- buildTime: "04/05/2025 07:49 PM EDT",
771
+ version: "4.10.0",
772
+ buildTime: "05/17/2025 06:18 PM EDT",
755
773
  homepage: "https://github.com/aversini/ui-components",
756
774
  license: "MIT"
757
775
  });
758
776
  } catch {
759
777
  }
760
- const x = R.createContext({
778
+ const C = S.createContext({
761
779
  mode: "light",
762
780
  cellWrapper: "thead",
763
781
  stickyHeader: !1,
764
782
  stickyFooter: !1,
765
783
  compact: !1
766
- }), Pe = ({
784
+ }), He = ({
767
785
  children: e,
768
- mode: a = "system",
786
+ mode: r = "system",
769
787
  caption: t,
770
- compact: r,
771
- summary: s,
788
+ compact: a,
789
+ summary: l,
772
790
  className: o,
773
791
  wrapperClassName: n,
774
792
  maxHeight: d,
775
793
  stickyHeader: c,
776
- stickyFooter: g,
777
- ...m
794
+ stickyFooter: h,
795
+ ...u
778
796
  }) => {
779
- const h = ie({
780
- mode: a,
797
+ const g = ge({
798
+ mode: r,
781
799
  className: o,
782
800
  wrapperClassName: n,
783
801
  stickyHeader: c,
784
- stickyFooter: g
802
+ stickyFooter: h
785
803
  });
786
804
  return /* @__PURE__ */ i(
787
- x.Provider,
805
+ C.Provider,
788
806
  {
789
- value: { mode: a, stickyHeader: c, stickyFooter: g, compact: r },
807
+ value: { mode: r, stickyHeader: c, stickyFooter: h, compact: a },
790
808
  children: /* @__PURE__ */ i(
791
809
  "div",
792
810
  {
793
- className: h.wrapper,
811
+ className: g.wrapper,
794
812
  ...d && {
795
813
  style: { maxHeight: d }
796
814
  },
797
- children: /* @__PURE__ */ _("table", { className: h.table, summary: s, ...m, children: [
798
- t && /* @__PURE__ */ i("caption", { className: h.caption, children: t }),
815
+ children: /* @__PURE__ */ N("table", { className: g.table, summary: l, ...u, children: [
816
+ t && /* @__PURE__ */ i("caption", { className: g.caption, children: t }),
799
817
  e
800
818
  ] })
801
819
  }
802
820
  )
803
821
  }
804
822
  );
805
- }, Ue = ({
823
+ }, $e = ({
806
824
  children: e,
807
- className: a,
825
+ className: r,
808
826
  ...t
809
827
  }) => {
810
- const r = N(x);
811
- r.cellWrapper = I;
812
- const s = ne({
813
- className: a,
814
- mode: r.mode,
815
- stickyHeader: r.stickyHeader
828
+ const a = B(C);
829
+ a.cellWrapper = z;
830
+ const l = he({
831
+ className: r,
832
+ mode: a.mode,
833
+ stickyHeader: a.stickyHeader
816
834
  });
817
- return /* @__PURE__ */ i("thead", { className: s, ...t, children: e });
818
- }, We = ({
835
+ return /* @__PURE__ */ i("thead", { className: l, ...t, children: e });
836
+ }, Fe = ({
819
837
  children: e,
820
- className: a,
838
+ className: r,
821
839
  ...t
822
840
  }) => {
823
- const r = N(x);
824
- r.cellWrapper = A;
825
- const s = ce({
826
- className: a,
827
- mode: r.mode,
828
- stickyFooter: r.stickyFooter
841
+ const a = B(C);
842
+ a.cellWrapper = W;
843
+ const l = be({
844
+ className: r,
845
+ mode: a.mode,
846
+ stickyFooter: a.stickyFooter
829
847
  });
830
- return /* @__PURE__ */ i("tfoot", { className: s, ...t, children: e });
831
- }, De = ({ children: e, ...a }) => {
832
- const t = N(x);
833
- return t.cellWrapper = p, /* @__PURE__ */ i("tbody", { ...a, children: e });
834
- }, Fe = ({
848
+ return /* @__PURE__ */ i("tfoot", { className: l, ...t, children: e });
849
+ }, Ge = ({ children: e, ...r }) => {
850
+ const t = B(C);
851
+ return t.cellWrapper = x, /* @__PURE__ */ i("tbody", { ...r, children: e });
852
+ }, qe = ({
835
853
  children: e,
836
- className: a,
854
+ className: r,
837
855
  ...t
838
856
  }) => {
839
- const r = N(x), s = de({
840
- mode: r.mode,
841
- cellWrapper: r.cellWrapper,
842
- className: a
857
+ const a = B(C), l = ue({
858
+ mode: a.mode,
859
+ cellWrapper: a.cellWrapper,
860
+ className: r
843
861
  });
844
- return /* @__PURE__ */ i("tr", { className: s, ...t, children: e });
845
- }, Le = ({
862
+ return /* @__PURE__ */ i("tr", { className: l, ...t, children: e });
863
+ }, Pe = ({
846
864
  children: e,
847
- component: a,
865
+ component: r,
848
866
  className: t,
849
- align: r,
850
- ...s
867
+ align: a,
868
+ ...l
851
869
  }) => {
852
- const o = N(x), n = a || (o.cellWrapper === I ? "th" : "td"), { mainClasses: d, alignClasses: c } = ge({
870
+ const o = B(C), n = r || (o.cellWrapper === z ? "th" : "td"), { mainClasses: d, alignClasses: c } = me({
853
871
  cellWrapper: o.cellWrapper,
854
872
  className: t,
855
873
  mode: o.mode,
856
874
  compact: o.compact,
857
- align: r
875
+ align: a
858
876
  });
859
- return r ? /* @__PURE__ */ i(n, { className: d, ...s, children: /* @__PURE__ */ i("div", { className: c, children: e }) }) : /* @__PURE__ */ i(n, { className: d, ...s, children: e });
860
- }, He = ({
877
+ return a ? /* @__PURE__ */ i(n, { className: d, ...l, children: /* @__PURE__ */ i("div", { className: c, children: e }) }) : /* @__PURE__ */ i(n, { className: d, ...l, children: e });
878
+ }, Ye = ({
861
879
  align: e,
862
- children: a,
880
+ children: r,
863
881
  buttonClassName: t,
864
- className: r,
865
- component: s,
882
+ className: a,
883
+ component: l,
866
884
  focusMode: o = "alt-system",
867
885
  mode: n = "alt-system",
868
886
  onClick: d,
869
887
  sortDirection: c,
870
- sortedCell: g,
871
- cellId: m,
872
- ...h
888
+ sortedCell: h,
889
+ cellId: u,
890
+ ...g
873
891
  }) => {
874
- const b = he({ buttonClassName: t });
892
+ const b = ye({ buttonClassName: t });
875
893
  return /* @__PURE__ */ i(
876
- Le,
894
+ Pe,
877
895
  {
878
- component: s,
879
- className: r,
896
+ component: l,
897
+ className: a,
880
898
  role: "columnheader",
881
- "aria-sort": c === T.ASC && g === m ? "ascending" : c === T.DESC && g === m ? "descending" : "other",
882
- ...h,
899
+ "aria-sort": c === R.ASC && h === u ? "ascending" : c === R.DESC && h === u ? "descending" : "other",
900
+ ...g,
883
901
  children: /* @__PURE__ */ i(
884
902
  Z,
885
903
  {
886
- active: g === m,
904
+ active: h === u,
887
905
  className: b,
888
906
  onClick: d,
889
907
  align: e,
@@ -891,20 +909,20 @@ const x = R.createContext({
891
909
  focusMode: o,
892
910
  mode: n,
893
911
  fullWidth: !0,
894
- labelRight: a,
895
- children: c === T.ASC && g === m ? /* @__PURE__ */ i(Me, { className: "size-4", monotone: !0 }) : c === T.DESC && g === m ? /* @__PURE__ */ i(Ve, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ i(ze, { className: "size-4", monotone: !0 })
912
+ labelRight: r,
913
+ children: c === R.ASC && h === u ? /* @__PURE__ */ i(Ae, { className: "size-4", monotone: !0 }) : c === R.DESC && h === u ? /* @__PURE__ */ i(je, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ i(Oe, { className: "size-4", monotone: !0 })
896
914
  }
897
915
  )
898
916
  }
899
917
  );
900
918
  };
901
919
  export {
902
- Pe as Table,
903
- De as TableBody,
904
- Le as TableCell,
905
- He as TableCellSort,
906
- T as TableCellSortDirections,
907
- We as TableFooter,
908
- Ue as TableHead,
909
- Fe as TableRow
920
+ He as Table,
921
+ Ge as TableBody,
922
+ Pe as TableCell,
923
+ Ye as TableCellSort,
924
+ R as TableCellSortDirections,
925
+ Fe as TableFooter,
926
+ $e as TableHead,
927
+ qe as TableRow
910
928
  };