@oneclick.dev/cms-core-modules 0.0.82 → 0.0.84

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.
Files changed (68) hide show
  1. package/dist/{ContentEditor-Dk-iDEjl.mjs → ContentEditor-DPhhOkx3.mjs} +7085 -5936
  2. package/dist/{ContentEditor-4e80zFyn.js → ContentEditor-DrxtH_Hq.js} +42 -42
  3. package/dist/{Create-DtFzwxn_.mjs → Create-6uT9HWar.mjs} +35 -35
  4. package/dist/{Create-CRn2sMHp.js → Create-DuZ5nZrX.js} +1 -1
  5. package/dist/{DateFormatter-DfIwyrnF.mjs → DateFormatter-2B0R-DY4.mjs} +213 -406
  6. package/dist/DateFormatter-DbtOLV0L.js +1 -0
  7. package/dist/{Detail-Bxi7lG9x.js → Detail-BZ-iE9vf.js} +1 -1
  8. package/dist/{Detail-B4b_FLDa.mjs → Detail-C1Blq61w.mjs} +90 -90
  9. package/dist/{Detail-BayNaAg9.js → Detail-C8wQiDcv.js} +1 -1
  10. package/dist/{Detail-BwDnY42G.mjs → Detail-CJVMJDP7.mjs} +17 -17
  11. package/dist/{Detail-CnK-qbhE.js → Detail-CPqug27l.js} +1 -1
  12. package/dist/Detail-CjuhjPby.js +1 -0
  13. package/dist/{Detail-U0mgLKt6.mjs → Detail-CtItxMX4.mjs} +62 -63
  14. package/dist/{Detail-CVgWHbMC.mjs → Detail-Dnpnmy4-.mjs} +158 -158
  15. package/dist/{Entries-D7MHylQE.mjs → Entries-BkOPae4R.mjs} +49 -49
  16. package/dist/Entries-CcEW98F5.js +1 -0
  17. package/dist/{NewReservationDialog.vue_vue_type_script_setup_true_lang-Ds7z0qeH.mjs → NewReservationDialog.vue_vue_type_script_setup_true_lang-Bc946oSc.mjs} +1 -1
  18. package/dist/{NewReservationDialog.vue_vue_type_script_setup_true_lang-C5YczjNb.js → NewReservationDialog.vue_vue_type_script_setup_true_lang-CqERfyYb.js} +1 -1
  19. package/dist/{Overview-CwCAeBnX.js → Overview-CA8wh_BI.js} +1 -1
  20. package/dist/{Overview-CgViRnNc.mjs → Overview-D4MFwRI_.mjs} +67 -68
  21. package/dist/{Overview-pCO_47Zt.js → Overview-Da0XexiT.js} +1 -1
  22. package/dist/Overview-DeQQ0FY3.js +1 -0
  23. package/dist/{Overview--XpvBbqz.mjs → Overview-DoOASlNz.mjs} +1 -3
  24. package/dist/{Overview-CuCQgqVp.mjs → Overview-gJSvftdE.mjs} +34 -34
  25. package/dist/{ReservationDetailDialog.vue_vue_type_script_setup_true_lang-B7ks5mbf.mjs → ReservationDetailDialog.vue_vue_type_script_setup_true_lang-Cohhnd5x.mjs} +0 -1
  26. package/dist/{ReservationDetailDialog.vue_vue_type_script_setup_true_lang-Vxubki_v.js → ReservationDetailDialog.vue_vue_type_script_setup_true_lang-VWVIxIr6.js} +1 -1
  27. package/dist/{SeoHealth-CC0rW1AG.mjs → SeoHealth-Bc5chnaa.mjs} +14 -14
  28. package/dist/{SeoHealth-EZzDmPDM.js → SeoHealth-BkpJ1F2Y.js} +1 -1
  29. package/dist/TableView-BPWAx--G.mjs +5743 -0
  30. package/dist/TableView-D63QrVlK.js +4 -0
  31. package/dist/View-BL70u98U.js +1 -0
  32. package/dist/{View-DDXN0tKD.mjs → View-BO5N911y.mjs} +5 -5
  33. package/dist/{agenda-XqvbrU72.mjs → agenda-C5grvzSa.mjs} +166 -169
  34. package/dist/agenda-DXMwVWpN.js +1 -0
  35. package/dist/{availability-B-tRp8hB.mjs → availability-C1NqOFsQ.mjs} +81 -81
  36. package/dist/{availability-BiBbzEIM.js → availability-D_wnfLsH.js} +1 -1
  37. package/dist/cms-core-modules.css +1 -1
  38. package/dist/{exceptions-CLgeeUSy.mjs → exceptions-BIwMhYa4.mjs} +1 -1
  39. package/dist/{exceptions-wEQEVzIs.js → exceptions-Cn7zooEu.js} +1 -1
  40. package/dist/{index-DTzdHh6g.js → index-C9pSS15N.js} +2 -2
  41. package/dist/{index-N0NoDEsI.mjs → index-MwjeLHPP.mjs} +3 -3
  42. package/dist/index.cjs.js +1 -1
  43. package/dist/index.mjs +50 -36
  44. package/dist/orders-CG1QUCN8.js +1 -0
  45. package/dist/orders-CeixEBcU.mjs +396 -0
  46. package/dist/server-handlers.cjs.js +1 -1
  47. package/dist/server-handlers.mjs +292 -256
  48. package/dist/src/contentManager/config.d.ts +28 -0
  49. package/dist/src/contentManager/index.d.ts +28 -0
  50. package/dist/src/contentManager/server.d.ts +7 -0
  51. package/dist/src/server-handlers.d.ts +1 -0
  52. package/package.json +2 -2
  53. package/dist/DateFormatter-C9qfmQnP.js +0 -1
  54. package/dist/Detail-BcboL7NF.js +0 -1
  55. package/dist/Entries-BPkZ7Jg5.js +0 -1
  56. package/dist/Overview-B-8TLLjh.js +0 -1
  57. package/dist/TableView-Ce8H65pL.js +0 -586
  58. package/dist/TableView-DRQvOW85.mjs +0 -89190
  59. package/dist/View-DfzaVOzS.js +0 -1
  60. package/dist/agenda-wNFDKn0G.js +0 -1
  61. package/dist/floating-ui.dom-BO2Hr6mz.mjs +0 -1292
  62. package/dist/floating-ui.dom-CAr9LGoC.js +0 -1
  63. package/dist/index-DYpruS-A-CA2jEOA3.js +0 -88
  64. package/dist/index-DYpruS-A-D38FBcI3.mjs +0 -4211
  65. package/dist/index-YMaY4uuk-BgpTtr73.js +0 -1
  66. package/dist/index-YMaY4uuk-C_xV5K9Z.mjs +0 -1300
  67. package/dist/orders-Bqa3Z3tH.mjs +0 -356
  68. package/dist/orders-D5GJOZXN.js +0 -1
