@component-labs/ui 0.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.
Files changed (114) hide show
  1. package/dist/HMKTUWOU-DlOdK4rt.js +25 -0
  2. package/dist/HMKTUWOU-DlOdK4rt.js.map +1 -0
  3. package/dist/HOITXJDS-DBccNHOl.js +48 -0
  4. package/dist/HOITXJDS-DBccNHOl.js.map +1 -0
  5. package/dist/I7KWAPMF-CcAk8kiH.js +86 -0
  6. package/dist/I7KWAPMF-CcAk8kiH.js.map +1 -0
  7. package/dist/IQYAUKXT-CoP_Jrsi.js +546 -0
  8. package/dist/IQYAUKXT-CoP_Jrsi.js.map +1 -0
  9. package/dist/PZ3OL7I2-h7WHitqi.js +61 -0
  10. package/dist/PZ3OL7I2-h7WHitqi.js.map +1 -0
  11. package/dist/Provider.d.ts +8 -0
  12. package/dist/Provider.d.ts.map +1 -0
  13. package/dist/Q5W46E73-DjlVG3LH.js +353 -0
  14. package/dist/Q5W46E73-DjlVG3LH.js.map +1 -0
  15. package/dist/U6HHPQDW-BkT6kvCd.js +888 -0
  16. package/dist/U6HHPQDW-BkT6kvCd.js.map +1 -0
  17. package/dist/X6LNAU2F-DroCIVyL.js +1692 -0
  18. package/dist/X6LNAU2F-DroCIVyL.js.map +1 -0
  19. package/dist/Z32PU2LQ-CPSDShGU.js +1116 -0
  20. package/dist/Z32PU2LQ-CPSDShGU.js.map +1 -0
  21. package/dist/button.d.ts +4 -0
  22. package/dist/button.d.ts.map +1 -0
  23. package/dist/button.js +252 -0
  24. package/dist/button.js.map +1 -0
  25. package/dist/checkbox.d.ts +4 -0
  26. package/dist/checkbox.d.ts.map +1 -0
  27. package/dist/checkbox.js +210 -0
  28. package/dist/checkbox.js.map +1 -0
  29. package/dist/combobox.d.ts +4 -0
  30. package/dist/combobox.d.ts.map +1 -0
  31. package/dist/combobox.js +948 -0
  32. package/dist/combobox.js.map +1 -0
  33. package/dist/components/button/Button.d.ts +26 -0
  34. package/dist/components/button/Button.d.ts.map +1 -0
  35. package/dist/components/button/Button.docs.d.ts +4 -0
  36. package/dist/components/button/Button.docs.d.ts.map +1 -0
  37. package/dist/components/button/Button.showcase.d.ts +40 -0
  38. package/dist/components/button/Button.showcase.d.ts.map +1 -0
  39. package/dist/components/checkbox/Checkbox.d.ts +19 -0
  40. package/dist/components/checkbox/Checkbox.d.ts.map +1 -0
  41. package/dist/components/checkbox/Checkbox.docs.d.ts +4 -0
  42. package/dist/components/checkbox/Checkbox.docs.d.ts.map +1 -0
  43. package/dist/components/checkbox/Checkbox.showcase.d.ts +35 -0
  44. package/dist/components/checkbox/Checkbox.showcase.d.ts.map +1 -0
  45. package/dist/components/combobox/Combobox.d.ts +36 -0
  46. package/dist/components/combobox/Combobox.d.ts.map +1 -0
  47. package/dist/components/combobox/Combobox.docs.d.ts +4 -0
  48. package/dist/components/combobox/Combobox.docs.d.ts.map +1 -0
  49. package/dist/components/combobox/Combobox.showcase.d.ts +43 -0
  50. package/dist/components/combobox/Combobox.showcase.d.ts.map +1 -0
  51. package/dist/components/data-table/DataTable.d.ts +86 -0
  52. package/dist/components/data-table/DataTable.d.ts.map +1 -0
  53. package/dist/components/data-table/DataTable.docs.d.ts +4 -0
  54. package/dist/components/data-table/DataTable.docs.d.ts.map +1 -0
  55. package/dist/components/data-table/DataTable.showcase.d.ts +36 -0
  56. package/dist/components/data-table/DataTable.showcase.d.ts.map +1 -0
  57. package/dist/components/date-picker/date-picker.d.ts +1 -0
  58. package/dist/components/date-picker/date-picker.d.ts.map +1 -0
  59. package/dist/components/dialog/Dialog.d.ts +56 -0
  60. package/dist/components/dialog/Dialog.d.ts.map +1 -0
  61. package/dist/components/dialog/Dialog.docs.d.ts +4 -0
  62. package/dist/components/dialog/Dialog.docs.d.ts.map +1 -0
  63. package/dist/components/input/Input.d.ts +22 -0
  64. package/dist/components/input/Input.d.ts.map +1 -0
  65. package/dist/components/input/Input.docs.d.ts +4 -0
  66. package/dist/components/input/Input.docs.d.ts.map +1 -0
  67. package/dist/components/menu/Menu.d.ts +41 -0
  68. package/dist/components/menu/Menu.d.ts.map +1 -0
  69. package/dist/components/menu/Menu.docs.d.ts +4 -0
  70. package/dist/components/menu/Menu.docs.d.ts.map +1 -0
  71. package/dist/components/menu/Menu.showcase.d.ts +43 -0
  72. package/dist/components/menu/Menu.showcase.d.ts.map +1 -0
  73. package/dist/components/slider/date-picker.d.ts +1 -0
  74. package/dist/components/slider/date-picker.d.ts.map +1 -0
  75. package/dist/components/sub-menu/date-picker.d.ts +1 -0
  76. package/dist/components/sub-menu/date-picker.d.ts.map +1 -0
  77. package/dist/components/switch/Switch.d.ts +17 -0
  78. package/dist/components/switch/Switch.d.ts.map +1 -0
  79. package/dist/components/switch/Switch.docs.d.ts +4 -0
  80. package/dist/components/switch/Switch.docs.d.ts.map +1 -0
  81. package/dist/components/toast/date-picker.d.ts +1 -0
  82. package/dist/components/toast/date-picker.d.ts.map +1 -0
  83. package/dist/data-table.d.ts +4 -0
  84. package/dist/data-table.d.ts.map +1 -0
  85. package/dist/data-table.js +298 -0
  86. package/dist/data-table.js.map +1 -0
  87. package/dist/dialog.d.ts +4 -0
  88. package/dist/dialog.d.ts.map +1 -0
  89. package/dist/dialog.js +323 -0
  90. package/dist/dialog.js.map +1 -0
  91. package/dist/index.d.ts +27 -0
  92. package/dist/index.d.ts.map +1 -0
  93. package/dist/input.d.ts +4 -0
  94. package/dist/input.d.ts.map +1 -0
  95. package/dist/input.js +230 -0
  96. package/dist/input.js.map +1 -0
  97. package/dist/lib/IntersectionObserver.d.ts +30 -0
  98. package/dist/lib/IntersectionObserver.d.ts.map +1 -0
  99. package/dist/lib/utils.d.ts +7 -0
  100. package/dist/lib/utils.d.ts.map +1 -0
  101. package/dist/menu.d.ts +4 -0
  102. package/dist/menu.d.ts.map +1 -0
  103. package/dist/menu.js +1335 -0
  104. package/dist/menu.js.map +1 -0
  105. package/dist/switch.d.ts +4 -0
  106. package/dist/switch.d.ts.map +1 -0
  107. package/dist/switch.js +194 -0
  108. package/dist/switch.js.map +1 -0
  109. package/dist/types/docs.d.ts +24 -0
  110. package/dist/types/docs.d.ts.map +1 -0
  111. package/dist/utils-BZvHF7th.js +2806 -0
  112. package/dist/utils-BZvHF7th.js.map +1 -0
  113. package/package.json +98 -0
  114. package/src/styles.css +91 -0
