@leaflink/stash 52.0.0 → 52.0.1
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/FilterSelect.js +55 -59
- package/dist/FilterSelect.js.map +1 -1
- package/dist/MoreActions.js +4 -1
- package/dist/MoreActions.js.map +1 -1
- package/dist/Select.js +1 -1
- package/dist/Table.js +70 -65
- package/dist/Table.js.map +1 -1
- package/dist/Table.vue.d.ts +4 -0
- package/dist/TableRow.js +23 -23
- package/dist/TableRow.js.map +1 -1
- package/dist/Tooltip.js +24 -19
- package/dist/Tooltip.js.map +1 -1
- package/dist/{floating-ui.vue-DLFiymOf.js → floating-ui.vue-CuGrC-z8.js} +390 -333
- package/dist/{floating-ui.vue-DLFiymOf.js.map → floating-ui.vue-CuGrC-z8.js.map} +1 -1
- package/package.json +1 -1
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
const j = Math.min, E = Math.max, st = Math.round, rt = Math.floor,
|
|
1
|
+
import { computed as I, ref as nt, shallowRef as Xt, watch as mt, getCurrentScope as Yt, onScopeDispose as qt, shallowReadonly as G, unref as Ut } from "vue";
|
|
2
|
+
const j = Math.min, E = Math.max, st = Math.round, rt = Math.floor, k = (t) => ({
|
|
3
3
|
x: t,
|
|
4
4
|
y: t
|
|
5
|
-
}),
|
|
5
|
+
}), Kt = {
|
|
6
6
|
left: "right",
|
|
7
7
|
right: "left",
|
|
8
8
|
bottom: "top",
|
|
9
9
|
top: "bottom"
|
|
10
|
-
},
|
|
10
|
+
}, Gt = {
|
|
11
11
|
start: "end",
|
|
12
12
|
end: "start"
|
|
13
13
|
};
|
|
14
|
-
function
|
|
14
|
+
function gt(t, e, n) {
|
|
15
15
|
return E(t, j(e, n));
|
|
16
16
|
}
|
|
17
|
-
function
|
|
17
|
+
function tt(t, e) {
|
|
18
18
|
return typeof t == "function" ? t(e) : t;
|
|
19
19
|
}
|
|
20
|
-
function
|
|
20
|
+
function X(t) {
|
|
21
21
|
return t.split("-")[0];
|
|
22
22
|
}
|
|
23
|
-
function
|
|
23
|
+
function et(t) {
|
|
24
24
|
return t.split("-")[1];
|
|
25
25
|
}
|
|
26
|
-
function
|
|
26
|
+
function Vt(t) {
|
|
27
27
|
return t === "x" ? "y" : "x";
|
|
28
28
|
}
|
|
29
29
|
function yt(t) {
|
|
30
30
|
return t === "y" ? "height" : "width";
|
|
31
31
|
}
|
|
32
32
|
const Jt = /* @__PURE__ */ new Set(["top", "bottom"]);
|
|
33
|
-
function
|
|
34
|
-
return Jt.has(
|
|
33
|
+
function $(t) {
|
|
34
|
+
return Jt.has(X(t)) ? "y" : "x";
|
|
35
35
|
}
|
|
36
36
|
function vt(t) {
|
|
37
|
-
return
|
|
37
|
+
return Vt($(t));
|
|
38
38
|
}
|
|
39
39
|
function Qt(t, e, n) {
|
|
40
40
|
n === void 0 && (n = !1);
|
|
41
|
-
const o =
|
|
41
|
+
const o = et(t), i = vt(t), s = yt(i);
|
|
42
42
|
let r = i === "x" ? o === (n ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
|
|
43
43
|
return e.reference[s] > e.floating[s] && (r = lt(r)), [r, lt(r)];
|
|
44
44
|
}
|
|
45
45
|
function Zt(t) {
|
|
46
46
|
const e = lt(t);
|
|
47
|
-
return [
|
|
47
|
+
return [pt(t), e, pt(e)];
|
|
48
48
|
}
|
|
49
|
-
function
|
|
50
|
-
return t.replace(/start|end/g, (e) =>
|
|
49
|
+
function pt(t) {
|
|
50
|
+
return t.replace(/start|end/g, (e) => Gt[e]);
|
|
51
51
|
}
|
|
52
|
-
const
|
|
52
|
+
const St = ["left", "right"], Et = ["right", "left"], te = ["top", "bottom"], ee = ["bottom", "top"];
|
|
53
53
|
function ne(t, e, n) {
|
|
54
54
|
switch (t) {
|
|
55
55
|
case "top":
|
|
56
56
|
case "bottom":
|
|
57
|
-
return n ? e ?
|
|
57
|
+
return n ? e ? Et : St : e ? St : Et;
|
|
58
58
|
case "left":
|
|
59
59
|
case "right":
|
|
60
60
|
return e ? te : ee;
|
|
@@ -63,12 +63,12 @@ function ne(t, e, n) {
|
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
65
|
function oe(t, e, n, o) {
|
|
66
|
-
const i =
|
|
67
|
-
let s = ne(
|
|
68
|
-
return i && (s = s.map((r) => r + "-" + i), e && (s = s.concat(s.map(
|
|
66
|
+
const i = et(t);
|
|
67
|
+
let s = ne(X(t), n === "start", o);
|
|
68
|
+
return i && (s = s.map((r) => r + "-" + i), e && (s = s.concat(s.map(pt)))), s;
|
|
69
69
|
}
|
|
70
70
|
function lt(t) {
|
|
71
|
-
return t.replace(/left|right|bottom|top/g, (e) =>
|
|
71
|
+
return t.replace(/left|right|bottom|top/g, (e) => Kt[e]);
|
|
72
72
|
}
|
|
73
73
|
function ie(t) {
|
|
74
74
|
return {
|
|
@@ -79,7 +79,7 @@ function ie(t) {
|
|
|
79
79
|
...t
|
|
80
80
|
};
|
|
81
81
|
}
|
|
82
|
-
function
|
|
82
|
+
function kt(t) {
|
|
83
83
|
return typeof t != "number" ? ie(t) : {
|
|
84
84
|
top: t,
|
|
85
85
|
right: t,
|
|
@@ -105,23 +105,23 @@ function ct(t) {
|
|
|
105
105
|
y: n
|
|
106
106
|
};
|
|
107
107
|
}
|
|
108
|
-
function
|
|
108
|
+
function Dt(t, e, n) {
|
|
109
109
|
let {
|
|
110
110
|
reference: o,
|
|
111
111
|
floating: i
|
|
112
112
|
} = t;
|
|
113
|
-
const s =
|
|
113
|
+
const s = $(e), r = vt(e), l = yt(r), f = X(e), a = s === "y", c = o.x + o.width / 2 - i.width / 2, d = o.y + o.height / 2 - i.height / 2, h = o[l] / 2 - i[l] / 2;
|
|
114
114
|
let u;
|
|
115
115
|
switch (f) {
|
|
116
116
|
case "top":
|
|
117
117
|
u = {
|
|
118
|
-
x:
|
|
118
|
+
x: c,
|
|
119
119
|
y: o.y - i.height
|
|
120
120
|
};
|
|
121
121
|
break;
|
|
122
122
|
case "bottom":
|
|
123
123
|
u = {
|
|
124
|
-
x:
|
|
124
|
+
x: c,
|
|
125
125
|
y: o.y + o.height
|
|
126
126
|
};
|
|
127
127
|
break;
|
|
@@ -143,12 +143,12 @@ function St(t, e, n) {
|
|
|
143
143
|
y: o.y
|
|
144
144
|
};
|
|
145
145
|
}
|
|
146
|
-
switch (
|
|
146
|
+
switch (et(e)) {
|
|
147
147
|
case "start":
|
|
148
|
-
u[r] -= h * (n &&
|
|
148
|
+
u[r] -= h * (n && a ? -1 : 1);
|
|
149
149
|
break;
|
|
150
150
|
case "end":
|
|
151
|
-
u[r] += h * (n &&
|
|
151
|
+
u[r] += h * (n && a ? -1 : 1);
|
|
152
152
|
break;
|
|
153
153
|
}
|
|
154
154
|
return u;
|
|
@@ -160,61 +160,61 @@ const re = async (t, e, n) => {
|
|
|
160
160
|
middleware: s = [],
|
|
161
161
|
platform: r
|
|
162
162
|
} = n, l = s.filter(Boolean), f = await (r.isRTL == null ? void 0 : r.isRTL(e));
|
|
163
|
-
let
|
|
163
|
+
let a = await r.getElementRects({
|
|
164
164
|
reference: t,
|
|
165
165
|
floating: e,
|
|
166
166
|
strategy: i
|
|
167
167
|
}), {
|
|
168
|
-
x:
|
|
168
|
+
x: c,
|
|
169
169
|
y: d
|
|
170
|
-
} =
|
|
170
|
+
} = Dt(a, o, f), h = o, u = {}, m = 0;
|
|
171
171
|
for (let g = 0; g < l.length; g++) {
|
|
172
172
|
const {
|
|
173
|
-
name:
|
|
174
|
-
fn:
|
|
173
|
+
name: p,
|
|
174
|
+
fn: w
|
|
175
175
|
} = l[g], {
|
|
176
|
-
x
|
|
177
|
-
y:
|
|
178
|
-
data:
|
|
176
|
+
x,
|
|
177
|
+
y: v,
|
|
178
|
+
data: A,
|
|
179
179
|
reset: b
|
|
180
|
-
} = await
|
|
181
|
-
x:
|
|
180
|
+
} = await w({
|
|
181
|
+
x: c,
|
|
182
182
|
y: d,
|
|
183
183
|
initialPlacement: o,
|
|
184
184
|
placement: h,
|
|
185
185
|
strategy: i,
|
|
186
186
|
middlewareData: u,
|
|
187
|
-
rects:
|
|
187
|
+
rects: a,
|
|
188
188
|
platform: r,
|
|
189
189
|
elements: {
|
|
190
190
|
reference: t,
|
|
191
191
|
floating: e
|
|
192
192
|
}
|
|
193
193
|
});
|
|
194
|
-
|
|
194
|
+
c = x ?? c, d = v ?? d, u = {
|
|
195
195
|
...u,
|
|
196
|
-
[
|
|
197
|
-
...u[
|
|
198
|
-
...
|
|
196
|
+
[p]: {
|
|
197
|
+
...u[p],
|
|
198
|
+
...A
|
|
199
199
|
}
|
|
200
|
-
}, b && m <= 50 && (m++, typeof b == "object" && (b.placement && (h = b.placement), b.rects && (
|
|
200
|
+
}, b && m <= 50 && (m++, typeof b == "object" && (b.placement && (h = b.placement), b.rects && (a = b.rects === !0 ? await r.getElementRects({
|
|
201
201
|
reference: t,
|
|
202
202
|
floating: e,
|
|
203
203
|
strategy: i
|
|
204
204
|
}) : b.rects), {
|
|
205
|
-
x:
|
|
205
|
+
x: c,
|
|
206
206
|
y: d
|
|
207
|
-
} =
|
|
207
|
+
} = Dt(a, h, f)), g = -1);
|
|
208
208
|
}
|
|
209
209
|
return {
|
|
210
|
-
x:
|
|
210
|
+
x: c,
|
|
211
211
|
y: d,
|
|
212
212
|
placement: h,
|
|
213
213
|
strategy: i,
|
|
214
214
|
middlewareData: u
|
|
215
215
|
};
|
|
216
216
|
};
|
|
217
|
-
async function
|
|
217
|
+
async function bt(t, e) {
|
|
218
218
|
var n;
|
|
219
219
|
e === void 0 && (e = {});
|
|
220
220
|
const {
|
|
@@ -225,22 +225,22 @@ async function Ft(t, e) {
|
|
|
225
225
|
elements: l,
|
|
226
226
|
strategy: f
|
|
227
227
|
} = t, {
|
|
228
|
-
boundary:
|
|
229
|
-
rootBoundary:
|
|
228
|
+
boundary: a = "clippingAncestors",
|
|
229
|
+
rootBoundary: c = "viewport",
|
|
230
230
|
elementContext: d = "floating",
|
|
231
231
|
altBoundary: h = !1,
|
|
232
232
|
padding: u = 0
|
|
233
|
-
} =
|
|
234
|
-
element: (n = await (s.isElement == null ? void 0 : s.isElement(
|
|
235
|
-
boundary:
|
|
236
|
-
rootBoundary:
|
|
233
|
+
} = tt(e, t), m = kt(u), p = l[h ? d === "floating" ? "reference" : "floating" : d], w = ct(await s.getClippingRect({
|
|
234
|
+
element: (n = await (s.isElement == null ? void 0 : s.isElement(p))) == null || n ? p : p.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(l.floating)),
|
|
235
|
+
boundary: a,
|
|
236
|
+
rootBoundary: c,
|
|
237
237
|
strategy: f
|
|
238
|
-
})),
|
|
238
|
+
})), x = d === "floating" ? {
|
|
239
239
|
x: o,
|
|
240
240
|
y: i,
|
|
241
241
|
width: r.floating.width,
|
|
242
242
|
height: r.floating.height
|
|
243
|
-
} : r.reference,
|
|
243
|
+
} : r.reference, v = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(l.floating)), A = await (s.isElement == null ? void 0 : s.isElement(v)) ? await (s.getScale == null ? void 0 : s.getScale(v)) || {
|
|
244
244
|
x: 1,
|
|
245
245
|
y: 1
|
|
246
246
|
} : {
|
|
@@ -248,15 +248,15 @@ async function Ft(t, e) {
|
|
|
248
248
|
y: 1
|
|
249
249
|
}, b = ct(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
250
250
|
elements: l,
|
|
251
|
-
rect:
|
|
252
|
-
offsetParent:
|
|
251
|
+
rect: x,
|
|
252
|
+
offsetParent: v,
|
|
253
253
|
strategy: f
|
|
254
|
-
}) :
|
|
254
|
+
}) : x);
|
|
255
255
|
return {
|
|
256
|
-
top: (
|
|
257
|
-
bottom: (b.bottom -
|
|
258
|
-
left: (
|
|
259
|
-
right: (b.right -
|
|
256
|
+
top: (w.top - b.top + m.top) / A.y,
|
|
257
|
+
bottom: (b.bottom - w.bottom + m.bottom) / A.y,
|
|
258
|
+
left: (w.left - b.left + m.left) / A.x,
|
|
259
|
+
right: (b.right - w.right + m.right) / A.x
|
|
260
260
|
};
|
|
261
261
|
}
|
|
262
262
|
const se = (t) => ({
|
|
@@ -272,23 +272,23 @@ const se = (t) => ({
|
|
|
272
272
|
elements: l,
|
|
273
273
|
middlewareData: f
|
|
274
274
|
} = e, {
|
|
275
|
-
element:
|
|
276
|
-
padding:
|
|
277
|
-
} =
|
|
278
|
-
if (
|
|
275
|
+
element: a,
|
|
276
|
+
padding: c = 0
|
|
277
|
+
} = tt(t, e) || {};
|
|
278
|
+
if (a == null)
|
|
279
279
|
return {};
|
|
280
|
-
const d =
|
|
280
|
+
const d = kt(c), h = {
|
|
281
281
|
x: n,
|
|
282
282
|
y: o
|
|
283
|
-
}, u = vt(i), m = yt(u), g = await r.getDimensions(
|
|
284
|
-
let
|
|
285
|
-
(!
|
|
286
|
-
const O =
|
|
283
|
+
}, u = vt(i), m = yt(u), g = await r.getDimensions(a), p = u === "y", w = p ? "top" : "left", x = p ? "bottom" : "right", v = p ? "clientHeight" : "clientWidth", A = s.reference[m] + s.reference[u] - h[u] - s.floating[m], b = h[u] - s.reference[u], C = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(a));
|
|
284
|
+
let y = C ? C[v] : 0;
|
|
285
|
+
(!y || !await (r.isElement == null ? void 0 : r.isElement(C))) && (y = l.floating[v] || s.floating[m]);
|
|
286
|
+
const O = A / 2 - b / 2, S = y / 2 - g[m] / 2 - 1, L = j(d[w], S), _ = j(d[x], S), V = L, H = y - g[m] - _, R = y / 2 - g[m] / 2 + O, q = gt(V, R, H), N = !f.arrow && et(i) != null && R !== q && s.reference[m] / 2 - (R < V ? L : _) - g[m] / 2 < 0, T = N ? R < V ? R - V : R - H : 0;
|
|
287
287
|
return {
|
|
288
288
|
[u]: h[u] + T,
|
|
289
289
|
data: {
|
|
290
|
-
[u]:
|
|
291
|
-
centerOffset:
|
|
290
|
+
[u]: q,
|
|
291
|
+
centerOffset: R - q - T,
|
|
292
292
|
...N && {
|
|
293
293
|
alignmentOffset: T
|
|
294
294
|
}
|
|
@@ -308,58 +308,58 @@ const se = (t) => ({
|
|
|
308
308
|
rects: r,
|
|
309
309
|
initialPlacement: l,
|
|
310
310
|
platform: f,
|
|
311
|
-
elements:
|
|
311
|
+
elements: a
|
|
312
312
|
} = e, {
|
|
313
|
-
mainAxis:
|
|
313
|
+
mainAxis: c = !0,
|
|
314
314
|
crossAxis: d = !0,
|
|
315
315
|
fallbackPlacements: h,
|
|
316
316
|
fallbackStrategy: u = "bestFit",
|
|
317
317
|
fallbackAxisSideDirection: m = "none",
|
|
318
318
|
flipAlignment: g = !0,
|
|
319
|
-
...
|
|
320
|
-
} =
|
|
319
|
+
...p
|
|
320
|
+
} = tt(t, e);
|
|
321
321
|
if ((n = s.arrow) != null && n.alignmentOffset)
|
|
322
322
|
return {};
|
|
323
|
-
const
|
|
324
|
-
!h && C && b.push(...oe(l, g, m,
|
|
325
|
-
const
|
|
323
|
+
const w = X(i), x = $(l), v = X(l) === l, A = await (f.isRTL == null ? void 0 : f.isRTL(a.floating)), b = h || (v || !g ? [lt(l)] : Zt(l)), C = m !== "none";
|
|
324
|
+
!h && C && b.push(...oe(l, g, m, A));
|
|
325
|
+
const y = [l, ...b], O = await bt(e, p), S = [];
|
|
326
326
|
let L = ((o = s.flip) == null ? void 0 : o.overflows) || [];
|
|
327
|
-
if (
|
|
328
|
-
const
|
|
329
|
-
S.push(O[
|
|
327
|
+
if (c && S.push(O[w]), d) {
|
|
328
|
+
const R = Qt(i, r, A);
|
|
329
|
+
S.push(O[R[0]], O[R[1]]);
|
|
330
330
|
}
|
|
331
331
|
if (L = [...L, {
|
|
332
332
|
placement: i,
|
|
333
333
|
overflows: S
|
|
334
|
-
}], !S.every((
|
|
335
|
-
var
|
|
336
|
-
const
|
|
337
|
-
if (
|
|
334
|
+
}], !S.every((R) => R <= 0)) {
|
|
335
|
+
var _, V;
|
|
336
|
+
const R = (((_ = s.flip) == null ? void 0 : _.index) || 0) + 1, q = y[R];
|
|
337
|
+
if (q && (!(d === "alignment" ? x !== $(q) : !1) || // We leave the current main axis only if every placement on that axis
|
|
338
338
|
// overflows the main axis.
|
|
339
|
-
L.every((P) =>
|
|
339
|
+
L.every((P) => $(P.placement) === x ? P.overflows[0] > 0 : !0)))
|
|
340
340
|
return {
|
|
341
341
|
data: {
|
|
342
|
-
index:
|
|
342
|
+
index: R,
|
|
343
343
|
overflows: L
|
|
344
344
|
},
|
|
345
345
|
reset: {
|
|
346
|
-
placement:
|
|
346
|
+
placement: q
|
|
347
347
|
}
|
|
348
348
|
};
|
|
349
349
|
let N = (V = L.filter((T) => T.overflows[0] <= 0).sort((T, P) => T.overflows[1] - P.overflows[1])[0]) == null ? void 0 : V.placement;
|
|
350
350
|
if (!N)
|
|
351
351
|
switch (u) {
|
|
352
352
|
case "bestFit": {
|
|
353
|
-
var
|
|
354
|
-
const T = (
|
|
353
|
+
var H;
|
|
354
|
+
const T = (H = L.filter((P) => {
|
|
355
355
|
if (C) {
|
|
356
|
-
const
|
|
357
|
-
return
|
|
356
|
+
const z = $(P.placement);
|
|
357
|
+
return z === x || // Create a bias to the `y` side axis due to horizontal
|
|
358
358
|
// reading directions favoring greater width.
|
|
359
|
-
|
|
359
|
+
z === "y";
|
|
360
360
|
}
|
|
361
361
|
return !0;
|
|
362
|
-
}).map((P) => [P.placement, P.overflows.filter((
|
|
362
|
+
}).map((P) => [P.placement, P.overflows.filter((z) => z > 0).reduce((z, jt) => z + jt, 0)]).sort((P, z) => P[1] - z[1])[0]) == null ? void 0 : H[0];
|
|
363
363
|
T && (N = T);
|
|
364
364
|
break;
|
|
365
365
|
}
|
|
@@ -383,7 +383,7 @@ async function ae(t, e) {
|
|
|
383
383
|
placement: n,
|
|
384
384
|
platform: o,
|
|
385
385
|
elements: i
|
|
386
|
-
} = t, s = await (o.isRTL == null ? void 0 : o.isRTL(i.floating)), r =
|
|
386
|
+
} = t, s = await (o.isRTL == null ? void 0 : o.isRTL(i.floating)), r = X(n), l = et(n), f = $(n) === "y", a = ce.has(r) ? -1 : 1, c = s && f ? -1 : 1, d = tt(e, t);
|
|
387
387
|
let {
|
|
388
388
|
mainAxis: h,
|
|
389
389
|
crossAxis: u,
|
|
@@ -398,11 +398,11 @@ async function ae(t, e) {
|
|
|
398
398
|
alignmentAxis: d.alignmentAxis
|
|
399
399
|
};
|
|
400
400
|
return l && typeof m == "number" && (u = l === "end" ? m * -1 : m), f ? {
|
|
401
|
-
x: u *
|
|
402
|
-
y: h *
|
|
401
|
+
x: u * c,
|
|
402
|
+
y: h * a
|
|
403
403
|
} : {
|
|
404
|
-
x: h *
|
|
405
|
-
y: u *
|
|
404
|
+
x: h * a,
|
|
405
|
+
y: u * c
|
|
406
406
|
};
|
|
407
407
|
}
|
|
408
408
|
const fe = function(t) {
|
|
@@ -428,6 +428,62 @@ const fe = function(t) {
|
|
|
428
428
|
}
|
|
429
429
|
};
|
|
430
430
|
}, ue = function(t) {
|
|
431
|
+
return t === void 0 && (t = {}), {
|
|
432
|
+
name: "shift",
|
|
433
|
+
options: t,
|
|
434
|
+
async fn(e) {
|
|
435
|
+
const {
|
|
436
|
+
x: n,
|
|
437
|
+
y: o,
|
|
438
|
+
placement: i
|
|
439
|
+
} = e, {
|
|
440
|
+
mainAxis: s = !0,
|
|
441
|
+
crossAxis: r = !1,
|
|
442
|
+
limiter: l = {
|
|
443
|
+
fn: (p) => {
|
|
444
|
+
let {
|
|
445
|
+
x: w,
|
|
446
|
+
y: x
|
|
447
|
+
} = p;
|
|
448
|
+
return {
|
|
449
|
+
x: w,
|
|
450
|
+
y: x
|
|
451
|
+
};
|
|
452
|
+
}
|
|
453
|
+
},
|
|
454
|
+
...f
|
|
455
|
+
} = tt(t, e), a = {
|
|
456
|
+
x: n,
|
|
457
|
+
y: o
|
|
458
|
+
}, c = await bt(e, f), d = $(X(i)), h = Vt(d);
|
|
459
|
+
let u = a[h], m = a[d];
|
|
460
|
+
if (s) {
|
|
461
|
+
const p = h === "y" ? "top" : "left", w = h === "y" ? "bottom" : "right", x = u + c[p], v = u - c[w];
|
|
462
|
+
u = gt(x, u, v);
|
|
463
|
+
}
|
|
464
|
+
if (r) {
|
|
465
|
+
const p = d === "y" ? "top" : "left", w = d === "y" ? "bottom" : "right", x = m + c[p], v = m - c[w];
|
|
466
|
+
m = gt(x, m, v);
|
|
467
|
+
}
|
|
468
|
+
const g = l.fn({
|
|
469
|
+
...e,
|
|
470
|
+
[h]: u,
|
|
471
|
+
[d]: m
|
|
472
|
+
});
|
|
473
|
+
return {
|
|
474
|
+
...g,
|
|
475
|
+
data: {
|
|
476
|
+
x: g.x - n,
|
|
477
|
+
y: g.y - o,
|
|
478
|
+
enabled: {
|
|
479
|
+
[h]: s,
|
|
480
|
+
[d]: r
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
};
|
|
484
|
+
}
|
|
485
|
+
};
|
|
486
|
+
}, de = function(t) {
|
|
431
487
|
return t === void 0 && (t = {}), {
|
|
432
488
|
name: "size",
|
|
433
489
|
options: t,
|
|
@@ -441,23 +497,23 @@ const fe = function(t) {
|
|
|
441
497
|
} = e, {
|
|
442
498
|
apply: f = () => {
|
|
443
499
|
},
|
|
444
|
-
...
|
|
445
|
-
} =
|
|
500
|
+
...a
|
|
501
|
+
} = tt(t, e), c = await bt(e, a), d = X(i), h = et(i), u = $(i) === "y", {
|
|
446
502
|
width: m,
|
|
447
503
|
height: g
|
|
448
504
|
} = s.floating;
|
|
449
|
-
let
|
|
450
|
-
d === "top" || d === "bottom" ? (
|
|
451
|
-
const
|
|
452
|
-
let
|
|
453
|
-
if ((n = e.middlewareData.shift) != null && n.enabled.x && (O =
|
|
454
|
-
const L = E(
|
|
455
|
-
u ? O = m - 2 * (L !== 0 ||
|
|
505
|
+
let p, w;
|
|
506
|
+
d === "top" || d === "bottom" ? (p = d, w = h === (await (r.isRTL == null ? void 0 : r.isRTL(l.floating)) ? "start" : "end") ? "left" : "right") : (w = d, p = h === "end" ? "top" : "bottom");
|
|
507
|
+
const x = g - c.top - c.bottom, v = m - c.left - c.right, A = j(g - c[p], x), b = j(m - c[w], v), C = !e.middlewareData.shift;
|
|
508
|
+
let y = A, O = b;
|
|
509
|
+
if ((n = e.middlewareData.shift) != null && n.enabled.x && (O = v), (o = e.middlewareData.shift) != null && o.enabled.y && (y = x), C && !h) {
|
|
510
|
+
const L = E(c.left, 0), _ = E(c.right, 0), V = E(c.top, 0), H = E(c.bottom, 0);
|
|
511
|
+
u ? O = m - 2 * (L !== 0 || _ !== 0 ? L + _ : E(c.left, c.right)) : y = g - 2 * (V !== 0 || H !== 0 ? V + H : E(c.top, c.bottom));
|
|
456
512
|
}
|
|
457
513
|
await f({
|
|
458
514
|
...e,
|
|
459
515
|
availableWidth: O,
|
|
460
|
-
availableHeight:
|
|
516
|
+
availableHeight: y
|
|
461
517
|
});
|
|
462
518
|
const S = await r.getDimensions(l.floating);
|
|
463
519
|
return m !== S.width || g !== S.height ? {
|
|
@@ -472,7 +528,7 @@ function at() {
|
|
|
472
528
|
return typeof window < "u";
|
|
473
529
|
}
|
|
474
530
|
function K(t) {
|
|
475
|
-
return
|
|
531
|
+
return At(t) ? (t.nodeName || "").toLowerCase() : "#document";
|
|
476
532
|
}
|
|
477
533
|
function D(t) {
|
|
478
534
|
var e;
|
|
@@ -480,21 +536,21 @@ function D(t) {
|
|
|
480
536
|
}
|
|
481
537
|
function B(t) {
|
|
482
538
|
var e;
|
|
483
|
-
return (e = (
|
|
539
|
+
return (e = (At(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
|
|
484
540
|
}
|
|
485
|
-
function
|
|
541
|
+
function At(t) {
|
|
486
542
|
return at() ? t instanceof Node || t instanceof D(t).Node : !1;
|
|
487
543
|
}
|
|
488
544
|
function M(t) {
|
|
489
545
|
return at() ? t instanceof Element || t instanceof D(t).Element : !1;
|
|
490
546
|
}
|
|
491
|
-
function
|
|
547
|
+
function W(t) {
|
|
492
548
|
return at() ? t instanceof HTMLElement || t instanceof D(t).HTMLElement : !1;
|
|
493
549
|
}
|
|
494
|
-
function
|
|
550
|
+
function Lt(t) {
|
|
495
551
|
return !at() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof D(t).ShadowRoot;
|
|
496
552
|
}
|
|
497
|
-
const
|
|
553
|
+
const me = /* @__PURE__ */ new Set(["inline", "contents"]);
|
|
498
554
|
function it(t) {
|
|
499
555
|
const {
|
|
500
556
|
overflow: e,
|
|
@@ -502,15 +558,15 @@ function it(t) {
|
|
|
502
558
|
overflowY: o,
|
|
503
559
|
display: i
|
|
504
560
|
} = F(t);
|
|
505
|
-
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !
|
|
561
|
+
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !me.has(i);
|
|
506
562
|
}
|
|
507
|
-
const
|
|
508
|
-
function
|
|
509
|
-
return
|
|
563
|
+
const he = /* @__PURE__ */ new Set(["table", "td", "th"]);
|
|
564
|
+
function ge(t) {
|
|
565
|
+
return he.has(K(t));
|
|
510
566
|
}
|
|
511
|
-
const
|
|
567
|
+
const pe = [":popover-open", ":modal"];
|
|
512
568
|
function ft(t) {
|
|
513
|
-
return
|
|
569
|
+
return pe.some((e) => {
|
|
514
570
|
try {
|
|
515
571
|
return t.matches(e);
|
|
516
572
|
} catch {
|
|
@@ -518,28 +574,28 @@ function ft(t) {
|
|
|
518
574
|
}
|
|
519
575
|
});
|
|
520
576
|
}
|
|
521
|
-
const
|
|
522
|
-
function
|
|
577
|
+
const we = ["transform", "translate", "scale", "rotate", "perspective"], xe = ["transform", "translate", "scale", "rotate", "perspective", "filter"], ye = ["paint", "layout", "strict", "content"];
|
|
578
|
+
function Ot(t) {
|
|
523
579
|
const e = Rt(), n = M(t) ? F(t) : t;
|
|
524
|
-
return
|
|
580
|
+
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) || xe.some((o) => (n.willChange || "").includes(o)) || ye.some((o) => (n.contain || "").includes(o));
|
|
525
581
|
}
|
|
526
582
|
function ve(t) {
|
|
527
|
-
let e =
|
|
528
|
-
for (;
|
|
529
|
-
if (
|
|
583
|
+
let e = Y(t);
|
|
584
|
+
for (; W(e) && !Z(e); ) {
|
|
585
|
+
if (Ot(e))
|
|
530
586
|
return e;
|
|
531
587
|
if (ft(e))
|
|
532
588
|
return null;
|
|
533
|
-
e =
|
|
589
|
+
e = Y(e);
|
|
534
590
|
}
|
|
535
591
|
return null;
|
|
536
592
|
}
|
|
537
593
|
function Rt() {
|
|
538
594
|
return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
|
|
539
595
|
}
|
|
540
|
-
const
|
|
596
|
+
const be = /* @__PURE__ */ new Set(["html", "body", "#document"]);
|
|
541
597
|
function Z(t) {
|
|
542
|
-
return
|
|
598
|
+
return be.has(K(t));
|
|
543
599
|
}
|
|
544
600
|
function F(t) {
|
|
545
601
|
return D(t).getComputedStyle(t);
|
|
@@ -553,108 +609,108 @@ function ut(t) {
|
|
|
553
609
|
scrollTop: t.scrollY
|
|
554
610
|
};
|
|
555
611
|
}
|
|
556
|
-
function
|
|
612
|
+
function Y(t) {
|
|
557
613
|
if (K(t) === "html")
|
|
558
614
|
return t;
|
|
559
615
|
const e = (
|
|
560
616
|
// Step into the shadow DOM of the parent of a slotted node.
|
|
561
617
|
t.assignedSlot || // DOM Element detected.
|
|
562
618
|
t.parentNode || // ShadowRoot detected.
|
|
563
|
-
|
|
619
|
+
Lt(t) && t.host || // Fallback.
|
|
564
620
|
B(t)
|
|
565
621
|
);
|
|
566
|
-
return
|
|
622
|
+
return Lt(e) ? e.host : e;
|
|
567
623
|
}
|
|
568
|
-
function
|
|
569
|
-
const e =
|
|
570
|
-
return Z(e) ? t.ownerDocument ? t.ownerDocument.body : t.body :
|
|
624
|
+
function Wt(t) {
|
|
625
|
+
const e = Y(t);
|
|
626
|
+
return Z(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : W(e) && it(e) ? e : Wt(e);
|
|
571
627
|
}
|
|
572
|
-
function
|
|
628
|
+
function ot(t, e, n) {
|
|
573
629
|
var o;
|
|
574
630
|
e === void 0 && (e = []), n === void 0 && (n = !0);
|
|
575
|
-
const i =
|
|
631
|
+
const i = Wt(t), s = i === ((o = t.ownerDocument) == null ? void 0 : o.body), r = D(i);
|
|
576
632
|
if (s) {
|
|
577
|
-
const l =
|
|
578
|
-
return e.concat(r, r.visualViewport || [], it(i) ? i : [], l && n ?
|
|
633
|
+
const l = wt(r);
|
|
634
|
+
return e.concat(r, r.visualViewport || [], it(i) ? i : [], l && n ? ot(l) : []);
|
|
579
635
|
}
|
|
580
|
-
return e.concat(i,
|
|
636
|
+
return e.concat(i, ot(i, [], n));
|
|
581
637
|
}
|
|
582
|
-
function
|
|
638
|
+
function wt(t) {
|
|
583
639
|
return t.parent && Object.getPrototypeOf(t.parent) ? t.frameElement : null;
|
|
584
640
|
}
|
|
585
|
-
function
|
|
641
|
+
function Bt(t) {
|
|
586
642
|
const e = F(t);
|
|
587
643
|
let n = parseFloat(e.width) || 0, o = parseFloat(e.height) || 0;
|
|
588
|
-
const i =
|
|
644
|
+
const i = W(t), s = i ? t.offsetWidth : n, r = i ? t.offsetHeight : o, l = st(n) !== s || st(o) !== r;
|
|
589
645
|
return l && (n = s, o = r), {
|
|
590
646
|
width: n,
|
|
591
647
|
height: o,
|
|
592
648
|
$: l
|
|
593
649
|
};
|
|
594
650
|
}
|
|
595
|
-
function
|
|
651
|
+
function Ct(t) {
|
|
596
652
|
return M(t) ? t : t.contextElement;
|
|
597
653
|
}
|
|
598
654
|
function Q(t) {
|
|
599
|
-
const e =
|
|
600
|
-
if (!
|
|
601
|
-
return
|
|
655
|
+
const e = Ct(t);
|
|
656
|
+
if (!W(e))
|
|
657
|
+
return k(1);
|
|
602
658
|
const n = e.getBoundingClientRect(), {
|
|
603
659
|
width: o,
|
|
604
660
|
height: i,
|
|
605
661
|
$: s
|
|
606
|
-
} =
|
|
662
|
+
} = Bt(e);
|
|
607
663
|
let r = (s ? st(n.width) : n.width) / o, l = (s ? st(n.height) : n.height) / i;
|
|
608
664
|
return (!r || !Number.isFinite(r)) && (r = 1), (!l || !Number.isFinite(l)) && (l = 1), {
|
|
609
665
|
x: r,
|
|
610
666
|
y: l
|
|
611
667
|
};
|
|
612
668
|
}
|
|
613
|
-
const
|
|
614
|
-
function
|
|
669
|
+
const Ae = /* @__PURE__ */ k(0);
|
|
670
|
+
function Nt(t) {
|
|
615
671
|
const e = D(t);
|
|
616
|
-
return !Rt() || !e.visualViewport ?
|
|
672
|
+
return !Rt() || !e.visualViewport ? Ae : {
|
|
617
673
|
x: e.visualViewport.offsetLeft,
|
|
618
674
|
y: e.visualViewport.offsetTop
|
|
619
675
|
};
|
|
620
676
|
}
|
|
621
|
-
function
|
|
677
|
+
function Oe(t, e, n) {
|
|
622
678
|
return e === void 0 && (e = !1), !n || e && n !== D(t) ? !1 : e;
|
|
623
679
|
}
|
|
624
680
|
function U(t, e, n, o) {
|
|
625
681
|
e === void 0 && (e = !1), n === void 0 && (n = !1);
|
|
626
|
-
const i = t.getBoundingClientRect(), s =
|
|
627
|
-
let r =
|
|
682
|
+
const i = t.getBoundingClientRect(), s = Ct(t);
|
|
683
|
+
let r = k(1);
|
|
628
684
|
e && (o ? M(o) && (r = Q(o)) : r = Q(t));
|
|
629
|
-
const l =
|
|
630
|
-
let f = (i.left + l.x) / r.x,
|
|
685
|
+
const l = Oe(s, n, o) ? Nt(s) : k(0);
|
|
686
|
+
let f = (i.left + l.x) / r.x, a = (i.top + l.y) / r.y, c = i.width / r.x, d = i.height / r.y;
|
|
631
687
|
if (s) {
|
|
632
688
|
const h = D(s), u = o && M(o) ? D(o) : o;
|
|
633
|
-
let m = h, g =
|
|
689
|
+
let m = h, g = wt(m);
|
|
634
690
|
for (; g && o && u !== m; ) {
|
|
635
|
-
const
|
|
636
|
-
f *=
|
|
691
|
+
const p = Q(g), w = g.getBoundingClientRect(), x = F(g), v = w.left + (g.clientLeft + parseFloat(x.paddingLeft)) * p.x, A = w.top + (g.clientTop + parseFloat(x.paddingTop)) * p.y;
|
|
692
|
+
f *= p.x, a *= p.y, c *= p.x, d *= p.y, f += v, a += A, m = D(g), g = wt(m);
|
|
637
693
|
}
|
|
638
694
|
}
|
|
639
695
|
return ct({
|
|
640
|
-
width:
|
|
696
|
+
width: c,
|
|
641
697
|
height: d,
|
|
642
698
|
x: f,
|
|
643
|
-
y:
|
|
699
|
+
y: a
|
|
644
700
|
});
|
|
645
701
|
}
|
|
646
702
|
function dt(t, e) {
|
|
647
703
|
const n = ut(t).scrollLeft;
|
|
648
704
|
return e ? e.left + n : U(B(t)).left + n;
|
|
649
705
|
}
|
|
650
|
-
function
|
|
706
|
+
function $t(t, e) {
|
|
651
707
|
const n = t.getBoundingClientRect(), o = n.left + e.scrollLeft - dt(t, n), i = n.top + e.scrollTop;
|
|
652
708
|
return {
|
|
653
709
|
x: o,
|
|
654
710
|
y: i
|
|
655
711
|
};
|
|
656
712
|
}
|
|
657
|
-
function
|
|
713
|
+
function Re(t) {
|
|
658
714
|
let {
|
|
659
715
|
elements: e,
|
|
660
716
|
rect: n,
|
|
@@ -667,24 +723,24 @@ function Oe(t) {
|
|
|
667
723
|
let f = {
|
|
668
724
|
scrollLeft: 0,
|
|
669
725
|
scrollTop: 0
|
|
670
|
-
},
|
|
671
|
-
const
|
|
672
|
-
if ((d || !d && !s) && ((K(o) !== "body" || it(r)) && (f = ut(o)),
|
|
726
|
+
}, a = k(1);
|
|
727
|
+
const c = k(0), d = W(o);
|
|
728
|
+
if ((d || !d && !s) && ((K(o) !== "body" || it(r)) && (f = ut(o)), W(o))) {
|
|
673
729
|
const u = U(o);
|
|
674
|
-
|
|
730
|
+
a = Q(o), c.x = u.x + o.clientLeft, c.y = u.y + o.clientTop;
|
|
675
731
|
}
|
|
676
|
-
const h = r && !d && !s ?
|
|
732
|
+
const h = r && !d && !s ? $t(r, f) : k(0);
|
|
677
733
|
return {
|
|
678
|
-
width: n.width *
|
|
679
|
-
height: n.height *
|
|
680
|
-
x: n.x *
|
|
681
|
-
y: n.y *
|
|
734
|
+
width: n.width * a.x,
|
|
735
|
+
height: n.height * a.y,
|
|
736
|
+
x: n.x * a.x - f.scrollLeft * a.x + c.x + h.x,
|
|
737
|
+
y: n.y * a.y - f.scrollTop * a.y + c.y + h.y
|
|
682
738
|
};
|
|
683
739
|
}
|
|
684
|
-
function
|
|
740
|
+
function Ce(t) {
|
|
685
741
|
return Array.from(t.getClientRects());
|
|
686
742
|
}
|
|
687
|
-
function
|
|
743
|
+
function Se(t) {
|
|
688
744
|
const e = B(t), n = ut(t), o = t.ownerDocument.body, i = E(e.scrollWidth, e.clientWidth, o.scrollWidth, o.clientWidth), s = E(e.scrollHeight, e.clientHeight, o.scrollHeight, o.clientHeight);
|
|
689
745
|
let r = -n.scrollLeft + dt(t);
|
|
690
746
|
const l = -n.scrollTop;
|
|
@@ -695,20 +751,20 @@ function Ce(t) {
|
|
|
695
751
|
y: l
|
|
696
752
|
};
|
|
697
753
|
}
|
|
698
|
-
const
|
|
699
|
-
function
|
|
754
|
+
const Tt = 25;
|
|
755
|
+
function Ee(t, e) {
|
|
700
756
|
const n = D(t), o = B(t), i = n.visualViewport;
|
|
701
757
|
let s = o.clientWidth, r = o.clientHeight, l = 0, f = 0;
|
|
702
758
|
if (i) {
|
|
703
759
|
s = i.width, r = i.height;
|
|
704
|
-
const
|
|
705
|
-
(!
|
|
760
|
+
const c = Rt();
|
|
761
|
+
(!c || c && e === "fixed") && (l = i.offsetLeft, f = i.offsetTop);
|
|
706
762
|
}
|
|
707
|
-
const
|
|
708
|
-
if (
|
|
709
|
-
const
|
|
710
|
-
m <=
|
|
711
|
-
} else
|
|
763
|
+
const a = dt(o);
|
|
764
|
+
if (a <= 0) {
|
|
765
|
+
const c = o.ownerDocument, d = c.body, h = getComputedStyle(d), u = c.compatMode === "CSS1Compat" && parseFloat(h.marginLeft) + parseFloat(h.marginRight) || 0, m = Math.abs(o.clientWidth - d.clientWidth - u);
|
|
766
|
+
m <= Tt && (s -= m);
|
|
767
|
+
} else a <= Tt && (s += a);
|
|
712
768
|
return {
|
|
713
769
|
width: s,
|
|
714
770
|
height: r,
|
|
@@ -716,26 +772,26 @@ function Se(t, e) {
|
|
|
716
772
|
y: f
|
|
717
773
|
};
|
|
718
774
|
}
|
|
719
|
-
const
|
|
720
|
-
function
|
|
721
|
-
const n = U(t, !0, e === "fixed"), o = n.top + t.clientTop, i = n.left + t.clientLeft, s =
|
|
775
|
+
const De = /* @__PURE__ */ new Set(["absolute", "fixed"]);
|
|
776
|
+
function Le(t, e) {
|
|
777
|
+
const n = U(t, !0, e === "fixed"), o = n.top + t.clientTop, i = n.left + t.clientLeft, s = W(t) ? Q(t) : k(1), r = t.clientWidth * s.x, l = t.clientHeight * s.y, f = i * s.x, a = o * s.y;
|
|
722
778
|
return {
|
|
723
779
|
width: r,
|
|
724
780
|
height: l,
|
|
725
781
|
x: f,
|
|
726
|
-
y:
|
|
782
|
+
y: a
|
|
727
783
|
};
|
|
728
784
|
}
|
|
729
|
-
function
|
|
785
|
+
function Pt(t, e, n) {
|
|
730
786
|
let o;
|
|
731
787
|
if (e === "viewport")
|
|
732
|
-
o =
|
|
788
|
+
o = Ee(t, n);
|
|
733
789
|
else if (e === "document")
|
|
734
|
-
o =
|
|
790
|
+
o = Se(B(t));
|
|
735
791
|
else if (M(e))
|
|
736
|
-
o =
|
|
792
|
+
o = Le(e, n);
|
|
737
793
|
else {
|
|
738
|
-
const i =
|
|
794
|
+
const i = Nt(t);
|
|
739
795
|
o = {
|
|
740
796
|
x: e.x - i.x,
|
|
741
797
|
y: e.y - i.y,
|
|
@@ -745,34 +801,34 @@ function Lt(t, e, n) {
|
|
|
745
801
|
}
|
|
746
802
|
return ct(o);
|
|
747
803
|
}
|
|
748
|
-
function
|
|
749
|
-
const n =
|
|
750
|
-
return n === e || !M(n) || Z(n) ? !1 : F(n).position === "fixed" ||
|
|
804
|
+
function _t(t, e) {
|
|
805
|
+
const n = Y(t);
|
|
806
|
+
return n === e || !M(n) || Z(n) ? !1 : F(n).position === "fixed" || _t(n, e);
|
|
751
807
|
}
|
|
752
|
-
function
|
|
808
|
+
function Te(t, e) {
|
|
753
809
|
const n = e.get(t);
|
|
754
810
|
if (n)
|
|
755
811
|
return n;
|
|
756
|
-
let o =
|
|
812
|
+
let o = ot(t, [], !1).filter((l) => M(l) && K(l) !== "body"), i = null;
|
|
757
813
|
const s = F(t).position === "fixed";
|
|
758
|
-
let r = s ?
|
|
814
|
+
let r = s ? Y(t) : t;
|
|
759
815
|
for (; M(r) && !Z(r); ) {
|
|
760
|
-
const l = F(r), f =
|
|
761
|
-
!f && l.position === "fixed" && (i = null), (s ? !f && !i : !f && l.position === "static" && !!i &&
|
|
816
|
+
const l = F(r), f = Ot(r);
|
|
817
|
+
!f && l.position === "fixed" && (i = null), (s ? !f && !i : !f && l.position === "static" && !!i && De.has(i.position) || it(r) && !f && _t(t, r)) ? o = o.filter((c) => c !== r) : i = l, r = Y(r);
|
|
762
818
|
}
|
|
763
819
|
return e.set(t, o), o;
|
|
764
820
|
}
|
|
765
|
-
function
|
|
821
|
+
function Pe(t) {
|
|
766
822
|
let {
|
|
767
823
|
element: e,
|
|
768
824
|
boundary: n,
|
|
769
825
|
rootBoundary: o,
|
|
770
826
|
strategy: i
|
|
771
827
|
} = t;
|
|
772
|
-
const r = [...n === "clippingAncestors" ? ft(e) ? [] :
|
|
773
|
-
const d =
|
|
774
|
-
return
|
|
775
|
-
},
|
|
828
|
+
const r = [...n === "clippingAncestors" ? ft(e) ? [] : Te(e, this._c) : [].concat(n), o], l = r[0], f = r.reduce((a, c) => {
|
|
829
|
+
const d = Pt(e, c, i);
|
|
830
|
+
return a.top = E(d.top, a.top), a.right = j(d.right, a.right), a.bottom = j(d.bottom, a.bottom), a.left = E(d.left, a.left), a;
|
|
831
|
+
}, Pt(e, l, i));
|
|
776
832
|
return {
|
|
777
833
|
width: f.right - f.left,
|
|
778
834
|
height: f.bottom - f.top,
|
|
@@ -780,33 +836,33 @@ function Te(t) {
|
|
|
780
836
|
y: f.top
|
|
781
837
|
};
|
|
782
838
|
}
|
|
783
|
-
function
|
|
839
|
+
function Me(t) {
|
|
784
840
|
const {
|
|
785
841
|
width: e,
|
|
786
842
|
height: n
|
|
787
|
-
} =
|
|
843
|
+
} = Bt(t);
|
|
788
844
|
return {
|
|
789
845
|
width: e,
|
|
790
846
|
height: n
|
|
791
847
|
};
|
|
792
848
|
}
|
|
793
|
-
function
|
|
794
|
-
const o =
|
|
849
|
+
function Fe(t, e, n) {
|
|
850
|
+
const o = W(e), i = B(e), s = n === "fixed", r = U(t, !0, s, e);
|
|
795
851
|
let l = {
|
|
796
852
|
scrollLeft: 0,
|
|
797
853
|
scrollTop: 0
|
|
798
854
|
};
|
|
799
|
-
const f =
|
|
800
|
-
function
|
|
855
|
+
const f = k(0);
|
|
856
|
+
function a() {
|
|
801
857
|
f.x = dt(i);
|
|
802
858
|
}
|
|
803
859
|
if (o || !o && !s)
|
|
804
860
|
if ((K(e) !== "body" || it(i)) && (l = ut(e)), o) {
|
|
805
861
|
const u = U(e, !0, s, e);
|
|
806
862
|
f.x = u.x + e.clientLeft, f.y = u.y + e.clientTop;
|
|
807
|
-
} else i &&
|
|
808
|
-
s && !o && i &&
|
|
809
|
-
const
|
|
863
|
+
} else i && a();
|
|
864
|
+
s && !o && i && a();
|
|
865
|
+
const c = i && !o && !s ? $t(i, l) : k(0), d = r.left + l.scrollLeft - f.x - c.x, h = r.top + l.scrollTop - f.y - c.y;
|
|
810
866
|
return {
|
|
811
867
|
x: d,
|
|
812
868
|
y: h,
|
|
@@ -817,36 +873,36 @@ function Me(t, e, n) {
|
|
|
817
873
|
function ht(t) {
|
|
818
874
|
return F(t).position === "static";
|
|
819
875
|
}
|
|
820
|
-
function
|
|
821
|
-
if (!
|
|
876
|
+
function Mt(t, e) {
|
|
877
|
+
if (!W(t) || F(t).position === "fixed")
|
|
822
878
|
return null;
|
|
823
879
|
if (e)
|
|
824
880
|
return e(t);
|
|
825
881
|
let n = t.offsetParent;
|
|
826
882
|
return B(t) === n && (n = n.ownerDocument.body), n;
|
|
827
883
|
}
|
|
828
|
-
function
|
|
884
|
+
function Ht(t, e) {
|
|
829
885
|
const n = D(t);
|
|
830
886
|
if (ft(t))
|
|
831
887
|
return n;
|
|
832
|
-
if (!
|
|
833
|
-
let i =
|
|
888
|
+
if (!W(t)) {
|
|
889
|
+
let i = Y(t);
|
|
834
890
|
for (; i && !Z(i); ) {
|
|
835
891
|
if (M(i) && !ht(i))
|
|
836
892
|
return i;
|
|
837
|
-
i =
|
|
893
|
+
i = Y(i);
|
|
838
894
|
}
|
|
839
895
|
return n;
|
|
840
896
|
}
|
|
841
|
-
let o =
|
|
842
|
-
for (; o &&
|
|
843
|
-
o =
|
|
844
|
-
return o && Z(o) && ht(o) && !
|
|
897
|
+
let o = Mt(t, e);
|
|
898
|
+
for (; o && ge(o) && ht(o); )
|
|
899
|
+
o = Mt(o, e);
|
|
900
|
+
return o && Z(o) && ht(o) && !Ot(o) ? n : o || ve(t) || n;
|
|
845
901
|
}
|
|
846
|
-
const
|
|
847
|
-
const e = this.getOffsetParent ||
|
|
902
|
+
const Ve = async function(t) {
|
|
903
|
+
const e = this.getOffsetParent || Ht, n = this.getDimensions, o = await n(t.floating);
|
|
848
904
|
return {
|
|
849
|
-
reference:
|
|
905
|
+
reference: Fe(t.reference, await e(t.floating), t.strategy),
|
|
850
906
|
floating: {
|
|
851
907
|
x: 0,
|
|
852
908
|
y: 0,
|
|
@@ -855,25 +911,25 @@ const Fe = async function(t) {
|
|
|
855
911
|
}
|
|
856
912
|
};
|
|
857
913
|
};
|
|
858
|
-
function
|
|
914
|
+
function ke(t) {
|
|
859
915
|
return F(t).direction === "rtl";
|
|
860
916
|
}
|
|
861
917
|
const We = {
|
|
862
|
-
convertOffsetParentRelativeRectToViewportRelativeRect:
|
|
918
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: Re,
|
|
863
919
|
getDocumentElement: B,
|
|
864
|
-
getClippingRect:
|
|
865
|
-
getOffsetParent:
|
|
866
|
-
getElementRects:
|
|
867
|
-
getClientRects:
|
|
868
|
-
getDimensions:
|
|
920
|
+
getClippingRect: Pe,
|
|
921
|
+
getOffsetParent: Ht,
|
|
922
|
+
getElementRects: Ve,
|
|
923
|
+
getClientRects: Ce,
|
|
924
|
+
getDimensions: Me,
|
|
869
925
|
getScale: Q,
|
|
870
926
|
isElement: M,
|
|
871
|
-
isRTL:
|
|
927
|
+
isRTL: ke
|
|
872
928
|
};
|
|
873
|
-
function
|
|
929
|
+
function zt(t, e) {
|
|
874
930
|
return t.x === e.x && t.y === e.y && t.width === e.width && t.height === e.height;
|
|
875
931
|
}
|
|
876
|
-
function
|
|
932
|
+
function Be(t, e) {
|
|
877
933
|
let n = null, o;
|
|
878
934
|
const i = B(t);
|
|
879
935
|
function s() {
|
|
@@ -882,44 +938,44 @@ function ke(t, e) {
|
|
|
882
938
|
}
|
|
883
939
|
function r(l, f) {
|
|
884
940
|
l === void 0 && (l = !1), f === void 0 && (f = 1), s();
|
|
885
|
-
const
|
|
886
|
-
left:
|
|
941
|
+
const a = t.getBoundingClientRect(), {
|
|
942
|
+
left: c,
|
|
887
943
|
top: d,
|
|
888
944
|
width: h,
|
|
889
945
|
height: u
|
|
890
|
-
} =
|
|
946
|
+
} = a;
|
|
891
947
|
if (l || e(), !h || !u)
|
|
892
948
|
return;
|
|
893
|
-
const m = rt(d), g = rt(i.clientWidth - (
|
|
894
|
-
rootMargin: -m + "px " + -g + "px " + -
|
|
949
|
+
const m = rt(d), g = rt(i.clientWidth - (c + h)), p = rt(i.clientHeight - (d + u)), w = rt(c), v = {
|
|
950
|
+
rootMargin: -m + "px " + -g + "px " + -p + "px " + -w + "px",
|
|
895
951
|
threshold: E(0, j(1, f)) || 1
|
|
896
952
|
};
|
|
897
|
-
let
|
|
953
|
+
let A = !0;
|
|
898
954
|
function b(C) {
|
|
899
|
-
const
|
|
900
|
-
if (
|
|
901
|
-
if (!
|
|
955
|
+
const y = C[0].intersectionRatio;
|
|
956
|
+
if (y !== f) {
|
|
957
|
+
if (!A)
|
|
902
958
|
return r();
|
|
903
|
-
|
|
959
|
+
y ? r(!1, y) : o = setTimeout(() => {
|
|
904
960
|
r(!1, 1e-7);
|
|
905
961
|
}, 1e3);
|
|
906
962
|
}
|
|
907
|
-
|
|
963
|
+
y === 1 && !zt(a, t.getBoundingClientRect()) && r(), A = !1;
|
|
908
964
|
}
|
|
909
965
|
try {
|
|
910
966
|
n = new IntersectionObserver(b, {
|
|
911
|
-
...
|
|
967
|
+
...v,
|
|
912
968
|
// Handle <iframe>s
|
|
913
969
|
root: i.ownerDocument
|
|
914
970
|
});
|
|
915
971
|
} catch {
|
|
916
|
-
n = new IntersectionObserver(b,
|
|
972
|
+
n = new IntersectionObserver(b, v);
|
|
917
973
|
}
|
|
918
974
|
n.observe(t);
|
|
919
975
|
}
|
|
920
976
|
return r(!0), s;
|
|
921
977
|
}
|
|
922
|
-
function
|
|
978
|
+
function ze(t, e, n, o) {
|
|
923
979
|
o === void 0 && (o = {});
|
|
924
980
|
const {
|
|
925
981
|
ancestorScroll: i = !0,
|
|
@@ -927,35 +983,35 @@ function He(t, e, n, o) {
|
|
|
927
983
|
elementResize: r = typeof ResizeObserver == "function",
|
|
928
984
|
layoutShift: l = typeof IntersectionObserver == "function",
|
|
929
985
|
animationFrame: f = !1
|
|
930
|
-
} = o,
|
|
931
|
-
|
|
932
|
-
i &&
|
|
986
|
+
} = o, a = Ct(t), c = i || s ? [...a ? ot(a) : [], ...ot(e)] : [];
|
|
987
|
+
c.forEach((w) => {
|
|
988
|
+
i && w.addEventListener("scroll", n, {
|
|
933
989
|
passive: !0
|
|
934
|
-
}), s &&
|
|
990
|
+
}), s && w.addEventListener("resize", n);
|
|
935
991
|
});
|
|
936
|
-
const d =
|
|
992
|
+
const d = a && l ? Be(a, n) : null;
|
|
937
993
|
let h = -1, u = null;
|
|
938
|
-
r && (u = new ResizeObserver((
|
|
939
|
-
let [
|
|
940
|
-
|
|
941
|
-
var
|
|
942
|
-
(
|
|
994
|
+
r && (u = new ResizeObserver((w) => {
|
|
995
|
+
let [x] = w;
|
|
996
|
+
x && x.target === a && u && (u.unobserve(e), cancelAnimationFrame(h), h = requestAnimationFrame(() => {
|
|
997
|
+
var v;
|
|
998
|
+
(v = u) == null || v.observe(e);
|
|
943
999
|
})), n();
|
|
944
|
-
}),
|
|
1000
|
+
}), a && !f && u.observe(a), u.observe(e));
|
|
945
1001
|
let m, g = f ? U(t) : null;
|
|
946
|
-
f &&
|
|
947
|
-
function
|
|
948
|
-
const
|
|
949
|
-
g && !
|
|
1002
|
+
f && p();
|
|
1003
|
+
function p() {
|
|
1004
|
+
const w = U(t);
|
|
1005
|
+
g && !zt(g, w) && n(), g = w, m = requestAnimationFrame(p);
|
|
950
1006
|
}
|
|
951
1007
|
return n(), () => {
|
|
952
|
-
var
|
|
953
|
-
|
|
954
|
-
i &&
|
|
955
|
-
}), d == null || d(), (
|
|
1008
|
+
var w;
|
|
1009
|
+
c.forEach((x) => {
|
|
1010
|
+
i && x.removeEventListener("scroll", n), s && x.removeEventListener("resize", n);
|
|
1011
|
+
}), d == null || d(), (w = u) == null || w.disconnect(), u = null, f && cancelAnimationFrame(m);
|
|
956
1012
|
};
|
|
957
1013
|
}
|
|
958
|
-
const
|
|
1014
|
+
const Ie = fe, je = ue, Xe = le, Ye = de, Ne = se, $e = (t, e, n) => {
|
|
959
1015
|
const o = /* @__PURE__ */ new Map(), i = {
|
|
960
1016
|
platform: We,
|
|
961
1017
|
...n
|
|
@@ -968,66 +1024,66 @@ const ze = fe, Ie = le, je = ue, Be = se, Ne = (t, e, n) => {
|
|
|
968
1024
|
platform: s
|
|
969
1025
|
});
|
|
970
1026
|
};
|
|
971
|
-
function
|
|
1027
|
+
function _e(t) {
|
|
972
1028
|
return t != null && typeof t == "object" && "$el" in t;
|
|
973
1029
|
}
|
|
974
|
-
function
|
|
975
|
-
if (
|
|
1030
|
+
function xt(t) {
|
|
1031
|
+
if (_e(t)) {
|
|
976
1032
|
const e = t.$el;
|
|
977
|
-
return
|
|
1033
|
+
return At(e) && K(e) === "#comment" ? null : e;
|
|
978
1034
|
}
|
|
979
1035
|
return t;
|
|
980
1036
|
}
|
|
981
1037
|
function J(t) {
|
|
982
|
-
return typeof t == "function" ? t() :
|
|
1038
|
+
return typeof t == "function" ? t() : Ut(t);
|
|
983
1039
|
}
|
|
984
|
-
function
|
|
1040
|
+
function qe(t) {
|
|
985
1041
|
return {
|
|
986
1042
|
name: "arrow",
|
|
987
1043
|
options: t,
|
|
988
1044
|
fn(e) {
|
|
989
|
-
const n =
|
|
990
|
-
return n == null ? {} :
|
|
1045
|
+
const n = xt(J(t.element));
|
|
1046
|
+
return n == null ? {} : Ne({
|
|
991
1047
|
element: n,
|
|
992
1048
|
padding: t.padding
|
|
993
1049
|
}).fn(e);
|
|
994
1050
|
}
|
|
995
1051
|
};
|
|
996
1052
|
}
|
|
997
|
-
function
|
|
1053
|
+
function It(t) {
|
|
998
1054
|
return typeof window > "u" ? 1 : (t.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
999
1055
|
}
|
|
1000
|
-
function
|
|
1001
|
-
const n =
|
|
1056
|
+
function Ft(t, e) {
|
|
1057
|
+
const n = It(t);
|
|
1002
1058
|
return Math.round(e * n) / n;
|
|
1003
1059
|
}
|
|
1004
|
-
function
|
|
1060
|
+
function Ue(t, e, n) {
|
|
1005
1061
|
n === void 0 && (n = {});
|
|
1006
|
-
const o = n.whileElementsMounted, i =
|
|
1007
|
-
var
|
|
1008
|
-
return (
|
|
1009
|
-
}), s =
|
|
1010
|
-
var
|
|
1011
|
-
return (
|
|
1012
|
-
}), l =
|
|
1013
|
-
var
|
|
1014
|
-
return (
|
|
1015
|
-
}), f =
|
|
1016
|
-
var
|
|
1017
|
-
return (
|
|
1018
|
-
}),
|
|
1019
|
-
const
|
|
1062
|
+
const o = n.whileElementsMounted, i = I(() => {
|
|
1063
|
+
var y;
|
|
1064
|
+
return (y = J(n.open)) != null ? y : !0;
|
|
1065
|
+
}), s = I(() => J(n.middleware)), r = I(() => {
|
|
1066
|
+
var y;
|
|
1067
|
+
return (y = J(n.placement)) != null ? y : "bottom";
|
|
1068
|
+
}), l = I(() => {
|
|
1069
|
+
var y;
|
|
1070
|
+
return (y = J(n.strategy)) != null ? y : "absolute";
|
|
1071
|
+
}), f = I(() => {
|
|
1072
|
+
var y;
|
|
1073
|
+
return (y = J(n.transform)) != null ? y : !0;
|
|
1074
|
+
}), a = I(() => xt(t.value)), c = I(() => xt(e.value)), d = nt(0), h = nt(0), u = nt(l.value), m = nt(r.value), g = Xt({}), p = nt(!1), w = I(() => {
|
|
1075
|
+
const y = {
|
|
1020
1076
|
position: u.value,
|
|
1021
1077
|
left: "0",
|
|
1022
1078
|
top: "0"
|
|
1023
1079
|
};
|
|
1024
|
-
if (!
|
|
1025
|
-
return
|
|
1026
|
-
const O =
|
|
1080
|
+
if (!c.value)
|
|
1081
|
+
return y;
|
|
1082
|
+
const O = Ft(c.value, d.value), S = Ft(c.value, h.value);
|
|
1027
1083
|
return f.value ? {
|
|
1028
|
-
...
|
|
1084
|
+
...y,
|
|
1029
1085
|
transform: "translate(" + O + "px, " + S + "px)",
|
|
1030
|
-
...
|
|
1086
|
+
...It(c.value) >= 1.5 && {
|
|
1031
1087
|
willChange: "transform"
|
|
1032
1088
|
}
|
|
1033
1089
|
} : {
|
|
@@ -1036,58 +1092,59 @@ function Ye(t, e, n) {
|
|
|
1036
1092
|
top: S + "px"
|
|
1037
1093
|
};
|
|
1038
1094
|
});
|
|
1039
|
-
let
|
|
1040
|
-
function
|
|
1041
|
-
if (
|
|
1095
|
+
let x;
|
|
1096
|
+
function v() {
|
|
1097
|
+
if (a.value == null || c.value == null)
|
|
1042
1098
|
return;
|
|
1043
|
-
const
|
|
1044
|
-
|
|
1099
|
+
const y = i.value;
|
|
1100
|
+
$e(a.value, c.value, {
|
|
1045
1101
|
middleware: s.value,
|
|
1046
1102
|
placement: r.value,
|
|
1047
1103
|
strategy: l.value
|
|
1048
1104
|
}).then((O) => {
|
|
1049
|
-
d.value = O.x, h.value = O.y, u.value = O.strategy, m.value = O.placement, g.value = O.middlewareData,
|
|
1105
|
+
d.value = O.x, h.value = O.y, u.value = O.strategy, m.value = O.placement, g.value = O.middlewareData, p.value = y !== !1;
|
|
1050
1106
|
});
|
|
1051
1107
|
}
|
|
1052
|
-
function
|
|
1053
|
-
typeof
|
|
1108
|
+
function A() {
|
|
1109
|
+
typeof x == "function" && (x(), x = void 0);
|
|
1054
1110
|
}
|
|
1055
1111
|
function b() {
|
|
1056
|
-
if (
|
|
1057
|
-
|
|
1112
|
+
if (A(), o === void 0) {
|
|
1113
|
+
v();
|
|
1058
1114
|
return;
|
|
1059
1115
|
}
|
|
1060
|
-
if (
|
|
1061
|
-
|
|
1116
|
+
if (a.value != null && c.value != null) {
|
|
1117
|
+
x = o(a.value, c.value, v);
|
|
1062
1118
|
return;
|
|
1063
1119
|
}
|
|
1064
1120
|
}
|
|
1065
1121
|
function C() {
|
|
1066
|
-
i.value || (
|
|
1122
|
+
i.value || (p.value = !1);
|
|
1067
1123
|
}
|
|
1068
|
-
return mt([s, r, l, i],
|
|
1124
|
+
return mt([s, r, l, i], v, {
|
|
1069
1125
|
flush: "sync"
|
|
1070
|
-
}), mt([
|
|
1126
|
+
}), mt([a, c], b, {
|
|
1071
1127
|
flush: "sync"
|
|
1072
1128
|
}), mt(i, C, {
|
|
1073
1129
|
flush: "sync"
|
|
1074
|
-
}),
|
|
1130
|
+
}), Yt() && qt(A), {
|
|
1075
1131
|
x: G(d),
|
|
1076
1132
|
y: G(h),
|
|
1077
1133
|
strategy: G(u),
|
|
1078
1134
|
placement: G(m),
|
|
1079
1135
|
middlewareData: G(g),
|
|
1080
|
-
isPositioned: G(
|
|
1081
|
-
floatingStyles:
|
|
1082
|
-
update:
|
|
1136
|
+
isPositioned: G(p),
|
|
1137
|
+
floatingStyles: w,
|
|
1138
|
+
update: v
|
|
1083
1139
|
};
|
|
1084
1140
|
}
|
|
1085
1141
|
export {
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1142
|
+
ze as a,
|
|
1143
|
+
qe as b,
|
|
1144
|
+
Ye as c,
|
|
1145
|
+
Xe as f,
|
|
1146
|
+
Ie as o,
|
|
1090
1147
|
je as s,
|
|
1091
|
-
|
|
1148
|
+
Ue as u
|
|
1092
1149
|
};
|
|
1093
|
-
//# sourceMappingURL=floating-ui.vue-
|
|
1150
|
+
//# sourceMappingURL=floating-ui.vue-CuGrC-z8.js.map
|