@wrdagency/blockout 0.0.13 → 0.0.14

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.
Files changed (59) hide show
  1. package/dist/{2NBKRL7C-C6mXReCE.js → 2NBKRL7C-D-Q0qGRV.js} +3 -3
  2. package/dist/{P7GR5CS5-DNbthaqU.js → P7GR5CS5-qyeuZVEs.js} +1 -1
  3. package/dist/T7VMP3TM-BxgFbvdx.js +2106 -0
  4. package/dist/{UQQRIHDV-CFdrMoqW.js → UQQRIHDV-BGs025hb.js} +2 -2
  5. package/dist/{VIIRIBF3-B585VK9r.js → VIIRIBF3-D9clDhln.js} +1 -1
  6. package/dist/_commonjsHelpers-DaMA6jEr.js +8 -0
  7. package/dist/assets/button.css +1 -0
  8. package/dist/assets/form.css +1 -1
  9. package/dist/assets/index.css +1 -1
  10. package/dist/assets/index10.css +1 -1
  11. package/dist/assets/index11.css +1 -1
  12. package/dist/assets/index12.css +1 -0
  13. package/dist/assets/index13.css +1 -0
  14. package/dist/assets/index2.css +1 -1
  15. package/dist/assets/index3.css +1 -1
  16. package/dist/assets/index4.css +1 -1
  17. package/dist/components/breadcrumbs/index.js +23 -16
  18. package/dist/components/button/{index.d.ts → button.d.ts} +2 -3
  19. package/dist/components/button/button.js +28 -0
  20. package/dist/components/button/icon.d.ts +6 -0
  21. package/dist/components/button/icon.js +10 -0
  22. package/dist/components/button/index.js +6 -26
  23. package/dist/components/controls/base-control/affix.d.ts +6 -0
  24. package/dist/components/controls/base-control/affix.js +15 -0
  25. package/dist/components/controls/base-control/index.js +26 -21
  26. package/dist/components/controls/index.d.ts +1 -0
  27. package/dist/components/controls/index.js +10 -8
  28. package/dist/components/controls/number-control/index.d.ts +1 -1
  29. package/dist/components/controls/number-control/index.js +37 -31
  30. package/dist/components/controls/password-control/index.d.ts +7 -0
  31. package/dist/components/controls/password-control/index.js +114 -0
  32. package/dist/components/controls/select-control/index.js +9 -9
  33. package/dist/components/data-table/column.js +1 -1
  34. package/dist/components/form/components/pagination.js +1 -1
  35. package/dist/components/form/components/step.js +22 -16
  36. package/dist/components/form/index.d.ts +0 -2
  37. package/dist/components/form/types/fields.d.ts +1 -1
  38. package/dist/components/form/types/form.d.ts +1 -1
  39. package/dist/components/index.d.ts +2 -1
  40. package/dist/components/index.js +23 -19
  41. package/dist/components/markdown/index.d.ts +6 -0
  42. package/dist/components/markdown/index.js +25844 -0
  43. package/dist/components/menu/index.js +4 -4
  44. package/dist/components/menu/item.js +1 -1
  45. package/dist/components/menu/items/action.js +1 -1
  46. package/dist/components/menu/items/spacer.js +2 -2
  47. package/dist/components/menu/items/submenu.js +2 -2
  48. package/dist/components/menu/items/toggle.js +1 -1
  49. package/dist/floating-ui.dom-9sqP7IwC.js +1512 -0
  50. package/dist/hooks/index.d.ts +1 -0
  51. package/dist/hooks/index.js +4 -0
  52. package/dist/hooks/theme.d.ts +8 -0
  53. package/dist/hooks/theme.js +45 -0
  54. package/dist/index.d.ts +1 -0
  55. package/dist/index.js +30 -24
  56. package/dist/{item-C0kyELlf.js → item-D9r2-3fk.js} +5 -5
  57. package/package.json +3 -1
  58. package/dist/T7VMP3TM-B3jxXFmj.js +0 -3548
  59. package/dist/_commonjsHelpers-C6fGbg64.js +0 -6
