@codeandfunction/callaloo 3.16.1 → 3.16.3
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/README.md +5 -3
- package/dist/assets/CLFormCharCounter.css +1 -1
- package/dist/assets/CLInputMessages.css +1 -1
- package/dist/assets/core.css +1 -0
- package/dist/assets/shared/form-utilities.css +1 -0
- package/dist/chunks/{CLA11yButton.vue_vue_type_style_index_0_lang-Cdx5rsou.js → CLA11yButton.vue_vue_type_style_index_0_lang-Caaw-9_c.js} +1 -1
- package/dist/chunks/{CLButton.vue_vue_type_style_index_0_lang-CrhjC50b.js → CLButton.vue_vue_type_style_index_0_lang-N3EWoTbB.js} +4 -4
- package/dist/chunks/{CLCard.vue_vue_type_style_index_0_lang-DVuAcV5A.js → CLCard.vue_vue_type_style_index_0_lang-CpReGucs.js} +6 -6
- package/dist/chunks/{CLFormLabel.vue_vue_type_script_setup_true_lang-fddy-FWI.js → CLFormLabel.vue_vue_type_script_setup_true_lang-Cw3nPc64.js} +1 -1
- package/dist/chunks/{CLHeading.vue_vue_type_style_index_0_lang-DILwNSgn.js → CLHeading.vue_vue_type_style_index_0_lang-BcCh5-Bx.js} +1 -1
- package/dist/chunks/{CLIcon.vue_vue_type_style_index_0_lang-CZB8svPf.js → CLIcon.vue_vue_type_style_index_0_lang-BaCl5yQI.js} +23 -22
- package/dist/chunks/{CLInputMessages.vue_vue_type_style_index_0_lang-RMOT1TQk.js → CLInputMessages.vue_vue_type_style_index_0_lang-BNGT0om7.js} +12 -11
- package/dist/chunks/{CLLink.vue_vue_type_style_index_0_lang-BUgw8Rpy.js → CLLink.vue_vue_type_style_index_0_lang-BMUevw_4.js} +12 -11
- package/dist/chunks/{CLNavLink.vue_vue_type_script_setup_true_lang-Ckz9MEj5.js → CLNavLink.vue_vue_type_script_setup_true_lang-D2oCLUGX.js} +1 -1
- package/dist/chunks/{CLPill.vue_vue_type_style_index_0_lang-mkIKVHjg.js → CLPill.vue_vue_type_style_index_0_lang-DYXrV-YE.js} +3 -3
- package/dist/chunks/{CLProgress.vue_vue_type_style_index_0_lang-CSf7WiNb.js → CLProgress.vue_vue_type_style_index_0_lang-Cu3FhEX0.js} +2 -2
- package/dist/chunks/{CLSkeleton.vue_vue_type_style_index_0_lang-E-bZeUWT.js → CLSkeleton.vue_vue_type_style_index_0_lang-DblqrUXo.js} +1 -1
- package/dist/chunks/{CLSpinner.vue_vue_type_style_index_0_lang-C8s8K4zb.js → CLSpinner.vue_vue_type_style_index_0_lang-DskZL4VC.js} +1 -1
- package/dist/chunks/{CLText.vue_vue_type_style_index_0_lang-V7LSR7DF.js → CLText.vue_vue_type_style_index_0_lang-Cz9Sv2AC.js} +1 -1
- package/dist/chunks/{CLToast.vue_vue_type_style_index_0_lang-DOI4DZGg.js → CLToast.vue_vue_type_style_index_0_lang-CYcPXUMQ.js} +24 -23
- package/dist/chunks/base-theme-Bg6XMoeN.js +275 -0
- package/dist/chunks/helper--hRjZVm6.js +62 -0
- package/dist/chunks/utils-Bp7YeySh.js +29 -0
- package/dist/chunks/utils-C9rOAW29.js +387 -0
- package/dist/chunks/{utils-C7Yjsqk-.js → utils-D-5TdmRW.js} +10 -9
- package/dist/chunks/{utils-D_WP3vZz.js → utils-DRsWhcFX.js} +13 -12
- package/dist/chunks/{utils-DFnkOeYP.js → utils-DVR3a-_d.js} +26 -25
- package/dist/chunks/utils-nC7WS9e0.js +15 -0
- package/dist/components/Buttons/CLA11yButton/CLA11yButton.css +1 -1
- package/dist/components/Buttons/CLA11yButton/CLA11yButton.js +2 -1
- package/dist/components/Buttons/CLButton/CLButton.css +1 -1
- package/dist/components/Buttons/CLButton/CLButton.js +2 -1
- package/dist/components/Buttons/CLButton/CLButton.vue.d.ts +3 -3
- package/dist/components/CLIcon/CLIcon.css +1 -1
- package/dist/components/CLIcon/CLIcon.js +2 -1
- package/dist/components/CLTable/CLTable.css +1 -1
- package/dist/components/CLTable/CLTable.js +31 -29
- package/dist/components/Containers/CLCard/CLCard.css +1 -1
- package/dist/components/Containers/CLCard/CLCard.js +2 -1
- package/dist/components/Containers/CLCard/CLCard.vue.d.ts +2 -2
- package/dist/components/Containers/CLCarousel/CLCarousel.css +1 -1
- package/dist/components/Containers/CLCarousel/CLCarousel.js +17 -16
- package/dist/components/Containers/CLCarousel/CLCarousel.vue.d.ts +1 -1
- package/dist/components/Containers/CLDisclosure/CLDisclosure.css +1 -1
- package/dist/components/Containers/CLDisclosure/CLDisclosure.js +7 -6
- package/dist/components/Form/CLCheckbox/CLCheckbox.css +1 -1
- package/dist/components/Form/CLCheckbox/CLCheckbox.js +5 -3
- package/dist/components/Form/CLCheckbox/CLCheckbox.vue.d.ts +2 -2
- package/dist/components/Form/CLInput/CLInput.css +1 -1
- package/dist/components/Form/CLInput/CLInput.js +7 -5
- package/dist/components/Form/CLInput/CLInput.vue.d.ts +2 -2
- package/dist/components/Form/CLRadioButton/CLRadioButton.css +1 -1
- package/dist/components/Form/CLRadioButton/CLRadioButton.js +4 -2
- package/dist/components/Form/CLRadioButton/CLRadioButton.vue.d.ts +1 -1
- package/dist/components/Form/CLSelect/CLSelect.css +1 -1
- package/dist/components/Form/CLSelect/CLSelect.js +5 -3
- package/dist/components/Form/CLSelect/CLSelect.vue.d.ts +1 -1
- package/dist/components/Form/CLTextArea/CLTextArea.css +1 -1
- package/dist/components/Form/CLTextArea/CLTextArea.js +4 -2
- package/dist/components/Form/CLTextArea/CLTextArea.vue.d.ts +1 -1
- package/dist/components/Indicators/CLBadge/CLBadge.css +1 -1
- package/dist/components/Indicators/CLBadge/CLBadge.js +2 -1
- package/dist/components/Indicators/CLBanner/CLBanner.css +1 -1
- package/dist/components/Indicators/CLBanner/CLBanner.js +7 -6
- package/dist/components/Indicators/CLBanner/CLBanner.vue.d.ts +2 -2
- package/dist/components/Indicators/CLPill/CLPill.css +1 -1
- package/dist/components/Indicators/CLPill/CLPill.js +2 -1
- package/dist/components/Indicators/CLProgress/CLProgress.css +1 -1
- package/dist/components/Indicators/CLProgress/CLProgress.js +2 -1
- package/dist/components/Loading/CLSkeleton/CLSkeleton.css +1 -1
- package/dist/components/Loading/CLSkeleton/CLSkeleton.js +2 -1
- package/dist/components/Loading/CLSkeleton/CLSkeleton.vue.d.ts +2 -2
- package/dist/components/Loading/CLSpinner/CLSpinner.css +1 -1
- package/dist/components/Loading/CLSpinner/CLSpinner.js +2 -1
- package/dist/components/Modals/CLModal/CLModal.css +1 -1
- package/dist/components/Modals/CLModal/CLModal.js +17 -15
- package/dist/components/Navigation/CLLink/CLLink.css +1 -1
- package/dist/components/Navigation/CLLink/CLLink.js +2 -1
- package/dist/components/Navigation/CLNavLink/CLNavLink.js +2 -1
- package/dist/components/Navigation/CLNavSection/CLNavSection.css +1 -1
- package/dist/components/Navigation/CLNavSection/CLNavSection.js +3 -2
- package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.css +1 -1
- package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.js +510 -551
- package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.vue.d.ts +7 -7
- package/dist/components/Popups/CLToast/CLToast.css +1 -1
- package/dist/components/Popups/CLToast/CLToast.js +2 -1
- package/dist/components/Popups/CLToast/CLToast.vue.d.ts +1 -1
- package/dist/components/Providers/CLThemeProvider/CLThemeProvider.js +20 -17
- package/dist/components/Providers/CLToastProvider/CLToastProvider.js +2 -1
- package/dist/components/Typography/CLHeading/CLHeading.css +1 -1
- package/dist/components/Typography/CLHeading/CLHeading.js +2 -1
- package/dist/components/Typography/CLText/CLText.css +1 -1
- package/dist/components/Typography/CLText/CLText.js +2 -1
- package/dist/composables/index.d.ts +2 -0
- package/dist/composables/useDropdown.js +50 -0
- package/dist/{chunks/useEsc-C9QIDZ_8.js → composables/useEsc.js} +3 -2
- package/dist/{chunks/useHasSlotContent-DDqs5uK9.js → composables/useHasSlotContent.js} +3 -2
- package/dist/composables/useTheme.js +31 -0
- package/dist/composables/useToast.js +15 -0
- package/dist/index.js +1 -0
- package/dist/utils/merge.d.ts +18 -0
- package/package.json +32 -30
- package/dist/chunks/base-theme-C9_Hz5HW.js +0 -832
- package/dist/chunks/useTheme-yoEfuNvB.js +0 -417
- package/dist/chunks/utils-DTWXs4YX.js +0 -14
- package/dist/chunks/utils-Da9LXXQ0.js +0 -28
|
@@ -1,11 +1,13 @@
|
|
|
1
|
+
import '../../../assets/core.css';
|
|
1
2
|
import './CLDropdownMenu.css';
|
|
2
|
-
import { computed as V, ref as
|
|
3
|
-
import { _ as ue } from "../../../chunks/CLButton.vue_vue_type_style_index_0_lang-
|
|
4
|
-
import { _ as de } from "../../../chunks/CLCard.vue_vue_type_style_index_0_lang-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
|
|
3
|
+
import { computed as V, ref as E, shallowRef as te, watch as ut, getCurrentScope as ee, onScopeDispose as ne, shallowReadonly as q, unref as A, defineComponent as oe, useCssVars as ie, onBeforeUnmount as re, createElementBlock as Rt, openBlock as At, normalizeClass as dt, createVNode as Ot, createCommentVNode as le, withCtx as Et, createTextVNode as se, toDisplayString as ce, normalizeStyle as ae, renderSlot as fe } from "vue";
|
|
4
|
+
import { _ as ue } from "../../../chunks/CLButton.vue_vue_type_style_index_0_lang-N3EWoTbB.js";
|
|
5
|
+
import { _ as de } from "../../../chunks/CLCard.vue_vue_type_style_index_0_lang-CpReGucs.js";
|
|
6
|
+
import { b as me, i as mt } from "../../../chunks/helper--hRjZVm6.js";
|
|
7
|
+
import { useDropdown as he } from "../../../composables/useDropdown.js";
|
|
8
|
+
import { useEsc as ge } from "../../../composables/useEsc.js";
|
|
9
|
+
import { CLPlacement as pe, CLIconSizes as Lt, CLIconNames as we, CLColorVariants as Dt, CLSizes as ye, CLColors as Tt } from "../../../index.js";
|
|
10
|
+
const tt = Math.min, I = Math.max, et = Math.round, Q = Math.floor, B = (t) => ({
|
|
9
11
|
x: t,
|
|
10
12
|
y: t
|
|
11
13
|
}), ve = {
|
|
@@ -13,20 +15,20 @@ const et = Math.min, N = Math.max, nt = Math.round, tt = Math.floor, k = (t) =>
|
|
|
13
15
|
right: "left",
|
|
14
16
|
bottom: "top",
|
|
15
17
|
top: "bottom"
|
|
16
|
-
},
|
|
18
|
+
}, xe = {
|
|
17
19
|
start: "end",
|
|
18
20
|
end: "start"
|
|
19
21
|
};
|
|
20
|
-
function
|
|
21
|
-
return
|
|
22
|
+
function Bt(t, e, n) {
|
|
23
|
+
return I(t, tt(e, n));
|
|
22
24
|
}
|
|
23
|
-
function
|
|
25
|
+
function it(t, e) {
|
|
24
26
|
return typeof t == "function" ? t(e) : t;
|
|
25
27
|
}
|
|
26
|
-
function
|
|
28
|
+
function N(t) {
|
|
27
29
|
return t.split("-")[0];
|
|
28
30
|
}
|
|
29
|
-
function
|
|
31
|
+
function rt(t) {
|
|
30
32
|
return t.split("-")[1];
|
|
31
33
|
}
|
|
32
34
|
function It(t) {
|
|
@@ -35,48 +37,48 @@ function It(t) {
|
|
|
35
37
|
function Nt(t) {
|
|
36
38
|
return t === "y" ? "height" : "width";
|
|
37
39
|
}
|
|
38
|
-
const
|
|
39
|
-
function
|
|
40
|
-
return
|
|
40
|
+
const be = /* @__PURE__ */ new Set(["top", "bottom"]);
|
|
41
|
+
function F(t) {
|
|
42
|
+
return be.has(N(t)) ? "y" : "x";
|
|
41
43
|
}
|
|
42
44
|
function Xt(t) {
|
|
43
|
-
return It(
|
|
45
|
+
return It(F(t));
|
|
44
46
|
}
|
|
45
|
-
function
|
|
47
|
+
function Ce(t, e, n) {
|
|
46
48
|
n === void 0 && (n = !1);
|
|
47
|
-
const o =
|
|
49
|
+
const o = rt(t), i = Xt(t), l = Nt(i);
|
|
48
50
|
let r = i === "x" ? o === (n ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
|
|
49
|
-
return e.reference[
|
|
51
|
+
return e.reference[l] > e.floating[l] && (r = nt(r)), [r, nt(r)];
|
|
50
52
|
}
|
|
51
|
-
function
|
|
52
|
-
const e =
|
|
53
|
-
return [
|
|
53
|
+
function Se(t) {
|
|
54
|
+
const e = nt(t);
|
|
55
|
+
return [gt(t), e, gt(e)];
|
|
54
56
|
}
|
|
55
|
-
function
|
|
56
|
-
return t.replace(/start|end/g, (e) =>
|
|
57
|
+
function gt(t) {
|
|
58
|
+
return t.replace(/start|end/g, (e) => xe[e]);
|
|
57
59
|
}
|
|
58
|
-
const
|
|
59
|
-
function
|
|
60
|
+
const Pt = ["left", "right"], kt = ["right", "left"], Re = ["top", "bottom"], Ae = ["bottom", "top"];
|
|
61
|
+
function Oe(t, e, n) {
|
|
60
62
|
switch (t) {
|
|
61
63
|
case "top":
|
|
62
64
|
case "bottom":
|
|
63
|
-
return n ? e ?
|
|
65
|
+
return n ? e ? kt : Pt : e ? Pt : kt;
|
|
64
66
|
case "left":
|
|
65
67
|
case "right":
|
|
66
|
-
return e ?
|
|
68
|
+
return e ? Re : Ae;
|
|
67
69
|
default:
|
|
68
70
|
return [];
|
|
69
71
|
}
|
|
70
72
|
}
|
|
71
|
-
function
|
|
72
|
-
const i =
|
|
73
|
-
let
|
|
74
|
-
return i && (
|
|
73
|
+
function Ee(t, e, n, o) {
|
|
74
|
+
const i = rt(t);
|
|
75
|
+
let l = Oe(N(t), n === "start", o);
|
|
76
|
+
return i && (l = l.map((r) => r + "-" + i), e && (l = l.concat(l.map(gt)))), l;
|
|
75
77
|
}
|
|
76
|
-
function
|
|
78
|
+
function nt(t) {
|
|
77
79
|
return t.replace(/left|right|bottom|top/g, (e) => ve[e]);
|
|
78
80
|
}
|
|
79
|
-
function
|
|
81
|
+
function Le(t) {
|
|
80
82
|
return {
|
|
81
83
|
top: 0,
|
|
82
84
|
right: 0,
|
|
@@ -85,15 +87,15 @@ function Ae(t) {
|
|
|
85
87
|
...t
|
|
86
88
|
};
|
|
87
89
|
}
|
|
88
|
-
function
|
|
89
|
-
return typeof t != "number" ?
|
|
90
|
+
function De(t) {
|
|
91
|
+
return typeof t != "number" ? Le(t) : {
|
|
90
92
|
top: t,
|
|
91
93
|
right: t,
|
|
92
94
|
bottom: t,
|
|
93
95
|
left: t
|
|
94
96
|
};
|
|
95
97
|
}
|
|
96
|
-
function
|
|
98
|
+
function ot(t) {
|
|
97
99
|
const {
|
|
98
100
|
x: e,
|
|
99
101
|
y: n,
|
|
@@ -116,31 +118,31 @@ function Vt(t, e, n) {
|
|
|
116
118
|
reference: o,
|
|
117
119
|
floating: i
|
|
118
120
|
} = t;
|
|
119
|
-
const
|
|
121
|
+
const l = F(e), r = Xt(e), s = Nt(r), c = N(e), a = l === "y", f = o.x + o.width / 2 - i.width / 2, u = o.y + o.height / 2 - i.height / 2, m = o[s] / 2 - i[s] / 2;
|
|
120
122
|
let d;
|
|
121
|
-
switch (
|
|
123
|
+
switch (c) {
|
|
122
124
|
case "top":
|
|
123
125
|
d = {
|
|
124
|
-
x:
|
|
126
|
+
x: f,
|
|
125
127
|
y: o.y - i.height
|
|
126
128
|
};
|
|
127
129
|
break;
|
|
128
130
|
case "bottom":
|
|
129
131
|
d = {
|
|
130
|
-
x:
|
|
132
|
+
x: f,
|
|
131
133
|
y: o.y + o.height
|
|
132
134
|
};
|
|
133
135
|
break;
|
|
134
136
|
case "right":
|
|
135
137
|
d = {
|
|
136
138
|
x: o.x + o.width,
|
|
137
|
-
y:
|
|
139
|
+
y: u
|
|
138
140
|
};
|
|
139
141
|
break;
|
|
140
142
|
case "left":
|
|
141
143
|
d = {
|
|
142
144
|
x: o.x - i.width,
|
|
143
|
-
y:
|
|
145
|
+
y: u
|
|
144
146
|
};
|
|
145
147
|
break;
|
|
146
148
|
default:
|
|
@@ -149,7 +151,7 @@ function Vt(t, e, n) {
|
|
|
149
151
|
y: o.y
|
|
150
152
|
};
|
|
151
153
|
}
|
|
152
|
-
switch (
|
|
154
|
+
switch (rt(e)) {
|
|
153
155
|
case "start":
|
|
154
156
|
d[r] -= m * (n && a ? -1 : 1);
|
|
155
157
|
break;
|
|
@@ -159,33 +161,33 @@ function Vt(t, e, n) {
|
|
|
159
161
|
}
|
|
160
162
|
return d;
|
|
161
163
|
}
|
|
162
|
-
const
|
|
164
|
+
const Te = async (t, e, n) => {
|
|
163
165
|
const {
|
|
164
166
|
placement: o = "bottom",
|
|
165
167
|
strategy: i = "absolute",
|
|
166
|
-
middleware:
|
|
168
|
+
middleware: l = [],
|
|
167
169
|
platform: r
|
|
168
|
-
} = n,
|
|
170
|
+
} = n, s = l.filter(Boolean), c = await (r.isRTL == null ? void 0 : r.isRTL(e));
|
|
169
171
|
let a = await r.getElementRects({
|
|
170
172
|
reference: t,
|
|
171
173
|
floating: e,
|
|
172
174
|
strategy: i
|
|
173
175
|
}), {
|
|
174
|
-
x:
|
|
175
|
-
y:
|
|
176
|
-
} = Vt(a, o,
|
|
177
|
-
for (let
|
|
176
|
+
x: f,
|
|
177
|
+
y: u
|
|
178
|
+
} = Vt(a, o, c), m = o, d = {}, h = 0;
|
|
179
|
+
for (let y = 0; y < s.length; y++) {
|
|
178
180
|
const {
|
|
179
|
-
name:
|
|
180
|
-
fn:
|
|
181
|
-
} =
|
|
182
|
-
x:
|
|
181
|
+
name: v,
|
|
182
|
+
fn: g
|
|
183
|
+
} = s[y], {
|
|
184
|
+
x: w,
|
|
183
185
|
y: x,
|
|
184
186
|
data: C,
|
|
185
187
|
reset: b
|
|
186
|
-
} = await
|
|
187
|
-
x:
|
|
188
|
-
y:
|
|
188
|
+
} = await g({
|
|
189
|
+
x: f,
|
|
190
|
+
y: u,
|
|
189
191
|
initialPlacement: o,
|
|
190
192
|
placement: m,
|
|
191
193
|
strategy: i,
|
|
@@ -197,10 +199,10 @@ const De = async (t, e, n) => {
|
|
|
197
199
|
floating: e
|
|
198
200
|
}
|
|
199
201
|
});
|
|
200
|
-
|
|
202
|
+
f = w ?? f, u = x ?? u, d = {
|
|
201
203
|
...d,
|
|
202
|
-
[
|
|
203
|
-
...d[
|
|
204
|
+
[v]: {
|
|
205
|
+
...d[v],
|
|
204
206
|
...C
|
|
205
207
|
}
|
|
206
208
|
}, b && h <= 50 && (h++, typeof b == "object" && (b.placement && (m = b.placement), b.rects && (a = b.rects === !0 ? await r.getElementRects({
|
|
@@ -208,13 +210,13 @@ const De = async (t, e, n) => {
|
|
|
208
210
|
floating: e,
|
|
209
211
|
strategy: i
|
|
210
212
|
}) : b.rects), {
|
|
211
|
-
x:
|
|
212
|
-
y:
|
|
213
|
-
} = Vt(a, m,
|
|
213
|
+
x: f,
|
|
214
|
+
y: u
|
|
215
|
+
} = Vt(a, m, c)), y = -1);
|
|
214
216
|
}
|
|
215
217
|
return {
|
|
216
|
-
x:
|
|
217
|
-
y:
|
|
218
|
+
x: f,
|
|
219
|
+
y: u,
|
|
218
220
|
placement: m,
|
|
219
221
|
strategy: i,
|
|
220
222
|
middlewareData: d
|
|
@@ -226,46 +228,46 @@ async function jt(t, e) {
|
|
|
226
228
|
const {
|
|
227
229
|
x: o,
|
|
228
230
|
y: i,
|
|
229
|
-
platform:
|
|
231
|
+
platform: l,
|
|
230
232
|
rects: r,
|
|
231
|
-
elements:
|
|
232
|
-
strategy:
|
|
233
|
+
elements: s,
|
|
234
|
+
strategy: c
|
|
233
235
|
} = t, {
|
|
234
236
|
boundary: a = "clippingAncestors",
|
|
235
|
-
rootBoundary:
|
|
236
|
-
elementContext:
|
|
237
|
+
rootBoundary: f = "viewport",
|
|
238
|
+
elementContext: u = "floating",
|
|
237
239
|
altBoundary: m = !1,
|
|
238
240
|
padding: d = 0
|
|
239
|
-
} =
|
|
240
|
-
element: (n = await (
|
|
241
|
+
} = it(e, t), h = De(d), v = s[m ? u === "floating" ? "reference" : "floating" : u], g = ot(await l.getClippingRect({
|
|
242
|
+
element: (n = await (l.isElement == null ? void 0 : l.isElement(v))) == null || n ? v : v.contextElement || await (l.getDocumentElement == null ? void 0 : l.getDocumentElement(s.floating)),
|
|
241
243
|
boundary: a,
|
|
242
|
-
rootBoundary:
|
|
243
|
-
strategy:
|
|
244
|
-
})),
|
|
244
|
+
rootBoundary: f,
|
|
245
|
+
strategy: c
|
|
246
|
+
})), w = u === "floating" ? {
|
|
245
247
|
x: o,
|
|
246
248
|
y: i,
|
|
247
249
|
width: r.floating.width,
|
|
248
250
|
height: r.floating.height
|
|
249
|
-
} : r.reference, x = await (
|
|
251
|
+
} : r.reference, x = await (l.getOffsetParent == null ? void 0 : l.getOffsetParent(s.floating)), C = await (l.isElement == null ? void 0 : l.isElement(x)) ? await (l.getScale == null ? void 0 : l.getScale(x)) || {
|
|
250
252
|
x: 1,
|
|
251
253
|
y: 1
|
|
252
254
|
} : {
|
|
253
255
|
x: 1,
|
|
254
256
|
y: 1
|
|
255
|
-
}, b =
|
|
256
|
-
elements:
|
|
257
|
-
rect:
|
|
257
|
+
}, b = ot(l.convertOffsetParentRelativeRectToViewportRelativeRect ? await l.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
258
|
+
elements: s,
|
|
259
|
+
rect: w,
|
|
258
260
|
offsetParent: x,
|
|
259
|
-
strategy:
|
|
260
|
-
}) :
|
|
261
|
+
strategy: c
|
|
262
|
+
}) : w);
|
|
261
263
|
return {
|
|
262
|
-
top: (
|
|
263
|
-
bottom: (b.bottom -
|
|
264
|
-
left: (
|
|
265
|
-
right: (b.right -
|
|
264
|
+
top: (g.top - b.top + h.top) / C.y,
|
|
265
|
+
bottom: (b.bottom - g.bottom + h.bottom) / C.y,
|
|
266
|
+
left: (g.left - b.left + h.left) / C.x,
|
|
267
|
+
right: (b.right - g.right + h.right) / C.x
|
|
266
268
|
};
|
|
267
269
|
}
|
|
268
|
-
const
|
|
270
|
+
const Be = function(t) {
|
|
269
271
|
return t === void 0 && (t = {}), {
|
|
270
272
|
name: "flip",
|
|
271
273
|
options: t,
|
|
@@ -273,108 +275,108 @@ const Te = function(t) {
|
|
|
273
275
|
var n, o;
|
|
274
276
|
const {
|
|
275
277
|
placement: i,
|
|
276
|
-
middlewareData:
|
|
278
|
+
middlewareData: l,
|
|
277
279
|
rects: r,
|
|
278
|
-
initialPlacement:
|
|
279
|
-
platform:
|
|
280
|
+
initialPlacement: s,
|
|
281
|
+
platform: c,
|
|
280
282
|
elements: a
|
|
281
283
|
} = e, {
|
|
282
|
-
mainAxis:
|
|
283
|
-
crossAxis:
|
|
284
|
+
mainAxis: f = !0,
|
|
285
|
+
crossAxis: u = !0,
|
|
284
286
|
fallbackPlacements: m,
|
|
285
287
|
fallbackStrategy: d = "bestFit",
|
|
286
288
|
fallbackAxisSideDirection: h = "none",
|
|
287
|
-
flipAlignment:
|
|
288
|
-
...
|
|
289
|
-
} =
|
|
290
|
-
if ((n =
|
|
289
|
+
flipAlignment: y = !0,
|
|
290
|
+
...v
|
|
291
|
+
} = it(t, e);
|
|
292
|
+
if ((n = l.arrow) != null && n.alignmentOffset)
|
|
291
293
|
return {};
|
|
292
|
-
const
|
|
293
|
-
!m && T && b.push(...
|
|
294
|
-
const
|
|
295
|
-
let
|
|
296
|
-
if (
|
|
297
|
-
const
|
|
298
|
-
|
|
294
|
+
const g = N(i), w = F(s), x = N(s) === s, C = await (c.isRTL == null ? void 0 : c.isRTL(a.floating)), b = m || (x || !y ? [nt(s)] : Se(s)), T = h !== "none";
|
|
295
|
+
!m && T && b.push(...Ee(s, y, h, C));
|
|
296
|
+
const p = [s, ...b], S = await jt(e, v), z = [];
|
|
297
|
+
let Y = ((o = l.flip) == null ? void 0 : o.overflows) || [];
|
|
298
|
+
if (f && z.push(S[g]), u) {
|
|
299
|
+
const H = Ce(i, r, C);
|
|
300
|
+
z.push(S[H[0]], S[H[1]]);
|
|
299
301
|
}
|
|
300
|
-
if (
|
|
302
|
+
if (Y = [...Y, {
|
|
301
303
|
placement: i,
|
|
302
|
-
overflows:
|
|
303
|
-
}], !
|
|
304
|
+
overflows: z
|
|
305
|
+
}], !z.every((H) => H <= 0)) {
|
|
304
306
|
var bt, Ct;
|
|
305
|
-
const
|
|
306
|
-
if (
|
|
307
|
+
const H = (((bt = l.flip) == null ? void 0 : bt.index) || 0) + 1, ft = p[H];
|
|
308
|
+
if (ft && (!(u === "alignment" ? w !== F(ft) : !1) || // We leave the current main axis only if every placement on that axis
|
|
307
309
|
// overflows the main axis.
|
|
308
|
-
|
|
310
|
+
Y.every((O) => F(O.placement) === w ? O.overflows[0] > 0 : !0)))
|
|
309
311
|
return {
|
|
310
312
|
data: {
|
|
311
|
-
index:
|
|
312
|
-
overflows:
|
|
313
|
+
index: H,
|
|
314
|
+
overflows: Y
|
|
313
315
|
},
|
|
314
316
|
reset: {
|
|
315
|
-
placement:
|
|
317
|
+
placement: ft
|
|
316
318
|
}
|
|
317
319
|
};
|
|
318
|
-
let
|
|
319
|
-
if (!
|
|
320
|
+
let G = (Ct = Y.filter((W) => W.overflows[0] <= 0).sort((W, O) => W.overflows[1] - O.overflows[1])[0]) == null ? void 0 : Ct.placement;
|
|
321
|
+
if (!G)
|
|
320
322
|
switch (d) {
|
|
321
323
|
case "bestFit": {
|
|
322
|
-
var
|
|
323
|
-
const
|
|
324
|
+
var St;
|
|
325
|
+
const W = (St = Y.filter((O) => {
|
|
324
326
|
if (T) {
|
|
325
|
-
const $ =
|
|
326
|
-
return $ ===
|
|
327
|
+
const $ = F(O.placement);
|
|
328
|
+
return $ === w || // Create a bias to the `y` side axis due to horizontal
|
|
327
329
|
// reading directions favoring greater width.
|
|
328
330
|
$ === "y";
|
|
329
331
|
}
|
|
330
332
|
return !0;
|
|
331
|
-
}).map((
|
|
332
|
-
|
|
333
|
+
}).map((O) => [O.placement, O.overflows.filter(($) => $ > 0).reduce(($, Qt) => $ + Qt, 0)]).sort((O, $) => O[1] - $[1])[0]) == null ? void 0 : St[0];
|
|
334
|
+
W && (G = W);
|
|
333
335
|
break;
|
|
334
336
|
}
|
|
335
337
|
case "initialPlacement":
|
|
336
|
-
|
|
338
|
+
G = s;
|
|
337
339
|
break;
|
|
338
340
|
}
|
|
339
|
-
if (i !==
|
|
341
|
+
if (i !== G)
|
|
340
342
|
return {
|
|
341
343
|
reset: {
|
|
342
|
-
placement:
|
|
344
|
+
placement: G
|
|
343
345
|
}
|
|
344
346
|
};
|
|
345
347
|
}
|
|
346
348
|
return {};
|
|
347
349
|
}
|
|
348
350
|
};
|
|
349
|
-
},
|
|
350
|
-
async function
|
|
351
|
+
}, Pe = /* @__PURE__ */ new Set(["left", "top"]);
|
|
352
|
+
async function ke(t, e) {
|
|
351
353
|
const {
|
|
352
354
|
placement: n,
|
|
353
355
|
platform: o,
|
|
354
356
|
elements: i
|
|
355
|
-
} = t,
|
|
357
|
+
} = t, l = await (o.isRTL == null ? void 0 : o.isRTL(i.floating)), r = N(n), s = rt(n), c = F(n) === "y", a = Pe.has(r) ? -1 : 1, f = l && c ? -1 : 1, u = it(e, t);
|
|
356
358
|
let {
|
|
357
359
|
mainAxis: m,
|
|
358
360
|
crossAxis: d,
|
|
359
361
|
alignmentAxis: h
|
|
360
|
-
} = typeof
|
|
361
|
-
mainAxis:
|
|
362
|
+
} = typeof u == "number" ? {
|
|
363
|
+
mainAxis: u,
|
|
362
364
|
crossAxis: 0,
|
|
363
365
|
alignmentAxis: null
|
|
364
366
|
} : {
|
|
365
|
-
mainAxis:
|
|
366
|
-
crossAxis:
|
|
367
|
-
alignmentAxis:
|
|
367
|
+
mainAxis: u.mainAxis || 0,
|
|
368
|
+
crossAxis: u.crossAxis || 0,
|
|
369
|
+
alignmentAxis: u.alignmentAxis
|
|
368
370
|
};
|
|
369
|
-
return
|
|
370
|
-
x: d *
|
|
371
|
+
return s && typeof h == "number" && (d = s === "end" ? h * -1 : h), c ? {
|
|
372
|
+
x: d * f,
|
|
371
373
|
y: m * a
|
|
372
374
|
} : {
|
|
373
375
|
x: m * a,
|
|
374
|
-
y: d *
|
|
376
|
+
y: d * f
|
|
375
377
|
};
|
|
376
378
|
}
|
|
377
|
-
const
|
|
379
|
+
const Ve = function(t) {
|
|
378
380
|
return t === void 0 && (t = 0), {
|
|
379
381
|
name: "offset",
|
|
380
382
|
options: t,
|
|
@@ -382,21 +384,21 @@ const Pe = function(t) {
|
|
|
382
384
|
var n, o;
|
|
383
385
|
const {
|
|
384
386
|
x: i,
|
|
385
|
-
y:
|
|
387
|
+
y: l,
|
|
386
388
|
placement: r,
|
|
387
|
-
middlewareData:
|
|
388
|
-
} = e,
|
|
389
|
-
return r === ((n =
|
|
390
|
-
x: i +
|
|
391
|
-
y:
|
|
389
|
+
middlewareData: s
|
|
390
|
+
} = e, c = await ke(e, t);
|
|
391
|
+
return r === ((n = s.offset) == null ? void 0 : n.placement) && (o = s.arrow) != null && o.alignmentOffset ? {} : {
|
|
392
|
+
x: i + c.x,
|
|
393
|
+
y: l + c.y,
|
|
392
394
|
data: {
|
|
393
|
-
...
|
|
395
|
+
...c,
|
|
394
396
|
placement: r
|
|
395
397
|
}
|
|
396
398
|
};
|
|
397
399
|
}
|
|
398
400
|
};
|
|
399
|
-
},
|
|
401
|
+
}, $e = function(t) {
|
|
400
402
|
return t === void 0 && (t = {}), {
|
|
401
403
|
name: "shift",
|
|
402
404
|
options: t,
|
|
@@ -406,47 +408,47 @@ const Pe = function(t) {
|
|
|
406
408
|
y: o,
|
|
407
409
|
placement: i
|
|
408
410
|
} = e, {
|
|
409
|
-
mainAxis:
|
|
411
|
+
mainAxis: l = !0,
|
|
410
412
|
crossAxis: r = !1,
|
|
411
|
-
limiter:
|
|
412
|
-
fn: (
|
|
413
|
+
limiter: s = {
|
|
414
|
+
fn: (v) => {
|
|
413
415
|
let {
|
|
414
|
-
x:
|
|
415
|
-
y:
|
|
416
|
-
} =
|
|
416
|
+
x: g,
|
|
417
|
+
y: w
|
|
418
|
+
} = v;
|
|
417
419
|
return {
|
|
418
|
-
x:
|
|
419
|
-
y:
|
|
420
|
+
x: g,
|
|
421
|
+
y: w
|
|
420
422
|
};
|
|
421
423
|
}
|
|
422
424
|
},
|
|
423
|
-
...
|
|
424
|
-
} =
|
|
425
|
+
...c
|
|
426
|
+
} = it(t, e), a = {
|
|
425
427
|
x: n,
|
|
426
428
|
y: o
|
|
427
|
-
},
|
|
428
|
-
let d = a[m], h = a[
|
|
429
|
-
if (
|
|
430
|
-
const
|
|
431
|
-
d =
|
|
429
|
+
}, f = await jt(e, c), u = F(N(i)), m = It(u);
|
|
430
|
+
let d = a[m], h = a[u];
|
|
431
|
+
if (l) {
|
|
432
|
+
const v = m === "y" ? "top" : "left", g = m === "y" ? "bottom" : "right", w = d + f[v], x = d - f[g];
|
|
433
|
+
d = Bt(w, d, x);
|
|
432
434
|
}
|
|
433
435
|
if (r) {
|
|
434
|
-
const
|
|
435
|
-
h =
|
|
436
|
+
const v = u === "y" ? "top" : "left", g = u === "y" ? "bottom" : "right", w = h + f[v], x = h - f[g];
|
|
437
|
+
h = Bt(w, h, x);
|
|
436
438
|
}
|
|
437
|
-
const
|
|
439
|
+
const y = s.fn({
|
|
438
440
|
...e,
|
|
439
441
|
[m]: d,
|
|
440
|
-
[
|
|
442
|
+
[u]: h
|
|
441
443
|
});
|
|
442
444
|
return {
|
|
443
|
-
...
|
|
445
|
+
...y,
|
|
444
446
|
data: {
|
|
445
|
-
x:
|
|
446
|
-
y:
|
|
447
|
+
x: y.x - n,
|
|
448
|
+
y: y.y - o,
|
|
447
449
|
enabled: {
|
|
448
|
-
[m]:
|
|
449
|
-
[
|
|
450
|
+
[m]: l,
|
|
451
|
+
[u]: r
|
|
450
452
|
}
|
|
451
453
|
}
|
|
452
454
|
};
|
|
@@ -456,46 +458,46 @@ const Pe = function(t) {
|
|
|
456
458
|
function lt() {
|
|
457
459
|
return typeof window < "u";
|
|
458
460
|
}
|
|
459
|
-
function
|
|
460
|
-
return
|
|
461
|
+
function j(t) {
|
|
462
|
+
return wt(t) ? (t.nodeName || "").toLowerCase() : "#document";
|
|
461
463
|
}
|
|
462
|
-
function
|
|
464
|
+
function R(t) {
|
|
463
465
|
var e;
|
|
464
466
|
return (t == null || (e = t.ownerDocument) == null ? void 0 : e.defaultView) || window;
|
|
465
467
|
}
|
|
466
|
-
function
|
|
468
|
+
function k(t) {
|
|
467
469
|
var e;
|
|
468
|
-
return (e = (
|
|
470
|
+
return (e = (wt(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
|
|
469
471
|
}
|
|
470
|
-
function
|
|
471
|
-
return lt() ? t instanceof Node || t instanceof
|
|
472
|
+
function wt(t) {
|
|
473
|
+
return lt() ? t instanceof Node || t instanceof R(t).Node : !1;
|
|
472
474
|
}
|
|
473
|
-
function
|
|
474
|
-
return lt() ? t instanceof Element || t instanceof
|
|
475
|
+
function L(t) {
|
|
476
|
+
return lt() ? t instanceof Element || t instanceof R(t).Element : !1;
|
|
475
477
|
}
|
|
476
|
-
function
|
|
477
|
-
return lt() ? t instanceof HTMLElement || t instanceof
|
|
478
|
+
function P(t) {
|
|
479
|
+
return lt() ? t instanceof HTMLElement || t instanceof R(t).HTMLElement : !1;
|
|
478
480
|
}
|
|
479
481
|
function $t(t) {
|
|
480
|
-
return !lt() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof
|
|
482
|
+
return !lt() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof R(t).ShadowRoot;
|
|
481
483
|
}
|
|
482
|
-
const
|
|
483
|
-
function
|
|
484
|
+
const Fe = /* @__PURE__ */ new Set(["inline", "contents"]);
|
|
485
|
+
function J(t) {
|
|
484
486
|
const {
|
|
485
487
|
overflow: e,
|
|
486
488
|
overflowX: n,
|
|
487
489
|
overflowY: o,
|
|
488
490
|
display: i
|
|
489
491
|
} = D(t);
|
|
490
|
-
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) &&
|
|
492
|
+
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !Fe.has(i);
|
|
491
493
|
}
|
|
492
|
-
const
|
|
493
|
-
function
|
|
494
|
-
return
|
|
494
|
+
const Me = /* @__PURE__ */ new Set(["table", "td", "th"]);
|
|
495
|
+
function ze(t) {
|
|
496
|
+
return Me.has(j(t));
|
|
495
497
|
}
|
|
496
|
-
const
|
|
497
|
-
function
|
|
498
|
-
return
|
|
498
|
+
const He = [":popover-open", ":modal"];
|
|
499
|
+
function st(t) {
|
|
500
|
+
return He.some((e) => {
|
|
499
501
|
try {
|
|
500
502
|
return t.matches(e);
|
|
501
503
|
} catch {
|
|
@@ -503,34 +505,34 @@ function ct(t) {
|
|
|
503
505
|
}
|
|
504
506
|
});
|
|
505
507
|
}
|
|
506
|
-
const
|
|
507
|
-
function
|
|
508
|
-
const e =
|
|
509
|
-
return
|
|
508
|
+
const We = ["transform", "translate", "scale", "rotate", "perspective"], Ie = ["transform", "translate", "scale", "rotate", "perspective", "filter"], Ne = ["paint", "layout", "strict", "content"];
|
|
509
|
+
function yt(t) {
|
|
510
|
+
const e = vt(), n = L(t) ? D(t) : t;
|
|
511
|
+
return We.some((o) => n[o] ? n[o] !== "none" : !1) || (n.containerType ? n.containerType !== "normal" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== "none" : !1) || !e && (n.filter ? n.filter !== "none" : !1) || Ie.some((o) => (n.willChange || "").includes(o)) || Ne.some((o) => (n.contain || "").includes(o));
|
|
510
512
|
}
|
|
511
|
-
function
|
|
512
|
-
let e =
|
|
513
|
-
for (;
|
|
514
|
-
if (
|
|
513
|
+
function Xe(t) {
|
|
514
|
+
let e = M(t);
|
|
515
|
+
for (; P(e) && !_(e); ) {
|
|
516
|
+
if (yt(e))
|
|
515
517
|
return e;
|
|
516
|
-
if (
|
|
518
|
+
if (st(e))
|
|
517
519
|
return null;
|
|
518
|
-
e =
|
|
520
|
+
e = M(e);
|
|
519
521
|
}
|
|
520
522
|
return null;
|
|
521
523
|
}
|
|
522
|
-
function
|
|
524
|
+
function vt() {
|
|
523
525
|
return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
|
|
524
526
|
}
|
|
525
|
-
const
|
|
526
|
-
function
|
|
527
|
-
return
|
|
527
|
+
const je = /* @__PURE__ */ new Set(["html", "body", "#document"]);
|
|
528
|
+
function _(t) {
|
|
529
|
+
return je.has(j(t));
|
|
528
530
|
}
|
|
529
531
|
function D(t) {
|
|
530
|
-
return
|
|
532
|
+
return R(t).getComputedStyle(t);
|
|
531
533
|
}
|
|
532
|
-
function
|
|
533
|
-
return
|
|
534
|
+
function ct(t) {
|
|
535
|
+
return L(t) ? {
|
|
534
536
|
scrollLeft: t.scrollLeft,
|
|
535
537
|
scrollTop: t.scrollTop
|
|
536
538
|
} : {
|
|
@@ -538,187 +540,187 @@ function at(t) {
|
|
|
538
540
|
scrollTop: t.scrollY
|
|
539
541
|
};
|
|
540
542
|
}
|
|
541
|
-
function
|
|
542
|
-
if (
|
|
543
|
+
function M(t) {
|
|
544
|
+
if (j(t) === "html")
|
|
543
545
|
return t;
|
|
544
546
|
const e = (
|
|
545
547
|
// Step into the shadow DOM of the parent of a slotted node.
|
|
546
548
|
t.assignedSlot || // DOM Element detected.
|
|
547
549
|
t.parentNode || // ShadowRoot detected.
|
|
548
550
|
$t(t) && t.host || // Fallback.
|
|
549
|
-
|
|
551
|
+
k(t)
|
|
550
552
|
);
|
|
551
553
|
return $t(e) ? e.host : e;
|
|
552
554
|
}
|
|
553
555
|
function Yt(t) {
|
|
554
|
-
const e =
|
|
555
|
-
return
|
|
556
|
+
const e = M(t);
|
|
557
|
+
return _(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : P(e) && J(e) ? e : Yt(e);
|
|
556
558
|
}
|
|
557
|
-
function
|
|
559
|
+
function Z(t, e, n) {
|
|
558
560
|
var o;
|
|
559
561
|
e === void 0 && (e = []), n === void 0 && (n = !0);
|
|
560
|
-
const i = Yt(t),
|
|
561
|
-
if (
|
|
562
|
-
const
|
|
563
|
-
return e.concat(r, r.visualViewport || [],
|
|
562
|
+
const i = Yt(t), l = i === ((o = t.ownerDocument) == null ? void 0 : o.body), r = R(i);
|
|
563
|
+
if (l) {
|
|
564
|
+
const s = pt(r);
|
|
565
|
+
return e.concat(r, r.visualViewport || [], J(i) ? i : [], s && n ? Z(s) : []);
|
|
564
566
|
}
|
|
565
|
-
return e.concat(i,
|
|
567
|
+
return e.concat(i, Z(i, [], n));
|
|
566
568
|
}
|
|
567
|
-
function
|
|
569
|
+
function pt(t) {
|
|
568
570
|
return t.parent && Object.getPrototypeOf(t.parent) ? t.frameElement : null;
|
|
569
571
|
}
|
|
570
572
|
function qt(t) {
|
|
571
573
|
const e = D(t);
|
|
572
574
|
let n = parseFloat(e.width) || 0, o = parseFloat(e.height) || 0;
|
|
573
|
-
const i =
|
|
574
|
-
return
|
|
575
|
+
const i = P(t), l = i ? t.offsetWidth : n, r = i ? t.offsetHeight : o, s = et(n) !== l || et(o) !== r;
|
|
576
|
+
return s && (n = l, o = r), {
|
|
575
577
|
width: n,
|
|
576
578
|
height: o,
|
|
577
|
-
$:
|
|
579
|
+
$: s
|
|
578
580
|
};
|
|
579
581
|
}
|
|
580
582
|
function xt(t) {
|
|
581
|
-
return
|
|
583
|
+
return L(t) ? t : t.contextElement;
|
|
582
584
|
}
|
|
583
|
-
function
|
|
585
|
+
function U(t) {
|
|
584
586
|
const e = xt(t);
|
|
585
|
-
if (!
|
|
586
|
-
return
|
|
587
|
+
if (!P(e))
|
|
588
|
+
return B(1);
|
|
587
589
|
const n = e.getBoundingClientRect(), {
|
|
588
590
|
width: o,
|
|
589
591
|
height: i,
|
|
590
|
-
$:
|
|
592
|
+
$: l
|
|
591
593
|
} = qt(e);
|
|
592
|
-
let r = (
|
|
593
|
-
return (!r || !Number.isFinite(r)) && (r = 1), (!
|
|
594
|
+
let r = (l ? et(n.width) : n.width) / o, s = (l ? et(n.height) : n.height) / i;
|
|
595
|
+
return (!r || !Number.isFinite(r)) && (r = 1), (!s || !Number.isFinite(s)) && (s = 1), {
|
|
594
596
|
x: r,
|
|
595
|
-
y:
|
|
597
|
+
y: s
|
|
596
598
|
};
|
|
597
599
|
}
|
|
598
|
-
const
|
|
600
|
+
const Ye = /* @__PURE__ */ B(0);
|
|
599
601
|
function Ut(t) {
|
|
600
|
-
const e =
|
|
601
|
-
return !
|
|
602
|
+
const e = R(t);
|
|
603
|
+
return !vt() || !e.visualViewport ? Ye : {
|
|
602
604
|
x: e.visualViewport.offsetLeft,
|
|
603
605
|
y: e.visualViewport.offsetTop
|
|
604
606
|
};
|
|
605
607
|
}
|
|
606
|
-
function
|
|
607
|
-
return e === void 0 && (e = !1), !n || e && n !==
|
|
608
|
+
function qe(t, e, n) {
|
|
609
|
+
return e === void 0 && (e = !1), !n || e && n !== R(t) ? !1 : e;
|
|
608
610
|
}
|
|
609
|
-
function
|
|
611
|
+
function X(t, e, n, o) {
|
|
610
612
|
e === void 0 && (e = !1), n === void 0 && (n = !1);
|
|
611
|
-
const i = t.getBoundingClientRect(),
|
|
612
|
-
let r =
|
|
613
|
-
e && (o ?
|
|
614
|
-
const
|
|
615
|
-
let
|
|
616
|
-
if (
|
|
617
|
-
const m =
|
|
618
|
-
let h = m,
|
|
619
|
-
for (;
|
|
620
|
-
const
|
|
621
|
-
|
|
613
|
+
const i = t.getBoundingClientRect(), l = xt(t);
|
|
614
|
+
let r = B(1);
|
|
615
|
+
e && (o ? L(o) && (r = U(o)) : r = U(t));
|
|
616
|
+
const s = qe(l, n, o) ? Ut(l) : B(0);
|
|
617
|
+
let c = (i.left + s.x) / r.x, a = (i.top + s.y) / r.y, f = i.width / r.x, u = i.height / r.y;
|
|
618
|
+
if (l) {
|
|
619
|
+
const m = R(l), d = o && L(o) ? R(o) : o;
|
|
620
|
+
let h = m, y = pt(h);
|
|
621
|
+
for (; y && o && d !== h; ) {
|
|
622
|
+
const v = U(y), g = y.getBoundingClientRect(), w = D(y), x = g.left + (y.clientLeft + parseFloat(w.paddingLeft)) * v.x, C = g.top + (y.clientTop + parseFloat(w.paddingTop)) * v.y;
|
|
623
|
+
c *= v.x, a *= v.y, f *= v.x, u *= v.y, c += x, a += C, h = R(y), y = pt(h);
|
|
622
624
|
}
|
|
623
625
|
}
|
|
624
|
-
return
|
|
625
|
-
width:
|
|
626
|
-
height:
|
|
627
|
-
x:
|
|
626
|
+
return ot({
|
|
627
|
+
width: f,
|
|
628
|
+
height: u,
|
|
629
|
+
x: c,
|
|
628
630
|
y: a
|
|
629
631
|
});
|
|
630
632
|
}
|
|
631
|
-
function
|
|
632
|
-
const n =
|
|
633
|
-
return e ? e.left + n :
|
|
633
|
+
function at(t, e) {
|
|
634
|
+
const n = ct(t).scrollLeft;
|
|
635
|
+
return e ? e.left + n : X(k(t)).left + n;
|
|
634
636
|
}
|
|
635
637
|
function _t(t, e) {
|
|
636
|
-
const n = t.getBoundingClientRect(), o = n.left + e.scrollLeft -
|
|
638
|
+
const n = t.getBoundingClientRect(), o = n.left + e.scrollLeft - at(t, n), i = n.top + e.scrollTop;
|
|
637
639
|
return {
|
|
638
640
|
x: o,
|
|
639
641
|
y: i
|
|
640
642
|
};
|
|
641
643
|
}
|
|
642
|
-
function
|
|
644
|
+
function Ue(t) {
|
|
643
645
|
let {
|
|
644
646
|
elements: e,
|
|
645
647
|
rect: n,
|
|
646
648
|
offsetParent: o,
|
|
647
649
|
strategy: i
|
|
648
650
|
} = t;
|
|
649
|
-
const
|
|
650
|
-
if (o === r ||
|
|
651
|
+
const l = i === "fixed", r = k(o), s = e ? st(e.floating) : !1;
|
|
652
|
+
if (o === r || s && l)
|
|
651
653
|
return n;
|
|
652
|
-
let
|
|
654
|
+
let c = {
|
|
653
655
|
scrollLeft: 0,
|
|
654
656
|
scrollTop: 0
|
|
655
|
-
}, a =
|
|
656
|
-
const
|
|
657
|
-
if ((
|
|
658
|
-
const d =
|
|
659
|
-
a =
|
|
657
|
+
}, a = B(1);
|
|
658
|
+
const f = B(0), u = P(o);
|
|
659
|
+
if ((u || !u && !l) && ((j(o) !== "body" || J(r)) && (c = ct(o)), P(o))) {
|
|
660
|
+
const d = X(o);
|
|
661
|
+
a = U(o), f.x = d.x + o.clientLeft, f.y = d.y + o.clientTop;
|
|
660
662
|
}
|
|
661
|
-
const m = r && !
|
|
663
|
+
const m = r && !u && !l ? _t(r, c) : B(0);
|
|
662
664
|
return {
|
|
663
665
|
width: n.width * a.x,
|
|
664
666
|
height: n.height * a.y,
|
|
665
|
-
x: n.x * a.x -
|
|
666
|
-
y: n.y * a.y -
|
|
667
|
+
x: n.x * a.x - c.scrollLeft * a.x + f.x + m.x,
|
|
668
|
+
y: n.y * a.y - c.scrollTop * a.y + f.y + m.y
|
|
667
669
|
};
|
|
668
670
|
}
|
|
669
|
-
function
|
|
671
|
+
function _e(t) {
|
|
670
672
|
return Array.from(t.getClientRects());
|
|
671
673
|
}
|
|
672
|
-
function
|
|
673
|
-
const e =
|
|
674
|
-
let r = -n.scrollLeft +
|
|
675
|
-
const
|
|
676
|
-
return D(o).direction === "rtl" && (r +=
|
|
674
|
+
function Ge(t) {
|
|
675
|
+
const e = k(t), n = ct(t), o = t.ownerDocument.body, i = I(e.scrollWidth, e.clientWidth, o.scrollWidth, o.clientWidth), l = I(e.scrollHeight, e.clientHeight, o.scrollHeight, o.clientHeight);
|
|
676
|
+
let r = -n.scrollLeft + at(t);
|
|
677
|
+
const s = -n.scrollTop;
|
|
678
|
+
return D(o).direction === "rtl" && (r += I(e.clientWidth, o.clientWidth) - i), {
|
|
677
679
|
width: i,
|
|
678
|
-
height:
|
|
680
|
+
height: l,
|
|
679
681
|
x: r,
|
|
680
|
-
y:
|
|
682
|
+
y: s
|
|
681
683
|
};
|
|
682
684
|
}
|
|
683
685
|
const Ft = 25;
|
|
684
|
-
function
|
|
685
|
-
const n =
|
|
686
|
-
let
|
|
686
|
+
function Ke(t, e) {
|
|
687
|
+
const n = R(t), o = k(t), i = n.visualViewport;
|
|
688
|
+
let l = o.clientWidth, r = o.clientHeight, s = 0, c = 0;
|
|
687
689
|
if (i) {
|
|
688
|
-
|
|
689
|
-
const
|
|
690
|
-
(!
|
|
690
|
+
l = i.width, r = i.height;
|
|
691
|
+
const f = vt();
|
|
692
|
+
(!f || f && e === "fixed") && (s = i.offsetLeft, c = i.offsetTop);
|
|
691
693
|
}
|
|
692
|
-
const a =
|
|
694
|
+
const a = at(o);
|
|
693
695
|
if (a <= 0) {
|
|
694
|
-
const
|
|
695
|
-
h <= Ft && (
|
|
696
|
-
} else a <= Ft && (
|
|
696
|
+
const f = o.ownerDocument, u = f.body, m = getComputedStyle(u), d = f.compatMode === "CSS1Compat" && parseFloat(m.marginLeft) + parseFloat(m.marginRight) || 0, h = Math.abs(o.clientWidth - u.clientWidth - d);
|
|
697
|
+
h <= Ft && (l -= h);
|
|
698
|
+
} else a <= Ft && (l += a);
|
|
697
699
|
return {
|
|
698
|
-
width:
|
|
700
|
+
width: l,
|
|
699
701
|
height: r,
|
|
700
|
-
x:
|
|
701
|
-
y:
|
|
702
|
+
x: s,
|
|
703
|
+
y: c
|
|
702
704
|
};
|
|
703
705
|
}
|
|
704
|
-
const
|
|
705
|
-
function
|
|
706
|
-
const n =
|
|
706
|
+
const Ze = /* @__PURE__ */ new Set(["absolute", "fixed"]);
|
|
707
|
+
function Je(t, e) {
|
|
708
|
+
const n = X(t, !0, e === "fixed"), o = n.top + t.clientTop, i = n.left + t.clientLeft, l = P(t) ? U(t) : B(1), r = t.clientWidth * l.x, s = t.clientHeight * l.y, c = i * l.x, a = o * l.y;
|
|
707
709
|
return {
|
|
708
710
|
width: r,
|
|
709
|
-
height:
|
|
710
|
-
x:
|
|
711
|
+
height: s,
|
|
712
|
+
x: c,
|
|
711
713
|
y: a
|
|
712
714
|
};
|
|
713
715
|
}
|
|
714
716
|
function Mt(t, e, n) {
|
|
715
717
|
let o;
|
|
716
718
|
if (e === "viewport")
|
|
717
|
-
o =
|
|
719
|
+
o = Ke(t, n);
|
|
718
720
|
else if (e === "document")
|
|
719
|
-
o =
|
|
720
|
-
else if (
|
|
721
|
-
o =
|
|
721
|
+
o = Ge(k(t));
|
|
722
|
+
else if (L(e))
|
|
723
|
+
o = Je(e, n);
|
|
722
724
|
else {
|
|
723
725
|
const i = Ut(t);
|
|
724
726
|
o = {
|
|
@@ -728,44 +730,44 @@ function Mt(t, e, n) {
|
|
|
728
730
|
height: e.height
|
|
729
731
|
};
|
|
730
732
|
}
|
|
731
|
-
return
|
|
733
|
+
return ot(o);
|
|
732
734
|
}
|
|
733
735
|
function Gt(t, e) {
|
|
734
|
-
const n =
|
|
735
|
-
return n === e || !
|
|
736
|
+
const n = M(t);
|
|
737
|
+
return n === e || !L(n) || _(n) ? !1 : D(n).position === "fixed" || Gt(n, e);
|
|
736
738
|
}
|
|
737
|
-
function
|
|
739
|
+
function Qe(t, e) {
|
|
738
740
|
const n = e.get(t);
|
|
739
741
|
if (n)
|
|
740
742
|
return n;
|
|
741
|
-
let o =
|
|
742
|
-
const
|
|
743
|
-
let r =
|
|
744
|
-
for (;
|
|
745
|
-
const
|
|
746
|
-
!
|
|
743
|
+
let o = Z(t, [], !1).filter((s) => L(s) && j(s) !== "body"), i = null;
|
|
744
|
+
const l = D(t).position === "fixed";
|
|
745
|
+
let r = l ? M(t) : t;
|
|
746
|
+
for (; L(r) && !_(r); ) {
|
|
747
|
+
const s = D(r), c = yt(r);
|
|
748
|
+
!c && s.position === "fixed" && (i = null), (l ? !c && !i : !c && s.position === "static" && !!i && Ze.has(i.position) || J(r) && !c && Gt(t, r)) ? o = o.filter((f) => f !== r) : i = s, r = M(r);
|
|
747
749
|
}
|
|
748
750
|
return e.set(t, o), o;
|
|
749
751
|
}
|
|
750
|
-
function
|
|
752
|
+
function tn(t) {
|
|
751
753
|
let {
|
|
752
754
|
element: e,
|
|
753
755
|
boundary: n,
|
|
754
756
|
rootBoundary: o,
|
|
755
757
|
strategy: i
|
|
756
758
|
} = t;
|
|
757
|
-
const r = [...n === "clippingAncestors" ?
|
|
758
|
-
const
|
|
759
|
-
return a.top =
|
|
760
|
-
}, Mt(e,
|
|
759
|
+
const r = [...n === "clippingAncestors" ? st(e) ? [] : Qe(e, this._c) : [].concat(n), o], s = r[0], c = r.reduce((a, f) => {
|
|
760
|
+
const u = Mt(e, f, i);
|
|
761
|
+
return a.top = I(u.top, a.top), a.right = tt(u.right, a.right), a.bottom = tt(u.bottom, a.bottom), a.left = I(u.left, a.left), a;
|
|
762
|
+
}, Mt(e, s, i));
|
|
761
763
|
return {
|
|
762
|
-
width:
|
|
763
|
-
height:
|
|
764
|
-
x:
|
|
765
|
-
y:
|
|
764
|
+
width: c.right - c.left,
|
|
765
|
+
height: c.bottom - c.top,
|
|
766
|
+
x: c.left,
|
|
767
|
+
y: c.top
|
|
766
768
|
};
|
|
767
769
|
}
|
|
768
|
-
function
|
|
770
|
+
function en(t) {
|
|
769
771
|
const {
|
|
770
772
|
width: e,
|
|
771
773
|
height: n
|
|
@@ -775,25 +777,25 @@ function tn(t) {
|
|
|
775
777
|
height: n
|
|
776
778
|
};
|
|
777
779
|
}
|
|
778
|
-
function
|
|
779
|
-
const o =
|
|
780
|
-
let
|
|
780
|
+
function nn(t, e, n) {
|
|
781
|
+
const o = P(e), i = k(e), l = n === "fixed", r = X(t, !0, l, e);
|
|
782
|
+
let s = {
|
|
781
783
|
scrollLeft: 0,
|
|
782
784
|
scrollTop: 0
|
|
783
785
|
};
|
|
784
|
-
const
|
|
786
|
+
const c = B(0);
|
|
785
787
|
function a() {
|
|
786
|
-
|
|
788
|
+
c.x = at(i);
|
|
787
789
|
}
|
|
788
|
-
if (o || !o && !
|
|
789
|
-
if ((
|
|
790
|
-
const d =
|
|
791
|
-
|
|
790
|
+
if (o || !o && !l)
|
|
791
|
+
if ((j(e) !== "body" || J(i)) && (s = ct(e)), o) {
|
|
792
|
+
const d = X(e, !0, l, e);
|
|
793
|
+
c.x = d.x + e.clientLeft, c.y = d.y + e.clientTop;
|
|
792
794
|
} else i && a();
|
|
793
|
-
|
|
794
|
-
const
|
|
795
|
+
l && !o && i && a();
|
|
796
|
+
const f = i && !o && !l ? _t(i, s) : B(0), u = r.left + s.scrollLeft - c.x - f.x, m = r.top + s.scrollTop - c.y - f.y;
|
|
795
797
|
return {
|
|
796
|
-
x:
|
|
798
|
+
x: u,
|
|
797
799
|
y: m,
|
|
798
800
|
width: r.width,
|
|
799
801
|
height: r.height
|
|
@@ -803,35 +805,35 @@ function ht(t) {
|
|
|
803
805
|
return D(t).position === "static";
|
|
804
806
|
}
|
|
805
807
|
function zt(t, e) {
|
|
806
|
-
if (!
|
|
808
|
+
if (!P(t) || D(t).position === "fixed")
|
|
807
809
|
return null;
|
|
808
810
|
if (e)
|
|
809
811
|
return e(t);
|
|
810
812
|
let n = t.offsetParent;
|
|
811
|
-
return
|
|
813
|
+
return k(t) === n && (n = n.ownerDocument.body), n;
|
|
812
814
|
}
|
|
813
815
|
function Kt(t, e) {
|
|
814
|
-
const n =
|
|
815
|
-
if (
|
|
816
|
+
const n = R(t);
|
|
817
|
+
if (st(t))
|
|
816
818
|
return n;
|
|
817
|
-
if (!
|
|
818
|
-
let i =
|
|
819
|
-
for (; i && !
|
|
820
|
-
if (
|
|
819
|
+
if (!P(t)) {
|
|
820
|
+
let i = M(t);
|
|
821
|
+
for (; i && !_(i); ) {
|
|
822
|
+
if (L(i) && !ht(i))
|
|
821
823
|
return i;
|
|
822
|
-
i =
|
|
824
|
+
i = M(i);
|
|
823
825
|
}
|
|
824
826
|
return n;
|
|
825
827
|
}
|
|
826
828
|
let o = zt(t, e);
|
|
827
|
-
for (; o &&
|
|
829
|
+
for (; o && ze(o) && ht(o); )
|
|
828
830
|
o = zt(o, e);
|
|
829
|
-
return o &&
|
|
831
|
+
return o && _(o) && ht(o) && !yt(o) ? n : o || Xe(t) || n;
|
|
830
832
|
}
|
|
831
|
-
const
|
|
833
|
+
const on = async function(t) {
|
|
832
834
|
const e = this.getOffsetParent || Kt, n = this.getDimensions, o = await n(t.floating);
|
|
833
835
|
return {
|
|
834
|
-
reference:
|
|
836
|
+
reference: nn(t.reference, await e(t.floating), t.strategy),
|
|
835
837
|
floating: {
|
|
836
838
|
x: 0,
|
|
837
839
|
y: 0,
|
|
@@ -840,56 +842,56 @@ const nn = async function(t) {
|
|
|
840
842
|
}
|
|
841
843
|
};
|
|
842
844
|
};
|
|
843
|
-
function
|
|
845
|
+
function rn(t) {
|
|
844
846
|
return D(t).direction === "rtl";
|
|
845
847
|
}
|
|
846
|
-
const
|
|
847
|
-
convertOffsetParentRelativeRectToViewportRelativeRect:
|
|
848
|
-
getDocumentElement:
|
|
849
|
-
getClippingRect:
|
|
848
|
+
const ln = {
|
|
849
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: Ue,
|
|
850
|
+
getDocumentElement: k,
|
|
851
|
+
getClippingRect: tn,
|
|
850
852
|
getOffsetParent: Kt,
|
|
851
|
-
getElementRects:
|
|
852
|
-
getClientRects:
|
|
853
|
-
getDimensions:
|
|
854
|
-
getScale:
|
|
855
|
-
isElement:
|
|
856
|
-
isRTL:
|
|
853
|
+
getElementRects: on,
|
|
854
|
+
getClientRects: _e,
|
|
855
|
+
getDimensions: en,
|
|
856
|
+
getScale: U,
|
|
857
|
+
isElement: L,
|
|
858
|
+
isRTL: rn
|
|
857
859
|
};
|
|
858
860
|
function Zt(t, e) {
|
|
859
861
|
return t.x === e.x && t.y === e.y && t.width === e.width && t.height === e.height;
|
|
860
862
|
}
|
|
861
863
|
function sn(t, e) {
|
|
862
864
|
let n = null, o;
|
|
863
|
-
const i =
|
|
864
|
-
function
|
|
865
|
-
var
|
|
866
|
-
clearTimeout(o), (
|
|
865
|
+
const i = k(t);
|
|
866
|
+
function l() {
|
|
867
|
+
var s;
|
|
868
|
+
clearTimeout(o), (s = n) == null || s.disconnect(), n = null;
|
|
867
869
|
}
|
|
868
|
-
function r(
|
|
869
|
-
|
|
870
|
+
function r(s, c) {
|
|
871
|
+
s === void 0 && (s = !1), c === void 0 && (c = 1), l();
|
|
870
872
|
const a = t.getBoundingClientRect(), {
|
|
871
|
-
left:
|
|
872
|
-
top:
|
|
873
|
+
left: f,
|
|
874
|
+
top: u,
|
|
873
875
|
width: m,
|
|
874
876
|
height: d
|
|
875
877
|
} = a;
|
|
876
|
-
if (
|
|
878
|
+
if (s || e(), !m || !d)
|
|
877
879
|
return;
|
|
878
|
-
const h =
|
|
879
|
-
rootMargin: -h + "px " + -
|
|
880
|
-
threshold:
|
|
880
|
+
const h = Q(u), y = Q(i.clientWidth - (f + m)), v = Q(i.clientHeight - (u + d)), g = Q(f), x = {
|
|
881
|
+
rootMargin: -h + "px " + -y + "px " + -v + "px " + -g + "px",
|
|
882
|
+
threshold: I(0, tt(1, c)) || 1
|
|
881
883
|
};
|
|
882
884
|
let C = !0;
|
|
883
885
|
function b(T) {
|
|
884
|
-
const
|
|
885
|
-
if (
|
|
886
|
+
const p = T[0].intersectionRatio;
|
|
887
|
+
if (p !== c) {
|
|
886
888
|
if (!C)
|
|
887
889
|
return r();
|
|
888
|
-
|
|
890
|
+
p ? r(!1, p) : o = setTimeout(() => {
|
|
889
891
|
r(!1, 1e-7);
|
|
890
892
|
}, 1e3);
|
|
891
893
|
}
|
|
892
|
-
|
|
894
|
+
p === 1 && !Zt(a, t.getBoundingClientRect()) && r(), C = !1;
|
|
893
895
|
}
|
|
894
896
|
try {
|
|
895
897
|
n = new IntersectionObserver(b, {
|
|
@@ -902,69 +904,69 @@ function sn(t, e) {
|
|
|
902
904
|
}
|
|
903
905
|
n.observe(t);
|
|
904
906
|
}
|
|
905
|
-
return r(!0),
|
|
907
|
+
return r(!0), l;
|
|
906
908
|
}
|
|
907
|
-
function
|
|
909
|
+
function cn(t, e, n, o) {
|
|
908
910
|
o === void 0 && (o = {});
|
|
909
911
|
const {
|
|
910
912
|
ancestorScroll: i = !0,
|
|
911
|
-
ancestorResize:
|
|
913
|
+
ancestorResize: l = !0,
|
|
912
914
|
elementResize: r = typeof ResizeObserver == "function",
|
|
913
|
-
layoutShift:
|
|
914
|
-
animationFrame:
|
|
915
|
-
} = o, a = xt(t),
|
|
916
|
-
|
|
917
|
-
i &&
|
|
915
|
+
layoutShift: s = typeof IntersectionObserver == "function",
|
|
916
|
+
animationFrame: c = !1
|
|
917
|
+
} = o, a = xt(t), f = i || l ? [...a ? Z(a) : [], ...Z(e)] : [];
|
|
918
|
+
f.forEach((g) => {
|
|
919
|
+
i && g.addEventListener("scroll", n, {
|
|
918
920
|
passive: !0
|
|
919
|
-
}),
|
|
921
|
+
}), l && g.addEventListener("resize", n);
|
|
920
922
|
});
|
|
921
|
-
const
|
|
923
|
+
const u = a && s ? sn(a, n) : null;
|
|
922
924
|
let m = -1, d = null;
|
|
923
|
-
r && (d = new ResizeObserver((
|
|
924
|
-
let [
|
|
925
|
-
|
|
925
|
+
r && (d = new ResizeObserver((g) => {
|
|
926
|
+
let [w] = g;
|
|
927
|
+
w && w.target === a && d && (d.unobserve(e), cancelAnimationFrame(m), m = requestAnimationFrame(() => {
|
|
926
928
|
var x;
|
|
927
929
|
(x = d) == null || x.observe(e);
|
|
928
930
|
})), n();
|
|
929
|
-
}), a && !
|
|
930
|
-
let h,
|
|
931
|
-
|
|
932
|
-
function
|
|
933
|
-
const
|
|
934
|
-
|
|
931
|
+
}), a && !c && d.observe(a), d.observe(e));
|
|
932
|
+
let h, y = c ? X(t) : null;
|
|
933
|
+
c && v();
|
|
934
|
+
function v() {
|
|
935
|
+
const g = X(t);
|
|
936
|
+
y && !Zt(y, g) && n(), y = g, h = requestAnimationFrame(v);
|
|
935
937
|
}
|
|
936
938
|
return n(), () => {
|
|
937
|
-
var
|
|
938
|
-
|
|
939
|
-
i &&
|
|
940
|
-
}),
|
|
939
|
+
var g;
|
|
940
|
+
f.forEach((w) => {
|
|
941
|
+
i && w.removeEventListener("scroll", n), l && w.removeEventListener("resize", n);
|
|
942
|
+
}), u?.(), (g = d) == null || g.disconnect(), d = null, c && cancelAnimationFrame(h);
|
|
941
943
|
};
|
|
942
944
|
}
|
|
943
|
-
const
|
|
945
|
+
const an = Ve, fn = $e, un = Be, dn = (t, e, n) => {
|
|
944
946
|
const o = /* @__PURE__ */ new Map(), i = {
|
|
945
|
-
platform:
|
|
947
|
+
platform: ln,
|
|
946
948
|
...n
|
|
947
|
-
},
|
|
949
|
+
}, l = {
|
|
948
950
|
...i.platform,
|
|
949
951
|
_c: o
|
|
950
952
|
};
|
|
951
|
-
return
|
|
953
|
+
return Te(t, e, {
|
|
952
954
|
...i,
|
|
953
|
-
platform:
|
|
955
|
+
platform: l
|
|
954
956
|
});
|
|
955
957
|
};
|
|
956
|
-
function
|
|
958
|
+
function mn(t) {
|
|
957
959
|
return t != null && typeof t == "object" && "$el" in t;
|
|
958
960
|
}
|
|
959
961
|
function Ht(t) {
|
|
960
|
-
if (
|
|
962
|
+
if (mn(t)) {
|
|
961
963
|
const e = t.$el;
|
|
962
|
-
return
|
|
964
|
+
return wt(e) && j(e) === "#comment" ? null : e;
|
|
963
965
|
}
|
|
964
966
|
return t;
|
|
965
967
|
}
|
|
966
|
-
function
|
|
967
|
-
return typeof t == "function" ? t() :
|
|
968
|
+
function K(t) {
|
|
969
|
+
return typeof t == "function" ? t() : A(t);
|
|
968
970
|
}
|
|
969
971
|
function Jt(t) {
|
|
970
972
|
return typeof window > "u" ? 1 : (t.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
@@ -973,131 +975,88 @@ function Wt(t, e) {
|
|
|
973
975
|
const n = Jt(t);
|
|
974
976
|
return Math.round(e * n) / n;
|
|
975
977
|
}
|
|
976
|
-
function
|
|
978
|
+
function hn(t, e, n) {
|
|
977
979
|
n === void 0 && (n = {});
|
|
978
980
|
const o = n.whileElementsMounted, i = V(() => {
|
|
979
|
-
var
|
|
980
|
-
return (
|
|
981
|
-
}),
|
|
982
|
-
var
|
|
983
|
-
return (
|
|
981
|
+
var p;
|
|
982
|
+
return (p = K(n.open)) != null ? p : !0;
|
|
983
|
+
}), l = V(() => K(n.middleware)), r = V(() => {
|
|
984
|
+
var p;
|
|
985
|
+
return (p = K(n.placement)) != null ? p : "bottom";
|
|
986
|
+
}), s = V(() => {
|
|
987
|
+
var p;
|
|
988
|
+
return (p = K(n.strategy)) != null ? p : "absolute";
|
|
984
989
|
}), c = V(() => {
|
|
985
|
-
var
|
|
986
|
-
return (
|
|
987
|
-
}),
|
|
988
|
-
|
|
989
|
-
return (g = Z(n.transform)) != null ? g : !0;
|
|
990
|
-
}), a = V(() => Ht(t.value)), u = V(() => Ht(e.value)), f = L(0), m = L(0), d = L(c.value), h = L(r.value), v = te({}), y = L(!1), w = V(() => {
|
|
991
|
-
const g = {
|
|
990
|
+
var p;
|
|
991
|
+
return (p = K(n.transform)) != null ? p : !0;
|
|
992
|
+
}), a = V(() => Ht(t.value)), f = V(() => Ht(e.value)), u = E(0), m = E(0), d = E(s.value), h = E(r.value), y = te({}), v = E(!1), g = V(() => {
|
|
993
|
+
const p = {
|
|
992
994
|
position: d.value,
|
|
993
995
|
left: "0",
|
|
994
996
|
top: "0"
|
|
995
997
|
};
|
|
996
|
-
if (!
|
|
997
|
-
return
|
|
998
|
-
const
|
|
999
|
-
return
|
|
1000
|
-
...
|
|
1001
|
-
transform: "translate(" +
|
|
1002
|
-
...Jt(
|
|
998
|
+
if (!f.value)
|
|
999
|
+
return p;
|
|
1000
|
+
const S = Wt(f.value, u.value), z = Wt(f.value, m.value);
|
|
1001
|
+
return c.value ? {
|
|
1002
|
+
...p,
|
|
1003
|
+
transform: "translate(" + S + "px, " + z + "px)",
|
|
1004
|
+
...Jt(f.value) >= 1.5 && {
|
|
1003
1005
|
willChange: "transform"
|
|
1004
1006
|
}
|
|
1005
1007
|
} : {
|
|
1006
1008
|
position: d.value,
|
|
1007
|
-
left:
|
|
1008
|
-
top:
|
|
1009
|
+
left: S + "px",
|
|
1010
|
+
top: z + "px"
|
|
1009
1011
|
};
|
|
1010
1012
|
});
|
|
1011
|
-
let
|
|
1013
|
+
let w;
|
|
1012
1014
|
function x() {
|
|
1013
|
-
if (a.value == null ||
|
|
1015
|
+
if (a.value == null || f.value == null)
|
|
1014
1016
|
return;
|
|
1015
|
-
const
|
|
1016
|
-
|
|
1017
|
-
middleware:
|
|
1017
|
+
const p = i.value;
|
|
1018
|
+
dn(a.value, f.value, {
|
|
1019
|
+
middleware: l.value,
|
|
1018
1020
|
placement: r.value,
|
|
1019
|
-
strategy:
|
|
1020
|
-
}).then((
|
|
1021
|
-
|
|
1021
|
+
strategy: s.value
|
|
1022
|
+
}).then((S) => {
|
|
1023
|
+
u.value = S.x, m.value = S.y, d.value = S.strategy, h.value = S.placement, y.value = S.middlewareData, v.value = p !== !1;
|
|
1022
1024
|
});
|
|
1023
1025
|
}
|
|
1024
1026
|
function C() {
|
|
1025
|
-
typeof
|
|
1027
|
+
typeof w == "function" && (w(), w = void 0);
|
|
1026
1028
|
}
|
|
1027
1029
|
function b() {
|
|
1028
1030
|
if (C(), o === void 0) {
|
|
1029
1031
|
x();
|
|
1030
1032
|
return;
|
|
1031
1033
|
}
|
|
1032
|
-
if (a.value != null &&
|
|
1033
|
-
|
|
1034
|
+
if (a.value != null && f.value != null) {
|
|
1035
|
+
w = o(a.value, f.value, x);
|
|
1034
1036
|
return;
|
|
1035
1037
|
}
|
|
1036
1038
|
}
|
|
1037
1039
|
function T() {
|
|
1038
|
-
i.value || (
|
|
1040
|
+
i.value || (v.value = !1);
|
|
1039
1041
|
}
|
|
1040
|
-
return
|
|
1042
|
+
return ut([l, r, s, i], x, {
|
|
1041
1043
|
flush: "sync"
|
|
1042
|
-
}),
|
|
1044
|
+
}), ut([a, f], b, {
|
|
1043
1045
|
flush: "sync"
|
|
1044
|
-
}),
|
|
1046
|
+
}), ut(i, T, {
|
|
1045
1047
|
flush: "sync"
|
|
1046
1048
|
}), ee() && ne(C), {
|
|
1047
|
-
x:
|
|
1048
|
-
y:
|
|
1049
|
-
strategy:
|
|
1050
|
-
placement:
|
|
1051
|
-
middlewareData:
|
|
1052
|
-
isPositioned:
|
|
1053
|
-
floatingStyles:
|
|
1049
|
+
x: q(u),
|
|
1050
|
+
y: q(m),
|
|
1051
|
+
strategy: q(d),
|
|
1052
|
+
placement: q(h),
|
|
1053
|
+
middlewareData: q(y),
|
|
1054
|
+
isPositioned: q(v),
|
|
1055
|
+
floatingStyles: g,
|
|
1054
1056
|
update: x
|
|
1055
1057
|
};
|
|
1056
1058
|
}
|
|
1057
|
-
const
|
|
1058
|
-
triggerElem: t,
|
|
1059
|
-
dropdownRef: e,
|
|
1060
|
-
openDropdownHandler: n,
|
|
1061
|
-
closeDropdownHandler: o
|
|
1062
|
-
}) => {
|
|
1063
|
-
const i = L(!1), s = L(), r = () => {
|
|
1064
|
-
try {
|
|
1065
|
-
i.value = !i.value, i.value && F && (s.value = window.setTimeout(() => {
|
|
1066
|
-
window.removeEventListener("click", l), window.removeEventListener("keyup", l), window.addEventListener("click", l), window.addEventListener("keyup", l);
|
|
1067
|
-
}, 100)), n?.();
|
|
1068
|
-
} catch (f) {
|
|
1069
|
-
console.error(f);
|
|
1070
|
-
}
|
|
1071
|
-
}, c = (f) => {
|
|
1072
|
-
try {
|
|
1073
|
-
const m = f?.target, d = t?.value, h = e?.value;
|
|
1074
|
-
return F && d && h && !d.contains(m) && !h.contains(m) ? !0 : void 0;
|
|
1075
|
-
} catch (m) {
|
|
1076
|
-
console.error(m);
|
|
1077
|
-
return;
|
|
1078
|
-
}
|
|
1079
|
-
}, l = (f) => {
|
|
1080
|
-
try {
|
|
1081
|
-
c(f) && (F && (window.removeEventListener("click", l), window.removeEventListener("keyup", l)), i.value = !1, o?.());
|
|
1082
|
-
} catch (m) {
|
|
1083
|
-
console.error(m);
|
|
1084
|
-
}
|
|
1085
|
-
};
|
|
1086
|
-
return {
|
|
1087
|
-
open: i,
|
|
1088
|
-
toggleDropdown: r,
|
|
1089
|
-
closeDropdown: () => {
|
|
1090
|
-
try {
|
|
1091
|
-
F && (window.removeEventListener("click", l), window.removeEventListener("keyup", l)), i.value = !1, o?.();
|
|
1092
|
-
} catch (f) {
|
|
1093
|
-
console.error(f);
|
|
1094
|
-
}
|
|
1095
|
-
},
|
|
1096
|
-
clearEventListeners: () => {
|
|
1097
|
-
F && (s.value && window.clearTimeout(s.value), window.removeEventListener("click", l), window.removeEventListener("keyup", l));
|
|
1098
|
-
}
|
|
1099
|
-
};
|
|
1100
|
-
}, wn = ["data-testid"], gn = ["id", "aria-labelledby", "aria-hidden"], En = /* @__PURE__ */ oe({
|
|
1059
|
+
const gn = ["data-testid"], pn = ["id", "aria-labelledby", "aria-hidden"], Rn = /* @__PURE__ */ oe({
|
|
1101
1060
|
name: "CLDropdownMenu",
|
|
1102
1061
|
__name: "CLDropdownMenu",
|
|
1103
1062
|
props: {
|
|
@@ -1105,7 +1064,7 @@ const hn = ({
|
|
|
1105
1064
|
buttonBorderRadius: {},
|
|
1106
1065
|
buttonColor: { default: Tt.Secondary },
|
|
1107
1066
|
buttonHeight: { default: "auto" },
|
|
1108
|
-
buttonSize: { default:
|
|
1067
|
+
buttonSize: { default: ye.Small },
|
|
1109
1068
|
buttonVariant: { default: Dt.Soft },
|
|
1110
1069
|
buttonWidth: { default: "auto" },
|
|
1111
1070
|
buttonWrapped: { type: Boolean },
|
|
@@ -1114,66 +1073,66 @@ const hn = ({
|
|
|
1114
1073
|
containerElevated: { type: Boolean, default: !1 },
|
|
1115
1074
|
contentWidth: { default: "auto" },
|
|
1116
1075
|
dropdownId: {},
|
|
1117
|
-
iconAfter: { default:
|
|
1118
|
-
iconAfterSize: { default:
|
|
1076
|
+
iconAfter: { default: we.ChevronDown },
|
|
1077
|
+
iconAfterSize: { default: Lt.Tiny },
|
|
1119
1078
|
iconBefore: {},
|
|
1120
|
-
iconSize: { default:
|
|
1079
|
+
iconSize: { default: Lt.Tiny },
|
|
1121
1080
|
isOpen: { type: Boolean, default: !1 },
|
|
1122
1081
|
label: {},
|
|
1123
1082
|
onCloseHandler: {},
|
|
1124
1083
|
onOpenHandler: {},
|
|
1125
|
-
placement: { default:
|
|
1084
|
+
placement: { default: pe.BottomStart },
|
|
1126
1085
|
testId: { default: "clll-dropdown-menu" },
|
|
1127
1086
|
zIndex: { default: 30 }
|
|
1128
1087
|
},
|
|
1129
1088
|
setup(t) {
|
|
1130
|
-
ie((
|
|
1131
|
-
v69f60b10:
|
|
1089
|
+
ie((p) => ({
|
|
1090
|
+
v69f60b10: A(a)
|
|
1132
1091
|
}));
|
|
1133
1092
|
const e = t;
|
|
1134
|
-
let n =
|
|
1135
|
-
const i =
|
|
1136
|
-
|
|
1137
|
-
},
|
|
1138
|
-
r.value = !0, e?.onOpenHandler?.(), C(),
|
|
1093
|
+
let n = E(), o = E();
|
|
1094
|
+
const i = E(), l = E(), r = E(e.isOpen), s = E(e.placement), c = "clll-dropdown-menu", a = V(() => e.zIndex === "auto" || me(e.zIndex) ? e.zIndex : e.zIndex.toString()), f = () => {
|
|
1095
|
+
y.value ? u() : m();
|
|
1096
|
+
}, u = () => {
|
|
1097
|
+
r.value = !0, e?.onOpenHandler?.(), C(), mt && window.document.addEventListener("click", b);
|
|
1139
1098
|
}, m = () => {
|
|
1140
|
-
r.value = !1, e?.onCloseHandler?.(),
|
|
1141
|
-
}, d = (
|
|
1142
|
-
|
|
1143
|
-
}, h = (
|
|
1144
|
-
|
|
1099
|
+
r.value = !1, e?.onCloseHandler?.(), mt && window.document.removeEventListener("click", b), T(), w();
|
|
1100
|
+
}, d = (p) => {
|
|
1101
|
+
p && (n.value = p);
|
|
1102
|
+
}, h = (p) => {
|
|
1103
|
+
p && (o.value = p);
|
|
1145
1104
|
}, {
|
|
1146
|
-
open:
|
|
1147
|
-
toggleDropdown:
|
|
1148
|
-
closeDropdown:
|
|
1149
|
-
clearEventListeners:
|
|
1150
|
-
} =
|
|
1105
|
+
open: y,
|
|
1106
|
+
toggleDropdown: v,
|
|
1107
|
+
closeDropdown: g,
|
|
1108
|
+
clearEventListeners: w
|
|
1109
|
+
} = he({
|
|
1151
1110
|
triggerElem: n,
|
|
1152
|
-
dropdownRef:
|
|
1153
|
-
openDropdownHandler:
|
|
1111
|
+
dropdownRef: l,
|
|
1112
|
+
openDropdownHandler: f,
|
|
1154
1113
|
closeDropdownHandler: m
|
|
1155
|
-
}), { floatingStyles: x, update: C } =
|
|
1156
|
-
middleware: [
|
|
1157
|
-
placement:
|
|
1114
|
+
}), { floatingStyles: x, update: C } = hn(i, l, {
|
|
1115
|
+
middleware: [un(), an(10), fn()],
|
|
1116
|
+
placement: s,
|
|
1158
1117
|
open: r,
|
|
1159
|
-
whileElementsMounted:
|
|
1160
|
-
}), b = (
|
|
1161
|
-
r.value &&
|
|
1162
|
-
}, { clearEventListeners: T } =
|
|
1118
|
+
whileElementsMounted: cn
|
|
1119
|
+
}), b = (p) => {
|
|
1120
|
+
r.value && l.value?.contains(p?.target) && g();
|
|
1121
|
+
}, { clearEventListeners: T } = ge({ escHandler: g, triggerElem: n });
|
|
1163
1122
|
return re(() => {
|
|
1164
|
-
|
|
1165
|
-
}), (
|
|
1166
|
-
class:
|
|
1123
|
+
mt && window.document.removeEventListener("click", b), T(), w();
|
|
1124
|
+
}), (p, S) => (At(), Rt("div", {
|
|
1125
|
+
class: dt([`${c}__menu`]),
|
|
1167
1126
|
"data-testid": t.testId
|
|
1168
1127
|
}, [
|
|
1169
|
-
|
|
1170
|
-
id: `${
|
|
1128
|
+
Ot(A(ue), {
|
|
1129
|
+
id: `${c}__toggle--${t.dropdownId}`,
|
|
1171
1130
|
ref_key: "anchor",
|
|
1172
1131
|
ref: i,
|
|
1173
|
-
"aria-controls": `${
|
|
1174
|
-
"aria-expanded":
|
|
1132
|
+
"aria-controls": `${c}--${t.dropdownId}`,
|
|
1133
|
+
"aria-expanded": A(r) || t.isOpen,
|
|
1175
1134
|
"aria-label": t.buttonAriaLabel,
|
|
1176
|
-
class:
|
|
1135
|
+
class: dt(`${c}__toggle`),
|
|
1177
1136
|
color: t.buttonColor,
|
|
1178
1137
|
"border-radius": t.buttonBorderRadius,
|
|
1179
1138
|
"forward-ref": d,
|
|
@@ -1183,51 +1142,51 @@ const hn = ({
|
|
|
1183
1142
|
"icon-size": t.iconSize,
|
|
1184
1143
|
"icon-after-size": t.iconAfterSize,
|
|
1185
1144
|
size: t.buttonSize,
|
|
1186
|
-
"test-id": `${
|
|
1145
|
+
"test-id": `${c}__toggle`,
|
|
1187
1146
|
variant: t.buttonVariant,
|
|
1188
1147
|
width: t.buttonWidth,
|
|
1189
1148
|
wrap: t.buttonWrapped,
|
|
1190
|
-
onClick:
|
|
1149
|
+
onClick: A(v)
|
|
1191
1150
|
}, {
|
|
1192
|
-
default:
|
|
1193
|
-
|
|
1151
|
+
default: Et(() => [
|
|
1152
|
+
se(ce(t.label), 1)
|
|
1194
1153
|
]),
|
|
1195
1154
|
_: 1
|
|
1196
1155
|
}, 8, ["id", "aria-controls", "aria-expanded", "aria-label", "class", "color", "border-radius", "height", "icon-after", "icon-before", "icon-size", "icon-after-size", "size", "test-id", "variant", "width", "wrap", "onClick"]),
|
|
1197
|
-
|
|
1156
|
+
A(r) || t.isOpen ? (At(), Rt("div", {
|
|
1198
1157
|
key: 0,
|
|
1199
|
-
id: `${
|
|
1158
|
+
id: `${c}--${t.dropdownId}`,
|
|
1200
1159
|
ref_key: "dropdownElem",
|
|
1201
|
-
ref:
|
|
1202
|
-
"aria-labelledby": `${
|
|
1203
|
-
"aria-hidden": !(
|
|
1204
|
-
class:
|
|
1205
|
-
`${
|
|
1206
|
-
`${
|
|
1160
|
+
ref: l,
|
|
1161
|
+
"aria-labelledby": `${c}__toggle--${t.dropdownId}`,
|
|
1162
|
+
"aria-hidden": !(A(r) || t.isOpen),
|
|
1163
|
+
class: dt([
|
|
1164
|
+
`${c}__dropdown`,
|
|
1165
|
+
`${c}__dropdown--${A(s)}`
|
|
1207
1166
|
]),
|
|
1208
|
-
style: ae(
|
|
1167
|
+
style: ae(A(x))
|
|
1209
1168
|
}, [
|
|
1210
|
-
|
|
1169
|
+
Ot(A(de), {
|
|
1211
1170
|
bordered: t.containerBordered,
|
|
1212
1171
|
"border-radius": t.containerBorderRadius,
|
|
1213
|
-
color:
|
|
1172
|
+
color: A(Tt).Neutral,
|
|
1214
1173
|
elevated: t.containerElevated,
|
|
1215
1174
|
"forward-ref": h,
|
|
1216
1175
|
padded: !1,
|
|
1217
|
-
"test-id": `${
|
|
1218
|
-
variant:
|
|
1176
|
+
"test-id": `${c}__content`,
|
|
1177
|
+
variant: A(Dt).Ghost,
|
|
1219
1178
|
width: t.contentWidth
|
|
1220
1179
|
}, {
|
|
1221
|
-
default:
|
|
1222
|
-
fe(
|
|
1180
|
+
default: Et(() => [
|
|
1181
|
+
fe(p.$slots, "content")
|
|
1223
1182
|
]),
|
|
1224
1183
|
_: 3
|
|
1225
1184
|
}, 8, ["bordered", "border-radius", "color", "elevated", "test-id", "variant", "width"])
|
|
1226
|
-
], 14,
|
|
1227
|
-
], 10,
|
|
1185
|
+
], 14, pn)) : le("", !0)
|
|
1186
|
+
], 10, gn));
|
|
1228
1187
|
}
|
|
1229
1188
|
});
|
|
1230
1189
|
export {
|
|
1231
|
-
|
|
1232
|
-
|
|
1190
|
+
Rn as CLDropdownMenu,
|
|
1191
|
+
Rn as default
|
|
1233
1192
|
};
|