@@ -0,0 +1,1692 @@
1
+ import { i as Le, g as ge, j as Fe, s as ke, k as he, l as $e, m as Ne, n as Ve, C as Be, a as He } from "./IQYAUKXT-CoP_Jrsi.js";
2
+ import { c as at, l as pe, _ as We, m as Pt, C as _t, f as ft, a as ut, Q as ze, d as tt, $ as _e, a0 as kt, U as $t, H as je, k as yt, g as Xe, a1 as Ke, w as Nt, y as Ue, a2 as Ye, e as qe, x as ve, E as xe, i as jt, K as Ge, h as oe, F as xt, j as Je, L as Qe, P as Ze, q as tn, O as en, a3 as nn } from "./U6HHPQDW-BkT6kvCd.js";
3
+ import { useRef as bt, useEffect as on, useContext as rn, useCallback as we, useMemo as sn, createContext as Xt, useState as cn } from "react";
4
+ import { u as ln } from "./PZ3OL7I2-h7WHitqi.js";
5
+ import { u as an, m as fn, o as un, t as dn, c as mn, f as gn } from "./Q5W46E73-DjlVG3LH.js";
6
+ import { jsx as Vt } from "react/jsx-runtime";
7
+ import { g as hn, h as pn, j as vn, c as xn, k as wn, l as yn } from "./Z32PU2LQ-CPSDShGU.js";
8
+ var bn = "div", ye = at(
9
+ function({
10
+ store: t,
11
+ shouldRegisterItem: n = !0,
12
+ getItem: o = We,
13
+ // @ts-expect-error This prop may come from a collection renderer.
14
+ element: i,
15
+ ...r
16
+ }) {
17
+ const s = Le();
18
+ t = t || s;
19
+ const c = pe(r.id), a = bt(i);
20
+ return on(() => {
21
+ const l = a.current;
22
+ if (!c || !l || !n) return;
23
+ const d = o({ id: c, element: l });
24
+ return t == null ? void 0 : t.renderItem(d);
25
+ }, [c, n, o, t]), r = {
26
+ ...r,
27
+ ref: Pt(a, r.ref)
28
+ }, _t(r);
29
+ }
30
+ );
31
+ ft(function(t) {
32
+ const n = ye(t);
33
+ return ut(bn, n);
34
+ });
35
+ var Cn = "button";
36
+ function Sn(e) {
37
+ return kt(e) ? !0 : e.tagName === "INPUT" && !Ye(e);
38
+ }
39
+ function An(e, t = !1) {
40
+ const n = e.clientHeight, { top: o } = e.getBoundingClientRect(), i = Math.max(n * 0.875, n - 40) * 1.5, r = t ? n - i + o : i + o;
41
+ return e.tagName === "HTML" ? r + e.scrollTop : r;
42
+ }
43
+ function Pn(e, t = !1) {
44
+ const { top: n } = e.getBoundingClientRect();
45
+ return t ? n + e.clientHeight : n;
46
+ }
47
+ function ie(e, t, n, o = !1) {
48
+ var i;
49
+ if (!t || !n) return;
50
+ const { renderedItems: r } = t.getState(), s = qe(e);
51
+ if (!s) return;
52
+ const c = An(s, o);
53
+ let a, l;
54
+ for (let d = 0; d < r.length; d += 1) {
55
+ const f = a;
56
+ if (a = n(d), !a) break;
57
+ if (a === f) continue;
58
+ const h = (i = Ve(t, a)) == null ? void 0 : i.element;
59
+ if (!h) continue;
60
+ const m = Pn(h, o) - c, p = Math.abs(m);
61
+ if (o && m <= 0 || !o && m >= 0) {
62
+ l !== void 0 && l < p && (a = f);
63
+ break;
64
+ }
65
+ l = p;
66
+ }
67
+ return a;
68
+ }
69
+ function En(e, t) {
70
+ return $t(e) ? !1 : he(t, e.target);
71
+ }
72
+ var On = at(
73
+ function({
74
+ store: t,
75
+ rowId: n,
76
+ preventScrollOnKeyDown: o = !1,
77
+ moveOnKeyPress: i = !0,
78
+ tabbable: r = !1,
79
+ getItem: s,
80
+ "aria-setsize": c,
81
+ "aria-posinset": a,
82
+ ...l
83
+ }) {
84
+ const d = ge();
85
+ t = t || d;
86
+ const f = pe(l.id), h = bt(null), u = rn(Fe), p = ze(l) && !l.accessibleWhenDisabled, {
87
+ rowId: v,
88
+ baseElement: w,
89
+ isActiveItem: y,
90
+ ariaSetSize: x,
91
+ ariaPosInSet: S,
92
+ isTabbable: C
93
+ } = an(t, {
94
+ rowId(g) {
95
+ if (n) return n;
96
+ if (g && u != null && u.baseElement && u.baseElement === g.baseElement)
97
+ return u.id;
98
+ },
99
+ baseElement(g) {
100
+ return (g == null ? void 0 : g.baseElement) || void 0;
101
+ },
102
+ isActiveItem(g) {
103
+ return !!g && g.activeId === f;
104
+ },
105
+ ariaSetSize(g) {
106
+ if (c != null) return c;
107
+ if (g && u != null && u.ariaSetSize && u.baseElement === g.baseElement)
108
+ return u.ariaSetSize;
109
+ },
110
+ ariaPosInSet(g) {
111
+ if (a != null) return a;
112
+ if (!g || !(u != null && u.ariaPosInSet) || u.baseElement !== g.baseElement) return;
113
+ const b = g.renderedItems.filter(
114
+ (A) => A.rowId === v
115
+ );
116
+ return u.ariaPosInSet + b.findIndex((A) => A.id === f);
117
+ },
118
+ isTabbable(g) {
119
+ if (!(g != null && g.renderedItems.length)) return !0;
120
+ if (g.virtualFocus) return !1;
121
+ if (r) return !0;
122
+ if (g.activeId === null) return !1;
123
+ const b = t == null ? void 0 : t.item(g.activeId);
124
+ return b != null && b.disabled || !(b != null && b.element) ? !0 : g.activeId === f;
125
+ }
126
+ }), O = we(
127
+ (g) => {
128
+ var b;
129
+ const A = {
130
+ ...g,
131
+ id: f || g.id,
132
+ rowId: v,
133
+ disabled: !!p,
134
+ children: (b = g.element) == null ? void 0 : b.textContent
135
+ };
136
+ return s ? s(A) : A;
137
+ },
138
+ [f, v, p, s]
139
+ ), E = l.onFocus, P = bt(!1), D = tt((g) => {
140
+ if (E == null || E(g), g.defaultPrevented || _e(g) || !f || !t || En(g, t)) return;
141
+ const { virtualFocus: b, baseElement: A } = t.getState();
142
+ if (t.setActiveId(f), kt(g.currentTarget) && ke(g.currentTarget), !b || !$t(g) || Sn(g.currentTarget) || !(A != null && A.isConnected)) return;
143
+ je() && g.currentTarget.hasAttribute("data-autofocus") && g.currentTarget.scrollIntoView({
144
+ block: "nearest",
145
+ inline: "nearest"
146
+ }), P.current = !0, g.relatedTarget === A || he(t, g.relatedTarget) ? $e(A) : A.focus();
147
+ }), T = l.onBlurCapture, M = tt((g) => {
148
+ if (T == null || T(g), g.defaultPrevented) return;
149
+ const b = t == null ? void 0 : t.getState();
150
+ b != null && b.virtualFocus && P.current && (P.current = !1, g.preventDefault(), g.stopPropagation());
151
+ }), I = l.onKeyDown, L = yt(o), R = yt(i), $ = tt((g) => {
152
+ if (I == null || I(g), g.defaultPrevented || !$t(g) || !t) return;
153
+ const { currentTarget: b } = g, A = t.getState(), G = t.item(f), z = !!(G != null && G.rowId), k = A.orientation !== "horizontal", B = A.orientation !== "vertical", Mt = () => !!(z || B || !A.baseElement || !Ue(A.baseElement)), U = {
154
+ ArrowUp: (z || k) && t.up,
155
+ ArrowRight: (z || B) && t.next,
156
+ ArrowDown: (z || k) && t.down,
157
+ ArrowLeft: (z || B) && t.previous,
158
+ Home: () => {
159
+ if (Mt())
160
+ return !z || g.ctrlKey ? t == null ? void 0 : t.first() : t == null ? void 0 : t.previous(-1);
161
+ },
162
+ End: () => {
163
+ if (Mt())
164
+ return !z || g.ctrlKey ? t == null ? void 0 : t.last() : t == null ? void 0 : t.next(-1);
165
+ },
166
+ PageUp: () => ie(b, t, t == null ? void 0 : t.up, !0),
167
+ PageDown: () => ie(b, t, t == null ? void 0 : t.down)
168
+ }[g.key];
169
+ if (U) {
170
+ if (kt(b)) {
171
+ const Y = Xe(b), It = B && g.key === "ArrowLeft", Lt = B && g.key === "ArrowRight", nt = k && g.key === "ArrowUp", ot = k && g.key === "ArrowDown";
172
+ if (Lt || ot) {
173
+ const { length: ht } = Ke(b);
174
+ if (Y.end !== ht) return;
175
+ } else if ((It || nt) && Y.start !== 0) return;
176
+ }
177
+ const gt = U();
178
+ if (L(g) || gt !== void 0) {
179
+ if (!R(g)) return;
180
+ g.preventDefault(), t.move(gt);
181
+ }
182
+ }
183
+ }), F = sn(
184
+ () => ({ id: f, baseElement: w }),
185
+ [f, w]
186
+ );
187
+ return l = Nt(
188
+ l,
189
+ (g) => /* @__PURE__ */ Vt(Ne.Provider, { value: F, children: g }),
190
+ [F]
191
+ ), l = {
192
+ id: f,
193
+ "data-active-item": y || void 0,
194
+ ...l,
195
+ ref: Pt(h, l.ref),
196
+ tabIndex: C ? l.tabIndex : -1,
197
+ onFocus: D,
198
+ onBlurCapture: M,
199
+ onKeyDown: $
200
+ }, l = ln(l), l = ye({
201
+ store: t,
202
+ ...l,
203
+ getItem: O,
204
+ shouldRegisterItem: f ? l.shouldRegisterItem : !1
205
+ }), _t({
206
+ ...l,
207
+ "aria-setsize": x,
208
+ "aria-posinset": S
209
+ });
210
+ }
211
+ );
212
+ ve(
213
+ ft(function(t) {
214
+ const n = On(t);
215
+ return ut(Cn, n);
216
+ })
217
+ );
218
+ var Et = xe(
219
+ [pn],
220
+ [hn]
221
+ ), Go = Et.useContext, Kt = Et.useProviderContext, Rn = Et.ContextProvider, be = Et.ScopedContextProvider, Jo = Xt(
222
+ void 0
223
+ ), dt = xe(
224
+ [Rn, He],
225
+ [be, Be]
226
+ ), Qo = dt.useContext, Zo = dt.useScopedContext, ti = dt.useProviderContext, ei = dt.ContextProvider, ni = dt.ScopedContextProvider, oi = Xt(
227
+ void 0
228
+ ), ii = Xt(!1);
229
+ const J = Math.min, N = Math.max, Ct = Math.round, wt = Math.floor, j = (e) => ({
230
+ x: e,
231
+ y: e
232
+ }), Tn = {
233
+ left: "right",
234
+ right: "left",
235
+ bottom: "top",
236
+ top: "bottom"
237
+ }, Dn = {
238
+ start: "end",
239
+ end: "start"
240
+ };
241
+ function Bt(e, t, n) {
242
+ return N(e, J(t, n));
243
+ }
244
+ function Q(e, t) {
245
+ return typeof e == "function" ? e(t) : e;
246
+ }
247
+ function q(e) {
248
+ return e.split("-")[0];
249
+ }
250
+ function st(e) {
251
+ return e.split("-")[1];
252
+ }
253
+ function Ut(e) {
254
+ return e === "x" ? "y" : "x";
255
+ }
256
+ function Yt(e) {
257
+ return e === "y" ? "height" : "width";
258
+ }
259
+ const Mn = /* @__PURE__ */ new Set(["top", "bottom"]);
260
+ function _(e) {
261
+ return Mn.has(q(e)) ? "y" : "x";
262
+ }
263
+ function qt(e) {
264
+ return Ut(_(e));
265
+ }
266
+ function In(e, t, n) {
267
+ n === void 0 && (n = !1);
268
+ const o = st(e), i = qt(e), r = Yt(i);
269
+ let s = i === "x" ? o === (n ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
270
+ return t.reference[r] > t.floating[r] && (s = St(s)), [s, St(s)];
271
+ }
272
+ function Ln(e) {
273
+ const t = St(e);
274
+ return [Ht(e), t, Ht(t)];
275
+ }
276
+ function Ht(e) {
277
+ return e.replace(/start|end/g, (t) => Dn[t]);
278
+ }
279
+ const re = ["left", "right"], se = ["right", "left"], Fn = ["top", "bottom"], kn = ["bottom", "top"];
280
+ function $n(e, t, n) {
281
+ switch (e) {
282
+ case "top":
283
+ case "bottom":
284
+ return n ? t ? se : re : t ? re : se;
285
+ case "left":
286
+ case "right":
287
+ return t ? Fn : kn;
288
+ default:
289
+ return [];
290
+ }
291
+ }
292
+ function Nn(e, t, n, o) {
293
+ const i = st(e);
294
+ let r = $n(q(e), n === "start", o);
295
+ return i && (r = r.map((s) => s + "-" + i), t && (r = r.concat(r.map(Ht)))), r;
296
+ }
297
+ function St(e) {
298
+ return e.replace(/left|right|bottom|top/g, (t) => Tn[t]);
299
+ }
300
+ function Vn(e) {
301
+ return {
302
+ top: 0,
303
+ right: 0,
304
+ bottom: 0,
305
+ left: 0,
306
+ ...e
307
+ };
308
+ }
309
+ function Ce(e) {
310
+ return typeof e != "number" ? Vn(e) : {
311
+ top: e,
312
+ right: e,
313
+ bottom: e,
314
+ left: e
315
+ };
316
+ }
317
+ function At(e) {
318
+ const {
319
+ x: t,
320
+ y: n,
321
+ width: o,
322
+ height: i
323
+ } = e;
324
+ return {
325
+ width: o,
326
+ height: i,
327
+ top: n,
328
+ left: t,
329
+ right: t + o,
330
+ bottom: n + i,
331
+ x: t,
332
+ y: n
333
+ };
334
+ }
335
+ function ce(e, t, n) {
336
+ let {
337
+ reference: o,
338
+ floating: i
339
+ } = e;
340
+ const r = _(t), s = qt(t), c = Yt(s), a = q(t), l = r === "y", d = o.x + o.width / 2 - i.width / 2, f = o.y + o.height / 2 - i.height / 2, h = o[c] / 2 - i[c] / 2;
341
+ let u;
342
+ switch (a) {
343
+ case "top":
344
+ u = {
345
+ x: d,
346
+ y: o.y - i.height
347
+ };
348
+ break;
349
+ case "bottom":
350
+ u = {
351
+ x: d,
352
+ y: o.y + o.height
353
+ };
354
+ break;
355
+ case "right":
356
+ u = {
357
+ x: o.x + o.width,
358
+ y: f
359
+ };
360
+ break;
361
+ case "left":
362
+ u = {
363
+ x: o.x - i.width,
364
+ y: f
365
+ };
366
+ break;
367
+ default:
368
+ u = {
369
+ x: o.x,
370
+ y: o.y
371
+ };
372
+ }
373
+ switch (st(t)) {
374
+ case "start":
375
+ u[s] -= h * (n && l ? -1 : 1);
376
+ break;
377
+ case "end":
378
+ u[s] += h * (n && l ? -1 : 1);
379
+ break;
380
+ }
381
+ return u;
382
+ }
383
+ const Bn = async (e, t, n) => {
384
+ const {
385
+ placement: o = "bottom",
386
+ strategy: i = "absolute",
387
+ middleware: r = [],
388
+ platform: s
389
+ } = n, c = r.filter(Boolean), a = await (s.isRTL == null ? void 0 : s.isRTL(t));
390
+ let l = await s.getElementRects({
391
+ reference: e,
392
+ floating: t,
393
+ strategy: i
394
+ }), {
395
+ x: d,
396
+ y: f
397
+ } = ce(l, o, a), h = o, u = {}, m = 0;
398
+ for (let p = 0; p < c.length; p++) {
399
+ const {
400
+ name: v,
401
+ fn: w
402
+ } = c[p], {
403
+ x: y,
404
+ y: x,
405
+ data: S,
406
+ reset: C
407
+ } = await w({
408
+ x: d,
409
+ y: f,
410
+ initialPlacement: o,
411
+ placement: h,
412
+ strategy: i,
413
+ middlewareData: u,
414
+ rects: l,
415
+ platform: s,
416
+ elements: {
417
+ reference: e,
418
+ floating: t
419
+ }
420
+ });
421
+ d = y ?? d, f = x ?? f, u = {
422
+ ...u,
423
+ [v]: {
424
+ ...u[v],
425
+ ...S
426
+ }
427
+ }, C && m <= 50 && (m++, typeof C == "object" && (C.placement && (h = C.placement), C.rects && (l = C.rects === !0 ? await s.getElementRects({
428
+ reference: e,
429
+ floating: t,
430
+ strategy: i
431
+ }) : C.rects), {
432
+ x: d,
433
+ y: f
434
+ } = ce(l, h, a)), p = -1);
435
+ }
436
+ return {
437
+ x: d,
438
+ y: f,
439
+ placement: h,
440
+ strategy: i,
441
+ middlewareData: u
442
+ };
443
+ };
444
+ async function Gt(e, t) {
445
+ var n;
446
+ t === void 0 && (t = {});
447
+ const {
448
+ x: o,
449
+ y: i,
450
+ platform: r,
451
+ rects: s,
452
+ elements: c,
453
+ strategy: a
454
+ } = e, {
455
+ boundary: l = "clippingAncestors",
456
+ rootBoundary: d = "viewport",
457
+ elementContext: f = "floating",
458
+ altBoundary: h = !1,
459
+ padding: u = 0
460
+ } = Q(t, e), m = Ce(u), v = c[h ? f === "floating" ? "reference" : "floating" : f], w = At(await r.getClippingRect({
461
+ element: (n = await (r.isElement == null ? void 0 : r.isElement(v))) == null || n ? v : v.contextElement || await (r.getDocumentElement == null ? void 0 : r.getDocumentElement(c.floating)),
462
+ boundary: l,
463
+ rootBoundary: d,
464
+ strategy: a
465
+ })), y = f === "floating" ? {
466
+ x: o,
467
+ y: i,
468
+ width: s.floating.width,
469
+ height: s.floating.height
470
+ } : s.reference, x = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(c.floating)), S = await (r.isElement == null ? void 0 : r.isElement(x)) ? await (r.getScale == null ? void 0 : r.getScale(x)) || {
471
+ x: 1,
472
+ y: 1
473
+ } : {
474
+ x: 1,
475
+ y: 1
476
+ }, C = At(r.convertOffsetParentRelativeRectToViewportRelativeRect ? await r.convertOffsetParentRelativeRectToViewportRelativeRect({
477
+ elements: c,
478
+ rect: y,
479
+ offsetParent: x,
480
+ strategy: a
481
+ }) : y);
482
+ return {
483
+ top: (w.top - C.top + m.top) / S.y,
484
+ bottom: (C.bottom - w.bottom + m.bottom) / S.y,
485
+ left: (w.left - C.left + m.left) / S.x,
486
+ right: (C.right - w.right + m.right) / S.x
487
+ };
488
+ }
489
+ const Hn = (e) => ({
490
+ name: "arrow",
491
+ options: e,
492
+ async fn(t) {
493
+ const {
494
+ x: n,
495
+ y: o,
496
+ placement: i,
497
+ rects: r,
498
+ platform: s,
499
+ elements: c,
500
+ middlewareData: a
501
+ } = t, {
502
+ element: l,
503
+ padding: d = 0
504
+ } = Q(e, t) || {};
505
+ if (l == null)
506
+ return {};
507
+ const f = Ce(d), h = {
508
+ x: n,
509
+ y: o
510
+ }, u = qt(i), m = Yt(u), p = await s.getDimensions(l), v = u === "y", w = v ? "top" : "left", y = v ? "bottom" : "right", x = v ? "clientHeight" : "clientWidth", S = r.reference[m] + r.reference[u] - h[u] - r.floating[m], C = h[u] - r.reference[u], O = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(l));
511
+ let E = O ? O[x] : 0;
512
+ (!E || !await (s.isElement == null ? void 0 : s.isElement(O))) && (E = c.floating[x] || r.floating[m]);
513
+ const P = S / 2 - C / 2, D = E / 2 - p[m] / 2 - 1, T = J(f[w], D), M = J(f[y], D), I = T, L = E - p[m] - M, R = E / 2 - p[m] / 2 + P, $ = Bt(I, R, L), F = !a.arrow && st(i) != null && R !== $ && r.reference[m] / 2 - (R < I ? T : M) - p[m] / 2 < 0, g = F ? R < I ? R - I : R - L : 0;
514
+ return {
515
+ [u]: h[u] + g,
516
+ data: {
517
+ [u]: $,
518
+ centerOffset: R - $ - g,
519
+ ...F && {
520
+ alignmentOffset: g
521
+ }
522
+ },
523
+ reset: F
524
+ };
525
+ }
526
+ }), Wn = function(e) {
527
+ return e === void 0 && (e = {}), {
528
+ name: "flip",
529
+ options: e,
530
+ async fn(t) {
531
+ var n, o;
532
+ const {
533
+ placement: i,
534
+ middlewareData: r,
535
+ rects: s,
536
+ initialPlacement: c,
537
+ platform: a,
538
+ elements: l
539
+ } = t, {
540
+ mainAxis: d = !0,
541
+ crossAxis: f = !0,
542
+ fallbackPlacements: h,
543
+ fallbackStrategy: u = "bestFit",
544
+ fallbackAxisSideDirection: m = "none",
545
+ flipAlignment: p = !0,
546
+ ...v
547
+ } = Q(e, t);
548
+ if ((n = r.arrow) != null && n.alignmentOffset)
549
+ return {};
550
+ const w = q(i), y = _(c), x = q(c) === c, S = await (a.isRTL == null ? void 0 : a.isRTL(l.floating)), C = h || (x || !p ? [St(c)] : Ln(c)), O = m !== "none";
551
+ !h && O && C.push(...Nn(c, p, m, S));
552
+ const E = [c, ...C], P = await Gt(t, v), D = [];
553
+ let T = ((o = r.flip) == null ? void 0 : o.overflows) || [];
554
+ if (d && D.push(P[w]), f) {
555
+ const R = In(i, s, S);
556
+ D.push(P[R[0]], P[R[1]]);
557
+ }
558
+ if (T = [...T, {
559
+ placement: i,
560
+ overflows: D
561
+ }], !D.every((R) => R <= 0)) {
562
+ var M, I;
563
+ const R = (((M = r.flip) == null ? void 0 : M.index) || 0) + 1, $ = E[R];
564
+ if ($ && (!(f === "alignment" ? y !== _($) : !1) || // We leave the current main axis only if every placement on that axis
565
+ // overflows the main axis.
566
+ T.every((b) => _(b.placement) === y ? b.overflows[0] > 0 : !0)))
567
+ return {
568
+ data: {
569
+ index: R,
570
+ overflows: T
571
+ },
572
+ reset: {
573
+ placement: $
574
+ }
575
+ };
576
+ let F = (I = T.filter((g) => g.overflows[0] <= 0).sort((g, b) => g.overflows[1] - b.overflows[1])[0]) == null ? void 0 : I.placement;
577
+ if (!F)
578
+ switch (u) {
579
+ case "bestFit": {
580
+ var L;
581
+ const g = (L = T.filter((b) => {
582
+ if (O) {
583
+ const A = _(b.placement);
584
+ return A === y || // Create a bias to the `y` side axis due to horizontal
585
+ // reading directions favoring greater width.
586
+ A === "y";
587
+ }
588
+ return !0;
589
+ }).map((b) => [b.placement, b.overflows.filter((A) => A > 0).reduce((A, G) => A + G, 0)]).sort((b, A) => b[1] - A[1])[0]) == null ? void 0 : L[0];
590
+ g && (F = g);
591
+ break;
592
+ }
593
+ case "initialPlacement":
594
+ F = c;
595
+ break;
596
+ }
597
+ if (i !== F)
598
+ return {
599
+ reset: {
600
+ placement: F
601
+ }
602
+ };
603
+ }
604
+ return {};
605
+ }
606
+ };
607
+ }, Se = /* @__PURE__ */ new Set(["left", "top"]);
608
+ async function zn(e, t) {
609
+ const {
610
+ placement: n,
611
+ platform: o,
612
+ elements: i
613
+ } = e, r = await (o.isRTL == null ? void 0 : o.isRTL(i.floating)), s = q(n), c = st(n), a = _(n) === "y", l = Se.has(s) ? -1 : 1, d = r && a ? -1 : 1, f = Q(t, e);
614
+ let {
615
+ mainAxis: h,
616
+ crossAxis: u,
617
+ alignmentAxis: m
618
+ } = typeof f == "number" ? {
619
+ mainAxis: f,
620
+ crossAxis: 0,
621
+ alignmentAxis: null
622
+ } : {
623
+ mainAxis: f.mainAxis || 0,
624
+ crossAxis: f.crossAxis || 0,
625
+ alignmentAxis: f.alignmentAxis
626
+ };
627
+ return c && typeof m == "number" && (u = c === "end" ? m * -1 : m), a ? {
628
+ x: u * d,
629
+ y: h * l
630
+ } : {
631
+ x: h * l,
632
+ y: u * d
633
+ };
634
+ }
635
+ const _n = function(e) {
636
+ return e === void 0 && (e = 0), {
637
+ name: "offset",
638
+ options: e,
639
+ async fn(t) {
640
+ var n, o;
641
+ const {
642
+ x: i,
643
+ y: r,
644
+ placement: s,
645
+ middlewareData: c
646
+ } = t, a = await zn(t, e);
647
+ return s === ((n = c.offset) == null ? void 0 : n.placement) && (o = c.arrow) != null && o.alignmentOffset ? {} : {
648
+ x: i + a.x,
649
+ y: r + a.y,
650
+ data: {
651
+ ...a,
652
+ placement: s
653
+ }
654
+ };
655
+ }
656
+ };
657
+ }, jn = function(e) {
658
+ return e === void 0 && (e = {}), {
659
+ name: "shift",
660
+ options: e,
661
+ async fn(t) {
662
+ const {
663
+ x: n,
664
+ y: o,
665
+ placement: i
666
+ } = t, {
667
+ mainAxis: r = !0,
668
+ crossAxis: s = !1,
669
+ limiter: c = {
670
+ fn: (v) => {
671
+ let {
672
+ x: w,
673
+ y
674
+ } = v;
675
+ return {
676
+ x: w,
677
+ y
678
+ };
679
+ }
680
+ },
681
+ ...a
682
+ } = Q(e, t), l = {
683
+ x: n,
684
+ y: o
685
+ }, d = await Gt(t, a), f = _(q(i)), h = Ut(f);
686
+ let u = l[h], m = l[f];
687
+ if (r) {
688
+ const v = h === "y" ? "top" : "left", w = h === "y" ? "bottom" : "right", y = u + d[v], x = u - d[w];
689
+ u = Bt(y, u, x);
690
+ }
691
+ if (s) {
692
+ const v = f === "y" ? "top" : "left", w = f === "y" ? "bottom" : "right", y = m + d[v], x = m - d[w];
693
+ m = Bt(y, m, x);
694
+ }
695
+ const p = c.fn({
696
+ ...t,
697
+ [h]: u,
698
+ [f]: m
699
+ });
700
+ return {
701
+ ...p,
702
+ data: {
703
+ x: p.x - n,
704
+ y: p.y - o,
705
+ enabled: {
706
+ [h]: r,
707
+ [f]: s
708
+ }
709
+ }
710
+ };
711
+ }
712
+ };
713
+ }, Xn = function(e) {
714
+ return e === void 0 && (e = {}), {
715
+ options: e,
716
+ fn(t) {
717
+ const {
718
+ x: n,
719
+ y: o,
720
+ placement: i,
721
+ rects: r,
722
+ middlewareData: s
723
+ } = t, {
724
+ offset: c = 0,
725
+ mainAxis: a = !0,
726
+ crossAxis: l = !0
727
+ } = Q(e, t), d = {
728
+ x: n,
729
+ y: o
730
+ }, f = _(i), h = Ut(f);
731
+ let u = d[h], m = d[f];
732
+ const p = Q(c, t), v = typeof p == "number" ? {
733
+ mainAxis: p,
734
+ crossAxis: 0
735
+ } : {
736
+ mainAxis: 0,
737
+ crossAxis: 0,
738
+ ...p
739
+ };
740
+ if (a) {
741
+ const x = h === "y" ? "height" : "width", S = r.reference[h] - r.floating[x] + v.mainAxis, C = r.reference[h] + r.reference[x] - v.mainAxis;
742
+ u < S ? u = S : u > C && (u = C);
743
+ }
744
+ if (l) {
745
+ var w, y;
746
+ const x = h === "y" ? "width" : "height", S = Se.has(q(i)), C = r.reference[f] - r.floating[x] + (S && ((w = s.offset) == null ? void 0 : w[f]) || 0) + (S ? 0 : v.crossAxis), O = r.reference[f] + r.reference[x] + (S ? 0 : ((y = s.offset) == null ? void 0 : y[f]) || 0) - (S ? v.crossAxis : 0);
747
+ m < C ? m = C : m > O && (m = O);
748
+ }
749
+ return {
750
+ [h]: u,
751
+ [f]: m
752
+ };
753
+ }
754
+ };
755
+ }, Kn = function(e) {
756
+ return e === void 0 && (e = {}), {
757
+ name: "size",
758
+ options: e,
759
+ async fn(t) {
760
+ var n, o;
761
+ const {
762
+ placement: i,
763
+ rects: r,
764
+ platform: s,
765
+ elements: c
766
+ } = t, {
767
+ apply: a = () => {
768
+ },
769
+ ...l
770
+ } = Q(e, t), d = await Gt(t, l), f = q(i), h = st(i), u = _(i) === "y", {
771
+ width: m,
772
+ height: p
773
+ } = r.floating;
774
+ let v, w;
775
+ f === "top" || f === "bottom" ? (v = f, w = h === (await (s.isRTL == null ? void 0 : s.isRTL(c.floating)) ? "start" : "end") ? "left" : "right") : (w = f, v = h === "end" ? "top" : "bottom");
776
+ const y = p - d.top - d.bottom, x = m - d.left - d.right, S = J(p - d[v], y), C = J(m - d[w], x), O = !t.middlewareData.shift;
777
+ let E = S, P = C;
778
+ if ((n = t.middlewareData.shift) != null && n.enabled.x && (P = x), (o = t.middlewareData.shift) != null && o.enabled.y && (E = y), O && !h) {
779
+ const T = N(d.left, 0), M = N(d.right, 0), I = N(d.top, 0), L = N(d.bottom, 0);
780
+ u ? P = m - 2 * (T !== 0 || M !== 0 ? T + M : N(d.left, d.right)) : E = p - 2 * (I !== 0 || L !== 0 ? I + L : N(d.top, d.bottom));
781
+ }
782
+ await a({
783
+ ...t,
784
+ availableWidth: P,
785
+ availableHeight: E
786
+ });
787
+ const D = await s.getDimensions(c.floating);
788
+ return m !== D.width || p !== D.height ? {
789
+ reset: {
790
+ rects: !0
791
+ }
792
+ } : {};
793
+ }
794
+ };
795
+ };
796
+ function Ot() {
797
+ return typeof window < "u";
798
+ }
799
+ function ct(e) {
800
+ return Ae(e) ? (e.nodeName || "").toLowerCase() : "#document";
801
+ }
802
+ function V(e) {
803
+ var t;
804
+ return (e == null || (t = e.ownerDocument) == null ? void 0 : t.defaultView) || window;
805
+ }
806
+ function K(e) {
807
+ var t;
808
+ return (t = (Ae(e) ? e.ownerDocument : e.document) || window.document) == null ? void 0 : t.documentElement;
809
+ }
810
+ function Ae(e) {
811
+ return Ot() ? e instanceof Node || e instanceof V(e).Node : !1;
812
+ }
813
+ function H(e) {
814
+ return Ot() ? e instanceof Element || e instanceof V(e).Element : !1;
815
+ }
816
+ function X(e) {
817
+ return Ot() ? e instanceof HTMLElement || e instanceof V(e).HTMLElement : !1;
818
+ }
819
+ function le(e) {
820
+ return !Ot() || typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof V(e).ShadowRoot;
821
+ }
822
+ const Un = /* @__PURE__ */ new Set(["inline", "contents"]);
823
+ function mt(e) {
824
+ const {
825
+ overflow: t,
826
+ overflowX: n,
827
+ overflowY: o,
828
+ display: i
829
+ } = W(e);
830
+ return /auto|scroll|overlay|hidden|clip/.test(t + o + n) && !Un.has(i);
831
+ }
832
+ const Yn = /* @__PURE__ */ new Set(["table", "td", "th"]);
833
+ function qn(e) {
834
+ return Yn.has(ct(e));
835
+ }
836
+ const Gn = [":popover-open", ":modal"];
837
+ function Rt(e) {
838
+ return Gn.some((t) => {
839
+ try {
840
+ return e.matches(t);
841
+ } catch {
842
+ return !1;
843
+ }
844
+ });
845
+ }
846
+ const Jn = ["transform", "translate", "scale", "rotate", "perspective"], Qn = ["transform", "translate", "scale", "rotate", "perspective", "filter"], Zn = ["paint", "layout", "strict", "content"];
847
+ function Jt(e) {
848
+ const t = Qt(), n = H(e) ? W(e) : e;
849
+ return Jn.some((o) => n[o] ? n[o] !== "none" : !1) || (n.containerType ? n.containerType !== "normal" : !1) || !t && (n.backdropFilter ? n.backdropFilter !== "none" : !1) || !t && (n.filter ? n.filter !== "none" : !1) || Qn.some((o) => (n.willChange || "").includes(o)) || Zn.some((o) => (n.contain || "").includes(o));
850
+ }
851
+ function to(e) {
852
+ let t = Z(e);
853
+ for (; X(t) && !rt(t); ) {
854
+ if (Jt(t))
855
+ return t;
856
+ if (Rt(t))
857
+ return null;
858
+ t = Z(t);
859
+ }
860
+ return null;
861
+ }
862
+ function Qt() {
863
+ return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
864
+ }
865
+ const eo = /* @__PURE__ */ new Set(["html", "body", "#document"]);
866
+ function rt(e) {
867
+ return eo.has(ct(e));
868
+ }
869
+ function W(e) {
870
+ return V(e).getComputedStyle(e);
871
+ }
872
+ function Tt(e) {
873
+ return H(e) ? {
874
+ scrollLeft: e.scrollLeft,
875
+ scrollTop: e.scrollTop
876
+ } : {
877
+ scrollLeft: e.scrollX,
878
+ scrollTop: e.scrollY
879
+ };
880
+ }
881
+ function Z(e) {
882
+ if (ct(e) === "html")
883
+ return e;
884
+ const t = (
885
+ // Step into the shadow DOM of the parent of a slotted node.
886
+ e.assignedSlot || // DOM Element detected.
887
+ e.parentNode || // ShadowRoot detected.
888
+ le(e) && e.host || // Fallback.
889
+ K(e)
890
+ );
891
+ return le(t) ? t.host : t;
892
+ }
893
+ function Pe(e) {
894
+ const t = Z(e);
895
+ return rt(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : X(t) && mt(t) ? t : Pe(t);
896
+ }
897
+ function lt(e, t, n) {
898
+ var o;
899
+ t === void 0 && (t = []), n === void 0 && (n = !0);
900
+ const i = Pe(e), r = i === ((o = e.ownerDocument) == null ? void 0 : o.body), s = V(i);
901
+ if (r) {
902
+ const c = Wt(s);
903
+ return t.concat(s, s.visualViewport || [], mt(i) ? i : [], c && n ? lt(c) : []);
904
+ }
905
+ return t.concat(i, lt(i, [], n));
906
+ }
907
+ function Wt(e) {
908
+ return e.parent && Object.getPrototypeOf(e.parent) ? e.frameElement : null;
909
+ }
910
+ function Ee(e) {
911
+ const t = W(e);
912
+ let n = parseFloat(t.width) || 0, o = parseFloat(t.height) || 0;
913
+ const i = X(e), r = i ? e.offsetWidth : n, s = i ? e.offsetHeight : o, c = Ct(n) !== r || Ct(o) !== s;
914
+ return c && (n = r, o = s), {
915
+ width: n,
916
+ height: o,
917
+ $: c
918
+ };
919
+ }
920
+ function Zt(e) {
921
+ return H(e) ? e : e.contextElement;
922
+ }
923
+ function it(e) {
924
+ const t = Zt(e);
925
+ if (!X(t))
926
+ return j(1);
927
+ const n = t.getBoundingClientRect(), {
928
+ width: o,
929
+ height: i,
930
+ $: r
931
+ } = Ee(t);
932
+ let s = (r ? Ct(n.width) : n.width) / o, c = (r ? Ct(n.height) : n.height) / i;
933
+ return (!s || !Number.isFinite(s)) && (s = 1), (!c || !Number.isFinite(c)) && (c = 1), {
934
+ x: s,
935
+ y: c
936
+ };
937
+ }
938
+ const no = /* @__PURE__ */ j(0);
939
+ function Oe(e) {
940
+ const t = V(e);
941
+ return !Qt() || !t.visualViewport ? no : {
942
+ x: t.visualViewport.offsetLeft,
943
+ y: t.visualViewport.offsetTop
944
+ };
945
+ }
946
+ function oo(e, t, n) {
947
+ return t === void 0 && (t = !1), !n || t && n !== V(e) ? !1 : t;
948
+ }
949
+ function et(e, t, n, o) {
950
+ t === void 0 && (t = !1), n === void 0 && (n = !1);
951
+ const i = e.getBoundingClientRect(), r = Zt(e);
952
+ let s = j(1);
953
+ t && (o ? H(o) && (s = it(o)) : s = it(e));
954
+ const c = oo(r, n, o) ? Oe(r) : j(0);
955
+ let a = (i.left + c.x) / s.x, l = (i.top + c.y) / s.y, d = i.width / s.x, f = i.height / s.y;
956
+ if (r) {
957
+ const h = V(r), u = o && H(o) ? V(o) : o;
958
+ let m = h, p = Wt(m);
959
+ for (; p && o && u !== m; ) {
960
+ const v = it(p), w = p.getBoundingClientRect(), y = W(p), x = w.left + (p.clientLeft + parseFloat(y.paddingLeft)) * v.x, S = w.top + (p.clientTop + parseFloat(y.paddingTop)) * v.y;
961
+ a *= v.x, l *= v.y, d *= v.x, f *= v.y, a += x, l += S, m = V(p), p = Wt(m);
962
+ }
963
+ }
964
+ return At({
965
+ width: d,
966
+ height: f,
967
+ x: a,
968
+ y: l
969
+ });
970
+ }
971
+ function Dt(e, t) {
972
+ const n = Tt(e).scrollLeft;
973
+ return t ? t.left + n : et(K(e)).left + n;
974
+ }
975
+ function Re(e, t) {
976
+ const n = e.getBoundingClientRect(), o = n.left + t.scrollLeft - Dt(e, n), i = n.top + t.scrollTop;
977
+ return {
978
+ x: o,
979
+ y: i
980
+ };
981
+ }
982
+ function io(e) {
983
+ let {
984
+ elements: t,
985
+ rect: n,
986
+ offsetParent: o,
987
+ strategy: i
988
+ } = e;
989
+ const r = i === "fixed", s = K(o), c = t ? Rt(t.floating) : !1;
990
+ if (o === s || c && r)
991
+ return n;
992
+ let a = {
993
+ scrollLeft: 0,
994
+ scrollTop: 0
995
+ }, l = j(1);
996
+ const d = j(0), f = X(o);
997
+ if ((f || !f && !r) && ((ct(o) !== "body" || mt(s)) && (a = Tt(o)), X(o))) {
998
+ const u = et(o);
999
+ l = it(o), d.x = u.x + o.clientLeft, d.y = u.y + o.clientTop;
1000
+ }
1001
+ const h = s && !f && !r ? Re(s, a) : j(0);
1002
+ return {
1003
+ width: n.width * l.x,
1004
+ height: n.height * l.y,
1005
+ x: n.x * l.x - a.scrollLeft * l.x + d.x + h.x,
1006
+ y: n.y * l.y - a.scrollTop * l.y + d.y + h.y
1007
+ };
1008
+ }
1009
+ function ro(e) {
1010
+ return Array.from(e.getClientRects());
1011
+ }
1012
+ function so(e) {
1013
+ const t = K(e), n = Tt(e), o = e.ownerDocument.body, i = N(t.scrollWidth, t.clientWidth, o.scrollWidth, o.clientWidth), r = N(t.scrollHeight, t.clientHeight, o.scrollHeight, o.clientHeight);
1014
+ let s = -n.scrollLeft + Dt(e);
1015
+ const c = -n.scrollTop;
1016
+ return W(o).direction === "rtl" && (s += N(t.clientWidth, o.clientWidth) - i), {
1017
+ width: i,
1018
+ height: r,
1019
+ x: s,
1020
+ y: c
1021
+ };
1022
+ }
1023
+ const ae = 25;
1024
+ function co(e, t) {
1025
+ const n = V(e), o = K(e), i = n.visualViewport;
1026
+ let r = o.clientWidth, s = o.clientHeight, c = 0, a = 0;
1027
+ if (i) {
1028
+ r = i.width, s = i.height;
1029
+ const d = Qt();
1030
+ (!d || d && t === "fixed") && (c = i.offsetLeft, a = i.offsetTop);
1031
+ }
1032
+ const l = Dt(o);
1033
+ if (l <= 0) {
1034
+ const d = o.ownerDocument, f = d.body, h = getComputedStyle(f), u = d.compatMode === "CSS1Compat" && parseFloat(h.marginLeft) + parseFloat(h.marginRight) || 0, m = Math.abs(o.clientWidth - f.clientWidth - u);
1035
+ m <= ae && (r -= m);
1036
+ } else l <= ae && (r += l);
1037
+ return {
1038
+ width: r,
1039
+ height: s,
1040
+ x: c,
1041
+ y: a
1042
+ };
1043
+ }
1044
+ const lo = /* @__PURE__ */ new Set(["absolute", "fixed"]);
1045
+ function ao(e, t) {
1046
+ const n = et(e, !0, t === "fixed"), o = n.top + e.clientTop, i = n.left + e.clientLeft, r = X(e) ? it(e) : j(1), s = e.clientWidth * r.x, c = e.clientHeight * r.y, a = i * r.x, l = o * r.y;
1047
+ return {
1048
+ width: s,
1049
+ height: c,
1050
+ x: a,
1051
+ y: l
1052
+ };
1053
+ }
1054
+ function fe(e, t, n) {
1055
+ let o;
1056
+ if (t === "viewport")
1057
+ o = co(e, n);
1058
+ else if (t === "document")
1059
+ o = so(K(e));
1060
+ else if (H(t))
1061
+ o = ao(t, n);
1062
+ else {
1063
+ const i = Oe(e);
1064
+ o = {
1065
+ x: t.x - i.x,
1066
+ y: t.y - i.y,
1067
+ width: t.width,
1068
+ height: t.height
1069
+ };
1070
+ }
1071
+ return At(o);
1072
+ }
1073
+ function Te(e, t) {
1074
+ const n = Z(e);
1075
+ return n === t || !H(n) || rt(n) ? !1 : W(n).position === "fixed" || Te(n, t);
1076
+ }
1077
+ function fo(e, t) {
1078
+ const n = t.get(e);
1079
+ if (n)
1080
+ return n;
1081
+ let o = lt(e, [], !1).filter((c) => H(c) && ct(c) !== "body"), i = null;
1082
+ const r = W(e).position === "fixed";
1083
+ let s = r ? Z(e) : e;
1084
+ for (; H(s) && !rt(s); ) {
1085
+ const c = W(s), a = Jt(s);
1086
+ !a && c.position === "fixed" && (i = null), (r ? !a && !i : !a && c.position === "static" && !!i && lo.has(i.position) || mt(s) && !a && Te(e, s)) ? o = o.filter((d) => d !== s) : i = c, s = Z(s);
1087
+ }
1088
+ return t.set(e, o), o;
1089
+ }
1090
+ function uo(e) {
1091
+ let {
1092
+ element: t,
1093
+ boundary: n,
1094
+ rootBoundary: o,
1095
+ strategy: i
1096
+ } = e;
1097
+ const s = [...n === "clippingAncestors" ? Rt(t) ? [] : fo(t, this._c) : [].concat(n), o], c = s[0], a = s.reduce((l, d) => {
1098
+ const f = fe(t, d, i);
1099
+ return l.top = N(f.top, l.top), l.right = J(f.right, l.right), l.bottom = J(f.bottom, l.bottom), l.left = N(f.left, l.left), l;
1100
+ }, fe(t, c, i));
1101
+ return {
1102
+ width: a.right - a.left,
1103
+ height: a.bottom - a.top,
1104
+ x: a.left,
1105
+ y: a.top
1106
+ };
1107
+ }
1108
+ function mo(e) {
1109
+ const {
1110
+ width: t,
1111
+ height: n
1112
+ } = Ee(e);
1113
+ return {
1114
+ width: t,
1115
+ height: n
1116
+ };
1117
+ }
1118
+ function go(e, t, n) {
1119
+ const o = X(t), i = K(t), r = n === "fixed", s = et(e, !0, r, t);
1120
+ let c = {
1121
+ scrollLeft: 0,
1122
+ scrollTop: 0
1123
+ };
1124
+ const a = j(0);
1125
+ function l() {
1126
+ a.x = Dt(i);
1127
+ }
1128
+ if (o || !o && !r)
1129
+ if ((ct(t) !== "body" || mt(i)) && (c = Tt(t)), o) {
1130
+ const u = et(t, !0, r, t);
1131
+ a.x = u.x + t.clientLeft, a.y = u.y + t.clientTop;
1132
+ } else i && l();
1133
+ r && !o && i && l();
1134
+ const d = i && !o && !r ? Re(i, c) : j(0), f = s.left + c.scrollLeft - a.x - d.x, h = s.top + c.scrollTop - a.y - d.y;
1135
+ return {
1136
+ x: f,
1137
+ y: h,
1138
+ width: s.width,
1139
+ height: s.height
1140
+ };
1141
+ }
1142
+ function Ft(e) {
1143
+ return W(e).position === "static";
1144
+ }
1145
+ function ue(e, t) {
1146
+ if (!X(e) || W(e).position === "fixed")
1147
+ return null;
1148
+ if (t)
1149
+ return t(e);
1150
+ let n = e.offsetParent;
1151
+ return K(e) === n && (n = n.ownerDocument.body), n;
1152
+ }
1153
+ function De(e, t) {
1154
+ const n = V(e);
1155
+ if (Rt(e))
1156
+ return n;
1157
+ if (!X(e)) {
1158
+ let i = Z(e);
1159
+ for (; i && !rt(i); ) {
1160
+ if (H(i) && !Ft(i))
1161
+ return i;
1162
+ i = Z(i);
1163
+ }
1164
+ return n;
1165
+ }
1166
+ let o = ue(e, t);
1167
+ for (; o && qn(o) && Ft(o); )
1168
+ o = ue(o, t);
1169
+ return o && rt(o) && Ft(o) && !Jt(o) ? n : o || to(e) || n;
1170
+ }
1171
+ const ho = async function(e) {
1172
+ const t = this.getOffsetParent || De, n = this.getDimensions, o = await n(e.floating);
1173
+ return {
1174
+ reference: go(e.reference, await t(e.floating), e.strategy),
1175
+ floating: {
1176
+ x: 0,
1177
+ y: 0,
1178
+ width: o.width,
1179
+ height: o.height
1180
+ }
1181
+ };
1182
+ };
1183
+ function po(e) {
1184
+ return W(e).direction === "rtl";
1185
+ }
1186
+ const vo = {
1187
+ convertOffsetParentRelativeRectToViewportRelativeRect: io,
1188
+ getDocumentElement: K,
1189
+ getClippingRect: uo,
1190
+ getOffsetParent: De,
1191
+ getElementRects: ho,
1192
+ getClientRects: ro,
1193
+ getDimensions: mo,
1194
+ getScale: it,
1195
+ isElement: H,
1196
+ isRTL: po
1197
+ };
1198
+ function Me(e, t) {
1199
+ return e.x === t.x && e.y === t.y && e.width === t.width && e.height === t.height;
1200
+ }
1201
+ function xo(e, t) {
1202
+ let n = null, o;
1203
+ const i = K(e);
1204
+ function r() {
1205
+ var c;
1206
+ clearTimeout(o), (c = n) == null || c.disconnect(), n = null;
1207
+ }
1208
+ function s(c, a) {
1209
+ c === void 0 && (c = !1), a === void 0 && (a = 1), r();
1210
+ const l = e.getBoundingClientRect(), {
1211
+ left: d,
1212
+ top: f,
1213
+ width: h,
1214
+ height: u
1215
+ } = l;
1216
+ if (c || t(), !h || !u)
1217
+ return;
1218
+ const m = wt(f), p = wt(i.clientWidth - (d + h)), v = wt(i.clientHeight - (f + u)), w = wt(d), x = {
1219
+ rootMargin: -m + "px " + -p + "px " + -v + "px " + -w + "px",
1220
+ threshold: N(0, J(1, a)) || 1
1221
+ };
1222
+ let S = !0;
1223
+ function C(O) {
1224
+ const E = O[0].intersectionRatio;
1225
+ if (E !== a) {
1226
+ if (!S)
1227
+ return s();
1228
+ E ? s(!1, E) : o = setTimeout(() => {
1229
+ s(!1, 1e-7);
1230
+ }, 1e3);
1231
+ }
1232
+ E === 1 && !Me(l, e.getBoundingClientRect()) && s(), S = !1;
1233
+ }
1234
+ try {
1235
+ n = new IntersectionObserver(C, {
1236
+ ...x,
1237
+ // Handle <iframe>s
1238
+ root: i.ownerDocument
1239
+ });
1240
+ } catch {
1241
+ n = new IntersectionObserver(C, x);
1242
+ }
1243
+ n.observe(e);
1244
+ }
1245
+ return s(!0), r;
1246
+ }
1247
+ function wo(e, t, n, o) {
1248
+ o === void 0 && (o = {});
1249
+ const {
1250
+ ancestorScroll: i = !0,
1251
+ ancestorResize: r = !0,
1252
+ elementResize: s = typeof ResizeObserver == "function",
1253
+ layoutShift: c = typeof IntersectionObserver == "function",
1254
+ animationFrame: a = !1
1255
+ } = o, l = Zt(e), d = i || r ? [...l ? lt(l) : [], ...lt(t)] : [];
1256
+ d.forEach((w) => {
1257
+ i && w.addEventListener("scroll", n, {
1258
+ passive: !0
1259
+ }), r && w.addEventListener("resize", n);
1260
+ });
1261
+ const f = l && c ? xo(l, n) : null;
1262
+ let h = -1, u = null;
1263
+ s && (u = new ResizeObserver((w) => {
1264
+ let [y] = w;
1265
+ y && y.target === l && u && (u.unobserve(t), cancelAnimationFrame(h), h = requestAnimationFrame(() => {
1266
+ var x;
1267
+ (x = u) == null || x.observe(t);
1268
+ })), n();
1269
+ }), l && !a && u.observe(l), u.observe(t));
1270
+ let m, p = a ? et(e) : null;
1271
+ a && v();
1272
+ function v() {
1273
+ const w = et(e);
1274
+ p && !Me(p, w) && n(), p = w, m = requestAnimationFrame(v);
1275
+ }
1276
+ return n(), () => {
1277
+ var w;
1278
+ d.forEach((y) => {
1279
+ i && y.removeEventListener("scroll", n), r && y.removeEventListener("resize", n);
1280
+ }), f == null || f(), (w = u) == null || w.disconnect(), u = null, a && cancelAnimationFrame(m);
1281
+ };
1282
+ }
1283
+ const yo = _n, bo = jn, Co = Wn, So = Kn, Ao = Hn, Po = Xn, Eo = (e, t, n) => {
1284
+ const o = /* @__PURE__ */ new Map(), i = {
1285
+ platform: vo,
1286
+ ...n
1287
+ }, r = {
1288
+ ...i.platform,
1289
+ _c: o
1290
+ };
1291
+ return Bn(e, t, {
1292
+ ...i,
1293
+ platform: r
1294
+ });
1295
+ };
1296
+ var Oo = "div";
1297
+ function de(e = 0, t = 0, n = 0, o = 0) {
1298
+ if (typeof DOMRect == "function")
1299
+ return new DOMRect(e, t, n, o);
1300
+ const i = {
1301
+ x: e,
1302
+ y: t,
1303
+ width: n,
1304
+ height: o,
1305
+ top: t,
1306
+ right: e + n,
1307
+ bottom: t + o,
1308
+ left: e
1309
+ };
1310
+ return { ...i, toJSON: () => i };
1311
+ }
1312
+ function Ro(e) {
1313
+ if (!e) return de();
1314
+ const { x: t, y: n, width: o, height: i } = e;
1315
+ return de(t, n, o, i);
1316
+ }
1317
+ function To(e, t) {
1318
+ return {
1319
+ contextElement: e || void 0,
1320
+ getBoundingClientRect: () => {
1321
+ const o = e, i = t == null ? void 0 : t(o);
1322
+ return i || !o ? Ro(i) : o.getBoundingClientRect();
1323
+ }
1324
+ };
1325
+ }
1326
+ function Do(e) {
1327
+ return /^(?:top|bottom|left|right)(?:-(?:start|end))?$/.test(e);
1328
+ }
1329
+ function me(e) {
1330
+ const t = window.devicePixelRatio || 1;
1331
+ return Math.round(e * t) / t;
1332
+ }
1333
+ function Mo(e, t) {
1334
+ return yo(({ placement: n }) => {
1335
+ var o;
1336
+ const i = ((e == null ? void 0 : e.clientHeight) || 0) / 2, r = typeof t.gutter == "number" ? t.gutter + i : (o = t.gutter) != null ? o : i;
1337
+ return {
1338
+ crossAxis: !!n.split("-")[1] ? void 0 : t.shift,
1339
+ mainAxis: r,
1340
+ alignmentAxis: t.shift
1341
+ };
1342
+ });
1343
+ }
1344
+ function Io(e) {
1345
+ if (e.flip === !1) return;
1346
+ const t = typeof e.flip == "string" ? e.flip.split(" ") : void 0;
1347
+ return jt(
1348
+ !t || t.every(Do),
1349
+ process.env.NODE_ENV !== "production" && "`flip` expects a spaced-delimited list of placements"
1350
+ ), Co({
1351
+ padding: e.overflowPadding,
1352
+ fallbackPlacements: t
1353
+ });
1354
+ }
1355
+ function Lo(e) {
1356
+ if (!(!e.slide && !e.overlap))
1357
+ return bo({
1358
+ mainAxis: e.slide,
1359
+ crossAxis: e.overlap,
1360
+ padding: e.overflowPadding,
1361
+ limiter: Po()
1362
+ });
1363
+ }
1364
+ function Fo(e) {
1365
+ return So({
1366
+ padding: e.overflowPadding,
1367
+ apply({ elements: t, availableWidth: n, availableHeight: o, rects: i }) {
1368
+ const r = t.floating, s = Math.round(i.reference.width);
1369
+ n = Math.floor(n), o = Math.floor(o), r.style.setProperty(
1370
+ "--popover-anchor-width",
1371
+ `${s}px`
1372
+ ), r.style.setProperty(
1373
+ "--popover-available-width",
1374
+ `${n}px`
1375
+ ), r.style.setProperty(
1376
+ "--popover-available-height",
1377
+ `${o}px`
1378
+ ), e.sameWidth && (r.style.width = `${s}px`), e.fitViewport && (r.style.maxWidth = `${n}px`, r.style.maxHeight = `${o}px`);
1379
+ }
1380
+ });
1381
+ }
1382
+ function ko(e, t) {
1383
+ if (e)
1384
+ return Ao({
1385
+ element: e,
1386
+ padding: t.arrowPadding
1387
+ });
1388
+ }
1389
+ var $o = at(
1390
+ function({
1391
+ store: t,
1392
+ modal: n = !1,
1393
+ portal: o = !!n,
1394
+ preserveTabOrder: i = !0,
1395
+ autoFocusOnShow: r = !0,
1396
+ wrapperProps: s,
1397
+ fixed: c = !1,
1398
+ flip: a = !0,
1399
+ shift: l = 0,
1400
+ slide: d = !0,
1401
+ overlap: f = !1,
1402
+ sameWidth: h = !1,
1403
+ fitViewport: u = !1,
1404
+ gutter: m,
1405
+ arrowPadding: p = 4,
1406
+ overflowPadding: v = 8,
1407
+ getAnchorRect: w,
1408
+ updatePosition: y,
1409
+ ...x
1410
+ }) {
1411
+ const S = Kt();
1412
+ t = t || S, jt(
1413
+ t,
1414
+ process.env.NODE_ENV !== "production" && "Popover must receive a `store` prop or be wrapped in a PopoverProvider component."
1415
+ );
1416
+ const C = t.useState("arrowElement"), O = t.useState("anchorElement"), E = t.useState("disclosureElement"), P = t.useState("popoverElement"), D = t.useState("contentElement"), T = t.useState("placement"), M = t.useState("mounted"), I = t.useState("rendered"), L = bt(null), [R, $] = cn(!1), { portalRef: F, domReady: g } = Ge(o, x.portalRef), b = tt(w), A = tt(y), G = !!y;
1417
+ oe(() => {
1418
+ if (!(P != null && P.isConnected)) return;
1419
+ P.style.setProperty(
1420
+ "--popover-overflow-padding",
1421
+ `${v}px`
1422
+ );
1423
+ const k = To(O, b), B = async () => {
1424
+ if (!M) return;
1425
+ C || (L.current = L.current || document.createElement("div"));
1426
+ const U = C || L.current, gt = [
1427
+ Mo(U, { gutter: m, shift: l }),
1428
+ Io({ flip: a, overflowPadding: v }),
1429
+ Lo({ slide: d, overlap: f, overflowPadding: v }),
1430
+ ko(U, { arrowPadding: p }),
1431
+ Fo({
1432
+ sameWidth: h,
1433
+ fitViewport: u,
1434
+ overflowPadding: v
1435
+ })
1436
+ ], Y = await Eo(k, P, {
1437
+ placement: T,
1438
+ strategy: c ? "fixed" : "absolute",
1439
+ middleware: gt
1440
+ });
1441
+ t == null || t.setState("currentPlacement", Y.placement), $(!0);
1442
+ const It = me(Y.x), Lt = me(Y.y);
1443
+ if (Object.assign(P.style, {
1444
+ top: "0",
1445
+ left: "0",
1446
+ transform: `translate3d(${It}px,${Lt}px,0)`
1447
+ }), U && Y.middlewareData.arrow) {
1448
+ const { x: nt, y: ot } = Y.middlewareData.arrow, ht = Y.placement.split("-")[0], pt = U.clientWidth / 2, vt = U.clientHeight / 2, ee = nt != null ? nt + pt : -pt, ne = ot != null ? ot + vt : -vt;
1449
+ P.style.setProperty(
1450
+ "--popover-transform-origin",
1451
+ {
1452
+ top: `${ee}px calc(100% + ${vt}px)`,
1453
+ bottom: `${ee}px ${-vt}px`,
1454
+ left: `calc(100% + ${pt}px) ${ne}px`,
1455
+ right: `${-pt}px ${ne}px`
1456
+ }[ht]
1457
+ ), Object.assign(U.style, {
1458
+ left: nt != null ? `${nt}px` : "",
1459
+ top: ot != null ? `${ot}px` : "",
1460
+ [ht]: "100%"
1461
+ });
1462
+ }
1463
+ }, te = wo(k, P, async () => {
1464
+ G ? (await A({ updatePosition: B }), $(!0)) : await B();
1465
+ }, {
1466
+ // JSDOM doesn't support ResizeObserver
1467
+ elementResize: typeof ResizeObserver == "function"
1468
+ });
1469
+ return () => {
1470
+ $(!1), te();
1471
+ };
1472
+ }, [
1473
+ t,
1474
+ I,
1475
+ P,
1476
+ C,
1477
+ O,
1478
+ P,
1479
+ T,
1480
+ M,
1481
+ g,
1482
+ c,
1483
+ a,
1484
+ l,
1485
+ d,
1486
+ f,
1487
+ h,
1488
+ u,
1489
+ m,
1490
+ p,
1491
+ v,
1492
+ b,
1493
+ G,
1494
+ A
1495
+ ]), oe(() => {
1496
+ if (!M || !g || !(P != null && P.isConnected) || !(D != null && D.isConnected)) return;
1497
+ const k = () => {
1498
+ P.style.zIndex = getComputedStyle(D).zIndex;
1499
+ };
1500
+ k();
1501
+ let B = requestAnimationFrame(() => {
1502
+ B = requestAnimationFrame(k);
1503
+ });
1504
+ return () => cancelAnimationFrame(B);
1505
+ }, [M, g, P, D]);
1506
+ const z = c ? "fixed" : "absolute";
1507
+ return x = Nt(
1508
+ x,
1509
+ (k) => /* @__PURE__ */ Vt(
1510
+ "div",
1511
+ {
1512
+ ...s,
1513
+ style: {
1514
+ // https://floating-ui.com/docs/computeposition#initial-layout
1515
+ position: z,
1516
+ top: 0,
1517
+ left: 0,
1518
+ width: "max-content",
1519
+ ...s == null ? void 0 : s.style
1520
+ },
1521
+ ref: t == null ? void 0 : t.setPopoverElement,
1522
+ children: k
1523
+ }
1524
+ ),
1525
+ [t, z, s]
1526
+ ), x = Nt(
1527
+ x,
1528
+ (k) => /* @__PURE__ */ Vt(be, { value: t, children: k }),
1529
+ [t]
1530
+ ), x = {
1531
+ // data-placing is not part of the public API. We're setting this here so
1532
+ // we can wait for the popover to be positioned before other components
1533
+ // move focus into it. For example, this attribute is observed by the
1534
+ // Combobox component with the autoSelect behavior.
1535
+ "data-placing": !R || void 0,
1536
+ ...x,
1537
+ style: {
1538
+ position: "relative",
1539
+ ...x.style
1540
+ }
1541
+ }, x = vn({
1542
+ store: t,
1543
+ modal: n,
1544
+ portal: o,
1545
+ preserveTabOrder: i,
1546
+ preserveTabOrderAnchor: E || O,
1547
+ autoFocusOnShow: R && r,
1548
+ ...x,
1549
+ portalRef: F
1550
+ }), x;
1551
+ }
1552
+ );
1553
+ xn(
1554
+ ft(function(t) {
1555
+ const n = $o(t);
1556
+ return ut(Oo, n);
1557
+ }),
1558
+ Kt
1559
+ );
1560
+ function ri({
1561
+ popover: e,
1562
+ ...t
1563
+ } = {}) {
1564
+ const n = fn(
1565
+ t.store,
1566
+ un(e, [
1567
+ "arrowElement",
1568
+ "anchorElement",
1569
+ "contentElement",
1570
+ "popoverElement",
1571
+ "disclosureElement"
1572
+ ])
1573
+ );
1574
+ dn(t, n);
1575
+ const o = n == null ? void 0 : n.getState(), i = wn({ ...t, store: n }), r = xt(
1576
+ t.placement,
1577
+ o == null ? void 0 : o.placement,
1578
+ "bottom"
1579
+ ), s = {
1580
+ ...i.getState(),
1581
+ placement: r,
1582
+ currentPlacement: r,
1583
+ anchorElement: xt(o == null ? void 0 : o.anchorElement, null),
1584
+ popoverElement: xt(o == null ? void 0 : o.popoverElement, null),
1585
+ arrowElement: xt(o == null ? void 0 : o.arrowElement, null),
1586
+ rendered: Symbol("rendered")
1587
+ }, c = mn(s, i, n);
1588
+ return {
1589
+ ...i,
1590
+ ...c,
1591
+ setAnchorElement: (a) => c.setState("anchorElement", a),
1592
+ setPopoverElement: (a) => c.setState("popoverElement", a),
1593
+ setArrowElement: (a) => c.setState("arrowElement", a),
1594
+ render: () => c.setState("rendered", Symbol("rendered"))
1595
+ };
1596
+ }
1597
+ function si(e, t, n) {
1598
+ return Je(t, [n.popover]), gn(e, n, "placement"), yn(e, t, n);
1599
+ }
1600
+ var No = "div", Vo = at(
1601
+ function({ store: t, ...n }) {
1602
+ const o = Kt();
1603
+ return t = t || o, n = {
1604
+ ...n,
1605
+ ref: Pt(t == null ? void 0 : t.setAnchorElement, n.ref)
1606
+ }, n;
1607
+ }
1608
+ );
1609
+ ft(function(t) {
1610
+ const n = Vo(t);
1611
+ return ut(No, n);
1612
+ });
1613
+ var Bo = "div";
1614
+ function Ie(e) {
1615
+ const t = e.relatedTarget;
1616
+ return (t == null ? void 0 : t.nodeType) === Node.ELEMENT_NODE ? t : null;
1617
+ }
1618
+ function Ho(e) {
1619
+ const t = Ie(e);
1620
+ return t ? en(e.currentTarget, t) : !1;
1621
+ }
1622
+ var zt = Symbol("composite-hover");
1623
+ function Wo(e) {
1624
+ let t = Ie(e);
1625
+ if (!t) return !1;
1626
+ do {
1627
+ if (nn(t, zt) && t[zt]) return !0;
1628
+ t = t.parentElement;
1629
+ } while (t);
1630
+ return !1;
1631
+ }
1632
+ var zo = at(
1633
+ function({
1634
+ store: t,
1635
+ focusOnHover: n = !0,
1636
+ blurOnHoverEnd: o = !!n,
1637
+ ...i
1638
+ }) {
1639
+ const r = ge();
1640
+ t = t || r, jt(
1641
+ t,
1642
+ process.env.NODE_ENV !== "production" && "CompositeHover must be wrapped in a Composite component."
1643
+ );
1644
+ const s = Qe(), c = i.onMouseMove, a = yt(n), l = tt((m) => {
1645
+ if (c == null || c(m), !m.defaultPrevented && s() && a(m)) {
1646
+ if (!Ze(m.currentTarget)) {
1647
+ const p = t == null ? void 0 : t.getState().baseElement;
1648
+ p && !tn(p) && p.focus();
1649
+ }
1650
+ t == null || t.setActiveId(m.currentTarget.id);
1651
+ }
1652
+ }), d = i.onMouseLeave, f = yt(o), h = tt((m) => {
1653
+ var p;
1654
+ d == null || d(m), !m.defaultPrevented && s() && (Ho(m) || Wo(m) || a(m) && f(m) && (t == null || t.setActiveId(null), (p = t == null ? void 0 : t.getState().baseElement) == null || p.focus()));
1655
+ }), u = we((m) => {
1656
+ m && (m[zt] = !0);
1657
+ }, []);
1658
+ return i = {
1659
+ ...i,
1660
+ ref: Pt(u, i.ref),
1661
+ onMouseMove: l,
1662
+ onMouseLeave: h
1663
+ }, _t(i);
1664
+ }
1665
+ );
1666
+ ve(
1667
+ ft(function(t) {
1668
+ const n = zo(t);
1669
+ return ut(Bo, n);
1670
+ })
1671
+ );
1672
+ export {
1673
+ Jo as C,
1674
+ be as P,
1675
+ Vo as a,
1676
+ Zo as b,
1677
+ On as c,
1678
+ zo as d,
1679
+ oi as e,
1680
+ ii as f,
1681
+ Qo as g,
1682
+ ni as h,
1683
+ $o as i,
1684
+ ri as j,
1685
+ si as k,
1686
+ ei as l,
1687
+ Rn as m,
1688
+ Kt as n,
1689
+ Go as o,
1690
+ ti as u
1691
+ };
1692
+ //# sourceMappingURL=X6LNAU2F-DroCIVyL.js.map