welcome-ui 10.0.0-alpha.4 → 10.0.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/2W3RN7C5-DMC82gDP.js +61 -0
- package/dist/{4I4MLMKD-z3Xm3qCo.js → 4I4MLMKD-BO6Lcy7s.js} +17 -17
- package/dist/Accordion.js +19 -17
- package/dist/Alert.js +40 -31
- package/dist/AspectRatio.js +1 -0
- package/dist/Avatar.js +13 -11
- package/dist/{B7UTNDHN-BDa2-8JK.js → B7UTNDHN-BghjolIs.js} +30 -30
- package/dist/Badge.js +1 -0
- package/dist/Breadcrumb.js +76 -71
- package/dist/Button.js +8 -6
- package/dist/ButtonGroup.js +6 -4
- package/dist/Card.css +1 -1
- package/dist/Card.js +68 -15
- package/dist/Checkbox.js +30 -29
- package/dist/CloseButton.js +7 -5
- package/dist/{CustomPopper-vwbOQq72.js → CustomPopper-C1wIDHbM.js} +5 -4
- package/dist/{DSAASPLT-C-2xDjIv.js → DSAASPLT-Fx1kuAsk.js} +3 -3
- package/dist/DatePicker.js +82 -78
- package/dist/DateTimePicker.js +22 -21
- package/dist/Drawer.js +101 -80
- package/dist/DropdownMenu.css +1 -1
- package/dist/DropdownMenu.js +889 -462
- package/dist/Field.js +1 -0
- package/dist/FieldGroup.js +9 -7
- package/dist/FileDrop.js +184 -176
- package/dist/FileUpload.js +43 -40
- package/dist/{GVVKDT6A-C66-lr0B.js → GVVKDT6A-CF9ejW_c.js} +103 -103
- package/dist/Hint.js +9 -7
- package/dist/Icon.js +6 -4
- package/dist/InputText.js +30 -28
- package/dist/{KPUWHTQJ-Byij2al4.js → KPUWHTQJ-Dv3cAqjP.js} +33 -31
- package/dist/Label.js +9 -7
- package/dist/Link.js +25 -21
- package/dist/Loader.js +12 -10
- package/dist/Logo.js +21 -13
- package/dist/Modal.js +145 -114
- package/dist/{NI3IVY7K-DpF3td-7.js → NI3IVY7K-Dy240mkD.js} +160 -160
- package/dist/{NMGNQVTG-BgAqqGOq.js → NMGNQVTG-DRO2uXZT.js} +6 -6
- package/dist/{OE2EFRVA-DkdhQLJL.js → OE2EFRVA-Dg1R6gaC.js} +186 -170
- package/dist/{OLVWQA7U-wHytlFYu.js → OLVWQA7U-Dia3UUnG.js} +36 -36
- package/dist/Pagination.js +39 -37
- package/dist/PasswordInput.js +20 -17
- package/dist/Popover.js +89 -72
- package/dist/{RTNCFSKZ-LcIdBwa8.js → RTNCFSKZ-BywELldk.js} +42 -42
- package/dist/Radio.js +20 -19
- package/dist/RadioGroup.js +29 -27
- package/dist/RadioTab.js +2 -1
- package/dist/{SBSPVDDI-BoxPz2JY.js → SBSPVDDI-CmtnvvUX.js} +46 -46
- package/dist/SQZLCNLX-Dg4KKdNJ.js +83 -0
- package/dist/Search.css +1 -1
- package/dist/Search.js +62 -60
- package/dist/Select.css +1 -1
- package/dist/Select.js +204 -202
- package/dist/Slider.js +66 -61
- package/dist/Stepper.js +34 -27
- package/dist/StickyNote.js +30 -23
- package/dist/Swiper.js +52 -50
- package/dist/{T22PY7TE-CzEDuEn1.js → T22PY7TE-gLuJpoOm.js} +46 -46
- package/dist/Table.js +34 -21
- package/dist/Tabs.js +161 -152
- package/dist/Tag.css +1 -1
- package/dist/Tag.js +70 -65
- package/dist/Text.js +4 -2
- package/dist/Textarea.js +10 -8
- package/dist/TimePicker.js +22 -21
- package/dist/Toast.js +186 -177
- package/dist/Toggle.js +16 -14
- package/dist/Tooltip.js +29 -27
- package/dist/VariantIcon.js +7 -5
- package/dist/VisuallyHidden.js +8 -6
- package/dist/WelcomeLoader.js +3 -2
- package/dist/XCKGTAUF-CJwwVibW.js +25 -0
- package/dist/{Y67KZUMI-BDyUNSJw.js → Y67KZUMI-BwLWwpNF.js} +2 -2
- package/dist/{ZTXFEM5L-CjFLRObi.js → ZTXFEM5L-WGHY_jqg.js} +3 -3
- package/dist/theme.js +1 -0
- package/dist/types/components/Alert/components/Title.d.ts +4 -1
- package/dist/types/components/Alert/index.d.ts +4 -1
- package/dist/types/components/Card/Body.d.ts +2 -3
- package/dist/types/components/Card/Footer.d.ts +6 -0
- package/dist/types/components/Card/Header.d.ts +5 -0
- package/dist/types/components/Card/index.d.ts +7 -8
- package/dist/types/components/Card/types.d.ts +16 -3
- package/dist/types/components/Checkbox/index.d.ts +1 -2
- package/dist/types/components/Checkbox/types.d.ts +3 -1
- package/dist/types/components/DateTimePickerCommon/CustomHeader.d.ts +4 -1
- package/dist/types/components/DateTimePickerCommon/CustomPopper.d.ts +6 -3
- package/dist/types/components/Drawer/AssetDrawer/Header.d.ts +4 -1
- package/dist/types/components/Drawer/AssetDrawer/IconBlock.d.ts +4 -1
- package/dist/types/components/Drawer/components/Close.d.ts +4 -1
- package/dist/types/components/Drawer/components/Title.d.ts +4 -1
- package/dist/types/components/Drawer/index.d.ts +12 -3
- package/dist/types/components/DropdownMenu/Action.d.ts +2 -0
- package/dist/types/components/DropdownMenu/Group.d.ts +4 -0
- package/dist/types/components/DropdownMenu/Item.d.ts +7 -0
- package/dist/types/components/DropdownMenu/Search.d.ts +2 -0
- package/dist/types/components/DropdownMenu/Submenu.d.ts +4 -0
- package/dist/types/components/DropdownMenu/index.d.ts +11 -0
- package/dist/types/components/DropdownMenu/types.d.ts +26 -5
- package/dist/types/components/FileDrop/components/FilePreview.d.ts +4 -1
- package/dist/types/components/FileDrop/components/Message.d.ts +4 -1
- package/dist/types/components/Loader/index.d.ts +4 -1
- package/dist/types/components/Modal/Assets/AssetContent.d.ts +4 -1
- package/dist/types/components/Modal/Assets/AssetTitle.d.ts +4 -1
- package/dist/types/components/Modal/Assets/CloseButton.d.ts +4 -1
- package/dist/types/components/Modal/Assets/Dialog.d.ts +4 -1
- package/dist/types/components/Modal/Assets/Iframe.d.ts +4 -1
- package/dist/types/components/Modal/Assets/index.d.ts +16 -4
- package/dist/types/components/Modal/components/Close.d.ts +4 -1
- package/dist/types/components/Modal/index.d.ts +16 -4
- package/dist/types/components/PasswordInput/ToggleButton.d.ts +4 -1
- package/dist/types/components/Popover/Arrow.d.ts +4 -1
- package/dist/types/components/Popover/ContentWrapper.d.ts +4 -1
- package/dist/types/components/RadioGroup/index.d.ts +4 -1
- package/dist/types/components/Stepper/index.d.ts +8 -2
- package/dist/types/components/StickyNote/components/Button.d.ts +4 -1
- package/dist/types/components/StickyNote/components/Title.d.ts +4 -1
- package/dist/types/components/StickyNote/index.d.ts +8 -2
- package/dist/types/components/Swiper/index.d.ts +4 -1
- package/dist/types/components/Table/index.d.ts +20 -5
- package/dist/types/components/Tabs/components/ActiveBar/index.d.ts +4 -1
- package/dist/types/components/Tag/types.d.ts +4 -2
- package/dist/types/components/Toast/index.d.ts +4 -1
- package/dist/utils.js +1 -0
- package/package.json +2 -2
- package/dist/2W3RN7C5-uG7eBeTQ.js +0 -61
- package/dist/SQZLCNLX-CUlXoT69.js +0 -82
- package/dist/XCKGTAUF-CahZE721.js +0 -25
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import * as m from "react";
|
|
3
|
-
import { isValidElement as Kt, useMemo as
|
|
3
|
+
import { isValidElement as Kt, useMemo as j, useState as T, useLayoutEffect as kt, useEffect as E, useRef as N, useCallback as yt, useReducer as jt, createContext as Bt, useContext as $t } from "react";
|
|
4
4
|
import { jsx as P } from "react/jsx-runtime";
|
|
5
5
|
var Wt = Object.defineProperty, qt = Object.defineProperties, Ut = Object.getOwnPropertyDescriptors, D = Object.getOwnPropertySymbols, Et = Object.prototype.hasOwnProperty, wt = Object.prototype.propertyIsEnumerable, ut = (t, e, r) => e in t ? Wt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, l = (t, e) => {
|
|
6
6
|
for (var r in e || (e = {}))
|
|
@@ -17,14 +17,14 @@ var Wt = Object.defineProperty, qt = Object.defineProperties, Ut = Object.getOwn
|
|
|
17
17
|
for (var n of D(t))
|
|
18
18
|
e.indexOf(n) < 0 && wt.call(t, n) && (r[n] = t[n]);
|
|
19
19
|
return r;
|
|
20
|
-
}, Xt = Object.defineProperty, Gt = Object.defineProperties, Ht = Object.getOwnPropertyDescriptors, R = Object.getOwnPropertySymbols, xt = Object.prototype.hasOwnProperty, Pt = Object.prototype.propertyIsEnumerable, st = (t, e, r) => e in t ? Xt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r,
|
|
20
|
+
}, Xt = Object.defineProperty, Gt = Object.defineProperties, Ht = Object.getOwnPropertyDescriptors, R = Object.getOwnPropertySymbols, xt = Object.prototype.hasOwnProperty, Pt = Object.prototype.propertyIsEnumerable, st = (t, e, r) => e in t ? Xt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, B = (t, e) => {
|
|
21
21
|
for (var r in e || (e = {}))
|
|
22
22
|
xt.call(e, r) && st(t, r, e[r]);
|
|
23
23
|
if (R)
|
|
24
24
|
for (var r of R(e))
|
|
25
25
|
Pt.call(e, r) && st(t, r, e[r]);
|
|
26
26
|
return t;
|
|
27
|
-
}, Yt = (t, e) => Gt(t, Ht(e)),
|
|
27
|
+
}, Yt = (t, e) => Gt(t, Ht(e)), Be = (t, e) => {
|
|
28
28
|
var r = {};
|
|
29
29
|
for (var n in t)
|
|
30
30
|
xt.call(t, n) && e.indexOf(n) < 0 && (r[n] = t[n]);
|
|
@@ -33,9 +33,19 @@ var Wt = Object.defineProperty, qt = Object.defineProperties, Ut = Object.getOwn
|
|
|
33
33
|
e.indexOf(n) < 0 && Pt.call(t, n) && (r[n] = t[n]);
|
|
34
34
|
return r;
|
|
35
35
|
};
|
|
36
|
-
function
|
|
36
|
+
function $e(...t) {
|
|
37
37
|
}
|
|
38
38
|
function We(t, e) {
|
|
39
|
+
if (t === e) return !0;
|
|
40
|
+
if (!t || !e || typeof t != "object" || typeof e != "object") return !1;
|
|
41
|
+
const r = Object.keys(t), n = Object.keys(e), { length: o } = r;
|
|
42
|
+
if (n.length !== o) return !1;
|
|
43
|
+
for (const u of r)
|
|
44
|
+
if (t[u] !== e[u])
|
|
45
|
+
return !1;
|
|
46
|
+
return !0;
|
|
47
|
+
}
|
|
48
|
+
function qe(t, e) {
|
|
39
49
|
if (zt(t)) {
|
|
40
50
|
const r = Jt(e) ? e() : e;
|
|
41
51
|
return t(r);
|
|
@@ -48,41 +58,41 @@ function zt(t) {
|
|
|
48
58
|
function Jt(t) {
|
|
49
59
|
return typeof t == "function";
|
|
50
60
|
}
|
|
51
|
-
function
|
|
61
|
+
function $(t, e) {
|
|
52
62
|
return typeof Object.hasOwn == "function" ? Object.hasOwn(t, e) : Object.prototype.hasOwnProperty.call(t, e);
|
|
53
63
|
}
|
|
54
|
-
function
|
|
64
|
+
function Ue(...t) {
|
|
55
65
|
return (...e) => {
|
|
56
66
|
for (const r of t)
|
|
57
67
|
typeof r == "function" && r(...e);
|
|
58
68
|
};
|
|
59
69
|
}
|
|
60
|
-
function
|
|
70
|
+
function Xe(t) {
|
|
61
71
|
return t.normalize("NFD").replace(/[\u0300-\u036f]/g, "");
|
|
62
72
|
}
|
|
63
|
-
function
|
|
64
|
-
const r =
|
|
73
|
+
function Ge(t, e) {
|
|
74
|
+
const r = B({}, t);
|
|
65
75
|
for (const n of e)
|
|
66
|
-
|
|
76
|
+
$(r, n) && delete r[n];
|
|
67
77
|
return r;
|
|
68
78
|
}
|
|
69
|
-
function
|
|
79
|
+
function He(t, e) {
|
|
70
80
|
const r = {};
|
|
71
81
|
for (const n of e)
|
|
72
|
-
|
|
82
|
+
$(t, n) && (r[n] = t[n]);
|
|
73
83
|
return r;
|
|
74
84
|
}
|
|
75
|
-
function
|
|
85
|
+
function Ye(t) {
|
|
76
86
|
return t;
|
|
77
87
|
}
|
|
78
|
-
function
|
|
88
|
+
function ze(t, e) {
|
|
79
89
|
if (!t)
|
|
80
90
|
throw typeof e != "string" ? new Error("Invariant failed") : new Error(e);
|
|
81
91
|
}
|
|
82
|
-
function
|
|
92
|
+
function Je(t) {
|
|
83
93
|
return Object.keys(t);
|
|
84
94
|
}
|
|
85
|
-
function
|
|
95
|
+
function Qe(t, ...e) {
|
|
86
96
|
const r = typeof t == "function" ? t(...e) : t;
|
|
87
97
|
return r == null ? !1 : !r;
|
|
88
98
|
}
|
|
@@ -95,7 +105,7 @@ function Zt(t) {
|
|
|
95
105
|
t[r] !== void 0 && (e[r] = t[r]);
|
|
96
106
|
return e;
|
|
97
107
|
}
|
|
98
|
-
function
|
|
108
|
+
function Ze(...t) {
|
|
99
109
|
for (const e of t)
|
|
100
110
|
if (e !== void 0) return e;
|
|
101
111
|
}
|
|
@@ -111,7 +121,7 @@ function re(t) {
|
|
|
111
121
|
function ne(t, e) {
|
|
112
122
|
const r = l({}, t);
|
|
113
123
|
for (const n in e) {
|
|
114
|
-
if (
|
|
124
|
+
if (!$(e, n)) continue;
|
|
115
125
|
if (n === "className") {
|
|
116
126
|
const u = "className";
|
|
117
127
|
r[u] = t[u] ? `${t[u]} ${e[u]}` : e[u];
|
|
@@ -136,7 +146,7 @@ function ne(t, e) {
|
|
|
136
146
|
}
|
|
137
147
|
return r;
|
|
138
148
|
}
|
|
139
|
-
var
|
|
149
|
+
var F = oe();
|
|
140
150
|
function oe() {
|
|
141
151
|
var t;
|
|
142
152
|
return typeof window < "u" && !!((t = window.document) != null && t.createElement);
|
|
@@ -144,15 +154,15 @@ function oe() {
|
|
|
144
154
|
function _(t) {
|
|
145
155
|
return t ? "self" in t ? t.document : t.ownerDocument || document : document;
|
|
146
156
|
}
|
|
147
|
-
function
|
|
157
|
+
function tr(t) {
|
|
148
158
|
return t ? "self" in t ? t.self : _(t).defaultView || window : self;
|
|
149
159
|
}
|
|
150
|
-
function
|
|
160
|
+
function O(t, e = !1) {
|
|
151
161
|
const { activeElement: r } = _(t);
|
|
152
162
|
if (!(r != null && r.nodeName))
|
|
153
163
|
return null;
|
|
154
164
|
if (W(r) && r.contentDocument)
|
|
155
|
-
return
|
|
165
|
+
return O(
|
|
156
166
|
r.contentDocument.body,
|
|
157
167
|
e
|
|
158
168
|
);
|
|
@@ -166,7 +176,7 @@ function F(t, e = !1) {
|
|
|
166
176
|
}
|
|
167
177
|
return r;
|
|
168
178
|
}
|
|
169
|
-
function
|
|
179
|
+
function I(t, e) {
|
|
170
180
|
return t === e || t.contains(e);
|
|
171
181
|
}
|
|
172
182
|
function W(t) {
|
|
@@ -198,10 +208,10 @@ function q(t) {
|
|
|
198
208
|
return !1;
|
|
199
209
|
}
|
|
200
210
|
}
|
|
201
|
-
function
|
|
211
|
+
function er(t) {
|
|
202
212
|
return t.isContentEditable || q(t);
|
|
203
213
|
}
|
|
204
|
-
function
|
|
214
|
+
function rr(t) {
|
|
205
215
|
if (q(t))
|
|
206
216
|
return t.value;
|
|
207
217
|
if (t.isContentEditable) {
|
|
@@ -210,13 +220,13 @@ function er(t) {
|
|
|
210
220
|
}
|
|
211
221
|
return "";
|
|
212
222
|
}
|
|
213
|
-
function
|
|
223
|
+
function nr(t) {
|
|
214
224
|
let e = 0, r = 0;
|
|
215
225
|
if (q(t))
|
|
216
226
|
e = t.selectionStart || 0, r = t.selectionEnd || 0;
|
|
217
227
|
else if (t.isContentEditable) {
|
|
218
228
|
const n = _(t).getSelection();
|
|
219
|
-
if (n != null && n.rangeCount && n.anchorNode &&
|
|
229
|
+
if (n != null && n.rangeCount && n.anchorNode && I(t, n.anchorNode) && n.focusNode && I(t, n.focusNode)) {
|
|
220
230
|
const o = n.getRangeAt(0), u = o.cloneRange();
|
|
221
231
|
u.selectNodeContents(t), u.setEnd(o.startContainer, o.startOffset), e = u.toString().length, u.setEnd(o.endContainer, o.endOffset), r = u.toString().length;
|
|
222
232
|
}
|
|
@@ -227,7 +237,7 @@ function ae(t, e) {
|
|
|
227
237
|
const r = ["dialog", "menu", "listbox", "tree", "grid"], n = t == null ? void 0 : t.getAttribute("role");
|
|
228
238
|
return n && r.indexOf(n) !== -1 ? n : e;
|
|
229
239
|
}
|
|
230
|
-
function
|
|
240
|
+
function or(t, e) {
|
|
231
241
|
var r;
|
|
232
242
|
const n = {
|
|
233
243
|
menu: "menuitem",
|
|
@@ -248,7 +258,7 @@ function ce(t) {
|
|
|
248
258
|
}
|
|
249
259
|
return ce(t.parentElement) || document.scrollingElement || document.body;
|
|
250
260
|
}
|
|
251
|
-
function
|
|
261
|
+
function ur(t, e) {
|
|
252
262
|
const r = t.map((o, u) => [u, o]);
|
|
253
263
|
let n = !1;
|
|
254
264
|
return r.sort(([o, u], [a, i]) => {
|
|
@@ -260,27 +270,27 @@ function fe(t, e) {
|
|
|
260
270
|
return !!(e.compareDocumentPosition(t) & Node.DOCUMENT_POSITION_PRECEDING);
|
|
261
271
|
}
|
|
262
272
|
function le() {
|
|
263
|
-
return
|
|
273
|
+
return F && !!navigator.maxTouchPoints;
|
|
264
274
|
}
|
|
265
275
|
function Ct() {
|
|
266
|
-
return
|
|
276
|
+
return F ? /mac|iphone|ipad|ipod/i.test(navigator.platform) : !1;
|
|
267
277
|
}
|
|
268
278
|
function de() {
|
|
269
|
-
return
|
|
270
|
-
}
|
|
271
|
-
function ur() {
|
|
272
|
-
return T && /firefox\//i.test(navigator.userAgent);
|
|
279
|
+
return F && Ct() && /apple/i.test(navigator.vendor);
|
|
273
280
|
}
|
|
274
281
|
function sr() {
|
|
275
|
-
return
|
|
282
|
+
return F && /firefox\//i.test(navigator.userAgent);
|
|
283
|
+
}
|
|
284
|
+
function ir() {
|
|
285
|
+
return F && navigator.platform.startsWith("Mac") && !le();
|
|
276
286
|
}
|
|
277
287
|
function be(t) {
|
|
278
|
-
return !!(t.currentTarget && !
|
|
288
|
+
return !!(t.currentTarget && !I(t.currentTarget, t.target));
|
|
279
289
|
}
|
|
280
290
|
function it(t) {
|
|
281
291
|
return t.target === t.currentTarget;
|
|
282
292
|
}
|
|
283
|
-
function
|
|
293
|
+
function ar(t) {
|
|
284
294
|
const e = t.currentTarget;
|
|
285
295
|
if (!e) return !1;
|
|
286
296
|
const r = Ct();
|
|
@@ -288,31 +298,31 @@ function ir(t) {
|
|
|
288
298
|
const n = e.tagName.toLowerCase();
|
|
289
299
|
return n === "a" || n === "button" && e.type === "submit" || n === "input" && e.type === "submit";
|
|
290
300
|
}
|
|
291
|
-
function
|
|
301
|
+
function cr(t) {
|
|
292
302
|
const e = t.currentTarget;
|
|
293
303
|
if (!e) return !1;
|
|
294
304
|
const r = e.tagName.toLowerCase();
|
|
295
305
|
return t.altKey ? r === "a" || r === "button" && e.type === "submit" || r === "input" && e.type === "submit" : !1;
|
|
296
306
|
}
|
|
297
|
-
function
|
|
307
|
+
function fr(t, e, r) {
|
|
298
308
|
const n = new Event(e, r);
|
|
299
309
|
return t.dispatchEvent(n);
|
|
300
310
|
}
|
|
301
|
-
function
|
|
302
|
-
const r = new FocusEvent("blur", e), n = t.dispatchEvent(r), o = Yt(
|
|
311
|
+
function lr(t, e) {
|
|
312
|
+
const r = new FocusEvent("blur", e), n = t.dispatchEvent(r), o = Yt(B({}, e), { bubbles: !0 });
|
|
303
313
|
return t.dispatchEvent(new FocusEvent("focusout", o)), n;
|
|
304
314
|
}
|
|
305
|
-
function
|
|
315
|
+
function dr(t, e, r) {
|
|
306
316
|
const n = new KeyboardEvent(e, r);
|
|
307
317
|
return t.dispatchEvent(n);
|
|
308
318
|
}
|
|
309
|
-
function
|
|
319
|
+
function br(t, e) {
|
|
310
320
|
const r = new MouseEvent("click", e);
|
|
311
321
|
return t.dispatchEvent(r);
|
|
312
322
|
}
|
|
313
323
|
function pe(t, e) {
|
|
314
324
|
const r = e || t.currentTarget, n = t.relatedTarget;
|
|
315
|
-
return !n || !
|
|
325
|
+
return !n || !I(r, n);
|
|
316
326
|
}
|
|
317
327
|
function K(t, e, r, n) {
|
|
318
328
|
const u = ((i) => {
|
|
@@ -344,8 +354,12 @@ function g(t, e, r, n = window) {
|
|
|
344
354
|
}
|
|
345
355
|
var U = l({}, m), at = U.useId;
|
|
346
356
|
U.useDeferredValue;
|
|
347
|
-
var ct = U.useInsertionEffect, M =
|
|
348
|
-
function
|
|
357
|
+
var ct = U.useInsertionEffect, M = F ? kt : E;
|
|
358
|
+
function pr(t) {
|
|
359
|
+
const [e] = T(t);
|
|
360
|
+
return e;
|
|
361
|
+
}
|
|
362
|
+
function vr(t) {
|
|
349
363
|
const e = N(t);
|
|
350
364
|
return M(() => {
|
|
351
365
|
e.current = t;
|
|
@@ -362,8 +376,8 @@ function y(t) {
|
|
|
362
376
|
return (n = e.current) == null ? void 0 : n.call(e, ...r);
|
|
363
377
|
}, []);
|
|
364
378
|
}
|
|
365
|
-
function
|
|
366
|
-
const [e, r] =
|
|
379
|
+
function mr(t) {
|
|
380
|
+
const [e, r] = T(null);
|
|
367
381
|
return M(() => {
|
|
368
382
|
if (e == null || !t) return;
|
|
369
383
|
let n = null;
|
|
@@ -373,7 +387,7 @@ function pr(t) {
|
|
|
373
387
|
}, [e, t]), [e, r];
|
|
374
388
|
}
|
|
375
389
|
function X(...t) {
|
|
376
|
-
return
|
|
390
|
+
return j(() => {
|
|
377
391
|
if (t.some(Boolean))
|
|
378
392
|
return (e) => {
|
|
379
393
|
for (const r of t)
|
|
@@ -381,12 +395,12 @@ function X(...t) {
|
|
|
381
395
|
};
|
|
382
396
|
}, t);
|
|
383
397
|
}
|
|
384
|
-
function
|
|
398
|
+
function gr(t) {
|
|
385
399
|
if (at) {
|
|
386
400
|
const n = at();
|
|
387
401
|
return t || n;
|
|
388
402
|
}
|
|
389
|
-
const [e, r] =
|
|
403
|
+
const [e, r] = T(t);
|
|
390
404
|
return M(() => {
|
|
391
405
|
if (t || e) return;
|
|
392
406
|
const n = Math.random().toString(36).slice(2, 8);
|
|
@@ -397,13 +411,13 @@ function ve(t, e) {
|
|
|
397
411
|
const r = (u) => {
|
|
398
412
|
if (typeof u == "string")
|
|
399
413
|
return u;
|
|
400
|
-
}, [n, o] =
|
|
414
|
+
}, [n, o] = T(() => r(e));
|
|
401
415
|
return M(() => {
|
|
402
416
|
const u = t && "current" in t ? t.current : t;
|
|
403
417
|
o((u == null ? void 0 : u.tagName.toLowerCase()) || r(e));
|
|
404
418
|
}, [t, e]), n;
|
|
405
419
|
}
|
|
406
|
-
function
|
|
420
|
+
function yr(t, e) {
|
|
407
421
|
const r = N(!1);
|
|
408
422
|
E(() => {
|
|
409
423
|
if (r.current)
|
|
@@ -416,32 +430,32 @@ function mr(t, e) {
|
|
|
416
430
|
[]
|
|
417
431
|
);
|
|
418
432
|
}
|
|
419
|
-
function
|
|
420
|
-
return
|
|
433
|
+
function Er() {
|
|
434
|
+
return jt(() => [], []);
|
|
421
435
|
}
|
|
422
|
-
function
|
|
436
|
+
function wr(t) {
|
|
423
437
|
return y(
|
|
424
438
|
typeof t == "function" ? t : () => t
|
|
425
439
|
);
|
|
426
440
|
}
|
|
427
|
-
function
|
|
441
|
+
function hr(t, e, r = []) {
|
|
428
442
|
const n = yt(
|
|
429
443
|
(o) => (t.wrapElement && (o = t.wrapElement(o)), e(o)),
|
|
430
444
|
[...r, t.wrapElement]
|
|
431
445
|
);
|
|
432
446
|
return w(l({}, t), { wrapElement: n });
|
|
433
447
|
}
|
|
434
|
-
function
|
|
435
|
-
const [r, n] =
|
|
448
|
+
function xr(t = !1, e) {
|
|
449
|
+
const [r, n] = T(null);
|
|
436
450
|
return { portalRef: X(n, e), portalNode: r, domReady: !t || r };
|
|
437
451
|
}
|
|
438
|
-
function
|
|
439
|
-
const n = t.onLoadedMetadataCapture, o =
|
|
452
|
+
function Pr(t, e, r) {
|
|
453
|
+
const n = t.onLoadedMetadataCapture, o = j(() => Object.assign(() => {
|
|
440
454
|
}, w(l({}, n), { [e]: r })), [n, e, r]);
|
|
441
455
|
return [n == null ? void 0 : n[e], { onLoadedMetadataCapture: o }];
|
|
442
456
|
}
|
|
443
457
|
var ft = !1;
|
|
444
|
-
function
|
|
458
|
+
function Cr() {
|
|
445
459
|
return E(() => {
|
|
446
460
|
ft || (g("mousemove", ge, !0), g("mousedown", A, !0), g("mouseup", A, !0), g("keydown", A, !0), g("scroll", A, !0), ft = !0);
|
|
447
461
|
}, []), y(() => G);
|
|
@@ -461,7 +475,7 @@ function ye(t) {
|
|
|
461
475
|
const e = m.forwardRef((r, n) => t(w(l({}, r), { ref: n })));
|
|
462
476
|
return e.displayName = t.displayName || t.name, e;
|
|
463
477
|
}
|
|
464
|
-
function
|
|
478
|
+
function Tr(t, e) {
|
|
465
479
|
return m.memo(t, e);
|
|
466
480
|
}
|
|
467
481
|
function Ee(t, e) {
|
|
@@ -477,7 +491,7 @@ function we(t) {
|
|
|
477
491
|
const e = (r = {}) => t(r);
|
|
478
492
|
return e.displayName = t.name, e;
|
|
479
493
|
}
|
|
480
|
-
function
|
|
494
|
+
function Fr(t = [], e = []) {
|
|
481
495
|
const r = m.createContext(void 0), n = m.createContext(void 0), o = () => m.useContext(r), u = (c = !1) => {
|
|
482
496
|
const d = m.useContext(n), p = o();
|
|
483
497
|
return c ? d : d || p;
|
|
@@ -502,7 +516,7 @@ function Cr(t = [], e = []) {
|
|
|
502
516
|
) }))
|
|
503
517
|
};
|
|
504
518
|
}
|
|
505
|
-
var he =
|
|
519
|
+
var he = Bt(!0), V = "input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], summary, iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false'])";
|
|
506
520
|
function xe(t) {
|
|
507
521
|
return Number.parseInt(t.getAttribute("tabindex") || "0", 10) < 0;
|
|
508
522
|
}
|
|
@@ -514,7 +528,7 @@ function S(t) {
|
|
|
514
528
|
if (!("form" in t) || !t.form || t.checked || t.type !== "radio") return !0;
|
|
515
529
|
const e = t.form.elements.namedItem(t.name);
|
|
516
530
|
if (!e || !("length" in e)) return !0;
|
|
517
|
-
const r =
|
|
531
|
+
const r = O(t);
|
|
518
532
|
return !r || r === t || !("form" in r) || r.form !== t.form || r.name !== t.name;
|
|
519
533
|
}
|
|
520
534
|
function H(t, e) {
|
|
@@ -545,7 +559,7 @@ function Y(t, e, r) {
|
|
|
545
559
|
}
|
|
546
560
|
}), !o.length && r ? n : o;
|
|
547
561
|
}
|
|
548
|
-
function
|
|
562
|
+
function Or(t, e, r) {
|
|
549
563
|
const [n] = Y(
|
|
550
564
|
t,
|
|
551
565
|
e,
|
|
@@ -554,10 +568,10 @@ function Tr(t, e, r) {
|
|
|
554
568
|
return n || null;
|
|
555
569
|
}
|
|
556
570
|
function Pe(t, e, r, n) {
|
|
557
|
-
const o =
|
|
571
|
+
const o = O(t), u = H(t, e), a = u.indexOf(o), i = u.slice(a + 1);
|
|
558
572
|
return i.find(S) || (r ? u.find(S) : null) || (n ? i[0] : null) || null;
|
|
559
573
|
}
|
|
560
|
-
function
|
|
574
|
+
function _r(t, e) {
|
|
561
575
|
return Pe(
|
|
562
576
|
document.body,
|
|
563
577
|
!1,
|
|
@@ -566,10 +580,10 @@ function Fr(t, e) {
|
|
|
566
580
|
);
|
|
567
581
|
}
|
|
568
582
|
function Ce(t, e, r, n) {
|
|
569
|
-
const o =
|
|
583
|
+
const o = O(t), u = H(t, e).reverse(), a = u.indexOf(o);
|
|
570
584
|
return u.slice(a + 1).find(S) || null || null || null;
|
|
571
585
|
}
|
|
572
|
-
function
|
|
586
|
+
function Ir(t, e) {
|
|
573
587
|
return Ce(
|
|
574
588
|
document.body,
|
|
575
589
|
!1
|
|
@@ -581,33 +595,33 @@ function Te(t) {
|
|
|
581
595
|
return t || null;
|
|
582
596
|
}
|
|
583
597
|
function bt(t) {
|
|
584
|
-
const e =
|
|
598
|
+
const e = O(t);
|
|
585
599
|
if (!e) return !1;
|
|
586
600
|
if (e === t) return !0;
|
|
587
601
|
const r = e.getAttribute("aria-activedescendant");
|
|
588
602
|
return r ? r === t.id : !1;
|
|
589
603
|
}
|
|
590
604
|
function Fe(t) {
|
|
591
|
-
const e =
|
|
605
|
+
const e = O(t);
|
|
592
606
|
if (!e) return !1;
|
|
593
|
-
if (
|
|
607
|
+
if (I(t, e)) return !0;
|
|
594
608
|
const r = e.getAttribute("aria-activedescendant");
|
|
595
609
|
return !r || !("id" in t) ? !1 : r === t.id ? !0 : !!t.querySelector(`#${CSS.escape(r)}`);
|
|
596
610
|
}
|
|
597
|
-
function
|
|
611
|
+
function Oe(t) {
|
|
598
612
|
!Fe(t) && C(t) && t.focus();
|
|
599
613
|
}
|
|
600
|
-
function
|
|
614
|
+
function _e(t) {
|
|
601
615
|
var e;
|
|
602
616
|
const r = (e = t.getAttribute("tabindex")) != null ? e : "";
|
|
603
617
|
t.setAttribute("data-tabindex", r), t.setAttribute("tabindex", "-1");
|
|
604
618
|
}
|
|
605
|
-
function
|
|
619
|
+
function Sr(t, e) {
|
|
606
620
|
const r = Y(t, e);
|
|
607
621
|
for (const n of r)
|
|
608
|
-
|
|
622
|
+
_e(n);
|
|
609
623
|
}
|
|
610
|
-
function
|
|
624
|
+
function Ar(t) {
|
|
611
625
|
const e = t.querySelectorAll("[data-tabindex]"), r = (n) => {
|
|
612
626
|
const o = n.getAttribute("data-tabindex");
|
|
613
627
|
n.removeAttribute("data-tabindex"), o ? n.setAttribute("tabindex", o) : n.removeAttribute("tabindex");
|
|
@@ -616,10 +630,10 @@ function Sr(t) {
|
|
|
616
630
|
for (const n of e)
|
|
617
631
|
r(n);
|
|
618
632
|
}
|
|
619
|
-
function
|
|
620
|
-
"scrollIntoView" in t ? (t.focus({ preventScroll: !0 }), t.scrollIntoView(
|
|
633
|
+
function Dr(t, e) {
|
|
634
|
+
"scrollIntoView" in t ? (t.focus({ preventScroll: !0 }), t.scrollIntoView(B({ block: "nearest", inline: "nearest" }, e))) : t.focus();
|
|
621
635
|
}
|
|
622
|
-
var
|
|
636
|
+
var Ie = "div", pt = de(), Se = [
|
|
623
637
|
"text",
|
|
624
638
|
"search",
|
|
625
639
|
"url",
|
|
@@ -634,7 +648,7 @@ var Se = "div", pt = de(), Ie = [
|
|
|
634
648
|
"datetime",
|
|
635
649
|
"datetime-local"
|
|
636
650
|
], Tt = Symbol("safariFocusAncestor");
|
|
637
|
-
function
|
|
651
|
+
function Rr(t) {
|
|
638
652
|
return t ? !!t[Tt] : !1;
|
|
639
653
|
}
|
|
640
654
|
function vt(t, e) {
|
|
@@ -642,7 +656,7 @@ function vt(t, e) {
|
|
|
642
656
|
}
|
|
643
657
|
function Ae(t) {
|
|
644
658
|
const { tagName: e, readOnly: r, type: n } = t;
|
|
645
|
-
return e === "TEXTAREA" && !r || e === "SELECT" && !r ? !0 : e === "INPUT" && !r ?
|
|
659
|
+
return e === "TEXTAREA" && !r || e === "SELECT" && !r ? !0 : e === "INPUT" && !r ? Se.includes(n) : !!(t.isContentEditable || t.getAttribute("role") === "combobox" && t.dataset.name);
|
|
646
660
|
}
|
|
647
661
|
function De(t) {
|
|
648
662
|
return "labels" in t ? t.labels : null;
|
|
@@ -659,7 +673,7 @@ function Ne(t) {
|
|
|
659
673
|
function Me(t, e, r, n, o) {
|
|
660
674
|
return t ? e ? r && !n ? -1 : void 0 : r ? o : o || 0 : o;
|
|
661
675
|
}
|
|
662
|
-
function
|
|
676
|
+
function k(t, e) {
|
|
663
677
|
return y((r) => {
|
|
664
678
|
t == null || t(r), !r.defaultPrevented && e && (r.stopPropagation(), r.preventDefault());
|
|
665
679
|
});
|
|
@@ -702,7 +716,7 @@ var Ke = we(
|
|
|
702
716
|
x.removeEventListener("mouseup", v);
|
|
703
717
|
};
|
|
704
718
|
}, [n]);
|
|
705
|
-
const c = n && Qt(i), d = !!c && !o, [p, h] =
|
|
719
|
+
const c = n && Qt(i), d = !!c && !o, [p, h] = T(!1);
|
|
706
720
|
E(() => {
|
|
707
721
|
n && d && p && h(!1);
|
|
708
722
|
}, [n, d, p]), E(() => {
|
|
@@ -714,13 +728,13 @@ var Ke = we(
|
|
|
714
728
|
});
|
|
715
729
|
return f.observe(s), () => f.disconnect();
|
|
716
730
|
}, [n, p]);
|
|
717
|
-
const Ft =
|
|
731
|
+
const Ft = k(
|
|
718
732
|
i.onKeyPressCapture,
|
|
719
733
|
c
|
|
720
|
-
),
|
|
734
|
+
), Ot = k(
|
|
721
735
|
i.onMouseDownCapture,
|
|
722
736
|
c
|
|
723
|
-
),
|
|
737
|
+
), _t = k(i.onClickCapture, c), J = i.onMouseDown, It = y((s) => {
|
|
724
738
|
if (J == null || J(s), s.defaultPrevented || !n) return;
|
|
725
739
|
const f = s.currentTarget;
|
|
726
740
|
if (!pt || be(s) || !ue(f) && !mt(f)) return;
|
|
@@ -731,13 +745,13 @@ var Ke = we(
|
|
|
731
745
|
f.addEventListener("focusin", x, Lt);
|
|
732
746
|
const ot = Te(f.parentElement);
|
|
733
747
|
vt(ot, !0), K(f, "mouseup", () => {
|
|
734
|
-
f.removeEventListener("focusin", x, !0), vt(ot, !1), !v &&
|
|
748
|
+
f.removeEventListener("focusin", x, !0), vt(ot, !1), !v && Oe(f);
|
|
735
749
|
});
|
|
736
750
|
}), Q = (s, f) => {
|
|
737
751
|
if (f && (s.currentTarget = f), !n) return;
|
|
738
752
|
const v = s.currentTarget;
|
|
739
753
|
v && bt(v) && (a == null || a(s), !s.defaultPrevented && (v.dataset.focusVisible = "true", h(!0)));
|
|
740
|
-
}, Z = i.onKeyDownCapture,
|
|
754
|
+
}, Z = i.onKeyDownCapture, St = y((s) => {
|
|
741
755
|
if (Z == null || Z(s), s.defaultPrevented || !n || p || s.metaKey || s.altKey || s.ctrlKey || !it(s)) return;
|
|
742
756
|
const f = s.currentTarget;
|
|
743
757
|
K(f, "focusout", () => Q(s, f));
|
|
@@ -751,11 +765,11 @@ var Ke = we(
|
|
|
751
765
|
z || Ae(s.target) ? K(s.target, "focusout", v) : h(!1);
|
|
752
766
|
}), et = i.onBlur, Dt = y((s) => {
|
|
753
767
|
et == null || et(s), n && pe(s) && (s.currentTarget.removeAttribute("data-focus-visible"), h(!1));
|
|
754
|
-
}), Rt =
|
|
768
|
+
}), Rt = $t(he), Nt = y((s) => {
|
|
755
769
|
n && u && s && Rt && queueMicrotask(() => {
|
|
756
770
|
bt(s) || C(s) && s.focus();
|
|
757
771
|
});
|
|
758
|
-
}), rt = ve(b), Mt = n && Re(rt), nt = n && Ne(rt), L = i.style, Vt =
|
|
772
|
+
}), rt = ve(b), Mt = n && Re(rt), nt = n && Ne(rt), L = i.style, Vt = j(() => d ? l({ pointerEvents: "none" }, L) : L, [d, L]);
|
|
759
773
|
return i = w(l({
|
|
760
774
|
"data-focus-visible": n && p || void 0,
|
|
761
775
|
"data-autofocus": u || void 0,
|
|
@@ -774,10 +788,10 @@ var Ke = we(
|
|
|
774
788
|
// TODO: Test Focusable contentEditable.
|
|
775
789
|
contentEditable: c ? void 0 : i.contentEditable,
|
|
776
790
|
onKeyPressCapture: Ft,
|
|
777
|
-
onClickCapture:
|
|
778
|
-
onMouseDownCapture:
|
|
779
|
-
onMouseDown:
|
|
780
|
-
onKeyDownCapture:
|
|
791
|
+
onClickCapture: _t,
|
|
792
|
+
onMouseDownCapture: Ot,
|
|
793
|
+
onMouseDown: It,
|
|
794
|
+
onKeyDownCapture: St,
|
|
781
795
|
onFocusCapture: At,
|
|
782
796
|
onBlur: Dt
|
|
783
797
|
}), Zt(i);
|
|
@@ -785,90 +799,92 @@ var Ke = we(
|
|
|
785
799
|
);
|
|
786
800
|
ye(function(e) {
|
|
787
801
|
const r = Ke(e);
|
|
788
|
-
return Ee(
|
|
802
|
+
return Ee(Ie, r);
|
|
789
803
|
});
|
|
790
804
|
export {
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
805
|
+
br as $,
|
|
806
|
+
Yt as A,
|
|
807
|
+
B,
|
|
808
|
+
yr as C,
|
|
809
|
+
fr as D,
|
|
810
|
+
Qe as E,
|
|
811
|
+
Qt as F,
|
|
812
|
+
or as G,
|
|
813
|
+
ae as H,
|
|
814
|
+
cr as I,
|
|
815
|
+
ar as J,
|
|
816
|
+
pr as K,
|
|
817
|
+
We as L,
|
|
818
|
+
Be as M,
|
|
819
|
+
qe as N,
|
|
820
|
+
tr as O,
|
|
821
|
+
Pr as P,
|
|
822
|
+
ve as Q,
|
|
823
|
+
ue as R,
|
|
824
|
+
Ge as S,
|
|
825
|
+
He as T,
|
|
826
|
+
Je as U,
|
|
827
|
+
Ue as V,
|
|
828
|
+
$e as W,
|
|
829
|
+
Ye as X,
|
|
830
|
+
vr as Y,
|
|
831
|
+
Ke as Z,
|
|
818
832
|
ht as _,
|
|
819
833
|
l as a,
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
834
|
+
sr as a0,
|
|
835
|
+
K as a1,
|
|
836
|
+
Er as a2,
|
|
837
|
+
te as a3,
|
|
838
|
+
pe as a4,
|
|
839
|
+
_r as a5,
|
|
840
|
+
Ir as a6,
|
|
841
|
+
Ar as a7,
|
|
842
|
+
Sr as a8,
|
|
843
|
+
he as a9,
|
|
844
|
+
g as aa,
|
|
845
|
+
ie as ab,
|
|
846
|
+
Rr as ac,
|
|
847
|
+
Ct as ad,
|
|
848
|
+
ir as ae,
|
|
849
|
+
Y as af,
|
|
850
|
+
xr as ag,
|
|
851
|
+
O as ah,
|
|
852
|
+
Or as ai,
|
|
853
|
+
C as aj,
|
|
854
|
+
Oe as ak,
|
|
855
|
+
de as al,
|
|
856
|
+
mr as am,
|
|
857
|
+
Dr as an,
|
|
858
|
+
lr as ao,
|
|
859
|
+
dr as ap,
|
|
860
|
+
be as aq,
|
|
847
861
|
er as ar,
|
|
848
|
-
|
|
862
|
+
nr as as,
|
|
863
|
+
rr as at,
|
|
864
|
+
ce as au,
|
|
849
865
|
Ee as b,
|
|
850
866
|
we as c,
|
|
851
867
|
w as d,
|
|
852
|
-
|
|
868
|
+
Fr as e,
|
|
853
869
|
ye as f,
|
|
854
870
|
_ as g,
|
|
855
871
|
q as h,
|
|
856
|
-
|
|
872
|
+
ze as i,
|
|
857
873
|
it as j,
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
874
|
+
hr as k,
|
|
875
|
+
gr as l,
|
|
876
|
+
M as m,
|
|
877
|
+
Xe as n,
|
|
878
|
+
Cr as o,
|
|
879
|
+
wr as p,
|
|
880
|
+
Fe as q,
|
|
865
881
|
Zt as r,
|
|
866
|
-
|
|
867
|
-
|
|
882
|
+
ur as s,
|
|
883
|
+
bt as t,
|
|
868
884
|
y as u,
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
885
|
+
X as v,
|
|
886
|
+
I as w,
|
|
887
|
+
$ as x,
|
|
888
|
+
Tr as y,
|
|
889
|
+
Ze as z
|
|
874
890
|
};
|