vxui-react 1.1.0 → 1.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.cjs +23 -23
- package/dist/index.js +819 -851
- package/dist/vxui-react.css +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { jsx as a, Fragment as q, jsxs as S } from "react/jsx-runtime";
|
|
2
2
|
import * as b from "react";
|
|
3
|
-
import ae, { useState as
|
|
4
|
-
import * as
|
|
5
|
-
import
|
|
6
|
-
const
|
|
7
|
-
function
|
|
3
|
+
import ae, { useState as D, useEffect as O, useContext as ye, createContext as _e, forwardRef as re, createElement as it, useRef as L, useMemo as be, useCallback as U, useId as Ir } from "react";
|
|
4
|
+
import * as sn from "react-dom";
|
|
5
|
+
import Lr from "react-dom";
|
|
6
|
+
const Mr = 767, Or = 1023;
|
|
7
|
+
function It() {
|
|
8
8
|
if (typeof window > "u") return "desktop";
|
|
9
9
|
const e = window.innerWidth;
|
|
10
|
-
return e <=
|
|
10
|
+
return e <= Mr ? "phone" : e <= Or ? "tablet" : "desktop";
|
|
11
11
|
}
|
|
12
|
-
const
|
|
12
|
+
const on = _e({
|
|
13
13
|
viewport: "desktop",
|
|
14
14
|
isPhone: !1,
|
|
15
15
|
isTablet: !1,
|
|
16
16
|
isDesktop: !0
|
|
17
17
|
});
|
|
18
|
-
function
|
|
19
|
-
const [t, n] =
|
|
18
|
+
function bi({ children: e }) {
|
|
19
|
+
const [t, n] = D(It);
|
|
20
20
|
O(() => {
|
|
21
21
|
const s = () => {
|
|
22
|
-
const o =
|
|
22
|
+
const o = It();
|
|
23
23
|
n((l) => l === o ? l : o);
|
|
24
24
|
};
|
|
25
25
|
return window.addEventListener("resize", s, { passive: !0 }), () => window.removeEventListener("resize", s);
|
|
@@ -30,13 +30,13 @@ function yi({ children: e }) {
|
|
|
30
30
|
isTablet: t === "tablet",
|
|
31
31
|
isDesktop: t === "desktop"
|
|
32
32
|
};
|
|
33
|
-
return /* @__PURE__ */ a(
|
|
33
|
+
return /* @__PURE__ */ a(on.Provider, { value: r, children: e });
|
|
34
34
|
}
|
|
35
|
-
function
|
|
36
|
-
return ye(
|
|
35
|
+
function ln() {
|
|
36
|
+
return ye(on);
|
|
37
37
|
}
|
|
38
|
-
function
|
|
39
|
-
const { viewport: r } =
|
|
38
|
+
function xi({ desktop: e, mobile: t, tablet: n }) {
|
|
39
|
+
const { viewport: r } = ln();
|
|
40
40
|
return r === "phone" ? /* @__PURE__ */ a(q, { children: t }) : r === "tablet" ? /* @__PURE__ */ a(q, { children: n ?? e }) : /* @__PURE__ */ a(q, { children: e });
|
|
41
41
|
}
|
|
42
42
|
/**
|
|
@@ -45,13 +45,13 @@ function _i({ desktop: e, mobile: t, tablet: n }) {
|
|
|
45
45
|
* This source code is licensed under the ISC license.
|
|
46
46
|
* See the LICENSE file in the root directory of this source tree.
|
|
47
47
|
*/
|
|
48
|
-
const
|
|
48
|
+
const $r = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), Br = (e) => e.replace(
|
|
49
49
|
/^([A-Z])|[\s-_]+(\w)/g,
|
|
50
50
|
(t, n, r) => r ? r.toUpperCase() : n.toLowerCase()
|
|
51
|
-
),
|
|
52
|
-
const t =
|
|
51
|
+
), Lt = (e) => {
|
|
52
|
+
const t = Br(e);
|
|
53
53
|
return t.charAt(0).toUpperCase() + t.slice(1);
|
|
54
|
-
}, cn = (...e) => e.filter((t, n, r) => !!t && t.trim() !== "" && r.indexOf(t) === n).join(" ").trim(),
|
|
54
|
+
}, cn = (...e) => e.filter((t, n, r) => !!t && t.trim() !== "" && r.indexOf(t) === n).join(" ").trim(), zr = (e) => {
|
|
55
55
|
for (const t in e)
|
|
56
56
|
if (t.startsWith("aria-") || t === "role" || t === "title")
|
|
57
57
|
return !0;
|
|
@@ -62,7 +62,7 @@ const zr = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), Ur = (
|
|
|
62
62
|
* This source code is licensed under the ISC license.
|
|
63
63
|
* See the LICENSE file in the root directory of this source tree.
|
|
64
64
|
*/
|
|
65
|
-
var
|
|
65
|
+
var Ur = {
|
|
66
66
|
xmlns: "http://www.w3.org/2000/svg",
|
|
67
67
|
width: 24,
|
|
68
68
|
height: 24,
|
|
@@ -79,7 +79,7 @@ var Hr = {
|
|
|
79
79
|
* This source code is licensed under the ISC license.
|
|
80
80
|
* See the LICENSE file in the root directory of this source tree.
|
|
81
81
|
*/
|
|
82
|
-
const
|
|
82
|
+
const Wr = re(
|
|
83
83
|
({
|
|
84
84
|
color: e = "currentColor",
|
|
85
85
|
size: t = 24,
|
|
@@ -93,13 +93,13 @@ const Gr = re(
|
|
|
93
93
|
"svg",
|
|
94
94
|
{
|
|
95
95
|
ref: u,
|
|
96
|
-
...
|
|
96
|
+
...Ur,
|
|
97
97
|
width: t,
|
|
98
98
|
height: t,
|
|
99
99
|
stroke: e,
|
|
100
100
|
strokeWidth: r ? Number(n) * 24 / Number(t) : n,
|
|
101
101
|
className: cn("lucide", s),
|
|
102
|
-
...!o && !
|
|
102
|
+
...!o && !zr(i) && { "aria-hidden": "true" },
|
|
103
103
|
...i
|
|
104
104
|
},
|
|
105
105
|
[
|
|
@@ -116,18 +116,18 @@ const Gr = re(
|
|
|
116
116
|
*/
|
|
117
117
|
const X = (e, t) => {
|
|
118
118
|
const n = re(
|
|
119
|
-
({ className: r, ...s }, o) => it(
|
|
119
|
+
({ className: r, ...s }, o) => it(Wr, {
|
|
120
120
|
ref: o,
|
|
121
121
|
iconNode: t,
|
|
122
122
|
className: cn(
|
|
123
|
-
`lucide-${
|
|
123
|
+
`lucide-${$r(Lt(e))}`,
|
|
124
124
|
`lucide-${e}`,
|
|
125
125
|
r
|
|
126
126
|
),
|
|
127
127
|
...s
|
|
128
128
|
})
|
|
129
129
|
);
|
|
130
|
-
return n.displayName =
|
|
130
|
+
return n.displayName = Lt(e), n;
|
|
131
131
|
};
|
|
132
132
|
/**
|
|
133
133
|
* @license lucide-react v0.511.0 - ISC
|
|
@@ -135,102 +135,102 @@ const X = (e, t) => {
|
|
|
135
135
|
* This source code is licensed under the ISC license.
|
|
136
136
|
* See the LICENSE file in the root directory of this source tree.
|
|
137
137
|
*/
|
|
138
|
-
const
|
|
138
|
+
const Hr = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]], vt = X("check", Hr);
|
|
139
139
|
/**
|
|
140
140
|
* @license lucide-react v0.511.0 - ISC
|
|
141
141
|
*
|
|
142
142
|
* This source code is licensed under the ISC license.
|
|
143
143
|
* See the LICENSE file in the root directory of this source tree.
|
|
144
144
|
*/
|
|
145
|
-
const
|
|
145
|
+
const Gr = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]], ht = X("chevron-down", Gr);
|
|
146
146
|
/**
|
|
147
147
|
* @license lucide-react v0.511.0 - ISC
|
|
148
148
|
*
|
|
149
149
|
* This source code is licensed under the ISC license.
|
|
150
150
|
* See the LICENSE file in the root directory of this source tree.
|
|
151
151
|
*/
|
|
152
|
-
const
|
|
152
|
+
const jr = [["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]], un = X("chevron-left", jr);
|
|
153
153
|
/**
|
|
154
154
|
* @license lucide-react v0.511.0 - ISC
|
|
155
155
|
*
|
|
156
156
|
* This source code is licensed under the ISC license.
|
|
157
157
|
* See the LICENSE file in the root directory of this source tree.
|
|
158
158
|
*/
|
|
159
|
-
const
|
|
159
|
+
const Kr = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]], Ue = X("chevron-right", Kr);
|
|
160
160
|
/**
|
|
161
161
|
* @license lucide-react v0.511.0 - ISC
|
|
162
162
|
*
|
|
163
163
|
* This source code is licensed under the ISC license.
|
|
164
164
|
* See the LICENSE file in the root directory of this source tree.
|
|
165
165
|
*/
|
|
166
|
-
const
|
|
166
|
+
const Vr = [
|
|
167
167
|
["rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2", key: "17jyea" }],
|
|
168
168
|
["path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2", key: "zix9uf" }]
|
|
169
|
-
],
|
|
169
|
+
], Yr = X("copy", Vr);
|
|
170
170
|
/**
|
|
171
171
|
* @license lucide-react v0.511.0 - ISC
|
|
172
172
|
*
|
|
173
173
|
* This source code is licensed under the ISC license.
|
|
174
174
|
* See the LICENSE file in the root directory of this source tree.
|
|
175
175
|
*/
|
|
176
|
-
const
|
|
176
|
+
const qr = [
|
|
177
177
|
["path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z", key: "1rqfz7" }],
|
|
178
178
|
["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }]
|
|
179
|
-
],
|
|
179
|
+
], Xr = X("file", qr);
|
|
180
180
|
/**
|
|
181
181
|
* @license lucide-react v0.511.0 - ISC
|
|
182
182
|
*
|
|
183
183
|
* This source code is licensed under the ISC license.
|
|
184
184
|
* See the LICENSE file in the root directory of this source tree.
|
|
185
185
|
*/
|
|
186
|
-
const
|
|
186
|
+
const Zr = [
|
|
187
187
|
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
188
188
|
["path", { d: "M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20", key: "13o1zl" }],
|
|
189
189
|
["path", { d: "M2 12h20", key: "9i4pu4" }]
|
|
190
|
-
],
|
|
190
|
+
], Qr = X("globe", Zr);
|
|
191
191
|
/**
|
|
192
192
|
* @license lucide-react v0.511.0 - ISC
|
|
193
193
|
*
|
|
194
194
|
* This source code is licensed under the ISC license.
|
|
195
195
|
* See the LICENSE file in the root directory of this source tree.
|
|
196
196
|
*/
|
|
197
|
-
const
|
|
197
|
+
const Jr = [
|
|
198
198
|
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
|
|
199
199
|
["path", { d: "M9 3v18", key: "fh3hqa" }],
|
|
200
200
|
["path", { d: "m16 15-3-3 3-3", key: "14y99z" }]
|
|
201
|
-
], dn = X("panel-left-close",
|
|
201
|
+
], dn = X("panel-left-close", Jr);
|
|
202
202
|
/**
|
|
203
203
|
* @license lucide-react v0.511.0 - ISC
|
|
204
204
|
*
|
|
205
205
|
* This source code is licensed under the ISC license.
|
|
206
206
|
* See the LICENSE file in the root directory of this source tree.
|
|
207
207
|
*/
|
|
208
|
-
const
|
|
208
|
+
const ea = [
|
|
209
209
|
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
|
|
210
210
|
["path", { d: "M9 3v18", key: "fh3hqa" }],
|
|
211
211
|
["path", { d: "m14 9 3 3-3 3", key: "8010ee" }]
|
|
212
|
-
], pn = X("panel-left-open",
|
|
212
|
+
], pn = X("panel-left-open", ea);
|
|
213
213
|
/**
|
|
214
214
|
* @license lucide-react v0.511.0 - ISC
|
|
215
215
|
*
|
|
216
216
|
* This source code is licensed under the ISC license.
|
|
217
217
|
* See the LICENSE file in the root directory of this source tree.
|
|
218
218
|
*/
|
|
219
|
-
const
|
|
219
|
+
const ta = [
|
|
220
220
|
["path", { d: "M12 3v12", key: "1x0j5s" }],
|
|
221
221
|
["path", { d: "m17 8-5-5-5 5", key: "7q97r8" }],
|
|
222
222
|
["path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4", key: "ih7n3h" }]
|
|
223
|
-
],
|
|
223
|
+
], na = X("upload", ta);
|
|
224
224
|
/**
|
|
225
225
|
* @license lucide-react v0.511.0 - ISC
|
|
226
226
|
*
|
|
227
227
|
* This source code is licensed under the ISC license.
|
|
228
228
|
* See the LICENSE file in the root directory of this source tree.
|
|
229
229
|
*/
|
|
230
|
-
const
|
|
230
|
+
const ra = [
|
|
231
231
|
["path", { d: "M18 6 6 18", key: "1bl5f8" }],
|
|
232
232
|
["path", { d: "m6 6 12 12", key: "d8bk6v" }]
|
|
233
|
-
], ve = X("x",
|
|
233
|
+
], ve = X("x", ra);
|
|
234
234
|
function T(...e) {
|
|
235
235
|
return e.filter(Boolean).join(" ");
|
|
236
236
|
}
|
|
@@ -280,8 +280,8 @@ function fn(e, t) {
|
|
|
280
280
|
};
|
|
281
281
|
}, []);
|
|
282
282
|
}
|
|
283
|
-
function
|
|
284
|
-
const { isTablet: o } =
|
|
283
|
+
function aa({ collapsed: e = !1, mobileNavOpen: t = !1, density: n, className: r, children: s }) {
|
|
284
|
+
const { isTablet: o } = ln();
|
|
285
285
|
return /* @__PURE__ */ a(
|
|
286
286
|
"div",
|
|
287
287
|
{
|
|
@@ -294,7 +294,7 @@ function oa({ collapsed: e = !1, mobileNavOpen: t = !1, density: n, className: r
|
|
|
294
294
|
}
|
|
295
295
|
);
|
|
296
296
|
}
|
|
297
|
-
function
|
|
297
|
+
function sa({
|
|
298
298
|
brand: e = "VXUI",
|
|
299
299
|
brandCaption: t,
|
|
300
300
|
brandIcon: n,
|
|
@@ -355,16 +355,16 @@ function ia({
|
|
|
355
355
|
}
|
|
356
356
|
);
|
|
357
357
|
}
|
|
358
|
-
function
|
|
358
|
+
function oa({ label: e = "Primary navigation", children: t }) {
|
|
359
359
|
return /* @__PURE__ */ a("nav", { className: "vx-sidebar__nav", "aria-label": e, children: t });
|
|
360
360
|
}
|
|
361
|
-
function
|
|
361
|
+
function ia({ title: e, children: t }) {
|
|
362
362
|
return /* @__PURE__ */ S("div", { className: "vx-nav-section-block", children: [
|
|
363
363
|
e ? /* @__PURE__ */ a("div", { className: "vx-nav-section-block__title", children: e }) : null,
|
|
364
364
|
/* @__PURE__ */ a("div", { className: "vx-nav-section-block__items", children: t })
|
|
365
365
|
] });
|
|
366
366
|
}
|
|
367
|
-
function
|
|
367
|
+
function la({ label: e, icon: t, badge: n, trailing: r, active: s, onSelect: o }) {
|
|
368
368
|
return /* @__PURE__ */ S(
|
|
369
369
|
"button",
|
|
370
370
|
{
|
|
@@ -380,7 +380,7 @@ function ua({ label: e, icon: t, badge: n, trailing: r, active: s, onSelect: o }
|
|
|
380
380
|
}
|
|
381
381
|
);
|
|
382
382
|
}
|
|
383
|
-
function
|
|
383
|
+
function ca({ onClose: e, closeLabel: t = "Close sidebar" }) {
|
|
384
384
|
return /* @__PURE__ */ a(
|
|
385
385
|
"button",
|
|
386
386
|
{
|
|
@@ -391,10 +391,10 @@ function da({ onClose: e, closeLabel: t = "Close sidebar" }) {
|
|
|
391
391
|
}
|
|
392
392
|
);
|
|
393
393
|
}
|
|
394
|
-
function
|
|
394
|
+
function ua({ children: e }) {
|
|
395
395
|
return /* @__PURE__ */ a("div", { className: "vx-shell__main", children: e });
|
|
396
396
|
}
|
|
397
|
-
const
|
|
397
|
+
const da = re(function({
|
|
398
398
|
title: t,
|
|
399
399
|
description: n,
|
|
400
400
|
breadcrumb: r,
|
|
@@ -422,7 +422,7 @@ const fa = re(function({
|
|
|
422
422
|
s ? /* @__PURE__ */ a("div", { className: "vx-topbar__actions", children: s }) : null
|
|
423
423
|
] });
|
|
424
424
|
});
|
|
425
|
-
function
|
|
425
|
+
function pa({ children: e }) {
|
|
426
426
|
const t = L(null), n = L(null);
|
|
427
427
|
return fn(t, n), /* @__PURE__ */ S(
|
|
428
428
|
"div",
|
|
@@ -442,7 +442,7 @@ function va({ children: e }) {
|
|
|
442
442
|
}
|
|
443
443
|
);
|
|
444
444
|
}
|
|
445
|
-
function
|
|
445
|
+
function yi({
|
|
446
446
|
brand: e = "VXUI",
|
|
447
447
|
brandCaption: t,
|
|
448
448
|
brandIcon: n,
|
|
@@ -465,9 +465,9 @@ function wi({
|
|
|
465
465
|
sidebarFooter: v,
|
|
466
466
|
children: f
|
|
467
467
|
}) {
|
|
468
|
-
return /* @__PURE__ */ S(
|
|
468
|
+
return /* @__PURE__ */ S(aa, { collapsed: c, mobileNavOpen: d, density: w, children: [
|
|
469
469
|
/* @__PURE__ */ a(
|
|
470
|
-
|
|
470
|
+
sa,
|
|
471
471
|
{
|
|
472
472
|
brand: e,
|
|
473
473
|
brandCaption: t,
|
|
@@ -477,13 +477,13 @@ function wi({
|
|
|
477
477
|
onToggle: p,
|
|
478
478
|
collapseLabel: E,
|
|
479
479
|
expandLabel: g,
|
|
480
|
-
children: /* @__PURE__ */ a(
|
|
480
|
+
children: /* @__PURE__ */ a(oa, { children: (u ?? (i ? [{ items: i }] : [])).map((_, N) => /* @__PURE__ */ a(ia, { title: _.title, children: _.items.map(({ key: C, onSelect: A, ...P }) => /* @__PURE__ */ a(la, { onSelect: A, ...P }, C)) }, _.key ?? _.title ?? N)) })
|
|
481
481
|
}
|
|
482
482
|
),
|
|
483
|
-
x ? /* @__PURE__ */ a(
|
|
484
|
-
/* @__PURE__ */ S(
|
|
483
|
+
x ? /* @__PURE__ */ a(ca, { onClose: x, closeLabel: m }) : null,
|
|
484
|
+
/* @__PURE__ */ S(ua, { children: [
|
|
485
485
|
/* @__PURE__ */ a(
|
|
486
|
-
|
|
486
|
+
da,
|
|
487
487
|
{
|
|
488
488
|
ref: r,
|
|
489
489
|
breadcrumb: s,
|
|
@@ -495,26 +495,26 @@ function wi({
|
|
|
495
495
|
menuButtonLabel: k
|
|
496
496
|
}
|
|
497
497
|
),
|
|
498
|
-
/* @__PURE__ */ a(
|
|
498
|
+
/* @__PURE__ */ a(pa, { children: f })
|
|
499
499
|
] })
|
|
500
500
|
] });
|
|
501
501
|
}
|
|
502
|
-
function
|
|
502
|
+
function _i({ className: e, variant: t = "neutral", ...n }) {
|
|
503
503
|
return /* @__PURE__ */ a("span", { className: T("vx-badge", `vx-badge--${t}`, e), ...n });
|
|
504
504
|
}
|
|
505
|
-
function
|
|
505
|
+
function wi({ className: e, ...t }) {
|
|
506
506
|
return /* @__PURE__ */ a("section", { className: T("vx-card", e), ...t });
|
|
507
507
|
}
|
|
508
|
-
function
|
|
508
|
+
function ki({ className: e, ...t }) {
|
|
509
509
|
return /* @__PURE__ */ a("header", { className: T("vx-card__header", e), ...t });
|
|
510
510
|
}
|
|
511
|
-
function
|
|
511
|
+
function Ni({ className: e, ...t }) {
|
|
512
512
|
return /* @__PURE__ */ a("h2", { className: T("vx-card__title", e), ...t });
|
|
513
513
|
}
|
|
514
|
-
function
|
|
514
|
+
function Si({ className: e, ...t }) {
|
|
515
515
|
return /* @__PURE__ */ a("p", { className: T("vx-card__description", e), ...t });
|
|
516
516
|
}
|
|
517
|
-
function
|
|
517
|
+
function Ei({ className: e, ...t }) {
|
|
518
518
|
return /* @__PURE__ */ a("div", { className: T("vx-card__content", e), ...t });
|
|
519
519
|
}
|
|
520
520
|
function M(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
|
|
@@ -523,7 +523,7 @@ function M(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
|
|
|
523
523
|
return t == null ? void 0 : t(s);
|
|
524
524
|
};
|
|
525
525
|
}
|
|
526
|
-
function
|
|
526
|
+
function Mt(e, t) {
|
|
527
527
|
if (typeof e == "function")
|
|
528
528
|
return e(t);
|
|
529
529
|
e != null && (e.current = t);
|
|
@@ -532,14 +532,14 @@ function vn(...e) {
|
|
|
532
532
|
return (t) => {
|
|
533
533
|
let n = !1;
|
|
534
534
|
const r = e.map((s) => {
|
|
535
|
-
const o =
|
|
535
|
+
const o = Mt(s, t);
|
|
536
536
|
return !n && typeof o == "function" && (n = !0), o;
|
|
537
537
|
});
|
|
538
538
|
if (n)
|
|
539
539
|
return () => {
|
|
540
540
|
for (let s = 0; s < r.length; s++) {
|
|
541
541
|
const o = r[s];
|
|
542
|
-
typeof o == "function" ? o() :
|
|
542
|
+
typeof o == "function" ? o() : Mt(e[s], null);
|
|
543
543
|
}
|
|
544
544
|
};
|
|
545
545
|
};
|
|
@@ -547,7 +547,7 @@ function vn(...e) {
|
|
|
547
547
|
function K(...e) {
|
|
548
548
|
return b.useCallback(vn(...e), e);
|
|
549
549
|
}
|
|
550
|
-
function
|
|
550
|
+
function fa(e, t) {
|
|
551
551
|
const n = b.createContext(t), r = (o) => {
|
|
552
552
|
const { children: l, ...i } = o, u = b.useMemo(() => i, Object.values(i));
|
|
553
553
|
return /* @__PURE__ */ a(n.Provider, { value: u, children: l });
|
|
@@ -591,9 +591,9 @@ function he(e, t = []) {
|
|
|
591
591
|
);
|
|
592
592
|
};
|
|
593
593
|
};
|
|
594
|
-
return s.scopeName = e, [r,
|
|
594
|
+
return s.scopeName = e, [r, va(s, ...t)];
|
|
595
595
|
}
|
|
596
|
-
function
|
|
596
|
+
function va(...e) {
|
|
597
597
|
const t = e[0];
|
|
598
598
|
if (e.length === 1) return t;
|
|
599
599
|
const n = () => {
|
|
@@ -612,15 +612,15 @@ function ma(...e) {
|
|
|
612
612
|
return n.scopeName = t.scopeName, n;
|
|
613
613
|
}
|
|
614
614
|
var se = globalThis != null && globalThis.document ? b.useLayoutEffect : () => {
|
|
615
|
-
},
|
|
616
|
-
}),
|
|
615
|
+
}, ha = b[" useId ".trim().toString()] || (() => {
|
|
616
|
+
}), ma = 0;
|
|
617
617
|
function xe(e) {
|
|
618
|
-
const [t, n] = b.useState(
|
|
618
|
+
const [t, n] = b.useState(ha());
|
|
619
619
|
return se(() => {
|
|
620
|
-
n((r) => r ?? String(
|
|
620
|
+
n((r) => r ?? String(ma++));
|
|
621
621
|
}, [e]), e || (t ? `radix-${t}` : "");
|
|
622
622
|
}
|
|
623
|
-
var
|
|
623
|
+
var ga = b[" useInsertionEffect ".trim().toString()] || se;
|
|
624
624
|
function we({
|
|
625
625
|
prop: e,
|
|
626
626
|
defaultProp: t,
|
|
@@ -628,7 +628,7 @@ function we({
|
|
|
628
628
|
},
|
|
629
629
|
caller: r
|
|
630
630
|
}) {
|
|
631
|
-
const [s, o, l] =
|
|
631
|
+
const [s, o, l] = ba({
|
|
632
632
|
defaultProp: t,
|
|
633
633
|
onChange: n
|
|
634
634
|
}), i = e !== void 0, u = i ? e : s;
|
|
@@ -645,7 +645,7 @@ function we({
|
|
|
645
645
|
(d) => {
|
|
646
646
|
var p;
|
|
647
647
|
if (i) {
|
|
648
|
-
const x =
|
|
648
|
+
const x = xa(d) ? d(e) : d;
|
|
649
649
|
x !== e && ((p = l.current) == null || p.call(l, x));
|
|
650
650
|
} else
|
|
651
651
|
o(d);
|
|
@@ -654,25 +654,25 @@ function we({
|
|
|
654
654
|
);
|
|
655
655
|
return [u, c];
|
|
656
656
|
}
|
|
657
|
-
function
|
|
657
|
+
function ba({
|
|
658
658
|
defaultProp: e,
|
|
659
659
|
onChange: t
|
|
660
660
|
}) {
|
|
661
661
|
const [n, r] = b.useState(e), s = b.useRef(n), o = b.useRef(t);
|
|
662
|
-
return
|
|
662
|
+
return ga(() => {
|
|
663
663
|
o.current = t;
|
|
664
664
|
}, [t]), b.useEffect(() => {
|
|
665
665
|
var l;
|
|
666
666
|
s.current !== n && ((l = o.current) == null || l.call(o, n), s.current = n);
|
|
667
667
|
}, [n, s]), [n, r, o];
|
|
668
668
|
}
|
|
669
|
-
function
|
|
669
|
+
function xa(e) {
|
|
670
670
|
return typeof e == "function";
|
|
671
671
|
}
|
|
672
672
|
// @__NO_SIDE_EFFECTS__
|
|
673
673
|
function $e(e) {
|
|
674
|
-
const t = /* @__PURE__ */
|
|
675
|
-
const { children: o, ...l } = r, i = b.Children.toArray(o), u = i.find(
|
|
674
|
+
const t = /* @__PURE__ */ ya(e), n = b.forwardRef((r, s) => {
|
|
675
|
+
const { children: o, ...l } = r, i = b.Children.toArray(o), u = i.find(wa);
|
|
676
676
|
if (u) {
|
|
677
677
|
const c = u.props.children, d = i.map((p) => p === u ? b.Children.count(c) > 1 ? b.Children.only(null) : b.isValidElement(c) ? c.props.children : null : p);
|
|
678
678
|
return /* @__PURE__ */ a(t, { ...l, ref: s, children: b.isValidElement(c) ? b.cloneElement(c, void 0, d) : null });
|
|
@@ -682,22 +682,22 @@ function $e(e) {
|
|
|
682
682
|
return n.displayName = `${e}.Slot`, n;
|
|
683
683
|
}
|
|
684
684
|
// @__NO_SIDE_EFFECTS__
|
|
685
|
-
function
|
|
685
|
+
function ya(e) {
|
|
686
686
|
const t = b.forwardRef((n, r) => {
|
|
687
687
|
const { children: s, ...o } = n;
|
|
688
688
|
if (b.isValidElement(s)) {
|
|
689
|
-
const l =
|
|
689
|
+
const l = Na(s), i = ka(o, s.props);
|
|
690
690
|
return s.type !== b.Fragment && (i.ref = r ? vn(r, l) : l), b.cloneElement(s, i);
|
|
691
691
|
}
|
|
692
692
|
return b.Children.count(s) > 1 ? b.Children.only(null) : null;
|
|
693
693
|
});
|
|
694
694
|
return t.displayName = `${e}.SlotClone`, t;
|
|
695
695
|
}
|
|
696
|
-
var
|
|
697
|
-
function
|
|
698
|
-
return b.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId ===
|
|
696
|
+
var _a = Symbol("radix.slottable");
|
|
697
|
+
function wa(e) {
|
|
698
|
+
return b.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === _a;
|
|
699
699
|
}
|
|
700
|
-
function
|
|
700
|
+
function ka(e, t) {
|
|
701
701
|
const n = { ...t };
|
|
702
702
|
for (const r in t) {
|
|
703
703
|
const s = e[r], o = t[r];
|
|
@@ -708,12 +708,12 @@ function Sa(e, t) {
|
|
|
708
708
|
}
|
|
709
709
|
return { ...e, ...n };
|
|
710
710
|
}
|
|
711
|
-
function
|
|
711
|
+
function Na(e) {
|
|
712
712
|
var r, s;
|
|
713
713
|
let t = (r = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : r.get, n = t && "isReactWarning" in t && t.isReactWarning;
|
|
714
714
|
return n ? e.ref : (t = (s = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : s.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
715
715
|
}
|
|
716
|
-
var
|
|
716
|
+
var Sa = [
|
|
717
717
|
"a",
|
|
718
718
|
"button",
|
|
719
719
|
"div",
|
|
@@ -731,7 +731,7 @@ var Ta = [
|
|
|
731
731
|
"span",
|
|
732
732
|
"svg",
|
|
733
733
|
"ul"
|
|
734
|
-
], B =
|
|
734
|
+
], B = Sa.reduce((e, t) => {
|
|
735
735
|
const n = /* @__PURE__ */ $e(`Primitive.${t}`), r = b.forwardRef((s, o) => {
|
|
736
736
|
const { asChild: l, ...i } = s, u = l ? n : t;
|
|
737
737
|
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ a(u, { ...i, ref: o });
|
|
@@ -739,7 +739,7 @@ var Ta = [
|
|
|
739
739
|
return r.displayName = `Primitive.${t}`, { ...e, [t]: r };
|
|
740
740
|
}, {});
|
|
741
741
|
function hn(e, t) {
|
|
742
|
-
e &&
|
|
742
|
+
e && sn.flushSync(() => e.dispatchEvent(t));
|
|
743
743
|
}
|
|
744
744
|
function J(e) {
|
|
745
745
|
const t = b.useRef(e);
|
|
@@ -750,7 +750,7 @@ function J(e) {
|
|
|
750
750
|
return (r = t.current) == null ? void 0 : r.call(t, ...n);
|
|
751
751
|
}, []);
|
|
752
752
|
}
|
|
753
|
-
function
|
|
753
|
+
function Ea(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
754
754
|
const n = J(e);
|
|
755
755
|
b.useEffect(() => {
|
|
756
756
|
const r = (s) => {
|
|
@@ -759,11 +759,11 @@ function Ca(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
|
759
759
|
return t.addEventListener("keydown", r, { capture: !0 }), () => t.removeEventListener("keydown", r, { capture: !0 });
|
|
760
760
|
}, [n, t]);
|
|
761
761
|
}
|
|
762
|
-
var
|
|
762
|
+
var Ta = "DismissableLayer", lt = "dismissableLayer.update", Ca = "dismissableLayer.pointerDownOutside", Aa = "dismissableLayer.focusOutside", Ot, mn = b.createContext({
|
|
763
763
|
layers: /* @__PURE__ */ new Set(),
|
|
764
764
|
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
765
765
|
branches: /* @__PURE__ */ new Set()
|
|
766
|
-
}),
|
|
766
|
+
}), mt = b.forwardRef(
|
|
767
767
|
(e, t) => {
|
|
768
768
|
const {
|
|
769
769
|
disableOutsidePointerEvents: n = !1,
|
|
@@ -773,22 +773,22 @@ var Aa = "DismissableLayer", lt = "dismissableLayer.update", Pa = "dismissableLa
|
|
|
773
773
|
onInteractOutside: l,
|
|
774
774
|
onDismiss: i,
|
|
775
775
|
...u
|
|
776
|
-
} = e, c = b.useContext(mn), [d, p] = b.useState(null), x = (d == null ? void 0 : d.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, k] = b.useState({}), E = K(t, (N) => p(N)), g = Array.from(c.layers), [m] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), w = g.indexOf(m), h = d ? g.indexOf(d) : -1, v = c.layersWithOutsidePointerEventsDisabled.size > 0, f = h >= w, y =
|
|
776
|
+
} = e, c = b.useContext(mn), [d, p] = b.useState(null), x = (d == null ? void 0 : d.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, k] = b.useState({}), E = K(t, (N) => p(N)), g = Array.from(c.layers), [m] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), w = g.indexOf(m), h = d ? g.indexOf(d) : -1, v = c.layersWithOutsidePointerEventsDisabled.size > 0, f = h >= w, y = Ra((N) => {
|
|
777
777
|
const C = N.target, A = [...c.branches].some((P) => P.contains(C));
|
|
778
778
|
!f || A || (s == null || s(N), l == null || l(N), N.defaultPrevented || i == null || i());
|
|
779
|
-
}, x), _ =
|
|
779
|
+
}, x), _ = Fa((N) => {
|
|
780
780
|
const C = N.target;
|
|
781
781
|
[...c.branches].some((P) => P.contains(C)) || (o == null || o(N), l == null || l(N), N.defaultPrevented || i == null || i());
|
|
782
782
|
}, x);
|
|
783
|
-
return
|
|
783
|
+
return Ea((N) => {
|
|
784
784
|
h === c.layers.size - 1 && (r == null || r(N), !N.defaultPrevented && i && (N.preventDefault(), i()));
|
|
785
785
|
}, x), b.useEffect(() => {
|
|
786
786
|
if (d)
|
|
787
|
-
return n && (c.layersWithOutsidePointerEventsDisabled.size === 0 && (
|
|
788
|
-
n && c.layersWithOutsidePointerEventsDisabled.size === 1 && (x.body.style.pointerEvents =
|
|
787
|
+
return n && (c.layersWithOutsidePointerEventsDisabled.size === 0 && (Ot = x.body.style.pointerEvents, x.body.style.pointerEvents = "none"), c.layersWithOutsidePointerEventsDisabled.add(d)), c.layers.add(d), $t(), () => {
|
|
788
|
+
n && c.layersWithOutsidePointerEventsDisabled.size === 1 && (x.body.style.pointerEvents = Ot);
|
|
789
789
|
};
|
|
790
790
|
}, [d, x, n, c]), b.useEffect(() => () => {
|
|
791
|
-
d && (c.layers.delete(d), c.layersWithOutsidePointerEventsDisabled.delete(d),
|
|
791
|
+
d && (c.layers.delete(d), c.layersWithOutsidePointerEventsDisabled.delete(d), $t());
|
|
792
792
|
}, [d, c]), b.useEffect(() => {
|
|
793
793
|
const N = () => k({});
|
|
794
794
|
return document.addEventListener(lt, N), () => document.removeEventListener(lt, N);
|
|
@@ -811,8 +811,8 @@ var Aa = "DismissableLayer", lt = "dismissableLayer.update", Pa = "dismissableLa
|
|
|
811
811
|
);
|
|
812
812
|
}
|
|
813
813
|
);
|
|
814
|
-
|
|
815
|
-
var
|
|
814
|
+
mt.displayName = Ta;
|
|
815
|
+
var Pa = "DismissableLayerBranch", gn = b.forwardRef((e, t) => {
|
|
816
816
|
const n = b.useContext(mn), r = b.useRef(null), s = K(t, r);
|
|
817
817
|
return b.useEffect(() => {
|
|
818
818
|
const o = r.current;
|
|
@@ -822,8 +822,8 @@ var Ra = "DismissableLayerBranch", gn = b.forwardRef((e, t) => {
|
|
|
822
822
|
};
|
|
823
823
|
}, [n.branches]), /* @__PURE__ */ a(B.div, { ...e, ref: s });
|
|
824
824
|
});
|
|
825
|
-
gn.displayName =
|
|
826
|
-
function
|
|
825
|
+
gn.displayName = Pa;
|
|
826
|
+
function Ra(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
827
827
|
const n = J(e), r = b.useRef(!1), s = b.useRef(() => {
|
|
828
828
|
});
|
|
829
829
|
return b.useEffect(() => {
|
|
@@ -831,7 +831,7 @@ function Fa(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
|
831
831
|
if (i.target && !r.current) {
|
|
832
832
|
let u = function() {
|
|
833
833
|
bn(
|
|
834
|
-
|
|
834
|
+
Ca,
|
|
835
835
|
n,
|
|
836
836
|
c,
|
|
837
837
|
{ discrete: !0 }
|
|
@@ -853,11 +853,11 @@ function Fa(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
|
853
853
|
onPointerDownCapture: () => r.current = !0
|
|
854
854
|
};
|
|
855
855
|
}
|
|
856
|
-
function
|
|
856
|
+
function Fa(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
857
857
|
const n = J(e), r = b.useRef(!1);
|
|
858
858
|
return b.useEffect(() => {
|
|
859
859
|
const s = (o) => {
|
|
860
|
-
o.target && !r.current && bn(
|
|
860
|
+
o.target && !r.current && bn(Aa, n, { originalEvent: o }, {
|
|
861
861
|
discrete: !1
|
|
862
862
|
});
|
|
863
863
|
};
|
|
@@ -867,7 +867,7 @@ function Ia(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
|
867
867
|
onBlurCapture: () => r.current = !1
|
|
868
868
|
};
|
|
869
869
|
}
|
|
870
|
-
function
|
|
870
|
+
function $t() {
|
|
871
871
|
const e = new CustomEvent(lt);
|
|
872
872
|
document.dispatchEvent(e);
|
|
873
873
|
}
|
|
@@ -875,7 +875,7 @@ function bn(e, t, n, { discrete: r }) {
|
|
|
875
875
|
const s = n.originalEvent.target, o = new CustomEvent(e, { bubbles: !1, cancelable: !0, detail: n });
|
|
876
876
|
t && s.addEventListener(e, t, { once: !0 }), r ? hn(s, o) : s.dispatchEvent(o);
|
|
877
877
|
}
|
|
878
|
-
var
|
|
878
|
+
var Da = mt, Ia = gn, Xe = "focusScope.autoFocusOnMount", Ze = "focusScope.autoFocusOnUnmount", Bt = { bubbles: !1, cancelable: !0 }, La = "FocusScope", xn = b.forwardRef((e, t) => {
|
|
879
879
|
const {
|
|
880
880
|
loop: n = !1,
|
|
881
881
|
trapped: r = !1,
|
|
@@ -914,16 +914,16 @@ var La = gt, Ma = gn, Xe = "focusScope.autoFocusOnMount", Ze = "focusScope.autoF
|
|
|
914
914
|
}
|
|
915
915
|
}, [r, i, k.paused]), b.useEffect(() => {
|
|
916
916
|
if (i) {
|
|
917
|
-
|
|
917
|
+
Ut.add(k);
|
|
918
918
|
const g = document.activeElement;
|
|
919
919
|
if (!i.contains(g)) {
|
|
920
|
-
const w = new CustomEvent(Xe,
|
|
921
|
-
i.addEventListener(Xe, c), i.dispatchEvent(w), w.defaultPrevented || (
|
|
920
|
+
const w = new CustomEvent(Xe, Bt);
|
|
921
|
+
i.addEventListener(Xe, c), i.dispatchEvent(w), w.defaultPrevented || (Ma(Ua(yn(i)), { select: !0 }), document.activeElement === g && ne(i));
|
|
922
922
|
}
|
|
923
923
|
return () => {
|
|
924
924
|
i.removeEventListener(Xe, c), setTimeout(() => {
|
|
925
|
-
const w = new CustomEvent(Ze,
|
|
926
|
-
i.addEventListener(Ze, d), i.dispatchEvent(w), w.defaultPrevented || ne(g ?? document.body, { select: !0 }), i.removeEventListener(Ze, d),
|
|
925
|
+
const w = new CustomEvent(Ze, Bt);
|
|
926
|
+
i.addEventListener(Ze, d), i.dispatchEvent(w), w.defaultPrevented || ne(g ?? document.body, { select: !0 }), i.removeEventListener(Ze, d), Ut.remove(k);
|
|
927
927
|
}, 0);
|
|
928
928
|
};
|
|
929
929
|
}
|
|
@@ -933,7 +933,7 @@ var La = gt, Ma = gn, Xe = "focusScope.autoFocusOnMount", Ze = "focusScope.autoF
|
|
|
933
933
|
if (!n && !r || k.paused) return;
|
|
934
934
|
const m = g.key === "Tab" && !g.altKey && !g.ctrlKey && !g.metaKey, w = document.activeElement;
|
|
935
935
|
if (m && w) {
|
|
936
|
-
const h = g.currentTarget, [v, f] =
|
|
936
|
+
const h = g.currentTarget, [v, f] = Oa(h);
|
|
937
937
|
v && f ? !g.shiftKey && w === f ? (g.preventDefault(), n && ne(v, { select: !0 })) : g.shiftKey && w === v && (g.preventDefault(), n && ne(f, { select: !0 })) : w === h && g.preventDefault();
|
|
938
938
|
}
|
|
939
939
|
},
|
|
@@ -941,14 +941,14 @@ var La = gt, Ma = gn, Xe = "focusScope.autoFocusOnMount", Ze = "focusScope.autoF
|
|
|
941
941
|
);
|
|
942
942
|
return /* @__PURE__ */ a(B.div, { tabIndex: -1, ...l, ref: x, onKeyDown: E });
|
|
943
943
|
});
|
|
944
|
-
xn.displayName =
|
|
945
|
-
function
|
|
944
|
+
xn.displayName = La;
|
|
945
|
+
function Ma(e, { select: t = !1 } = {}) {
|
|
946
946
|
const n = document.activeElement;
|
|
947
947
|
for (const r of e)
|
|
948
948
|
if (ne(r, { select: t }), document.activeElement !== n) return;
|
|
949
949
|
}
|
|
950
|
-
function
|
|
951
|
-
const t = yn(e), n =
|
|
950
|
+
function Oa(e) {
|
|
951
|
+
const t = yn(e), n = zt(t, e), r = zt(t.reverse(), e);
|
|
952
952
|
return [n, r];
|
|
953
953
|
}
|
|
954
954
|
function yn(e) {
|
|
@@ -961,11 +961,11 @@ function yn(e) {
|
|
|
961
961
|
for (; n.nextNode(); ) t.push(n.currentNode);
|
|
962
962
|
return t;
|
|
963
963
|
}
|
|
964
|
-
function
|
|
964
|
+
function zt(e, t) {
|
|
965
965
|
for (const n of e)
|
|
966
|
-
if (
|
|
966
|
+
if (!$a(n, { upTo: t })) return n;
|
|
967
967
|
}
|
|
968
|
-
function
|
|
968
|
+
function $a(e, { upTo: t }) {
|
|
969
969
|
if (getComputedStyle(e).visibility === "hidden") return !0;
|
|
970
970
|
for (; e; ) {
|
|
971
971
|
if (t !== void 0 && e === t) return !1;
|
|
@@ -974,54 +974,54 @@ function za(e, { upTo: t }) {
|
|
|
974
974
|
}
|
|
975
975
|
return !1;
|
|
976
976
|
}
|
|
977
|
-
function
|
|
977
|
+
function Ba(e) {
|
|
978
978
|
return e instanceof HTMLInputElement && "select" in e;
|
|
979
979
|
}
|
|
980
980
|
function ne(e, { select: t = !1 } = {}) {
|
|
981
981
|
if (e && e.focus) {
|
|
982
982
|
const n = document.activeElement;
|
|
983
|
-
e.focus({ preventScroll: !0 }), e !== n &&
|
|
983
|
+
e.focus({ preventScroll: !0 }), e !== n && Ba(e) && t && e.select();
|
|
984
984
|
}
|
|
985
985
|
}
|
|
986
|
-
var
|
|
987
|
-
function
|
|
986
|
+
var Ut = za();
|
|
987
|
+
function za() {
|
|
988
988
|
let e = [];
|
|
989
989
|
return {
|
|
990
990
|
add(t) {
|
|
991
991
|
const n = e[0];
|
|
992
|
-
t !== n && (n == null || n.pause()), e =
|
|
992
|
+
t !== n && (n == null || n.pause()), e = Wt(e, t), e.unshift(t);
|
|
993
993
|
},
|
|
994
994
|
remove(t) {
|
|
995
995
|
var n;
|
|
996
|
-
e =
|
|
996
|
+
e = Wt(e, t), (n = e[0]) == null || n.resume();
|
|
997
997
|
}
|
|
998
998
|
};
|
|
999
999
|
}
|
|
1000
|
-
function
|
|
1000
|
+
function Wt(e, t) {
|
|
1001
1001
|
const n = [...e], r = n.indexOf(t);
|
|
1002
1002
|
return r !== -1 && n.splice(r, 1), n;
|
|
1003
1003
|
}
|
|
1004
|
-
function
|
|
1004
|
+
function Ua(e) {
|
|
1005
1005
|
return e.filter((t) => t.tagName !== "A");
|
|
1006
1006
|
}
|
|
1007
|
-
var
|
|
1007
|
+
var Wa = "Portal", gt = b.forwardRef((e, t) => {
|
|
1008
1008
|
var i;
|
|
1009
1009
|
const { container: n, ...r } = e, [s, o] = b.useState(!1);
|
|
1010
1010
|
se(() => o(!0), []);
|
|
1011
1011
|
const l = n || s && ((i = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : i.body);
|
|
1012
|
-
return l ?
|
|
1012
|
+
return l ? Lr.createPortal(/* @__PURE__ */ a(B.div, { ...r, ref: t }), l) : null;
|
|
1013
1013
|
});
|
|
1014
|
-
|
|
1015
|
-
function
|
|
1014
|
+
gt.displayName = Wa;
|
|
1015
|
+
function Ha(e, t) {
|
|
1016
1016
|
return b.useReducer((n, r) => t[n][r] ?? n, e);
|
|
1017
1017
|
}
|
|
1018
1018
|
var me = (e) => {
|
|
1019
|
-
const { present: t, children: n } = e, r =
|
|
1019
|
+
const { present: t, children: n } = e, r = Ga(t), s = typeof n == "function" ? n({ present: r.isPresent }) : b.Children.only(n), o = K(r.ref, ja(s));
|
|
1020
1020
|
return typeof n == "function" || r.isPresent ? b.cloneElement(s, { ref: o }) : null;
|
|
1021
1021
|
};
|
|
1022
1022
|
me.displayName = "Presence";
|
|
1023
|
-
function
|
|
1024
|
-
const [t, n] = b.useState(), r = b.useRef(null), s = b.useRef(e), o = b.useRef("none"), l = e ? "mounted" : "unmounted", [i, u] =
|
|
1023
|
+
function Ga(e) {
|
|
1024
|
+
const [t, n] = b.useState(), r = b.useRef(null), s = b.useRef(e), o = b.useRef("none"), l = e ? "mounted" : "unmounted", [i, u] = Ha(l, {
|
|
1025
1025
|
mounted: {
|
|
1026
1026
|
UNMOUNT: "unmounted",
|
|
1027
1027
|
ANIMATION_OUT: "unmountSuspended"
|
|
@@ -1072,21 +1072,21 @@ function Ka(e) {
|
|
|
1072
1072
|
function Ce(e) {
|
|
1073
1073
|
return (e == null ? void 0 : e.animationName) || "none";
|
|
1074
1074
|
}
|
|
1075
|
-
function
|
|
1075
|
+
function ja(e) {
|
|
1076
1076
|
var r, s;
|
|
1077
1077
|
let t = (r = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : r.get, n = t && "isReactWarning" in t && t.isReactWarning;
|
|
1078
1078
|
return n ? e.ref : (t = (s = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : s.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
1079
1079
|
}
|
|
1080
1080
|
var Qe = 0;
|
|
1081
|
-
function
|
|
1081
|
+
function Ka() {
|
|
1082
1082
|
b.useEffect(() => {
|
|
1083
1083
|
const e = document.querySelectorAll("[data-radix-focus-guard]");
|
|
1084
|
-
return document.body.insertAdjacentElement("afterbegin", e[0] ??
|
|
1084
|
+
return document.body.insertAdjacentElement("afterbegin", e[0] ?? Ht()), document.body.insertAdjacentElement("beforeend", e[1] ?? Ht()), Qe++, () => {
|
|
1085
1085
|
Qe === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach((t) => t.remove()), Qe--;
|
|
1086
1086
|
};
|
|
1087
1087
|
}, []);
|
|
1088
1088
|
}
|
|
1089
|
-
function
|
|
1089
|
+
function Ht() {
|
|
1090
1090
|
const e = document.createElement("span");
|
|
1091
1091
|
return e.setAttribute("data-radix-focus-guard", ""), e.tabIndex = 0, e.style.outline = "none", e.style.opacity = "0", e.style.position = "fixed", e.style.pointerEvents = "none", e;
|
|
1092
1092
|
}
|
|
@@ -1107,17 +1107,17 @@ function _n(e, t) {
|
|
|
1107
1107
|
t.indexOf(r[s]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[s]) && (n[r[s]] = e[r[s]]);
|
|
1108
1108
|
return n;
|
|
1109
1109
|
}
|
|
1110
|
-
function
|
|
1110
|
+
function Va(e, t, n) {
|
|
1111
1111
|
if (n || arguments.length === 2) for (var r = 0, s = t.length, o; r < s; r++)
|
|
1112
1112
|
(o || !(r in t)) && (o || (o = Array.prototype.slice.call(t, 0, r)), o[r] = t[r]);
|
|
1113
1113
|
return e.concat(o || Array.prototype.slice.call(t));
|
|
1114
1114
|
}
|
|
1115
|
-
var Me = "right-scroll-bar-position", Oe = "width-before-scroll-bar",
|
|
1115
|
+
var Me = "right-scroll-bar-position", Oe = "width-before-scroll-bar", Ya = "with-scroll-bars-hidden", qa = "--removed-body-scroll-bar-size";
|
|
1116
1116
|
function Je(e, t) {
|
|
1117
1117
|
return typeof e == "function" ? e(t) : e && (e.current = t), e;
|
|
1118
1118
|
}
|
|
1119
|
-
function
|
|
1120
|
-
var n =
|
|
1119
|
+
function Xa(e, t) {
|
|
1120
|
+
var n = D(function() {
|
|
1121
1121
|
return {
|
|
1122
1122
|
// value
|
|
1123
1123
|
value: e,
|
|
@@ -1137,15 +1137,15 @@ function Qa(e, t) {
|
|
|
1137
1137
|
})[0];
|
|
1138
1138
|
return n.callback = t, n.facade;
|
|
1139
1139
|
}
|
|
1140
|
-
var
|
|
1141
|
-
function
|
|
1142
|
-
var n =
|
|
1140
|
+
var Za = typeof window < "u" ? b.useLayoutEffect : b.useEffect, Gt = /* @__PURE__ */ new WeakMap();
|
|
1141
|
+
function Qa(e, t) {
|
|
1142
|
+
var n = Xa(null, function(r) {
|
|
1143
1143
|
return e.forEach(function(s) {
|
|
1144
1144
|
return Je(s, r);
|
|
1145
1145
|
});
|
|
1146
1146
|
});
|
|
1147
|
-
return
|
|
1148
|
-
var r =
|
|
1147
|
+
return Za(function() {
|
|
1148
|
+
var r = Gt.get(n);
|
|
1149
1149
|
if (r) {
|
|
1150
1150
|
var s = new Set(r), o = new Set(e), l = n.current;
|
|
1151
1151
|
s.forEach(function(i) {
|
|
@@ -1154,14 +1154,14 @@ function es(e, t) {
|
|
|
1154
1154
|
s.has(i) || Je(i, l);
|
|
1155
1155
|
});
|
|
1156
1156
|
}
|
|
1157
|
-
|
|
1157
|
+
Gt.set(n, e);
|
|
1158
1158
|
}, [e]), n;
|
|
1159
1159
|
}
|
|
1160
|
-
function
|
|
1160
|
+
function Ja(e) {
|
|
1161
1161
|
return e;
|
|
1162
1162
|
}
|
|
1163
|
-
function
|
|
1164
|
-
t === void 0 && (t =
|
|
1163
|
+
function es(e, t) {
|
|
1164
|
+
t === void 0 && (t = Ja);
|
|
1165
1165
|
var n = [], r = !1, s = {
|
|
1166
1166
|
read: function() {
|
|
1167
1167
|
if (r)
|
|
@@ -1215,9 +1215,9 @@ function ns(e, t) {
|
|
|
1215
1215
|
};
|
|
1216
1216
|
return s;
|
|
1217
1217
|
}
|
|
1218
|
-
function
|
|
1218
|
+
function ts(e) {
|
|
1219
1219
|
e === void 0 && (e = {});
|
|
1220
|
-
var t =
|
|
1220
|
+
var t = es(null);
|
|
1221
1221
|
return t.options = Q({ async: !0, ssr: !1 }, e), t;
|
|
1222
1222
|
}
|
|
1223
1223
|
var wn = function(e) {
|
|
@@ -1230,16 +1230,16 @@ var wn = function(e) {
|
|
|
1230
1230
|
return b.createElement(r, Q({}, n));
|
|
1231
1231
|
};
|
|
1232
1232
|
wn.isSideCarExport = !0;
|
|
1233
|
-
function
|
|
1233
|
+
function ns(e, t) {
|
|
1234
1234
|
return e.useMedium(t), wn;
|
|
1235
1235
|
}
|
|
1236
|
-
var kn =
|
|
1236
|
+
var kn = ts(), et = function() {
|
|
1237
1237
|
}, We = b.forwardRef(function(e, t) {
|
|
1238
1238
|
var n = b.useRef(null), r = b.useState({
|
|
1239
1239
|
onScrollCapture: et,
|
|
1240
1240
|
onWheelCapture: et,
|
|
1241
1241
|
onTouchMoveCapture: et
|
|
1242
|
-
}), s = r[0], o = r[1], l = e.forwardProps, i = e.children, u = e.className, c = e.removeScrollBar, d = e.enabled, p = e.shards, x = e.sideCar, k = e.noRelative, E = e.noIsolation, g = e.inert, m = e.allowPinchZoom, w = e.as, h = w === void 0 ? "div" : w, v = e.gapMode, f = _n(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noRelative", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), y = x, _ =
|
|
1242
|
+
}), s = r[0], o = r[1], l = e.forwardProps, i = e.children, u = e.className, c = e.removeScrollBar, d = e.enabled, p = e.shards, x = e.sideCar, k = e.noRelative, E = e.noIsolation, g = e.inert, m = e.allowPinchZoom, w = e.as, h = w === void 0 ? "div" : w, v = e.gapMode, f = _n(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noRelative", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), y = x, _ = Qa([n, t]), N = Q(Q({}, f), s);
|
|
1243
1243
|
return b.createElement(
|
|
1244
1244
|
b.Fragment,
|
|
1245
1245
|
null,
|
|
@@ -1256,37 +1256,37 @@ We.classNames = {
|
|
|
1256
1256
|
fullWidth: Oe,
|
|
1257
1257
|
zeroRight: Me
|
|
1258
1258
|
};
|
|
1259
|
-
var
|
|
1259
|
+
var rs = function() {
|
|
1260
1260
|
if (typeof __webpack_nonce__ < "u")
|
|
1261
1261
|
return __webpack_nonce__;
|
|
1262
1262
|
};
|
|
1263
|
-
function
|
|
1263
|
+
function as() {
|
|
1264
1264
|
if (!document)
|
|
1265
1265
|
return null;
|
|
1266
1266
|
var e = document.createElement("style");
|
|
1267
1267
|
e.type = "text/css";
|
|
1268
|
-
var t =
|
|
1268
|
+
var t = rs();
|
|
1269
1269
|
return t && e.setAttribute("nonce", t), e;
|
|
1270
1270
|
}
|
|
1271
|
-
function
|
|
1271
|
+
function ss(e, t) {
|
|
1272
1272
|
e.styleSheet ? e.styleSheet.cssText = t : e.appendChild(document.createTextNode(t));
|
|
1273
1273
|
}
|
|
1274
|
-
function
|
|
1274
|
+
function os(e) {
|
|
1275
1275
|
var t = document.head || document.getElementsByTagName("head")[0];
|
|
1276
1276
|
t.appendChild(e);
|
|
1277
1277
|
}
|
|
1278
|
-
var
|
|
1278
|
+
var is = function() {
|
|
1279
1279
|
var e = 0, t = null;
|
|
1280
1280
|
return {
|
|
1281
1281
|
add: function(n) {
|
|
1282
|
-
e == 0 && (t =
|
|
1282
|
+
e == 0 && (t = as()) && (ss(t, n), os(t)), e++;
|
|
1283
1283
|
},
|
|
1284
1284
|
remove: function() {
|
|
1285
1285
|
e--, !e && t && (t.parentNode && t.parentNode.removeChild(t), t = null);
|
|
1286
1286
|
}
|
|
1287
1287
|
};
|
|
1288
|
-
},
|
|
1289
|
-
var e =
|
|
1288
|
+
}, ls = function() {
|
|
1289
|
+
var e = is();
|
|
1290
1290
|
return function(t, n) {
|
|
1291
1291
|
b.useEffect(function() {
|
|
1292
1292
|
return e.add(t), function() {
|
|
@@ -1295,35 +1295,35 @@ var cs = function() {
|
|
|
1295
1295
|
}, [t && n]);
|
|
1296
1296
|
};
|
|
1297
1297
|
}, Nn = function() {
|
|
1298
|
-
var e =
|
|
1298
|
+
var e = ls(), t = function(n) {
|
|
1299
1299
|
var r = n.styles, s = n.dynamic;
|
|
1300
1300
|
return e(r, s), null;
|
|
1301
1301
|
};
|
|
1302
1302
|
return t;
|
|
1303
|
-
},
|
|
1303
|
+
}, cs = {
|
|
1304
1304
|
left: 0,
|
|
1305
1305
|
top: 0,
|
|
1306
1306
|
right: 0,
|
|
1307
1307
|
gap: 0
|
|
1308
1308
|
}, tt = function(e) {
|
|
1309
1309
|
return parseInt(e || "", 10) || 0;
|
|
1310
|
-
},
|
|
1310
|
+
}, us = function(e) {
|
|
1311
1311
|
var t = window.getComputedStyle(document.body), n = t[e === "padding" ? "paddingLeft" : "marginLeft"], r = t[e === "padding" ? "paddingTop" : "marginTop"], s = t[e === "padding" ? "paddingRight" : "marginRight"];
|
|
1312
1312
|
return [tt(n), tt(r), tt(s)];
|
|
1313
|
-
},
|
|
1313
|
+
}, ds = function(e) {
|
|
1314
1314
|
if (e === void 0 && (e = "margin"), typeof window > "u")
|
|
1315
|
-
return
|
|
1316
|
-
var t =
|
|
1315
|
+
return cs;
|
|
1316
|
+
var t = us(e), n = document.documentElement.clientWidth, r = window.innerWidth;
|
|
1317
1317
|
return {
|
|
1318
1318
|
left: t[0],
|
|
1319
1319
|
top: t[1],
|
|
1320
1320
|
right: t[2],
|
|
1321
1321
|
gap: Math.max(0, r - n + t[2] - t[0])
|
|
1322
1322
|
};
|
|
1323
|
-
},
|
|
1323
|
+
}, ps = Nn(), pe = "data-scroll-locked", fs = function(e, t, n, r) {
|
|
1324
1324
|
var s = e.left, o = e.top, l = e.right, i = e.gap;
|
|
1325
1325
|
return n === void 0 && (n = "margin"), `
|
|
1326
|
-
.`.concat(
|
|
1326
|
+
.`.concat(Ya, ` {
|
|
1327
1327
|
overflow: hidden `).concat(r, `;
|
|
1328
1328
|
padding-right: `).concat(i, "px ").concat(r, `;
|
|
1329
1329
|
}
|
|
@@ -1361,26 +1361,26 @@ var cs = function() {
|
|
|
1361
1361
|
}
|
|
1362
1362
|
|
|
1363
1363
|
body[`).concat(pe, `] {
|
|
1364
|
-
`).concat(
|
|
1364
|
+
`).concat(qa, ": ").concat(i, `px;
|
|
1365
1365
|
}
|
|
1366
1366
|
`);
|
|
1367
|
-
},
|
|
1367
|
+
}, jt = function() {
|
|
1368
1368
|
var e = parseInt(document.body.getAttribute(pe) || "0", 10);
|
|
1369
1369
|
return isFinite(e) ? e : 0;
|
|
1370
|
-
},
|
|
1370
|
+
}, vs = function() {
|
|
1371
1371
|
b.useEffect(function() {
|
|
1372
|
-
return document.body.setAttribute(pe, (
|
|
1373
|
-
var e =
|
|
1372
|
+
return document.body.setAttribute(pe, (jt() + 1).toString()), function() {
|
|
1373
|
+
var e = jt() - 1;
|
|
1374
1374
|
e <= 0 ? document.body.removeAttribute(pe) : document.body.setAttribute(pe, e.toString());
|
|
1375
1375
|
};
|
|
1376
1376
|
}, []);
|
|
1377
|
-
},
|
|
1377
|
+
}, hs = function(e) {
|
|
1378
1378
|
var t = e.noRelative, n = e.noImportant, r = e.gapMode, s = r === void 0 ? "margin" : r;
|
|
1379
|
-
|
|
1379
|
+
vs();
|
|
1380
1380
|
var o = b.useMemo(function() {
|
|
1381
|
-
return
|
|
1381
|
+
return ds(s);
|
|
1382
1382
|
}, [s]);
|
|
1383
|
-
return b.createElement(
|
|
1383
|
+
return b.createElement(ps, { styles: fs(o, !t, s, n ? "" : "!important") });
|
|
1384
1384
|
}, ct = !1;
|
|
1385
1385
|
if (typeof window < "u")
|
|
1386
1386
|
try {
|
|
@@ -1393,7 +1393,7 @@ if (typeof window < "u")
|
|
|
1393
1393
|
} catch {
|
|
1394
1394
|
ct = !1;
|
|
1395
1395
|
}
|
|
1396
|
-
var ce = ct ? { passive: !1 } : !1,
|
|
1396
|
+
var ce = ct ? { passive: !1 } : !1, ms = function(e) {
|
|
1397
1397
|
return e.tagName === "TEXTAREA";
|
|
1398
1398
|
}, Sn = function(e, t) {
|
|
1399
1399
|
if (!(e instanceof Element))
|
|
@@ -1402,13 +1402,13 @@ var ce = ct ? { passive: !1 } : !1, bs = function(e) {
|
|
|
1402
1402
|
return (
|
|
1403
1403
|
// not-not-scrollable
|
|
1404
1404
|
n[t] !== "hidden" && // contains scroll inside self
|
|
1405
|
-
!(n.overflowY === n.overflowX && !
|
|
1405
|
+
!(n.overflowY === n.overflowX && !ms(e) && n[t] === "visible")
|
|
1406
1406
|
);
|
|
1407
|
-
},
|
|
1407
|
+
}, gs = function(e) {
|
|
1408
1408
|
return Sn(e, "overflowY");
|
|
1409
|
-
},
|
|
1409
|
+
}, bs = function(e) {
|
|
1410
1410
|
return Sn(e, "overflowX");
|
|
1411
|
-
},
|
|
1411
|
+
}, Kt = function(e, t) {
|
|
1412
1412
|
var n = t.ownerDocument, r = t;
|
|
1413
1413
|
do {
|
|
1414
1414
|
typeof ShadowRoot < "u" && r instanceof ShadowRoot && (r = r.host);
|
|
@@ -1421,14 +1421,14 @@ var ce = ct ? { passive: !1 } : !1, bs = function(e) {
|
|
|
1421
1421
|
r = r.parentNode;
|
|
1422
1422
|
} while (r && r !== n.body);
|
|
1423
1423
|
return !1;
|
|
1424
|
-
},
|
|
1424
|
+
}, xs = function(e) {
|
|
1425
1425
|
var t = e.scrollTop, n = e.scrollHeight, r = e.clientHeight;
|
|
1426
1426
|
return [
|
|
1427
1427
|
t,
|
|
1428
1428
|
n,
|
|
1429
1429
|
r
|
|
1430
1430
|
];
|
|
1431
|
-
},
|
|
1431
|
+
}, ys = function(e) {
|
|
1432
1432
|
var t = e.scrollLeft, n = e.scrollWidth, r = e.clientWidth;
|
|
1433
1433
|
return [
|
|
1434
1434
|
t,
|
|
@@ -1436,13 +1436,13 @@ var ce = ct ? { passive: !1 } : !1, bs = function(e) {
|
|
|
1436
1436
|
r
|
|
1437
1437
|
];
|
|
1438
1438
|
}, En = function(e, t) {
|
|
1439
|
-
return e === "v" ?
|
|
1439
|
+
return e === "v" ? gs(t) : bs(t);
|
|
1440
1440
|
}, Tn = function(e, t) {
|
|
1441
|
-
return e === "v" ?
|
|
1442
|
-
},
|
|
1441
|
+
return e === "v" ? xs(t) : ys(t);
|
|
1442
|
+
}, _s = function(e, t) {
|
|
1443
1443
|
return e === "h" && t === "rtl" ? -1 : 1;
|
|
1444
|
-
},
|
|
1445
|
-
var o =
|
|
1444
|
+
}, ws = function(e, t, n, r, s) {
|
|
1445
|
+
var o = _s(e, window.getComputedStyle(t).direction), l = o * r, i = n.target, u = t.contains(i), c = !1, d = l > 0, p = 0, x = 0;
|
|
1446
1446
|
do {
|
|
1447
1447
|
if (!i)
|
|
1448
1448
|
break;
|
|
@@ -1458,26 +1458,26 @@ var ce = ct ? { passive: !1 } : !1, bs = function(e) {
|
|
|
1458
1458
|
return (d && Math.abs(p) < 1 || !d && Math.abs(x) < 1) && (c = !0), c;
|
|
1459
1459
|
}, Pe = function(e) {
|
|
1460
1460
|
return "changedTouches" in e ? [e.changedTouches[0].clientX, e.changedTouches[0].clientY] : [0, 0];
|
|
1461
|
-
},
|
|
1461
|
+
}, Vt = function(e) {
|
|
1462
1462
|
return [e.deltaX, e.deltaY];
|
|
1463
|
-
},
|
|
1463
|
+
}, Yt = function(e) {
|
|
1464
1464
|
return e && "current" in e ? e.current : e;
|
|
1465
|
-
},
|
|
1465
|
+
}, ks = function(e, t) {
|
|
1466
1466
|
return e[0] === t[0] && e[1] === t[1];
|
|
1467
|
-
},
|
|
1467
|
+
}, Ns = function(e) {
|
|
1468
1468
|
return `
|
|
1469
1469
|
.block-interactivity-`.concat(e, ` {pointer-events: none;}
|
|
1470
1470
|
.allow-interactivity-`).concat(e, ` {pointer-events: all;}
|
|
1471
1471
|
`);
|
|
1472
|
-
},
|
|
1473
|
-
function
|
|
1474
|
-
var t = b.useRef([]), n = b.useRef([0, 0]), r = b.useRef(), s = b.useState(
|
|
1472
|
+
}, Ss = 0, ue = [];
|
|
1473
|
+
function Es(e) {
|
|
1474
|
+
var t = b.useRef([]), n = b.useRef([0, 0]), r = b.useRef(), s = b.useState(Ss++)[0], o = b.useState(Nn)[0], l = b.useRef(e);
|
|
1475
1475
|
b.useEffect(function() {
|
|
1476
1476
|
l.current = e;
|
|
1477
1477
|
}, [e]), b.useEffect(function() {
|
|
1478
1478
|
if (e.inert) {
|
|
1479
1479
|
document.body.classList.add("block-interactivity-".concat(s));
|
|
1480
|
-
var g =
|
|
1480
|
+
var g = Va([e.lockRef.current], (e.shards || []).map(Yt), !0).filter(Boolean);
|
|
1481
1481
|
return g.forEach(function(m) {
|
|
1482
1482
|
return m.classList.add("allow-interactivity-".concat(s));
|
|
1483
1483
|
}), function() {
|
|
@@ -1496,34 +1496,34 @@ function Cs(e) {
|
|
|
1496
1496
|
var C = window.getSelection(), A = C && C.anchorNode, P = A ? A === _ || A.contains(_) : !1;
|
|
1497
1497
|
if (P)
|
|
1498
1498
|
return !1;
|
|
1499
|
-
var
|
|
1500
|
-
if (!
|
|
1499
|
+
var F = Kt(N, _);
|
|
1500
|
+
if (!F)
|
|
1501
1501
|
return !0;
|
|
1502
|
-
if (
|
|
1502
|
+
if (F ? y = N : (y = N === "v" ? "h" : "v", F = Kt(N, _)), !F)
|
|
1503
1503
|
return !1;
|
|
1504
1504
|
if (!r.current && "changedTouches" in g && (v || f) && (r.current = y), !y)
|
|
1505
1505
|
return !0;
|
|
1506
|
-
var
|
|
1507
|
-
return
|
|
1506
|
+
var R = r.current || y;
|
|
1507
|
+
return ws(R, m, g, R === "h" ? v : f);
|
|
1508
1508
|
}, []), u = b.useCallback(function(g) {
|
|
1509
1509
|
var m = g;
|
|
1510
1510
|
if (!(!ue.length || ue[ue.length - 1] !== o)) {
|
|
1511
|
-
var w = "deltaY" in m ?
|
|
1512
|
-
return y.name === m.type && (y.target === m.target || m.target === y.shadowParent) &&
|
|
1511
|
+
var w = "deltaY" in m ? Vt(m) : Pe(m), h = t.current.filter(function(y) {
|
|
1512
|
+
return y.name === m.type && (y.target === m.target || m.target === y.shadowParent) && ks(y.delta, w);
|
|
1513
1513
|
})[0];
|
|
1514
1514
|
if (h && h.should) {
|
|
1515
1515
|
m.cancelable && m.preventDefault();
|
|
1516
1516
|
return;
|
|
1517
1517
|
}
|
|
1518
1518
|
if (!h) {
|
|
1519
|
-
var v = (l.current.shards || []).map(
|
|
1519
|
+
var v = (l.current.shards || []).map(Yt).filter(Boolean).filter(function(y) {
|
|
1520
1520
|
return y.contains(m.target);
|
|
1521
1521
|
}), f = v.length > 0 ? i(m, v[0]) : !l.current.noIsolation;
|
|
1522
1522
|
f && m.cancelable && m.preventDefault();
|
|
1523
1523
|
}
|
|
1524
1524
|
}
|
|
1525
1525
|
}, []), c = b.useCallback(function(g, m, w, h) {
|
|
1526
|
-
var v = { name: g, delta: m, target: w, should: h, shadowParent:
|
|
1526
|
+
var v = { name: g, delta: m, target: w, should: h, shadowParent: Ts(w) };
|
|
1527
1527
|
t.current.push(v), setTimeout(function() {
|
|
1528
1528
|
t.current = t.current.filter(function(f) {
|
|
1529
1529
|
return f !== v;
|
|
@@ -1532,7 +1532,7 @@ function Cs(e) {
|
|
|
1532
1532
|
}, []), d = b.useCallback(function(g) {
|
|
1533
1533
|
n.current = Pe(g), r.current = void 0;
|
|
1534
1534
|
}, []), p = b.useCallback(function(g) {
|
|
1535
|
-
c(g.type,
|
|
1535
|
+
c(g.type, Vt(g), g.target, i(g, e.lockRef.current));
|
|
1536
1536
|
}, []), x = b.useCallback(function(g) {
|
|
1537
1537
|
c(g.type, Pe(g), g.target, i(g, e.lockRef.current));
|
|
1538
1538
|
}, []);
|
|
@@ -1551,28 +1551,28 @@ function Cs(e) {
|
|
|
1551
1551
|
return b.createElement(
|
|
1552
1552
|
b.Fragment,
|
|
1553
1553
|
null,
|
|
1554
|
-
E ? b.createElement(o, { styles:
|
|
1555
|
-
k ? b.createElement(
|
|
1554
|
+
E ? b.createElement(o, { styles: Ns(s) }) : null,
|
|
1555
|
+
k ? b.createElement(hs, { noRelative: e.noRelative, gapMode: e.gapMode }) : null
|
|
1556
1556
|
);
|
|
1557
1557
|
}
|
|
1558
|
-
function
|
|
1558
|
+
function Ts(e) {
|
|
1559
1559
|
for (var t = null; e !== null; )
|
|
1560
1560
|
e instanceof ShadowRoot && (t = e.host, e = e.host), e = e.parentNode;
|
|
1561
1561
|
return t;
|
|
1562
1562
|
}
|
|
1563
|
-
const
|
|
1563
|
+
const Cs = ns(kn, Es);
|
|
1564
1564
|
var Cn = b.forwardRef(function(e, t) {
|
|
1565
|
-
return b.createElement(We, Q({}, e, { ref: t, sideCar:
|
|
1565
|
+
return b.createElement(We, Q({}, e, { ref: t, sideCar: Cs }));
|
|
1566
1566
|
});
|
|
1567
1567
|
Cn.classNames = We.classNames;
|
|
1568
|
-
var
|
|
1568
|
+
var As = function(e) {
|
|
1569
1569
|
if (typeof document > "u")
|
|
1570
1570
|
return null;
|
|
1571
1571
|
var t = Array.isArray(e) ? e[0] : e;
|
|
1572
1572
|
return t.ownerDocument.body;
|
|
1573
|
-
}, de = /* @__PURE__ */ new WeakMap(),
|
|
1573
|
+
}, de = /* @__PURE__ */ new WeakMap(), Re = /* @__PURE__ */ new WeakMap(), Fe = {}, nt = 0, An = function(e) {
|
|
1574
1574
|
return e && (e.host || An(e.parentNode));
|
|
1575
|
-
},
|
|
1575
|
+
}, Ps = function(e, t) {
|
|
1576
1576
|
return t.map(function(n) {
|
|
1577
1577
|
if (e.contains(n))
|
|
1578
1578
|
return n;
|
|
@@ -1581,10 +1581,10 @@ var Ds = function(e) {
|
|
|
1581
1581
|
}).filter(function(n) {
|
|
1582
1582
|
return !!n;
|
|
1583
1583
|
});
|
|
1584
|
-
},
|
|
1585
|
-
var s =
|
|
1586
|
-
|
|
1587
|
-
var o =
|
|
1584
|
+
}, Rs = function(e, t, n, r) {
|
|
1585
|
+
var s = Ps(t, Array.isArray(e) ? e : [e]);
|
|
1586
|
+
Fe[n] || (Fe[n] = /* @__PURE__ */ new WeakMap());
|
|
1587
|
+
var o = Fe[n], l = [], i = /* @__PURE__ */ new Set(), u = new Set(s), c = function(p) {
|
|
1588
1588
|
!p || i.has(p) || (i.add(p), c(p.parentNode));
|
|
1589
1589
|
};
|
|
1590
1590
|
s.forEach(c);
|
|
@@ -1595,7 +1595,7 @@ var Ds = function(e) {
|
|
|
1595
1595
|
else
|
|
1596
1596
|
try {
|
|
1597
1597
|
var k = x.getAttribute(r), E = k !== null && k !== "false", g = (de.get(x) || 0) + 1, m = (o.get(x) || 0) + 1;
|
|
1598
|
-
de.set(x, g), o.set(x, m), l.push(x), g === 1 && E &&
|
|
1598
|
+
de.set(x, g), o.set(x, m), l.push(x), g === 1 && E && Re.set(x, !0), m === 1 && x.setAttribute(n, "true"), E || x.setAttribute(r, "true");
|
|
1599
1599
|
} catch (w) {
|
|
1600
1600
|
console.error("aria-hidden: cannot operate on ", x, w);
|
|
1601
1601
|
}
|
|
@@ -1604,16 +1604,16 @@ var Ds = function(e) {
|
|
|
1604
1604
|
return d(t), i.clear(), nt++, function() {
|
|
1605
1605
|
l.forEach(function(p) {
|
|
1606
1606
|
var x = de.get(p) - 1, k = o.get(p) - 1;
|
|
1607
|
-
de.set(p, x), o.set(p, k), x || (
|
|
1608
|
-
}), nt--, nt || (de = /* @__PURE__ */ new WeakMap(), de = /* @__PURE__ */ new WeakMap(),
|
|
1607
|
+
de.set(p, x), o.set(p, k), x || (Re.has(p) || p.removeAttribute(r), Re.delete(p)), k || p.removeAttribute(n);
|
|
1608
|
+
}), nt--, nt || (de = /* @__PURE__ */ new WeakMap(), de = /* @__PURE__ */ new WeakMap(), Re = /* @__PURE__ */ new WeakMap(), Fe = {});
|
|
1609
1609
|
};
|
|
1610
|
-
},
|
|
1610
|
+
}, Fs = function(e, t, n) {
|
|
1611
1611
|
n === void 0 && (n = "data-aria-hidden");
|
|
1612
|
-
var r = Array.from(Array.isArray(e) ? e : [e]), s =
|
|
1613
|
-
return s ? (r.push.apply(r, Array.from(s.querySelectorAll("[aria-live], script"))),
|
|
1612
|
+
var r = Array.from(Array.isArray(e) ? e : [e]), s = As(e);
|
|
1613
|
+
return s ? (r.push.apply(r, Array.from(s.querySelectorAll("[aria-live], script"))), Rs(r, s, n, "aria-hidden")) : function() {
|
|
1614
1614
|
return null;
|
|
1615
1615
|
};
|
|
1616
|
-
}, He = "Dialog", [Pn] = he(He), [
|
|
1616
|
+
}, He = "Dialog", [Pn] = he(He), [Ds, Z] = Pn(He), Rn = (e) => {
|
|
1617
1617
|
const {
|
|
1618
1618
|
__scopeDialog: t,
|
|
1619
1619
|
children: n,
|
|
@@ -1628,7 +1628,7 @@ var Ds = function(e) {
|
|
|
1628
1628
|
caller: He
|
|
1629
1629
|
});
|
|
1630
1630
|
return /* @__PURE__ */ a(
|
|
1631
|
-
|
|
1631
|
+
Ds,
|
|
1632
1632
|
{
|
|
1633
1633
|
scope: t,
|
|
1634
1634
|
triggerRef: i,
|
|
@@ -1644,10 +1644,10 @@ var Ds = function(e) {
|
|
|
1644
1644
|
}
|
|
1645
1645
|
);
|
|
1646
1646
|
};
|
|
1647
|
-
|
|
1648
|
-
var
|
|
1647
|
+
Rn.displayName = He;
|
|
1648
|
+
var Fn = "DialogTrigger", Dn = b.forwardRef(
|
|
1649
1649
|
(e, t) => {
|
|
1650
|
-
const { __scopeDialog: n, ...r } = e, s = Z(
|
|
1650
|
+
const { __scopeDialog: n, ...r } = e, s = Z(Fn, n), o = K(t, s.triggerRef);
|
|
1651
1651
|
return /* @__PURE__ */ a(
|
|
1652
1652
|
B.button,
|
|
1653
1653
|
{
|
|
@@ -1655,7 +1655,7 @@ var Rn = "DialogTrigger", Fn = b.forwardRef(
|
|
|
1655
1655
|
"aria-haspopup": "dialog",
|
|
1656
1656
|
"aria-expanded": s.open,
|
|
1657
1657
|
"aria-controls": s.contentId,
|
|
1658
|
-
"data-state":
|
|
1658
|
+
"data-state": yt(s.open),
|
|
1659
1659
|
...r,
|
|
1660
1660
|
ref: o,
|
|
1661
1661
|
onClick: M(e.onClick, s.onOpenToggle)
|
|
@@ -1663,31 +1663,31 @@ var Rn = "DialogTrigger", Fn = b.forwardRef(
|
|
|
1663
1663
|
);
|
|
1664
1664
|
}
|
|
1665
1665
|
);
|
|
1666
|
-
|
|
1667
|
-
var
|
|
1666
|
+
Dn.displayName = Fn;
|
|
1667
|
+
var bt = "DialogPortal", [Is, In] = Pn(bt, {
|
|
1668
1668
|
forceMount: void 0
|
|
1669
1669
|
}), Ln = (e) => {
|
|
1670
|
-
const { __scopeDialog: t, forceMount: n, children: r, container: s } = e, o = Z(
|
|
1671
|
-
return /* @__PURE__ */ a(
|
|
1670
|
+
const { __scopeDialog: t, forceMount: n, children: r, container: s } = e, o = Z(bt, t);
|
|
1671
|
+
return /* @__PURE__ */ a(Is, { scope: t, forceMount: n, children: b.Children.map(r, (l) => /* @__PURE__ */ a(me, { present: n || o.open, children: /* @__PURE__ */ a(gt, { asChild: !0, container: s, children: l }) })) });
|
|
1672
1672
|
};
|
|
1673
|
-
Ln.displayName =
|
|
1673
|
+
Ln.displayName = bt;
|
|
1674
1674
|
var Be = "DialogOverlay", Mn = b.forwardRef(
|
|
1675
1675
|
(e, t) => {
|
|
1676
1676
|
const n = In(Be, e.__scopeDialog), { forceMount: r = n.forceMount, ...s } = e, o = Z(Be, e.__scopeDialog);
|
|
1677
|
-
return o.modal ? /* @__PURE__ */ a(me, { present: r || o.open, children: /* @__PURE__ */ a(
|
|
1677
|
+
return o.modal ? /* @__PURE__ */ a(me, { present: r || o.open, children: /* @__PURE__ */ a(Ms, { ...s, ref: t }) }) : null;
|
|
1678
1678
|
}
|
|
1679
1679
|
);
|
|
1680
1680
|
Mn.displayName = Be;
|
|
1681
|
-
var
|
|
1681
|
+
var Ls = /* @__PURE__ */ $e("DialogOverlay.RemoveScroll"), Ms = b.forwardRef(
|
|
1682
1682
|
(e, t) => {
|
|
1683
1683
|
const { __scopeDialog: n, ...r } = e, s = Z(Be, n);
|
|
1684
1684
|
return (
|
|
1685
1685
|
// Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
|
|
1686
1686
|
// ie. when `Overlay` and `Content` are siblings
|
|
1687
|
-
/* @__PURE__ */ a(Cn, { as:
|
|
1687
|
+
/* @__PURE__ */ a(Cn, { as: Ls, allowPinchZoom: !0, shards: [s.contentRef], children: /* @__PURE__ */ a(
|
|
1688
1688
|
B.div,
|
|
1689
1689
|
{
|
|
1690
|
-
"data-state":
|
|
1690
|
+
"data-state": yt(s.open),
|
|
1691
1691
|
...r,
|
|
1692
1692
|
ref: t,
|
|
1693
1693
|
style: { pointerEvents: "auto", ...r.style }
|
|
@@ -1698,16 +1698,16 @@ var Os = /* @__PURE__ */ $e("DialogOverlay.RemoveScroll"), $s = b.forwardRef(
|
|
|
1698
1698
|
), oe = "DialogContent", On = b.forwardRef(
|
|
1699
1699
|
(e, t) => {
|
|
1700
1700
|
const n = In(oe, e.__scopeDialog), { forceMount: r = n.forceMount, ...s } = e, o = Z(oe, e.__scopeDialog);
|
|
1701
|
-
return /* @__PURE__ */ a(me, { present: r || o.open, children: o.modal ? /* @__PURE__ */ a(
|
|
1701
|
+
return /* @__PURE__ */ a(me, { present: r || o.open, children: o.modal ? /* @__PURE__ */ a(Os, { ...s, ref: t }) : /* @__PURE__ */ a($s, { ...s, ref: t }) });
|
|
1702
1702
|
}
|
|
1703
1703
|
);
|
|
1704
1704
|
On.displayName = oe;
|
|
1705
|
-
var
|
|
1705
|
+
var Os = b.forwardRef(
|
|
1706
1706
|
(e, t) => {
|
|
1707
1707
|
const n = Z(oe, e.__scopeDialog), r = b.useRef(null), s = K(t, n.contentRef, r);
|
|
1708
1708
|
return b.useEffect(() => {
|
|
1709
1709
|
const o = r.current;
|
|
1710
|
-
if (o) return
|
|
1710
|
+
if (o) return Fs(o);
|
|
1711
1711
|
}, []), /* @__PURE__ */ a(
|
|
1712
1712
|
$n,
|
|
1713
1713
|
{
|
|
@@ -1730,7 +1730,7 @@ var Bs = b.forwardRef(
|
|
|
1730
1730
|
}
|
|
1731
1731
|
);
|
|
1732
1732
|
}
|
|
1733
|
-
),
|
|
1733
|
+
), $s = b.forwardRef(
|
|
1734
1734
|
(e, t) => {
|
|
1735
1735
|
const n = Z(oe, e.__scopeDialog), r = b.useRef(!1), s = b.useRef(!1);
|
|
1736
1736
|
return /* @__PURE__ */ a(
|
|
@@ -1756,7 +1756,7 @@ var Bs = b.forwardRef(
|
|
|
1756
1756
|
), $n = b.forwardRef(
|
|
1757
1757
|
(e, t) => {
|
|
1758
1758
|
const { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: s, onCloseAutoFocus: o, ...l } = e, i = Z(oe, n), u = b.useRef(null), c = K(t, u);
|
|
1759
|
-
return
|
|
1759
|
+
return Ka(), /* @__PURE__ */ S(q, { children: [
|
|
1760
1760
|
/* @__PURE__ */ a(
|
|
1761
1761
|
xn,
|
|
1762
1762
|
{
|
|
@@ -1766,13 +1766,13 @@ var Bs = b.forwardRef(
|
|
|
1766
1766
|
onMountAutoFocus: s,
|
|
1767
1767
|
onUnmountAutoFocus: o,
|
|
1768
1768
|
children: /* @__PURE__ */ a(
|
|
1769
|
-
|
|
1769
|
+
mt,
|
|
1770
1770
|
{
|
|
1771
1771
|
role: "dialog",
|
|
1772
1772
|
id: i.contentId,
|
|
1773
1773
|
"aria-describedby": i.descriptionId,
|
|
1774
1774
|
"aria-labelledby": i.titleId,
|
|
1775
|
-
"data-state":
|
|
1775
|
+
"data-state": yt(i.open),
|
|
1776
1776
|
...l,
|
|
1777
1777
|
ref: c,
|
|
1778
1778
|
onDismiss: () => i.onOpenChange(!1)
|
|
@@ -1781,18 +1781,18 @@ var Bs = b.forwardRef(
|
|
|
1781
1781
|
}
|
|
1782
1782
|
),
|
|
1783
1783
|
/* @__PURE__ */ S(q, { children: [
|
|
1784
|
-
/* @__PURE__ */ a(
|
|
1785
|
-
/* @__PURE__ */ a(
|
|
1784
|
+
/* @__PURE__ */ a(Bs, { titleId: i.titleId }),
|
|
1785
|
+
/* @__PURE__ */ a(Us, { contentRef: u, descriptionId: i.descriptionId })
|
|
1786
1786
|
] })
|
|
1787
1787
|
] });
|
|
1788
1788
|
}
|
|
1789
|
-
),
|
|
1789
|
+
), xt = "DialogTitle", Bn = b.forwardRef(
|
|
1790
1790
|
(e, t) => {
|
|
1791
|
-
const { __scopeDialog: n, ...r } = e, s = Z(
|
|
1791
|
+
const { __scopeDialog: n, ...r } = e, s = Z(xt, n);
|
|
1792
1792
|
return /* @__PURE__ */ a(B.h2, { id: s.titleId, ...r, ref: t });
|
|
1793
1793
|
}
|
|
1794
1794
|
);
|
|
1795
|
-
Bn.displayName =
|
|
1795
|
+
Bn.displayName = xt;
|
|
1796
1796
|
var zn = "DialogDescription", Un = b.forwardRef(
|
|
1797
1797
|
(e, t) => {
|
|
1798
1798
|
const { __scopeDialog: n, ...r } = e, s = Z(zn, n);
|
|
@@ -1815,14 +1815,14 @@ var Wn = "DialogClose", Hn = b.forwardRef(
|
|
|
1815
1815
|
}
|
|
1816
1816
|
);
|
|
1817
1817
|
Hn.displayName = Wn;
|
|
1818
|
-
function
|
|
1818
|
+
function yt(e) {
|
|
1819
1819
|
return e ? "open" : "closed";
|
|
1820
1820
|
}
|
|
1821
|
-
var Gn = "DialogTitleWarning", [
|
|
1821
|
+
var Gn = "DialogTitleWarning", [Ti, jn] = fa(Gn, {
|
|
1822
1822
|
contentName: oe,
|
|
1823
|
-
titleName:
|
|
1823
|
+
titleName: xt,
|
|
1824
1824
|
docsSlug: "dialog"
|
|
1825
|
-
}),
|
|
1825
|
+
}), Bs = ({ titleId: e }) => {
|
|
1826
1826
|
const t = jn(Gn), n = `\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
1827
1827
|
|
|
1828
1828
|
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
@@ -1831,46 +1831,15 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
|
|
|
1831
1831
|
return b.useEffect(() => {
|
|
1832
1832
|
e && (document.getElementById(e) || console.error(n));
|
|
1833
1833
|
}, [n, e]), null;
|
|
1834
|
-
},
|
|
1835
|
-
const r = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${jn(
|
|
1834
|
+
}, zs = "DialogDescriptionWarning", Us = ({ contentRef: e, descriptionId: t }) => {
|
|
1835
|
+
const r = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${jn(zs).contentName}}.`;
|
|
1836
1836
|
return b.useEffect(() => {
|
|
1837
1837
|
var o;
|
|
1838
1838
|
const s = (o = e.current) == null ? void 0 : o.getAttribute("aria-describedby");
|
|
1839
1839
|
t && s && (document.getElementById(t) || console.warn(r));
|
|
1840
1840
|
}, [r, e, t]), null;
|
|
1841
|
-
},
|
|
1842
|
-
function
|
|
1843
|
-
return vt().isPhone;
|
|
1844
|
-
}
|
|
1845
|
-
function Vn({
|
|
1846
|
-
trigger: e,
|
|
1847
|
-
title: t,
|
|
1848
|
-
description: n,
|
|
1849
|
-
side: r = "right",
|
|
1850
|
-
children: s,
|
|
1851
|
-
footer: o,
|
|
1852
|
-
className: l,
|
|
1853
|
-
...i
|
|
1854
|
-
}) {
|
|
1855
|
-
return /* @__PURE__ */ S(wt, { ...i, children: [
|
|
1856
|
-
e ? /* @__PURE__ */ a(kt, { asChild: !0, children: e }) : null,
|
|
1857
|
-
/* @__PURE__ */ S(Nt, { children: [
|
|
1858
|
-
/* @__PURE__ */ a(St, { className: "vx-sheet__overlay" }),
|
|
1859
|
-
/* @__PURE__ */ S(Et, { className: T("vx-sheet", `vx-sheet--${r}`, l), children: [
|
|
1860
|
-
/* @__PURE__ */ S("div", { className: "vx-sheet__header", children: [
|
|
1861
|
-
/* @__PURE__ */ S("div", { children: [
|
|
1862
|
-
t ? /* @__PURE__ */ a(Tt, { className: "vx-sheet__title", children: t }) : null,
|
|
1863
|
-
n ? /* @__PURE__ */ a(Ct, { className: "vx-sheet__description", children: n }) : null
|
|
1864
|
-
] }),
|
|
1865
|
-
/* @__PURE__ */ a(ze, { className: "vx-dialog__close", "aria-label": "Close", children: /* @__PURE__ */ a(ve, { size: 16 }) })
|
|
1866
|
-
] }),
|
|
1867
|
-
/* @__PURE__ */ a("div", { className: "vx-sheet__body", children: s }),
|
|
1868
|
-
o ? /* @__PURE__ */ a("div", { className: "vx-sheet__footer", children: o }) : null
|
|
1869
|
-
] })
|
|
1870
|
-
] })
|
|
1871
|
-
] });
|
|
1872
|
-
}
|
|
1873
|
-
function Pi({
|
|
1841
|
+
}, _t = Rn, wt = Dn, kt = Ln, Nt = Mn, St = On, Et = Bn, Tt = Un, ze = Hn;
|
|
1842
|
+
function Ci({
|
|
1874
1843
|
trigger: e,
|
|
1875
1844
|
title: t,
|
|
1876
1845
|
description: n,
|
|
@@ -1879,27 +1848,15 @@ function Pi({
|
|
|
1879
1848
|
className: o,
|
|
1880
1849
|
...l
|
|
1881
1850
|
}) {
|
|
1882
|
-
return
|
|
1883
|
-
|
|
1884
|
-
{
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
description: n,
|
|
1888
|
-
side: "bottom",
|
|
1889
|
-
footer: s,
|
|
1890
|
-
className: T("vx-dialog--mobile-sheet", o),
|
|
1891
|
-
...l,
|
|
1892
|
-
children: r
|
|
1893
|
-
}
|
|
1894
|
-
) : /* @__PURE__ */ S(wt, { ...l, children: [
|
|
1895
|
-
/* @__PURE__ */ a(kt, { asChild: !0, children: e }),
|
|
1896
|
-
/* @__PURE__ */ S(Nt, { children: [
|
|
1897
|
-
/* @__PURE__ */ a(St, { className: "vx-dialog__overlay" }),
|
|
1898
|
-
/* @__PURE__ */ S(Et, { className: T("vx-dialog__content", o), children: [
|
|
1851
|
+
return /* @__PURE__ */ S(_t, { ...l, children: [
|
|
1852
|
+
/* @__PURE__ */ a(wt, { asChild: !0, children: e }),
|
|
1853
|
+
/* @__PURE__ */ S(kt, { children: [
|
|
1854
|
+
/* @__PURE__ */ a(Nt, { className: "vx-dialog__overlay" }),
|
|
1855
|
+
/* @__PURE__ */ S(St, { className: T("vx-dialog__content", o), children: [
|
|
1899
1856
|
/* @__PURE__ */ S("div", { className: "vx-dialog__header", children: [
|
|
1900
1857
|
/* @__PURE__ */ S("div", { children: [
|
|
1901
|
-
/* @__PURE__ */ a(
|
|
1902
|
-
n ? /* @__PURE__ */ a(
|
|
1858
|
+
/* @__PURE__ */ a(Et, { className: "vx-dialog__title", children: t }),
|
|
1859
|
+
n ? /* @__PURE__ */ a(Tt, { className: "vx-dialog__description", children: n }) : null
|
|
1903
1860
|
] }),
|
|
1904
1861
|
/* @__PURE__ */ a(ze, { className: "vx-dialog__close", "aria-label": "Close dialog", children: /* @__PURE__ */ a(ve, { size: 16 }) })
|
|
1905
1862
|
] }),
|
|
@@ -1909,7 +1866,7 @@ function Pi({
|
|
|
1909
1866
|
] })
|
|
1910
1867
|
] });
|
|
1911
1868
|
}
|
|
1912
|
-
function
|
|
1869
|
+
function Ai({ className: e, label: t, hint: n, prefix: r, suffix: s, error: o, ...l }) {
|
|
1913
1870
|
return /* @__PURE__ */ S("label", { className: "vx-field-group", children: [
|
|
1914
1871
|
t ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: t }) : null,
|
|
1915
1872
|
/* @__PURE__ */ S("span", { className: T("vx-input", o && "vx-input--invalid", e), children: [
|
|
@@ -1921,11 +1878,11 @@ function Di({ className: e, label: t, hint: n, prefix: r, suffix: s, error: o, .
|
|
|
1921
1878
|
!o && n ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: n }) : null
|
|
1922
1879
|
] });
|
|
1923
1880
|
}
|
|
1924
|
-
function
|
|
1881
|
+
function Ws(e) {
|
|
1925
1882
|
const t = b.useRef({ value: e, previous: e });
|
|
1926
1883
|
return b.useMemo(() => (t.current.value !== e && (t.current.previous = t.current.value, t.current.value = e), t.current.previous), [e]);
|
|
1927
1884
|
}
|
|
1928
|
-
function
|
|
1885
|
+
function Hs(e) {
|
|
1929
1886
|
const [t, n] = b.useState(void 0);
|
|
1930
1887
|
return se(() => {
|
|
1931
1888
|
if (e) {
|
|
@@ -1947,7 +1904,7 @@ function js(e) {
|
|
|
1947
1904
|
n(void 0);
|
|
1948
1905
|
}, [e]), t;
|
|
1949
1906
|
}
|
|
1950
|
-
var Ge = "Switch", [
|
|
1907
|
+
var Ge = "Switch", [Gs] = he(Ge), [js, Ks] = Gs(Ge), Kn = b.forwardRef(
|
|
1951
1908
|
(e, t) => {
|
|
1952
1909
|
const {
|
|
1953
1910
|
__scopeSwitch: n,
|
|
@@ -1966,7 +1923,7 @@ var Ge = "Switch", [Ks] = he(Ge), [Vs, Ys] = Ks(Ge), Yn = b.forwardRef(
|
|
|
1966
1923
|
onChange: c,
|
|
1967
1924
|
caller: Ge
|
|
1968
1925
|
});
|
|
1969
|
-
return /* @__PURE__ */ S(
|
|
1926
|
+
return /* @__PURE__ */ S(js, { scope: n, checked: w, disabled: i, children: [
|
|
1970
1927
|
/* @__PURE__ */ a(
|
|
1971
1928
|
B.button,
|
|
1972
1929
|
{
|
|
@@ -1974,7 +1931,7 @@ var Ge = "Switch", [Ks] = he(Ge), [Vs, Ys] = Ks(Ge), Yn = b.forwardRef(
|
|
|
1974
1931
|
role: "switch",
|
|
1975
1932
|
"aria-checked": w,
|
|
1976
1933
|
"aria-required": l,
|
|
1977
|
-
"data-state":
|
|
1934
|
+
"data-state": Xn(w),
|
|
1978
1935
|
"data-disabled": i ? "" : void 0,
|
|
1979
1936
|
disabled: i,
|
|
1980
1937
|
value: u,
|
|
@@ -1986,7 +1943,7 @@ var Ge = "Switch", [Ks] = he(Ge), [Vs, Ys] = Ks(Ge), Yn = b.forwardRef(
|
|
|
1986
1943
|
}
|
|
1987
1944
|
),
|
|
1988
1945
|
m && /* @__PURE__ */ a(
|
|
1989
|
-
|
|
1946
|
+
qn,
|
|
1990
1947
|
{
|
|
1991
1948
|
control: x,
|
|
1992
1949
|
bubbles: !g.current,
|
|
@@ -2002,14 +1959,14 @@ var Ge = "Switch", [Ks] = he(Ge), [Vs, Ys] = Ks(Ge), Yn = b.forwardRef(
|
|
|
2002
1959
|
] });
|
|
2003
1960
|
}
|
|
2004
1961
|
);
|
|
2005
|
-
|
|
2006
|
-
var
|
|
1962
|
+
Kn.displayName = Ge;
|
|
1963
|
+
var Vn = "SwitchThumb", Yn = b.forwardRef(
|
|
2007
1964
|
(e, t) => {
|
|
2008
|
-
const { __scopeSwitch: n, ...r } = e, s =
|
|
1965
|
+
const { __scopeSwitch: n, ...r } = e, s = Ks(Vn, n);
|
|
2009
1966
|
return /* @__PURE__ */ a(
|
|
2010
1967
|
B.span,
|
|
2011
1968
|
{
|
|
2012
|
-
"data-state":
|
|
1969
|
+
"data-state": Xn(s.checked),
|
|
2013
1970
|
"data-disabled": s.disabled ? "" : void 0,
|
|
2014
1971
|
...r,
|
|
2015
1972
|
ref: t
|
|
@@ -2017,8 +1974,8 @@ var qn = "SwitchThumb", Xn = b.forwardRef(
|
|
|
2017
1974
|
);
|
|
2018
1975
|
}
|
|
2019
1976
|
);
|
|
2020
|
-
|
|
2021
|
-
var
|
|
1977
|
+
Yn.displayName = Vn;
|
|
1978
|
+
var Vs = "SwitchBubbleInput", qn = b.forwardRef(
|
|
2022
1979
|
({
|
|
2023
1980
|
__scopeSwitch: e,
|
|
2024
1981
|
control: t,
|
|
@@ -2026,7 +1983,7 @@ var qs = "SwitchBubbleInput", Zn = b.forwardRef(
|
|
|
2026
1983
|
bubbles: r = !0,
|
|
2027
1984
|
...s
|
|
2028
1985
|
}, o) => {
|
|
2029
|
-
const l = b.useRef(null), i = K(l, o), u =
|
|
1986
|
+
const l = b.useRef(null), i = K(l, o), u = Ws(n), c = Hs(t);
|
|
2030
1987
|
return b.useEffect(() => {
|
|
2031
1988
|
const d = l.current;
|
|
2032
1989
|
if (!d) return;
|
|
@@ -2059,21 +2016,21 @@ var qs = "SwitchBubbleInput", Zn = b.forwardRef(
|
|
|
2059
2016
|
);
|
|
2060
2017
|
}
|
|
2061
2018
|
);
|
|
2062
|
-
|
|
2063
|
-
function
|
|
2019
|
+
qn.displayName = Vs;
|
|
2020
|
+
function Xn(e) {
|
|
2064
2021
|
return e ? "checked" : "unchecked";
|
|
2065
2022
|
}
|
|
2066
|
-
var
|
|
2067
|
-
function
|
|
2023
|
+
var Ys = Kn, qs = Yn;
|
|
2024
|
+
function Pi({ className: e, label: t, description: n, ...r }) {
|
|
2068
2025
|
return /* @__PURE__ */ S("label", { className: "vx-switch", children: [
|
|
2069
2026
|
/* @__PURE__ */ S("span", { className: "vx-switch__copy", children: [
|
|
2070
2027
|
/* @__PURE__ */ a("span", { className: "vx-switch__label", children: t }),
|
|
2071
2028
|
n ? /* @__PURE__ */ a("span", { className: "vx-switch__description", children: n }) : null
|
|
2072
2029
|
] }),
|
|
2073
|
-
/* @__PURE__ */ a(
|
|
2030
|
+
/* @__PURE__ */ a(Ys, { className: T("vx-switch__control", e), ...r, children: /* @__PURE__ */ a(qs, { className: "vx-switch__thumb" }) })
|
|
2074
2031
|
] });
|
|
2075
2032
|
}
|
|
2076
|
-
function
|
|
2033
|
+
function Zn(e) {
|
|
2077
2034
|
const t = e + "CollectionProvider", [n, r] = he(t), [s, o] = n(
|
|
2078
2035
|
t,
|
|
2079
2036
|
{ collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
|
|
@@ -2113,19 +2070,19 @@ function Jn(e) {
|
|
|
2113
2070
|
r
|
|
2114
2071
|
];
|
|
2115
2072
|
}
|
|
2116
|
-
var
|
|
2117
|
-
function
|
|
2118
|
-
const t = b.useContext(
|
|
2073
|
+
var Xs = b.createContext(void 0);
|
|
2074
|
+
function Qn(e) {
|
|
2075
|
+
const t = b.useContext(Xs);
|
|
2119
2076
|
return e || t || "ltr";
|
|
2120
2077
|
}
|
|
2121
|
-
var rt = "rovingFocusGroup.onEntryFocus",
|
|
2078
|
+
var rt = "rovingFocusGroup.onEntryFocus", Zs = { bubbles: !1, cancelable: !0 }, ke = "RovingFocusGroup", [ut, Jn, Qs] = Zn(ke), [Js, er] = he(
|
|
2122
2079
|
ke,
|
|
2123
|
-
[
|
|
2124
|
-
), [
|
|
2125
|
-
(e, t) => /* @__PURE__ */ a(ut.Provider, { scope: e.__scopeRovingFocusGroup, children: /* @__PURE__ */ a(ut.Slot, { scope: e.__scopeRovingFocusGroup, children: /* @__PURE__ */ a(
|
|
2080
|
+
[Qs]
|
|
2081
|
+
), [eo, to] = Js(ke), tr = b.forwardRef(
|
|
2082
|
+
(e, t) => /* @__PURE__ */ a(ut.Provider, { scope: e.__scopeRovingFocusGroup, children: /* @__PURE__ */ a(ut.Slot, { scope: e.__scopeRovingFocusGroup, children: /* @__PURE__ */ a(no, { ...e, ref: t }) }) })
|
|
2126
2083
|
);
|
|
2127
|
-
|
|
2128
|
-
var
|
|
2084
|
+
tr.displayName = ke;
|
|
2085
|
+
var no = b.forwardRef((e, t) => {
|
|
2129
2086
|
const {
|
|
2130
2087
|
__scopeRovingFocusGroup: n,
|
|
2131
2088
|
orientation: r,
|
|
@@ -2137,18 +2094,18 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2137
2094
|
onEntryFocus: c,
|
|
2138
2095
|
preventScrollOnEntryFocus: d = !1,
|
|
2139
2096
|
...p
|
|
2140
|
-
} = e, x = b.useRef(null), k = K(t, x), E =
|
|
2097
|
+
} = e, x = b.useRef(null), k = K(t, x), E = Qn(o), [g, m] = we({
|
|
2141
2098
|
prop: l,
|
|
2142
2099
|
defaultProp: i ?? null,
|
|
2143
2100
|
onChange: u,
|
|
2144
2101
|
caller: ke
|
|
2145
|
-
}), [w, h] = b.useState(!1), v = J(c), f =
|
|
2102
|
+
}), [w, h] = b.useState(!1), v = J(c), f = Jn(n), y = b.useRef(!1), [_, N] = b.useState(0);
|
|
2146
2103
|
return b.useEffect(() => {
|
|
2147
2104
|
const C = x.current;
|
|
2148
2105
|
if (C)
|
|
2149
2106
|
return C.addEventListener(rt, v), () => C.removeEventListener(rt, v);
|
|
2150
2107
|
}, [v]), /* @__PURE__ */ a(
|
|
2151
|
-
|
|
2108
|
+
eo,
|
|
2152
2109
|
{
|
|
2153
2110
|
scope: n,
|
|
2154
2111
|
orientation: r,
|
|
@@ -2182,12 +2139,12 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2182
2139
|
onFocus: M(e.onFocus, (C) => {
|
|
2183
2140
|
const A = !y.current;
|
|
2184
2141
|
if (C.target === C.currentTarget && A && !w) {
|
|
2185
|
-
const P = new CustomEvent(rt,
|
|
2142
|
+
const P = new CustomEvent(rt, Zs);
|
|
2186
2143
|
if (C.currentTarget.dispatchEvent(P), !P.defaultPrevented) {
|
|
2187
|
-
const
|
|
2144
|
+
const F = f().filter((H) => H.focusable), R = F.find((H) => H.active), $ = F.find((H) => H.id === g), W = [R, $, ...F].filter(
|
|
2188
2145
|
Boolean
|
|
2189
2146
|
).map((H) => H.ref.current);
|
|
2190
|
-
|
|
2147
|
+
ar(W, d);
|
|
2191
2148
|
}
|
|
2192
2149
|
}
|
|
2193
2150
|
y.current = !1;
|
|
@@ -2197,7 +2154,7 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2197
2154
|
)
|
|
2198
2155
|
}
|
|
2199
2156
|
);
|
|
2200
|
-
}),
|
|
2157
|
+
}), nr = "RovingFocusGroupItem", rr = b.forwardRef(
|
|
2201
2158
|
(e, t) => {
|
|
2202
2159
|
const {
|
|
2203
2160
|
__scopeRovingFocusGroup: n,
|
|
@@ -2206,7 +2163,7 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2206
2163
|
tabStopId: o,
|
|
2207
2164
|
children: l,
|
|
2208
2165
|
...i
|
|
2209
|
-
} = e, u = xe(), c = o || u, d =
|
|
2166
|
+
} = e, u = xe(), c = o || u, d = to(nr, n), p = d.currentTabStopId === c, x = Jn(n), { onFocusableItemAdd: k, onFocusableItemRemove: E, currentTabStopId: g } = d;
|
|
2210
2167
|
return b.useEffect(() => {
|
|
2211
2168
|
if (r)
|
|
2212
2169
|
return k(), () => E();
|
|
@@ -2234,7 +2191,7 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2234
2191
|
return;
|
|
2235
2192
|
}
|
|
2236
2193
|
if (m.target !== m.currentTarget) return;
|
|
2237
|
-
const w =
|
|
2194
|
+
const w = so(m, d.orientation, d.dir);
|
|
2238
2195
|
if (w !== void 0) {
|
|
2239
2196
|
if (m.metaKey || m.ctrlKey || m.altKey || m.shiftKey) return;
|
|
2240
2197
|
m.preventDefault();
|
|
@@ -2243,9 +2200,9 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2243
2200
|
else if (w === "prev" || w === "next") {
|
|
2244
2201
|
w === "prev" && v.reverse();
|
|
2245
2202
|
const f = v.indexOf(m.currentTarget);
|
|
2246
|
-
v = d.loop ?
|
|
2203
|
+
v = d.loop ? oo(v, f + 1) : v.slice(f + 1);
|
|
2247
2204
|
}
|
|
2248
|
-
setTimeout(() =>
|
|
2205
|
+
setTimeout(() => ar(v));
|
|
2249
2206
|
}
|
|
2250
2207
|
}),
|
|
2251
2208
|
children: typeof l == "function" ? l({ isCurrentTabStop: p, hasTabStop: g != null }) : l
|
|
@@ -2255,8 +2212,8 @@ var ao = b.forwardRef((e, t) => {
|
|
|
2255
2212
|
);
|
|
2256
2213
|
}
|
|
2257
2214
|
);
|
|
2258
|
-
|
|
2259
|
-
var
|
|
2215
|
+
rr.displayName = nr;
|
|
2216
|
+
var ro = {
|
|
2260
2217
|
ArrowLeft: "prev",
|
|
2261
2218
|
ArrowUp: "prev",
|
|
2262
2219
|
ArrowRight: "next",
|
|
@@ -2266,25 +2223,25 @@ var so = {
|
|
|
2266
2223
|
PageDown: "last",
|
|
2267
2224
|
End: "last"
|
|
2268
2225
|
};
|
|
2269
|
-
function
|
|
2226
|
+
function ao(e, t) {
|
|
2270
2227
|
return t !== "rtl" ? e : e === "ArrowLeft" ? "ArrowRight" : e === "ArrowRight" ? "ArrowLeft" : e;
|
|
2271
2228
|
}
|
|
2272
|
-
function
|
|
2273
|
-
const r =
|
|
2229
|
+
function so(e, t, n) {
|
|
2230
|
+
const r = ao(e.key, n);
|
|
2274
2231
|
if (!(t === "vertical" && ["ArrowLeft", "ArrowRight"].includes(r)) && !(t === "horizontal" && ["ArrowUp", "ArrowDown"].includes(r)))
|
|
2275
|
-
return
|
|
2232
|
+
return ro[r];
|
|
2276
2233
|
}
|
|
2277
|
-
function
|
|
2234
|
+
function ar(e, t = !1) {
|
|
2278
2235
|
const n = document.activeElement;
|
|
2279
2236
|
for (const r of e)
|
|
2280
2237
|
if (r === n || (r.focus({ preventScroll: t }), document.activeElement !== n)) return;
|
|
2281
2238
|
}
|
|
2282
|
-
function
|
|
2239
|
+
function oo(e, t) {
|
|
2283
2240
|
return e.map((n, r) => e[(t + r) % e.length]);
|
|
2284
2241
|
}
|
|
2285
|
-
var
|
|
2286
|
-
|
|
2287
|
-
]),
|
|
2242
|
+
var io = tr, lo = rr, je = "Tabs", [co] = he(je, [
|
|
2243
|
+
er
|
|
2244
|
+
]), sr = er(), [uo, Ct] = co(je), or = b.forwardRef(
|
|
2288
2245
|
(e, t) => {
|
|
2289
2246
|
const {
|
|
2290
2247
|
__scopeTabs: n,
|
|
@@ -2295,14 +2252,14 @@ var co = rr, uo = sr, je = "Tabs", [po] = he(je, [
|
|
|
2295
2252
|
dir: i,
|
|
2296
2253
|
activationMode: u = "automatic",
|
|
2297
2254
|
...c
|
|
2298
|
-
} = e, d =
|
|
2255
|
+
} = e, d = Qn(i), [p, x] = we({
|
|
2299
2256
|
prop: r,
|
|
2300
2257
|
onChange: s,
|
|
2301
2258
|
defaultProp: o ?? "",
|
|
2302
2259
|
caller: je
|
|
2303
2260
|
});
|
|
2304
2261
|
return /* @__PURE__ */ a(
|
|
2305
|
-
|
|
2262
|
+
uo,
|
|
2306
2263
|
{
|
|
2307
2264
|
scope: n,
|
|
2308
2265
|
baseId: xe(),
|
|
@@ -2324,12 +2281,12 @@ var co = rr, uo = sr, je = "Tabs", [po] = he(je, [
|
|
|
2324
2281
|
);
|
|
2325
2282
|
}
|
|
2326
2283
|
);
|
|
2327
|
-
|
|
2328
|
-
var
|
|
2284
|
+
or.displayName = je;
|
|
2285
|
+
var ir = "TabsList", lr = b.forwardRef(
|
|
2329
2286
|
(e, t) => {
|
|
2330
|
-
const { __scopeTabs: n, loop: r = !0, ...s } = e, o =
|
|
2287
|
+
const { __scopeTabs: n, loop: r = !0, ...s } = e, o = Ct(ir, n), l = sr(n);
|
|
2331
2288
|
return /* @__PURE__ */ a(
|
|
2332
|
-
|
|
2289
|
+
io,
|
|
2333
2290
|
{
|
|
2334
2291
|
asChild: !0,
|
|
2335
2292
|
...l,
|
|
@@ -2349,12 +2306,12 @@ var cr = "TabsList", ur = b.forwardRef(
|
|
|
2349
2306
|
);
|
|
2350
2307
|
}
|
|
2351
2308
|
);
|
|
2352
|
-
|
|
2353
|
-
var
|
|
2309
|
+
lr.displayName = ir;
|
|
2310
|
+
var cr = "TabsTrigger", ur = b.forwardRef(
|
|
2354
2311
|
(e, t) => {
|
|
2355
|
-
const { __scopeTabs: n, value: r, disabled: s = !1, ...o } = e, l =
|
|
2312
|
+
const { __scopeTabs: n, value: r, disabled: s = !1, ...o } = e, l = Ct(cr, n), i = sr(n), u = fr(l.baseId, r), c = vr(l.baseId, r), d = r === l.value;
|
|
2356
2313
|
return /* @__PURE__ */ a(
|
|
2357
|
-
|
|
2314
|
+
lo,
|
|
2358
2315
|
{
|
|
2359
2316
|
asChild: !0,
|
|
2360
2317
|
...i,
|
|
@@ -2389,10 +2346,10 @@ var dr = "TabsTrigger", pr = b.forwardRef(
|
|
|
2389
2346
|
);
|
|
2390
2347
|
}
|
|
2391
2348
|
);
|
|
2392
|
-
|
|
2393
|
-
var
|
|
2349
|
+
ur.displayName = cr;
|
|
2350
|
+
var dr = "TabsContent", pr = b.forwardRef(
|
|
2394
2351
|
(e, t) => {
|
|
2395
|
-
const { __scopeTabs: n, value: r, forceMount: s, children: o, ...l } = e, i =
|
|
2352
|
+
const { __scopeTabs: n, value: r, forceMount: s, children: o, ...l } = e, i = Ct(dr, n), u = fr(i.baseId, r), c = vr(i.baseId, r), d = r === i.value, p = b.useRef(d);
|
|
2396
2353
|
return b.useEffect(() => {
|
|
2397
2354
|
const x = requestAnimationFrame(() => p.current = !1);
|
|
2398
2355
|
return () => cancelAnimationFrame(x);
|
|
@@ -2417,21 +2374,21 @@ var fr = "TabsContent", vr = b.forwardRef(
|
|
|
2417
2374
|
) });
|
|
2418
2375
|
}
|
|
2419
2376
|
);
|
|
2420
|
-
|
|
2421
|
-
function
|
|
2377
|
+
pr.displayName = dr;
|
|
2378
|
+
function fr(e, t) {
|
|
2422
2379
|
return `${e}-trigger-${t}`;
|
|
2423
2380
|
}
|
|
2424
|
-
function
|
|
2381
|
+
function vr(e, t) {
|
|
2425
2382
|
return `${e}-content-${t}`;
|
|
2426
2383
|
}
|
|
2427
|
-
var
|
|
2428
|
-
const
|
|
2429
|
-
return /* @__PURE__ */ a(
|
|
2430
|
-
}),
|
|
2431
|
-
return /* @__PURE__ */ a(
|
|
2432
|
-
}),
|
|
2433
|
-
return /* @__PURE__ */ a(
|
|
2434
|
-
}),
|
|
2384
|
+
var po = or, fo = lr, vo = ur, ho = pr;
|
|
2385
|
+
const Ri = po, Fi = re(function({ className: t, ...n }, r) {
|
|
2386
|
+
return /* @__PURE__ */ a(fo, { ref: r, className: T("vx-tabs__list", t), ...n });
|
|
2387
|
+
}), Di = re(function({ className: t, ...n }, r) {
|
|
2388
|
+
return /* @__PURE__ */ a(vo, { ref: r, className: T("vx-tabs__trigger", t), ...n });
|
|
2389
|
+
}), Ii = re(function({ className: t, ...n }, r) {
|
|
2390
|
+
return /* @__PURE__ */ a(ho, { ref: r, className: T("vx-tabs__content", t), ...n });
|
|
2391
|
+
}), hr = {
|
|
2435
2392
|
light: {
|
|
2436
2393
|
label: "Light",
|
|
2437
2394
|
mode: "light"
|
|
@@ -2448,8 +2405,8 @@ function Y(e, t = {}) {
|
|
|
2448
2405
|
tokens: t.tokens
|
|
2449
2406
|
};
|
|
2450
2407
|
}
|
|
2451
|
-
const
|
|
2452
|
-
...
|
|
2408
|
+
const Li = {
|
|
2409
|
+
...hr,
|
|
2453
2410
|
sunset: Y("light", {
|
|
2454
2411
|
label: "Sunset",
|
|
2455
2412
|
tokens: {
|
|
@@ -2757,13 +2714,13 @@ const Oi = {
|
|
|
2757
2714
|
}
|
|
2758
2715
|
})
|
|
2759
2716
|
};
|
|
2760
|
-
function
|
|
2717
|
+
function mo(e) {
|
|
2761
2718
|
return {
|
|
2762
|
-
...
|
|
2719
|
+
...hr,
|
|
2763
2720
|
...e
|
|
2764
2721
|
};
|
|
2765
2722
|
}
|
|
2766
|
-
function
|
|
2723
|
+
function go(e, t) {
|
|
2767
2724
|
if (e && t[e])
|
|
2768
2725
|
return e;
|
|
2769
2726
|
if (t.light)
|
|
@@ -2771,25 +2728,25 @@ function xo(e, t) {
|
|
|
2771
2728
|
const [n] = Object.keys(t);
|
|
2772
2729
|
return n ?? "light";
|
|
2773
2730
|
}
|
|
2774
|
-
function
|
|
2731
|
+
function bo(e, t) {
|
|
2775
2732
|
const n = window.localStorage.getItem(e);
|
|
2776
2733
|
return n && t[n] ? n : null;
|
|
2777
2734
|
}
|
|
2778
|
-
function
|
|
2735
|
+
function xo(e, t, n) {
|
|
2779
2736
|
var s;
|
|
2780
2737
|
if (((s = e[n]) == null ? void 0 : s.mode) === t)
|
|
2781
2738
|
return n;
|
|
2782
2739
|
const r = Object.entries(e).find(([, o]) => o.mode === t);
|
|
2783
2740
|
return r == null ? void 0 : r[0];
|
|
2784
2741
|
}
|
|
2785
|
-
const
|
|
2786
|
-
function
|
|
2742
|
+
const mr = _e(null);
|
|
2743
|
+
function Mi({
|
|
2787
2744
|
children: e,
|
|
2788
2745
|
defaultTheme: t = "light",
|
|
2789
2746
|
storageKey: n = "vxui-react-theme",
|
|
2790
2747
|
themes: r
|
|
2791
2748
|
}) {
|
|
2792
|
-
const s = be(() =>
|
|
2749
|
+
const s = be(() => mo(r), [r]), o = be(() => go(t, s), [t, s]), l = L([]), [i, u] = D(() => typeof window > "u" ? o : bo(n, s) ?? o), c = s[i] ? i : o, d = s[c];
|
|
2793
2750
|
O(() => {
|
|
2794
2751
|
i !== c && u(c);
|
|
2795
2752
|
}, [c, i]), O(() => {
|
|
@@ -2815,21 +2772,21 @@ function $i({
|
|
|
2815
2772
|
toggleTheme: () => {
|
|
2816
2773
|
u((x) => {
|
|
2817
2774
|
const E = (s[x] ?? d).mode === "light" ? "dark" : "light";
|
|
2818
|
-
return
|
|
2775
|
+
return xo(s, E, E) ?? x;
|
|
2819
2776
|
});
|
|
2820
2777
|
}
|
|
2821
2778
|
}),
|
|
2822
2779
|
[d, o, s, c]
|
|
2823
2780
|
);
|
|
2824
|
-
return /* @__PURE__ */ a(
|
|
2781
|
+
return /* @__PURE__ */ a(mr.Provider, { value: p, children: e });
|
|
2825
2782
|
}
|
|
2826
|
-
function
|
|
2827
|
-
const e = ye(
|
|
2783
|
+
function Oi() {
|
|
2784
|
+
const e = ye(mr);
|
|
2828
2785
|
if (!e)
|
|
2829
2786
|
throw new Error("useTheme must be used within ThemeProvider.");
|
|
2830
2787
|
return e;
|
|
2831
2788
|
}
|
|
2832
|
-
var
|
|
2789
|
+
var yo = Object.freeze({
|
|
2833
2790
|
// See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
|
|
2834
2791
|
position: "absolute",
|
|
2835
2792
|
border: 0,
|
|
@@ -2841,18 +2798,18 @@ var wo = Object.freeze({
|
|
|
2841
2798
|
clip: "rect(0, 0, 0, 0)",
|
|
2842
2799
|
whiteSpace: "nowrap",
|
|
2843
2800
|
wordWrap: "normal"
|
|
2844
|
-
}),
|
|
2801
|
+
}), _o = "VisuallyHidden", At = b.forwardRef(
|
|
2845
2802
|
(e, t) => /* @__PURE__ */ a(
|
|
2846
2803
|
B.span,
|
|
2847
2804
|
{
|
|
2848
2805
|
...e,
|
|
2849
2806
|
ref: t,
|
|
2850
|
-
style: { ...
|
|
2807
|
+
style: { ...yo, ...e.style }
|
|
2851
2808
|
}
|
|
2852
2809
|
)
|
|
2853
2810
|
);
|
|
2854
|
-
|
|
2855
|
-
var
|
|
2811
|
+
At.displayName = _o;
|
|
2812
|
+
var Pt = "ToastProvider", [Rt, wo, ko] = Zn("Toast"), [gr] = he("Toast", [ko]), [No, Ke] = gr(Pt), br = (e) => {
|
|
2856
2813
|
const {
|
|
2857
2814
|
__scopeToast: t,
|
|
2858
2815
|
label: n = "Notification",
|
|
@@ -2862,9 +2819,9 @@ var Dt = "ToastProvider", [Rt, No, So] = Jn("Toast"), [xr] = he("Toast", [So]),
|
|
|
2862
2819
|
children: l
|
|
2863
2820
|
} = e, [i, u] = b.useState(null), [c, d] = b.useState(0), p = b.useRef(!1), x = b.useRef(!1);
|
|
2864
2821
|
return n.trim() || console.error(
|
|
2865
|
-
`Invalid prop \`label\` supplied to \`${
|
|
2822
|
+
`Invalid prop \`label\` supplied to \`${Pt}\`. Expected non-empty \`string\`.`
|
|
2866
2823
|
), /* @__PURE__ */ a(Rt.Provider, { scope: t, children: /* @__PURE__ */ a(
|
|
2867
|
-
|
|
2824
|
+
No,
|
|
2868
2825
|
{
|
|
2869
2826
|
scope: t,
|
|
2870
2827
|
label: n,
|
|
@@ -2882,15 +2839,15 @@ var Dt = "ToastProvider", [Rt, No, So] = Jn("Toast"), [xr] = he("Toast", [So]),
|
|
|
2882
2839
|
}
|
|
2883
2840
|
) });
|
|
2884
2841
|
};
|
|
2885
|
-
|
|
2886
|
-
var
|
|
2842
|
+
br.displayName = Pt;
|
|
2843
|
+
var xr = "ToastViewport", So = ["F8"], dt = "toast.viewportPause", pt = "toast.viewportResume", yr = b.forwardRef(
|
|
2887
2844
|
(e, t) => {
|
|
2888
2845
|
const {
|
|
2889
2846
|
__scopeToast: n,
|
|
2890
|
-
hotkey: r =
|
|
2847
|
+
hotkey: r = So,
|
|
2891
2848
|
label: s = "Notifications ({hotkey})",
|
|
2892
2849
|
...o
|
|
2893
|
-
} = e, l = Ke(
|
|
2850
|
+
} = e, l = Ke(xr, n), i = wo(n), u = b.useRef(null), c = b.useRef(null), d = b.useRef(null), p = b.useRef(null), x = K(t, p, l.onViewportChange), k = r.join("+").replace(/Key/g, "").replace(/Digit/g, ""), E = l.toastCount > 0;
|
|
2894
2851
|
b.useEffect(() => {
|
|
2895
2852
|
const m = (w) => {
|
|
2896
2853
|
var v;
|
|
@@ -2923,7 +2880,7 @@ var _r = "ToastViewport", To = ["F8"], dt = "toast.viewportPause", pt = "toast.v
|
|
|
2923
2880
|
const g = b.useCallback(
|
|
2924
2881
|
({ tabbingDirection: m }) => {
|
|
2925
2882
|
const h = i().map((v) => {
|
|
2926
|
-
const f = v.ref.current, y = [f, ...
|
|
2883
|
+
const f = v.ref.current, y = [f, ...Bo(f)];
|
|
2927
2884
|
return m === "forwards" ? y : y.reverse();
|
|
2928
2885
|
});
|
|
2929
2886
|
return (m === "forwards" ? h.reverse() : h).flat();
|
|
@@ -2942,14 +2899,14 @@ var _r = "ToastViewport", To = ["F8"], dt = "toast.viewportPause", pt = "toast.v
|
|
|
2942
2899
|
(y = c.current) == null || y.focus();
|
|
2943
2900
|
return;
|
|
2944
2901
|
}
|
|
2945
|
-
const
|
|
2946
|
-
at(
|
|
2902
|
+
const R = g({ tabbingDirection: A ? "backwards" : "forwards" }), $ = R.findIndex((I) => I === C);
|
|
2903
|
+
at(R.slice($ + 1)) ? h.preventDefault() : A ? (_ = c.current) == null || _.focus() : (N = d.current) == null || N.focus();
|
|
2947
2904
|
}
|
|
2948
2905
|
};
|
|
2949
2906
|
return m.addEventListener("keydown", w), () => m.removeEventListener("keydown", w);
|
|
2950
2907
|
}
|
|
2951
2908
|
}, [i, g]), /* @__PURE__ */ S(
|
|
2952
|
-
|
|
2909
|
+
Ia,
|
|
2953
2910
|
{
|
|
2954
2911
|
ref: u,
|
|
2955
2912
|
role: "region",
|
|
@@ -2987,12 +2944,12 @@ var _r = "ToastViewport", To = ["F8"], dt = "toast.viewportPause", pt = "toast.v
|
|
|
2987
2944
|
);
|
|
2988
2945
|
}
|
|
2989
2946
|
);
|
|
2990
|
-
|
|
2991
|
-
var
|
|
2947
|
+
yr.displayName = xr;
|
|
2948
|
+
var _r = "ToastFocusProxy", ft = b.forwardRef(
|
|
2992
2949
|
(e, t) => {
|
|
2993
|
-
const { __scopeToast: n, onFocusFromOutsideViewport: r, ...s } = e, o = Ke(
|
|
2950
|
+
const { __scopeToast: n, onFocusFromOutsideViewport: r, ...s } = e, o = Ke(_r, n);
|
|
2994
2951
|
return /* @__PURE__ */ a(
|
|
2995
|
-
|
|
2952
|
+
At,
|
|
2996
2953
|
{
|
|
2997
2954
|
tabIndex: 0,
|
|
2998
2955
|
...s,
|
|
@@ -3007,8 +2964,8 @@ var kr = "ToastFocusProxy", ft = b.forwardRef(
|
|
|
3007
2964
|
);
|
|
3008
2965
|
}
|
|
3009
2966
|
);
|
|
3010
|
-
ft.displayName =
|
|
3011
|
-
var Ne = "Toast",
|
|
2967
|
+
ft.displayName = _r;
|
|
2968
|
+
var Ne = "Toast", Eo = "toast.swipeStart", To = "toast.swipeMove", Co = "toast.swipeCancel", Ao = "toast.swipeEnd", wr = b.forwardRef(
|
|
3012
2969
|
(e, t) => {
|
|
3013
2970
|
const { forceMount: n, open: r, defaultOpen: s, onOpenChange: o, ...l } = e, [i, u] = we({
|
|
3014
2971
|
prop: r,
|
|
@@ -3017,7 +2974,7 @@ var Ne = "Toast", Co = "toast.swipeStart", Ao = "toast.swipeMove", Po = "toast.s
|
|
|
3017
2974
|
caller: Ne
|
|
3018
2975
|
});
|
|
3019
2976
|
return /* @__PURE__ */ a(me, { present: n || i, children: /* @__PURE__ */ a(
|
|
3020
|
-
|
|
2977
|
+
Fo,
|
|
3021
2978
|
{
|
|
3022
2979
|
open: i,
|
|
3023
2980
|
...l,
|
|
@@ -3043,11 +3000,11 @@ var Ne = "Toast", Co = "toast.swipeStart", Ao = "toast.swipeMove", Po = "toast.s
|
|
|
3043
3000
|
) });
|
|
3044
3001
|
}
|
|
3045
3002
|
);
|
|
3046
|
-
|
|
3047
|
-
var [
|
|
3003
|
+
wr.displayName = Ne;
|
|
3004
|
+
var [Po, Ro] = gr(Ne, {
|
|
3048
3005
|
onClose() {
|
|
3049
3006
|
}
|
|
3050
|
-
}),
|
|
3007
|
+
}), Fo = b.forwardRef(
|
|
3051
3008
|
(e, t) => {
|
|
3052
3009
|
const {
|
|
3053
3010
|
__scopeToast: n,
|
|
@@ -3063,20 +3020,20 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3063
3020
|
onSwipeCancel: x,
|
|
3064
3021
|
onSwipeEnd: k,
|
|
3065
3022
|
...E
|
|
3066
|
-
} = e, g = Ke(Ne, n), [m, w] = b.useState(null), h = K(t, (I) => w(I)), v = b.useRef(null), f = b.useRef(null), y = s || g.duration, _ = b.useRef(0), N = b.useRef(y), C = b.useRef(0), { onToastAdd: A, onToastRemove: P } = g,
|
|
3023
|
+
} = e, g = Ke(Ne, n), [m, w] = b.useState(null), h = K(t, (I) => w(I)), v = b.useRef(null), f = b.useRef(null), y = s || g.duration, _ = b.useRef(0), N = b.useRef(y), C = b.useRef(0), { onToastAdd: A, onToastRemove: P } = g, F = J(() => {
|
|
3067
3024
|
var W;
|
|
3068
3025
|
(m == null ? void 0 : m.contains(document.activeElement)) && ((W = g.viewport) == null || W.focus()), l();
|
|
3069
|
-
}),
|
|
3026
|
+
}), R = b.useCallback(
|
|
3070
3027
|
(I) => {
|
|
3071
|
-
!I || I === 1 / 0 || (window.clearTimeout(C.current), _.current = (/* @__PURE__ */ new Date()).getTime(), C.current = window.setTimeout(
|
|
3028
|
+
!I || I === 1 / 0 || (window.clearTimeout(C.current), _.current = (/* @__PURE__ */ new Date()).getTime(), C.current = window.setTimeout(F, I));
|
|
3072
3029
|
},
|
|
3073
|
-
[
|
|
3030
|
+
[F]
|
|
3074
3031
|
);
|
|
3075
3032
|
b.useEffect(() => {
|
|
3076
3033
|
const I = g.viewport;
|
|
3077
3034
|
if (I) {
|
|
3078
3035
|
const W = () => {
|
|
3079
|
-
|
|
3036
|
+
R(N.current), c == null || c();
|
|
3080
3037
|
}, H = () => {
|
|
3081
3038
|
const ee = (/* @__PURE__ */ new Date()).getTime() - _.current;
|
|
3082
3039
|
N.current = N.current - ee, window.clearTimeout(C.current), u == null || u();
|
|
@@ -3085,13 +3042,13 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3085
3042
|
I.removeEventListener(dt, H), I.removeEventListener(pt, W);
|
|
3086
3043
|
};
|
|
3087
3044
|
}
|
|
3088
|
-
}, [g.viewport, y, u, c,
|
|
3089
|
-
o && !g.isClosePausedRef.current &&
|
|
3090
|
-
}, [o, y, g.isClosePausedRef,
|
|
3091
|
-
const $ = b.useMemo(() => m ?
|
|
3045
|
+
}, [g.viewport, y, u, c, R]), b.useEffect(() => {
|
|
3046
|
+
o && !g.isClosePausedRef.current && R(y);
|
|
3047
|
+
}, [o, y, g.isClosePausedRef, R]), b.useEffect(() => (A(), () => P()), [A, P]);
|
|
3048
|
+
const $ = b.useMemo(() => m ? Cr(m) : null, [m]);
|
|
3092
3049
|
return g.viewport ? /* @__PURE__ */ S(q, { children: [
|
|
3093
3050
|
$ && /* @__PURE__ */ a(
|
|
3094
|
-
|
|
3051
|
+
Do,
|
|
3095
3052
|
{
|
|
3096
3053
|
__scopeToast: n,
|
|
3097
3054
|
role: "status",
|
|
@@ -3099,13 +3056,13 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3099
3056
|
children: $
|
|
3100
3057
|
}
|
|
3101
3058
|
),
|
|
3102
|
-
/* @__PURE__ */ a(
|
|
3059
|
+
/* @__PURE__ */ a(Po, { scope: n, onClose: F, children: sn.createPortal(
|
|
3103
3060
|
/* @__PURE__ */ a(Rt.ItemSlot, { scope: n, children: /* @__PURE__ */ a(
|
|
3104
|
-
|
|
3061
|
+
Da,
|
|
3105
3062
|
{
|
|
3106
3063
|
asChild: !0,
|
|
3107
3064
|
onEscapeKeyDown: M(i, () => {
|
|
3108
|
-
g.isFocusedToastEscapeKeyDownRef.current ||
|
|
3065
|
+
g.isFocusedToastEscapeKeyDownRef.current || F(), g.isFocusedToastEscapeKeyDownRef.current = !1;
|
|
3109
3066
|
}),
|
|
3110
3067
|
children: /* @__PURE__ */ a(
|
|
3111
3068
|
B.li,
|
|
@@ -3117,7 +3074,7 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3117
3074
|
ref: h,
|
|
3118
3075
|
style: { userSelect: "none", touchAction: "none", ...e.style },
|
|
3119
3076
|
onKeyDown: M(e.onKeyDown, (I) => {
|
|
3120
|
-
I.key === "Escape" && (i == null || i(I.nativeEvent), I.nativeEvent.defaultPrevented || (g.isFocusedToastEscapeKeyDownRef.current = !0,
|
|
3077
|
+
I.key === "Escape" && (i == null || i(I.nativeEvent), I.nativeEvent.defaultPrevented || (g.isFocusedToastEscapeKeyDownRef.current = !0, F()));
|
|
3121
3078
|
}),
|
|
3122
3079
|
onPointerDown: M(e.onPointerDown, (I) => {
|
|
3123
3080
|
I.button === 0 && (v.current = { x: I.clientX, y: I.clientY });
|
|
@@ -3125,9 +3082,9 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3125
3082
|
onPointerMove: M(e.onPointerMove, (I) => {
|
|
3126
3083
|
if (!v.current) return;
|
|
3127
3084
|
const W = I.clientX - v.current.x, H = I.clientY - v.current.y, ee = !!f.current, z = ["left", "right"].includes(g.swipeDirection), G = ["left", "up"].includes(g.swipeDirection) ? Math.min : Math.max, te = z ? G(0, W) : 0, ie = z ? 0 : G(0, H), j = I.pointerType === "touch" ? 10 : 2, le = { x: te, y: ie }, V = { originalEvent: I, delta: le };
|
|
3128
|
-
ee ? (f.current = le,
|
|
3085
|
+
ee ? (f.current = le, De(To, p, V, {
|
|
3129
3086
|
discrete: !1
|
|
3130
|
-
})) :
|
|
3087
|
+
})) : qt(le, g.swipeDirection, j) ? (f.current = le, De(Eo, d, V, {
|
|
3131
3088
|
discrete: !1
|
|
3132
3089
|
}), I.target.setPointerCapture(I.pointerId)) : (Math.abs(W) > j || Math.abs(H) > j) && (v.current = null);
|
|
3133
3090
|
}),
|
|
@@ -3135,10 +3092,10 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3135
3092
|
const W = f.current, H = I.target;
|
|
3136
3093
|
if (H.hasPointerCapture(I.pointerId) && H.releasePointerCapture(I.pointerId), f.current = null, v.current = null, W) {
|
|
3137
3094
|
const ee = I.currentTarget, z = { originalEvent: I, delta: W };
|
|
3138
|
-
|
|
3095
|
+
qt(W, g.swipeDirection, g.swipeThreshold) ? De(Ao, k, z, {
|
|
3139
3096
|
discrete: !0
|
|
3140
|
-
}) :
|
|
3141
|
-
|
|
3097
|
+
}) : De(
|
|
3098
|
+
Co,
|
|
3142
3099
|
x,
|
|
3143
3100
|
z,
|
|
3144
3101
|
{
|
|
@@ -3157,43 +3114,43 @@ var [Ro, Fo] = xr(Ne, {
|
|
|
3157
3114
|
) })
|
|
3158
3115
|
] }) : null;
|
|
3159
3116
|
}
|
|
3160
|
-
),
|
|
3117
|
+
), Do = (e) => {
|
|
3161
3118
|
const { __scopeToast: t, children: n, ...r } = e, s = Ke(Ne, t), [o, l] = b.useState(!1), [i, u] = b.useState(!1);
|
|
3162
|
-
return
|
|
3119
|
+
return Oo(() => l(!0)), b.useEffect(() => {
|
|
3163
3120
|
const c = window.setTimeout(() => u(!0), 1e3);
|
|
3164
3121
|
return () => window.clearTimeout(c);
|
|
3165
|
-
}, []), i ? null : /* @__PURE__ */ a(
|
|
3122
|
+
}, []), i ? null : /* @__PURE__ */ a(gt, { asChild: !0, children: /* @__PURE__ */ a(At, { ...r, children: o && /* @__PURE__ */ S(q, { children: [
|
|
3166
3123
|
s.label,
|
|
3167
3124
|
" ",
|
|
3168
3125
|
n
|
|
3169
3126
|
] }) }) });
|
|
3170
|
-
},
|
|
3127
|
+
}, Io = "ToastTitle", kr = b.forwardRef(
|
|
3171
3128
|
(e, t) => {
|
|
3172
3129
|
const { __scopeToast: n, ...r } = e;
|
|
3173
3130
|
return /* @__PURE__ */ a(B.div, { ...r, ref: t });
|
|
3174
3131
|
}
|
|
3175
3132
|
);
|
|
3176
|
-
|
|
3177
|
-
var
|
|
3133
|
+
kr.displayName = Io;
|
|
3134
|
+
var Lo = "ToastDescription", Nr = b.forwardRef(
|
|
3178
3135
|
(e, t) => {
|
|
3179
3136
|
const { __scopeToast: n, ...r } = e;
|
|
3180
3137
|
return /* @__PURE__ */ a(B.div, { ...r, ref: t });
|
|
3181
3138
|
}
|
|
3182
3139
|
);
|
|
3183
|
-
|
|
3184
|
-
var
|
|
3140
|
+
Nr.displayName = Lo;
|
|
3141
|
+
var Sr = "ToastAction", Mo = b.forwardRef(
|
|
3185
3142
|
(e, t) => {
|
|
3186
3143
|
const { altText: n, ...r } = e;
|
|
3187
|
-
return n.trim() ? /* @__PURE__ */ a(
|
|
3188
|
-
`Invalid prop \`altText\` supplied to \`${
|
|
3144
|
+
return n.trim() ? /* @__PURE__ */ a(Tr, { altText: n, asChild: !0, children: /* @__PURE__ */ a(Ft, { ...r, ref: t }) }) : (console.error(
|
|
3145
|
+
`Invalid prop \`altText\` supplied to \`${Sr}\`. Expected non-empty \`string\`.`
|
|
3189
3146
|
), null);
|
|
3190
3147
|
}
|
|
3191
3148
|
);
|
|
3192
|
-
|
|
3193
|
-
var
|
|
3149
|
+
Mo.displayName = Sr;
|
|
3150
|
+
var Er = "ToastClose", Ft = b.forwardRef(
|
|
3194
3151
|
(e, t) => {
|
|
3195
|
-
const { __scopeToast: n, ...r } = e, s =
|
|
3196
|
-
return /* @__PURE__ */ a(
|
|
3152
|
+
const { __scopeToast: n, ...r } = e, s = Ro(Er, n);
|
|
3153
|
+
return /* @__PURE__ */ a(Tr, { asChild: !0, children: /* @__PURE__ */ a(
|
|
3197
3154
|
B.button,
|
|
3198
3155
|
{
|
|
3199
3156
|
type: "button",
|
|
@@ -3204,8 +3161,8 @@ var Cr = "ToastClose", Ft = b.forwardRef(
|
|
|
3204
3161
|
) });
|
|
3205
3162
|
}
|
|
3206
3163
|
);
|
|
3207
|
-
Ft.displayName =
|
|
3208
|
-
var
|
|
3164
|
+
Ft.displayName = Er;
|
|
3165
|
+
var Tr = b.forwardRef((e, t) => {
|
|
3209
3166
|
const { __scopeToast: n, altText: r, ...s } = e;
|
|
3210
3167
|
return /* @__PURE__ */ a(
|
|
3211
3168
|
B.div,
|
|
@@ -3217,29 +3174,29 @@ var Ar = b.forwardRef((e, t) => {
|
|
|
3217
3174
|
}
|
|
3218
3175
|
);
|
|
3219
3176
|
});
|
|
3220
|
-
function
|
|
3177
|
+
function Cr(e) {
|
|
3221
3178
|
const t = [];
|
|
3222
3179
|
return Array.from(e.childNodes).forEach((r) => {
|
|
3223
|
-
if (r.nodeType === r.TEXT_NODE && r.textContent && t.push(r.textContent),
|
|
3180
|
+
if (r.nodeType === r.TEXT_NODE && r.textContent && t.push(r.textContent), $o(r)) {
|
|
3224
3181
|
const s = r.ariaHidden || r.hidden || r.style.display === "none", o = r.dataset.radixToastAnnounceExclude === "";
|
|
3225
3182
|
if (!s)
|
|
3226
3183
|
if (o) {
|
|
3227
3184
|
const l = r.dataset.radixToastAnnounceAlt;
|
|
3228
3185
|
l && t.push(l);
|
|
3229
3186
|
} else
|
|
3230
|
-
t.push(...
|
|
3187
|
+
t.push(...Cr(r));
|
|
3231
3188
|
}
|
|
3232
3189
|
}), t;
|
|
3233
3190
|
}
|
|
3234
|
-
function
|
|
3191
|
+
function De(e, t, n, { discrete: r }) {
|
|
3235
3192
|
const s = n.originalEvent.currentTarget, o = new CustomEvent(e, { bubbles: !0, cancelable: !0, detail: n });
|
|
3236
3193
|
t && s.addEventListener(e, t, { once: !0 }), r ? hn(s, o) : s.dispatchEvent(o);
|
|
3237
3194
|
}
|
|
3238
|
-
var
|
|
3195
|
+
var qt = (e, t, n = 0) => {
|
|
3239
3196
|
const r = Math.abs(e.x), s = Math.abs(e.y), o = r > s;
|
|
3240
3197
|
return t === "left" || t === "right" ? o && r > n : !o && s > n;
|
|
3241
3198
|
};
|
|
3242
|
-
function
|
|
3199
|
+
function Oo(e = () => {
|
|
3243
3200
|
}) {
|
|
3244
3201
|
const t = J(e);
|
|
3245
3202
|
se(() => {
|
|
@@ -3249,10 +3206,10 @@ function Bo(e = () => {
|
|
|
3249
3206
|
};
|
|
3250
3207
|
}, [t]);
|
|
3251
3208
|
}
|
|
3252
|
-
function
|
|
3209
|
+
function $o(e) {
|
|
3253
3210
|
return e.nodeType === e.ELEMENT_NODE;
|
|
3254
3211
|
}
|
|
3255
|
-
function
|
|
3212
|
+
function Bo(e) {
|
|
3256
3213
|
const t = [], n = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, {
|
|
3257
3214
|
acceptNode: (r) => {
|
|
3258
3215
|
const s = r.tagName === "INPUT" && r.type === "hidden";
|
|
@@ -3266,22 +3223,22 @@ function at(e) {
|
|
|
3266
3223
|
const t = document.activeElement;
|
|
3267
3224
|
return e.some((n) => n === t ? !0 : (n.focus(), document.activeElement !== t));
|
|
3268
3225
|
}
|
|
3269
|
-
var
|
|
3270
|
-
const
|
|
3271
|
-
let
|
|
3272
|
-
function
|
|
3273
|
-
const [t, n] =
|
|
3226
|
+
var zo = br, Uo = yr, Wo = wr, Ho = kr, Go = Nr, jo = Ft;
|
|
3227
|
+
const Ar = _e(null);
|
|
3228
|
+
let Ko = 1;
|
|
3229
|
+
function $i({ children: e }) {
|
|
3230
|
+
const [t, n] = D([]), r = be(
|
|
3274
3231
|
() => ({
|
|
3275
3232
|
push: (s) => {
|
|
3276
|
-
n((o) => [...o, { id:
|
|
3233
|
+
n((o) => [...o, { id: Ko += 1, tone: "info", ...s }]);
|
|
3277
3234
|
}
|
|
3278
3235
|
}),
|
|
3279
3236
|
[]
|
|
3280
3237
|
);
|
|
3281
|
-
return /* @__PURE__ */ a(
|
|
3238
|
+
return /* @__PURE__ */ a(Ar.Provider, { value: r, children: /* @__PURE__ */ S(zo, { swipeDirection: "right", children: [
|
|
3282
3239
|
e,
|
|
3283
3240
|
t.map((s) => /* @__PURE__ */ S(
|
|
3284
|
-
|
|
3241
|
+
Wo,
|
|
3285
3242
|
{
|
|
3286
3243
|
className: T("vx-toast", `vx-toast--${s.tone ?? "info"}`),
|
|
3287
3244
|
duration: 4500,
|
|
@@ -3291,24 +3248,24 @@ function zi({ children: e }) {
|
|
|
3291
3248
|
},
|
|
3292
3249
|
children: [
|
|
3293
3250
|
/* @__PURE__ */ S("div", { className: "vx-toast__content", children: [
|
|
3294
|
-
/* @__PURE__ */ a(
|
|
3295
|
-
s.description ? /* @__PURE__ */ a(
|
|
3251
|
+
/* @__PURE__ */ a(Ho, { className: "vx-toast__title", children: s.title }),
|
|
3252
|
+
s.description ? /* @__PURE__ */ a(Go, { className: "vx-toast__description", children: s.description }) : null
|
|
3296
3253
|
] }),
|
|
3297
|
-
/* @__PURE__ */ a(
|
|
3254
|
+
/* @__PURE__ */ a(jo, { className: "vx-toast__close", "aria-label": "Dismiss notification", children: /* @__PURE__ */ a(ve, { size: 16 }) })
|
|
3298
3255
|
]
|
|
3299
3256
|
},
|
|
3300
3257
|
s.id
|
|
3301
3258
|
)),
|
|
3302
|
-
/* @__PURE__ */ a(
|
|
3259
|
+
/* @__PURE__ */ a(Uo, { className: "vx-toast__viewport" })
|
|
3303
3260
|
] }) });
|
|
3304
3261
|
}
|
|
3305
|
-
function
|
|
3306
|
-
const e = ye(
|
|
3262
|
+
function Bi() {
|
|
3263
|
+
const e = ye(Ar);
|
|
3307
3264
|
if (!e)
|
|
3308
3265
|
throw new Error("useToast must be used within ToastProvider.");
|
|
3309
3266
|
return e;
|
|
3310
3267
|
}
|
|
3311
|
-
function
|
|
3268
|
+
function zi({
|
|
3312
3269
|
as: e = "p",
|
|
3313
3270
|
variant: t = "default",
|
|
3314
3271
|
size: n = "base",
|
|
@@ -3332,7 +3289,7 @@ function Wi({
|
|
|
3332
3289
|
}
|
|
3333
3290
|
);
|
|
3334
3291
|
}
|
|
3335
|
-
function
|
|
3292
|
+
function Ui({
|
|
3336
3293
|
as: e,
|
|
3337
3294
|
level: t = 2,
|
|
3338
3295
|
variant: n = "default",
|
|
@@ -3357,7 +3314,7 @@ function Hi({
|
|
|
3357
3314
|
}
|
|
3358
3315
|
);
|
|
3359
3316
|
}
|
|
3360
|
-
function
|
|
3317
|
+
function Wi({ className: e, label: t, hint: n, placeholder: r, children: s, ...o }) {
|
|
3361
3318
|
return /* @__PURE__ */ S("label", { className: "vx-field-group", children: [
|
|
3362
3319
|
t ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: t }) : null,
|
|
3363
3320
|
/* @__PURE__ */ S("span", { className: T("vx-select", e), children: [
|
|
@@ -3370,7 +3327,7 @@ function Gi({ className: e, label: t, hint: n, placeholder: r, children: s, ...o
|
|
|
3370
3327
|
n ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: n }) : null
|
|
3371
3328
|
] });
|
|
3372
3329
|
}
|
|
3373
|
-
function
|
|
3330
|
+
function Hi({ className: e, label: t, description: n, indeterminate: r, ...s }) {
|
|
3374
3331
|
return /* @__PURE__ */ S("label", { className: T("vx-checkbox", s.disabled && "vx-checkbox--disabled"), children: [
|
|
3375
3332
|
/* @__PURE__ */ S("span", { className: "vx-checkbox__control-wrap", children: [
|
|
3376
3333
|
/* @__PURE__ */ a(
|
|
@@ -3392,7 +3349,7 @@ function ji({ className: e, label: t, description: n, indeterminate: r, ...s })
|
|
|
3392
3349
|
] }) : null
|
|
3393
3350
|
] });
|
|
3394
3351
|
}
|
|
3395
|
-
function
|
|
3352
|
+
function Gi({ className: e, label: t, description: n, ...r }) {
|
|
3396
3353
|
return /* @__PURE__ */ S("label", { className: T("vx-radio", r.disabled && "vx-radio--disabled"), children: [
|
|
3397
3354
|
/* @__PURE__ */ S("span", { className: "vx-radio__control-wrap", children: [
|
|
3398
3355
|
/* @__PURE__ */ a("input", { type: "radio", className: T("vx-radio__input", e), ...r }),
|
|
@@ -3404,13 +3361,13 @@ function Ki({ className: e, label: t, description: n, ...r }) {
|
|
|
3404
3361
|
] }) : null
|
|
3405
3362
|
] });
|
|
3406
3363
|
}
|
|
3407
|
-
function
|
|
3364
|
+
function ji({ label: e, children: t, className: n }) {
|
|
3408
3365
|
return /* @__PURE__ */ S("fieldset", { className: T("vx-radio-group", n), children: [
|
|
3409
3366
|
e ? /* @__PURE__ */ a("legend", { className: "vx-field-group__label", children: e }) : null,
|
|
3410
3367
|
/* @__PURE__ */ a("div", { className: "vx-radio-group__items", children: t })
|
|
3411
3368
|
] });
|
|
3412
3369
|
}
|
|
3413
|
-
function
|
|
3370
|
+
function Ki({ className: e, label: t, hint: n, resize: r = "vertical", style: s, ...o }) {
|
|
3414
3371
|
return /* @__PURE__ */ S("label", { className: "vx-field-group", children: [
|
|
3415
3372
|
t ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: t }) : null,
|
|
3416
3373
|
/* @__PURE__ */ a(
|
|
@@ -3424,7 +3381,7 @@ function Yi({ className: e, label: t, hint: n, resize: r = "vertical", style: s,
|
|
|
3424
3381
|
n ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: n }) : null
|
|
3425
3382
|
] });
|
|
3426
3383
|
}
|
|
3427
|
-
function
|
|
3384
|
+
function Vi({ className: e, label: t, showValue: n = !1, hint: r, value: s, defaultValue: o, ...l }) {
|
|
3428
3385
|
return /* @__PURE__ */ S("label", { className: "vx-field-group", children: [
|
|
3429
3386
|
t || n ? /* @__PURE__ */ S("span", { className: "vx-slider__header", children: [
|
|
3430
3387
|
t ? /* @__PURE__ */ a("span", { className: "vx-field-group__label vx-slider__label", children: t }) : null,
|
|
@@ -3443,9 +3400,9 @@ function qi({ className: e, label: t, showValue: n = !1, hint: r, value: s, defa
|
|
|
3443
3400
|
r ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: r }) : null
|
|
3444
3401
|
] });
|
|
3445
3402
|
}
|
|
3446
|
-
const
|
|
3447
|
-
function
|
|
3448
|
-
const s =
|
|
3403
|
+
const Vo = { sm: 16, md: 24, lg: 36 };
|
|
3404
|
+
function Yi({ className: e, size: t = "md", label: n = "Loading…", ...r }) {
|
|
3405
|
+
const s = Vo[t];
|
|
3449
3406
|
return /* @__PURE__ */ a(
|
|
3450
3407
|
"span",
|
|
3451
3408
|
{
|
|
@@ -3478,7 +3435,7 @@ function Xi({ className: e, size: t = "md", label: n = "Loading…", ...r }) {
|
|
|
3478
3435
|
}
|
|
3479
3436
|
);
|
|
3480
3437
|
}
|
|
3481
|
-
function
|
|
3438
|
+
function qi({
|
|
3482
3439
|
className: e,
|
|
3483
3440
|
value: t = 0,
|
|
3484
3441
|
max: n = 100,
|
|
@@ -3523,7 +3480,7 @@ function Zi({
|
|
|
3523
3480
|
)
|
|
3524
3481
|
] });
|
|
3525
3482
|
}
|
|
3526
|
-
const
|
|
3483
|
+
const Yo = {
|
|
3527
3484
|
info: /* @__PURE__ */ S("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: [
|
|
3528
3485
|
/* @__PURE__ */ a("circle", { cx: "8", cy: "8", r: "7", stroke: "currentColor", strokeWidth: "1.5" }),
|
|
3529
3486
|
/* @__PURE__ */ a("path", { d: "M8 7v4M8 5.5v.5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
|
|
@@ -3541,7 +3498,7 @@ const Xo = {
|
|
|
3541
3498
|
/* @__PURE__ */ a("path", { d: "M10 6L6 10M6 6l4 4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
|
|
3542
3499
|
] })
|
|
3543
3500
|
};
|
|
3544
|
-
function
|
|
3501
|
+
function Xi({
|
|
3545
3502
|
className: e,
|
|
3546
3503
|
variant: t = "info",
|
|
3547
3504
|
title: n,
|
|
@@ -3557,7 +3514,7 @@ function Qi({
|
|
|
3557
3514
|
className: T("vx-alert", `vx-alert--${t}`, e),
|
|
3558
3515
|
...l,
|
|
3559
3516
|
children: [
|
|
3560
|
-
/* @__PURE__ */ a("span", { className: "vx-alert__icon", children: r ??
|
|
3517
|
+
/* @__PURE__ */ a("span", { className: "vx-alert__icon", children: r ?? Yo[t] }),
|
|
3561
3518
|
/* @__PURE__ */ S("div", { className: "vx-alert__body", children: [
|
|
3562
3519
|
n ? /* @__PURE__ */ a("p", { className: "vx-alert__title", children: n }) : null,
|
|
3563
3520
|
o ? /* @__PURE__ */ a("div", { className: "vx-alert__content", children: o }) : null
|
|
@@ -3567,7 +3524,7 @@ function Qi({
|
|
|
3567
3524
|
}
|
|
3568
3525
|
);
|
|
3569
3526
|
}
|
|
3570
|
-
function
|
|
3527
|
+
function Zi({
|
|
3571
3528
|
className: e,
|
|
3572
3529
|
width: t,
|
|
3573
3530
|
height: n,
|
|
@@ -3600,8 +3557,8 @@ function Ji({
|
|
|
3600
3557
|
}
|
|
3601
3558
|
);
|
|
3602
3559
|
}
|
|
3603
|
-
function
|
|
3604
|
-
const [o, l] =
|
|
3560
|
+
function Qi({ content: e, placement: t = "top", delay: n = 600, children: r, className: s }) {
|
|
3561
|
+
const [o, l] = D(!1), i = L(null), u = U(() => {
|
|
3605
3562
|
i.current = setTimeout(() => l(!0), n);
|
|
3606
3563
|
}, [n]), c = U(() => {
|
|
3607
3564
|
i.current && clearTimeout(i.current), l(!1);
|
|
@@ -3613,7 +3570,7 @@ function el({ content: e, placement: t = "top", delay: n = 600, children: r, cla
|
|
|
3613
3570
|
o ? /* @__PURE__ */ a("span", { role: "tooltip", className: T("vx-tooltip", `vx-tooltip--${t}`), children: e }) : null
|
|
3614
3571
|
] });
|
|
3615
3572
|
}
|
|
3616
|
-
function
|
|
3573
|
+
function Ji({
|
|
3617
3574
|
content: e,
|
|
3618
3575
|
placement: t = "bottom",
|
|
3619
3576
|
trigger: n = "click",
|
|
@@ -3622,7 +3579,7 @@ function tl({
|
|
|
3622
3579
|
open: o,
|
|
3623
3580
|
onOpenChange: l
|
|
3624
3581
|
}) {
|
|
3625
|
-
const [i, u] =
|
|
3582
|
+
const [i, u] = D(!1), c = o !== void 0, d = c ? o : i, p = L(null), x = U((g) => {
|
|
3626
3583
|
c || u(g), l == null || l(g);
|
|
3627
3584
|
}, [c, l]), k = U(() => x(!d), [d, x]);
|
|
3628
3585
|
O(() => {
|
|
@@ -3642,7 +3599,7 @@ function tl({
|
|
|
3642
3599
|
d ? /* @__PURE__ */ a("div", { className: T("vx-popover", `vx-popover--${t}`), role: "dialog", children: e }) : null
|
|
3643
3600
|
] });
|
|
3644
3601
|
}
|
|
3645
|
-
function
|
|
3602
|
+
function el({
|
|
3646
3603
|
trigger: e,
|
|
3647
3604
|
groups: t,
|
|
3648
3605
|
items: n,
|
|
@@ -3651,7 +3608,7 @@ function nl({
|
|
|
3651
3608
|
open: o,
|
|
3652
3609
|
onOpenChange: l
|
|
3653
3610
|
}) {
|
|
3654
|
-
const [i, u] =
|
|
3611
|
+
const [i, u] = D(!1), c = o !== void 0, d = c ? o : i, p = L(null), x = U((g) => {
|
|
3655
3612
|
c || u(g), l == null || l(g);
|
|
3656
3613
|
}, [c, l]), k = U(() => x(!d), [d, x]);
|
|
3657
3614
|
O(() => {
|
|
@@ -3708,20 +3665,20 @@ function nl({
|
|
|
3708
3665
|
] }, m)) }) : null
|
|
3709
3666
|
] });
|
|
3710
3667
|
}
|
|
3711
|
-
const
|
|
3712
|
-
function
|
|
3668
|
+
const qo = () => /* @__PURE__ */ a("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ a("path", { d: "M4.5 2.5L7.5 6l-3 3.5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
|
|
3669
|
+
function tl({ items: e, separator: t, className: n }) {
|
|
3713
3670
|
return /* @__PURE__ */ a("nav", { "aria-label": "Breadcrumb", className: T("vx-breadcrumb", n), children: /* @__PURE__ */ a("ol", { className: "vx-breadcrumb__list", children: e.map((r, s) => {
|
|
3714
3671
|
const o = s === e.length - 1;
|
|
3715
3672
|
return /* @__PURE__ */ S("li", { className: "vx-breadcrumb__item", children: [
|
|
3716
3673
|
o ? /* @__PURE__ */ a("span", { className: "vx-breadcrumb__current", "aria-current": "page", children: r.label }) : r.href ? /* @__PURE__ */ a("a", { href: r.href, className: "vx-breadcrumb__link", children: r.label }) : /* @__PURE__ */ a("button", { type: "button", className: "vx-breadcrumb__link", onClick: r.onClick, children: r.label }),
|
|
3717
|
-
o ? null : /* @__PURE__ */ a("span", { className: "vx-breadcrumb__sep", "aria-hidden": "true", children: t ?? /* @__PURE__ */ a(
|
|
3674
|
+
o ? null : /* @__PURE__ */ a("span", { className: "vx-breadcrumb__sep", "aria-hidden": "true", children: t ?? /* @__PURE__ */ a(qo, {}) })
|
|
3718
3675
|
] }, s);
|
|
3719
3676
|
}) }) });
|
|
3720
3677
|
}
|
|
3721
3678
|
function Ie(e, t) {
|
|
3722
3679
|
return Array.from({ length: t - e + 1 }, (n, r) => e + r);
|
|
3723
3680
|
}
|
|
3724
|
-
function
|
|
3681
|
+
function nl({ page: e, total: t, pageSize: n = 10, siblingCount: r = 1, onChange: s, className: o }) {
|
|
3725
3682
|
const l = Math.max(1, Math.ceil(t / n)), i = (() => {
|
|
3726
3683
|
const u = r * 2 + 5;
|
|
3727
3684
|
if (l <= u) return Ie(1, l);
|
|
@@ -3766,8 +3723,8 @@ function al({ page: e, total: t, pageSize: n = 10, siblingCount: r = 1, onChange
|
|
|
3766
3723
|
)
|
|
3767
3724
|
] });
|
|
3768
3725
|
}
|
|
3769
|
-
function
|
|
3770
|
-
const [s, o] =
|
|
3726
|
+
function rl({ items: e, multiple: t = !1, defaultOpen: n = [], className: r }) {
|
|
3727
|
+
const [s, o] = D(new Set(n));
|
|
3771
3728
|
function l(i) {
|
|
3772
3729
|
o((u) => {
|
|
3773
3730
|
const c = new Set(t ? u : []);
|
|
@@ -3795,7 +3752,7 @@ function sl({ items: e, multiple: t = !1, defaultOpen: n = [], className: r }) {
|
|
|
3795
3752
|
] }, i.key);
|
|
3796
3753
|
}) });
|
|
3797
3754
|
}
|
|
3798
|
-
function
|
|
3755
|
+
function al({ className: e, orientation: t = "horizontal", decorative: n = !0, ...r }) {
|
|
3799
3756
|
return /* @__PURE__ */ a(
|
|
3800
3757
|
"hr",
|
|
3801
3758
|
{
|
|
@@ -3806,18 +3763,18 @@ function ol({ className: e, orientation: t = "horizontal", decorative: n = !0, .
|
|
|
3806
3763
|
}
|
|
3807
3764
|
);
|
|
3808
3765
|
}
|
|
3809
|
-
function
|
|
3766
|
+
function Xo(e) {
|
|
3810
3767
|
const t = e.trim().split(/\s+/);
|
|
3811
3768
|
return t.length === 1 ? t[0].slice(0, 2).toUpperCase() : (t[0][0] + t[t.length - 1][0]).toUpperCase();
|
|
3812
3769
|
}
|
|
3813
|
-
const
|
|
3814
|
-
function
|
|
3770
|
+
const Xt = [0, 30, 60, 120, 160, 200, 240, 270, 300, 340];
|
|
3771
|
+
function Zo(e) {
|
|
3815
3772
|
let t = 0;
|
|
3816
3773
|
for (let n = 0; n < e.length; n++) t += e.charCodeAt(n);
|
|
3817
|
-
return
|
|
3774
|
+
return Xt[t % Xt.length];
|
|
3818
3775
|
}
|
|
3819
|
-
function
|
|
3820
|
-
const [u, c] =
|
|
3776
|
+
function sl({ src: e, name: t, size: n = "md", shape: r = "circle", fallback: s, className: o, alt: l, ...i }) {
|
|
3777
|
+
const [u, c] = D(!1), d = e && !u, p = t ?? l ?? "", x = p ? Zo(p) : 200;
|
|
3821
3778
|
return /* @__PURE__ */ a(
|
|
3822
3779
|
"span",
|
|
3823
3780
|
{
|
|
@@ -3833,14 +3790,14 @@ function il({ src: e, name: t, size: n = "md", shape: r = "circle", fallback: s,
|
|
|
3833
3790
|
onError: () => c(!0),
|
|
3834
3791
|
...i
|
|
3835
3792
|
}
|
|
3836
|
-
) : s ? /* @__PURE__ */ a("span", { className: "vx-avatar__fallback", children: s }) : p ? /* @__PURE__ */ a("span", { className: "vx-avatar__initials", children:
|
|
3793
|
+
) : s ? /* @__PURE__ */ a("span", { className: "vx-avatar__fallback", children: s }) : p ? /* @__PURE__ */ a("span", { className: "vx-avatar__initials", children: Xo(p) }) : /* @__PURE__ */ S("svg", { className: "vx-avatar__placeholder", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: [
|
|
3837
3794
|
/* @__PURE__ */ a("circle", { cx: "12", cy: "8", r: "4", stroke: "currentColor", strokeWidth: "1.5" }),
|
|
3838
3795
|
/* @__PURE__ */ a("path", { d: "M4 20c0-4 3.58-7 8-7s8 3 8 7", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
|
|
3839
3796
|
] })
|
|
3840
3797
|
}
|
|
3841
3798
|
);
|
|
3842
3799
|
}
|
|
3843
|
-
function
|
|
3800
|
+
function ol({
|
|
3844
3801
|
columns: e,
|
|
3845
3802
|
data: t,
|
|
3846
3803
|
striped: n = !1,
|
|
@@ -3856,7 +3813,7 @@ function ll({
|
|
|
3856
3813
|
className: x,
|
|
3857
3814
|
...k
|
|
3858
3815
|
}) {
|
|
3859
|
-
const [E, g] =
|
|
3816
|
+
const [E, g] = D(null), [m, w] = D(null), h = c !== void 0, v = h ? c : E, f = h ? d ?? null : m, y = U((_) => {
|
|
3860
3817
|
let N;
|
|
3861
3818
|
v !== _ ? N = "asc" : f === "asc" ? N = "desc" : f === "desc" ? N = null : N = "asc", h || (g(N === null ? null : _), w(N)), p == null || p(_, N);
|
|
3862
3819
|
}, [v, f, h, p]);
|
|
@@ -3904,24 +3861,24 @@ function ll({
|
|
|
3904
3861
|
}
|
|
3905
3862
|
) });
|
|
3906
3863
|
}
|
|
3907
|
-
function
|
|
3864
|
+
function il({ topBar: e, bottomNav: t, children: n, className: r }) {
|
|
3908
3865
|
return /* @__PURE__ */ S("div", { className: T("vxm-shell", r), children: [
|
|
3909
3866
|
e && /* @__PURE__ */ a("div", { className: "vxm-shell__topbar", children: e }),
|
|
3910
3867
|
/* @__PURE__ */ a("main", { className: "vxm-shell__main", children: n }),
|
|
3911
3868
|
t && /* @__PURE__ */ a("div", { className: "vxm-shell__bottomnav", children: t })
|
|
3912
3869
|
] });
|
|
3913
3870
|
}
|
|
3914
|
-
function
|
|
3871
|
+
function ll({ title: e, leading: t, trailing: n, className: r }) {
|
|
3915
3872
|
return /* @__PURE__ */ S("div", { className: T("vxm-topbar", r), children: [
|
|
3916
3873
|
/* @__PURE__ */ a("div", { className: "vxm-topbar__leading", children: t }),
|
|
3917
3874
|
/* @__PURE__ */ a("div", { className: "vxm-topbar__title", children: e }),
|
|
3918
3875
|
/* @__PURE__ */ a("div", { className: "vxm-topbar__trailing", children: n })
|
|
3919
3876
|
] });
|
|
3920
3877
|
}
|
|
3921
|
-
function
|
|
3878
|
+
function cl({ label: e, className: t, children: n, ...r }) {
|
|
3922
3879
|
return /* @__PURE__ */ a("button", { type: "button", className: T("vxm-icon-btn", t), "aria-label": e, ...r, children: n });
|
|
3923
3880
|
}
|
|
3924
|
-
function
|
|
3881
|
+
function ul({ items: e, className: t }) {
|
|
3925
3882
|
return /* @__PURE__ */ a("nav", { className: T("vxm-bottomnav", t), "aria-label": "底部导航", children: e.map((n) => /* @__PURE__ */ S(
|
|
3926
3883
|
"button",
|
|
3927
3884
|
{
|
|
@@ -3940,7 +3897,7 @@ function pl({ items: e, className: t }) {
|
|
|
3940
3897
|
n.key
|
|
3941
3898
|
)) });
|
|
3942
3899
|
}
|
|
3943
|
-
function
|
|
3900
|
+
function dl({
|
|
3944
3901
|
open: e,
|
|
3945
3902
|
onClose: t,
|
|
3946
3903
|
title: n,
|
|
@@ -3948,7 +3905,7 @@ function fl({
|
|
|
3948
3905
|
children: s,
|
|
3949
3906
|
className: o
|
|
3950
3907
|
}) {
|
|
3951
|
-
const l = L(null), i = L(0), [u, c] =
|
|
3908
|
+
const l = L(null), i = L(0), [u, c] = D(!1), [d, p] = D(0), x = L(0);
|
|
3952
3909
|
O(() => {
|
|
3953
3910
|
e || (p(0), x.current = 0);
|
|
3954
3911
|
}, [e]), O(() => {
|
|
@@ -4008,7 +3965,7 @@ function fl({
|
|
|
4008
3965
|
}
|
|
4009
3966
|
) : null;
|
|
4010
3967
|
}
|
|
4011
|
-
function
|
|
3968
|
+
function pl({ icon: e, destructive: t, className: n, children: r, ...s }) {
|
|
4012
3969
|
return /* @__PURE__ */ S(
|
|
4013
3970
|
"button",
|
|
4014
3971
|
{
|
|
@@ -4022,16 +3979,16 @@ function vl({ icon: e, destructive: t, className: n, children: r, ...s }) {
|
|
|
4022
3979
|
}
|
|
4023
3980
|
);
|
|
4024
3981
|
}
|
|
4025
|
-
function
|
|
3982
|
+
function fl({ className: e, ...t }) {
|
|
4026
3983
|
return /* @__PURE__ */ a("ul", { className: T("vxm-list", e), role: "list", ...t });
|
|
4027
3984
|
}
|
|
4028
|
-
function
|
|
3985
|
+
function vl({ title: e, className: t, children: n, ...r }) {
|
|
4029
3986
|
return /* @__PURE__ */ S("div", { className: T("vxm-list-section", t), ...r, children: [
|
|
4030
3987
|
e && /* @__PURE__ */ a("div", { className: "vxm-list-section__title", children: e }),
|
|
4031
3988
|
n
|
|
4032
3989
|
] });
|
|
4033
3990
|
}
|
|
4034
|
-
function
|
|
3991
|
+
function hl({
|
|
4035
3992
|
leading: e,
|
|
4036
3993
|
trailing: t,
|
|
4037
3994
|
label: n,
|
|
@@ -4075,7 +4032,7 @@ function gl({
|
|
|
4075
4032
|
}
|
|
4076
4033
|
);
|
|
4077
4034
|
}
|
|
4078
|
-
function
|
|
4035
|
+
function ml({
|
|
4079
4036
|
open: e,
|
|
4080
4037
|
onClose: t,
|
|
4081
4038
|
width: n = 280,
|
|
@@ -4084,7 +4041,7 @@ function bl({
|
|
|
4084
4041
|
children: o,
|
|
4085
4042
|
className: l
|
|
4086
4043
|
}) {
|
|
4087
|
-
const i = L(null), u = L(0), c = L(0), [d, p] =
|
|
4044
|
+
const i = L(null), u = L(0), c = L(0), [d, p] = D(!1), [x, k] = D(0);
|
|
4088
4045
|
O(() => {
|
|
4089
4046
|
e || (k(0), c.current = 0);
|
|
4090
4047
|
}, [e]), O(() => {
|
|
@@ -4140,7 +4097,7 @@ function bl({
|
|
|
4140
4097
|
)
|
|
4141
4098
|
] });
|
|
4142
4099
|
}
|
|
4143
|
-
function
|
|
4100
|
+
function gl({ icon: e, label: t, badge: n, active: r, onClick: s }) {
|
|
4144
4101
|
return /* @__PURE__ */ S(
|
|
4145
4102
|
"button",
|
|
4146
4103
|
{
|
|
@@ -4156,41 +4113,41 @@ function xl({ icon: e, label: t, badge: n, active: r, onClick: s }) {
|
|
|
4156
4113
|
}
|
|
4157
4114
|
);
|
|
4158
4115
|
}
|
|
4159
|
-
function
|
|
4116
|
+
function bl({ title: e, children: t }) {
|
|
4160
4117
|
return /* @__PURE__ */ S("div", { className: "vxm-drawer-section", children: [
|
|
4161
4118
|
e && /* @__PURE__ */ a("div", { className: "vxm-drawer-section__title", children: e }),
|
|
4162
4119
|
/* @__PURE__ */ a("div", { className: "vxm-drawer-section__items", children: t })
|
|
4163
4120
|
] });
|
|
4164
4121
|
}
|
|
4165
|
-
const
|
|
4122
|
+
const xl = re(function({ className: t, required: n, children: r, ...s }, o) {
|
|
4166
4123
|
return /* @__PURE__ */ S("label", { ref: o, className: T("vx-label", t), ...s, children: [
|
|
4167
4124
|
r,
|
|
4168
4125
|
n ? /* @__PURE__ */ a("span", { className: "vx-label__required", "aria-hidden": "true", children: " *" }) : null
|
|
4169
4126
|
] });
|
|
4170
|
-
}),
|
|
4171
|
-
function
|
|
4172
|
-
return ye(
|
|
4127
|
+
}), Pr = _e({});
|
|
4128
|
+
function Qo() {
|
|
4129
|
+
return ye(Pr);
|
|
4173
4130
|
}
|
|
4174
|
-
function
|
|
4131
|
+
function yl({ className: e, ...t }) {
|
|
4175
4132
|
return /* @__PURE__ */ a("form", { noValidate: !0, className: T("vx-form", e), ...t });
|
|
4176
4133
|
}
|
|
4177
|
-
function
|
|
4178
|
-
return /* @__PURE__ */ a(
|
|
4134
|
+
function _l({ error: e, children: t, className: n }) {
|
|
4135
|
+
return /* @__PURE__ */ a(Pr.Provider, { value: { error: e }, children: /* @__PURE__ */ a("div", { className: T("vx-form-field", e && "vx-form-field--invalid", n), children: t }) });
|
|
4179
4136
|
}
|
|
4180
|
-
function
|
|
4137
|
+
function wl({ className: e, required: t, children: n, ...r }) {
|
|
4181
4138
|
return /* @__PURE__ */ S("label", { className: T("vx-form-label", e), ...r, children: [
|
|
4182
4139
|
n,
|
|
4183
4140
|
t ? /* @__PURE__ */ a("span", { className: "vx-form-label__required", "aria-hidden": "true", children: " *" }) : null
|
|
4184
4141
|
] });
|
|
4185
4142
|
}
|
|
4186
|
-
function
|
|
4143
|
+
function kl({ className: e, children: t, ...n }) {
|
|
4187
4144
|
return /* @__PURE__ */ a("p", { className: T("vx-form-description", e), ...n, children: t });
|
|
4188
4145
|
}
|
|
4189
|
-
function
|
|
4190
|
-
const { error: r } =
|
|
4146
|
+
function Nl({ className: e, children: t, ...n }) {
|
|
4147
|
+
const { error: r } = Qo(), s = r ?? t;
|
|
4191
4148
|
return s ? /* @__PURE__ */ a("p", { className: T("vx-form-message", r && "vx-form-message--error", e), ...n, children: s }) : null;
|
|
4192
4149
|
}
|
|
4193
|
-
function
|
|
4150
|
+
function Sl({
|
|
4194
4151
|
trigger: e,
|
|
4195
4152
|
title: t,
|
|
4196
4153
|
description: n,
|
|
@@ -4202,43 +4159,30 @@ function Tl({
|
|
|
4202
4159
|
className: u,
|
|
4203
4160
|
...c
|
|
4204
4161
|
}) {
|
|
4205
|
-
|
|
4206
|
-
/* @__PURE__ */ a(
|
|
4207
|
-
/* @__PURE__ */
|
|
4208
|
-
|
|
4209
|
-
return d ? /* @__PURE__ */ a(
|
|
4210
|
-
Vn,
|
|
4211
|
-
{
|
|
4212
|
-
trigger: e,
|
|
4213
|
-
title: t,
|
|
4214
|
-
description: n,
|
|
4215
|
-
side: "bottom",
|
|
4216
|
-
footer: p,
|
|
4217
|
-
className: T("vx-dialog--mobile-sheet", u),
|
|
4218
|
-
...c,
|
|
4219
|
-
children: null
|
|
4220
|
-
}
|
|
4221
|
-
) : /* @__PURE__ */ S(wt, { ...c, children: [
|
|
4222
|
-
/* @__PURE__ */ a(kt, { asChild: !0, children: e }),
|
|
4223
|
-
/* @__PURE__ */ S(Nt, { children: [
|
|
4224
|
-
/* @__PURE__ */ a(St, { className: "vx-dialog__overlay" }),
|
|
4162
|
+
return /* @__PURE__ */ S(_t, { ...c, children: [
|
|
4163
|
+
/* @__PURE__ */ a(wt, { asChild: !0, children: e }),
|
|
4164
|
+
/* @__PURE__ */ S(kt, { children: [
|
|
4165
|
+
/* @__PURE__ */ a(Nt, { className: "vx-dialog__overlay" }),
|
|
4225
4166
|
/* @__PURE__ */ S(
|
|
4226
|
-
|
|
4167
|
+
St,
|
|
4227
4168
|
{
|
|
4228
4169
|
className: T("vx-alert-dialog__content", u),
|
|
4229
4170
|
role: "alertdialog",
|
|
4230
4171
|
"aria-modal": "true",
|
|
4231
4172
|
children: [
|
|
4232
|
-
/* @__PURE__ */ a(
|
|
4233
|
-
n ? /* @__PURE__ */ a(
|
|
4234
|
-
|
|
4173
|
+
/* @__PURE__ */ a(Et, { className: "vx-alert-dialog__title", children: t }),
|
|
4174
|
+
n ? /* @__PURE__ */ a(Tt, { className: "vx-alert-dialog__description", children: n }) : null,
|
|
4175
|
+
/* @__PURE__ */ S("div", { className: "vx-alert-dialog__footer", children: [
|
|
4176
|
+
/* @__PURE__ */ a(ze, { asChild: !0, children: /* @__PURE__ */ a(fe, { variant: "secondary", onClick: l, children: s }) }),
|
|
4177
|
+
/* @__PURE__ */ a(ze, { asChild: !0, children: /* @__PURE__ */ a(fe, { variant: i === "danger" ? "danger" : "solid", onClick: o, children: r }) })
|
|
4178
|
+
] })
|
|
4235
4179
|
]
|
|
4236
4180
|
}
|
|
4237
4181
|
)
|
|
4238
4182
|
] })
|
|
4239
4183
|
] });
|
|
4240
4184
|
}
|
|
4241
|
-
function
|
|
4185
|
+
function El({
|
|
4242
4186
|
className: e,
|
|
4243
4187
|
label: t,
|
|
4244
4188
|
hint: n,
|
|
@@ -4331,16 +4275,16 @@ function Cl({
|
|
|
4331
4275
|
!r && n ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: n }) : null
|
|
4332
4276
|
] });
|
|
4333
4277
|
}
|
|
4334
|
-
function
|
|
4278
|
+
function Jo(e, t) {
|
|
4335
4279
|
return new Date(e, t + 1, 0).getDate();
|
|
4336
4280
|
}
|
|
4337
|
-
function
|
|
4281
|
+
function ei(e, t) {
|
|
4338
4282
|
return new Date(e, t, 1).getDay();
|
|
4339
4283
|
}
|
|
4340
|
-
function
|
|
4284
|
+
function Zt(e, t) {
|
|
4341
4285
|
return e.getFullYear() === t.getFullYear() && e.getMonth() === t.getMonth() && e.getDate() === t.getDate();
|
|
4342
4286
|
}
|
|
4343
|
-
function
|
|
4287
|
+
function ti({
|
|
4344
4288
|
value: e,
|
|
4345
4289
|
defaultValue: t,
|
|
4346
4290
|
onChange: n,
|
|
@@ -4349,31 +4293,31 @@ function ri({
|
|
|
4349
4293
|
className: o,
|
|
4350
4294
|
weekStartsOnMonday: l = !1
|
|
4351
4295
|
}) {
|
|
4352
|
-
const i = /* @__PURE__ */ new Date(), u = e !== void 0, [c, d] =
|
|
4296
|
+
const i = /* @__PURE__ */ new Date(), u = e !== void 0, [c, d] = D(t), p = u ? e : c, [x, k] = D((p ?? i).getFullYear()), [E, g] = D((p ?? i).getMonth()), m = Jo(x, E), w = ei(x, E), h = l ? w === 0 ? 6 : w - 1 : w, v = l ? ["Mo", "Tu", "We", "Th", "Fr", "Sa", "Su"] : ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], f = () => {
|
|
4353
4297
|
E === 0 ? (k((P) => P - 1), g(11)) : g((P) => P - 1);
|
|
4354
4298
|
}, y = () => {
|
|
4355
4299
|
E === 11 ? (k((P) => P + 1), g(0)) : g((P) => P + 1);
|
|
4356
4300
|
}, _ = U(
|
|
4357
4301
|
(P) => {
|
|
4358
|
-
const
|
|
4302
|
+
const F = new Date(x, E, P);
|
|
4359
4303
|
if (r) {
|
|
4360
|
-
const
|
|
4361
|
-
if (
|
|
4304
|
+
const R = new Date(r.getFullYear(), r.getMonth(), r.getDate());
|
|
4305
|
+
if (F < R) return !0;
|
|
4362
4306
|
}
|
|
4363
4307
|
if (s) {
|
|
4364
|
-
const
|
|
4365
|
-
if (
|
|
4308
|
+
const R = new Date(s.getFullYear(), s.getMonth(), s.getDate());
|
|
4309
|
+
if (F > R) return !0;
|
|
4366
4310
|
}
|
|
4367
4311
|
return !1;
|
|
4368
4312
|
},
|
|
4369
4313
|
[x, E, r, s]
|
|
4370
4314
|
), N = (P) => {
|
|
4371
4315
|
if (_(P)) return;
|
|
4372
|
-
const
|
|
4373
|
-
u || d(
|
|
4316
|
+
const F = new Date(x, E, P);
|
|
4317
|
+
u || d(F), n == null || n(F);
|
|
4374
4318
|
}, C = new Date(x, E).toLocaleString("default", { month: "long" }), A = [
|
|
4375
4319
|
...Array(h).fill(null),
|
|
4376
|
-
...Array.from({ length: m }, (P,
|
|
4320
|
+
...Array.from({ length: m }, (P, F) => F + 1)
|
|
4377
4321
|
];
|
|
4378
4322
|
for (; A.length % 7 !== 0; ) A.push(null);
|
|
4379
4323
|
return /* @__PURE__ */ S("div", { className: T("vx-calendar", o), children: [
|
|
@@ -4406,10 +4350,10 @@ function ri({
|
|
|
4406
4350
|
] }),
|
|
4407
4351
|
/* @__PURE__ */ S("div", { className: "vx-calendar__grid", role: "grid", "aria-label": `${C} ${x}`, children: [
|
|
4408
4352
|
v.map((P) => /* @__PURE__ */ a("div", { className: "vx-calendar__weekday", role: "columnheader", children: P }, P)),
|
|
4409
|
-
A.map((P,
|
|
4353
|
+
A.map((P, F) => {
|
|
4410
4354
|
if (P === null)
|
|
4411
|
-
return /* @__PURE__ */ a("div", { className: "vx-calendar__cell vx-calendar__cell--empty" }, `e-${
|
|
4412
|
-
const
|
|
4355
|
+
return /* @__PURE__ */ a("div", { className: "vx-calendar__cell vx-calendar__cell--empty" }, `e-${F}`);
|
|
4356
|
+
const R = new Date(x, E, P), $ = Zt(R, i), I = p ? Zt(R, p) : !1, W = _(P);
|
|
4413
4357
|
return /* @__PURE__ */ a(
|
|
4414
4358
|
"button",
|
|
4415
4359
|
{
|
|
@@ -4423,7 +4367,7 @@ function ri({
|
|
|
4423
4367
|
),
|
|
4424
4368
|
onClick: () => N(P),
|
|
4425
4369
|
disabled: W,
|
|
4426
|
-
"aria-label":
|
|
4370
|
+
"aria-label": R.toLocaleDateString(),
|
|
4427
4371
|
"aria-selected": I,
|
|
4428
4372
|
children: P
|
|
4429
4373
|
},
|
|
@@ -4433,17 +4377,17 @@ function ri({
|
|
|
4433
4377
|
] })
|
|
4434
4378
|
] });
|
|
4435
4379
|
}
|
|
4436
|
-
function
|
|
4380
|
+
function ni(e) {
|
|
4437
4381
|
return e.toLocaleDateString();
|
|
4438
4382
|
}
|
|
4439
|
-
function
|
|
4383
|
+
function ri() {
|
|
4440
4384
|
return /* @__PURE__ */ S("svg", { width: "15", height: "15", viewBox: "0 0 15 15", fill: "none", "aria-hidden": "true", children: [
|
|
4441
4385
|
/* @__PURE__ */ a("rect", { x: "1", y: "3", width: "13", height: "11", rx: "2", stroke: "currentColor", strokeWidth: "1.2" }),
|
|
4442
4386
|
/* @__PURE__ */ a("path", { d: "M1 6.5h13", stroke: "currentColor", strokeWidth: "1.2" }),
|
|
4443
4387
|
/* @__PURE__ */ a("path", { d: "M5 1v3M10 1v3", stroke: "currentColor", strokeWidth: "1.4", strokeLinecap: "round" })
|
|
4444
4388
|
] });
|
|
4445
4389
|
}
|
|
4446
|
-
function
|
|
4390
|
+
function Tl({
|
|
4447
4391
|
value: e,
|
|
4448
4392
|
defaultValue: t,
|
|
4449
4393
|
onChange: n,
|
|
@@ -4457,7 +4401,7 @@ function Al({
|
|
|
4457
4401
|
weekStartsOnMonday: d,
|
|
4458
4402
|
className: p
|
|
4459
4403
|
}) {
|
|
4460
|
-
const x = e !== void 0, [k, E] =
|
|
4404
|
+
const x = e !== void 0, [k, E] = D(t), g = x ? e : k, [m, w] = D(!1), h = L(null);
|
|
4461
4405
|
O(() => {
|
|
4462
4406
|
if (!m) return;
|
|
4463
4407
|
const f = (_) => {
|
|
@@ -4488,15 +4432,15 @@ function Al({
|
|
|
4488
4432
|
"aria-haspopup": "dialog",
|
|
4489
4433
|
"aria-expanded": m,
|
|
4490
4434
|
children: [
|
|
4491
|
-
/* @__PURE__ */ a(
|
|
4492
|
-
/* @__PURE__ */ a("span", { className: T("vx-datepicker__value", !g && "vx-datepicker__value--placeholder"), children: g ?
|
|
4435
|
+
/* @__PURE__ */ a(ri, {}),
|
|
4436
|
+
/* @__PURE__ */ a("span", { className: T("vx-datepicker__value", !g && "vx-datepicker__value--placeholder"), children: g ? ni(g) : r })
|
|
4493
4437
|
]
|
|
4494
4438
|
}
|
|
4495
4439
|
),
|
|
4496
4440
|
l ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: l }) : null,
|
|
4497
4441
|
!l && o ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: o }) : null,
|
|
4498
4442
|
m ? /* @__PURE__ */ a("div", { className: "vx-datepicker__popover", role: "dialog", "aria-label": "Date picker", children: /* @__PURE__ */ a(
|
|
4499
|
-
|
|
4443
|
+
ti,
|
|
4500
4444
|
{
|
|
4501
4445
|
value: g,
|
|
4502
4446
|
onChange: v,
|
|
@@ -4507,7 +4451,7 @@ function Al({
|
|
|
4507
4451
|
) }) : null
|
|
4508
4452
|
] });
|
|
4509
4453
|
}
|
|
4510
|
-
function
|
|
4454
|
+
function Cl({
|
|
4511
4455
|
options: e,
|
|
4512
4456
|
value: t,
|
|
4513
4457
|
defaultValue: n,
|
|
@@ -4522,34 +4466,34 @@ function Pl({
|
|
|
4522
4466
|
emptyText: p = "No results",
|
|
4523
4467
|
className: x
|
|
4524
4468
|
}) {
|
|
4525
|
-
const k = t !== void 0, [E, g] =
|
|
4526
|
-
(
|
|
4469
|
+
const k = t !== void 0, [E, g] = D(n), m = k ? t : E, [w, h] = D(!1), [v, f] = D(""), y = L(null), _ = L(null), N = Ir(), C = e.find((R) => R.value === m), A = e.filter(
|
|
4470
|
+
(R) => R.label.toLowerCase().includes(v.toLowerCase())
|
|
4527
4471
|
);
|
|
4528
4472
|
O(() => {
|
|
4529
4473
|
if (!w) {
|
|
4530
4474
|
f("");
|
|
4531
4475
|
return;
|
|
4532
4476
|
}
|
|
4533
|
-
const
|
|
4477
|
+
const R = setTimeout(() => {
|
|
4534
4478
|
var $;
|
|
4535
4479
|
return ($ = _.current) == null ? void 0 : $.focus();
|
|
4536
4480
|
}, 0);
|
|
4537
|
-
return () => clearTimeout(
|
|
4481
|
+
return () => clearTimeout(R);
|
|
4538
4482
|
}, [w]), O(() => {
|
|
4539
4483
|
if (!w) return;
|
|
4540
|
-
const
|
|
4484
|
+
const R = (I) => {
|
|
4541
4485
|
y.current && !y.current.contains(I.target) && h(!1);
|
|
4542
4486
|
}, $ = (I) => {
|
|
4543
4487
|
I.key === "Escape" && h(!1);
|
|
4544
4488
|
};
|
|
4545
|
-
return document.addEventListener("mousedown",
|
|
4546
|
-
document.removeEventListener("mousedown",
|
|
4489
|
+
return document.addEventListener("mousedown", R), document.addEventListener("keydown", $), () => {
|
|
4490
|
+
document.removeEventListener("mousedown", R), document.removeEventListener("keydown", $);
|
|
4547
4491
|
};
|
|
4548
4492
|
}, [w]);
|
|
4549
|
-
const P = (
|
|
4550
|
-
|
|
4551
|
-
},
|
|
4552
|
-
|
|
4493
|
+
const P = (R) => {
|
|
4494
|
+
R.disabled || (k || g(R.value), r == null || r(R.value), h(!1));
|
|
4495
|
+
}, F = (R) => {
|
|
4496
|
+
R.stopPropagation(), k || g(void 0), r == null || r(void 0);
|
|
4553
4497
|
};
|
|
4554
4498
|
return /* @__PURE__ */ S("div", { ref: y, className: T("vx-combobox", x), children: [
|
|
4555
4499
|
l ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: l }) : null,
|
|
@@ -4562,7 +4506,7 @@ function Pl({
|
|
|
4562
4506
|
u && "vx-combobox__trigger--invalid",
|
|
4563
4507
|
c && "vx-combobox__trigger--disabled"
|
|
4564
4508
|
),
|
|
4565
|
-
onClick: () => !c && h((
|
|
4509
|
+
onClick: () => !c && h((R) => !R),
|
|
4566
4510
|
disabled: c,
|
|
4567
4511
|
"aria-haspopup": "listbox",
|
|
4568
4512
|
"aria-expanded": w,
|
|
@@ -4574,14 +4518,14 @@ function Pl({
|
|
|
4574
4518
|
"span",
|
|
4575
4519
|
{
|
|
4576
4520
|
className: "vx-combobox__clear",
|
|
4577
|
-
onClick:
|
|
4521
|
+
onClick: F,
|
|
4578
4522
|
role: "button",
|
|
4579
4523
|
"aria-label": "Clear selection",
|
|
4580
4524
|
children: /* @__PURE__ */ a(ve, { size: 14 })
|
|
4581
4525
|
}
|
|
4582
4526
|
),
|
|
4583
4527
|
/* @__PURE__ */ a(
|
|
4584
|
-
|
|
4528
|
+
ht,
|
|
4585
4529
|
{
|
|
4586
4530
|
size: 14,
|
|
4587
4531
|
className: T("vx-combobox__chevron", w && "vx-combobox__chevron--open")
|
|
@@ -4602,33 +4546,33 @@ function Pl({
|
|
|
4602
4546
|
className: "vx-combobox__search",
|
|
4603
4547
|
placeholder: o,
|
|
4604
4548
|
value: v,
|
|
4605
|
-
onChange: (
|
|
4549
|
+
onChange: (R) => f(R.target.value),
|
|
4606
4550
|
"aria-label": o
|
|
4607
4551
|
}
|
|
4608
4552
|
) }),
|
|
4609
|
-
/* @__PURE__ */ a("ul", { id: N, className: "vx-combobox__list", role: "listbox", "aria-label": l ?? "Options", children: A.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-combobox__empty", children: p }) : A.map((
|
|
4553
|
+
/* @__PURE__ */ a("ul", { id: N, className: "vx-combobox__list", role: "listbox", "aria-label": l ?? "Options", children: A.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-combobox__empty", children: p }) : A.map((R) => /* @__PURE__ */ S(
|
|
4610
4554
|
"li",
|
|
4611
4555
|
{
|
|
4612
4556
|
className: T(
|
|
4613
4557
|
"vx-combobox__option",
|
|
4614
|
-
|
|
4615
|
-
|
|
4558
|
+
R.value === m && "vx-combobox__option--selected",
|
|
4559
|
+
R.disabled && "vx-combobox__option--disabled"
|
|
4616
4560
|
),
|
|
4617
4561
|
role: "option",
|
|
4618
|
-
"aria-selected":
|
|
4619
|
-
"aria-disabled":
|
|
4620
|
-
onClick: () => P(
|
|
4562
|
+
"aria-selected": R.value === m,
|
|
4563
|
+
"aria-disabled": R.disabled,
|
|
4564
|
+
onClick: () => P(R),
|
|
4621
4565
|
children: [
|
|
4622
|
-
/* @__PURE__ */ a("span", { children:
|
|
4623
|
-
|
|
4566
|
+
/* @__PURE__ */ a("span", { children: R.label }),
|
|
4567
|
+
R.value === m ? /* @__PURE__ */ a(vt, { size: 14 }) : null
|
|
4624
4568
|
]
|
|
4625
4569
|
},
|
|
4626
|
-
|
|
4570
|
+
R.value
|
|
4627
4571
|
)) })
|
|
4628
4572
|
] })
|
|
4629
4573
|
] });
|
|
4630
4574
|
}
|
|
4631
|
-
function
|
|
4575
|
+
function Al({
|
|
4632
4576
|
label: e,
|
|
4633
4577
|
hint: t,
|
|
4634
4578
|
error: n,
|
|
@@ -4639,7 +4583,7 @@ function Dl({
|
|
|
4639
4583
|
onFiles: i,
|
|
4640
4584
|
className: u
|
|
4641
4585
|
}) {
|
|
4642
|
-
const [c, d] =
|
|
4586
|
+
const [c, d] = D(!1), [p, x] = D([]), [k, E] = D(), g = L(null), m = U(
|
|
4643
4587
|
(y) => {
|
|
4644
4588
|
if (!y) return;
|
|
4645
4589
|
const _ = Array.from(y);
|
|
@@ -4689,7 +4633,7 @@ function Dl({
|
|
|
4689
4633
|
},
|
|
4690
4634
|
"aria-label": "Upload files, click or drag and drop",
|
|
4691
4635
|
children: [
|
|
4692
|
-
/* @__PURE__ */ a(
|
|
4636
|
+
/* @__PURE__ */ a(na, { size: 24, className: "vx-file-upload__icon" }),
|
|
4693
4637
|
/* @__PURE__ */ S("p", { className: "vx-file-upload__text", children: [
|
|
4694
4638
|
/* @__PURE__ */ a("span", { className: "vx-file-upload__link", children: "Click to upload" }),
|
|
4695
4639
|
" or drag and drop"
|
|
@@ -4714,7 +4658,7 @@ function Dl({
|
|
|
4714
4658
|
),
|
|
4715
4659
|
f ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: f }) : null,
|
|
4716
4660
|
p.length > 0 && /* @__PURE__ */ a("ul", { className: "vx-file-upload__list", children: p.map(({ id: y, file: _ }) => /* @__PURE__ */ S("li", { className: "vx-file-upload__file", children: [
|
|
4717
|
-
/* @__PURE__ */ a(
|
|
4661
|
+
/* @__PURE__ */ a(Xr, { size: 14, className: "vx-file-upload__file-icon" }),
|
|
4718
4662
|
/* @__PURE__ */ a("span", { className: "vx-file-upload__file-name", children: _.name }),
|
|
4719
4663
|
/* @__PURE__ */ S("span", { className: "vx-file-upload__file-size", children: [
|
|
4720
4664
|
(_.size / 1024).toFixed(0),
|
|
@@ -4733,6 +4677,34 @@ function Dl({
|
|
|
4733
4677
|
] }, y)) })
|
|
4734
4678
|
] });
|
|
4735
4679
|
}
|
|
4680
|
+
function Pl({
|
|
4681
|
+
trigger: e,
|
|
4682
|
+
title: t,
|
|
4683
|
+
description: n,
|
|
4684
|
+
side: r = "right",
|
|
4685
|
+
children: s,
|
|
4686
|
+
footer: o,
|
|
4687
|
+
className: l,
|
|
4688
|
+
...i
|
|
4689
|
+
}) {
|
|
4690
|
+
return /* @__PURE__ */ S(_t, { ...i, children: [
|
|
4691
|
+
e ? /* @__PURE__ */ a(wt, { asChild: !0, children: e }) : null,
|
|
4692
|
+
/* @__PURE__ */ S(kt, { children: [
|
|
4693
|
+
/* @__PURE__ */ a(Nt, { className: "vx-sheet__overlay" }),
|
|
4694
|
+
/* @__PURE__ */ S(St, { className: T("vx-sheet", `vx-sheet--${r}`, l), children: [
|
|
4695
|
+
/* @__PURE__ */ S("div", { className: "vx-sheet__header", children: [
|
|
4696
|
+
/* @__PURE__ */ S("div", { children: [
|
|
4697
|
+
t ? /* @__PURE__ */ a(Et, { className: "vx-sheet__title", children: t }) : null,
|
|
4698
|
+
n ? /* @__PURE__ */ a(Tt, { className: "vx-sheet__description", children: n }) : null
|
|
4699
|
+
] }),
|
|
4700
|
+
/* @__PURE__ */ a(ze, { className: "vx-dialog__close", "aria-label": "Close", children: /* @__PURE__ */ a(ve, { size: 16 }) })
|
|
4701
|
+
] }),
|
|
4702
|
+
/* @__PURE__ */ a("div", { className: "vx-sheet__body", children: s }),
|
|
4703
|
+
o ? /* @__PURE__ */ a("div", { className: "vx-sheet__footer", children: o }) : null
|
|
4704
|
+
] })
|
|
4705
|
+
] })
|
|
4706
|
+
] });
|
|
4707
|
+
}
|
|
4736
4708
|
function Rl({
|
|
4737
4709
|
maxHeight: e,
|
|
4738
4710
|
maxWidth: t,
|
|
@@ -4765,7 +4737,7 @@ function Fl({
|
|
|
4765
4737
|
onClick: l,
|
|
4766
4738
|
...i
|
|
4767
4739
|
}) {
|
|
4768
|
-
const [u, c] =
|
|
4740
|
+
const [u, c] = D(t), d = e !== void 0, p = d ? e : u, x = (k) => {
|
|
4769
4741
|
d || c((E) => !E), n == null || n(!p), l == null || l(k);
|
|
4770
4742
|
};
|
|
4771
4743
|
return /* @__PURE__ */ a(
|
|
@@ -4780,7 +4752,7 @@ function Fl({
|
|
|
4780
4752
|
}
|
|
4781
4753
|
);
|
|
4782
4754
|
}
|
|
4783
|
-
function
|
|
4755
|
+
function Dl({
|
|
4784
4756
|
items: e,
|
|
4785
4757
|
value: t,
|
|
4786
4758
|
defaultValue: n,
|
|
@@ -4789,7 +4761,7 @@ function Il({
|
|
|
4789
4761
|
size: o = "md",
|
|
4790
4762
|
className: l
|
|
4791
4763
|
}) {
|
|
4792
|
-
const [i, u] =
|
|
4764
|
+
const [i, u] = D(
|
|
4793
4765
|
n ?? (s === "multiple" ? [] : "")
|
|
4794
4766
|
), c = t !== void 0, d = c ? t : i, p = (k) => Array.isArray(d) ? d.includes(k) : d === k, x = (k) => {
|
|
4795
4767
|
let E;
|
|
@@ -4818,8 +4790,8 @@ function Il({
|
|
|
4818
4790
|
k.value
|
|
4819
4791
|
)) });
|
|
4820
4792
|
}
|
|
4821
|
-
function
|
|
4822
|
-
const [s, o] =
|
|
4793
|
+
function Il({ groups: e, items: t, children: n, className: r }) {
|
|
4794
|
+
const [s, o] = D(null), l = L(null), i = e ?? (t ? [{ items: t }] : []);
|
|
4823
4795
|
O(() => {
|
|
4824
4796
|
if (!s) return;
|
|
4825
4797
|
const c = (p) => {
|
|
@@ -4874,14 +4846,14 @@ function Ll({ groups: e, items: t, children: n, className: r }) {
|
|
|
4874
4846
|
)
|
|
4875
4847
|
] });
|
|
4876
4848
|
}
|
|
4877
|
-
function
|
|
4849
|
+
function Ll({
|
|
4878
4850
|
content: e,
|
|
4879
4851
|
placement: t = "bottom",
|
|
4880
4852
|
delay: n = 400,
|
|
4881
4853
|
children: r,
|
|
4882
4854
|
className: s
|
|
4883
4855
|
}) {
|
|
4884
|
-
const [o, l] =
|
|
4856
|
+
const [o, l] = D(!1), i = L(null), u = U(() => {
|
|
4885
4857
|
i.current = setTimeout(() => l(!0), n);
|
|
4886
4858
|
}, [n]), c = U(() => {
|
|
4887
4859
|
i.current && clearTimeout(i.current), l(!1);
|
|
@@ -4901,8 +4873,8 @@ function Ml({
|
|
|
4901
4873
|
}
|
|
4902
4874
|
);
|
|
4903
4875
|
}
|
|
4904
|
-
function
|
|
4905
|
-
const [n, r] =
|
|
4876
|
+
function Ml({ menus: e, className: t }) {
|
|
4877
|
+
const [n, r] = D(null), s = L(null);
|
|
4906
4878
|
return O(() => {
|
|
4907
4879
|
if (n === null) return;
|
|
4908
4880
|
const o = (i) => {
|
|
@@ -4962,8 +4934,8 @@ function Ol({ menus: e, className: t }) {
|
|
|
4962
4934
|
] }, l);
|
|
4963
4935
|
}) });
|
|
4964
4936
|
}
|
|
4965
|
-
function
|
|
4966
|
-
const [n, r] =
|
|
4937
|
+
function Ol({ items: e, className: t }) {
|
|
4938
|
+
const [n, r] = D(null), s = L(null);
|
|
4967
4939
|
return O(() => {
|
|
4968
4940
|
if (n === null) return;
|
|
4969
4941
|
const o = (i) => {
|
|
@@ -4992,7 +4964,7 @@ function $l({ items: e, className: t }) {
|
|
|
4992
4964
|
children: [
|
|
4993
4965
|
o.label,
|
|
4994
4966
|
/* @__PURE__ */ a(
|
|
4995
|
-
|
|
4967
|
+
ht,
|
|
4996
4968
|
{
|
|
4997
4969
|
size: 14,
|
|
4998
4970
|
className: T(
|
|
@@ -5037,7 +5009,7 @@ function $l({ items: e, className: t }) {
|
|
|
5037
5009
|
] }, l);
|
|
5038
5010
|
}) }) });
|
|
5039
5011
|
}
|
|
5040
|
-
function
|
|
5012
|
+
function $l({
|
|
5041
5013
|
steps: e,
|
|
5042
5014
|
currentStep: t = 0,
|
|
5043
5015
|
orientation: n = "horizontal",
|
|
@@ -5051,7 +5023,7 @@ function Bl({
|
|
|
5051
5023
|
children: e.map((s, o) => {
|
|
5052
5024
|
const l = s.status ?? (o < t ? "completed" : o === t ? "active" : "pending");
|
|
5053
5025
|
return /* @__PURE__ */ S("li", { className: T("vx-stepper__step", `vx-stepper__step--${l}`), children: [
|
|
5054
|
-
/* @__PURE__ */ a("div", { className: "vx-stepper__indicator", "aria-hidden": "true", children: l === "completed" ? /* @__PURE__ */ a(
|
|
5026
|
+
/* @__PURE__ */ a("div", { className: "vx-stepper__indicator", "aria-hidden": "true", children: l === "completed" ? /* @__PURE__ */ a(vt, { size: 14 }) : /* @__PURE__ */ a("span", { children: o + 1 }) }),
|
|
5055
5027
|
/* @__PURE__ */ S("div", { className: "vx-stepper__content", children: [
|
|
5056
5028
|
/* @__PURE__ */ a("span", { className: "vx-stepper__label", children: s.label }),
|
|
5057
5029
|
s.description && /* @__PURE__ */ a("span", { className: "vx-stepper__description", children: s.description })
|
|
@@ -5062,7 +5034,7 @@ function Bl({
|
|
|
5062
5034
|
}
|
|
5063
5035
|
);
|
|
5064
5036
|
}
|
|
5065
|
-
function
|
|
5037
|
+
function Bl({ items: e, className: t }) {
|
|
5066
5038
|
return /* @__PURE__ */ a("ol", { className: T("vx-timeline", t), "aria-label": "Timeline", children: e.map((n, r) => /* @__PURE__ */ S(
|
|
5067
5039
|
"li",
|
|
5068
5040
|
{
|
|
@@ -5084,7 +5056,7 @@ function zl({ items: e, className: t }) {
|
|
|
5084
5056
|
r
|
|
5085
5057
|
)) });
|
|
5086
5058
|
}
|
|
5087
|
-
function
|
|
5059
|
+
function zl({ icon: e, title: t, description: n, action: r, className: s }) {
|
|
5088
5060
|
return /* @__PURE__ */ S("div", { className: T("vx-empty-state", s), role: "status", "aria-live": "polite", children: [
|
|
5089
5061
|
e && /* @__PURE__ */ a("div", { className: "vx-empty-state__icon", "aria-hidden": "true", children: e }),
|
|
5090
5062
|
/* @__PURE__ */ a("p", { className: "vx-empty-state__title", children: t }),
|
|
@@ -5092,7 +5064,7 @@ function Ul({ icon: e, title: t, description: n, action: r, className: s }) {
|
|
|
5092
5064
|
r && /* @__PURE__ */ a("div", { className: "vx-empty-state__action", children: r })
|
|
5093
5065
|
] });
|
|
5094
5066
|
}
|
|
5095
|
-
function
|
|
5067
|
+
function Ul({
|
|
5096
5068
|
items: e,
|
|
5097
5069
|
defaultIndex: t = 0,
|
|
5098
5070
|
index: n,
|
|
@@ -5104,7 +5076,7 @@ function Wl({
|
|
|
5104
5076
|
showArrows: u = !0,
|
|
5105
5077
|
className: c
|
|
5106
5078
|
}) {
|
|
5107
|
-
const d = n !== void 0, [p, x] =
|
|
5079
|
+
const d = n !== void 0, [p, x] = D(t), k = d ? n : p, E = e.length, g = L(null), m = U(
|
|
5108
5080
|
(v) => {
|
|
5109
5081
|
let f = v;
|
|
5110
5082
|
l ? f = (v % E + E) % E : f = Math.max(0, Math.min(v, E - 1)), d || x(f), r == null || r(f);
|
|
@@ -5185,7 +5157,7 @@ function Wl({
|
|
|
5185
5157
|
}
|
|
5186
5158
|
);
|
|
5187
5159
|
}
|
|
5188
|
-
function
|
|
5160
|
+
function ai({ filled: e, half: t }) {
|
|
5189
5161
|
return /* @__PURE__ */ a("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: t ? /* @__PURE__ */ S(q, { children: [
|
|
5190
5162
|
/* @__PURE__ */ a("defs", { children: /* @__PURE__ */ S("linearGradient", { id: "vx-star-half", children: [
|
|
5191
5163
|
/* @__PURE__ */ a("stop", { offset: "50%", stopColor: "currentColor" }),
|
|
@@ -5212,7 +5184,7 @@ function oi({ filled: e, half: t }) {
|
|
|
5212
5184
|
}
|
|
5213
5185
|
) });
|
|
5214
5186
|
}
|
|
5215
|
-
function
|
|
5187
|
+
function Wl({
|
|
5216
5188
|
value: e,
|
|
5217
5189
|
defaultValue: t = 0,
|
|
5218
5190
|
onChange: n,
|
|
@@ -5224,7 +5196,7 @@ function Hl({
|
|
|
5224
5196
|
className: u,
|
|
5225
5197
|
size: c = "md"
|
|
5226
5198
|
}) {
|
|
5227
|
-
const d = e !== void 0, [p, x] =
|
|
5199
|
+
const d = e !== void 0, [p, x] = D(t), k = d ? e : p, [E, g] = D(null), m = E ?? k, w = (f, y) => {
|
|
5228
5200
|
if (!s) return f;
|
|
5229
5201
|
const _ = y.currentTarget.getBoundingClientRect();
|
|
5230
5202
|
return y.clientX - _.left < _.width / 2 ? f - 0.5 : f;
|
|
@@ -5258,7 +5230,7 @@ function Hl({
|
|
|
5258
5230
|
"aria-label": `${_} star${_ !== 1 ? "s" : ""}`,
|
|
5259
5231
|
"aria-pressed": k >= _,
|
|
5260
5232
|
tabIndex: l || o ? -1 : 0,
|
|
5261
|
-
children: /* @__PURE__ */ a(
|
|
5233
|
+
children: /* @__PURE__ */ a(ai, { filled: N, half: C })
|
|
5262
5234
|
},
|
|
5263
5235
|
y
|
|
5264
5236
|
);
|
|
@@ -5266,7 +5238,7 @@ function Hl({
|
|
|
5266
5238
|
}
|
|
5267
5239
|
);
|
|
5268
5240
|
}
|
|
5269
|
-
function
|
|
5241
|
+
function Rr({ node: e, depth: t, selected: n, expanded: r, onSelect: s, onToggle: o }) {
|
|
5270
5242
|
const l = e.children && e.children.length > 0, i = r.has(e.id), u = n === e.id, c = (d) => {
|
|
5271
5243
|
(d.key === "Enter" || d.key === " ") && (d.preventDefault(), e.disabled || s(e.id, e)), d.key === "ArrowRight" && l && !i && (d.preventDefault(), o(e.id)), d.key === "ArrowLeft" && i && (d.preventDefault(), o(e.id));
|
|
5272
5244
|
};
|
|
@@ -5301,7 +5273,7 @@ function Fr({ node: e, depth: t, selected: n, expanded: r, onSelect: s, onToggle
|
|
|
5301
5273
|
}
|
|
5302
5274
|
),
|
|
5303
5275
|
l && i && /* @__PURE__ */ a("ul", { role: "group", className: "vx-tree__children", children: e.children.map((d) => /* @__PURE__ */ a(
|
|
5304
|
-
|
|
5276
|
+
Rr,
|
|
5305
5277
|
{
|
|
5306
5278
|
node: d,
|
|
5307
5279
|
depth: t + 1,
|
|
@@ -5314,7 +5286,7 @@ function Fr({ node: e, depth: t, selected: n, expanded: r, onSelect: s, onToggle
|
|
|
5314
5286
|
)) })
|
|
5315
5287
|
] });
|
|
5316
5288
|
}
|
|
5317
|
-
function
|
|
5289
|
+
function Hl({
|
|
5318
5290
|
nodes: e,
|
|
5319
5291
|
selected: t,
|
|
5320
5292
|
defaultSelected: n,
|
|
@@ -5324,7 +5296,7 @@ function Gl({
|
|
|
5324
5296
|
onExpandedChange: l,
|
|
5325
5297
|
className: i
|
|
5326
5298
|
}) {
|
|
5327
|
-
const u = t !== void 0, [c, d] =
|
|
5299
|
+
const u = t !== void 0, [c, d] = D(n), p = u ? t : c, x = o !== void 0, [k, E] = D(
|
|
5328
5300
|
new Set(s)
|
|
5329
5301
|
), g = x ? new Set(o) : k, m = U(
|
|
5330
5302
|
(h, v) => {
|
|
@@ -5345,7 +5317,7 @@ function Gl({
|
|
|
5345
5317
|
role: "tree",
|
|
5346
5318
|
"aria-multiselectable": "false",
|
|
5347
5319
|
children: e.map((h) => /* @__PURE__ */ a(
|
|
5348
|
-
|
|
5320
|
+
Rr,
|
|
5349
5321
|
{
|
|
5350
5322
|
node: h,
|
|
5351
5323
|
depth: 0,
|
|
@@ -5359,7 +5331,7 @@ function Gl({
|
|
|
5359
5331
|
}
|
|
5360
5332
|
);
|
|
5361
5333
|
}
|
|
5362
|
-
function
|
|
5334
|
+
function Gl({
|
|
5363
5335
|
value: e,
|
|
5364
5336
|
defaultValue: t = [],
|
|
5365
5337
|
onChange: n,
|
|
@@ -5374,12 +5346,12 @@ function jl({
|
|
|
5374
5346
|
className: p,
|
|
5375
5347
|
...x
|
|
5376
5348
|
}) {
|
|
5377
|
-
const k = e !== void 0, [E, g] =
|
|
5378
|
-
k || g(
|
|
5379
|
-
}, N = (
|
|
5380
|
-
const
|
|
5381
|
-
if (
|
|
5382
|
-
if (m.includes(
|
|
5349
|
+
const k = e !== void 0, [E, g] = D(t), m = k ? e : E, [w, h] = D(""), [v, f] = D(), y = L(null), _ = (F) => {
|
|
5350
|
+
k || g(F), n == null || n(F);
|
|
5351
|
+
}, N = (F) => {
|
|
5352
|
+
const R = F.trim();
|
|
5353
|
+
if (R) {
|
|
5354
|
+
if (m.includes(R)) {
|
|
5383
5355
|
f("Tag already exists");
|
|
5384
5356
|
return;
|
|
5385
5357
|
}
|
|
@@ -5388,7 +5360,7 @@ function jl({
|
|
|
5388
5360
|
return;
|
|
5389
5361
|
}
|
|
5390
5362
|
if (c) {
|
|
5391
|
-
const $ = c(
|
|
5363
|
+
const $ = c(R);
|
|
5392
5364
|
if ($ === !1) {
|
|
5393
5365
|
f("Invalid tag");
|
|
5394
5366
|
return;
|
|
@@ -5398,12 +5370,12 @@ function jl({
|
|
|
5398
5370
|
return;
|
|
5399
5371
|
}
|
|
5400
5372
|
}
|
|
5401
|
-
f(void 0), _([...m,
|
|
5373
|
+
f(void 0), _([...m, R]), h("");
|
|
5402
5374
|
}
|
|
5403
|
-
}, C = (
|
|
5404
|
-
_(m.filter((
|
|
5405
|
-
}, A = (
|
|
5406
|
-
i.includes(
|
|
5375
|
+
}, C = (F) => {
|
|
5376
|
+
_(m.filter((R, $) => $ !== F));
|
|
5377
|
+
}, A = (F) => {
|
|
5378
|
+
i.includes(F.key) ? (F.preventDefault(), N(w)) : F.key === "Backspace" && !w && m.length > 0 && C(m.length - 1);
|
|
5407
5379
|
}, P = o ?? v;
|
|
5408
5380
|
return /* @__PURE__ */ S("div", { className: T("vx-tag-input", p), children: [
|
|
5409
5381
|
r ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: r }) : null,
|
|
@@ -5416,25 +5388,25 @@ function jl({
|
|
|
5416
5388
|
d && "vx-tag-input__wrap--disabled"
|
|
5417
5389
|
),
|
|
5418
5390
|
onClick: () => {
|
|
5419
|
-
var
|
|
5420
|
-
return (
|
|
5391
|
+
var F;
|
|
5392
|
+
return (F = y.current) == null ? void 0 : F.focus();
|
|
5421
5393
|
},
|
|
5422
5394
|
children: [
|
|
5423
|
-
m.map((
|
|
5424
|
-
|
|
5395
|
+
m.map((F, R) => /* @__PURE__ */ S("span", { className: "vx-tag-input__tag", children: [
|
|
5396
|
+
F,
|
|
5425
5397
|
!d && /* @__PURE__ */ a(
|
|
5426
5398
|
"button",
|
|
5427
5399
|
{
|
|
5428
5400
|
type: "button",
|
|
5429
5401
|
className: "vx-tag-input__remove",
|
|
5430
5402
|
onClick: ($) => {
|
|
5431
|
-
$.stopPropagation(), C(
|
|
5403
|
+
$.stopPropagation(), C(R);
|
|
5432
5404
|
},
|
|
5433
|
-
"aria-label": `Remove tag ${
|
|
5405
|
+
"aria-label": `Remove tag ${F}`,
|
|
5434
5406
|
children: /* @__PURE__ */ a(ve, { size: 11 })
|
|
5435
5407
|
}
|
|
5436
5408
|
)
|
|
5437
|
-
] },
|
|
5409
|
+
] }, R)),
|
|
5438
5410
|
/* @__PURE__ */ a(
|
|
5439
5411
|
"input",
|
|
5440
5412
|
{
|
|
@@ -5444,8 +5416,8 @@ function jl({
|
|
|
5444
5416
|
placeholder: m.length === 0 ? l : "",
|
|
5445
5417
|
disabled: d,
|
|
5446
5418
|
onKeyDown: A,
|
|
5447
|
-
onChange: (
|
|
5448
|
-
h(
|
|
5419
|
+
onChange: (F) => {
|
|
5420
|
+
h(F.target.value), f(void 0);
|
|
5449
5421
|
},
|
|
5450
5422
|
onBlur: () => {
|
|
5451
5423
|
w.trim() && N(w);
|
|
@@ -5461,7 +5433,7 @@ function jl({
|
|
|
5461
5433
|
!P && s ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: s }) : null
|
|
5462
5434
|
] });
|
|
5463
5435
|
}
|
|
5464
|
-
function
|
|
5436
|
+
function si(e) {
|
|
5465
5437
|
const t = parseInt(e.slice(1, 3), 16) / 255, n = parseInt(e.slice(3, 5), 16) / 255, r = parseInt(e.slice(5, 7), 16) / 255, s = Math.max(t, n, r), o = Math.min(t, n, r), l = (s + o) / 2;
|
|
5466
5438
|
let i = 0, u = 0;
|
|
5467
5439
|
if (s !== o) {
|
|
@@ -5495,10 +5467,10 @@ function st(e, t, n) {
|
|
|
5495
5467
|
const d = (p) => Math.round(p * 255).toString(16).padStart(2, "0");
|
|
5496
5468
|
return `#${d(i)}${d(u)}${d(c)}`;
|
|
5497
5469
|
}
|
|
5498
|
-
function
|
|
5470
|
+
function Qt(e) {
|
|
5499
5471
|
return /^#[0-9a-f]{6}$/i.test(e);
|
|
5500
5472
|
}
|
|
5501
|
-
const
|
|
5473
|
+
const oi = [
|
|
5502
5474
|
"#ef4444",
|
|
5503
5475
|
"#f97316",
|
|
5504
5476
|
"#eab308",
|
|
@@ -5512,7 +5484,7 @@ const li = [
|
|
|
5512
5484
|
"#ffffff",
|
|
5513
5485
|
"#f8fafc"
|
|
5514
5486
|
];
|
|
5515
|
-
function
|
|
5487
|
+
function jl({
|
|
5516
5488
|
value: e,
|
|
5517
5489
|
defaultValue: t = "#3b82f6",
|
|
5518
5490
|
onChange: n,
|
|
@@ -5520,18 +5492,18 @@ function Kl({
|
|
|
5520
5492
|
hint: s,
|
|
5521
5493
|
error: o,
|
|
5522
5494
|
disabled: l,
|
|
5523
|
-
presets: i =
|
|
5495
|
+
presets: i = oi,
|
|
5524
5496
|
showPresets: u = !0,
|
|
5525
5497
|
className: c
|
|
5526
5498
|
}) {
|
|
5527
|
-
const d = e !== void 0, [p, x] =
|
|
5499
|
+
const d = e !== void 0, [p, x] = D(t), k = d ? e : p, [E, g] = D(k), [m, w] = D(!1), [h, v, f] = Qt(k) ? si(k) : [0, 0, 50], y = U(
|
|
5528
5500
|
(N) => {
|
|
5529
5501
|
d || x(N), g(N), n == null || n(N);
|
|
5530
5502
|
},
|
|
5531
5503
|
[d, n]
|
|
5532
5504
|
), _ = (N) => {
|
|
5533
5505
|
const C = N.startsWith("#") ? N : `#${N}`;
|
|
5534
|
-
g(C),
|
|
5506
|
+
g(C), Qt(C) && y(C);
|
|
5535
5507
|
};
|
|
5536
5508
|
return /* @__PURE__ */ S("div", { className: T("vx-colorpicker", c), children: [
|
|
5537
5509
|
r ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: r }) : null,
|
|
@@ -5635,7 +5607,7 @@ function Kl({
|
|
|
5635
5607
|
] })
|
|
5636
5608
|
] });
|
|
5637
5609
|
}
|
|
5638
|
-
function
|
|
5610
|
+
function Kl({
|
|
5639
5611
|
direction: e = "horizontal",
|
|
5640
5612
|
children: t,
|
|
5641
5613
|
className: n
|
|
@@ -5652,7 +5624,7 @@ function Vl({
|
|
|
5652
5624
|
}
|
|
5653
5625
|
);
|
|
5654
5626
|
}
|
|
5655
|
-
function
|
|
5627
|
+
function Vl({
|
|
5656
5628
|
children: e,
|
|
5657
5629
|
defaultSize: t = 50,
|
|
5658
5630
|
minSize: n = 10,
|
|
@@ -5671,11 +5643,11 @@ function Yl({
|
|
|
5671
5643
|
}
|
|
5672
5644
|
);
|
|
5673
5645
|
}
|
|
5674
|
-
function
|
|
5646
|
+
function Yl({
|
|
5675
5647
|
className: e,
|
|
5676
5648
|
direction: t = "horizontal"
|
|
5677
5649
|
}) {
|
|
5678
|
-
const n = L(!1), [r, s] =
|
|
5650
|
+
const n = L(!1), [r, s] = D(!1), o = U(
|
|
5679
5651
|
(l) => {
|
|
5680
5652
|
const i = l.currentTarget, u = i.previousElementSibling, c = i.nextElementSibling;
|
|
5681
5653
|
if (!u || !c) return;
|
|
@@ -5709,7 +5681,7 @@ function ql({
|
|
|
5709
5681
|
}
|
|
5710
5682
|
);
|
|
5711
5683
|
}
|
|
5712
|
-
function
|
|
5684
|
+
function Jt(e, t) {
|
|
5713
5685
|
if (!t) return e;
|
|
5714
5686
|
const n = e.toLowerCase().indexOf(t.toLowerCase());
|
|
5715
5687
|
return n === -1 ? e : /* @__PURE__ */ S(q, { children: [
|
|
@@ -5718,11 +5690,11 @@ function en(e, t) {
|
|
|
5718
5690
|
e.slice(n + t.length)
|
|
5719
5691
|
] });
|
|
5720
5692
|
}
|
|
5721
|
-
function
|
|
5693
|
+
function ii(e, t) {
|
|
5722
5694
|
const n = t.toLowerCase(), r = e.title.toLowerCase(), s = e.section.toLowerCase(), o = e.description.toLowerCase(), l = (e.keywords ?? []).join(" ").toLowerCase();
|
|
5723
5695
|
return r === n ? 100 : r.startsWith(n) ? 80 : r.includes(n) ? 60 : s.includes(n) ? 40 : l.includes(n) ? 35 : o.includes(n) ? 20 : 0;
|
|
5724
5696
|
}
|
|
5725
|
-
function
|
|
5697
|
+
function ql({
|
|
5726
5698
|
entries: e,
|
|
5727
5699
|
open: t,
|
|
5728
5700
|
onClose: n,
|
|
@@ -5734,7 +5706,7 @@ function Xl({
|
|
|
5734
5706
|
labelGo: u = "Go",
|
|
5735
5707
|
labelClose: c = "Close"
|
|
5736
5708
|
}) {
|
|
5737
|
-
const [d, p] =
|
|
5709
|
+
const [d, p] = D(""), [x, k] = D(0), E = L(null), g = L(null), m = d.trim() ? e.map((f) => ({ entry: f, s: ii(f, d.trim()) })).filter((f) => f.s > 0).sort((f, y) => y.s - f.s).map((f) => f.entry) : e;
|
|
5738
5710
|
O(() => {
|
|
5739
5711
|
t && (p(""), k(0), setTimeout(() => {
|
|
5740
5712
|
var f;
|
|
@@ -5808,8 +5780,8 @@ function Xl({
|
|
|
5808
5780
|
children: [
|
|
5809
5781
|
y.icon ? /* @__PURE__ */ a("span", { className: "vx-cmd__item-icon", children: y.icon }) : /* @__PURE__ */ a("span", { className: "vx-cmd__item-icon vx-cmd__item-icon--section", children: y.section.slice(0, 1) }),
|
|
5810
5782
|
/* @__PURE__ */ S("span", { className: "vx-cmd__item-body", children: [
|
|
5811
|
-
/* @__PURE__ */ a("span", { className: "vx-cmd__item-title", children:
|
|
5812
|
-
/* @__PURE__ */ a("span", { className: "vx-cmd__item-sub", children:
|
|
5783
|
+
/* @__PURE__ */ a("span", { className: "vx-cmd__item-title", children: Jt(y.title, d) }),
|
|
5784
|
+
/* @__PURE__ */ a("span", { className: "vx-cmd__item-sub", children: Jt(y.section, d) })
|
|
5813
5785
|
] }),
|
|
5814
5786
|
C && /* @__PURE__ */ a("kbd", { className: "vx-cmd__enter", children: "↵" })
|
|
5815
5787
|
]
|
|
@@ -5839,13 +5811,13 @@ function Xl({
|
|
|
5839
5811
|
}
|
|
5840
5812
|
) });
|
|
5841
5813
|
}
|
|
5842
|
-
var
|
|
5843
|
-
function
|
|
5814
|
+
var en = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
5815
|
+
function li(e) {
|
|
5844
5816
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
5845
5817
|
}
|
|
5846
|
-
var ot = { exports: {} },
|
|
5847
|
-
function
|
|
5848
|
-
return
|
|
5818
|
+
var ot = { exports: {} }, tn;
|
|
5819
|
+
function ci() {
|
|
5820
|
+
return tn || (tn = 1, (function(e) {
|
|
5849
5821
|
var t = typeof window < "u" ? window : typeof WorkerGlobalScope < "u" && self instanceof WorkerGlobalScope ? self : {};
|
|
5850
5822
|
/**
|
|
5851
5823
|
* Prism: Lightweight, robust, elegant syntax highlighting
|
|
@@ -6200,8 +6172,8 @@ function di() {
|
|
|
6200
6172
|
f.hasOwnProperty(C) || (N[C] = _[C]);
|
|
6201
6173
|
}
|
|
6202
6174
|
var P = y[h];
|
|
6203
|
-
return y[h] = N, i.languages.DFS(i.languages, function(
|
|
6204
|
-
|
|
6175
|
+
return y[h] = N, i.languages.DFS(i.languages, function(F, R) {
|
|
6176
|
+
R === P && F != h && (this[F] = N);
|
|
6205
6177
|
}), N;
|
|
6206
6178
|
},
|
|
6207
6179
|
// Traverse a language definition with Depth First Search
|
|
@@ -6296,8 +6268,8 @@ function di() {
|
|
|
6296
6268
|
grammar: _,
|
|
6297
6269
|
code: C
|
|
6298
6270
|
};
|
|
6299
|
-
function P(
|
|
6300
|
-
A.highlightedCode =
|
|
6271
|
+
function P(R) {
|
|
6272
|
+
A.highlightedCode = R, i.hooks.run("before-insert", A), A.element.innerHTML = A.highlightedCode, i.hooks.run("after-highlight", A), i.hooks.run("complete", A), f && f.call(A.element);
|
|
6301
6273
|
}
|
|
6302
6274
|
if (i.hooks.run("before-sanity-check", A), N = A.element.parentElement, N && N.nodeName.toLowerCase() === "pre" && !N.hasAttribute("tabindex") && N.setAttribute("tabindex", "0"), !A.code) {
|
|
6303
6275
|
i.hooks.run("complete", A), f && f.call(A.element);
|
|
@@ -6308,10 +6280,10 @@ function di() {
|
|
|
6308
6280
|
return;
|
|
6309
6281
|
}
|
|
6310
6282
|
if (v && r.Worker) {
|
|
6311
|
-
var
|
|
6312
|
-
|
|
6313
|
-
P(
|
|
6314
|
-
},
|
|
6283
|
+
var F = new Worker(i.filename);
|
|
6284
|
+
F.onmessage = function(R) {
|
|
6285
|
+
P(R.data);
|
|
6286
|
+
}, F.postMessage(JSON.stringify({
|
|
6315
6287
|
language: A.language,
|
|
6316
6288
|
code: A.code,
|
|
6317
6289
|
immediateClose: !0
|
|
@@ -6468,12 +6440,12 @@ function di() {
|
|
|
6468
6440
|
for (var P = 0; P < A.length; ++P) {
|
|
6469
6441
|
if (N && N.cause == C + "," + P)
|
|
6470
6442
|
return;
|
|
6471
|
-
var
|
|
6472
|
-
if (I && !
|
|
6473
|
-
var H =
|
|
6474
|
-
|
|
6443
|
+
var F = A[P], R = F.inside, $ = !!F.lookbehind, I = !!F.greedy, W = F.alias;
|
|
6444
|
+
if (I && !F.pattern.global) {
|
|
6445
|
+
var H = F.pattern.toString().match(/[imsuy]*$/)[0];
|
|
6446
|
+
F.pattern = RegExp(F.pattern.source, H + "g");
|
|
6475
6447
|
}
|
|
6476
|
-
for (var ee =
|
|
6448
|
+
for (var ee = F.pattern || F, z = y.next, G = _; z !== v.tail && !(N && G >= N.reach); G += z.value.length, z = z.next) {
|
|
6477
6449
|
var te = z.value;
|
|
6478
6450
|
if (v.length > h.length)
|
|
6479
6451
|
return;
|
|
@@ -6492,12 +6464,12 @@ function di() {
|
|
|
6492
6464
|
ie--, te = h.slice(G, V), j.index -= G;
|
|
6493
6465
|
} else if (j = c(ee, 0, te, $), !j)
|
|
6494
6466
|
continue;
|
|
6495
|
-
var Se = j.index, Ee = j[0], Ve = te.slice(0, Se),
|
|
6467
|
+
var Se = j.index, Ee = j[0], Ve = te.slice(0, Se), Dt = te.slice(Se + Ee.length), Ye = G + te.length;
|
|
6496
6468
|
N && Ye > N.reach && (N.reach = Ye);
|
|
6497
6469
|
var Te = z.prev;
|
|
6498
6470
|
Ve && (Te = x(v, Te, Ve), G += Ve.length), k(v, Te, ie);
|
|
6499
|
-
var
|
|
6500
|
-
if (z = x(v, Te,
|
|
6471
|
+
var Dr = new u(C, R ? i.tokenize(Ee, R) : Ee, W, Ee);
|
|
6472
|
+
if (z = x(v, Te, Dr), Dt && x(v, z, Dt), ie > 1) {
|
|
6501
6473
|
var qe = {
|
|
6502
6474
|
cause: C + "," + P,
|
|
6503
6475
|
reach: Ye
|
|
@@ -6543,7 +6515,7 @@ function di() {
|
|
|
6543
6515
|
}
|
|
6544
6516
|
return i;
|
|
6545
6517
|
})(t);
|
|
6546
|
-
e.exports && (e.exports = n), typeof
|
|
6518
|
+
e.exports && (e.exports = n), typeof en < "u" && (en.Prism = n), n.languages.markup = {
|
|
6547
6519
|
comment: {
|
|
6548
6520
|
pattern: /<!--(?:(?!<!--)[\s\S])*?-->/,
|
|
6549
6521
|
greedy: !0
|
|
@@ -7002,8 +6974,8 @@ function di() {
|
|
|
7002
6974
|
})();
|
|
7003
6975
|
})(ot)), ot.exports;
|
|
7004
6976
|
}
|
|
7005
|
-
var
|
|
7006
|
-
const Le = /* @__PURE__ */ ui
|
|
6977
|
+
var ui = ci();
|
|
6978
|
+
const Le = /* @__PURE__ */ li(ui);
|
|
7007
6979
|
Prism.languages.markup = {
|
|
7008
6980
|
comment: {
|
|
7009
6981
|
pattern: /<!--(?:(?!<!--)[\s\S])*?-->/,
|
|
@@ -7396,9 +7368,9 @@ Prism.languages.js = Prism.languages.javascript;
|
|
|
7396
7368
|
u.language !== "jsx" && u.language !== "tsx" || i(u.tokens);
|
|
7397
7369
|
});
|
|
7398
7370
|
})(Prism);
|
|
7399
|
-
var
|
|
7400
|
-
function
|
|
7401
|
-
return
|
|
7371
|
+
var nn = {}, rn;
|
|
7372
|
+
function di() {
|
|
7373
|
+
return rn || (rn = 1, (function(e) {
|
|
7402
7374
|
e.languages.typescript = e.languages.extend("javascript", {
|
|
7403
7375
|
"class-name": {
|
|
7404
7376
|
pattern: /(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,
|
|
@@ -7442,9 +7414,9 @@ function fi() {
|
|
|
7442
7414
|
}
|
|
7443
7415
|
}
|
|
7444
7416
|
}), e.languages.ts = e.languages.typescript;
|
|
7445
|
-
})(Prism)),
|
|
7417
|
+
})(Prism)), nn;
|
|
7446
7418
|
}
|
|
7447
|
-
|
|
7419
|
+
di();
|
|
7448
7420
|
(function(e) {
|
|
7449
7421
|
var t = e.util.clone(e.languages.typescript);
|
|
7450
7422
|
e.languages.tsx = e.languages.extend("jsx", t), delete e.languages.tsx.parameter, delete e.languages.tsx["literal-property"];
|
|
@@ -7695,14 +7667,14 @@ Prism.languages.json = {
|
|
|
7695
7667
|
}
|
|
7696
7668
|
};
|
|
7697
7669
|
Prism.languages.webmanifest = Prism.languages.json;
|
|
7698
|
-
function
|
|
7670
|
+
function Xl({
|
|
7699
7671
|
code: e,
|
|
7700
7672
|
language: t = "tsx",
|
|
7701
7673
|
copyLabel: n,
|
|
7702
7674
|
copiedLabel: r,
|
|
7703
7675
|
onCopy: s
|
|
7704
7676
|
}) {
|
|
7705
|
-
const [o, l] =
|
|
7677
|
+
const [o, l] = D(!1), i = L(null), u = be(() => {
|
|
7706
7678
|
const d = Le.languages[t] ?? Le.languages.tsx ?? Le.languages.typescript;
|
|
7707
7679
|
return d ? Le.highlight(e, d, t) : e;
|
|
7708
7680
|
}, [e, t]);
|
|
@@ -7724,7 +7696,7 @@ function Zl({
|
|
|
7724
7696
|
className: o ? "vx-code-block__copy vx-code-block__copy--copied" : "vx-code-block__copy",
|
|
7725
7697
|
onClick: () => void c(),
|
|
7726
7698
|
children: [
|
|
7727
|
-
o ? /* @__PURE__ */ a(
|
|
7699
|
+
o ? /* @__PURE__ */ a(vt, { size: 14 }) : /* @__PURE__ */ a(Yr, { size: 14 }),
|
|
7728
7700
|
o ? r : n
|
|
7729
7701
|
]
|
|
7730
7702
|
}
|
|
@@ -7738,7 +7710,7 @@ function Zl({
|
|
|
7738
7710
|
) })
|
|
7739
7711
|
] });
|
|
7740
7712
|
}
|
|
7741
|
-
const
|
|
7713
|
+
const Fr = {
|
|
7742
7714
|
locale: "en",
|
|
7743
7715
|
label: "English",
|
|
7744
7716
|
searchPlaceholder: "Search components, pages, keywords…",
|
|
@@ -7751,7 +7723,7 @@ const Ir = {
|
|
|
7751
7723
|
sidebarExpand: "Expand",
|
|
7752
7724
|
sidebarCloseLabel: "Close sidebar",
|
|
7753
7725
|
searchTrigger: "Search",
|
|
7754
|
-
versionLabel: "v1.
|
|
7726
|
+
versionLabel: "v1.1.1",
|
|
7755
7727
|
mobilePreview: "Mobile Preview",
|
|
7756
7728
|
nav: {
|
|
7757
7729
|
gettingStarted: "Getting Started",
|
|
@@ -8058,11 +8030,9 @@ const Ir = {
|
|
|
8058
8030
|
overlays: {
|
|
8059
8031
|
section: "Components",
|
|
8060
8032
|
title: "Overlays",
|
|
8061
|
-
description: "
|
|
8033
|
+
description: "Tooltip, Popover, and DropdownMenu layer transient content above the page without navigating away.",
|
|
8062
8034
|
guidance: [
|
|
8063
|
-
"
|
|
8064
|
-
"AlertDialog is for destructive or irreversible actions that require explicit confirmation.",
|
|
8065
|
-
"Sheet slides in from an edge — use it for settings panels or contextual detail views.",
|
|
8035
|
+
"Tooltips are for supplementary text only — never interactive content.",
|
|
8066
8036
|
"Popovers can contain forms and rich content; they require explicit close triggers.",
|
|
8067
8037
|
"DropdownMenus should group related actions and support keyboard navigation."
|
|
8068
8038
|
]
|
|
@@ -8198,7 +8168,7 @@ const Ir = {
|
|
|
8198
8168
|
]
|
|
8199
8169
|
}
|
|
8200
8170
|
}
|
|
8201
|
-
},
|
|
8171
|
+
}, pi = {
|
|
8202
8172
|
locale: "zh",
|
|
8203
8173
|
label: "中文",
|
|
8204
8174
|
searchPlaceholder: "搜索组件、页面、关键词…",
|
|
@@ -8211,7 +8181,7 @@ const Ir = {
|
|
|
8211
8181
|
sidebarExpand: "展开",
|
|
8212
8182
|
sidebarCloseLabel: "关闭侧边栏",
|
|
8213
8183
|
searchTrigger: "搜索",
|
|
8214
|
-
versionLabel: "v1.
|
|
8184
|
+
versionLabel: "v1.1.1",
|
|
8215
8185
|
mobilePreview: "移动端预览",
|
|
8216
8186
|
nav: {
|
|
8217
8187
|
gettingStarted: "开始使用",
|
|
@@ -8518,11 +8488,9 @@ const Ir = {
|
|
|
8518
8488
|
overlays: {
|
|
8519
8489
|
section: "组件",
|
|
8520
8490
|
title: "浮层",
|
|
8521
|
-
description: "
|
|
8491
|
+
description: "Tooltip、Popover 和 DropdownMenu 在页面上方叠加临时内容,无需跳转。",
|
|
8522
8492
|
guidance: [
|
|
8523
|
-
"
|
|
8524
|
-
"AlertDialog 适用于破坏性或不可撤销操作,需要用户明确确认。",
|
|
8525
|
-
"Sheet 从页面边缘滑入,适合设置面板或上下文详情视图。",
|
|
8493
|
+
"Tooltip 仅用于补充文本,绝不放置可交互内容。",
|
|
8526
8494
|
"Popover 可包含表单和富内容;需要明确的关闭触发器。",
|
|
8527
8495
|
"DropdownMenu 应对相关操作分组,并支持键盘导航。"
|
|
8528
8496
|
]
|
|
@@ -8658,17 +8626,17 @@ const Ir = {
|
|
|
8658
8626
|
]
|
|
8659
8627
|
}
|
|
8660
8628
|
}
|
|
8661
|
-
},
|
|
8662
|
-
t:
|
|
8629
|
+
}, an = { en: Fr, zh: pi }, fi = _e({
|
|
8630
|
+
t: Fr,
|
|
8663
8631
|
locale: "en",
|
|
8664
8632
|
setLocale: () => {
|
|
8665
8633
|
}
|
|
8666
8634
|
});
|
|
8667
|
-
function
|
|
8668
|
-
return ye(
|
|
8635
|
+
function vi() {
|
|
8636
|
+
return ye(fi);
|
|
8669
8637
|
}
|
|
8670
|
-
function
|
|
8671
|
-
const { locale: n, setLocale: r } =
|
|
8638
|
+
function Zl({ variant: e = "inline", className: t }) {
|
|
8639
|
+
const { locale: n, setLocale: r } = vi(), s = Object.entries(an), o = an[n], [l, i] = D(!1), u = L(null);
|
|
8672
8640
|
return O(() => {
|
|
8673
8641
|
if (!l) return;
|
|
8674
8642
|
const d = (p) => {
|
|
@@ -8704,9 +8672,9 @@ function Ql({ variant: e = "inline", className: t }) {
|
|
|
8704
8672
|
className: "vx-lang-drop__trigger-btn",
|
|
8705
8673
|
style: { height: "36px" },
|
|
8706
8674
|
children: [
|
|
8707
|
-
/* @__PURE__ */ a(
|
|
8675
|
+
/* @__PURE__ */ a(Qr, { size: 14, "aria-hidden": "true" }),
|
|
8708
8676
|
(o == null ? void 0 : o.label) ?? n,
|
|
8709
|
-
/* @__PURE__ */ a(
|
|
8677
|
+
/* @__PURE__ */ a(ht, { size: 14, className: "vx-lang-drop__chevron", "aria-hidden": "true" })
|
|
8710
8678
|
]
|
|
8711
8679
|
}
|
|
8712
8680
|
),
|
|
@@ -8729,105 +8697,105 @@ function Ql({ variant: e = "inline", className: t }) {
|
|
|
8729
8697
|
);
|
|
8730
8698
|
}
|
|
8731
8699
|
export {
|
|
8732
|
-
|
|
8733
|
-
|
|
8734
|
-
|
|
8735
|
-
|
|
8736
|
-
|
|
8737
|
-
|
|
8738
|
-
|
|
8739
|
-
|
|
8740
|
-
|
|
8741
|
-
|
|
8700
|
+
rl as Accordion,
|
|
8701
|
+
dl as ActionSheet,
|
|
8702
|
+
pl as ActionSheetItem,
|
|
8703
|
+
Xi as Alert,
|
|
8704
|
+
Sl as AlertDialog,
|
|
8705
|
+
yi as AppShell,
|
|
8706
|
+
sl as Avatar,
|
|
8707
|
+
_i as Badge,
|
|
8708
|
+
ul as BottomNav,
|
|
8709
|
+
tl as Breadcrumb,
|
|
8742
8710
|
fe as Button,
|
|
8743
|
-
|
|
8744
|
-
|
|
8745
|
-
|
|
8746
|
-
|
|
8747
|
-
|
|
8748
|
-
|
|
8749
|
-
|
|
8750
|
-
|
|
8751
|
-
|
|
8752
|
-
|
|
8753
|
-
|
|
8754
|
-
|
|
8755
|
-
|
|
8756
|
-
|
|
8757
|
-
|
|
8758
|
-
|
|
8759
|
-
|
|
8760
|
-
|
|
8761
|
-
|
|
8762
|
-
|
|
8763
|
-
|
|
8764
|
-
|
|
8765
|
-
|
|
8766
|
-
|
|
8767
|
-
|
|
8768
|
-
|
|
8769
|
-
|
|
8770
|
-
|
|
8771
|
-
|
|
8772
|
-
|
|
8773
|
-
|
|
8774
|
-
|
|
8775
|
-
|
|
8776
|
-
|
|
8777
|
-
|
|
8778
|
-
|
|
8779
|
-
|
|
8780
|
-
|
|
8781
|
-
|
|
8782
|
-
|
|
8783
|
-
|
|
8784
|
-
|
|
8785
|
-
|
|
8786
|
-
|
|
8787
|
-
|
|
8788
|
-
|
|
8789
|
-
|
|
8790
|
-
|
|
8791
|
-
|
|
8792
|
-
|
|
8711
|
+
ti as Calendar,
|
|
8712
|
+
wi as Card,
|
|
8713
|
+
Ei as CardContent,
|
|
8714
|
+
Si as CardDescription,
|
|
8715
|
+
ki as CardHeader,
|
|
8716
|
+
Ni as CardTitle,
|
|
8717
|
+
Ul as Carousel,
|
|
8718
|
+
Hi as Checkbox,
|
|
8719
|
+
Xl as CodeBlock,
|
|
8720
|
+
jl as ColorPicker,
|
|
8721
|
+
Cl as Combobox,
|
|
8722
|
+
ql as CommandPalette,
|
|
8723
|
+
Il as ContextMenu,
|
|
8724
|
+
Tl as DatePicker,
|
|
8725
|
+
Ci as Dialog,
|
|
8726
|
+
gl as DrawerNavItem,
|
|
8727
|
+
bl as DrawerNavSection,
|
|
8728
|
+
el as DropdownMenu,
|
|
8729
|
+
zl as EmptyState,
|
|
8730
|
+
Al as FileUpload,
|
|
8731
|
+
yl as Form,
|
|
8732
|
+
kl as FormDescription,
|
|
8733
|
+
_l as FormField,
|
|
8734
|
+
wl as FormLabel,
|
|
8735
|
+
Nl as FormMessage,
|
|
8736
|
+
Ui as Heading,
|
|
8737
|
+
Ll as HoverCard,
|
|
8738
|
+
Ai as Input,
|
|
8739
|
+
xl as Label,
|
|
8740
|
+
Zl as LanguageSwitcher,
|
|
8741
|
+
Ml as Menubar,
|
|
8742
|
+
ml as MobileDrawer,
|
|
8743
|
+
cl as MobileIconButton,
|
|
8744
|
+
fl as MobileList,
|
|
8745
|
+
hl as MobileListItem,
|
|
8746
|
+
vl as MobileListSection,
|
|
8747
|
+
il as MobileShell,
|
|
8748
|
+
ll as MobileTopBar,
|
|
8749
|
+
Ol as NavigationMenu,
|
|
8750
|
+
El as NumberInput,
|
|
8751
|
+
nl as Pagination,
|
|
8752
|
+
Ji as Popover,
|
|
8753
|
+
qi as Progress,
|
|
8754
|
+
Gi as Radio,
|
|
8755
|
+
ji as RadioGroup,
|
|
8756
|
+
Wl as Rating,
|
|
8757
|
+
Yl as ResizableHandle,
|
|
8758
|
+
Vl as ResizablePanel,
|
|
8759
|
+
Kl as ResizablePanelGroup,
|
|
8760
|
+
xi as Responsive,
|
|
8793
8761
|
Rl as ScrollArea,
|
|
8794
|
-
|
|
8795
|
-
|
|
8796
|
-
|
|
8797
|
-
|
|
8798
|
-
|
|
8799
|
-
|
|
8800
|
-
|
|
8801
|
-
|
|
8802
|
-
|
|
8803
|
-
|
|
8804
|
-
|
|
8805
|
-
|
|
8806
|
-
|
|
8807
|
-
|
|
8808
|
-
|
|
8809
|
-
|
|
8810
|
-
|
|
8811
|
-
|
|
8812
|
-
|
|
8813
|
-
|
|
8814
|
-
|
|
8815
|
-
|
|
8816
|
-
|
|
8817
|
-
|
|
8818
|
-
|
|
8819
|
-
|
|
8820
|
-
|
|
8821
|
-
|
|
8762
|
+
Wi as Select,
|
|
8763
|
+
al as Separator,
|
|
8764
|
+
Pl as Sheet,
|
|
8765
|
+
aa as Shell,
|
|
8766
|
+
pa as ShellContent,
|
|
8767
|
+
ua as ShellMain,
|
|
8768
|
+
oa as ShellNav,
|
|
8769
|
+
la as ShellNavItem,
|
|
8770
|
+
ia as ShellNavSection,
|
|
8771
|
+
ca as ShellOverlay,
|
|
8772
|
+
sa as ShellSidebar,
|
|
8773
|
+
da as ShellTopbar,
|
|
8774
|
+
Zi as Skeleton,
|
|
8775
|
+
Vi as Slider,
|
|
8776
|
+
Yi as Spinner,
|
|
8777
|
+
$l as Stepper,
|
|
8778
|
+
Pi as Switch,
|
|
8779
|
+
ol as Table,
|
|
8780
|
+
Ri as Tabs,
|
|
8781
|
+
Ii as TabsContent,
|
|
8782
|
+
Fi as TabsList,
|
|
8783
|
+
Di as TabsTrigger,
|
|
8784
|
+
Gl as TagInput,
|
|
8785
|
+
zi as Text,
|
|
8786
|
+
Ki as Textarea,
|
|
8787
|
+
Mi as ThemeProvider,
|
|
8788
|
+
Bl as Timeline,
|
|
8789
|
+
$i as ToastProvider,
|
|
8822
8790
|
Fl as Toggle,
|
|
8823
|
-
|
|
8824
|
-
|
|
8825
|
-
|
|
8826
|
-
|
|
8791
|
+
Dl as ToggleGroup,
|
|
8792
|
+
Qi as Tooltip,
|
|
8793
|
+
Hl as TreeView,
|
|
8794
|
+
bi as ViewportProvider,
|
|
8827
8795
|
Y as createTheme,
|
|
8828
|
-
|
|
8829
|
-
|
|
8830
|
-
|
|
8831
|
-
|
|
8832
|
-
|
|
8796
|
+
Li as themePresets,
|
|
8797
|
+
Qo as useFormField,
|
|
8798
|
+
Oi as useTheme,
|
|
8799
|
+
Bi as useToast,
|
|
8800
|
+
ln as useViewport
|
|
8833
8801
|
};
|