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