@@ -1,3548 +0,0 @@
1
- import { y as z, x as Te, D as De, z as ce, an as $n, o as G, M as Ut, r as Yt, k as _, c as Cr, P as Gt, C as Ar, a as Tr, b as Vn, d as ee, _ as se, ao as _r, i as Fe, ag as Rr, v as j, ap as Ue, Y as Xt, g as ue, a3 as Ne, u as rt, W as Jt, G as fe, j as W, s as Be, aq as Ir, f as K, e as Q, ar as Zt, as as Hn, t as Bn, K as Fr, at as vn, a4 as nt, E as Qt, I as de, Z as Lr, aj as Mr, w as Wn, au as Nr, av as kr, U as Rt, aw as Dt, A as zn, a1 as Vt, ax as $r, ay as Vr, a2 as Hr, a6 as Br, az as Ct, a5 as Wr, a7 as zr, O as jr, p as Kr, am as qr } from "./P7GR5CS5-DNbthaqU.js";
2
- import { t as en, c as it, f as $e, l as Ur, i as hn, d as re, s as xt, n as ke, q as Yr, k as Gr, r as Xr, v as It, e as jn, w as Jr, x as Zr, u as he, m as Kn, o as qn, y as Qr, g as Un, z as Ft, A as yn, B as eo, C as to, F as no, D as ro, E as oo, G as io, H as ot, I as so, J as ao, K as co } from "./UQQRIHDV-CFdrMoqW.js";
3
- import Yn, { createContext as Je, useRef as Y, useEffect as U, useState as le, useCallback as st, useMemo as Gn, useContext as tn, isValidElement as uo } from "react";
4
- import { jsx as H, jsxs as yt, Fragment as bt } from "react/jsx-runtime";
5
- function lo(e) {
6
- var t;
7
- const r = e.find((s) => !!s.element), n = [...e].reverse().find((s) => !!s.element);
8
- let o = (t = r == null ? void 0 : r.element) == null ? void 0 : t.parentElement;
9
- for (; o && (n != null && n.element); ) {
10
- if (n && o.contains(n.element))
11
- return o;
12
- o = o.parentElement;
13
- }
14
- return G(o).body;
15
- }
16
- function fo(e) {
17
- return e == null ? void 0 : e.__unstablePrivateStore;
18
- }
19
- function mo(e = {}) {
20
- var t;
21
- en(e, e.store);
22
- const r = (t = e.store) == null ? void 0 : t.getState(), n = z(
23
- e.items,
24
- r == null ? void 0 : r.items,
25
- e.defaultItems,
26
- []
27
- ), o = new Map(n.map((i) => [i.id, i])), s = {
28
- items: n,
29
- renderedItems: z(r == null ? void 0 : r.renderedItems, [])
30
- }, c = fo(e.store), l = it(
31
- { items: n, renderedItems: s.renderedItems },
32
- c
33
- ), a = it(s, e.store), u = (i) => {
34
- const d = $n(i, (p) => p.element);
35
- l.setState("renderedItems", d), a.setState("renderedItems", d);
36
- };
37
- $e(a, () => Ur(l)), $e(l, () => hn(l, ["items"], (i) => {
38
- a.setState("items", i.items);
39
- })), $e(l, () => hn(l, ["renderedItems"], (i) => {
40
- let d = !0, p = requestAnimationFrame(() => {
41
- const { renderedItems: w } = a.getState();
42
- i.renderedItems !== w && u(i.renderedItems);
43
- });
44
- if (typeof IntersectionObserver != "function")
45
- return () => cancelAnimationFrame(p);
46
- const h = () => {
47
- if (d) {
48
- d = !1;
49
- return;
50
- }
51
- cancelAnimationFrame(p), p = requestAnimationFrame(() => u(i.renderedItems));
52
- }, x = lo(i.renderedItems), b = new IntersectionObserver(h, { root: x });
53
- for (const w of i.renderedItems)
54
- w.element && b.observe(w.element);
55
- return () => {
56
- cancelAnimationFrame(p), b.disconnect();
57
- };
58
- }));
59
- const m = (i, d, p = !1) => {
60
- let h;
61
- return d((b) => {
62
- const w = b.findIndex(({ id: g }) => g === i.id), E = b.slice();
63
- if (w !== -1) {
64
- h = b[w];
65
- const g = ce(ce({}, h), i);
66
- E[w] = g, o.set(i.id, g);
67
- } else
68
- E.push(i), o.set(i.id, i);
69
- return E;
70
- }), () => {
71
- d((b) => {
72
- if (!h)
73
- return p && o.delete(i.id), b.filter(({ id: g }) => g !== i.id);
74
- const w = b.findIndex(({ id: g }) => g === i.id);
75
- if (w === -1) return b;
76
- const E = b.slice();
77
- return E[w] = h, o.set(i.id, h), E;
78
- });
79
- };
80
- }, f = (i) => m(
81
- i,
82
- (d) => l.setState("items", d),
83
- !0
84
- );
85
- return Te(ce({}, a), {
86
- registerItem: f,
87
- renderItem: (i) => De(
88
- f(i),
89
- m(
90
- i,
91
- (d) => l.setState("renderedItems", d)
92
- )
93
- ),
94
- item: (i) => {
95
- if (!i) return null;
96
- let d = o.get(i);
97
- if (!d) {
98
- const { items: p } = l.getState();
99
- d = p.find((h) => h.id === i), d && o.set(i, d);
100
- }
101
- return d || null;
102
- },
103
- // @ts-expect-error Internal
104
- __unstablePrivateStore: l
105
- });
106
- }
107
- function po(e, t, r) {
108
- return Ut(t, [r.store]), re(e, r, "items", "setItems"), e;
109
- }
110
- function Cs(e) {
111
- return Array.isArray(e) ? e : typeof e < "u" ? [e] : [];
112
- }
113
- function Xn(e) {
114
- const t = [];
115
- for (const r of e)
116
- t.push(...r);
117
- return t;
118
- }
119
- function Ht(e) {
120
- return e.slice().reverse();
121
- }
122
- var go = { id: null };
123
- function Se(e, t) {
124
- return e.find((r) => t ? !r.disabled && r.id !== t : !r.disabled);
125
- }
126
- function vo(e, t) {
127
- return e.filter((r) => t ? !r.disabled && r.id !== t : !r.disabled);
128
- }
129
- function bn(e, t) {
130
- return e.filter((r) => r.rowId === t);
131
- }
132
- function ho(e, t, r = !1) {
133
- const n = e.findIndex((o) => o.id === t);
134
- return [
135
- ...e.slice(n + 1),
136
- ...r ? [go] : [],
137
- ...e.slice(0, n)
138
- ];
139
- }
140
- function Jn(e) {
141
- const t = [];
142
- for (const r of e) {
143
- const n = t.find((o) => {
144
- var s;
145
- return ((s = o[0]) == null ? void 0 : s.rowId) === r.rowId;
146
- });
147
- n ? n.push(r) : t.push([r]);
148
- }
149
- return t;
150
- }
151
- function Zn(e) {
152
- let t = 0;
153
- for (const { length: r } of e)
154
- r > t && (t = r);
155
- return t;
156
- }
157
- function yo(e) {
158
- return {
159
- id: "__EMPTY_ITEM__",
160
- disabled: !0,
161
- rowId: e
162
- };
163
- }
164
- function bo(e, t, r) {
165
- const n = Zn(e);
166
- for (const o of e)
167
- for (let s = 0; s < n; s += 1) {
168
- const c = o[s];
169
- if (!c || r && c.disabled) {
170
- const a = s === 0 && r ? Se(o) : o[s - 1];
171
- o[s] = a && t !== a.id && r ? a : yo(a == null ? void 0 : a.rowId);
172
- }
173
- }
174
- return e;
175
- }
176
- function wo(e) {
177
- const t = Jn(e), r = Zn(t), n = [];
178
- for (let o = 0; o < r; o += 1)
179
- for (const s of t) {
180
- const c = s[o];
181
- c && n.push(Te(ce({}, c), {
182
- // If there's no rowId, it means that it's not a grid composite, but
183
- // a single row instead. So, instead of verticalizing it, that is,
184
- // assigning a different rowId based on the column index, we keep it
185
- // undefined so they will be part of the same row. This is useful
186
- // when using up/down on one-dimensional composites.
187
- rowId: c.rowId ? `${o}` : void 0
188
- }));
189
- }
190
- return n;
191
- }
192
- function As(e = {}) {
193
- var t;
194
- const r = (t = e.store) == null ? void 0 : t.getState(), n = mo(e), o = z(
195
- e.activeId,
196
- r == null ? void 0 : r.activeId,
197
- e.defaultActiveId
198
- ), s = Te(ce({}, n.getState()), {
199
- id: z(
200
- e.id,
201
- r == null ? void 0 : r.id,
202
- `id-${Math.random().toString(36).slice(2, 8)}`
203
- ),
204
- activeId: o,
205
- baseElement: z(r == null ? void 0 : r.baseElement, null),
206
- includesBaseElement: z(
207
- e.includesBaseElement,
208
- r == null ? void 0 : r.includesBaseElement,
209
- o === null
210
- ),
211
- moves: z(r == null ? void 0 : r.moves, 0),
212
- orientation: z(
213
- e.orientation,
214
- r == null ? void 0 : r.orientation,
215
- "both"
216
- ),
217
- rtl: z(e.rtl, r == null ? void 0 : r.rtl, !1),
218
- virtualFocus: z(
219
- e.virtualFocus,
220
- r == null ? void 0 : r.virtualFocus,
221
- !1
222
- ),
223
- focusLoop: z(e.focusLoop, r == null ? void 0 : r.focusLoop, !1),
224
- focusWrap: z(e.focusWrap, r == null ? void 0 : r.focusWrap, !1),
225
- focusShift: z(e.focusShift, r == null ? void 0 : r.focusShift, !1)
226
- }), c = it(s, n, e.store);
227
- $e(
228
- c,
229
- () => xt(c, ["renderedItems", "activeId"], (a) => {
230
- c.setState("activeId", (u) => {
231
- var m;
232
- return u !== void 0 ? u : (m = Se(a.renderedItems)) == null ? void 0 : m.id;
233
- });
234
- })
235
- );
236
- const l = (a = "next", u = {}) => {
237
- var m, f;
238
- const i = c.getState(), {
239
- skip: d = 0,
240
- activeId: p = i.activeId,
241
- focusShift: h = i.focusShift,
242
- focusLoop: x = i.focusLoop,
243
- focusWrap: b = i.focusWrap,
244
- includesBaseElement: w = i.includesBaseElement,
245
- renderedItems: E = i.renderedItems,
246
- rtl: g = i.rtl
247
- } = u, v = a === "up" || a === "down", O = a === "next" || a === "down", S = O ? g && !v : !g || v, $ = h && !d;
248
- let C = v ? Xn(
249
- bo(Jn(E), p, $)
250
- ) : E;
251
- if (C = S ? Ht(C) : C, C = v ? wo(C) : C, p == null)
252
- return (m = Se(C)) == null ? void 0 : m.id;
253
- const R = C.find((T) => T.id === p);
254
- if (!R)
255
- return (f = Se(C)) == null ? void 0 : f.id;
256
- const B = C.some((T) => T.rowId), L = C.indexOf(R), y = C.slice(L + 1), D = bn(y, R.rowId);
257
- if (d) {
258
- const T = vo(D, p), k = T.slice(d)[0] || // If we can't find an item, just return the last one.
259
- T[T.length - 1];
260
- return k == null ? void 0 : k.id;
261
- }
262
- const A = x && (v ? x !== "horizontal" : x !== "vertical"), M = B && b && (v ? b !== "horizontal" : b !== "vertical"), I = O ? (!B || v) && A && w : v ? w : !1;
263
- if (A) {
264
- const T = M && !I ? C : bn(C, R.rowId), k = ho(T, p, I), q = Se(k, p);
265
- return q == null ? void 0 : q.id;
266
- }
267
- if (M) {
268
- const T = Se(
269
- // We can use nextItems, which contains all the next items, including
270
- // items from other rows, to wrap between rows. However, if there is a
271
- // null item (the composite container), we'll only use the next items in
272
- // the row. So moving next from the last item will focus on the
273
- // composite container. On grid composites, horizontal navigation never
274
- // focuses on the composite container, only vertical.
275
- I ? D : y,
276
- p
277
- );
278
- return I ? (T == null ? void 0 : T.id) || null : T == null ? void 0 : T.id;
279
- }
280
- const V = Se(D, p);
281
- return !V && I ? null : V == null ? void 0 : V.id;
282
- };
283
- return Te(ce(ce({}, n), c), {
284
- setBaseElement: (a) => c.setState("baseElement", a),
285
- setActiveId: (a) => c.setState("activeId", a),
286
- move: (a) => {
287
- a !== void 0 && (c.setState("activeId", a), c.setState("moves", (u) => u + 1));
288
- },
289
- first: () => {
290
- var a;
291
- return (a = Se(c.getState().renderedItems)) == null ? void 0 : a.id;
292
- },
293
- last: () => {
294
- var a;
295
- return (a = Se(Ht(c.getState().renderedItems))) == null ? void 0 : a.id;
296
- },
297
- next: (a) => (a !== void 0 && typeof a == "number" && (a = { skip: a }), l("next", a)),
298
- previous: (a) => (a !== void 0 && typeof a == "number" && (a = { skip: a }), l("previous", a)),
299
- down: (a) => (a !== void 0 && typeof a == "number" && (a = { skip: a }), l("down", a)),
300
- up: (a) => (a !== void 0 && typeof a == "number" && (a = { skip: a }), l("up", a))
301
- });
302
- }
303
- function Ts(e) {
304
- const t = Yt(e.id);
305
- return _({ id: t }, e);
306
- }
307
- function _s(e, t, r) {
308
- return e = po(e, t, r), re(e, r, "activeId", "setActiveId"), re(e, r, "includesBaseElement"), re(e, r, "virtualFocus"), re(e, r, "orientation"), re(e, r, "rtl"), re(e, r, "focusLoop"), re(e, r, "focusWrap"), re(e, r, "focusShift"), e;
309
- }
310
- var Rs = Je(
311
- void 0
312
- ), ct = Cr(
313
- [Tr, Vn],
314
- [Gt, Ar]
315
- ), Is = ct.useContext, Fs = ct.useScopedContext, Ls = ct.useProviderContext, Ms = ct.ContextProvider, Ns = ct.ScopedContextProvider, ks = Je(
316
- void 0
317
- ), $s = Je(!1), xo = "div";
318
- function Eo(e) {
319
- return e.some((t) => !!t.rowId);
320
- }
321
- function So(e) {
322
- const t = e.target;
323
- return t && !Jt(t) ? !1 : e.key.length === 1 && !e.ctrlKey && !e.metaKey;
324
- }
325
- function Oo(e) {
326
- return e.key === "Shift" || e.key === "Control" || e.key === "Alt" || e.key === "Meta";
327
- }
328
- function wn(e, t, r) {
329
- return ue((n) => {
330
- var o;
331
- if (t == null || t(n), n.defaultPrevented || n.isPropagationStopped() || !Ne(n) || Oo(n) || So(n)) return;
332
- const s = e.getState(), c = (o = ke(e, s.activeId)) == null ? void 0 : o.element;
333
- if (!c) return;
334
- const l = n, { view: a } = l, u = se(l, ["view"]), m = r == null ? void 0 : r.current;
335
- c !== m && c.focus(), Ir(c, n.type, u) || n.preventDefault(), n.currentTarget.contains(c) && n.stopPropagation();
336
- });
337
- }
338
- function Po(e) {
339
- return Jr(
340
- Xn(Ht(Zr(e)))
341
- );
342
- }
343
- function Do(e) {
344
- const [t, r] = le(!1), n = st(() => r(!0), []), o = e.useState(
345
- (s) => ke(e, s.activeId)
346
- );
347
- return U(() => {
348
- const s = o == null ? void 0 : o.element;
349
- t && s && (r(!1), s.focus({ preventScroll: !0 }));
350
- }, [o, t]), n;
351
- }
352
- var Co = ee(
353
- function(t) {
354
- var r = t, {
355
- store: n,
356
- composite: o = !0,
357
- focusOnMove: s = o,
358
- moveOnKeyPress: c = !0
359
- } = r, l = se(r, [
360
- "store",
361
- "composite",
362
- "focusOnMove",
363
- "moveOnKeyPress"
364
- ]);
365
- const a = _r();
366
- n = n || a, Fe(
367
- n,
368
- process.env.NODE_ENV !== "production" && "Composite must receive a `store` prop or be wrapped in a CompositeProvider component."
369
- );
370
- const u = Y(null), m = Y(null), f = Do(n), i = n.useState("moves"), [, d] = Rr(
371
- o ? n.setBaseElement : null
372
- );
373
- U(() => {
374
- var y;
375
- if (!n || !i || !o || !s) return;
376
- const { activeId: D } = n.getState(), A = (y = ke(n, D)) == null ? void 0 : y.element;
377
- A && Yr(A);
378
- }, [n, i, o, s]), j(() => {
379
- if (!n || !i || !o) return;
380
- const { baseElement: y, activeId: D } = n.getState();
381
- if (!(D === null) || !y) return;
382
- const M = m.current;
383
- m.current = null, M && Ue(M, { relatedTarget: y }), Gr(y) || y.focus();
384
- }, [n, i, o]);
385
- const p = n.useState("activeId"), h = n.useState("virtualFocus");
386
- j(() => {
387
- var y;
388
- if (!n || !o || !h) return;
389
- const D = m.current;
390
- if (m.current = null, !D) return;
391
- const M = ((y = ke(n, p)) == null ? void 0 : y.element) || Xt(D);
392
- M !== D && Ue(D, { relatedTarget: M });
393
- }, [n, p, h, o]);
394
- const x = wn(
395
- n,
396
- l.onKeyDownCapture,
397
- m
398
- ), b = wn(
399
- n,
400
- l.onKeyUpCapture,
401
- m
402
- ), w = l.onFocusCapture, E = ue((y) => {
403
- if (w == null || w(y), y.defaultPrevented || !n) return;
404
- const { virtualFocus: D } = n.getState();
405
- if (!D) return;
406
- const A = y.relatedTarget, M = Xr(y.currentTarget);
407
- Ne(y) && M && (y.stopPropagation(), m.current = A);
408
- }), g = l.onFocus, v = ue((y) => {
409
- if (g == null || g(y), y.defaultPrevented || !o || !n) return;
410
- const { relatedTarget: D } = y, { virtualFocus: A } = n.getState();
411
- A ? Ne(y) && !It(n, D) && queueMicrotask(f) : Ne(y) && n.setActiveId(null);
412
- }), O = l.onBlurCapture, S = ue((y) => {
413
- var D;
414
- if (O == null || O(y), y.defaultPrevented || !n) return;
415
- const { virtualFocus: A, activeId: M } = n.getState();
416
- if (!A) return;
417
- const I = (D = ke(n, M)) == null ? void 0 : D.element, V = y.relatedTarget, T = It(n, V), k = m.current;
418
- m.current = null, Ne(y) && T ? (V === I ? k && k !== V && Ue(k, y) : I ? Ue(I, y) : k && Ue(k, y), y.stopPropagation()) : !It(n, y.target) && I && Ue(I, y);
419
- }), $ = l.onKeyDown, C = rt(c), R = ue((y) => {
420
- var D;
421
- if ($ == null || $(y), y.nativeEvent.isComposing || y.defaultPrevented || !n || !Ne(y)) return;
422
- const { orientation: A, renderedItems: M, activeId: I } = n.getState(), V = ke(n, I);
423
- if ((D = V == null ? void 0 : V.element) != null && D.isConnected) return;
424
- const T = A !== "horizontal", k = A !== "vertical", q = Eo(M);
425
- if ((y.key === "ArrowLeft" || y.key === "ArrowRight" || y.key === "Home" || y.key === "End") && Jt(y.currentTarget)) return;
426
- const te = {
427
- ArrowUp: (q || T) && (() => {
428
- if (q) {
429
- const xe = Po(M);
430
- return xe == null ? void 0 : xe.id;
431
- }
432
- return n == null ? void 0 : n.last();
433
- }),
434
- ArrowRight: (q || k) && n.first,
435
- ArrowDown: (q || T) && n.first,
436
- ArrowLeft: (q || k) && n.last,
437
- Home: n.first,
438
- End: n.last,
439
- PageUp: n.first,
440
- PageDown: n.last
441
- }[y.key];
442
- if (te) {
443
- const xe = te();
444
- if (xe !== void 0) {
445
- if (!C(y)) return;
446
- y.preventDefault(), n.move(xe);
447
- }
448
- }
449
- });
450
- l = fe(
451
- l,
452
- (y) => /* @__PURE__ */ H(Vn, { value: n, children: y }),
453
- [n]
454
- );
455
- const B = n.useState((y) => {
456
- var D;
457
- if (n && o && y.virtualFocus)
458
- return (D = ke(n, y.activeId)) == null ? void 0 : D.id;
459
- });
460
- l = W(_({
461
- "aria-activedescendant": B
462
- }, l), {
463
- ref: Be(u, d, l.ref),
464
- onKeyDownCapture: x,
465
- onKeyUpCapture: b,
466
- onFocusCapture: E,
467
- onFocus: v,
468
- onBlurCapture: S,
469
- onKeyDown: R
470
- });
471
- const L = n.useState(
472
- (y) => o && (y.virtualFocus || y.activeId === null)
473
- );
474
- return l = jn(_({ focusable: L }, l)), l;
475
- }
476
- );
477
- K(function(t) {
478
- const r = Co(t);
479
- return Q(xo, r);
480
- });
481
- var gt = { exports: {} }, J = {};
482
- /**
483
- * @license React
484
- * react-dom.production.js
485
- *
486
- * Copyright (c) Meta Platforms, Inc. and affiliates.
487
- *
488
- * This source code is licensed under the MIT license found in the
489
- * LICENSE file in the root directory of this source tree.
490
- */
491
- var xn;
492
- function Ao() {
493
- if (xn) return J;
494
- xn = 1;
495
- var e = Yn;
496
- function t(a) {
497
- var u = "https://react.dev/errors/" + a;
498
- if (1 < arguments.length) {
499
- u += "?args[]=" + encodeURIComponent(arguments[1]);
500
- for (var m = 2; m < arguments.length; m++)
501
- u += "&args[]=" + encodeURIComponent(arguments[m]);
502
- }
503
- return "Minified React error #" + a + "; visit " + u + " for the full message or use the non-minified dev environment for full errors and additional helpful warnings.";
504
- }
505
- function r() {
506
- }
507
- var n = {
508
- d: {
509
- f: r,
510
- r: function() {
511
- throw Error(t(522));
512
- },
513
- D: r,
514
- C: r,
515
- L: r,
516
- m: r,
517
- X: r,
518
- S: r,
519
- M: r
520
- },
521
- p: 0,
522
- findDOMNode: null
523
- }, o = Symbol.for("react.portal");
524
- function s(a, u, m) {
525
- var f = 3 < arguments.length && arguments[3] !== void 0 ? arguments[3] : null;
526
- return {
527
- $$typeof: o,
528
- key: f == null ? null : "" + f,
529
- children: a,
530
- containerInfo: u,
531
- implementation: m
532
- };
533
- }
534
- var c = e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
535
- function l(a, u) {
536
- if (a === "font") return "";
537
- if (typeof u == "string")
538
- return u === "use-credentials" ? u : "";
539
- }
540
- return J.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = n, J.createPortal = function(a, u) {
541
- var m = 2 < arguments.length && arguments[2] !== void 0 ? arguments[2] : null;
542
- if (!u || u.nodeType !== 1 && u.nodeType !== 9 && u.nodeType !== 11)
543
- throw Error(t(299));
544
- return s(a, u, null, m);
545
- }, J.flushSync = function(a) {
546
- var u = c.T, m = n.p;
547
- try {
548
- if (c.T = null, n.p = 2, a) return a();
549
- } finally {
550
- c.T = u, n.p = m, n.d.f();
551
- }
552
- }, J.preconnect = function(a, u) {
553
- typeof a == "string" && (u ? (u = u.crossOrigin, u = typeof u == "string" ? u === "use-credentials" ? u : "" : void 0) : u = null, n.d.C(a, u));
554
- }, J.prefetchDNS = function(a) {
555
- typeof a == "string" && n.d.D(a);
556
- }, J.preinit = function(a, u) {
557
- if (typeof a == "string" && u && typeof u.as == "string") {
558
- var m = u.as, f = l(m, u.crossOrigin), i = typeof u.integrity == "string" ? u.integrity : void 0, d = typeof u.fetchPriority == "string" ? u.fetchPriority : void 0;
559
- m === "style" ? n.d.S(
560
- a,
561
- typeof u.precedence == "string" ? u.precedence : void 0,
562
- {
563
- crossOrigin: f,
564
- integrity: i,
565
- fetchPriority: d
566
- }
567
- ) : m === "script" && n.d.X(a, {
568
- crossOrigin: f,
569
- integrity: i,
570
- fetchPriority: d,
571
- nonce: typeof u.nonce == "string" ? u.nonce : void 0
572
- });
573
- }
574
- }, J.preinitModule = function(a, u) {
575
- if (typeof a == "string")
576
- if (typeof u == "object" && u !== null) {
577
- if (u.as == null || u.as === "script") {
578
- var m = l(
579
- u.as,
580
- u.crossOrigin
581
- );
582
- n.d.M(a, {
583
- crossOrigin: m,
584
- integrity: typeof u.integrity == "string" ? u.integrity : void 0,
585
- nonce: typeof u.nonce == "string" ? u.nonce : void 0
586
- });
587
- }
588
- } else u == null && n.d.M(a);
589
- }, J.preload = function(a, u) {
590
- if (typeof a == "string" && typeof u == "object" && u !== null && typeof u.as == "string") {
591
- var m = u.as, f = l(m, u.crossOrigin);
592
- n.d.L(a, m, {
593
- crossOrigin: f,
594
- integrity: typeof u.integrity == "string" ? u.integrity : void 0,
595
- nonce: typeof u.nonce == "string" ? u.nonce : void 0,
596
- type: typeof u.type == "string" ? u.type : void 0,
597
- fetchPriority: typeof u.fetchPriority == "string" ? u.fetchPriority : void 0,
598
- referrerPolicy: typeof u.referrerPolicy == "string" ? u.referrerPolicy : void 0,
599
- imageSrcSet: typeof u.imageSrcSet == "string" ? u.imageSrcSet : void 0,
600
- imageSizes: typeof u.imageSizes == "string" ? u.imageSizes : void 0,
601
- media: typeof u.media == "string" ? u.media : void 0
602
- });
603
- }
604
- }, J.preloadModule = function(a, u) {
605
- if (typeof a == "string")
606
- if (u) {
607
- var m = l(u.as, u.crossOrigin);
608
- n.d.m(a, {
609
- as: typeof u.as == "string" && u.as !== "script" ? u.as : void 0,
610
- crossOrigin: m,
611
- integrity: typeof u.integrity == "string" ? u.integrity : void 0
612
- });
613
- } else n.d.m(a);
614
- }, J.requestFormReset = function(a) {
615
- n.d.r(a);
616
- }, J.unstable_batchedUpdates = function(a, u) {
617
- return a(u);
618
- }, J.useFormState = function(a, u, m) {
619
- return c.H.useFormState(a, u, m);
620
- }, J.useFormStatus = function() {
621
- return c.H.useHostTransitionStatus();
622
- }, J.version = "19.1.0", J;
623
- }
624
- var Z = {};
625
- /**
626
- * @license React
627
- * react-dom.development.js
628
- *
629
- * Copyright (c) Meta Platforms, Inc. and affiliates.
630
- *
631
- * This source code is licensed under the MIT license found in the
632
- * LICENSE file in the root directory of this source tree.
633
- */
634
- var En;
635
- function To() {
636
- return En || (En = 1, process.env.NODE_ENV !== "production" && function() {
637
- function e() {
638
- }
639
- function t(f) {
640
- return "" + f;
641
- }
642
- function r(f, i, d) {
643
- var p = 3 < arguments.length && arguments[3] !== void 0 ? arguments[3] : null;
644
- try {
645
- t(p);
646
- var h = !1;
647
- } catch {
648
- h = !0;
649
- }
650
- return h && (console.error(
651
- "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
652
- typeof Symbol == "function" && Symbol.toStringTag && p[Symbol.toStringTag] || p.constructor.name || "Object"
653
- ), t(p)), {
654
- $$typeof: u,
655
- key: p == null ? null : "" + p,
656
- children: f,
657
- containerInfo: i,
658
- implementation: d
659
- };
660
- }
661
- function n(f, i) {
662
- if (f === "font") return "";
663
- if (typeof i == "string")
664
- return i === "use-credentials" ? i : "";
665
- }
666
- function o(f) {
667
- return f === null ? "`null`" : f === void 0 ? "`undefined`" : f === "" ? "an empty string" : 'something with type "' + typeof f + '"';
668
- }
669
- function s(f) {
670
- return f === null ? "`null`" : f === void 0 ? "`undefined`" : f === "" ? "an empty string" : typeof f == "string" ? JSON.stringify(f) : typeof f == "number" ? "`" + f + "`" : 'something with type "' + typeof f + '"';
671
- }
672
- function c() {
673
- var f = m.H;
674
- return f === null && console.error(
675
- `Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
676
- 1. You might have mismatching versions of React and the renderer (such as React DOM)
677
- 2. You might be breaking the Rules of Hooks
678
- 3. You might have more than one copy of React in the same app
679
- See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`
680
- ), f;
681
- }
682
- typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
683
- var l = Yn, a = {
684
- d: {
685
- f: e,
686
- r: function() {
687
- throw Error(
688
- "Invalid form element. requestFormReset must be passed a form that was rendered by React."
689
- );
690
- },
691
- D: e,
692
- C: e,
693
- L: e,
694
- m: e,
695
- X: e,
696
- S: e,
697
- M: e
698
- },
699
- p: 0,
700
- findDOMNode: null
701
- }, u = Symbol.for("react.portal"), m = l.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
702
- typeof Map == "function" && Map.prototype != null && typeof Map.prototype.forEach == "function" && typeof Set == "function" && Set.prototype != null && typeof Set.prototype.clear == "function" && typeof Set.prototype.forEach == "function" || console.error(
703
- "React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"
704
- ), Z.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = a, Z.createPortal = function(f, i) {
705
- var d = 2 < arguments.length && arguments[2] !== void 0 ? arguments[2] : null;
706
- if (!i || i.nodeType !== 1 && i.nodeType !== 9 && i.nodeType !== 11)
707
- throw Error("Target container is not a DOM element.");
708
- return r(f, i, null, d);
709
- }, Z.flushSync = function(f) {
710
- var i = m.T, d = a.p;
711
- try {
712
- if (m.T = null, a.p = 2, f)
713
- return f();
714
- } finally {
715
- m.T = i, a.p = d, a.d.f() && console.error(
716
- "flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering. Consider moving this call to a scheduler task or micro task."
717
- );
718
- }
719
- }, Z.preconnect = function(f, i) {
720
- typeof f == "string" && f ? i != null && typeof i != "object" ? console.error(
721
- "ReactDOM.preconnect(): Expected the `options` argument (second) to be an object but encountered %s instead. The only supported option at this time is `crossOrigin` which accepts a string.",
722
- s(i)
723
- ) : i != null && typeof i.crossOrigin != "string" && console.error(
724
- "ReactDOM.preconnect(): Expected the `crossOrigin` option (second argument) to be a string but encountered %s instead. Try removing this option or passing a string value instead.",
725
- o(i.crossOrigin)
726
- ) : console.error(
727
- "ReactDOM.preconnect(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.",
728
- o(f)
729
- ), typeof f == "string" && (i ? (i = i.crossOrigin, i = typeof i == "string" ? i === "use-credentials" ? i : "" : void 0) : i = null, a.d.C(f, i));
730
- }, Z.prefetchDNS = function(f) {
731
- if (typeof f != "string" || !f)
732
- console.error(
733
- "ReactDOM.prefetchDNS(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.",
734
- o(f)
735
- );
736
- else if (1 < arguments.length) {
737
- var i = arguments[1];
738
- typeof i == "object" && i.hasOwnProperty("crossOrigin") ? console.error(
739
- "ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. It looks like the you are attempting to set a crossOrigin property for this DNS lookup hint. Browsers do not perform DNS queries using CORS and setting this attribute on the resource hint has no effect. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.",
740
- s(i)
741
- ) : console.error(
742
- "ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.",
743
- s(i)
744
- );
745
- }
746
- typeof f == "string" && a.d.D(f);
747
- }, Z.preinit = function(f, i) {
748
- if (typeof f == "string" && f ? i == null || typeof i != "object" ? console.error(
749
- "ReactDOM.preinit(): Expected the `options` argument (second) to be an object with an `as` property describing the type of resource to be preinitialized but encountered %s instead.",
750
- s(i)
751
- ) : i.as !== "style" && i.as !== "script" && console.error(
752
- 'ReactDOM.preinit(): Expected the `as` property in the `options` argument (second) to contain a valid value describing the type of resource to be preinitialized but encountered %s instead. Valid values for `as` are "style" and "script".',
753
- s(i.as)
754
- ) : console.error(
755
- "ReactDOM.preinit(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.",
756
- o(f)
757
- ), typeof f == "string" && i && typeof i.as == "string") {
758
- var d = i.as, p = n(d, i.crossOrigin), h = typeof i.integrity == "string" ? i.integrity : void 0, x = typeof i.fetchPriority == "string" ? i.fetchPriority : void 0;
759
- d === "style" ? a.d.S(
760
- f,
761
- typeof i.precedence == "string" ? i.precedence : void 0,
762
- {
763
- crossOrigin: p,
764
- integrity: h,
765
- fetchPriority: x
766
- }
767
- ) : d === "script" && a.d.X(f, {
768
- crossOrigin: p,
769
- integrity: h,
770
- fetchPriority: x,
771
- nonce: typeof i.nonce == "string" ? i.nonce : void 0
772
- });
773
- }
774
- }, Z.preinitModule = function(f, i) {
775
- var d = "";
776
- if (typeof f == "string" && f || (d += " The `href` argument encountered was " + o(f) + "."), i !== void 0 && typeof i != "object" ? d += " The `options` argument encountered was " + o(i) + "." : i && "as" in i && i.as !== "script" && (d += " The `as` option encountered was " + s(i.as) + "."), d)
777
- console.error(
778
- "ReactDOM.preinitModule(): Expected up to two arguments, a non-empty `href` string and, optionally, an `options` object with a valid `as` property.%s",
779
- d
780
- );
781
- else
782
- switch (d = i && typeof i.as == "string" ? i.as : "script", d) {
783
- case "script":
784
- break;
785
- default:
786
- d = s(d), console.error(
787
- 'ReactDOM.preinitModule(): Currently the only supported "as" type for this function is "script" but received "%s" instead. This warning was generated for `href` "%s". In the future other module types will be supported, aligning with the import-attributes proposal. Learn more here: (https://github.com/tc39/proposal-import-attributes)',
788
- d,
789
- f
790
- );
791
- }
792
- typeof f == "string" && (typeof i == "object" && i !== null ? (i.as == null || i.as === "script") && (d = n(
793
- i.as,
794
- i.crossOrigin
795
- ), a.d.M(f, {
796
- crossOrigin: d,
797
- integrity: typeof i.integrity == "string" ? i.integrity : void 0,
798
- nonce: typeof i.nonce == "string" ? i.nonce : void 0
799
- })) : i == null && a.d.M(f));
800
- }, Z.preload = function(f, i) {
801
- var d = "";
802
- if (typeof f == "string" && f || (d += " The `href` argument encountered was " + o(f) + "."), i == null || typeof i != "object" ? d += " The `options` argument encountered was " + o(i) + "." : typeof i.as == "string" && i.as || (d += " The `as` option encountered was " + o(i.as) + "."), d && console.error(
803
- 'ReactDOM.preload(): Expected two arguments, a non-empty `href` string and an `options` object with an `as` property valid for a `<link rel="preload" as="..." />` tag.%s',
804
- d
805
- ), typeof f == "string" && typeof i == "object" && i !== null && typeof i.as == "string") {
806
- d = i.as;
807
- var p = n(
808
- d,
809
- i.crossOrigin
810
- );
811
- a.d.L(f, d, {
812
- crossOrigin: p,
813
- integrity: typeof i.integrity == "string" ? i.integrity : void 0,
814
- nonce: typeof i.nonce == "string" ? i.nonce : void 0,
815
- type: typeof i.type == "string" ? i.type : void 0,
816
- fetchPriority: typeof i.fetchPriority == "string" ? i.fetchPriority : void 0,
817
- referrerPolicy: typeof i.referrerPolicy == "string" ? i.referrerPolicy : void 0,
818
- imageSrcSet: typeof i.imageSrcSet == "string" ? i.imageSrcSet : void 0,
819
- imageSizes: typeof i.imageSizes == "string" ? i.imageSizes : void 0,
820
- media: typeof i.media == "string" ? i.media : void 0
821
- });
822
- }
823
- }, Z.preloadModule = function(f, i) {
824
- var d = "";
825
- typeof f == "string" && f || (d += " The `href` argument encountered was " + o(f) + "."), i !== void 0 && typeof i != "object" ? d += " The `options` argument encountered was " + o(i) + "." : i && "as" in i && typeof i.as != "string" && (d += " The `as` option encountered was " + o(i.as) + "."), d && console.error(
826
- 'ReactDOM.preloadModule(): Expected two arguments, a non-empty `href` string and, optionally, an `options` object with an `as` property valid for a `<link rel="modulepreload" as="..." />` tag.%s',
827
- d
828
- ), typeof f == "string" && (i ? (d = n(
829
- i.as,
830
- i.crossOrigin
831
- ), a.d.m(f, {
832
- as: typeof i.as == "string" && i.as !== "script" ? i.as : void 0,
833
- crossOrigin: d,
834
- integrity: typeof i.integrity == "string" ? i.integrity : void 0
835
- })) : a.d.m(f));
836
- }, Z.requestFormReset = function(f) {
837
- a.d.r(f);
838
- }, Z.unstable_batchedUpdates = function(f, i) {
839
- return f(i);
840
- }, Z.useFormState = function(f, i, d) {
841
- return c().useFormState(f, i, d);
842
- }, Z.useFormStatus = function() {
843
- return c().useHostTransitionStatus();
844
- }, Z.version = "19.1.0", typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
845
- }()), Z;
846
- }
847
- var Sn;
848
- function _o() {
849
- if (Sn) return gt.exports;
850
- Sn = 1;
851
- function e() {
852
- if (!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ > "u" || typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE != "function")) {
853
- if (process.env.NODE_ENV !== "production")
854
- throw new Error("^_^");
855
- try {
856
- __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e);
857
- } catch (t) {
858
- console.error(t);
859
- }
860
- }
861
- }
862
- return process.env.NODE_ENV === "production" ? (e(), gt.exports = Ao()) : gt.exports = To(), gt.exports;
863
- }
864
- var Et = _o(), Ro = "div";
865
- function On(e, t) {
866
- const r = setTimeout(t, e);
867
- return () => clearTimeout(r);
868
- }
869
- function Io(e) {
870
- let t = requestAnimationFrame(() => {
871
- t = requestAnimationFrame(e);
872
- });
873
- return () => cancelAnimationFrame(t);
874
- }
875
- function Pn(...e) {
876
- return e.join(", ").split(", ").reduce((t, r) => {
877
- const n = r.endsWith("ms") ? 1 : 1e3, o = Number.parseFloat(r || "0s") * n;
878
- return o > t ? o : t;
879
- }, 0);
880
- }
881
- function Qn(e, t, r) {
882
- return !r && t !== !1 && (!e || !!t);
883
- }
884
- var nn = ee(function(t) {
885
- var r = t, { store: n, alwaysVisible: o } = r, s = se(r, ["store", "alwaysVisible"]);
886
- const c = Zt();
887
- n = n || c, Fe(
888
- n,
889
- process.env.NODE_ENV !== "production" && "DisclosureContent must receive a `store` prop or be wrapped in a DisclosureProvider component."
890
- );
891
- const l = Y(null), a = Yt(s.id), [u, m] = le(null), f = n.useState("open"), i = n.useState("mounted"), d = n.useState("animated"), p = n.useState("contentElement"), h = he(n.disclosure, "contentElement");
892
- j(() => {
893
- l.current && (n == null || n.setContentElement(l.current));
894
- }, [n]), j(() => {
895
- let E;
896
- return n == null || n.setState("animated", (g) => (E = g, !0)), () => {
897
- E !== void 0 && (n == null || n.setState("animated", E));
898
- };
899
- }, [n]), j(() => {
900
- if (d) {
901
- if (!(p != null && p.isConnected)) {
902
- m(null);
903
- return;
904
- }
905
- return Io(() => {
906
- m(f ? "enter" : i ? "leave" : null);
907
- });
908
- }
909
- }, [d, p, f, i]), j(() => {
910
- if (!n || !d || !u || !p) return;
911
- const E = () => n == null ? void 0 : n.setState("animating", !1), g = () => Et.flushSync(E);
912
- if (u === "leave" && f || u === "enter" && !f) return;
913
- if (typeof d == "number")
914
- return On(d, g);
915
- const {
916
- transitionDuration: v,
917
- animationDuration: O,
918
- transitionDelay: S,
919
- animationDelay: $
920
- } = getComputedStyle(p), {
921
- transitionDuration: C = "0",
922
- animationDuration: R = "0",
923
- transitionDelay: B = "0",
924
- animationDelay: L = "0"
925
- } = h ? getComputedStyle(h) : {}, y = Pn(
926
- S,
927
- $,
928
- B,
929
- L
930
- ), D = Pn(
931
- v,
932
- O,
933
- C,
934
- R
935
- ), A = y + D;
936
- if (!A) {
937
- u === "enter" && n.setState("animated", !1), E();
938
- return;
939
- }
940
- const M = 1e3 / 60, I = Math.max(A - M, 0);
941
- return On(I, g);
942
- }, [n, d, p, h, f, u]), s = fe(
943
- s,
944
- (E) => /* @__PURE__ */ H(Hn, { value: n, children: E }),
945
- [n]
946
- );
947
- const x = Qn(i, s.hidden, o), b = s.style, w = Gn(() => x ? W(_({}, b), { display: "none" }) : b, [x, b]);
948
- return s = W(_({
949
- id: a,
950
- "data-open": f || void 0,
951
- "data-enter": u === "enter" || void 0,
952
- "data-leave": u === "leave" || void 0,
953
- hidden: x
954
- }, s), {
955
- ref: Be(a ? n.setContentElement : null, l, s.ref),
956
- style: w
957
- }), Bn(s);
958
- }), Fo = K(function(t) {
959
- const r = nn(t);
960
- return Q(Ro, r);
961
- });
962
- K(function(t) {
963
- var r = t, {
964
- unmountOnHide: n
965
- } = r, o = se(r, [
966
- "unmountOnHide"
967
- ]);
968
- const s = Zt(), c = o.store || s;
969
- return he(
970
- c,
971
- (a) => !n || (a == null ? void 0 : a.mounted)
972
- ) === !1 ? null : /* @__PURE__ */ H(Fo, _({}, o));
973
- });
974
- function er(e = {}) {
975
- const t = Kn(
976
- e.store,
977
- qn(e.disclosure, ["contentElement", "disclosureElement"])
978
- );
979
- en(e, t);
980
- const r = t == null ? void 0 : t.getState(), n = z(
981
- e.open,
982
- r == null ? void 0 : r.open,
983
- e.defaultOpen,
984
- !1
985
- ), o = z(e.animated, r == null ? void 0 : r.animated, !1), s = {
986
- open: n,
987
- animated: o,
988
- animating: !!o && n,
989
- mounted: n,
990
- contentElement: z(r == null ? void 0 : r.contentElement, null),
991
- disclosureElement: z(r == null ? void 0 : r.disclosureElement, null)
992
- }, c = it(s, t);
993
- return $e(
994
- c,
995
- () => xt(c, ["animated", "animating"], (l) => {
996
- l.animated || c.setState("animating", !1);
997
- })
998
- ), $e(
999
- c,
1000
- () => Qr(c, ["open"], () => {
1001
- c.getState().animated && c.setState("animating", !0);
1002
- })
1003
- ), $e(
1004
- c,
1005
- () => xt(c, ["open", "animating"], (l) => {
1006
- c.setState("mounted", l.open || l.animating);
1007
- })
1008
- ), Te(ce({}, c), {
1009
- disclosure: e.disclosure,
1010
- setOpen: (l) => c.setState("open", l),
1011
- show: () => c.setState("open", !0),
1012
- hide: () => c.setState("open", !1),
1013
- toggle: () => c.setState("open", (l) => !l),
1014
- stopAnimation: () => c.setState("animating", !1),
1015
- setContentElement: (l) => c.setState("contentElement", l),
1016
- setDisclosureElement: (l) => c.setState("disclosureElement", l)
1017
- });
1018
- }
1019
- function tr(e, t, r) {
1020
- return Ut(t, [r.store, r.disclosure]), re(e, r, "open", "setOpen"), re(e, r, "mounted", "setMounted"), re(e, r, "animated"), Object.assign(e, { disclosure: r.disclosure });
1021
- }
1022
- function Lo(e = {}) {
1023
- const [t, r] = Un(er, e);
1024
- return tr(t, r, e);
1025
- }
1026
- function nr(e = {}) {
1027
- return er(e);
1028
- }
1029
- function rr(e, t, r) {
1030
- return tr(e, t, r);
1031
- }
1032
- function Mo(e = {}) {
1033
- const [t, r] = Un(nr, e);
1034
- return rr(t, r, e);
1035
- }
1036
- function Vs(e = {}) {
1037
- var t = e, {
1038
- popover: r
1039
- } = t, n = Fr(t, [
1040
- "popover"
1041
- ]);
1042
- const o = Kn(
1043
- n.store,
1044
- qn(r, [
1045
- "arrowElement",
1046
- "anchorElement",
1047
- "contentElement",
1048
- "popoverElement",
1049
- "disclosureElement"
1050
- ])
1051
- );
1052
- en(n, o);
1053
- const s = o == null ? void 0 : o.getState(), c = nr(Te(ce({}, n), { store: o })), l = z(
1054
- n.placement,
1055
- s == null ? void 0 : s.placement,
1056
- "bottom"
1057
- ), a = Te(ce({}, c.getState()), {
1058
- placement: l,
1059
- currentPlacement: l,
1060
- anchorElement: z(s == null ? void 0 : s.anchorElement, null),
1061
- popoverElement: z(s == null ? void 0 : s.popoverElement, null),
1062
- arrowElement: z(s == null ? void 0 : s.arrowElement, null),
1063
- rendered: Symbol("rendered")
1064
- }), u = it(a, c, o);
1065
- return Te(ce(ce({}, c), u), {
1066
- setAnchorElement: (m) => u.setState("anchorElement", m),
1067
- setPopoverElement: (m) => u.setState("popoverElement", m),
1068
- setArrowElement: (m) => u.setState("arrowElement", m),
1069
- render: () => u.setState("rendered", Symbol("rendered"))
1070
- });
1071
- }
1072
- function Hs(e, t, r) {
1073
- return Ut(t, [r.popover]), re(e, r, "placement"), rr(e, t, r);
1074
- }
1075
- var Dn = Je(null), No = "span", or = ee(
1076
- function(t) {
1077
- return t = W(_({}, t), {
1078
- style: _({
1079
- border: 0,
1080
- clip: "rect(0 0 0 0)",
1081
- height: "1px",
1082
- margin: "-1px",
1083
- overflow: "hidden",
1084
- padding: 0,
1085
- position: "absolute",
1086
- whiteSpace: "nowrap",
1087
- width: "1px"
1088
- }, t.style)
1089
- }), t;
1090
- }
1091
- );
1092
- K(function(t) {
1093
- const r = or(t);
1094
- return Q(No, r);
1095
- });
1096
- var ko = "span", $o = ee(
1097
- function(t) {
1098
- return t = W(_({
1099
- "data-focus-trap": "",
1100
- tabIndex: 0,
1101
- "aria-hidden": !0
1102
- }, t), {
1103
- style: _({
1104
- // Prevents unintended scroll jumps.
1105
- position: "fixed",
1106
- top: 0,
1107
- left: 0
1108
- }, t.style)
1109
- }), t = or(t), t;
1110
- }
1111
- ), vt = K(function(t) {
1112
- const r = $o(t);
1113
- return Q(ko, r);
1114
- }), Vo = "div";
1115
- function Ho(e) {
1116
- return G(e).body;
1117
- }
1118
- function Bo(e, t) {
1119
- return t ? typeof t == "function" ? t(e) : t : G(e).createElement("div");
1120
- }
1121
- function Wo(e = "id") {
1122
- return `${e ? `${e}-` : ""}${Math.random().toString(36).slice(2, 8)}`;
1123
- }
1124
- function Ae(e) {
1125
- queueMicrotask(() => {
1126
- e == null || e.focus();
1127
- });
1128
- }
1129
- var ir = ee(function(t) {
1130
- var r = t, {
1131
- preserveTabOrder: n,
1132
- preserveTabOrderAnchor: o,
1133
- portalElement: s,
1134
- portalRef: c,
1135
- portal: l = !0
1136
- } = r, a = se(r, [
1137
- "preserveTabOrder",
1138
- "preserveTabOrderAnchor",
1139
- "portalElement",
1140
- "portalRef",
1141
- "portal"
1142
- ]);
1143
- const u = Y(null), m = Be(u, a.ref), f = tn(Dn), [i, d] = le(null), [p, h] = le(
1144
- null
1145
- ), x = Y(null), b = Y(null), w = Y(null), E = Y(null);
1146
- return j(() => {
1147
- const g = u.current;
1148
- if (!g || !l) {
1149
- d(null);
1150
- return;
1151
- }
1152
- const v = Bo(g, s);
1153
- if (!v) {
1154
- d(null);
1155
- return;
1156
- }
1157
- const O = v.isConnected;
1158
- if (O || (f || Ho(g)).appendChild(v), v.id || (v.id = g.id ? `portal/${g.id}` : Wo()), d(v), vn(c, v), !O)
1159
- return () => {
1160
- v.remove(), vn(c, null);
1161
- };
1162
- }, [l, s, f, c]), j(() => {
1163
- if (!l || !n || !o) return;
1164
- const v = G(o).createElement("span");
1165
- return v.style.position = "fixed", o.insertAdjacentElement("afterend", v), h(v), () => {
1166
- v.remove(), h(null);
1167
- };
1168
- }, [l, n, o]), U(() => {
1169
- if (!i || !n) return;
1170
- let g = 0;
1171
- const v = (O) => {
1172
- if (!nt(O)) return;
1173
- const S = O.type === "focusin";
1174
- if (cancelAnimationFrame(g), S)
1175
- return eo(i);
1176
- g = requestAnimationFrame(() => {
1177
- to(i, !0);
1178
- });
1179
- };
1180
- return i.addEventListener("focusin", v, !0), i.addEventListener("focusout", v, !0), () => {
1181
- cancelAnimationFrame(g), i.removeEventListener("focusin", v, !0), i.removeEventListener("focusout", v, !0);
1182
- };
1183
- }, [i, n]), a = fe(
1184
- a,
1185
- (g) => {
1186
- if (g = // While the portal node is not in the DOM, we need to pass the
1187
- // current context to the portal context, otherwise it's going to
1188
- // reset to the body element on nested portals.
1189
- /* @__PURE__ */ H(Dn.Provider, { value: i || f, children: g }), !l) return g;
1190
- if (!i)
1191
- return /* @__PURE__ */ H(
1192
- "span",
1193
- {
1194
- ref: m,
1195
- id: a.id,
1196
- style: { position: "fixed" },
1197
- hidden: !0
1198
- }
1199
- );
1200
- g = /* @__PURE__ */ yt(bt, { children: [
1201
- n && i && /* @__PURE__ */ H(
1202
- vt,
1203
- {
1204
- ref: b,
1205
- "data-focus-trap": a.id,
1206
- className: "__focus-trap-inner-before",
1207
- onFocus: (O) => {
1208
- nt(O, i) ? Ae(Ft()) : Ae(x.current);
1209
- }
1210
- }
1211
- ),
1212
- g,
1213
- n && i && /* @__PURE__ */ H(
1214
- vt,
1215
- {
1216
- ref: w,
1217
- "data-focus-trap": a.id,
1218
- className: "__focus-trap-inner-after",
1219
- onFocus: (O) => {
1220
- nt(O, i) ? Ae(yn()) : Ae(E.current);
1221
- }
1222
- }
1223
- )
1224
- ] }), i && (g = Et.createPortal(g, i));
1225
- let v = /* @__PURE__ */ yt(bt, { children: [
1226
- n && i && /* @__PURE__ */ H(
1227
- vt,
1228
- {
1229
- ref: x,
1230
- "data-focus-trap": a.id,
1231
- className: "__focus-trap-outer-before",
1232
- onFocus: (O) => {
1233
- !(O.relatedTarget === E.current) && nt(O, i) ? Ae(b.current) : Ae(yn());
1234
- }
1235
- }
1236
- ),
1237
- n && // We're using position: fixed here so that the browser doesn't
1238
- // add margin to the element when setting gap on a parent element.
1239
- /* @__PURE__ */ H("span", { "aria-owns": i == null ? void 0 : i.id, style: { position: "fixed" } }),
1240
- n && i && /* @__PURE__ */ H(
1241
- vt,
1242
- {
1243
- ref: E,
1244
- "data-focus-trap": a.id,
1245
- className: "__focus-trap-outer-after",
1246
- onFocus: (O) => {
1247
- if (nt(O, i))
1248
- Ae(w.current);
1249
- else {
1250
- const S = Ft();
1251
- if (S === b.current) {
1252
- requestAnimationFrame(() => {
1253
- var $;
1254
- return ($ = Ft()) == null ? void 0 : $.focus();
1255
- });
1256
- return;
1257
- }
1258
- Ae(S);
1259
- }
1260
- }
1261
- }
1262
- )
1263
- ] });
1264
- return p && n && (v = Et.createPortal(
1265
- v,
1266
- p
1267
- )), /* @__PURE__ */ yt(bt, { children: [
1268
- v,
1269
- g
1270
- ] });
1271
- },
1272
- [i, f, l, a.id, n, p]
1273
- ), a = W(_({}, a), {
1274
- ref: m
1275
- }), a;
1276
- });
1277
- K(function(t) {
1278
- const r = ir(t);
1279
- return Q(Vo, r);
1280
- });
1281
- var Cn = Je(0);
1282
- function zo({ level: e, children: t }) {
1283
- const r = tn(Cn), n = Math.max(
1284
- Math.min(e || r + 1, 6),
1285
- 1
1286
- );
1287
- return /* @__PURE__ */ H(Cn.Provider, { value: n, children: t });
1288
- }
1289
- var jo = "div", sr = ee(function(t) {
1290
- var r = t, { autoFocusOnShow: n = !0 } = r, o = se(r, ["autoFocusOnShow"]);
1291
- return o = fe(
1292
- o,
1293
- (s) => /* @__PURE__ */ H(no.Provider, { value: n, children: s }),
1294
- [n]
1295
- ), o;
1296
- });
1297
- K(function(t) {
1298
- const r = sr(t);
1299
- return Q(jo, r);
1300
- });
1301
- function Ko(e, t) {
1302
- const n = G(e).createElement("button");
1303
- return n.type = "button", n.tabIndex = -1, n.textContent = "Dismiss popup", Object.assign(n.style, {
1304
- border: "0px",
1305
- clip: "rect(0 0 0 0)",
1306
- height: "1px",
1307
- margin: "-1px",
1308
- overflow: "hidden",
1309
- padding: "0px",
1310
- position: "absolute",
1311
- whiteSpace: "nowrap",
1312
- width: "1px"
1313
- }), n.addEventListener("click", t), e.prepend(n), () => {
1314
- n.removeEventListener("click", t), n.remove();
1315
- };
1316
- }
1317
- function qo(e) {
1318
- const t = Y();
1319
- return U(() => {
1320
- if (!e) {
1321
- t.current = null;
1322
- return;
1323
- }
1324
- return Qt("mousedown", (n) => {
1325
- t.current = n.target;
1326
- }, !0);
1327
- }, [e]), t;
1328
- }
1329
- var Lt = /* @__PURE__ */ new WeakMap();
1330
- function ut(e, t, r) {
1331
- Lt.has(e) || Lt.set(e, /* @__PURE__ */ new Map());
1332
- const n = Lt.get(e), o = n.get(t);
1333
- if (!o)
1334
- return n.set(t, r()), () => {
1335
- var l;
1336
- (l = n.get(t)) == null || l(), n.delete(t);
1337
- };
1338
- const s = r(), c = () => {
1339
- s(), o(), n.delete(t);
1340
- };
1341
- return n.set(t, c), () => {
1342
- n.get(t) === c && (s(), n.set(t, o));
1343
- };
1344
- }
1345
- function rn(e, t, r) {
1346
- return ut(e, t, () => {
1347
- const o = e.getAttribute(t);
1348
- return e.setAttribute(t, r), () => {
1349
- o == null ? e.removeAttribute(t) : e.setAttribute(t, o);
1350
- };
1351
- });
1352
- }
1353
- function Ve(e, t, r) {
1354
- return ut(e, t, () => {
1355
- const o = t in e, s = e[t];
1356
- return e[t] = r, () => {
1357
- o ? e[t] = s : delete e[t];
1358
- };
1359
- });
1360
- }
1361
- function Bt(e, t) {
1362
- return e ? ut(e, "style", () => {
1363
- const n = e.style.cssText;
1364
- return Object.assign(e.style, t), () => {
1365
- e.style.cssText = n;
1366
- };
1367
- }) : () => {
1368
- };
1369
- }
1370
- function Uo(e, t, r) {
1371
- return e ? ut(e, t, () => {
1372
- const o = e.style.getPropertyValue(t);
1373
- return e.style.setProperty(t, r), () => {
1374
- o ? e.style.setProperty(t, o) : e.style.removeProperty(t);
1375
- };
1376
- }) : () => {
1377
- };
1378
- }
1379
- var Yo = ["SCRIPT", "STYLE"];
1380
- function Wt(e) {
1381
- return `__ariakit-dialog-snapshot-${e}`;
1382
- }
1383
- function Go(e, t) {
1384
- const r = G(t), n = Wt(e);
1385
- if (!r.body[n]) return !0;
1386
- do {
1387
- if (t === r.body) return !1;
1388
- if (t[n]) return !0;
1389
- if (!t.parentElement) return !1;
1390
- t = t.parentElement;
1391
- } while (!0);
1392
- }
1393
- function Xo(e, t, r) {
1394
- return Yo.includes(t.tagName) || !Go(e, t) ? !1 : !r.some(
1395
- (n) => n && de(t, n)
1396
- );
1397
- }
1398
- function on(e, t, r, n) {
1399
- for (let o of t) {
1400
- if (!(o != null && o.isConnected)) continue;
1401
- const s = t.some((a) => !a || a === o ? !1 : a.contains(o)), c = G(o), l = o;
1402
- for (; o.parentElement && o !== c.body; ) {
1403
- if (n == null || n(o.parentElement, l), !s)
1404
- for (const a of o.parentElement.children)
1405
- Xo(e, a, t) && r(a, l);
1406
- o = o.parentElement;
1407
- }
1408
- }
1409
- }
1410
- function Jo(e, t) {
1411
- const { body: r } = G(t[0]), n = [];
1412
- return on(e, t, (s) => {
1413
- n.push(Ve(s, Wt(e), !0));
1414
- }), De(Ve(r, Wt(e), !0), () => {
1415
- for (const s of n)
1416
- s();
1417
- });
1418
- }
1419
- function ar(e, ...t) {
1420
- if (!e) return !1;
1421
- const r = e.getAttribute("data-backdrop");
1422
- return r == null ? !1 : r === "" || r === "true" || !t.length ? !0 : t.some((n) => r === n);
1423
- }
1424
- function Ge(e = "", t = !1) {
1425
- return `__ariakit-dialog-${t ? "ancestor" : "outside"}${e ? `-${e}` : ""}`;
1426
- }
1427
- function Zo(e, t = "") {
1428
- return De(
1429
- Ve(e, Ge(), !0),
1430
- Ve(e, Ge(t), !0)
1431
- );
1432
- }
1433
- function cr(e, t = "") {
1434
- return De(
1435
- Ve(e, Ge("", !0), !0),
1436
- Ve(e, Ge(t, !0), !0)
1437
- );
1438
- }
1439
- function sn(e, t) {
1440
- const r = Ge(t, !0);
1441
- if (e[r]) return !0;
1442
- const n = Ge(t);
1443
- do {
1444
- if (e[n]) return !0;
1445
- if (!e.parentElement) return !1;
1446
- e = e.parentElement;
1447
- } while (!0);
1448
- }
1449
- function An(e, t) {
1450
- const r = [], n = t.map((s) => s == null ? void 0 : s.id);
1451
- return on(
1452
- e,
1453
- t,
1454
- (s) => {
1455
- ar(s, ...n) || r.unshift(Zo(s, e));
1456
- },
1457
- (s, c) => {
1458
- c.hasAttribute("data-dialog") && c.id !== e || r.unshift(cr(s, e));
1459
- }
1460
- ), () => {
1461
- for (const s of r)
1462
- s();
1463
- };
1464
- }
1465
- function Qo(e) {
1466
- return e.tagName === "HTML" ? !0 : de(G(e).body, e);
1467
- }
1468
- function ei(e, t) {
1469
- if (!e) return !1;
1470
- if (de(e, t)) return !0;
1471
- const r = t.getAttribute("aria-activedescendant");
1472
- if (r) {
1473
- const n = G(e).getElementById(r);
1474
- if (n)
1475
- return de(e, n);
1476
- }
1477
- return !1;
1478
- }
1479
- function ti(e, t) {
1480
- if (!("clientY" in e)) return !1;
1481
- const r = t.getBoundingClientRect();
1482
- return r.width === 0 || r.height === 0 ? !1 : r.top <= e.clientY && e.clientY <= r.top + r.height && r.left <= e.clientX && e.clientX <= r.left + r.width;
1483
- }
1484
- function Mt({
1485
- store: e,
1486
- type: t,
1487
- listener: r,
1488
- capture: n,
1489
- domReady: o
1490
- }) {
1491
- const s = ue(r), c = he(e, "open"), l = Y(!1);
1492
- j(() => {
1493
- if (!c || !o) return;
1494
- const { contentElement: a } = e.getState();
1495
- if (!a) return;
1496
- const u = () => {
1497
- l.current = !0;
1498
- };
1499
- return a.addEventListener("focusin", u, !0), () => a.removeEventListener("focusin", u, !0);
1500
- }, [e, c, o]), U(() => c ? Qt(t, (u) => {
1501
- const { contentElement: m, disclosureElement: f } = e.getState(), i = u.target;
1502
- !m || !i || !Qo(i) || de(m, i) || ei(f, i) || i.hasAttribute("data-focus-trap") || ti(u, m) || l.current && !sn(i, m.id) || ro(i) || s(u);
1503
- }, n) : void 0, [c, n]);
1504
- }
1505
- function Nt(e, t) {
1506
- return typeof e == "function" ? e(t) : !!e;
1507
- }
1508
- function ni(e, t, r) {
1509
- const n = he(e, "open"), o = qo(n), s = { store: e, domReady: r, capture: !0 };
1510
- Mt(W(_({}, s), {
1511
- type: "click",
1512
- listener: (c) => {
1513
- const { contentElement: l } = e.getState(), a = o.current;
1514
- a && Lr(a) && sn(a, l == null ? void 0 : l.id) && Nt(t, c) && e.hide();
1515
- }
1516
- })), Mt(W(_({}, s), {
1517
- type: "focusin",
1518
- listener: (c) => {
1519
- const { contentElement: l } = e.getState();
1520
- l && c.target !== G(l) && Nt(t, c) && e.hide();
1521
- }
1522
- })), Mt(W(_({}, s), {
1523
- type: "contextmenu",
1524
- listener: (c) => {
1525
- Nt(t, c) && e.hide();
1526
- }
1527
- }));
1528
- }
1529
- var Tn = Je({});
1530
- function ri(e) {
1531
- const t = tn(Tn), [r, n] = le([]), o = st(
1532
- (l) => {
1533
- var a;
1534
- return n((u) => [...u, l]), De((a = t.add) == null ? void 0 : a.call(t, l), () => {
1535
- n((u) => u.filter((m) => m !== l));
1536
- });
1537
- },
1538
- [t]
1539
- );
1540
- j(() => xt(e, ["open", "contentElement"], (l) => {
1541
- var a;
1542
- if (l.open && l.contentElement)
1543
- return (a = t.add) == null ? void 0 : a.call(t, e);
1544
- }), [e, t]);
1545
- const s = Gn(() => ({ store: e, add: o }), [e, o]);
1546
- return { wrapElement: st(
1547
- (l) => /* @__PURE__ */ H(Tn.Provider, { value: s, children: l }),
1548
- [s]
1549
- ), nestedDialogs: r };
1550
- }
1551
- function oi({
1552
- attribute: e,
1553
- contentId: t,
1554
- contentElement: r,
1555
- enabled: n
1556
- }) {
1557
- const [o, s] = Mr(), c = st(() => {
1558
- if (!n || !r) return !1;
1559
- const { body: l } = G(r), a = l.getAttribute(e);
1560
- return !a || a === t;
1561
- }, [o, n, r, e, t]);
1562
- return U(() => {
1563
- if (!n || !t || !r) return;
1564
- const { body: l } = G(r);
1565
- if (c())
1566
- return l.setAttribute(e, t), () => l.removeAttribute(e);
1567
- const a = new MutationObserver(() => Et.flushSync(s));
1568
- return a.observe(l, { attributeFilter: [e] }), () => a.disconnect();
1569
- }, [o, n, t, r, c, e]), c;
1570
- }
1571
- function ii(e) {
1572
- const t = e.getBoundingClientRect().left;
1573
- return Math.round(t) + e.scrollLeft ? "paddingLeft" : "paddingRight";
1574
- }
1575
- function si(e, t, r) {
1576
- const n = oi({
1577
- attribute: "data-dialog-prevent-body-scroll",
1578
- contentElement: e,
1579
- contentId: t,
1580
- enabled: r
1581
- });
1582
- U(() => {
1583
- if (!n() || !e) return;
1584
- const o = G(e), s = Wn(e), { documentElement: c, body: l } = o, a = c.style.getPropertyValue("--scrollbar-width"), u = a ? Number.parseInt(a) : s.innerWidth - c.clientWidth, m = () => Uo(
1585
- c,
1586
- "--scrollbar-width",
1587
- `${u}px`
1588
- ), f = ii(c), i = () => Bt(l, {
1589
- overflow: "hidden",
1590
- [f]: `${u}px`
1591
- }), d = () => {
1592
- var h, x;
1593
- const { scrollX: b, scrollY: w, visualViewport: E } = s, g = (h = E == null ? void 0 : E.offsetLeft) != null ? h : 0, v = (x = E == null ? void 0 : E.offsetTop) != null ? x : 0, O = Bt(l, {
1594
- position: "fixed",
1595
- overflow: "hidden",
1596
- top: `${-(w - Math.floor(v))}px`,
1597
- left: `${-(b - Math.floor(g))}px`,
1598
- right: "0",
1599
- [f]: `${u}px`
1600
- });
1601
- return () => {
1602
- O(), process.env.NODE_ENV !== "test" && s.scrollTo({ left: b, top: w, behavior: "instant" });
1603
- };
1604
- }, p = Nr() && !kr();
1605
- return De(
1606
- m(),
1607
- p ? d() : i()
1608
- );
1609
- }, [n, e]);
1610
- }
1611
- function ai(e, ...t) {
1612
- if (!e) return !1;
1613
- const r = e.getAttribute("data-focus-trap");
1614
- return r == null ? !1 : t.length ? r === "" ? !1 : t.some((n) => r === n) : !0;
1615
- }
1616
- function ur() {
1617
- return "inert" in HTMLElement.prototype;
1618
- }
1619
- function ci(e) {
1620
- return rn(e, "aria-hidden", "true");
1621
- }
1622
- function lr(e, t) {
1623
- if (!("style" in e)) return Rt;
1624
- if (ur())
1625
- return Ve(e, "inert", !0);
1626
- const n = oo(e, !0).map((o) => {
1627
- if (t != null && t.some((c) => c && de(c, o))) return Rt;
1628
- const s = ut(o, "focus", () => (o.focus = Rt, () => {
1629
- delete o.focus;
1630
- }));
1631
- return De(rn(o, "tabindex", "-1"), s);
1632
- });
1633
- return De(
1634
- ...n,
1635
- ci(e),
1636
- Bt(e, {
1637
- pointerEvents: "none",
1638
- userSelect: "none",
1639
- cursor: "default"
1640
- })
1641
- );
1642
- }
1643
- function ui(e, t) {
1644
- const r = [], n = t.map((s) => s == null ? void 0 : s.id);
1645
- return on(
1646
- e,
1647
- t,
1648
- (s) => {
1649
- ar(s, ...n) || ai(s, ...n) || r.unshift(lr(s, t));
1650
- },
1651
- (s) => {
1652
- s.hasAttribute("role") && (t.some((c) => c && de(c, s)) || r.unshift(rn(s, "role", "none")));
1653
- }
1654
- ), () => {
1655
- for (const s of r)
1656
- s();
1657
- };
1658
- }
1659
- var li = "div", fi = [
1660
- "a",
1661
- "button",
1662
- "details",
1663
- "dialog",
1664
- "div",
1665
- "form",
1666
- "h1",
1667
- "h2",
1668
- "h3",
1669
- "h4",
1670
- "h5",
1671
- "h6",
1672
- "header",
1673
- "img",
1674
- "input",
1675
- "label",
1676
- "li",
1677
- "nav",
1678
- "ol",
1679
- "p",
1680
- "section",
1681
- "select",
1682
- "span",
1683
- "summary",
1684
- "textarea",
1685
- "ul",
1686
- "svg"
1687
- ];
1688
- ee(
1689
- function(t) {
1690
- return t;
1691
- }
1692
- );
1693
- var zt = K(
1694
- // @ts-expect-error
1695
- function(t) {
1696
- return Q(li, t);
1697
- }
1698
- );
1699
- Object.assign(
1700
- zt,
1701
- fi.reduce((e, t) => (e[t] = K(function(n) {
1702
- return Q(t, n);
1703
- }), e), {})
1704
- );
1705
- function di({
1706
- store: e,
1707
- backdrop: t,
1708
- alwaysVisible: r,
1709
- hidden: n
1710
- }) {
1711
- const o = Y(null), s = Lo({ disclosure: e }), c = he(e, "contentElement");
1712
- U(() => {
1713
- const u = o.current, m = c;
1714
- u && m && (u.style.zIndex = getComputedStyle(m).zIndex);
1715
- }, [c]), j(() => {
1716
- const u = c == null ? void 0 : c.id;
1717
- if (!u) return;
1718
- const m = o.current;
1719
- if (m)
1720
- return cr(m, u);
1721
- }, [c]);
1722
- const l = nn({
1723
- ref: o,
1724
- store: s,
1725
- role: "presentation",
1726
- "data-backdrop": (c == null ? void 0 : c.id) || "",
1727
- alwaysVisible: r,
1728
- hidden: n ?? void 0,
1729
- style: {
1730
- position: "fixed",
1731
- top: 0,
1732
- right: 0,
1733
- bottom: 0,
1734
- left: 0
1735
- }
1736
- });
1737
- if (!t) return null;
1738
- if (uo(t))
1739
- return /* @__PURE__ */ H(zt, W(_({}, l), { render: t }));
1740
- const a = typeof t != "boolean" ? t : "div";
1741
- return /* @__PURE__ */ H(zt, W(_({}, l), { render: /* @__PURE__ */ H(a, {}) }));
1742
- }
1743
- var mi = "div", _n = Br();
1744
- function pi(e) {
1745
- const t = Xt();
1746
- return !t || e && de(e, t) ? !1 : !!ot(t);
1747
- }
1748
- function Rn(e, t = !1) {
1749
- if (!e) return null;
1750
- const r = "current" in e ? e.current : e;
1751
- return r ? t ? ot(r) ? r : null : r : null;
1752
- }
1753
- var fr = ee(function(t) {
1754
- var r = t, {
1755
- store: n,
1756
- open: o,
1757
- onClose: s,
1758
- focusable: c = !0,
1759
- modal: l = !0,
1760
- portal: a = !!l,
1761
- backdrop: u = !!l,
1762
- hideOnEscape: m = !0,
1763
- hideOnInteractOutside: f = !0,
1764
- getPersistentElements: i,
1765
- preventBodyScroll: d = !!l,
1766
- autoFocusOnShow: p = !0,
1767
- autoFocusOnHide: h = !0,
1768
- initialFocus: x,
1769
- finalFocus: b,
1770
- unmountOnHide: w,
1771
- unstable_treeSnapshotKey: E
1772
- } = r, g = se(r, [
1773
- "store",
1774
- "open",
1775
- "onClose",
1776
- "focusable",
1777
- "modal",
1778
- "portal",
1779
- "backdrop",
1780
- "hideOnEscape",
1781
- "hideOnInteractOutside",
1782
- "getPersistentElements",
1783
- "preventBodyScroll",
1784
- "autoFocusOnShow",
1785
- "autoFocusOnHide",
1786
- "initialFocus",
1787
- "finalFocus",
1788
- "unmountOnHide",
1789
- "unstable_treeSnapshotKey"
1790
- ]);
1791
- const v = Dt(), O = Y(null), S = Mo({
1792
- store: n || v,
1793
- open: o,
1794
- setOpen(P) {
1795
- if (P) return;
1796
- const F = O.current;
1797
- if (!F) return;
1798
- const X = new Event("close", { bubbles: !1, cancelable: !0 });
1799
- s && F.addEventListener("close", s, { once: !0 }), F.dispatchEvent(X), X.defaultPrevented && S.setOpen(!0);
1800
- }
1801
- }), { portalRef: $, domReady: C } = zn(a, g.portalRef), R = g.preserveTabOrder, B = he(
1802
- S,
1803
- (P) => R && !l && P.mounted
1804
- ), L = Yt(g.id), y = he(S, "open"), D = he(S, "mounted"), A = he(S, "contentElement"), M = Qn(D, g.hidden, g.alwaysVisible);
1805
- si(A, L, d && !M), ni(S, f, C);
1806
- const { wrapElement: I, nestedDialogs: V } = ri(S);
1807
- g = fe(g, I, [I]), j(() => {
1808
- if (!y) return;
1809
- const P = O.current, F = Xt(P, !0);
1810
- F && F.tagName !== "BODY" && (P && de(P, F) || S.setDisclosureElement(F));
1811
- }, [S, y]), _n && U(() => {
1812
- if (!D) return;
1813
- const { disclosureElement: P } = S.getState();
1814
- if (!P || !Vt(P)) return;
1815
- const F = () => {
1816
- let X = !1;
1817
- const N = () => {
1818
- X = !0;
1819
- }, ne = { capture: !0, once: !0 };
1820
- P.addEventListener("focusin", N, ne), Hr(P, "mouseup", () => {
1821
- P.removeEventListener("focusin", N, !0), !X && so(P);
1822
- });
1823
- };
1824
- return P.addEventListener("mousedown", F), () => {
1825
- P.removeEventListener("mousedown", F);
1826
- };
1827
- }, [S, D]), U(() => {
1828
- if (!D || !C) return;
1829
- const P = O.current;
1830
- if (!P) return;
1831
- const F = Wn(P), X = F.visualViewport || F, N = () => {
1832
- var ne, ve;
1833
- const tt = (ve = (ne = F.visualViewport) == null ? void 0 : ne.height) != null ? ve : F.innerHeight;
1834
- P.style.setProperty("--dialog-viewport-height", `${tt}px`);
1835
- };
1836
- return N(), X.addEventListener("resize", N), () => {
1837
- X.removeEventListener("resize", N);
1838
- };
1839
- }, [D, C]), U(() => {
1840
- if (!l || !D || !C) return;
1841
- const P = O.current;
1842
- if (!(!P || P.querySelector("[data-dialog-dismiss]")))
1843
- return Ko(P, S.hide);
1844
- }, [S, l, D, C]), j(() => {
1845
- if (!ur() || y || !D || !C) return;
1846
- const P = O.current;
1847
- if (P)
1848
- return lr(P);
1849
- }, [y, D, C]);
1850
- const T = y && C;
1851
- j(() => {
1852
- if (!L || !T) return;
1853
- const P = O.current;
1854
- return Jo(L, [P]);
1855
- }, [L, T, E]);
1856
- const k = ue(i);
1857
- j(() => {
1858
- if (!L || !T) return;
1859
- const { disclosureElement: P } = S.getState(), F = O.current, X = k() || [], N = [
1860
- F,
1861
- ...X,
1862
- ...V.map((ne) => ne.getState().contentElement)
1863
- ];
1864
- return l ? De(
1865
- An(L, N),
1866
- ui(L, N)
1867
- ) : An(L, [P, ...N]);
1868
- }, [
1869
- L,
1870
- S,
1871
- T,
1872
- k,
1873
- V,
1874
- l,
1875
- E
1876
- ]);
1877
- const q = !!p, We = rt(p), [et, ae] = le(!1);
1878
- U(() => {
1879
- if (!y || !q || !C || !(A != null && A.isConnected)) return;
1880
- const P = Rn(x, !0) || // If no initial focus is specified, we try to focus the first element
1881
- // with the autofocus attribute. If it's an Ariakit component, the
1882
- // Focusable component will consume the autoFocus prop and add the
1883
- // data-autofocus attribute to the element instead.
1884
- A.querySelector(
1885
- "[data-autofocus=true],[autofocus]"
1886
- ) || // We have to fallback to the first focusable element otherwise portaled
1887
- // dialogs with preserveTabOrder set to true will not receive focus
1888
- // properly because the elements aren't tabbable until the dialog receives
1889
- // focus.
1890
- io(A, !0, a && B) || // Finally, we fallback to the dialog element itself.
1891
- A, F = ot(P);
1892
- We(F ? P : null) && (ae(!0), queueMicrotask(() => {
1893
- P.focus(), _n && F && P.scrollIntoView({ block: "nearest", inline: "nearest" });
1894
- }));
1895
- }, [
1896
- y,
1897
- q,
1898
- C,
1899
- A,
1900
- x,
1901
- a,
1902
- B,
1903
- We
1904
- ]);
1905
- const te = !!h, xe = rt(h), [ze, Ee] = le(!1);
1906
- U(() => {
1907
- if (y)
1908
- return Ee(!0), () => Ee(!1);
1909
- }, [y]);
1910
- const Le = st(
1911
- (P, F = !0) => {
1912
- const { disclosureElement: X } = S.getState();
1913
- if (pi(P)) return;
1914
- let N = Rn(b) || X;
1915
- if (N != null && N.id) {
1916
- const ve = G(N), tt = `[aria-activedescendant="${N.id}"]`, pt = ve.querySelector(tt);
1917
- pt && (N = pt);
1918
- }
1919
- if (N && !ot(N)) {
1920
- const ve = N.closest("[data-dialog]");
1921
- if (ve != null && ve.id) {
1922
- const tt = G(ve), pt = `[aria-controls~="${ve.id}"]`, gn = tt.querySelector(pt);
1923
- gn && (N = gn);
1924
- }
1925
- }
1926
- const ne = N && ot(N);
1927
- if (!ne && F) {
1928
- requestAnimationFrame(() => Le(P, !1));
1929
- return;
1930
- }
1931
- xe(ne ? N : null) && ne && (N == null || N.focus({ preventScroll: !0 }));
1932
- },
1933
- [S, b, xe]
1934
- ), ge = Y(!1);
1935
- j(() => {
1936
- if (y || !ze || !te) return;
1937
- const P = O.current;
1938
- ge.current = !0, Le(P);
1939
- }, [y, ze, C, te, Le]), U(() => {
1940
- if (!ze || !te) return;
1941
- const P = O.current;
1942
- return () => {
1943
- if (ge.current) {
1944
- ge.current = !1;
1945
- return;
1946
- }
1947
- Le(P);
1948
- };
1949
- }, [ze, te, Le]);
1950
- const ft = rt(m);
1951
- U(() => !C || !D ? void 0 : Qt("keydown", (F) => {
1952
- if (F.key !== "Escape" || F.defaultPrevented) return;
1953
- const X = O.current;
1954
- if (!X || sn(X)) return;
1955
- const N = F.target;
1956
- if (!N) return;
1957
- const { disclosureElement: ne } = S.getState();
1958
- !!(N.tagName === "BODY" || de(X, N) || !ne || de(ne, N)) && ft(F) && S.hide();
1959
- }, !0), [S, C, D, ft]), g = fe(
1960
- g,
1961
- (P) => /* @__PURE__ */ H(zo, { level: l ? 1 : void 0, children: P }),
1962
- [l]
1963
- );
1964
- const dt = g.hidden, Me = g.alwaysVisible;
1965
- g = fe(
1966
- g,
1967
- (P) => u ? /* @__PURE__ */ yt(bt, { children: [
1968
- /* @__PURE__ */ H(
1969
- di,
1970
- {
1971
- store: S,
1972
- backdrop: u,
1973
- hidden: dt,
1974
- alwaysVisible: Me
1975
- }
1976
- ),
1977
- P
1978
- ] }) : P,
1979
- [S, u, dt, Me]
1980
- );
1981
- const [je, mt] = le(), [Ke, qe] = le();
1982
- return g = fe(
1983
- g,
1984
- (P) => /* @__PURE__ */ H(Hn, { value: S, children: /* @__PURE__ */ H($r.Provider, { value: mt, children: /* @__PURE__ */ H(Vr.Provider, { value: qe, children: P }) }) }),
1985
- [S]
1986
- ), g = W(_({
1987
- id: L,
1988
- "data-dialog": "",
1989
- role: "dialog",
1990
- tabIndex: c ? -1 : void 0,
1991
- "aria-labelledby": je,
1992
- "aria-describedby": Ke
1993
- }, g), {
1994
- ref: Be(O, g.ref)
1995
- }), g = sr(W(_({}, g), {
1996
- autoFocusOnShow: et
1997
- })), g = nn(_({ store: S }, g)), g = jn(W(_({}, g), { focusable: c })), g = ir(W(_({ portal: a }, g), { portalRef: $, preserveTabOrder: B })), g;
1998
- });
1999
- function dr(e, t = Dt) {
2000
- return K(function(n) {
2001
- const o = t(), s = n.store || o;
2002
- return he(
2003
- s,
2004
- (l) => !n.unmountOnHide || (l == null ? void 0 : l.mounted) || !!n.open
2005
- ) ? /* @__PURE__ */ H(e, _({}, n)) : null;
2006
- });
2007
- }
2008
- dr(
2009
- K(function(t) {
2010
- const r = fr(t);
2011
- return Q(mi, r);
2012
- }),
2013
- Dt
2014
- );
2015
- const _e = Math.min, oe = Math.max, St = Math.round, ht = Math.floor, ye = (e) => ({
2016
- x: e,
2017
- y: e
2018
- }), gi = {
2019
- left: "right",
2020
- right: "left",
2021
- bottom: "top",
2022
- top: "bottom"
2023
- }, vi = {
2024
- start: "end",
2025
- end: "start"
2026
- };
2027
- function jt(e, t, r) {
2028
- return oe(e, _e(t, r));
2029
- }
2030
- function Re(e, t) {
2031
- return typeof e == "function" ? e(t) : e;
2032
- }
2033
- function Ce(e) {
2034
- return e.split("-")[0];
2035
- }
2036
- function Ze(e) {
2037
- return e.split("-")[1];
2038
- }
2039
- function an(e) {
2040
- return e === "x" ? "y" : "x";
2041
- }
2042
- function cn(e) {
2043
- return e === "y" ? "height" : "width";
2044
- }
2045
- function Pe(e) {
2046
- return ["top", "bottom"].includes(Ce(e)) ? "y" : "x";
2047
- }
2048
- function un(e) {
2049
- return an(Pe(e));
2050
- }
2051
- function hi(e, t, r) {
2052
- r === void 0 && (r = !1);
2053
- const n = Ze(e), o = un(e), s = cn(o);
2054
- let c = o === "x" ? n === (r ? "end" : "start") ? "right" : "left" : n === "start" ? "bottom" : "top";
2055
- return t.reference[s] > t.floating[s] && (c = Ot(c)), [c, Ot(c)];
2056
- }
2057
- function yi(e) {
2058
- const t = Ot(e);
2059
- return [Kt(e), t, Kt(t)];
2060
- }
2061
- function Kt(e) {
2062
- return e.replace(/start|end/g, (t) => vi[t]);
2063
- }
2064
- function bi(e, t, r) {
2065
- const n = ["left", "right"], o = ["right", "left"], s = ["top", "bottom"], c = ["bottom", "top"];
2066
- switch (e) {
2067
- case "top":
2068
- case "bottom":
2069
- return r ? t ? o : n : t ? n : o;
2070
- case "left":
2071
- case "right":
2072
- return t ? s : c;
2073
- default:
2074
- return [];
2075
- }
2076
- }
2077
- function wi(e, t, r, n) {
2078
- const o = Ze(e);
2079
- let s = bi(Ce(e), r === "start", n);
2080
- return o && (s = s.map((c) => c + "-" + o), t && (s = s.concat(s.map(Kt)))), s;
2081
- }
2082
- function Ot(e) {
2083
- return e.replace(/left|right|bottom|top/g, (t) => gi[t]);
2084
- }
2085
- function xi(e) {
2086
- return {
2087
- top: 0,
2088
- right: 0,
2089
- bottom: 0,
2090
- left: 0,
2091
- ...e
2092
- };
2093
- }
2094
- function mr(e) {
2095
- return typeof e != "number" ? xi(e) : {
2096
- top: e,
2097
- right: e,
2098
- bottom: e,
2099
- left: e
2100
- };
2101
- }
2102
- function Pt(e) {
2103
- const {
2104
- x: t,
2105
- y: r,
2106
- width: n,
2107
- height: o
2108
- } = e;
2109
- return {
2110
- width: n,
2111
- height: o,
2112
- top: r,
2113
- left: t,
2114
- right: t + n,
2115
- bottom: r + o,
2116
- x: t,
2117
- y: r
2118
- };
2119
- }
2120
- function In(e, t, r) {
2121
- let {
2122
- reference: n,
2123
- floating: o
2124
- } = e;
2125
- const s = Pe(t), c = un(t), l = cn(c), a = Ce(t), u = s === "y", m = n.x + n.width / 2 - o.width / 2, f = n.y + n.height / 2 - o.height / 2, i = n[l] / 2 - o[l] / 2;
2126
- let d;
2127
- switch (a) {
2128
- case "top":
2129
- d = {
2130
- x: m,
2131
- y: n.y - o.height
2132
- };
2133
- break;
2134
- case "bottom":
2135
- d = {
2136
- x: m,
2137
- y: n.y + n.height
2138
- };
2139
- break;
2140
- case "right":
2141
- d = {
2142
- x: n.x + n.width,
2143
- y: f
2144
- };
2145
- break;
2146
- case "left":
2147
- d = {
2148
- x: n.x - o.width,
2149
- y: f
2150
- };
2151
- break;
2152
- default:
2153
- d = {
2154
- x: n.x,
2155
- y: n.y
2156
- };
2157
- }
2158
- switch (Ze(t)) {
2159
- case "start":
2160
- d[c] -= i * (r && u ? -1 : 1);
2161
- break;
2162
- case "end":
2163
- d[c] += i * (r && u ? -1 : 1);
2164
- break;
2165
- }
2166
- return d;
2167
- }
2168
- const Ei = async (e, t, r) => {
2169
- const {
2170
- placement: n = "bottom",
2171
- strategy: o = "absolute",
2172
- middleware: s = [],
2173
- platform: c
2174
- } = r, l = s.filter(Boolean), a = await (c.isRTL == null ? void 0 : c.isRTL(t));
2175
- let u = await c.getElementRects({
2176
- reference: e,
2177
- floating: t,
2178
- strategy: o
2179
- }), {
2180
- x: m,
2181
- y: f
2182
- } = In(u, n, a), i = n, d = {}, p = 0;
2183
- for (let h = 0; h < l.length; h++) {
2184
- const {
2185
- name: x,
2186
- fn: b
2187
- } = l[h], {
2188
- x: w,
2189
- y: E,
2190
- data: g,
2191
- reset: v
2192
- } = await b({
2193
- x: m,
2194
- y: f,
2195
- initialPlacement: n,
2196
- placement: i,
2197
- strategy: o,
2198
- middlewareData: d,
2199
- rects: u,
2200
- platform: c,
2201
- elements: {
2202
- reference: e,
2203
- floating: t
2204
- }
2205
- });
2206
- m = w ?? m, f = E ?? f, d = {
2207
- ...d,
2208
- [x]: {
2209
- ...d[x],
2210
- ...g
2211
- }
2212
- }, v && p <= 50 && (p++, typeof v == "object" && (v.placement && (i = v.placement), v.rects && (u = v.rects === !0 ? await c.getElementRects({
2213
- reference: e,
2214
- floating: t,
2215
- strategy: o
2216
- }) : v.rects), {
2217
- x: m,
2218
- y: f
2219
- } = In(u, i, a)), h = -1);
2220
- }
2221
- return {
2222
- x: m,
2223
- y: f,
2224
- placement: i,
2225
- strategy: o,
2226
- middlewareData: d
2227
- };
2228
- };
2229
- async function ln(e, t) {
2230
- var r;
2231
- t === void 0 && (t = {});
2232
- const {
2233
- x: n,
2234
- y: o,
2235
- platform: s,
2236
- rects: c,
2237
- elements: l,
2238
- strategy: a
2239
- } = e, {
2240
- boundary: u = "clippingAncestors",
2241
- rootBoundary: m = "viewport",
2242
- elementContext: f = "floating",
2243
- altBoundary: i = !1,
2244
- padding: d = 0
2245
- } = Re(t, e), p = mr(d), x = l[i ? f === "floating" ? "reference" : "floating" : f], b = Pt(await s.getClippingRect({
2246
- element: (r = await (s.isElement == null ? void 0 : s.isElement(x))) == null || r ? x : x.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(l.floating)),
2247
- boundary: u,
2248
- rootBoundary: m,
2249
- strategy: a
2250
- })), w = f === "floating" ? {
2251
- x: n,
2252
- y: o,
2253
- width: c.floating.width,
2254
- height: c.floating.height
2255
- } : c.reference, E = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(l.floating)), g = await (s.isElement == null ? void 0 : s.isElement(E)) ? await (s.getScale == null ? void 0 : s.getScale(E)) || {
2256
- x: 1,
2257
- y: 1
2258
- } : {
2259
- x: 1,
2260
- y: 1
2261
- }, v = Pt(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({
2262
- elements: l,
2263
- rect: w,
2264
- offsetParent: E,
2265
- strategy: a
2266
- }) : w);
2267
- return {
2268
- top: (b.top - v.top + p.top) / g.y,
2269
- bottom: (v.bottom - b.bottom + p.bottom) / g.y,
2270
- left: (b.left - v.left + p.left) / g.x,
2271
- right: (v.right - b.right + p.right) / g.x
2272
- };
2273
- }
2274
- const Si = (e) => ({
2275
- name: "arrow",
2276
- options: e,
2277
- async fn(t) {
2278
- const {
2279
- x: r,
2280
- y: n,
2281
- placement: o,
2282
- rects: s,
2283
- platform: c,
2284
- elements: l,
2285
- middlewareData: a
2286
- } = t, {
2287
- element: u,
2288
- padding: m = 0
2289
- } = Re(e, t) || {};
2290
- if (u == null)
2291
- return {};
2292
- const f = mr(m), i = {
2293
- x: r,
2294
- y: n
2295
- }, d = un(o), p = cn(d), h = await c.getDimensions(u), x = d === "y", b = x ? "top" : "left", w = x ? "bottom" : "right", E = x ? "clientHeight" : "clientWidth", g = s.reference[p] + s.reference[d] - i[d] - s.floating[p], v = i[d] - s.reference[d], O = await (c.getOffsetParent == null ? void 0 : c.getOffsetParent(u));
2296
- let S = O ? O[E] : 0;
2297
- (!S || !await (c.isElement == null ? void 0 : c.isElement(O))) && (S = l.floating[E] || s.floating[p]);
2298
- const $ = g / 2 - v / 2, C = S / 2 - h[p] / 2 - 1, R = _e(f[b], C), B = _e(f[w], C), L = R, y = S - h[p] - B, D = S / 2 - h[p] / 2 + $, A = jt(L, D, y), M = !a.arrow && Ze(o) != null && D !== A && s.reference[p] / 2 - (D < L ? R : B) - h[p] / 2 < 0, I = M ? D < L ? D - L : D - y : 0;
2299
- return {
2300
- [d]: i[d] + I,
2301
- data: {
2302
- [d]: A,
2303
- centerOffset: D - A - I,
2304
- ...M && {
2305
- alignmentOffset: I
2306
- }
2307
- },
2308
- reset: M
2309
- };
2310
- }
2311
- }), Oi = function(e) {
2312
- return e === void 0 && (e = {}), {
2313
- name: "flip",
2314
- options: e,
2315
- async fn(t) {
2316
- var r, n;
2317
- const {
2318
- placement: o,
2319
- middlewareData: s,
2320
- rects: c,
2321
- initialPlacement: l,
2322
- platform: a,
2323
- elements: u
2324
- } = t, {
2325
- mainAxis: m = !0,
2326
- crossAxis: f = !0,
2327
- fallbackPlacements: i,
2328
- fallbackStrategy: d = "bestFit",
2329
- fallbackAxisSideDirection: p = "none",
2330
- flipAlignment: h = !0,
2331
- ...x
2332
- } = Re(e, t);
2333
- if ((r = s.arrow) != null && r.alignmentOffset)
2334
- return {};
2335
- const b = Ce(o), w = Pe(l), E = Ce(l) === l, g = await (a.isRTL == null ? void 0 : a.isRTL(u.floating)), v = i || (E || !h ? [Ot(l)] : yi(l)), O = p !== "none";
2336
- !i && O && v.push(...wi(l, h, p, g));
2337
- const S = [l, ...v], $ = await ln(t, x), C = [];
2338
- let R = ((n = s.flip) == null ? void 0 : n.overflows) || [];
2339
- if (m && C.push($[b]), f) {
2340
- const A = hi(o, c, g);
2341
- C.push($[A[0]], $[A[1]]);
2342
- }
2343
- if (R = [...R, {
2344
- placement: o,
2345
- overflows: C
2346
- }], !C.every((A) => A <= 0)) {
2347
- var B, L;
2348
- const A = (((B = s.flip) == null ? void 0 : B.index) || 0) + 1, M = S[A];
2349
- if (M) {
2350
- var y;
2351
- const V = f === "alignment" ? w !== Pe(M) : !1, T = ((y = R[0]) == null ? void 0 : y.overflows[0]) > 0;
2352
- if (!V || T)
2353
- return {
2354
- data: {
2355
- index: A,
2356
- overflows: R
2357
- },
2358
- reset: {
2359
- placement: M
2360
- }
2361
- };
2362
- }
2363
- let I = (L = R.filter((V) => V.overflows[0] <= 0).sort((V, T) => V.overflows[1] - T.overflows[1])[0]) == null ? void 0 : L.placement;
2364
- if (!I)
2365
- switch (d) {
2366
- case "bestFit": {
2367
- var D;
2368
- const V = (D = R.filter((T) => {
2369
- if (O) {
2370
- const k = Pe(T.placement);
2371
- return k === w || // Create a bias to the `y` side axis due to horizontal
2372
- // reading directions favoring greater width.
2373
- k === "y";
2374
- }
2375
- return !0;
2376
- }).map((T) => [T.placement, T.overflows.filter((k) => k > 0).reduce((k, q) => k + q, 0)]).sort((T, k) => T[1] - k[1])[0]) == null ? void 0 : D[0];
2377
- V && (I = V);
2378
- break;
2379
- }
2380
- case "initialPlacement":
2381
- I = l;
2382
- break;
2383
- }
2384
- if (o !== I)
2385
- return {
2386
- reset: {
2387
- placement: I
2388
- }
2389
- };
2390
- }
2391
- return {};
2392
- }
2393
- };
2394
- };
2395
- async function Pi(e, t) {
2396
- const {
2397
- placement: r,
2398
- platform: n,
2399
- elements: o
2400
- } = e, s = await (n.isRTL == null ? void 0 : n.isRTL(o.floating)), c = Ce(r), l = Ze(r), a = Pe(r) === "y", u = ["left", "top"].includes(c) ? -1 : 1, m = s && a ? -1 : 1, f = Re(t, e);
2401
- let {
2402
- mainAxis: i,
2403
- crossAxis: d,
2404
- alignmentAxis: p
2405
- } = typeof f == "number" ? {
2406
- mainAxis: f,
2407
- crossAxis: 0,
2408
- alignmentAxis: null
2409
- } : {
2410
- mainAxis: f.mainAxis || 0,
2411
- crossAxis: f.crossAxis || 0,
2412
- alignmentAxis: f.alignmentAxis
2413
- };
2414
- return l && typeof p == "number" && (d = l === "end" ? p * -1 : p), a ? {
2415
- x: d * m,
2416
- y: i * u
2417
- } : {
2418
- x: i * u,
2419
- y: d * m
2420
- };
2421
- }
2422
- const Di = function(e) {
2423
- return e === void 0 && (e = 0), {
2424
- name: "offset",
2425
- options: e,
2426
- async fn(t) {
2427
- var r, n;
2428
- const {
2429
- x: o,
2430
- y: s,
2431
- placement: c,
2432
- middlewareData: l
2433
- } = t, a = await Pi(t, e);
2434
- return c === ((r = l.offset) == null ? void 0 : r.placement) && (n = l.arrow) != null && n.alignmentOffset ? {} : {
2435
- x: o + a.x,
2436
- y: s + a.y,
2437
- data: {
2438
- ...a,
2439
- placement: c
2440
- }
2441
- };
2442
- }
2443
- };
2444
- }, Ci = function(e) {
2445
- return e === void 0 && (e = {}), {
2446
- name: "shift",
2447
- options: e,
2448
- async fn(t) {
2449
- const {
2450
- x: r,
2451
- y: n,
2452
- placement: o
2453
- } = t, {
2454
- mainAxis: s = !0,
2455
- crossAxis: c = !1,
2456
- limiter: l = {
2457
- fn: (x) => {
2458
- let {
2459
- x: b,
2460
- y: w
2461
- } = x;
2462
- return {
2463
- x: b,
2464
- y: w
2465
- };
2466
- }
2467
- },
2468
- ...a
2469
- } = Re(e, t), u = {
2470
- x: r,
2471
- y: n
2472
- }, m = await ln(t, a), f = Pe(Ce(o)), i = an(f);
2473
- let d = u[i], p = u[f];
2474
- if (s) {
2475
- const x = i === "y" ? "top" : "left", b = i === "y" ? "bottom" : "right", w = d + m[x], E = d - m[b];
2476
- d = jt(w, d, E);
2477
- }
2478
- if (c) {
2479
- const x = f === "y" ? "top" : "left", b = f === "y" ? "bottom" : "right", w = p + m[x], E = p - m[b];
2480
- p = jt(w, p, E);
2481
- }
2482
- const h = l.fn({
2483
- ...t,
2484
- [i]: d,
2485
- [f]: p
2486
- });
2487
- return {
2488
- ...h,
2489
- data: {
2490
- x: h.x - r,
2491
- y: h.y - n,
2492
- enabled: {
2493
- [i]: s,
2494
- [f]: c
2495
- }
2496
- }
2497
- };
2498
- }
2499
- };
2500
- }, Ai = function(e) {
2501
- return e === void 0 && (e = {}), {
2502
- options: e,
2503
- fn(t) {
2504
- const {
2505
- x: r,
2506
- y: n,
2507
- placement: o,
2508
- rects: s,
2509
- middlewareData: c
2510
- } = t, {
2511
- offset: l = 0,
2512
- mainAxis: a = !0,
2513
- crossAxis: u = !0
2514
- } = Re(e, t), m = {
2515
- x: r,
2516
- y: n
2517
- }, f = Pe(o), i = an(f);
2518
- let d = m[i], p = m[f];
2519
- const h = Re(l, t), x = typeof h == "number" ? {
2520
- mainAxis: h,
2521
- crossAxis: 0
2522
- } : {
2523
- mainAxis: 0,
2524
- crossAxis: 0,
2525
- ...h
2526
- };
2527
- if (a) {
2528
- const E = i === "y" ? "height" : "width", g = s.reference[i] - s.floating[E] + x.mainAxis, v = s.reference[i] + s.reference[E] - x.mainAxis;
2529
- d < g ? d = g : d > v && (d = v);
2530
- }
2531
- if (u) {
2532
- var b, w;
2533
- const E = i === "y" ? "width" : "height", g = ["top", "left"].includes(Ce(o)), v = s.reference[f] - s.floating[E] + (g && ((b = c.offset) == null ? void 0 : b[f]) || 0) + (g ? 0 : x.crossAxis), O = s.reference[f] + s.reference[E] + (g ? 0 : ((w = c.offset) == null ? void 0 : w[f]) || 0) - (g ? x.crossAxis : 0);
2534
- p < v ? p = v : p > O && (p = O);
2535
- }
2536
- return {
2537
- [i]: d,
2538
- [f]: p
2539
- };
2540
- }
2541
- };
2542
- }, Ti = function(e) {
2543
- return e === void 0 && (e = {}), {
2544
- name: "size",
2545
- options: e,
2546
- async fn(t) {
2547
- var r, n;
2548
- const {
2549
- placement: o,
2550
- rects: s,
2551
- platform: c,
2552
- elements: l
2553
- } = t, {
2554
- apply: a = () => {
2555
- },
2556
- ...u
2557
- } = Re(e, t), m = await ln(t, u), f = Ce(o), i = Ze(o), d = Pe(o) === "y", {
2558
- width: p,
2559
- height: h
2560
- } = s.floating;
2561
- let x, b;
2562
- f === "top" || f === "bottom" ? (x = f, b = i === (await (c.isRTL == null ? void 0 : c.isRTL(l.floating)) ? "start" : "end") ? "left" : "right") : (b = f, x = i === "end" ? "top" : "bottom");
2563
- const w = h - m.top - m.bottom, E = p - m.left - m.right, g = _e(h - m[x], w), v = _e(p - m[b], E), O = !t.middlewareData.shift;
2564
- let S = g, $ = v;
2565
- if ((r = t.middlewareData.shift) != null && r.enabled.x && ($ = E), (n = t.middlewareData.shift) != null && n.enabled.y && (S = w), O && !i) {
2566
- const R = oe(m.left, 0), B = oe(m.right, 0), L = oe(m.top, 0), y = oe(m.bottom, 0);
2567
- d ? $ = p - 2 * (R !== 0 || B !== 0 ? R + B : oe(m.left, m.right)) : S = h - 2 * (L !== 0 || y !== 0 ? L + y : oe(m.top, m.bottom));
2568
- }
2569
- await a({
2570
- ...t,
2571
- availableWidth: $,
2572
- availableHeight: S
2573
- });
2574
- const C = await c.getDimensions(l.floating);
2575
- return p !== C.width || h !== C.height ? {
2576
- reset: {
2577
- rects: !0
2578
- }
2579
- } : {};
2580
- }
2581
- };
2582
- };
2583
- function At() {
2584
- return typeof window < "u";
2585
- }
2586
- function Qe(e) {
2587
- return pr(e) ? (e.nodeName || "").toLowerCase() : "#document";
2588
- }
2589
- function ie(e) {
2590
- var t;
2591
- return (e == null || (t = e.ownerDocument) == null ? void 0 : t.defaultView) || window;
2592
- }
2593
- function we(e) {
2594
- var t;
2595
- return (t = (pr(e) ? e.ownerDocument : e.document) || window.document) == null ? void 0 : t.documentElement;
2596
- }
2597
- function pr(e) {
2598
- return At() ? e instanceof Node || e instanceof ie(e).Node : !1;
2599
- }
2600
- function me(e) {
2601
- return At() ? e instanceof Element || e instanceof ie(e).Element : !1;
2602
- }
2603
- function be(e) {
2604
- return At() ? e instanceof HTMLElement || e instanceof ie(e).HTMLElement : !1;
2605
- }
2606
- function Fn(e) {
2607
- return !At() || typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof ie(e).ShadowRoot;
2608
- }
2609
- function lt(e) {
2610
- const {
2611
- overflow: t,
2612
- overflowX: r,
2613
- overflowY: n,
2614
- display: o
2615
- } = pe(e);
2616
- return /auto|scroll|overlay|hidden|clip/.test(t + n + r) && !["inline", "contents"].includes(o);
2617
- }
2618
- function _i(e) {
2619
- return ["table", "td", "th"].includes(Qe(e));
2620
- }
2621
- function Tt(e) {
2622
- return [":popover-open", ":modal"].some((t) => {
2623
- try {
2624
- return e.matches(t);
2625
- } catch {
2626
- return !1;
2627
- }
2628
- });
2629
- }
2630
- function fn(e) {
2631
- const t = dn(), r = me(e) ? pe(e) : e;
2632
- return ["transform", "translate", "scale", "rotate", "perspective"].some((n) => r[n] ? r[n] !== "none" : !1) || (r.containerType ? r.containerType !== "normal" : !1) || !t && (r.backdropFilter ? r.backdropFilter !== "none" : !1) || !t && (r.filter ? r.filter !== "none" : !1) || ["transform", "translate", "scale", "rotate", "perspective", "filter"].some((n) => (r.willChange || "").includes(n)) || ["paint", "layout", "strict", "content"].some((n) => (r.contain || "").includes(n));
2633
- }
2634
- function Ri(e) {
2635
- let t = Ie(e);
2636
- for (; be(t) && !Xe(t); ) {
2637
- if (fn(t))
2638
- return t;
2639
- if (Tt(t))
2640
- return null;
2641
- t = Ie(t);
2642
- }
2643
- return null;
2644
- }
2645
- function dn() {
2646
- return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
2647
- }
2648
- function Xe(e) {
2649
- return ["html", "body", "#document"].includes(Qe(e));
2650
- }
2651
- function pe(e) {
2652
- return ie(e).getComputedStyle(e);
2653
- }
2654
- function _t(e) {
2655
- return me(e) ? {
2656
- scrollLeft: e.scrollLeft,
2657
- scrollTop: e.scrollTop
2658
- } : {
2659
- scrollLeft: e.scrollX,
2660
- scrollTop: e.scrollY
2661
- };
2662
- }
2663
- function Ie(e) {
2664
- if (Qe(e) === "html")
2665
- return e;
2666
- const t = (
2667
- // Step into the shadow DOM of the parent of a slotted node.
2668
- e.assignedSlot || // DOM Element detected.
2669
- e.parentNode || // ShadowRoot detected.
2670
- Fn(e) && e.host || // Fallback.
2671
- we(e)
2672
- );
2673
- return Fn(t) ? t.host : t;
2674
- }
2675
- function gr(e) {
2676
- const t = Ie(e);
2677
- return Xe(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : be(t) && lt(t) ? t : gr(t);
2678
- }
2679
- function at(e, t, r) {
2680
- var n;
2681
- t === void 0 && (t = []), r === void 0 && (r = !0);
2682
- const o = gr(e), s = o === ((n = e.ownerDocument) == null ? void 0 : n.body), c = ie(o);
2683
- if (s) {
2684
- const l = qt(c);
2685
- return t.concat(c, c.visualViewport || [], lt(o) ? o : [], l && r ? at(l) : []);
2686
- }
2687
- return t.concat(o, at(o, [], r));
2688
- }
2689
- function qt(e) {
2690
- return e.parent && Object.getPrototypeOf(e.parent) ? e.frameElement : null;
2691
- }
2692
- function vr(e) {
2693
- const t = pe(e);
2694
- let r = parseFloat(t.width) || 0, n = parseFloat(t.height) || 0;
2695
- const o = be(e), s = o ? e.offsetWidth : r, c = o ? e.offsetHeight : n, l = St(r) !== s || St(n) !== c;
2696
- return l && (r = s, n = c), {
2697
- width: r,
2698
- height: n,
2699
- $: l
2700
- };
2701
- }
2702
- function mn(e) {
2703
- return me(e) ? e : e.contextElement;
2704
- }
2705
- function Ye(e) {
2706
- const t = mn(e);
2707
- if (!be(t))
2708
- return ye(1);
2709
- const r = t.getBoundingClientRect(), {
2710
- width: n,
2711
- height: o,
2712
- $: s
2713
- } = vr(t);
2714
- let c = (s ? St(r.width) : r.width) / n, l = (s ? St(r.height) : r.height) / o;
2715
- return (!c || !Number.isFinite(c)) && (c = 1), (!l || !Number.isFinite(l)) && (l = 1), {
2716
- x: c,
2717
- y: l
2718
- };
2719
- }
2720
- const Ii = /* @__PURE__ */ ye(0);
2721
- function hr(e) {
2722
- const t = ie(e);
2723
- return !dn() || !t.visualViewport ? Ii : {
2724
- x: t.visualViewport.offsetLeft,
2725
- y: t.visualViewport.offsetTop
2726
- };
2727
- }
2728
- function Fi(e, t, r) {
2729
- return t === void 0 && (t = !1), !r || t && r !== ie(e) ? !1 : t;
2730
- }
2731
- function He(e, t, r, n) {
2732
- t === void 0 && (t = !1), r === void 0 && (r = !1);
2733
- const o = e.getBoundingClientRect(), s = mn(e);
2734
- let c = ye(1);
2735
- t && (n ? me(n) && (c = Ye(n)) : c = Ye(e));
2736
- const l = Fi(s, r, n) ? hr(s) : ye(0);
2737
- let a = (o.left + l.x) / c.x, u = (o.top + l.y) / c.y, m = o.width / c.x, f = o.height / c.y;
2738
- if (s) {
2739
- const i = ie(s), d = n && me(n) ? ie(n) : n;
2740
- let p = i, h = qt(p);
2741
- for (; h && n && d !== p; ) {
2742
- const x = Ye(h), b = h.getBoundingClientRect(), w = pe(h), E = b.left + (h.clientLeft + parseFloat(w.paddingLeft)) * x.x, g = b.top + (h.clientTop + parseFloat(w.paddingTop)) * x.y;
2743
- a *= x.x, u *= x.y, m *= x.x, f *= x.y, a += E, u += g, p = ie(h), h = qt(p);
2744
- }
2745
- }
2746
- return Pt({
2747
- width: m,
2748
- height: f,
2749
- x: a,
2750
- y: u
2751
- });
2752
- }
2753
- function pn(e, t) {
2754
- const r = _t(e).scrollLeft;
2755
- return t ? t.left + r : He(we(e)).left + r;
2756
- }
2757
- function yr(e, t, r) {
2758
- r === void 0 && (r = !1);
2759
- const n = e.getBoundingClientRect(), o = n.left + t.scrollLeft - (r ? 0 : (
2760
- // RTL <body> scrollbar.
2761
- pn(e, n)
2762
- )), s = n.top + t.scrollTop;
2763
- return {
2764
- x: o,
2765
- y: s
2766
- };
2767
- }
2768
- function Li(e) {
2769
- let {
2770
- elements: t,
2771
- rect: r,
2772
- offsetParent: n,
2773
- strategy: o
2774
- } = e;
2775
- const s = o === "fixed", c = we(n), l = t ? Tt(t.floating) : !1;
2776
- if (n === c || l && s)
2777
- return r;
2778
- let a = {
2779
- scrollLeft: 0,
2780
- scrollTop: 0
2781
- }, u = ye(1);
2782
- const m = ye(0), f = be(n);
2783
- if ((f || !f && !s) && ((Qe(n) !== "body" || lt(c)) && (a = _t(n)), be(n))) {
2784
- const d = He(n);
2785
- u = Ye(n), m.x = d.x + n.clientLeft, m.y = d.y + n.clientTop;
2786
- }
2787
- const i = c && !f && !s ? yr(c, a, !0) : ye(0);
2788
- return {
2789
- width: r.width * u.x,
2790
- height: r.height * u.y,
2791
- x: r.x * u.x - a.scrollLeft * u.x + m.x + i.x,
2792
- y: r.y * u.y - a.scrollTop * u.y + m.y + i.y
2793
- };
2794
- }
2795
- function Mi(e) {
2796
- return Array.from(e.getClientRects());
2797
- }
2798
- function Ni(e) {
2799
- const t = we(e), r = _t(e), n = e.ownerDocument.body, o = oe(t.scrollWidth, t.clientWidth, n.scrollWidth, n.clientWidth), s = oe(t.scrollHeight, t.clientHeight, n.scrollHeight, n.clientHeight);
2800
- let c = -r.scrollLeft + pn(e);
2801
- const l = -r.scrollTop;
2802
- return pe(n).direction === "rtl" && (c += oe(t.clientWidth, n.clientWidth) - o), {
2803
- width: o,
2804
- height: s,
2805
- x: c,
2806
- y: l
2807
- };
2808
- }
2809
- function ki(e, t) {
2810
- const r = ie(e), n = we(e), o = r.visualViewport;
2811
- let s = n.clientWidth, c = n.clientHeight, l = 0, a = 0;
2812
- if (o) {
2813
- s = o.width, c = o.height;
2814
- const u = dn();
2815
- (!u || u && t === "fixed") && (l = o.offsetLeft, a = o.offsetTop);
2816
- }
2817
- return {
2818
- width: s,
2819
- height: c,
2820
- x: l,
2821
- y: a
2822
- };
2823
- }
2824
- function $i(e, t) {
2825
- const r = He(e, !0, t === "fixed"), n = r.top + e.clientTop, o = r.left + e.clientLeft, s = be(e) ? Ye(e) : ye(1), c = e.clientWidth * s.x, l = e.clientHeight * s.y, a = o * s.x, u = n * s.y;
2826
- return {
2827
- width: c,
2828
- height: l,
2829
- x: a,
2830
- y: u
2831
- };
2832
- }
2833
- function Ln(e, t, r) {
2834
- let n;
2835
- if (t === "viewport")
2836
- n = ki(e, r);
2837
- else if (t === "document")
2838
- n = Ni(we(e));
2839
- else if (me(t))
2840
- n = $i(t, r);
2841
- else {
2842
- const o = hr(e);
2843
- n = {
2844
- x: t.x - o.x,
2845
- y: t.y - o.y,
2846
- width: t.width,
2847
- height: t.height
2848
- };
2849
- }
2850
- return Pt(n);
2851
- }
2852
- function br(e, t) {
2853
- const r = Ie(e);
2854
- return r === t || !me(r) || Xe(r) ? !1 : pe(r).position === "fixed" || br(r, t);
2855
- }
2856
- function Vi(e, t) {
2857
- const r = t.get(e);
2858
- if (r)
2859
- return r;
2860
- let n = at(e, [], !1).filter((l) => me(l) && Qe(l) !== "body"), o = null;
2861
- const s = pe(e).position === "fixed";
2862
- let c = s ? Ie(e) : e;
2863
- for (; me(c) && !Xe(c); ) {
2864
- const l = pe(c), a = fn(c);
2865
- !a && l.position === "fixed" && (o = null), (s ? !a && !o : !a && l.position === "static" && !!o && ["absolute", "fixed"].includes(o.position) || lt(c) && !a && br(e, c)) ? n = n.filter((m) => m !== c) : o = l, c = Ie(c);
2866
- }
2867
- return t.set(e, n), n;
2868
- }
2869
- function Hi(e) {
2870
- let {
2871
- element: t,
2872
- boundary: r,
2873
- rootBoundary: n,
2874
- strategy: o
2875
- } = e;
2876
- const c = [...r === "clippingAncestors" ? Tt(t) ? [] : Vi(t, this._c) : [].concat(r), n], l = c[0], a = c.reduce((u, m) => {
2877
- const f = Ln(t, m, o);
2878
- return u.top = oe(f.top, u.top), u.right = _e(f.right, u.right), u.bottom = _e(f.bottom, u.bottom), u.left = oe(f.left, u.left), u;
2879
- }, Ln(t, l, o));
2880
- return {
2881
- width: a.right - a.left,
2882
- height: a.bottom - a.top,
2883
- x: a.left,
2884
- y: a.top
2885
- };
2886
- }
2887
- function Bi(e) {
2888
- const {
2889
- width: t,
2890
- height: r
2891
- } = vr(e);
2892
- return {
2893
- width: t,
2894
- height: r
2895
- };
2896
- }
2897
- function Wi(e, t, r) {
2898
- const n = be(t), o = we(t), s = r === "fixed", c = He(e, !0, s, t);
2899
- let l = {
2900
- scrollLeft: 0,
2901
- scrollTop: 0
2902
- };
2903
- const a = ye(0);
2904
- function u() {
2905
- a.x = pn(o);
2906
- }
2907
- if (n || !n && !s)
2908
- if ((Qe(t) !== "body" || lt(o)) && (l = _t(t)), n) {
2909
- const d = He(t, !0, s, t);
2910
- a.x = d.x + t.clientLeft, a.y = d.y + t.clientTop;
2911
- } else o && u();
2912
- s && !n && o && u();
2913
- const m = o && !n && !s ? yr(o, l) : ye(0), f = c.left + l.scrollLeft - a.x - m.x, i = c.top + l.scrollTop - a.y - m.y;
2914
- return {
2915
- x: f,
2916
- y: i,
2917
- width: c.width,
2918
- height: c.height
2919
- };
2920
- }
2921
- function kt(e) {
2922
- return pe(e).position === "static";
2923
- }
2924
- function Mn(e, t) {
2925
- if (!be(e) || pe(e).position === "fixed")
2926
- return null;
2927
- if (t)
2928
- return t(e);
2929
- let r = e.offsetParent;
2930
- return we(e) === r && (r = r.ownerDocument.body), r;
2931
- }
2932
- function wr(e, t) {
2933
- const r = ie(e);
2934
- if (Tt(e))
2935
- return r;
2936
- if (!be(e)) {
2937
- let o = Ie(e);
2938
- for (; o && !Xe(o); ) {
2939
- if (me(o) && !kt(o))
2940
- return o;
2941
- o = Ie(o);
2942
- }
2943
- return r;
2944
- }
2945
- let n = Mn(e, t);
2946
- for (; n && _i(n) && kt(n); )
2947
- n = Mn(n, t);
2948
- return n && Xe(n) && kt(n) && !fn(n) ? r : n || Ri(e) || r;
2949
- }
2950
- const zi = async function(e) {
2951
- const t = this.getOffsetParent || wr, r = this.getDimensions, n = await r(e.floating);
2952
- return {
2953
- reference: Wi(e.reference, await t(e.floating), e.strategy),
2954
- floating: {
2955
- x: 0,
2956
- y: 0,
2957
- width: n.width,
2958
- height: n.height
2959
- }
2960
- };
2961
- };
2962
- function ji(e) {
2963
- return pe(e).direction === "rtl";
2964
- }
2965
- const Ki = {
2966
- convertOffsetParentRelativeRectToViewportRelativeRect: Li,
2967
- getDocumentElement: we,
2968
- getClippingRect: Hi,
2969
- getOffsetParent: wr,
2970
- getElementRects: zi,
2971
- getClientRects: Mi,
2972
- getDimensions: Bi,
2973
- getScale: Ye,
2974
- isElement: me,
2975
- isRTL: ji
2976
- };
2977
- function xr(e, t) {
2978
- return e.x === t.x && e.y === t.y && e.width === t.width && e.height === t.height;
2979
- }
2980
- function qi(e, t) {
2981
- let r = null, n;
2982
- const o = we(e);
2983
- function s() {
2984
- var l;
2985
- clearTimeout(n), (l = r) == null || l.disconnect(), r = null;
2986
- }
2987
- function c(l, a) {
2988
- l === void 0 && (l = !1), a === void 0 && (a = 1), s();
2989
- const u = e.getBoundingClientRect(), {
2990
- left: m,
2991
- top: f,
2992
- width: i,
2993
- height: d
2994
- } = u;
2995
- if (l || t(), !i || !d)
2996
- return;
2997
- const p = ht(f), h = ht(o.clientWidth - (m + i)), x = ht(o.clientHeight - (f + d)), b = ht(m), E = {
2998
- rootMargin: -p + "px " + -h + "px " + -x + "px " + -b + "px",
2999
- threshold: oe(0, _e(1, a)) || 1
3000
- };
3001
- let g = !0;
3002
- function v(O) {
3003
- const S = O[0].intersectionRatio;
3004
- if (S !== a) {
3005
- if (!g)
3006
- return c();
3007
- S ? c(!1, S) : n = setTimeout(() => {
3008
- c(!1, 1e-7);
3009
- }, 1e3);
3010
- }
3011
- S === 1 && !xr(u, e.getBoundingClientRect()) && c(), g = !1;
3012
- }
3013
- try {
3014
- r = new IntersectionObserver(v, {
3015
- ...E,
3016
- // Handle <iframe>s
3017
- root: o.ownerDocument
3018
- });
3019
- } catch {
3020
- r = new IntersectionObserver(v, E);
3021
- }
3022
- r.observe(e);
3023
- }
3024
- return c(!0), s;
3025
- }
3026
- function Ui(e, t, r, n) {
3027
- n === void 0 && (n = {});
3028
- const {
3029
- ancestorScroll: o = !0,
3030
- ancestorResize: s = !0,
3031
- elementResize: c = typeof ResizeObserver == "function",
3032
- layoutShift: l = typeof IntersectionObserver == "function",
3033
- animationFrame: a = !1
3034
- } = n, u = mn(e), m = o || s ? [...u ? at(u) : [], ...at(t)] : [];
3035
- m.forEach((b) => {
3036
- o && b.addEventListener("scroll", r, {
3037
- passive: !0
3038
- }), s && b.addEventListener("resize", r);
3039
- });
3040
- const f = u && l ? qi(u, r) : null;
3041
- let i = -1, d = null;
3042
- c && (d = new ResizeObserver((b) => {
3043
- let [w] = b;
3044
- w && w.target === u && d && (d.unobserve(t), cancelAnimationFrame(i), i = requestAnimationFrame(() => {
3045
- var E;
3046
- (E = d) == null || E.observe(t);
3047
- })), r();
3048
- }), u && !a && d.observe(u), d.observe(t));
3049
- let p, h = a ? He(e) : null;
3050
- a && x();
3051
- function x() {
3052
- const b = He(e);
3053
- h && !xr(h, b) && r(), h = b, p = requestAnimationFrame(x);
3054
- }
3055
- return r(), () => {
3056
- var b;
3057
- m.forEach((w) => {
3058
- o && w.removeEventListener("scroll", r), s && w.removeEventListener("resize", r);
3059
- }), f == null || f(), (b = d) == null || b.disconnect(), d = null, a && cancelAnimationFrame(p);
3060
- };
3061
- }
3062
- const Yi = Di, Gi = Ci, Xi = Oi, Ji = Ti, Zi = Si, Qi = Ai, es = (e, t, r) => {
3063
- const n = /* @__PURE__ */ new Map(), o = {
3064
- platform: Ki,
3065
- ...r
3066
- }, s = {
3067
- ...o.platform,
3068
- _c: n
3069
- };
3070
- return Ei(e, t, {
3071
- ...o,
3072
- platform: s
3073
- });
3074
- };
3075
- var ts = "div";
3076
- function Nn(e = 0, t = 0, r = 0, n = 0) {
3077
- if (typeof DOMRect == "function")
3078
- return new DOMRect(e, t, r, n);
3079
- const o = {
3080
- x: e,
3081
- y: t,
3082
- width: r,
3083
- height: n,
3084
- top: t,
3085
- right: e + r,
3086
- bottom: t + n,
3087
- left: e
3088
- };
3089
- return W(_({}, o), { toJSON: () => o });
3090
- }
3091
- function ns(e) {
3092
- if (!e) return Nn();
3093
- const { x: t, y: r, width: n, height: o } = e;
3094
- return Nn(t, r, n, o);
3095
- }
3096
- function rs(e, t) {
3097
- return {
3098
- contextElement: e || void 0,
3099
- getBoundingClientRect: () => {
3100
- const n = e, o = t == null ? void 0 : t(n);
3101
- return o || !n ? ns(o) : n.getBoundingClientRect();
3102
- }
3103
- };
3104
- }
3105
- function os(e) {
3106
- return /^(?:top|bottom|left|right)(?:-(?:start|end))?$/.test(e);
3107
- }
3108
- function kn(e) {
3109
- const t = window.devicePixelRatio || 1;
3110
- return Math.round(e * t) / t;
3111
- }
3112
- function is(e, t) {
3113
- return Yi(({ placement: r }) => {
3114
- var n;
3115
- const o = ((e == null ? void 0 : e.clientHeight) || 0) / 2, s = typeof t.gutter == "number" ? t.gutter + o : (n = t.gutter) != null ? n : o;
3116
- return {
3117
- crossAxis: !!r.split("-")[1] ? void 0 : t.shift,
3118
- mainAxis: s,
3119
- alignmentAxis: t.shift
3120
- };
3121
- });
3122
- }
3123
- function ss(e) {
3124
- if (e.flip === !1) return;
3125
- const t = typeof e.flip == "string" ? e.flip.split(" ") : void 0;
3126
- return Fe(
3127
- !t || t.every(os),
3128
- process.env.NODE_ENV !== "production" && "`flip` expects a spaced-delimited list of placements"
3129
- ), Xi({
3130
- padding: e.overflowPadding,
3131
- fallbackPlacements: t
3132
- });
3133
- }
3134
- function as(e) {
3135
- if (!(!e.slide && !e.overlap))
3136
- return Gi({
3137
- mainAxis: e.slide,
3138
- crossAxis: e.overlap,
3139
- padding: e.overflowPadding,
3140
- limiter: Qi()
3141
- });
3142
- }
3143
- function cs(e) {
3144
- return Ji({
3145
- padding: e.overflowPadding,
3146
- apply({ elements: t, availableWidth: r, availableHeight: n, rects: o }) {
3147
- const s = t.floating, c = Math.round(o.reference.width);
3148
- r = Math.floor(r), n = Math.floor(n), s.style.setProperty(
3149
- "--popover-anchor-width",
3150
- `${c}px`
3151
- ), s.style.setProperty(
3152
- "--popover-available-width",
3153
- `${r}px`
3154
- ), s.style.setProperty(
3155
- "--popover-available-height",
3156
- `${n}px`
3157
- ), e.sameWidth && (s.style.width = `${c}px`), e.fitViewport && (s.style.maxWidth = `${r}px`, s.style.maxHeight = `${n}px`);
3158
- }
3159
- });
3160
- }
3161
- function us(e, t) {
3162
- if (e)
3163
- return Zi({
3164
- element: e,
3165
- padding: t.arrowPadding
3166
- });
3167
- }
3168
- var ls = ee(
3169
- function(t) {
3170
- var r = t, {
3171
- store: n,
3172
- modal: o = !1,
3173
- portal: s = !!o,
3174
- preserveTabOrder: c = !0,
3175
- autoFocusOnShow: l = !0,
3176
- wrapperProps: a,
3177
- fixed: u = !1,
3178
- flip: m = !0,
3179
- shift: f = 0,
3180
- slide: i = !0,
3181
- overlap: d = !1,
3182
- sameWidth: p = !1,
3183
- fitViewport: h = !1,
3184
- gutter: x,
3185
- arrowPadding: b = 4,
3186
- overflowPadding: w = 8,
3187
- getAnchorRect: E,
3188
- updatePosition: g
3189
- } = r, v = se(r, [
3190
- "store",
3191
- "modal",
3192
- "portal",
3193
- "preserveTabOrder",
3194
- "autoFocusOnShow",
3195
- "wrapperProps",
3196
- "fixed",
3197
- "flip",
3198
- "shift",
3199
- "slide",
3200
- "overlap",
3201
- "sameWidth",
3202
- "fitViewport",
3203
- "gutter",
3204
- "arrowPadding",
3205
- "overflowPadding",
3206
- "getAnchorRect",
3207
- "updatePosition"
3208
- ]);
3209
- const O = Ct();
3210
- n = n || O, Fe(
3211
- n,
3212
- process.env.NODE_ENV !== "production" && "Popover must receive a `store` prop or be wrapped in a PopoverProvider component."
3213
- );
3214
- const S = n.useState("arrowElement"), $ = n.useState("anchorElement"), C = n.useState("disclosureElement"), R = n.useState("popoverElement"), B = n.useState("contentElement"), L = n.useState("placement"), y = n.useState("mounted"), D = n.useState("rendered"), A = Y(null), [M, I] = le(!1), { portalRef: V, domReady: T } = zn(s, v.portalRef), k = ue(E), q = ue(g), We = !!g;
3215
- j(() => {
3216
- if (!(R != null && R.isConnected)) return;
3217
- R.style.setProperty(
3218
- "--popover-overflow-padding",
3219
- `${w}px`
3220
- );
3221
- const ae = rs($, k), te = async () => {
3222
- if (!y) return;
3223
- S || (A.current = A.current || document.createElement("div"));
3224
- const Ee = S || A.current, Le = [
3225
- is(Ee, { gutter: x, shift: f }),
3226
- ss({ flip: m, overflowPadding: w }),
3227
- as({ slide: i, overlap: d, overflowPadding: w }),
3228
- us(Ee, { arrowPadding: b }),
3229
- cs({
3230
- sameWidth: p,
3231
- fitViewport: h,
3232
- overflowPadding: w
3233
- })
3234
- ], ge = await es(ae, R, {
3235
- placement: L,
3236
- strategy: u ? "fixed" : "absolute",
3237
- middleware: Le
3238
- });
3239
- n == null || n.setState("currentPlacement", ge.placement), I(!0);
3240
- const ft = kn(ge.x), dt = kn(ge.y);
3241
- if (Object.assign(R.style, {
3242
- top: "0",
3243
- left: "0",
3244
- transform: `translate3d(${ft}px,${dt}px,0)`
3245
- }), Ee && ge.middlewareData.arrow) {
3246
- const { x: Me, y: je } = ge.middlewareData.arrow, mt = ge.placement.split("-")[0], Ke = Ee.clientWidth / 2, qe = Ee.clientHeight / 2, P = Me != null ? Me + Ke : -Ke, F = je != null ? je + qe : -qe;
3247
- R.style.setProperty(
3248
- "--popover-transform-origin",
3249
- {
3250
- top: `${P}px calc(100% + ${qe}px)`,
3251
- bottom: `${P}px ${-qe}px`,
3252
- left: `calc(100% + ${Ke}px) ${F}px`,
3253
- right: `${-Ke}px ${F}px`
3254
- }[mt]
3255
- ), Object.assign(Ee.style, {
3256
- left: Me != null ? `${Me}px` : "",
3257
- top: je != null ? `${je}px` : "",
3258
- [mt]: "100%"
3259
- });
3260
- }
3261
- }, ze = Ui(ae, R, async () => {
3262
- We ? (await q({ updatePosition: te }), I(!0)) : await te();
3263
- }, {
3264
- // JSDOM doesn't support ResizeObserver
3265
- elementResize: typeof ResizeObserver == "function"
3266
- });
3267
- return () => {
3268
- I(!1), ze();
3269
- };
3270
- }, [
3271
- n,
3272
- D,
3273
- R,
3274
- S,
3275
- $,
3276
- R,
3277
- L,
3278
- y,
3279
- T,
3280
- u,
3281
- m,
3282
- f,
3283
- i,
3284
- d,
3285
- p,
3286
- h,
3287
- x,
3288
- b,
3289
- w,
3290
- k,
3291
- We,
3292
- q
3293
- ]), j(() => {
3294
- if (!y || !T || !(R != null && R.isConnected) || !(B != null && B.isConnected)) return;
3295
- const ae = () => {
3296
- R.style.zIndex = getComputedStyle(B).zIndex;
3297
- };
3298
- ae();
3299
- let te = requestAnimationFrame(() => {
3300
- te = requestAnimationFrame(ae);
3301
- });
3302
- return () => cancelAnimationFrame(te);
3303
- }, [y, T, R, B]);
3304
- const et = u ? "fixed" : "absolute";
3305
- return v = fe(
3306
- v,
3307
- (ae) => /* @__PURE__ */ H(
3308
- "div",
3309
- W(_({}, a), {
3310
- style: _({
3311
- // https://floating-ui.com/docs/computeposition#initial-layout
3312
- position: et,
3313
- top: 0,
3314
- left: 0,
3315
- width: "max-content"
3316
- }, a == null ? void 0 : a.style),
3317
- ref: n == null ? void 0 : n.setPopoverElement,
3318
- children: ae
3319
- })
3320
- ),
3321
- [n, et, a]
3322
- ), v = fe(
3323
- v,
3324
- (ae) => /* @__PURE__ */ H(Gt, { value: n, children: ae }),
3325
- [n]
3326
- ), v = W(_({
3327
- // data-placing is not part of the public API. We're setting this here so
3328
- // we can wait for the popover to be positioned before other components
3329
- // move focus into it. For example, this attribute is observed by the
3330
- // Combobox component with the autoSelect behavior.
3331
- "data-placing": !M || void 0
3332
- }, v), {
3333
- style: _({
3334
- position: "relative"
3335
- }, v.style)
3336
- }), v = fr(W(_({
3337
- store: n,
3338
- modal: o,
3339
- portal: s,
3340
- preserveTabOrder: c,
3341
- preserveTabOrderAnchor: C || $,
3342
- autoFocusOnShow: M && l
3343
- }, v), {
3344
- portalRef: V
3345
- })), v;
3346
- }
3347
- );
3348
- dr(
3349
- K(function(t) {
3350
- const r = ls(t);
3351
- return Q(ts, r);
3352
- }),
3353
- Ct
3354
- );
3355
- var fs = "div", Er = ee(
3356
- function(t) {
3357
- var r = t, { store: n } = r, o = se(r, ["store"]);
3358
- const s = Ct();
3359
- return n = n || s, o = W(_({}, o), {
3360
- ref: Be(n == null ? void 0 : n.setAnchorElement, o.ref)
3361
- }), o;
3362
- }
3363
- );
3364
- K(function(t) {
3365
- const r = Er(t);
3366
- return Q(fs, r);
3367
- });
3368
- var Sr = "button", Or = ee(
3369
- function(t) {
3370
- const r = Y(null), n = Wr(r, Sr), [o, s] = le(
3371
- () => !!n && Vt({ tagName: n, type: t.type })
3372
- );
3373
- return U(() => {
3374
- r.current && s(Vt(r.current));
3375
- }, []), t = W(_({
3376
- role: !o && n !== "a" ? "button" : void 0
3377
- }, t), {
3378
- ref: Be(r, t.ref)
3379
- }), t = ao(t), t;
3380
- }
3381
- );
3382
- K(function(t) {
3383
- const r = Or(t);
3384
- return Q(Sr, r);
3385
- });
3386
- var ds = "button", ms = Symbol("disclosure"), Pr = ee(
3387
- function(t) {
3388
- var r = t, { store: n, toggleOnClick: o = !0 } = r, s = se(r, ["store", "toggleOnClick"]);
3389
- const c = Zt();
3390
- n = n || c, Fe(
3391
- n,
3392
- process.env.NODE_ENV !== "production" && "Disclosure must receive a `store` prop or be wrapped in a DisclosureProvider component."
3393
- );
3394
- const l = Y(null), [a, u] = le(!1), m = n.useState("disclosureElement"), f = n.useState("open");
3395
- U(() => {
3396
- let w = m === l.current;
3397
- m != null && m.isConnected || (n == null || n.setDisclosureElement(l.current), w = !0), u(f && w);
3398
- }, [m, n, f]);
3399
- const i = s.onClick, d = rt(o), [p, h] = zr(s, ms, !0), x = ue((w) => {
3400
- i == null || i(w), !w.defaultPrevented && (p || d(w) && (n == null || n.setDisclosureElement(w.currentTarget), n == null || n.toggle()));
3401
- }), b = n.useState("contentElement");
3402
- return s = W(_(_({
3403
- "aria-expanded": a,
3404
- "aria-controls": b == null ? void 0 : b.id
3405
- }, h), s), {
3406
- ref: Be(l, s.ref),
3407
- onClick: x
3408
- }), s = Or(s), s;
3409
- }
3410
- );
3411
- K(function(t) {
3412
- const r = Pr(t);
3413
- return Q(ds, r);
3414
- });
3415
- var ps = "button", Dr = ee(
3416
- function(t) {
3417
- var r = t, { store: n } = r, o = se(r, ["store"]);
3418
- const s = Dt();
3419
- n = n || s, Fe(
3420
- n,
3421
- process.env.NODE_ENV !== "production" && "DialogDisclosure must receive a `store` prop or be wrapped in a DialogProvider component."
3422
- );
3423
- const c = n.useState("contentElement");
3424
- return o = _({
3425
- "aria-haspopup": jr(c, "dialog")
3426
- }, o), o = Pr(_({ store: n }, o)), o;
3427
- }
3428
- );
3429
- K(function(t) {
3430
- const r = Dr(t);
3431
- return Q(ps, r);
3432
- });
3433
- var gs = "button", vs = ee(function(t) {
3434
- var r = t, { store: n } = r, o = se(r, ["store"]);
3435
- const s = Ct();
3436
- n = n || s, Fe(
3437
- n,
3438
- process.env.NODE_ENV !== "production" && "PopoverDisclosure must receive a `store` prop or be wrapped in a PopoverProvider component."
3439
- );
3440
- const c = o.onClick, l = ue((a) => {
3441
- n == null || n.setAnchorElement(a.currentTarget), c == null || c(a);
3442
- });
3443
- return o = fe(
3444
- o,
3445
- (a) => /* @__PURE__ */ H(Gt, { value: n, children: a }),
3446
- [n]
3447
- ), o = W(_({}, o), {
3448
- onClick: l
3449
- }), o = Er(_({ store: n }, o)), o = Dr(_({ store: n }, o)), o;
3450
- });
3451
- K(function(t) {
3452
- const r = vs(t);
3453
- return Q(gs, r);
3454
- });
3455
- var hs = "div", Oe = "";
3456
- function $t() {
3457
- Oe = "";
3458
- }
3459
- function ys(e) {
3460
- const t = e.target;
3461
- return t && Jt(t) ? !1 : e.key === " " && Oe.length ? !0 : e.key.length === 1 && !e.ctrlKey && !e.altKey && !e.metaKey && /^[\p{Letter}\p{Number}]$/u.test(e.key);
3462
- }
3463
- function bs(e, t) {
3464
- if (Ne(e)) return !0;
3465
- const r = e.target;
3466
- return r ? t.some((o) => o.element === r) : !1;
3467
- }
3468
- function ws(e) {
3469
- return e.filter((t) => !t.disabled);
3470
- }
3471
- function wt(e, t) {
3472
- var r;
3473
- const n = ((r = e.element) == null ? void 0 : r.textContent) || e.children || // The composite item object itself doesn't include a value property, but
3474
- // other components like Select do. Since CompositeTypeahead is a generic
3475
- // component that can be used with those as well, we also consider the value
3476
- // property as a fallback for the typeahead text content.
3477
- "value" in e && e.value;
3478
- return n ? qr(n).trim().toLowerCase().startsWith(t.toLowerCase()) : !1;
3479
- }
3480
- function xs(e, t, r) {
3481
- if (!r) return e;
3482
- const n = e.find((o) => o.id === r);
3483
- return !n || !wt(n, t) || Oe !== t && wt(n, Oe) ? e : (Oe = t, co(
3484
- e.filter((o) => wt(o, Oe)),
3485
- r
3486
- ).filter((o) => o.id !== r));
3487
- }
3488
- var Es = ee(function(t) {
3489
- var r = t, { store: n, typeahead: o = !0 } = r, s = se(r, ["store", "typeahead"]);
3490
- const c = Kr();
3491
- n = n || c, Fe(
3492
- n,
3493
- process.env.NODE_ENV !== "production" && "CompositeTypeahead must be a Composite component"
3494
- );
3495
- const l = s.onKeyDownCapture, a = Y(0), u = ue((m) => {
3496
- if (l == null || l(m), m.defaultPrevented || !o || !n) return;
3497
- if (!ys(m))
3498
- return $t();
3499
- const { renderedItems: f, items: i, activeId: d, id: p } = n.getState();
3500
- let h = ws(
3501
- i.length > f.length ? i : f
3502
- );
3503
- const x = G(m.currentTarget), b = `[data-offscreen-id="${p}"]`, w = x.querySelectorAll(b);
3504
- for (const v of w) {
3505
- const O = v.ariaDisabled === "true" || "disabled" in v && !!v.disabled;
3506
- h.push({ id: v.id, element: v, disabled: O });
3507
- }
3508
- if (w.length && (h = $n(h, (v) => v.element)), !bs(m, h)) return $t();
3509
- m.preventDefault(), window.clearTimeout(a.current), a.current = window.setTimeout(() => {
3510
- Oe = "";
3511
- }, 500);
3512
- const E = m.key.toLowerCase();
3513
- Oe += E, h = xs(h, E, d);
3514
- const g = h.find((v) => wt(v, Oe));
3515
- g ? n.move(g.id) : $t();
3516
- });
3517
- return s = W(_({}, s), {
3518
- onKeyDownCapture: u
3519
- }), Bn(s);
3520
- });
3521
- K(function(t) {
3522
- const r = Es(t);
3523
- return Q(hs, r);
3524
- });
3525
- export {
3526
- Ms as C,
3527
- zt as R,
3528
- ls as a,
3529
- dr as b,
3530
- Vs as c,
3531
- As as d,
3532
- Ls as e,
3533
- _s as f,
3534
- Co as g,
3535
- Es as h,
3536
- Qn as i,
3537
- vs as j,
3538
- Ts as k,
3539
- Er as l,
3540
- Fs as m,
3541
- Rs as n,
3542
- ks as o,
3543
- $s as p,
3544
- Is as q,
3545
- Ns as r,
3546
- Cs as t,
3547
- Hs as u
3548
- };