@@ -1,1292 +0,0 @@
1
- const Dt = ["top", "right", "bottom", "left"], vt = ["start", "end"], bt = /* @__PURE__ */ Dt.reduce((t, e) => t.concat(e, e + "-" + vt[0], e + "-" + vt[1]), []), $ = Math.min, L = Math.max, ot = Math.round, nt = Math.floor, X = (t) => ({
2
- x: t,
3
- y: t
4
- }), Xt = {
5
- left: "right",
6
- right: "left",
7
- bottom: "top",
8
- top: "bottom"
9
- }, jt = {
10
- start: "end",
11
- end: "start"
12
- };
13
- function ut(t, e, n) {
14
- return L(t, $(e, n));
15
- }
16
- function _(t, e) {
17
- return typeof t == "function" ? t(e) : t;
18
- }
19
- function k(t) {
20
- return t.split("-")[0];
21
- }
22
- function V(t) {
23
- return t.split("-")[1];
24
- }
25
- function mt(t) {
26
- return t === "x" ? "y" : "x";
27
- }
28
- function ht(t) {
29
- return t === "y" ? "height" : "width";
30
- }
31
- const Yt = /* @__PURE__ */ new Set(["top", "bottom"]);
32
- function N(t) {
33
- return Yt.has(k(t)) ? "y" : "x";
34
- }
35
- function gt(t) {
36
- return mt(N(t));
37
- }
38
- function Mt(t, e, n) {
39
- n === void 0 && (n = !1);
40
- const o = V(t), i = gt(t), s = ht(i);
41
- let r = i === "x" ? o === (n ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
42
- return e.reference[s] > e.floating[s] && (r = st(r)), [r, st(r)];
43
- }
44
- function qt(t) {
45
- const e = st(t);
46
- return [it(t), e, it(e)];
47
- }
48
- function it(t) {
49
- return t.replace(/start|end/g, (e) => jt[e]);
50
- }
51
- const At = ["left", "right"], Ot = ["right", "left"], Ut = ["top", "bottom"], Kt = ["bottom", "top"];
52
- function Gt(t, e, n) {
53
- switch (t) {
54
- case "top":
55
- case "bottom":
56
- return n ? e ? Ot : At : e ? At : Ot;
57
- case "left":
58
- case "right":
59
- return e ? Ut : Kt;
60
- default:
61
- return [];
62
- }
63
- }
64
- function Jt(t, e, n, o) {
65
- const i = V(t);
66
- let s = Gt(k(t), n === "start", o);
67
- return i && (s = s.map((r) => r + "-" + i), e && (s = s.concat(s.map(it)))), s;
68
- }
69
- function st(t) {
70
- return t.replace(/left|right|bottom|top/g, (e) => Xt[e]);
71
- }
72
- function Qt(t) {
73
- return {
74
- top: 0,
75
- right: 0,
76
- bottom: 0,
77
- left: 0,
78
- ...t
79
- };
80
- }
81
- function pt(t) {
82
- return typeof t != "number" ? Qt(t) : {
83
- top: t,
84
- right: t,
85
- bottom: t,
86
- left: t
87
- };
88
- }
89
- function J(t) {
90
- const {
91
- x: e,
92
- y: n,
93
- width: o,
94
- height: i
95
- } = t;
96
- return {
97
- width: o,
98
- height: i,
99
- top: n,
100
- left: e,
101
- right: e + o,
102
- bottom: n + i,
103
- x: e,
104
- y: n
105
- };
106
- }
107
- function Rt(t, e, n) {
108
- let {
109
- reference: o,
110
- floating: i
111
- } = t;
112
- const s = N(e), r = gt(e), c = ht(r), a = k(e), u = s === "y", d = o.x + o.width / 2 - i.width / 2, l = o.y + o.height / 2 - i.height / 2, m = o[c] / 2 - i[c] / 2;
113
- let f;
114
- switch (a) {
115
- case "top":
116
- f = {
117
- x: d,
118
- y: o.y - i.height
119
- };
120
- break;
121
- case "bottom":
122
- f = {
123
- x: d,
124
- y: o.y + o.height
125
- };
126
- break;
127
- case "right":
128
- f = {
129
- x: o.x + o.width,
130
- y: l
131
- };
132
- break;
133
- case "left":
134
- f = {
135
- x: o.x - i.width,
136
- y: l
137
- };
138
- break;
139
- default:
140
- f = {
141
- x: o.x,
142
- y: o.y
143
- };
144
- }
145
- switch (V(e)) {
146
- case "start":
147
- f[r] -= m * (n && u ? -1 : 1);
148
- break;
149
- case "end":
150
- f[r] += m * (n && u ? -1 : 1);
151
- break;
152
- }
153
- return f;
154
- }
155
- async function Zt(t, e) {
156
- var n;
157
- e === void 0 && (e = {});
158
- const {
159
- x: o,
160
- y: i,
161
- platform: s,
162
- rects: r,
163
- elements: c,
164
- strategy: a
165
- } = t, {
166
- boundary: u = "clippingAncestors",
167
- rootBoundary: d = "viewport",
168
- elementContext: l = "floating",
169
- altBoundary: m = !1,
170
- padding: f = 0
171
- } = _(e, t), h = pt(f), p = c[m ? l === "floating" ? "reference" : "floating" : l], w = J(await s.getClippingRect({
172
- element: (n = await (s.isElement == null ? void 0 : s.isElement(p))) == null || n ? p : p.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(c.floating)),
173
- boundary: u,
174
- rootBoundary: d,
175
- strategy: a
176
- })), x = l === "floating" ? {
177
- x: o,
178
- y: i,
179
- width: r.floating.width,
180
- height: r.floating.height
181
- } : r.reference, y = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(c.floating)), v = await (s.isElement == null ? void 0 : s.isElement(y)) ? await (s.getScale == null ? void 0 : s.getScale(y)) || {
182
- x: 1,
183
- y: 1
184
- } : {
185
- x: 1,
186
- y: 1
187
- }, A = J(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({
188
- elements: c,
189
- rect: x,
190
- offsetParent: y,
191
- strategy: a
192
- }) : x);
193
- return {
194
- top: (w.top - A.top + h.top) / v.y,
195
- bottom: (A.bottom - w.bottom + h.bottom) / v.y,
196
- left: (w.left - A.left + h.left) / v.x,
197
- right: (A.right - w.right + h.right) / v.x
198
- };
199
- }
200
- const te = async (t, e, n) => {
201
- const {
202
- placement: o = "bottom",
203
- strategy: i = "absolute",
204
- middleware: s = [],
205
- platform: r
206
- } = n, c = s.filter(Boolean), a = await (r.isRTL == null ? void 0 : r.isRTL(e));
207
- let u = await r.getElementRects({
208
- reference: t,
209
- floating: e,
210
- strategy: i
211
- }), {
212
- x: d,
213
- y: l
214
- } = Rt(u, o, a), m = o, f = {}, h = 0;
215
- for (let p = 0; p < c.length; p++) {
216
- var g;
217
- const {
218
- name: w,
219
- fn: x
220
- } = c[p], {
221
- x: y,
222
- y: v,
223
- data: A,
224
- reset: O
225
- } = await x({
226
- x: d,
227
- y: l,
228
- initialPlacement: o,
229
- placement: m,
230
- strategy: i,
231
- middlewareData: f,
232
- rects: u,
233
- platform: {
234
- ...r,
235
- detectOverflow: (g = r.detectOverflow) != null ? g : Zt
236
- },
237
- elements: {
238
- reference: t,
239
- floating: e
240
- }
241
- });
242
- d = y ?? d, l = v ?? l, f = {
243
- ...f,
244
- [w]: {
245
- ...f[w],
246
- ...A
247
- }
248
- }, O && h <= 50 && (h++, typeof O == "object" && (O.placement && (m = O.placement), O.rects && (u = O.rects === !0 ? await r.getElementRects({
249
- reference: t,
250
- floating: e,
251
- strategy: i
252
- }) : O.rects), {
253
- x: d,
254
- y: l
255
- } = Rt(u, m, a)), p = -1);
256
- }
257
- return {
258
- x: d,
259
- y: l,
260
- placement: m,
261
- strategy: i,
262
- middlewareData: f
263
- };
264
- }, ee = (t) => ({
265
- name: "arrow",
266
- options: t,
267
- async fn(e) {
268
- const {
269
- x: n,
270
- y: o,
271
- placement: i,
272
- rects: s,
273
- platform: r,
274
- elements: c,
275
- middlewareData: a
276
- } = e, {
277
- element: u,
278
- padding: d = 0
279
- } = _(t, e) || {};
280
- if (u == null)
281
- return {};
282
- const l = pt(d), m = {
283
- x: n,
284
- y: o
285
- }, f = gt(i), h = ht(f), g = await r.getDimensions(u), p = f === "y", w = p ? "top" : "left", x = p ? "bottom" : "right", y = p ? "clientHeight" : "clientWidth", v = s.reference[h] + s.reference[f] - m[f] - s.floating[h], A = m[f] - s.reference[f], O = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(u));
286
- let R = O ? O[y] : 0;
287
- (!R || !await (r.isElement == null ? void 0 : r.isElement(O))) && (R = c.floating[y] || s.floating[h]);
288
- const B = v / 2 - A / 2, T = R / 2 - g[h] / 2 - 1, b = $(l[w], T), S = $(l[x], T), P = b, E = R - g[h] - S, C = R / 2 - g[h] / 2 + B, H = ut(P, C, E), W = !a.arrow && V(i) != null && C !== H && s.reference[h] / 2 - (C < P ? b : S) - g[h] / 2 < 0, D = W ? C < P ? C - P : C - E : 0;
289
- return {
290
- [f]: m[f] + D,
291
- data: {
292
- [f]: H,
293
- centerOffset: C - H - D,
294
- ...W && {
295
- alignmentOffset: D
296
- }
297
- },
298
- reset: W
299
- };
300
- }
301
- });
302
- function ne(t, e, n) {
303
- return (t ? [...n.filter((i) => V(i) === t), ...n.filter((i) => V(i) !== t)] : n.filter((i) => k(i) === i)).filter((i) => t ? V(i) === t || (e ? it(i) !== i : !1) : !0);
304
- }
305
- const oe = function(t) {
306
- return t === void 0 && (t = {}), {
307
- name: "autoPlacement",
308
- options: t,
309
- async fn(e) {
310
- var n, o, i;
311
- const {
312
- rects: s,
313
- middlewareData: r,
314
- placement: c,
315
- platform: a,
316
- elements: u
317
- } = e, {
318
- crossAxis: d = !1,
319
- alignment: l,
320
- allowedPlacements: m = bt,
321
- autoAlignment: f = !0,
322
- ...h
323
- } = _(t, e), g = l !== void 0 || m === bt ? ne(l || null, f, m) : m, p = await a.detectOverflow(e, h), w = ((n = r.autoPlacement) == null ? void 0 : n.index) || 0, x = g[w];
324
- if (x == null)
325
- return {};
326
- const y = Mt(x, s, await (a.isRTL == null ? void 0 : a.isRTL(u.floating)));
327
- if (c !== x)
328
- return {
329
- reset: {
330
- placement: g[0]
331
- }
332
- };
333
- const v = [p[k(x)], p[y[0]], p[y[1]]], A = [...((o = r.autoPlacement) == null ? void 0 : o.overflows) || [], {
334
- placement: x,
335
- overflows: v
336
- }], O = g[w + 1];
337
- if (O)
338
- return {
339
- data: {
340
- index: w + 1,
341
- overflows: A
342
- },
343
- reset: {
344
- placement: O
345
- }
346
- };
347
- const R = A.map((b) => {
348
- const S = V(b.placement);
349
- return [b.placement, S && d ? (
350
- // Check along the mainAxis and main crossAxis side.
351
- b.overflows.slice(0, 2).reduce((P, E) => P + E, 0)
352
- ) : (
353
- // Check only the mainAxis.
354
- b.overflows[0]
355
- ), b.overflows];
356
- }).sort((b, S) => b[1] - S[1]), T = ((i = R.filter((b) => b[2].slice(
357
- 0,
358
- // Aligned placements should not check their opposite crossAxis
359
- // side.
360
- V(b[0]) ? 2 : 3
361
- ).every((S) => S <= 0))[0]) == null ? void 0 : i[0]) || R[0][0];
362
- return T !== c ? {
363
- data: {
364
- index: w + 1,
365
- overflows: A
366
- },
367
- reset: {
368
- placement: T
369
- }
370
- } : {};
371
- }
372
- };
373
- }, ie = function(t) {
374
- return t === void 0 && (t = {}), {
375
- name: "flip",
376
- options: t,
377
- async fn(e) {
378
- var n, o;
379
- const {
380
- placement: i,
381
- middlewareData: s,
382
- rects: r,
383
- initialPlacement: c,
384
- platform: a,
385
- elements: u
386
- } = e, {
387
- mainAxis: d = !0,
388
- crossAxis: l = !0,
389
- fallbackPlacements: m,
390
- fallbackStrategy: f = "bestFit",
391
- fallbackAxisSideDirection: h = "none",
392
- flipAlignment: g = !0,
393
- ...p
394
- } = _(t, e);
395
- if ((n = s.arrow) != null && n.alignmentOffset)
396
- return {};
397
- const w = k(i), x = N(c), y = k(c) === c, v = await (a.isRTL == null ? void 0 : a.isRTL(u.floating)), A = m || (y || !g ? [st(c)] : qt(c)), O = h !== "none";
398
- !m && O && A.push(...Jt(c, g, h, v));
399
- const R = [c, ...A], B = await a.detectOverflow(e, p), T = [];
400
- let b = ((o = s.flip) == null ? void 0 : o.overflows) || [];
401
- if (d && T.push(B[w]), l) {
402
- const C = Mt(i, r, v);
403
- T.push(B[C[0]], B[C[1]]);
404
- }
405
- if (b = [...b, {
406
- placement: i,
407
- overflows: T
408
- }], !T.every((C) => C <= 0)) {
409
- var S, P;
410
- const C = (((S = s.flip) == null ? void 0 : S.index) || 0) + 1, H = R[C];
411
- if (H && (!(l === "alignment" ? x !== N(H) : !1) || // We leave the current main axis only if every placement on that axis
412
- // overflows the main axis.
413
- b.every((M) => N(M.placement) === x ? M.overflows[0] > 0 : !0)))
414
- return {
415
- data: {
416
- index: C,
417
- overflows: b
418
- },
419
- reset: {
420
- placement: H
421
- }
422
- };
423
- let W = (P = b.filter((D) => D.overflows[0] <= 0).sort((D, M) => D.overflows[1] - M.overflows[1])[0]) == null ? void 0 : P.placement;
424
- if (!W)
425
- switch (f) {
426
- case "bestFit": {
427
- var E;
428
- const D = (E = b.filter((M) => {
429
- if (O) {
430
- const q = N(M.placement);
431
- return q === x || // Create a bias to the `y` side axis due to horizontal
432
- // reading directions favoring greater width.
433
- q === "y";
434
- }
435
- return !0;
436
- }).map((M) => [M.placement, M.overflows.filter((q) => q > 0).reduce((q, It) => q + It, 0)]).sort((M, q) => M[1] - q[1])[0]) == null ? void 0 : E[0];
437
- D && (W = D);
438
- break;
439
- }
440
- case "initialPlacement":
441
- W = c;
442
- break;
443
- }
444
- if (i !== W)
445
- return {
446
- reset: {
447
- placement: W
448
- }
449
- };
450
- }
451
- return {};
452
- }
453
- };
454
- };
455
- function St(t, e) {
456
- return {
457
- top: t.top - e.height,
458
- right: t.right - e.width,
459
- bottom: t.bottom - e.height,
460
- left: t.left - e.width
461
- };
462
- }
463
- function Ct(t) {
464
- return Dt.some((e) => t[e] >= 0);
465
- }
466
- const se = function(t) {
467
- return t === void 0 && (t = {}), {
468
- name: "hide",
469
- options: t,
470
- async fn(e) {
471
- const {
472
- rects: n,
473
- platform: o
474
- } = e, {
475
- strategy: i = "referenceHidden",
476
- ...s
477
- } = _(t, e);
478
- switch (i) {
479
- case "referenceHidden": {
480
- const r = await o.detectOverflow(e, {
481
- ...s,
482
- elementContext: "reference"
483
- }), c = St(r, n.reference);
484
- return {
485
- data: {
486
- referenceHiddenOffsets: c,
487
- referenceHidden: Ct(c)
488
- }
489
- };
490
- }
491
- case "escaped": {
492
- const r = await o.detectOverflow(e, {
493
- ...s,
494
- altBoundary: !0
495
- }), c = St(r, n.floating);
496
- return {
497
- data: {
498
- escapedOffsets: c,
499
- escaped: Ct(c)
500
- }
501
- };
502
- }
503
- default:
504
- return {};
505
- }
506
- }
507
- };
508
- };
509
- function Ft(t) {
510
- const e = $(...t.map((s) => s.left)), n = $(...t.map((s) => s.top)), o = L(...t.map((s) => s.right)), i = L(...t.map((s) => s.bottom));
511
- return {
512
- x: e,
513
- y: n,
514
- width: o - e,
515
- height: i - n
516
- };
517
- }
518
- function re(t) {
519
- const e = t.slice().sort((i, s) => i.y - s.y), n = [];
520
- let o = null;
521
- for (let i = 0; i < e.length; i++) {
522
- const s = e[i];
523
- !o || s.y - o.y > o.height / 2 ? n.push([s]) : n[n.length - 1].push(s), o = s;
524
- }
525
- return n.map((i) => J(Ft(i)));
526
- }
527
- const ce = function(t) {
528
- return t === void 0 && (t = {}), {
529
- name: "inline",
530
- options: t,
531
- async fn(e) {
532
- const {
533
- placement: n,
534
- elements: o,
535
- rects: i,
536
- platform: s,
537
- strategy: r
538
- } = e, {
539
- padding: c = 2,
540
- x: a,
541
- y: u
542
- } = _(t, e), d = Array.from(await (s.getClientRects == null ? void 0 : s.getClientRects(o.reference)) || []), l = re(d), m = J(Ft(d)), f = pt(c);
543
- function h() {
544
- if (l.length === 2 && l[0].left > l[1].right && a != null && u != null)
545
- return l.find((p) => a > p.left - f.left && a < p.right + f.right && u > p.top - f.top && u < p.bottom + f.bottom) || m;
546
- if (l.length >= 2) {
547
- if (N(n) === "y") {
548
- const b = l[0], S = l[l.length - 1], P = k(n) === "top", E = b.top, C = S.bottom, H = P ? b.left : S.left, W = P ? b.right : S.right, D = W - H, M = C - E;
549
- return {
550
- top: E,
551
- bottom: C,
552
- left: H,
553
- right: W,
554
- width: D,
555
- height: M,
556
- x: H,
557
- y: E
558
- };
559
- }
560
- const p = k(n) === "left", w = L(...l.map((b) => b.right)), x = $(...l.map((b) => b.left)), y = l.filter((b) => p ? b.left === x : b.right === w), v = y[0].top, A = y[y.length - 1].bottom, O = x, R = w, B = R - O, T = A - v;
561
- return {
562
- top: v,
563
- bottom: A,
564
- left: O,
565
- right: R,
566
- width: B,
567
- height: T,
568
- x: O,
569
- y: v
570
- };
571
- }
572
- return m;
573
- }
574
- const g = await s.getElementRects({
575
- reference: {
576
- getBoundingClientRect: h
577
- },
578
- floating: o.floating,
579
- strategy: r
580
- });
581
- return i.reference.x !== g.reference.x || i.reference.y !== g.reference.y || i.reference.width !== g.reference.width || i.reference.height !== g.reference.height ? {
582
- reset: {
583
- rects: g
584
- }
585
- } : {};
586
- }
587
- };
588
- }, kt = /* @__PURE__ */ new Set(["left", "top"]);
589
- async function le(t, e) {
590
- const {
591
- placement: n,
592
- platform: o,
593
- elements: i
594
- } = t, s = await (o.isRTL == null ? void 0 : o.isRTL(i.floating)), r = k(n), c = V(n), a = N(n) === "y", u = kt.has(r) ? -1 : 1, d = s && a ? -1 : 1, l = _(e, t);
595
- let {
596
- mainAxis: m,
597
- crossAxis: f,
598
- alignmentAxis: h
599
- } = typeof l == "number" ? {
600
- mainAxis: l,
601
- crossAxis: 0,
602
- alignmentAxis: null
603
- } : {
604
- mainAxis: l.mainAxis || 0,
605
- crossAxis: l.crossAxis || 0,
606
- alignmentAxis: l.alignmentAxis
607
- };
608
- return c && typeof h == "number" && (f = c === "end" ? h * -1 : h), a ? {
609
- x: f * d,
610
- y: m * u
611
- } : {
612
- x: m * u,
613
- y: f * d
614
- };
615
- }
616
- const ae = function(t) {
617
- return t === void 0 && (t = 0), {
618
- name: "offset",
619
- options: t,
620
- async fn(e) {
621
- var n, o;
622
- const {
623
- x: i,
624
- y: s,
625
- placement: r,
626
- middlewareData: c
627
- } = e, a = await le(e, t);
628
- return r === ((n = c.offset) == null ? void 0 : n.placement) && (o = c.arrow) != null && o.alignmentOffset ? {} : {
629
- x: i + a.x,
630
- y: s + a.y,
631
- data: {
632
- ...a,
633
- placement: r
634
- }
635
- };
636
- }
637
- };
638
- }, fe = function(t) {
639
- return t === void 0 && (t = {}), {
640
- name: "shift",
641
- options: t,
642
- async fn(e) {
643
- const {
644
- x: n,
645
- y: o,
646
- placement: i,
647
- platform: s
648
- } = e, {
649
- mainAxis: r = !0,
650
- crossAxis: c = !1,
651
- limiter: a = {
652
- fn: (w) => {
653
- let {
654
- x,
655
- y
656
- } = w;
657
- return {
658
- x,
659
- y
660
- };
661
- }
662
- },
663
- ...u
664
- } = _(t, e), d = {
665
- x: n,
666
- y: o
667
- }, l = await s.detectOverflow(e, u), m = N(k(i)), f = mt(m);
668
- let h = d[f], g = d[m];
669
- if (r) {
670
- const w = f === "y" ? "top" : "left", x = f === "y" ? "bottom" : "right", y = h + l[w], v = h - l[x];
671
- h = ut(y, h, v);
672
- }
673
- if (c) {
674
- const w = m === "y" ? "top" : "left", x = m === "y" ? "bottom" : "right", y = g + l[w], v = g - l[x];
675
- g = ut(y, g, v);
676
- }
677
- const p = a.fn({
678
- ...e,
679
- [f]: h,
680
- [m]: g
681
- });
682
- return {
683
- ...p,
684
- data: {
685
- x: p.x - n,
686
- y: p.y - o,
687
- enabled: {
688
- [f]: r,
689
- [m]: c
690
- }
691
- }
692
- };
693
- }
694
- };
695
- }, ue = function(t) {
696
- return t === void 0 && (t = {}), {
697
- options: t,
698
- fn(e) {
699
- const {
700
- x: n,
701
- y: o,
702
- placement: i,
703
- rects: s,
704
- middlewareData: r
705
- } = e, {
706
- offset: c = 0,
707
- mainAxis: a = !0,
708
- crossAxis: u = !0
709
- } = _(t, e), d = {
710
- x: n,
711
- y: o
712
- }, l = N(i), m = mt(l);
713
- let f = d[m], h = d[l];
714
- const g = _(c, e), p = typeof g == "number" ? {
715
- mainAxis: g,
716
- crossAxis: 0
717
- } : {
718
- mainAxis: 0,
719
- crossAxis: 0,
720
- ...g
721
- };
722
- if (a) {
723
- const y = m === "y" ? "height" : "width", v = s.reference[m] - s.floating[y] + p.mainAxis, A = s.reference[m] + s.reference[y] - p.mainAxis;
724
- f < v ? f = v : f > A && (f = A);
725
- }
726
- if (u) {
727
- var w, x;
728
- const y = m === "y" ? "width" : "height", v = kt.has(k(i)), A = s.reference[l] - s.floating[y] + (v && ((w = r.offset) == null ? void 0 : w[l]) || 0) + (v ? 0 : p.crossAxis), O = s.reference[l] + s.reference[y] + (v ? 0 : ((x = r.offset) == null ? void 0 : x[l]) || 0) - (v ? p.crossAxis : 0);
729
- h < A ? h = A : h > O && (h = O);
730
- }
731
- return {
732
- [m]: f,
733
- [l]: h
734
- };
735
- }
736
- };
737
- }, de = function(t) {
738
- return t === void 0 && (t = {}), {
739
- name: "size",
740
- options: t,
741
- async fn(e) {
742
- var n, o;
743
- const {
744
- placement: i,
745
- rects: s,
746
- platform: r,
747
- elements: c
748
- } = e, {
749
- apply: a = () => {
750
- },
751
- ...u
752
- } = _(t, e), d = await r.detectOverflow(e, u), l = k(i), m = V(i), f = N(i) === "y", {
753
- width: h,
754
- height: g
755
- } = s.floating;
756
- let p, w;
757
- l === "top" || l === "bottom" ? (p = l, w = m === (await (r.isRTL == null ? void 0 : r.isRTL(c.floating)) ? "start" : "end") ? "left" : "right") : (w = l, p = m === "end" ? "top" : "bottom");
758
- const x = g - d.top - d.bottom, y = h - d.left - d.right, v = $(g - d[p], x), A = $(h - d[w], y), O = !e.middlewareData.shift;
759
- let R = v, B = A;
760
- if ((n = e.middlewareData.shift) != null && n.enabled.x && (B = y), (o = e.middlewareData.shift) != null && o.enabled.y && (R = x), O && !m) {
761
- const b = L(d.left, 0), S = L(d.right, 0), P = L(d.top, 0), E = L(d.bottom, 0);
762
- f ? B = h - 2 * (b !== 0 || S !== 0 ? b + S : L(d.left, d.right)) : R = g - 2 * (P !== 0 || E !== 0 ? P + E : L(d.top, d.bottom));
763
- }
764
- await a({
765
- ...e,
766
- availableWidth: B,
767
- availableHeight: R
768
- });
769
- const T = await r.getDimensions(c.floating);
770
- return h !== T.width || g !== T.height ? {
771
- reset: {
772
- rects: !0
773
- }
774
- } : {};
775
- }
776
- };
777
- };
778
- function rt() {
779
- return typeof window < "u";
780
- }
781
- function Z(t) {
782
- return Bt(t) ? (t.nodeName || "").toLowerCase() : "#document";
783
- }
784
- function F(t) {
785
- var e;
786
- return (t == null || (e = t.ownerDocument) == null ? void 0 : e.defaultView) || window;
787
- }
788
- function Y(t) {
789
- var e;
790
- return (e = (Bt(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
791
- }
792
- function Bt(t) {
793
- return rt() ? t instanceof Node || t instanceof F(t).Node : !1;
794
- }
795
- function z(t) {
796
- return rt() ? t instanceof Element || t instanceof F(t).Element : !1;
797
- }
798
- function j(t) {
799
- return rt() ? t instanceof HTMLElement || t instanceof F(t).HTMLElement : !1;
800
- }
801
- function Lt(t) {
802
- return !rt() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof F(t).ShadowRoot;
803
- }
804
- const me = /* @__PURE__ */ new Set(["inline", "contents"]);
805
- function et(t) {
806
- const {
807
- overflow: e,
808
- overflowX: n,
809
- overflowY: o,
810
- display: i
811
- } = I(t);
812
- return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !me.has(i);
813
- }
814
- const he = /* @__PURE__ */ new Set(["table", "td", "th"]);
815
- function ge(t) {
816
- return he.has(Z(t));
817
- }
818
- const pe = [":popover-open", ":modal"];
819
- function ct(t) {
820
- return pe.some((e) => {
821
- try {
822
- return t.matches(e);
823
- } catch {
824
- return !1;
825
- }
826
- });
827
- }
828
- const we = ["transform", "translate", "scale", "rotate", "perspective"], xe = ["transform", "translate", "scale", "rotate", "perspective", "filter"], ye = ["paint", "layout", "strict", "content"];
829
- function wt(t) {
830
- const e = xt(), n = z(t) ? I(t) : t;
831
- 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));
832
- }
833
- function ve(t) {
834
- let e = U(t);
835
- for (; j(e) && !Q(e); ) {
836
- if (wt(e))
837
- return e;
838
- if (ct(e))
839
- return null;
840
- e = U(e);
841
- }
842
- return null;
843
- }
844
- function xt() {
845
- return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
846
- }
847
- const be = /* @__PURE__ */ new Set(["html", "body", "#document"]);
848
- function Q(t) {
849
- return be.has(Z(t));
850
- }
851
- function I(t) {
852
- return F(t).getComputedStyle(t);
853
- }
854
- function lt(t) {
855
- return z(t) ? {
856
- scrollLeft: t.scrollLeft,
857
- scrollTop: t.scrollTop
858
- } : {
859
- scrollLeft: t.scrollX,
860
- scrollTop: t.scrollY
861
- };
862
- }
863
- function U(t) {
864
- if (Z(t) === "html")
865
- return t;
866
- const e = (
867
- // Step into the shadow DOM of the parent of a slotted node.
868
- t.assignedSlot || // DOM Element detected.
869
- t.parentNode || // ShadowRoot detected.
870
- Lt(t) && t.host || // Fallback.
871
- Y(t)
872
- );
873
- return Lt(e) ? e.host : e;
874
- }
875
- function Wt(t) {
876
- const e = U(t);
877
- return Q(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : j(e) && et(e) ? e : Wt(e);
878
- }
879
- function tt(t, e, n) {
880
- var o;
881
- e === void 0 && (e = []), n === void 0 && (n = !0);
882
- const i = Wt(t), s = i === ((o = t.ownerDocument) == null ? void 0 : o.body), r = F(i);
883
- if (s) {
884
- const c = dt(r);
885
- return e.concat(r, r.visualViewport || [], et(i) ? i : [], c && n ? tt(c) : []);
886
- }
887
- return e.concat(i, tt(i, [], n));
888
- }
889
- function dt(t) {
890
- return t.parent && Object.getPrototypeOf(t.parent) ? t.frameElement : null;
891
- }
892
- function Ht(t) {
893
- const e = I(t);
894
- let n = parseFloat(e.width) || 0, o = parseFloat(e.height) || 0;
895
- const i = j(t), s = i ? t.offsetWidth : n, r = i ? t.offsetHeight : o, c = ot(n) !== s || ot(o) !== r;
896
- return c && (n = s, o = r), {
897
- width: n,
898
- height: o,
899
- $: c
900
- };
901
- }
902
- function yt(t) {
903
- return z(t) ? t : t.contextElement;
904
- }
905
- function G(t) {
906
- const e = yt(t);
907
- if (!j(e))
908
- return X(1);
909
- const n = e.getBoundingClientRect(), {
910
- width: o,
911
- height: i,
912
- $: s
913
- } = Ht(e);
914
- let r = (s ? ot(n.width) : n.width) / o, c = (s ? ot(n.height) : n.height) / i;
915
- return (!r || !Number.isFinite(r)) && (r = 1), (!c || !Number.isFinite(c)) && (c = 1), {
916
- x: r,
917
- y: c
918
- };
919
- }
920
- const Ae = /* @__PURE__ */ X(0);
921
- function Nt(t) {
922
- const e = F(t);
923
- return !xt() || !e.visualViewport ? Ae : {
924
- x: e.visualViewport.offsetLeft,
925
- y: e.visualViewport.offsetTop
926
- };
927
- }
928
- function Oe(t, e, n) {
929
- return e === void 0 && (e = !1), !n || e && n !== F(t) ? !1 : e;
930
- }
931
- function K(t, e, n, o) {
932
- e === void 0 && (e = !1), n === void 0 && (n = !1);
933
- const i = t.getBoundingClientRect(), s = yt(t);
934
- let r = X(1);
935
- e && (o ? z(o) && (r = G(o)) : r = G(t));
936
- const c = Oe(s, n, o) ? Nt(s) : X(0);
937
- let a = (i.left + c.x) / r.x, u = (i.top + c.y) / r.y, d = i.width / r.x, l = i.height / r.y;
938
- if (s) {
939
- const m = F(s), f = o && z(o) ? F(o) : o;
940
- let h = m, g = dt(h);
941
- for (; g && o && f !== h; ) {
942
- const p = G(g), w = g.getBoundingClientRect(), x = I(g), y = w.left + (g.clientLeft + parseFloat(x.paddingLeft)) * p.x, v = w.top + (g.clientTop + parseFloat(x.paddingTop)) * p.y;
943
- a *= p.x, u *= p.y, d *= p.x, l *= p.y, a += y, u += v, h = F(g), g = dt(h);
944
- }
945
- }
946
- return J({
947
- width: d,
948
- height: l,
949
- x: a,
950
- y: u
951
- });
952
- }
953
- function at(t, e) {
954
- const n = lt(t).scrollLeft;
955
- return e ? e.left + n : K(Y(t)).left + n;
956
- }
957
- function Vt(t, e) {
958
- const n = t.getBoundingClientRect(), o = n.left + e.scrollLeft - at(t, n), i = n.top + e.scrollTop;
959
- return {
960
- x: o,
961
- y: i
962
- };
963
- }
964
- function Re(t) {
965
- let {
966
- elements: e,
967
- rect: n,
968
- offsetParent: o,
969
- strategy: i
970
- } = t;
971
- const s = i === "fixed", r = Y(o), c = e ? ct(e.floating) : !1;
972
- if (o === r || c && s)
973
- return n;
974
- let a = {
975
- scrollLeft: 0,
976
- scrollTop: 0
977
- }, u = X(1);
978
- const d = X(0), l = j(o);
979
- if ((l || !l && !s) && ((Z(o) !== "body" || et(r)) && (a = lt(o)), j(o))) {
980
- const f = K(o);
981
- u = G(o), d.x = f.x + o.clientLeft, d.y = f.y + o.clientTop;
982
- }
983
- const m = r && !l && !s ? Vt(r, a) : X(0);
984
- return {
985
- width: n.width * u.x,
986
- height: n.height * u.y,
987
- x: n.x * u.x - a.scrollLeft * u.x + d.x + m.x,
988
- y: n.y * u.y - a.scrollTop * u.y + d.y + m.y
989
- };
990
- }
991
- function Se(t) {
992
- return Array.from(t.getClientRects());
993
- }
994
- function Ce(t) {
995
- const e = Y(t), n = lt(t), o = t.ownerDocument.body, i = L(e.scrollWidth, e.clientWidth, o.scrollWidth, o.clientWidth), s = L(e.scrollHeight, e.clientHeight, o.scrollHeight, o.clientHeight);
996
- let r = -n.scrollLeft + at(t);
997
- const c = -n.scrollTop;
998
- return I(o).direction === "rtl" && (r += L(e.clientWidth, o.clientWidth) - i), {
999
- width: i,
1000
- height: s,
1001
- x: r,
1002
- y: c
1003
- };
1004
- }
1005
- const Tt = 25;
1006
- function Le(t, e) {
1007
- const n = F(t), o = Y(t), i = n.visualViewport;
1008
- let s = o.clientWidth, r = o.clientHeight, c = 0, a = 0;
1009
- if (i) {
1010
- s = i.width, r = i.height;
1011
- const d = xt();
1012
- (!d || d && e === "fixed") && (c = i.offsetLeft, a = i.offsetTop);
1013
- }
1014
- const u = at(o);
1015
- if (u <= 0) {
1016
- const d = o.ownerDocument, l = d.body, m = getComputedStyle(l), f = d.compatMode === "CSS1Compat" && parseFloat(m.marginLeft) + parseFloat(m.marginRight) || 0, h = Math.abs(o.clientWidth - l.clientWidth - f);
1017
- h <= Tt && (s -= h);
1018
- } else u <= Tt && (s += u);
1019
- return {
1020
- width: s,
1021
- height: r,
1022
- x: c,
1023
- y: a
1024
- };
1025
- }
1026
- const Te = /* @__PURE__ */ new Set(["absolute", "fixed"]);
1027
- function Pe(t, e) {
1028
- const n = K(t, !0, e === "fixed"), o = n.top + t.clientTop, i = n.left + t.clientLeft, s = j(t) ? G(t) : X(1), r = t.clientWidth * s.x, c = t.clientHeight * s.y, a = i * s.x, u = o * s.y;
1029
- return {
1030
- width: r,
1031
- height: c,
1032
- x: a,
1033
- y: u
1034
- };
1035
- }
1036
- function Pt(t, e, n) {
1037
- let o;
1038
- if (e === "viewport")
1039
- o = Le(t, n);
1040
- else if (e === "document")
1041
- o = Ce(Y(t));
1042
- else if (z(e))
1043
- o = Pe(e, n);
1044
- else {
1045
- const i = Nt(t);
1046
- o = {
1047
- x: e.x - i.x,
1048
- y: e.y - i.y,
1049
- width: e.width,
1050
- height: e.height
1051
- };
1052
- }
1053
- return J(o);
1054
- }
1055
- function $t(t, e) {
1056
- const n = U(t);
1057
- return n === e || !z(n) || Q(n) ? !1 : I(n).position === "fixed" || $t(n, e);
1058
- }
1059
- function Ee(t, e) {
1060
- const n = e.get(t);
1061
- if (n)
1062
- return n;
1063
- let o = tt(t, [], !1).filter((c) => z(c) && Z(c) !== "body"), i = null;
1064
- const s = I(t).position === "fixed";
1065
- let r = s ? U(t) : t;
1066
- for (; z(r) && !Q(r); ) {
1067
- const c = I(r), a = wt(r);
1068
- !a && c.position === "fixed" && (i = null), (s ? !a && !i : !a && c.position === "static" && !!i && Te.has(i.position) || et(r) && !a && $t(t, r)) ? o = o.filter((d) => d !== r) : i = c, r = U(r);
1069
- }
1070
- return e.set(t, o), o;
1071
- }
1072
- function De(t) {
1073
- let {
1074
- element: e,
1075
- boundary: n,
1076
- rootBoundary: o,
1077
- strategy: i
1078
- } = t;
1079
- const r = [...n === "clippingAncestors" ? ct(e) ? [] : Ee(e, this._c) : [].concat(n), o], c = r[0], a = r.reduce((u, d) => {
1080
- const l = Pt(e, d, i);
1081
- return u.top = L(l.top, u.top), u.right = $(l.right, u.right), u.bottom = $(l.bottom, u.bottom), u.left = L(l.left, u.left), u;
1082
- }, Pt(e, c, i));
1083
- return {
1084
- width: a.right - a.left,
1085
- height: a.bottom - a.top,
1086
- x: a.left,
1087
- y: a.top
1088
- };
1089
- }
1090
- function Me(t) {
1091
- const {
1092
- width: e,
1093
- height: n
1094
- } = Ht(t);
1095
- return {
1096
- width: e,
1097
- height: n
1098
- };
1099
- }
1100
- function Fe(t, e, n) {
1101
- const o = j(e), i = Y(e), s = n === "fixed", r = K(t, !0, s, e);
1102
- let c = {
1103
- scrollLeft: 0,
1104
- scrollTop: 0
1105
- };
1106
- const a = X(0);
1107
- function u() {
1108
- a.x = at(i);
1109
- }
1110
- if (o || !o && !s)
1111
- if ((Z(e) !== "body" || et(i)) && (c = lt(e)), o) {
1112
- const f = K(e, !0, s, e);
1113
- a.x = f.x + e.clientLeft, a.y = f.y + e.clientTop;
1114
- } else i && u();
1115
- s && !o && i && u();
1116
- const d = i && !o && !s ? Vt(i, c) : X(0), l = r.left + c.scrollLeft - a.x - d.x, m = r.top + c.scrollTop - a.y - d.y;
1117
- return {
1118
- x: l,
1119
- y: m,
1120
- width: r.width,
1121
- height: r.height
1122
- };
1123
- }
1124
- function ft(t) {
1125
- return I(t).position === "static";
1126
- }
1127
- function Et(t, e) {
1128
- if (!j(t) || I(t).position === "fixed")
1129
- return null;
1130
- if (e)
1131
- return e(t);
1132
- let n = t.offsetParent;
1133
- return Y(t) === n && (n = n.ownerDocument.body), n;
1134
- }
1135
- function _t(t, e) {
1136
- const n = F(t);
1137
- if (ct(t))
1138
- return n;
1139
- if (!j(t)) {
1140
- let i = U(t);
1141
- for (; i && !Q(i); ) {
1142
- if (z(i) && !ft(i))
1143
- return i;
1144
- i = U(i);
1145
- }
1146
- return n;
1147
- }
1148
- let o = Et(t, e);
1149
- for (; o && ge(o) && ft(o); )
1150
- o = Et(o, e);
1151
- return o && Q(o) && ft(o) && !wt(o) ? n : o || ve(t) || n;
1152
- }
1153
- const ke = async function(t) {
1154
- const e = this.getOffsetParent || _t, n = this.getDimensions, o = await n(t.floating);
1155
- return {
1156
- reference: Fe(t.reference, await e(t.floating), t.strategy),
1157
- floating: {
1158
- x: 0,
1159
- y: 0,
1160
- width: o.width,
1161
- height: o.height
1162
- }
1163
- };
1164
- };
1165
- function Be(t) {
1166
- return I(t).direction === "rtl";
1167
- }
1168
- const We = {
1169
- convertOffsetParentRelativeRectToViewportRelativeRect: Re,
1170
- getDocumentElement: Y,
1171
- getClippingRect: De,
1172
- getOffsetParent: _t,
1173
- getElementRects: ke,
1174
- getClientRects: Se,
1175
- getDimensions: Me,
1176
- getScale: G,
1177
- isElement: z,
1178
- isRTL: Be
1179
- };
1180
- function zt(t, e) {
1181
- return t.x === e.x && t.y === e.y && t.width === e.width && t.height === e.height;
1182
- }
1183
- function He(t, e) {
1184
- let n = null, o;
1185
- const i = Y(t);
1186
- function s() {
1187
- var c;
1188
- clearTimeout(o), (c = n) == null || c.disconnect(), n = null;
1189
- }
1190
- function r(c, a) {
1191
- c === void 0 && (c = !1), a === void 0 && (a = 1), s();
1192
- const u = t.getBoundingClientRect(), {
1193
- left: d,
1194
- top: l,
1195
- width: m,
1196
- height: f
1197
- } = u;
1198
- if (c || e(), !m || !f)
1199
- return;
1200
- const h = nt(l), g = nt(i.clientWidth - (d + m)), p = nt(i.clientHeight - (l + f)), w = nt(d), y = {
1201
- rootMargin: -h + "px " + -g + "px " + -p + "px " + -w + "px",
1202
- threshold: L(0, $(1, a)) || 1
1203
- };
1204
- let v = !0;
1205
- function A(O) {
1206
- const R = O[0].intersectionRatio;
1207
- if (R !== a) {
1208
- if (!v)
1209
- return r();
1210
- R ? r(!1, R) : o = setTimeout(() => {
1211
- r(!1, 1e-7);
1212
- }, 1e3);
1213
- }
1214
- R === 1 && !zt(u, t.getBoundingClientRect()) && r(), v = !1;
1215
- }
1216
- try {
1217
- n = new IntersectionObserver(A, {
1218
- ...y,
1219
- // Handle <iframe>s
1220
- root: i.ownerDocument
1221
- });
1222
- } catch {
1223
- n = new IntersectionObserver(A, y);
1224
- }
1225
- n.observe(t);
1226
- }
1227
- return r(!0), s;
1228
- }
1229
- function Ne(t, e, n, o) {
1230
- o === void 0 && (o = {});
1231
- const {
1232
- ancestorScroll: i = !0,
1233
- ancestorResize: s = !0,
1234
- elementResize: r = typeof ResizeObserver == "function",
1235
- layoutShift: c = typeof IntersectionObserver == "function",
1236
- animationFrame: a = !1
1237
- } = o, u = yt(t), d = i || s ? [...u ? tt(u) : [], ...tt(e)] : [];
1238
- d.forEach((w) => {
1239
- i && w.addEventListener("scroll", n, {
1240
- passive: !0
1241
- }), s && w.addEventListener("resize", n);
1242
- });
1243
- const l = u && c ? He(u, n) : null;
1244
- let m = -1, f = null;
1245
- r && (f = new ResizeObserver((w) => {
1246
- let [x] = w;
1247
- x && x.target === u && f && (f.unobserve(e), cancelAnimationFrame(m), m = requestAnimationFrame(() => {
1248
- var y;
1249
- (y = f) == null || y.observe(e);
1250
- })), n();
1251
- }), u && !a && f.observe(u), f.observe(e));
1252
- let h, g = a ? K(t) : null;
1253
- a && p();
1254
- function p() {
1255
- const w = K(t);
1256
- g && !zt(g, w) && n(), g = w, h = requestAnimationFrame(p);
1257
- }
1258
- return n(), () => {
1259
- var w;
1260
- d.forEach((x) => {
1261
- i && x.removeEventListener("scroll", n), s && x.removeEventListener("resize", n);
1262
- }), l?.(), (w = f) == null || w.disconnect(), f = null, a && cancelAnimationFrame(h);
1263
- };
1264
- }
1265
- const Ve = ae, $e = oe, _e = fe, ze = ie, Ie = de, Xe = se, je = ee, Ye = ce, qe = ue, Ue = (t, e, n) => {
1266
- const o = /* @__PURE__ */ new Map(), i = {
1267
- platform: We,
1268
- ...n
1269
- }, s = {
1270
- ...i.platform,
1271
- _c: o
1272
- };
1273
- return te(t, e, {
1274
- ...i,
1275
- platform: s
1276
- });
1277
- };
1278
- export {
1279
- je as a,
1280
- Ne as b,
1281
- Ue as c,
1282
- Ie as d,
1283
- $e as e,
1284
- ze as f,
1285
- Z as g,
1286
- Xe as h,
1287
- Bt as i,
1288
- Ye as j,
1289
- qe as l,
1290
- Ve as o,
1291
- _e as s
1292
- };