@duro-app/ui 0.9.1 → 0.9.2
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/components/Alert/Alert.d.ts.map +1 -1
- package/dist/components/Alert/styles.css.d.ts +5 -12
- package/dist/components/Alert/styles.css.d.ts.map +1 -1
- package/dist/components/Icon/Icon.d.ts.map +1 -1
- package/dist/index.css +1 -1
- package/dist/index.js +243 -251
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { jsx as r, jsxs as z, Fragment as
|
|
2
|
-
import { useState as G, useCallback as W, useContext as
|
|
1
|
+
import { jsx as r, jsxs as z, Fragment as B } from "react/jsx-runtime";
|
|
2
|
+
import { useState as G, useCallback as W, useContext as O, createContext as R, useId as _, useMemo as $e, useRef as w, useEffect as H, Children as qe } from "react";
|
|
3
3
|
/**
|
|
4
4
|
* @license react-strict-dom
|
|
5
5
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
@@ -15,36 +15,36 @@ var We = me.styleq = void 0, Xe = /* @__PURE__ */ new WeakMap(), Ye = "$$css";
|
|
|
15
15
|
function He(e) {
|
|
16
16
|
var t, n, s;
|
|
17
17
|
return e != null && (t = e.disableCache === !0, n = e.disableMix === !0, s = e.transform), function() {
|
|
18
|
-
for (var l = [], i = "", c = null, d = "",
|
|
18
|
+
for (var l = [], i = "", c = null, d = "", k = t ? null : Xe, g = new Array(arguments.length), u = 0; u < arguments.length; u++)
|
|
19
19
|
g[u] = arguments[u];
|
|
20
20
|
for (; g.length > 0; ) {
|
|
21
21
|
var $ = g.pop();
|
|
22
22
|
if (!($ == null || $ === !1)) {
|
|
23
23
|
if (Array.isArray($)) {
|
|
24
|
-
for (var
|
|
25
|
-
g.push($[
|
|
24
|
+
for (var M = 0; M < $.length; M++)
|
|
25
|
+
g.push($[M]);
|
|
26
26
|
continue;
|
|
27
27
|
}
|
|
28
28
|
var p = s != null ? s($) : $;
|
|
29
29
|
if (p.$$css != null) {
|
|
30
30
|
var m = "";
|
|
31
|
-
if (
|
|
32
|
-
var f =
|
|
33
|
-
f != null && (m = f[0], d = f[2], l.push.apply(l, f[1]),
|
|
31
|
+
if (k != null && k.has(p)) {
|
|
32
|
+
var f = k.get(p);
|
|
33
|
+
f != null && (m = f[0], d = f[2], l.push.apply(l, f[1]), k = f[3]);
|
|
34
34
|
} else {
|
|
35
35
|
var v = [];
|
|
36
36
|
for (var h in p) {
|
|
37
37
|
var b = p[h];
|
|
38
38
|
if (h === Ye) {
|
|
39
|
-
var
|
|
40
|
-
|
|
39
|
+
var C = p[h];
|
|
40
|
+
C !== !0 && (d = d ? C + "; " + d : C);
|
|
41
41
|
continue;
|
|
42
42
|
}
|
|
43
|
-
typeof b == "string" || b === null ? l.includes(h) || (l.push(h),
|
|
43
|
+
typeof b == "string" || b === null ? l.includes(h) || (l.push(h), k != null && v.push(h), typeof b == "string" && (m += m ? " " + b : b)) : console.error("styleq: ".concat(h, " typeof ").concat(String(b), ' is not "string" or "null".'));
|
|
44
44
|
}
|
|
45
|
-
if (
|
|
45
|
+
if (k != null) {
|
|
46
46
|
var Q = /* @__PURE__ */ new WeakMap();
|
|
47
|
-
|
|
47
|
+
k.set(p, [m, v, d, Q]), k = Q;
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
50
|
m && (i = i ? m + " " + i : m);
|
|
@@ -53,8 +53,8 @@ function He(e) {
|
|
|
53
53
|
else {
|
|
54
54
|
var y = null;
|
|
55
55
|
for (var I in p) {
|
|
56
|
-
var
|
|
57
|
-
|
|
56
|
+
var S = p[I];
|
|
57
|
+
S !== void 0 && (l.includes(I) || (S != null && (c == null && (c = {}), y == null && (y = {}), y[I] = S), l.push(I), k = null));
|
|
58
58
|
}
|
|
59
59
|
y != null && (c = Object.assign(y, c));
|
|
60
60
|
}
|
|
@@ -74,8 +74,8 @@ function x(...e) {
|
|
|
74
74
|
if (t != null && t !== "" && (o.className = t), n != null && (o.style = n), s != null && s !== "") {
|
|
75
75
|
const l = s.split(";"), i = {};
|
|
76
76
|
for (const c of l) {
|
|
77
|
-
const d = c.trim(), [
|
|
78
|
-
g != null && (i[
|
|
77
|
+
const d = c.trim(), [k, g] = d.split(":");
|
|
78
|
+
g != null && (i[k] = i[k] != null ? `${i[k]},${g}` : g);
|
|
79
79
|
}
|
|
80
80
|
o["data-style-src"] = Object.keys(i).map((c) => `${c}:${i[c]}`).join("; ");
|
|
81
81
|
}
|
|
@@ -121,7 +121,7 @@ const A = {
|
|
|
121
121
|
kHenm0: "x288g5",
|
|
122
122
|
$$css: !0
|
|
123
123
|
}
|
|
124
|
-
}, Fe = A.inline, Qe = [A.inlineblock, A.button], Ke = A.block, Z = [A.block, A.heading], Ue = [A.inlineblock, A.input], _e = A.inline, Ze = A.block, et = A.block, tt = A.inline, nt = [A.inlineblock, A.textarea],
|
|
124
|
+
}, Fe = A.inline, Qe = [A.inlineblock, A.button], Ke = A.block, Z = [A.block, A.heading], Ue = [A.inlineblock, A.input], _e = A.inline, Ze = A.block, et = A.block, tt = A.inline, nt = [A.inlineblock, A.textarea], a = {
|
|
125
125
|
a: Fe,
|
|
126
126
|
button: Qe,
|
|
127
127
|
div: Ke,
|
|
@@ -138,43 +138,43 @@ const A = {
|
|
|
138
138
|
span: tt,
|
|
139
139
|
textarea: nt
|
|
140
140
|
}, rt = {
|
|
141
|
-
"x-circle": /* @__PURE__ */ z(
|
|
141
|
+
"x-circle": /* @__PURE__ */ z(B, { children: [
|
|
142
142
|
/* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "10" }),
|
|
143
143
|
/* @__PURE__ */ r("line", { x1: "15", y1: "9", x2: "9", y2: "15" }),
|
|
144
144
|
/* @__PURE__ */ r("line", { x1: "9", y1: "9", x2: "15", y2: "15" })
|
|
145
145
|
] }),
|
|
146
|
-
"check-circle": /* @__PURE__ */ z(
|
|
146
|
+
"check-circle": /* @__PURE__ */ z(B, { children: [
|
|
147
147
|
/* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "10" }),
|
|
148
148
|
/* @__PURE__ */ r("polyline", { points: "16 10 11 15 8 12" })
|
|
149
149
|
] }),
|
|
150
|
-
"check-done": /* @__PURE__ */ z(
|
|
150
|
+
"check-done": /* @__PURE__ */ z(B, { children: [
|
|
151
151
|
/* @__PURE__ */ r("path", { d: "M22 11.08V12a10 10 0 1 1-5.93-9.14" }),
|
|
152
152
|
/* @__PURE__ */ r("polyline", { points: "22 4 12 14.01 9 11.01" })
|
|
153
153
|
] }),
|
|
154
|
-
clock: /* @__PURE__ */ z(
|
|
154
|
+
clock: /* @__PURE__ */ z(B, { children: [
|
|
155
155
|
/* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "10" }),
|
|
156
156
|
/* @__PURE__ */ r("polyline", { points: "12 6 12 12 16 14" })
|
|
157
157
|
] }),
|
|
158
|
-
forbidden: /* @__PURE__ */ z(
|
|
158
|
+
forbidden: /* @__PURE__ */ z(B, { children: [
|
|
159
159
|
/* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "10" }),
|
|
160
160
|
/* @__PURE__ */ r("line", { x1: "4.93", y1: "4.93", x2: "19.07", y2: "19.07" })
|
|
161
161
|
] }),
|
|
162
|
-
"info-circle": /* @__PURE__ */ z(
|
|
162
|
+
"info-circle": /* @__PURE__ */ z(B, { children: [
|
|
163
163
|
/* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "10" }),
|
|
164
164
|
/* @__PURE__ */ r("line", { x1: "12", y1: "16", x2: "12", y2: "12" }),
|
|
165
165
|
/* @__PURE__ */ r("line", { x1: "12", y1: "8", x2: "12.01", y2: "8" })
|
|
166
166
|
] }),
|
|
167
|
-
"alert-triangle": /* @__PURE__ */ z(
|
|
167
|
+
"alert-triangle": /* @__PURE__ */ z(B, { children: [
|
|
168
168
|
/* @__PURE__ */ r("path", { d: "M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z" }),
|
|
169
169
|
/* @__PURE__ */ r("line", { x1: "12", y1: "9", x2: "12", y2: "13" }),
|
|
170
170
|
/* @__PURE__ */ r("line", { x1: "12", y1: "17", x2: "12.01", y2: "17" })
|
|
171
171
|
] }),
|
|
172
172
|
shield: /* @__PURE__ */ r("path", { d: "M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" }),
|
|
173
|
-
lock: /* @__PURE__ */ z(
|
|
173
|
+
lock: /* @__PURE__ */ z(B, { children: [
|
|
174
174
|
/* @__PURE__ */ r("rect", { x: "3", y: "11", width: "18", height: "11", rx: "2", ry: "2" }),
|
|
175
175
|
/* @__PURE__ */ r("path", { d: "M7 11V7a5 5 0 0 1 10 0v4" })
|
|
176
176
|
] }),
|
|
177
|
-
key: /* @__PURE__ */ r(
|
|
177
|
+
key: /* @__PURE__ */ r(B, { children: /* @__PURE__ */ r("path", { d: "M21 2l-2 2m-7.61 7.61a5.5 5.5 0 1 1-7.78 7.78 5.5 5.5 0 0 1 7.78-7.78zm0 0L15.5 7.5m0 0l3 3L22 7l-3-3m-3.5 3.5L19 4" }) })
|
|
178
178
|
}, st = {
|
|
179
179
|
// Filled circle with "i" cutout (dot + line)
|
|
180
180
|
"info-circle-filled": /* @__PURE__ */ r("path", { fillRule: "evenodd", d: "M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm-.75 6a.75.75 0 1 1 1.5 0 .75.75 0 0 1-1.5 0zM11 11a1 1 0 1 1 2 0v5a1 1 0 1 1-2 0v-5z" }),
|
|
@@ -187,7 +187,7 @@ const A = {
|
|
|
187
187
|
// Filled shield with checkmark cutout
|
|
188
188
|
"shield-filled": /* @__PURE__ */ r("path", { fillRule: "evenodd", d: "M12 1L3 5v7c0 6.5 8.5 10.5 9 10.73.5-.23 9-4.23 9-10.73V5l-9-4zm3.707 8.707a1 1 0 0 0-1.414-1.414L11 11.586l-1.293-1.293a1 1 0 0 0-1.414 1.414l2 2a1 1 0 0 0 1.414 0l4-4z" }),
|
|
189
189
|
// Filled lock body with stroke shackle
|
|
190
|
-
"lock-filled": /* @__PURE__ */ z(
|
|
190
|
+
"lock-filled": /* @__PURE__ */ z(B, { children: [
|
|
191
191
|
/* @__PURE__ */ r("path", { d: "M7 11V7a5 5 0 0 1 10 0v4", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
|
|
192
192
|
/* @__PURE__ */ r("rect", { x: "3", y: "11", width: "18", height: "11", rx: "2", ry: "2" })
|
|
193
193
|
] })
|
|
@@ -199,12 +199,8 @@ function ve({
|
|
|
199
199
|
const n = st[e];
|
|
200
200
|
return n ? /* @__PURE__ */ r("svg", { viewBox: "0 0 24 24", fill: "currentColor", width: t, height: t, children: n }) : /* @__PURE__ */ r("svg", { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", width: t, height: t, children: rt[e] });
|
|
201
201
|
}
|
|
202
|
-
const
|
|
202
|
+
const ge = {
|
|
203
203
|
base: {
|
|
204
|
-
k1xSpc: "x78zum5",
|
|
205
|
-
kXwgrk: "x1q0g3np",
|
|
206
|
-
kGNEyG: "x1cy8zhl",
|
|
207
|
-
kOIVth: "x1wyuhvo",
|
|
208
204
|
kmVPX3: "x16ixvul",
|
|
209
205
|
kaIpWk: "x1gbengz",
|
|
210
206
|
kMzoRj: "xmkeg23",
|
|
@@ -213,17 +209,13 @@ const ce = {
|
|
|
213
209
|
kLWn49: "xi1gl5z",
|
|
214
210
|
$$css: !0
|
|
215
211
|
},
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
212
|
+
icon: {
|
|
213
|
+
kyUFMd: "x1faq86j",
|
|
214
|
+
km5ZXQ: "xxn522s",
|
|
215
|
+
keoZOQ: "xr9ek0c",
|
|
216
|
+
k1xSpc: "x3nfvp2",
|
|
219
217
|
kGNEyG: "x6s0dn4",
|
|
220
218
|
kjj79g: "xl56j7k",
|
|
221
|
-
kLKAdn: "x4p5aij",
|
|
222
|
-
$$css: !0
|
|
223
|
-
},
|
|
224
|
-
content: {
|
|
225
|
-
kUk6DE: "x98rzlu",
|
|
226
|
-
k7Eaqz: "xeuugli",
|
|
227
219
|
$$css: !0
|
|
228
220
|
},
|
|
229
221
|
error: {
|
|
@@ -265,12 +257,12 @@ function zn({
|
|
|
265
257
|
children: n
|
|
266
258
|
}) {
|
|
267
259
|
const s = it(t, e);
|
|
268
|
-
return /* @__PURE__ */
|
|
269
|
-
/* @__PURE__ */ r("
|
|
270
|
-
|
|
271
|
-
] })
|
|
260
|
+
return /* @__PURE__ */ z("div", { role: "alert", ...x(a.div, ge.base, ge[e]), children: [
|
|
261
|
+
s && /* @__PURE__ */ r("span", { ...x(a.span, ge.icon), children: s }),
|
|
262
|
+
n
|
|
263
|
+
] });
|
|
272
264
|
}
|
|
273
|
-
const
|
|
265
|
+
const le = {
|
|
274
266
|
base: {
|
|
275
267
|
k1xSpc: "x3nfvp2",
|
|
276
268
|
kGNEyG: "x6s0dn4",
|
|
@@ -324,15 +316,15 @@ const xe = {
|
|
|
324
316
|
$$css: !0
|
|
325
317
|
}
|
|
326
318
|
}, ct = {
|
|
327
|
-
sm:
|
|
328
|
-
md:
|
|
319
|
+
sm: le.sizeSm,
|
|
320
|
+
md: le.sizeMd
|
|
329
321
|
};
|
|
330
322
|
function In({
|
|
331
323
|
variant: e = "default",
|
|
332
324
|
size: t = "md",
|
|
333
325
|
children: n
|
|
334
326
|
}) {
|
|
335
|
-
return /* @__PURE__ */ r("span", { ...x(
|
|
327
|
+
return /* @__PURE__ */ r("span", { ...x(a.span, le.base, ct[t], le[e]), children: n });
|
|
336
328
|
}
|
|
337
329
|
const ne = {
|
|
338
330
|
base: {
|
|
@@ -422,7 +414,7 @@ function qn({
|
|
|
422
414
|
onClick: l,
|
|
423
415
|
children: i
|
|
424
416
|
}) {
|
|
425
|
-
return /* @__PURE__ */ r("button", { type: o, disabled: s, onClick: l, ...x(
|
|
417
|
+
return /* @__PURE__ */ r("button", { type: o, disabled: s, onClick: l, ...x(a.button, ne.base, lt[t], ne[e], n && ne.fullWidth, s && ne.disabled), children: i });
|
|
426
418
|
}
|
|
427
419
|
const re = {
|
|
428
420
|
base: {
|
|
@@ -493,8 +485,8 @@ function Wn({
|
|
|
493
485
|
onClick: s,
|
|
494
486
|
children: o
|
|
495
487
|
}) {
|
|
496
|
-
return /* @__PURE__ */ z("div", { onClick: s, ...x(
|
|
497
|
-
n && /* @__PURE__ */ r("div", { ...x(
|
|
488
|
+
return /* @__PURE__ */ z("div", { onClick: s, ...x(a.div, re.base, re[e], xt[t]), children: [
|
|
489
|
+
n && /* @__PURE__ */ r("div", { ...x(a.div, re.header), children: n }),
|
|
498
490
|
o
|
|
499
491
|
] });
|
|
500
492
|
}
|
|
@@ -557,15 +549,15 @@ function Hn({
|
|
|
557
549
|
onChange: l,
|
|
558
550
|
children: i
|
|
559
551
|
}) {
|
|
560
|
-
const c = n !== void 0, [d,
|
|
561
|
-
c ||
|
|
552
|
+
const c = n !== void 0, [d, k] = G(s), g = c ? n : d, u = W(($) => {
|
|
553
|
+
c || k($.target.checked), l?.($);
|
|
562
554
|
}, [c, l]);
|
|
563
|
-
return /* @__PURE__ */ z("label", { ...x(
|
|
564
|
-
/* @__PURE__ */ r("input", { type: "checkbox", name: e, value: t, checked: c ? n : void 0, defaultChecked: c ? void 0 : s, disabled: o, onChange: u, ...x(
|
|
565
|
-
/* @__PURE__ */ r("span", { ...x(
|
|
555
|
+
return /* @__PURE__ */ z("label", { ...x(a.label, ee.root, o && ee.rootDisabled), children: [
|
|
556
|
+
/* @__PURE__ */ r("input", { type: "checkbox", name: e, value: t, checked: c ? n : void 0, defaultChecked: c ? void 0 : s, disabled: o, onChange: u, ...x(a.input, ee.input), dir: "auto" }),
|
|
557
|
+
/* @__PURE__ */ r("span", { ...x(a.span, ee.box, g ? ee.boxChecked : ee.boxUnchecked), "aria-hidden": !0, children: /* @__PURE__ */ r("svg", { width: 12, height: 12, viewBox: "0 0 12 12", fill: "none", style: {
|
|
566
558
|
opacity: g ? 1 : 0
|
|
567
559
|
}, children: /* @__PURE__ */ r("polyline", { points: "2.5 6 5 8.5 9.5 3.5", stroke: "currentColor", strokeWidth: 1.5, strokeLinecap: "round", strokeLinejoin: "round" }) }) }),
|
|
568
|
-
i && /* @__PURE__ */ r("span", { ...x(
|
|
560
|
+
i && /* @__PURE__ */ r("span", { ...x(a.span), children: i })
|
|
569
561
|
] });
|
|
570
562
|
}
|
|
571
563
|
const he = {
|
|
@@ -596,10 +588,10 @@ function Gn({
|
|
|
596
588
|
icon: t,
|
|
597
589
|
action: n
|
|
598
590
|
}) {
|
|
599
|
-
return /* @__PURE__ */ z("div", { ...x(
|
|
591
|
+
return /* @__PURE__ */ z("div", { ...x(a.div, he.root), children: [
|
|
600
592
|
t,
|
|
601
|
-
/* @__PURE__ */ r("p", { ...x(
|
|
602
|
-
n && /* @__PURE__ */ r("div", { ...x(
|
|
593
|
+
/* @__PURE__ */ r("p", { ...x(a.p, he.message), children: e }),
|
|
594
|
+
n && /* @__PURE__ */ r("div", { ...x(a.div, he.action), children: n })
|
|
603
595
|
] });
|
|
604
596
|
}
|
|
605
597
|
const Ge = {
|
|
@@ -716,7 +708,7 @@ const Ge = {
|
|
|
716
708
|
kb6lSQ: "xgvl3jc",
|
|
717
709
|
$$css: !0
|
|
718
710
|
}
|
|
719
|
-
},
|
|
711
|
+
}, ce = {
|
|
720
712
|
default: {
|
|
721
713
|
kMwMTN: "xg6mlj0",
|
|
722
714
|
$$css: !0
|
|
@@ -741,17 +733,17 @@ const Ge = {
|
|
|
741
733
|
k9WMMc: "xp4054r",
|
|
742
734
|
$$css: !0
|
|
743
735
|
}
|
|
744
|
-
},
|
|
736
|
+
}, at = {
|
|
745
737
|
1: "headingXl",
|
|
746
738
|
2: "headingLg",
|
|
747
739
|
3: "headingMd",
|
|
748
740
|
4: "headingSm",
|
|
749
741
|
5: "headingSm",
|
|
750
742
|
6: "headingSm"
|
|
751
|
-
},
|
|
752
|
-
start:
|
|
753
|
-
center:
|
|
754
|
-
end:
|
|
743
|
+
}, kt = {
|
|
744
|
+
start: ce.alignStart,
|
|
745
|
+
center: ce.alignCenter,
|
|
746
|
+
end: ce.alignEnd
|
|
755
747
|
};
|
|
756
748
|
function Ln({
|
|
757
749
|
level: e,
|
|
@@ -760,14 +752,14 @@ function Ln({
|
|
|
760
752
|
align: s,
|
|
761
753
|
children: o
|
|
762
754
|
}) {
|
|
763
|
-
const l = t ??
|
|
764
|
-
return e === 1 ? /* @__PURE__ */ r("h1", { ...x(
|
|
755
|
+
const l = t ?? at[e], i = [Ge[l], ce[n], s && kt[s]];
|
|
756
|
+
return e === 1 ? /* @__PURE__ */ r("h1", { ...x(a.h1, i), children: o }) : e === 2 ? /* @__PURE__ */ r("h2", { ...x(a.h2, i), children: o }) : e === 3 ? /* @__PURE__ */ r("h3", { ...x(a.h3, i), children: o }) : e === 4 ? /* @__PURE__ */ r("h4", { ...x(a.h4, i), children: o }) : e === 5 ? /* @__PURE__ */ r("h5", { ...x(a.h5, i), children: o }) : /* @__PURE__ */ r("h6", { ...x(a.h6, i), children: o });
|
|
765
757
|
}
|
|
766
758
|
const Le = R(null);
|
|
767
759
|
function ie() {
|
|
768
|
-
return
|
|
760
|
+
return O(Le);
|
|
769
761
|
}
|
|
770
|
-
const
|
|
762
|
+
const xe = {
|
|
771
763
|
root: {
|
|
772
764
|
k1xSpc: "x78zum5",
|
|
773
765
|
kXwgrk: "xdt5ytf",
|
|
@@ -801,25 +793,25 @@ function ut({
|
|
|
801
793
|
errorId: `${n}-error`,
|
|
802
794
|
invalid: e
|
|
803
795
|
}), [n, e]);
|
|
804
|
-
return /* @__PURE__ */ r(Le.Provider, { value: s, children: /* @__PURE__ */ r("div", { ...x(
|
|
796
|
+
return /* @__PURE__ */ r(Le.Provider, { value: s, children: /* @__PURE__ */ r("div", { ...x(a.div, xe.root), children: t }) });
|
|
805
797
|
}
|
|
806
798
|
function dt({
|
|
807
799
|
children: e
|
|
808
800
|
}) {
|
|
809
801
|
const t = ie();
|
|
810
|
-
return /* @__PURE__ */ r("label", { htmlFor: t?.controlId, ...x(
|
|
802
|
+
return /* @__PURE__ */ r("label", { htmlFor: t?.controlId, ...x(a.label, xe.label), children: e });
|
|
811
803
|
}
|
|
812
804
|
function gt({
|
|
813
805
|
children: e
|
|
814
806
|
}) {
|
|
815
807
|
const t = ie();
|
|
816
|
-
return /* @__PURE__ */ r("span", { id: t?.descriptionId, ...x(
|
|
808
|
+
return /* @__PURE__ */ r("span", { id: t?.descriptionId, ...x(a.span, xe.description), children: e });
|
|
817
809
|
}
|
|
818
810
|
function ht({
|
|
819
811
|
children: e
|
|
820
812
|
}) {
|
|
821
813
|
const t = ie();
|
|
822
|
-
return !t?.invalid && !e ? null : /* @__PURE__ */ r("span", { id: t?.errorId, role: "alert", ...x(
|
|
814
|
+
return !t?.invalid && !e ? null : /* @__PURE__ */ r("span", { id: t?.errorId, role: "alert", ...x(a.span, xe.error), children: e });
|
|
823
815
|
}
|
|
824
816
|
const Tn = {
|
|
825
817
|
Root: ut,
|
|
@@ -828,7 +820,7 @@ const Tn = {
|
|
|
828
820
|
Error: ht
|
|
829
821
|
}, Te = R(null);
|
|
830
822
|
function pt() {
|
|
831
|
-
return
|
|
823
|
+
return O(Te);
|
|
832
824
|
}
|
|
833
825
|
const pe = {
|
|
834
826
|
base: {
|
|
@@ -879,14 +871,14 @@ function En({
|
|
|
879
871
|
pattern: i,
|
|
880
872
|
autoComplete: c,
|
|
881
873
|
value: d,
|
|
882
|
-
defaultValue:
|
|
874
|
+
defaultValue: k,
|
|
883
875
|
disabled: g,
|
|
884
876
|
onChange: u
|
|
885
877
|
}) {
|
|
886
|
-
const $ = ie(),
|
|
878
|
+
const $ = ie(), M = pt(), p = i !== void 0 ? {
|
|
887
879
|
pattern: i
|
|
888
880
|
} : void 0;
|
|
889
|
-
return /* @__PURE__ */ r("input", { id: $?.controlId, type: t, name: n, placeholder: s, required: o, minLength: l, autoComplete: c, value: d, defaultValue:
|
|
881
|
+
return /* @__PURE__ */ r("input", { id: $?.controlId, type: t, name: n, placeholder: s, required: o, minLength: l, autoComplete: c, value: d, defaultValue: k, disabled: g, "aria-describedby": $ ? `${$.descriptionId} ${$.invalid ? $.errorId : ""}`.trim() : void 0, "aria-invalid": $?.invalid || e === "error" || void 0, onChange: u, ...x(a.input, pe.base, pe[e], M?.inGroup && pe.inGroup), ...p, dir: "auto" });
|
|
890
882
|
}
|
|
891
883
|
const te = {
|
|
892
884
|
wrapper: {
|
|
@@ -949,7 +941,7 @@ function ft({
|
|
|
949
941
|
const t = $e(() => ({
|
|
950
942
|
inGroup: !0
|
|
951
943
|
}), []);
|
|
952
|
-
return /* @__PURE__ */ r(Te.Provider, { value: t, children: /* @__PURE__ */ r("div", { ...x(
|
|
944
|
+
return /* @__PURE__ */ r(Te.Provider, { value: t, children: /* @__PURE__ */ r("div", { ...x(a.div, te.wrapper), children: e }) });
|
|
953
945
|
}
|
|
954
946
|
function vt({
|
|
955
947
|
position: e = "end",
|
|
@@ -958,7 +950,7 @@ function vt({
|
|
|
958
950
|
children: s
|
|
959
951
|
}) {
|
|
960
952
|
const o = e === "start" ? te.addonStart : te.addonEnd, l = [te.addon, o, t && !n && te.addonClickable, n && te.addonDisabled];
|
|
961
|
-
return t ? /* @__PURE__ */ r("button", { type: "button", onClick: t, disabled: n, ...x(
|
|
953
|
+
return t ? /* @__PURE__ */ r("button", { type: "button", onClick: t, disabled: n, ...x(a.button, l), children: s }) : /* @__PURE__ */ r("span", { ...x(a.span, l), children: s });
|
|
962
954
|
}
|
|
963
955
|
const Vn = {
|
|
964
956
|
Root: ft,
|
|
@@ -1026,7 +1018,7 @@ function An({
|
|
|
1026
1018
|
rel: l,
|
|
1027
1019
|
children: i
|
|
1028
1020
|
}) {
|
|
1029
|
-
return /* @__PURE__ */ r("a", { href: e, target: o, rel: l, ...x(
|
|
1021
|
+
return /* @__PURE__ */ r("a", { href: e, target: o, rel: l, ...x(a.a, oe.base, $t[n], oe[t], s && oe.fullWidth), children: i });
|
|
1030
1022
|
}
|
|
1031
1023
|
const P = {
|
|
1032
1024
|
root: {
|
|
@@ -1114,19 +1106,19 @@ const P = {
|
|
|
1114
1106
|
}
|
|
1115
1107
|
}, Ee = R(null);
|
|
1116
1108
|
function ae() {
|
|
1117
|
-
const e =
|
|
1109
|
+
const e = O(Ee);
|
|
1118
1110
|
if (!e) throw new Error("Menu compound components must be used within Menu.Root");
|
|
1119
1111
|
return e;
|
|
1120
1112
|
}
|
|
1121
1113
|
function mt() {
|
|
1122
|
-
const [e, t] = G(!1), [n, s] = G(null), o = _(), l = w(null), i = w(null), c = w(/* @__PURE__ */ new Map()), d = w([]),
|
|
1123
|
-
t(!1), s(null),
|
|
1114
|
+
const [e, t] = G(!1), [n, s] = G(null), o = _(), l = w(null), i = w(null), c = w(/* @__PURE__ */ new Map()), d = w([]), k = w(!1), g = W(() => {
|
|
1115
|
+
t(!1), s(null), k.current = !1, i.current?.focus();
|
|
1124
1116
|
}, []), u = W(() => {
|
|
1125
|
-
t((p) => (p ? (s(null),
|
|
1117
|
+
t((p) => (p ? (s(null), k.current = !1) : k.current = !0, !p));
|
|
1126
1118
|
}, []);
|
|
1127
1119
|
H(() => {
|
|
1128
|
-
if (e &&
|
|
1129
|
-
|
|
1120
|
+
if (e && k.current) {
|
|
1121
|
+
k.current = !1;
|
|
1130
1122
|
const p = d.current;
|
|
1131
1123
|
p.length > 0 && s(p[0]);
|
|
1132
1124
|
}
|
|
@@ -1135,8 +1127,8 @@ function mt() {
|
|
|
1135
1127
|
c.current.set(p, m);
|
|
1136
1128
|
const f = c.current, v = [...f.keys()];
|
|
1137
1129
|
return v.sort((h, b) => {
|
|
1138
|
-
const
|
|
1139
|
-
return !
|
|
1130
|
+
const C = f.get(h), Q = f.get(b);
|
|
1131
|
+
return !C || !Q ? 0 : C.compareDocumentPosition(Q) & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : 1;
|
|
1140
1132
|
}), d.current = v, () => {
|
|
1141
1133
|
c.current.delete(p), d.current = d.current.filter((h) => h !== p);
|
|
1142
1134
|
};
|
|
@@ -1206,7 +1198,7 @@ function bt({
|
|
|
1206
1198
|
ctx: t,
|
|
1207
1199
|
rootRef: n
|
|
1208
1200
|
} = mt();
|
|
1209
|
-
return /* @__PURE__ */ r(Ee.Provider, { value: t, children: /* @__PURE__ */ r("div", { ref: n, ...x(
|
|
1201
|
+
return /* @__PURE__ */ r(Ee.Provider, { value: t, children: /* @__PURE__ */ r("div", { ref: n, ...x(a.div, P.root), children: e }) });
|
|
1210
1202
|
}
|
|
1211
1203
|
function yt({
|
|
1212
1204
|
children: e
|
|
@@ -1219,7 +1211,7 @@ function yt({
|
|
|
1219
1211
|
} = ae(), l = w(null);
|
|
1220
1212
|
return H(() => {
|
|
1221
1213
|
o.current = l.current;
|
|
1222
|
-
}), /* @__PURE__ */ r("button", { ref: l, type: "button", onClick: n, "aria-expanded": t, "aria-haspopup": "menu", "aria-controls": t ? s : void 0, ...x(
|
|
1214
|
+
}), /* @__PURE__ */ r("button", { ref: l, type: "button", onClick: n, "aria-expanded": t, "aria-haspopup": "menu", "aria-controls": t ? s : void 0, ...x(a.button, P.trigger), children: e });
|
|
1223
1215
|
}
|
|
1224
1216
|
function wt({
|
|
1225
1217
|
children: e,
|
|
@@ -1231,12 +1223,12 @@ function wt({
|
|
|
1231
1223
|
menuId: o,
|
|
1232
1224
|
highlightedId: l
|
|
1233
1225
|
} = ae();
|
|
1234
|
-
return n ? /* @__PURE__ */ z(
|
|
1235
|
-
/* @__PURE__ */ r("div", { ...x(
|
|
1236
|
-
/* @__PURE__ */ r("div", { id: o, role: "menu", "aria-activedescendant": l ?? void 0, ...x(
|
|
1226
|
+
return n ? /* @__PURE__ */ z(B, { children: [
|
|
1227
|
+
/* @__PURE__ */ r("div", { ...x(a.div, P.backdrop), onClick: s }),
|
|
1228
|
+
/* @__PURE__ */ r("div", { id: o, role: "menu", "aria-activedescendant": l ?? void 0, ...x(a.div, P.popup, t === "end" && P.popupEnd), children: e })
|
|
1237
1229
|
] }) : null;
|
|
1238
1230
|
}
|
|
1239
|
-
function
|
|
1231
|
+
function Mt({
|
|
1240
1232
|
onClick: e,
|
|
1241
1233
|
children: t
|
|
1242
1234
|
}) {
|
|
@@ -1252,9 +1244,9 @@ function St({
|
|
|
1252
1244
|
return l(i, g);
|
|
1253
1245
|
}, [i, l]), /* @__PURE__ */ r("div", { ref: c, id: i, role: "menuitem", onClick: () => {
|
|
1254
1246
|
e?.(), n();
|
|
1255
|
-
}, onPointerEnter: () => o(i), ...x(
|
|
1247
|
+
}, onPointerEnter: () => o(i), ...x(a.div, P.item, d && P.itemHighlighted), children: t });
|
|
1256
1248
|
}
|
|
1257
|
-
function
|
|
1249
|
+
function St({
|
|
1258
1250
|
href: e,
|
|
1259
1251
|
children: t
|
|
1260
1252
|
}) {
|
|
@@ -1265,17 +1257,17 @@ function Mt({
|
|
|
1265
1257
|
registerItem: l
|
|
1266
1258
|
} = ae(), i = _(), c = w(null), d = s === i;
|
|
1267
1259
|
return H(() => {
|
|
1268
|
-
const
|
|
1269
|
-
if (
|
|
1270
|
-
return l(i,
|
|
1271
|
-
}, [i, l]), /* @__PURE__ */ r("a", { ref: c, id: i, href: e, onClick: n, role: "menuitem", onPointerEnter: () => o(i), ...x(
|
|
1260
|
+
const k = c.current;
|
|
1261
|
+
if (k)
|
|
1262
|
+
return l(i, k);
|
|
1263
|
+
}, [i, l]), /* @__PURE__ */ r("a", { ref: c, id: i, href: e, onClick: n, role: "menuitem", onPointerEnter: () => o(i), ...x(a.a, P.item, P.linkItem, d && P.itemHighlighted), children: t });
|
|
1272
1264
|
}
|
|
1273
1265
|
const Nn = {
|
|
1274
1266
|
Root: bt,
|
|
1275
1267
|
Trigger: yt,
|
|
1276
1268
|
Popup: wt,
|
|
1277
|
-
Item:
|
|
1278
|
-
LinkItem:
|
|
1269
|
+
Item: Mt,
|
|
1270
|
+
LinkItem: St
|
|
1279
1271
|
}, D = {
|
|
1280
1272
|
root: {
|
|
1281
1273
|
kVAEAm: "x1n2onr6",
|
|
@@ -1368,23 +1360,23 @@ const Nn = {
|
|
|
1368
1360
|
"--x-transform": t ?? void 0
|
|
1369
1361
|
}]
|
|
1370
1362
|
}, Ve = R(null);
|
|
1371
|
-
function
|
|
1372
|
-
const e =
|
|
1363
|
+
function ke() {
|
|
1364
|
+
const e = O(Ve);
|
|
1373
1365
|
if (!e) throw new Error("ScrollArea compound components must be used within ScrollArea.Root");
|
|
1374
1366
|
return e;
|
|
1375
1367
|
}
|
|
1376
1368
|
function jt() {
|
|
1377
|
-
const e = w(null), t = w(null), [n, s] = G(0), [o, l] = G(0), [i, c] = G(0), [d,
|
|
1369
|
+
const e = w(null), t = w(null), [n, s] = G(0), [o, l] = G(0), [i, c] = G(0), [d, k] = G(0), [g, u] = G(0), [$, M] = G(0), [p, m] = G(!1), f = w(null), v = W(() => {
|
|
1378
1370
|
const h = e.current;
|
|
1379
|
-
h && (s(h.scrollTop), l(h.scrollLeft), c(h.scrollHeight),
|
|
1371
|
+
h && (s(h.scrollTop), l(h.scrollLeft), c(h.scrollHeight), k(h.scrollWidth), u(h.clientHeight), M(h.clientWidth), m(!0), f.current && clearTimeout(f.current), f.current = setTimeout(() => m(!1), 1e3));
|
|
1380
1372
|
}, []);
|
|
1381
1373
|
return H(() => {
|
|
1382
1374
|
const h = e.current;
|
|
1383
1375
|
if (!h) return;
|
|
1384
1376
|
const b = new ResizeObserver(() => {
|
|
1385
|
-
c(h.scrollHeight),
|
|
1377
|
+
c(h.scrollHeight), k(h.scrollWidth), u(h.clientHeight), M(h.clientWidth);
|
|
1386
1378
|
});
|
|
1387
|
-
return b.observe(h), c(h.scrollHeight),
|
|
1379
|
+
return b.observe(h), c(h.scrollHeight), k(h.scrollWidth), u(h.clientHeight), M(h.clientWidth), () => b.disconnect();
|
|
1388
1380
|
}, []), H(() => {
|
|
1389
1381
|
const h = e.current;
|
|
1390
1382
|
if (h)
|
|
@@ -1407,7 +1399,7 @@ function zt({
|
|
|
1407
1399
|
children: e
|
|
1408
1400
|
}) {
|
|
1409
1401
|
const t = jt();
|
|
1410
|
-
return /* @__PURE__ */ r(Ve.Provider, { value: t, children: /* @__PURE__ */ r("div", { ...x(
|
|
1402
|
+
return /* @__PURE__ */ r(Ve.Provider, { value: t, children: /* @__PURE__ */ r("div", { ...x(a.div, D.root), children: e }) });
|
|
1411
1403
|
}
|
|
1412
1404
|
function It({
|
|
1413
1405
|
children: e,
|
|
@@ -1415,16 +1407,16 @@ function It({
|
|
|
1415
1407
|
}) {
|
|
1416
1408
|
const {
|
|
1417
1409
|
viewportRef: n
|
|
1418
|
-
} =
|
|
1419
|
-
return /* @__PURE__ */ r("div", { ref: n, ...x(
|
|
1410
|
+
} = ke();
|
|
1411
|
+
return /* @__PURE__ */ r("div", { ref: n, ...x(a.div, D.viewport, t != null && D.viewportMaxHeight(t)), children: e });
|
|
1420
1412
|
}
|
|
1421
1413
|
function qt({
|
|
1422
1414
|
children: e
|
|
1423
1415
|
}) {
|
|
1424
1416
|
const {
|
|
1425
1417
|
contentRef: t
|
|
1426
|
-
} =
|
|
1427
|
-
return /* @__PURE__ */ r("div", { ref: t, ...x(
|
|
1418
|
+
} = ke();
|
|
1419
|
+
return /* @__PURE__ */ r("div", { ref: t, ...x(a.div, D.content), children: e });
|
|
1428
1420
|
}
|
|
1429
1421
|
function Wt({
|
|
1430
1422
|
orientation: e = "vertical",
|
|
@@ -1436,8 +1428,8 @@ function Wt({
|
|
|
1436
1428
|
scrollWidth: o,
|
|
1437
1429
|
clientHeight: l,
|
|
1438
1430
|
clientWidth: i
|
|
1439
|
-
} =
|
|
1440
|
-
return (e === "vertical" ? s > l : o > i) ? /* @__PURE__ */ r("div", { ...x(
|
|
1431
|
+
} = ke();
|
|
1432
|
+
return (e === "vertical" ? s > l : o > i) ? /* @__PURE__ */ r("div", { ...x(a.div, D.scrollbar, e === "vertical" ? D.scrollbarVertical : D.scrollbarHorizontal, n ? D.scrollbarVisible : D.scrollbarHidden), children: t }) : null;
|
|
1441
1433
|
}
|
|
1442
1434
|
function Ht({
|
|
1443
1435
|
orientation: e = "vertical"
|
|
@@ -1450,18 +1442,18 @@ function Ht({
|
|
|
1450
1442
|
scrollWidth: l,
|
|
1451
1443
|
clientHeight: i,
|
|
1452
1444
|
clientWidth: c
|
|
1453
|
-
} =
|
|
1454
|
-
y.preventDefault(), d.current = !0,
|
|
1455
|
-
}, [u, t]),
|
|
1445
|
+
} = ke(), d = w(!1), k = w(0), g = w(0), u = e === "vertical", $ = Math.max(u ? i / o * 100 : c / l * 100, 10), M = u ? o - i : l - c, p = u ? i : c, m = $ / 100 * p, f = u ? n : s, v = M > 0 ? f / M * (p - m) : 0, h = u ? D.thumbVertical(`${$}%`, `translateY(${v}px)`) : D.thumbHorizontal(`${$}%`, `translateX(${v}px)`), b = W((y) => {
|
|
1446
|
+
y.preventDefault(), d.current = !0, k.current = u ? y.clientY : y.clientX, g.current = u ? t.current?.scrollTop ?? 0 : t.current?.scrollLeft ?? 0, y.target.setPointerCapture(y.pointerId);
|
|
1447
|
+
}, [u, t]), C = W((y) => {
|
|
1456
1448
|
if (!d.current) return;
|
|
1457
1449
|
const I = t.current;
|
|
1458
1450
|
if (!I) return;
|
|
1459
|
-
const
|
|
1451
|
+
const S = (u ? y.clientY : y.clientX) - k.current, j = M / (p - m), J = S * j;
|
|
1460
1452
|
u ? I.scrollTop = g.current + J : I.scrollLeft = g.current + J;
|
|
1461
|
-
}, [u,
|
|
1453
|
+
}, [u, M, p, m, t]), Q = W(() => {
|
|
1462
1454
|
d.current = !1;
|
|
1463
1455
|
}, []);
|
|
1464
|
-
return /* @__PURE__ */ r("div", { onPointerDown: b, onPointerMove:
|
|
1456
|
+
return /* @__PURE__ */ r("div", { onPointerDown: b, onPointerMove: C, onPointerUp: Q, ...x(a.div, D.thumb, h) });
|
|
1465
1457
|
}
|
|
1466
1458
|
const On = {
|
|
1467
1459
|
Root: zt,
|
|
@@ -1568,8 +1560,8 @@ const On = {
|
|
|
1568
1560
|
$$css: !0
|
|
1569
1561
|
}
|
|
1570
1562
|
}, Ae = R(null);
|
|
1571
|
-
function
|
|
1572
|
-
const e =
|
|
1563
|
+
function ue() {
|
|
1564
|
+
const e = O(Ae);
|
|
1573
1565
|
if (!e) throw new Error("Select compound components must be used within Select.Root");
|
|
1574
1566
|
return e;
|
|
1575
1567
|
}
|
|
@@ -1585,76 +1577,76 @@ function Gt({
|
|
|
1585
1577
|
onValueChange: n,
|
|
1586
1578
|
initialLabels: s
|
|
1587
1579
|
}) {
|
|
1588
|
-
const [o, l] = be(t, e ?? null, n), [i, c] = G(!1), [d,
|
|
1580
|
+
const [o, l] = be(t, e ?? null, n), [i, c] = G(!1), [d, k] = G(s ?? {}), [g, u] = G(null), $ = _(), M = w(null), p = w(null), m = w(/* @__PURE__ */ new Map()), f = w([]), v = W(() => {
|
|
1589
1581
|
c(!1), u(null), p.current?.focus();
|
|
1590
1582
|
}, []), h = W(() => {
|
|
1591
1583
|
c((y) => {
|
|
1592
1584
|
if (y)
|
|
1593
1585
|
u(null);
|
|
1594
1586
|
else {
|
|
1595
|
-
const I = m.current,
|
|
1587
|
+
const I = m.current, S = f.current;
|
|
1596
1588
|
let j = null;
|
|
1597
|
-
for (const J of
|
|
1589
|
+
for (const J of S) {
|
|
1598
1590
|
const L = I.get(J);
|
|
1599
1591
|
if (L && L.value === o) {
|
|
1600
1592
|
j = J;
|
|
1601
1593
|
break;
|
|
1602
1594
|
}
|
|
1603
1595
|
}
|
|
1604
|
-
u(j ?? (
|
|
1596
|
+
u(j ?? (S.length > 0 ? S[0] : null));
|
|
1605
1597
|
}
|
|
1606
1598
|
return !y;
|
|
1607
1599
|
});
|
|
1608
1600
|
}, [o]), b = W((y, I) => {
|
|
1609
|
-
|
|
1610
|
-
...
|
|
1601
|
+
k((S) => S[y] === I ? S : {
|
|
1602
|
+
...S,
|
|
1611
1603
|
[y]: I
|
|
1612
1604
|
});
|
|
1613
|
-
}, []),
|
|
1605
|
+
}, []), C = W((y, I, S) => {
|
|
1614
1606
|
m.current.set(y, {
|
|
1615
1607
|
value: I,
|
|
1616
|
-
element:
|
|
1608
|
+
element: S
|
|
1617
1609
|
});
|
|
1618
1610
|
const j = m.current, J = [...j.keys()];
|
|
1619
1611
|
return J.sort((L, K) => {
|
|
1620
|
-
const
|
|
1621
|
-
return !
|
|
1612
|
+
const Se = j.get(L)?.element, je = j.get(K)?.element;
|
|
1613
|
+
return !Se || !je ? 0 : Se.compareDocumentPosition(je) & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : 1;
|
|
1622
1614
|
}), f.current = J, () => {
|
|
1623
1615
|
m.current.delete(y), f.current = f.current.filter((L) => L !== y);
|
|
1624
1616
|
};
|
|
1625
1617
|
}, []);
|
|
1626
1618
|
return H(() => {
|
|
1627
|
-
const y =
|
|
1619
|
+
const y = M.current;
|
|
1628
1620
|
if (!y || !i) return;
|
|
1629
|
-
function I(
|
|
1621
|
+
function I(S) {
|
|
1630
1622
|
const j = f.current, J = m.current;
|
|
1631
1623
|
if (j.length !== 0)
|
|
1632
|
-
switch (
|
|
1624
|
+
switch (S.key) {
|
|
1633
1625
|
case "ArrowDown": {
|
|
1634
|
-
|
|
1626
|
+
S.preventDefault(), u((L) => {
|
|
1635
1627
|
const K = L ? j.indexOf(L) : -1;
|
|
1636
1628
|
return j[(K + 1) % j.length];
|
|
1637
1629
|
});
|
|
1638
1630
|
break;
|
|
1639
1631
|
}
|
|
1640
1632
|
case "ArrowUp": {
|
|
1641
|
-
|
|
1633
|
+
S.preventDefault(), u((L) => {
|
|
1642
1634
|
const K = L ? j.indexOf(L) : 0;
|
|
1643
1635
|
return j[(K - 1 + j.length) % j.length];
|
|
1644
1636
|
});
|
|
1645
1637
|
break;
|
|
1646
1638
|
}
|
|
1647
1639
|
case "Home": {
|
|
1648
|
-
|
|
1640
|
+
S.preventDefault(), u(j[0]);
|
|
1649
1641
|
break;
|
|
1650
1642
|
}
|
|
1651
1643
|
case "End": {
|
|
1652
|
-
|
|
1644
|
+
S.preventDefault(), u(j[j.length - 1]);
|
|
1653
1645
|
break;
|
|
1654
1646
|
}
|
|
1655
1647
|
case "Enter":
|
|
1656
1648
|
case " ": {
|
|
1657
|
-
|
|
1649
|
+
S.preventDefault(), u((L) => {
|
|
1658
1650
|
if (L) {
|
|
1659
1651
|
const K = J.get(L);
|
|
1660
1652
|
K && (l(K.value), v());
|
|
@@ -1683,10 +1675,10 @@ function Gt({
|
|
|
1683
1675
|
listboxId: $,
|
|
1684
1676
|
highlightedId: g,
|
|
1685
1677
|
setHighlightedId: u,
|
|
1686
|
-
registerItem:
|
|
1678
|
+
registerItem: C,
|
|
1687
1679
|
triggerRef: p
|
|
1688
|
-
}), [i, h, v, o, l, d, b, $, g, u,
|
|
1689
|
-
rootRef:
|
|
1680
|
+
}), [i, h, v, o, l, d, b, $, g, u, C]),
|
|
1681
|
+
rootRef: M
|
|
1690
1682
|
};
|
|
1691
1683
|
}
|
|
1692
1684
|
function Lt({
|
|
@@ -1706,8 +1698,8 @@ function Lt({
|
|
|
1706
1698
|
onValueChange: s,
|
|
1707
1699
|
initialLabels: o
|
|
1708
1700
|
});
|
|
1709
|
-
return /* @__PURE__ */ r(Ae.Provider, { value: i, children: /* @__PURE__ */ z("div", { ref: c, ...x(
|
|
1710
|
-
e && /* @__PURE__ */ r("input", { type: "hidden", name: e, value: i.value ?? "", dir: "auto", ...x(
|
|
1701
|
+
return /* @__PURE__ */ r(Ae.Provider, { value: i, children: /* @__PURE__ */ z("div", { ref: c, ...x(a.div, Y.root), children: [
|
|
1702
|
+
e && /* @__PURE__ */ r("input", { type: "hidden", name: e, value: i.value ?? "", dir: "auto", ...x(a.input) }),
|
|
1711
1703
|
l
|
|
1712
1704
|
] }) });
|
|
1713
1705
|
}
|
|
@@ -1720,10 +1712,10 @@ function Tt({
|
|
|
1720
1712
|
listboxId: s,
|
|
1721
1713
|
highlightedId: o,
|
|
1722
1714
|
triggerRef: l
|
|
1723
|
-
} =
|
|
1715
|
+
} = ue(), i = w(null);
|
|
1724
1716
|
return H(() => {
|
|
1725
1717
|
l.current = i.current;
|
|
1726
|
-
}), /* @__PURE__ */ r("button", { ref: i, type: "button", role: "combobox", onClick: n, "aria-expanded": t, "aria-haspopup": "listbox", "aria-controls": t ? s : void 0, "aria-activedescendant": o ?? void 0, ...x(
|
|
1718
|
+
}), /* @__PURE__ */ r("button", { ref: i, type: "button", role: "combobox", onClick: n, "aria-expanded": t, "aria-haspopup": "listbox", "aria-controls": t ? s : void 0, "aria-activedescendant": o ?? void 0, ...x(a.button, Y.trigger), children: e });
|
|
1727
1719
|
}
|
|
1728
1720
|
function Et({
|
|
1729
1721
|
placeholder: e
|
|
@@ -1731,13 +1723,13 @@ function Et({
|
|
|
1731
1723
|
const {
|
|
1732
1724
|
value: t,
|
|
1733
1725
|
labels: n
|
|
1734
|
-
} =
|
|
1735
|
-
return /* @__PURE__ */ r("span", { ...x(
|
|
1726
|
+
} = ue(), s = t ? n[t] ?? t : null;
|
|
1727
|
+
return /* @__PURE__ */ r("span", { ...x(a.span, s ? Y.value : Y.placeholder), children: s ?? e });
|
|
1736
1728
|
}
|
|
1737
1729
|
function Vt({
|
|
1738
1730
|
children: e
|
|
1739
1731
|
}) {
|
|
1740
|
-
return /* @__PURE__ */ r("span", { ...x(
|
|
1732
|
+
return /* @__PURE__ */ r("span", { ...x(a.span, Y.icon), children: e ?? /* @__PURE__ */ r("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: /* @__PURE__ */ r("path", { d: "M6 9l6 6 6-6" }) }) });
|
|
1741
1733
|
}
|
|
1742
1734
|
function At({
|
|
1743
1735
|
children: e
|
|
@@ -1746,10 +1738,10 @@ function At({
|
|
|
1746
1738
|
open: t,
|
|
1747
1739
|
close: n,
|
|
1748
1740
|
listboxId: s
|
|
1749
|
-
} =
|
|
1750
|
-
return /* @__PURE__ */ z(
|
|
1751
|
-
t && /* @__PURE__ */ r("div", { ...x(
|
|
1752
|
-
/* @__PURE__ */ r("div", { id: s, role: "listbox", "aria-hidden": !t, ...x(
|
|
1741
|
+
} = ue();
|
|
1742
|
+
return /* @__PURE__ */ z(B, { children: [
|
|
1743
|
+
t && /* @__PURE__ */ r("div", { ...x(a.div, Y.backdrop), onClick: n }),
|
|
1744
|
+
/* @__PURE__ */ r("div", { id: s, role: "listbox", "aria-hidden": !t, ...x(a.div, Y.popup, !t && Y.hidden), children: e })
|
|
1753
1745
|
] });
|
|
1754
1746
|
}
|
|
1755
1747
|
function Nt({
|
|
@@ -1764,7 +1756,7 @@ function Nt({
|
|
|
1764
1756
|
highlightedId: i,
|
|
1765
1757
|
setHighlightedId: c,
|
|
1766
1758
|
registerItem: d
|
|
1767
|
-
} =
|
|
1759
|
+
} = ue(), k = _(), g = w(null), u = n === e, $ = i === k;
|
|
1768
1760
|
return H(() => {
|
|
1769
1761
|
const p = g.current;
|
|
1770
1762
|
if (!p) return;
|
|
@@ -1773,15 +1765,15 @@ function Nt({
|
|
|
1773
1765
|
}, [e, l]), H(() => {
|
|
1774
1766
|
const p = g.current;
|
|
1775
1767
|
if (p)
|
|
1776
|
-
return d(
|
|
1777
|
-
}, [
|
|
1768
|
+
return d(k, e, p);
|
|
1769
|
+
}, [k, e, d]), /* @__PURE__ */ r("div", { ref: g, id: k, role: "option", "aria-selected": u, onClick: () => {
|
|
1778
1770
|
s(e), o();
|
|
1779
|
-
}, onPointerEnter: () => c(
|
|
1771
|
+
}, onPointerEnter: () => c(k), ...x(a.div, Y.item, u && Y.itemSelected, $ && Y.itemHighlighted), children: t });
|
|
1780
1772
|
}
|
|
1781
1773
|
function Ot({
|
|
1782
1774
|
children: e
|
|
1783
1775
|
}) {
|
|
1784
|
-
return /* @__PURE__ */ r("span", { ...x(
|
|
1776
|
+
return /* @__PURE__ */ r("span", { ...x(a.span), children: e });
|
|
1785
1777
|
}
|
|
1786
1778
|
const Cn = {
|
|
1787
1779
|
Root: Lt,
|
|
@@ -1872,7 +1864,7 @@ const Cn = {
|
|
|
1872
1864
|
}
|
|
1873
1865
|
}, Ne = R(null);
|
|
1874
1866
|
function Oe() {
|
|
1875
|
-
const e =
|
|
1867
|
+
const e = O(Ne);
|
|
1876
1868
|
if (!e) throw new Error("SideNav compound components must be used within SideNav.Root");
|
|
1877
1869
|
return e;
|
|
1878
1870
|
}
|
|
@@ -1884,10 +1876,10 @@ function Ct({
|
|
|
1884
1876
|
}) {
|
|
1885
1877
|
const [o, l] = be(t, n ?? null, s ? (u) => {
|
|
1886
1878
|
u !== null && s(u);
|
|
1887
|
-
} : void 0), [i, c] = G(/* @__PURE__ */ new Set()), d = w([]),
|
|
1879
|
+
} : void 0), [i, c] = G(/* @__PURE__ */ new Set()), d = w([]), k = W((u) => {
|
|
1888
1880
|
c(($) => {
|
|
1889
|
-
const
|
|
1890
|
-
return
|
|
1881
|
+
const M = new Set($);
|
|
1882
|
+
return M.has(u) ? M.delete(u) : M.add(u), M;
|
|
1891
1883
|
});
|
|
1892
1884
|
}, []), g = W((u) => (d.current.includes(u) || d.current.push(u), () => {
|
|
1893
1885
|
d.current = d.current.filter(($) => $ !== u);
|
|
@@ -1898,10 +1890,10 @@ function Ct({
|
|
|
1898
1890
|
activeValue: o,
|
|
1899
1891
|
onSelect: l,
|
|
1900
1892
|
expandedGroups: i,
|
|
1901
|
-
toggleGroup:
|
|
1893
|
+
toggleGroup: k,
|
|
1902
1894
|
registerItem: g,
|
|
1903
1895
|
orderRef: d
|
|
1904
|
-
}, children: /* @__PURE__ */ r("nav", { role: "navigation", ...x(
|
|
1896
|
+
}, children: /* @__PURE__ */ r("nav", { role: "navigation", ...x(a.nav, U.root), children: e }) });
|
|
1905
1897
|
}
|
|
1906
1898
|
function Bt({
|
|
1907
1899
|
children: e,
|
|
@@ -1913,19 +1905,19 @@ function Bt({
|
|
|
1913
1905
|
expandedGroups: l,
|
|
1914
1906
|
toggleGroup: i,
|
|
1915
1907
|
activeValue: c
|
|
1916
|
-
} = Oe(), d = l.has(o),
|
|
1908
|
+
} = Oe(), d = l.has(o), k = w(null);
|
|
1917
1909
|
H(() => {
|
|
1918
1910
|
if (!c || l.has(o)) return;
|
|
1919
|
-
const u =
|
|
1911
|
+
const u = k.current;
|
|
1920
1912
|
if (!u) return;
|
|
1921
1913
|
u.querySelector(`[data-nav-value="${c}"]`) && i(o);
|
|
1922
1914
|
}, [c, o, l, i]), H(() => {
|
|
1923
1915
|
s && !l.has(o) && i(o);
|
|
1924
1916
|
}, []);
|
|
1925
|
-
const g = !c || !
|
|
1926
|
-
return /* @__PURE__ */ z("div", { ref:
|
|
1927
|
-
/* @__PURE__ */ z("button", { type: "button", onClick: () => i(o), ...x(
|
|
1928
|
-
/* @__PURE__ */ r("span", { ...x(
|
|
1917
|
+
const g = !c || !k.current ? !1 : !!k.current.querySelector(`[data-nav-value="${c}"]`);
|
|
1918
|
+
return /* @__PURE__ */ z("div", { ref: k, ...x(a.div, U.group), children: [
|
|
1919
|
+
/* @__PURE__ */ z("button", { type: "button", onClick: () => i(o), ...x(a.button, U.groupTrigger, g && U.groupTriggerActive), "aria-expanded": d, children: [
|
|
1920
|
+
/* @__PURE__ */ r("span", { ...x(a.span, U.chevron, d && U.chevronOpen), children: /* @__PURE__ */ r("svg", { width: 10, height: 10, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2.5, strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ r("path", { d: "M9 18l6-6-6-6" }) }) }),
|
|
1929
1921
|
t
|
|
1930
1922
|
] }),
|
|
1931
1923
|
d && e
|
|
@@ -1940,7 +1932,7 @@ function Dt({
|
|
|
1940
1932
|
onSelect: s,
|
|
1941
1933
|
registerItem: o
|
|
1942
1934
|
} = Oe(), l = n === e;
|
|
1943
|
-
return H(() => o(e), [e, o]), /* @__PURE__ */ r("button", { type: "button", "data-nav-value": e, onClick: () => s(e), ...x(
|
|
1935
|
+
return H(() => o(e), [e, o]), /* @__PURE__ */ r("button", { type: "button", "data-nav-value": e, onClick: () => s(e), ...x(a.button, U.item, l && U.itemActive), "aria-current": l ? "page" : void 0, children: t });
|
|
1944
1936
|
}
|
|
1945
1937
|
const Bn = {
|
|
1946
1938
|
Root: Ct,
|
|
@@ -1999,9 +1991,9 @@ function Dn({
|
|
|
1999
1991
|
size: e = "md",
|
|
2000
1992
|
label: t = "Loading"
|
|
2001
1993
|
}) {
|
|
2002
|
-
return /* @__PURE__ */ z("div", { role: "status", ...x(
|
|
2003
|
-
/* @__PURE__ */ r("div", { ...x(
|
|
2004
|
-
/* @__PURE__ */ r("span", { ...x(
|
|
1994
|
+
return /* @__PURE__ */ z("div", { role: "status", ...x(a.div, se.root), children: [
|
|
1995
|
+
/* @__PURE__ */ r("div", { ...x(a.div, se.spinner, Rt[e]), "aria-hidden": !0 }),
|
|
1996
|
+
/* @__PURE__ */ r("span", { ...x(a.span, se.srOnly), children: t })
|
|
2005
1997
|
] });
|
|
2006
1998
|
}
|
|
2007
1999
|
const ze = {
|
|
@@ -2038,7 +2030,7 @@ function Rn({
|
|
|
2038
2030
|
size: t = 48,
|
|
2039
2031
|
variant: n = "muted"
|
|
2040
2032
|
}) {
|
|
2041
|
-
return /* @__PURE__ */ r("div", { ...x(
|
|
2033
|
+
return /* @__PURE__ */ r("div", { ...x(a.div, ze.root, ze[n]), children: /* @__PURE__ */ r(ve, { name: e, size: t }) });
|
|
2042
2034
|
}
|
|
2043
2035
|
const Xt = {
|
|
2044
2036
|
kumcoG: "xqketvx",
|
|
@@ -2123,8 +2115,8 @@ const Xt = {
|
|
|
2123
2115
|
"--x-gridTemplateColumns": `repeat(${e}, 1fr)` != null ? `repeat(${e}, 1fr)` : void 0
|
|
2124
2116
|
}]
|
|
2125
2117
|
}, Ce = R(null);
|
|
2126
|
-
function
|
|
2127
|
-
const e =
|
|
2118
|
+
function de() {
|
|
2119
|
+
const e = O(Ce);
|
|
2128
2120
|
if (!e) throw new Error("Table compound components must be used within Table.Root");
|
|
2129
2121
|
return e;
|
|
2130
2122
|
}
|
|
@@ -2140,20 +2132,20 @@ function Yt({
|
|
|
2140
2132
|
size: n,
|
|
2141
2133
|
columns: s,
|
|
2142
2134
|
isHeader: !1
|
|
2143
|
-
}, children: /* @__PURE__ */ r("div", { role: "table", ...x(
|
|
2135
|
+
}, children: /* @__PURE__ */ r("div", { role: "table", ...x(a.div, V.root), children: e }) });
|
|
2144
2136
|
}
|
|
2145
2137
|
function Jt({
|
|
2146
2138
|
children: e
|
|
2147
2139
|
}) {
|
|
2148
|
-
return /* @__PURE__ */ r(ye.Provider, { value: !0, children: /* @__PURE__ */ r("div", { role: "rowgroup", ...x(
|
|
2140
|
+
return /* @__PURE__ */ r(ye.Provider, { value: !0, children: /* @__PURE__ */ r("div", { role: "rowgroup", ...x(a.div, V.header), children: e }) });
|
|
2149
2141
|
}
|
|
2150
2142
|
function Pt({
|
|
2151
2143
|
children: e
|
|
2152
2144
|
}) {
|
|
2153
2145
|
const {
|
|
2154
2146
|
variant: t
|
|
2155
|
-
} =
|
|
2156
|
-
return /* @__PURE__ */ r(ye.Provider, { value: !1, children: /* @__PURE__ */ r("div", { role: "rowgroup", ...x(
|
|
2147
|
+
} = de(), n = qe.toArray(e);
|
|
2148
|
+
return /* @__PURE__ */ r(ye.Provider, { value: !1, children: /* @__PURE__ */ r("div", { role: "rowgroup", ...x(a.div), children: n.map((s, o) => t === "striped" ? /* @__PURE__ */ r(Be.Provider, { value: o, children: s }, o) : s) }) });
|
|
2157
2149
|
}
|
|
2158
2150
|
const Be = R(-1);
|
|
2159
2151
|
function Ft({
|
|
@@ -2162,8 +2154,8 @@ function Ft({
|
|
|
2162
2154
|
const {
|
|
2163
2155
|
variant: t,
|
|
2164
2156
|
columns: n
|
|
2165
|
-
} =
|
|
2166
|
-
return /* @__PURE__ */ r("div", { role: "row", ...x(
|
|
2157
|
+
} = de(), s = O(ye), o = O(Be), l = o >= 0 && o % 2 === 1, i = qe.toArray(e);
|
|
2158
|
+
return /* @__PURE__ */ r("div", { role: "row", ...x(a.div, V.row, V.gridColumns(n), !s && V.bodyRow, !s && t === "striped" && l && V.stripedEven), children: t === "bordered" ? i.map((c, d) => /* @__PURE__ */ r(we.Provider, { value: {
|
|
2167
2159
|
index: d,
|
|
2168
2160
|
total: i.length
|
|
2169
2161
|
}, children: c }, d)) : e });
|
|
@@ -2178,11 +2170,11 @@ function Qt({
|
|
|
2178
2170
|
const {
|
|
2179
2171
|
size: t,
|
|
2180
2172
|
variant: n
|
|
2181
|
-
} =
|
|
2173
|
+
} = de(), {
|
|
2182
2174
|
index: s,
|
|
2183
2175
|
total: o
|
|
2184
|
-
} =
|
|
2185
|
-
return /* @__PURE__ */ r("div", { role: "columnheader", ...x(
|
|
2176
|
+
} = O(we), l = n === "bordered" && s === o - 1;
|
|
2177
|
+
return /* @__PURE__ */ r("div", { role: "columnheader", ...x(a.div, V.headerCell, t === "sm" ? V.cellSm : V.cellMd, n === "bordered" && V.borderedCell, l && V.borderedCellLast), children: e });
|
|
2186
2178
|
}
|
|
2187
2179
|
function Kt({
|
|
2188
2180
|
children: e
|
|
@@ -2190,11 +2182,11 @@ function Kt({
|
|
|
2190
2182
|
const {
|
|
2191
2183
|
size: t,
|
|
2192
2184
|
variant: n
|
|
2193
|
-
} =
|
|
2185
|
+
} = de(), {
|
|
2194
2186
|
index: s,
|
|
2195
2187
|
total: o
|
|
2196
|
-
} =
|
|
2197
|
-
return /* @__PURE__ */ r("div", { role: "cell", ...x(
|
|
2188
|
+
} = O(we), l = n === "bordered" && s === o - 1;
|
|
2189
|
+
return /* @__PURE__ */ r("div", { role: "cell", ...x(a.div, V.cell, t === "sm" ? V.cellSm : V.cellMd, n === "bordered" && V.borderedCell, l && V.borderedCellLast), children: e });
|
|
2198
2190
|
}
|
|
2199
2191
|
const Xn = {
|
|
2200
2192
|
Root: Yt,
|
|
@@ -2292,8 +2284,8 @@ const Xn = {
|
|
|
2292
2284
|
$$css: !0
|
|
2293
2285
|
}
|
|
2294
2286
|
}, De = R(null);
|
|
2295
|
-
function
|
|
2296
|
-
const e =
|
|
2287
|
+
function Me() {
|
|
2288
|
+
const e = O(De);
|
|
2297
2289
|
if (!e) throw new Error("Tabs compound components must be used within Tabs.Root");
|
|
2298
2290
|
return e;
|
|
2299
2291
|
}
|
|
@@ -2303,10 +2295,10 @@ function Ut({
|
|
|
2303
2295
|
onValueChange: n,
|
|
2304
2296
|
orientation: s = "horizontal"
|
|
2305
2297
|
}) {
|
|
2306
|
-
const [o, l] = be(e, t ?? null, n ? (
|
|
2307
|
-
|
|
2308
|
-
} : void 0), i = w(/* @__PURE__ */ new Map()), c = w([]), d = W((
|
|
2309
|
-
i.current.delete(
|
|
2298
|
+
const [o, l] = be(e, t ?? null, n ? (k) => {
|
|
2299
|
+
k !== null && n(k);
|
|
2300
|
+
} : void 0), i = w(/* @__PURE__ */ new Map()), c = w([]), d = W((k, g) => (i.current.set(k, g), c.current.includes(k) || c.current.push(k), () => {
|
|
2301
|
+
i.current.delete(k), c.current = c.current.filter((u) => u !== k);
|
|
2310
2302
|
}), []);
|
|
2311
2303
|
return {
|
|
2312
2304
|
activeValue: o,
|
|
@@ -2330,7 +2322,7 @@ function _t({
|
|
|
2330
2322
|
onValueChange: s,
|
|
2331
2323
|
orientation: o
|
|
2332
2324
|
});
|
|
2333
|
-
return /* @__PURE__ */ r(De.Provider, { value: l, children: /* @__PURE__ */ r("div", { ...x(
|
|
2325
|
+
return /* @__PURE__ */ r(De.Provider, { value: l, children: /* @__PURE__ */ r("div", { ...x(a.div, X.root, o === "vertical" && X.rootVertical), children: e }) });
|
|
2334
2326
|
}
|
|
2335
2327
|
function Zt({
|
|
2336
2328
|
children: e
|
|
@@ -2341,18 +2333,18 @@ function Zt({
|
|
|
2341
2333
|
onSelect: s,
|
|
2342
2334
|
tabsRef: o,
|
|
2343
2335
|
orderRef: l
|
|
2344
|
-
} =
|
|
2336
|
+
} = Me(), i = w(null);
|
|
2345
2337
|
return H(() => {
|
|
2346
2338
|
const c = i.current;
|
|
2347
2339
|
if (!c) return;
|
|
2348
|
-
function d(
|
|
2340
|
+
function d(k) {
|
|
2349
2341
|
const g = l.current, u = o.current;
|
|
2350
2342
|
if (g.length === 0) return;
|
|
2351
|
-
const $ = this,
|
|
2343
|
+
const $ = this, M = t === "horizontal" ? "ArrowLeft" : "ArrowUp", p = t === "horizontal" ? "ArrowRight" : "ArrowDown";
|
|
2352
2344
|
let m = null;
|
|
2353
|
-
switch (
|
|
2345
|
+
switch (k.key) {
|
|
2354
2346
|
case p: {
|
|
2355
|
-
|
|
2347
|
+
k.preventDefault();
|
|
2356
2348
|
const f = n ? g.indexOf(n) : -1;
|
|
2357
2349
|
for (let v = 1; v <= g.length; v++) {
|
|
2358
2350
|
const h = (f + v) % g.length, b = g[h];
|
|
@@ -2363,8 +2355,8 @@ function Zt({
|
|
|
2363
2355
|
}
|
|
2364
2356
|
break;
|
|
2365
2357
|
}
|
|
2366
|
-
case
|
|
2367
|
-
|
|
2358
|
+
case M: {
|
|
2359
|
+
k.preventDefault();
|
|
2368
2360
|
const f = n ? g.indexOf(n) : 0;
|
|
2369
2361
|
for (let v = 1; v <= g.length; v++) {
|
|
2370
2362
|
const h = (f - v + g.length) % g.length, b = g[h];
|
|
@@ -2376,7 +2368,7 @@ function Zt({
|
|
|
2376
2368
|
break;
|
|
2377
2369
|
}
|
|
2378
2370
|
case "Home": {
|
|
2379
|
-
|
|
2371
|
+
k.preventDefault();
|
|
2380
2372
|
for (const f of g)
|
|
2381
2373
|
if (!u.get(f)) {
|
|
2382
2374
|
m = f;
|
|
@@ -2385,7 +2377,7 @@ function Zt({
|
|
|
2385
2377
|
break;
|
|
2386
2378
|
}
|
|
2387
2379
|
case "End": {
|
|
2388
|
-
|
|
2380
|
+
k.preventDefault();
|
|
2389
2381
|
for (let f = g.length - 1; f >= 0; f--)
|
|
2390
2382
|
if (!u.get(g[f])) {
|
|
2391
2383
|
m = g[f];
|
|
@@ -2397,7 +2389,7 @@ function Zt({
|
|
|
2397
2389
|
m && (s(m), $.querySelector(`[data-tab-value="${m}"]`)?.focus());
|
|
2398
2390
|
}
|
|
2399
2391
|
return c.addEventListener("keydown", d), () => c.removeEventListener("keydown", d);
|
|
2400
|
-
}, [t, n, s, o, l]), /* @__PURE__ */ r("div", { ref: i, role: "tablist", "aria-orientation": t, ...x(
|
|
2392
|
+
}, [t, n, s, o, l]), /* @__PURE__ */ r("div", { ref: i, role: "tablist", "aria-orientation": t, ...x(a.div, X.list, t === "vertical" && X.listVertical), children: e });
|
|
2401
2393
|
}
|
|
2402
2394
|
function en({
|
|
2403
2395
|
value: e,
|
|
@@ -2409,10 +2401,10 @@ function en({
|
|
|
2409
2401
|
onSelect: o,
|
|
2410
2402
|
orientation: l,
|
|
2411
2403
|
registerTab: i
|
|
2412
|
-
} =
|
|
2413
|
-
return H(() => i(e, t), [e, t, i]), /* @__PURE__ */ r("button", { type: "button", role: "tab", id: d, "aria-selected": c, "aria-controls":
|
|
2404
|
+
} = Me(), c = s === e, d = _(), k = `${d}-panel`;
|
|
2405
|
+
return H(() => i(e, t), [e, t, i]), /* @__PURE__ */ r("button", { type: "button", role: "tab", id: d, "aria-selected": c, "aria-controls": k, "aria-disabled": t || void 0, "data-tab-value": e, tabIndex: c ? 0 : -1, onClick: () => {
|
|
2414
2406
|
t || o(e);
|
|
2415
|
-
}, ...x(
|
|
2407
|
+
}, ...x(a.button, X.tab, l === "vertical" && X.tabVertical, c && (l === "vertical" ? X.tabActiveVertical : X.tabActiveHorizontal), t && X.tabDisabled), children: n });
|
|
2416
2408
|
}
|
|
2417
2409
|
function tn({
|
|
2418
2410
|
value: e,
|
|
@@ -2421,8 +2413,8 @@ function tn({
|
|
|
2421
2413
|
const {
|
|
2422
2414
|
activeValue: n,
|
|
2423
2415
|
orientation: s
|
|
2424
|
-
} =
|
|
2425
|
-
return n !== e ? null : /* @__PURE__ */ r("div", { role: "tabpanel", ...x(
|
|
2416
|
+
} = Me();
|
|
2417
|
+
return n !== e ? null : /* @__PURE__ */ r("div", { role: "tabpanel", ...x(a.div, X.panel, s === "vertical" && X.panelVertical), children: t });
|
|
2426
2418
|
}
|
|
2427
2419
|
const Yn = {
|
|
2428
2420
|
Root: _t,
|
|
@@ -2474,8 +2466,8 @@ function Jn({
|
|
|
2474
2466
|
disabled: c,
|
|
2475
2467
|
onChange: d
|
|
2476
2468
|
}) {
|
|
2477
|
-
const
|
|
2478
|
-
return /* @__PURE__ */ r("textarea", { id:
|
|
2469
|
+
const k = ie();
|
|
2470
|
+
return /* @__PURE__ */ r("textarea", { id: k?.controlId, name: t, placeholder: n, required: s, rows: o, value: l, defaultValue: i, disabled: c, "aria-describedby": k ? `${k.descriptionId} ${k.invalid ? k.errorId : ""}`.trim() : void 0, "aria-invalid": k?.invalid || e === "error" || void 0, onChange: d, ...x(a.textarea, Ie.base, Ie[e]), dir: "auto" });
|
|
2479
2471
|
}
|
|
2480
2472
|
const Pn = {
|
|
2481
2473
|
bg: "var(--bg-xqkwqtp)",
|
|
@@ -2722,7 +2714,7 @@ function tr({
|
|
|
2722
2714
|
children: t
|
|
2723
2715
|
}) {
|
|
2724
2716
|
const n = cn[e], s = [n?.[0], n?.[1], ln.root];
|
|
2725
|
-
return /* @__PURE__ */ r("div", { ...x(
|
|
2717
|
+
return /* @__PURE__ */ r("div", { ...x(a.div, s), children: t });
|
|
2726
2718
|
}
|
|
2727
2719
|
const F = {
|
|
2728
2720
|
default: {
|
|
@@ -2788,7 +2780,7 @@ const F = {
|
|
|
2788
2780
|
medium: F.weightMedium,
|
|
2789
2781
|
semibold: F.weightSemibold,
|
|
2790
2782
|
bold: F.weightBold
|
|
2791
|
-
},
|
|
2783
|
+
}, an = {
|
|
2792
2784
|
start: F.alignStart,
|
|
2793
2785
|
center: F.alignCenter,
|
|
2794
2786
|
end: F.alignEnd
|
|
@@ -2802,8 +2794,8 @@ function nr({
|
|
|
2802
2794
|
as: l = "span",
|
|
2803
2795
|
children: i
|
|
2804
2796
|
}) {
|
|
2805
|
-
const c = [Ge[e], F[t], n && xn[n], s &&
|
|
2806
|
-
return l === "p" ? /* @__PURE__ */ r("p", { ...x(
|
|
2797
|
+
const c = [Ge[e], F[t], n && xn[n], s && an[s], o && F.truncate];
|
|
2798
|
+
return l === "p" ? /* @__PURE__ */ r("p", { ...x(a.p, c), children: i }) : l === "div" ? /* @__PURE__ */ r("div", { ...x(a.div, c), children: i }) : /* @__PURE__ */ r("span", { ...x(a.span, c), children: i });
|
|
2807
2799
|
}
|
|
2808
2800
|
const fe = {
|
|
2809
2801
|
root: {
|
|
@@ -2861,8 +2853,8 @@ const fe = {
|
|
|
2861
2853
|
$$css: !0
|
|
2862
2854
|
}
|
|
2863
2855
|
}, Re = R(null);
|
|
2864
|
-
function
|
|
2865
|
-
const e =
|
|
2856
|
+
function kn() {
|
|
2857
|
+
const e = O(Re);
|
|
2866
2858
|
if (!e) throw new Error("Tooltip compound components must be used within Tooltip.Root");
|
|
2867
2859
|
return e;
|
|
2868
2860
|
}
|
|
@@ -2874,18 +2866,18 @@ function un({
|
|
|
2874
2866
|
}) {
|
|
2875
2867
|
const [o, l] = G(!1), i = _(), c = w(null), d = W(() => {
|
|
2876
2868
|
c.current && clearTimeout(c.current), c.current = setTimeout(() => l(!0), s);
|
|
2877
|
-
}, [s]),
|
|
2869
|
+
}, [s]), k = W(() => {
|
|
2878
2870
|
c.current && clearTimeout(c.current), c.current = null, l(!1);
|
|
2879
2871
|
}, []);
|
|
2880
2872
|
return /* @__PURE__ */ r(Re.Provider, { value: {
|
|
2881
2873
|
open: o,
|
|
2882
2874
|
show: d,
|
|
2883
|
-
hide:
|
|
2875
|
+
hide: k,
|
|
2884
2876
|
tooltipId: i,
|
|
2885
2877
|
placement: n
|
|
2886
|
-
}, children: /* @__PURE__ */ z("div", { ...x(
|
|
2878
|
+
}, children: /* @__PURE__ */ z("div", { ...x(a.div, fe.root), children: [
|
|
2887
2879
|
e,
|
|
2888
|
-
o && /* @__PURE__ */ r("div", { id: i, role: "tooltip", ...x(
|
|
2880
|
+
o && /* @__PURE__ */ r("div", { id: i, role: "tooltip", ...x(a.div, fe.popup, fe[n]), children: t })
|
|
2889
2881
|
] }) });
|
|
2890
2882
|
}
|
|
2891
2883
|
function dn({
|
|
@@ -2896,13 +2888,13 @@ function dn({
|
|
|
2896
2888
|
show: n,
|
|
2897
2889
|
hide: s,
|
|
2898
2890
|
tooltipId: o
|
|
2899
|
-
} =
|
|
2900
|
-
return /* @__PURE__ */ r("div", { onPointerEnter: n, onPointerLeave: s, onFocus: n, onBlur: s, "aria-describedby": t ? o : void 0, ...x(
|
|
2891
|
+
} = kn();
|
|
2892
|
+
return /* @__PURE__ */ r("div", { onPointerEnter: n, onPointerLeave: s, onFocus: n, onBlur: s, "aria-describedby": t ? o : void 0, ...x(a.div), children: e });
|
|
2901
2893
|
}
|
|
2902
2894
|
const rr = {
|
|
2903
2895
|
Root: un,
|
|
2904
2896
|
Trigger: dn
|
|
2905
|
-
},
|
|
2897
|
+
}, N = {
|
|
2906
2898
|
base: {
|
|
2907
2899
|
k1xSpc: "x78zum5",
|
|
2908
2900
|
kXwgrk: "xdt5ytf",
|
|
@@ -2957,26 +2949,26 @@ const rr = {
|
|
|
2957
2949
|
$$css: !0
|
|
2958
2950
|
}
|
|
2959
2951
|
}, gn = {
|
|
2960
|
-
xs:
|
|
2961
|
-
sm:
|
|
2962
|
-
ms:
|
|
2963
|
-
md:
|
|
2964
|
-
lg:
|
|
2965
|
-
xl:
|
|
2966
|
-
xxl:
|
|
2967
|
-
xxxl:
|
|
2952
|
+
xs: N.gapXs,
|
|
2953
|
+
sm: N.gapSm,
|
|
2954
|
+
ms: N.gapMs,
|
|
2955
|
+
md: N.gapMd,
|
|
2956
|
+
lg: N.gapLg,
|
|
2957
|
+
xl: N.gapXl,
|
|
2958
|
+
xxl: N.gapXxl,
|
|
2959
|
+
xxxl: N.gapXxxl
|
|
2968
2960
|
}, hn = {
|
|
2969
|
-
start:
|
|
2970
|
-
center:
|
|
2971
|
-
end:
|
|
2972
|
-
stretch:
|
|
2961
|
+
start: N.alignStart,
|
|
2962
|
+
center: N.alignCenter,
|
|
2963
|
+
end: N.alignEnd,
|
|
2964
|
+
stretch: N.alignStretch
|
|
2973
2965
|
};
|
|
2974
2966
|
function sr({
|
|
2975
2967
|
gap: e = "md",
|
|
2976
2968
|
align: t = "stretch",
|
|
2977
2969
|
children: n
|
|
2978
2970
|
}) {
|
|
2979
|
-
return /* @__PURE__ */ r("div", { ...x(
|
|
2971
|
+
return /* @__PURE__ */ r("div", { ...x(a.div, N.base, gn[e], hn[t]), children: n });
|
|
2980
2972
|
}
|
|
2981
2973
|
const q = {
|
|
2982
2974
|
base: {
|
|
@@ -3080,7 +3072,7 @@ function or({
|
|
|
3080
3072
|
justify: n = "start",
|
|
3081
3073
|
children: s
|
|
3082
3074
|
}) {
|
|
3083
|
-
return /* @__PURE__ */ r("div", { ...x(
|
|
3075
|
+
return /* @__PURE__ */ r("div", { ...x(a.div, q.base, pn[e], fn[t], vn[n]), children: s });
|
|
3084
3076
|
}
|
|
3085
3077
|
const T = {
|
|
3086
3078
|
base: {
|
|
@@ -3174,7 +3166,7 @@ function ir({
|
|
|
3174
3166
|
justify: n = "start",
|
|
3175
3167
|
children: s
|
|
3176
3168
|
}) {
|
|
3177
|
-
return /* @__PURE__ */ r("div", { ...x(
|
|
3169
|
+
return /* @__PURE__ */ r("div", { ...x(a.div, T.base, $n[e], mn[t], bn[n]), children: s });
|
|
3178
3170
|
}
|
|
3179
3171
|
const yn = {
|
|
3180
3172
|
kumcoG: "xqketvx",
|
|
@@ -3252,7 +3244,7 @@ const yn = {
|
|
|
3252
3244
|
xl: E.gapXl,
|
|
3253
3245
|
xxl: E.gapXxl,
|
|
3254
3246
|
xxxl: E.gapXxxl
|
|
3255
|
-
},
|
|
3247
|
+
}, Mn = {
|
|
3256
3248
|
1: E.col1,
|
|
3257
3249
|
2: E.col2,
|
|
3258
3250
|
3: E.col3,
|
|
@@ -3266,8 +3258,8 @@ function cr({
|
|
|
3266
3258
|
minColumnWidth: n,
|
|
3267
3259
|
children: s
|
|
3268
3260
|
}) {
|
|
3269
|
-
const o = n ? E.autoFit(n) : t ?
|
|
3270
|
-
return /* @__PURE__ */ r("div", { ...x(
|
|
3261
|
+
const o = n ? E.autoFit(n) : t ? Mn[t] : void 0;
|
|
3262
|
+
return /* @__PURE__ */ r("div", { ...x(a.div, E.base, wn[e], o), children: s });
|
|
3271
3263
|
}
|
|
3272
3264
|
function lr(e = {}) {
|
|
3273
3265
|
const {
|
|
@@ -3278,9 +3270,9 @@ function lr(e = {}) {
|
|
|
3278
3270
|
const i = s.current;
|
|
3279
3271
|
if (!i) return;
|
|
3280
3272
|
let c = null;
|
|
3281
|
-
const d = new ResizeObserver((
|
|
3273
|
+
const d = new ResizeObserver((k) => {
|
|
3282
3274
|
c !== null && cancelAnimationFrame(c), c = requestAnimationFrame(() => {
|
|
3283
|
-
const g =
|
|
3275
|
+
const g = k[0];
|
|
3284
3276
|
if (!g) return;
|
|
3285
3277
|
const u = g.contentBoxSize?.[0]?.inlineSize ?? g.contentRect.width;
|
|
3286
3278
|
u < t ? l("compact") : u >= n ? l("spacious") : l("default");
|