@sps-woodland/focused-task 8.42.0 → 8.42.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +1048 -691
- package/lib/index.umd.cjs +3 -3
- package/lib/style.css +1 -1
- package/package.json +7 -7
package/lib/index.js
CHANGED
|
@@ -1,120 +1,115 @@
|
|
|
1
|
-
import { Metadata as
|
|
2
|
-
import { Button as
|
|
3
|
-
import * as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import { code as
|
|
7
|
-
const
|
|
1
|
+
import { Metadata as Ge, cl as ie, combineEventHandlers as Ce, useChildTestIdAttrBuilder as ht, selectChildren as Et, contentOf as Fe } from "@sps-woodland/core";
|
|
2
|
+
import { Button as wt } from "@sps-woodland/buttons";
|
|
3
|
+
import * as v from "react";
|
|
4
|
+
import m, { useState as Z, useRef as h, useCallback as N, useContext as H, useEffect as _, useReducer as gt, useMemo as U, createContext as yt } from "react";
|
|
5
|
+
import Tt from "react-dom";
|
|
6
|
+
import { code as Pe } from "@spscommerce/utils";
|
|
7
|
+
const g = typeof document < "u" ? m.useLayoutEffect : () => {
|
|
8
8
|
};
|
|
9
|
-
function
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
]), S((...n) => {
|
|
16
|
-
const r = t.current;
|
|
17
|
-
return r?.(...n);
|
|
18
|
-
}, []);
|
|
19
|
-
}
|
|
20
|
-
function ot(e) {
|
|
21
|
-
let [t, n] = j(e), r = y(null), o = K(() => {
|
|
22
|
-
if (!r.current) return;
|
|
23
|
-
let a = r.current.next();
|
|
24
|
-
if (a.done) {
|
|
25
|
-
r.current = null;
|
|
9
|
+
function Nt(e) {
|
|
10
|
+
let [t, n] = Z(e), r = h(t), o = h(null), i = h(() => {
|
|
11
|
+
if (!o.current) return;
|
|
12
|
+
let l = o.current.next();
|
|
13
|
+
if (l.done) {
|
|
14
|
+
o.current = null;
|
|
26
15
|
return;
|
|
27
16
|
}
|
|
28
|
-
|
|
17
|
+
r.current === l.value ? i.current() : n(l.value);
|
|
29
18
|
});
|
|
30
|
-
|
|
31
|
-
r.current &&
|
|
32
|
-
});
|
|
33
|
-
let i = K((a) => {
|
|
34
|
-
r.current = a(t), o();
|
|
19
|
+
g(() => {
|
|
20
|
+
r.current = t, o.current && i.current();
|
|
35
21
|
});
|
|
22
|
+
let a = N((l) => {
|
|
23
|
+
o.current = l(r.current), i.current();
|
|
24
|
+
}, [
|
|
25
|
+
i
|
|
26
|
+
]);
|
|
36
27
|
return [
|
|
37
28
|
t,
|
|
38
|
-
|
|
29
|
+
a
|
|
39
30
|
];
|
|
40
31
|
}
|
|
41
|
-
const
|
|
32
|
+
const ae = {
|
|
42
33
|
prefix: String(Math.round(Math.random() * 1e10)),
|
|
43
34
|
current: 0
|
|
44
|
-
},
|
|
45
|
-
let
|
|
46
|
-
function
|
|
47
|
-
let t =
|
|
35
|
+
}, ze = /* @__PURE__ */ m.createContext(ae), kt = /* @__PURE__ */ m.createContext(!1);
|
|
36
|
+
let St = !!(typeof window < "u" && window.document && window.document.createElement), pe = /* @__PURE__ */ new WeakMap();
|
|
37
|
+
function xt(e = !1) {
|
|
38
|
+
let t = H(ze), n = h(null);
|
|
48
39
|
if (n.current === null && !e) {
|
|
49
40
|
var r, o;
|
|
50
|
-
let i = (o =
|
|
41
|
+
let i = (o = m.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED) === null || o === void 0 || (r = o.ReactCurrentOwner) === null || r === void 0 ? void 0 : r.current;
|
|
51
42
|
if (i) {
|
|
52
|
-
let a =
|
|
53
|
-
a == null ?
|
|
43
|
+
let a = pe.get(i);
|
|
44
|
+
a == null ? pe.set(i, {
|
|
54
45
|
id: t.current,
|
|
55
46
|
state: i.memoizedState
|
|
56
|
-
}) : i.memoizedState !== a.state && (t.current = a.id,
|
|
47
|
+
}) : i.memoizedState !== a.state && (t.current = a.id, pe.delete(i));
|
|
57
48
|
}
|
|
58
49
|
n.current = ++t.current;
|
|
59
50
|
}
|
|
60
51
|
return n.current;
|
|
61
52
|
}
|
|
62
|
-
function
|
|
63
|
-
let t =
|
|
64
|
-
t ===
|
|
65
|
-
let n =
|
|
53
|
+
function Lt(e) {
|
|
54
|
+
let t = H(ze);
|
|
55
|
+
t === ae && !St && process.env.NODE_ENV !== "production" && console.warn("When server rendering, you must wrap your application in an <SSRProvider> to ensure consistent ids are generated between the client and server.");
|
|
56
|
+
let n = xt(!!e), r = t === ae && process.env.NODE_ENV === "test" ? "react-aria" : `react-aria${t.prefix}`;
|
|
66
57
|
return e || `${r}-${n}`;
|
|
67
58
|
}
|
|
68
|
-
function
|
|
69
|
-
let t =
|
|
59
|
+
function _t(e) {
|
|
60
|
+
let t = m.useId(), [n] = Z(Ue()), r = n || process.env.NODE_ENV === "test" ? "react-aria" : `react-aria${ae.prefix}`;
|
|
70
61
|
return e || `${r}-${t}`;
|
|
71
62
|
}
|
|
72
|
-
const
|
|
73
|
-
function
|
|
63
|
+
const Ct = typeof m.useId == "function" ? _t : Lt;
|
|
64
|
+
function Ft() {
|
|
74
65
|
return !1;
|
|
75
66
|
}
|
|
76
|
-
function
|
|
67
|
+
function Pt() {
|
|
77
68
|
return !0;
|
|
78
69
|
}
|
|
79
|
-
function
|
|
70
|
+
function Ot(e) {
|
|
80
71
|
return () => {
|
|
81
72
|
};
|
|
82
73
|
}
|
|
83
|
-
function
|
|
84
|
-
return typeof
|
|
85
|
-
}
|
|
86
|
-
let
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
74
|
+
function Ue() {
|
|
75
|
+
return typeof m.useSyncExternalStore == "function" ? m.useSyncExternalStore(Ot, Ft, Pt) : H(kt);
|
|
76
|
+
}
|
|
77
|
+
let Mt = !!(typeof window < "u" && window.document && window.document.createElement), B = /* @__PURE__ */ new Map(), G;
|
|
78
|
+
typeof FinalizationRegistry < "u" && (G = new FinalizationRegistry((e) => {
|
|
79
|
+
B.delete(e);
|
|
80
|
+
}));
|
|
81
|
+
function Je(e) {
|
|
82
|
+
let [t, n] = Z(e), r = h(null), o = Ct(t), i = h(null);
|
|
83
|
+
if (G && G.register(i, o), Mt) {
|
|
84
|
+
const a = B.get(o);
|
|
85
|
+
a && !a.includes(r) ? a.push(r) : B.set(o, [
|
|
86
|
+
r
|
|
87
|
+
]);
|
|
88
|
+
}
|
|
89
|
+
return g(() => {
|
|
97
90
|
let a = o;
|
|
98
91
|
return () => {
|
|
99
|
-
|
|
92
|
+
G && G.unregister(i), B.delete(a);
|
|
100
93
|
};
|
|
101
94
|
}, [
|
|
102
95
|
o
|
|
103
|
-
]),
|
|
96
|
+
]), _(() => {
|
|
104
97
|
let a = r.current;
|
|
105
|
-
a && (
|
|
98
|
+
return a && n(a), () => {
|
|
99
|
+
a && (r.current = null);
|
|
100
|
+
};
|
|
106
101
|
}), o;
|
|
107
102
|
}
|
|
108
|
-
function
|
|
103
|
+
function Rt(e, t) {
|
|
109
104
|
if (e === t) return e;
|
|
110
|
-
let n =
|
|
105
|
+
let n = B.get(e);
|
|
111
106
|
if (n)
|
|
112
|
-
return n.forEach((o) => o
|
|
113
|
-
let r =
|
|
114
|
-
return r ? (r.forEach((o) => o
|
|
107
|
+
return n.forEach((o) => o.current = t), t;
|
|
108
|
+
let r = B.get(t);
|
|
109
|
+
return r ? (r.forEach((o) => o.current = e), e) : t;
|
|
115
110
|
}
|
|
116
|
-
function
|
|
117
|
-
let t =
|
|
111
|
+
function Dt(e = []) {
|
|
112
|
+
let t = Je(), [n, r] = Nt(t), o = N(() => {
|
|
118
113
|
r(function* () {
|
|
119
114
|
yield t, yield document.getElementById(t) ? t : void 0;
|
|
120
115
|
});
|
|
@@ -122,35 +117,212 @@ function mt(e = []) {
|
|
|
122
117
|
t,
|
|
123
118
|
r
|
|
124
119
|
]);
|
|
125
|
-
return
|
|
120
|
+
return g(o, [
|
|
126
121
|
t,
|
|
127
122
|
o,
|
|
128
123
|
...e
|
|
129
124
|
]), n;
|
|
130
125
|
}
|
|
131
|
-
function
|
|
126
|
+
function le(...e) {
|
|
132
127
|
return (...t) => {
|
|
133
128
|
for (let n of e) typeof n == "function" && n(...t);
|
|
134
129
|
};
|
|
135
130
|
}
|
|
136
|
-
const
|
|
131
|
+
const w = (e) => {
|
|
137
132
|
var t;
|
|
138
133
|
return (t = e?.ownerDocument) !== null && t !== void 0 ? t : document;
|
|
139
|
-
},
|
|
140
|
-
function
|
|
134
|
+
}, X = (e) => e && "window" in e && e.window === e ? e : w(e).defaultView || window;
|
|
135
|
+
function At(e) {
|
|
136
|
+
return e !== null && typeof e == "object" && "nodeType" in e && typeof e.nodeType == "number";
|
|
137
|
+
}
|
|
138
|
+
function It(e) {
|
|
139
|
+
return At(e) && e.nodeType === Node.DOCUMENT_FRAGMENT_NODE && "host" in e;
|
|
140
|
+
}
|
|
141
|
+
let Wt = !1;
|
|
142
|
+
function ue() {
|
|
143
|
+
return Wt;
|
|
144
|
+
}
|
|
145
|
+
function F(e, t) {
|
|
146
|
+
if (!ue()) return t && e ? e.contains(t) : !1;
|
|
147
|
+
if (!e || !t) return !1;
|
|
148
|
+
let n = t;
|
|
149
|
+
for (; n !== null; ) {
|
|
150
|
+
if (n === e) return !0;
|
|
151
|
+
n.tagName === "SLOT" && n.assignedSlot ? n = n.assignedSlot.parentNode : It(n) ? n = n.host : n = n.parentNode;
|
|
152
|
+
}
|
|
153
|
+
return !1;
|
|
154
|
+
}
|
|
155
|
+
const T = (e = document) => {
|
|
156
|
+
var t;
|
|
157
|
+
if (!ue()) return e.activeElement;
|
|
158
|
+
let n = e.activeElement;
|
|
159
|
+
for (; n && "shadowRoot" in n && (!((t = n.shadowRoot) === null || t === void 0) && t.activeElement); ) n = n.shadowRoot.activeElement;
|
|
160
|
+
return n;
|
|
161
|
+
};
|
|
162
|
+
function y(e) {
|
|
163
|
+
if (ue() && e.target instanceof Element && e.target.shadowRoot) {
|
|
164
|
+
var t, n;
|
|
165
|
+
if ("composedPath" in e) return (t = e.composedPath()[0]) !== null && t !== void 0 ? t : null;
|
|
166
|
+
if ("composedPath" in e.nativeEvent) return (n = e.nativeEvent.composedPath()[0]) !== null && n !== void 0 ? n : null;
|
|
167
|
+
}
|
|
168
|
+
return e.target;
|
|
169
|
+
}
|
|
170
|
+
class Kt {
|
|
171
|
+
get currentNode() {
|
|
172
|
+
return this._currentNode;
|
|
173
|
+
}
|
|
174
|
+
set currentNode(t) {
|
|
175
|
+
if (!F(this.root, t)) throw new Error("Cannot set currentNode to a node that is not contained by the root node.");
|
|
176
|
+
const n = [];
|
|
177
|
+
let r = t, o = t;
|
|
178
|
+
for (this._currentNode = t; r && r !== this.root; ) if (r.nodeType === Node.DOCUMENT_FRAGMENT_NODE) {
|
|
179
|
+
const a = r, l = this._doc.createTreeWalker(a, this.whatToShow, {
|
|
180
|
+
acceptNode: this._acceptNode
|
|
181
|
+
});
|
|
182
|
+
n.push(l), l.currentNode = o, this._currentSetFor.add(l), r = o = a.host;
|
|
183
|
+
} else r = r.parentNode;
|
|
184
|
+
const i = this._doc.createTreeWalker(this.root, this.whatToShow, {
|
|
185
|
+
acceptNode: this._acceptNode
|
|
186
|
+
});
|
|
187
|
+
n.push(i), i.currentNode = o, this._currentSetFor.add(i), this._walkerStack = n;
|
|
188
|
+
}
|
|
189
|
+
get doc() {
|
|
190
|
+
return this._doc;
|
|
191
|
+
}
|
|
192
|
+
firstChild() {
|
|
193
|
+
let t = this.currentNode, n = this.nextNode();
|
|
194
|
+
return F(t, n) ? (n && (this.currentNode = n), n) : (this.currentNode = t, null);
|
|
195
|
+
}
|
|
196
|
+
lastChild() {
|
|
197
|
+
let n = this._walkerStack[0].lastChild();
|
|
198
|
+
return n && (this.currentNode = n), n;
|
|
199
|
+
}
|
|
200
|
+
nextNode() {
|
|
201
|
+
const t = this._walkerStack[0].nextNode();
|
|
202
|
+
if (t) {
|
|
203
|
+
if (t.shadowRoot) {
|
|
204
|
+
var n;
|
|
205
|
+
let o;
|
|
206
|
+
if (typeof this.filter == "function" ? o = this.filter(t) : !((n = this.filter) === null || n === void 0) && n.acceptNode && (o = this.filter.acceptNode(t)), o === NodeFilter.FILTER_ACCEPT)
|
|
207
|
+
return this.currentNode = t, t;
|
|
208
|
+
let i = this.nextNode();
|
|
209
|
+
return i && (this.currentNode = i), i;
|
|
210
|
+
}
|
|
211
|
+
return t && (this.currentNode = t), t;
|
|
212
|
+
} else if (this._walkerStack.length > 1) {
|
|
213
|
+
this._walkerStack.shift();
|
|
214
|
+
let r = this.nextNode();
|
|
215
|
+
return r && (this.currentNode = r), r;
|
|
216
|
+
} else return null;
|
|
217
|
+
}
|
|
218
|
+
previousNode() {
|
|
219
|
+
const t = this._walkerStack[0];
|
|
220
|
+
if (t.currentNode === t.root) {
|
|
221
|
+
if (this._currentSetFor.has(t))
|
|
222
|
+
if (this._currentSetFor.delete(t), this._walkerStack.length > 1) {
|
|
223
|
+
this._walkerStack.shift();
|
|
224
|
+
let o = this.previousNode();
|
|
225
|
+
return o && (this.currentNode = o), o;
|
|
226
|
+
} else return null;
|
|
227
|
+
return null;
|
|
228
|
+
}
|
|
229
|
+
const n = t.previousNode();
|
|
230
|
+
if (n) {
|
|
231
|
+
if (n.shadowRoot) {
|
|
232
|
+
var r;
|
|
233
|
+
let i;
|
|
234
|
+
if (typeof this.filter == "function" ? i = this.filter(n) : !((r = this.filter) === null || r === void 0) && r.acceptNode && (i = this.filter.acceptNode(n)), i === NodeFilter.FILTER_ACCEPT)
|
|
235
|
+
return n && (this.currentNode = n), n;
|
|
236
|
+
let a = this.lastChild();
|
|
237
|
+
return a && (this.currentNode = a), a;
|
|
238
|
+
}
|
|
239
|
+
return n && (this.currentNode = n), n;
|
|
240
|
+
} else if (this._walkerStack.length > 1) {
|
|
241
|
+
this._walkerStack.shift();
|
|
242
|
+
let o = this.previousNode();
|
|
243
|
+
return o && (this.currentNode = o), o;
|
|
244
|
+
} else return null;
|
|
245
|
+
}
|
|
246
|
+
/**
|
|
247
|
+
* @deprecated
|
|
248
|
+
*/
|
|
249
|
+
nextSibling() {
|
|
250
|
+
return null;
|
|
251
|
+
}
|
|
252
|
+
/**
|
|
253
|
+
* @deprecated
|
|
254
|
+
*/
|
|
255
|
+
previousSibling() {
|
|
256
|
+
return null;
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* @deprecated
|
|
260
|
+
*/
|
|
261
|
+
parentNode() {
|
|
262
|
+
return null;
|
|
263
|
+
}
|
|
264
|
+
constructor(t, n, r, o) {
|
|
265
|
+
this._walkerStack = [], this._currentSetFor = /* @__PURE__ */ new Set(), this._acceptNode = (a) => {
|
|
266
|
+
if (a.nodeType === Node.ELEMENT_NODE) {
|
|
267
|
+
const s = a.shadowRoot;
|
|
268
|
+
if (s) {
|
|
269
|
+
const c = this._doc.createTreeWalker(s, this.whatToShow, {
|
|
270
|
+
acceptNode: this._acceptNode
|
|
271
|
+
});
|
|
272
|
+
return this._walkerStack.unshift(c), NodeFilter.FILTER_ACCEPT;
|
|
273
|
+
} else {
|
|
274
|
+
var l;
|
|
275
|
+
if (typeof this.filter == "function") return this.filter(a);
|
|
276
|
+
if (!((l = this.filter) === null || l === void 0) && l.acceptNode) return this.filter.acceptNode(a);
|
|
277
|
+
if (this.filter === null) return NodeFilter.FILTER_ACCEPT;
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
return NodeFilter.FILTER_SKIP;
|
|
281
|
+
}, this._doc = t, this.root = n, this.filter = o ?? null, this.whatToShow = r ?? NodeFilter.SHOW_ALL, this._currentNode = n, this._walkerStack.unshift(t.createTreeWalker(n, r, this._acceptNode));
|
|
282
|
+
const i = n.shadowRoot;
|
|
283
|
+
if (i) {
|
|
284
|
+
const a = this._doc.createTreeWalker(i, this.whatToShow, {
|
|
285
|
+
acceptNode: this._acceptNode
|
|
286
|
+
});
|
|
287
|
+
this._walkerStack.unshift(a);
|
|
288
|
+
}
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
function Vt(e, t, n, r) {
|
|
292
|
+
return ue() ? new Kt(e, t, n, r) : e.createTreeWalker(t, n, r);
|
|
293
|
+
}
|
|
294
|
+
function Bt(...e) {
|
|
295
|
+
return e.length === 1 && e[0] ? e[0] : (t) => {
|
|
296
|
+
let n = !1;
|
|
297
|
+
const r = e.map((o) => {
|
|
298
|
+
const i = Oe(o, t);
|
|
299
|
+
return n || (n = typeof i == "function"), i;
|
|
300
|
+
});
|
|
301
|
+
if (n) return () => {
|
|
302
|
+
r.forEach((o, i) => {
|
|
303
|
+
typeof o == "function" ? o() : Oe(e[i], null);
|
|
304
|
+
});
|
|
305
|
+
};
|
|
306
|
+
};
|
|
307
|
+
}
|
|
308
|
+
function Oe(e, t) {
|
|
309
|
+
if (typeof e == "function") return e(t);
|
|
310
|
+
e != null && (e.current = t);
|
|
311
|
+
}
|
|
312
|
+
function Xe(e) {
|
|
141
313
|
var t, n, r = "";
|
|
142
314
|
if (typeof e == "string" || typeof e == "number") r += e;
|
|
143
315
|
else if (typeof e == "object") if (Array.isArray(e)) {
|
|
144
316
|
var o = e.length;
|
|
145
|
-
for (t = 0; t < o; t++) e[t] && (n =
|
|
317
|
+
for (t = 0; t < o; t++) e[t] && (n = Xe(e[t])) && (r && (r += " "), r += n);
|
|
146
318
|
} else for (n in e) e[n] && (r && (r += " "), r += n);
|
|
147
319
|
return r;
|
|
148
320
|
}
|
|
149
|
-
function
|
|
150
|
-
for (var e, t, n = 0, r = "", o = arguments.length; n < o; n++) (e = arguments[n]) && (t =
|
|
321
|
+
function Ht() {
|
|
322
|
+
for (var e, t, n = 0, r = "", o = arguments.length; n < o; n++) (e = arguments[n]) && (t = Xe(e)) && (r && (r += " "), r += t);
|
|
151
323
|
return r;
|
|
152
324
|
}
|
|
153
|
-
function
|
|
325
|
+
function jt(...e) {
|
|
154
326
|
let t = {
|
|
155
327
|
...e[0]
|
|
156
328
|
};
|
|
@@ -161,19 +333,19 @@ function ht(...e) {
|
|
|
161
333
|
typeof i == "function" && typeof a == "function" && // This is a lot faster than a regex.
|
|
162
334
|
o[0] === "o" && o[1] === "n" && o.charCodeAt(2) >= /* 'A' */
|
|
163
335
|
65 && o.charCodeAt(2) <= /* 'Z' */
|
|
164
|
-
90 ? t[o] =
|
|
336
|
+
90 ? t[o] = le(i, a) : (o === "className" || o === "UNSAFE_className") && typeof i == "string" && typeof a == "string" ? t[o] = Ht(i, a) : o === "id" && i && a ? t.id = Rt(i, a) : o === "ref" && i && a ? t.ref = Bt(i, a) : t[o] = a !== void 0 ? a : i;
|
|
165
337
|
}
|
|
166
338
|
}
|
|
167
339
|
return t;
|
|
168
340
|
}
|
|
169
|
-
const
|
|
341
|
+
const qt = /* @__PURE__ */ new Set([
|
|
170
342
|
"id"
|
|
171
|
-
]),
|
|
343
|
+
]), Gt = /* @__PURE__ */ new Set([
|
|
172
344
|
"aria-label",
|
|
173
345
|
"aria-labelledby",
|
|
174
346
|
"aria-describedby",
|
|
175
347
|
"aria-details"
|
|
176
|
-
]),
|
|
348
|
+
]), zt = /* @__PURE__ */ new Set([
|
|
177
349
|
"href",
|
|
178
350
|
"hrefLang",
|
|
179
351
|
"target",
|
|
@@ -181,37 +353,78 @@ const Et = /* @__PURE__ */ new Set([
|
|
|
181
353
|
"download",
|
|
182
354
|
"ping",
|
|
183
355
|
"referrerPolicy"
|
|
184
|
-
]),
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
356
|
+
]), Ut = /* @__PURE__ */ new Set([
|
|
357
|
+
"dir",
|
|
358
|
+
"lang",
|
|
359
|
+
"hidden",
|
|
360
|
+
"inert",
|
|
361
|
+
"translate"
|
|
362
|
+
]), Me = /* @__PURE__ */ new Set([
|
|
363
|
+
"onClick",
|
|
364
|
+
"onAuxClick",
|
|
365
|
+
"onContextMenu",
|
|
366
|
+
"onDoubleClick",
|
|
367
|
+
"onMouseDown",
|
|
368
|
+
"onMouseEnter",
|
|
369
|
+
"onMouseLeave",
|
|
370
|
+
"onMouseMove",
|
|
371
|
+
"onMouseOut",
|
|
372
|
+
"onMouseOver",
|
|
373
|
+
"onMouseUp",
|
|
374
|
+
"onTouchCancel",
|
|
375
|
+
"onTouchEnd",
|
|
376
|
+
"onTouchMove",
|
|
377
|
+
"onTouchStart",
|
|
378
|
+
"onPointerDown",
|
|
379
|
+
"onPointerMove",
|
|
380
|
+
"onPointerUp",
|
|
381
|
+
"onPointerCancel",
|
|
382
|
+
"onPointerEnter",
|
|
383
|
+
"onPointerLeave",
|
|
384
|
+
"onPointerOver",
|
|
385
|
+
"onPointerOut",
|
|
386
|
+
"onGotPointerCapture",
|
|
387
|
+
"onLostPointerCapture",
|
|
388
|
+
"onScroll",
|
|
389
|
+
"onWheel",
|
|
390
|
+
"onAnimationStart",
|
|
391
|
+
"onAnimationEnd",
|
|
392
|
+
"onAnimationIteration",
|
|
393
|
+
"onTransitionCancel",
|
|
394
|
+
"onTransitionEnd",
|
|
395
|
+
"onTransitionRun",
|
|
396
|
+
"onTransitionStart"
|
|
397
|
+
]), Jt = /^(data-.*)$/;
|
|
398
|
+
function Xt(e, t = {}) {
|
|
399
|
+
let { labelable: n, isLink: r, global: o, events: i = o, propNames: a } = t, l = {};
|
|
400
|
+
for (const s in e) Object.prototype.hasOwnProperty.call(e, s) && (qt.has(s) || n && Gt.has(s) || r && zt.has(s) || o && Ut.has(s) || i && (Me.has(s) || s.endsWith("Capture") && Me.has(s.slice(0, -7))) || a?.has(s) || Jt.test(s)) && (l[s] = e[s]);
|
|
401
|
+
return l;
|
|
402
|
+
}
|
|
403
|
+
function he(e) {
|
|
404
|
+
if (Yt()) e.focus({
|
|
192
405
|
preventScroll: !0
|
|
193
406
|
});
|
|
194
407
|
else {
|
|
195
|
-
let t =
|
|
196
|
-
e.focus(),
|
|
408
|
+
let t = Qt(e);
|
|
409
|
+
e.focus(), Zt(t);
|
|
197
410
|
}
|
|
198
411
|
}
|
|
199
|
-
let
|
|
200
|
-
function
|
|
201
|
-
if (
|
|
202
|
-
|
|
412
|
+
let ne = null;
|
|
413
|
+
function Yt() {
|
|
414
|
+
if (ne == null) {
|
|
415
|
+
ne = !1;
|
|
203
416
|
try {
|
|
204
417
|
document.createElement("div").focus({
|
|
205
418
|
get preventScroll() {
|
|
206
|
-
return
|
|
419
|
+
return ne = !0, !0;
|
|
207
420
|
}
|
|
208
421
|
});
|
|
209
422
|
} catch {
|
|
210
423
|
}
|
|
211
424
|
}
|
|
212
|
-
return
|
|
425
|
+
return ne;
|
|
213
426
|
}
|
|
214
|
-
function
|
|
427
|
+
function Qt(e) {
|
|
215
428
|
let t = e.parentNode, n = [], r = document.scrollingElement || document.documentElement;
|
|
216
429
|
for (; t instanceof HTMLElement && t !== r; )
|
|
217
430
|
(t.offsetHeight < t.scrollHeight || t.offsetWidth < t.scrollWidth) && n.push({
|
|
@@ -225,152 +438,270 @@ function kt(e) {
|
|
|
225
438
|
scrollLeft: r.scrollLeft
|
|
226
439
|
}), n;
|
|
227
440
|
}
|
|
228
|
-
function
|
|
441
|
+
function Zt(e) {
|
|
229
442
|
for (let { element: t, scrollTop: n, scrollLeft: r } of e)
|
|
230
443
|
t.scrollTop = n, t.scrollLeft = r;
|
|
231
444
|
}
|
|
232
|
-
function
|
|
445
|
+
function de(e) {
|
|
233
446
|
var t;
|
|
234
|
-
|
|
447
|
+
if (typeof window > "u" || window.navigator == null) return !1;
|
|
448
|
+
let n = (t = window.navigator.userAgentData) === null || t === void 0 ? void 0 : t.brands;
|
|
449
|
+
return Array.isArray(n) && n.some((r) => e.test(r.brand)) || e.test(window.navigator.userAgent);
|
|
235
450
|
}
|
|
236
|
-
function
|
|
451
|
+
function ke(e) {
|
|
237
452
|
var t;
|
|
238
453
|
return typeof window < "u" && window.navigator != null ? e.test(((t = window.navigator.userAgentData) === null || t === void 0 ? void 0 : t.platform) || window.navigator.platform) : !1;
|
|
239
454
|
}
|
|
240
|
-
function
|
|
455
|
+
function O(e) {
|
|
456
|
+
if (process.env.NODE_ENV === "test") return e;
|
|
241
457
|
let t = null;
|
|
242
458
|
return () => (t == null && (t = e()), t);
|
|
243
459
|
}
|
|
244
|
-
const
|
|
245
|
-
return
|
|
246
|
-
}),
|
|
247
|
-
return
|
|
248
|
-
}),
|
|
249
|
-
return
|
|
250
|
-
|
|
251
|
-
}),
|
|
252
|
-
return
|
|
253
|
-
})
|
|
254
|
-
|
|
460
|
+
const Y = O(function() {
|
|
461
|
+
return ke(/^Mac/i);
|
|
462
|
+
}), en = O(function() {
|
|
463
|
+
return ke(/^iPhone/i);
|
|
464
|
+
}), Ye = O(function() {
|
|
465
|
+
return ke(/^iPad/i) || // iPadOS 13 lies and says it's a Mac, but we can distinguish by detecting touch support.
|
|
466
|
+
Y() && navigator.maxTouchPoints > 1;
|
|
467
|
+
}), Qe = O(function() {
|
|
468
|
+
return en() || Ye();
|
|
469
|
+
});
|
|
470
|
+
O(function() {
|
|
471
|
+
return Y() || Qe();
|
|
472
|
+
});
|
|
473
|
+
const tn = O(function() {
|
|
474
|
+
return de(/AppleWebKit/i) && !Ze();
|
|
475
|
+
}), Ze = O(function() {
|
|
476
|
+
return de(/Chrome/i);
|
|
477
|
+
}), et = O(function() {
|
|
478
|
+
return de(/Android/i);
|
|
479
|
+
}), nn = O(function() {
|
|
480
|
+
return de(/Firefox/i);
|
|
255
481
|
});
|
|
256
|
-
|
|
257
|
-
|
|
482
|
+
function Q(e, t, n = !0) {
|
|
483
|
+
var r, o;
|
|
484
|
+
let { metaKey: i, ctrlKey: a, altKey: l, shiftKey: s } = t;
|
|
485
|
+
nn() && (!((o = window.event) === null || o === void 0 || (r = o.type) === null || r === void 0) && r.startsWith("key")) && e.target === "_blank" && (Y() ? i = !0 : a = !0);
|
|
486
|
+
let c = tn() && Y() && !Ye() && process.env.NODE_ENV !== "test" ? new KeyboardEvent("keydown", {
|
|
487
|
+
keyIdentifier: "Enter",
|
|
488
|
+
metaKey: i,
|
|
489
|
+
ctrlKey: a,
|
|
490
|
+
altKey: l,
|
|
491
|
+
shiftKey: s
|
|
492
|
+
}) : new MouseEvent("click", {
|
|
493
|
+
metaKey: i,
|
|
494
|
+
ctrlKey: a,
|
|
495
|
+
altKey: l,
|
|
496
|
+
shiftKey: s,
|
|
497
|
+
detail: 1,
|
|
498
|
+
bubbles: !0,
|
|
499
|
+
cancelable: !0
|
|
500
|
+
});
|
|
501
|
+
Q.isOpening = n, he(e), e.dispatchEvent(c), Q.isOpening = !1;
|
|
502
|
+
}
|
|
503
|
+
Q.isOpening = !1;
|
|
504
|
+
let M = /* @__PURE__ */ new Map(), Ee = /* @__PURE__ */ new Set();
|
|
505
|
+
function Re() {
|
|
258
506
|
if (typeof window > "u") return;
|
|
259
507
|
function e(r) {
|
|
260
508
|
return "propertyName" in r;
|
|
261
509
|
}
|
|
262
510
|
let t = (r) => {
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
511
|
+
let o = y(r);
|
|
512
|
+
if (!e(r) || !o) return;
|
|
513
|
+
let i = M.get(o);
|
|
514
|
+
i || (i = /* @__PURE__ */ new Set(), M.set(o, i), o.addEventListener("transitioncancel", n, {
|
|
266
515
|
once: !0
|
|
267
|
-
})),
|
|
516
|
+
})), i.add(r.propertyName);
|
|
268
517
|
}, n = (r) => {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
518
|
+
let o = y(r);
|
|
519
|
+
if (!e(r) || !o) return;
|
|
520
|
+
let i = M.get(o);
|
|
521
|
+
if (i && (i.delete(r.propertyName), i.size === 0 && (o.removeEventListener("transitioncancel", n), M.delete(o)), M.size === 0)) {
|
|
522
|
+
for (let a of Ee) a();
|
|
523
|
+
Ee.clear();
|
|
274
524
|
}
|
|
275
525
|
};
|
|
276
526
|
document.body.addEventListener("transitionrun", t), document.body.addEventListener("transitionend", n);
|
|
277
527
|
}
|
|
278
|
-
typeof document < "u" && (document.readyState !== "loading" ?
|
|
279
|
-
function
|
|
528
|
+
typeof document < "u" && (document.readyState !== "loading" ? Re() : document.addEventListener("DOMContentLoaded", Re));
|
|
529
|
+
function rn() {
|
|
530
|
+
for (const [e] of M)
|
|
531
|
+
"isConnected" in e && !e.isConnected && M.delete(e);
|
|
532
|
+
}
|
|
533
|
+
function on(e) {
|
|
280
534
|
requestAnimationFrame(() => {
|
|
281
|
-
M.size === 0 ? e() :
|
|
535
|
+
rn(), M.size === 0 ? e() : Ee.add(e);
|
|
282
536
|
});
|
|
283
537
|
}
|
|
284
|
-
function
|
|
285
|
-
let
|
|
286
|
-
|
|
538
|
+
function an() {
|
|
539
|
+
let e = h(/* @__PURE__ */ new Map()), t = N((o, i, a, l) => {
|
|
540
|
+
let s = l?.once ? (...c) => {
|
|
541
|
+
e.current.delete(a), a(...c);
|
|
542
|
+
} : a;
|
|
543
|
+
e.current.set(a, {
|
|
544
|
+
type: i,
|
|
545
|
+
eventTarget: o,
|
|
546
|
+
fn: s,
|
|
547
|
+
options: l
|
|
548
|
+
}), o.addEventListener(i, s, l);
|
|
549
|
+
}, []), n = N((o, i, a, l) => {
|
|
550
|
+
var s;
|
|
551
|
+
let c = ((s = e.current.get(a)) === null || s === void 0 ? void 0 : s.fn) || a;
|
|
552
|
+
o.removeEventListener(i, c, l), e.current.delete(a);
|
|
553
|
+
}, []), r = N(() => {
|
|
554
|
+
e.current.forEach((o, i) => {
|
|
555
|
+
n(o.eventTarget, o.type, i, o.options);
|
|
556
|
+
});
|
|
557
|
+
}, [
|
|
558
|
+
n
|
|
559
|
+
]);
|
|
560
|
+
return _(() => r, [
|
|
561
|
+
r
|
|
562
|
+
]), {
|
|
563
|
+
addGlobalListener: t,
|
|
564
|
+
removeGlobalListener: n,
|
|
565
|
+
removeAllGlobalListeners: r
|
|
566
|
+
};
|
|
567
|
+
}
|
|
568
|
+
var ve;
|
|
569
|
+
const ln = (ve = m.useInsertionEffect) !== null && ve !== void 0 ? ve : g;
|
|
570
|
+
function De(e) {
|
|
571
|
+
const t = h(null);
|
|
572
|
+
return ln(() => {
|
|
573
|
+
t.current = e;
|
|
574
|
+
}, [
|
|
575
|
+
e
|
|
576
|
+
]), N((...n) => {
|
|
577
|
+
const r = t.current;
|
|
578
|
+
return r?.(...n);
|
|
579
|
+
}, []);
|
|
287
580
|
}
|
|
288
581
|
function Ae(e, t) {
|
|
582
|
+
if (!e) return !1;
|
|
583
|
+
let n = window.getComputedStyle(e), r = document.scrollingElement || document.documentElement, o = /(auto|scroll)/.test(n.overflow + n.overflowX + n.overflowY);
|
|
584
|
+
return e === r && n.overflow !== "hidden" && (o = !0), o && t && (o = e.scrollHeight !== e.clientHeight || e.scrollWidth !== e.clientWidth), o;
|
|
585
|
+
}
|
|
586
|
+
function tt(e, t) {
|
|
289
587
|
let n = e;
|
|
290
|
-
for (
|
|
588
|
+
for (Ae(n, t) && (n = n.parentElement); n && !Ae(n, t); ) n = n.parentElement;
|
|
291
589
|
return n || document.scrollingElement || document.documentElement;
|
|
292
590
|
}
|
|
293
|
-
function
|
|
294
|
-
return e.
|
|
591
|
+
function sn(e) {
|
|
592
|
+
return e.pointerType === "" && e.isTrusted ? !0 : et() && e.pointerType ? e.type === "click" && e.buttons === 1 : e.detail === 0 && !e.pointerType;
|
|
593
|
+
}
|
|
594
|
+
const cn = typeof Element < "u" && "checkVisibility" in Element.prototype;
|
|
595
|
+
function un(e) {
|
|
596
|
+
const t = X(e);
|
|
597
|
+
if (!(e instanceof t.HTMLElement) && !(e instanceof t.SVGElement)) return !1;
|
|
598
|
+
let { display: n, visibility: r } = e.style, o = n !== "none" && r !== "hidden" && r !== "collapse";
|
|
599
|
+
if (o) {
|
|
600
|
+
const { getComputedStyle: i } = e.ownerDocument.defaultView;
|
|
601
|
+
let { display: a, visibility: l } = i(e);
|
|
602
|
+
o = a !== "none" && l !== "hidden" && l !== "collapse";
|
|
603
|
+
}
|
|
604
|
+
return o;
|
|
605
|
+
}
|
|
606
|
+
function dn(e, t) {
|
|
607
|
+
return !e.hasAttribute("hidden") && // Ignore HiddenSelect when tree walking.
|
|
608
|
+
!e.hasAttribute("data-react-aria-prevent-focus") && (e.nodeName === "DETAILS" && t && t.nodeName !== "SUMMARY" ? e.hasAttribute("open") : !0);
|
|
609
|
+
}
|
|
610
|
+
function Se(e, t) {
|
|
611
|
+
return cn ? e.checkVisibility({
|
|
612
|
+
visibilityProperty: !0
|
|
613
|
+
}) && !e.closest("[data-react-aria-prevent-focus]") : e.nodeName !== "#comment" && un(e) && dn(e, t) && (!e.parentElement || Se(e.parentElement, e));
|
|
614
|
+
}
|
|
615
|
+
const xe = [
|
|
616
|
+
"input:not([disabled]):not([type=hidden])",
|
|
617
|
+
"select:not([disabled])",
|
|
618
|
+
"textarea:not([disabled])",
|
|
619
|
+
"button:not([disabled])",
|
|
620
|
+
"a[href]",
|
|
621
|
+
"area[href]",
|
|
622
|
+
"summary",
|
|
623
|
+
"iframe",
|
|
624
|
+
"object",
|
|
625
|
+
"embed",
|
|
626
|
+
"audio[controls]",
|
|
627
|
+
"video[controls]",
|
|
628
|
+
'[contenteditable]:not([contenteditable^="false"])',
|
|
629
|
+
"permission"
|
|
630
|
+
], fn = xe.join(":not([hidden]),") + ",[tabindex]:not([disabled]):not([hidden])";
|
|
631
|
+
xe.push('[tabindex]:not([tabindex="-1"]):not([disabled])');
|
|
632
|
+
const pn = xe.join(':not([hidden]):not([tabindex="-1"]),');
|
|
633
|
+
function vn(e) {
|
|
634
|
+
return e.matches(fn) && Se(e) && !nt(e);
|
|
635
|
+
}
|
|
636
|
+
function bn(e) {
|
|
637
|
+
return e.matches(pn) && Se(e) && !nt(e);
|
|
638
|
+
}
|
|
639
|
+
function nt(e) {
|
|
640
|
+
let t = e;
|
|
641
|
+
for (; t != null; ) {
|
|
642
|
+
if (t instanceof t.ownerDocument.defaultView.HTMLElement && t.inert) return !0;
|
|
643
|
+
t = t.parentElement;
|
|
644
|
+
}
|
|
645
|
+
return !1;
|
|
295
646
|
}
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
647
|
+
var be;
|
|
648
|
+
const $n = typeof document < "u" ? (be = m.useInsertionEffect) !== null && be !== void 0 ? be : m.useLayoutEffect : () => {
|
|
649
|
+
};
|
|
650
|
+
function mn(e, t, n) {
|
|
651
|
+
let [r, o] = Z(e || t), i = h(r), a = h(e !== void 0), l = e !== void 0;
|
|
652
|
+
_(() => {
|
|
653
|
+
let d = a.current;
|
|
654
|
+
d !== l && process.env.NODE_ENV !== "production" && console.warn(`WARN: A component changed from ${d ? "controlled" : "uncontrolled"} to ${l ? "controlled" : "uncontrolled"}.`), a.current = l;
|
|
301
655
|
}, [
|
|
302
|
-
|
|
656
|
+
l
|
|
303
657
|
]);
|
|
304
|
-
let
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
})) : (a || o(l), d(l, ...s));
|
|
658
|
+
let s = l ? e : r;
|
|
659
|
+
$n(() => {
|
|
660
|
+
i.current = s;
|
|
661
|
+
});
|
|
662
|
+
let [, c] = gt(() => ({}), {}), u = N((d, ...f) => {
|
|
663
|
+
let p = typeof d == "function" ? d(i.current) : d;
|
|
664
|
+
Object.is(i.current, p) || (i.current = p, o(p), c(), n?.(p, ...f));
|
|
312
665
|
}, [
|
|
313
|
-
a,
|
|
314
|
-
c,
|
|
315
666
|
n
|
|
316
667
|
]);
|
|
317
668
|
return [
|
|
318
|
-
|
|
669
|
+
s,
|
|
319
670
|
u
|
|
320
671
|
];
|
|
321
672
|
}
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
}
|
|
326
|
-
We.displayName = "PressResponderContext";
|
|
327
|
-
function Dt({ children: e }) {
|
|
328
|
-
let t = H(() => ({
|
|
329
|
-
register: () => {
|
|
330
|
-
}
|
|
331
|
-
}), []);
|
|
332
|
-
return /* @__PURE__ */ h.createElement(We.Provider, {
|
|
333
|
-
value: t
|
|
334
|
-
}, e);
|
|
673
|
+
function rt(e) {
|
|
674
|
+
let t = e;
|
|
675
|
+
return t.nativeEvent = e, t.isDefaultPrevented = () => t.defaultPrevented, t.isPropagationStopped = () => t.cancelBubble, t.persist = () => {
|
|
676
|
+
}, t;
|
|
335
677
|
}
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
}
|
|
343
|
-
stopPropagation() {
|
|
344
|
-
this.nativeEvent.stopPropagation(), this.isPropagationStopped = () => !0;
|
|
345
|
-
}
|
|
346
|
-
isPropagationStopped() {
|
|
347
|
-
return !1;
|
|
348
|
-
}
|
|
349
|
-
persist() {
|
|
350
|
-
}
|
|
351
|
-
constructor(t, n) {
|
|
352
|
-
this.nativeEvent = n, this.target = n.target, this.currentTarget = n.currentTarget, this.relatedTarget = n.relatedTarget, this.bubbles = n.bubbles, this.cancelable = n.cancelable, this.defaultPrevented = n.defaultPrevented, this.eventPhase = n.eventPhase, this.isTrusted = n.isTrusted, this.timeStamp = n.timeStamp, this.type = t;
|
|
353
|
-
}
|
|
678
|
+
function hn(e, t) {
|
|
679
|
+
Object.defineProperty(e, "target", {
|
|
680
|
+
value: t
|
|
681
|
+
}), Object.defineProperty(e, "currentTarget", {
|
|
682
|
+
value: t
|
|
683
|
+
});
|
|
354
684
|
}
|
|
355
|
-
function
|
|
356
|
-
let t =
|
|
685
|
+
function En(e) {
|
|
686
|
+
let t = h({
|
|
357
687
|
isFocused: !1,
|
|
358
688
|
observer: null
|
|
359
689
|
});
|
|
360
|
-
|
|
361
|
-
const
|
|
690
|
+
return g(() => {
|
|
691
|
+
const n = t.current;
|
|
362
692
|
return () => {
|
|
363
|
-
|
|
693
|
+
n.observer && (n.observer.disconnect(), n.observer = null);
|
|
364
694
|
};
|
|
365
|
-
}, [])
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
});
|
|
369
|
-
return S((r) => {
|
|
370
|
-
if (r.target instanceof HTMLButtonElement || r.target instanceof HTMLInputElement || r.target instanceof HTMLTextAreaElement || r.target instanceof HTMLSelectElement) {
|
|
695
|
+
}, []), N((n) => {
|
|
696
|
+
let r = y(n);
|
|
697
|
+
if (r instanceof HTMLButtonElement || r instanceof HTMLInputElement || r instanceof HTMLTextAreaElement || r instanceof HTMLSelectElement) {
|
|
371
698
|
t.current.isFocused = !0;
|
|
372
|
-
let o = r
|
|
373
|
-
t.current.isFocused = !1, o.disabled
|
|
699
|
+
let o = r, i = (a) => {
|
|
700
|
+
if (t.current.isFocused = !1, o.disabled) {
|
|
701
|
+
let l = rt(a);
|
|
702
|
+
e?.(l);
|
|
703
|
+
}
|
|
704
|
+
t.current.observer && (t.current.observer.disconnect(), t.current.observer = null);
|
|
374
705
|
};
|
|
375
706
|
o.addEventListener("focusout", i, {
|
|
376
707
|
once: !0
|
|
@@ -378,12 +709,12 @@ function Wt(e) {
|
|
|
378
709
|
if (t.current.isFocused && o.disabled) {
|
|
379
710
|
var a;
|
|
380
711
|
(a = t.current.observer) === null || a === void 0 || a.disconnect();
|
|
381
|
-
let
|
|
712
|
+
let l = o === T() ? null : T();
|
|
382
713
|
o.dispatchEvent(new FocusEvent("blur", {
|
|
383
|
-
relatedTarget:
|
|
714
|
+
relatedTarget: l
|
|
384
715
|
})), o.dispatchEvent(new FocusEvent("focusout", {
|
|
385
716
|
bubbles: !0,
|
|
386
|
-
relatedTarget:
|
|
717
|
+
relatedTarget: l
|
|
387
718
|
}));
|
|
388
719
|
}
|
|
389
720
|
}), t.current.observer.observe(o, {
|
|
@@ -394,367 +725,394 @@ function Wt(e) {
|
|
|
394
725
|
});
|
|
395
726
|
}
|
|
396
727
|
}, [
|
|
397
|
-
|
|
728
|
+
e
|
|
398
729
|
]);
|
|
399
730
|
}
|
|
400
|
-
let
|
|
401
|
-
|
|
402
|
-
|
|
731
|
+
let wn = !1;
|
|
732
|
+
const ot = m.createContext({
|
|
733
|
+
register: () => {
|
|
734
|
+
}
|
|
735
|
+
});
|
|
736
|
+
ot.displayName = "PressResponderContext";
|
|
737
|
+
let ee = null;
|
|
738
|
+
const gn = /* @__PURE__ */ new Set();
|
|
739
|
+
let J = /* @__PURE__ */ new Map(), W = !1, we = !1;
|
|
740
|
+
function Le(e, t) {
|
|
741
|
+
for (let n of gn) n(e, t);
|
|
403
742
|
}
|
|
404
|
-
function
|
|
405
|
-
return !(e.metaKey || !
|
|
743
|
+
function yn(e) {
|
|
744
|
+
return !(e.metaKey || !Y() && e.altKey || e.ctrlKey || e.key === "Control" || e.key === "Shift" || e.key === "Meta");
|
|
406
745
|
}
|
|
407
|
-
function
|
|
408
|
-
|
|
746
|
+
function se(e) {
|
|
747
|
+
W = !0, !Q.isOpening && yn(e) && (ee = "keyboard", Le("keyboard", e));
|
|
409
748
|
}
|
|
410
|
-
function
|
|
411
|
-
|
|
749
|
+
function S(e) {
|
|
750
|
+
ee = "pointer", "pointerType" in e && e.pointerType, (e.type === "mousedown" || e.type === "pointerdown") && (W = !0, Le("pointer", e));
|
|
412
751
|
}
|
|
413
|
-
function
|
|
414
|
-
|
|
752
|
+
function it(e) {
|
|
753
|
+
!Q.isOpening && sn(e) && (W = !0, ee = "virtual");
|
|
415
754
|
}
|
|
416
|
-
function
|
|
417
|
-
e
|
|
755
|
+
function at(e) {
|
|
756
|
+
y(e) === window || y(e) === document || wn || !e.isTrusted || (!W && !we && (ee = "virtual", Le("virtual", e)), W = !1, we = !1);
|
|
418
757
|
}
|
|
419
|
-
function
|
|
420
|
-
|
|
758
|
+
function lt() {
|
|
759
|
+
W = !1, we = !0;
|
|
421
760
|
}
|
|
422
|
-
function
|
|
423
|
-
if (typeof window > "u" ||
|
|
424
|
-
const t =
|
|
761
|
+
function Ie(e) {
|
|
762
|
+
if (typeof window > "u" || typeof document > "u" || J.get(X(e))) return;
|
|
763
|
+
const t = X(e), n = w(e);
|
|
425
764
|
let r = t.HTMLElement.prototype.focus;
|
|
426
765
|
t.HTMLElement.prototype.focus = function() {
|
|
427
|
-
|
|
428
|
-
}, n.addEventListener("keydown",
|
|
429
|
-
|
|
766
|
+
W = !0, r.apply(this, arguments);
|
|
767
|
+
}, n.addEventListener("keydown", se, !0), n.addEventListener("keyup", se, !0), n.addEventListener("click", it, !0), t.addEventListener("focus", at, !0), t.addEventListener("blur", lt, !1), typeof PointerEvent < "u" ? (n.addEventListener("pointerdown", S, !0), n.addEventListener("pointermove", S, !0), n.addEventListener("pointerup", S, !0)) : process.env.NODE_ENV === "test" && (n.addEventListener("mousedown", S, !0), n.addEventListener("mousemove", S, !0), n.addEventListener("mouseup", S, !0)), t.addEventListener("beforeunload", () => {
|
|
768
|
+
st(e);
|
|
430
769
|
}, {
|
|
431
770
|
once: !0
|
|
432
|
-
}),
|
|
771
|
+
}), J.set(t, {
|
|
433
772
|
focus: r
|
|
434
773
|
});
|
|
435
774
|
}
|
|
436
|
-
const
|
|
437
|
-
const n =
|
|
438
|
-
t && r.removeEventListener("DOMContentLoaded", t),
|
|
775
|
+
const st = (e, t) => {
|
|
776
|
+
const n = X(e), r = w(e);
|
|
777
|
+
t && r.removeEventListener("DOMContentLoaded", t), J.has(n) && (n.HTMLElement.prototype.focus = J.get(n).focus, r.removeEventListener("keydown", se, !0), r.removeEventListener("keyup", se, !0), r.removeEventListener("click", it, !0), n.removeEventListener("focus", at, !0), n.removeEventListener("blur", lt, !1), typeof PointerEvent < "u" ? (r.removeEventListener("pointerdown", S, !0), r.removeEventListener("pointermove", S, !0), r.removeEventListener("pointerup", S, !0)) : process.env.NODE_ENV === "test" && (r.removeEventListener("mousedown", S, !0), r.removeEventListener("mousemove", S, !0), r.removeEventListener("mouseup", S, !0)), J.delete(n));
|
|
439
778
|
};
|
|
440
|
-
function
|
|
441
|
-
const t =
|
|
779
|
+
function Tn(e) {
|
|
780
|
+
const t = w(e);
|
|
442
781
|
let n;
|
|
443
|
-
return t.readyState !== "loading" ?
|
|
444
|
-
|
|
445
|
-
}, t.addEventListener("DOMContentLoaded", n)), () =>
|
|
782
|
+
return t.readyState !== "loading" ? Ie(e) : (n = () => {
|
|
783
|
+
Ie(e);
|
|
784
|
+
}, t.addEventListener("DOMContentLoaded", n)), () => st(e, n);
|
|
446
785
|
}
|
|
447
|
-
typeof document < "u" &&
|
|
448
|
-
function
|
|
449
|
-
return
|
|
786
|
+
typeof document < "u" && Tn();
|
|
787
|
+
function ct() {
|
|
788
|
+
return ee;
|
|
450
789
|
}
|
|
451
|
-
function
|
|
452
|
-
|
|
790
|
+
function ge(e) {
|
|
791
|
+
if (!e.isConnected) return;
|
|
792
|
+
const t = w(e);
|
|
793
|
+
if (ct() === "virtual") {
|
|
794
|
+
let n = T(t);
|
|
795
|
+
on(() => {
|
|
796
|
+
const r = T(t);
|
|
797
|
+
(r === n || r === t.body) && e.isConnected && he(e);
|
|
798
|
+
});
|
|
799
|
+
} else he(e);
|
|
800
|
+
}
|
|
801
|
+
function Nn({ children: e }) {
|
|
802
|
+
let t = U(() => ({
|
|
803
|
+
register: () => {
|
|
804
|
+
}
|
|
805
|
+
}), []);
|
|
806
|
+
return /* @__PURE__ */ m.createElement(ot.Provider, {
|
|
807
|
+
value: t
|
|
808
|
+
}, e);
|
|
809
|
+
}
|
|
810
|
+
function kn(e) {
|
|
811
|
+
let { isDisabled: t, onBlurWithin: n, onFocusWithin: r, onFocusWithinChange: o } = e, i = h({
|
|
453
812
|
isFocusWithin: !1
|
|
454
|
-
}), a =
|
|
455
|
-
i.current.isFocusWithin && !
|
|
813
|
+
}), { addGlobalListener: a, removeAllGlobalListeners: l } = an(), s = N((d) => {
|
|
814
|
+
F(d.currentTarget, y(d)) && i.current.isFocusWithin && !F(d.currentTarget, d.relatedTarget) && (i.current.isFocusWithin = !1, l(), n && n(d), o && o(!1));
|
|
456
815
|
}, [
|
|
457
816
|
n,
|
|
458
817
|
o,
|
|
459
|
-
i
|
|
460
|
-
|
|
461
|
-
|
|
818
|
+
i,
|
|
819
|
+
l
|
|
820
|
+
]), c = En(s), u = N((d) => {
|
|
821
|
+
if (!F(d.currentTarget, y(d))) return;
|
|
822
|
+
let f = y(d);
|
|
823
|
+
const p = w(f), b = T(p);
|
|
824
|
+
if (!i.current.isFocusWithin && b === f) {
|
|
825
|
+
r && r(d), o && o(!0), i.current.isFocusWithin = !0, c(d);
|
|
826
|
+
let L = d.currentTarget;
|
|
827
|
+
a(p, "focus", (A) => {
|
|
828
|
+
let te = y(A);
|
|
829
|
+
if (i.current.isFocusWithin && !F(L, te)) {
|
|
830
|
+
let K = new p.defaultView.FocusEvent("blur", {
|
|
831
|
+
relatedTarget: te
|
|
832
|
+
});
|
|
833
|
+
hn(K, L);
|
|
834
|
+
let fe = rt(K);
|
|
835
|
+
s(fe);
|
|
836
|
+
}
|
|
837
|
+
}, {
|
|
838
|
+
capture: !0
|
|
839
|
+
});
|
|
840
|
+
}
|
|
462
841
|
}, [
|
|
463
842
|
r,
|
|
464
843
|
o,
|
|
465
|
-
c
|
|
844
|
+
c,
|
|
845
|
+
a,
|
|
846
|
+
s
|
|
466
847
|
]);
|
|
467
848
|
return t ? {
|
|
468
849
|
focusWithinProps: {
|
|
469
|
-
// These
|
|
850
|
+
// These cannot be null, that would conflict in mergeProps
|
|
470
851
|
onFocus: void 0,
|
|
471
852
|
onBlur: void 0
|
|
472
853
|
}
|
|
473
854
|
} : {
|
|
474
855
|
focusWithinProps: {
|
|
475
856
|
onFocus: u,
|
|
476
|
-
onBlur:
|
|
857
|
+
onBlur: s
|
|
477
858
|
}
|
|
478
859
|
};
|
|
479
860
|
}
|
|
480
|
-
function
|
|
481
|
-
let { ref: t, onInteractOutside: n, isDisabled: r, onInteractOutsideStart: o } = e, i =
|
|
861
|
+
function Sn(e) {
|
|
862
|
+
let { ref: t, onInteractOutside: n, isDisabled: r, onInteractOutsideStart: o } = e, i = h({
|
|
482
863
|
isPointerDown: !1,
|
|
483
864
|
ignoreEmulatedMouseEvents: !1
|
|
484
|
-
}), a =
|
|
485
|
-
n &&
|
|
486
|
-
}),
|
|
487
|
-
n && n(
|
|
865
|
+
}), a = De((s) => {
|
|
866
|
+
n && re(s, t) && (o && o(s), i.current.isPointerDown = !0);
|
|
867
|
+
}), l = De((s) => {
|
|
868
|
+
n && n(s);
|
|
488
869
|
});
|
|
489
|
-
|
|
490
|
-
let
|
|
870
|
+
_(() => {
|
|
871
|
+
let s = i.current;
|
|
491
872
|
if (r) return;
|
|
492
|
-
const
|
|
873
|
+
const c = t.current, u = w(c);
|
|
493
874
|
if (typeof PointerEvent < "u") {
|
|
494
|
-
let d = (
|
|
495
|
-
|
|
875
|
+
let d = (f) => {
|
|
876
|
+
s.isPointerDown && re(f, t) && l(f), s.isPointerDown = !1;
|
|
496
877
|
};
|
|
497
|
-
return
|
|
498
|
-
|
|
878
|
+
return u.addEventListener("pointerdown", a, !0), u.addEventListener("click", d, !0), () => {
|
|
879
|
+
u.removeEventListener("pointerdown", a, !0), u.removeEventListener("click", d, !0);
|
|
499
880
|
};
|
|
500
|
-
} else {
|
|
501
|
-
let d = (
|
|
502
|
-
|
|
503
|
-
},
|
|
504
|
-
|
|
881
|
+
} else if (process.env.NODE_ENV === "test") {
|
|
882
|
+
let d = (p) => {
|
|
883
|
+
s.ignoreEmulatedMouseEvents ? s.ignoreEmulatedMouseEvents = !1 : s.isPointerDown && re(p, t) && l(p), s.isPointerDown = !1;
|
|
884
|
+
}, f = (p) => {
|
|
885
|
+
s.ignoreEmulatedMouseEvents = !0, s.isPointerDown && re(p, t) && l(p), s.isPointerDown = !1;
|
|
505
886
|
};
|
|
506
|
-
return
|
|
507
|
-
|
|
887
|
+
return u.addEventListener("mousedown", a, !0), u.addEventListener("mouseup", d, !0), u.addEventListener("touchstart", a, !0), u.addEventListener("touchend", f, !0), () => {
|
|
888
|
+
u.removeEventListener("mousedown", a, !0), u.removeEventListener("mouseup", d, !0), u.removeEventListener("touchstart", a, !0), u.removeEventListener("touchend", f, !0);
|
|
508
889
|
};
|
|
509
890
|
}
|
|
510
891
|
}, [
|
|
511
892
|
t,
|
|
512
|
-
r
|
|
513
|
-
a,
|
|
514
|
-
c
|
|
893
|
+
r
|
|
515
894
|
]);
|
|
516
895
|
}
|
|
517
|
-
function
|
|
896
|
+
function re(e, t) {
|
|
518
897
|
if (e.button > 0) return !1;
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
return t.current && !t.current.contains(e.target);
|
|
524
|
-
}
|
|
525
|
-
function ce(e) {
|
|
526
|
-
const t = g(e);
|
|
527
|
-
if (Ht() === "virtual") {
|
|
528
|
-
let n = t.activeElement;
|
|
529
|
-
_t(() => {
|
|
530
|
-
t.activeElement === n && e.isConnected && ge(e);
|
|
531
|
-
});
|
|
532
|
-
} else ge(e);
|
|
533
|
-
}
|
|
534
|
-
function jt(e) {
|
|
535
|
-
const t = Z(e);
|
|
536
|
-
if (!(e instanceof t.HTMLElement) && !(e instanceof t.SVGElement)) return !1;
|
|
537
|
-
let { display: n, visibility: r } = e.style, o = n !== "none" && r !== "hidden" && r !== "collapse";
|
|
538
|
-
if (o) {
|
|
539
|
-
const { getComputedStyle: i } = e.ownerDocument.defaultView;
|
|
540
|
-
let { display: a, visibility: c } = i(e);
|
|
541
|
-
o = a !== "none" && c !== "hidden" && c !== "collapse";
|
|
898
|
+
let n = y(e);
|
|
899
|
+
if (n) {
|
|
900
|
+
const r = n.ownerDocument;
|
|
901
|
+
if (!r || !F(r.documentElement, n) || n.closest("[data-react-aria-top-layer]")) return !1;
|
|
542
902
|
}
|
|
543
|
-
return
|
|
903
|
+
return t.current ? !e.composedPath().includes(t.current) : !1;
|
|
544
904
|
}
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
}
|
|
549
|
-
|
|
550
|
-
return e.nodeName !== "#comment" && jt(e) && qt(e, t) && (!e.parentElement || Ve(e.parentElement, e));
|
|
551
|
-
}
|
|
552
|
-
const xe = /* @__PURE__ */ h.createContext(null), ue = "react-aria-focus-scope-restore";
|
|
553
|
-
let m = null;
|
|
554
|
-
function zt(e) {
|
|
555
|
-
let { children: t, contain: n, restoreFocus: r, autoFocus: o } = e, i = y(null), a = y(null), c = y([]), { parentNode: u } = A(xe) || {}, l = H(() => new fe({
|
|
556
|
-
scopeRef: c
|
|
905
|
+
const We = /* @__PURE__ */ m.createContext(null), ye = "react-aria-focus-scope-restore";
|
|
906
|
+
let $ = null;
|
|
907
|
+
function xn(e) {
|
|
908
|
+
let { children: t, contain: n, restoreFocus: r, autoFocus: o } = e, i = h(null), a = h(null), l = h([]), { parentNode: s } = H(We) || {}, c = U(() => new Ne({
|
|
909
|
+
scopeRef: l
|
|
557
910
|
}), [
|
|
558
|
-
|
|
911
|
+
l
|
|
559
912
|
]);
|
|
560
|
-
|
|
561
|
-
let
|
|
562
|
-
if (
|
|
563
|
-
let
|
|
564
|
-
|
|
913
|
+
g(() => {
|
|
914
|
+
let f = s || E.root;
|
|
915
|
+
if (E.getTreeNode(f.scopeRef) && $ && !ce($, f.scopeRef)) {
|
|
916
|
+
let p = E.getTreeNode($);
|
|
917
|
+
p && (f = p);
|
|
565
918
|
}
|
|
566
|
-
|
|
919
|
+
f.addChild(c), E.addNode(c);
|
|
567
920
|
}, [
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
]),
|
|
571
|
-
let
|
|
572
|
-
|
|
921
|
+
c,
|
|
922
|
+
s
|
|
923
|
+
]), g(() => {
|
|
924
|
+
let f = E.getTreeNode(l);
|
|
925
|
+
f && (f.contain = !!n);
|
|
573
926
|
}, [
|
|
574
927
|
n
|
|
575
|
-
]),
|
|
576
|
-
var
|
|
577
|
-
let
|
|
578
|
-
for (;
|
|
579
|
-
|
|
580
|
-
return
|
|
581
|
-
for (let
|
|
928
|
+
]), g(() => {
|
|
929
|
+
var f;
|
|
930
|
+
let p = (f = i.current) === null || f === void 0 ? void 0 : f.nextSibling, b = [], L = (A) => A.stopPropagation();
|
|
931
|
+
for (; p && p !== a.current; )
|
|
932
|
+
b.push(p), p.addEventListener(ye, L), p = p.nextSibling;
|
|
933
|
+
return l.current = b, () => {
|
|
934
|
+
for (let A of b) A.removeEventListener(ye, L);
|
|
582
935
|
};
|
|
583
936
|
}, [
|
|
584
937
|
t
|
|
585
|
-
]),
|
|
586
|
-
const
|
|
587
|
-
let
|
|
588
|
-
if (
|
|
589
|
-
for (let
|
|
590
|
-
|
|
938
|
+
]), Mn(l, r, n), Fn(l, n), Rn(l, r, n), On(l, o), _(() => {
|
|
939
|
+
const f = T(w(l.current ? l.current[0] : void 0));
|
|
940
|
+
let p = null;
|
|
941
|
+
if (x(f, l.current)) {
|
|
942
|
+
for (let b of E.traverse()) b.scopeRef && x(f, b.scopeRef.current) && (p = b);
|
|
943
|
+
p === E.getTreeNode(l) && ($ = p.scopeRef);
|
|
591
944
|
}
|
|
592
945
|
}, [
|
|
593
|
-
|
|
594
|
-
]),
|
|
595
|
-
var p, b
|
|
596
|
-
let
|
|
597
|
-
(
|
|
946
|
+
l
|
|
947
|
+
]), g(() => () => {
|
|
948
|
+
var f, p, b;
|
|
949
|
+
let L = (b = (p = E.getTreeNode(l)) === null || p === void 0 || (f = p.parent) === null || f === void 0 ? void 0 : f.scopeRef) !== null && b !== void 0 ? b : null;
|
|
950
|
+
(l === $ || ce(l, $)) && (!L || E.getTreeNode(L)) && ($ = L), E.removeTreeNode(l);
|
|
598
951
|
}, [
|
|
599
|
-
|
|
952
|
+
l
|
|
600
953
|
]);
|
|
601
|
-
let
|
|
602
|
-
focusManager:
|
|
603
|
-
parentNode:
|
|
954
|
+
let u = U(() => Ln(l), []), d = U(() => ({
|
|
955
|
+
focusManager: u,
|
|
956
|
+
parentNode: c
|
|
604
957
|
}), [
|
|
605
|
-
|
|
606
|
-
|
|
958
|
+
c,
|
|
959
|
+
u
|
|
607
960
|
]);
|
|
608
|
-
return /* @__PURE__ */
|
|
961
|
+
return /* @__PURE__ */ m.createElement(We.Provider, {
|
|
609
962
|
value: d
|
|
610
|
-
}, /* @__PURE__ */
|
|
963
|
+
}, /* @__PURE__ */ m.createElement("span", {
|
|
611
964
|
"data-focus-scope-start": !0,
|
|
612
965
|
hidden: !0,
|
|
613
966
|
ref: i
|
|
614
|
-
}), t, /* @__PURE__ */
|
|
967
|
+
}), t, /* @__PURE__ */ m.createElement("span", {
|
|
615
968
|
"data-focus-scope-end": !0,
|
|
616
969
|
hidden: !0,
|
|
617
970
|
ref: a
|
|
618
971
|
}));
|
|
619
972
|
}
|
|
620
|
-
function
|
|
973
|
+
function Ln(e) {
|
|
621
974
|
return {
|
|
622
975
|
focusNext(t = {}) {
|
|
623
|
-
let n = e.current, { from: r, tabbable: o, wrap: i, accept: a } = t
|
|
976
|
+
let n = e.current, { from: r, tabbable: o, wrap: i, accept: a } = t;
|
|
977
|
+
var l;
|
|
978
|
+
let s = r || T(w((l = n[0]) !== null && l !== void 0 ? l : void 0)), c = n[0].previousElementSibling, u = I(n), d = D(u, {
|
|
624
979
|
tabbable: o,
|
|
625
980
|
accept: a
|
|
626
981
|
}, n);
|
|
627
|
-
|
|
628
|
-
let
|
|
629
|
-
return !
|
|
982
|
+
d.currentNode = x(s, n) ? s : c;
|
|
983
|
+
let f = d.nextNode();
|
|
984
|
+
return !f && i && (d.currentNode = c, f = d.nextNode()), f && P(f, !0), f;
|
|
630
985
|
},
|
|
631
986
|
focusPrevious(t = {}) {
|
|
632
|
-
let n = e.current, { from: r, tabbable: o, wrap: i, accept: a } = t
|
|
987
|
+
let n = e.current, { from: r, tabbable: o, wrap: i, accept: a } = t;
|
|
988
|
+
var l;
|
|
989
|
+
let s = r || T(w((l = n[0]) !== null && l !== void 0 ? l : void 0)), c = n[n.length - 1].nextElementSibling, u = I(n), d = D(u, {
|
|
633
990
|
tabbable: o,
|
|
634
991
|
accept: a
|
|
635
992
|
}, n);
|
|
636
|
-
|
|
637
|
-
let
|
|
638
|
-
return !
|
|
993
|
+
d.currentNode = x(s, n) ? s : c;
|
|
994
|
+
let f = d.previousNode();
|
|
995
|
+
return !f && i && (d.currentNode = c, f = d.previousNode()), f && P(f, !0), f;
|
|
639
996
|
},
|
|
640
997
|
focusFirst(t = {}) {
|
|
641
|
-
let n = e.current, { tabbable: r, accept: o } = t, i =
|
|
998
|
+
let n = e.current, { tabbable: r, accept: o } = t, i = I(n), a = D(i, {
|
|
642
999
|
tabbable: r,
|
|
643
1000
|
accept: o
|
|
644
1001
|
}, n);
|
|
645
1002
|
a.currentNode = n[0].previousElementSibling;
|
|
646
|
-
let
|
|
647
|
-
return
|
|
1003
|
+
let l = a.nextNode();
|
|
1004
|
+
return l && P(l, !0), l;
|
|
648
1005
|
},
|
|
649
1006
|
focusLast(t = {}) {
|
|
650
|
-
let n = e.current, { tabbable: r, accept: o } = t, i =
|
|
1007
|
+
let n = e.current, { tabbable: r, accept: o } = t, i = I(n), a = D(i, {
|
|
651
1008
|
tabbable: r,
|
|
652
1009
|
accept: o
|
|
653
1010
|
}, n);
|
|
654
1011
|
a.currentNode = n[n.length - 1].nextElementSibling;
|
|
655
|
-
let
|
|
656
|
-
return
|
|
1012
|
+
let l = a.previousNode();
|
|
1013
|
+
return l && P(l, !0), l;
|
|
657
1014
|
}
|
|
658
1015
|
};
|
|
659
1016
|
}
|
|
660
|
-
|
|
661
|
-
"input:not([disabled]):not([type=hidden])",
|
|
662
|
-
"select:not([disabled])",
|
|
663
|
-
"textarea:not([disabled])",
|
|
664
|
-
"button:not([disabled])",
|
|
665
|
-
"a[href]",
|
|
666
|
-
"area[href]",
|
|
667
|
-
"summary",
|
|
668
|
-
"iframe",
|
|
669
|
-
"object",
|
|
670
|
-
"embed",
|
|
671
|
-
"audio[controls]",
|
|
672
|
-
"video[controls]",
|
|
673
|
-
"[contenteditable]"
|
|
674
|
-
], Gt = be.join(":not([hidden]),") + ",[tabindex]:not([disabled]):not([hidden])";
|
|
675
|
-
be.push('[tabindex]:not([tabindex="-1"]):not([disabled])');
|
|
676
|
-
const Jt = be.join(':not([hidden]):not([tabindex="-1"]),');
|
|
677
|
-
function _(e) {
|
|
1017
|
+
function I(e) {
|
|
678
1018
|
return e[0].parentElement;
|
|
679
1019
|
}
|
|
680
|
-
function
|
|
681
|
-
let t =
|
|
1020
|
+
function z(e) {
|
|
1021
|
+
let t = E.getTreeNode($);
|
|
682
1022
|
for (; t && t.scopeRef !== e; ) {
|
|
683
1023
|
if (t.contain) return !1;
|
|
684
1024
|
t = t.parent;
|
|
685
1025
|
}
|
|
686
1026
|
return !0;
|
|
687
1027
|
}
|
|
688
|
-
function
|
|
689
|
-
|
|
690
|
-
|
|
1028
|
+
function _n(e) {
|
|
1029
|
+
if (!e.form)
|
|
1030
|
+
return Array.from(w(e).querySelectorAll(`input[type="radio"][name="${CSS.escape(e.name)}"]`)).filter((r) => !r.form);
|
|
1031
|
+
const t = e.form.elements.namedItem(e.name);
|
|
1032
|
+
let n = X(e);
|
|
1033
|
+
return t instanceof n.RadioNodeList ? Array.from(t).filter((r) => r instanceof n.HTMLInputElement) : t instanceof n.HTMLInputElement ? [
|
|
1034
|
+
t
|
|
1035
|
+
] : [];
|
|
1036
|
+
}
|
|
1037
|
+
function Cn(e) {
|
|
1038
|
+
if (e.checked) return !0;
|
|
1039
|
+
const t = _n(e);
|
|
1040
|
+
return t.length > 0 && !t.some((n) => n.checked);
|
|
1041
|
+
}
|
|
1042
|
+
function Fn(e, t) {
|
|
1043
|
+
let n = h(void 0), r = h(void 0);
|
|
1044
|
+
g(() => {
|
|
691
1045
|
let o = e.current;
|
|
692
1046
|
if (!t) {
|
|
693
1047
|
r.current && (cancelAnimationFrame(r.current), r.current = void 0);
|
|
694
1048
|
return;
|
|
695
1049
|
}
|
|
696
|
-
const i =
|
|
697
|
-
let a = (
|
|
698
|
-
if (
|
|
699
|
-
let
|
|
700
|
-
if (!d || !
|
|
701
|
-
let
|
|
1050
|
+
const i = w(o ? o[0] : void 0);
|
|
1051
|
+
let a = (c) => {
|
|
1052
|
+
if (c.key !== "Tab" || c.altKey || c.ctrlKey || c.metaKey || !z(e) || c.isComposing) return;
|
|
1053
|
+
let u = T(i), d = e.current;
|
|
1054
|
+
if (!d || !x(u, d)) return;
|
|
1055
|
+
let f = I(d), p = D(f, {
|
|
702
1056
|
tabbable: !0
|
|
703
1057
|
}, d);
|
|
704
|
-
if (!
|
|
705
|
-
|
|
706
|
-
let
|
|
707
|
-
|
|
708
|
-
},
|
|
709
|
-
(
|
|
710
|
-
},
|
|
1058
|
+
if (!u) return;
|
|
1059
|
+
p.currentNode = u;
|
|
1060
|
+
let b = c.shiftKey ? p.previousNode() : p.nextNode();
|
|
1061
|
+
b || (p.currentNode = c.shiftKey ? d[d.length - 1].nextElementSibling : d[0].previousElementSibling, b = c.shiftKey ? p.previousNode() : p.nextNode()), c.preventDefault(), b && P(b, !0);
|
|
1062
|
+
}, l = (c) => {
|
|
1063
|
+
(!$ || ce($, e)) && x(y(c), e.current) ? ($ = e, n.current = y(c)) : z(e) && !R(y(c), e) ? n.current ? n.current.focus() : $ && $.current && Te($.current) : z(e) && (n.current = y(c));
|
|
1064
|
+
}, s = (c) => {
|
|
711
1065
|
r.current && cancelAnimationFrame(r.current), r.current = requestAnimationFrame(() => {
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
1066
|
+
let u = ct(), d = (u === "virtual" || u === null) && et() && Ze(), f = T(i);
|
|
1067
|
+
if (!d && f && z(e) && !R(f, e)) {
|
|
1068
|
+
$ = e;
|
|
1069
|
+
let b = y(c);
|
|
1070
|
+
if (b && b.isConnected) {
|
|
1071
|
+
var p;
|
|
1072
|
+
n.current = b, (p = n.current) === null || p === void 0 || p.focus();
|
|
1073
|
+
} else $.current && Te($.current);
|
|
1074
|
+
}
|
|
717
1075
|
});
|
|
718
1076
|
};
|
|
719
|
-
return i.addEventListener("keydown", a, !1), i.addEventListener("focusin",
|
|
720
|
-
i.removeEventListener("keydown", a, !1), i.removeEventListener("focusin",
|
|
1077
|
+
return i.addEventListener("keydown", a, !1), i.addEventListener("focusin", l, !1), o?.forEach((c) => c.addEventListener("focusin", l, !1)), o?.forEach((c) => c.addEventListener("focusout", s, !1)), () => {
|
|
1078
|
+
i.removeEventListener("keydown", a, !1), i.removeEventListener("focusin", l, !1), o?.forEach((c) => c.removeEventListener("focusin", l, !1)), o?.forEach((c) => c.removeEventListener("focusout", s, !1));
|
|
721
1079
|
};
|
|
722
1080
|
}, [
|
|
723
1081
|
e,
|
|
724
1082
|
t
|
|
725
|
-
]),
|
|
1083
|
+
]), g(() => () => {
|
|
726
1084
|
r.current && cancelAnimationFrame(r.current);
|
|
727
1085
|
}, [
|
|
728
1086
|
r
|
|
729
1087
|
]);
|
|
730
1088
|
}
|
|
731
|
-
function
|
|
732
|
-
return
|
|
1089
|
+
function ut(e) {
|
|
1090
|
+
return R(e);
|
|
733
1091
|
}
|
|
734
|
-
function
|
|
735
|
-
return !e || !t ? !1 : t.some((n) => n
|
|
1092
|
+
function x(e, t) {
|
|
1093
|
+
return !e || !t ? !1 : t.some((n) => F(n, e));
|
|
736
1094
|
}
|
|
737
|
-
function
|
|
1095
|
+
function R(e, t = null) {
|
|
738
1096
|
if (e instanceof Element && e.closest("[data-react-aria-top-layer]")) return !0;
|
|
739
|
-
for (let { scopeRef: n } of
|
|
740
|
-
if (n &&
|
|
1097
|
+
for (let { scopeRef: n } of E.traverse(E.getTreeNode(t)))
|
|
1098
|
+
if (n && x(e, n.current)) return !0;
|
|
741
1099
|
return !1;
|
|
742
1100
|
}
|
|
743
|
-
function
|
|
744
|
-
return
|
|
1101
|
+
function Pn(e) {
|
|
1102
|
+
return R(e, $);
|
|
745
1103
|
}
|
|
746
|
-
function
|
|
1104
|
+
function ce(e, t) {
|
|
747
1105
|
var n;
|
|
748
|
-
let r = (n =
|
|
1106
|
+
let r = (n = E.getTreeNode(t)) === null || n === void 0 ? void 0 : n.parent;
|
|
749
1107
|
for (; r; ) {
|
|
750
1108
|
if (r.scopeRef === e) return !0;
|
|
751
1109
|
r = r.parent;
|
|
752
1110
|
}
|
|
753
1111
|
return !1;
|
|
754
1112
|
}
|
|
755
|
-
function
|
|
1113
|
+
function P(e, t = !1) {
|
|
756
1114
|
if (e != null && !t) try {
|
|
757
|
-
|
|
1115
|
+
ge(e);
|
|
758
1116
|
} catch {
|
|
759
1117
|
}
|
|
760
1118
|
else if (e != null) try {
|
|
@@ -762,40 +1120,40 @@ function F(e, t = !1) {
|
|
|
762
1120
|
} catch {
|
|
763
1121
|
}
|
|
764
1122
|
}
|
|
765
|
-
function
|
|
766
|
-
let n = e[0].previousElementSibling, r =
|
|
1123
|
+
function dt(e, t = !0) {
|
|
1124
|
+
let n = e[0].previousElementSibling, r = I(e), o = D(r, {
|
|
767
1125
|
tabbable: t
|
|
768
1126
|
}, e);
|
|
769
1127
|
o.currentNode = n;
|
|
770
1128
|
let i = o.nextNode();
|
|
771
|
-
return t && !i && (r =
|
|
1129
|
+
return t && !i && (r = I(e), o = D(r, {
|
|
772
1130
|
tabbable: !1
|
|
773
1131
|
}, e), o.currentNode = n, i = o.nextNode()), i;
|
|
774
1132
|
}
|
|
775
|
-
function
|
|
776
|
-
|
|
1133
|
+
function Te(e, t = !0) {
|
|
1134
|
+
P(dt(e, t));
|
|
777
1135
|
}
|
|
778
|
-
function
|
|
779
|
-
const n =
|
|
780
|
-
|
|
1136
|
+
function On(e, t) {
|
|
1137
|
+
const n = m.useRef(t);
|
|
1138
|
+
_(() => {
|
|
781
1139
|
if (n.current) {
|
|
782
|
-
|
|
783
|
-
const r =
|
|
784
|
-
!
|
|
1140
|
+
$ = e;
|
|
1141
|
+
const r = w(e.current ? e.current[0] : void 0);
|
|
1142
|
+
!x(T(r), $.current) && e.current && Te(e.current);
|
|
785
1143
|
}
|
|
786
1144
|
n.current = !1;
|
|
787
1145
|
}, [
|
|
788
1146
|
e
|
|
789
1147
|
]);
|
|
790
1148
|
}
|
|
791
|
-
function
|
|
792
|
-
|
|
1149
|
+
function Mn(e, t, n) {
|
|
1150
|
+
g(() => {
|
|
793
1151
|
if (t || n) return;
|
|
794
1152
|
let r = e.current;
|
|
795
|
-
const o =
|
|
1153
|
+
const o = w(r ? r[0] : void 0);
|
|
796
1154
|
let i = (a) => {
|
|
797
|
-
let
|
|
798
|
-
|
|
1155
|
+
let l = y(a);
|
|
1156
|
+
x(l, e.current) ? $ = e : ut(l) || ($ = null);
|
|
799
1157
|
};
|
|
800
1158
|
return o.addEventListener("focusin", i, !1), r?.forEach((a) => a.addEventListener("focusin", i, !1)), () => {
|
|
801
1159
|
o.removeEventListener("focusin", i, !1), r?.forEach((a) => a.removeEventListener("focusin", i, !1));
|
|
@@ -806,49 +1164,49 @@ function Zt(e, t, n) {
|
|
|
806
1164
|
n
|
|
807
1165
|
]);
|
|
808
1166
|
}
|
|
809
|
-
function
|
|
810
|
-
let t =
|
|
1167
|
+
function Ke(e) {
|
|
1168
|
+
let t = E.getTreeNode($);
|
|
811
1169
|
for (; t && t.scopeRef !== e; ) {
|
|
812
1170
|
if (t.nodeToRestore) return !1;
|
|
813
1171
|
t = t.parent;
|
|
814
1172
|
}
|
|
815
1173
|
return t?.scopeRef === e;
|
|
816
1174
|
}
|
|
817
|
-
function
|
|
818
|
-
const r =
|
|
819
|
-
|
|
1175
|
+
function Rn(e, t, n) {
|
|
1176
|
+
const r = h(typeof document < "u" ? T(w(e.current ? e.current[0] : void 0)) : null);
|
|
1177
|
+
g(() => {
|
|
820
1178
|
let o = e.current;
|
|
821
|
-
const i =
|
|
1179
|
+
const i = w(o ? o[0] : void 0);
|
|
822
1180
|
if (!t || n) return;
|
|
823
1181
|
let a = () => {
|
|
824
|
-
(
|
|
1182
|
+
(!$ || ce($, e)) && x(T(i), e.current) && ($ = e);
|
|
825
1183
|
};
|
|
826
|
-
return i.addEventListener("focusin", a, !1), o?.forEach((
|
|
827
|
-
i.removeEventListener("focusin", a, !1), o?.forEach((
|
|
1184
|
+
return i.addEventListener("focusin", a, !1), o?.forEach((l) => l.addEventListener("focusin", a, !1)), () => {
|
|
1185
|
+
i.removeEventListener("focusin", a, !1), o?.forEach((l) => l.removeEventListener("focusin", a, !1));
|
|
828
1186
|
};
|
|
829
1187
|
}, [
|
|
830
1188
|
e,
|
|
831
1189
|
n
|
|
832
|
-
]),
|
|
833
|
-
const o =
|
|
1190
|
+
]), g(() => {
|
|
1191
|
+
const o = w(e.current ? e.current[0] : void 0);
|
|
834
1192
|
if (!t) return;
|
|
835
1193
|
let i = (a) => {
|
|
836
|
-
if (a.key !== "Tab" || a.altKey || a.ctrlKey || a.metaKey || !
|
|
837
|
-
let
|
|
838
|
-
if (!
|
|
839
|
-
let
|
|
840
|
-
if (!
|
|
841
|
-
let
|
|
1194
|
+
if (a.key !== "Tab" || a.altKey || a.ctrlKey || a.metaKey || !z(e) || a.isComposing) return;
|
|
1195
|
+
let l = o.activeElement;
|
|
1196
|
+
if (!R(l, e) || !Ke(e)) return;
|
|
1197
|
+
let s = E.getTreeNode(e);
|
|
1198
|
+
if (!s) return;
|
|
1199
|
+
let c = s.nodeToRestore, u = D(o.body, {
|
|
842
1200
|
tabbable: !0
|
|
843
1201
|
});
|
|
844
|
-
|
|
845
|
-
let d = a.shiftKey ?
|
|
846
|
-
if ((!
|
|
847
|
-
|
|
1202
|
+
u.currentNode = l;
|
|
1203
|
+
let d = a.shiftKey ? u.previousNode() : u.nextNode();
|
|
1204
|
+
if ((!c || !c.isConnected || c === o.body) && (c = void 0, s.nodeToRestore = void 0), (!d || !R(d, e)) && c) {
|
|
1205
|
+
u.currentNode = c;
|
|
848
1206
|
do
|
|
849
|
-
d = a.shiftKey ?
|
|
850
|
-
while (
|
|
851
|
-
a.preventDefault(), a.stopPropagation(), d ?
|
|
1207
|
+
d = a.shiftKey ? u.previousNode() : u.nextNode();
|
|
1208
|
+
while (R(d, e));
|
|
1209
|
+
a.preventDefault(), a.stopPropagation(), d ? P(d, !0) : ut(c) ? P(c, !0) : l.blur();
|
|
852
1210
|
}
|
|
853
1211
|
};
|
|
854
1212
|
return n || o.addEventListener("keydown", i, !0), () => {
|
|
@@ -858,36 +1216,35 @@ function tn(e, t, n) {
|
|
|
858
1216
|
e,
|
|
859
1217
|
t,
|
|
860
1218
|
n
|
|
861
|
-
]),
|
|
862
|
-
const o =
|
|
1219
|
+
]), g(() => {
|
|
1220
|
+
const o = w(e.current ? e.current[0] : void 0);
|
|
863
1221
|
if (!t) return;
|
|
864
|
-
let i =
|
|
1222
|
+
let i = E.getTreeNode(e);
|
|
865
1223
|
if (i) {
|
|
866
1224
|
var a;
|
|
867
1225
|
return i.nodeToRestore = (a = r.current) !== null && a !== void 0 ? a : void 0, () => {
|
|
868
|
-
let
|
|
869
|
-
if (!
|
|
870
|
-
let
|
|
871
|
-
if (t &&
|
|
872
|
-
|
|
873
|
-
let l = $.clone();
|
|
1226
|
+
let l = E.getTreeNode(e);
|
|
1227
|
+
if (!l) return;
|
|
1228
|
+
let s = l.nodeToRestore, c = T(o);
|
|
1229
|
+
if (t && s && (c && R(c, e) || c === o.body && Ke(e))) {
|
|
1230
|
+
let u = E.clone();
|
|
874
1231
|
requestAnimationFrame(() => {
|
|
875
1232
|
if (o.activeElement === o.body) {
|
|
876
|
-
let
|
|
877
|
-
for (;
|
|
878
|
-
if (
|
|
879
|
-
|
|
1233
|
+
let d = u.getTreeNode(e);
|
|
1234
|
+
for (; d; ) {
|
|
1235
|
+
if (d.nodeToRestore && d.nodeToRestore.isConnected) {
|
|
1236
|
+
Ve(d.nodeToRestore);
|
|
880
1237
|
return;
|
|
881
1238
|
}
|
|
882
|
-
|
|
1239
|
+
d = d.parent;
|
|
883
1240
|
}
|
|
884
|
-
for (
|
|
885
|
-
if (
|
|
886
|
-
let
|
|
887
|
-
|
|
1241
|
+
for (d = u.getTreeNode(e); d; ) {
|
|
1242
|
+
if (d.scopeRef && d.scopeRef.current && E.getTreeNode(d.scopeRef)) {
|
|
1243
|
+
let f = dt(d.scopeRef.current, !0);
|
|
1244
|
+
Ve(f);
|
|
888
1245
|
return;
|
|
889
1246
|
}
|
|
890
|
-
|
|
1247
|
+
d = d.parent;
|
|
891
1248
|
}
|
|
892
1249
|
}
|
|
893
1250
|
});
|
|
@@ -899,22 +1256,21 @@ function tn(e, t, n) {
|
|
|
899
1256
|
t
|
|
900
1257
|
]);
|
|
901
1258
|
}
|
|
902
|
-
function
|
|
903
|
-
e.dispatchEvent(new CustomEvent(
|
|
1259
|
+
function Ve(e) {
|
|
1260
|
+
e.dispatchEvent(new CustomEvent(ye, {
|
|
904
1261
|
bubbles: !0,
|
|
905
1262
|
cancelable: !0
|
|
906
|
-
})) &&
|
|
1263
|
+
})) && P(e);
|
|
907
1264
|
}
|
|
908
|
-
function
|
|
909
|
-
let r = t?.tabbable ?
|
|
910
|
-
acceptNode(
|
|
911
|
-
|
|
912
|
-
return !(t == null || (a = t.from) === null || a === void 0) && a.contains(i) ? NodeFilter.FILTER_REJECT : i.matches(r) && Ve(i) && (!n || w(i, n)) && (!t?.accept || t.accept(i)) ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
|
|
1265
|
+
function D(e, t, n) {
|
|
1266
|
+
let r = t?.tabbable ? bn : vn, o = e?.nodeType === Node.ELEMENT_NODE ? e : null, i = w(o), a = Vt(i, e || i, NodeFilter.SHOW_ELEMENT, {
|
|
1267
|
+
acceptNode(l) {
|
|
1268
|
+
return F(t?.from, l) || t?.tabbable && l.tagName === "INPUT" && l.getAttribute("type") === "radio" && (!Cn(l) || a.currentNode.tagName === "INPUT" && a.currentNode.type === "radio" && a.currentNode.name === l.name) ? NodeFilter.FILTER_REJECT : r(l) && (!n || x(l, n)) && (!t?.accept || t.accept(l)) ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
|
|
913
1269
|
}
|
|
914
1270
|
});
|
|
915
|
-
return t?.from && (
|
|
1271
|
+
return t?.from && (a.currentNode = t.from), a;
|
|
916
1272
|
}
|
|
917
|
-
class
|
|
1273
|
+
class _e {
|
|
918
1274
|
get size() {
|
|
919
1275
|
return this.fastMap.size;
|
|
920
1276
|
}
|
|
@@ -924,7 +1280,7 @@ class me {
|
|
|
924
1280
|
addTreeNode(t, n, r) {
|
|
925
1281
|
let o = this.fastMap.get(n ?? null);
|
|
926
1282
|
if (!o) return;
|
|
927
|
-
let i = new
|
|
1283
|
+
let i = new Ne({
|
|
928
1284
|
scopeRef: t
|
|
929
1285
|
});
|
|
930
1286
|
o.addChild(i), i.parent = o, this.fastMap.set(t, i), r && (i.nodeToRestore = r);
|
|
@@ -937,7 +1293,7 @@ class me {
|
|
|
937
1293
|
let n = this.fastMap.get(t);
|
|
938
1294
|
if (!n) return;
|
|
939
1295
|
let r = n.parent;
|
|
940
|
-
for (let i of this.traverse()) i !== n && n.nodeToRestore && i.nodeToRestore && n.scopeRef && n.scopeRef.current &&
|
|
1296
|
+
for (let i of this.traverse()) i !== n && n.nodeToRestore && i.nodeToRestore && n.scopeRef && n.scopeRef.current && x(i.nodeToRestore, n.scopeRef.current) && (i.nodeToRestore = n.nodeToRestore);
|
|
941
1297
|
let o = n.children;
|
|
942
1298
|
r && (r.removeChild(n), o.size > 0 && o.forEach((i) => r && r.addChild(i))), this.fastMap.delete(n.scopeRef);
|
|
943
1299
|
}
|
|
@@ -947,18 +1303,18 @@ class me {
|
|
|
947
1303
|
}
|
|
948
1304
|
clone() {
|
|
949
1305
|
var t;
|
|
950
|
-
let n = new
|
|
1306
|
+
let n = new _e();
|
|
951
1307
|
var r;
|
|
952
1308
|
for (let o of this.traverse()) n.addTreeNode(o.scopeRef, (r = (t = o.parent) === null || t === void 0 ? void 0 : t.scopeRef) !== null && r !== void 0 ? r : null, o.nodeToRestore);
|
|
953
1309
|
return n;
|
|
954
1310
|
}
|
|
955
1311
|
constructor() {
|
|
956
|
-
this.fastMap = /* @__PURE__ */ new Map(), this.root = new
|
|
1312
|
+
this.fastMap = /* @__PURE__ */ new Map(), this.root = new Ne({
|
|
957
1313
|
scopeRef: null
|
|
958
1314
|
}), this.fastMap.set(null, this.root);
|
|
959
1315
|
}
|
|
960
1316
|
}
|
|
961
|
-
class
|
|
1317
|
+
class Ne {
|
|
962
1318
|
addChild(t) {
|
|
963
1319
|
this.children.add(t), t.parent = this;
|
|
964
1320
|
}
|
|
@@ -969,55 +1325,55 @@ class fe {
|
|
|
969
1325
|
this.children = /* @__PURE__ */ new Set(), this.contain = !1, this.scopeRef = t.scopeRef;
|
|
970
1326
|
}
|
|
971
1327
|
}
|
|
972
|
-
let
|
|
973
|
-
const
|
|
974
|
-
function
|
|
975
|
-
let { onClose: n, shouldCloseOnBlur: r, isOpen: o, isDismissable: i = !1, isKeyboardDismissDisabled: a = !1, shouldCloseOnInteractOutside:
|
|
976
|
-
|
|
977
|
-
let
|
|
978
|
-
|
|
1328
|
+
let E = new _e();
|
|
1329
|
+
const Dn = /* @__PURE__ */ new WeakMap(), C = [];
|
|
1330
|
+
function An(e, t) {
|
|
1331
|
+
let { onClose: n, shouldCloseOnBlur: r, isOpen: o, isDismissable: i = !1, isKeyboardDismissDisabled: a = !1, shouldCloseOnInteractOutside: l } = e;
|
|
1332
|
+
_(() => (o && C.push(t), () => {
|
|
1333
|
+
let b = C.indexOf(t);
|
|
1334
|
+
b >= 0 && C.splice(b, 1);
|
|
979
1335
|
}), [
|
|
980
1336
|
o,
|
|
981
1337
|
t
|
|
982
1338
|
]);
|
|
983
|
-
let
|
|
984
|
-
|
|
985
|
-
},
|
|
986
|
-
(!
|
|
987
|
-
},
|
|
988
|
-
(!
|
|
989
|
-
}, d = (
|
|
990
|
-
|
|
1339
|
+
let s = () => {
|
|
1340
|
+
C[C.length - 1] === t && n && n();
|
|
1341
|
+
}, c = (b) => {
|
|
1342
|
+
(!l || l(b.target)) && C[C.length - 1] === t && (b.stopPropagation(), b.preventDefault());
|
|
1343
|
+
}, u = (b) => {
|
|
1344
|
+
(!l || l(b.target)) && (C[C.length - 1] === t && (b.stopPropagation(), b.preventDefault()), s());
|
|
1345
|
+
}, d = (b) => {
|
|
1346
|
+
b.key === "Escape" && !a && !b.nativeEvent.isComposing && (b.stopPropagation(), b.preventDefault(), s());
|
|
991
1347
|
};
|
|
992
|
-
|
|
1348
|
+
Sn({
|
|
993
1349
|
ref: t,
|
|
994
|
-
onInteractOutside: i && o ?
|
|
995
|
-
onInteractOutsideStart:
|
|
1350
|
+
onInteractOutside: i && o ? u : null,
|
|
1351
|
+
onInteractOutsideStart: c
|
|
996
1352
|
});
|
|
997
|
-
let { focusWithinProps:
|
|
1353
|
+
let { focusWithinProps: f } = kn({
|
|
998
1354
|
isDisabled: !r,
|
|
999
|
-
onBlurWithin: (
|
|
1000
|
-
!
|
|
1355
|
+
onBlurWithin: (b) => {
|
|
1356
|
+
!b.relatedTarget || Pn(b.relatedTarget) || (!l || l(b.relatedTarget)) && n();
|
|
1001
1357
|
}
|
|
1002
|
-
}),
|
|
1003
|
-
|
|
1358
|
+
}), p = (b) => {
|
|
1359
|
+
b.target === b.currentTarget && b.preventDefault();
|
|
1004
1360
|
};
|
|
1005
1361
|
return {
|
|
1006
1362
|
overlayProps: {
|
|
1007
1363
|
onKeyDown: d,
|
|
1008
|
-
...
|
|
1364
|
+
...f
|
|
1009
1365
|
},
|
|
1010
1366
|
underlayProps: {
|
|
1011
|
-
onPointerDown:
|
|
1367
|
+
onPointerDown: p
|
|
1012
1368
|
}
|
|
1013
1369
|
};
|
|
1014
1370
|
}
|
|
1015
|
-
function
|
|
1371
|
+
function In(e, t, n) {
|
|
1016
1372
|
let { isOpen: r } = t;
|
|
1017
|
-
|
|
1018
|
-
n && n.current &&
|
|
1373
|
+
_(() => {
|
|
1374
|
+
n && n.current && Dn.set(n.current, t.close);
|
|
1019
1375
|
});
|
|
1020
|
-
let o, i =
|
|
1376
|
+
let o, i = Je();
|
|
1021
1377
|
return {
|
|
1022
1378
|
triggerProps: {
|
|
1023
1379
|
"aria-haspopup": o,
|
|
@@ -1030,7 +1386,7 @@ function on(e, t, n) {
|
|
|
1030
1386
|
}
|
|
1031
1387
|
};
|
|
1032
1388
|
}
|
|
1033
|
-
const
|
|
1389
|
+
const $e = typeof document < "u" && window.visualViewport, Wn = /* @__PURE__ */ new Set([
|
|
1034
1390
|
"checkbox",
|
|
1035
1391
|
"radio",
|
|
1036
1392
|
"range",
|
|
@@ -1041,81 +1397,81 @@ const ae = typeof document < "u" && window.visualViewport, an = /* @__PURE__ */
|
|
|
1041
1397
|
"submit",
|
|
1042
1398
|
"reset"
|
|
1043
1399
|
]);
|
|
1044
|
-
let
|
|
1045
|
-
function
|
|
1400
|
+
let oe = 0, me;
|
|
1401
|
+
function Kn(e = {}) {
|
|
1046
1402
|
let { isDisabled: t } = e;
|
|
1047
|
-
|
|
1403
|
+
g(() => {
|
|
1048
1404
|
if (!t)
|
|
1049
|
-
return
|
|
1050
|
-
|
|
1405
|
+
return oe++, oe === 1 && (Qe() ? me = Bn() : me = Vn()), () => {
|
|
1406
|
+
oe--, oe === 0 && me();
|
|
1051
1407
|
};
|
|
1052
1408
|
}, [
|
|
1053
1409
|
t
|
|
1054
1410
|
]);
|
|
1055
1411
|
}
|
|
1056
|
-
function
|
|
1057
|
-
return
|
|
1412
|
+
function Vn() {
|
|
1413
|
+
return le(V(document.documentElement, "paddingRight", `${window.innerWidth - document.documentElement.clientWidth}px`), V(document.documentElement, "overflow", "hidden"));
|
|
1058
1414
|
}
|
|
1059
|
-
function
|
|
1060
|
-
let e, t, n = (
|
|
1061
|
-
e =
|
|
1062
|
-
}, r = (
|
|
1415
|
+
function Bn() {
|
|
1416
|
+
let e, t, n = (c) => {
|
|
1417
|
+
e = tt(c.target, !0), !(e === document.documentElement && e === document.body) && e instanceof HTMLElement && window.getComputedStyle(e).overscrollBehavior === "auto" && (t = V(e, "overscrollBehavior", "contain"));
|
|
1418
|
+
}, r = (c) => {
|
|
1063
1419
|
if (!e || e === document.documentElement || e === document.body) {
|
|
1064
|
-
|
|
1420
|
+
c.preventDefault();
|
|
1065
1421
|
return;
|
|
1066
1422
|
}
|
|
1067
|
-
e.scrollHeight === e.clientHeight && e.scrollWidth === e.clientWidth &&
|
|
1068
|
-
}, o = (
|
|
1069
|
-
let
|
|
1070
|
-
|
|
1071
|
-
|
|
1423
|
+
e.scrollHeight === e.clientHeight && e.scrollWidth === e.clientWidth && c.preventDefault();
|
|
1424
|
+
}, o = (c) => {
|
|
1425
|
+
let u = c.target;
|
|
1426
|
+
He(u) && u !== document.activeElement && (c.preventDefault(), l(), u.style.transform = "translateY(-2000px)", u.focus(), requestAnimationFrame(() => {
|
|
1427
|
+
u.style.transform = "";
|
|
1072
1428
|
})), t && t();
|
|
1073
|
-
}, i = (
|
|
1074
|
-
let
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
}) :
|
|
1429
|
+
}, i = (c) => {
|
|
1430
|
+
let u = c.target;
|
|
1431
|
+
He(u) && (l(), u.style.transform = "translateY(-2000px)", requestAnimationFrame(() => {
|
|
1432
|
+
u.style.transform = "", $e && ($e.height < window.innerHeight ? requestAnimationFrame(() => {
|
|
1433
|
+
Be(u);
|
|
1434
|
+
}) : $e.addEventListener("resize", () => Be(u), {
|
|
1079
1435
|
once: !0
|
|
1080
1436
|
}));
|
|
1081
1437
|
}));
|
|
1082
|
-
}, a = null,
|
|
1438
|
+
}, a = null, l = () => {
|
|
1083
1439
|
if (a) return;
|
|
1084
|
-
let
|
|
1440
|
+
let c = () => {
|
|
1085
1441
|
window.scrollTo(0, 0);
|
|
1086
|
-
},
|
|
1087
|
-
a =
|
|
1088
|
-
window.scrollTo(
|
|
1442
|
+
}, u = window.pageXOffset, d = window.pageYOffset;
|
|
1443
|
+
a = le(j(window, "scroll", c), V(document.documentElement, "paddingRight", `${window.innerWidth - document.documentElement.clientWidth}px`), V(document.documentElement, "overflow", "hidden"), V(document.body, "marginTop", `-${d}px`), () => {
|
|
1444
|
+
window.scrollTo(u, d);
|
|
1089
1445
|
}), window.scrollTo(0, 0);
|
|
1090
|
-
},
|
|
1446
|
+
}, s = le(j(document, "touchstart", n, {
|
|
1091
1447
|
passive: !1,
|
|
1092
1448
|
capture: !0
|
|
1093
|
-
}),
|
|
1449
|
+
}), j(document, "touchmove", r, {
|
|
1094
1450
|
passive: !1,
|
|
1095
1451
|
capture: !0
|
|
1096
|
-
}),
|
|
1452
|
+
}), j(document, "touchend", o, {
|
|
1097
1453
|
passive: !1,
|
|
1098
1454
|
capture: !0
|
|
1099
|
-
}),
|
|
1455
|
+
}), j(document, "focus", i, !0));
|
|
1100
1456
|
return () => {
|
|
1101
|
-
t?.(), a?.(),
|
|
1457
|
+
t?.(), a?.(), s();
|
|
1102
1458
|
};
|
|
1103
1459
|
}
|
|
1104
|
-
function
|
|
1460
|
+
function V(e, t, n) {
|
|
1105
1461
|
let r = e.style[t];
|
|
1106
1462
|
return e.style[t] = n, () => {
|
|
1107
1463
|
e.style[t] = r;
|
|
1108
1464
|
};
|
|
1109
1465
|
}
|
|
1110
|
-
function
|
|
1466
|
+
function j(e, t, n, r) {
|
|
1111
1467
|
return e.addEventListener(t, n, r), () => {
|
|
1112
1468
|
e.removeEventListener(t, n, r);
|
|
1113
1469
|
};
|
|
1114
1470
|
}
|
|
1115
|
-
function
|
|
1471
|
+
function Be(e) {
|
|
1116
1472
|
let t = document.scrollingElement || document.documentElement;
|
|
1117
1473
|
for (; e && e !== t; ) {
|
|
1118
|
-
let n =
|
|
1474
|
+
let n = tt(e);
|
|
1119
1475
|
if (n !== document.documentElement && n !== document.body && n !== e) {
|
|
1120
1476
|
let r = n.getBoundingClientRect().top, o = e.getBoundingClientRect().top;
|
|
1121
1477
|
o > r + e.clientHeight && (n.scrollTop += o - r);
|
|
@@ -1123,48 +1479,48 @@ function Se(e) {
|
|
|
1123
1479
|
e = n.parentElement;
|
|
1124
1480
|
}
|
|
1125
1481
|
}
|
|
1126
|
-
function
|
|
1127
|
-
return e instanceof HTMLInputElement && !
|
|
1128
|
-
}
|
|
1129
|
-
let
|
|
1130
|
-
function
|
|
1131
|
-
let n = new Set(e), r = /* @__PURE__ */ new Set(), o = (
|
|
1132
|
-
for (let
|
|
1133
|
-
let
|
|
1134
|
-
if (n.has(
|
|
1135
|
-
for (let
|
|
1136
|
-
if (
|
|
1482
|
+
function He(e) {
|
|
1483
|
+
return e instanceof HTMLInputElement && !Wn.has(e.type) || e instanceof HTMLTextAreaElement || e instanceof HTMLElement && e.isContentEditable;
|
|
1484
|
+
}
|
|
1485
|
+
let q = /* @__PURE__ */ new WeakMap(), k = [];
|
|
1486
|
+
function Hn(e, t = document.body) {
|
|
1487
|
+
let n = new Set(e), r = /* @__PURE__ */ new Set(), o = (s) => {
|
|
1488
|
+
for (let f of s.querySelectorAll("[data-live-announcer], [data-react-aria-top-layer]")) n.add(f);
|
|
1489
|
+
let c = (f) => {
|
|
1490
|
+
if (n.has(f) || r.has(f.parentElement) && f.parentElement.getAttribute("role") !== "row") return NodeFilter.FILTER_REJECT;
|
|
1491
|
+
for (let p of n)
|
|
1492
|
+
if (f.contains(p)) return NodeFilter.FILTER_SKIP;
|
|
1137
1493
|
return NodeFilter.FILTER_ACCEPT;
|
|
1138
|
-
},
|
|
1139
|
-
acceptNode:
|
|
1140
|
-
}), d =
|
|
1141
|
-
if (d === NodeFilter.FILTER_ACCEPT && i(
|
|
1142
|
-
let
|
|
1143
|
-
for (;
|
|
1144
|
-
i(
|
|
1494
|
+
}, u = document.createTreeWalker(s, NodeFilter.SHOW_ELEMENT, {
|
|
1495
|
+
acceptNode: c
|
|
1496
|
+
}), d = c(s);
|
|
1497
|
+
if (d === NodeFilter.FILTER_ACCEPT && i(s), d !== NodeFilter.FILTER_REJECT) {
|
|
1498
|
+
let f = u.nextNode();
|
|
1499
|
+
for (; f != null; )
|
|
1500
|
+
i(f), f = u.nextNode();
|
|
1145
1501
|
}
|
|
1146
|
-
}, i = (
|
|
1147
|
-
var
|
|
1148
|
-
let
|
|
1149
|
-
|
|
1502
|
+
}, i = (s) => {
|
|
1503
|
+
var c;
|
|
1504
|
+
let u = (c = q.get(s)) !== null && c !== void 0 ? c : 0;
|
|
1505
|
+
s.getAttribute("aria-hidden") === "true" && u === 0 || (u === 0 && s.setAttribute("aria-hidden", "true"), r.add(s), q.set(s, u + 1));
|
|
1150
1506
|
};
|
|
1151
|
-
|
|
1152
|
-
let a = new MutationObserver((
|
|
1153
|
-
for (let
|
|
1154
|
-
if (!(
|
|
1507
|
+
k.length && k[k.length - 1].disconnect(), o(t);
|
|
1508
|
+
let a = new MutationObserver((s) => {
|
|
1509
|
+
for (let c of s)
|
|
1510
|
+
if (!(c.type !== "childList" || c.addedNodes.length === 0) && ![
|
|
1155
1511
|
...n,
|
|
1156
1512
|
...r
|
|
1157
|
-
].some((
|
|
1158
|
-
for (let
|
|
1159
|
-
for (let
|
|
1160
|
-
(
|
|
1513
|
+
].some((u) => u.contains(c.target))) {
|
|
1514
|
+
for (let u of c.removedNodes) u instanceof Element && (n.delete(u), r.delete(u));
|
|
1515
|
+
for (let u of c.addedNodes)
|
|
1516
|
+
(u instanceof HTMLElement || u instanceof SVGElement) && (u.dataset.liveAnnouncer === "true" || u.dataset.reactAriaTopLayer === "true") ? n.add(u) : u instanceof Element && o(u);
|
|
1161
1517
|
}
|
|
1162
1518
|
});
|
|
1163
1519
|
a.observe(t, {
|
|
1164
1520
|
childList: !0,
|
|
1165
1521
|
subtree: !0
|
|
1166
1522
|
});
|
|
1167
|
-
let
|
|
1523
|
+
let l = {
|
|
1168
1524
|
observe() {
|
|
1169
1525
|
a.observe(t, {
|
|
1170
1526
|
childList: !0,
|
|
@@ -1175,75 +1531,75 @@ function un(e, t = document.body) {
|
|
|
1175
1531
|
a.disconnect();
|
|
1176
1532
|
}
|
|
1177
1533
|
};
|
|
1178
|
-
return
|
|
1534
|
+
return k.push(l), () => {
|
|
1179
1535
|
a.disconnect();
|
|
1180
|
-
for (let
|
|
1181
|
-
let
|
|
1182
|
-
|
|
1536
|
+
for (let s of r) {
|
|
1537
|
+
let c = q.get(s);
|
|
1538
|
+
c === 1 ? (s.removeAttribute("aria-hidden"), q.delete(s)) : q.set(s, c - 1);
|
|
1183
1539
|
}
|
|
1184
|
-
|
|
1540
|
+
l === k[k.length - 1] ? (k.pop(), k.length && k[k.length - 1].observe()) : k.splice(k.indexOf(l), 1);
|
|
1185
1541
|
};
|
|
1186
1542
|
}
|
|
1187
|
-
const
|
|
1188
|
-
function
|
|
1543
|
+
const jn = /* @__PURE__ */ yt({});
|
|
1544
|
+
function qn() {
|
|
1189
1545
|
var e;
|
|
1190
|
-
return (e =
|
|
1546
|
+
return (e = H(jn)) !== null && e !== void 0 ? e : {};
|
|
1191
1547
|
}
|
|
1192
|
-
const
|
|
1193
|
-
function
|
|
1194
|
-
let t =
|
|
1548
|
+
const ft = /* @__PURE__ */ m.createContext(null);
|
|
1549
|
+
function Gn(e) {
|
|
1550
|
+
let t = Ue(), { portalContainer: n = t ? null : document.body, isExiting: r } = e, [o, i] = Z(!1), a = U(() => ({
|
|
1195
1551
|
contain: o,
|
|
1196
1552
|
setContain: i
|
|
1197
1553
|
}), [
|
|
1198
1554
|
o,
|
|
1199
1555
|
i
|
|
1200
|
-
]), { getContainer:
|
|
1201
|
-
if (!e.portalContainer &&
|
|
1202
|
-
let
|
|
1203
|
-
return e.disableFocusManagement || (
|
|
1556
|
+
]), { getContainer: l } = qn();
|
|
1557
|
+
if (!e.portalContainer && l && (n = l()), !n) return null;
|
|
1558
|
+
let s = e.children;
|
|
1559
|
+
return e.disableFocusManagement || (s = /* @__PURE__ */ m.createElement(xn, {
|
|
1204
1560
|
restoreFocus: !0,
|
|
1205
1561
|
contain: o && !r
|
|
1206
|
-
},
|
|
1562
|
+
}, s)), s = /* @__PURE__ */ m.createElement(ft.Provider, {
|
|
1207
1563
|
value: a
|
|
1208
|
-
}, /* @__PURE__ */
|
|
1564
|
+
}, /* @__PURE__ */ m.createElement(Nn, null, s)), /* @__PURE__ */ Tt.createPortal(s, n);
|
|
1209
1565
|
}
|
|
1210
|
-
function
|
|
1211
|
-
let e =
|
|
1212
|
-
|
|
1566
|
+
function pt() {
|
|
1567
|
+
let e = H(ft), t = e?.setContain;
|
|
1568
|
+
g(() => {
|
|
1213
1569
|
t?.(!0);
|
|
1214
1570
|
}, [
|
|
1215
1571
|
t
|
|
1216
1572
|
]);
|
|
1217
1573
|
}
|
|
1218
|
-
function
|
|
1219
|
-
let { overlayProps: r, underlayProps: o } =
|
|
1574
|
+
function zn(e, t, n) {
|
|
1575
|
+
let { overlayProps: r, underlayProps: o } = An({
|
|
1220
1576
|
...e,
|
|
1221
1577
|
isOpen: t.isOpen,
|
|
1222
1578
|
onClose: t.close
|
|
1223
1579
|
}, n);
|
|
1224
|
-
return
|
|
1580
|
+
return Kn({
|
|
1225
1581
|
isDisabled: !t.isOpen
|
|
1226
|
-
}),
|
|
1227
|
-
if (t.isOpen) return
|
|
1582
|
+
}), pt(), _(() => {
|
|
1583
|
+
if (t.isOpen) return Hn([
|
|
1228
1584
|
n.current
|
|
1229
1585
|
]);
|
|
1230
1586
|
}, [
|
|
1231
1587
|
t.isOpen,
|
|
1232
1588
|
n
|
|
1233
1589
|
]), {
|
|
1234
|
-
modalProps:
|
|
1590
|
+
modalProps: jt(r),
|
|
1235
1591
|
underlayProps: o
|
|
1236
1592
|
};
|
|
1237
1593
|
}
|
|
1238
|
-
function
|
|
1239
|
-
let { role: n = "dialog" } = e, r =
|
|
1594
|
+
function Un(e, t) {
|
|
1595
|
+
let { role: n = "dialog" } = e, r = Dt();
|
|
1240
1596
|
r = e["aria-label"] ? void 0 : r;
|
|
1241
|
-
let o =
|
|
1242
|
-
return
|
|
1597
|
+
let o = h(!1);
|
|
1598
|
+
return _(() => {
|
|
1243
1599
|
if (t.current && !t.current.contains(document.activeElement)) {
|
|
1244
|
-
|
|
1600
|
+
ge(t.current);
|
|
1245
1601
|
let i = setTimeout(() => {
|
|
1246
|
-
document.activeElement === t.current && (o.current = !0, t.current && (t.current.blur(),
|
|
1602
|
+
document.activeElement === t.current && (o.current = !0, t.current && (t.current.blur(), ge(t.current)), o.current = !1);
|
|
1247
1603
|
}, 500);
|
|
1248
1604
|
return () => {
|
|
1249
1605
|
clearTimeout(i);
|
|
@@ -1251,9 +1607,9 @@ function bn(e, t) {
|
|
|
1251
1607
|
}
|
|
1252
1608
|
}, [
|
|
1253
1609
|
t
|
|
1254
|
-
]),
|
|
1610
|
+
]), pt(), {
|
|
1255
1611
|
dialogProps: {
|
|
1256
|
-
...
|
|
1612
|
+
...Xt(e, {
|
|
1257
1613
|
labelable: !0
|
|
1258
1614
|
}),
|
|
1259
1615
|
role: n,
|
|
@@ -1271,7 +1627,7 @@ function bn(e, t) {
|
|
|
1271
1627
|
}
|
|
1272
1628
|
};
|
|
1273
1629
|
}
|
|
1274
|
-
function
|
|
1630
|
+
function Jn(e, t, n) {
|
|
1275
1631
|
return t in e ? Object.defineProperty(e, t, {
|
|
1276
1632
|
value: n,
|
|
1277
1633
|
enumerable: !0,
|
|
@@ -1279,7 +1635,7 @@ function mn(e, t, n) {
|
|
|
1279
1635
|
writable: !0
|
|
1280
1636
|
}) : e[t] = n, e;
|
|
1281
1637
|
}
|
|
1282
|
-
function
|
|
1638
|
+
function je(e, t) {
|
|
1283
1639
|
var n = Object.keys(e);
|
|
1284
1640
|
if (Object.getOwnPropertySymbols) {
|
|
1285
1641
|
var r = Object.getOwnPropertySymbols(e);
|
|
@@ -1289,51 +1645,51 @@ function Fe(e, t) {
|
|
|
1289
1645
|
}
|
|
1290
1646
|
return n;
|
|
1291
1647
|
}
|
|
1292
|
-
function
|
|
1648
|
+
function qe(e) {
|
|
1293
1649
|
for (var t = 1; t < arguments.length; t++) {
|
|
1294
1650
|
var n = arguments[t] != null ? arguments[t] : {};
|
|
1295
|
-
t % 2 ?
|
|
1296
|
-
|
|
1297
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) :
|
|
1651
|
+
t % 2 ? je(Object(n), !0).forEach(function(r) {
|
|
1652
|
+
Jn(e, r, n[r]);
|
|
1653
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : je(Object(n)).forEach(function(r) {
|
|
1298
1654
|
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(n, r));
|
|
1299
1655
|
});
|
|
1300
1656
|
}
|
|
1301
1657
|
return e;
|
|
1302
1658
|
}
|
|
1303
|
-
var
|
|
1659
|
+
var Xn = (e, t, n) => {
|
|
1304
1660
|
for (var r of Object.keys(e)) {
|
|
1305
1661
|
var o;
|
|
1306
1662
|
if (e[r] !== ((o = t[r]) !== null && o !== void 0 ? o : n[r]))
|
|
1307
1663
|
return !1;
|
|
1308
1664
|
}
|
|
1309
1665
|
return !0;
|
|
1310
|
-
},
|
|
1311
|
-
var n = e.defaultClassName, r =
|
|
1666
|
+
}, Yn = (e) => (t) => {
|
|
1667
|
+
var n = e.defaultClassName, r = qe(qe({}, e.defaultVariants), t);
|
|
1312
1668
|
for (var o in r) {
|
|
1313
1669
|
var i, a = (i = r[o]) !== null && i !== void 0 ? i : e.defaultVariants[o];
|
|
1314
1670
|
if (a != null) {
|
|
1315
|
-
var
|
|
1316
|
-
typeof
|
|
1317
|
-
var
|
|
1671
|
+
var l = a;
|
|
1672
|
+
typeof l == "boolean" && (l = l === !0 ? "true" : "false");
|
|
1673
|
+
var s = (
|
|
1318
1674
|
// @ts-expect-error
|
|
1319
|
-
e.variantClassNames[o][
|
|
1675
|
+
e.variantClassNames[o][l]
|
|
1320
1676
|
);
|
|
1321
|
-
|
|
1677
|
+
s && (n += " " + s);
|
|
1322
1678
|
}
|
|
1323
1679
|
}
|
|
1324
|
-
for (var [
|
|
1325
|
-
|
|
1680
|
+
for (var [c, u] of e.compoundVariants)
|
|
1681
|
+
Xn(c, r, e.defaultVariants) && (n += " " + u);
|
|
1326
1682
|
return n;
|
|
1327
|
-
},
|
|
1328
|
-
function
|
|
1683
|
+
}, Qn = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq0", Zn = Yn({ defaultClassName: "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq1", variantClassNames: { fullWidth: { true: "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq2", false: "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq3" } }, defaultVariants: {}, compoundVariants: [] }), er = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq4", tr = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq5", nr = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq7", rr = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq8", or = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psq9", ir = "pkg_sps-woodland_focused-task__version_8_42_2__hash_1io4psqa";
|
|
1684
|
+
function vt({
|
|
1329
1685
|
children: e,
|
|
1330
1686
|
className: t = "",
|
|
1331
1687
|
...n
|
|
1332
1688
|
}) {
|
|
1333
|
-
return /* @__PURE__ */
|
|
1689
|
+
return /* @__PURE__ */ v.createElement("div", { className: ie(rr, t), ...n }, /* @__PURE__ */ v.createElement("div", { className: ie(or) }, /* @__PURE__ */ v.createElement("div", { className: ie(ir) }, e)));
|
|
1334
1690
|
}
|
|
1335
|
-
|
|
1336
|
-
function
|
|
1691
|
+
Ge.set(vt, { name: "FocusedTaskActions" });
|
|
1692
|
+
function ar({
|
|
1337
1693
|
children: e,
|
|
1338
1694
|
className: t,
|
|
1339
1695
|
"data-testid": n,
|
|
@@ -1341,49 +1697,49 @@ function Nn({
|
|
|
1341
1697
|
onFocus: o,
|
|
1342
1698
|
overlayProps: i,
|
|
1343
1699
|
state: a,
|
|
1344
|
-
onClose:
|
|
1345
|
-
fullWidth:
|
|
1346
|
-
...
|
|
1700
|
+
onClose: l,
|
|
1701
|
+
fullWidth: s = !1,
|
|
1702
|
+
...c
|
|
1347
1703
|
}) {
|
|
1348
|
-
const
|
|
1349
|
-
{ ...
|
|
1704
|
+
const u = v.useRef(null), { modalProps: d, underlayProps: f } = zn(
|
|
1705
|
+
{ ...c },
|
|
1350
1706
|
a,
|
|
1351
|
-
|
|
1352
|
-
), { dialogProps:
|
|
1353
|
-
function
|
|
1354
|
-
|
|
1707
|
+
u
|
|
1708
|
+
), { dialogProps: p, titleProps: b } = Un(c, u), L = Ce(d.onFocus, p.onFocus, o), A = Ce(d.onBlur, p.onBlur, r), te = ht({ "data-testid": n }), [K, fe] = Et(e, [{ type: vt }]);
|
|
1709
|
+
function $t() {
|
|
1710
|
+
l && typeof l == "function" && l(), a.close();
|
|
1355
1711
|
}
|
|
1356
|
-
const
|
|
1357
|
-
|
|
1712
|
+
const mt = /* @__PURE__ */ v.createElement(
|
|
1713
|
+
wt,
|
|
1358
1714
|
{
|
|
1359
1715
|
"aria-label": "Close",
|
|
1360
|
-
onClick:
|
|
1716
|
+
onClick: $t,
|
|
1361
1717
|
kind: "icon",
|
|
1362
1718
|
icon: "x",
|
|
1363
|
-
className:
|
|
1719
|
+
className: tr
|
|
1364
1720
|
}
|
|
1365
1721
|
);
|
|
1366
|
-
return /* @__PURE__ */
|
|
1722
|
+
return /* @__PURE__ */ v.createElement(Gn, null, /* @__PURE__ */ v.createElement("div", { className: nr, ...f, ...c }, /* @__PURE__ */ v.createElement(
|
|
1367
1723
|
"div",
|
|
1368
1724
|
{
|
|
1369
1725
|
...d,
|
|
1370
|
-
...
|
|
1726
|
+
...p,
|
|
1371
1727
|
...i,
|
|
1372
|
-
onFocus:
|
|
1373
|
-
onBlur:
|
|
1374
|
-
...
|
|
1375
|
-
ref:
|
|
1376
|
-
className:
|
|
1728
|
+
onFocus: L,
|
|
1729
|
+
onBlur: A,
|
|
1730
|
+
...te("dialog"),
|
|
1731
|
+
ref: u,
|
|
1732
|
+
className: ie(Qn, t)
|
|
1377
1733
|
},
|
|
1378
|
-
/* @__PURE__ */
|
|
1379
|
-
/* @__PURE__ */
|
|
1380
|
-
|
|
1734
|
+
/* @__PURE__ */ v.createElement("div", { ...b, className: er }, mt),
|
|
1735
|
+
/* @__PURE__ */ v.createElement("div", { className: Zn({ fullWidth: s }) }, Fe(fe, a.close)),
|
|
1736
|
+
K && K.length > 0 && /* @__PURE__ */ v.createElement(v.Fragment, null, Fe(K, a.close))
|
|
1381
1737
|
)));
|
|
1382
1738
|
}
|
|
1383
|
-
function
|
|
1384
|
-
return e.state.isOpen ? /* @__PURE__ */
|
|
1739
|
+
function bt(e) {
|
|
1740
|
+
return e.state.isOpen ? /* @__PURE__ */ v.createElement(ar, { ...e }, e.children) : /* @__PURE__ */ v.createElement(v.Fragment, null);
|
|
1385
1741
|
}
|
|
1386
|
-
|
|
1742
|
+
Ge.set(bt, {
|
|
1387
1743
|
name: "FocusedTask",
|
|
1388
1744
|
props: {
|
|
1389
1745
|
fullWidth: { type: "boolean", default: "false" },
|
|
@@ -1392,17 +1748,17 @@ Le.set(Ge, {
|
|
|
1392
1748
|
onFocus: { type: "() => void" }
|
|
1393
1749
|
}
|
|
1394
1750
|
});
|
|
1395
|
-
function
|
|
1396
|
-
let [t, n] =
|
|
1397
|
-
const r =
|
|
1751
|
+
function lr(e) {
|
|
1752
|
+
let [t, n] = mn(e.isOpen, e.defaultOpen || !1, e.onOpenChange);
|
|
1753
|
+
const r = N(() => {
|
|
1398
1754
|
n(!0);
|
|
1399
1755
|
}, [
|
|
1400
1756
|
n
|
|
1401
|
-
]), o =
|
|
1757
|
+
]), o = N(() => {
|
|
1402
1758
|
n(!1);
|
|
1403
1759
|
}, [
|
|
1404
1760
|
n
|
|
1405
|
-
]), i =
|
|
1761
|
+
]), i = N(() => {
|
|
1406
1762
|
n(!t);
|
|
1407
1763
|
}, [
|
|
1408
1764
|
n,
|
|
@@ -1416,30 +1772,31 @@ function Fn(e) {
|
|
|
1416
1772
|
toggle: i
|
|
1417
1773
|
};
|
|
1418
1774
|
}
|
|
1419
|
-
function
|
|
1420
|
-
const t =
|
|
1775
|
+
function vr(e = {}) {
|
|
1776
|
+
const t = lr(e), n = h(null), { triggerProps: r, overlayProps: o } = In({}, t, n), { onPress: i, ...a } = r;
|
|
1421
1777
|
return {
|
|
1422
1778
|
triggerProps: {
|
|
1423
1779
|
...a,
|
|
1424
|
-
|
|
1780
|
+
// Forward event to onPress (types differ but handler doesn't inspect event)
|
|
1781
|
+
onClick: i ? (l) => i(l) : void 0,
|
|
1425
1782
|
ref: n
|
|
1426
1783
|
},
|
|
1427
1784
|
focusedTaskState: t,
|
|
1428
1785
|
focusedTaskProps: { overlayProps: o, state: t }
|
|
1429
1786
|
};
|
|
1430
1787
|
}
|
|
1431
|
-
const
|
|
1432
|
-
components: [
|
|
1788
|
+
const sr = {
|
|
1789
|
+
components: [bt],
|
|
1433
1790
|
examples: {
|
|
1434
1791
|
hooks: {
|
|
1435
1792
|
label: "Using the Hook",
|
|
1436
|
-
description: () => /* @__PURE__ */
|
|
1793
|
+
description: () => /* @__PURE__ */ v.createElement(v.Fragment, null, /* @__PURE__ */ v.createElement("p", null, "To use the focused task component, you must call the ", /* @__PURE__ */ v.createElement("code", null, "useFocusedTask"), " hook. Optional arguments for this hook include:"), /* @__PURE__ */ v.createElement("dl", null, /* @__PURE__ */ v.createElement("dt", null, /* @__PURE__ */ v.createElement("code", null, "isOpen"), ": boolean"), /* @__PURE__ */ v.createElement("dd", null, "Whether the overlay is open by default (controlled)"), /* @__PURE__ */ v.createElement("dt", null, /* @__PURE__ */ v.createElement("code", null, "defaultOpen"), ": boolean"), /* @__PURE__ */ v.createElement("dd", null, "Whether the overlay is open by default (uncontrolled)."), /* @__PURE__ */ v.createElement("dt", null, /* @__PURE__ */ v.createElement("code", null, "onOpenChange"), ": function"), /* @__PURE__ */ v.createElement("dd", null, "Handler that is called when the overlay's open state changes.", /* @__PURE__ */ v.createElement("code", null, "(isOpen: boolean) => void"))), /* @__PURE__ */ v.createElement("h5", null, "Focused Task Props, Focused Task State, and Trigger Props"), /* @__PURE__ */ v.createElement("p", null, "The ", /* @__PURE__ */ v.createElement("code", null, "useFocusedTask"), " returns an object with ", /* @__PURE__ */ v.createElement("code", null, "focusedTaskProps"), ",", " ", /* @__PURE__ */ v.createElement("code", null, "focusedTaskState"), " and ", /* @__PURE__ */ v.createElement("code", null, "triggerProps")), /* @__PURE__ */ v.createElement("p", null, "The ", /* @__PURE__ */ v.createElement("code", null, "triggerProps"), " need to be spread on the element that triggers the focused task."), /* @__PURE__ */ v.createElement("p", null, "The ", /* @__PURE__ */ v.createElement("code", null, "focusedTaskState"), " object (which is also included in ", /* @__PURE__ */ v.createElement("code", null, "focusedTaskProps"), ") allows programmatic access to the state of the focused task. This includes a read only", " ", /* @__PURE__ */ v.createElement("code", null, "isOpen"), " property, a ", /* @__PURE__ */ v.createElement("code", null, "setOpen(isOpen: boolean)"), " method which can be use to set whether the overlay is open, an ", /* @__PURE__ */ v.createElement("code", null, "open()"), " method which opens the overlay, a ", /* @__PURE__ */ v.createElement("code", null, "close()"), " method which closes the overlay and a", " ", /* @__PURE__ */ v.createElement("code", null, "toggle()"), " method that toggles the overlay's visiblity."), /* @__PURE__ */ v.createElement("p", null, "The ", /* @__PURE__ */ v.createElement("code", null, "focusedTaskProps"), " should be spread on the actual ", /* @__PURE__ */ v.createElement("code", null, "FocusedTask"), " component."), /* @__PURE__ */ v.createElement("p", null, "Please refer to the examples to see its implementation"))
|
|
1437
1794
|
},
|
|
1438
1795
|
standard: {
|
|
1439
1796
|
label: "Standard",
|
|
1440
1797
|
examples: {
|
|
1441
1798
|
basic: {
|
|
1442
|
-
react:
|
|
1799
|
+
react: Pe`
|
|
1443
1800
|
import { FocusedTask, FocusedTaskActions, useFocusedTask } from "@sps-woodland/focused-task";
|
|
1444
1801
|
import { Button } from "@sps-woodland/buttons";
|
|
1445
1802
|
import { Card } from "@sps-woodland/cards";
|
|
@@ -1485,7 +1842,7 @@ const Pn = {
|
|
|
1485
1842
|
label: "Fill Width",
|
|
1486
1843
|
examples: {
|
|
1487
1844
|
basic: {
|
|
1488
|
-
react:
|
|
1845
|
+
react: Pe`
|
|
1489
1846
|
import { FocusedTask, FocusedTaskActions, useFocusedTask } from "@sps-woodland/focused-task";
|
|
1490
1847
|
import { Button } from "@sps-woodland/buttons";
|
|
1491
1848
|
import { Card } from "@sps-woodland/cards";
|
|
@@ -1529,12 +1886,12 @@ const Pn = {
|
|
|
1529
1886
|
}
|
|
1530
1887
|
}
|
|
1531
1888
|
}
|
|
1532
|
-
},
|
|
1533
|
-
"Focused Task":
|
|
1889
|
+
}, br = {
|
|
1890
|
+
"Focused Task": sr
|
|
1534
1891
|
};
|
|
1535
1892
|
export {
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1893
|
+
bt as FocusedTask,
|
|
1894
|
+
vt as FocusedTaskActions,
|
|
1895
|
+
br as MANIFEST,
|
|
1896
|
+
vr as useFocusedTask
|
|
1540
1897
|
};
|