highsoft-ui 1.0.49 → 1.0.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Footer/index.js +441 -202
- package/dist/components/PrefPanel/index.js +1075 -2145
- package/dist/highsoft-ui.css +1 -1
- package/dist/index-DAJ9ybTO.js +1126 -0
- package/package.json +3 -3
- package/dist/Check-Cm4roSEj.js +0 -23
|
@@ -1,22 +1,21 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { z as
|
|
3
|
-
import * as
|
|
4
|
-
import {
|
|
5
|
-
import { C as
|
|
6
|
-
import { _ as
|
|
7
|
-
import { c as
|
|
8
|
-
import { Button as
|
|
9
|
-
import * as
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
return /* @__PURE__ */ C("svg", Fe({
|
|
1
|
+
import { jsx as g, jsxs as K, Fragment as ee } from "react/jsx-runtime";
|
|
2
|
+
import { z as qe, b as Ge } from "../../utils-CzQFvGG2.js";
|
|
3
|
+
import * as w from "react";
|
|
4
|
+
import { useLayoutEffect as Ke } from "react";
|
|
5
|
+
import { u as kt, P as ft, c as ne, a as yt, b as Ue, d as Ze, e as Je, f as st, g as oe, h as Qe, i as tn, R as en, j as nn, k as on, F as rn, D as sn, C as cn } from "../../index-DAJ9ybTO.js";
|
|
6
|
+
import { _ as At } from "../../extends-hS2Bh-Yp.js";
|
|
7
|
+
import { c as an } from "../../clsx-OuTLNxxd.js";
|
|
8
|
+
import { Button as ln } from "../Button/index.js";
|
|
9
|
+
import * as fn from "react-dom";
|
|
10
|
+
var un = function(e) {
|
|
11
|
+
return /* @__PURE__ */ g("svg", At({
|
|
13
12
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14
13
|
width: 24,
|
|
15
14
|
height: 24,
|
|
16
15
|
fill: "none",
|
|
17
16
|
viewBox: "0 0 24 24"
|
|
18
|
-
},
|
|
19
|
-
children: /* @__PURE__ */
|
|
17
|
+
}, e, {
|
|
18
|
+
children: /* @__PURE__ */ g("path", {
|
|
20
19
|
stroke: "currentColor",
|
|
21
20
|
strokeLinecap: "round",
|
|
22
21
|
strokeLinejoin: "round",
|
|
@@ -24,15 +23,15 @@ var rr = function(t) {
|
|
|
24
23
|
d: "M15 17v4H9v-4m-3.8 0h13.6c1.1201 0 1.6802 0 2.108-.218a2 2 0 0 0 .874-.874C22 15.4802 22 14.9201 22 13.8V6.2c0-1.1201 0-1.6802-.218-2.108a2 2 0 0 0-.874-.874C20.4802 3 19.9201 3 18.8 3H5.2c-1.1201 0-1.6802 0-2.108.218a2 2 0 0 0-.874.874C2 4.5198 2 5.08 2 6.2v7.6c0 1.1201 0 1.6802.218 2.108.1917.3763.4977.6823.874.874C3.5198 17 4.08 17 5.2 17"
|
|
25
24
|
})
|
|
26
25
|
}));
|
|
27
|
-
},
|
|
28
|
-
return /* @__PURE__ */
|
|
26
|
+
}, dn = function(e) {
|
|
27
|
+
return /* @__PURE__ */ g("svg", At({
|
|
29
28
|
xmlns: "http://www.w3.org/2000/svg",
|
|
30
29
|
width: 24,
|
|
31
30
|
height: 24,
|
|
32
31
|
fill: "none",
|
|
33
32
|
viewBox: "0 0 24 24"
|
|
34
|
-
},
|
|
35
|
-
children: /* @__PURE__ */
|
|
33
|
+
}, e, {
|
|
34
|
+
children: /* @__PURE__ */ g("path", {
|
|
36
35
|
stroke: "currentColor",
|
|
37
36
|
strokeLinecap: "round",
|
|
38
37
|
strokeLinejoin: "round",
|
|
@@ -40,15 +39,15 @@ var rr = function(t) {
|
|
|
40
39
|
d: "M21.9548 12.9564c-1.3769 2.4153-3.9757 4.0437-6.9548 4.0437-4.4183 0-8-3.5817-8-8 0-2.9794 1.6287-5.5783 4.0443-6.9552C5.9698 2.5261 2 6.7994 2 11.9998c0 5.5229 4.4772 10 10 10 5.2002 0 9.4733-3.9693 9.9548-9.0434"
|
|
41
40
|
})
|
|
42
41
|
}));
|
|
43
|
-
},
|
|
44
|
-
return /* @__PURE__ */
|
|
42
|
+
}, pn = function(e) {
|
|
43
|
+
return /* @__PURE__ */ g("svg", At({
|
|
45
44
|
xmlns: "http://www.w3.org/2000/svg",
|
|
46
45
|
width: 24,
|
|
47
46
|
height: 24,
|
|
48
47
|
fill: "none",
|
|
49
48
|
viewBox: "0 0 24 24"
|
|
50
|
-
},
|
|
51
|
-
children: /* @__PURE__ */
|
|
49
|
+
}, e, {
|
|
50
|
+
children: /* @__PURE__ */ g("path", {
|
|
52
51
|
stroke: "currentColor",
|
|
53
52
|
strokeLinecap: "round",
|
|
54
53
|
strokeLinejoin: "round",
|
|
@@ -56,15 +55,15 @@ var rr = function(t) {
|
|
|
56
55
|
d: "M3 8h12m0 0c0 1.6569 1.3431 3 3 3s3-1.3431 3-3-1.3431-3-3-3-3 1.3431-3 3m-6 8h12M9 16c0 1.6569-1.3431 3-3 3s-3-1.3431-3-3 1.3431-3 3-3 3 1.3431 3 3"
|
|
57
56
|
})
|
|
58
57
|
}));
|
|
59
|
-
},
|
|
60
|
-
return /* @__PURE__ */
|
|
58
|
+
}, hn = function(e) {
|
|
59
|
+
return /* @__PURE__ */ g("svg", At({
|
|
61
60
|
xmlns: "http://www.w3.org/2000/svg",
|
|
62
61
|
width: 24,
|
|
63
62
|
height: 24,
|
|
64
63
|
fill: "none",
|
|
65
64
|
viewBox: "0 0 24 24"
|
|
66
|
-
},
|
|
67
|
-
children: /* @__PURE__ */
|
|
65
|
+
}, e, {
|
|
66
|
+
children: /* @__PURE__ */ g("path", {
|
|
68
67
|
stroke: "currentColor",
|
|
69
68
|
strokeLinecap: "round",
|
|
70
69
|
strokeLinejoin: "round",
|
|
@@ -73,1466 +72,397 @@ var rr = function(t) {
|
|
|
73
72
|
})
|
|
74
73
|
}));
|
|
75
74
|
};
|
|
76
|
-
function
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
e != null && (e.current = t);
|
|
80
|
-
}
|
|
81
|
-
function Ht(...e) {
|
|
82
|
-
return (t) => {
|
|
83
|
-
let n = !1;
|
|
84
|
-
const r = e.map((o) => {
|
|
85
|
-
const i = vt(o, t);
|
|
86
|
-
return !n && typeof i == "function" && (n = !0), i;
|
|
87
|
-
});
|
|
88
|
-
if (n)
|
|
89
|
-
return () => {
|
|
90
|
-
for (let o = 0; o < r.length; o++) {
|
|
91
|
-
const i = r[o];
|
|
92
|
-
typeof i == "function" ? i() : vt(e[o], null);
|
|
93
|
-
}
|
|
94
|
-
};
|
|
95
|
-
};
|
|
96
|
-
}
|
|
97
|
-
function re(...e) {
|
|
98
|
-
return a.useCallback(Ht(...e), e);
|
|
99
|
-
}
|
|
100
|
-
// @__NO_SIDE_EFFECTS__
|
|
101
|
-
function Vt(e) {
|
|
102
|
-
const t = /* @__PURE__ */ cr(e), n = a.forwardRef((r, o) => {
|
|
103
|
-
const { children: i, ...s } = r, c = a.Children.toArray(i), u = c.find(lr);
|
|
104
|
-
if (u) {
|
|
105
|
-
const l = u.props.children, f = c.map((d) => d === u ? a.Children.count(l) > 1 ? a.Children.only(null) : a.isValidElement(l) ? l.props.children : null : d);
|
|
106
|
-
return /* @__PURE__ */ C(t, { ...s, ref: o, children: a.isValidElement(l) ? a.cloneElement(l, void 0, f) : null });
|
|
107
|
-
}
|
|
108
|
-
return /* @__PURE__ */ C(t, { ...s, ref: o, children: i });
|
|
109
|
-
});
|
|
110
|
-
return n.displayName = `${e}.Slot`, n;
|
|
111
|
-
}
|
|
112
|
-
// @__NO_SIDE_EFFECTS__
|
|
113
|
-
function cr(e) {
|
|
114
|
-
const t = a.forwardRef((n, r) => {
|
|
115
|
-
const { children: o, ...i } = n;
|
|
116
|
-
if (a.isValidElement(o)) {
|
|
117
|
-
const s = fr(o), c = ur(i, o.props);
|
|
118
|
-
return o.type !== a.Fragment && (c.ref = r ? Ht(r, s) : s), a.cloneElement(o, c);
|
|
119
|
-
}
|
|
120
|
-
return a.Children.count(o) > 1 ? a.Children.only(null) : null;
|
|
121
|
-
});
|
|
122
|
-
return t.displayName = `${e}.SlotClone`, t;
|
|
123
|
-
}
|
|
124
|
-
var ar = Symbol("radix.slottable");
|
|
125
|
-
function lr(e) {
|
|
126
|
-
return a.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === ar;
|
|
127
|
-
}
|
|
128
|
-
function ur(e, t) {
|
|
129
|
-
const n = { ...t };
|
|
130
|
-
for (const r in t) {
|
|
131
|
-
const o = e[r], i = t[r];
|
|
132
|
-
/^on[A-Z]/.test(r) ? o && i ? n[r] = (...c) => {
|
|
133
|
-
const u = i(...c);
|
|
134
|
-
return o(...c), u;
|
|
135
|
-
} : o && (n[r] = o) : r === "style" ? n[r] = { ...o, ...i } : r === "className" && (n[r] = [o, i].filter(Boolean).join(" "));
|
|
136
|
-
}
|
|
137
|
-
return { ...e, ...n };
|
|
138
|
-
}
|
|
139
|
-
function fr(e) {
|
|
140
|
-
let t = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning;
|
|
141
|
-
return n ? e.ref : (t = Object.getOwnPropertyDescriptor(e, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
142
|
-
}
|
|
143
|
-
var dr = [
|
|
144
|
-
"a",
|
|
145
|
-
"button",
|
|
146
|
-
"div",
|
|
147
|
-
"form",
|
|
148
|
-
"h2",
|
|
149
|
-
"h3",
|
|
150
|
-
"img",
|
|
151
|
-
"input",
|
|
152
|
-
"label",
|
|
153
|
-
"li",
|
|
154
|
-
"nav",
|
|
155
|
-
"ol",
|
|
156
|
-
"p",
|
|
157
|
-
"select",
|
|
158
|
-
"span",
|
|
159
|
-
"svg",
|
|
160
|
-
"ul"
|
|
161
|
-
], G = dr.reduce((e, t) => {
|
|
162
|
-
const n = /* @__PURE__ */ Vt(`Primitive.${t}`), r = a.forwardRef((o, i) => {
|
|
163
|
-
const { asChild: s, ...c } = o, u = s ? n : t;
|
|
164
|
-
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ C(u, { ...c, ref: i });
|
|
165
|
-
});
|
|
166
|
-
return r.displayName = `Primitive.${t}`, { ...e, [t]: r };
|
|
167
|
-
}, {});
|
|
168
|
-
function pr(e, t) {
|
|
169
|
-
e && $t.flushSync(() => e.dispatchEvent(t));
|
|
170
|
-
}
|
|
171
|
-
function zt(e, t = []) {
|
|
172
|
-
let n = [];
|
|
173
|
-
function r(i, s) {
|
|
174
|
-
const c = a.createContext(s), u = n.length;
|
|
175
|
-
n = [...n, s];
|
|
176
|
-
const l = (d) => {
|
|
177
|
-
const { scope: m, children: h, ...v } = d, p = m?.[e]?.[u] || c, g = a.useMemo(() => v, Object.values(v));
|
|
178
|
-
return /* @__PURE__ */ C(p.Provider, { value: g, children: h });
|
|
179
|
-
};
|
|
180
|
-
l.displayName = i + "Provider";
|
|
181
|
-
function f(d, m) {
|
|
182
|
-
const h = m?.[e]?.[u] || c, v = a.useContext(h);
|
|
183
|
-
if (v) return v;
|
|
184
|
-
if (s !== void 0) return s;
|
|
185
|
-
throw new Error(`\`${d}\` must be used within \`${i}\``);
|
|
186
|
-
}
|
|
187
|
-
return [l, f];
|
|
188
|
-
}
|
|
189
|
-
const o = () => {
|
|
190
|
-
const i = n.map((s) => a.createContext(s));
|
|
191
|
-
return function(c) {
|
|
192
|
-
const u = c?.[e] || i;
|
|
193
|
-
return a.useMemo(
|
|
194
|
-
() => ({ [`__scope${e}`]: { ...c, [e]: u } }),
|
|
195
|
-
[c, u]
|
|
196
|
-
);
|
|
197
|
-
};
|
|
198
|
-
};
|
|
199
|
-
return o.scopeName = e, [r, hr(o, ...t)];
|
|
200
|
-
}
|
|
201
|
-
function hr(...e) {
|
|
202
|
-
const t = e[0];
|
|
203
|
-
if (e.length === 1) return t;
|
|
204
|
-
const n = () => {
|
|
205
|
-
const r = e.map((o) => ({
|
|
206
|
-
useScope: o(),
|
|
207
|
-
scopeName: o.scopeName
|
|
208
|
-
}));
|
|
209
|
-
return function(i) {
|
|
210
|
-
const s = r.reduce((c, { useScope: u, scopeName: l }) => {
|
|
211
|
-
const d = u(i)[`__scope${l}`];
|
|
212
|
-
return { ...c, ...d };
|
|
213
|
-
}, {});
|
|
214
|
-
return a.useMemo(() => ({ [`__scope${t.scopeName}`]: s }), [s]);
|
|
215
|
-
};
|
|
216
|
-
};
|
|
217
|
-
return n.scopeName = t.scopeName, n;
|
|
218
|
-
}
|
|
219
|
-
function J(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
|
|
220
|
-
return function(o) {
|
|
221
|
-
if (e?.(o), n === !1 || !o.defaultPrevented)
|
|
222
|
-
return t?.(o);
|
|
223
|
-
};
|
|
224
|
-
}
|
|
225
|
-
var ee = globalThis?.document ? a.useLayoutEffect : () => {
|
|
226
|
-
}, mr = a[" useInsertionEffect ".trim().toString()] || ee;
|
|
227
|
-
function vr({
|
|
228
|
-
prop: e,
|
|
229
|
-
defaultProp: t,
|
|
230
|
-
onChange: n = () => {
|
|
231
|
-
},
|
|
232
|
-
caller: r
|
|
233
|
-
}) {
|
|
234
|
-
const [o, i, s] = gr({
|
|
235
|
-
defaultProp: t,
|
|
236
|
-
onChange: n
|
|
237
|
-
}), c = e !== void 0, u = c ? e : o;
|
|
238
|
-
{
|
|
239
|
-
const f = a.useRef(e !== void 0);
|
|
240
|
-
a.useEffect(() => {
|
|
241
|
-
const d = f.current;
|
|
242
|
-
d !== c && console.warn(
|
|
243
|
-
`${r} is changing from ${d ? "controlled" : "uncontrolled"} to ${c ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
|
|
244
|
-
), f.current = c;
|
|
245
|
-
}, [c, r]);
|
|
246
|
-
}
|
|
247
|
-
const l = a.useCallback(
|
|
248
|
-
(f) => {
|
|
249
|
-
if (c) {
|
|
250
|
-
const d = yr(f) ? f(e) : f;
|
|
251
|
-
d !== e && s.current?.(d);
|
|
252
|
-
} else
|
|
253
|
-
i(f);
|
|
254
|
-
},
|
|
255
|
-
[c, e, i, s]
|
|
256
|
-
);
|
|
257
|
-
return [u, l];
|
|
258
|
-
}
|
|
259
|
-
function gr({
|
|
260
|
-
defaultProp: e,
|
|
261
|
-
onChange: t
|
|
262
|
-
}) {
|
|
263
|
-
const [n, r] = a.useState(e), o = a.useRef(n), i = a.useRef(t);
|
|
264
|
-
return mr(() => {
|
|
265
|
-
i.current = t;
|
|
266
|
-
}, [t]), a.useEffect(() => {
|
|
267
|
-
o.current !== n && (i.current?.(n), o.current = n);
|
|
268
|
-
}, [n, o]), [n, r, i];
|
|
269
|
-
}
|
|
270
|
-
function yr(e) {
|
|
271
|
-
return typeof e == "function";
|
|
272
|
-
}
|
|
273
|
-
function wr(e, t) {
|
|
274
|
-
return a.useReducer((n, r) => t[n][r] ?? n, e);
|
|
275
|
-
}
|
|
276
|
-
var rt = (e) => {
|
|
277
|
-
const { present: t, children: n } = e, r = br(t), o = typeof n == "function" ? n({ present: r.isPresent }) : a.Children.only(n), i = re(r.ref, xr(o));
|
|
278
|
-
return typeof n == "function" || r.isPresent ? a.cloneElement(o, { ref: i }) : null;
|
|
279
|
-
};
|
|
280
|
-
rt.displayName = "Presence";
|
|
281
|
-
function br(e) {
|
|
282
|
-
const [t, n] = a.useState(), r = a.useRef(null), o = a.useRef(e), i = a.useRef("none"), s = e ? "mounted" : "unmounted", [c, u] = wr(s, {
|
|
283
|
-
mounted: {
|
|
284
|
-
UNMOUNT: "unmounted",
|
|
285
|
-
ANIMATION_OUT: "unmountSuspended"
|
|
286
|
-
},
|
|
287
|
-
unmountSuspended: {
|
|
288
|
-
MOUNT: "mounted",
|
|
289
|
-
ANIMATION_END: "unmounted"
|
|
290
|
-
},
|
|
291
|
-
unmounted: {
|
|
292
|
-
MOUNT: "mounted"
|
|
293
|
-
}
|
|
294
|
-
});
|
|
295
|
-
return a.useEffect(() => {
|
|
296
|
-
const l = Ce(r.current);
|
|
297
|
-
i.current = c === "mounted" ? l : "none";
|
|
298
|
-
}, [c]), ee(() => {
|
|
299
|
-
const l = r.current, f = o.current;
|
|
300
|
-
if (f !== e) {
|
|
301
|
-
const m = i.current, h = Ce(l);
|
|
302
|
-
e ? u("MOUNT") : h === "none" || l?.display === "none" ? u("UNMOUNT") : u(f && m !== h ? "ANIMATION_OUT" : "UNMOUNT"), o.current = e;
|
|
303
|
-
}
|
|
304
|
-
}, [e, u]), ee(() => {
|
|
75
|
+
function mn(t) {
|
|
76
|
+
const [e, n] = w.useState(void 0);
|
|
77
|
+
return kt(() => {
|
|
305
78
|
if (t) {
|
|
306
|
-
|
|
307
|
-
const
|
|
308
|
-
|
|
309
|
-
if (h.target === t && p && (u("ANIMATION_END"), !o.current)) {
|
|
310
|
-
const g = t.style.animationFillMode;
|
|
311
|
-
t.style.animationFillMode = "forwards", l = f.setTimeout(() => {
|
|
312
|
-
t.style.animationFillMode === "forwards" && (t.style.animationFillMode = g);
|
|
313
|
-
});
|
|
314
|
-
}
|
|
315
|
-
}, m = (h) => {
|
|
316
|
-
h.target === t && (i.current = Ce(r.current));
|
|
317
|
-
};
|
|
318
|
-
return t.addEventListener("animationstart", m), t.addEventListener("animationcancel", d), t.addEventListener("animationend", d), () => {
|
|
319
|
-
f.clearTimeout(l), t.removeEventListener("animationstart", m), t.removeEventListener("animationcancel", d), t.removeEventListener("animationend", d);
|
|
320
|
-
};
|
|
321
|
-
} else
|
|
322
|
-
u("ANIMATION_END");
|
|
323
|
-
}, [t, u]), {
|
|
324
|
-
isPresent: ["mounted", "unmountSuspended"].includes(c),
|
|
325
|
-
ref: a.useCallback((l) => {
|
|
326
|
-
r.current = l ? getComputedStyle(l) : null, n(l);
|
|
327
|
-
}, [])
|
|
328
|
-
};
|
|
329
|
-
}
|
|
330
|
-
function Ce(e) {
|
|
331
|
-
return e?.animationName || "none";
|
|
332
|
-
}
|
|
333
|
-
function xr(e) {
|
|
334
|
-
let t = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning;
|
|
335
|
-
return n ? e.ref : (t = Object.getOwnPropertyDescriptor(e, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
336
|
-
}
|
|
337
|
-
var Er = a[" useId ".trim().toString()] || (() => {
|
|
338
|
-
}), Cr = 0;
|
|
339
|
-
function Pr(e) {
|
|
340
|
-
const [t, n] = a.useState(Er());
|
|
341
|
-
return ee(() => {
|
|
342
|
-
n((r) => r ?? String(Cr++));
|
|
343
|
-
}, [e]), e || (t ? `radix-${t}` : "");
|
|
344
|
-
}
|
|
345
|
-
function fe(e) {
|
|
346
|
-
const t = a.useRef(e);
|
|
347
|
-
return a.useEffect(() => {
|
|
348
|
-
t.current = e;
|
|
349
|
-
}), a.useMemo(() => (...n) => t.current?.(...n), []);
|
|
350
|
-
}
|
|
351
|
-
function Sr(e, t = globalThis?.document) {
|
|
352
|
-
const n = fe(e);
|
|
353
|
-
a.useEffect(() => {
|
|
354
|
-
const r = (o) => {
|
|
355
|
-
o.key === "Escape" && n(o);
|
|
356
|
-
};
|
|
357
|
-
return t.addEventListener("keydown", r, { capture: !0 }), () => t.removeEventListener("keydown", r, { capture: !0 });
|
|
358
|
-
}, [n, t]);
|
|
359
|
-
}
|
|
360
|
-
var Ar = "DismissableLayer", Qe = "dismissableLayer.update", Rr = "dismissableLayer.pointerDownOutside", Or = "dismissableLayer.focusOutside", gt, Ut = a.createContext({
|
|
361
|
-
layers: /* @__PURE__ */ new Set(),
|
|
362
|
-
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
363
|
-
branches: /* @__PURE__ */ new Set()
|
|
364
|
-
}), jt = a.forwardRef(
|
|
365
|
-
(e, t) => {
|
|
366
|
-
const {
|
|
367
|
-
disableOutsidePointerEvents: n = !1,
|
|
368
|
-
onEscapeKeyDown: r,
|
|
369
|
-
onPointerDownOutside: o,
|
|
370
|
-
onFocusOutside: i,
|
|
371
|
-
onInteractOutside: s,
|
|
372
|
-
onDismiss: c,
|
|
373
|
-
...u
|
|
374
|
-
} = e, l = a.useContext(Ut), [f, d] = a.useState(null), m = f?.ownerDocument ?? globalThis?.document, [, h] = a.useState({}), v = re(t, (P) => d(P)), p = Array.from(l.layers), [g] = [...l.layersWithOutsidePointerEventsDisabled].slice(-1), y = p.indexOf(g), w = f ? p.indexOf(f) : -1, x = l.layersWithOutsidePointerEventsDisabled.size > 0, b = w >= y, E = Mr((P) => {
|
|
375
|
-
const R = P.target, T = [...l.branches].some((O) => O.contains(R));
|
|
376
|
-
!b || T || (o?.(P), s?.(P), P.defaultPrevented || c?.());
|
|
377
|
-
}, m), S = kr((P) => {
|
|
378
|
-
const R = P.target;
|
|
379
|
-
[...l.branches].some((O) => O.contains(R)) || (i?.(P), s?.(P), P.defaultPrevented || c?.());
|
|
380
|
-
}, m);
|
|
381
|
-
return Sr((P) => {
|
|
382
|
-
w === l.layers.size - 1 && (r?.(P), !P.defaultPrevented && c && (P.preventDefault(), c()));
|
|
383
|
-
}, m), a.useEffect(() => {
|
|
384
|
-
if (f)
|
|
385
|
-
return n && (l.layersWithOutsidePointerEventsDisabled.size === 0 && (gt = m.body.style.pointerEvents, m.body.style.pointerEvents = "none"), l.layersWithOutsidePointerEventsDisabled.add(f)), l.layers.add(f), yt(), () => {
|
|
386
|
-
n && l.layersWithOutsidePointerEventsDisabled.size === 1 && (m.body.style.pointerEvents = gt);
|
|
387
|
-
};
|
|
388
|
-
}, [f, m, n, l]), a.useEffect(() => () => {
|
|
389
|
-
f && (l.layers.delete(f), l.layersWithOutsidePointerEventsDisabled.delete(f), yt());
|
|
390
|
-
}, [f, l]), a.useEffect(() => {
|
|
391
|
-
const P = () => h({});
|
|
392
|
-
return document.addEventListener(Qe, P), () => document.removeEventListener(Qe, P);
|
|
393
|
-
}, []), /* @__PURE__ */ C(
|
|
394
|
-
G.div,
|
|
395
|
-
{
|
|
396
|
-
...u,
|
|
397
|
-
ref: v,
|
|
398
|
-
style: {
|
|
399
|
-
pointerEvents: x ? b ? "auto" : "none" : void 0,
|
|
400
|
-
...e.style
|
|
401
|
-
},
|
|
402
|
-
onFocusCapture: J(e.onFocusCapture, S.onFocusCapture),
|
|
403
|
-
onBlurCapture: J(e.onBlurCapture, S.onBlurCapture),
|
|
404
|
-
onPointerDownCapture: J(
|
|
405
|
-
e.onPointerDownCapture,
|
|
406
|
-
E.onPointerDownCapture
|
|
407
|
-
)
|
|
408
|
-
}
|
|
409
|
-
);
|
|
410
|
-
}
|
|
411
|
-
);
|
|
412
|
-
jt.displayName = Ar;
|
|
413
|
-
var Nr = "DismissableLayerBranch", Tr = a.forwardRef((e, t) => {
|
|
414
|
-
const n = a.useContext(Ut), r = a.useRef(null), o = re(t, r);
|
|
415
|
-
return a.useEffect(() => {
|
|
416
|
-
const i = r.current;
|
|
417
|
-
if (i)
|
|
418
|
-
return n.branches.add(i), () => {
|
|
419
|
-
n.branches.delete(i);
|
|
420
|
-
};
|
|
421
|
-
}, [n.branches]), /* @__PURE__ */ C(G.div, { ...e, ref: o });
|
|
422
|
-
});
|
|
423
|
-
Tr.displayName = Nr;
|
|
424
|
-
function Mr(e, t = globalThis?.document) {
|
|
425
|
-
const n = fe(e), r = a.useRef(!1), o = a.useRef(() => {
|
|
426
|
-
});
|
|
427
|
-
return a.useEffect(() => {
|
|
428
|
-
const i = (c) => {
|
|
429
|
-
if (c.target && !r.current) {
|
|
430
|
-
let u = function() {
|
|
431
|
-
Yt(
|
|
432
|
-
Rr,
|
|
433
|
-
n,
|
|
434
|
-
l,
|
|
435
|
-
{ discrete: !0 }
|
|
436
|
-
);
|
|
437
|
-
};
|
|
438
|
-
const l = { originalEvent: c };
|
|
439
|
-
c.pointerType === "touch" ? (t.removeEventListener("click", o.current), o.current = u, t.addEventListener("click", o.current, { once: !0 })) : u();
|
|
440
|
-
} else
|
|
441
|
-
t.removeEventListener("click", o.current);
|
|
442
|
-
r.current = !1;
|
|
443
|
-
}, s = window.setTimeout(() => {
|
|
444
|
-
t.addEventListener("pointerdown", i);
|
|
445
|
-
}, 0);
|
|
446
|
-
return () => {
|
|
447
|
-
window.clearTimeout(s), t.removeEventListener("pointerdown", i), t.removeEventListener("click", o.current);
|
|
448
|
-
};
|
|
449
|
-
}, [t, n]), {
|
|
450
|
-
// ensures we check React component tree (not just DOM tree)
|
|
451
|
-
onPointerDownCapture: () => r.current = !0
|
|
452
|
-
};
|
|
453
|
-
}
|
|
454
|
-
function kr(e, t = globalThis?.document) {
|
|
455
|
-
const n = fe(e), r = a.useRef(!1);
|
|
456
|
-
return a.useEffect(() => {
|
|
457
|
-
const o = (i) => {
|
|
458
|
-
i.target && !r.current && Yt(Or, n, { originalEvent: i }, {
|
|
459
|
-
discrete: !1
|
|
460
|
-
});
|
|
461
|
-
};
|
|
462
|
-
return t.addEventListener("focusin", o), () => t.removeEventListener("focusin", o);
|
|
463
|
-
}, [t, n]), {
|
|
464
|
-
onFocusCapture: () => r.current = !0,
|
|
465
|
-
onBlurCapture: () => r.current = !1
|
|
466
|
-
};
|
|
467
|
-
}
|
|
468
|
-
function yt() {
|
|
469
|
-
const e = new CustomEvent(Qe);
|
|
470
|
-
document.dispatchEvent(e);
|
|
471
|
-
}
|
|
472
|
-
function Yt(e, t, n, { discrete: r }) {
|
|
473
|
-
const o = n.originalEvent.target, i = new CustomEvent(e, { bubbles: !1, cancelable: !0, detail: n });
|
|
474
|
-
t && o.addEventListener(e, t, { once: !0 }), r ? pr(o, i) : o.dispatchEvent(i);
|
|
475
|
-
}
|
|
476
|
-
var Ve = "focusScope.autoFocusOnMount", ze = "focusScope.autoFocusOnUnmount", wt = { bubbles: !1, cancelable: !0 }, Lr = "FocusScope", Kt = a.forwardRef((e, t) => {
|
|
477
|
-
const {
|
|
478
|
-
loop: n = !1,
|
|
479
|
-
trapped: r = !1,
|
|
480
|
-
onMountAutoFocus: o,
|
|
481
|
-
onUnmountAutoFocus: i,
|
|
482
|
-
...s
|
|
483
|
-
} = e, [c, u] = a.useState(null), l = fe(o), f = fe(i), d = a.useRef(null), m = re(t, (p) => u(p)), h = a.useRef({
|
|
484
|
-
paused: !1,
|
|
485
|
-
pause() {
|
|
486
|
-
this.paused = !0;
|
|
487
|
-
},
|
|
488
|
-
resume() {
|
|
489
|
-
this.paused = !1;
|
|
490
|
-
}
|
|
491
|
-
}).current;
|
|
492
|
-
a.useEffect(() => {
|
|
493
|
-
if (r) {
|
|
494
|
-
let p = function(x) {
|
|
495
|
-
if (h.paused || !c) return;
|
|
496
|
-
const b = x.target;
|
|
497
|
-
c.contains(b) ? d.current = b : q(d.current, { select: !0 });
|
|
498
|
-
}, g = function(x) {
|
|
499
|
-
if (h.paused || !c) return;
|
|
500
|
-
const b = x.relatedTarget;
|
|
501
|
-
b !== null && (c.contains(b) || q(d.current, { select: !0 }));
|
|
502
|
-
}, y = function(x) {
|
|
503
|
-
if (document.activeElement === document.body)
|
|
504
|
-
for (const E of x)
|
|
505
|
-
E.removedNodes.length > 0 && q(c);
|
|
506
|
-
};
|
|
507
|
-
document.addEventListener("focusin", p), document.addEventListener("focusout", g);
|
|
508
|
-
const w = new MutationObserver(y);
|
|
509
|
-
return c && w.observe(c, { childList: !0, subtree: !0 }), () => {
|
|
510
|
-
document.removeEventListener("focusin", p), document.removeEventListener("focusout", g), w.disconnect();
|
|
511
|
-
};
|
|
512
|
-
}
|
|
513
|
-
}, [r, c, h.paused]), a.useEffect(() => {
|
|
514
|
-
if (c) {
|
|
515
|
-
xt.add(h);
|
|
516
|
-
const p = document.activeElement;
|
|
517
|
-
if (!c.contains(p)) {
|
|
518
|
-
const y = new CustomEvent(Ve, wt);
|
|
519
|
-
c.addEventListener(Ve, l), c.dispatchEvent(y), y.defaultPrevented || (Dr(Br(Xt(c)), { select: !0 }), document.activeElement === p && q(c));
|
|
520
|
-
}
|
|
521
|
-
return () => {
|
|
522
|
-
c.removeEventListener(Ve, l), setTimeout(() => {
|
|
523
|
-
const y = new CustomEvent(ze, wt);
|
|
524
|
-
c.addEventListener(ze, f), c.dispatchEvent(y), y.defaultPrevented || q(p ?? document.body, { select: !0 }), c.removeEventListener(ze, f), xt.remove(h);
|
|
525
|
-
}, 0);
|
|
526
|
-
};
|
|
527
|
-
}
|
|
528
|
-
}, [c, l, f, h]);
|
|
529
|
-
const v = a.useCallback(
|
|
530
|
-
(p) => {
|
|
531
|
-
if (!n && !r || h.paused) return;
|
|
532
|
-
const g = p.key === "Tab" && !p.altKey && !p.ctrlKey && !p.metaKey, y = document.activeElement;
|
|
533
|
-
if (g && y) {
|
|
534
|
-
const w = p.currentTarget, [x, b] = _r(w);
|
|
535
|
-
x && b ? !p.shiftKey && y === b ? (p.preventDefault(), n && q(x, { select: !0 })) : p.shiftKey && y === x && (p.preventDefault(), n && q(b, { select: !0 })) : y === w && p.preventDefault();
|
|
536
|
-
}
|
|
537
|
-
},
|
|
538
|
-
[n, r, h.paused]
|
|
539
|
-
);
|
|
540
|
-
return /* @__PURE__ */ C(G.div, { tabIndex: -1, ...s, ref: m, onKeyDown: v });
|
|
541
|
-
});
|
|
542
|
-
Kt.displayName = Lr;
|
|
543
|
-
function Dr(e, { select: t = !1 } = {}) {
|
|
544
|
-
const n = document.activeElement;
|
|
545
|
-
for (const r of e)
|
|
546
|
-
if (q(r, { select: t }), document.activeElement !== n) return;
|
|
547
|
-
}
|
|
548
|
-
function _r(e) {
|
|
549
|
-
const t = Xt(e), n = bt(t, e), r = bt(t.reverse(), e);
|
|
550
|
-
return [n, r];
|
|
551
|
-
}
|
|
552
|
-
function Xt(e) {
|
|
553
|
-
const t = [], n = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, {
|
|
554
|
-
acceptNode: (r) => {
|
|
555
|
-
const o = r.tagName === "INPUT" && r.type === "hidden";
|
|
556
|
-
return r.disabled || r.hidden || o ? NodeFilter.FILTER_SKIP : r.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
|
|
557
|
-
}
|
|
558
|
-
});
|
|
559
|
-
for (; n.nextNode(); ) t.push(n.currentNode);
|
|
560
|
-
return t;
|
|
561
|
-
}
|
|
562
|
-
function bt(e, t) {
|
|
563
|
-
for (const n of e)
|
|
564
|
-
if (!Fr(n, { upTo: t })) return n;
|
|
565
|
-
}
|
|
566
|
-
function Fr(e, { upTo: t }) {
|
|
567
|
-
if (getComputedStyle(e).visibility === "hidden") return !0;
|
|
568
|
-
for (; e; ) {
|
|
569
|
-
if (t !== void 0 && e === t) return !1;
|
|
570
|
-
if (getComputedStyle(e).display === "none") return !0;
|
|
571
|
-
e = e.parentElement;
|
|
572
|
-
}
|
|
573
|
-
return !1;
|
|
574
|
-
}
|
|
575
|
-
function Ir(e) {
|
|
576
|
-
return e instanceof HTMLInputElement && "select" in e;
|
|
577
|
-
}
|
|
578
|
-
function q(e, { select: t = !1 } = {}) {
|
|
579
|
-
if (e && e.focus) {
|
|
580
|
-
const n = document.activeElement;
|
|
581
|
-
e.focus({ preventScroll: !0 }), e !== n && Ir(e) && t && e.select();
|
|
582
|
-
}
|
|
583
|
-
}
|
|
584
|
-
var xt = Wr();
|
|
585
|
-
function Wr() {
|
|
586
|
-
let e = [];
|
|
587
|
-
return {
|
|
588
|
-
add(t) {
|
|
589
|
-
const n = e[0];
|
|
590
|
-
t !== n && n?.pause(), e = Et(e, t), e.unshift(t);
|
|
591
|
-
},
|
|
592
|
-
remove(t) {
|
|
593
|
-
e = Et(e, t), e[0]?.resume();
|
|
594
|
-
}
|
|
595
|
-
};
|
|
596
|
-
}
|
|
597
|
-
function Et(e, t) {
|
|
598
|
-
const n = [...e], r = n.indexOf(t);
|
|
599
|
-
return r !== -1 && n.splice(r, 1), n;
|
|
600
|
-
}
|
|
601
|
-
function Br(e) {
|
|
602
|
-
return e.filter((t) => t.tagName !== "A");
|
|
603
|
-
}
|
|
604
|
-
var $r = "Portal", Zt = a.forwardRef((e, t) => {
|
|
605
|
-
const { container: n, ...r } = e, [o, i] = a.useState(!1);
|
|
606
|
-
ee(() => i(!0), []);
|
|
607
|
-
const s = n || o && globalThis?.document?.body;
|
|
608
|
-
return s ? nr.createPortal(/* @__PURE__ */ C(G.div, { ...r, ref: t }), s) : null;
|
|
609
|
-
});
|
|
610
|
-
Zt.displayName = $r;
|
|
611
|
-
var Ue = 0;
|
|
612
|
-
function Hr() {
|
|
613
|
-
a.useEffect(() => {
|
|
614
|
-
const e = document.querySelectorAll("[data-radix-focus-guard]");
|
|
615
|
-
return document.body.insertAdjacentElement("afterbegin", e[0] ?? Ct()), document.body.insertAdjacentElement("beforeend", e[1] ?? Ct()), Ue++, () => {
|
|
616
|
-
Ue === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach((t) => t.remove()), Ue--;
|
|
617
|
-
};
|
|
618
|
-
}, []);
|
|
619
|
-
}
|
|
620
|
-
function Ct() {
|
|
621
|
-
const e = document.createElement("span");
|
|
622
|
-
return e.setAttribute("data-radix-focus-guard", ""), e.tabIndex = 0, e.style.outline = "none", e.style.opacity = "0", e.style.position = "fixed", e.style.pointerEvents = "none", e;
|
|
623
|
-
}
|
|
624
|
-
var z = function() {
|
|
625
|
-
return z = Object.assign || function(t) {
|
|
626
|
-
for (var n, r = 1, o = arguments.length; r < o; r++) {
|
|
627
|
-
n = arguments[r];
|
|
628
|
-
for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (t[i] = n[i]);
|
|
629
|
-
}
|
|
630
|
-
return t;
|
|
631
|
-
}, z.apply(this, arguments);
|
|
632
|
-
};
|
|
633
|
-
function Gt(e, t) {
|
|
634
|
-
var n = {};
|
|
635
|
-
for (var r in e) Object.prototype.hasOwnProperty.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
|
|
636
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function")
|
|
637
|
-
for (var o = 0, r = Object.getOwnPropertySymbols(e); o < r.length; o++)
|
|
638
|
-
t.indexOf(r[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[o]) && (n[r[o]] = e[r[o]]);
|
|
639
|
-
return n;
|
|
640
|
-
}
|
|
641
|
-
function Vr(e, t, n) {
|
|
642
|
-
if (n || arguments.length === 2) for (var r = 0, o = t.length, i; r < o; r++)
|
|
643
|
-
(i || !(r in t)) && (i || (i = Array.prototype.slice.call(t, 0, r)), i[r] = t[r]);
|
|
644
|
-
return e.concat(i || Array.prototype.slice.call(t));
|
|
645
|
-
}
|
|
646
|
-
var Ne = "right-scroll-bar-position", Te = "width-before-scroll-bar", zr = "with-scroll-bars-hidden", Ur = "--removed-body-scroll-bar-size";
|
|
647
|
-
function je(e, t) {
|
|
648
|
-
return typeof e == "function" ? e(t) : e && (e.current = t), e;
|
|
649
|
-
}
|
|
650
|
-
function jr(e, t) {
|
|
651
|
-
var n = qn(function() {
|
|
652
|
-
return {
|
|
653
|
-
// value
|
|
654
|
-
value: e,
|
|
655
|
-
// last callback
|
|
656
|
-
callback: t,
|
|
657
|
-
// "memoized" public interface
|
|
658
|
-
facade: {
|
|
659
|
-
get current() {
|
|
660
|
-
return n.value;
|
|
661
|
-
},
|
|
662
|
-
set current(r) {
|
|
663
|
-
var o = n.value;
|
|
664
|
-
o !== r && (n.value = r, n.callback(r, o));
|
|
665
|
-
}
|
|
666
|
-
}
|
|
667
|
-
};
|
|
668
|
-
})[0];
|
|
669
|
-
return n.callback = t, n.facade;
|
|
670
|
-
}
|
|
671
|
-
var Yr = typeof window < "u" ? a.useLayoutEffect : a.useEffect, Pt = /* @__PURE__ */ new WeakMap();
|
|
672
|
-
function Kr(e, t) {
|
|
673
|
-
var n = jr(null, function(r) {
|
|
674
|
-
return e.forEach(function(o) {
|
|
675
|
-
return je(o, r);
|
|
676
|
-
});
|
|
677
|
-
});
|
|
678
|
-
return Yr(function() {
|
|
679
|
-
var r = Pt.get(n);
|
|
680
|
-
if (r) {
|
|
681
|
-
var o = new Set(r), i = new Set(e), s = n.current;
|
|
682
|
-
o.forEach(function(c) {
|
|
683
|
-
i.has(c) || je(c, null);
|
|
684
|
-
}), i.forEach(function(c) {
|
|
685
|
-
o.has(c) || je(c, s);
|
|
686
|
-
});
|
|
687
|
-
}
|
|
688
|
-
Pt.set(n, e);
|
|
689
|
-
}, [e]), n;
|
|
690
|
-
}
|
|
691
|
-
function Xr(e) {
|
|
692
|
-
return e;
|
|
693
|
-
}
|
|
694
|
-
function Zr(e, t) {
|
|
695
|
-
t === void 0 && (t = Xr);
|
|
696
|
-
var n = [], r = !1, o = {
|
|
697
|
-
read: function() {
|
|
698
|
-
if (r)
|
|
699
|
-
throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");
|
|
700
|
-
return n.length ? n[n.length - 1] : e;
|
|
701
|
-
},
|
|
702
|
-
useMedium: function(i) {
|
|
703
|
-
var s = t(i, r);
|
|
704
|
-
return n.push(s), function() {
|
|
705
|
-
n = n.filter(function(c) {
|
|
706
|
-
return c !== s;
|
|
707
|
-
});
|
|
708
|
-
};
|
|
709
|
-
},
|
|
710
|
-
assignSyncMedium: function(i) {
|
|
711
|
-
for (r = !0; n.length; ) {
|
|
712
|
-
var s = n;
|
|
713
|
-
n = [], s.forEach(i);
|
|
714
|
-
}
|
|
715
|
-
n = {
|
|
716
|
-
push: function(c) {
|
|
717
|
-
return i(c);
|
|
718
|
-
},
|
|
719
|
-
filter: function() {
|
|
720
|
-
return n;
|
|
721
|
-
}
|
|
722
|
-
};
|
|
723
|
-
},
|
|
724
|
-
assignMedium: function(i) {
|
|
725
|
-
r = !0;
|
|
726
|
-
var s = [];
|
|
727
|
-
if (n.length) {
|
|
728
|
-
var c = n;
|
|
729
|
-
n = [], c.forEach(i), s = n;
|
|
730
|
-
}
|
|
731
|
-
var u = function() {
|
|
732
|
-
var f = s;
|
|
733
|
-
s = [], f.forEach(i);
|
|
734
|
-
}, l = function() {
|
|
735
|
-
return Promise.resolve().then(u);
|
|
736
|
-
};
|
|
737
|
-
l(), n = {
|
|
738
|
-
push: function(f) {
|
|
739
|
-
s.push(f), l();
|
|
740
|
-
},
|
|
741
|
-
filter: function(f) {
|
|
742
|
-
return s = s.filter(f), n;
|
|
743
|
-
}
|
|
744
|
-
};
|
|
745
|
-
}
|
|
746
|
-
};
|
|
747
|
-
return o;
|
|
748
|
-
}
|
|
749
|
-
function Gr(e) {
|
|
750
|
-
e === void 0 && (e = {});
|
|
751
|
-
var t = Zr(null);
|
|
752
|
-
return t.options = z({ async: !0, ssr: !1 }, e), t;
|
|
753
|
-
}
|
|
754
|
-
var qt = function(e) {
|
|
755
|
-
var t = e.sideCar, n = Gt(e, ["sideCar"]);
|
|
756
|
-
if (!t)
|
|
757
|
-
throw new Error("Sidecar: please provide `sideCar` property to import the right car");
|
|
758
|
-
var r = t.read();
|
|
759
|
-
if (!r)
|
|
760
|
-
throw new Error("Sidecar medium not found");
|
|
761
|
-
return a.createElement(r, z({}, n));
|
|
762
|
-
};
|
|
763
|
-
qt.isSideCarExport = !0;
|
|
764
|
-
function qr(e, t) {
|
|
765
|
-
return e.useMedium(t), qt;
|
|
766
|
-
}
|
|
767
|
-
var Qt = Gr(), Ye = function() {
|
|
768
|
-
}, Ie = a.forwardRef(function(e, t) {
|
|
769
|
-
var n = a.useRef(null), r = a.useState({
|
|
770
|
-
onScrollCapture: Ye,
|
|
771
|
-
onWheelCapture: Ye,
|
|
772
|
-
onTouchMoveCapture: Ye
|
|
773
|
-
}), o = r[0], i = r[1], s = e.forwardProps, c = e.children, u = e.className, l = e.removeScrollBar, f = e.enabled, d = e.shards, m = e.sideCar, h = e.noRelative, v = e.noIsolation, p = e.inert, g = e.allowPinchZoom, y = e.as, w = y === void 0 ? "div" : y, x = e.gapMode, b = Gt(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noRelative", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), E = m, S = Kr([n, t]), P = z(z({}, b), o);
|
|
774
|
-
return a.createElement(
|
|
775
|
-
a.Fragment,
|
|
776
|
-
null,
|
|
777
|
-
f && a.createElement(E, { sideCar: Qt, removeScrollBar: l, shards: d, noRelative: h, noIsolation: v, inert: p, setCallbacks: i, allowPinchZoom: !!g, lockRef: n, gapMode: x }),
|
|
778
|
-
s ? a.cloneElement(a.Children.only(c), z(z({}, P), { ref: S })) : a.createElement(w, z({}, P, { className: u, ref: S }), c)
|
|
779
|
-
);
|
|
780
|
-
});
|
|
781
|
-
Ie.defaultProps = {
|
|
782
|
-
enabled: !0,
|
|
783
|
-
removeScrollBar: !0,
|
|
784
|
-
inert: !1
|
|
785
|
-
};
|
|
786
|
-
Ie.classNames = {
|
|
787
|
-
fullWidth: Te,
|
|
788
|
-
zeroRight: Ne
|
|
789
|
-
};
|
|
790
|
-
var Qr = function() {
|
|
791
|
-
if (typeof __webpack_nonce__ < "u")
|
|
792
|
-
return __webpack_nonce__;
|
|
793
|
-
};
|
|
794
|
-
function Jr() {
|
|
795
|
-
if (!document)
|
|
796
|
-
return null;
|
|
797
|
-
var e = document.createElement("style");
|
|
798
|
-
e.type = "text/css";
|
|
799
|
-
var t = Qr();
|
|
800
|
-
return t && e.setAttribute("nonce", t), e;
|
|
801
|
-
}
|
|
802
|
-
function eo(e, t) {
|
|
803
|
-
e.styleSheet ? e.styleSheet.cssText = t : e.appendChild(document.createTextNode(t));
|
|
804
|
-
}
|
|
805
|
-
function to(e) {
|
|
806
|
-
var t = document.head || document.getElementsByTagName("head")[0];
|
|
807
|
-
t.appendChild(e);
|
|
808
|
-
}
|
|
809
|
-
var no = function() {
|
|
810
|
-
var e = 0, t = null;
|
|
811
|
-
return {
|
|
812
|
-
add: function(n) {
|
|
813
|
-
e == 0 && (t = Jr()) && (eo(t, n), to(t)), e++;
|
|
814
|
-
},
|
|
815
|
-
remove: function() {
|
|
816
|
-
e--, !e && t && (t.parentNode && t.parentNode.removeChild(t), t = null);
|
|
817
|
-
}
|
|
818
|
-
};
|
|
819
|
-
}, ro = function() {
|
|
820
|
-
var e = no();
|
|
821
|
-
return function(t, n) {
|
|
822
|
-
a.useEffect(function() {
|
|
823
|
-
return e.add(t), function() {
|
|
824
|
-
e.remove();
|
|
825
|
-
};
|
|
826
|
-
}, [t && n]);
|
|
827
|
-
};
|
|
828
|
-
}, Jt = function() {
|
|
829
|
-
var e = ro(), t = function(n) {
|
|
830
|
-
var r = n.styles, o = n.dynamic;
|
|
831
|
-
return e(r, o), null;
|
|
832
|
-
};
|
|
833
|
-
return t;
|
|
834
|
-
}, oo = {
|
|
835
|
-
left: 0,
|
|
836
|
-
top: 0,
|
|
837
|
-
right: 0,
|
|
838
|
-
gap: 0
|
|
839
|
-
}, Ke = function(e) {
|
|
840
|
-
return parseInt(e || "", 10) || 0;
|
|
841
|
-
}, io = function(e) {
|
|
842
|
-
var t = window.getComputedStyle(document.body), n = t[e === "padding" ? "paddingLeft" : "marginLeft"], r = t[e === "padding" ? "paddingTop" : "marginTop"], o = t[e === "padding" ? "paddingRight" : "marginRight"];
|
|
843
|
-
return [Ke(n), Ke(r), Ke(o)];
|
|
844
|
-
}, so = function(e) {
|
|
845
|
-
if (e === void 0 && (e = "margin"), typeof window > "u")
|
|
846
|
-
return oo;
|
|
847
|
-
var t = io(e), n = document.documentElement.clientWidth, r = window.innerWidth;
|
|
848
|
-
return {
|
|
849
|
-
left: t[0],
|
|
850
|
-
top: t[1],
|
|
851
|
-
right: t[2],
|
|
852
|
-
gap: Math.max(0, r - n + t[2] - t[0])
|
|
853
|
-
};
|
|
854
|
-
}, co = Jt(), le = "data-scroll-locked", ao = function(e, t, n, r) {
|
|
855
|
-
var o = e.left, i = e.top, s = e.right, c = e.gap;
|
|
856
|
-
return n === void 0 && (n = "margin"), `
|
|
857
|
-
.`.concat(zr, ` {
|
|
858
|
-
overflow: hidden `).concat(r, `;
|
|
859
|
-
padding-right: `).concat(c, "px ").concat(r, `;
|
|
860
|
-
}
|
|
861
|
-
body[`).concat(le, `] {
|
|
862
|
-
overflow: hidden `).concat(r, `;
|
|
863
|
-
overscroll-behavior: contain;
|
|
864
|
-
`).concat([
|
|
865
|
-
t && "position: relative ".concat(r, ";"),
|
|
866
|
-
n === "margin" && `
|
|
867
|
-
padding-left: `.concat(o, `px;
|
|
868
|
-
padding-top: `).concat(i, `px;
|
|
869
|
-
padding-right: `).concat(s, `px;
|
|
870
|
-
margin-left:0;
|
|
871
|
-
margin-top:0;
|
|
872
|
-
margin-right: `).concat(c, "px ").concat(r, `;
|
|
873
|
-
`),
|
|
874
|
-
n === "padding" && "padding-right: ".concat(c, "px ").concat(r, ";")
|
|
875
|
-
].filter(Boolean).join(""), `
|
|
876
|
-
}
|
|
877
|
-
|
|
878
|
-
.`).concat(Ne, ` {
|
|
879
|
-
right: `).concat(c, "px ").concat(r, `;
|
|
880
|
-
}
|
|
881
|
-
|
|
882
|
-
.`).concat(Te, ` {
|
|
883
|
-
margin-right: `).concat(c, "px ").concat(r, `;
|
|
884
|
-
}
|
|
885
|
-
|
|
886
|
-
.`).concat(Ne, " .").concat(Ne, ` {
|
|
887
|
-
right: 0 `).concat(r, `;
|
|
888
|
-
}
|
|
889
|
-
|
|
890
|
-
.`).concat(Te, " .").concat(Te, ` {
|
|
891
|
-
margin-right: 0 `).concat(r, `;
|
|
892
|
-
}
|
|
893
|
-
|
|
894
|
-
body[`).concat(le, `] {
|
|
895
|
-
`).concat(Ur, ": ").concat(c, `px;
|
|
896
|
-
}
|
|
897
|
-
`);
|
|
898
|
-
}, St = function() {
|
|
899
|
-
var e = parseInt(document.body.getAttribute(le) || "0", 10);
|
|
900
|
-
return isFinite(e) ? e : 0;
|
|
901
|
-
}, lo = function() {
|
|
902
|
-
a.useEffect(function() {
|
|
903
|
-
return document.body.setAttribute(le, (St() + 1).toString()), function() {
|
|
904
|
-
var e = St() - 1;
|
|
905
|
-
e <= 0 ? document.body.removeAttribute(le) : document.body.setAttribute(le, e.toString());
|
|
906
|
-
};
|
|
907
|
-
}, []);
|
|
908
|
-
}, uo = function(e) {
|
|
909
|
-
var t = e.noRelative, n = e.noImportant, r = e.gapMode, o = r === void 0 ? "margin" : r;
|
|
910
|
-
lo();
|
|
911
|
-
var i = a.useMemo(function() {
|
|
912
|
-
return so(o);
|
|
913
|
-
}, [o]);
|
|
914
|
-
return a.createElement(co, { styles: ao(i, !t, o, n ? "" : "!important") });
|
|
915
|
-
}, Je = !1;
|
|
916
|
-
if (typeof window < "u")
|
|
917
|
-
try {
|
|
918
|
-
var Pe = Object.defineProperty({}, "passive", {
|
|
919
|
-
get: function() {
|
|
920
|
-
return Je = !0, !0;
|
|
921
|
-
}
|
|
922
|
-
});
|
|
923
|
-
window.addEventListener("test", Pe, Pe), window.removeEventListener("test", Pe, Pe);
|
|
924
|
-
} catch {
|
|
925
|
-
Je = !1;
|
|
926
|
-
}
|
|
927
|
-
var se = Je ? { passive: !1 } : !1, fo = function(e) {
|
|
928
|
-
return e.tagName === "TEXTAREA";
|
|
929
|
-
}, en = function(e, t) {
|
|
930
|
-
if (!(e instanceof Element))
|
|
931
|
-
return !1;
|
|
932
|
-
var n = window.getComputedStyle(e);
|
|
933
|
-
return (
|
|
934
|
-
// not-not-scrollable
|
|
935
|
-
n[t] !== "hidden" && // contains scroll inside self
|
|
936
|
-
!(n.overflowY === n.overflowX && !fo(e) && n[t] === "visible")
|
|
937
|
-
);
|
|
938
|
-
}, po = function(e) {
|
|
939
|
-
return en(e, "overflowY");
|
|
940
|
-
}, ho = function(e) {
|
|
941
|
-
return en(e, "overflowX");
|
|
942
|
-
}, At = function(e, t) {
|
|
943
|
-
var n = t.ownerDocument, r = t;
|
|
944
|
-
do {
|
|
945
|
-
typeof ShadowRoot < "u" && r instanceof ShadowRoot && (r = r.host);
|
|
946
|
-
var o = tn(e, r);
|
|
947
|
-
if (o) {
|
|
948
|
-
var i = nn(e, r), s = i[1], c = i[2];
|
|
949
|
-
if (s > c)
|
|
950
|
-
return !0;
|
|
951
|
-
}
|
|
952
|
-
r = r.parentNode;
|
|
953
|
-
} while (r && r !== n.body);
|
|
954
|
-
return !1;
|
|
955
|
-
}, mo = function(e) {
|
|
956
|
-
var t = e.scrollTop, n = e.scrollHeight, r = e.clientHeight;
|
|
957
|
-
return [
|
|
958
|
-
t,
|
|
959
|
-
n,
|
|
960
|
-
r
|
|
961
|
-
];
|
|
962
|
-
}, vo = function(e) {
|
|
963
|
-
var t = e.scrollLeft, n = e.scrollWidth, r = e.clientWidth;
|
|
964
|
-
return [
|
|
965
|
-
t,
|
|
966
|
-
n,
|
|
967
|
-
r
|
|
968
|
-
];
|
|
969
|
-
}, tn = function(e, t) {
|
|
970
|
-
return e === "v" ? po(t) : ho(t);
|
|
971
|
-
}, nn = function(e, t) {
|
|
972
|
-
return e === "v" ? mo(t) : vo(t);
|
|
973
|
-
}, go = function(e, t) {
|
|
974
|
-
return e === "h" && t === "rtl" ? -1 : 1;
|
|
975
|
-
}, yo = function(e, t, n, r, o) {
|
|
976
|
-
var i = go(e, window.getComputedStyle(t).direction), s = i * r, c = n.target, u = t.contains(c), l = !1, f = s > 0, d = 0, m = 0;
|
|
977
|
-
do {
|
|
978
|
-
if (!c)
|
|
979
|
-
break;
|
|
980
|
-
var h = nn(e, c), v = h[0], p = h[1], g = h[2], y = p - g - i * v;
|
|
981
|
-
(v || y) && tn(e, c) && (d += y, m += v);
|
|
982
|
-
var w = c.parentNode;
|
|
983
|
-
c = w && w.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? w.host : w;
|
|
984
|
-
} while (
|
|
985
|
-
// portaled content
|
|
986
|
-
!u && c !== document.body || // self content
|
|
987
|
-
u && (t.contains(c) || t === c)
|
|
988
|
-
);
|
|
989
|
-
return (f && Math.abs(d) < 1 || !f && Math.abs(m) < 1) && (l = !0), l;
|
|
990
|
-
}, Se = function(e) {
|
|
991
|
-
return "changedTouches" in e ? [e.changedTouches[0].clientX, e.changedTouches[0].clientY] : [0, 0];
|
|
992
|
-
}, Rt = function(e) {
|
|
993
|
-
return [e.deltaX, e.deltaY];
|
|
994
|
-
}, Ot = function(e) {
|
|
995
|
-
return e && "current" in e ? e.current : e;
|
|
996
|
-
}, wo = function(e, t) {
|
|
997
|
-
return e[0] === t[0] && e[1] === t[1];
|
|
998
|
-
}, bo = function(e) {
|
|
999
|
-
return `
|
|
1000
|
-
.block-interactivity-`.concat(e, ` {pointer-events: none;}
|
|
1001
|
-
.allow-interactivity-`).concat(e, ` {pointer-events: all;}
|
|
1002
|
-
`);
|
|
1003
|
-
}, xo = 0, ce = [];
|
|
1004
|
-
function Eo(e) {
|
|
1005
|
-
var t = a.useRef([]), n = a.useRef([0, 0]), r = a.useRef(), o = a.useState(xo++)[0], i = a.useState(Jt)[0], s = a.useRef(e);
|
|
1006
|
-
a.useEffect(function() {
|
|
1007
|
-
s.current = e;
|
|
1008
|
-
}, [e]), a.useEffect(function() {
|
|
1009
|
-
if (e.inert) {
|
|
1010
|
-
document.body.classList.add("block-interactivity-".concat(o));
|
|
1011
|
-
var p = Vr([e.lockRef.current], (e.shards || []).map(Ot), !0).filter(Boolean);
|
|
1012
|
-
return p.forEach(function(g) {
|
|
1013
|
-
return g.classList.add("allow-interactivity-".concat(o));
|
|
1014
|
-
}), function() {
|
|
1015
|
-
document.body.classList.remove("block-interactivity-".concat(o)), p.forEach(function(g) {
|
|
1016
|
-
return g.classList.remove("allow-interactivity-".concat(o));
|
|
1017
|
-
});
|
|
1018
|
-
};
|
|
1019
|
-
}
|
|
1020
|
-
}, [e.inert, e.lockRef.current, e.shards]);
|
|
1021
|
-
var c = a.useCallback(function(p, g) {
|
|
1022
|
-
if ("touches" in p && p.touches.length === 2 || p.type === "wheel" && p.ctrlKey)
|
|
1023
|
-
return !s.current.allowPinchZoom;
|
|
1024
|
-
var y = Se(p), w = n.current, x = "deltaX" in p ? p.deltaX : w[0] - y[0], b = "deltaY" in p ? p.deltaY : w[1] - y[1], E, S = p.target, P = Math.abs(x) > Math.abs(b) ? "h" : "v";
|
|
1025
|
-
if ("touches" in p && P === "h" && S.type === "range")
|
|
1026
|
-
return !1;
|
|
1027
|
-
var R = At(P, S);
|
|
1028
|
-
if (!R)
|
|
1029
|
-
return !0;
|
|
1030
|
-
if (R ? E = P : (E = P === "v" ? "h" : "v", R = At(P, S)), !R)
|
|
1031
|
-
return !1;
|
|
1032
|
-
if (!r.current && "changedTouches" in p && (x || b) && (r.current = E), !E)
|
|
1033
|
-
return !0;
|
|
1034
|
-
var T = r.current || E;
|
|
1035
|
-
return yo(T, g, p, T === "h" ? x : b);
|
|
1036
|
-
}, []), u = a.useCallback(function(p) {
|
|
1037
|
-
var g = p;
|
|
1038
|
-
if (!(!ce.length || ce[ce.length - 1] !== i)) {
|
|
1039
|
-
var y = "deltaY" in g ? Rt(g) : Se(g), w = t.current.filter(function(E) {
|
|
1040
|
-
return E.name === g.type && (E.target === g.target || g.target === E.shadowParent) && wo(E.delta, y);
|
|
1041
|
-
})[0];
|
|
1042
|
-
if (w && w.should) {
|
|
1043
|
-
g.cancelable && g.preventDefault();
|
|
1044
|
-
return;
|
|
1045
|
-
}
|
|
1046
|
-
if (!w) {
|
|
1047
|
-
var x = (s.current.shards || []).map(Ot).filter(Boolean).filter(function(E) {
|
|
1048
|
-
return E.contains(g.target);
|
|
1049
|
-
}), b = x.length > 0 ? c(g, x[0]) : !s.current.noIsolation;
|
|
1050
|
-
b && g.cancelable && g.preventDefault();
|
|
1051
|
-
}
|
|
1052
|
-
}
|
|
1053
|
-
}, []), l = a.useCallback(function(p, g, y, w) {
|
|
1054
|
-
var x = { name: p, delta: g, target: y, should: w, shadowParent: Co(y) };
|
|
1055
|
-
t.current.push(x), setTimeout(function() {
|
|
1056
|
-
t.current = t.current.filter(function(b) {
|
|
1057
|
-
return b !== x;
|
|
1058
|
-
});
|
|
1059
|
-
}, 1);
|
|
1060
|
-
}, []), f = a.useCallback(function(p) {
|
|
1061
|
-
n.current = Se(p), r.current = void 0;
|
|
1062
|
-
}, []), d = a.useCallback(function(p) {
|
|
1063
|
-
l(p.type, Rt(p), p.target, c(p, e.lockRef.current));
|
|
1064
|
-
}, []), m = a.useCallback(function(p) {
|
|
1065
|
-
l(p.type, Se(p), p.target, c(p, e.lockRef.current));
|
|
1066
|
-
}, []);
|
|
1067
|
-
a.useEffect(function() {
|
|
1068
|
-
return ce.push(i), e.setCallbacks({
|
|
1069
|
-
onScrollCapture: d,
|
|
1070
|
-
onWheelCapture: d,
|
|
1071
|
-
onTouchMoveCapture: m
|
|
1072
|
-
}), document.addEventListener("wheel", u, se), document.addEventListener("touchmove", u, se), document.addEventListener("touchstart", f, se), function() {
|
|
1073
|
-
ce = ce.filter(function(p) {
|
|
1074
|
-
return p !== i;
|
|
1075
|
-
}), document.removeEventListener("wheel", u, se), document.removeEventListener("touchmove", u, se), document.removeEventListener("touchstart", f, se);
|
|
1076
|
-
};
|
|
1077
|
-
}, []);
|
|
1078
|
-
var h = e.removeScrollBar, v = e.inert;
|
|
1079
|
-
return a.createElement(
|
|
1080
|
-
a.Fragment,
|
|
1081
|
-
null,
|
|
1082
|
-
v ? a.createElement(i, { styles: bo(o) }) : null,
|
|
1083
|
-
h ? a.createElement(uo, { noRelative: e.noRelative, gapMode: e.gapMode }) : null
|
|
1084
|
-
);
|
|
1085
|
-
}
|
|
1086
|
-
function Co(e) {
|
|
1087
|
-
for (var t = null; e !== null; )
|
|
1088
|
-
e instanceof ShadowRoot && (t = e.host, e = e.host), e = e.parentNode;
|
|
1089
|
-
return t;
|
|
1090
|
-
}
|
|
1091
|
-
const Po = qr(Qt, Eo);
|
|
1092
|
-
var rn = a.forwardRef(function(e, t) {
|
|
1093
|
-
return a.createElement(Ie, z({}, e, { ref: t, sideCar: Po }));
|
|
1094
|
-
});
|
|
1095
|
-
rn.classNames = Ie.classNames;
|
|
1096
|
-
var So = function(e) {
|
|
1097
|
-
if (typeof document > "u")
|
|
1098
|
-
return null;
|
|
1099
|
-
var t = Array.isArray(e) ? e[0] : e;
|
|
1100
|
-
return t.ownerDocument.body;
|
|
1101
|
-
}, ae = /* @__PURE__ */ new WeakMap(), Ae = /* @__PURE__ */ new WeakMap(), Re = {}, Xe = 0, on = function(e) {
|
|
1102
|
-
return e && (e.host || on(e.parentNode));
|
|
1103
|
-
}, Ao = function(e, t) {
|
|
1104
|
-
return t.map(function(n) {
|
|
1105
|
-
if (e.contains(n))
|
|
1106
|
-
return n;
|
|
1107
|
-
var r = on(n);
|
|
1108
|
-
return r && e.contains(r) ? r : (console.error("aria-hidden", n, "in not contained inside", e, ". Doing nothing"), null);
|
|
1109
|
-
}).filter(function(n) {
|
|
1110
|
-
return !!n;
|
|
1111
|
-
});
|
|
1112
|
-
}, Ro = function(e, t, n, r) {
|
|
1113
|
-
var o = Ao(t, Array.isArray(e) ? e : [e]);
|
|
1114
|
-
Re[n] || (Re[n] = /* @__PURE__ */ new WeakMap());
|
|
1115
|
-
var i = Re[n], s = [], c = /* @__PURE__ */ new Set(), u = new Set(o), l = function(d) {
|
|
1116
|
-
!d || c.has(d) || (c.add(d), l(d.parentNode));
|
|
1117
|
-
};
|
|
1118
|
-
o.forEach(l);
|
|
1119
|
-
var f = function(d) {
|
|
1120
|
-
!d || u.has(d) || Array.prototype.forEach.call(d.children, function(m) {
|
|
1121
|
-
if (c.has(m))
|
|
1122
|
-
f(m);
|
|
1123
|
-
else
|
|
1124
|
-
try {
|
|
1125
|
-
var h = m.getAttribute(r), v = h !== null && h !== "false", p = (ae.get(m) || 0) + 1, g = (i.get(m) || 0) + 1;
|
|
1126
|
-
ae.set(m, p), i.set(m, g), s.push(m), p === 1 && v && Ae.set(m, !0), g === 1 && m.setAttribute(n, "true"), v || m.setAttribute(r, "true");
|
|
1127
|
-
} catch (y) {
|
|
1128
|
-
console.error("aria-hidden: cannot operate on ", m, y);
|
|
1129
|
-
}
|
|
1130
|
-
});
|
|
1131
|
-
};
|
|
1132
|
-
return f(t), c.clear(), Xe++, function() {
|
|
1133
|
-
s.forEach(function(d) {
|
|
1134
|
-
var m = ae.get(d) - 1, h = i.get(d) - 1;
|
|
1135
|
-
ae.set(d, m), i.set(d, h), m || (Ae.has(d) || d.removeAttribute(r), Ae.delete(d)), h || d.removeAttribute(n);
|
|
1136
|
-
}), Xe--, Xe || (ae = /* @__PURE__ */ new WeakMap(), ae = /* @__PURE__ */ new WeakMap(), Ae = /* @__PURE__ */ new WeakMap(), Re = {});
|
|
1137
|
-
};
|
|
1138
|
-
}, Oo = function(e, t, n) {
|
|
1139
|
-
n === void 0 && (n = "data-aria-hidden");
|
|
1140
|
-
var r = Array.from(Array.isArray(e) ? e : [e]), o = So(e);
|
|
1141
|
-
return o ? (r.push.apply(r, Array.from(o.querySelectorAll("[aria-live], script"))), Ro(r, o, n, "aria-hidden")) : function() {
|
|
1142
|
-
return null;
|
|
1143
|
-
};
|
|
1144
|
-
};
|
|
1145
|
-
function No(e) {
|
|
1146
|
-
const [t, n] = a.useState(void 0);
|
|
1147
|
-
return ee(() => {
|
|
1148
|
-
if (e) {
|
|
1149
|
-
n({ width: e.offsetWidth, height: e.offsetHeight });
|
|
1150
|
-
const r = new ResizeObserver((o) => {
|
|
1151
|
-
if (!Array.isArray(o) || !o.length)
|
|
79
|
+
n({ width: t.offsetWidth, height: t.offsetHeight });
|
|
80
|
+
const o = new ResizeObserver((r) => {
|
|
81
|
+
if (!Array.isArray(r) || !r.length)
|
|
1152
82
|
return;
|
|
1153
|
-
const i =
|
|
83
|
+
const i = r[0];
|
|
1154
84
|
let s, c;
|
|
1155
85
|
if ("borderBoxSize" in i) {
|
|
1156
|
-
const
|
|
86
|
+
const a = i.borderBoxSize, l = Array.isArray(a) ? a[0] : a;
|
|
1157
87
|
s = l.inlineSize, c = l.blockSize;
|
|
1158
88
|
} else
|
|
1159
|
-
s =
|
|
89
|
+
s = t.offsetWidth, c = t.offsetHeight;
|
|
1160
90
|
n({ width: s, height: c });
|
|
1161
91
|
});
|
|
1162
|
-
return
|
|
92
|
+
return o.observe(t, { box: "border-box" }), () => o.unobserve(t);
|
|
1163
93
|
} else
|
|
1164
94
|
n(void 0);
|
|
1165
|
-
}, [
|
|
95
|
+
}, [t]), e;
|
|
1166
96
|
}
|
|
1167
|
-
const
|
|
1168
|
-
x:
|
|
1169
|
-
y:
|
|
1170
|
-
}),
|
|
97
|
+
const gn = ["top", "right", "bottom", "left"], U = Math.min, H = Math.max, gt = Math.round, ht = Math.floor, j = (t) => ({
|
|
98
|
+
x: t,
|
|
99
|
+
y: t
|
|
100
|
+
}), wn = {
|
|
1171
101
|
left: "right",
|
|
1172
102
|
right: "left",
|
|
1173
103
|
bottom: "top",
|
|
1174
104
|
top: "bottom"
|
|
1175
|
-
},
|
|
105
|
+
}, vn = {
|
|
1176
106
|
start: "end",
|
|
1177
107
|
end: "start"
|
|
1178
108
|
};
|
|
1179
|
-
function
|
|
1180
|
-
return
|
|
109
|
+
function _t(t, e, n) {
|
|
110
|
+
return H(t, U(e, n));
|
|
1181
111
|
}
|
|
1182
|
-
function
|
|
1183
|
-
return typeof
|
|
112
|
+
function q(t, e) {
|
|
113
|
+
return typeof t == "function" ? t(e) : t;
|
|
1184
114
|
}
|
|
1185
|
-
function
|
|
1186
|
-
return
|
|
115
|
+
function G(t) {
|
|
116
|
+
return t.split("-")[0];
|
|
1187
117
|
}
|
|
1188
|
-
function
|
|
1189
|
-
return
|
|
118
|
+
function ot(t) {
|
|
119
|
+
return t.split("-")[1];
|
|
1190
120
|
}
|
|
1191
|
-
function
|
|
1192
|
-
return
|
|
121
|
+
function Lt(t) {
|
|
122
|
+
return t === "x" ? "y" : "x";
|
|
1193
123
|
}
|
|
1194
|
-
function
|
|
1195
|
-
return
|
|
124
|
+
function Tt(t) {
|
|
125
|
+
return t === "y" ? "height" : "width";
|
|
1196
126
|
}
|
|
1197
|
-
const
|
|
1198
|
-
function
|
|
1199
|
-
return
|
|
127
|
+
const xn = /* @__PURE__ */ new Set(["top", "bottom"]);
|
|
128
|
+
function V(t) {
|
|
129
|
+
return xn.has(G(t)) ? "y" : "x";
|
|
1200
130
|
}
|
|
1201
|
-
function
|
|
1202
|
-
return
|
|
131
|
+
function Nt(t) {
|
|
132
|
+
return Lt(V(t));
|
|
1203
133
|
}
|
|
1204
|
-
function
|
|
134
|
+
function yn(t, e, n) {
|
|
1205
135
|
n === void 0 && (n = !1);
|
|
1206
|
-
const
|
|
1207
|
-
let s =
|
|
1208
|
-
return
|
|
136
|
+
const o = ot(t), r = Nt(t), i = Tt(r);
|
|
137
|
+
let s = r === "x" ? o === (n ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
|
|
138
|
+
return e.reference[i] > e.floating[i] && (s = wt(s)), [s, wt(s)];
|
|
1209
139
|
}
|
|
1210
|
-
function
|
|
1211
|
-
const
|
|
1212
|
-
return [
|
|
140
|
+
function An(t) {
|
|
141
|
+
const e = wt(t);
|
|
142
|
+
return [Mt(t), e, Mt(e)];
|
|
1213
143
|
}
|
|
1214
|
-
function
|
|
1215
|
-
return
|
|
144
|
+
function Mt(t) {
|
|
145
|
+
return t.replace(/start|end/g, (e) => vn[e]);
|
|
1216
146
|
}
|
|
1217
|
-
const
|
|
1218
|
-
function
|
|
1219
|
-
switch (
|
|
147
|
+
const Yt = ["left", "right"], Xt = ["right", "left"], Pn = ["top", "bottom"], bn = ["bottom", "top"];
|
|
148
|
+
function Cn(t, e, n) {
|
|
149
|
+
switch (t) {
|
|
1220
150
|
case "top":
|
|
1221
151
|
case "bottom":
|
|
1222
|
-
return n ?
|
|
152
|
+
return n ? e ? Xt : Yt : e ? Yt : Xt;
|
|
1223
153
|
case "left":
|
|
1224
154
|
case "right":
|
|
1225
|
-
return
|
|
155
|
+
return e ? Pn : bn;
|
|
1226
156
|
default:
|
|
1227
157
|
return [];
|
|
1228
158
|
}
|
|
1229
159
|
}
|
|
1230
|
-
function
|
|
1231
|
-
const
|
|
1232
|
-
let i =
|
|
1233
|
-
return
|
|
160
|
+
function Rn(t, e, n, o) {
|
|
161
|
+
const r = ot(t);
|
|
162
|
+
let i = Cn(G(t), n === "start", o);
|
|
163
|
+
return r && (i = i.map((s) => s + "-" + r), e && (i = i.concat(i.map(Mt)))), i;
|
|
1234
164
|
}
|
|
1235
|
-
function
|
|
1236
|
-
return
|
|
165
|
+
function wt(t) {
|
|
166
|
+
return t.replace(/left|right|bottom|top/g, (e) => wn[e]);
|
|
1237
167
|
}
|
|
1238
|
-
function
|
|
168
|
+
function On(t) {
|
|
1239
169
|
return {
|
|
1240
170
|
top: 0,
|
|
1241
171
|
right: 0,
|
|
1242
172
|
bottom: 0,
|
|
1243
173
|
left: 0,
|
|
1244
|
-
...
|
|
174
|
+
...t
|
|
1245
175
|
};
|
|
1246
176
|
}
|
|
1247
|
-
function
|
|
1248
|
-
return typeof
|
|
1249
|
-
top:
|
|
1250
|
-
right:
|
|
1251
|
-
bottom:
|
|
1252
|
-
left:
|
|
177
|
+
function re(t) {
|
|
178
|
+
return typeof t != "number" ? On(t) : {
|
|
179
|
+
top: t,
|
|
180
|
+
right: t,
|
|
181
|
+
bottom: t,
|
|
182
|
+
left: t
|
|
1253
183
|
};
|
|
1254
184
|
}
|
|
1255
|
-
function
|
|
185
|
+
function vt(t) {
|
|
1256
186
|
const {
|
|
1257
|
-
x:
|
|
187
|
+
x: e,
|
|
1258
188
|
y: n,
|
|
1259
|
-
width:
|
|
1260
|
-
height:
|
|
1261
|
-
} =
|
|
189
|
+
width: o,
|
|
190
|
+
height: r
|
|
191
|
+
} = t;
|
|
1262
192
|
return {
|
|
1263
|
-
width:
|
|
1264
|
-
height:
|
|
193
|
+
width: o,
|
|
194
|
+
height: r,
|
|
1265
195
|
top: n,
|
|
1266
|
-
left:
|
|
1267
|
-
right:
|
|
1268
|
-
bottom: n +
|
|
1269
|
-
x:
|
|
196
|
+
left: e,
|
|
197
|
+
right: e + o,
|
|
198
|
+
bottom: n + r,
|
|
199
|
+
x: e,
|
|
1270
200
|
y: n
|
|
1271
201
|
};
|
|
1272
202
|
}
|
|
1273
|
-
function
|
|
203
|
+
function qt(t, e, n) {
|
|
1274
204
|
let {
|
|
1275
|
-
reference:
|
|
1276
|
-
floating:
|
|
1277
|
-
} =
|
|
1278
|
-
const i =
|
|
1279
|
-
let
|
|
1280
|
-
switch (
|
|
205
|
+
reference: o,
|
|
206
|
+
floating: r
|
|
207
|
+
} = t;
|
|
208
|
+
const i = V(e), s = Nt(e), c = Tt(s), a = G(e), l = i === "y", f = o.x + o.width / 2 - r.width / 2, u = o.y + o.height / 2 - r.height / 2, p = o[c] / 2 - r[c] / 2;
|
|
209
|
+
let d;
|
|
210
|
+
switch (a) {
|
|
1281
211
|
case "top":
|
|
1282
|
-
|
|
212
|
+
d = {
|
|
1283
213
|
x: f,
|
|
1284
|
-
y:
|
|
214
|
+
y: o.y - r.height
|
|
1285
215
|
};
|
|
1286
216
|
break;
|
|
1287
217
|
case "bottom":
|
|
1288
|
-
|
|
218
|
+
d = {
|
|
1289
219
|
x: f,
|
|
1290
|
-
y:
|
|
220
|
+
y: o.y + o.height
|
|
1291
221
|
};
|
|
1292
222
|
break;
|
|
1293
223
|
case "right":
|
|
1294
|
-
|
|
1295
|
-
x:
|
|
1296
|
-
y:
|
|
224
|
+
d = {
|
|
225
|
+
x: o.x + o.width,
|
|
226
|
+
y: u
|
|
1297
227
|
};
|
|
1298
228
|
break;
|
|
1299
229
|
case "left":
|
|
1300
|
-
|
|
1301
|
-
x:
|
|
1302
|
-
y:
|
|
230
|
+
d = {
|
|
231
|
+
x: o.x - r.width,
|
|
232
|
+
y: u
|
|
1303
233
|
};
|
|
1304
234
|
break;
|
|
1305
235
|
default:
|
|
1306
|
-
|
|
1307
|
-
x:
|
|
1308
|
-
y:
|
|
236
|
+
d = {
|
|
237
|
+
x: o.x,
|
|
238
|
+
y: o.y
|
|
1309
239
|
};
|
|
1310
240
|
}
|
|
1311
|
-
switch (
|
|
241
|
+
switch (ot(e)) {
|
|
1312
242
|
case "start":
|
|
1313
|
-
|
|
243
|
+
d[s] -= p * (n && l ? -1 : 1);
|
|
1314
244
|
break;
|
|
1315
245
|
case "end":
|
|
1316
|
-
|
|
246
|
+
d[s] += p * (n && l ? -1 : 1);
|
|
1317
247
|
break;
|
|
1318
248
|
}
|
|
1319
|
-
return
|
|
249
|
+
return d;
|
|
1320
250
|
}
|
|
1321
|
-
const
|
|
251
|
+
const Sn = async (t, e, n) => {
|
|
1322
252
|
const {
|
|
1323
|
-
placement:
|
|
1324
|
-
strategy:
|
|
253
|
+
placement: o = "bottom",
|
|
254
|
+
strategy: r = "absolute",
|
|
1325
255
|
middleware: i = [],
|
|
1326
256
|
platform: s
|
|
1327
|
-
} = n, c = i.filter(Boolean),
|
|
257
|
+
} = n, c = i.filter(Boolean), a = await (s.isRTL == null ? void 0 : s.isRTL(e));
|
|
1328
258
|
let l = await s.getElementRects({
|
|
1329
|
-
reference:
|
|
1330
|
-
floating:
|
|
1331
|
-
strategy:
|
|
259
|
+
reference: t,
|
|
260
|
+
floating: e,
|
|
261
|
+
strategy: r
|
|
1332
262
|
}), {
|
|
1333
263
|
x: f,
|
|
1334
|
-
y:
|
|
1335
|
-
} =
|
|
1336
|
-
for (let
|
|
264
|
+
y: u
|
|
265
|
+
} = qt(l, o, a), p = o, d = {}, h = 0;
|
|
266
|
+
for (let m = 0; m < c.length; m++) {
|
|
1337
267
|
const {
|
|
1338
|
-
name:
|
|
1339
|
-
fn:
|
|
1340
|
-
} = c[
|
|
1341
|
-
x:
|
|
1342
|
-
y:
|
|
1343
|
-
data:
|
|
1344
|
-
reset:
|
|
1345
|
-
} = await
|
|
268
|
+
name: x,
|
|
269
|
+
fn: v
|
|
270
|
+
} = c[m], {
|
|
271
|
+
x: y,
|
|
272
|
+
y: b,
|
|
273
|
+
data: A,
|
|
274
|
+
reset: P
|
|
275
|
+
} = await v({
|
|
1346
276
|
x: f,
|
|
1347
|
-
y:
|
|
1348
|
-
initialPlacement:
|
|
1349
|
-
placement:
|
|
1350
|
-
strategy:
|
|
1351
|
-
middlewareData:
|
|
277
|
+
y: u,
|
|
278
|
+
initialPlacement: o,
|
|
279
|
+
placement: p,
|
|
280
|
+
strategy: r,
|
|
281
|
+
middlewareData: d,
|
|
1352
282
|
rects: l,
|
|
1353
283
|
platform: s,
|
|
1354
284
|
elements: {
|
|
1355
|
-
reference:
|
|
1356
|
-
floating:
|
|
285
|
+
reference: t,
|
|
286
|
+
floating: e
|
|
1357
287
|
}
|
|
1358
288
|
});
|
|
1359
|
-
f =
|
|
1360
|
-
...
|
|
1361
|
-
[
|
|
1362
|
-
...
|
|
1363
|
-
...
|
|
289
|
+
f = y ?? f, u = b ?? u, d = {
|
|
290
|
+
...d,
|
|
291
|
+
[x]: {
|
|
292
|
+
...d[x],
|
|
293
|
+
...A
|
|
1364
294
|
}
|
|
1365
|
-
},
|
|
1366
|
-
reference:
|
|
1367
|
-
floating:
|
|
1368
|
-
strategy:
|
|
1369
|
-
}) :
|
|
295
|
+
}, P && h <= 50 && (h++, typeof P == "object" && (P.placement && (p = P.placement), P.rects && (l = P.rects === !0 ? await s.getElementRects({
|
|
296
|
+
reference: t,
|
|
297
|
+
floating: e,
|
|
298
|
+
strategy: r
|
|
299
|
+
}) : P.rects), {
|
|
1370
300
|
x: f,
|
|
1371
|
-
y:
|
|
1372
|
-
} =
|
|
301
|
+
y: u
|
|
302
|
+
} = qt(l, p, a)), m = -1);
|
|
1373
303
|
}
|
|
1374
304
|
return {
|
|
1375
305
|
x: f,
|
|
1376
|
-
y:
|
|
1377
|
-
placement:
|
|
1378
|
-
strategy:
|
|
1379
|
-
middlewareData:
|
|
306
|
+
y: u,
|
|
307
|
+
placement: p,
|
|
308
|
+
strategy: r,
|
|
309
|
+
middlewareData: d
|
|
1380
310
|
};
|
|
1381
311
|
};
|
|
1382
|
-
async function
|
|
312
|
+
async function at(t, e) {
|
|
1383
313
|
var n;
|
|
1384
|
-
|
|
314
|
+
e === void 0 && (e = {});
|
|
1385
315
|
const {
|
|
1386
|
-
x:
|
|
1387
|
-
y:
|
|
316
|
+
x: o,
|
|
317
|
+
y: r,
|
|
1388
318
|
platform: i,
|
|
1389
319
|
rects: s,
|
|
1390
320
|
elements: c,
|
|
1391
|
-
strategy:
|
|
1392
|
-
} =
|
|
321
|
+
strategy: a
|
|
322
|
+
} = t, {
|
|
1393
323
|
boundary: l = "clippingAncestors",
|
|
1394
324
|
rootBoundary: f = "viewport",
|
|
1395
|
-
elementContext:
|
|
1396
|
-
altBoundary:
|
|
1397
|
-
padding:
|
|
1398
|
-
} =
|
|
1399
|
-
element: (n = await (i.isElement == null ? void 0 : i.isElement(
|
|
325
|
+
elementContext: u = "floating",
|
|
326
|
+
altBoundary: p = !1,
|
|
327
|
+
padding: d = 0
|
|
328
|
+
} = q(e, t), h = re(d), x = c[p ? u === "floating" ? "reference" : "floating" : u], v = vt(await i.getClippingRect({
|
|
329
|
+
element: (n = await (i.isElement == null ? void 0 : i.isElement(x))) == null || n ? x : x.contextElement || await (i.getDocumentElement == null ? void 0 : i.getDocumentElement(c.floating)),
|
|
1400
330
|
boundary: l,
|
|
1401
331
|
rootBoundary: f,
|
|
1402
|
-
strategy:
|
|
1403
|
-
})),
|
|
1404
|
-
x:
|
|
1405
|
-
y:
|
|
332
|
+
strategy: a
|
|
333
|
+
})), y = u === "floating" ? {
|
|
334
|
+
x: o,
|
|
335
|
+
y: r,
|
|
1406
336
|
width: s.floating.width,
|
|
1407
337
|
height: s.floating.height
|
|
1408
|
-
} : s.reference,
|
|
338
|
+
} : s.reference, b = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(c.floating)), A = await (i.isElement == null ? void 0 : i.isElement(b)) ? await (i.getScale == null ? void 0 : i.getScale(b)) || {
|
|
1409
339
|
x: 1,
|
|
1410
340
|
y: 1
|
|
1411
341
|
} : {
|
|
1412
342
|
x: 1,
|
|
1413
343
|
y: 1
|
|
1414
|
-
},
|
|
344
|
+
}, P = vt(i.convertOffsetParentRelativeRectToViewportRelativeRect ? await i.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
1415
345
|
elements: c,
|
|
1416
|
-
rect:
|
|
1417
|
-
offsetParent:
|
|
1418
|
-
strategy:
|
|
1419
|
-
}) :
|
|
346
|
+
rect: y,
|
|
347
|
+
offsetParent: b,
|
|
348
|
+
strategy: a
|
|
349
|
+
}) : y);
|
|
1420
350
|
return {
|
|
1421
|
-
top: (
|
|
1422
|
-
bottom: (
|
|
1423
|
-
left: (
|
|
1424
|
-
right: (
|
|
351
|
+
top: (v.top - P.top + h.top) / A.y,
|
|
352
|
+
bottom: (P.bottom - v.bottom + h.bottom) / A.y,
|
|
353
|
+
left: (v.left - P.left + h.left) / A.x,
|
|
354
|
+
right: (P.right - v.right + h.right) / A.x
|
|
1425
355
|
};
|
|
1426
356
|
}
|
|
1427
|
-
const
|
|
357
|
+
const En = (t) => ({
|
|
1428
358
|
name: "arrow",
|
|
1429
|
-
options:
|
|
1430
|
-
async fn(
|
|
359
|
+
options: t,
|
|
360
|
+
async fn(e) {
|
|
1431
361
|
const {
|
|
1432
362
|
x: n,
|
|
1433
|
-
y:
|
|
1434
|
-
placement:
|
|
363
|
+
y: o,
|
|
364
|
+
placement: r,
|
|
1435
365
|
rects: i,
|
|
1436
366
|
platform: s,
|
|
1437
367
|
elements: c,
|
|
1438
|
-
middlewareData:
|
|
1439
|
-
} =
|
|
368
|
+
middlewareData: a
|
|
369
|
+
} = e, {
|
|
1440
370
|
element: l,
|
|
1441
371
|
padding: f = 0
|
|
1442
|
-
} =
|
|
372
|
+
} = q(t, e) || {};
|
|
1443
373
|
if (l == null)
|
|
1444
374
|
return {};
|
|
1445
|
-
const
|
|
375
|
+
const u = re(f), p = {
|
|
1446
376
|
x: n,
|
|
1447
|
-
y:
|
|
1448
|
-
},
|
|
1449
|
-
let
|
|
1450
|
-
(!
|
|
1451
|
-
const
|
|
377
|
+
y: o
|
|
378
|
+
}, d = Nt(r), h = Tt(d), m = await s.getDimensions(l), x = d === "y", v = x ? "top" : "left", y = x ? "bottom" : "right", b = x ? "clientHeight" : "clientWidth", A = i.reference[h] + i.reference[d] - p[d] - i.floating[h], P = p[d] - i.reference[d], O = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(l));
|
|
379
|
+
let R = O ? O[b] : 0;
|
|
380
|
+
(!R || !await (s.isElement == null ? void 0 : s.isElement(O))) && (R = c.floating[b] || i.floating[h]);
|
|
381
|
+
const D = A / 2 - P / 2, F = R / 2 - m[h] / 2 - 1, M = U(u[v], F), T = U(u[y], F), N = M, E = R - m[h] - T, S = R / 2 - m[h] / 2 + D, $ = _t(N, S, E), k = !a.arrow && ot(r) != null && S !== $ && i.reference[h] / 2 - (S < N ? M : T) - m[h] / 2 < 0, _ = k ? S < N ? S - N : S - E : 0;
|
|
1452
382
|
return {
|
|
1453
|
-
[
|
|
383
|
+
[d]: p[d] + _,
|
|
1454
384
|
data: {
|
|
1455
|
-
[
|
|
1456
|
-
centerOffset:
|
|
385
|
+
[d]: $,
|
|
386
|
+
centerOffset: S - $ - _,
|
|
1457
387
|
...k && {
|
|
1458
|
-
alignmentOffset:
|
|
388
|
+
alignmentOffset: _
|
|
1459
389
|
}
|
|
1460
390
|
},
|
|
1461
391
|
reset: k
|
|
1462
392
|
};
|
|
1463
393
|
}
|
|
1464
|
-
}),
|
|
1465
|
-
return
|
|
394
|
+
}), kn = function(t) {
|
|
395
|
+
return t === void 0 && (t = {}), {
|
|
1466
396
|
name: "flip",
|
|
1467
|
-
options:
|
|
1468
|
-
async fn(
|
|
1469
|
-
var n,
|
|
397
|
+
options: t,
|
|
398
|
+
async fn(e) {
|
|
399
|
+
var n, o;
|
|
1470
400
|
const {
|
|
1471
|
-
placement:
|
|
401
|
+
placement: r,
|
|
1472
402
|
middlewareData: i,
|
|
1473
403
|
rects: s,
|
|
1474
404
|
initialPlacement: c,
|
|
1475
|
-
platform:
|
|
405
|
+
platform: a,
|
|
1476
406
|
elements: l
|
|
1477
|
-
} =
|
|
407
|
+
} = e, {
|
|
1478
408
|
mainAxis: f = !0,
|
|
1479
|
-
crossAxis:
|
|
1480
|
-
fallbackPlacements:
|
|
1481
|
-
fallbackStrategy:
|
|
1482
|
-
fallbackAxisSideDirection:
|
|
1483
|
-
flipAlignment:
|
|
1484
|
-
...
|
|
1485
|
-
} =
|
|
409
|
+
crossAxis: u = !0,
|
|
410
|
+
fallbackPlacements: p,
|
|
411
|
+
fallbackStrategy: d = "bestFit",
|
|
412
|
+
fallbackAxisSideDirection: h = "none",
|
|
413
|
+
flipAlignment: m = !0,
|
|
414
|
+
...x
|
|
415
|
+
} = q(t, e);
|
|
1486
416
|
if ((n = i.arrow) != null && n.alignmentOffset)
|
|
1487
417
|
return {};
|
|
1488
|
-
const
|
|
1489
|
-
!
|
|
1490
|
-
const
|
|
1491
|
-
let
|
|
1492
|
-
if (f &&
|
|
1493
|
-
const
|
|
1494
|
-
|
|
418
|
+
const v = G(r), y = V(c), b = G(c) === c, A = await (a.isRTL == null ? void 0 : a.isRTL(l.floating)), P = p || (b || !m ? [wt(c)] : An(c)), O = h !== "none";
|
|
419
|
+
!p && O && P.push(...Rn(c, m, h, A));
|
|
420
|
+
const R = [c, ...P], D = await at(e, x), F = [];
|
|
421
|
+
let M = ((o = i.flip) == null ? void 0 : o.overflows) || [];
|
|
422
|
+
if (f && F.push(D[v]), u) {
|
|
423
|
+
const S = yn(r, s, A);
|
|
424
|
+
F.push(D[S[0]], D[S[1]]);
|
|
1495
425
|
}
|
|
1496
|
-
if (
|
|
1497
|
-
placement:
|
|
1498
|
-
overflows:
|
|
1499
|
-
}], !
|
|
1500
|
-
var
|
|
1501
|
-
const
|
|
1502
|
-
if (
|
|
426
|
+
if (M = [...M, {
|
|
427
|
+
placement: r,
|
|
428
|
+
overflows: F
|
|
429
|
+
}], !F.every((S) => S <= 0)) {
|
|
430
|
+
var T, N;
|
|
431
|
+
const S = (((T = i.flip) == null ? void 0 : T.index) || 0) + 1, $ = R[S];
|
|
432
|
+
if ($ && (!(u === "alignment" ? y !== V($) : !1) || // We leave the current main axis only if every placement on that axis
|
|
1503
433
|
// overflows the main axis.
|
|
1504
|
-
|
|
434
|
+
M.every((C) => V(C.placement) === y ? C.overflows[0] > 0 : !0)))
|
|
1505
435
|
return {
|
|
1506
436
|
data: {
|
|
1507
|
-
index:
|
|
1508
|
-
overflows:
|
|
437
|
+
index: S,
|
|
438
|
+
overflows: M
|
|
1509
439
|
},
|
|
1510
440
|
reset: {
|
|
1511
|
-
placement:
|
|
441
|
+
placement: $
|
|
1512
442
|
}
|
|
1513
443
|
};
|
|
1514
|
-
let k = (
|
|
444
|
+
let k = (N = M.filter((_) => _.overflows[0] <= 0).sort((_, C) => _.overflows[1] - C.overflows[1])[0]) == null ? void 0 : N.placement;
|
|
1515
445
|
if (!k)
|
|
1516
|
-
switch (
|
|
446
|
+
switch (d) {
|
|
1517
447
|
case "bestFit": {
|
|
1518
|
-
var
|
|
1519
|
-
const
|
|
1520
|
-
if (
|
|
1521
|
-
const
|
|
1522
|
-
return
|
|
448
|
+
var E;
|
|
449
|
+
const _ = (E = M.filter((C) => {
|
|
450
|
+
if (O) {
|
|
451
|
+
const L = V(C.placement);
|
|
452
|
+
return L === y || // Create a bias to the `y` side axis due to horizontal
|
|
1523
453
|
// reading directions favoring greater width.
|
|
1524
|
-
|
|
454
|
+
L === "y";
|
|
1525
455
|
}
|
|
1526
456
|
return !0;
|
|
1527
|
-
}).map((
|
|
1528
|
-
|
|
457
|
+
}).map((C) => [C.placement, C.overflows.filter((L) => L > 0).reduce((L, I) => L + I, 0)]).sort((C, L) => C[1] - L[1])[0]) == null ? void 0 : E[0];
|
|
458
|
+
_ && (k = _);
|
|
1529
459
|
break;
|
|
1530
460
|
}
|
|
1531
461
|
case "initialPlacement":
|
|
1532
462
|
k = c;
|
|
1533
463
|
break;
|
|
1534
464
|
}
|
|
1535
|
-
if (
|
|
465
|
+
if (r !== k)
|
|
1536
466
|
return {
|
|
1537
467
|
reset: {
|
|
1538
468
|
placement: k
|
|
@@ -1543,50 +473,50 @@ const Vo = (e) => ({
|
|
|
1543
473
|
}
|
|
1544
474
|
};
|
|
1545
475
|
};
|
|
1546
|
-
function
|
|
476
|
+
function Gt(t, e) {
|
|
1547
477
|
return {
|
|
1548
|
-
top:
|
|
1549
|
-
right:
|
|
1550
|
-
bottom:
|
|
1551
|
-
left:
|
|
478
|
+
top: t.top - e.height,
|
|
479
|
+
right: t.right - e.width,
|
|
480
|
+
bottom: t.bottom - e.height,
|
|
481
|
+
left: t.left - e.width
|
|
1552
482
|
};
|
|
1553
483
|
}
|
|
1554
|
-
function
|
|
1555
|
-
return
|
|
484
|
+
function Kt(t) {
|
|
485
|
+
return gn.some((e) => t[e] >= 0);
|
|
1556
486
|
}
|
|
1557
|
-
const
|
|
1558
|
-
return
|
|
487
|
+
const _n = function(t) {
|
|
488
|
+
return t === void 0 && (t = {}), {
|
|
1559
489
|
name: "hide",
|
|
1560
|
-
options:
|
|
1561
|
-
async fn(
|
|
490
|
+
options: t,
|
|
491
|
+
async fn(e) {
|
|
1562
492
|
const {
|
|
1563
493
|
rects: n
|
|
1564
|
-
} =
|
|
1565
|
-
strategy:
|
|
1566
|
-
...
|
|
1567
|
-
} =
|
|
1568
|
-
switch (
|
|
494
|
+
} = e, {
|
|
495
|
+
strategy: o = "referenceHidden",
|
|
496
|
+
...r
|
|
497
|
+
} = q(t, e);
|
|
498
|
+
switch (o) {
|
|
1569
499
|
case "referenceHidden": {
|
|
1570
|
-
const i = await
|
|
1571
|
-
...
|
|
500
|
+
const i = await at(e, {
|
|
501
|
+
...r,
|
|
1572
502
|
elementContext: "reference"
|
|
1573
|
-
}), s =
|
|
503
|
+
}), s = Gt(i, n.reference);
|
|
1574
504
|
return {
|
|
1575
505
|
data: {
|
|
1576
506
|
referenceHiddenOffsets: s,
|
|
1577
|
-
referenceHidden:
|
|
507
|
+
referenceHidden: Kt(s)
|
|
1578
508
|
}
|
|
1579
509
|
};
|
|
1580
510
|
}
|
|
1581
511
|
case "escaped": {
|
|
1582
|
-
const i = await
|
|
1583
|
-
...
|
|
512
|
+
const i = await at(e, {
|
|
513
|
+
...r,
|
|
1584
514
|
altBoundary: !0
|
|
1585
|
-
}), s =
|
|
515
|
+
}), s = Gt(i, n.floating);
|
|
1586
516
|
return {
|
|
1587
517
|
data: {
|
|
1588
518
|
escapedOffsets: s,
|
|
1589
|
-
escaped:
|
|
519
|
+
escaped: Kt(s)
|
|
1590
520
|
}
|
|
1591
521
|
};
|
|
1592
522
|
}
|
|
@@ -1595,188 +525,188 @@ const Uo = function(e) {
|
|
|
1595
525
|
}
|
|
1596
526
|
}
|
|
1597
527
|
};
|
|
1598
|
-
},
|
|
1599
|
-
async function
|
|
528
|
+
}, ie = /* @__PURE__ */ new Set(["left", "top"]);
|
|
529
|
+
async function Mn(t, e) {
|
|
1600
530
|
const {
|
|
1601
531
|
placement: n,
|
|
1602
|
-
platform:
|
|
1603
|
-
elements:
|
|
1604
|
-
} =
|
|
532
|
+
platform: o,
|
|
533
|
+
elements: r
|
|
534
|
+
} = t, i = await (o.isRTL == null ? void 0 : o.isRTL(r.floating)), s = G(n), c = ot(n), a = V(n) === "y", l = ie.has(s) ? -1 : 1, f = i && a ? -1 : 1, u = q(e, t);
|
|
1605
535
|
let {
|
|
1606
|
-
mainAxis:
|
|
1607
|
-
crossAxis:
|
|
1608
|
-
alignmentAxis:
|
|
1609
|
-
} = typeof
|
|
1610
|
-
mainAxis:
|
|
536
|
+
mainAxis: p,
|
|
537
|
+
crossAxis: d,
|
|
538
|
+
alignmentAxis: h
|
|
539
|
+
} = typeof u == "number" ? {
|
|
540
|
+
mainAxis: u,
|
|
1611
541
|
crossAxis: 0,
|
|
1612
542
|
alignmentAxis: null
|
|
1613
543
|
} : {
|
|
1614
|
-
mainAxis:
|
|
1615
|
-
crossAxis:
|
|
1616
|
-
alignmentAxis:
|
|
544
|
+
mainAxis: u.mainAxis || 0,
|
|
545
|
+
crossAxis: u.crossAxis || 0,
|
|
546
|
+
alignmentAxis: u.alignmentAxis
|
|
1617
547
|
};
|
|
1618
|
-
return c && typeof
|
|
1619
|
-
x:
|
|
1620
|
-
y:
|
|
548
|
+
return c && typeof h == "number" && (d = c === "end" ? h * -1 : h), a ? {
|
|
549
|
+
x: d * f,
|
|
550
|
+
y: p * l
|
|
1621
551
|
} : {
|
|
1622
|
-
x:
|
|
1623
|
-
y:
|
|
552
|
+
x: p * l,
|
|
553
|
+
y: d * f
|
|
1624
554
|
};
|
|
1625
555
|
}
|
|
1626
|
-
const
|
|
1627
|
-
return
|
|
556
|
+
const Dn = function(t) {
|
|
557
|
+
return t === void 0 && (t = 0), {
|
|
1628
558
|
name: "offset",
|
|
1629
|
-
options:
|
|
1630
|
-
async fn(
|
|
1631
|
-
var n,
|
|
559
|
+
options: t,
|
|
560
|
+
async fn(e) {
|
|
561
|
+
var n, o;
|
|
1632
562
|
const {
|
|
1633
|
-
x:
|
|
563
|
+
x: r,
|
|
1634
564
|
y: i,
|
|
1635
565
|
placement: s,
|
|
1636
566
|
middlewareData: c
|
|
1637
|
-
} =
|
|
1638
|
-
return s === ((n = c.offset) == null ? void 0 : n.placement) && (
|
|
1639
|
-
x:
|
|
1640
|
-
y: i +
|
|
567
|
+
} = e, a = await Mn(e, t);
|
|
568
|
+
return s === ((n = c.offset) == null ? void 0 : n.placement) && (o = c.arrow) != null && o.alignmentOffset ? {} : {
|
|
569
|
+
x: r + a.x,
|
|
570
|
+
y: i + a.y,
|
|
1641
571
|
data: {
|
|
1642
|
-
...
|
|
572
|
+
...a,
|
|
1643
573
|
placement: s
|
|
1644
574
|
}
|
|
1645
575
|
};
|
|
1646
576
|
}
|
|
1647
577
|
};
|
|
1648
|
-
},
|
|
1649
|
-
return
|
|
578
|
+
}, Ln = function(t) {
|
|
579
|
+
return t === void 0 && (t = {}), {
|
|
1650
580
|
name: "shift",
|
|
1651
|
-
options:
|
|
1652
|
-
async fn(
|
|
581
|
+
options: t,
|
|
582
|
+
async fn(e) {
|
|
1653
583
|
const {
|
|
1654
584
|
x: n,
|
|
1655
|
-
y:
|
|
1656
|
-
placement:
|
|
1657
|
-
} =
|
|
585
|
+
y: o,
|
|
586
|
+
placement: r
|
|
587
|
+
} = e, {
|
|
1658
588
|
mainAxis: i = !0,
|
|
1659
589
|
crossAxis: s = !1,
|
|
1660
590
|
limiter: c = {
|
|
1661
|
-
fn: (
|
|
591
|
+
fn: (x) => {
|
|
1662
592
|
let {
|
|
1663
|
-
x:
|
|
1664
|
-
y
|
|
1665
|
-
} =
|
|
593
|
+
x: v,
|
|
594
|
+
y
|
|
595
|
+
} = x;
|
|
1666
596
|
return {
|
|
1667
|
-
x:
|
|
1668
|
-
y
|
|
597
|
+
x: v,
|
|
598
|
+
y
|
|
1669
599
|
};
|
|
1670
600
|
}
|
|
1671
601
|
},
|
|
1672
|
-
...
|
|
1673
|
-
} =
|
|
602
|
+
...a
|
|
603
|
+
} = q(t, e), l = {
|
|
1674
604
|
x: n,
|
|
1675
|
-
y:
|
|
1676
|
-
}, f = await
|
|
1677
|
-
let
|
|
605
|
+
y: o
|
|
606
|
+
}, f = await at(e, a), u = V(G(r)), p = Lt(u);
|
|
607
|
+
let d = l[p], h = l[u];
|
|
1678
608
|
if (i) {
|
|
1679
|
-
const
|
|
1680
|
-
|
|
609
|
+
const x = p === "y" ? "top" : "left", v = p === "y" ? "bottom" : "right", y = d + f[x], b = d - f[v];
|
|
610
|
+
d = _t(y, d, b);
|
|
1681
611
|
}
|
|
1682
612
|
if (s) {
|
|
1683
|
-
const
|
|
1684
|
-
|
|
613
|
+
const x = u === "y" ? "top" : "left", v = u === "y" ? "bottom" : "right", y = h + f[x], b = h - f[v];
|
|
614
|
+
h = _t(y, h, b);
|
|
1685
615
|
}
|
|
1686
|
-
const
|
|
1687
|
-
...
|
|
1688
|
-
[
|
|
1689
|
-
[
|
|
616
|
+
const m = c.fn({
|
|
617
|
+
...e,
|
|
618
|
+
[p]: d,
|
|
619
|
+
[u]: h
|
|
1690
620
|
});
|
|
1691
621
|
return {
|
|
1692
|
-
...
|
|
622
|
+
...m,
|
|
1693
623
|
data: {
|
|
1694
|
-
x:
|
|
1695
|
-
y:
|
|
624
|
+
x: m.x - n,
|
|
625
|
+
y: m.y - o,
|
|
1696
626
|
enabled: {
|
|
1697
|
-
[
|
|
1698
|
-
[
|
|
627
|
+
[p]: i,
|
|
628
|
+
[u]: s
|
|
1699
629
|
}
|
|
1700
630
|
}
|
|
1701
631
|
};
|
|
1702
632
|
}
|
|
1703
633
|
};
|
|
1704
|
-
},
|
|
1705
|
-
return
|
|
1706
|
-
options:
|
|
1707
|
-
fn(
|
|
634
|
+
}, Tn = function(t) {
|
|
635
|
+
return t === void 0 && (t = {}), {
|
|
636
|
+
options: t,
|
|
637
|
+
fn(e) {
|
|
1708
638
|
const {
|
|
1709
639
|
x: n,
|
|
1710
|
-
y:
|
|
1711
|
-
placement:
|
|
640
|
+
y: o,
|
|
641
|
+
placement: r,
|
|
1712
642
|
rects: i,
|
|
1713
643
|
middlewareData: s
|
|
1714
|
-
} =
|
|
644
|
+
} = e, {
|
|
1715
645
|
offset: c = 0,
|
|
1716
|
-
mainAxis:
|
|
646
|
+
mainAxis: a = !0,
|
|
1717
647
|
crossAxis: l = !0
|
|
1718
|
-
} =
|
|
648
|
+
} = q(t, e), f = {
|
|
1719
649
|
x: n,
|
|
1720
|
-
y:
|
|
1721
|
-
},
|
|
1722
|
-
let
|
|
1723
|
-
const
|
|
1724
|
-
mainAxis:
|
|
650
|
+
y: o
|
|
651
|
+
}, u = V(r), p = Lt(u);
|
|
652
|
+
let d = f[p], h = f[u];
|
|
653
|
+
const m = q(c, e), x = typeof m == "number" ? {
|
|
654
|
+
mainAxis: m,
|
|
1725
655
|
crossAxis: 0
|
|
1726
656
|
} : {
|
|
1727
657
|
mainAxis: 0,
|
|
1728
658
|
crossAxis: 0,
|
|
1729
|
-
...
|
|
659
|
+
...m
|
|
1730
660
|
};
|
|
1731
|
-
if (
|
|
1732
|
-
const
|
|
1733
|
-
|
|
661
|
+
if (a) {
|
|
662
|
+
const b = p === "y" ? "height" : "width", A = i.reference[p] - i.floating[b] + x.mainAxis, P = i.reference[p] + i.reference[b] - x.mainAxis;
|
|
663
|
+
d < A ? d = A : d > P && (d = P);
|
|
1734
664
|
}
|
|
1735
665
|
if (l) {
|
|
1736
|
-
var
|
|
1737
|
-
const
|
|
1738
|
-
|
|
666
|
+
var v, y;
|
|
667
|
+
const b = p === "y" ? "width" : "height", A = ie.has(G(r)), P = i.reference[u] - i.floating[b] + (A && ((v = s.offset) == null ? void 0 : v[u]) || 0) + (A ? 0 : x.crossAxis), O = i.reference[u] + i.reference[b] + (A ? 0 : ((y = s.offset) == null ? void 0 : y[u]) || 0) - (A ? x.crossAxis : 0);
|
|
668
|
+
h < P ? h = P : h > O && (h = O);
|
|
1739
669
|
}
|
|
1740
670
|
return {
|
|
1741
|
-
[
|
|
1742
|
-
[
|
|
671
|
+
[p]: d,
|
|
672
|
+
[u]: h
|
|
1743
673
|
};
|
|
1744
674
|
}
|
|
1745
675
|
};
|
|
1746
|
-
},
|
|
1747
|
-
return
|
|
676
|
+
}, Nn = function(t) {
|
|
677
|
+
return t === void 0 && (t = {}), {
|
|
1748
678
|
name: "size",
|
|
1749
|
-
options:
|
|
1750
|
-
async fn(
|
|
1751
|
-
var n,
|
|
679
|
+
options: t,
|
|
680
|
+
async fn(e) {
|
|
681
|
+
var n, o;
|
|
1752
682
|
const {
|
|
1753
|
-
placement:
|
|
683
|
+
placement: r,
|
|
1754
684
|
rects: i,
|
|
1755
685
|
platform: s,
|
|
1756
686
|
elements: c
|
|
1757
|
-
} =
|
|
1758
|
-
apply:
|
|
687
|
+
} = e, {
|
|
688
|
+
apply: a = () => {
|
|
1759
689
|
},
|
|
1760
690
|
...l
|
|
1761
|
-
} =
|
|
1762
|
-
width:
|
|
1763
|
-
height:
|
|
691
|
+
} = q(t, e), f = await at(e, l), u = G(r), p = ot(r), d = V(r) === "y", {
|
|
692
|
+
width: h,
|
|
693
|
+
height: m
|
|
1764
694
|
} = i.floating;
|
|
1765
|
-
let
|
|
1766
|
-
|
|
1767
|
-
const
|
|
1768
|
-
let
|
|
1769
|
-
if ((n =
|
|
1770
|
-
const
|
|
1771
|
-
|
|
695
|
+
let x, v;
|
|
696
|
+
u === "top" || u === "bottom" ? (x = u, v = p === (await (s.isRTL == null ? void 0 : s.isRTL(c.floating)) ? "start" : "end") ? "left" : "right") : (v = u, x = p === "end" ? "top" : "bottom");
|
|
697
|
+
const y = m - f.top - f.bottom, b = h - f.left - f.right, A = U(m - f[x], y), P = U(h - f[v], b), O = !e.middlewareData.shift;
|
|
698
|
+
let R = A, D = P;
|
|
699
|
+
if ((n = e.middlewareData.shift) != null && n.enabled.x && (D = b), (o = e.middlewareData.shift) != null && o.enabled.y && (R = y), O && !p) {
|
|
700
|
+
const M = H(f.left, 0), T = H(f.right, 0), N = H(f.top, 0), E = H(f.bottom, 0);
|
|
701
|
+
d ? D = h - 2 * (M !== 0 || T !== 0 ? M + T : H(f.left, f.right)) : R = m - 2 * (N !== 0 || E !== 0 ? N + E : H(f.top, f.bottom));
|
|
1772
702
|
}
|
|
1773
|
-
await
|
|
1774
|
-
...
|
|
1775
|
-
availableWidth:
|
|
1776
|
-
availableHeight:
|
|
703
|
+
await a({
|
|
704
|
+
...e,
|
|
705
|
+
availableWidth: D,
|
|
706
|
+
availableHeight: R
|
|
1777
707
|
});
|
|
1778
|
-
const
|
|
1779
|
-
return
|
|
708
|
+
const F = await s.getDimensions(c.floating);
|
|
709
|
+
return h !== F.width || m !== F.height ? {
|
|
1780
710
|
reset: {
|
|
1781
711
|
rects: !0
|
|
1782
712
|
}
|
|
@@ -1784,828 +714,828 @@ const Yo = function(e) {
|
|
|
1784
714
|
}
|
|
1785
715
|
};
|
|
1786
716
|
};
|
|
1787
|
-
function
|
|
717
|
+
function Pt() {
|
|
1788
718
|
return typeof window < "u";
|
|
1789
719
|
}
|
|
1790
|
-
function
|
|
1791
|
-
return
|
|
720
|
+
function rt(t) {
|
|
721
|
+
return se(t) ? (t.nodeName || "").toLowerCase() : "#document";
|
|
1792
722
|
}
|
|
1793
|
-
function
|
|
1794
|
-
var
|
|
1795
|
-
return (
|
|
723
|
+
function W(t) {
|
|
724
|
+
var e;
|
|
725
|
+
return (t == null || (e = t.ownerDocument) == null ? void 0 : e.defaultView) || window;
|
|
1796
726
|
}
|
|
1797
|
-
function
|
|
1798
|
-
var
|
|
1799
|
-
return (
|
|
727
|
+
function X(t) {
|
|
728
|
+
var e;
|
|
729
|
+
return (e = (se(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
|
|
1800
730
|
}
|
|
1801
|
-
function
|
|
1802
|
-
return
|
|
731
|
+
function se(t) {
|
|
732
|
+
return Pt() ? t instanceof Node || t instanceof W(t).Node : !1;
|
|
1803
733
|
}
|
|
1804
|
-
function
|
|
1805
|
-
return
|
|
734
|
+
function B(t) {
|
|
735
|
+
return Pt() ? t instanceof Element || t instanceof W(t).Element : !1;
|
|
1806
736
|
}
|
|
1807
|
-
function Y(
|
|
1808
|
-
return
|
|
737
|
+
function Y(t) {
|
|
738
|
+
return Pt() ? t instanceof HTMLElement || t instanceof W(t).HTMLElement : !1;
|
|
1809
739
|
}
|
|
1810
|
-
function
|
|
1811
|
-
return !
|
|
740
|
+
function Ut(t) {
|
|
741
|
+
return !Pt() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof W(t).ShadowRoot;
|
|
1812
742
|
}
|
|
1813
|
-
const
|
|
1814
|
-
function
|
|
743
|
+
const Fn = /* @__PURE__ */ new Set(["inline", "contents"]);
|
|
744
|
+
function ut(t) {
|
|
1815
745
|
const {
|
|
1816
|
-
overflow:
|
|
746
|
+
overflow: e,
|
|
1817
747
|
overflowX: n,
|
|
1818
|
-
overflowY:
|
|
1819
|
-
display:
|
|
1820
|
-
} =
|
|
1821
|
-
return /auto|scroll|overlay|hidden|clip/.test(
|
|
1822
|
-
}
|
|
1823
|
-
const
|
|
1824
|
-
function
|
|
1825
|
-
return
|
|
1826
|
-
}
|
|
1827
|
-
const
|
|
1828
|
-
function
|
|
1829
|
-
return
|
|
748
|
+
overflowY: o,
|
|
749
|
+
display: r
|
|
750
|
+
} = z(t);
|
|
751
|
+
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !Fn.has(r);
|
|
752
|
+
}
|
|
753
|
+
const $n = /* @__PURE__ */ new Set(["table", "td", "th"]);
|
|
754
|
+
function Hn(t) {
|
|
755
|
+
return $n.has(rt(t));
|
|
756
|
+
}
|
|
757
|
+
const Wn = [":popover-open", ":modal"];
|
|
758
|
+
function bt(t) {
|
|
759
|
+
return Wn.some((e) => {
|
|
1830
760
|
try {
|
|
1831
|
-
return
|
|
761
|
+
return t.matches(e);
|
|
1832
762
|
} catch {
|
|
1833
763
|
return !1;
|
|
1834
764
|
}
|
|
1835
765
|
});
|
|
1836
766
|
}
|
|
1837
|
-
const
|
|
1838
|
-
function
|
|
1839
|
-
const
|
|
1840
|
-
return
|
|
1841
|
-
}
|
|
1842
|
-
function
|
|
1843
|
-
let
|
|
1844
|
-
for (; Y(
|
|
1845
|
-
if (
|
|
1846
|
-
return
|
|
1847
|
-
if (
|
|
767
|
+
const Bn = ["transform", "translate", "scale", "rotate", "perspective"], zn = ["transform", "translate", "scale", "rotate", "perspective", "filter"], In = ["paint", "layout", "strict", "content"];
|
|
768
|
+
function Ft(t) {
|
|
769
|
+
const e = $t(), n = B(t) ? z(t) : t;
|
|
770
|
+
return Bn.some((o) => n[o] ? n[o] !== "none" : !1) || (n.containerType ? n.containerType !== "normal" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== "none" : !1) || !e && (n.filter ? n.filter !== "none" : !1) || zn.some((o) => (n.willChange || "").includes(o)) || In.some((o) => (n.contain || "").includes(o));
|
|
771
|
+
}
|
|
772
|
+
function Vn(t) {
|
|
773
|
+
let e = Z(t);
|
|
774
|
+
for (; Y(e) && !et(e); ) {
|
|
775
|
+
if (Ft(e))
|
|
776
|
+
return e;
|
|
777
|
+
if (bt(e))
|
|
1848
778
|
return null;
|
|
1849
|
-
|
|
779
|
+
e = Z(e);
|
|
1850
780
|
}
|
|
1851
781
|
return null;
|
|
1852
782
|
}
|
|
1853
|
-
function
|
|
783
|
+
function $t() {
|
|
1854
784
|
return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
|
|
1855
785
|
}
|
|
1856
|
-
const
|
|
1857
|
-
function
|
|
1858
|
-
return
|
|
786
|
+
const jn = /* @__PURE__ */ new Set(["html", "body", "#document"]);
|
|
787
|
+
function et(t) {
|
|
788
|
+
return jn.has(rt(t));
|
|
1859
789
|
}
|
|
1860
|
-
function
|
|
1861
|
-
return
|
|
790
|
+
function z(t) {
|
|
791
|
+
return W(t).getComputedStyle(t);
|
|
1862
792
|
}
|
|
1863
|
-
function
|
|
1864
|
-
return
|
|
1865
|
-
scrollLeft:
|
|
1866
|
-
scrollTop:
|
|
793
|
+
function Ct(t) {
|
|
794
|
+
return B(t) ? {
|
|
795
|
+
scrollLeft: t.scrollLeft,
|
|
796
|
+
scrollTop: t.scrollTop
|
|
1867
797
|
} : {
|
|
1868
|
-
scrollLeft:
|
|
1869
|
-
scrollTop:
|
|
798
|
+
scrollLeft: t.scrollX,
|
|
799
|
+
scrollTop: t.scrollY
|
|
1870
800
|
};
|
|
1871
801
|
}
|
|
1872
|
-
function
|
|
1873
|
-
if (
|
|
1874
|
-
return
|
|
1875
|
-
const
|
|
802
|
+
function Z(t) {
|
|
803
|
+
if (rt(t) === "html")
|
|
804
|
+
return t;
|
|
805
|
+
const e = (
|
|
1876
806
|
// Step into the shadow DOM of the parent of a slotted node.
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
807
|
+
t.assignedSlot || // DOM Element detected.
|
|
808
|
+
t.parentNode || // ShadowRoot detected.
|
|
809
|
+
Ut(t) && t.host || // Fallback.
|
|
810
|
+
X(t)
|
|
1881
811
|
);
|
|
1882
|
-
return
|
|
812
|
+
return Ut(e) ? e.host : e;
|
|
1883
813
|
}
|
|
1884
|
-
function
|
|
1885
|
-
const
|
|
1886
|
-
return
|
|
814
|
+
function ce(t) {
|
|
815
|
+
const e = Z(t);
|
|
816
|
+
return et(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : Y(e) && ut(e) ? e : ce(e);
|
|
1887
817
|
}
|
|
1888
|
-
function
|
|
1889
|
-
var
|
|
1890
|
-
|
|
1891
|
-
const
|
|
818
|
+
function lt(t, e, n) {
|
|
819
|
+
var o;
|
|
820
|
+
e === void 0 && (e = []), n === void 0 && (n = !0);
|
|
821
|
+
const r = ce(t), i = r === ((o = t.ownerDocument) == null ? void 0 : o.body), s = W(r);
|
|
1892
822
|
if (i) {
|
|
1893
|
-
const c =
|
|
1894
|
-
return
|
|
823
|
+
const c = Dt(s);
|
|
824
|
+
return e.concat(s, s.visualViewport || [], ut(r) ? r : [], c && n ? lt(c) : []);
|
|
1895
825
|
}
|
|
1896
|
-
return
|
|
826
|
+
return e.concat(r, lt(r, [], n));
|
|
1897
827
|
}
|
|
1898
|
-
function
|
|
1899
|
-
return
|
|
828
|
+
function Dt(t) {
|
|
829
|
+
return t.parent && Object.getPrototypeOf(t.parent) ? t.frameElement : null;
|
|
1900
830
|
}
|
|
1901
|
-
function
|
|
1902
|
-
const
|
|
1903
|
-
let n = parseFloat(
|
|
1904
|
-
const
|
|
1905
|
-
return c && (n = i,
|
|
831
|
+
function ae(t) {
|
|
832
|
+
const e = z(t);
|
|
833
|
+
let n = parseFloat(e.width) || 0, o = parseFloat(e.height) || 0;
|
|
834
|
+
const r = Y(t), i = r ? t.offsetWidth : n, s = r ? t.offsetHeight : o, c = gt(n) !== i || gt(o) !== s;
|
|
835
|
+
return c && (n = i, o = s), {
|
|
1906
836
|
width: n,
|
|
1907
|
-
height:
|
|
837
|
+
height: o,
|
|
1908
838
|
$: c
|
|
1909
839
|
};
|
|
1910
840
|
}
|
|
1911
|
-
function
|
|
1912
|
-
return
|
|
841
|
+
function Ht(t) {
|
|
842
|
+
return B(t) ? t : t.contextElement;
|
|
1913
843
|
}
|
|
1914
|
-
function
|
|
1915
|
-
const
|
|
1916
|
-
if (!Y(
|
|
844
|
+
function tt(t) {
|
|
845
|
+
const e = Ht(t);
|
|
846
|
+
if (!Y(e))
|
|
1917
847
|
return j(1);
|
|
1918
|
-
const n =
|
|
1919
|
-
width:
|
|
1920
|
-
height:
|
|
848
|
+
const n = e.getBoundingClientRect(), {
|
|
849
|
+
width: o,
|
|
850
|
+
height: r,
|
|
1921
851
|
$: i
|
|
1922
|
-
} =
|
|
1923
|
-
let s = (i ?
|
|
852
|
+
} = ae(e);
|
|
853
|
+
let s = (i ? gt(n.width) : n.width) / o, c = (i ? gt(n.height) : n.height) / r;
|
|
1924
854
|
return (!s || !Number.isFinite(s)) && (s = 1), (!c || !Number.isFinite(c)) && (c = 1), {
|
|
1925
855
|
x: s,
|
|
1926
856
|
y: c
|
|
1927
857
|
};
|
|
1928
858
|
}
|
|
1929
|
-
const
|
|
1930
|
-
function
|
|
1931
|
-
const
|
|
1932
|
-
return
|
|
1933
|
-
x:
|
|
1934
|
-
y:
|
|
859
|
+
const Yn = /* @__PURE__ */ j(0);
|
|
860
|
+
function le(t) {
|
|
861
|
+
const e = W(t);
|
|
862
|
+
return !$t() || !e.visualViewport ? Yn : {
|
|
863
|
+
x: e.visualViewport.offsetLeft,
|
|
864
|
+
y: e.visualViewport.offsetTop
|
|
1935
865
|
};
|
|
1936
866
|
}
|
|
1937
|
-
function
|
|
1938
|
-
return
|
|
867
|
+
function Xn(t, e, n) {
|
|
868
|
+
return e === void 0 && (e = !1), !n || e && n !== W(t) ? !1 : e;
|
|
1939
869
|
}
|
|
1940
|
-
function
|
|
1941
|
-
|
|
1942
|
-
const
|
|
870
|
+
function Q(t, e, n, o) {
|
|
871
|
+
e === void 0 && (e = !1), n === void 0 && (n = !1);
|
|
872
|
+
const r = t.getBoundingClientRect(), i = Ht(t);
|
|
1943
873
|
let s = j(1);
|
|
1944
|
-
|
|
1945
|
-
const c =
|
|
1946
|
-
let
|
|
874
|
+
e && (o ? B(o) && (s = tt(o)) : s = tt(t));
|
|
875
|
+
const c = Xn(i, n, o) ? le(i) : j(0);
|
|
876
|
+
let a = (r.left + c.x) / s.x, l = (r.top + c.y) / s.y, f = r.width / s.x, u = r.height / s.y;
|
|
1947
877
|
if (i) {
|
|
1948
|
-
const
|
|
1949
|
-
let
|
|
1950
|
-
for (;
|
|
1951
|
-
const
|
|
1952
|
-
|
|
878
|
+
const p = W(i), d = o && B(o) ? W(o) : o;
|
|
879
|
+
let h = p, m = Dt(h);
|
|
880
|
+
for (; m && o && d !== h; ) {
|
|
881
|
+
const x = tt(m), v = m.getBoundingClientRect(), y = z(m), b = v.left + (m.clientLeft + parseFloat(y.paddingLeft)) * x.x, A = v.top + (m.clientTop + parseFloat(y.paddingTop)) * x.y;
|
|
882
|
+
a *= x.x, l *= x.y, f *= x.x, u *= x.y, a += b, l += A, h = W(m), m = Dt(h);
|
|
1953
883
|
}
|
|
1954
884
|
}
|
|
1955
|
-
return
|
|
885
|
+
return vt({
|
|
1956
886
|
width: f,
|
|
1957
|
-
height:
|
|
1958
|
-
x:
|
|
887
|
+
height: u,
|
|
888
|
+
x: a,
|
|
1959
889
|
y: l
|
|
1960
890
|
});
|
|
1961
891
|
}
|
|
1962
|
-
function
|
|
1963
|
-
const n =
|
|
1964
|
-
return
|
|
892
|
+
function Wt(t, e) {
|
|
893
|
+
const n = Ct(t).scrollLeft;
|
|
894
|
+
return e ? e.left + n : Q(X(t)).left + n;
|
|
1965
895
|
}
|
|
1966
|
-
function
|
|
896
|
+
function fe(t, e, n) {
|
|
1967
897
|
n === void 0 && (n = !1);
|
|
1968
|
-
const
|
|
898
|
+
const o = t.getBoundingClientRect(), r = o.left + e.scrollLeft - (n ? 0 : (
|
|
1969
899
|
// RTL <body> scrollbar.
|
|
1970
|
-
|
|
1971
|
-
)), i =
|
|
900
|
+
Wt(t, o)
|
|
901
|
+
)), i = o.top + e.scrollTop;
|
|
1972
902
|
return {
|
|
1973
|
-
x:
|
|
903
|
+
x: r,
|
|
1974
904
|
y: i
|
|
1975
905
|
};
|
|
1976
906
|
}
|
|
1977
|
-
function
|
|
907
|
+
function qn(t) {
|
|
1978
908
|
let {
|
|
1979
|
-
elements:
|
|
909
|
+
elements: e,
|
|
1980
910
|
rect: n,
|
|
1981
|
-
offsetParent:
|
|
1982
|
-
strategy:
|
|
1983
|
-
} =
|
|
1984
|
-
const i =
|
|
1985
|
-
if (
|
|
911
|
+
offsetParent: o,
|
|
912
|
+
strategy: r
|
|
913
|
+
} = t;
|
|
914
|
+
const i = r === "fixed", s = X(o), c = e ? bt(e.floating) : !1;
|
|
915
|
+
if (o === s || c && i)
|
|
1986
916
|
return n;
|
|
1987
|
-
let
|
|
917
|
+
let a = {
|
|
1988
918
|
scrollLeft: 0,
|
|
1989
919
|
scrollTop: 0
|
|
1990
920
|
}, l = j(1);
|
|
1991
|
-
const f = j(0),
|
|
1992
|
-
if ((
|
|
1993
|
-
const
|
|
1994
|
-
l =
|
|
921
|
+
const f = j(0), u = Y(o);
|
|
922
|
+
if ((u || !u && !i) && ((rt(o) !== "body" || ut(s)) && (a = Ct(o)), Y(o))) {
|
|
923
|
+
const d = Q(o);
|
|
924
|
+
l = tt(o), f.x = d.x + o.clientLeft, f.y = d.y + o.clientTop;
|
|
1995
925
|
}
|
|
1996
|
-
const
|
|
926
|
+
const p = s && !u && !i ? fe(s, a, !0) : j(0);
|
|
1997
927
|
return {
|
|
1998
928
|
width: n.width * l.x,
|
|
1999
929
|
height: n.height * l.y,
|
|
2000
|
-
x: n.x * l.x -
|
|
2001
|
-
y: n.y * l.y -
|
|
930
|
+
x: n.x * l.x - a.scrollLeft * l.x + f.x + p.x,
|
|
931
|
+
y: n.y * l.y - a.scrollTop * l.y + f.y + p.y
|
|
2002
932
|
};
|
|
2003
933
|
}
|
|
2004
|
-
function
|
|
2005
|
-
return Array.from(
|
|
934
|
+
function Gn(t) {
|
|
935
|
+
return Array.from(t.getClientRects());
|
|
2006
936
|
}
|
|
2007
|
-
function
|
|
2008
|
-
const
|
|
2009
|
-
let s = -n.scrollLeft +
|
|
937
|
+
function Kn(t) {
|
|
938
|
+
const e = X(t), n = Ct(t), o = t.ownerDocument.body, r = H(e.scrollWidth, e.clientWidth, o.scrollWidth, o.clientWidth), i = H(e.scrollHeight, e.clientHeight, o.scrollHeight, o.clientHeight);
|
|
939
|
+
let s = -n.scrollLeft + Wt(t);
|
|
2010
940
|
const c = -n.scrollTop;
|
|
2011
|
-
return
|
|
2012
|
-
width:
|
|
941
|
+
return z(o).direction === "rtl" && (s += H(e.clientWidth, o.clientWidth) - r), {
|
|
942
|
+
width: r,
|
|
2013
943
|
height: i,
|
|
2014
944
|
x: s,
|
|
2015
945
|
y: c
|
|
2016
946
|
};
|
|
2017
947
|
}
|
|
2018
|
-
function
|
|
2019
|
-
const n =
|
|
2020
|
-
let i =
|
|
2021
|
-
if (
|
|
2022
|
-
i =
|
|
2023
|
-
const l =
|
|
2024
|
-
(!l || l &&
|
|
948
|
+
function Un(t, e) {
|
|
949
|
+
const n = W(t), o = X(t), r = n.visualViewport;
|
|
950
|
+
let i = o.clientWidth, s = o.clientHeight, c = 0, a = 0;
|
|
951
|
+
if (r) {
|
|
952
|
+
i = r.width, s = r.height;
|
|
953
|
+
const l = $t();
|
|
954
|
+
(!l || l && e === "fixed") && (c = r.offsetLeft, a = r.offsetTop);
|
|
2025
955
|
}
|
|
2026
956
|
return {
|
|
2027
957
|
width: i,
|
|
2028
958
|
height: s,
|
|
2029
959
|
x: c,
|
|
2030
|
-
y:
|
|
960
|
+
y: a
|
|
2031
961
|
};
|
|
2032
962
|
}
|
|
2033
|
-
const
|
|
2034
|
-
function
|
|
2035
|
-
const n =
|
|
963
|
+
const Zn = /* @__PURE__ */ new Set(["absolute", "fixed"]);
|
|
964
|
+
function Jn(t, e) {
|
|
965
|
+
const n = Q(t, !0, e === "fixed"), o = n.top + t.clientTop, r = n.left + t.clientLeft, i = Y(t) ? tt(t) : j(1), s = t.clientWidth * i.x, c = t.clientHeight * i.y, a = r * i.x, l = o * i.y;
|
|
2036
966
|
return {
|
|
2037
967
|
width: s,
|
|
2038
968
|
height: c,
|
|
2039
|
-
x:
|
|
969
|
+
x: a,
|
|
2040
970
|
y: l
|
|
2041
971
|
};
|
|
2042
972
|
}
|
|
2043
|
-
function
|
|
2044
|
-
let
|
|
2045
|
-
if (
|
|
2046
|
-
|
|
2047
|
-
else if (
|
|
2048
|
-
|
|
2049
|
-
else if (
|
|
2050
|
-
|
|
973
|
+
function Zt(t, e, n) {
|
|
974
|
+
let o;
|
|
975
|
+
if (e === "viewport")
|
|
976
|
+
o = Un(t, n);
|
|
977
|
+
else if (e === "document")
|
|
978
|
+
o = Kn(X(t));
|
|
979
|
+
else if (B(e))
|
|
980
|
+
o = Jn(e, n);
|
|
2051
981
|
else {
|
|
2052
|
-
const
|
|
2053
|
-
|
|
2054
|
-
x:
|
|
2055
|
-
y:
|
|
2056
|
-
width:
|
|
2057
|
-
height:
|
|
982
|
+
const r = le(t);
|
|
983
|
+
o = {
|
|
984
|
+
x: e.x - r.x,
|
|
985
|
+
y: e.y - r.y,
|
|
986
|
+
width: e.width,
|
|
987
|
+
height: e.height
|
|
2058
988
|
};
|
|
2059
989
|
}
|
|
2060
|
-
return
|
|
990
|
+
return vt(o);
|
|
2061
991
|
}
|
|
2062
|
-
function
|
|
2063
|
-
const n =
|
|
2064
|
-
return n ===
|
|
992
|
+
function ue(t, e) {
|
|
993
|
+
const n = Z(t);
|
|
994
|
+
return n === e || !B(n) || et(n) ? !1 : z(n).position === "fixed" || ue(n, e);
|
|
2065
995
|
}
|
|
2066
|
-
function
|
|
2067
|
-
const n =
|
|
996
|
+
function Qn(t, e) {
|
|
997
|
+
const n = e.get(t);
|
|
2068
998
|
if (n)
|
|
2069
999
|
return n;
|
|
2070
|
-
let
|
|
2071
|
-
const i =
|
|
2072
|
-
let s = i ?
|
|
2073
|
-
for (;
|
|
2074
|
-
const c =
|
|
2075
|
-
!
|
|
1000
|
+
let o = lt(t, [], !1).filter((c) => B(c) && rt(c) !== "body"), r = null;
|
|
1001
|
+
const i = z(t).position === "fixed";
|
|
1002
|
+
let s = i ? Z(t) : t;
|
|
1003
|
+
for (; B(s) && !et(s); ) {
|
|
1004
|
+
const c = z(s), a = Ft(s);
|
|
1005
|
+
!a && c.position === "fixed" && (r = null), (i ? !a && !r : !a && c.position === "static" && !!r && Zn.has(r.position) || ut(s) && !a && ue(t, s)) ? o = o.filter((f) => f !== s) : r = c, s = Z(s);
|
|
2076
1006
|
}
|
|
2077
|
-
return
|
|
1007
|
+
return e.set(t, o), o;
|
|
2078
1008
|
}
|
|
2079
|
-
function
|
|
1009
|
+
function to(t) {
|
|
2080
1010
|
let {
|
|
2081
|
-
element:
|
|
1011
|
+
element: e,
|
|
2082
1012
|
boundary: n,
|
|
2083
|
-
rootBoundary:
|
|
2084
|
-
strategy:
|
|
2085
|
-
} =
|
|
2086
|
-
const s = [...n === "clippingAncestors" ?
|
|
2087
|
-
const
|
|
2088
|
-
return l.top =
|
|
2089
|
-
},
|
|
1013
|
+
rootBoundary: o,
|
|
1014
|
+
strategy: r
|
|
1015
|
+
} = t;
|
|
1016
|
+
const s = [...n === "clippingAncestors" ? bt(e) ? [] : Qn(e, this._c) : [].concat(n), o], c = s[0], a = s.reduce((l, f) => {
|
|
1017
|
+
const u = Zt(e, f, r);
|
|
1018
|
+
return l.top = H(u.top, l.top), l.right = U(u.right, l.right), l.bottom = U(u.bottom, l.bottom), l.left = H(u.left, l.left), l;
|
|
1019
|
+
}, Zt(e, c, r));
|
|
2090
1020
|
return {
|
|
2091
|
-
width:
|
|
2092
|
-
height:
|
|
2093
|
-
x:
|
|
2094
|
-
y:
|
|
1021
|
+
width: a.right - a.left,
|
|
1022
|
+
height: a.bottom - a.top,
|
|
1023
|
+
x: a.left,
|
|
1024
|
+
y: a.top
|
|
2095
1025
|
};
|
|
2096
1026
|
}
|
|
2097
|
-
function
|
|
1027
|
+
function eo(t) {
|
|
2098
1028
|
const {
|
|
2099
|
-
width:
|
|
1029
|
+
width: e,
|
|
2100
1030
|
height: n
|
|
2101
|
-
} =
|
|
1031
|
+
} = ae(t);
|
|
2102
1032
|
return {
|
|
2103
|
-
width:
|
|
1033
|
+
width: e,
|
|
2104
1034
|
height: n
|
|
2105
1035
|
};
|
|
2106
1036
|
}
|
|
2107
|
-
function
|
|
2108
|
-
const
|
|
1037
|
+
function no(t, e, n) {
|
|
1038
|
+
const o = Y(e), r = X(e), i = n === "fixed", s = Q(t, !0, i, e);
|
|
2109
1039
|
let c = {
|
|
2110
1040
|
scrollLeft: 0,
|
|
2111
1041
|
scrollTop: 0
|
|
2112
1042
|
};
|
|
2113
|
-
const
|
|
1043
|
+
const a = j(0);
|
|
2114
1044
|
function l() {
|
|
2115
|
-
|
|
1045
|
+
a.x = Wt(r);
|
|
2116
1046
|
}
|
|
2117
|
-
if (
|
|
2118
|
-
if ((
|
|
2119
|
-
const
|
|
2120
|
-
|
|
2121
|
-
} else
|
|
2122
|
-
i && !
|
|
2123
|
-
const f =
|
|
1047
|
+
if (o || !o && !i)
|
|
1048
|
+
if ((rt(e) !== "body" || ut(r)) && (c = Ct(e)), o) {
|
|
1049
|
+
const d = Q(e, !0, i, e);
|
|
1050
|
+
a.x = d.x + e.clientLeft, a.y = d.y + e.clientTop;
|
|
1051
|
+
} else r && l();
|
|
1052
|
+
i && !o && r && l();
|
|
1053
|
+
const f = r && !o && !i ? fe(r, c) : j(0), u = s.left + c.scrollLeft - a.x - f.x, p = s.top + c.scrollTop - a.y - f.y;
|
|
2124
1054
|
return {
|
|
2125
|
-
x:
|
|
2126
|
-
y:
|
|
1055
|
+
x: u,
|
|
1056
|
+
y: p,
|
|
2127
1057
|
width: s.width,
|
|
2128
1058
|
height: s.height
|
|
2129
1059
|
};
|
|
2130
1060
|
}
|
|
2131
|
-
function
|
|
2132
|
-
return
|
|
1061
|
+
function Ot(t) {
|
|
1062
|
+
return z(t).position === "static";
|
|
2133
1063
|
}
|
|
2134
|
-
function
|
|
2135
|
-
if (!Y(
|
|
1064
|
+
function Jt(t, e) {
|
|
1065
|
+
if (!Y(t) || z(t).position === "fixed")
|
|
2136
1066
|
return null;
|
|
2137
|
-
if (
|
|
2138
|
-
return t
|
|
2139
|
-
let n =
|
|
2140
|
-
return
|
|
2141
|
-
}
|
|
2142
|
-
function
|
|
2143
|
-
const n =
|
|
2144
|
-
if (
|
|
1067
|
+
if (e)
|
|
1068
|
+
return e(t);
|
|
1069
|
+
let n = t.offsetParent;
|
|
1070
|
+
return X(t) === n && (n = n.ownerDocument.body), n;
|
|
1071
|
+
}
|
|
1072
|
+
function de(t, e) {
|
|
1073
|
+
const n = W(t);
|
|
1074
|
+
if (bt(t))
|
|
2145
1075
|
return n;
|
|
2146
|
-
if (!Y(
|
|
2147
|
-
let
|
|
2148
|
-
for (;
|
|
2149
|
-
if (
|
|
2150
|
-
return
|
|
2151
|
-
|
|
1076
|
+
if (!Y(t)) {
|
|
1077
|
+
let r = Z(t);
|
|
1078
|
+
for (; r && !et(r); ) {
|
|
1079
|
+
if (B(r) && !Ot(r))
|
|
1080
|
+
return r;
|
|
1081
|
+
r = Z(r);
|
|
2152
1082
|
}
|
|
2153
1083
|
return n;
|
|
2154
1084
|
}
|
|
2155
|
-
let
|
|
2156
|
-
for (;
|
|
2157
|
-
|
|
2158
|
-
return
|
|
1085
|
+
let o = Jt(t, e);
|
|
1086
|
+
for (; o && Hn(o) && Ot(o); )
|
|
1087
|
+
o = Jt(o, e);
|
|
1088
|
+
return o && et(o) && Ot(o) && !Ft(o) ? n : o || Vn(t) || n;
|
|
2159
1089
|
}
|
|
2160
|
-
const
|
|
2161
|
-
const
|
|
1090
|
+
const oo = async function(t) {
|
|
1091
|
+
const e = this.getOffsetParent || de, n = this.getDimensions, o = await n(t.floating);
|
|
2162
1092
|
return {
|
|
2163
|
-
reference:
|
|
1093
|
+
reference: no(t.reference, await e(t.floating), t.strategy),
|
|
2164
1094
|
floating: {
|
|
2165
1095
|
x: 0,
|
|
2166
1096
|
y: 0,
|
|
2167
|
-
width:
|
|
2168
|
-
height:
|
|
1097
|
+
width: o.width,
|
|
1098
|
+
height: o.height
|
|
2169
1099
|
}
|
|
2170
1100
|
};
|
|
2171
1101
|
};
|
|
2172
|
-
function
|
|
2173
|
-
return
|
|
2174
|
-
}
|
|
2175
|
-
const
|
|
2176
|
-
convertOffsetParentRelativeRectToViewportRelativeRect:
|
|
2177
|
-
getDocumentElement:
|
|
2178
|
-
getClippingRect:
|
|
2179
|
-
getOffsetParent:
|
|
2180
|
-
getElementRects:
|
|
2181
|
-
getClientRects:
|
|
2182
|
-
getDimensions:
|
|
2183
|
-
getScale:
|
|
2184
|
-
isElement:
|
|
2185
|
-
isRTL:
|
|
1102
|
+
function ro(t) {
|
|
1103
|
+
return z(t).direction === "rtl";
|
|
1104
|
+
}
|
|
1105
|
+
const io = {
|
|
1106
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: qn,
|
|
1107
|
+
getDocumentElement: X,
|
|
1108
|
+
getClippingRect: to,
|
|
1109
|
+
getOffsetParent: de,
|
|
1110
|
+
getElementRects: oo,
|
|
1111
|
+
getClientRects: Gn,
|
|
1112
|
+
getDimensions: eo,
|
|
1113
|
+
getScale: tt,
|
|
1114
|
+
isElement: B,
|
|
1115
|
+
isRTL: ro
|
|
2186
1116
|
};
|
|
2187
|
-
function
|
|
2188
|
-
return
|
|
1117
|
+
function pe(t, e) {
|
|
1118
|
+
return t.x === e.x && t.y === e.y && t.width === e.width && t.height === e.height;
|
|
2189
1119
|
}
|
|
2190
|
-
function
|
|
2191
|
-
let n = null,
|
|
2192
|
-
const
|
|
1120
|
+
function so(t, e) {
|
|
1121
|
+
let n = null, o;
|
|
1122
|
+
const r = X(t);
|
|
2193
1123
|
function i() {
|
|
2194
1124
|
var c;
|
|
2195
|
-
clearTimeout(
|
|
1125
|
+
clearTimeout(o), (c = n) == null || c.disconnect(), n = null;
|
|
2196
1126
|
}
|
|
2197
|
-
function s(c,
|
|
2198
|
-
c === void 0 && (c = !1),
|
|
2199
|
-
const l =
|
|
1127
|
+
function s(c, a) {
|
|
1128
|
+
c === void 0 && (c = !1), a === void 0 && (a = 1), i();
|
|
1129
|
+
const l = t.getBoundingClientRect(), {
|
|
2200
1130
|
left: f,
|
|
2201
|
-
top:
|
|
2202
|
-
width:
|
|
2203
|
-
height:
|
|
1131
|
+
top: u,
|
|
1132
|
+
width: p,
|
|
1133
|
+
height: d
|
|
2204
1134
|
} = l;
|
|
2205
|
-
if (c ||
|
|
1135
|
+
if (c || e(), !p || !d)
|
|
2206
1136
|
return;
|
|
2207
|
-
const
|
|
2208
|
-
rootMargin: -
|
|
2209
|
-
threshold:
|
|
1137
|
+
const h = ht(u), m = ht(r.clientWidth - (f + p)), x = ht(r.clientHeight - (u + d)), v = ht(f), b = {
|
|
1138
|
+
rootMargin: -h + "px " + -m + "px " + -x + "px " + -v + "px",
|
|
1139
|
+
threshold: H(0, U(1, a)) || 1
|
|
2210
1140
|
};
|
|
2211
|
-
let
|
|
2212
|
-
function
|
|
2213
|
-
const
|
|
2214
|
-
if (
|
|
2215
|
-
if (!
|
|
1141
|
+
let A = !0;
|
|
1142
|
+
function P(O) {
|
|
1143
|
+
const R = O[0].intersectionRatio;
|
|
1144
|
+
if (R !== a) {
|
|
1145
|
+
if (!A)
|
|
2216
1146
|
return s();
|
|
2217
|
-
|
|
1147
|
+
R ? s(!1, R) : o = setTimeout(() => {
|
|
2218
1148
|
s(!1, 1e-7);
|
|
2219
1149
|
}, 1e3);
|
|
2220
1150
|
}
|
|
2221
|
-
|
|
1151
|
+
R === 1 && !pe(l, t.getBoundingClientRect()) && s(), A = !1;
|
|
2222
1152
|
}
|
|
2223
1153
|
try {
|
|
2224
|
-
n = new IntersectionObserver(
|
|
2225
|
-
...
|
|
1154
|
+
n = new IntersectionObserver(P, {
|
|
1155
|
+
...b,
|
|
2226
1156
|
// Handle <iframe>s
|
|
2227
|
-
root:
|
|
1157
|
+
root: r.ownerDocument
|
|
2228
1158
|
});
|
|
2229
1159
|
} catch {
|
|
2230
|
-
n = new IntersectionObserver(
|
|
1160
|
+
n = new IntersectionObserver(P, b);
|
|
2231
1161
|
}
|
|
2232
|
-
n.observe(
|
|
1162
|
+
n.observe(t);
|
|
2233
1163
|
}
|
|
2234
1164
|
return s(!0), i;
|
|
2235
1165
|
}
|
|
2236
|
-
function
|
|
2237
|
-
|
|
1166
|
+
function co(t, e, n, o) {
|
|
1167
|
+
o === void 0 && (o = {});
|
|
2238
1168
|
const {
|
|
2239
|
-
ancestorScroll:
|
|
1169
|
+
ancestorScroll: r = !0,
|
|
2240
1170
|
ancestorResize: i = !0,
|
|
2241
1171
|
elementResize: s = typeof ResizeObserver == "function",
|
|
2242
1172
|
layoutShift: c = typeof IntersectionObserver == "function",
|
|
2243
|
-
animationFrame:
|
|
2244
|
-
} =
|
|
2245
|
-
f.forEach((
|
|
2246
|
-
|
|
1173
|
+
animationFrame: a = !1
|
|
1174
|
+
} = o, l = Ht(t), f = r || i ? [...l ? lt(l) : [], ...lt(e)] : [];
|
|
1175
|
+
f.forEach((v) => {
|
|
1176
|
+
r && v.addEventListener("scroll", n, {
|
|
2247
1177
|
passive: !0
|
|
2248
|
-
}), i &&
|
|
1178
|
+
}), i && v.addEventListener("resize", n);
|
|
2249
1179
|
});
|
|
2250
|
-
const
|
|
2251
|
-
let
|
|
2252
|
-
s && (
|
|
2253
|
-
let [
|
|
2254
|
-
|
|
2255
|
-
var
|
|
2256
|
-
(
|
|
1180
|
+
const u = l && c ? so(l, n) : null;
|
|
1181
|
+
let p = -1, d = null;
|
|
1182
|
+
s && (d = new ResizeObserver((v) => {
|
|
1183
|
+
let [y] = v;
|
|
1184
|
+
y && y.target === l && d && (d.unobserve(e), cancelAnimationFrame(p), p = requestAnimationFrame(() => {
|
|
1185
|
+
var b;
|
|
1186
|
+
(b = d) == null || b.observe(e);
|
|
2257
1187
|
})), n();
|
|
2258
|
-
}), l && !
|
|
2259
|
-
let
|
|
2260
|
-
|
|
2261
|
-
function
|
|
2262
|
-
const
|
|
2263
|
-
|
|
1188
|
+
}), l && !a && d.observe(l), d.observe(e));
|
|
1189
|
+
let h, m = a ? Q(t) : null;
|
|
1190
|
+
a && x();
|
|
1191
|
+
function x() {
|
|
1192
|
+
const v = Q(t);
|
|
1193
|
+
m && !pe(m, v) && n(), m = v, h = requestAnimationFrame(x);
|
|
2264
1194
|
}
|
|
2265
1195
|
return n(), () => {
|
|
2266
|
-
var
|
|
2267
|
-
f.forEach((
|
|
2268
|
-
|
|
2269
|
-
}),
|
|
1196
|
+
var v;
|
|
1197
|
+
f.forEach((y) => {
|
|
1198
|
+
r && y.removeEventListener("scroll", n), i && y.removeEventListener("resize", n);
|
|
1199
|
+
}), u?.(), (v = d) == null || v.disconnect(), d = null, a && cancelAnimationFrame(h);
|
|
2270
1200
|
};
|
|
2271
1201
|
}
|
|
2272
|
-
const
|
|
2273
|
-
const
|
|
2274
|
-
platform:
|
|
1202
|
+
const ao = Dn, lo = Ln, fo = kn, uo = Nn, po = _n, Qt = En, ho = Tn, mo = (t, e, n) => {
|
|
1203
|
+
const o = /* @__PURE__ */ new Map(), r = {
|
|
1204
|
+
platform: io,
|
|
2275
1205
|
...n
|
|
2276
1206
|
}, i = {
|
|
2277
|
-
...
|
|
2278
|
-
_c:
|
|
1207
|
+
...r.platform,
|
|
1208
|
+
_c: o
|
|
2279
1209
|
};
|
|
2280
|
-
return
|
|
2281
|
-
...
|
|
1210
|
+
return Sn(t, e, {
|
|
1211
|
+
...r,
|
|
2282
1212
|
platform: i
|
|
2283
1213
|
});
|
|
2284
1214
|
};
|
|
2285
|
-
var
|
|
2286
|
-
},
|
|
2287
|
-
function
|
|
2288
|
-
if (
|
|
1215
|
+
var go = typeof document < "u", wo = function() {
|
|
1216
|
+
}, mt = go ? Ke : wo;
|
|
1217
|
+
function xt(t, e) {
|
|
1218
|
+
if (t === e)
|
|
2289
1219
|
return !0;
|
|
2290
|
-
if (typeof
|
|
1220
|
+
if (typeof t != typeof e)
|
|
2291
1221
|
return !1;
|
|
2292
|
-
if (typeof
|
|
1222
|
+
if (typeof t == "function" && t.toString() === e.toString())
|
|
2293
1223
|
return !0;
|
|
2294
|
-
let n,
|
|
2295
|
-
if (
|
|
2296
|
-
if (Array.isArray(
|
|
2297
|
-
if (n =
|
|
2298
|
-
for (
|
|
2299
|
-
if (!
|
|
1224
|
+
let n, o, r;
|
|
1225
|
+
if (t && e && typeof t == "object") {
|
|
1226
|
+
if (Array.isArray(t)) {
|
|
1227
|
+
if (n = t.length, n !== e.length) return !1;
|
|
1228
|
+
for (o = n; o-- !== 0; )
|
|
1229
|
+
if (!xt(t[o], e[o]))
|
|
2300
1230
|
return !1;
|
|
2301
1231
|
return !0;
|
|
2302
1232
|
}
|
|
2303
|
-
if (
|
|
1233
|
+
if (r = Object.keys(t), n = r.length, n !== Object.keys(e).length)
|
|
2304
1234
|
return !1;
|
|
2305
|
-
for (
|
|
2306
|
-
if (!{}.hasOwnProperty.call(
|
|
1235
|
+
for (o = n; o-- !== 0; )
|
|
1236
|
+
if (!{}.hasOwnProperty.call(e, r[o]))
|
|
2307
1237
|
return !1;
|
|
2308
|
-
for (
|
|
2309
|
-
const i = o
|
|
2310
|
-
if (!(i === "_owner" &&
|
|
1238
|
+
for (o = n; o-- !== 0; ) {
|
|
1239
|
+
const i = r[o];
|
|
1240
|
+
if (!(i === "_owner" && t.$$typeof) && !xt(t[i], e[i]))
|
|
2311
1241
|
return !1;
|
|
2312
1242
|
}
|
|
2313
1243
|
return !0;
|
|
2314
1244
|
}
|
|
2315
|
-
return
|
|
1245
|
+
return t !== t && e !== e;
|
|
2316
1246
|
}
|
|
2317
|
-
function
|
|
2318
|
-
return typeof window > "u" ? 1 : (
|
|
1247
|
+
function he(t) {
|
|
1248
|
+
return typeof window > "u" ? 1 : (t.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
2319
1249
|
}
|
|
2320
|
-
function
|
|
2321
|
-
const n =
|
|
2322
|
-
return Math.round(
|
|
1250
|
+
function te(t, e) {
|
|
1251
|
+
const n = he(t);
|
|
1252
|
+
return Math.round(e * n) / n;
|
|
2323
1253
|
}
|
|
2324
|
-
function
|
|
2325
|
-
const
|
|
2326
|
-
return
|
|
2327
|
-
|
|
2328
|
-
}),
|
|
1254
|
+
function St(t) {
|
|
1255
|
+
const e = w.useRef(t);
|
|
1256
|
+
return mt(() => {
|
|
1257
|
+
e.current = t;
|
|
1258
|
+
}), e;
|
|
2329
1259
|
}
|
|
2330
|
-
function
|
|
2331
|
-
|
|
1260
|
+
function vo(t) {
|
|
1261
|
+
t === void 0 && (t = {});
|
|
2332
1262
|
const {
|
|
2333
|
-
placement:
|
|
1263
|
+
placement: e = "bottom",
|
|
2334
1264
|
strategy: n = "absolute",
|
|
2335
|
-
middleware:
|
|
2336
|
-
platform:
|
|
1265
|
+
middleware: o = [],
|
|
1266
|
+
platform: r,
|
|
2337
1267
|
elements: {
|
|
2338
1268
|
reference: i,
|
|
2339
1269
|
floating: s
|
|
2340
1270
|
} = {},
|
|
2341
1271
|
transform: c = !0,
|
|
2342
|
-
whileElementsMounted:
|
|
1272
|
+
whileElementsMounted: a,
|
|
2343
1273
|
open: l
|
|
2344
|
-
} =
|
|
1274
|
+
} = t, [f, u] = w.useState({
|
|
2345
1275
|
x: 0,
|
|
2346
1276
|
y: 0,
|
|
2347
1277
|
strategy: n,
|
|
2348
|
-
placement:
|
|
1278
|
+
placement: e,
|
|
2349
1279
|
middlewareData: {},
|
|
2350
1280
|
isPositioned: !1
|
|
2351
|
-
}), [
|
|
2352
|
-
|
|
2353
|
-
const [
|
|
2354
|
-
|
|
2355
|
-
}, []),
|
|
2356
|
-
|
|
2357
|
-
}, []),
|
|
2358
|
-
if (!
|
|
1281
|
+
}), [p, d] = w.useState(o);
|
|
1282
|
+
xt(p, o) || d(o);
|
|
1283
|
+
const [h, m] = w.useState(null), [x, v] = w.useState(null), y = w.useCallback((C) => {
|
|
1284
|
+
C !== O.current && (O.current = C, m(C));
|
|
1285
|
+
}, []), b = w.useCallback((C) => {
|
|
1286
|
+
C !== R.current && (R.current = C, v(C));
|
|
1287
|
+
}, []), A = i || h, P = s || x, O = w.useRef(null), R = w.useRef(null), D = w.useRef(f), F = a != null, M = St(a), T = St(r), N = St(l), E = w.useCallback(() => {
|
|
1288
|
+
if (!O.current || !R.current)
|
|
2359
1289
|
return;
|
|
2360
|
-
const
|
|
2361
|
-
placement:
|
|
1290
|
+
const C = {
|
|
1291
|
+
placement: e,
|
|
2362
1292
|
strategy: n,
|
|
2363
|
-
middleware:
|
|
1293
|
+
middleware: p
|
|
2364
1294
|
};
|
|
2365
|
-
|
|
2366
|
-
const
|
|
2367
|
-
...
|
|
1295
|
+
T.current && (C.platform = T.current), mo(O.current, R.current, C).then((L) => {
|
|
1296
|
+
const I = {
|
|
1297
|
+
...L,
|
|
2368
1298
|
// The floating element's position may be recomputed while it's closed
|
|
2369
1299
|
// but still mounted (such as when transitioning out). To ensure
|
|
2370
1300
|
// `isPositioned` will be `false` initially on the next open, avoid
|
|
2371
1301
|
// setting it to `true` when `open === false` (must be specified).
|
|
2372
|
-
isPositioned:
|
|
1302
|
+
isPositioned: N.current !== !1
|
|
2373
1303
|
};
|
|
2374
|
-
|
|
2375
|
-
|
|
1304
|
+
S.current && !xt(D.current, I) && (D.current = I, fn.flushSync(() => {
|
|
1305
|
+
u(I);
|
|
2376
1306
|
}));
|
|
2377
1307
|
});
|
|
2378
|
-
}, [
|
|
2379
|
-
|
|
2380
|
-
l === !1 &&
|
|
2381
|
-
...
|
|
1308
|
+
}, [p, e, n, T, N]);
|
|
1309
|
+
mt(() => {
|
|
1310
|
+
l === !1 && D.current.isPositioned && (D.current.isPositioned = !1, u((C) => ({
|
|
1311
|
+
...C,
|
|
2382
1312
|
isPositioned: !1
|
|
2383
1313
|
})));
|
|
2384
1314
|
}, [l]);
|
|
2385
|
-
const
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
}), []),
|
|
2389
|
-
if (
|
|
2390
|
-
if (
|
|
2391
|
-
return
|
|
2392
|
-
|
|
1315
|
+
const S = w.useRef(!1);
|
|
1316
|
+
mt(() => (S.current = !0, () => {
|
|
1317
|
+
S.current = !1;
|
|
1318
|
+
}), []), mt(() => {
|
|
1319
|
+
if (A && (O.current = A), P && (R.current = P), A && P) {
|
|
1320
|
+
if (M.current)
|
|
1321
|
+
return M.current(A, P, E);
|
|
1322
|
+
E();
|
|
2393
1323
|
}
|
|
2394
|
-
}, [
|
|
2395
|
-
const
|
|
2396
|
-
reference:
|
|
2397
|
-
floating:
|
|
2398
|
-
setReference:
|
|
2399
|
-
setFloating:
|
|
2400
|
-
}), [
|
|
2401
|
-
reference:
|
|
2402
|
-
floating:
|
|
2403
|
-
}), [
|
|
2404
|
-
const
|
|
1324
|
+
}, [A, P, E, M, F]);
|
|
1325
|
+
const $ = w.useMemo(() => ({
|
|
1326
|
+
reference: O,
|
|
1327
|
+
floating: R,
|
|
1328
|
+
setReference: y,
|
|
1329
|
+
setFloating: b
|
|
1330
|
+
}), [y, b]), k = w.useMemo(() => ({
|
|
1331
|
+
reference: A,
|
|
1332
|
+
floating: P
|
|
1333
|
+
}), [A, P]), _ = w.useMemo(() => {
|
|
1334
|
+
const C = {
|
|
2405
1335
|
position: n,
|
|
2406
1336
|
left: 0,
|
|
2407
1337
|
top: 0
|
|
2408
1338
|
};
|
|
2409
1339
|
if (!k.floating)
|
|
2410
|
-
return
|
|
2411
|
-
const
|
|
1340
|
+
return C;
|
|
1341
|
+
const L = te(k.floating, f.x), I = te(k.floating, f.y);
|
|
2412
1342
|
return c ? {
|
|
2413
|
-
...
|
|
2414
|
-
transform: "translate(" +
|
|
2415
|
-
...
|
|
1343
|
+
...C,
|
|
1344
|
+
transform: "translate(" + L + "px, " + I + "px)",
|
|
1345
|
+
...he(k.floating) >= 1.5 && {
|
|
2416
1346
|
willChange: "transform"
|
|
2417
1347
|
}
|
|
2418
1348
|
} : {
|
|
2419
1349
|
position: n,
|
|
2420
|
-
left:
|
|
2421
|
-
top:
|
|
1350
|
+
left: L,
|
|
1351
|
+
top: I
|
|
2422
1352
|
};
|
|
2423
1353
|
}, [n, c, k.floating, f.x, f.y]);
|
|
2424
|
-
return
|
|
1354
|
+
return w.useMemo(() => ({
|
|
2425
1355
|
...f,
|
|
2426
|
-
update:
|
|
2427
|
-
refs:
|
|
1356
|
+
update: E,
|
|
1357
|
+
refs: $,
|
|
2428
1358
|
elements: k,
|
|
2429
|
-
floatingStyles:
|
|
2430
|
-
}), [f,
|
|
1359
|
+
floatingStyles: _
|
|
1360
|
+
}), [f, E, $, k, _]);
|
|
2431
1361
|
}
|
|
2432
|
-
const
|
|
2433
|
-
function
|
|
1362
|
+
const xo = (t) => {
|
|
1363
|
+
function e(n) {
|
|
2434
1364
|
return {}.hasOwnProperty.call(n, "current");
|
|
2435
1365
|
}
|
|
2436
1366
|
return {
|
|
2437
1367
|
name: "arrow",
|
|
2438
|
-
options:
|
|
1368
|
+
options: t,
|
|
2439
1369
|
fn(n) {
|
|
2440
1370
|
const {
|
|
2441
|
-
element:
|
|
2442
|
-
padding:
|
|
2443
|
-
} = typeof
|
|
2444
|
-
return
|
|
2445
|
-
element:
|
|
2446
|
-
padding:
|
|
2447
|
-
}).fn(n) : {} :
|
|
2448
|
-
element:
|
|
2449
|
-
padding:
|
|
1371
|
+
element: o,
|
|
1372
|
+
padding: r
|
|
1373
|
+
} = typeof t == "function" ? t(n) : t;
|
|
1374
|
+
return o && e(o) ? o.current != null ? Qt({
|
|
1375
|
+
element: o.current,
|
|
1376
|
+
padding: r
|
|
1377
|
+
}).fn(n) : {} : o ? Qt({
|
|
1378
|
+
element: o,
|
|
1379
|
+
padding: r
|
|
2450
1380
|
}).fn(n) : {};
|
|
2451
1381
|
}
|
|
2452
1382
|
};
|
|
2453
|
-
},
|
|
2454
|
-
...
|
|
2455
|
-
options: [
|
|
2456
|
-
}),
|
|
2457
|
-
...
|
|
2458
|
-
options: [
|
|
2459
|
-
}),
|
|
2460
|
-
...
|
|
2461
|
-
options: [
|
|
2462
|
-
}),
|
|
2463
|
-
...
|
|
2464
|
-
options: [
|
|
2465
|
-
}),
|
|
2466
|
-
...
|
|
2467
|
-
options: [
|
|
2468
|
-
}),
|
|
2469
|
-
...
|
|
2470
|
-
options: [
|
|
2471
|
-
}),
|
|
2472
|
-
...
|
|
2473
|
-
options: [
|
|
1383
|
+
}, yo = (t, e) => ({
|
|
1384
|
+
...ao(t),
|
|
1385
|
+
options: [t, e]
|
|
1386
|
+
}), Ao = (t, e) => ({
|
|
1387
|
+
...lo(t),
|
|
1388
|
+
options: [t, e]
|
|
1389
|
+
}), Po = (t, e) => ({
|
|
1390
|
+
...ho(t),
|
|
1391
|
+
options: [t, e]
|
|
1392
|
+
}), bo = (t, e) => ({
|
|
1393
|
+
...fo(t),
|
|
1394
|
+
options: [t, e]
|
|
1395
|
+
}), Co = (t, e) => ({
|
|
1396
|
+
...uo(t),
|
|
1397
|
+
options: [t, e]
|
|
1398
|
+
}), Ro = (t, e) => ({
|
|
1399
|
+
...po(t),
|
|
1400
|
+
options: [t, e]
|
|
1401
|
+
}), Oo = (t, e) => ({
|
|
1402
|
+
...xo(t),
|
|
1403
|
+
options: [t, e]
|
|
2474
1404
|
});
|
|
2475
|
-
var
|
|
2476
|
-
const { children: n, width:
|
|
2477
|
-
return /* @__PURE__ */
|
|
2478
|
-
|
|
1405
|
+
var So = "Arrow", me = w.forwardRef((t, e) => {
|
|
1406
|
+
const { children: n, width: o = 10, height: r = 5, ...i } = t;
|
|
1407
|
+
return /* @__PURE__ */ g(
|
|
1408
|
+
ft.svg,
|
|
2479
1409
|
{
|
|
2480
1410
|
...i,
|
|
2481
|
-
ref:
|
|
2482
|
-
width:
|
|
2483
|
-
height:
|
|
1411
|
+
ref: e,
|
|
1412
|
+
width: o,
|
|
1413
|
+
height: r,
|
|
2484
1414
|
viewBox: "0 0 30 10",
|
|
2485
1415
|
preserveAspectRatio: "none",
|
|
2486
|
-
children:
|
|
1416
|
+
children: t.asChild ? n : /* @__PURE__ */ g("polygon", { points: "0,0 30,0 15,10" })
|
|
2487
1417
|
}
|
|
2488
1418
|
);
|
|
2489
1419
|
});
|
|
2490
|
-
|
|
2491
|
-
var
|
|
2492
|
-
const { __scopePopper:
|
|
2493
|
-
return /* @__PURE__ */
|
|
1420
|
+
me.displayName = So;
|
|
1421
|
+
var Eo = me, Bt = "Popper", [ge, we] = ne(Bt), [ko, ve] = ge(Bt), xe = (t) => {
|
|
1422
|
+
const { __scopePopper: e, children: n } = t, [o, r] = w.useState(null);
|
|
1423
|
+
return /* @__PURE__ */ g(ko, { scope: e, anchor: o, onAnchorChange: r, children: n });
|
|
2494
1424
|
};
|
|
2495
|
-
|
|
2496
|
-
var
|
|
2497
|
-
(
|
|
2498
|
-
const { __scopePopper: n, virtualRef:
|
|
2499
|
-
return
|
|
2500
|
-
i.onAnchorChange(
|
|
2501
|
-
}),
|
|
1425
|
+
xe.displayName = Bt;
|
|
1426
|
+
var ye = "PopperAnchor", Ae = w.forwardRef(
|
|
1427
|
+
(t, e) => {
|
|
1428
|
+
const { __scopePopper: n, virtualRef: o, ...r } = t, i = ve(ye, n), s = w.useRef(null), c = yt(e, s);
|
|
1429
|
+
return w.useEffect(() => {
|
|
1430
|
+
i.onAnchorChange(o?.current || s.current);
|
|
1431
|
+
}), o ? null : /* @__PURE__ */ g(ft.div, { ...r, ref: c });
|
|
2502
1432
|
}
|
|
2503
1433
|
);
|
|
2504
|
-
|
|
2505
|
-
var
|
|
2506
|
-
(
|
|
1434
|
+
Ae.displayName = ye;
|
|
1435
|
+
var zt = "PopperContent", [_o, Mo] = ge(zt), Pe = w.forwardRef(
|
|
1436
|
+
(t, e) => {
|
|
2507
1437
|
const {
|
|
2508
1438
|
__scopePopper: n,
|
|
2509
|
-
side:
|
|
2510
|
-
sideOffset:
|
|
1439
|
+
side: o = "bottom",
|
|
1440
|
+
sideOffset: r = 0,
|
|
2511
1441
|
align: i = "center",
|
|
2512
1442
|
alignOffset: s = 0,
|
|
2513
1443
|
arrowPadding: c = 0,
|
|
2514
|
-
avoidCollisions:
|
|
1444
|
+
avoidCollisions: a = !0,
|
|
2515
1445
|
collisionBoundary: l = [],
|
|
2516
1446
|
collisionPadding: f = 0,
|
|
2517
|
-
sticky:
|
|
2518
|
-
hideWhenDetached:
|
|
2519
|
-
updatePositionStrategy:
|
|
2520
|
-
onPlaced:
|
|
2521
|
-
...
|
|
2522
|
-
} =
|
|
2523
|
-
padding:
|
|
2524
|
-
boundary:
|
|
1447
|
+
sticky: u = "partial",
|
|
1448
|
+
hideWhenDetached: p = !1,
|
|
1449
|
+
updatePositionStrategy: d = "optimized",
|
|
1450
|
+
onPlaced: h,
|
|
1451
|
+
...m
|
|
1452
|
+
} = t, x = ve(zt, n), [v, y] = w.useState(null), b = yt(e, (it) => y(it)), [A, P] = w.useState(null), O = mn(A), R = O?.width ?? 0, D = O?.height ?? 0, F = o + (i !== "center" ? "-" + i : ""), M = typeof f == "number" ? f : { top: 0, right: 0, bottom: 0, left: 0, ...f }, T = Array.isArray(l) ? l : [l], N = T.length > 0, E = {
|
|
1453
|
+
padding: M,
|
|
1454
|
+
boundary: T.filter(Lo),
|
|
2525
1455
|
// with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
|
|
2526
|
-
altBoundary:
|
|
2527
|
-
}, { refs:
|
|
1456
|
+
altBoundary: N
|
|
1457
|
+
}, { refs: S, floatingStyles: $, placement: k, isPositioned: _, middlewareData: C } = vo({
|
|
2528
1458
|
// default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
|
|
2529
1459
|
strategy: "fixed",
|
|
2530
|
-
placement:
|
|
2531
|
-
whileElementsMounted: (...
|
|
2532
|
-
animationFrame:
|
|
1460
|
+
placement: F,
|
|
1461
|
+
whileElementsMounted: (...it) => co(...it, {
|
|
1462
|
+
animationFrame: d === "always"
|
|
2533
1463
|
}),
|
|
2534
1464
|
elements: {
|
|
2535
|
-
reference:
|
|
1465
|
+
reference: x.anchor
|
|
2536
1466
|
},
|
|
2537
1467
|
middleware: [
|
|
2538
|
-
|
|
2539
|
-
|
|
1468
|
+
yo({ mainAxis: r + D, alignmentAxis: s }),
|
|
1469
|
+
a && Ao({
|
|
2540
1470
|
mainAxis: !0,
|
|
2541
1471
|
crossAxis: !1,
|
|
2542
|
-
limiter:
|
|
2543
|
-
...
|
|
1472
|
+
limiter: u === "partial" ? Po() : void 0,
|
|
1473
|
+
...E
|
|
2544
1474
|
}),
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
...
|
|
2548
|
-
apply: ({ elements:
|
|
2549
|
-
const { width:
|
|
2550
|
-
|
|
1475
|
+
a && bo({ ...E }),
|
|
1476
|
+
Co({
|
|
1477
|
+
...E,
|
|
1478
|
+
apply: ({ elements: it, rects: jt, availableWidth: Ve, availableHeight: je }) => {
|
|
1479
|
+
const { width: Ye, height: Xe } = jt.reference, pt = it.floating.style;
|
|
1480
|
+
pt.setProperty("--radix-popper-available-width", `${Ve}px`), pt.setProperty("--radix-popper-available-height", `${je}px`), pt.setProperty("--radix-popper-anchor-width", `${Ye}px`), pt.setProperty("--radix-popper-anchor-height", `${Xe}px`);
|
|
2551
1481
|
}
|
|
2552
1482
|
}),
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
1483
|
+
A && Oo({ element: A, padding: c }),
|
|
1484
|
+
To({ arrowWidth: R, arrowHeight: D }),
|
|
1485
|
+
p && Ro({ strategy: "referenceHidden", ...E })
|
|
2556
1486
|
]
|
|
2557
|
-
}), [
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
}, [
|
|
2561
|
-
const
|
|
2562
|
-
return
|
|
2563
|
-
|
|
2564
|
-
}, [
|
|
1487
|
+
}), [L, I] = Re(k), Vt = Ue(h);
|
|
1488
|
+
kt(() => {
|
|
1489
|
+
_ && Vt?.();
|
|
1490
|
+
}, [_, Vt]);
|
|
1491
|
+
const He = C.arrow?.x, We = C.arrow?.y, Be = C.arrow?.centerOffset !== 0, [ze, Ie] = w.useState();
|
|
1492
|
+
return kt(() => {
|
|
1493
|
+
v && Ie(window.getComputedStyle(v).zIndex);
|
|
1494
|
+
}, [v]), /* @__PURE__ */ g(
|
|
2565
1495
|
"div",
|
|
2566
1496
|
{
|
|
2567
|
-
ref:
|
|
1497
|
+
ref: S.setFloating,
|
|
2568
1498
|
"data-radix-popper-content-wrapper": "",
|
|
2569
1499
|
style: {
|
|
2570
|
-
|
|
2571
|
-
transform:
|
|
1500
|
+
...$,
|
|
1501
|
+
transform: _ ? $.transform : "translate(0, -200%)",
|
|
2572
1502
|
// keep off the page when measuring
|
|
2573
1503
|
minWidth: "max-content",
|
|
2574
|
-
zIndex:
|
|
1504
|
+
zIndex: ze,
|
|
2575
1505
|
"--radix-popper-transform-origin": [
|
|
2576
|
-
|
|
2577
|
-
|
|
1506
|
+
C.transformOrigin?.x,
|
|
1507
|
+
C.transformOrigin?.y
|
|
2578
1508
|
].join(" "),
|
|
2579
1509
|
// hide the content if using the hide middleware and should be hidden
|
|
2580
1510
|
// set visibility to hidden and disable pointer events so the UI behaves
|
|
2581
1511
|
// as if the PopperContent isn't there at all
|
|
2582
|
-
...
|
|
1512
|
+
...C.hide?.referenceHidden && {
|
|
2583
1513
|
visibility: "hidden",
|
|
2584
1514
|
pointerEvents: "none"
|
|
2585
1515
|
}
|
|
2586
1516
|
},
|
|
2587
|
-
dir:
|
|
2588
|
-
children: /* @__PURE__ */
|
|
2589
|
-
|
|
1517
|
+
dir: t.dir,
|
|
1518
|
+
children: /* @__PURE__ */ g(
|
|
1519
|
+
_o,
|
|
2590
1520
|
{
|
|
2591
1521
|
scope: n,
|
|
2592
|
-
placedSide:
|
|
2593
|
-
onArrowChange:
|
|
2594
|
-
arrowX:
|
|
2595
|
-
arrowY:
|
|
2596
|
-
shouldHideArrow:
|
|
2597
|
-
children: /* @__PURE__ */
|
|
2598
|
-
|
|
1522
|
+
placedSide: L,
|
|
1523
|
+
onArrowChange: P,
|
|
1524
|
+
arrowX: He,
|
|
1525
|
+
arrowY: We,
|
|
1526
|
+
shouldHideArrow: Be,
|
|
1527
|
+
children: /* @__PURE__ */ g(
|
|
1528
|
+
ft.div,
|
|
2599
1529
|
{
|
|
2600
|
-
"data-side":
|
|
2601
|
-
"data-align":
|
|
2602
|
-
...
|
|
2603
|
-
ref:
|
|
1530
|
+
"data-side": L,
|
|
1531
|
+
"data-align": I,
|
|
1532
|
+
...m,
|
|
1533
|
+
ref: b,
|
|
2604
1534
|
style: {
|
|
2605
|
-
...
|
|
1535
|
+
...m.style,
|
|
2606
1536
|
// if the PopperContent hasn't been placed yet (not all measurements done)
|
|
2607
1537
|
// we prevent animations so that users's animation don't kick in too early referring wrong sides
|
|
2608
|
-
animation:
|
|
1538
|
+
animation: _ ? void 0 : "none"
|
|
2609
1539
|
}
|
|
2610
1540
|
}
|
|
2611
1541
|
)
|
|
@@ -2615,19 +1545,19 @@ var dt = "PopperContent", [zi, Ui] = yn(dt), Pn = a.forwardRef(
|
|
|
2615
1545
|
);
|
|
2616
1546
|
}
|
|
2617
1547
|
);
|
|
2618
|
-
|
|
2619
|
-
var
|
|
1548
|
+
Pe.displayName = zt;
|
|
1549
|
+
var be = "PopperArrow", Do = {
|
|
2620
1550
|
top: "bottom",
|
|
2621
1551
|
right: "left",
|
|
2622
1552
|
bottom: "top",
|
|
2623
1553
|
left: "right"
|
|
2624
|
-
},
|
|
2625
|
-
const { __scopePopper:
|
|
1554
|
+
}, Ce = w.forwardRef(function(e, n) {
|
|
1555
|
+
const { __scopePopper: o, ...r } = e, i = Mo(be, o), s = Do[i.placedSide];
|
|
2626
1556
|
return (
|
|
2627
1557
|
// we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)
|
|
2628
1558
|
// doesn't report size as we'd expect on SVG elements.
|
|
2629
1559
|
// it reports their bounding box which is effectively the largest path inside the SVG.
|
|
2630
|
-
/* @__PURE__ */
|
|
1560
|
+
/* @__PURE__ */ g(
|
|
2631
1561
|
"span",
|
|
2632
1562
|
{
|
|
2633
1563
|
ref: i.onArrowChange,
|
|
@@ -2650,13 +1580,13 @@ var Sn = "PopperArrow", ji = {
|
|
|
2650
1580
|
}[i.placedSide],
|
|
2651
1581
|
visibility: i.shouldHideArrow ? "hidden" : void 0
|
|
2652
1582
|
},
|
|
2653
|
-
children: /* @__PURE__ */
|
|
2654
|
-
|
|
1583
|
+
children: /* @__PURE__ */ g(
|
|
1584
|
+
Eo,
|
|
2655
1585
|
{
|
|
2656
|
-
...
|
|
1586
|
+
...r,
|
|
2657
1587
|
ref: n,
|
|
2658
1588
|
style: {
|
|
2659
|
-
...
|
|
1589
|
+
...r.style,
|
|
2660
1590
|
// ensures the element can be measured correctly (mostly for if SVG)
|
|
2661
1591
|
display: "block"
|
|
2662
1592
|
}
|
|
@@ -2666,193 +1596,193 @@ var Sn = "PopperArrow", ji = {
|
|
|
2666
1596
|
)
|
|
2667
1597
|
);
|
|
2668
1598
|
});
|
|
2669
|
-
|
|
2670
|
-
function
|
|
2671
|
-
return
|
|
1599
|
+
Ce.displayName = be;
|
|
1600
|
+
function Lo(t) {
|
|
1601
|
+
return t !== null;
|
|
2672
1602
|
}
|
|
2673
|
-
var
|
|
1603
|
+
var To = (t) => ({
|
|
2674
1604
|
name: "transformOrigin",
|
|
2675
|
-
options:
|
|
2676
|
-
fn(
|
|
2677
|
-
const { placement: n, rects:
|
|
2678
|
-
let
|
|
2679
|
-
return l === "bottom" ? (
|
|
1605
|
+
options: t,
|
|
1606
|
+
fn(e) {
|
|
1607
|
+
const { placement: n, rects: o, middlewareData: r } = e, s = r.arrow?.centerOffset !== 0, c = s ? 0 : t.arrowWidth, a = s ? 0 : t.arrowHeight, [l, f] = Re(n), u = { start: "0%", center: "50%", end: "100%" }[f], p = (r.arrow?.x ?? 0) + c / 2, d = (r.arrow?.y ?? 0) + a / 2;
|
|
1608
|
+
let h = "", m = "";
|
|
1609
|
+
return l === "bottom" ? (h = s ? u : `${p}px`, m = `${-a}px`) : l === "top" ? (h = s ? u : `${p}px`, m = `${o.floating.height + a}px`) : l === "right" ? (h = `${-a}px`, m = s ? u : `${d}px`) : l === "left" && (h = `${o.floating.width + a}px`, m = s ? u : `${d}px`), { data: { x: h, y: m } };
|
|
2680
1610
|
}
|
|
2681
1611
|
});
|
|
2682
|
-
function
|
|
2683
|
-
const [
|
|
2684
|
-
return [
|
|
1612
|
+
function Re(t) {
|
|
1613
|
+
const [e, n = "center"] = t.split("-");
|
|
1614
|
+
return [e, n];
|
|
2685
1615
|
}
|
|
2686
|
-
var
|
|
2687
|
-
|
|
2688
|
-
]),
|
|
1616
|
+
var No = xe, Oe = Ae, Fo = Pe, $o = Ce, Rt = "Popover", [Se, fr] = ne(Rt, [
|
|
1617
|
+
we
|
|
1618
|
+
]), dt = we(), [Ho, J] = Se(Rt), Ee = (t) => {
|
|
2689
1619
|
const {
|
|
2690
|
-
__scopePopover:
|
|
1620
|
+
__scopePopover: e,
|
|
2691
1621
|
children: n,
|
|
2692
|
-
open:
|
|
2693
|
-
defaultOpen:
|
|
1622
|
+
open: o,
|
|
1623
|
+
defaultOpen: r,
|
|
2694
1624
|
onOpenChange: i,
|
|
2695
1625
|
modal: s = !1
|
|
2696
|
-
} =
|
|
2697
|
-
prop:
|
|
2698
|
-
defaultProp:
|
|
1626
|
+
} = t, c = dt(e), a = w.useRef(null), [l, f] = w.useState(!1), [u, p] = Ze({
|
|
1627
|
+
prop: o,
|
|
1628
|
+
defaultProp: r ?? !1,
|
|
2699
1629
|
onChange: i,
|
|
2700
|
-
caller:
|
|
1630
|
+
caller: Rt
|
|
2701
1631
|
});
|
|
2702
|
-
return /* @__PURE__ */
|
|
2703
|
-
|
|
1632
|
+
return /* @__PURE__ */ g(No, { ...c, children: /* @__PURE__ */ g(
|
|
1633
|
+
Ho,
|
|
2704
1634
|
{
|
|
2705
|
-
scope:
|
|
2706
|
-
contentId:
|
|
2707
|
-
triggerRef:
|
|
2708
|
-
open:
|
|
2709
|
-
onOpenChange:
|
|
2710
|
-
onOpenToggle:
|
|
1635
|
+
scope: e,
|
|
1636
|
+
contentId: Je(),
|
|
1637
|
+
triggerRef: a,
|
|
1638
|
+
open: u,
|
|
1639
|
+
onOpenChange: p,
|
|
1640
|
+
onOpenToggle: w.useCallback(() => p((d) => !d), [p]),
|
|
2711
1641
|
hasCustomAnchor: l,
|
|
2712
|
-
onCustomAnchorAdd:
|
|
2713
|
-
onCustomAnchorRemove:
|
|
1642
|
+
onCustomAnchorAdd: w.useCallback(() => f(!0), []),
|
|
1643
|
+
onCustomAnchorRemove: w.useCallback(() => f(!1), []),
|
|
2714
1644
|
modal: s,
|
|
2715
1645
|
children: n
|
|
2716
1646
|
}
|
|
2717
1647
|
) });
|
|
2718
1648
|
};
|
|
2719
|
-
|
|
2720
|
-
var
|
|
2721
|
-
(
|
|
2722
|
-
const { __scopePopover: n, ...
|
|
2723
|
-
return
|
|
1649
|
+
Ee.displayName = Rt;
|
|
1650
|
+
var ke = "PopoverAnchor", _e = w.forwardRef(
|
|
1651
|
+
(t, e) => {
|
|
1652
|
+
const { __scopePopover: n, ...o } = t, r = J(ke, n), i = dt(n), { onCustomAnchorAdd: s, onCustomAnchorRemove: c } = r;
|
|
1653
|
+
return w.useEffect(() => (s(), () => c()), [s, c]), /* @__PURE__ */ g(Oe, { ...i, ...o, ref: e });
|
|
2724
1654
|
}
|
|
2725
1655
|
);
|
|
2726
|
-
|
|
2727
|
-
var
|
|
2728
|
-
(
|
|
2729
|
-
const { __scopePopover: n, ...
|
|
2730
|
-
|
|
1656
|
+
_e.displayName = ke;
|
|
1657
|
+
var Me = "PopoverTrigger", De = w.forwardRef(
|
|
1658
|
+
(t, e) => {
|
|
1659
|
+
const { __scopePopover: n, ...o } = t, r = J(Me, n), i = dt(n), s = yt(e, r.triggerRef), c = /* @__PURE__ */ g(
|
|
1660
|
+
ft.button,
|
|
2731
1661
|
{
|
|
2732
1662
|
type: "button",
|
|
2733
1663
|
"aria-haspopup": "dialog",
|
|
2734
|
-
"aria-expanded":
|
|
2735
|
-
"aria-controls":
|
|
2736
|
-
"data-state":
|
|
2737
|
-
...
|
|
1664
|
+
"aria-expanded": r.open,
|
|
1665
|
+
"aria-controls": r.contentId,
|
|
1666
|
+
"data-state": $e(r.open),
|
|
1667
|
+
...o,
|
|
2738
1668
|
ref: s,
|
|
2739
|
-
onClick:
|
|
1669
|
+
onClick: st(t.onClick, r.onOpenToggle)
|
|
2740
1670
|
}
|
|
2741
1671
|
);
|
|
2742
|
-
return
|
|
1672
|
+
return r.hasCustomAnchor ? c : /* @__PURE__ */ g(Oe, { asChild: !0, ...i, children: c });
|
|
2743
1673
|
}
|
|
2744
1674
|
);
|
|
2745
|
-
|
|
2746
|
-
var
|
|
1675
|
+
De.displayName = Me;
|
|
1676
|
+
var It = "PopoverPortal", [Wo, Bo] = Se(It, {
|
|
2747
1677
|
forceMount: void 0
|
|
2748
|
-
}),
|
|
2749
|
-
const { __scopePopover:
|
|
2750
|
-
return /* @__PURE__ */
|
|
1678
|
+
}), Le = (t) => {
|
|
1679
|
+
const { __scopePopover: e, forceMount: n, children: o, container: r } = t, i = J(It, e);
|
|
1680
|
+
return /* @__PURE__ */ g(Wo, { scope: e, forceMount: n, children: /* @__PURE__ */ g(oe, { present: n || i.open, children: /* @__PURE__ */ g(Qe, { asChild: !0, container: r, children: o }) }) });
|
|
2751
1681
|
};
|
|
2752
|
-
|
|
2753
|
-
var
|
|
2754
|
-
(
|
|
2755
|
-
const n =
|
|
2756
|
-
return /* @__PURE__ */
|
|
1682
|
+
Le.displayName = It;
|
|
1683
|
+
var nt = "PopoverContent", Te = w.forwardRef(
|
|
1684
|
+
(t, e) => {
|
|
1685
|
+
const n = Bo(nt, t.__scopePopover), { forceMount: o = n.forceMount, ...r } = t, i = J(nt, t.__scopePopover);
|
|
1686
|
+
return /* @__PURE__ */ g(oe, { present: o || i.open, children: i.modal ? /* @__PURE__ */ g(Io, { ...r, ref: e }) : /* @__PURE__ */ g(Vo, { ...r, ref: e }) });
|
|
2757
1687
|
}
|
|
2758
1688
|
);
|
|
2759
|
-
|
|
2760
|
-
var
|
|
2761
|
-
(
|
|
2762
|
-
const n =
|
|
2763
|
-
return
|
|
2764
|
-
const s =
|
|
2765
|
-
if (s) return
|
|
2766
|
-
}, []), /* @__PURE__ */
|
|
2767
|
-
|
|
1689
|
+
Te.displayName = nt;
|
|
1690
|
+
var zo = nn("PopoverContent.RemoveScroll"), Io = w.forwardRef(
|
|
1691
|
+
(t, e) => {
|
|
1692
|
+
const n = J(nt, t.__scopePopover), o = w.useRef(null), r = yt(e, o), i = w.useRef(!1);
|
|
1693
|
+
return w.useEffect(() => {
|
|
1694
|
+
const s = o.current;
|
|
1695
|
+
if (s) return tn(s);
|
|
1696
|
+
}, []), /* @__PURE__ */ g(en, { as: zo, allowPinchZoom: !0, children: /* @__PURE__ */ g(
|
|
1697
|
+
Ne,
|
|
2768
1698
|
{
|
|
2769
|
-
...
|
|
2770
|
-
ref:
|
|
1699
|
+
...t,
|
|
1700
|
+
ref: r,
|
|
2771
1701
|
trapFocus: n.open,
|
|
2772
1702
|
disableOutsidePointerEvents: !0,
|
|
2773
|
-
onCloseAutoFocus:
|
|
1703
|
+
onCloseAutoFocus: st(t.onCloseAutoFocus, (s) => {
|
|
2774
1704
|
s.preventDefault(), i.current || n.triggerRef.current?.focus();
|
|
2775
1705
|
}),
|
|
2776
|
-
onPointerDownOutside:
|
|
2777
|
-
|
|
1706
|
+
onPointerDownOutside: st(
|
|
1707
|
+
t.onPointerDownOutside,
|
|
2778
1708
|
(s) => {
|
|
2779
|
-
const c = s.detail.originalEvent,
|
|
1709
|
+
const c = s.detail.originalEvent, a = c.button === 0 && c.ctrlKey === !0, l = c.button === 2 || a;
|
|
2780
1710
|
i.current = l;
|
|
2781
1711
|
},
|
|
2782
1712
|
{ checkForDefaultPrevented: !1 }
|
|
2783
1713
|
),
|
|
2784
|
-
onFocusOutside:
|
|
2785
|
-
|
|
1714
|
+
onFocusOutside: st(
|
|
1715
|
+
t.onFocusOutside,
|
|
2786
1716
|
(s) => s.preventDefault(),
|
|
2787
1717
|
{ checkForDefaultPrevented: !1 }
|
|
2788
1718
|
)
|
|
2789
1719
|
}
|
|
2790
1720
|
) });
|
|
2791
1721
|
}
|
|
2792
|
-
),
|
|
2793
|
-
(
|
|
2794
|
-
const n =
|
|
2795
|
-
return /* @__PURE__ */
|
|
2796
|
-
|
|
1722
|
+
), Vo = w.forwardRef(
|
|
1723
|
+
(t, e) => {
|
|
1724
|
+
const n = J(nt, t.__scopePopover), o = w.useRef(!1), r = w.useRef(!1);
|
|
1725
|
+
return /* @__PURE__ */ g(
|
|
1726
|
+
Ne,
|
|
2797
1727
|
{
|
|
2798
|
-
...
|
|
2799
|
-
ref:
|
|
1728
|
+
...t,
|
|
1729
|
+
ref: e,
|
|
2800
1730
|
trapFocus: !1,
|
|
2801
1731
|
disableOutsidePointerEvents: !1,
|
|
2802
1732
|
onCloseAutoFocus: (i) => {
|
|
2803
|
-
|
|
1733
|
+
t.onCloseAutoFocus?.(i), i.defaultPrevented || (o.current || n.triggerRef.current?.focus(), i.preventDefault()), o.current = !1, r.current = !1;
|
|
2804
1734
|
},
|
|
2805
1735
|
onInteractOutside: (i) => {
|
|
2806
|
-
|
|
1736
|
+
t.onInteractOutside?.(i), i.defaultPrevented || (o.current = !0, i.detail.originalEvent.type === "pointerdown" && (r.current = !0));
|
|
2807
1737
|
const s = i.target;
|
|
2808
|
-
n.triggerRef.current?.contains(s) && i.preventDefault(), i.detail.originalEvent.type === "focusin" &&
|
|
1738
|
+
n.triggerRef.current?.contains(s) && i.preventDefault(), i.detail.originalEvent.type === "focusin" && r.current && i.preventDefault();
|
|
2809
1739
|
}
|
|
2810
1740
|
}
|
|
2811
1741
|
);
|
|
2812
1742
|
}
|
|
2813
|
-
),
|
|
2814
|
-
(
|
|
1743
|
+
), Ne = w.forwardRef(
|
|
1744
|
+
(t, e) => {
|
|
2815
1745
|
const {
|
|
2816
1746
|
__scopePopover: n,
|
|
2817
|
-
trapFocus:
|
|
2818
|
-
onOpenAutoFocus:
|
|
1747
|
+
trapFocus: o,
|
|
1748
|
+
onOpenAutoFocus: r,
|
|
2819
1749
|
onCloseAutoFocus: i,
|
|
2820
1750
|
disableOutsidePointerEvents: s,
|
|
2821
1751
|
onEscapeKeyDown: c,
|
|
2822
|
-
onPointerDownOutside:
|
|
1752
|
+
onPointerDownOutside: a,
|
|
2823
1753
|
onFocusOutside: l,
|
|
2824
1754
|
onInteractOutside: f,
|
|
2825
|
-
...
|
|
2826
|
-
} =
|
|
2827
|
-
return
|
|
2828
|
-
|
|
1755
|
+
...u
|
|
1756
|
+
} = t, p = J(nt, n), d = dt(n);
|
|
1757
|
+
return on(), /* @__PURE__ */ g(
|
|
1758
|
+
rn,
|
|
2829
1759
|
{
|
|
2830
1760
|
asChild: !0,
|
|
2831
1761
|
loop: !0,
|
|
2832
|
-
trapped:
|
|
2833
|
-
onMountAutoFocus:
|
|
1762
|
+
trapped: o,
|
|
1763
|
+
onMountAutoFocus: r,
|
|
2834
1764
|
onUnmountAutoFocus: i,
|
|
2835
|
-
children: /* @__PURE__ */
|
|
2836
|
-
|
|
1765
|
+
children: /* @__PURE__ */ g(
|
|
1766
|
+
sn,
|
|
2837
1767
|
{
|
|
2838
1768
|
asChild: !0,
|
|
2839
1769
|
disableOutsidePointerEvents: s,
|
|
2840
1770
|
onInteractOutside: f,
|
|
2841
1771
|
onEscapeKeyDown: c,
|
|
2842
|
-
onPointerDownOutside:
|
|
1772
|
+
onPointerDownOutside: a,
|
|
2843
1773
|
onFocusOutside: l,
|
|
2844
|
-
onDismiss: () =>
|
|
2845
|
-
children: /* @__PURE__ */
|
|
2846
|
-
|
|
1774
|
+
onDismiss: () => p.onOpenChange(!1),
|
|
1775
|
+
children: /* @__PURE__ */ g(
|
|
1776
|
+
Fo,
|
|
2847
1777
|
{
|
|
2848
|
-
"data-state":
|
|
1778
|
+
"data-state": $e(p.open),
|
|
2849
1779
|
role: "dialog",
|
|
2850
|
-
id:
|
|
2851
|
-
...h,
|
|
1780
|
+
id: p.contentId,
|
|
2852
1781
|
...d,
|
|
2853
|
-
|
|
1782
|
+
...u,
|
|
1783
|
+
ref: e,
|
|
2854
1784
|
style: {
|
|
2855
|
-
...
|
|
1785
|
+
...u.style,
|
|
2856
1786
|
"--radix-popover-content-transform-origin": "var(--radix-popper-transform-origin)",
|
|
2857
1787
|
"--radix-popover-content-available-width": "var(--radix-popper-available-width)",
|
|
2858
1788
|
"--radix-popover-content-available-height": "var(--radix-popper-available-height)",
|
|
@@ -2866,108 +1796,108 @@ var es = /* @__PURE__ */ Vt("PopoverContent.RemoveScroll"), ts = a.forwardRef(
|
|
|
2866
1796
|
}
|
|
2867
1797
|
);
|
|
2868
1798
|
}
|
|
2869
|
-
),
|
|
2870
|
-
(
|
|
2871
|
-
const { __scopePopover: n, ...
|
|
2872
|
-
return /* @__PURE__ */
|
|
2873
|
-
|
|
1799
|
+
), Fe = "PopoverClose", jo = w.forwardRef(
|
|
1800
|
+
(t, e) => {
|
|
1801
|
+
const { __scopePopover: n, ...o } = t, r = J(Fe, n);
|
|
1802
|
+
return /* @__PURE__ */ g(
|
|
1803
|
+
ft.button,
|
|
2874
1804
|
{
|
|
2875
1805
|
type: "button",
|
|
2876
|
-
...
|
|
2877
|
-
ref:
|
|
2878
|
-
onClick:
|
|
1806
|
+
...o,
|
|
1807
|
+
ref: e,
|
|
1808
|
+
onClick: st(t.onClick, () => r.onOpenChange(!1))
|
|
2879
1809
|
}
|
|
2880
1810
|
);
|
|
2881
1811
|
}
|
|
2882
1812
|
);
|
|
2883
|
-
|
|
2884
|
-
var
|
|
2885
|
-
(
|
|
2886
|
-
const { __scopePopover: n, ...
|
|
2887
|
-
return /* @__PURE__ */
|
|
1813
|
+
jo.displayName = Fe;
|
|
1814
|
+
var Yo = "PopoverArrow", Xo = w.forwardRef(
|
|
1815
|
+
(t, e) => {
|
|
1816
|
+
const { __scopePopover: n, ...o } = t, r = dt(n);
|
|
1817
|
+
return /* @__PURE__ */ g($o, { ...r, ...o, ref: e });
|
|
2888
1818
|
}
|
|
2889
1819
|
);
|
|
2890
|
-
|
|
2891
|
-
function
|
|
2892
|
-
return
|
|
2893
|
-
}
|
|
2894
|
-
var
|
|
2895
|
-
const
|
|
2896
|
-
anchor:
|
|
2897
|
-
container:
|
|
2898
|
-
radio:
|
|
2899
|
-
check:
|
|
2900
|
-
radioInput:
|
|
1820
|
+
Xo.displayName = Yo;
|
|
1821
|
+
function $e(t) {
|
|
1822
|
+
return t ? "open" : "closed";
|
|
1823
|
+
}
|
|
1824
|
+
var qo = Ee, Go = _e, Ko = De, Uo = Le, Zo = Te;
|
|
1825
|
+
const Jo = "_anchor_vbdag_270", Qo = "_container_vbdag_275", tr = "_radio_vbdag_292", er = "_check_vbdag_304", nr = "_radioInput_vbdag_312", ct = {
|
|
1826
|
+
anchor: Jo,
|
|
1827
|
+
container: Qo,
|
|
1828
|
+
radio: tr,
|
|
1829
|
+
check: er,
|
|
1830
|
+
radioInput: nr
|
|
2901
1831
|
};
|
|
2902
|
-
function
|
|
2903
|
-
return /* @__PURE__ */
|
|
2904
|
-
/* @__PURE__ */
|
|
1832
|
+
function Et({ children: t, id: e, ...n }) {
|
|
1833
|
+
return /* @__PURE__ */ K(ee, { children: [
|
|
1834
|
+
/* @__PURE__ */ g(
|
|
2905
1835
|
"input",
|
|
2906
1836
|
{
|
|
2907
1837
|
type: "radio",
|
|
2908
|
-
id:
|
|
2909
|
-
className:
|
|
1838
|
+
id: e,
|
|
1839
|
+
className: an(ct.radioInput, "sr-only"),
|
|
2910
1840
|
...n
|
|
2911
1841
|
}
|
|
2912
1842
|
),
|
|
2913
|
-
/* @__PURE__ */
|
|
2914
|
-
|
|
2915
|
-
/* @__PURE__ */
|
|
1843
|
+
/* @__PURE__ */ K("label", { htmlFor: e, className: ct.radio, children: [
|
|
1844
|
+
t,
|
|
1845
|
+
/* @__PURE__ */ g(cn, { className: ct.check })
|
|
2916
1846
|
] })
|
|
2917
1847
|
] });
|
|
2918
1848
|
}
|
|
2919
|
-
function
|
|
2920
|
-
const { theme:
|
|
2921
|
-
return /* @__PURE__ */
|
|
2922
|
-
/* @__PURE__ */
|
|
2923
|
-
/* @__PURE__ */
|
|
2924
|
-
/* @__PURE__ */
|
|
1849
|
+
function ur() {
|
|
1850
|
+
const { theme: t, systemTheme: e, setTheme: n } = qe(), o = Ge();
|
|
1851
|
+
return /* @__PURE__ */ K(qo, { children: [
|
|
1852
|
+
/* @__PURE__ */ g(Ko, { asChild: !0, children: /* @__PURE__ */ K(ln, { variant: "transparent", "aria-label": "Preferences", children: [
|
|
1853
|
+
/* @__PURE__ */ g(pn, {}),
|
|
1854
|
+
/* @__PURE__ */ g(Go, { className: ct.anchor })
|
|
2925
1855
|
] }) }),
|
|
2926
|
-
/* @__PURE__ */
|
|
2927
|
-
|
|
1856
|
+
/* @__PURE__ */ g(Uo, { children: /* @__PURE__ */ g(
|
|
1857
|
+
Zo,
|
|
2928
1858
|
{
|
|
2929
1859
|
sideOffset: 8,
|
|
2930
1860
|
hideWhenDetached: !0,
|
|
2931
|
-
className:
|
|
2932
|
-
children:
|
|
2933
|
-
/* @__PURE__ */
|
|
2934
|
-
/* @__PURE__ */
|
|
2935
|
-
|
|
1861
|
+
className: ct.container,
|
|
1862
|
+
children: o && /* @__PURE__ */ K(ee, { children: [
|
|
1863
|
+
/* @__PURE__ */ g("span", { children: "Appearance" }),
|
|
1864
|
+
/* @__PURE__ */ K(
|
|
1865
|
+
Et,
|
|
2936
1866
|
{
|
|
2937
1867
|
id: "system",
|
|
2938
1868
|
name: "theme",
|
|
2939
|
-
checked:
|
|
1869
|
+
checked: t === "system",
|
|
2940
1870
|
onChange: () => n("system"),
|
|
2941
1871
|
children: [
|
|
2942
|
-
/* @__PURE__ */
|
|
1872
|
+
/* @__PURE__ */ g(un, {}),
|
|
2943
1873
|
"Auto (",
|
|
2944
|
-
|
|
1874
|
+
e,
|
|
2945
1875
|
")"
|
|
2946
1876
|
]
|
|
2947
1877
|
}
|
|
2948
1878
|
),
|
|
2949
|
-
/* @__PURE__ */
|
|
2950
|
-
|
|
1879
|
+
/* @__PURE__ */ K(
|
|
1880
|
+
Et,
|
|
2951
1881
|
{
|
|
2952
1882
|
id: "light",
|
|
2953
1883
|
name: "theme",
|
|
2954
|
-
checked:
|
|
1884
|
+
checked: t === "light",
|
|
2955
1885
|
onChange: () => n("light"),
|
|
2956
1886
|
children: [
|
|
2957
|
-
/* @__PURE__ */
|
|
1887
|
+
/* @__PURE__ */ g(hn, {}),
|
|
2958
1888
|
"Light"
|
|
2959
1889
|
]
|
|
2960
1890
|
}
|
|
2961
1891
|
),
|
|
2962
|
-
/* @__PURE__ */
|
|
2963
|
-
|
|
1892
|
+
/* @__PURE__ */ K(
|
|
1893
|
+
Et,
|
|
2964
1894
|
{
|
|
2965
1895
|
id: "dark",
|
|
2966
1896
|
name: "theme",
|
|
2967
|
-
checked:
|
|
1897
|
+
checked: t === "dark",
|
|
2968
1898
|
onChange: () => n("dark"),
|
|
2969
1899
|
children: [
|
|
2970
|
-
/* @__PURE__ */
|
|
1900
|
+
/* @__PURE__ */ g(dn, {}),
|
|
2971
1901
|
"Dark"
|
|
2972
1902
|
]
|
|
2973
1903
|
}
|
|
@@ -2978,6 +1908,6 @@ function Ss() {
|
|
|
2978
1908
|
] });
|
|
2979
1909
|
}
|
|
2980
1910
|
export {
|
|
2981
|
-
|
|
2982
|
-
|
|
1911
|
+
ur as PrefPanel,
|
|
1912
|
+
Et as PrefRadio
|
|
2983
1913
|
};
|