tgui-core 1.8.3 → 2.0.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/dist/common/constants.d.ts +4 -0
- package/dist/common/constants.js +17 -0
- package/dist/common/hotkeys.js +48 -48
- package/dist/common/ui.d.ts +6 -0
- package/dist/common/ui.js +63 -59
- package/dist/components/AnimatedNumber.d.ts +1 -1
- package/dist/components/Button.d.ts +3 -3
- package/dist/components/Button.js +21 -22
- package/dist/components/Chart.d.ts +3 -15
- package/dist/components/Chart.js +68 -86
- package/dist/components/ColorBox.js +3 -3
- package/dist/components/Dialog.d.ts +16 -0
- package/dist/components/Dialog.js +5 -5
- package/dist/components/DmIcon.d.ts +1 -1
- package/dist/components/DraggableControl.d.ts +56 -0
- package/dist/components/DraggableControl.js +126 -176
- package/dist/components/Dropdown.d.ts +5 -5
- package/dist/components/Dropdown.js +135 -132
- package/dist/components/FitText.d.ts +1 -1
- package/dist/components/Flex.js +24 -26
- package/dist/components/Floating.d.ts +75 -0
- package/dist/components/Floating.js +2235 -0
- package/dist/components/ImageButton.d.ts +2 -3
- package/dist/components/ImageButton.js +88 -98
- package/dist/components/InfinitePlane.d.ts +35 -32
- package/dist/components/InfinitePlane.js +123 -133
- package/dist/components/Knob.d.ts +22 -6
- package/dist/components/Knob.js +45 -46
- package/dist/components/MenuBar.js +81 -97
- package/dist/components/Modal.js +12 -12
- package/dist/components/NumberInput.d.ts +1 -1
- package/dist/components/Popper.d.ts +5 -1
- package/dist/components/Popper.js +1026 -121
- package/dist/components/ProgressBar.js +3 -3
- package/dist/components/RoundGauge.js +30 -30
- package/dist/components/Section.js +7 -7
- package/dist/components/Slider.d.ts +22 -6
- package/dist/components/Slider.js +55 -56
- package/dist/components/Stack.js +3 -3
- package/dist/components/Table.js +7 -7
- package/dist/components/Tabs.js +7 -7
- package/dist/components/TextArea.d.ts +17 -0
- package/dist/components/TextArea.js +35 -33
- package/dist/components/Tooltip.d.ts +3 -34
- package/dist/components/Tooltip.js +14 -77
- package/dist/components/TrackOutsideClicks.d.ts +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +64 -62
- package/package.json +26 -27
- package/styles/base.scss +13 -11
- package/styles/colors.scss +63 -67
- package/styles/components/BlockQuote.scss +5 -8
- package/styles/components/Button.scss +123 -99
- package/styles/components/Dialog.scss +23 -30
- package/styles/components/Dimmer.scss +3 -8
- package/styles/components/Divider.scss +6 -7
- package/styles/components/Dropdown.scss +97 -52
- package/styles/components/Flex.scss +0 -1
- package/styles/components/Floating.scss +60 -0
- package/styles/components/ImageButton.scss +136 -192
- package/styles/components/Input.scss +24 -26
- package/styles/components/Knob.scss +37 -41
- package/styles/components/LabeledList.scss +8 -6
- package/styles/components/MenuBar.scss +17 -21
- package/styles/components/Modal.scss +8 -7
- package/styles/components/NoticeBox.scss +22 -26
- package/styles/components/NumberInput.scss +30 -28
- package/styles/components/ProgressBar.scss +27 -19
- package/styles/components/RoundGauge.scss +46 -26
- package/styles/components/Section.scss +17 -32
- package/styles/components/Slider.scss +18 -15
- package/styles/components/Stack.scss +8 -48
- package/styles/components/Table.scss +2 -2
- package/styles/components/Tabs.scss +92 -66
- package/styles/components/TextArea.scss +32 -36
- package/styles/components/Tooltip.scss +10 -13
- package/styles/functions.scss +1 -62
- package/styles/main.scss +6 -1
- package/styles/reset.scss +7 -11
- package/styles/vars-colors.scss +108 -0
- package/styles/vars-components.scss +162 -0
- package/styles/vars-values.scss +110 -0
- package/dist/popper-CiqSDJTE.js +0 -906
package/dist/popper-CiqSDJTE.js
DELETED
|
@@ -1,906 +0,0 @@
|
|
|
1
|
-
var B = "top", S = "bottom", L = "right", $ = "left", Pt = "auto", ft = [B, S, L, $], Q = "start", ot = "end", ue = "clippingParents", Kt = "viewport", nt = "popper", le = "reference", Ft = /* @__PURE__ */ ft.reduce(function(t, e) {
|
|
2
|
-
return t.concat([e + "-" + Q, e + "-" + ot]);
|
|
3
|
-
}, []), Qt = /* @__PURE__ */ [].concat(ft, [Pt]).reduce(function(t, e) {
|
|
4
|
-
return t.concat([e, e + "-" + Q, e + "-" + ot]);
|
|
5
|
-
}, []), ve = "beforeRead", de = "read", he = "afterRead", me = "beforeMain", ge = "main", ye = "afterMain", be = "beforeWrite", we = "write", xe = "afterWrite", Oe = [ve, de, he, me, ge, ye, be, we, xe];
|
|
6
|
-
function V(t) {
|
|
7
|
-
return t ? (t.nodeName || "").toLowerCase() : null;
|
|
8
|
-
}
|
|
9
|
-
function k(t) {
|
|
10
|
-
if (t == null)
|
|
11
|
-
return window;
|
|
12
|
-
if (t.toString() !== "[object Window]") {
|
|
13
|
-
var e = t.ownerDocument;
|
|
14
|
-
return e && e.defaultView || window;
|
|
15
|
-
}
|
|
16
|
-
return t;
|
|
17
|
-
}
|
|
18
|
-
function J(t) {
|
|
19
|
-
var e = k(t).Element;
|
|
20
|
-
return t instanceof e || t instanceof Element;
|
|
21
|
-
}
|
|
22
|
-
function T(t) {
|
|
23
|
-
var e = k(t).HTMLElement;
|
|
24
|
-
return t instanceof e || t instanceof HTMLElement;
|
|
25
|
-
}
|
|
26
|
-
function Dt(t) {
|
|
27
|
-
if (typeof ShadowRoot > "u")
|
|
28
|
-
return !1;
|
|
29
|
-
var e = k(t).ShadowRoot;
|
|
30
|
-
return t instanceof e || t instanceof ShadowRoot;
|
|
31
|
-
}
|
|
32
|
-
function Ae(t) {
|
|
33
|
-
var e = t.state;
|
|
34
|
-
Object.keys(e.elements).forEach(function(r) {
|
|
35
|
-
var n = e.styles[r] || {}, a = e.attributes[r] || {}, i = e.elements[r];
|
|
36
|
-
!T(i) || !V(i) || (Object.assign(i.style, n), Object.keys(a).forEach(function(p) {
|
|
37
|
-
var s = a[p];
|
|
38
|
-
s === !1 ? i.removeAttribute(p) : i.setAttribute(p, s === !0 ? "" : s);
|
|
39
|
-
}));
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
function Ee(t) {
|
|
43
|
-
var e = t.state, r = {
|
|
44
|
-
popper: {
|
|
45
|
-
position: e.options.strategy,
|
|
46
|
-
left: "0",
|
|
47
|
-
top: "0",
|
|
48
|
-
margin: "0"
|
|
49
|
-
},
|
|
50
|
-
arrow: {
|
|
51
|
-
position: "absolute"
|
|
52
|
-
},
|
|
53
|
-
reference: {}
|
|
54
|
-
};
|
|
55
|
-
return Object.assign(e.elements.popper.style, r.popper), e.styles = r, e.elements.arrow && Object.assign(e.elements.arrow.style, r.arrow), function() {
|
|
56
|
-
Object.keys(e.elements).forEach(function(n) {
|
|
57
|
-
var a = e.elements[n], i = e.attributes[n] || {}, p = Object.keys(e.styles.hasOwnProperty(n) ? e.styles[n] : r[n]), s = p.reduce(function(o, c) {
|
|
58
|
-
return o[c] = "", o;
|
|
59
|
-
}, {});
|
|
60
|
-
!T(a) || !V(a) || (Object.assign(a.style, s), Object.keys(i).forEach(function(o) {
|
|
61
|
-
a.removeAttribute(o);
|
|
62
|
-
}));
|
|
63
|
-
});
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
const Pe = {
|
|
67
|
-
name: "applyStyles",
|
|
68
|
-
enabled: !0,
|
|
69
|
-
phase: "write",
|
|
70
|
-
fn: Ae,
|
|
71
|
-
effect: Ee,
|
|
72
|
-
requires: ["computeStyles"]
|
|
73
|
-
};
|
|
74
|
-
function H(t) {
|
|
75
|
-
return t.split("-")[0];
|
|
76
|
-
}
|
|
77
|
-
var G = Math.max, gt = Math.min, Z = Math.round;
|
|
78
|
-
function At() {
|
|
79
|
-
var t = navigator.userAgentData;
|
|
80
|
-
return t != null && t.brands && Array.isArray(t.brands) ? t.brands.map(function(e) {
|
|
81
|
-
return e.brand + "/" + e.version;
|
|
82
|
-
}).join(" ") : navigator.userAgent;
|
|
83
|
-
}
|
|
84
|
-
function Zt() {
|
|
85
|
-
return !/^((?!chrome|android).)*safari/i.test(At());
|
|
86
|
-
}
|
|
87
|
-
function _(t, e, r) {
|
|
88
|
-
e === void 0 && (e = !1), r === void 0 && (r = !1);
|
|
89
|
-
var n = t.getBoundingClientRect(), a = 1, i = 1;
|
|
90
|
-
e && T(t) && (a = t.offsetWidth > 0 && Z(n.width) / t.offsetWidth || 1, i = t.offsetHeight > 0 && Z(n.height) / t.offsetHeight || 1);
|
|
91
|
-
var p = J(t) ? k(t) : window, s = p.visualViewport, o = !Zt() && r, c = (n.left + (o && s ? s.offsetLeft : 0)) / a, f = (n.top + (o && s ? s.offsetTop : 0)) / i, h = n.width / a, y = n.height / i;
|
|
92
|
-
return {
|
|
93
|
-
width: h,
|
|
94
|
-
height: y,
|
|
95
|
-
top: f,
|
|
96
|
-
right: c + h,
|
|
97
|
-
bottom: f + y,
|
|
98
|
-
left: c,
|
|
99
|
-
x: c,
|
|
100
|
-
y: f
|
|
101
|
-
};
|
|
102
|
-
}
|
|
103
|
-
function jt(t) {
|
|
104
|
-
var e = _(t), r = t.offsetWidth, n = t.offsetHeight;
|
|
105
|
-
return Math.abs(e.width - r) <= 1 && (r = e.width), Math.abs(e.height - n) <= 1 && (n = e.height), {
|
|
106
|
-
x: t.offsetLeft,
|
|
107
|
-
y: t.offsetTop,
|
|
108
|
-
width: r,
|
|
109
|
-
height: n
|
|
110
|
-
};
|
|
111
|
-
}
|
|
112
|
-
function _t(t, e) {
|
|
113
|
-
var r = e.getRootNode && e.getRootNode();
|
|
114
|
-
if (t.contains(e))
|
|
115
|
-
return !0;
|
|
116
|
-
if (r && Dt(r)) {
|
|
117
|
-
var n = e;
|
|
118
|
-
do {
|
|
119
|
-
if (n && t.isSameNode(n))
|
|
120
|
-
return !0;
|
|
121
|
-
n = n.parentNode || n.host;
|
|
122
|
-
} while (n);
|
|
123
|
-
}
|
|
124
|
-
return !1;
|
|
125
|
-
}
|
|
126
|
-
function N(t) {
|
|
127
|
-
return k(t).getComputedStyle(t);
|
|
128
|
-
}
|
|
129
|
-
function De(t) {
|
|
130
|
-
return ["table", "td", "th"].indexOf(V(t)) >= 0;
|
|
131
|
-
}
|
|
132
|
-
function q(t) {
|
|
133
|
-
return ((J(t) ? t.ownerDocument : (
|
|
134
|
-
// $FlowFixMe[prop-missing]
|
|
135
|
-
t.document
|
|
136
|
-
)) || window.document).documentElement;
|
|
137
|
-
}
|
|
138
|
-
function yt(t) {
|
|
139
|
-
return V(t) === "html" ? t : (
|
|
140
|
-
// this is a quicker (but less type safe) way to save quite some bytes from the bundle
|
|
141
|
-
// $FlowFixMe[incompatible-return]
|
|
142
|
-
// $FlowFixMe[prop-missing]
|
|
143
|
-
t.assignedSlot || // step into the shadow DOM of the parent of a slotted node
|
|
144
|
-
t.parentNode || // DOM Element detected
|
|
145
|
-
(Dt(t) ? t.host : null) || // ShadowRoot detected
|
|
146
|
-
// $FlowFixMe[incompatible-call]: HTMLElement is a Node
|
|
147
|
-
q(t)
|
|
148
|
-
);
|
|
149
|
-
}
|
|
150
|
-
function qt(t) {
|
|
151
|
-
return !T(t) || // https://github.com/popperjs/popper-core/issues/837
|
|
152
|
-
N(t).position === "fixed" ? null : t.offsetParent;
|
|
153
|
-
}
|
|
154
|
-
function je(t) {
|
|
155
|
-
var e = /firefox/i.test(At()), r = /Trident/i.test(At());
|
|
156
|
-
if (r && T(t)) {
|
|
157
|
-
var n = N(t);
|
|
158
|
-
if (n.position === "fixed")
|
|
159
|
-
return null;
|
|
160
|
-
}
|
|
161
|
-
var a = yt(t);
|
|
162
|
-
for (Dt(a) && (a = a.host); T(a) && ["html", "body"].indexOf(V(a)) < 0; ) {
|
|
163
|
-
var i = N(a);
|
|
164
|
-
if (i.transform !== "none" || i.perspective !== "none" || i.contain === "paint" || ["transform", "perspective"].indexOf(i.willChange) !== -1 || e && i.willChange === "filter" || e && i.filter && i.filter !== "none")
|
|
165
|
-
return a;
|
|
166
|
-
a = a.parentNode;
|
|
167
|
-
}
|
|
168
|
-
return null;
|
|
169
|
-
}
|
|
170
|
-
function pt(t) {
|
|
171
|
-
for (var e = k(t), r = qt(t); r && De(r) && N(r).position === "static"; )
|
|
172
|
-
r = qt(r);
|
|
173
|
-
return r && (V(r) === "html" || V(r) === "body" && N(r).position === "static") ? e : r || je(t) || e;
|
|
174
|
-
}
|
|
175
|
-
function Rt(t) {
|
|
176
|
-
return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y";
|
|
177
|
-
}
|
|
178
|
-
function at(t, e, r) {
|
|
179
|
-
return G(t, gt(e, r));
|
|
180
|
-
}
|
|
181
|
-
function Re(t, e, r) {
|
|
182
|
-
var n = at(t, e, r);
|
|
183
|
-
return n > r ? r : n;
|
|
184
|
-
}
|
|
185
|
-
function te() {
|
|
186
|
-
return {
|
|
187
|
-
top: 0,
|
|
188
|
-
right: 0,
|
|
189
|
-
bottom: 0,
|
|
190
|
-
left: 0
|
|
191
|
-
};
|
|
192
|
-
}
|
|
193
|
-
function ee(t) {
|
|
194
|
-
return Object.assign({}, te(), t);
|
|
195
|
-
}
|
|
196
|
-
function re(t, e) {
|
|
197
|
-
return e.reduce(function(r, n) {
|
|
198
|
-
return r[n] = t, r;
|
|
199
|
-
}, {});
|
|
200
|
-
}
|
|
201
|
-
var Be = function(e, r) {
|
|
202
|
-
return e = typeof e == "function" ? e(Object.assign({}, r.rects, {
|
|
203
|
-
placement: r.placement
|
|
204
|
-
})) : e, ee(typeof e != "number" ? e : re(e, ft));
|
|
205
|
-
};
|
|
206
|
-
function $e(t) {
|
|
207
|
-
var e, r = t.state, n = t.name, a = t.options, i = r.elements.arrow, p = r.modifiersData.popperOffsets, s = H(r.placement), o = Rt(s), c = [$, L].indexOf(s) >= 0, f = c ? "height" : "width";
|
|
208
|
-
if (!(!i || !p)) {
|
|
209
|
-
var h = Be(a.padding, r), y = jt(i), u = o === "y" ? B : $, w = o === "y" ? S : L, d = r.rects.reference[f] + r.rects.reference[o] - p[o] - r.rects.popper[f], v = p[o] - r.rects.reference[o], b = pt(i), O = b ? o === "y" ? b.clientHeight || 0 : b.clientWidth || 0 : 0, A = d / 2 - v / 2, l = h[u], m = O - y[f] - h[w], g = O / 2 - y[f] / 2 + A, x = at(l, g, m), D = o;
|
|
210
|
-
r.modifiersData[n] = (e = {}, e[D] = x, e.centerOffset = x - g, e);
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
function Ce(t) {
|
|
214
|
-
var e = t.state, r = t.options, n = r.element, a = n === void 0 ? "[data-popper-arrow]" : n;
|
|
215
|
-
a != null && (typeof a == "string" && (a = e.elements.popper.querySelector(a), !a) || _t(e.elements.popper, a) && (e.elements.arrow = a));
|
|
216
|
-
}
|
|
217
|
-
const ke = {
|
|
218
|
-
name: "arrow",
|
|
219
|
-
enabled: !0,
|
|
220
|
-
phase: "main",
|
|
221
|
-
fn: $e,
|
|
222
|
-
effect: Ce,
|
|
223
|
-
requires: ["popperOffsets"],
|
|
224
|
-
requiresIfExists: ["preventOverflow"]
|
|
225
|
-
};
|
|
226
|
-
function tt(t) {
|
|
227
|
-
return t.split("-")[1];
|
|
228
|
-
}
|
|
229
|
-
var Te = {
|
|
230
|
-
top: "auto",
|
|
231
|
-
right: "auto",
|
|
232
|
-
bottom: "auto",
|
|
233
|
-
left: "auto"
|
|
234
|
-
};
|
|
235
|
-
function Se(t, e) {
|
|
236
|
-
var r = t.x, n = t.y, a = e.devicePixelRatio || 1;
|
|
237
|
-
return {
|
|
238
|
-
x: Z(r * a) / a || 0,
|
|
239
|
-
y: Z(n * a) / a || 0
|
|
240
|
-
};
|
|
241
|
-
}
|
|
242
|
-
function Xt(t) {
|
|
243
|
-
var e, r = t.popper, n = t.popperRect, a = t.placement, i = t.variation, p = t.offsets, s = t.position, o = t.gpuAcceleration, c = t.adaptive, f = t.roundOffsets, h = t.isFixed, y = p.x, u = y === void 0 ? 0 : y, w = p.y, d = w === void 0 ? 0 : w, v = typeof f == "function" ? f({
|
|
244
|
-
x: u,
|
|
245
|
-
y: d
|
|
246
|
-
}) : {
|
|
247
|
-
x: u,
|
|
248
|
-
y: d
|
|
249
|
-
};
|
|
250
|
-
u = v.x, d = v.y;
|
|
251
|
-
var b = p.hasOwnProperty("x"), O = p.hasOwnProperty("y"), A = $, l = B, m = window;
|
|
252
|
-
if (c) {
|
|
253
|
-
var g = pt(r), x = "clientHeight", D = "clientWidth";
|
|
254
|
-
if (g === k(r) && (g = q(r), N(g).position !== "static" && s === "absolute" && (x = "scrollHeight", D = "scrollWidth")), g = g, a === B || (a === $ || a === L) && i === ot) {
|
|
255
|
-
l = S;
|
|
256
|
-
var P = h && g === m && m.visualViewport ? m.visualViewport.height : (
|
|
257
|
-
// $FlowFixMe[prop-missing]
|
|
258
|
-
g[x]
|
|
259
|
-
);
|
|
260
|
-
d -= P - n.height, d *= o ? 1 : -1;
|
|
261
|
-
}
|
|
262
|
-
if (a === $ || (a === B || a === S) && i === ot) {
|
|
263
|
-
A = L;
|
|
264
|
-
var E = h && g === m && m.visualViewport ? m.visualViewport.width : (
|
|
265
|
-
// $FlowFixMe[prop-missing]
|
|
266
|
-
g[D]
|
|
267
|
-
);
|
|
268
|
-
u -= E - n.width, u *= o ? 1 : -1;
|
|
269
|
-
}
|
|
270
|
-
}
|
|
271
|
-
var j = Object.assign({
|
|
272
|
-
position: s
|
|
273
|
-
}, c && Te), M = f === !0 ? Se({
|
|
274
|
-
x: u,
|
|
275
|
-
y: d
|
|
276
|
-
}, k(r)) : {
|
|
277
|
-
x: u,
|
|
278
|
-
y: d
|
|
279
|
-
};
|
|
280
|
-
if (u = M.x, d = M.y, o) {
|
|
281
|
-
var R;
|
|
282
|
-
return Object.assign({}, j, (R = {}, R[l] = O ? "0" : "", R[A] = b ? "0" : "", R.transform = (m.devicePixelRatio || 1) <= 1 ? "translate(" + u + "px, " + d + "px)" : "translate3d(" + u + "px, " + d + "px, 0)", R));
|
|
283
|
-
}
|
|
284
|
-
return Object.assign({}, j, (e = {}, e[l] = O ? d + "px" : "", e[A] = b ? u + "px" : "", e.transform = "", e));
|
|
285
|
-
}
|
|
286
|
-
function Le(t) {
|
|
287
|
-
var e = t.state, r = t.options, n = r.gpuAcceleration, a = n === void 0 ? !0 : n, i = r.adaptive, p = i === void 0 ? !0 : i, s = r.roundOffsets, o = s === void 0 ? !0 : s, c = {
|
|
288
|
-
placement: H(e.placement),
|
|
289
|
-
variation: tt(e.placement),
|
|
290
|
-
popper: e.elements.popper,
|
|
291
|
-
popperRect: e.rects.popper,
|
|
292
|
-
gpuAcceleration: a,
|
|
293
|
-
isFixed: e.options.strategy === "fixed"
|
|
294
|
-
};
|
|
295
|
-
e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Xt(Object.assign({}, c, {
|
|
296
|
-
offsets: e.modifiersData.popperOffsets,
|
|
297
|
-
position: e.options.strategy,
|
|
298
|
-
adaptive: p,
|
|
299
|
-
roundOffsets: o
|
|
300
|
-
})))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Xt(Object.assign({}, c, {
|
|
301
|
-
offsets: e.modifiersData.arrow,
|
|
302
|
-
position: "absolute",
|
|
303
|
-
adaptive: !1,
|
|
304
|
-
roundOffsets: o
|
|
305
|
-
})))), e.attributes.popper = Object.assign({}, e.attributes.popper, {
|
|
306
|
-
"data-popper-placement": e.placement
|
|
307
|
-
});
|
|
308
|
-
}
|
|
309
|
-
const Me = {
|
|
310
|
-
name: "computeStyles",
|
|
311
|
-
enabled: !0,
|
|
312
|
-
phase: "beforeWrite",
|
|
313
|
-
fn: Le,
|
|
314
|
-
data: {}
|
|
315
|
-
};
|
|
316
|
-
var ht = {
|
|
317
|
-
passive: !0
|
|
318
|
-
};
|
|
319
|
-
function We(t) {
|
|
320
|
-
var e = t.state, r = t.instance, n = t.options, a = n.scroll, i = a === void 0 ? !0 : a, p = n.resize, s = p === void 0 ? !0 : p, o = k(e.elements.popper), c = [].concat(e.scrollParents.reference, e.scrollParents.popper);
|
|
321
|
-
return i && c.forEach(function(f) {
|
|
322
|
-
f.addEventListener("scroll", r.update, ht);
|
|
323
|
-
}), s && o.addEventListener("resize", r.update, ht), function() {
|
|
324
|
-
i && c.forEach(function(f) {
|
|
325
|
-
f.removeEventListener("scroll", r.update, ht);
|
|
326
|
-
}), s && o.removeEventListener("resize", r.update, ht);
|
|
327
|
-
};
|
|
328
|
-
}
|
|
329
|
-
const He = {
|
|
330
|
-
name: "eventListeners",
|
|
331
|
-
enabled: !0,
|
|
332
|
-
phase: "write",
|
|
333
|
-
fn: function() {
|
|
334
|
-
},
|
|
335
|
-
effect: We,
|
|
336
|
-
data: {}
|
|
337
|
-
};
|
|
338
|
-
var Ve = {
|
|
339
|
-
left: "right",
|
|
340
|
-
right: "left",
|
|
341
|
-
bottom: "top",
|
|
342
|
-
top: "bottom"
|
|
343
|
-
};
|
|
344
|
-
function mt(t) {
|
|
345
|
-
return t.replace(/left|right|bottom|top/g, function(e) {
|
|
346
|
-
return Ve[e];
|
|
347
|
-
});
|
|
348
|
-
}
|
|
349
|
-
var Ne = {
|
|
350
|
-
start: "end",
|
|
351
|
-
end: "start"
|
|
352
|
-
};
|
|
353
|
-
function It(t) {
|
|
354
|
-
return t.replace(/start|end/g, function(e) {
|
|
355
|
-
return Ne[e];
|
|
356
|
-
});
|
|
357
|
-
}
|
|
358
|
-
function Bt(t) {
|
|
359
|
-
var e = k(t), r = e.pageXOffset, n = e.pageYOffset;
|
|
360
|
-
return {
|
|
361
|
-
scrollLeft: r,
|
|
362
|
-
scrollTop: n
|
|
363
|
-
};
|
|
364
|
-
}
|
|
365
|
-
function $t(t) {
|
|
366
|
-
return _(q(t)).left + Bt(t).scrollLeft;
|
|
367
|
-
}
|
|
368
|
-
function Fe(t, e) {
|
|
369
|
-
var r = k(t), n = q(t), a = r.visualViewport, i = n.clientWidth, p = n.clientHeight, s = 0, o = 0;
|
|
370
|
-
if (a) {
|
|
371
|
-
i = a.width, p = a.height;
|
|
372
|
-
var c = Zt();
|
|
373
|
-
(c || !c && e === "fixed") && (s = a.offsetLeft, o = a.offsetTop);
|
|
374
|
-
}
|
|
375
|
-
return {
|
|
376
|
-
width: i,
|
|
377
|
-
height: p,
|
|
378
|
-
x: s + $t(t),
|
|
379
|
-
y: o
|
|
380
|
-
};
|
|
381
|
-
}
|
|
382
|
-
function qe(t) {
|
|
383
|
-
var e, r = q(t), n = Bt(t), a = (e = t.ownerDocument) == null ? void 0 : e.body, i = G(r.scrollWidth, r.clientWidth, a ? a.scrollWidth : 0, a ? a.clientWidth : 0), p = G(r.scrollHeight, r.clientHeight, a ? a.scrollHeight : 0, a ? a.clientHeight : 0), s = -n.scrollLeft + $t(t), o = -n.scrollTop;
|
|
384
|
-
return N(a || r).direction === "rtl" && (s += G(r.clientWidth, a ? a.clientWidth : 0) - i), {
|
|
385
|
-
width: i,
|
|
386
|
-
height: p,
|
|
387
|
-
x: s,
|
|
388
|
-
y: o
|
|
389
|
-
};
|
|
390
|
-
}
|
|
391
|
-
function Ct(t) {
|
|
392
|
-
var e = N(t), r = e.overflow, n = e.overflowX, a = e.overflowY;
|
|
393
|
-
return /auto|scroll|overlay|hidden/.test(r + a + n);
|
|
394
|
-
}
|
|
395
|
-
function ne(t) {
|
|
396
|
-
return ["html", "body", "#document"].indexOf(V(t)) >= 0 ? t.ownerDocument.body : T(t) && Ct(t) ? t : ne(yt(t));
|
|
397
|
-
}
|
|
398
|
-
function it(t, e) {
|
|
399
|
-
var r;
|
|
400
|
-
e === void 0 && (e = []);
|
|
401
|
-
var n = ne(t), a = n === ((r = t.ownerDocument) == null ? void 0 : r.body), i = k(n), p = a ? [i].concat(i.visualViewport || [], Ct(n) ? n : []) : n, s = e.concat(p);
|
|
402
|
-
return a ? s : (
|
|
403
|
-
// $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
|
|
404
|
-
s.concat(it(yt(p)))
|
|
405
|
-
);
|
|
406
|
-
}
|
|
407
|
-
function Et(t) {
|
|
408
|
-
return Object.assign({}, t, {
|
|
409
|
-
left: t.x,
|
|
410
|
-
top: t.y,
|
|
411
|
-
right: t.x + t.width,
|
|
412
|
-
bottom: t.y + t.height
|
|
413
|
-
});
|
|
414
|
-
}
|
|
415
|
-
function Xe(t, e) {
|
|
416
|
-
var r = _(t, !1, e === "fixed");
|
|
417
|
-
return r.top = r.top + t.clientTop, r.left = r.left + t.clientLeft, r.bottom = r.top + t.clientHeight, r.right = r.left + t.clientWidth, r.width = t.clientWidth, r.height = t.clientHeight, r.x = r.left, r.y = r.top, r;
|
|
418
|
-
}
|
|
419
|
-
function Yt(t, e, r) {
|
|
420
|
-
return e === Kt ? Et(Fe(t, r)) : J(e) ? Xe(e, r) : Et(qe(q(t)));
|
|
421
|
-
}
|
|
422
|
-
function Ie(t) {
|
|
423
|
-
var e = it(yt(t)), r = ["absolute", "fixed"].indexOf(N(t).position) >= 0, n = r && T(t) ? pt(t) : t;
|
|
424
|
-
return J(n) ? e.filter(function(a) {
|
|
425
|
-
return J(a) && _t(a, n) && V(a) !== "body";
|
|
426
|
-
}) : [];
|
|
427
|
-
}
|
|
428
|
-
function Ye(t, e, r, n) {
|
|
429
|
-
var a = e === "clippingParents" ? Ie(t) : [].concat(e), i = [].concat(a, [r]), p = i[0], s = i.reduce(function(o, c) {
|
|
430
|
-
var f = Yt(t, c, n);
|
|
431
|
-
return o.top = G(f.top, o.top), o.right = gt(f.right, o.right), o.bottom = gt(f.bottom, o.bottom), o.left = G(f.left, o.left), o;
|
|
432
|
-
}, Yt(t, p, n));
|
|
433
|
-
return s.width = s.right - s.left, s.height = s.bottom - s.top, s.x = s.left, s.y = s.top, s;
|
|
434
|
-
}
|
|
435
|
-
function ae(t) {
|
|
436
|
-
var e = t.reference, r = t.element, n = t.placement, a = n ? H(n) : null, i = n ? tt(n) : null, p = e.x + e.width / 2 - r.width / 2, s = e.y + e.height / 2 - r.height / 2, o;
|
|
437
|
-
switch (a) {
|
|
438
|
-
case B:
|
|
439
|
-
o = {
|
|
440
|
-
x: p,
|
|
441
|
-
y: e.y - r.height
|
|
442
|
-
};
|
|
443
|
-
break;
|
|
444
|
-
case S:
|
|
445
|
-
o = {
|
|
446
|
-
x: p,
|
|
447
|
-
y: e.y + e.height
|
|
448
|
-
};
|
|
449
|
-
break;
|
|
450
|
-
case L:
|
|
451
|
-
o = {
|
|
452
|
-
x: e.x + e.width,
|
|
453
|
-
y: s
|
|
454
|
-
};
|
|
455
|
-
break;
|
|
456
|
-
case $:
|
|
457
|
-
o = {
|
|
458
|
-
x: e.x - r.width,
|
|
459
|
-
y: s
|
|
460
|
-
};
|
|
461
|
-
break;
|
|
462
|
-
default:
|
|
463
|
-
o = {
|
|
464
|
-
x: e.x,
|
|
465
|
-
y: e.y
|
|
466
|
-
};
|
|
467
|
-
}
|
|
468
|
-
var c = a ? Rt(a) : null;
|
|
469
|
-
if (c != null) {
|
|
470
|
-
var f = c === "y" ? "height" : "width";
|
|
471
|
-
switch (i) {
|
|
472
|
-
case Q:
|
|
473
|
-
o[c] = o[c] - (e[f] / 2 - r[f] / 2);
|
|
474
|
-
break;
|
|
475
|
-
case ot:
|
|
476
|
-
o[c] = o[c] + (e[f] / 2 - r[f] / 2);
|
|
477
|
-
break;
|
|
478
|
-
}
|
|
479
|
-
}
|
|
480
|
-
return o;
|
|
481
|
-
}
|
|
482
|
-
function st(t, e) {
|
|
483
|
-
e === void 0 && (e = {});
|
|
484
|
-
var r = e, n = r.placement, a = n === void 0 ? t.placement : n, i = r.strategy, p = i === void 0 ? t.strategy : i, s = r.boundary, o = s === void 0 ? ue : s, c = r.rootBoundary, f = c === void 0 ? Kt : c, h = r.elementContext, y = h === void 0 ? nt : h, u = r.altBoundary, w = u === void 0 ? !1 : u, d = r.padding, v = d === void 0 ? 0 : d, b = ee(typeof v != "number" ? v : re(v, ft)), O = y === nt ? le : nt, A = t.rects.popper, l = t.elements[w ? O : y], m = Ye(J(l) ? l : l.contextElement || q(t.elements.popper), o, f, p), g = _(t.elements.reference), x = ae({
|
|
485
|
-
reference: g,
|
|
486
|
-
element: A,
|
|
487
|
-
strategy: "absolute",
|
|
488
|
-
placement: a
|
|
489
|
-
}), D = Et(Object.assign({}, A, x)), P = y === nt ? D : g, E = {
|
|
490
|
-
top: m.top - P.top + b.top,
|
|
491
|
-
bottom: P.bottom - m.bottom + b.bottom,
|
|
492
|
-
left: m.left - P.left + b.left,
|
|
493
|
-
right: P.right - m.right + b.right
|
|
494
|
-
}, j = t.modifiersData.offset;
|
|
495
|
-
if (y === nt && j) {
|
|
496
|
-
var M = j[a];
|
|
497
|
-
Object.keys(E).forEach(function(R) {
|
|
498
|
-
var X = [L, S].indexOf(R) >= 0 ? 1 : -1, I = [B, S].indexOf(R) >= 0 ? "y" : "x";
|
|
499
|
-
E[R] += M[I] * X;
|
|
500
|
-
});
|
|
501
|
-
}
|
|
502
|
-
return E;
|
|
503
|
-
}
|
|
504
|
-
function ze(t, e) {
|
|
505
|
-
e === void 0 && (e = {});
|
|
506
|
-
var r = e, n = r.placement, a = r.boundary, i = r.rootBoundary, p = r.padding, s = r.flipVariations, o = r.allowedAutoPlacements, c = o === void 0 ? Qt : o, f = tt(n), h = f ? s ? Ft : Ft.filter(function(w) {
|
|
507
|
-
return tt(w) === f;
|
|
508
|
-
}) : ft, y = h.filter(function(w) {
|
|
509
|
-
return c.indexOf(w) >= 0;
|
|
510
|
-
});
|
|
511
|
-
y.length === 0 && (y = h);
|
|
512
|
-
var u = y.reduce(function(w, d) {
|
|
513
|
-
return w[d] = st(t, {
|
|
514
|
-
placement: d,
|
|
515
|
-
boundary: a,
|
|
516
|
-
rootBoundary: i,
|
|
517
|
-
padding: p
|
|
518
|
-
})[H(d)], w;
|
|
519
|
-
}, {});
|
|
520
|
-
return Object.keys(u).sort(function(w, d) {
|
|
521
|
-
return u[w] - u[d];
|
|
522
|
-
});
|
|
523
|
-
}
|
|
524
|
-
function Ue(t) {
|
|
525
|
-
if (H(t) === Pt)
|
|
526
|
-
return [];
|
|
527
|
-
var e = mt(t);
|
|
528
|
-
return [It(t), e, It(e)];
|
|
529
|
-
}
|
|
530
|
-
function Ge(t) {
|
|
531
|
-
var e = t.state, r = t.options, n = t.name;
|
|
532
|
-
if (!e.modifiersData[n]._skip) {
|
|
533
|
-
for (var a = r.mainAxis, i = a === void 0 ? !0 : a, p = r.altAxis, s = p === void 0 ? !0 : p, o = r.fallbackPlacements, c = r.padding, f = r.boundary, h = r.rootBoundary, y = r.altBoundary, u = r.flipVariations, w = u === void 0 ? !0 : u, d = r.allowedAutoPlacements, v = e.options.placement, b = H(v), O = b === v, A = o || (O || !w ? [mt(v)] : Ue(v)), l = [v].concat(A).reduce(function(K, F) {
|
|
534
|
-
return K.concat(H(F) === Pt ? ze(e, {
|
|
535
|
-
placement: F,
|
|
536
|
-
boundary: f,
|
|
537
|
-
rootBoundary: h,
|
|
538
|
-
padding: c,
|
|
539
|
-
flipVariations: w,
|
|
540
|
-
allowedAutoPlacements: d
|
|
541
|
-
}) : F);
|
|
542
|
-
}, []), m = e.rects.reference, g = e.rects.popper, x = /* @__PURE__ */ new Map(), D = !0, P = l[0], E = 0; E < l.length; E++) {
|
|
543
|
-
var j = l[E], M = H(j), R = tt(j) === Q, X = [B, S].indexOf(M) >= 0, I = X ? "width" : "height", C = st(e, {
|
|
544
|
-
placement: j,
|
|
545
|
-
boundary: f,
|
|
546
|
-
rootBoundary: h,
|
|
547
|
-
altBoundary: y,
|
|
548
|
-
padding: c
|
|
549
|
-
}), W = X ? R ? L : $ : R ? S : B;
|
|
550
|
-
m[I] > g[I] && (W = mt(W));
|
|
551
|
-
var ct = mt(W), Y = [];
|
|
552
|
-
if (i && Y.push(C[M] <= 0), s && Y.push(C[W] <= 0, C[ct] <= 0), Y.every(function(K) {
|
|
553
|
-
return K;
|
|
554
|
-
})) {
|
|
555
|
-
P = j, D = !1;
|
|
556
|
-
break;
|
|
557
|
-
}
|
|
558
|
-
x.set(j, Y);
|
|
559
|
-
}
|
|
560
|
-
if (D)
|
|
561
|
-
for (var ut = w ? 3 : 1, bt = function(F) {
|
|
562
|
-
var rt = l.find(function(vt) {
|
|
563
|
-
var z = x.get(vt);
|
|
564
|
-
if (z)
|
|
565
|
-
return z.slice(0, F).every(function(wt) {
|
|
566
|
-
return wt;
|
|
567
|
-
});
|
|
568
|
-
});
|
|
569
|
-
if (rt)
|
|
570
|
-
return P = rt, "break";
|
|
571
|
-
}, et = ut; et > 0; et--) {
|
|
572
|
-
var lt = bt(et);
|
|
573
|
-
if (lt === "break") break;
|
|
574
|
-
}
|
|
575
|
-
e.placement !== P && (e.modifiersData[n]._skip = !0, e.placement = P, e.reset = !0);
|
|
576
|
-
}
|
|
577
|
-
}
|
|
578
|
-
const Je = {
|
|
579
|
-
name: "flip",
|
|
580
|
-
enabled: !0,
|
|
581
|
-
phase: "main",
|
|
582
|
-
fn: Ge,
|
|
583
|
-
requiresIfExists: ["offset"],
|
|
584
|
-
data: {
|
|
585
|
-
_skip: !1
|
|
586
|
-
}
|
|
587
|
-
};
|
|
588
|
-
function zt(t, e, r) {
|
|
589
|
-
return r === void 0 && (r = {
|
|
590
|
-
x: 0,
|
|
591
|
-
y: 0
|
|
592
|
-
}), {
|
|
593
|
-
top: t.top - e.height - r.y,
|
|
594
|
-
right: t.right - e.width + r.x,
|
|
595
|
-
bottom: t.bottom - e.height + r.y,
|
|
596
|
-
left: t.left - e.width - r.x
|
|
597
|
-
};
|
|
598
|
-
}
|
|
599
|
-
function Ut(t) {
|
|
600
|
-
return [B, L, S, $].some(function(e) {
|
|
601
|
-
return t[e] >= 0;
|
|
602
|
-
});
|
|
603
|
-
}
|
|
604
|
-
function Ke(t) {
|
|
605
|
-
var e = t.state, r = t.name, n = e.rects.reference, a = e.rects.popper, i = e.modifiersData.preventOverflow, p = st(e, {
|
|
606
|
-
elementContext: "reference"
|
|
607
|
-
}), s = st(e, {
|
|
608
|
-
altBoundary: !0
|
|
609
|
-
}), o = zt(p, n), c = zt(s, a, i), f = Ut(o), h = Ut(c);
|
|
610
|
-
e.modifiersData[r] = {
|
|
611
|
-
referenceClippingOffsets: o,
|
|
612
|
-
popperEscapeOffsets: c,
|
|
613
|
-
isReferenceHidden: f,
|
|
614
|
-
hasPopperEscaped: h
|
|
615
|
-
}, e.attributes.popper = Object.assign({}, e.attributes.popper, {
|
|
616
|
-
"data-popper-reference-hidden": f,
|
|
617
|
-
"data-popper-escaped": h
|
|
618
|
-
});
|
|
619
|
-
}
|
|
620
|
-
const Qe = {
|
|
621
|
-
name: "hide",
|
|
622
|
-
enabled: !0,
|
|
623
|
-
phase: "main",
|
|
624
|
-
requiresIfExists: ["preventOverflow"],
|
|
625
|
-
fn: Ke
|
|
626
|
-
};
|
|
627
|
-
function Ze(t, e, r) {
|
|
628
|
-
var n = H(t), a = [$, B].indexOf(n) >= 0 ? -1 : 1, i = typeof r == "function" ? r(Object.assign({}, e, {
|
|
629
|
-
placement: t
|
|
630
|
-
})) : r, p = i[0], s = i[1];
|
|
631
|
-
return p = p || 0, s = (s || 0) * a, [$, L].indexOf(n) >= 0 ? {
|
|
632
|
-
x: s,
|
|
633
|
-
y: p
|
|
634
|
-
} : {
|
|
635
|
-
x: p,
|
|
636
|
-
y: s
|
|
637
|
-
};
|
|
638
|
-
}
|
|
639
|
-
function _e(t) {
|
|
640
|
-
var e = t.state, r = t.options, n = t.name, a = r.offset, i = a === void 0 ? [0, 0] : a, p = Qt.reduce(function(f, h) {
|
|
641
|
-
return f[h] = Ze(h, e.rects, i), f;
|
|
642
|
-
}, {}), s = p[e.placement], o = s.x, c = s.y;
|
|
643
|
-
e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += o, e.modifiersData.popperOffsets.y += c), e.modifiersData[n] = p;
|
|
644
|
-
}
|
|
645
|
-
const tr = {
|
|
646
|
-
name: "offset",
|
|
647
|
-
enabled: !0,
|
|
648
|
-
phase: "main",
|
|
649
|
-
requires: ["popperOffsets"],
|
|
650
|
-
fn: _e
|
|
651
|
-
};
|
|
652
|
-
function er(t) {
|
|
653
|
-
var e = t.state, r = t.name;
|
|
654
|
-
e.modifiersData[r] = ae({
|
|
655
|
-
reference: e.rects.reference,
|
|
656
|
-
element: e.rects.popper,
|
|
657
|
-
strategy: "absolute",
|
|
658
|
-
placement: e.placement
|
|
659
|
-
});
|
|
660
|
-
}
|
|
661
|
-
const rr = {
|
|
662
|
-
name: "popperOffsets",
|
|
663
|
-
enabled: !0,
|
|
664
|
-
phase: "read",
|
|
665
|
-
fn: er,
|
|
666
|
-
data: {}
|
|
667
|
-
};
|
|
668
|
-
function nr(t) {
|
|
669
|
-
return t === "x" ? "y" : "x";
|
|
670
|
-
}
|
|
671
|
-
function ar(t) {
|
|
672
|
-
var e = t.state, r = t.options, n = t.name, a = r.mainAxis, i = a === void 0 ? !0 : a, p = r.altAxis, s = p === void 0 ? !1 : p, o = r.boundary, c = r.rootBoundary, f = r.altBoundary, h = r.padding, y = r.tether, u = y === void 0 ? !0 : y, w = r.tetherOffset, d = w === void 0 ? 0 : w, v = st(e, {
|
|
673
|
-
boundary: o,
|
|
674
|
-
rootBoundary: c,
|
|
675
|
-
padding: h,
|
|
676
|
-
altBoundary: f
|
|
677
|
-
}), b = H(e.placement), O = tt(e.placement), A = !O, l = Rt(b), m = nr(l), g = e.modifiersData.popperOffsets, x = e.rects.reference, D = e.rects.popper, P = typeof d == "function" ? d(Object.assign({}, e.rects, {
|
|
678
|
-
placement: e.placement
|
|
679
|
-
})) : d, E = typeof P == "number" ? {
|
|
680
|
-
mainAxis: P,
|
|
681
|
-
altAxis: P
|
|
682
|
-
} : Object.assign({
|
|
683
|
-
mainAxis: 0,
|
|
684
|
-
altAxis: 0
|
|
685
|
-
}, P), j = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, M = {
|
|
686
|
-
x: 0,
|
|
687
|
-
y: 0
|
|
688
|
-
};
|
|
689
|
-
if (g) {
|
|
690
|
-
if (i) {
|
|
691
|
-
var R, X = l === "y" ? B : $, I = l === "y" ? S : L, C = l === "y" ? "height" : "width", W = g[l], ct = W + v[X], Y = W - v[I], ut = u ? -D[C] / 2 : 0, bt = O === Q ? x[C] : D[C], et = O === Q ? -D[C] : -x[C], lt = e.elements.arrow, K = u && lt ? jt(lt) : {
|
|
692
|
-
width: 0,
|
|
693
|
-
height: 0
|
|
694
|
-
}, F = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : te(), rt = F[X], vt = F[I], z = at(0, x[C], K[C]), wt = A ? x[C] / 2 - ut - z - rt - E.mainAxis : bt - z - rt - E.mainAxis, ie = A ? -x[C] / 2 + ut + z + vt + E.mainAxis : et + z + vt + E.mainAxis, xt = e.elements.arrow && pt(e.elements.arrow), oe = xt ? l === "y" ? xt.clientTop || 0 : xt.clientLeft || 0 : 0, kt = (R = j == null ? void 0 : j[l]) != null ? R : 0, se = W + wt - kt - oe, fe = W + ie - kt, Tt = at(u ? gt(ct, se) : ct, W, u ? G(Y, fe) : Y);
|
|
695
|
-
g[l] = Tt, M[l] = Tt - W;
|
|
696
|
-
}
|
|
697
|
-
if (s) {
|
|
698
|
-
var St, pe = l === "x" ? B : $, ce = l === "x" ? S : L, U = g[m], dt = m === "y" ? "height" : "width", Lt = U + v[pe], Mt = U - v[ce], Ot = [B, $].indexOf(b) !== -1, Wt = (St = j == null ? void 0 : j[m]) != null ? St : 0, Ht = Ot ? Lt : U - x[dt] - D[dt] - Wt + E.altAxis, Vt = Ot ? U + x[dt] + D[dt] - Wt - E.altAxis : Mt, Nt = u && Ot ? Re(Ht, U, Vt) : at(u ? Ht : Lt, U, u ? Vt : Mt);
|
|
699
|
-
g[m] = Nt, M[m] = Nt - U;
|
|
700
|
-
}
|
|
701
|
-
e.modifiersData[n] = M;
|
|
702
|
-
}
|
|
703
|
-
}
|
|
704
|
-
const ir = {
|
|
705
|
-
name: "preventOverflow",
|
|
706
|
-
enabled: !0,
|
|
707
|
-
phase: "main",
|
|
708
|
-
fn: ar,
|
|
709
|
-
requiresIfExists: ["offset"]
|
|
710
|
-
};
|
|
711
|
-
function or(t) {
|
|
712
|
-
return {
|
|
713
|
-
scrollLeft: t.scrollLeft,
|
|
714
|
-
scrollTop: t.scrollTop
|
|
715
|
-
};
|
|
716
|
-
}
|
|
717
|
-
function sr(t) {
|
|
718
|
-
return t === k(t) || !T(t) ? Bt(t) : or(t);
|
|
719
|
-
}
|
|
720
|
-
function fr(t) {
|
|
721
|
-
var e = t.getBoundingClientRect(), r = Z(e.width) / t.offsetWidth || 1, n = Z(e.height) / t.offsetHeight || 1;
|
|
722
|
-
return r !== 1 || n !== 1;
|
|
723
|
-
}
|
|
724
|
-
function pr(t, e, r) {
|
|
725
|
-
r === void 0 && (r = !1);
|
|
726
|
-
var n = T(e), a = T(e) && fr(e), i = q(e), p = _(t, a, r), s = {
|
|
727
|
-
scrollLeft: 0,
|
|
728
|
-
scrollTop: 0
|
|
729
|
-
}, o = {
|
|
730
|
-
x: 0,
|
|
731
|
-
y: 0
|
|
732
|
-
};
|
|
733
|
-
return (n || !n && !r) && ((V(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078
|
|
734
|
-
Ct(i)) && (s = sr(e)), T(e) ? (o = _(e, !0), o.x += e.clientLeft, o.y += e.clientTop) : i && (o.x = $t(i))), {
|
|
735
|
-
x: p.left + s.scrollLeft - o.x,
|
|
736
|
-
y: p.top + s.scrollTop - o.y,
|
|
737
|
-
width: p.width,
|
|
738
|
-
height: p.height
|
|
739
|
-
};
|
|
740
|
-
}
|
|
741
|
-
function cr(t) {
|
|
742
|
-
var e = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Set(), n = [];
|
|
743
|
-
t.forEach(function(i) {
|
|
744
|
-
e.set(i.name, i);
|
|
745
|
-
});
|
|
746
|
-
function a(i) {
|
|
747
|
-
r.add(i.name);
|
|
748
|
-
var p = [].concat(i.requires || [], i.requiresIfExists || []);
|
|
749
|
-
p.forEach(function(s) {
|
|
750
|
-
if (!r.has(s)) {
|
|
751
|
-
var o = e.get(s);
|
|
752
|
-
o && a(o);
|
|
753
|
-
}
|
|
754
|
-
}), n.push(i);
|
|
755
|
-
}
|
|
756
|
-
return t.forEach(function(i) {
|
|
757
|
-
r.has(i.name) || a(i);
|
|
758
|
-
}), n;
|
|
759
|
-
}
|
|
760
|
-
function ur(t) {
|
|
761
|
-
var e = cr(t);
|
|
762
|
-
return Oe.reduce(function(r, n) {
|
|
763
|
-
return r.concat(e.filter(function(a) {
|
|
764
|
-
return a.phase === n;
|
|
765
|
-
}));
|
|
766
|
-
}, []);
|
|
767
|
-
}
|
|
768
|
-
function lr(t) {
|
|
769
|
-
var e;
|
|
770
|
-
return function() {
|
|
771
|
-
return e || (e = new Promise(function(r) {
|
|
772
|
-
Promise.resolve().then(function() {
|
|
773
|
-
e = void 0, r(t());
|
|
774
|
-
});
|
|
775
|
-
})), e;
|
|
776
|
-
};
|
|
777
|
-
}
|
|
778
|
-
function vr(t) {
|
|
779
|
-
var e = t.reduce(function(r, n) {
|
|
780
|
-
var a = r[n.name];
|
|
781
|
-
return r[n.name] = a ? Object.assign({}, a, n, {
|
|
782
|
-
options: Object.assign({}, a.options, n.options),
|
|
783
|
-
data: Object.assign({}, a.data, n.data)
|
|
784
|
-
}) : n, r;
|
|
785
|
-
}, {});
|
|
786
|
-
return Object.keys(e).map(function(r) {
|
|
787
|
-
return e[r];
|
|
788
|
-
});
|
|
789
|
-
}
|
|
790
|
-
var Gt = {
|
|
791
|
-
placement: "bottom",
|
|
792
|
-
modifiers: [],
|
|
793
|
-
strategy: "absolute"
|
|
794
|
-
};
|
|
795
|
-
function Jt() {
|
|
796
|
-
for (var t = arguments.length, e = new Array(t), r = 0; r < t; r++)
|
|
797
|
-
e[r] = arguments[r];
|
|
798
|
-
return !e.some(function(n) {
|
|
799
|
-
return !(n && typeof n.getBoundingClientRect == "function");
|
|
800
|
-
});
|
|
801
|
-
}
|
|
802
|
-
function dr(t) {
|
|
803
|
-
t === void 0 && (t = {});
|
|
804
|
-
var e = t, r = e.defaultModifiers, n = r === void 0 ? [] : r, a = e.defaultOptions, i = a === void 0 ? Gt : a;
|
|
805
|
-
return function(s, o, c) {
|
|
806
|
-
c === void 0 && (c = i);
|
|
807
|
-
var f = {
|
|
808
|
-
placement: "bottom",
|
|
809
|
-
orderedModifiers: [],
|
|
810
|
-
options: Object.assign({}, Gt, i),
|
|
811
|
-
modifiersData: {},
|
|
812
|
-
elements: {
|
|
813
|
-
reference: s,
|
|
814
|
-
popper: o
|
|
815
|
-
},
|
|
816
|
-
attributes: {},
|
|
817
|
-
styles: {}
|
|
818
|
-
}, h = [], y = !1, u = {
|
|
819
|
-
state: f,
|
|
820
|
-
setOptions: function(b) {
|
|
821
|
-
var O = typeof b == "function" ? b(f.options) : b;
|
|
822
|
-
d(), f.options = Object.assign({}, i, f.options, O), f.scrollParents = {
|
|
823
|
-
reference: J(s) ? it(s) : s.contextElement ? it(s.contextElement) : [],
|
|
824
|
-
popper: it(o)
|
|
825
|
-
};
|
|
826
|
-
var A = ur(vr([].concat(n, f.options.modifiers)));
|
|
827
|
-
return f.orderedModifiers = A.filter(function(l) {
|
|
828
|
-
return l.enabled;
|
|
829
|
-
}), w(), u.update();
|
|
830
|
-
},
|
|
831
|
-
// Sync update – it will always be executed, even if not necessary. This
|
|
832
|
-
// is useful for low frequency updates where sync behavior simplifies the
|
|
833
|
-
// logic.
|
|
834
|
-
// For high frequency updates (e.g. `resize` and `scroll` events), always
|
|
835
|
-
// prefer the async Popper#update method
|
|
836
|
-
forceUpdate: function() {
|
|
837
|
-
if (!y) {
|
|
838
|
-
var b = f.elements, O = b.reference, A = b.popper;
|
|
839
|
-
if (Jt(O, A)) {
|
|
840
|
-
f.rects = {
|
|
841
|
-
reference: pr(O, pt(A), f.options.strategy === "fixed"),
|
|
842
|
-
popper: jt(A)
|
|
843
|
-
}, f.reset = !1, f.placement = f.options.placement, f.orderedModifiers.forEach(function(E) {
|
|
844
|
-
return f.modifiersData[E.name] = Object.assign({}, E.data);
|
|
845
|
-
});
|
|
846
|
-
for (var l = 0; l < f.orderedModifiers.length; l++) {
|
|
847
|
-
if (f.reset === !0) {
|
|
848
|
-
f.reset = !1, l = -1;
|
|
849
|
-
continue;
|
|
850
|
-
}
|
|
851
|
-
var m = f.orderedModifiers[l], g = m.fn, x = m.options, D = x === void 0 ? {} : x, P = m.name;
|
|
852
|
-
typeof g == "function" && (f = g({
|
|
853
|
-
state: f,
|
|
854
|
-
options: D,
|
|
855
|
-
name: P,
|
|
856
|
-
instance: u
|
|
857
|
-
}) || f);
|
|
858
|
-
}
|
|
859
|
-
}
|
|
860
|
-
}
|
|
861
|
-
},
|
|
862
|
-
// Async and optimistically optimized update – it will not be executed if
|
|
863
|
-
// not necessary (debounced to run at most once-per-tick)
|
|
864
|
-
update: lr(function() {
|
|
865
|
-
return new Promise(function(v) {
|
|
866
|
-
u.forceUpdate(), v(f);
|
|
867
|
-
});
|
|
868
|
-
}),
|
|
869
|
-
destroy: function() {
|
|
870
|
-
d(), y = !0;
|
|
871
|
-
}
|
|
872
|
-
};
|
|
873
|
-
if (!Jt(s, o))
|
|
874
|
-
return u;
|
|
875
|
-
u.setOptions(c).then(function(v) {
|
|
876
|
-
!y && c.onFirstUpdate && c.onFirstUpdate(v);
|
|
877
|
-
});
|
|
878
|
-
function w() {
|
|
879
|
-
f.orderedModifiers.forEach(function(v) {
|
|
880
|
-
var b = v.name, O = v.options, A = O === void 0 ? {} : O, l = v.effect;
|
|
881
|
-
if (typeof l == "function") {
|
|
882
|
-
var m = l({
|
|
883
|
-
state: f,
|
|
884
|
-
name: b,
|
|
885
|
-
instance: u,
|
|
886
|
-
options: A
|
|
887
|
-
}), g = function() {
|
|
888
|
-
};
|
|
889
|
-
h.push(m || g);
|
|
890
|
-
}
|
|
891
|
-
});
|
|
892
|
-
}
|
|
893
|
-
function d() {
|
|
894
|
-
h.forEach(function(v) {
|
|
895
|
-
return v();
|
|
896
|
-
}), h = [];
|
|
897
|
-
}
|
|
898
|
-
return u;
|
|
899
|
-
};
|
|
900
|
-
}
|
|
901
|
-
var hr = [He, rr, Me, Pe, tr, Je, ir, ke, Qe], mr = /* @__PURE__ */ dr({
|
|
902
|
-
defaultModifiers: hr
|
|
903
|
-
});
|
|
904
|
-
export {
|
|
905
|
-
mr as c
|
|
906
|
-
};
|