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