@namuna-nur/ui-kit 1.9.1 → 1.9.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/shared/Avatar.tokens.js +692 -688
- package/lib/shared/CardProgress.tokens.js +5585 -5598
- package/lib/src/atoms/Select/Select.d.ts +1 -1
- package/lib/src/atoms/Select/Select.stories.d.ts +2 -0
- package/lib/src/atoms/Select/Select.tokens.d.ts +1 -0
- package/lib/src/atoms/Select/Select.types.d.ts +1 -0
- package/lib/src/molecules/SelectList/SelectList.tokens.d.ts +1 -0
- package/lib/src/molecules/SelectList/SelectList.types.d.ts +5 -0
- package/lib/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as c from "react";
|
|
2
|
-
import ae, { forwardRef as ue, useLayoutEffect as oi, useState as Yr, createElement as
|
|
2
|
+
import ae, { forwardRef as ue, useLayoutEffect as oi, useState as Yr, createElement as be, useRef as mr } from "react";
|
|
3
3
|
import { a as A, f as ai } from "./twMerge.js";
|
|
4
4
|
import * as Xr from "react-dom";
|
|
5
5
|
import ii from "react-dom";
|
|
@@ -61,9 +61,9 @@ function li() {
|
|
|
61
61
|
return "Profiler";
|
|
62
62
|
case x:
|
|
63
63
|
return "StrictMode";
|
|
64
|
-
case
|
|
64
|
+
case _:
|
|
65
65
|
return "Suspense";
|
|
66
|
-
case
|
|
66
|
+
case E:
|
|
67
67
|
return "SuspenseList";
|
|
68
68
|
case I:
|
|
69
69
|
return "Activity";
|
|
@@ -78,7 +78,7 @@ function li() {
|
|
|
78
78
|
return y.displayName || "Context";
|
|
79
79
|
case w:
|
|
80
80
|
return (y._context.displayName || "Context") + ".Consumer";
|
|
81
|
-
case
|
|
81
|
+
case R:
|
|
82
82
|
var T = y.render;
|
|
83
83
|
return y = y.displayName, y || (y = T.displayName || T.name || "", y = y !== "" ? "ForwardRef(" + y + ")" : "ForwardRef"), y;
|
|
84
84
|
case M:
|
|
@@ -149,7 +149,7 @@ function li() {
|
|
|
149
149
|
configurable: !0
|
|
150
150
|
});
|
|
151
151
|
}
|
|
152
|
-
function
|
|
152
|
+
function d() {
|
|
153
153
|
var y = e(this.type);
|
|
154
154
|
return V[y] || (V[y] = !0, console.error(
|
|
155
155
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
@@ -165,7 +165,7 @@ function li() {
|
|
|
165
165
|
_owner: U
|
|
166
166
|
}, (N !== void 0 ? N : null) !== null ? Object.defineProperty(y, "ref", {
|
|
167
167
|
enumerable: !1,
|
|
168
|
-
get:
|
|
168
|
+
get: d
|
|
169
169
|
}) : Object.defineProperty(y, "ref", { enumerable: !1, value: null }), y._store = {}, Object.defineProperty(y._store, "validated", {
|
|
170
170
|
configurable: !1,
|
|
171
171
|
enumerable: !1,
|
|
@@ -194,17 +194,17 @@ function li() {
|
|
|
194
194
|
if (U)
|
|
195
195
|
if (L(N)) {
|
|
196
196
|
for (U = 0; U < N.length; U++)
|
|
197
|
-
|
|
197
|
+
u(N[U]);
|
|
198
198
|
Object.freeze && Object.freeze(N);
|
|
199
199
|
} else
|
|
200
200
|
console.error(
|
|
201
201
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
202
202
|
);
|
|
203
|
-
else
|
|
203
|
+
else u(N);
|
|
204
204
|
if ($.call(T, "key")) {
|
|
205
205
|
N = e(y);
|
|
206
|
-
var J = Object.keys(T).filter(function(
|
|
207
|
-
return
|
|
206
|
+
var J = Object.keys(T).filter(function(Re) {
|
|
207
|
+
return Re !== "key";
|
|
208
208
|
});
|
|
209
209
|
U = 0 < J.length ? "{key: someKey, " + J.join(": ..., ") + ": ...}" : "{key: someKey}", B[N + U] || (J = 0 < J.length ? "{" + J.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
210
210
|
`A props object containing a "key" prop is being spread into JSX:
|
|
@@ -236,13 +236,13 @@ React keys must be passed directly to JSX without using spread:
|
|
|
236
236
|
ee
|
|
237
237
|
);
|
|
238
238
|
}
|
|
239
|
-
function
|
|
239
|
+
function u(y) {
|
|
240
240
|
p(y) ? y._store && (y._store.validated = 1) : typeof y == "object" && y !== null && y.$$typeof === D && (y._payload.status === "fulfilled" ? p(y._payload.value) && y._payload.value._store && (y._payload.value._store.validated = 1) : y._store && (y._store.validated = 1));
|
|
241
241
|
}
|
|
242
242
|
function p(y) {
|
|
243
243
|
return typeof y == "object" && y !== null && y.$$typeof === g;
|
|
244
244
|
}
|
|
245
|
-
var h = ae, g = Symbol.for("react.transitional.element"), v = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), x = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), w = Symbol.for("react.consumer"), C = Symbol.for("react.context"),
|
|
245
|
+
var h = ae, g = Symbol.for("react.transitional.element"), v = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), x = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), w = Symbol.for("react.consumer"), C = Symbol.for("react.context"), R = Symbol.for("react.forward_ref"), _ = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), M = Symbol.for("react.memo"), D = Symbol.for("react.lazy"), I = Symbol.for("react.activity"), G = Symbol.for("react.client.reference"), W = h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, $ = Object.prototype.hasOwnProperty, L = Array.isArray, z = console.createTask ? console.createTask : function() {
|
|
246
246
|
return null;
|
|
247
247
|
};
|
|
248
248
|
h = {
|
|
@@ -253,7 +253,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
253
253
|
var j, V = {}, O = h.react_stack_bottom_frame.bind(
|
|
254
254
|
h,
|
|
255
255
|
a
|
|
256
|
-
)(),
|
|
256
|
+
)(), P = z(r(a)), B = {};
|
|
257
257
|
Ke.Fragment = b, Ke.jsx = function(y, T, F) {
|
|
258
258
|
var U = 1e4 > W.recentlyCreatedOwnerStacks++;
|
|
259
259
|
return f(
|
|
@@ -262,7 +262,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
262
262
|
F,
|
|
263
263
|
!1,
|
|
264
264
|
U ? Error("react-stack-top-frame") : O,
|
|
265
|
-
U ? z(r(y)) :
|
|
265
|
+
U ? z(r(y)) : P
|
|
266
266
|
);
|
|
267
267
|
}, Ke.jsxs = function(y, T, F) {
|
|
268
268
|
var U = 1e4 > W.recentlyCreatedOwnerStacks++;
|
|
@@ -272,7 +272,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
272
272
|
F,
|
|
273
273
|
!0,
|
|
274
274
|
U ? Error("react-stack-top-frame") : O,
|
|
275
|
-
U ? z(r(y)) :
|
|
275
|
+
U ? z(r(y)) : P
|
|
276
276
|
);
|
|
277
277
|
};
|
|
278
278
|
}()), Ke;
|
|
@@ -340,10 +340,10 @@ const Ye = {
|
|
|
340
340
|
iconPosition: a = "right",
|
|
341
341
|
size: i = "medium",
|
|
342
342
|
variant: s = "primary",
|
|
343
|
-
isShadow:
|
|
343
|
+
isShadow: d = !1,
|
|
344
344
|
...l
|
|
345
345
|
}, f) => {
|
|
346
|
-
const
|
|
346
|
+
const u = Ye.icon, p = Ye.sizes[i], h = Ye.variants[s] || Ye.variants.primary, g = u.variants[s], v = u.disabled[s];
|
|
347
347
|
return /* @__PURE__ */ m.jsxs(
|
|
348
348
|
"button",
|
|
349
349
|
{
|
|
@@ -361,9 +361,9 @@ const Ye = {
|
|
|
361
361
|
!n && h.hover,
|
|
362
362
|
!n && h.active,
|
|
363
363
|
n && h.disabled,
|
|
364
|
-
!!r &&
|
|
364
|
+
!!r && u.parent,
|
|
365
365
|
!!r && !e && "min-w-0",
|
|
366
|
-
s === "primary" &&
|
|
366
|
+
s === "primary" && d && "shadow-3xl",
|
|
367
367
|
t == null ? void 0 : t.base
|
|
368
368
|
),
|
|
369
369
|
children: [
|
|
@@ -412,31 +412,31 @@ const Ye = {
|
|
|
412
412
|
badge: a,
|
|
413
413
|
iconSizes: i,
|
|
414
414
|
text: s,
|
|
415
|
-
...
|
|
415
|
+
...d
|
|
416
416
|
}, l) => {
|
|
417
417
|
var v;
|
|
418
|
-
const f =
|
|
418
|
+
const f = Me.icon, u = Me.variants[r], p = f.variants[r], h = (v = Me.shape) == null ? void 0 : v[o], g = f.disabled[r];
|
|
419
419
|
return /* @__PURE__ */ m.jsxs(
|
|
420
420
|
"button",
|
|
421
421
|
{
|
|
422
|
-
...
|
|
422
|
+
...d,
|
|
423
423
|
role: "button",
|
|
424
|
-
type:
|
|
424
|
+
type: d.type || "button",
|
|
425
425
|
ref: l,
|
|
426
426
|
disabled: t,
|
|
427
427
|
className: A(
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
428
|
+
Me.base,
|
|
429
|
+
u.base,
|
|
430
|
+
u.focus,
|
|
431
431
|
h,
|
|
432
|
-
a &&
|
|
433
|
-
!t &&
|
|
434
|
-
!t &&
|
|
435
|
-
t &&
|
|
432
|
+
a && Me.badgeStyles.base,
|
|
433
|
+
!t && u.hover,
|
|
434
|
+
!t && u.active,
|
|
435
|
+
t && u.disabled,
|
|
436
436
|
e == null ? void 0 : e.button
|
|
437
437
|
),
|
|
438
438
|
children: [
|
|
439
|
-
a && /* @__PURE__ */ m.jsx("span", { className:
|
|
439
|
+
a && /* @__PURE__ */ m.jsx("span", { className: Me.badgeStyles.badgeStyles, children: a }),
|
|
440
440
|
!!n && /* @__PURE__ */ m.jsx(
|
|
441
441
|
n,
|
|
442
442
|
{
|
|
@@ -453,12 +453,12 @@ const Ye = {
|
|
|
453
453
|
viewBox: i == null ? void 0 : i.viewBox
|
|
454
454
|
}
|
|
455
455
|
),
|
|
456
|
-
!!s && /* @__PURE__ */ m.jsx(
|
|
456
|
+
!!s && /* @__PURE__ */ m.jsx(ge, { className: e == null ? void 0 : e.text, children: s })
|
|
457
457
|
]
|
|
458
458
|
}
|
|
459
459
|
);
|
|
460
460
|
}
|
|
461
|
-
),
|
|
461
|
+
), Me = {
|
|
462
462
|
base: "group inline-flex items-center justify-center rounded-[10px] outline-none border",
|
|
463
463
|
icon: {
|
|
464
464
|
base: "text-inherit",
|
|
@@ -504,7 +504,7 @@ const Ye = {
|
|
|
504
504
|
disabled: "disabled:border-transparent disabled:cursor-default"
|
|
505
505
|
}
|
|
506
506
|
}
|
|
507
|
-
},
|
|
507
|
+
}, Oe = {
|
|
508
508
|
active: "active:bg-tertiary-10 active:border-tertiary-10 outline-none",
|
|
509
509
|
base: "border border-secondary-10/[.25] hover:border-primary-10 flex items-center justify-center rounded-[6px] cursor-pointer",
|
|
510
510
|
checked: "bg-primary-10 border-primary-10",
|
|
@@ -531,7 +531,7 @@ const Ye = {
|
|
|
531
531
|
size: a = "large",
|
|
532
532
|
...i
|
|
533
533
|
}, s) => {
|
|
534
|
-
const
|
|
534
|
+
const d = Oe.base, l = Oe.sizes[a];
|
|
535
535
|
return /* @__PURE__ */ m.jsxs(
|
|
536
536
|
"label",
|
|
537
537
|
{
|
|
@@ -540,11 +540,11 @@ const Ye = {
|
|
|
540
540
|
tabIndex: 0,
|
|
541
541
|
className: A(
|
|
542
542
|
l.label,
|
|
543
|
-
|
|
544
|
-
e &&
|
|
545
|
-
!n &&
|
|
546
|
-
!n && e &&
|
|
547
|
-
n &&
|
|
543
|
+
d,
|
|
544
|
+
e && Oe.checked,
|
|
545
|
+
!n && Oe.active,
|
|
546
|
+
!n && e && Oe.hover,
|
|
547
|
+
n && Oe.disabled,
|
|
548
548
|
t
|
|
549
549
|
),
|
|
550
550
|
children: [
|
|
@@ -608,14 +608,14 @@ const Ye = {
|
|
|
608
608
|
maxLength: a,
|
|
609
609
|
id: i,
|
|
610
610
|
classNames: s,
|
|
611
|
-
...
|
|
611
|
+
...d
|
|
612
612
|
}, l) => {
|
|
613
|
-
const f =
|
|
613
|
+
const f = ke.parent, u = ke.base, p = ke.state, h = ke.disabled, g = ke.styles, v = ke.maxLength;
|
|
614
614
|
return /* @__PURE__ */ m.jsxs("div", { className: A(f, s == null ? void 0 : s.parent), children: [
|
|
615
615
|
/* @__PURE__ */ m.jsx(
|
|
616
616
|
"input",
|
|
617
617
|
{
|
|
618
|
-
...
|
|
618
|
+
...d,
|
|
619
619
|
role: "textbox",
|
|
620
620
|
ref: l,
|
|
621
621
|
id: i,
|
|
@@ -624,7 +624,7 @@ const Ye = {
|
|
|
624
624
|
onChange: t,
|
|
625
625
|
maxLength: a,
|
|
626
626
|
className: A(
|
|
627
|
-
|
|
627
|
+
u,
|
|
628
628
|
p.focus,
|
|
629
629
|
!e && p.hover,
|
|
630
630
|
o && (g == null ? void 0 : g[o]),
|
|
@@ -635,15 +635,15 @@ const Ye = {
|
|
|
635
635
|
}
|
|
636
636
|
),
|
|
637
637
|
a && /* @__PURE__ */ m.jsxs(
|
|
638
|
-
|
|
638
|
+
ge,
|
|
639
639
|
{
|
|
640
640
|
variant: "span",
|
|
641
641
|
className: A(
|
|
642
642
|
v,
|
|
643
|
-
String(
|
|
643
|
+
String(d.value).length === a ? "bg-danger-10" : "bg-success-10"
|
|
644
644
|
),
|
|
645
645
|
children: [
|
|
646
|
-
(
|
|
646
|
+
(d.value || "").toString().length,
|
|
647
647
|
"/",
|
|
648
648
|
a
|
|
649
649
|
]
|
|
@@ -651,7 +651,7 @@ const Ye = {
|
|
|
651
651
|
)
|
|
652
652
|
] });
|
|
653
653
|
}
|
|
654
|
-
),
|
|
654
|
+
), ke = {
|
|
655
655
|
parent: "relative flex flex-col items-start w-full",
|
|
656
656
|
base: "text-dark-10 text-sm leading-none w-full rounded-[10px] bg-gray-50 border border-gray-50 p-[12.5px] placeholder:text-dark-10/[.40]",
|
|
657
657
|
disabled: "bg-secondary-10/[.08] text-gray-30 cursor-not-allowed",
|
|
@@ -686,33 +686,33 @@ const Ye = {
|
|
|
686
686
|
base: "text-secondary-10 text-sm font-sans font-semibold leading-none",
|
|
687
687
|
disabled: "text-dark-30/25 cursor-not-allowed"
|
|
688
688
|
};
|
|
689
|
-
function
|
|
689
|
+
function we(e, t = []) {
|
|
690
690
|
let n = [];
|
|
691
691
|
function r(a, i) {
|
|
692
|
-
const s = c.createContext(i),
|
|
692
|
+
const s = c.createContext(i), d = n.length;
|
|
693
693
|
n = [...n, i];
|
|
694
|
-
const l = (
|
|
694
|
+
const l = (u) => {
|
|
695
695
|
var x;
|
|
696
|
-
const { scope: p, children: h, ...g } =
|
|
696
|
+
const { scope: p, children: h, ...g } = u, v = ((x = p == null ? void 0 : p[e]) == null ? void 0 : x[d]) || s, b = c.useMemo(() => g, Object.values(g));
|
|
697
697
|
return /* @__PURE__ */ m.jsx(v.Provider, { value: b, children: h });
|
|
698
698
|
};
|
|
699
699
|
l.displayName = a + "Provider";
|
|
700
|
-
function f(
|
|
700
|
+
function f(u, p) {
|
|
701
701
|
var v;
|
|
702
|
-
const h = ((v = p == null ? void 0 : p[e]) == null ? void 0 : v[
|
|
702
|
+
const h = ((v = p == null ? void 0 : p[e]) == null ? void 0 : v[d]) || s, g = c.useContext(h);
|
|
703
703
|
if (g) return g;
|
|
704
704
|
if (i !== void 0) return i;
|
|
705
|
-
throw new Error(`\`${
|
|
705
|
+
throw new Error(`\`${u}\` must be used within \`${a}\``);
|
|
706
706
|
}
|
|
707
707
|
return [l, f];
|
|
708
708
|
}
|
|
709
709
|
const o = () => {
|
|
710
710
|
const a = n.map((i) => c.createContext(i));
|
|
711
711
|
return function(s) {
|
|
712
|
-
const
|
|
712
|
+
const d = (s == null ? void 0 : s[e]) || a;
|
|
713
713
|
return c.useMemo(
|
|
714
|
-
() => ({ [`__scope${e}`]: { ...s, [e]:
|
|
715
|
-
[s,
|
|
714
|
+
() => ({ [`__scope${e}`]: { ...s, [e]: d } }),
|
|
715
|
+
[s, d]
|
|
716
716
|
);
|
|
717
717
|
};
|
|
718
718
|
};
|
|
@@ -727,9 +727,9 @@ function hi(...e) {
|
|
|
727
727
|
scopeName: o.scopeName
|
|
728
728
|
}));
|
|
729
729
|
return function(a) {
|
|
730
|
-
const i = r.reduce((s, { useScope:
|
|
731
|
-
const
|
|
732
|
-
return { ...s, ...
|
|
730
|
+
const i = r.reduce((s, { useScope: d, scopeName: l }) => {
|
|
731
|
+
const u = d(a)[`__scope${l}`];
|
|
732
|
+
return { ...s, ...u };
|
|
733
733
|
}, {});
|
|
734
734
|
return c.useMemo(() => ({ [`__scope${t.scopeName}`]: i }), [i]);
|
|
735
735
|
};
|
|
@@ -763,9 +763,9 @@ function K(...e) {
|
|
|
763
763
|
// @__NO_SIDE_EFFECTS__
|
|
764
764
|
function Ze(e) {
|
|
765
765
|
const t = /* @__PURE__ */ vi(e), n = c.forwardRef((r, o) => {
|
|
766
|
-
const { children: a, ...i } = r, s = c.Children.toArray(a),
|
|
767
|
-
if (
|
|
768
|
-
const l =
|
|
766
|
+
const { children: a, ...i } = r, s = c.Children.toArray(a), d = s.find(gi);
|
|
767
|
+
if (d) {
|
|
768
|
+
const l = d.props.children, f = s.map((u) => u === d ? c.Children.count(l) > 1 ? c.Children.only(null) : c.isValidElement(l) ? l.props.children : null : u);
|
|
769
769
|
return /* @__PURE__ */ m.jsx(t, { ...i, ref: o, children: c.isValidElement(l) ? c.cloneElement(l, void 0, f) : null });
|
|
770
770
|
}
|
|
771
771
|
return /* @__PURE__ */ m.jsx(t, { ...i, ref: o, children: a });
|
|
@@ -798,8 +798,8 @@ function bi(e, t) {
|
|
|
798
798
|
for (const r in t) {
|
|
799
799
|
const o = e[r], a = t[r];
|
|
800
800
|
/^on[A-Z]/.test(r) ? o && a ? n[r] = (...s) => {
|
|
801
|
-
const
|
|
802
|
-
return o(...s),
|
|
801
|
+
const d = a(...s);
|
|
802
|
+
return o(...s), d;
|
|
803
803
|
} : o && (n[r] = o) : r === "style" ? n[r] = { ...o, ...a } : r === "className" && (n[r] = [o, a].filter(Boolean).join(" "));
|
|
804
804
|
}
|
|
805
805
|
return { ...e, ...n };
|
|
@@ -810,7 +810,7 @@ function xi(e) {
|
|
|
810
810
|
return n ? e.ref : (t = (o = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : o.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
811
811
|
}
|
|
812
812
|
function Jr(e) {
|
|
813
|
-
const t = e + "CollectionProvider", [n, r] =
|
|
813
|
+
const t = e + "CollectionProvider", [n, r] = we(t), [o, a] = n(
|
|
814
814
|
t,
|
|
815
815
|
{ collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
|
|
816
816
|
), i = (v) => {
|
|
@@ -818,17 +818,17 @@ function Jr(e) {
|
|
|
818
818
|
return /* @__PURE__ */ m.jsx(o, { scope: b, itemMap: w, collectionRef: S, children: x });
|
|
819
819
|
};
|
|
820
820
|
i.displayName = t;
|
|
821
|
-
const s = e + "CollectionSlot",
|
|
821
|
+
const s = e + "CollectionSlot", d = /* @__PURE__ */ Ze(s), l = ae.forwardRef(
|
|
822
822
|
(v, b) => {
|
|
823
823
|
const { scope: x, children: S } = v, w = a(s, x), C = K(b, w.collectionRef);
|
|
824
|
-
return /* @__PURE__ */ m.jsx(
|
|
824
|
+
return /* @__PURE__ */ m.jsx(d, { ref: C, children: S });
|
|
825
825
|
}
|
|
826
826
|
);
|
|
827
827
|
l.displayName = s;
|
|
828
|
-
const f = e + "CollectionItemSlot",
|
|
828
|
+
const f = e + "CollectionItemSlot", u = "data-radix-collection-item", p = /* @__PURE__ */ Ze(f), h = ae.forwardRef(
|
|
829
829
|
(v, b) => {
|
|
830
|
-
const { scope: x, children: S, ...w } = v, C = ae.useRef(null),
|
|
831
|
-
return ae.useEffect(() => (
|
|
830
|
+
const { scope: x, children: S, ...w } = v, C = ae.useRef(null), R = K(b, C), _ = a(f, x);
|
|
831
|
+
return ae.useEffect(() => (_.itemMap.set(C, { ref: C, ...w }), () => void _.itemMap.delete(C))), /* @__PURE__ */ m.jsx(p, { [u]: "", ref: R, children: S });
|
|
832
832
|
}
|
|
833
833
|
);
|
|
834
834
|
h.displayName = f;
|
|
@@ -837,9 +837,9 @@ function Jr(e) {
|
|
|
837
837
|
return ae.useCallback(() => {
|
|
838
838
|
const S = b.collectionRef.current;
|
|
839
839
|
if (!S) return [];
|
|
840
|
-
const w = Array.from(S.querySelectorAll(`[${
|
|
840
|
+
const w = Array.from(S.querySelectorAll(`[${u}]`));
|
|
841
841
|
return Array.from(b.itemMap.values()).sort(
|
|
842
|
-
(
|
|
842
|
+
(_, E) => w.indexOf(_.ref.current) - w.indexOf(E.ref.current)
|
|
843
843
|
);
|
|
844
844
|
}, [b.collectionRef, b.itemMap]);
|
|
845
845
|
}
|
|
@@ -867,28 +867,28 @@ function Ue({
|
|
|
867
867
|
const [o, a, i] = wi({
|
|
868
868
|
defaultProp: t,
|
|
869
869
|
onChange: n
|
|
870
|
-
}), s = e !== void 0,
|
|
870
|
+
}), s = e !== void 0, d = s ? e : o;
|
|
871
871
|
{
|
|
872
872
|
const f = c.useRef(e !== void 0);
|
|
873
873
|
c.useEffect(() => {
|
|
874
|
-
const
|
|
875
|
-
|
|
876
|
-
`${r} is changing from ${
|
|
874
|
+
const u = f.current;
|
|
875
|
+
u !== s && console.warn(
|
|
876
|
+
`${r} is changing from ${u ? "controlled" : "uncontrolled"} to ${s ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
|
|
877
877
|
), f.current = s;
|
|
878
878
|
}, [s, r]);
|
|
879
879
|
}
|
|
880
880
|
const l = c.useCallback(
|
|
881
881
|
(f) => {
|
|
882
|
-
var
|
|
882
|
+
var u;
|
|
883
883
|
if (s) {
|
|
884
884
|
const p = Si(f) ? f(e) : f;
|
|
885
|
-
p !== e && ((
|
|
885
|
+
p !== e && ((u = i.current) == null || u.call(i, p));
|
|
886
886
|
} else
|
|
887
887
|
a(f);
|
|
888
888
|
},
|
|
889
889
|
[s, e, a, i]
|
|
890
890
|
);
|
|
891
|
-
return [
|
|
891
|
+
return [d, l];
|
|
892
892
|
}
|
|
893
893
|
function wi({
|
|
894
894
|
defaultProp: e,
|
|
@@ -925,8 +925,8 @@ var Ci = [
|
|
|
925
925
|
"ul"
|
|
926
926
|
], H = Ci.reduce((e, t) => {
|
|
927
927
|
const n = /* @__PURE__ */ Ze(`Primitive.${t}`), r = c.forwardRef((o, a) => {
|
|
928
|
-
const { asChild: i, ...s } = o,
|
|
929
|
-
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ m.jsx(
|
|
928
|
+
const { asChild: i, ...s } = o, d = i ? n : t;
|
|
929
|
+
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ m.jsx(d, { ...s, ref: a });
|
|
930
930
|
});
|
|
931
931
|
return r.displayName = `Primitive.${t}`, { ...e, [t]: r };
|
|
932
932
|
}, {});
|
|
@@ -936,13 +936,13 @@ function Qr(e, t) {
|
|
|
936
936
|
function Ei(e, t) {
|
|
937
937
|
return c.useReducer((n, r) => t[n][r] ?? n, e);
|
|
938
938
|
}
|
|
939
|
-
var
|
|
939
|
+
var Se = (e) => {
|
|
940
940
|
const { present: t, children: n } = e, r = Ri(t), o = typeof n == "function" ? n({ present: r.isPresent }) : c.Children.only(n), a = K(r.ref, _i(o));
|
|
941
941
|
return typeof n == "function" || r.isPresent ? c.cloneElement(o, { ref: a }) : null;
|
|
942
942
|
};
|
|
943
|
-
|
|
943
|
+
Se.displayName = "Presence";
|
|
944
944
|
function Ri(e) {
|
|
945
|
-
const [t, n] = c.useState(), r = c.useRef(null), o = c.useRef(e), a = c.useRef("none"), i = e ? "mounted" : "unmounted", [s,
|
|
945
|
+
const [t, n] = c.useState(), r = c.useRef(null), o = c.useRef(e), a = c.useRef("none"), i = e ? "mounted" : "unmounted", [s, d] = Ei(i, {
|
|
946
946
|
mounted: {
|
|
947
947
|
UNMOUNT: "unmounted",
|
|
948
948
|
ANIMATION_OUT: "unmountSuspended"
|
|
@@ -962,14 +962,14 @@ function Ri(e) {
|
|
|
962
962
|
const l = r.current, f = o.current;
|
|
963
963
|
if (f !== e) {
|
|
964
964
|
const p = a.current, h = ut(l);
|
|
965
|
-
e ?
|
|
965
|
+
e ? d("MOUNT") : h === "none" || (l == null ? void 0 : l.display) === "none" ? d("UNMOUNT") : d(f && p !== h ? "ANIMATION_OUT" : "UNMOUNT"), o.current = e;
|
|
966
966
|
}
|
|
967
|
-
}, [e,
|
|
967
|
+
}, [e, d]), te(() => {
|
|
968
968
|
if (t) {
|
|
969
969
|
let l;
|
|
970
|
-
const f = t.ownerDocument.defaultView ?? window,
|
|
970
|
+
const f = t.ownerDocument.defaultView ?? window, u = (h) => {
|
|
971
971
|
const v = ut(r.current).includes(CSS.escape(h.animationName));
|
|
972
|
-
if (h.target === t && v && (
|
|
972
|
+
if (h.target === t && v && (d("ANIMATION_END"), !o.current)) {
|
|
973
973
|
const b = t.style.animationFillMode;
|
|
974
974
|
t.style.animationFillMode = "forwards", l = f.setTimeout(() => {
|
|
975
975
|
t.style.animationFillMode === "forwards" && (t.style.animationFillMode = b);
|
|
@@ -978,12 +978,12 @@ function Ri(e) {
|
|
|
978
978
|
}, p = (h) => {
|
|
979
979
|
h.target === t && (a.current = ut(r.current));
|
|
980
980
|
};
|
|
981
|
-
return t.addEventListener("animationstart", p), t.addEventListener("animationcancel",
|
|
982
|
-
f.clearTimeout(l), t.removeEventListener("animationstart", p), t.removeEventListener("animationcancel",
|
|
981
|
+
return t.addEventListener("animationstart", p), t.addEventListener("animationcancel", u), t.addEventListener("animationend", u), () => {
|
|
982
|
+
f.clearTimeout(l), t.removeEventListener("animationstart", p), t.removeEventListener("animationcancel", u), t.removeEventListener("animationend", u);
|
|
983
983
|
};
|
|
984
984
|
} else
|
|
985
|
-
|
|
986
|
-
}, [t,
|
|
985
|
+
d("ANIMATION_END");
|
|
986
|
+
}, [t, d]), {
|
|
987
987
|
isPresent: ["mounted", "unmountSuspended"].includes(s),
|
|
988
988
|
ref: c.useCallback((l) => {
|
|
989
989
|
r.current = l ? getComputedStyle(l) : null, n(l);
|
|
@@ -1000,7 +1000,7 @@ function _i(e) {
|
|
|
1000
1000
|
}
|
|
1001
1001
|
var Pi = c[" useId ".trim().toString()] || (() => {
|
|
1002
1002
|
}), Ai = 0;
|
|
1003
|
-
function
|
|
1003
|
+
function Pe(e) {
|
|
1004
1004
|
const [t, n] = c.useState(Pi());
|
|
1005
1005
|
return te(() => {
|
|
1006
1006
|
n((r) => r ?? String(Ai++));
|
|
@@ -1042,16 +1042,16 @@ var Oi = "DismissableLayer", tn = "dismissableLayer.update", ki = "dismissableLa
|
|
|
1042
1042
|
onFocusOutside: a,
|
|
1043
1043
|
onInteractOutside: i,
|
|
1044
1044
|
onDismiss: s,
|
|
1045
|
-
...
|
|
1046
|
-
} = e, l = c.useContext(eo), [f,
|
|
1047
|
-
const M =
|
|
1048
|
-
!C || D || (o == null || o(
|
|
1049
|
-
}, p),
|
|
1050
|
-
const M =
|
|
1051
|
-
[...l.branches].some((I) => I.contains(M)) || (a == null || a(
|
|
1045
|
+
...d
|
|
1046
|
+
} = e, l = c.useContext(eo), [f, u] = c.useState(null), p = (f == null ? void 0 : f.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, h] = c.useState({}), g = K(t, (E) => u(E)), v = Array.from(l.layers), [b] = [...l.layersWithOutsidePointerEventsDisabled].slice(-1), x = v.indexOf(b), S = f ? v.indexOf(f) : -1, w = l.layersWithOutsidePointerEventsDisabled.size > 0, C = S >= x, R = Di((E) => {
|
|
1047
|
+
const M = E.target, D = [...l.branches].some((I) => I.contains(M));
|
|
1048
|
+
!C || D || (o == null || o(E), i == null || i(E), E.defaultPrevented || s == null || s());
|
|
1049
|
+
}, p), _ = Ni((E) => {
|
|
1050
|
+
const M = E.target;
|
|
1051
|
+
[...l.branches].some((I) => I.contains(M)) || (a == null || a(E), i == null || i(E), E.defaultPrevented || s == null || s());
|
|
1052
1052
|
}, p);
|
|
1053
|
-
return Mi((
|
|
1054
|
-
S === l.layers.size - 1 && (r == null || r(
|
|
1053
|
+
return Mi((E) => {
|
|
1054
|
+
S === l.layers.size - 1 && (r == null || r(E), !E.defaultPrevented && s && (E.preventDefault(), s()));
|
|
1055
1055
|
}, p), c.useEffect(() => {
|
|
1056
1056
|
if (f)
|
|
1057
1057
|
return n && (l.layersWithOutsidePointerEventsDisabled.size === 0 && (yr = p.body.style.pointerEvents, p.body.style.pointerEvents = "none"), l.layersWithOutsidePointerEventsDisabled.add(f)), l.layers.add(f), wr(), () => {
|
|
@@ -1060,22 +1060,22 @@ var Oi = "DismissableLayer", tn = "dismissableLayer.update", ki = "dismissableLa
|
|
|
1060
1060
|
}, [f, p, n, l]), c.useEffect(() => () => {
|
|
1061
1061
|
f && (l.layers.delete(f), l.layersWithOutsidePointerEventsDisabled.delete(f), wr());
|
|
1062
1062
|
}, [f, l]), c.useEffect(() => {
|
|
1063
|
-
const
|
|
1064
|
-
return document.addEventListener(tn,
|
|
1063
|
+
const E = () => h({});
|
|
1064
|
+
return document.addEventListener(tn, E), () => document.removeEventListener(tn, E);
|
|
1065
1065
|
}, []), /* @__PURE__ */ m.jsx(
|
|
1066
1066
|
H.div,
|
|
1067
1067
|
{
|
|
1068
|
-
...
|
|
1068
|
+
...d,
|
|
1069
1069
|
ref: g,
|
|
1070
1070
|
style: {
|
|
1071
1071
|
pointerEvents: w ? C ? "auto" : "none" : void 0,
|
|
1072
1072
|
...e.style
|
|
1073
1073
|
},
|
|
1074
|
-
onFocusCapture: k(e.onFocusCapture,
|
|
1075
|
-
onBlurCapture: k(e.onBlurCapture,
|
|
1074
|
+
onFocusCapture: k(e.onFocusCapture, _.onFocusCapture),
|
|
1075
|
+
onBlurCapture: k(e.onBlurCapture, _.onBlurCapture),
|
|
1076
1076
|
onPointerDownCapture: k(
|
|
1077
1077
|
e.onPointerDownCapture,
|
|
1078
|
-
|
|
1078
|
+
R.onPointerDownCapture
|
|
1079
1079
|
)
|
|
1080
1080
|
}
|
|
1081
1081
|
);
|
|
@@ -1099,7 +1099,7 @@ function Di(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
|
1099
1099
|
return c.useEffect(() => {
|
|
1100
1100
|
const a = (s) => {
|
|
1101
1101
|
if (s.target && !r.current) {
|
|
1102
|
-
let
|
|
1102
|
+
let d = function() {
|
|
1103
1103
|
no(
|
|
1104
1104
|
ki,
|
|
1105
1105
|
n,
|
|
@@ -1108,7 +1108,7 @@ function Di(e, t = globalThis == null ? void 0 : globalThis.document) {
|
|
|
1108
1108
|
);
|
|
1109
1109
|
};
|
|
1110
1110
|
const l = { originalEvent: s };
|
|
1111
|
-
s.pointerType === "touch" ? (t.removeEventListener("click", o.current), o.current =
|
|
1111
|
+
s.pointerType === "touch" ? (t.removeEventListener("click", o.current), o.current = d, t.addEventListener("click", o.current, { once: !0 })) : d();
|
|
1112
1112
|
} else
|
|
1113
1113
|
t.removeEventListener("click", o.current);
|
|
1114
1114
|
r.current = !1;
|
|
@@ -1165,7 +1165,7 @@ var Ut = "focusScope.autoFocusOnMount", Vt = "focusScope.autoFocusOnUnmount", Cr
|
|
|
1165
1165
|
onMountAutoFocus: o,
|
|
1166
1166
|
onUnmountAutoFocus: a,
|
|
1167
1167
|
...i
|
|
1168
|
-
} = e, [s,
|
|
1168
|
+
} = e, [s, d] = c.useState(null), l = ne(o), f = ne(a), u = c.useRef(null), p = K(t, (v) => d(v)), h = c.useRef({
|
|
1169
1169
|
paused: !1,
|
|
1170
1170
|
pause() {
|
|
1171
1171
|
this.paused = !0;
|
|
@@ -1179,15 +1179,15 @@ var Ut = "focusScope.autoFocusOnMount", Vt = "focusScope.autoFocusOnUnmount", Cr
|
|
|
1179
1179
|
let v = function(w) {
|
|
1180
1180
|
if (h.paused || !s) return;
|
|
1181
1181
|
const C = w.target;
|
|
1182
|
-
s.contains(C) ?
|
|
1182
|
+
s.contains(C) ? u.current = C : ve(u.current, { select: !0 });
|
|
1183
1183
|
}, b = function(w) {
|
|
1184
1184
|
if (h.paused || !s) return;
|
|
1185
1185
|
const C = w.relatedTarget;
|
|
1186
|
-
C !== null && (s.contains(C) || ve(
|
|
1186
|
+
C !== null && (s.contains(C) || ve(u.current, { select: !0 }));
|
|
1187
1187
|
}, x = function(w) {
|
|
1188
1188
|
if (document.activeElement === document.body)
|
|
1189
|
-
for (const
|
|
1190
|
-
|
|
1189
|
+
for (const R of w)
|
|
1190
|
+
R.removedNodes.length > 0 && ve(s);
|
|
1191
1191
|
};
|
|
1192
1192
|
document.addEventListener("focusin", v), document.addEventListener("focusout", b);
|
|
1193
1193
|
const S = new MutationObserver(x);
|
|
@@ -1287,7 +1287,7 @@ function _r(e, t) {
|
|
|
1287
1287
|
function Vi(e) {
|
|
1288
1288
|
return e.filter((t) => t.tagName !== "A");
|
|
1289
1289
|
}
|
|
1290
|
-
const Gi = ["top", "right", "bottom", "left"],
|
|
1290
|
+
const Gi = ["top", "right", "bottom", "left"], xe = Math.min, q = Math.max, yt = Math.round, dt = Math.floor, ce = (e) => ({
|
|
1291
1291
|
x: e,
|
|
1292
1292
|
y: e
|
|
1293
1293
|
}), Hi = {
|
|
@@ -1300,7 +1300,7 @@ const Gi = ["top", "right", "bottom", "left"], be = Math.min, q = Math.max, yt =
|
|
|
1300
1300
|
end: "start"
|
|
1301
1301
|
};
|
|
1302
1302
|
function nn(e, t, n) {
|
|
1303
|
-
return q(e,
|
|
1303
|
+
return q(e, xe(t, n));
|
|
1304
1304
|
}
|
|
1305
1305
|
function pe(e, t) {
|
|
1306
1306
|
return typeof e == "function" ? e(t) : e;
|
|
@@ -1398,9 +1398,9 @@ function Tr(e, t, n) {
|
|
|
1398
1398
|
reference: r,
|
|
1399
1399
|
floating: o
|
|
1400
1400
|
} = e;
|
|
1401
|
-
const a = se(t), i = hn(t), s = mn(i),
|
|
1401
|
+
const a = se(t), i = hn(t), s = mn(i), d = me(t), l = a === "y", f = r.x + r.width / 2 - o.width / 2, u = r.y + r.height / 2 - o.height / 2, p = r[s] / 2 - o[s] / 2;
|
|
1402
1402
|
let h;
|
|
1403
|
-
switch (
|
|
1403
|
+
switch (d) {
|
|
1404
1404
|
case "top":
|
|
1405
1405
|
h = {
|
|
1406
1406
|
x: f,
|
|
@@ -1416,13 +1416,13 @@ function Tr(e, t, n) {
|
|
|
1416
1416
|
case "right":
|
|
1417
1417
|
h = {
|
|
1418
1418
|
x: r.x + r.width,
|
|
1419
|
-
y:
|
|
1419
|
+
y: u
|
|
1420
1420
|
};
|
|
1421
1421
|
break;
|
|
1422
1422
|
case "left":
|
|
1423
1423
|
h = {
|
|
1424
1424
|
x: r.x - o.width,
|
|
1425
|
-
y:
|
|
1425
|
+
y: u
|
|
1426
1426
|
};
|
|
1427
1427
|
break;
|
|
1428
1428
|
default:
|
|
@@ -1447,15 +1447,15 @@ const ts = async (e, t, n) => {
|
|
|
1447
1447
|
strategy: o = "absolute",
|
|
1448
1448
|
middleware: a = [],
|
|
1449
1449
|
platform: i
|
|
1450
|
-
} = n, s = a.filter(Boolean),
|
|
1450
|
+
} = n, s = a.filter(Boolean), d = await (i.isRTL == null ? void 0 : i.isRTL(t));
|
|
1451
1451
|
let l = await i.getElementRects({
|
|
1452
1452
|
reference: e,
|
|
1453
1453
|
floating: t,
|
|
1454
1454
|
strategy: o
|
|
1455
1455
|
}), {
|
|
1456
1456
|
x: f,
|
|
1457
|
-
y:
|
|
1458
|
-
} = Tr(l, r,
|
|
1457
|
+
y: u
|
|
1458
|
+
} = Tr(l, r, d), p = r, h = {}, g = 0;
|
|
1459
1459
|
for (let v = 0; v < s.length; v++) {
|
|
1460
1460
|
const {
|
|
1461
1461
|
name: b,
|
|
@@ -1464,10 +1464,10 @@ const ts = async (e, t, n) => {
|
|
|
1464
1464
|
x: S,
|
|
1465
1465
|
y: w,
|
|
1466
1466
|
data: C,
|
|
1467
|
-
reset:
|
|
1467
|
+
reset: R
|
|
1468
1468
|
} = await x({
|
|
1469
1469
|
x: f,
|
|
1470
|
-
y:
|
|
1470
|
+
y: u,
|
|
1471
1471
|
initialPlacement: r,
|
|
1472
1472
|
placement: p,
|
|
1473
1473
|
strategy: o,
|
|
@@ -1479,24 +1479,24 @@ const ts = async (e, t, n) => {
|
|
|
1479
1479
|
floating: t
|
|
1480
1480
|
}
|
|
1481
1481
|
});
|
|
1482
|
-
f = S ?? f,
|
|
1482
|
+
f = S ?? f, u = w ?? u, h = {
|
|
1483
1483
|
...h,
|
|
1484
1484
|
[b]: {
|
|
1485
1485
|
...h[b],
|
|
1486
1486
|
...C
|
|
1487
1487
|
}
|
|
1488
|
-
},
|
|
1488
|
+
}, R && g <= 50 && (g++, typeof R == "object" && (R.placement && (p = R.placement), R.rects && (l = R.rects === !0 ? await i.getElementRects({
|
|
1489
1489
|
reference: e,
|
|
1490
1490
|
floating: t,
|
|
1491
1491
|
strategy: o
|
|
1492
|
-
}) :
|
|
1492
|
+
}) : R.rects), {
|
|
1493
1493
|
x: f,
|
|
1494
|
-
y:
|
|
1495
|
-
} = Tr(l, p,
|
|
1494
|
+
y: u
|
|
1495
|
+
} = Tr(l, p, d)), v = -1);
|
|
1496
1496
|
}
|
|
1497
1497
|
return {
|
|
1498
1498
|
x: f,
|
|
1499
|
-
y:
|
|
1499
|
+
y: u,
|
|
1500
1500
|
placement: p,
|
|
1501
1501
|
strategy: o,
|
|
1502
1502
|
middlewareData: h
|
|
@@ -1511,19 +1511,19 @@ async function Je(e, t) {
|
|
|
1511
1511
|
platform: a,
|
|
1512
1512
|
rects: i,
|
|
1513
1513
|
elements: s,
|
|
1514
|
-
strategy:
|
|
1514
|
+
strategy: d
|
|
1515
1515
|
} = e, {
|
|
1516
1516
|
boundary: l = "clippingAncestors",
|
|
1517
1517
|
rootBoundary: f = "viewport",
|
|
1518
|
-
elementContext:
|
|
1518
|
+
elementContext: u = "floating",
|
|
1519
1519
|
altBoundary: p = !1,
|
|
1520
1520
|
padding: h = 0
|
|
1521
|
-
} = pe(t, e), g = ao(h), b = s[p ?
|
|
1521
|
+
} = pe(t, e), g = ao(h), b = s[p ? u === "floating" ? "reference" : "floating" : u], x = St(await a.getClippingRect({
|
|
1522
1522
|
element: (n = await (a.isElement == null ? void 0 : a.isElement(b))) == null || n ? b : b.contextElement || await (a.getDocumentElement == null ? void 0 : a.getDocumentElement(s.floating)),
|
|
1523
1523
|
boundary: l,
|
|
1524
1524
|
rootBoundary: f,
|
|
1525
|
-
strategy:
|
|
1526
|
-
})), S =
|
|
1525
|
+
strategy: d
|
|
1526
|
+
})), S = u === "floating" ? {
|
|
1527
1527
|
x: r,
|
|
1528
1528
|
y: o,
|
|
1529
1529
|
width: i.floating.width,
|
|
@@ -1534,17 +1534,17 @@ async function Je(e, t) {
|
|
|
1534
1534
|
} : {
|
|
1535
1535
|
x: 1,
|
|
1536
1536
|
y: 1
|
|
1537
|
-
},
|
|
1537
|
+
}, R = St(a.convertOffsetParentRelativeRectToViewportRelativeRect ? await a.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
1538
1538
|
elements: s,
|
|
1539
1539
|
rect: S,
|
|
1540
1540
|
offsetParent: w,
|
|
1541
|
-
strategy:
|
|
1541
|
+
strategy: d
|
|
1542
1542
|
}) : S);
|
|
1543
1543
|
return {
|
|
1544
|
-
top: (x.top -
|
|
1545
|
-
bottom: (
|
|
1546
|
-
left: (x.left -
|
|
1547
|
-
right: (
|
|
1544
|
+
top: (x.top - R.top + g.top) / C.y,
|
|
1545
|
+
bottom: (R.bottom - x.bottom + g.bottom) / C.y,
|
|
1546
|
+
left: (x.left - R.left + g.left) / C.x,
|
|
1547
|
+
right: (R.right - x.right + g.right) / C.x
|
|
1548
1548
|
};
|
|
1549
1549
|
}
|
|
1550
1550
|
const ns = (e) => ({
|
|
@@ -1558,20 +1558,20 @@ const ns = (e) => ({
|
|
|
1558
1558
|
rects: a,
|
|
1559
1559
|
platform: i,
|
|
1560
1560
|
elements: s,
|
|
1561
|
-
middlewareData:
|
|
1561
|
+
middlewareData: d
|
|
1562
1562
|
} = t, {
|
|
1563
1563
|
element: l,
|
|
1564
1564
|
padding: f = 0
|
|
1565
1565
|
} = pe(e, t) || {};
|
|
1566
1566
|
if (l == null)
|
|
1567
1567
|
return {};
|
|
1568
|
-
const
|
|
1568
|
+
const u = ao(f), p = {
|
|
1569
1569
|
x: n,
|
|
1570
1570
|
y: r
|
|
1571
|
-
}, h = hn(o), g = mn(h), v = await i.getDimensions(l), b = h === "y", x = b ? "top" : "left", S = b ? "bottom" : "right", w = b ? "clientHeight" : "clientWidth", C = a.reference[g] + a.reference[h] - p[h] - a.floating[g],
|
|
1572
|
-
let
|
|
1573
|
-
(!
|
|
1574
|
-
const M = C / 2 -
|
|
1571
|
+
}, h = hn(o), g = mn(h), v = await i.getDimensions(l), b = h === "y", x = b ? "top" : "left", S = b ? "bottom" : "right", w = b ? "clientHeight" : "clientWidth", C = a.reference[g] + a.reference[h] - p[h] - a.floating[g], R = p[h] - a.reference[h], _ = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(l));
|
|
1572
|
+
let E = _ ? _[w] : 0;
|
|
1573
|
+
(!E || !await (i.isElement == null ? void 0 : i.isElement(_))) && (E = s.floating[w] || a.floating[g]);
|
|
1574
|
+
const M = C / 2 - R / 2, D = E / 2 - v[g] / 2 - 1, I = xe(u[x], D), G = xe(u[S], D), W = I, $ = E - v[g] - G, L = E / 2 - v[g] / 2 + M, z = nn(W, L, $), j = !d.arrow && Ve(o) != null && L !== z && a.reference[g] / 2 - (L < W ? I : G) - v[g] / 2 < 0, V = j ? L < W ? L - W : L - $ : 0;
|
|
1575
1575
|
return {
|
|
1576
1576
|
[h]: p[h] + V,
|
|
1577
1577
|
data: {
|
|
@@ -1595,11 +1595,11 @@ const ns = (e) => ({
|
|
|
1595
1595
|
middlewareData: a,
|
|
1596
1596
|
rects: i,
|
|
1597
1597
|
initialPlacement: s,
|
|
1598
|
-
platform:
|
|
1598
|
+
platform: d,
|
|
1599
1599
|
elements: l
|
|
1600
1600
|
} = t, {
|
|
1601
1601
|
mainAxis: f = !0,
|
|
1602
|
-
crossAxis:
|
|
1602
|
+
crossAxis: u = !0,
|
|
1603
1603
|
fallbackPlacements: p,
|
|
1604
1604
|
fallbackStrategy: h = "bestFit",
|
|
1605
1605
|
fallbackAxisSideDirection: g = "none",
|
|
@@ -1608,11 +1608,11 @@ const ns = (e) => ({
|
|
|
1608
1608
|
} = pe(e, t);
|
|
1609
1609
|
if ((n = a.arrow) != null && n.alignmentOffset)
|
|
1610
1610
|
return {};
|
|
1611
|
-
const x = me(o), S = se(s), w = me(s) === s, C = await (
|
|
1612
|
-
!p &&
|
|
1613
|
-
const
|
|
1611
|
+
const x = me(o), S = se(s), w = me(s) === s, C = await (d.isRTL == null ? void 0 : d.isRTL(l.floating)), R = p || (w || !v ? [wt(s)] : Xi(s)), _ = g !== "none";
|
|
1612
|
+
!p && _ && R.push(...Qi(s, v, g, C));
|
|
1613
|
+
const E = [s, ...R], M = await Je(t, b), D = [];
|
|
1614
1614
|
let I = ((r = a.flip) == null ? void 0 : r.overflows) || [];
|
|
1615
|
-
if (f && D.push(M[x]),
|
|
1615
|
+
if (f && D.push(M[x]), u) {
|
|
1616
1616
|
const L = Yi(o, i, C);
|
|
1617
1617
|
D.push(M[L[0]], M[L[1]]);
|
|
1618
1618
|
}
|
|
@@ -1621,8 +1621,8 @@ const ns = (e) => ({
|
|
|
1621
1621
|
overflows: D
|
|
1622
1622
|
}], !D.every((L) => L <= 0)) {
|
|
1623
1623
|
var G, W;
|
|
1624
|
-
const L = (((G = a.flip) == null ? void 0 : G.index) || 0) + 1, z =
|
|
1625
|
-
if (z && (!(
|
|
1624
|
+
const L = (((G = a.flip) == null ? void 0 : G.index) || 0) + 1, z = E[L];
|
|
1625
|
+
if (z && (!(u === "alignment" ? S !== se(z) : !1) || // We leave the current main axis only if every placement on that axis
|
|
1626
1626
|
// overflows the main axis.
|
|
1627
1627
|
I.every((O) => se(O.placement) === S ? O.overflows[0] > 0 : !0)))
|
|
1628
1628
|
return {
|
|
@@ -1640,14 +1640,14 @@ const ns = (e) => ({
|
|
|
1640
1640
|
case "bestFit": {
|
|
1641
1641
|
var $;
|
|
1642
1642
|
const V = ($ = I.filter((O) => {
|
|
1643
|
-
if (
|
|
1644
|
-
const
|
|
1645
|
-
return
|
|
1643
|
+
if (_) {
|
|
1644
|
+
const P = se(O.placement);
|
|
1645
|
+
return P === S || // Create a bias to the `y` side axis due to horizontal
|
|
1646
1646
|
// reading directions favoring greater width.
|
|
1647
|
-
|
|
1647
|
+
P === "y";
|
|
1648
1648
|
}
|
|
1649
1649
|
return !0;
|
|
1650
|
-
}).map((O) => [O.placement, O.overflows.filter((
|
|
1650
|
+
}).map((O) => [O.placement, O.overflows.filter((P) => P > 0).reduce((P, B) => P + B, 0)]).sort((O, P) => O[1] - P[1])[0]) == null ? void 0 : $[0];
|
|
1651
1651
|
V && (j = V);
|
|
1652
1652
|
break;
|
|
1653
1653
|
}
|
|
@@ -1724,21 +1724,21 @@ async function as(e, t) {
|
|
|
1724
1724
|
placement: n,
|
|
1725
1725
|
platform: r,
|
|
1726
1726
|
elements: o
|
|
1727
|
-
} = e, a = await (r.isRTL == null ? void 0 : r.isRTL(o.floating)), i = me(n), s = Ve(n),
|
|
1727
|
+
} = e, a = await (r.isRTL == null ? void 0 : r.isRTL(o.floating)), i = me(n), s = Ve(n), d = se(n) === "y", l = io.has(i) ? -1 : 1, f = a && d ? -1 : 1, u = pe(t, e);
|
|
1728
1728
|
let {
|
|
1729
1729
|
mainAxis: p,
|
|
1730
1730
|
crossAxis: h,
|
|
1731
1731
|
alignmentAxis: g
|
|
1732
|
-
} = typeof
|
|
1733
|
-
mainAxis:
|
|
1732
|
+
} = typeof u == "number" ? {
|
|
1733
|
+
mainAxis: u,
|
|
1734
1734
|
crossAxis: 0,
|
|
1735
1735
|
alignmentAxis: null
|
|
1736
1736
|
} : {
|
|
1737
|
-
mainAxis:
|
|
1738
|
-
crossAxis:
|
|
1739
|
-
alignmentAxis:
|
|
1737
|
+
mainAxis: u.mainAxis || 0,
|
|
1738
|
+
crossAxis: u.crossAxis || 0,
|
|
1739
|
+
alignmentAxis: u.alignmentAxis
|
|
1740
1740
|
};
|
|
1741
|
-
return s && typeof g == "number" && (h = s === "end" ? g * -1 : g),
|
|
1741
|
+
return s && typeof g == "number" && (h = s === "end" ? g * -1 : g), d ? {
|
|
1742
1742
|
x: h * f,
|
|
1743
1743
|
y: p * l
|
|
1744
1744
|
} : {
|
|
@@ -1757,12 +1757,12 @@ const is = function(e) {
|
|
|
1757
1757
|
y: a,
|
|
1758
1758
|
placement: i,
|
|
1759
1759
|
middlewareData: s
|
|
1760
|
-
} = t,
|
|
1760
|
+
} = t, d = await as(t, e);
|
|
1761
1761
|
return i === ((n = s.offset) == null ? void 0 : n.placement) && (r = s.arrow) != null && r.alignmentOffset ? {} : {
|
|
1762
|
-
x: o +
|
|
1763
|
-
y: a +
|
|
1762
|
+
x: o + d.x,
|
|
1763
|
+
y: a + d.y,
|
|
1764
1764
|
data: {
|
|
1765
|
-
...
|
|
1765
|
+
...d,
|
|
1766
1766
|
placement: i
|
|
1767
1767
|
}
|
|
1768
1768
|
};
|
|
@@ -1792,24 +1792,24 @@ const is = function(e) {
|
|
|
1792
1792
|
};
|
|
1793
1793
|
}
|
|
1794
1794
|
},
|
|
1795
|
-
...
|
|
1795
|
+
...d
|
|
1796
1796
|
} = pe(e, t), l = {
|
|
1797
1797
|
x: n,
|
|
1798
1798
|
y: r
|
|
1799
|
-
}, f = await Je(t,
|
|
1800
|
-
let h = l[p], g = l[
|
|
1799
|
+
}, f = await Je(t, d), u = se(me(o)), p = pn(u);
|
|
1800
|
+
let h = l[p], g = l[u];
|
|
1801
1801
|
if (a) {
|
|
1802
1802
|
const b = p === "y" ? "top" : "left", x = p === "y" ? "bottom" : "right", S = h + f[b], w = h - f[x];
|
|
1803
1803
|
h = nn(S, h, w);
|
|
1804
1804
|
}
|
|
1805
1805
|
if (i) {
|
|
1806
|
-
const b =
|
|
1806
|
+
const b = u === "y" ? "top" : "left", x = u === "y" ? "bottom" : "right", S = g + f[b], w = g - f[x];
|
|
1807
1807
|
g = nn(S, g, w);
|
|
1808
1808
|
}
|
|
1809
1809
|
const v = s.fn({
|
|
1810
1810
|
...t,
|
|
1811
1811
|
[p]: h,
|
|
1812
|
-
[
|
|
1812
|
+
[u]: g
|
|
1813
1813
|
});
|
|
1814
1814
|
return {
|
|
1815
1815
|
...v,
|
|
@@ -1818,7 +1818,7 @@ const is = function(e) {
|
|
|
1818
1818
|
y: v.y - r,
|
|
1819
1819
|
enabled: {
|
|
1820
1820
|
[p]: a,
|
|
1821
|
-
[
|
|
1821
|
+
[u]: i
|
|
1822
1822
|
}
|
|
1823
1823
|
}
|
|
1824
1824
|
};
|
|
@@ -1836,13 +1836,13 @@ const is = function(e) {
|
|
|
1836
1836
|
middlewareData: i
|
|
1837
1837
|
} = t, {
|
|
1838
1838
|
offset: s = 0,
|
|
1839
|
-
mainAxis:
|
|
1839
|
+
mainAxis: d = !0,
|
|
1840
1840
|
crossAxis: l = !0
|
|
1841
1841
|
} = pe(e, t), f = {
|
|
1842
1842
|
x: n,
|
|
1843
1843
|
y: r
|
|
1844
|
-
},
|
|
1845
|
-
let h = f[p], g = f[
|
|
1844
|
+
}, u = se(o), p = pn(u);
|
|
1845
|
+
let h = f[p], g = f[u];
|
|
1846
1846
|
const v = pe(s, t), b = typeof v == "number" ? {
|
|
1847
1847
|
mainAxis: v,
|
|
1848
1848
|
crossAxis: 0
|
|
@@ -1851,18 +1851,18 @@ const is = function(e) {
|
|
|
1851
1851
|
crossAxis: 0,
|
|
1852
1852
|
...v
|
|
1853
1853
|
};
|
|
1854
|
-
if (
|
|
1855
|
-
const w = p === "y" ? "height" : "width", C = a.reference[p] - a.floating[w] + b.mainAxis,
|
|
1856
|
-
h < C ? h = C : h >
|
|
1854
|
+
if (d) {
|
|
1855
|
+
const w = p === "y" ? "height" : "width", C = a.reference[p] - a.floating[w] + b.mainAxis, R = a.reference[p] + a.reference[w] - b.mainAxis;
|
|
1856
|
+
h < C ? h = C : h > R && (h = R);
|
|
1857
1857
|
}
|
|
1858
1858
|
if (l) {
|
|
1859
1859
|
var x, S;
|
|
1860
|
-
const w = p === "y" ? "width" : "height", C = io.has(me(o)),
|
|
1861
|
-
g <
|
|
1860
|
+
const w = p === "y" ? "width" : "height", C = io.has(me(o)), R = a.reference[u] - a.floating[w] + (C && ((x = i.offset) == null ? void 0 : x[u]) || 0) + (C ? 0 : b.crossAxis), _ = a.reference[u] + a.reference[w] + (C ? 0 : ((S = i.offset) == null ? void 0 : S[u]) || 0) - (C ? b.crossAxis : 0);
|
|
1861
|
+
g < R ? g = R : g > _ && (g = _);
|
|
1862
1862
|
}
|
|
1863
1863
|
return {
|
|
1864
1864
|
[p]: h,
|
|
1865
|
-
[
|
|
1865
|
+
[u]: g
|
|
1866
1866
|
};
|
|
1867
1867
|
}
|
|
1868
1868
|
};
|
|
@@ -1878,25 +1878,25 @@ const is = function(e) {
|
|
|
1878
1878
|
platform: i,
|
|
1879
1879
|
elements: s
|
|
1880
1880
|
} = t, {
|
|
1881
|
-
apply:
|
|
1881
|
+
apply: d = () => {
|
|
1882
1882
|
},
|
|
1883
1883
|
...l
|
|
1884
|
-
} = pe(e, t), f = await Je(t, l),
|
|
1884
|
+
} = pe(e, t), f = await Je(t, l), u = me(o), p = Ve(o), h = se(o) === "y", {
|
|
1885
1885
|
width: g,
|
|
1886
1886
|
height: v
|
|
1887
1887
|
} = a.floating;
|
|
1888
1888
|
let b, x;
|
|
1889
|
-
|
|
1890
|
-
const S = v - f.top - f.bottom, w = g - f.left - f.right, C =
|
|
1891
|
-
let
|
|
1892
|
-
if ((n = t.middlewareData.shift) != null && n.enabled.x && (M = w), (r = t.middlewareData.shift) != null && r.enabled.y && (
|
|
1889
|
+
u === "top" || u === "bottom" ? (b = u, x = p === (await (i.isRTL == null ? void 0 : i.isRTL(s.floating)) ? "start" : "end") ? "left" : "right") : (x = u, b = p === "end" ? "top" : "bottom");
|
|
1890
|
+
const S = v - f.top - f.bottom, w = g - f.left - f.right, C = xe(v - f[b], S), R = xe(g - f[x], w), _ = !t.middlewareData.shift;
|
|
1891
|
+
let E = C, M = R;
|
|
1892
|
+
if ((n = t.middlewareData.shift) != null && n.enabled.x && (M = w), (r = t.middlewareData.shift) != null && r.enabled.y && (E = S), _ && !p) {
|
|
1893
1893
|
const I = q(f.left, 0), G = q(f.right, 0), W = q(f.top, 0), $ = q(f.bottom, 0);
|
|
1894
|
-
h ? M = g - 2 * (I !== 0 || G !== 0 ? I + G : q(f.left, f.right)) :
|
|
1894
|
+
h ? M = g - 2 * (I !== 0 || G !== 0 ? I + G : q(f.left, f.right)) : E = v - 2 * (W !== 0 || $ !== 0 ? W + $ : q(f.top, f.bottom));
|
|
1895
1895
|
}
|
|
1896
|
-
await
|
|
1896
|
+
await d({
|
|
1897
1897
|
...t,
|
|
1898
1898
|
availableWidth: M,
|
|
1899
|
-
availableHeight:
|
|
1899
|
+
availableHeight: E
|
|
1900
1900
|
});
|
|
1901
1901
|
const D = await i.getDimensions(s.floating);
|
|
1902
1902
|
return g !== D.width || v !== D.height ? {
|
|
@@ -1963,13 +1963,13 @@ function vn(e) {
|
|
|
1963
1963
|
return ms.some((r) => n[r] ? n[r] !== "none" : !1) || (n.containerType ? n.containerType !== "normal" : !1) || !t && (n.backdropFilter ? n.backdropFilter !== "none" : !1) || !t && (n.filter ? n.filter !== "none" : !1) || hs.some((r) => (n.willChange || "").includes(r)) || vs.some((r) => (n.contain || "").includes(r));
|
|
1964
1964
|
}
|
|
1965
1965
|
function gs(e) {
|
|
1966
|
-
let t =
|
|
1967
|
-
for (; le(t) &&
|
|
1966
|
+
let t = ye(e);
|
|
1967
|
+
for (; le(t) && !Be(t); ) {
|
|
1968
1968
|
if (vn(t))
|
|
1969
1969
|
return t;
|
|
1970
1970
|
if (Tt(t))
|
|
1971
1971
|
return null;
|
|
1972
|
-
t =
|
|
1972
|
+
t = ye(t);
|
|
1973
1973
|
}
|
|
1974
1974
|
return null;
|
|
1975
1975
|
}
|
|
@@ -1977,7 +1977,7 @@ function gn() {
|
|
|
1977
1977
|
return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
|
|
1978
1978
|
}
|
|
1979
1979
|
const bs = /* @__PURE__ */ new Set(["html", "body", "#document"]);
|
|
1980
|
-
function
|
|
1980
|
+
function Be(e) {
|
|
1981
1981
|
return bs.has(Ge(e));
|
|
1982
1982
|
}
|
|
1983
1983
|
function oe(e) {
|
|
@@ -1992,7 +1992,7 @@ function Mt(e) {
|
|
|
1992
1992
|
scrollTop: e.scrollY
|
|
1993
1993
|
};
|
|
1994
1994
|
}
|
|
1995
|
-
function
|
|
1995
|
+
function ye(e) {
|
|
1996
1996
|
if (Ge(e) === "html")
|
|
1997
1997
|
return e;
|
|
1998
1998
|
const t = (
|
|
@@ -2005,8 +2005,8 @@ function xe(e) {
|
|
|
2005
2005
|
return kr(t) ? t.host : t;
|
|
2006
2006
|
}
|
|
2007
2007
|
function co(e) {
|
|
2008
|
-
const t =
|
|
2009
|
-
return
|
|
2008
|
+
const t = ye(e);
|
|
2009
|
+
return Be(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : le(t) && rt(t) ? t : co(t);
|
|
2010
2010
|
}
|
|
2011
2011
|
function Qe(e, t, n) {
|
|
2012
2012
|
var r;
|
|
@@ -2034,7 +2034,7 @@ function lo(e) {
|
|
|
2034
2034
|
function bn(e) {
|
|
2035
2035
|
return re(e) ? e : e.contextElement;
|
|
2036
2036
|
}
|
|
2037
|
-
function
|
|
2037
|
+
function Fe(e) {
|
|
2038
2038
|
const t = bn(e);
|
|
2039
2039
|
if (!le(t))
|
|
2040
2040
|
return ce(1);
|
|
@@ -2060,31 +2060,31 @@ function uo(e) {
|
|
|
2060
2060
|
function ys(e, t, n) {
|
|
2061
2061
|
return t === void 0 && (t = !1), !n || t && n !== Z(e) ? !1 : t;
|
|
2062
2062
|
}
|
|
2063
|
-
function
|
|
2063
|
+
function Ae(e, t, n, r) {
|
|
2064
2064
|
t === void 0 && (t = !1), n === void 0 && (n = !1);
|
|
2065
2065
|
const o = e.getBoundingClientRect(), a = bn(e);
|
|
2066
2066
|
let i = ce(1);
|
|
2067
|
-
t && (r ? re(r) && (i =
|
|
2067
|
+
t && (r ? re(r) && (i = Fe(r)) : i = Fe(e));
|
|
2068
2068
|
const s = ys(a, n, r) ? uo(a) : ce(0);
|
|
2069
|
-
let
|
|
2069
|
+
let d = (o.left + s.x) / i.x, l = (o.top + s.y) / i.y, f = o.width / i.x, u = o.height / i.y;
|
|
2070
2070
|
if (a) {
|
|
2071
2071
|
const p = Z(a), h = r && re(r) ? Z(r) : r;
|
|
2072
2072
|
let g = p, v = on(g);
|
|
2073
2073
|
for (; v && r && h !== g; ) {
|
|
2074
|
-
const b =
|
|
2075
|
-
|
|
2074
|
+
const b = Fe(v), x = v.getBoundingClientRect(), S = oe(v), w = x.left + (v.clientLeft + parseFloat(S.paddingLeft)) * b.x, C = x.top + (v.clientTop + parseFloat(S.paddingTop)) * b.y;
|
|
2075
|
+
d *= b.x, l *= b.y, f *= b.x, u *= b.y, d += w, l += C, g = Z(v), v = on(g);
|
|
2076
2076
|
}
|
|
2077
2077
|
}
|
|
2078
2078
|
return St({
|
|
2079
2079
|
width: f,
|
|
2080
|
-
height:
|
|
2081
|
-
x:
|
|
2080
|
+
height: u,
|
|
2081
|
+
x: d,
|
|
2082
2082
|
y: l
|
|
2083
2083
|
});
|
|
2084
2084
|
}
|
|
2085
2085
|
function Ot(e, t) {
|
|
2086
2086
|
const n = Mt(e).scrollLeft;
|
|
2087
|
-
return t ? t.left + n :
|
|
2087
|
+
return t ? t.left + n : Ae(de(e)).left + n;
|
|
2088
2088
|
}
|
|
2089
2089
|
function fo(e, t) {
|
|
2090
2090
|
const n = e.getBoundingClientRect(), r = n.left + t.scrollLeft - Ot(e, n), o = n.top + t.scrollTop;
|
|
@@ -2103,21 +2103,21 @@ function ws(e) {
|
|
|
2103
2103
|
const a = o === "fixed", i = de(r), s = t ? Tt(t.floating) : !1;
|
|
2104
2104
|
if (r === i || s && a)
|
|
2105
2105
|
return n;
|
|
2106
|
-
let
|
|
2106
|
+
let d = {
|
|
2107
2107
|
scrollLeft: 0,
|
|
2108
2108
|
scrollTop: 0
|
|
2109
2109
|
}, l = ce(1);
|
|
2110
|
-
const f = ce(0),
|
|
2111
|
-
if ((
|
|
2112
|
-
const h =
|
|
2113
|
-
l =
|
|
2110
|
+
const f = ce(0), u = le(r);
|
|
2111
|
+
if ((u || !u && !a) && ((Ge(r) !== "body" || rt(i)) && (d = Mt(r)), le(r))) {
|
|
2112
|
+
const h = Ae(r);
|
|
2113
|
+
l = Fe(r), f.x = h.x + r.clientLeft, f.y = h.y + r.clientTop;
|
|
2114
2114
|
}
|
|
2115
|
-
const p = i && !
|
|
2115
|
+
const p = i && !u && !a ? fo(i, d) : ce(0);
|
|
2116
2116
|
return {
|
|
2117
2117
|
width: n.width * l.x,
|
|
2118
2118
|
height: n.height * l.y,
|
|
2119
|
-
x: n.x * l.x -
|
|
2120
|
-
y: n.y * l.y -
|
|
2119
|
+
x: n.x * l.x - d.scrollLeft * l.x + f.x + p.x,
|
|
2120
|
+
y: n.y * l.y - d.scrollTop * l.y + f.y + p.y
|
|
2121
2121
|
};
|
|
2122
2122
|
}
|
|
2123
2123
|
function Ss(e) {
|
|
@@ -2137,31 +2137,31 @@ function Cs(e) {
|
|
|
2137
2137
|
const Ir = 25;
|
|
2138
2138
|
function Es(e, t) {
|
|
2139
2139
|
const n = Z(e), r = de(e), o = n.visualViewport;
|
|
2140
|
-
let a = r.clientWidth, i = r.clientHeight, s = 0,
|
|
2140
|
+
let a = r.clientWidth, i = r.clientHeight, s = 0, d = 0;
|
|
2141
2141
|
if (o) {
|
|
2142
2142
|
a = o.width, i = o.height;
|
|
2143
2143
|
const f = gn();
|
|
2144
|
-
(!f || f && t === "fixed") && (s = o.offsetLeft,
|
|
2144
|
+
(!f || f && t === "fixed") && (s = o.offsetLeft, d = o.offsetTop);
|
|
2145
2145
|
}
|
|
2146
2146
|
const l = Ot(r);
|
|
2147
2147
|
if (l <= 0) {
|
|
2148
|
-
const f = r.ownerDocument,
|
|
2148
|
+
const f = r.ownerDocument, u = f.body, p = getComputedStyle(u), h = f.compatMode === "CSS1Compat" && parseFloat(p.marginLeft) + parseFloat(p.marginRight) || 0, g = Math.abs(r.clientWidth - u.clientWidth - h);
|
|
2149
2149
|
g <= Ir && (a -= g);
|
|
2150
2150
|
} else l <= Ir && (a += l);
|
|
2151
2151
|
return {
|
|
2152
2152
|
width: a,
|
|
2153
2153
|
height: i,
|
|
2154
2154
|
x: s,
|
|
2155
|
-
y:
|
|
2155
|
+
y: d
|
|
2156
2156
|
};
|
|
2157
2157
|
}
|
|
2158
2158
|
const Rs = /* @__PURE__ */ new Set(["absolute", "fixed"]);
|
|
2159
2159
|
function _s(e, t) {
|
|
2160
|
-
const n =
|
|
2160
|
+
const n = Ae(e, !0, t === "fixed"), r = n.top + e.clientTop, o = n.left + e.clientLeft, a = le(e) ? Fe(e) : ce(1), i = e.clientWidth * a.x, s = e.clientHeight * a.y, d = o * a.x, l = r * a.y;
|
|
2161
2161
|
return {
|
|
2162
2162
|
width: i,
|
|
2163
2163
|
height: s,
|
|
2164
|
-
x:
|
|
2164
|
+
x: d,
|
|
2165
2165
|
y: l
|
|
2166
2166
|
};
|
|
2167
2167
|
}
|
|
@@ -2185,8 +2185,8 @@ function jr(e, t, n) {
|
|
|
2185
2185
|
return St(r);
|
|
2186
2186
|
}
|
|
2187
2187
|
function po(e, t) {
|
|
2188
|
-
const n =
|
|
2189
|
-
return n === t || !re(n) ||
|
|
2188
|
+
const n = ye(e);
|
|
2189
|
+
return n === t || !re(n) || Be(n) ? !1 : oe(n).position === "fixed" || po(n, t);
|
|
2190
2190
|
}
|
|
2191
2191
|
function Ps(e, t) {
|
|
2192
2192
|
const n = t.get(e);
|
|
@@ -2194,10 +2194,10 @@ function Ps(e, t) {
|
|
|
2194
2194
|
return n;
|
|
2195
2195
|
let r = Qe(e, [], !1).filter((s) => re(s) && Ge(s) !== "body"), o = null;
|
|
2196
2196
|
const a = oe(e).position === "fixed";
|
|
2197
|
-
let i = a ?
|
|
2198
|
-
for (; re(i) &&
|
|
2199
|
-
const s = oe(i),
|
|
2200
|
-
!
|
|
2197
|
+
let i = a ? ye(e) : e;
|
|
2198
|
+
for (; re(i) && !Be(i); ) {
|
|
2199
|
+
const s = oe(i), d = vn(i);
|
|
2200
|
+
!d && s.position === "fixed" && (o = null), (a ? !d && !o : !d && s.position === "static" && !!o && Rs.has(o.position) || rt(i) && !d && po(e, i)) ? r = r.filter((f) => f !== i) : o = s, i = ye(i);
|
|
2201
2201
|
}
|
|
2202
2202
|
return t.set(e, r), r;
|
|
2203
2203
|
}
|
|
@@ -2208,15 +2208,15 @@ function As(e) {
|
|
|
2208
2208
|
rootBoundary: r,
|
|
2209
2209
|
strategy: o
|
|
2210
2210
|
} = e;
|
|
2211
|
-
const i = [...n === "clippingAncestors" ? Tt(t) ? [] : Ps(t, this._c) : [].concat(n), r], s = i[0],
|
|
2212
|
-
const
|
|
2213
|
-
return l.top = q(
|
|
2211
|
+
const i = [...n === "clippingAncestors" ? Tt(t) ? [] : Ps(t, this._c) : [].concat(n), r], s = i[0], d = i.reduce((l, f) => {
|
|
2212
|
+
const u = jr(t, f, o);
|
|
2213
|
+
return l.top = q(u.top, l.top), l.right = xe(u.right, l.right), l.bottom = xe(u.bottom, l.bottom), l.left = q(u.left, l.left), l;
|
|
2214
2214
|
}, jr(t, s, o));
|
|
2215
2215
|
return {
|
|
2216
|
-
width:
|
|
2217
|
-
height:
|
|
2218
|
-
x:
|
|
2219
|
-
y:
|
|
2216
|
+
width: d.right - d.left,
|
|
2217
|
+
height: d.bottom - d.top,
|
|
2218
|
+
x: d.left,
|
|
2219
|
+
y: d.top
|
|
2220
2220
|
};
|
|
2221
2221
|
}
|
|
2222
2222
|
function Ts(e) {
|
|
@@ -2230,24 +2230,24 @@ function Ts(e) {
|
|
|
2230
2230
|
};
|
|
2231
2231
|
}
|
|
2232
2232
|
function Ms(e, t, n) {
|
|
2233
|
-
const r = le(t), o = de(t), a = n === "fixed", i =
|
|
2233
|
+
const r = le(t), o = de(t), a = n === "fixed", i = Ae(e, !0, a, t);
|
|
2234
2234
|
let s = {
|
|
2235
2235
|
scrollLeft: 0,
|
|
2236
2236
|
scrollTop: 0
|
|
2237
2237
|
};
|
|
2238
|
-
const
|
|
2238
|
+
const d = ce(0);
|
|
2239
2239
|
function l() {
|
|
2240
|
-
|
|
2240
|
+
d.x = Ot(o);
|
|
2241
2241
|
}
|
|
2242
2242
|
if (r || !r && !a)
|
|
2243
2243
|
if ((Ge(t) !== "body" || rt(o)) && (s = Mt(t)), r) {
|
|
2244
|
-
const h =
|
|
2245
|
-
|
|
2244
|
+
const h = Ae(t, !0, a, t);
|
|
2245
|
+
d.x = h.x + t.clientLeft, d.y = h.y + t.clientTop;
|
|
2246
2246
|
} else o && l();
|
|
2247
2247
|
a && !r && o && l();
|
|
2248
|
-
const f = o && !r && !a ? fo(o, s) : ce(0),
|
|
2248
|
+
const f = o && !r && !a ? fo(o, s) : ce(0), u = i.left + s.scrollLeft - d.x - f.x, p = i.top + s.scrollTop - d.y - f.y;
|
|
2249
2249
|
return {
|
|
2250
|
-
x:
|
|
2250
|
+
x: u,
|
|
2251
2251
|
y: p,
|
|
2252
2252
|
width: i.width,
|
|
2253
2253
|
height: i.height
|
|
@@ -2269,18 +2269,18 @@ function mo(e, t) {
|
|
|
2269
2269
|
if (Tt(e))
|
|
2270
2270
|
return n;
|
|
2271
2271
|
if (!le(e)) {
|
|
2272
|
-
let o =
|
|
2273
|
-
for (; o &&
|
|
2272
|
+
let o = ye(e);
|
|
2273
|
+
for (; o && !Be(o); ) {
|
|
2274
2274
|
if (re(o) && !Gt(o))
|
|
2275
2275
|
return o;
|
|
2276
|
-
o =
|
|
2276
|
+
o = ye(o);
|
|
2277
2277
|
}
|
|
2278
2278
|
return n;
|
|
2279
2279
|
}
|
|
2280
2280
|
let r = Dr(e, t);
|
|
2281
2281
|
for (; r && fs(r) && Gt(r); )
|
|
2282
2282
|
r = Dr(r, t);
|
|
2283
|
-
return r &&
|
|
2283
|
+
return r && Be(r) && Gt(r) && !vn(r) ? n : r || gs(e) || n;
|
|
2284
2284
|
}
|
|
2285
2285
|
const Os = async function(e) {
|
|
2286
2286
|
const t = this.getOffsetParent || mo, n = this.getDimensions, r = await n(e.floating);
|
|
@@ -2305,7 +2305,7 @@ const Is = {
|
|
|
2305
2305
|
getElementRects: Os,
|
|
2306
2306
|
getClientRects: Ss,
|
|
2307
2307
|
getDimensions: Ts,
|
|
2308
|
-
getScale:
|
|
2308
|
+
getScale: Fe,
|
|
2309
2309
|
isElement: re,
|
|
2310
2310
|
isRTL: ks
|
|
2311
2311
|
};
|
|
@@ -2319,40 +2319,40 @@ function js(e, t) {
|
|
|
2319
2319
|
var s;
|
|
2320
2320
|
clearTimeout(r), (s = n) == null || s.disconnect(), n = null;
|
|
2321
2321
|
}
|
|
2322
|
-
function i(s,
|
|
2323
|
-
s === void 0 && (s = !1),
|
|
2322
|
+
function i(s, d) {
|
|
2323
|
+
s === void 0 && (s = !1), d === void 0 && (d = 1), a();
|
|
2324
2324
|
const l = e.getBoundingClientRect(), {
|
|
2325
2325
|
left: f,
|
|
2326
|
-
top:
|
|
2326
|
+
top: u,
|
|
2327
2327
|
width: p,
|
|
2328
2328
|
height: h
|
|
2329
2329
|
} = l;
|
|
2330
2330
|
if (s || t(), !p || !h)
|
|
2331
2331
|
return;
|
|
2332
|
-
const g = dt(
|
|
2332
|
+
const g = dt(u), v = dt(o.clientWidth - (f + p)), b = dt(o.clientHeight - (u + h)), x = dt(f), w = {
|
|
2333
2333
|
rootMargin: -g + "px " + -v + "px " + -b + "px " + -x + "px",
|
|
2334
|
-
threshold: q(0,
|
|
2334
|
+
threshold: q(0, xe(1, d)) || 1
|
|
2335
2335
|
};
|
|
2336
2336
|
let C = !0;
|
|
2337
|
-
function
|
|
2338
|
-
const
|
|
2339
|
-
if (
|
|
2337
|
+
function R(_) {
|
|
2338
|
+
const E = _[0].intersectionRatio;
|
|
2339
|
+
if (E !== d) {
|
|
2340
2340
|
if (!C)
|
|
2341
2341
|
return i();
|
|
2342
|
-
|
|
2342
|
+
E ? i(!1, E) : r = setTimeout(() => {
|
|
2343
2343
|
i(!1, 1e-7);
|
|
2344
2344
|
}, 1e3);
|
|
2345
2345
|
}
|
|
2346
|
-
|
|
2346
|
+
E === 1 && !ho(l, e.getBoundingClientRect()) && i(), C = !1;
|
|
2347
2347
|
}
|
|
2348
2348
|
try {
|
|
2349
|
-
n = new IntersectionObserver(
|
|
2349
|
+
n = new IntersectionObserver(R, {
|
|
2350
2350
|
...w,
|
|
2351
2351
|
// Handle <iframe>s
|
|
2352
2352
|
root: o.ownerDocument
|
|
2353
2353
|
});
|
|
2354
2354
|
} catch {
|
|
2355
|
-
n = new IntersectionObserver(
|
|
2355
|
+
n = new IntersectionObserver(R, w);
|
|
2356
2356
|
}
|
|
2357
2357
|
n.observe(e);
|
|
2358
2358
|
}
|
|
@@ -2365,14 +2365,14 @@ function Ds(e, t, n, r) {
|
|
|
2365
2365
|
ancestorResize: a = !0,
|
|
2366
2366
|
elementResize: i = typeof ResizeObserver == "function",
|
|
2367
2367
|
layoutShift: s = typeof IntersectionObserver == "function",
|
|
2368
|
-
animationFrame:
|
|
2368
|
+
animationFrame: d = !1
|
|
2369
2369
|
} = r, l = bn(e), f = o || a ? [...l ? Qe(l) : [], ...Qe(t)] : [];
|
|
2370
2370
|
f.forEach((x) => {
|
|
2371
2371
|
o && x.addEventListener("scroll", n, {
|
|
2372
2372
|
passive: !0
|
|
2373
2373
|
}), a && x.addEventListener("resize", n);
|
|
2374
2374
|
});
|
|
2375
|
-
const
|
|
2375
|
+
const u = l && s ? js(l, n) : null;
|
|
2376
2376
|
let p = -1, h = null;
|
|
2377
2377
|
i && (h = new ResizeObserver((x) => {
|
|
2378
2378
|
let [S] = x;
|
|
@@ -2380,18 +2380,18 @@ function Ds(e, t, n, r) {
|
|
|
2380
2380
|
var w;
|
|
2381
2381
|
(w = h) == null || w.observe(t);
|
|
2382
2382
|
})), n();
|
|
2383
|
-
}), l && !
|
|
2384
|
-
let g, v =
|
|
2385
|
-
|
|
2383
|
+
}), l && !d && h.observe(l), h.observe(t));
|
|
2384
|
+
let g, v = d ? Ae(e) : null;
|
|
2385
|
+
d && b();
|
|
2386
2386
|
function b() {
|
|
2387
|
-
const x =
|
|
2387
|
+
const x = Ae(e);
|
|
2388
2388
|
v && !ho(v, x) && n(), v = x, g = requestAnimationFrame(b);
|
|
2389
2389
|
}
|
|
2390
2390
|
return n(), () => {
|
|
2391
2391
|
var x;
|
|
2392
2392
|
f.forEach((S) => {
|
|
2393
2393
|
o && S.removeEventListener("scroll", n), a && S.removeEventListener("resize", n);
|
|
2394
|
-
}),
|
|
2394
|
+
}), u == null || u(), (x = h) == null || x.disconnect(), h = null, d && cancelAnimationFrame(g);
|
|
2395
2395
|
};
|
|
2396
2396
|
}
|
|
2397
2397
|
const Ns = is, Ls = ss, Fs = rs, $s = ls, Bs = os, Nr = ns, Ws = cs, Us = (e, t, n) => {
|
|
@@ -2464,9 +2464,9 @@ function Hs(e) {
|
|
|
2464
2464
|
floating: i
|
|
2465
2465
|
} = {},
|
|
2466
2466
|
transform: s = !0,
|
|
2467
|
-
whileElementsMounted:
|
|
2467
|
+
whileElementsMounted: d,
|
|
2468
2468
|
open: l
|
|
2469
|
-
} = e, [f,
|
|
2469
|
+
} = e, [f, u] = c.useState({
|
|
2470
2470
|
x: 0,
|
|
2471
2471
|
y: 0,
|
|
2472
2472
|
strategy: n,
|
|
@@ -2476,20 +2476,20 @@ function Hs(e) {
|
|
|
2476
2476
|
}), [p, h] = c.useState(r);
|
|
2477
2477
|
Ct(p, r) || h(r);
|
|
2478
2478
|
const [g, v] = c.useState(null), [b, x] = c.useState(null), S = c.useCallback((O) => {
|
|
2479
|
-
O !==
|
|
2479
|
+
O !== _.current && (_.current = O, v(O));
|
|
2480
2480
|
}, []), w = c.useCallback((O) => {
|
|
2481
|
-
O !==
|
|
2482
|
-
}, []), C = a || g,
|
|
2483
|
-
if (!
|
|
2481
|
+
O !== E.current && (E.current = O, x(O));
|
|
2482
|
+
}, []), C = a || g, R = i || b, _ = c.useRef(null), E = c.useRef(null), M = c.useRef(f), D = d != null, I = Ht(d), G = Ht(o), W = Ht(l), $ = c.useCallback(() => {
|
|
2483
|
+
if (!_.current || !E.current)
|
|
2484
2484
|
return;
|
|
2485
2485
|
const O = {
|
|
2486
2486
|
placement: t,
|
|
2487
2487
|
strategy: n,
|
|
2488
2488
|
middleware: p
|
|
2489
2489
|
};
|
|
2490
|
-
G.current && (O.platform = G.current), Us(
|
|
2490
|
+
G.current && (O.platform = G.current), Us(_.current, E.current, O).then((P) => {
|
|
2491
2491
|
const B = {
|
|
2492
|
-
...
|
|
2492
|
+
...P,
|
|
2493
2493
|
// The floating element's position may be recomputed while it's closed
|
|
2494
2494
|
// but still mounted (such as when transitioning out). To ensure
|
|
2495
2495
|
// `isPositioned` will be `false` initially on the next open, avoid
|
|
@@ -2497,12 +2497,12 @@ function Hs(e) {
|
|
|
2497
2497
|
isPositioned: W.current !== !1
|
|
2498
2498
|
};
|
|
2499
2499
|
L.current && !Ct(M.current, B) && (M.current = B, Xr.flushSync(() => {
|
|
2500
|
-
|
|
2500
|
+
u(B);
|
|
2501
2501
|
}));
|
|
2502
2502
|
});
|
|
2503
2503
|
}, [p, t, n, G, W]);
|
|
2504
2504
|
gt(() => {
|
|
2505
|
-
l === !1 && M.current.isPositioned && (M.current.isPositioned = !1,
|
|
2505
|
+
l === !1 && M.current.isPositioned && (M.current.isPositioned = !1, u((O) => ({
|
|
2506
2506
|
...O,
|
|
2507
2507
|
isPositioned: !1
|
|
2508
2508
|
})));
|
|
@@ -2511,21 +2511,21 @@ function Hs(e) {
|
|
|
2511
2511
|
gt(() => (L.current = !0, () => {
|
|
2512
2512
|
L.current = !1;
|
|
2513
2513
|
}), []), gt(() => {
|
|
2514
|
-
if (C && (
|
|
2514
|
+
if (C && (_.current = C), R && (E.current = R), C && R) {
|
|
2515
2515
|
if (I.current)
|
|
2516
|
-
return I.current(C,
|
|
2516
|
+
return I.current(C, R, $);
|
|
2517
2517
|
$();
|
|
2518
2518
|
}
|
|
2519
|
-
}, [C,
|
|
2519
|
+
}, [C, R, $, I, D]);
|
|
2520
2520
|
const z = c.useMemo(() => ({
|
|
2521
|
-
reference:
|
|
2522
|
-
floating:
|
|
2521
|
+
reference: _,
|
|
2522
|
+
floating: E,
|
|
2523
2523
|
setReference: S,
|
|
2524
2524
|
setFloating: w
|
|
2525
2525
|
}), [S, w]), j = c.useMemo(() => ({
|
|
2526
2526
|
reference: C,
|
|
2527
|
-
floating:
|
|
2528
|
-
}), [C,
|
|
2527
|
+
floating: R
|
|
2528
|
+
}), [C, R]), V = c.useMemo(() => {
|
|
2529
2529
|
const O = {
|
|
2530
2530
|
position: n,
|
|
2531
2531
|
left: 0,
|
|
@@ -2533,16 +2533,16 @@ function Hs(e) {
|
|
|
2533
2533
|
};
|
|
2534
2534
|
if (!j.floating)
|
|
2535
2535
|
return O;
|
|
2536
|
-
const
|
|
2536
|
+
const P = Lr(j.floating, f.x), B = Lr(j.floating, f.y);
|
|
2537
2537
|
return s ? {
|
|
2538
2538
|
...O,
|
|
2539
|
-
transform: "translate(" +
|
|
2539
|
+
transform: "translate(" + P + "px, " + B + "px)",
|
|
2540
2540
|
...vo(j.floating) >= 1.5 && {
|
|
2541
2541
|
willChange: "transform"
|
|
2542
2542
|
}
|
|
2543
2543
|
} : {
|
|
2544
2544
|
position: n,
|
|
2545
|
-
left:
|
|
2545
|
+
left: P,
|
|
2546
2546
|
top: B
|
|
2547
2547
|
};
|
|
2548
2548
|
}, [n, s, j.floating, f.x, f.y]);
|
|
@@ -2625,7 +2625,7 @@ function bo(e) {
|
|
|
2625
2625
|
const a = o[0];
|
|
2626
2626
|
let i, s;
|
|
2627
2627
|
if ("borderBoxSize" in a) {
|
|
2628
|
-
const
|
|
2628
|
+
const d = a.borderBoxSize, l = Array.isArray(d) ? d[0] : d;
|
|
2629
2629
|
i = l.inlineSize, s = l.blockSize;
|
|
2630
2630
|
} else
|
|
2631
2631
|
i = e.offsetWidth, s = e.offsetHeight;
|
|
@@ -2636,24 +2636,24 @@ function bo(e) {
|
|
|
2636
2636
|
n(void 0);
|
|
2637
2637
|
}, [e]), t;
|
|
2638
2638
|
}
|
|
2639
|
-
var xn = "Popper", [xo, kt] =
|
|
2639
|
+
var xn = "Popper", [xo, kt] = we(xn), [nc, yo] = xo(xn), wo = (e) => {
|
|
2640
2640
|
const { __scopePopper: t, children: n } = e, [r, o] = c.useState(null);
|
|
2641
2641
|
return /* @__PURE__ */ m.jsx(nc, { scope: t, anchor: r, onAnchorChange: o, children: n });
|
|
2642
2642
|
};
|
|
2643
2643
|
wo.displayName = xn;
|
|
2644
2644
|
var So = "PopperAnchor", Co = c.forwardRef(
|
|
2645
2645
|
(e, t) => {
|
|
2646
|
-
const { __scopePopper: n, virtualRef: r, ...o } = e, a = yo(So, n), i = c.useRef(null), s = K(t, i),
|
|
2646
|
+
const { __scopePopper: n, virtualRef: r, ...o } = e, a = yo(So, n), i = c.useRef(null), s = K(t, i), d = c.useRef(null);
|
|
2647
2647
|
return c.useEffect(() => {
|
|
2648
|
-
const l =
|
|
2649
|
-
|
|
2648
|
+
const l = d.current;
|
|
2649
|
+
d.current = (r == null ? void 0 : r.current) || i.current, l !== d.current && a.onAnchorChange(d.current);
|
|
2650
2650
|
}), r ? null : /* @__PURE__ */ m.jsx(H.div, { ...o, ref: s });
|
|
2651
2651
|
}
|
|
2652
2652
|
);
|
|
2653
2653
|
Co.displayName = So;
|
|
2654
2654
|
var yn = "PopperContent", [rc, oc] = xo(yn), Eo = c.forwardRef(
|
|
2655
2655
|
(e, t) => {
|
|
2656
|
-
var N, J, Y,
|
|
2656
|
+
var N, J, Y, Re, dr, fr;
|
|
2657
2657
|
const {
|
|
2658
2658
|
__scopePopper: n,
|
|
2659
2659
|
side: r = "bottom",
|
|
@@ -2661,15 +2661,15 @@ var yn = "PopperContent", [rc, oc] = xo(yn), Eo = c.forwardRef(
|
|
|
2661
2661
|
align: a = "center",
|
|
2662
2662
|
alignOffset: i = 0,
|
|
2663
2663
|
arrowPadding: s = 0,
|
|
2664
|
-
avoidCollisions:
|
|
2664
|
+
avoidCollisions: d = !0,
|
|
2665
2665
|
collisionBoundary: l = [],
|
|
2666
2666
|
collisionPadding: f = 0,
|
|
2667
|
-
sticky:
|
|
2667
|
+
sticky: u = "partial",
|
|
2668
2668
|
hideWhenDetached: p = !1,
|
|
2669
2669
|
updatePositionStrategy: h = "optimized",
|
|
2670
2670
|
onPlaced: g,
|
|
2671
2671
|
...v
|
|
2672
|
-
} = e, b = yo(yn, n), [x, S] = c.useState(null), w = K(t, (He) => S(He)), [C,
|
|
2672
|
+
} = e, b = yo(yn, n), [x, S] = c.useState(null), w = K(t, (He) => S(He)), [C, R] = c.useState(null), _ = bo(C), E = (_ == null ? void 0 : _.width) ?? 0, M = (_ == null ? void 0 : _.height) ?? 0, D = r + (a !== "center" ? "-" + a : ""), I = typeof f == "number" ? f : { top: 0, right: 0, bottom: 0, left: 0, ...f }, G = Array.isArray(l) ? l : [l], W = G.length > 0, $ = {
|
|
2673
2673
|
padding: I,
|
|
2674
2674
|
boundary: G.filter(ic),
|
|
2675
2675
|
// with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
|
|
@@ -2686,13 +2686,13 @@ var yn = "PopperContent", [rc, oc] = xo(yn), Eo = c.forwardRef(
|
|
|
2686
2686
|
},
|
|
2687
2687
|
middleware: [
|
|
2688
2688
|
Ks({ mainAxis: o + M, alignmentAxis: i }),
|
|
2689
|
-
|
|
2689
|
+
d && Ys({
|
|
2690
2690
|
mainAxis: !0,
|
|
2691
2691
|
crossAxis: !1,
|
|
2692
|
-
limiter:
|
|
2692
|
+
limiter: u === "partial" ? Xs() : void 0,
|
|
2693
2693
|
...$
|
|
2694
2694
|
}),
|
|
2695
|
-
|
|
2695
|
+
d && qs({ ...$ }),
|
|
2696
2696
|
Zs({
|
|
2697
2697
|
...$,
|
|
2698
2698
|
apply: ({ elements: He, rects: pr, availableWidth: ei, availableHeight: ti }) => {
|
|
@@ -2701,10 +2701,10 @@ var yn = "PopperContent", [rc, oc] = xo(yn), Eo = c.forwardRef(
|
|
|
2701
2701
|
}
|
|
2702
2702
|
}),
|
|
2703
2703
|
C && Qs({ element: C, padding: s }),
|
|
2704
|
-
sc({ arrowWidth:
|
|
2704
|
+
sc({ arrowWidth: E, arrowHeight: M }),
|
|
2705
2705
|
p && Js({ strategy: "referenceHidden", ...$ })
|
|
2706
2706
|
]
|
|
2707
|
-
}), [
|
|
2707
|
+
}), [P, B] = Po(j), y = ne(g);
|
|
2708
2708
|
te(() => {
|
|
2709
2709
|
V && (y == null || y());
|
|
2710
2710
|
}, [V, y]);
|
|
@@ -2723,7 +2723,7 @@ var yn = "PopperContent", [rc, oc] = xo(yn), Eo = c.forwardRef(
|
|
|
2723
2723
|
minWidth: "max-content",
|
|
2724
2724
|
zIndex: fe,
|
|
2725
2725
|
"--radix-popper-transform-origin": [
|
|
2726
|
-
(
|
|
2726
|
+
(Re = O.transformOrigin) == null ? void 0 : Re.x,
|
|
2727
2727
|
(dr = O.transformOrigin) == null ? void 0 : dr.y
|
|
2728
2728
|
].join(" "),
|
|
2729
2729
|
// hide the content if using the hide middleware and should be hidden
|
|
@@ -2739,15 +2739,15 @@ var yn = "PopperContent", [rc, oc] = xo(yn), Eo = c.forwardRef(
|
|
|
2739
2739
|
rc,
|
|
2740
2740
|
{
|
|
2741
2741
|
scope: n,
|
|
2742
|
-
placedSide:
|
|
2743
|
-
onArrowChange:
|
|
2742
|
+
placedSide: P,
|
|
2743
|
+
onArrowChange: R,
|
|
2744
2744
|
arrowX: T,
|
|
2745
2745
|
arrowY: F,
|
|
2746
2746
|
shouldHideArrow: U,
|
|
2747
2747
|
children: /* @__PURE__ */ m.jsx(
|
|
2748
2748
|
H.div,
|
|
2749
2749
|
{
|
|
2750
|
-
"data-side":
|
|
2750
|
+
"data-side": P,
|
|
2751
2751
|
"data-align": B,
|
|
2752
2752
|
...v,
|
|
2753
2753
|
ref: w,
|
|
@@ -2825,9 +2825,9 @@ var sc = (e) => ({
|
|
|
2825
2825
|
options: e,
|
|
2826
2826
|
fn(t) {
|
|
2827
2827
|
var b, x, S;
|
|
2828
|
-
const { placement: n, rects: r, middlewareData: o } = t, i = ((b = o.arrow) == null ? void 0 : b.centerOffset) !== 0, s = i ? 0 : e.arrowWidth,
|
|
2828
|
+
const { placement: n, rects: r, middlewareData: o } = t, i = ((b = o.arrow) == null ? void 0 : b.centerOffset) !== 0, s = i ? 0 : e.arrowWidth, d = i ? 0 : e.arrowHeight, [l, f] = Po(n), u = { start: "0%", center: "50%", end: "100%" }[f], p = (((x = o.arrow) == null ? void 0 : x.x) ?? 0) + s / 2, h = (((S = o.arrow) == null ? void 0 : S.y) ?? 0) + d / 2;
|
|
2829
2829
|
let g = "", v = "";
|
|
2830
|
-
return l === "bottom" ? (g = i ?
|
|
2830
|
+
return l === "bottom" ? (g = i ? u : `${p}px`, v = `${-d}px`) : l === "top" ? (g = i ? u : `${p}px`, v = `${r.floating.height + d}px`) : l === "right" ? (g = `${-d}px`, v = i ? u : `${h}px`) : l === "left" && (g = `${r.floating.width + d}px`, v = i ? u : `${h}px`), { data: { x: g, y: v } };
|
|
2831
2831
|
}
|
|
2832
2832
|
});
|
|
2833
2833
|
function Po(e) {
|
|
@@ -2847,7 +2847,7 @@ var lc = function(e) {
|
|
|
2847
2847
|
return null;
|
|
2848
2848
|
var t = Array.isArray(e) ? e[0] : e;
|
|
2849
2849
|
return t.ownerDocument.body;
|
|
2850
|
-
},
|
|
2850
|
+
}, Ie = /* @__PURE__ */ new WeakMap(), ft = /* @__PURE__ */ new WeakMap(), pt = {}, zt = 0, Mo = function(e) {
|
|
2851
2851
|
return e && (e.host || Mo(e.parentNode));
|
|
2852
2852
|
}, uc = function(e, t) {
|
|
2853
2853
|
return t.map(function(n) {
|
|
@@ -2861,28 +2861,28 @@ var lc = function(e) {
|
|
|
2861
2861
|
}, dc = function(e, t, n, r) {
|
|
2862
2862
|
var o = uc(t, Array.isArray(e) ? e : [e]);
|
|
2863
2863
|
pt[n] || (pt[n] = /* @__PURE__ */ new WeakMap());
|
|
2864
|
-
var a = pt[n], i = [], s = /* @__PURE__ */ new Set(),
|
|
2865
|
-
!
|
|
2864
|
+
var a = pt[n], i = [], s = /* @__PURE__ */ new Set(), d = new Set(o), l = function(u) {
|
|
2865
|
+
!u || s.has(u) || (s.add(u), l(u.parentNode));
|
|
2866
2866
|
};
|
|
2867
2867
|
o.forEach(l);
|
|
2868
|
-
var f = function(
|
|
2869
|
-
!
|
|
2868
|
+
var f = function(u) {
|
|
2869
|
+
!u || d.has(u) || Array.prototype.forEach.call(u.children, function(p) {
|
|
2870
2870
|
if (s.has(p))
|
|
2871
2871
|
f(p);
|
|
2872
2872
|
else
|
|
2873
2873
|
try {
|
|
2874
|
-
var h = p.getAttribute(r), g = h !== null && h !== "false", v = (
|
|
2875
|
-
|
|
2874
|
+
var h = p.getAttribute(r), g = h !== null && h !== "false", v = (Ie.get(p) || 0) + 1, b = (a.get(p) || 0) + 1;
|
|
2875
|
+
Ie.set(p, v), a.set(p, b), i.push(p), v === 1 && g && ft.set(p, !0), b === 1 && p.setAttribute(n, "true"), g || p.setAttribute(r, "true");
|
|
2876
2876
|
} catch (x) {
|
|
2877
2877
|
console.error("aria-hidden: cannot operate on ", p, x);
|
|
2878
2878
|
}
|
|
2879
2879
|
});
|
|
2880
2880
|
};
|
|
2881
2881
|
return f(t), s.clear(), zt++, function() {
|
|
2882
|
-
i.forEach(function(
|
|
2883
|
-
var p =
|
|
2884
|
-
|
|
2885
|
-
}), zt--, zt || (
|
|
2882
|
+
i.forEach(function(u) {
|
|
2883
|
+
var p = Ie.get(u) - 1, h = a.get(u) - 1;
|
|
2884
|
+
Ie.set(u, p), a.set(u, h), p || (ft.has(u) || u.removeAttribute(r), ft.delete(u)), h || u.removeAttribute(n);
|
|
2885
|
+
}), zt--, zt || (Ie = /* @__PURE__ */ new WeakMap(), Ie = /* @__PURE__ */ new WeakMap(), ft = /* @__PURE__ */ new WeakMap(), pt = {});
|
|
2886
2886
|
};
|
|
2887
2887
|
}, Oo = function(e, t, n) {
|
|
2888
2888
|
n === void 0 && (n = "data-aria-hidden");
|
|
@@ -2933,19 +2933,19 @@ function cf(e, t, n, r) {
|
|
|
2933
2933
|
function s(f) {
|
|
2934
2934
|
try {
|
|
2935
2935
|
l(r.next(f));
|
|
2936
|
-
} catch (
|
|
2937
|
-
i(
|
|
2936
|
+
} catch (u) {
|
|
2937
|
+
i(u);
|
|
2938
2938
|
}
|
|
2939
2939
|
}
|
|
2940
|
-
function
|
|
2940
|
+
function d(f) {
|
|
2941
2941
|
try {
|
|
2942
2942
|
l(r.throw(f));
|
|
2943
|
-
} catch (
|
|
2944
|
-
i(
|
|
2943
|
+
} catch (u) {
|
|
2944
|
+
i(u);
|
|
2945
2945
|
}
|
|
2946
2946
|
}
|
|
2947
2947
|
function l(f) {
|
|
2948
|
-
f.done ? a(f.value) : o(f.value).then(s,
|
|
2948
|
+
f.done ? a(f.value) : o(f.value).then(s, d);
|
|
2949
2949
|
}
|
|
2950
2950
|
l((r = r.apply(e, t || [])).next());
|
|
2951
2951
|
});
|
|
@@ -2960,10 +2960,10 @@ function lf(e, t) {
|
|
|
2960
2960
|
}), i;
|
|
2961
2961
|
function s(l) {
|
|
2962
2962
|
return function(f) {
|
|
2963
|
-
return
|
|
2963
|
+
return d([l, f]);
|
|
2964
2964
|
};
|
|
2965
2965
|
}
|
|
2966
|
-
function
|
|
2966
|
+
function d(l) {
|
|
2967
2967
|
if (r) throw new TypeError("Generator is already executing.");
|
|
2968
2968
|
for (; i && (i = 0, l[0] && (n = 0)), n; ) try {
|
|
2969
2969
|
if (r = 1, o && (a = l[0] & 2 ? o.return : l[0] ? o.throw || ((a = o.return) && a.call(o), 0) : o.next) && !(a = a.call(o, l[1])).done) return a;
|
|
@@ -3100,11 +3100,11 @@ function xc(e, t) {
|
|
|
3100
3100
|
var s = n;
|
|
3101
3101
|
n = [], s.forEach(a), i = n;
|
|
3102
3102
|
}
|
|
3103
|
-
var
|
|
3103
|
+
var d = function() {
|
|
3104
3104
|
var f = i;
|
|
3105
3105
|
i = [], f.forEach(a);
|
|
3106
3106
|
}, l = function() {
|
|
3107
|
-
return Promise.resolve().then(
|
|
3107
|
+
return Promise.resolve().then(d);
|
|
3108
3108
|
};
|
|
3109
3109
|
l(), n = {
|
|
3110
3110
|
push: function(f) {
|
|
@@ -3142,12 +3142,12 @@ var jo = yc(), Yt = function() {
|
|
|
3142
3142
|
onScrollCapture: Yt,
|
|
3143
3143
|
onWheelCapture: Yt,
|
|
3144
3144
|
onTouchMoveCapture: Yt
|
|
3145
|
-
}), o = r[0], a = r[1], i = e.forwardProps, s = e.children,
|
|
3145
|
+
}), o = r[0], a = r[1], i = e.forwardProps, s = e.children, d = e.className, l = e.removeScrollBar, f = e.enabled, u = e.shards, p = e.sideCar, h = e.noRelative, g = e.noIsolation, v = e.inert, b = e.allowPinchZoom, x = e.as, S = x === void 0 ? "div" : x, w = e.gapMode, C = ko(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noRelative", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), R = p, _ = gc([n, t]), E = ie(ie({}, C), o);
|
|
3146
3146
|
return c.createElement(
|
|
3147
3147
|
c.Fragment,
|
|
3148
3148
|
null,
|
|
3149
|
-
f && c.createElement(
|
|
3150
|
-
i ? c.cloneElement(c.Children.only(s), ie(ie({},
|
|
3149
|
+
f && c.createElement(R, { sideCar: jo, removeScrollBar: l, shards: u, noRelative: h, noIsolation: g, inert: v, setCallbacks: a, allowPinchZoom: !!b, lockRef: n, gapMode: w }),
|
|
3150
|
+
i ? c.cloneElement(c.Children.only(s), ie(ie({}, E), { ref: _ })) : c.createElement(S, ie({}, E, { className: d, ref: _ }), s)
|
|
3151
3151
|
);
|
|
3152
3152
|
});
|
|
3153
3153
|
It.defaultProps = {
|
|
@@ -3223,14 +3223,14 @@ var _c = function() {
|
|
|
3223
3223
|
right: t[2],
|
|
3224
3224
|
gap: Math.max(0, r - n + t[2] - t[0])
|
|
3225
3225
|
};
|
|
3226
|
-
}, Oc = Do(),
|
|
3226
|
+
}, Oc = Do(), $e = "data-scroll-locked", kc = function(e, t, n, r) {
|
|
3227
3227
|
var o = e.left, a = e.top, i = e.right, s = e.gap;
|
|
3228
3228
|
return n === void 0 && (n = "margin"), `
|
|
3229
3229
|
.`.concat(pc, ` {
|
|
3230
3230
|
overflow: hidden `).concat(r, `;
|
|
3231
3231
|
padding-right: `).concat(s, "px ").concat(r, `;
|
|
3232
3232
|
}
|
|
3233
|
-
body[`).concat(
|
|
3233
|
+
body[`).concat($e, `] {
|
|
3234
3234
|
overflow: hidden `).concat(r, `;
|
|
3235
3235
|
overscroll-behavior: contain;
|
|
3236
3236
|
`).concat([
|
|
@@ -3263,18 +3263,18 @@ var _c = function() {
|
|
|
3263
3263
|
margin-right: 0 `).concat(r, `;
|
|
3264
3264
|
}
|
|
3265
3265
|
|
|
3266
|
-
body[`).concat(
|
|
3266
|
+
body[`).concat($e, `] {
|
|
3267
3267
|
`).concat(mc, ": ").concat(s, `px;
|
|
3268
3268
|
}
|
|
3269
3269
|
`);
|
|
3270
3270
|
}, $r = function() {
|
|
3271
|
-
var e = parseInt(document.body.getAttribute(
|
|
3271
|
+
var e = parseInt(document.body.getAttribute($e) || "0", 10);
|
|
3272
3272
|
return isFinite(e) ? e : 0;
|
|
3273
3273
|
}, Ic = function() {
|
|
3274
3274
|
c.useEffect(function() {
|
|
3275
|
-
return document.body.setAttribute(
|
|
3275
|
+
return document.body.setAttribute($e, ($r() + 1).toString()), function() {
|
|
3276
3276
|
var e = $r() - 1;
|
|
3277
|
-
e <= 0 ? document.body.removeAttribute(
|
|
3277
|
+
e <= 0 ? document.body.removeAttribute($e) : document.body.setAttribute($e, e.toString());
|
|
3278
3278
|
};
|
|
3279
3279
|
}, []);
|
|
3280
3280
|
}, jc = function(e) {
|
|
@@ -3296,7 +3296,7 @@ if (typeof window < "u")
|
|
|
3296
3296
|
} catch {
|
|
3297
3297
|
sn = !1;
|
|
3298
3298
|
}
|
|
3299
|
-
var
|
|
3299
|
+
var je = sn ? { passive: !1 } : !1, Dc = function(e) {
|
|
3300
3300
|
return e.tagName === "TEXTAREA";
|
|
3301
3301
|
}, No = function(e, t) {
|
|
3302
3302
|
if (!(e instanceof Element))
|
|
@@ -3345,20 +3345,20 @@ var Ie = sn ? { passive: !1 } : !1, Dc = function(e) {
|
|
|
3345
3345
|
}, Bc = function(e, t) {
|
|
3346
3346
|
return e === "h" && t === "rtl" ? -1 : 1;
|
|
3347
3347
|
}, Wc = function(e, t, n, r, o) {
|
|
3348
|
-
var a = Bc(e, window.getComputedStyle(t).direction), i = a * r, s = n.target,
|
|
3348
|
+
var a = Bc(e, window.getComputedStyle(t).direction), i = a * r, s = n.target, d = t.contains(s), l = !1, f = i > 0, u = 0, p = 0;
|
|
3349
3349
|
do {
|
|
3350
3350
|
if (!s)
|
|
3351
3351
|
break;
|
|
3352
3352
|
var h = Fo(e, s), g = h[0], v = h[1], b = h[2], x = v - b - a * g;
|
|
3353
|
-
(g || x) && Lo(e, s) && (
|
|
3353
|
+
(g || x) && Lo(e, s) && (u += x, p += g);
|
|
3354
3354
|
var S = s.parentNode;
|
|
3355
3355
|
s = S && S.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? S.host : S;
|
|
3356
3356
|
} while (
|
|
3357
3357
|
// portaled content
|
|
3358
|
-
!
|
|
3359
|
-
|
|
3358
|
+
!d && s !== document.body || // self content
|
|
3359
|
+
d && (t.contains(s) || t === s)
|
|
3360
3360
|
);
|
|
3361
|
-
return (f && Math.abs(
|
|
3361
|
+
return (f && Math.abs(u) < 1 || !f && Math.abs(p) < 1) && (l = !0), l;
|
|
3362
3362
|
}, ht = function(e) {
|
|
3363
3363
|
return "changedTouches" in e ? [e.changedTouches[0].clientX, e.changedTouches[0].clientY] : [0, 0];
|
|
3364
3364
|
}, Wr = function(e) {
|
|
@@ -3372,7 +3372,7 @@ var Ie = sn ? { passive: !1 } : !1, Dc = function(e) {
|
|
|
3372
3372
|
.block-interactivity-`.concat(e, ` {pointer-events: none;}
|
|
3373
3373
|
.allow-interactivity-`).concat(e, ` {pointer-events: all;}
|
|
3374
3374
|
`);
|
|
3375
|
-
}, Gc = 0,
|
|
3375
|
+
}, Gc = 0, De = [];
|
|
3376
3376
|
function Hc(e) {
|
|
3377
3377
|
var t = c.useRef([]), n = c.useRef([0, 0]), r = c.useRef(), o = c.useState(Gc++)[0], a = c.useState(Do)[0], i = c.useRef(e);
|
|
3378
3378
|
c.useEffect(function() {
|
|
@@ -3393,31 +3393,31 @@ function Hc(e) {
|
|
|
3393
3393
|
var s = c.useCallback(function(v, b) {
|
|
3394
3394
|
if ("touches" in v && v.touches.length === 2 || v.type === "wheel" && v.ctrlKey)
|
|
3395
3395
|
return !i.current.allowPinchZoom;
|
|
3396
|
-
var x = ht(v), S = n.current, w = "deltaX" in v ? v.deltaX : S[0] - x[0], C = "deltaY" in v ? v.deltaY : S[1] - x[1],
|
|
3397
|
-
if ("touches" in v &&
|
|
3396
|
+
var x = ht(v), S = n.current, w = "deltaX" in v ? v.deltaX : S[0] - x[0], C = "deltaY" in v ? v.deltaY : S[1] - x[1], R, _ = v.target, E = Math.abs(w) > Math.abs(C) ? "h" : "v";
|
|
3397
|
+
if ("touches" in v && E === "h" && _.type === "range")
|
|
3398
3398
|
return !1;
|
|
3399
|
-
var M = Br(
|
|
3399
|
+
var M = Br(E, _);
|
|
3400
3400
|
if (!M)
|
|
3401
3401
|
return !0;
|
|
3402
|
-
if (M ?
|
|
3402
|
+
if (M ? R = E : (R = E === "v" ? "h" : "v", M = Br(E, _)), !M)
|
|
3403
3403
|
return !1;
|
|
3404
|
-
if (!r.current && "changedTouches" in v && (w || C) && (r.current =
|
|
3404
|
+
if (!r.current && "changedTouches" in v && (w || C) && (r.current = R), !R)
|
|
3405
3405
|
return !0;
|
|
3406
|
-
var D = r.current ||
|
|
3406
|
+
var D = r.current || R;
|
|
3407
3407
|
return Wc(D, b, v, D === "h" ? w : C);
|
|
3408
|
-
}, []),
|
|
3408
|
+
}, []), d = c.useCallback(function(v) {
|
|
3409
3409
|
var b = v;
|
|
3410
|
-
if (!(!
|
|
3411
|
-
var x = "deltaY" in b ? Wr(b) : ht(b), S = t.current.filter(function(
|
|
3412
|
-
return
|
|
3410
|
+
if (!(!De.length || De[De.length - 1] !== a)) {
|
|
3411
|
+
var x = "deltaY" in b ? Wr(b) : ht(b), S = t.current.filter(function(R) {
|
|
3412
|
+
return R.name === b.type && (R.target === b.target || b.target === R.shadowParent) && Uc(R.delta, x);
|
|
3413
3413
|
})[0];
|
|
3414
3414
|
if (S && S.should) {
|
|
3415
3415
|
b.cancelable && b.preventDefault();
|
|
3416
3416
|
return;
|
|
3417
3417
|
}
|
|
3418
3418
|
if (!S) {
|
|
3419
|
-
var w = (i.current.shards || []).map(Ur).filter(Boolean).filter(function(
|
|
3420
|
-
return
|
|
3419
|
+
var w = (i.current.shards || []).map(Ur).filter(Boolean).filter(function(R) {
|
|
3420
|
+
return R.contains(b.target);
|
|
3421
3421
|
}), C = w.length > 0 ? s(b, w[0]) : !i.current.noIsolation;
|
|
3422
3422
|
C && b.cancelable && b.preventDefault();
|
|
3423
3423
|
}
|
|
@@ -3431,20 +3431,20 @@ function Hc(e) {
|
|
|
3431
3431
|
}, 1);
|
|
3432
3432
|
}, []), f = c.useCallback(function(v) {
|
|
3433
3433
|
n.current = ht(v), r.current = void 0;
|
|
3434
|
-
}, []),
|
|
3434
|
+
}, []), u = c.useCallback(function(v) {
|
|
3435
3435
|
l(v.type, Wr(v), v.target, s(v, e.lockRef.current));
|
|
3436
3436
|
}, []), p = c.useCallback(function(v) {
|
|
3437
3437
|
l(v.type, ht(v), v.target, s(v, e.lockRef.current));
|
|
3438
3438
|
}, []);
|
|
3439
3439
|
c.useEffect(function() {
|
|
3440
|
-
return
|
|
3441
|
-
onScrollCapture:
|
|
3442
|
-
onWheelCapture:
|
|
3440
|
+
return De.push(a), e.setCallbacks({
|
|
3441
|
+
onScrollCapture: u,
|
|
3442
|
+
onWheelCapture: u,
|
|
3443
3443
|
onTouchMoveCapture: p
|
|
3444
|
-
}), document.addEventListener("wheel",
|
|
3445
|
-
|
|
3444
|
+
}), document.addEventListener("wheel", d, je), document.addEventListener("touchmove", d, je), document.addEventListener("touchstart", f, je), function() {
|
|
3445
|
+
De = De.filter(function(v) {
|
|
3446
3446
|
return v !== a;
|
|
3447
|
-
}), document.removeEventListener("wheel",
|
|
3447
|
+
}), document.removeEventListener("wheel", d, je), document.removeEventListener("touchmove", d, je), document.removeEventListener("touchstart", f, je);
|
|
3448
3448
|
};
|
|
3449
3449
|
}, []);
|
|
3450
3450
|
var h = e.removeScrollBar, g = e.inert;
|
|
@@ -3465,9 +3465,9 @@ var En = c.forwardRef(function(e, t) {
|
|
|
3465
3465
|
return c.createElement(It, ie({}, e, { ref: t, sideCar: Kc }));
|
|
3466
3466
|
});
|
|
3467
3467
|
En.classNames = It.classNames;
|
|
3468
|
-
var jt = "Popover", [$o, Yc] =
|
|
3468
|
+
var jt = "Popover", [$o, Yc] = we(jt, [
|
|
3469
3469
|
kt
|
|
3470
|
-
]), ot = kt(), [Xc,
|
|
3470
|
+
]), ot = kt(), [Xc, Ce] = $o(jt), Rn = (e) => {
|
|
3471
3471
|
const {
|
|
3472
3472
|
__scopePopover: t,
|
|
3473
3473
|
children: n,
|
|
@@ -3475,7 +3475,7 @@ var jt = "Popover", [$o, Yc] = ye(jt, [
|
|
|
3475
3475
|
defaultOpen: o,
|
|
3476
3476
|
onOpenChange: a,
|
|
3477
3477
|
modal: i = !1
|
|
3478
|
-
} = e, s = ot(t),
|
|
3478
|
+
} = e, s = ot(t), d = c.useRef(null), [l, f] = c.useState(!1), [u, p] = Ue({
|
|
3479
3479
|
prop: r,
|
|
3480
3480
|
defaultProp: o ?? !1,
|
|
3481
3481
|
onChange: a,
|
|
@@ -3485,9 +3485,9 @@ var jt = "Popover", [$o, Yc] = ye(jt, [
|
|
|
3485
3485
|
Xc,
|
|
3486
3486
|
{
|
|
3487
3487
|
scope: t,
|
|
3488
|
-
contentId:
|
|
3489
|
-
triggerRef:
|
|
3490
|
-
open:
|
|
3488
|
+
contentId: Pe(),
|
|
3489
|
+
triggerRef: d,
|
|
3490
|
+
open: u,
|
|
3491
3491
|
onOpenChange: p,
|
|
3492
3492
|
onOpenToggle: c.useCallback(() => p((h) => !h), [p]),
|
|
3493
3493
|
hasCustomAnchor: l,
|
|
@@ -3501,14 +3501,14 @@ var jt = "Popover", [$o, Yc] = ye(jt, [
|
|
|
3501
3501
|
Rn.displayName = jt;
|
|
3502
3502
|
var Bo = "PopoverAnchor", _n = c.forwardRef(
|
|
3503
3503
|
(e, t) => {
|
|
3504
|
-
const { __scopePopover: n, ...r } = e, o =
|
|
3504
|
+
const { __scopePopover: n, ...r } = e, o = Ce(Bo, n), a = ot(n), { onCustomAnchorAdd: i, onCustomAnchorRemove: s } = o;
|
|
3505
3505
|
return c.useEffect(() => (i(), () => s()), [i, s]), /* @__PURE__ */ m.jsx(Sn, { ...a, ...r, ref: t });
|
|
3506
3506
|
}
|
|
3507
3507
|
);
|
|
3508
3508
|
_n.displayName = Bo;
|
|
3509
3509
|
var Wo = "PopoverTrigger", Pn = c.forwardRef(
|
|
3510
3510
|
(e, t) => {
|
|
3511
|
-
const { __scopePopover: n, ...r } = e, o =
|
|
3511
|
+
const { __scopePopover: n, ...r } = e, o = Ce(Wo, n), a = ot(n), i = K(t, o.triggerRef), s = /* @__PURE__ */ m.jsx(
|
|
3512
3512
|
H.button,
|
|
3513
3513
|
{
|
|
3514
3514
|
type: "button",
|
|
@@ -3528,20 +3528,20 @@ Pn.displayName = Wo;
|
|
|
3528
3528
|
var An = "PopoverPortal", [qc, Zc] = $o(An, {
|
|
3529
3529
|
forceMount: void 0
|
|
3530
3530
|
}), Tn = (e) => {
|
|
3531
|
-
const { __scopePopover: t, forceMount: n, children: r, container: o } = e, a =
|
|
3532
|
-
return /* @__PURE__ */ m.jsx(qc, { scope: t, forceMount: n, children: /* @__PURE__ */ m.jsx(
|
|
3531
|
+
const { __scopePopover: t, forceMount: n, children: r, container: o } = e, a = Ce(An, t);
|
|
3532
|
+
return /* @__PURE__ */ m.jsx(qc, { scope: t, forceMount: n, children: /* @__PURE__ */ m.jsx(Se, { present: n || a.open, children: /* @__PURE__ */ m.jsx(Cn, { asChild: !0, container: o, children: r }) }) });
|
|
3533
3533
|
};
|
|
3534
3534
|
Tn.displayName = An;
|
|
3535
|
-
var
|
|
3535
|
+
var We = "PopoverContent", Mn = c.forwardRef(
|
|
3536
3536
|
(e, t) => {
|
|
3537
|
-
const n = Zc(
|
|
3538
|
-
return /* @__PURE__ */ m.jsx(
|
|
3537
|
+
const n = Zc(We, e.__scopePopover), { forceMount: r = n.forceMount, ...o } = e, a = Ce(We, e.__scopePopover);
|
|
3538
|
+
return /* @__PURE__ */ m.jsx(Se, { present: r || a.open, children: a.modal ? /* @__PURE__ */ m.jsx(Qc, { ...o, ref: t }) : /* @__PURE__ */ m.jsx(el, { ...o, ref: t }) });
|
|
3539
3539
|
}
|
|
3540
3540
|
);
|
|
3541
|
-
Mn.displayName =
|
|
3541
|
+
Mn.displayName = We;
|
|
3542
3542
|
var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
3543
3543
|
(e, t) => {
|
|
3544
|
-
const n =
|
|
3544
|
+
const n = Ce(We, e.__scopePopover), r = c.useRef(null), o = K(t, r), a = c.useRef(!1);
|
|
3545
3545
|
return c.useEffect(() => {
|
|
3546
3546
|
const i = r.current;
|
|
3547
3547
|
if (i) return Oo(i);
|
|
@@ -3559,7 +3559,7 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3559
3559
|
onPointerDownOutside: k(
|
|
3560
3560
|
e.onPointerDownOutside,
|
|
3561
3561
|
(i) => {
|
|
3562
|
-
const s = i.detail.originalEvent,
|
|
3562
|
+
const s = i.detail.originalEvent, d = s.button === 0 && s.ctrlKey === !0, l = s.button === 2 || d;
|
|
3563
3563
|
a.current = l;
|
|
3564
3564
|
},
|
|
3565
3565
|
{ checkForDefaultPrevented: !1 }
|
|
@@ -3574,7 +3574,7 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3574
3574
|
}
|
|
3575
3575
|
), el = c.forwardRef(
|
|
3576
3576
|
(e, t) => {
|
|
3577
|
-
const n =
|
|
3577
|
+
const n = Ce(We, e.__scopePopover), r = c.useRef(!1), o = c.useRef(!1);
|
|
3578
3578
|
return /* @__PURE__ */ m.jsx(
|
|
3579
3579
|
Uo,
|
|
3580
3580
|
{
|
|
@@ -3587,8 +3587,8 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3587
3587
|
(i = e.onCloseAutoFocus) == null || i.call(e, a), a.defaultPrevented || (r.current || (s = n.triggerRef.current) == null || s.focus(), a.preventDefault()), r.current = !1, o.current = !1;
|
|
3588
3588
|
},
|
|
3589
3589
|
onInteractOutside: (a) => {
|
|
3590
|
-
var
|
|
3591
|
-
(
|
|
3590
|
+
var d, l;
|
|
3591
|
+
(d = e.onInteractOutside) == null || d.call(e, a), a.defaultPrevented || (r.current = !0, a.detail.originalEvent.type === "pointerdown" && (o.current = !0));
|
|
3592
3592
|
const i = a.target;
|
|
3593
3593
|
((l = n.triggerRef.current) == null ? void 0 : l.contains(i)) && a.preventDefault(), a.detail.originalEvent.type === "focusin" && o.current && a.preventDefault();
|
|
3594
3594
|
}
|
|
@@ -3604,11 +3604,11 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3604
3604
|
onCloseAutoFocus: a,
|
|
3605
3605
|
disableOutsidePointerEvents: i,
|
|
3606
3606
|
onEscapeKeyDown: s,
|
|
3607
|
-
onPointerDownOutside:
|
|
3607
|
+
onPointerDownOutside: d,
|
|
3608
3608
|
onFocusOutside: l,
|
|
3609
3609
|
onInteractOutside: f,
|
|
3610
|
-
...
|
|
3611
|
-
} = e, p =
|
|
3610
|
+
...u
|
|
3611
|
+
} = e, p = Ce(We, n), h = ot(n);
|
|
3612
3612
|
return ro(), /* @__PURE__ */ m.jsx(
|
|
3613
3613
|
fn,
|
|
3614
3614
|
{
|
|
@@ -3624,7 +3624,7 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3624
3624
|
disableOutsidePointerEvents: i,
|
|
3625
3625
|
onInteractOutside: f,
|
|
3626
3626
|
onEscapeKeyDown: s,
|
|
3627
|
-
onPointerDownOutside:
|
|
3627
|
+
onPointerDownOutside: d,
|
|
3628
3628
|
onFocusOutside: l,
|
|
3629
3629
|
onDismiss: () => p.onOpenChange(!1),
|
|
3630
3630
|
children: /* @__PURE__ */ m.jsx(
|
|
@@ -3634,10 +3634,10 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3634
3634
|
role: "dialog",
|
|
3635
3635
|
id: p.contentId,
|
|
3636
3636
|
...h,
|
|
3637
|
-
...
|
|
3637
|
+
...u,
|
|
3638
3638
|
ref: t,
|
|
3639
3639
|
style: {
|
|
3640
|
-
...
|
|
3640
|
+
...u.style,
|
|
3641
3641
|
"--radix-popover-content-transform-origin": "var(--radix-popper-transform-origin)",
|
|
3642
3642
|
"--radix-popover-content-available-width": "var(--radix-popper-available-width)",
|
|
3643
3643
|
"--radix-popover-content-available-height": "var(--radix-popper-available-height)",
|
|
@@ -3653,7 +3653,7 @@ var Jc = /* @__PURE__ */ Ze("PopoverContent.RemoveScroll"), Qc = c.forwardRef(
|
|
|
3653
3653
|
}
|
|
3654
3654
|
), Vo = "PopoverClose", On = c.forwardRef(
|
|
3655
3655
|
(e, t) => {
|
|
3656
|
-
const { __scopePopover: n, ...r } = e, o =
|
|
3656
|
+
const { __scopePopover: n, ...r } = e, o = Ce(Vo, n);
|
|
3657
3657
|
return /* @__PURE__ */ m.jsx(
|
|
3658
3658
|
H.button,
|
|
3659
3659
|
{
|
|
@@ -3709,7 +3709,7 @@ const sl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
3709
3709
|
}
|
|
3710
3710
|
) })
|
|
3711
3711
|
);
|
|
3712
|
-
var qt = "rovingFocusGroup.onEntryFocus", pl = { bubbles: !1, cancelable: !0 }, at = "RovingFocusGroup", [cn, Ko, ml] = Jr(at), [hl, Dt] =
|
|
3712
|
+
var qt = "rovingFocusGroup.onEntryFocus", pl = { bubbles: !1, cancelable: !0 }, at = "RovingFocusGroup", [cn, Ko, ml] = Jr(at), [hl, Dt] = we(
|
|
3713
3713
|
at,
|
|
3714
3714
|
[ml]
|
|
3715
3715
|
), [vl, gl] = hl(at), Yo = c.forwardRef(
|
|
@@ -3724,16 +3724,16 @@ var bl = c.forwardRef((e, t) => {
|
|
|
3724
3724
|
dir: a,
|
|
3725
3725
|
currentTabStopId: i,
|
|
3726
3726
|
defaultCurrentTabStopId: s,
|
|
3727
|
-
onCurrentTabStopIdChange:
|
|
3727
|
+
onCurrentTabStopIdChange: d,
|
|
3728
3728
|
onEntryFocus: l,
|
|
3729
3729
|
preventScrollOnEntryFocus: f = !1,
|
|
3730
|
-
...
|
|
3730
|
+
...u
|
|
3731
3731
|
} = e, p = c.useRef(null), h = K(t, p), g = dn(a), [v, b] = Ue({
|
|
3732
3732
|
prop: i,
|
|
3733
3733
|
defaultProp: s ?? null,
|
|
3734
|
-
onChange:
|
|
3734
|
+
onChange: d,
|
|
3735
3735
|
caller: at
|
|
3736
|
-
}), [x, S] = c.useState(!1), w = ne(l), C = Ko(n),
|
|
3736
|
+
}), [x, S] = c.useState(!1), w = ne(l), C = Ko(n), R = c.useRef(!1), [_, E] = c.useState(0);
|
|
3737
3737
|
return c.useEffect(() => {
|
|
3738
3738
|
const M = p.current;
|
|
3739
3739
|
if (M)
|
|
@@ -3752,26 +3752,26 @@ var bl = c.forwardRef((e, t) => {
|
|
|
3752
3752
|
),
|
|
3753
3753
|
onItemShiftTab: c.useCallback(() => S(!0), []),
|
|
3754
3754
|
onFocusableItemAdd: c.useCallback(
|
|
3755
|
-
() =>
|
|
3755
|
+
() => E((M) => M + 1),
|
|
3756
3756
|
[]
|
|
3757
3757
|
),
|
|
3758
3758
|
onFocusableItemRemove: c.useCallback(
|
|
3759
|
-
() =>
|
|
3759
|
+
() => E((M) => M - 1),
|
|
3760
3760
|
[]
|
|
3761
3761
|
),
|
|
3762
3762
|
children: /* @__PURE__ */ m.jsx(
|
|
3763
3763
|
H.div,
|
|
3764
3764
|
{
|
|
3765
|
-
tabIndex: x ||
|
|
3765
|
+
tabIndex: x || _ === 0 ? -1 : 0,
|
|
3766
3766
|
"data-orientation": r,
|
|
3767
|
-
...
|
|
3767
|
+
...u,
|
|
3768
3768
|
ref: h,
|
|
3769
3769
|
style: { outline: "none", ...e.style },
|
|
3770
3770
|
onMouseDown: k(e.onMouseDown, () => {
|
|
3771
|
-
|
|
3771
|
+
R.current = !0;
|
|
3772
3772
|
}),
|
|
3773
3773
|
onFocus: k(e.onFocus, (M) => {
|
|
3774
|
-
const D = !
|
|
3774
|
+
const D = !R.current;
|
|
3775
3775
|
if (M.target === M.currentTarget && D && !x) {
|
|
3776
3776
|
const I = new CustomEvent(qt, pl);
|
|
3777
3777
|
if (M.currentTarget.dispatchEvent(I), !I.defaultPrevented) {
|
|
@@ -3781,7 +3781,7 @@ var bl = c.forwardRef((e, t) => {
|
|
|
3781
3781
|
Zo(z, f);
|
|
3782
3782
|
}
|
|
3783
3783
|
}
|
|
3784
|
-
|
|
3784
|
+
R.current = !1;
|
|
3785
3785
|
}),
|
|
3786
3786
|
onBlur: k(e.onBlur, () => S(!1))
|
|
3787
3787
|
}
|
|
@@ -3797,7 +3797,7 @@ var bl = c.forwardRef((e, t) => {
|
|
|
3797
3797
|
tabStopId: a,
|
|
3798
3798
|
children: i,
|
|
3799
3799
|
...s
|
|
3800
|
-
} = e,
|
|
3800
|
+
} = e, d = Pe(), l = a || d, f = gl(Xo, n), u = f.currentTabStopId === l, p = Ko(n), { onFocusableItemAdd: h, onFocusableItemRemove: g, currentTabStopId: v } = f;
|
|
3801
3801
|
return c.useEffect(() => {
|
|
3802
3802
|
if (r)
|
|
3803
3803
|
return h(), () => g();
|
|
@@ -3811,7 +3811,7 @@ var bl = c.forwardRef((e, t) => {
|
|
|
3811
3811
|
children: /* @__PURE__ */ m.jsx(
|
|
3812
3812
|
H.span,
|
|
3813
3813
|
{
|
|
3814
|
-
tabIndex:
|
|
3814
|
+
tabIndex: u ? 0 : -1,
|
|
3815
3815
|
"data-orientation": f.orientation,
|
|
3816
3816
|
...s,
|
|
3817
3817
|
ref: t,
|
|
@@ -3839,7 +3839,7 @@ var bl = c.forwardRef((e, t) => {
|
|
|
3839
3839
|
setTimeout(() => Zo(w));
|
|
3840
3840
|
}
|
|
3841
3841
|
}),
|
|
3842
|
-
children: typeof i == "function" ? i({ isCurrentTabStop:
|
|
3842
|
+
children: typeof i == "function" ? i({ isCurrentTabStop: u, hasTabStop: v != null }) : i
|
|
3843
3843
|
}
|
|
3844
3844
|
)
|
|
3845
3845
|
}
|
|
@@ -3879,12 +3879,12 @@ var Jo = Yo, Qo = qo, ln = ["Enter", " "], Cl = ["ArrowDown", "PageUp", "Home"],
|
|
|
3879
3879
|
}, _l = {
|
|
3880
3880
|
ltr: ["ArrowLeft"],
|
|
3881
3881
|
rtl: ["ArrowRight"]
|
|
3882
|
-
}, it = "Menu", [et, Pl, Al] = Jr(it), [
|
|
3882
|
+
}, it = "Menu", [et, Pl, Al] = Jr(it), [Te, ta] = we(it, [
|
|
3883
3883
|
Al,
|
|
3884
3884
|
kt,
|
|
3885
3885
|
Dt
|
|
3886
|
-
]), st = kt(), na = Dt(), [ra,
|
|
3887
|
-
const { __scopeMenu: t, open: n = !1, children: r, dir: o, onOpenChange: a, modal: i = !0 } = e, s = st(t), [
|
|
3886
|
+
]), st = kt(), na = Dt(), [ra, Ee] = Te(it), [Tl, ct] = Te(it), oa = (e) => {
|
|
3887
|
+
const { __scopeMenu: t, open: n = !1, children: r, dir: o, onOpenChange: a, modal: i = !0 } = e, s = st(t), [d, l] = c.useState(null), f = c.useRef(!1), u = ne(a), p = dn(o);
|
|
3888
3888
|
return c.useEffect(() => {
|
|
3889
3889
|
const h = () => {
|
|
3890
3890
|
f.current = !0, document.addEventListener("pointerdown", g, { capture: !0, once: !0 }), document.addEventListener("pointermove", g, { capture: !0, once: !0 });
|
|
@@ -3897,14 +3897,14 @@ var Jo = Yo, Qo = qo, ln = ["Enter", " "], Cl = ["ArrowDown", "PageUp", "Home"],
|
|
|
3897
3897
|
{
|
|
3898
3898
|
scope: t,
|
|
3899
3899
|
open: n,
|
|
3900
|
-
onOpenChange:
|
|
3901
|
-
content:
|
|
3900
|
+
onOpenChange: u,
|
|
3901
|
+
content: d,
|
|
3902
3902
|
onContentChange: l,
|
|
3903
3903
|
children: /* @__PURE__ */ m.jsx(
|
|
3904
3904
|
Tl,
|
|
3905
3905
|
{
|
|
3906
3906
|
scope: t,
|
|
3907
|
-
onClose: c.useCallback(() =>
|
|
3907
|
+
onClose: c.useCallback(() => u(!1), [u]),
|
|
3908
3908
|
isUsingKeyboardRef: f,
|
|
3909
3909
|
dir: p,
|
|
3910
3910
|
modal: i,
|
|
@@ -3922,21 +3922,21 @@ var Ml = "MenuAnchor", In = c.forwardRef(
|
|
|
3922
3922
|
}
|
|
3923
3923
|
);
|
|
3924
3924
|
In.displayName = Ml;
|
|
3925
|
-
var jn = "MenuPortal", [Ol, aa] =
|
|
3925
|
+
var jn = "MenuPortal", [Ol, aa] = Te(jn, {
|
|
3926
3926
|
forceMount: void 0
|
|
3927
3927
|
}), ia = (e) => {
|
|
3928
|
-
const { __scopeMenu: t, forceMount: n, children: r, container: o } = e, a =
|
|
3929
|
-
return /* @__PURE__ */ m.jsx(Ol, { scope: t, forceMount: n, children: /* @__PURE__ */ m.jsx(
|
|
3928
|
+
const { __scopeMenu: t, forceMount: n, children: r, container: o } = e, a = Ee(jn, t);
|
|
3929
|
+
return /* @__PURE__ */ m.jsx(Ol, { scope: t, forceMount: n, children: /* @__PURE__ */ m.jsx(Se, { present: n || a.open, children: /* @__PURE__ */ m.jsx(Cn, { asChild: !0, container: o, children: r }) }) });
|
|
3930
3930
|
};
|
|
3931
3931
|
ia.displayName = jn;
|
|
3932
|
-
var Q = "MenuContent", [kl, Dn] =
|
|
3932
|
+
var Q = "MenuContent", [kl, Dn] = Te(Q), sa = c.forwardRef(
|
|
3933
3933
|
(e, t) => {
|
|
3934
|
-
const n = aa(Q, e.__scopeMenu), { forceMount: r = n.forceMount, ...o } = e, a =
|
|
3935
|
-
return /* @__PURE__ */ m.jsx(et.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ m.jsx(
|
|
3934
|
+
const n = aa(Q, e.__scopeMenu), { forceMount: r = n.forceMount, ...o } = e, a = Ee(Q, e.__scopeMenu), i = ct(Q, e.__scopeMenu);
|
|
3935
|
+
return /* @__PURE__ */ m.jsx(et.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ m.jsx(Se, { present: r || a.open, children: /* @__PURE__ */ m.jsx(et.Slot, { scope: e.__scopeMenu, children: i.modal ? /* @__PURE__ */ m.jsx(Il, { ...o, ref: t }) : /* @__PURE__ */ m.jsx(jl, { ...o, ref: t }) }) }) });
|
|
3936
3936
|
}
|
|
3937
3937
|
), Il = c.forwardRef(
|
|
3938
3938
|
(e, t) => {
|
|
3939
|
-
const n =
|
|
3939
|
+
const n = Ee(Q, e.__scopeMenu), r = c.useRef(null), o = K(t, r);
|
|
3940
3940
|
return c.useEffect(() => {
|
|
3941
3941
|
const a = r.current;
|
|
3942
3942
|
if (a) return Oo(a);
|
|
@@ -3958,7 +3958,7 @@ var Q = "MenuContent", [kl, Dn] = Ae(Q), sa = c.forwardRef(
|
|
|
3958
3958
|
);
|
|
3959
3959
|
}
|
|
3960
3960
|
), jl = c.forwardRef((e, t) => {
|
|
3961
|
-
const n =
|
|
3961
|
+
const n = Ee(Q, e.__scopeMenu);
|
|
3962
3962
|
return /* @__PURE__ */ m.jsx(
|
|
3963
3963
|
Nn,
|
|
3964
3964
|
{
|
|
@@ -3979,25 +3979,25 @@ var Q = "MenuContent", [kl, Dn] = Ae(Q), sa = c.forwardRef(
|
|
|
3979
3979
|
onOpenAutoFocus: a,
|
|
3980
3980
|
onCloseAutoFocus: i,
|
|
3981
3981
|
disableOutsidePointerEvents: s,
|
|
3982
|
-
onEntryFocus:
|
|
3982
|
+
onEntryFocus: d,
|
|
3983
3983
|
onEscapeKeyDown: l,
|
|
3984
3984
|
onPointerDownOutside: f,
|
|
3985
|
-
onFocusOutside:
|
|
3985
|
+
onFocusOutside: u,
|
|
3986
3986
|
onInteractOutside: p,
|
|
3987
3987
|
onDismiss: h,
|
|
3988
3988
|
disableOutsideScroll: g,
|
|
3989
3989
|
...v
|
|
3990
|
-
} = e, b =
|
|
3990
|
+
} = e, b = Ee(Q, n), x = ct(Q, n), S = st(n), w = na(n), C = Pl(n), [R, _] = c.useState(null), E = c.useRef(null), M = K(t, E, b.onContentChange), D = c.useRef(0), I = c.useRef(""), G = c.useRef(0), W = c.useRef(null), $ = c.useRef("right"), L = c.useRef(0), z = g ? En : c.Fragment, j = g ? { as: Dl, allowPinchZoom: !0 } : void 0, V = (P) => {
|
|
3991
3991
|
var N, J;
|
|
3992
|
-
const B = I.current +
|
|
3993
|
-
(function Y(
|
|
3994
|
-
I.current =
|
|
3992
|
+
const B = I.current + P, y = C().filter((Y) => !Y.disabled), T = document.activeElement, F = (N = y.find((Y) => Y.ref.current === T)) == null ? void 0 : N.textValue, U = y.map((Y) => Y.textValue), fe = Kl(U, B, F), ee = (J = y.find((Y) => Y.textValue === fe)) == null ? void 0 : J.ref.current;
|
|
3993
|
+
(function Y(Re) {
|
|
3994
|
+
I.current = Re, window.clearTimeout(D.current), Re !== "" && (D.current = window.setTimeout(() => Y(""), 1e3));
|
|
3995
3995
|
})(B), ee && setTimeout(() => ee.focus());
|
|
3996
3996
|
};
|
|
3997
3997
|
c.useEffect(() => () => window.clearTimeout(D.current), []), ro();
|
|
3998
|
-
const O = c.useCallback((
|
|
3998
|
+
const O = c.useCallback((P) => {
|
|
3999
3999
|
var y, T;
|
|
4000
|
-
return $.current === ((y = W.current) == null ? void 0 : y.side) && Xl(
|
|
4000
|
+
return $.current === ((y = W.current) == null ? void 0 : y.side) && Xl(P, (T = W.current) == null ? void 0 : T.area);
|
|
4001
4001
|
}, []);
|
|
4002
4002
|
return /* @__PURE__ */ m.jsx(
|
|
4003
4003
|
kl,
|
|
@@ -4005,36 +4005,36 @@ var Q = "MenuContent", [kl, Dn] = Ae(Q), sa = c.forwardRef(
|
|
|
4005
4005
|
scope: n,
|
|
4006
4006
|
searchRef: I,
|
|
4007
4007
|
onItemEnter: c.useCallback(
|
|
4008
|
-
(
|
|
4009
|
-
O(
|
|
4008
|
+
(P) => {
|
|
4009
|
+
O(P) && P.preventDefault();
|
|
4010
4010
|
},
|
|
4011
4011
|
[O]
|
|
4012
4012
|
),
|
|
4013
4013
|
onItemLeave: c.useCallback(
|
|
4014
|
-
(
|
|
4014
|
+
(P) => {
|
|
4015
4015
|
var B;
|
|
4016
|
-
O(
|
|
4016
|
+
O(P) || ((B = E.current) == null || B.focus(), _(null));
|
|
4017
4017
|
},
|
|
4018
4018
|
[O]
|
|
4019
4019
|
),
|
|
4020
4020
|
onTriggerLeave: c.useCallback(
|
|
4021
|
-
(
|
|
4022
|
-
O(
|
|
4021
|
+
(P) => {
|
|
4022
|
+
O(P) && P.preventDefault();
|
|
4023
4023
|
},
|
|
4024
4024
|
[O]
|
|
4025
4025
|
),
|
|
4026
4026
|
pointerGraceTimerRef: G,
|
|
4027
|
-
onPointerGraceIntentChange: c.useCallback((
|
|
4028
|
-
W.current =
|
|
4027
|
+
onPointerGraceIntentChange: c.useCallback((P) => {
|
|
4028
|
+
W.current = P;
|
|
4029
4029
|
}, []),
|
|
4030
4030
|
children: /* @__PURE__ */ m.jsx(z, { ...j, children: /* @__PURE__ */ m.jsx(
|
|
4031
4031
|
fn,
|
|
4032
4032
|
{
|
|
4033
4033
|
asChild: !0,
|
|
4034
4034
|
trapped: o,
|
|
4035
|
-
onMountAutoFocus: k(a, (
|
|
4035
|
+
onMountAutoFocus: k(a, (P) => {
|
|
4036
4036
|
var B;
|
|
4037
|
-
|
|
4037
|
+
P.preventDefault(), (B = E.current) == null || B.focus({ preventScroll: !0 });
|
|
4038
4038
|
}),
|
|
4039
4039
|
onUnmountAutoFocus: i,
|
|
4040
4040
|
children: /* @__PURE__ */ m.jsx(
|
|
@@ -4044,7 +4044,7 @@ var Q = "MenuContent", [kl, Dn] = Ae(Q), sa = c.forwardRef(
|
|
|
4044
4044
|
disableOutsidePointerEvents: s,
|
|
4045
4045
|
onEscapeKeyDown: l,
|
|
4046
4046
|
onPointerDownOutside: f,
|
|
4047
|
-
onFocusOutside:
|
|
4047
|
+
onFocusOutside: u,
|
|
4048
4048
|
onInteractOutside: p,
|
|
4049
4049
|
onDismiss: h,
|
|
4050
4050
|
children: /* @__PURE__ */ m.jsx(
|
|
@@ -4055,10 +4055,10 @@ var Q = "MenuContent", [kl, Dn] = Ae(Q), sa = c.forwardRef(
|
|
|
4055
4055
|
dir: x.dir,
|
|
4056
4056
|
orientation: "vertical",
|
|
4057
4057
|
loop: r,
|
|
4058
|
-
currentTabStopId:
|
|
4059
|
-
onCurrentTabStopIdChange:
|
|
4060
|
-
onEntryFocus: k(
|
|
4061
|
-
x.isUsingKeyboardRef.current ||
|
|
4058
|
+
currentTabStopId: R,
|
|
4059
|
+
onCurrentTabStopIdChange: _,
|
|
4060
|
+
onEntryFocus: k(d, (P) => {
|
|
4061
|
+
x.isUsingKeyboardRef.current || P.preventDefault();
|
|
4062
4062
|
}),
|
|
4063
4063
|
preventScrollOnEntryFocus: !0,
|
|
4064
4064
|
children: /* @__PURE__ */ m.jsx(
|
|
@@ -4073,25 +4073,25 @@ var Q = "MenuContent", [kl, Dn] = Ae(Q), sa = c.forwardRef(
|
|
|
4073
4073
|
...v,
|
|
4074
4074
|
ref: M,
|
|
4075
4075
|
style: { outline: "none", ...v.style },
|
|
4076
|
-
onKeyDown: k(v.onKeyDown, (
|
|
4077
|
-
const y =
|
|
4078
|
-
y && (
|
|
4079
|
-
const U =
|
|
4080
|
-
if (
|
|
4081
|
-
|
|
4076
|
+
onKeyDown: k(v.onKeyDown, (P) => {
|
|
4077
|
+
const y = P.target.closest("[data-radix-menu-content]") === P.currentTarget, T = P.ctrlKey || P.altKey || P.metaKey, F = P.key.length === 1;
|
|
4078
|
+
y && (P.key === "Tab" && P.preventDefault(), !T && F && V(P.key));
|
|
4079
|
+
const U = E.current;
|
|
4080
|
+
if (P.target !== U || !El.includes(P.key)) return;
|
|
4081
|
+
P.preventDefault();
|
|
4082
4082
|
const ee = C().filter((N) => !N.disabled).map((N) => N.ref.current);
|
|
4083
|
-
ea.includes(
|
|
4083
|
+
ea.includes(P.key) && ee.reverse(), Hl(ee);
|
|
4084
4084
|
}),
|
|
4085
|
-
onBlur: k(e.onBlur, (
|
|
4086
|
-
|
|
4085
|
+
onBlur: k(e.onBlur, (P) => {
|
|
4086
|
+
P.currentTarget.contains(P.target) || (window.clearTimeout(D.current), I.current = "");
|
|
4087
4087
|
}),
|
|
4088
4088
|
onPointerMove: k(
|
|
4089
4089
|
e.onPointerMove,
|
|
4090
|
-
tt((
|
|
4091
|
-
const B =
|
|
4092
|
-
if (
|
|
4093
|
-
const T =
|
|
4094
|
-
$.current = T, L.current =
|
|
4090
|
+
tt((P) => {
|
|
4091
|
+
const B = P.target, y = L.current !== P.clientX;
|
|
4092
|
+
if (P.currentTarget.contains(B) && y) {
|
|
4093
|
+
const T = P.clientX > L.current ? "right" : "left";
|
|
4094
|
+
$.current = T, L.current = P.clientX;
|
|
4095
4095
|
}
|
|
4096
4096
|
})
|
|
4097
4097
|
)
|
|
@@ -4124,31 +4124,31 @@ var Ll = "MenuLabel", ca = c.forwardRef(
|
|
|
4124
4124
|
ca.displayName = Ll;
|
|
4125
4125
|
var Et = "MenuItem", Vr = "menu.itemSelect", Nt = c.forwardRef(
|
|
4126
4126
|
(e, t) => {
|
|
4127
|
-
const { disabled: n = !1, onSelect: r, ...o } = e, a = c.useRef(null), i = ct(Et, e.__scopeMenu), s = Dn(Et, e.__scopeMenu),
|
|
4128
|
-
const
|
|
4129
|
-
if (!n &&
|
|
4127
|
+
const { disabled: n = !1, onSelect: r, ...o } = e, a = c.useRef(null), i = ct(Et, e.__scopeMenu), s = Dn(Et, e.__scopeMenu), d = K(t, a), l = c.useRef(!1), f = () => {
|
|
4128
|
+
const u = a.current;
|
|
4129
|
+
if (!n && u) {
|
|
4130
4130
|
const p = new CustomEvent(Vr, { bubbles: !0, cancelable: !0 });
|
|
4131
|
-
|
|
4131
|
+
u.addEventListener(Vr, (h) => r == null ? void 0 : r(h), { once: !0 }), Qr(u, p), p.defaultPrevented ? l.current = !1 : i.onClose();
|
|
4132
4132
|
}
|
|
4133
4133
|
};
|
|
4134
4134
|
return /* @__PURE__ */ m.jsx(
|
|
4135
4135
|
la,
|
|
4136
4136
|
{
|
|
4137
4137
|
...o,
|
|
4138
|
-
ref:
|
|
4138
|
+
ref: d,
|
|
4139
4139
|
disabled: n,
|
|
4140
4140
|
onClick: k(e.onClick, f),
|
|
4141
|
-
onPointerDown: (
|
|
4141
|
+
onPointerDown: (u) => {
|
|
4142
4142
|
var p;
|
|
4143
|
-
(p = e.onPointerDown) == null || p.call(e,
|
|
4143
|
+
(p = e.onPointerDown) == null || p.call(e, u), l.current = !0;
|
|
4144
4144
|
},
|
|
4145
|
-
onPointerUp: k(e.onPointerUp, (
|
|
4145
|
+
onPointerUp: k(e.onPointerUp, (u) => {
|
|
4146
4146
|
var p;
|
|
4147
|
-
l.current || (p =
|
|
4147
|
+
l.current || (p = u.currentTarget) == null || p.click();
|
|
4148
4148
|
}),
|
|
4149
|
-
onKeyDown: k(e.onKeyDown, (
|
|
4149
|
+
onKeyDown: k(e.onKeyDown, (u) => {
|
|
4150
4150
|
const p = s.searchRef.current !== "";
|
|
4151
|
-
n || p &&
|
|
4151
|
+
n || p && u.key === " " || ln.includes(u.key) && (u.currentTarget.click(), u.preventDefault());
|
|
4152
4152
|
})
|
|
4153
4153
|
}
|
|
4154
4154
|
);
|
|
@@ -4157,9 +4157,9 @@ var Et = "MenuItem", Vr = "menu.itemSelect", Nt = c.forwardRef(
|
|
|
4157
4157
|
Nt.displayName = Et;
|
|
4158
4158
|
var la = c.forwardRef(
|
|
4159
4159
|
(e, t) => {
|
|
4160
|
-
const { __scopeMenu: n, disabled: r = !1, textValue: o, ...a } = e, i = Dn(Et, n), s = na(n),
|
|
4160
|
+
const { __scopeMenu: n, disabled: r = !1, textValue: o, ...a } = e, i = Dn(Et, n), s = na(n), d = c.useRef(null), l = K(t, d), [f, u] = c.useState(!1), [p, h] = c.useState("");
|
|
4161
4161
|
return c.useEffect(() => {
|
|
4162
|
-
const g =
|
|
4162
|
+
const g = d.current;
|
|
4163
4163
|
g && h((g.textContent ?? "").trim());
|
|
4164
4164
|
}, [a.children]), /* @__PURE__ */ m.jsx(
|
|
4165
4165
|
et.ItemSlot,
|
|
@@ -4186,8 +4186,8 @@ var la = c.forwardRef(
|
|
|
4186
4186
|
e.onPointerLeave,
|
|
4187
4187
|
tt((g) => i.onItemLeave(g))
|
|
4188
4188
|
),
|
|
4189
|
-
onFocus: k(e.onFocus, () =>
|
|
4190
|
-
onBlur: k(e.onBlur, () =>
|
|
4189
|
+
onFocus: k(e.onFocus, () => u(!0)),
|
|
4190
|
+
onBlur: k(e.onBlur, () => u(!1))
|
|
4191
4191
|
}
|
|
4192
4192
|
) })
|
|
4193
4193
|
}
|
|
@@ -4214,7 +4214,7 @@ var la = c.forwardRef(
|
|
|
4214
4214
|
}
|
|
4215
4215
|
);
|
|
4216
4216
|
ua.displayName = Fl;
|
|
4217
|
-
var da = "MenuRadioGroup", [$l, Bl] =
|
|
4217
|
+
var da = "MenuRadioGroup", [$l, Bl] = Te(
|
|
4218
4218
|
da,
|
|
4219
4219
|
{ value: void 0, onValueChange: () => {
|
|
4220
4220
|
} }
|
|
@@ -4249,14 +4249,14 @@ var pa = "MenuRadioItem", ma = c.forwardRef(
|
|
|
4249
4249
|
}
|
|
4250
4250
|
);
|
|
4251
4251
|
ma.displayName = pa;
|
|
4252
|
-
var Fn = "MenuItemIndicator", [ha, Wl] =
|
|
4252
|
+
var Fn = "MenuItemIndicator", [ha, Wl] = Te(
|
|
4253
4253
|
Fn,
|
|
4254
4254
|
{ checked: !1 }
|
|
4255
4255
|
), va = c.forwardRef(
|
|
4256
4256
|
(e, t) => {
|
|
4257
4257
|
const { __scopeMenu: n, forceMount: r, ...o } = e, a = Wl(Fn, n);
|
|
4258
4258
|
return /* @__PURE__ */ m.jsx(
|
|
4259
|
-
|
|
4259
|
+
Se,
|
|
4260
4260
|
{
|
|
4261
4261
|
present: r || Rt(a.checked) || a.checked === !0,
|
|
4262
4262
|
children: /* @__PURE__ */ m.jsx(
|
|
@@ -4294,24 +4294,24 @@ var Vl = "MenuArrow", ba = c.forwardRef(
|
|
|
4294
4294
|
}
|
|
4295
4295
|
);
|
|
4296
4296
|
ba.displayName = Vl;
|
|
4297
|
-
var $n = "MenuSub", [Gl, xa] =
|
|
4298
|
-
const { __scopeMenu: t, children: n, open: r = !1, onOpenChange: o } = e, a =
|
|
4299
|
-
return c.useEffect(() => (a.open === !1 &&
|
|
4297
|
+
var $n = "MenuSub", [Gl, xa] = Te($n), ya = (e) => {
|
|
4298
|
+
const { __scopeMenu: t, children: n, open: r = !1, onOpenChange: o } = e, a = Ee($n, t), i = st(t), [s, d] = c.useState(null), [l, f] = c.useState(null), u = ne(o);
|
|
4299
|
+
return c.useEffect(() => (a.open === !1 && u(!1), () => u(!1)), [a.open, u]), /* @__PURE__ */ m.jsx(wn, { ...i, children: /* @__PURE__ */ m.jsx(
|
|
4300
4300
|
ra,
|
|
4301
4301
|
{
|
|
4302
4302
|
scope: t,
|
|
4303
4303
|
open: r,
|
|
4304
|
-
onOpenChange:
|
|
4304
|
+
onOpenChange: u,
|
|
4305
4305
|
content: l,
|
|
4306
4306
|
onContentChange: f,
|
|
4307
4307
|
children: /* @__PURE__ */ m.jsx(
|
|
4308
4308
|
Gl,
|
|
4309
4309
|
{
|
|
4310
4310
|
scope: t,
|
|
4311
|
-
contentId:
|
|
4312
|
-
triggerId:
|
|
4311
|
+
contentId: Pe(),
|
|
4312
|
+
triggerId: Pe(),
|
|
4313
4313
|
trigger: s,
|
|
4314
|
-
onTriggerChange:
|
|
4314
|
+
onTriggerChange: d,
|
|
4315
4315
|
children: n
|
|
4316
4316
|
}
|
|
4317
4317
|
)
|
|
@@ -4321,15 +4321,15 @@ var $n = "MenuSub", [Gl, xa] = Ae($n), ya = (e) => {
|
|
|
4321
4321
|
ya.displayName = $n;
|
|
4322
4322
|
var qe = "MenuSubTrigger", wa = c.forwardRef(
|
|
4323
4323
|
(e, t) => {
|
|
4324
|
-
const n =
|
|
4324
|
+
const n = Ee(qe, e.__scopeMenu), r = ct(qe, e.__scopeMenu), o = xa(qe, e.__scopeMenu), a = Dn(qe, e.__scopeMenu), i = c.useRef(null), { pointerGraceTimerRef: s, onPointerGraceIntentChange: d } = a, l = { __scopeMenu: e.__scopeMenu }, f = c.useCallback(() => {
|
|
4325
4325
|
i.current && window.clearTimeout(i.current), i.current = null;
|
|
4326
4326
|
}, []);
|
|
4327
4327
|
return c.useEffect(() => f, [f]), c.useEffect(() => {
|
|
4328
|
-
const
|
|
4328
|
+
const u = s.current;
|
|
4329
4329
|
return () => {
|
|
4330
|
-
window.clearTimeout(
|
|
4330
|
+
window.clearTimeout(u), d(null);
|
|
4331
4331
|
};
|
|
4332
|
-
}, [s,
|
|
4332
|
+
}, [s, d]), /* @__PURE__ */ m.jsx(In, { asChild: !0, ...l, children: /* @__PURE__ */ m.jsx(
|
|
4333
4333
|
la,
|
|
4334
4334
|
{
|
|
4335
4335
|
id: o.triggerId,
|
|
@@ -4339,21 +4339,21 @@ var qe = "MenuSubTrigger", wa = c.forwardRef(
|
|
|
4339
4339
|
"data-state": Ea(n.open),
|
|
4340
4340
|
...e,
|
|
4341
4341
|
ref: nt(t, o.onTriggerChange),
|
|
4342
|
-
onClick: (
|
|
4342
|
+
onClick: (u) => {
|
|
4343
4343
|
var p;
|
|
4344
|
-
(p = e.onClick) == null || p.call(e,
|
|
4344
|
+
(p = e.onClick) == null || p.call(e, u), !(e.disabled || u.defaultPrevented) && (u.currentTarget.focus(), n.open || n.onOpenChange(!0));
|
|
4345
4345
|
},
|
|
4346
4346
|
onPointerMove: k(
|
|
4347
4347
|
e.onPointerMove,
|
|
4348
|
-
tt((
|
|
4349
|
-
a.onItemEnter(
|
|
4348
|
+
tt((u) => {
|
|
4349
|
+
a.onItemEnter(u), !u.defaultPrevented && !e.disabled && !n.open && !i.current && (a.onPointerGraceIntentChange(null), i.current = window.setTimeout(() => {
|
|
4350
4350
|
n.onOpenChange(!0), f();
|
|
4351
4351
|
}, 100));
|
|
4352
4352
|
})
|
|
4353
4353
|
),
|
|
4354
4354
|
onPointerLeave: k(
|
|
4355
4355
|
e.onPointerLeave,
|
|
4356
|
-
tt((
|
|
4356
|
+
tt((u) => {
|
|
4357
4357
|
var h, g;
|
|
4358
4358
|
f();
|
|
4359
4359
|
const p = (h = n.content) == null ? void 0 : h.getBoundingClientRect();
|
|
@@ -4363,7 +4363,7 @@ var qe = "MenuSubTrigger", wa = c.forwardRef(
|
|
|
4363
4363
|
area: [
|
|
4364
4364
|
// Apply a bleed on clientX to ensure that our exit point is
|
|
4365
4365
|
// consistently within polygon bounds
|
|
4366
|
-
{ x:
|
|
4366
|
+
{ x: u.clientX + x, y: u.clientY },
|
|
4367
4367
|
{ x: S, y: p.top },
|
|
4368
4368
|
{ x: w, y: p.top },
|
|
4369
4369
|
{ x: w, y: p.bottom },
|
|
@@ -4375,15 +4375,15 @@ var qe = "MenuSubTrigger", wa = c.forwardRef(
|
|
|
4375
4375
|
300
|
|
4376
4376
|
);
|
|
4377
4377
|
} else {
|
|
4378
|
-
if (a.onTriggerLeave(
|
|
4378
|
+
if (a.onTriggerLeave(u), u.defaultPrevented) return;
|
|
4379
4379
|
a.onPointerGraceIntentChange(null);
|
|
4380
4380
|
}
|
|
4381
4381
|
})
|
|
4382
4382
|
),
|
|
4383
|
-
onKeyDown: k(e.onKeyDown, (
|
|
4383
|
+
onKeyDown: k(e.onKeyDown, (u) => {
|
|
4384
4384
|
var h;
|
|
4385
4385
|
const p = a.searchRef.current !== "";
|
|
4386
|
-
e.disabled || p &&
|
|
4386
|
+
e.disabled || p && u.key === " " || Rl[r.dir].includes(u.key) && (n.onOpenChange(!0), (h = n.content) == null || h.focus(), u.preventDefault());
|
|
4387
4387
|
})
|
|
4388
4388
|
}
|
|
4389
4389
|
) });
|
|
@@ -4392,8 +4392,8 @@ var qe = "MenuSubTrigger", wa = c.forwardRef(
|
|
|
4392
4392
|
wa.displayName = qe;
|
|
4393
4393
|
var Sa = "MenuSubContent", Ca = c.forwardRef(
|
|
4394
4394
|
(e, t) => {
|
|
4395
|
-
const n = aa(Q, e.__scopeMenu), { forceMount: r = n.forceMount, ...o } = e, a =
|
|
4396
|
-
return /* @__PURE__ */ m.jsx(et.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ m.jsx(
|
|
4395
|
+
const n = aa(Q, e.__scopeMenu), { forceMount: r = n.forceMount, ...o } = e, a = Ee(Q, e.__scopeMenu), i = ct(Q, e.__scopeMenu), s = xa(Sa, e.__scopeMenu), d = c.useRef(null), l = K(t, d);
|
|
4396
|
+
return /* @__PURE__ */ m.jsx(et.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ m.jsx(Se, { present: r || a.open, children: /* @__PURE__ */ m.jsx(et.Slot, { scope: e.__scopeMenu, children: /* @__PURE__ */ m.jsx(
|
|
4397
4397
|
Nn,
|
|
4398
4398
|
{
|
|
4399
4399
|
id: s.contentId,
|
|
@@ -4406,8 +4406,8 @@ var Sa = "MenuSubContent", Ca = c.forwardRef(
|
|
|
4406
4406
|
disableOutsideScroll: !1,
|
|
4407
4407
|
trapFocus: !1,
|
|
4408
4408
|
onOpenAutoFocus: (f) => {
|
|
4409
|
-
var
|
|
4410
|
-
i.isUsingKeyboardRef.current && ((
|
|
4409
|
+
var u;
|
|
4410
|
+
i.isUsingKeyboardRef.current && ((u = d.current) == null || u.focus()), f.preventDefault();
|
|
4411
4411
|
},
|
|
4412
4412
|
onCloseAutoFocus: (f) => f.preventDefault(),
|
|
4413
4413
|
onFocusOutside: k(e.onFocusOutside, (f) => {
|
|
@@ -4418,8 +4418,8 @@ var Sa = "MenuSubContent", Ca = c.forwardRef(
|
|
|
4418
4418
|
}),
|
|
4419
4419
|
onKeyDown: k(e.onKeyDown, (f) => {
|
|
4420
4420
|
var h;
|
|
4421
|
-
const
|
|
4422
|
-
|
|
4421
|
+
const u = f.currentTarget.contains(f.target), p = _l[i.dir].includes(f.key);
|
|
4422
|
+
u && p && (a.onOpenChange(!1), (h = s.trigger) == null || h.focus(), f.preventDefault());
|
|
4423
4423
|
})
|
|
4424
4424
|
}
|
|
4425
4425
|
) }) }) });
|
|
@@ -4447,17 +4447,17 @@ function Kl(e, t, n) {
|
|
|
4447
4447
|
const o = t.length > 1 && Array.from(t).every((l) => l === t[0]) ? t[0] : t, a = n ? e.indexOf(n) : -1;
|
|
4448
4448
|
let i = zl(e, Math.max(a, 0));
|
|
4449
4449
|
o.length === 1 && (i = i.filter((l) => l !== n));
|
|
4450
|
-
const
|
|
4450
|
+
const d = i.find(
|
|
4451
4451
|
(l) => l.toLowerCase().startsWith(o.toLowerCase())
|
|
4452
4452
|
);
|
|
4453
|
-
return
|
|
4453
|
+
return d !== n ? d : void 0;
|
|
4454
4454
|
}
|
|
4455
4455
|
function Yl(e, t) {
|
|
4456
4456
|
const { x: n, y: r } = e;
|
|
4457
4457
|
let o = !1;
|
|
4458
4458
|
for (let a = 0, i = t.length - 1; a < t.length; i = a++) {
|
|
4459
|
-
const s = t[a],
|
|
4460
|
-
f > r != p > r && n < (
|
|
4459
|
+
const s = t[a], d = t[i], l = s.x, f = s.y, u = d.x, p = d.y;
|
|
4460
|
+
f > r != p > r && n < (u - l) * (r - f) / (p - f) + l && (o = !o);
|
|
4461
4461
|
}
|
|
4462
4462
|
return o;
|
|
4463
4463
|
}
|
|
@@ -4469,7 +4469,7 @@ function Xl(e, t) {
|
|
|
4469
4469
|
function tt(e) {
|
|
4470
4470
|
return (t) => t.pointerType === "mouse" ? e(t) : void 0;
|
|
4471
4471
|
}
|
|
4472
|
-
var ql = oa, Zl = In, Jl = ia, Ql = sa, eu = Ln, tu = ca, nu = Nt, ru = ua, ou = fa, au = ma, iu = va, su = ga, cu = ba, lu = ya, uu = wa, du = Ca, Lt = "DropdownMenu", [fu, pu] =
|
|
4472
|
+
var ql = oa, Zl = In, Jl = ia, Ql = sa, eu = Ln, tu = ca, nu = Nt, ru = ua, ou = fa, au = ma, iu = va, su = ga, cu = ba, lu = ya, uu = wa, du = Ca, Lt = "DropdownMenu", [fu, pu] = we(
|
|
4473
4473
|
Lt,
|
|
4474
4474
|
[ta]
|
|
4475
4475
|
), X = ta(), [mu, Ra] = fu(Lt), Wn = (e) => {
|
|
@@ -4481,7 +4481,7 @@ var ql = oa, Zl = In, Jl = ia, Ql = sa, eu = Ln, tu = ca, nu = Nt, ru = ua, ou =
|
|
|
4481
4481
|
defaultOpen: a,
|
|
4482
4482
|
onOpenChange: i,
|
|
4483
4483
|
modal: s = !0
|
|
4484
|
-
} = e,
|
|
4484
|
+
} = e, d = X(t), l = c.useRef(null), [f, u] = Ue({
|
|
4485
4485
|
prop: o,
|
|
4486
4486
|
defaultProp: a ?? !1,
|
|
4487
4487
|
onChange: i,
|
|
@@ -4491,14 +4491,14 @@ var ql = oa, Zl = In, Jl = ia, Ql = sa, eu = Ln, tu = ca, nu = Nt, ru = ua, ou =
|
|
|
4491
4491
|
mu,
|
|
4492
4492
|
{
|
|
4493
4493
|
scope: t,
|
|
4494
|
-
triggerId:
|
|
4494
|
+
triggerId: Pe(),
|
|
4495
4495
|
triggerRef: l,
|
|
4496
|
-
contentId:
|
|
4496
|
+
contentId: Pe(),
|
|
4497
4497
|
open: f,
|
|
4498
|
-
onOpenChange:
|
|
4499
|
-
onOpenToggle: c.useCallback(() =>
|
|
4498
|
+
onOpenChange: u,
|
|
4499
|
+
onOpenToggle: c.useCallback(() => u((p) => !p), [u]),
|
|
4500
4500
|
modal: s,
|
|
4501
|
-
children: /* @__PURE__ */ m.jsx(ql, { ...
|
|
4501
|
+
children: /* @__PURE__ */ m.jsx(ql, { ...d, open: f, onOpenChange: u, dir: r, modal: s, children: n })
|
|
4502
4502
|
}
|
|
4503
4503
|
);
|
|
4504
4504
|
};
|
|
@@ -4547,11 +4547,11 @@ var Pa = "DropdownMenuContent", Gn = c.forwardRef(
|
|
|
4547
4547
|
...r,
|
|
4548
4548
|
ref: t,
|
|
4549
4549
|
onCloseAutoFocus: k(e.onCloseAutoFocus, (s) => {
|
|
4550
|
-
var
|
|
4551
|
-
i.current || (
|
|
4550
|
+
var d;
|
|
4551
|
+
i.current || (d = o.triggerRef.current) == null || d.focus(), i.current = !1, s.preventDefault();
|
|
4552
4552
|
}),
|
|
4553
4553
|
onInteractOutside: k(e.onInteractOutside, (s) => {
|
|
4554
|
-
const
|
|
4554
|
+
const d = s.detail.originalEvent, l = d.button === 0 && d.ctrlKey === !0, f = d.button === 2 || l;
|
|
4555
4555
|
(!o.modal || f) && (i.current = !0);
|
|
4556
4556
|
}),
|
|
4557
4557
|
style: {
|
|
@@ -4621,13 +4621,13 @@ var Eu = "DropdownMenuArrow", Qn = c.forwardRef(
|
|
|
4621
4621
|
);
|
|
4622
4622
|
Qn.displayName = Eu;
|
|
4623
4623
|
var Aa = (e) => {
|
|
4624
|
-
const { __scopeDropdownMenu: t, children: n, open: r, onOpenChange: o, defaultOpen: a } = e, i = X(t), [s,
|
|
4624
|
+
const { __scopeDropdownMenu: t, children: n, open: r, onOpenChange: o, defaultOpen: a } = e, i = X(t), [s, d] = Ue({
|
|
4625
4625
|
prop: r,
|
|
4626
4626
|
defaultProp: a ?? !1,
|
|
4627
4627
|
onChange: o,
|
|
4628
4628
|
caller: "DropdownMenuSub"
|
|
4629
4629
|
});
|
|
4630
|
-
return /* @__PURE__ */ m.jsx(lu, { ...i, open: s, onOpenChange:
|
|
4630
|
+
return /* @__PURE__ */ m.jsx(lu, { ...i, open: s, onOpenChange: d, children: n });
|
|
4631
4631
|
}, Ru = "DropdownMenuSubTrigger", er = c.forwardRef((e, t) => {
|
|
4632
4632
|
const { __scopeDropdownMenu: n, ...r } = e, o = X(n);
|
|
4633
4633
|
return /* @__PURE__ */ m.jsx(uu, { ...o, ...r, ref: t });
|
|
@@ -4699,7 +4699,7 @@ function Ft(e, t) {
|
|
|
4699
4699
|
}
|
|
4700
4700
|
var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
4701
4701
|
var n = e.color, r = n === void 0 ? "currentColor" : n, o = Ft(e, Fu);
|
|
4702
|
-
return
|
|
4702
|
+
return be("svg", Object.assign({
|
|
4703
4703
|
width: "15",
|
|
4704
4704
|
height: "15",
|
|
4705
4705
|
viewBox: "0 0 15 15",
|
|
@@ -4707,7 +4707,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4707
4707
|
xmlns: "http://www.w3.org/2000/svg"
|
|
4708
4708
|
}, o, {
|
|
4709
4709
|
ref: t
|
|
4710
|
-
}),
|
|
4710
|
+
}), be("path", {
|
|
4711
4711
|
d: "M11.4669 3.72684C11.7558 3.91574 11.8369 4.30308 11.648 4.59198L7.39799 11.092C7.29783 11.2452 7.13556 11.3467 6.95402 11.3699C6.77247 11.3931 6.58989 11.3355 6.45446 11.2124L3.70446 8.71241C3.44905 8.48022 3.43023 8.08494 3.66242 7.82953C3.89461 7.57412 4.28989 7.55529 4.5453 7.78749L6.75292 9.79441L10.6018 3.90792C10.7907 3.61902 11.178 3.53795 11.4669 3.72684Z",
|
|
4712
4712
|
fill: r,
|
|
4713
4713
|
fillRule: "evenodd",
|
|
@@ -4715,7 +4715,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4715
4715
|
}));
|
|
4716
4716
|
}), Bu = ["color"], Wu = /* @__PURE__ */ ue(function(e, t) {
|
|
4717
4717
|
var n = e.color, r = n === void 0 ? "currentColor" : n, o = Ft(e, Bu);
|
|
4718
|
-
return
|
|
4718
|
+
return be("svg", Object.assign({
|
|
4719
4719
|
width: "15",
|
|
4720
4720
|
height: "15",
|
|
4721
4721
|
viewBox: "0 0 15 15",
|
|
@@ -4723,7 +4723,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4723
4723
|
xmlns: "http://www.w3.org/2000/svg"
|
|
4724
4724
|
}, o, {
|
|
4725
4725
|
ref: t
|
|
4726
|
-
}),
|
|
4726
|
+
}), be("path", {
|
|
4727
4727
|
d: "M6.1584 3.13508C6.35985 2.94621 6.67627 2.95642 6.86514 3.15788L10.6151 7.15788C10.7954 7.3502 10.7954 7.64949 10.6151 7.84182L6.86514 11.8418C6.67627 12.0433 6.35985 12.0535 6.1584 11.8646C5.95694 11.6757 5.94673 11.3593 6.1356 11.1579L9.565 7.49985L6.1356 3.84182C5.94673 3.64036 5.95694 3.32394 6.1584 3.13508Z",
|
|
4728
4728
|
fill: r,
|
|
4729
4729
|
fillRule: "evenodd",
|
|
@@ -4731,7 +4731,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4731
4731
|
}));
|
|
4732
4732
|
}), Uu = ["color"], uf = /* @__PURE__ */ ue(function(e, t) {
|
|
4733
4733
|
var n = e.color, r = n === void 0 ? "currentColor" : n, o = Ft(e, Uu);
|
|
4734
|
-
return
|
|
4734
|
+
return be("svg", Object.assign({
|
|
4735
4735
|
width: "15",
|
|
4736
4736
|
height: "15",
|
|
4737
4737
|
viewBox: "0 0 15 15",
|
|
@@ -4739,7 +4739,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4739
4739
|
xmlns: "http://www.w3.org/2000/svg"
|
|
4740
4740
|
}, o, {
|
|
4741
4741
|
ref: t
|
|
4742
|
-
}),
|
|
4742
|
+
}), be("path", {
|
|
4743
4743
|
d: "M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",
|
|
4744
4744
|
fill: r,
|
|
4745
4745
|
fillRule: "evenodd",
|
|
@@ -4747,7 +4747,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4747
4747
|
}));
|
|
4748
4748
|
}), Vu = ["color"], Gu = /* @__PURE__ */ ue(function(e, t) {
|
|
4749
4749
|
var n = e.color, r = n === void 0 ? "currentColor" : n, o = Ft(e, Vu);
|
|
4750
|
-
return
|
|
4750
|
+
return be("svg", Object.assign({
|
|
4751
4751
|
width: "15",
|
|
4752
4752
|
height: "15",
|
|
4753
4753
|
viewBox: "0 0 15 15",
|
|
@@ -4755,7 +4755,7 @@ var Fu = ["color"], $u = /* @__PURE__ */ ue(function(e, t) {
|
|
|
4755
4755
|
xmlns: "http://www.w3.org/2000/svg"
|
|
4756
4756
|
}, o, {
|
|
4757
4757
|
ref: t
|
|
4758
|
-
}),
|
|
4758
|
+
}), be("path", {
|
|
4759
4759
|
d: "M9.875 7.5C9.875 8.81168 8.81168 9.875 7.5 9.875C6.18832 9.875 5.125 8.81168 5.125 7.5C5.125 6.18832 6.18832 5.125 7.5 5.125C8.81168 5.125 9.875 6.18832 9.875 7.5Z",
|
|
4760
4760
|
fill: r
|
|
4761
4761
|
}));
|
|
@@ -4887,7 +4887,7 @@ const sd = c.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ m.jsx(
|
|
|
4887
4887
|
}
|
|
4888
4888
|
));
|
|
4889
4889
|
sd.displayName = Qu.displayName;
|
|
4890
|
-
var $t = "Tabs", [cd, ld] =
|
|
4890
|
+
var $t = "Tabs", [cd, ld] = we($t, [
|
|
4891
4891
|
Dt
|
|
4892
4892
|
]), Fa = Dt(), [ud, nr] = cd($t), rr = c.forwardRef(
|
|
4893
4893
|
(e, t) => {
|
|
@@ -4898,9 +4898,9 @@ var $t = "Tabs", [cd, ld] = ye($t, [
|
|
|
4898
4898
|
defaultValue: a,
|
|
4899
4899
|
orientation: i = "horizontal",
|
|
4900
4900
|
dir: s,
|
|
4901
|
-
activationMode:
|
|
4901
|
+
activationMode: d = "automatic",
|
|
4902
4902
|
...l
|
|
4903
|
-
} = e, f = dn(s), [
|
|
4903
|
+
} = e, f = dn(s), [u, p] = Ue({
|
|
4904
4904
|
prop: r,
|
|
4905
4905
|
onChange: o,
|
|
4906
4906
|
defaultProp: a ?? "",
|
|
@@ -4910,12 +4910,12 @@ var $t = "Tabs", [cd, ld] = ye($t, [
|
|
|
4910
4910
|
ud,
|
|
4911
4911
|
{
|
|
4912
4912
|
scope: n,
|
|
4913
|
-
baseId:
|
|
4914
|
-
value:
|
|
4913
|
+
baseId: Pe(),
|
|
4914
|
+
value: u,
|
|
4915
4915
|
onValueChange: p,
|
|
4916
4916
|
orientation: i,
|
|
4917
4917
|
dir: f,
|
|
4918
|
-
activationMode:
|
|
4918
|
+
activationMode: d,
|
|
4919
4919
|
children: /* @__PURE__ */ m.jsx(
|
|
4920
4920
|
H.div,
|
|
4921
4921
|
{
|
|
@@ -4957,7 +4957,7 @@ var $a = "TabsList", or = c.forwardRef(
|
|
|
4957
4957
|
or.displayName = $a;
|
|
4958
4958
|
var Ba = "TabsTrigger", ar = c.forwardRef(
|
|
4959
4959
|
(e, t) => {
|
|
4960
|
-
const { __scopeTabs: n, value: r, disabled: o = !1, ...a } = e, i = nr(Ba, n), s = Fa(n),
|
|
4960
|
+
const { __scopeTabs: n, value: r, disabled: o = !1, ...a } = e, i = nr(Ba, n), s = Fa(n), d = Ua(i.baseId, r), l = Va(i.baseId, r), f = r === i.value;
|
|
4961
4961
|
return /* @__PURE__ */ m.jsx(
|
|
4962
4962
|
Qo,
|
|
4963
4963
|
{
|
|
@@ -4975,18 +4975,18 @@ var Ba = "TabsTrigger", ar = c.forwardRef(
|
|
|
4975
4975
|
"data-state": f ? "active" : "inactive",
|
|
4976
4976
|
"data-disabled": o ? "" : void 0,
|
|
4977
4977
|
disabled: o,
|
|
4978
|
-
id:
|
|
4978
|
+
id: d,
|
|
4979
4979
|
...a,
|
|
4980
4980
|
ref: t,
|
|
4981
|
-
onMouseDown: k(e.onMouseDown, (
|
|
4982
|
-
!o &&
|
|
4981
|
+
onMouseDown: k(e.onMouseDown, (u) => {
|
|
4982
|
+
!o && u.button === 0 && u.ctrlKey === !1 ? i.onValueChange(r) : u.preventDefault();
|
|
4983
4983
|
}),
|
|
4984
|
-
onKeyDown: k(e.onKeyDown, (
|
|
4985
|
-
[" ", "Enter"].includes(
|
|
4984
|
+
onKeyDown: k(e.onKeyDown, (u) => {
|
|
4985
|
+
[" ", "Enter"].includes(u.key) && i.onValueChange(r);
|
|
4986
4986
|
}),
|
|
4987
4987
|
onFocus: k(e.onFocus, () => {
|
|
4988
|
-
const
|
|
4989
|
-
!f && !o &&
|
|
4988
|
+
const u = i.activationMode !== "manual";
|
|
4989
|
+
!f && !o && u && i.onValueChange(r);
|
|
4990
4990
|
})
|
|
4991
4991
|
}
|
|
4992
4992
|
)
|
|
@@ -4997,17 +4997,17 @@ var Ba = "TabsTrigger", ar = c.forwardRef(
|
|
|
4997
4997
|
ar.displayName = Ba;
|
|
4998
4998
|
var Wa = "TabsContent", ir = c.forwardRef(
|
|
4999
4999
|
(e, t) => {
|
|
5000
|
-
const { __scopeTabs: n, value: r, forceMount: o, children: a, ...i } = e, s = nr(Wa, n),
|
|
5000
|
+
const { __scopeTabs: n, value: r, forceMount: o, children: a, ...i } = e, s = nr(Wa, n), d = Ua(s.baseId, r), l = Va(s.baseId, r), f = r === s.value, u = c.useRef(f);
|
|
5001
5001
|
return c.useEffect(() => {
|
|
5002
|
-
const p = requestAnimationFrame(() =>
|
|
5002
|
+
const p = requestAnimationFrame(() => u.current = !1);
|
|
5003
5003
|
return () => cancelAnimationFrame(p);
|
|
5004
|
-
}, []), /* @__PURE__ */ m.jsx(
|
|
5004
|
+
}, []), /* @__PURE__ */ m.jsx(Se, { present: o || f, children: ({ present: p }) => /* @__PURE__ */ m.jsx(
|
|
5005
5005
|
H.div,
|
|
5006
5006
|
{
|
|
5007
5007
|
"data-state": f ? "active" : "inactive",
|
|
5008
5008
|
"data-orientation": s.orientation,
|
|
5009
5009
|
role: "tabpanel",
|
|
5010
|
-
"aria-labelledby":
|
|
5010
|
+
"aria-labelledby": d,
|
|
5011
5011
|
hidden: !p,
|
|
5012
5012
|
id: l,
|
|
5013
5013
|
tabIndex: 0,
|
|
@@ -5015,7 +5015,7 @@ var Wa = "TabsContent", ir = c.forwardRef(
|
|
|
5015
5015
|
ref: t,
|
|
5016
5016
|
style: {
|
|
5017
5017
|
...e.style,
|
|
5018
|
-
animationDuration:
|
|
5018
|
+
animationDuration: u.current ? "0s" : void 0
|
|
5019
5019
|
},
|
|
5020
5020
|
children: p && a
|
|
5021
5021
|
}
|
|
@@ -5051,10 +5051,10 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5051
5051
|
isMine: a = !1,
|
|
5052
5052
|
firstMessage: i = !1,
|
|
5053
5053
|
lastMessage: s = !1,
|
|
5054
|
-
classNames:
|
|
5054
|
+
classNames: d,
|
|
5055
5055
|
...l
|
|
5056
5056
|
}, f) => {
|
|
5057
|
-
const
|
|
5057
|
+
const u = Ne.base, p = Ne.bubbleTail, h = Ne.wrapper, g = Ne.sender, v = Ne.message, b = Ne.timestamp;
|
|
5058
5058
|
return /* @__PURE__ */ m.jsxs(
|
|
5059
5059
|
"div",
|
|
5060
5060
|
{
|
|
@@ -5062,9 +5062,9 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5062
5062
|
id: e,
|
|
5063
5063
|
"data-testid": "message",
|
|
5064
5064
|
className: A(
|
|
5065
|
-
|
|
5065
|
+
u,
|
|
5066
5066
|
a && "bg-info-20 border-info-20",
|
|
5067
|
-
|
|
5067
|
+
d == null ? void 0 : d.base
|
|
5068
5068
|
),
|
|
5069
5069
|
...l,
|
|
5070
5070
|
children: [
|
|
@@ -5073,7 +5073,7 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5073
5073
|
"span",
|
|
5074
5074
|
{
|
|
5075
5075
|
"data-testid": "sender-name",
|
|
5076
|
-
className: A(g,
|
|
5076
|
+
className: A(g, d == null ? void 0 : d.sender),
|
|
5077
5077
|
children: r
|
|
5078
5078
|
}
|
|
5079
5079
|
),
|
|
@@ -5081,7 +5081,7 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5081
5081
|
"span",
|
|
5082
5082
|
{
|
|
5083
5083
|
"data-testid": "message-text",
|
|
5084
|
-
className: A(v,
|
|
5084
|
+
className: A(v, d == null ? void 0 : d.message),
|
|
5085
5085
|
children: t
|
|
5086
5086
|
}
|
|
5087
5087
|
)
|
|
@@ -5091,7 +5091,7 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5091
5091
|
"span",
|
|
5092
5092
|
{
|
|
5093
5093
|
"data-testid": "message-timestamp",
|
|
5094
|
-
className: A(b,
|
|
5094
|
+
className: A(b, d == null ? void 0 : d.timestamp),
|
|
5095
5095
|
children: ai(n, "HH:mm")
|
|
5096
5096
|
}
|
|
5097
5097
|
),
|
|
@@ -5124,7 +5124,7 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5124
5124
|
p,
|
|
5125
5125
|
!a && "-left-3",
|
|
5126
5126
|
a && "-right-3 bg-info-20",
|
|
5127
|
-
|
|
5127
|
+
d == null ? void 0 : d.bubbleTail
|
|
5128
5128
|
)
|
|
5129
5129
|
}
|
|
5130
5130
|
)
|
|
@@ -5134,7 +5134,7 @@ const pf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5134
5134
|
}
|
|
5135
5135
|
);
|
|
5136
5136
|
hd.displayName = "Message";
|
|
5137
|
-
const
|
|
5137
|
+
const Ne = {
|
|
5138
5138
|
base: "relative flex gap-3 bg-gray-40 border border-gray-40 rounded-[10px] px-2.5 py-2 min-h-10 w-max",
|
|
5139
5139
|
bubbleTail: "absolute inline-block w-[34px] h-[17px] bg-gray-40 triangle-up bottom-[-1px]",
|
|
5140
5140
|
wrapper: {
|
|
@@ -5146,7 +5146,7 @@ const De = {
|
|
|
5146
5146
|
timestamp: "text-xs text-dark-40/50 leading-none"
|
|
5147
5147
|
}, vd = ue(
|
|
5148
5148
|
({ checked: e, disabled: t, id: n, onChange: r, size: o = "large", className: a, ...i }, s) => {
|
|
5149
|
-
const
|
|
5149
|
+
const d = he.sizes[o];
|
|
5150
5150
|
return /* @__PURE__ */ m.jsxs(
|
|
5151
5151
|
"label",
|
|
5152
5152
|
{
|
|
@@ -5154,7 +5154,7 @@ const De = {
|
|
|
5154
5154
|
"aria-label": "radio-label",
|
|
5155
5155
|
className: A(
|
|
5156
5156
|
he.base,
|
|
5157
|
-
|
|
5157
|
+
d.label,
|
|
5158
5158
|
t && he.disabled,
|
|
5159
5159
|
!t && he.active,
|
|
5160
5160
|
!e && !t && he.hover,
|
|
@@ -5218,7 +5218,7 @@ const he = {
|
|
|
5218
5218
|
variant: t = "default",
|
|
5219
5219
|
className: n
|
|
5220
5220
|
}) => /* @__PURE__ */ m.jsx(
|
|
5221
|
-
|
|
5221
|
+
ge,
|
|
5222
5222
|
{
|
|
5223
5223
|
className: A(Gr.base, Gr.status[t], n),
|
|
5224
5224
|
"data-testid": "status",
|
|
@@ -5238,7 +5238,7 @@ function gd(e) {
|
|
|
5238
5238
|
const t = c.useRef({ value: e, previous: e });
|
|
5239
5239
|
return c.useMemo(() => (t.current.value !== e && (t.current.previous = t.current.value, t.current.value = e), t.current.previous), [e]);
|
|
5240
5240
|
}
|
|
5241
|
-
var Bt = "Switch", [bd, xd] =
|
|
5241
|
+
var Bt = "Switch", [bd, xd] = we(Bt), [yd, wd] = bd(Bt), sr = c.forwardRef(
|
|
5242
5242
|
(e, t) => {
|
|
5243
5243
|
const {
|
|
5244
5244
|
__scopeSwitch: n,
|
|
@@ -5247,10 +5247,10 @@ var Bt = "Switch", [bd, xd] = ye(Bt), [yd, wd] = bd(Bt), sr = c.forwardRef(
|
|
|
5247
5247
|
defaultChecked: a,
|
|
5248
5248
|
required: i,
|
|
5249
5249
|
disabled: s,
|
|
5250
|
-
value:
|
|
5250
|
+
value: d = "on",
|
|
5251
5251
|
onCheckedChange: l,
|
|
5252
5252
|
form: f,
|
|
5253
|
-
...
|
|
5253
|
+
...u
|
|
5254
5254
|
} = e, [p, h] = c.useState(null), g = K(t, (w) => h(w)), v = c.useRef(!1), b = p ? f || !!p.closest("form") : !0, [x, S] = Ue({
|
|
5255
5255
|
prop: o,
|
|
5256
5256
|
defaultProp: a ?? !1,
|
|
@@ -5268,8 +5268,8 @@ var Bt = "Switch", [bd, xd] = ye(Bt), [yd, wd] = bd(Bt), sr = c.forwardRef(
|
|
|
5268
5268
|
"data-state": za(x),
|
|
5269
5269
|
"data-disabled": s ? "" : void 0,
|
|
5270
5270
|
disabled: s,
|
|
5271
|
-
value:
|
|
5272
|
-
...
|
|
5271
|
+
value: d,
|
|
5272
|
+
...u,
|
|
5273
5273
|
ref: g,
|
|
5274
5274
|
onClick: k(e.onClick, (w) => {
|
|
5275
5275
|
S((C) => !C), b && (v.current = w.isPropagationStopped(), v.current || w.stopPropagation());
|
|
@@ -5282,7 +5282,7 @@ var Bt = "Switch", [bd, xd] = ye(Bt), [yd, wd] = bd(Bt), sr = c.forwardRef(
|
|
|
5282
5282
|
control: p,
|
|
5283
5283
|
bubbles: !v.current,
|
|
5284
5284
|
name: r,
|
|
5285
|
-
value:
|
|
5285
|
+
value: d,
|
|
5286
5286
|
checked: x,
|
|
5287
5287
|
required: i,
|
|
5288
5288
|
disabled: s,
|
|
@@ -5317,19 +5317,19 @@ var Sd = "SwitchBubbleInput", Ha = c.forwardRef(
|
|
|
5317
5317
|
bubbles: r = !0,
|
|
5318
5318
|
...o
|
|
5319
5319
|
}, a) => {
|
|
5320
|
-
const i = c.useRef(null), s = K(i, a),
|
|
5320
|
+
const i = c.useRef(null), s = K(i, a), d = gd(n), l = bo(t);
|
|
5321
5321
|
return c.useEffect(() => {
|
|
5322
5322
|
const f = i.current;
|
|
5323
5323
|
if (!f) return;
|
|
5324
|
-
const
|
|
5325
|
-
|
|
5324
|
+
const u = window.HTMLInputElement.prototype, h = Object.getOwnPropertyDescriptor(
|
|
5325
|
+
u,
|
|
5326
5326
|
"checked"
|
|
5327
5327
|
).set;
|
|
5328
|
-
if (
|
|
5328
|
+
if (d !== n && h) {
|
|
5329
5329
|
const g = new Event("click", { bubbles: r });
|
|
5330
5330
|
h.call(f, n), f.dispatchEvent(g);
|
|
5331
5331
|
}
|
|
5332
|
-
}, [
|
|
5332
|
+
}, [d, n, r]), /* @__PURE__ */ m.jsx(
|
|
5333
5333
|
"input",
|
|
5334
5334
|
{
|
|
5335
5335
|
type: "checkbox",
|
|
@@ -5402,14 +5402,14 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5402
5402
|
className: a,
|
|
5403
5403
|
iconDimensions: i,
|
|
5404
5404
|
...s
|
|
5405
|
-
},
|
|
5405
|
+
}, d) => {
|
|
5406
5406
|
const l = Xe.sizes[e];
|
|
5407
5407
|
return /* @__PURE__ */ m.jsxs(
|
|
5408
5408
|
"button",
|
|
5409
5409
|
{
|
|
5410
5410
|
role: "tab",
|
|
5411
5411
|
"aria-selected": t,
|
|
5412
|
-
ref:
|
|
5412
|
+
ref: d,
|
|
5413
5413
|
className: A(
|
|
5414
5414
|
l.base,
|
|
5415
5415
|
l.default,
|
|
@@ -5439,7 +5439,7 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5439
5439
|
}
|
|
5440
5440
|
);
|
|
5441
5441
|
}
|
|
5442
|
-
),
|
|
5442
|
+
), ge = ({
|
|
5443
5443
|
children: e,
|
|
5444
5444
|
className: t = "",
|
|
5445
5445
|
variant: n = "p",
|
|
@@ -5457,16 +5457,16 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5457
5457
|
status: a,
|
|
5458
5458
|
maxLength: i,
|
|
5459
5459
|
...s
|
|
5460
|
-
},
|
|
5460
|
+
}, d) => {
|
|
5461
5461
|
var v, b;
|
|
5462
|
-
const l =
|
|
5463
|
-
return /* @__PURE__ */ m.jsxs("div", { className:
|
|
5462
|
+
const l = _e.base, f = _e.state, u = _e.disabled, p = _e.styles, h = _e.maxLength;
|
|
5463
|
+
return /* @__PURE__ */ m.jsxs("div", { className: _e.root, children: [
|
|
5464
5464
|
/* @__PURE__ */ m.jsx(
|
|
5465
5465
|
"textarea",
|
|
5466
5466
|
{
|
|
5467
5467
|
...s,
|
|
5468
5468
|
role: "textbox",
|
|
5469
|
-
ref:
|
|
5469
|
+
ref: d,
|
|
5470
5470
|
maxLength: i,
|
|
5471
5471
|
disabled: t,
|
|
5472
5472
|
autoFocus: o,
|
|
@@ -5477,13 +5477,13 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5477
5477
|
f.focus,
|
|
5478
5478
|
!t && f.hover,
|
|
5479
5479
|
a && (p == null ? void 0 : p[a]),
|
|
5480
|
-
t &&
|
|
5480
|
+
t && u,
|
|
5481
5481
|
e
|
|
5482
5482
|
)
|
|
5483
5483
|
}
|
|
5484
5484
|
),
|
|
5485
|
-
/* @__PURE__ */ m.jsx("div", { className:
|
|
5486
|
-
|
|
5485
|
+
/* @__PURE__ */ m.jsx("div", { className: _e.messageContainer, children: i && /* @__PURE__ */ m.jsxs(
|
|
5486
|
+
ge,
|
|
5487
5487
|
{
|
|
5488
5488
|
variant: "span",
|
|
5489
5489
|
className: A(
|
|
@@ -5499,7 +5499,7 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5499
5499
|
) })
|
|
5500
5500
|
] });
|
|
5501
5501
|
}
|
|
5502
|
-
),
|
|
5502
|
+
), _e = {
|
|
5503
5503
|
root: "flex flex-col gap-1 w-full",
|
|
5504
5504
|
base: "w-full min-h-[60px] bg-gray-50 text-sm text-dark-10 font-sans font-medium leading-none px-3.5 py-3 border border-gray-50 rounded-[10px] placeholder:text-sm placeholder:text-dark-40/50 transition-colors duration-200",
|
|
5505
5505
|
disabled: "text-dark-40/25 bg-dark-30/[.08] cursor-not-allowed",
|
|
@@ -5571,64 +5571,66 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5571
5571
|
options: o,
|
|
5572
5572
|
placeholder: a = "Choose",
|
|
5573
5573
|
value: i,
|
|
5574
|
-
isDotable: s
|
|
5574
|
+
isDotable: s,
|
|
5575
|
+
loading: d = !1
|
|
5575
5576
|
}) => {
|
|
5576
|
-
const [
|
|
5577
|
-
className:
|
|
5578
|
-
text:
|
|
5577
|
+
const [l, f] = Yr(!1), p = si(o)(i), h = mr(null), g = mr(null), v = Le.base, b = Le.options, x = Le.status.styles, S = Le.disabled.trigger, w = Le.disabled.triggerText, C = ({
|
|
5578
|
+
className: _,
|
|
5579
|
+
text: E = ""
|
|
5579
5580
|
}) => /* @__PURE__ */ m.jsx(
|
|
5580
|
-
|
|
5581
|
+
ge,
|
|
5581
5582
|
{
|
|
5582
5583
|
className: A(
|
|
5583
|
-
|
|
5584
|
-
t &&
|
|
5585
|
-
|
|
5584
|
+
v.placeholder,
|
|
5585
|
+
t && w,
|
|
5586
|
+
"truncate min-w-0 flex-1",
|
|
5587
|
+
_
|
|
5586
5588
|
),
|
|
5587
|
-
children:
|
|
5589
|
+
children: E
|
|
5588
5590
|
}
|
|
5589
|
-
),
|
|
5590
|
-
if (
|
|
5591
|
-
const
|
|
5591
|
+
), R = (_) => {
|
|
5592
|
+
if (_.preventDefault(), i && g.current) {
|
|
5593
|
+
const E = g.current.querySelector(
|
|
5592
5594
|
`[data-value="${i}"]`
|
|
5593
5595
|
);
|
|
5594
|
-
|
|
5596
|
+
E && E.scrollIntoView({
|
|
5595
5597
|
block: "center",
|
|
5596
5598
|
behavior: "auto"
|
|
5597
5599
|
});
|
|
5598
5600
|
}
|
|
5599
5601
|
};
|
|
5600
|
-
return /* @__PURE__ */ m.jsx("div", { className: A("w-full", e == null ? void 0 : e.parent), children: /* @__PURE__ */ m.jsxs(ul, { open:
|
|
5602
|
+
return /* @__PURE__ */ m.jsx("div", { className: A("w-full", e == null ? void 0 : e.parent), children: /* @__PURE__ */ m.jsxs(ul, { open: l, onOpenChange: f, children: [
|
|
5601
5603
|
/* @__PURE__ */ m.jsxs(
|
|
5602
5604
|
dl,
|
|
5603
5605
|
{
|
|
5604
5606
|
role: "listbox",
|
|
5605
5607
|
disabled: t,
|
|
5606
5608
|
className: A(
|
|
5607
|
-
|
|
5608
|
-
t &&
|
|
5609
|
-
|
|
5610
|
-
!
|
|
5611
|
-
!
|
|
5609
|
+
v.trigger,
|
|
5610
|
+
t && S,
|
|
5611
|
+
l && v.focus,
|
|
5612
|
+
!l && !t && v.hover,
|
|
5613
|
+
!l && n && x[n],
|
|
5612
5614
|
e == null ? void 0 : e.trigger
|
|
5613
5615
|
),
|
|
5614
5616
|
children: [
|
|
5615
|
-
i ? /* @__PURE__ */ m.jsx(
|
|
5616
|
-
|
|
5617
|
+
/* @__PURE__ */ m.jsx("div", { className: v == null ? void 0 : v.textWrapper, children: i ? /* @__PURE__ */ m.jsx(
|
|
5618
|
+
C,
|
|
5617
5619
|
{
|
|
5618
|
-
text:
|
|
5620
|
+
text: p == null ? void 0 : p.label,
|
|
5619
5621
|
className: A(
|
|
5620
|
-
|
|
5621
|
-
t &&
|
|
5622
|
+
v.selected,
|
|
5623
|
+
t && Le.disabled.selectedDisabled,
|
|
5622
5624
|
e == null ? void 0 : e.selected
|
|
5623
5625
|
)
|
|
5624
5626
|
}
|
|
5625
5627
|
) : /* @__PURE__ */ m.jsx(
|
|
5626
|
-
|
|
5628
|
+
C,
|
|
5627
5629
|
{
|
|
5628
5630
|
text: a,
|
|
5629
5631
|
className: e == null ? void 0 : e.placeholder
|
|
5630
5632
|
}
|
|
5631
|
-
),
|
|
5633
|
+
) }),
|
|
5632
5634
|
/* @__PURE__ */ m.jsx(
|
|
5633
5635
|
ui,
|
|
5634
5636
|
{
|
|
@@ -5636,59 +5638,61 @@ const Rd = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
5636
5638
|
height: 20,
|
|
5637
5639
|
viewBox: "0 0 20 20",
|
|
5638
5640
|
className: A(
|
|
5639
|
-
|
|
5640
|
-
t &&
|
|
5641
|
-
|
|
5641
|
+
v.icon,
|
|
5642
|
+
t && v.iconDisabled,
|
|
5643
|
+
l && "-rotate-180",
|
|
5644
|
+
"flex-shrink-0"
|
|
5642
5645
|
)
|
|
5643
5646
|
}
|
|
5644
5647
|
)
|
|
5645
5648
|
]
|
|
5646
5649
|
}
|
|
5647
5650
|
),
|
|
5648
|
-
/* @__PURE__ */ m.jsx("div", { ref:
|
|
5651
|
+
/* @__PURE__ */ m.jsx("div", { ref: h, children: /* @__PURE__ */ m.jsx(
|
|
5649
5652
|
fl,
|
|
5650
5653
|
{
|
|
5651
|
-
container:
|
|
5652
|
-
className: A(
|
|
5654
|
+
container: h.current,
|
|
5655
|
+
className: A(b.content, e == null ? void 0 : e.content),
|
|
5653
5656
|
style: { minWidth: "var(--radix-popper-anchor-width)" },
|
|
5654
|
-
onOpenAutoFocus:
|
|
5655
|
-
ref:
|
|
5656
|
-
children:
|
|
5657
|
+
onOpenAutoFocus: R,
|
|
5658
|
+
ref: g,
|
|
5659
|
+
children: d ? /* @__PURE__ */ m.jsx("div", { className: A(b.items, "cursor-default"), children: /* @__PURE__ */ m.jsx(ge, { className: A(b.itemsText), children: "Загрузка..." }) }) : o && o.length > 0 ? o.map((_) => /* @__PURE__ */ m.jsx(
|
|
5657
5660
|
"div",
|
|
5658
5661
|
{
|
|
5659
|
-
"data-value":
|
|
5660
|
-
className: A(
|
|
5661
|
-
onClick: (
|
|
5662
|
-
|
|
5662
|
+
"data-value": _.value,
|
|
5663
|
+
className: A(b.items),
|
|
5664
|
+
onClick: (E) => {
|
|
5665
|
+
E.preventDefault(), E.stopPropagation(), r(_.value), f(!1);
|
|
5663
5666
|
},
|
|
5664
5667
|
children: /* @__PURE__ */ m.jsx(
|
|
5665
|
-
|
|
5668
|
+
ge,
|
|
5666
5669
|
{
|
|
5667
5670
|
className: A(
|
|
5668
|
-
|
|
5669
|
-
!s && i ===
|
|
5670
|
-
s &&
|
|
5671
|
-
s && i ===
|
|
5671
|
+
b.itemsText,
|
|
5672
|
+
!s && i === _.value && b.active,
|
|
5673
|
+
s && b.dot,
|
|
5674
|
+
s && i === _.value && "before:bg-dark-10 !font-bold"
|
|
5672
5675
|
),
|
|
5673
|
-
children:
|
|
5676
|
+
children: _.label
|
|
5674
5677
|
}
|
|
5675
5678
|
)
|
|
5676
5679
|
},
|
|
5677
|
-
|
|
5678
|
-
)))
|
|
5680
|
+
_.value
|
|
5681
|
+
)) : /* @__PURE__ */ m.jsx("div", { className: A(b.items, "cursor-default"), children: /* @__PURE__ */ m.jsx(ge, { className: A(b.itemsText), children: "Нет данных" }) })
|
|
5679
5682
|
}
|
|
5680
5683
|
) })
|
|
5681
5684
|
] }) });
|
|
5682
|
-
},
|
|
5685
|
+
}, Le = {
|
|
5683
5686
|
container: "w-full flex items-start flex-col gap-1.5",
|
|
5684
5687
|
base: {
|
|
5685
5688
|
icon: "ml-auto fill-sidebar-30/[.70] rounded hover:cursor-pointer transition-transform durantion-300",
|
|
5686
5689
|
iconDisabled: "text-dark-30/[.25] fill-dark-30/[.25]",
|
|
5690
|
+
textWrapper: "min-w-0 flex-1 overflow-hidden",
|
|
5687
5691
|
items: "group rounded-[5px] hover:bg-primary-10/[.10] cursor-pointer px-[9px] py-[5px]",
|
|
5688
5692
|
itemsText: "text-dark-30 text-xs font-normal group-hover:text-dark-30 group-hover:font-medium ",
|
|
5689
5693
|
placeholder: "text-sm font-normal font-mono text-dark-30/[.50] font-medium",
|
|
5690
|
-
selected: "text-dark-40 font-semibold",
|
|
5691
|
-
trigger: "px-4 py-3 rounded-[10px] h-[44px] border border-dark-30/[.10] bg-gray-50 text-start flex justify-between items-center outline-none",
|
|
5694
|
+
selected: "text-dark-40 font-semibold whitespace-nowrap",
|
|
5695
|
+
trigger: "px-4 py-3 rounded-[10px] h-[44px] border border-dark-30/[.10] bg-gray-50 text-start flex justify-between items-center outline-none gap-2",
|
|
5692
5696
|
focus: "bg-transparent outline-[2px] outline-primary-10/[.20] border-primary-10 outline-offset-0",
|
|
5693
5697
|
hover: "hover:border-primary-20/[.30]"
|
|
5694
5698
|
},
|
|
@@ -5717,30 +5721,30 @@ function Ad(e, t = []) {
|
|
|
5717
5721
|
function r(a, i) {
|
|
5718
5722
|
const s = c.createContext(i);
|
|
5719
5723
|
s.displayName = a + "Context";
|
|
5720
|
-
const
|
|
5724
|
+
const d = n.length;
|
|
5721
5725
|
n = [...n, i];
|
|
5722
|
-
const l = (
|
|
5726
|
+
const l = (u) => {
|
|
5723
5727
|
var x;
|
|
5724
|
-
const { scope: p, children: h, ...g } =
|
|
5728
|
+
const { scope: p, children: h, ...g } = u, v = ((x = p == null ? void 0 : p[e]) == null ? void 0 : x[d]) || s, b = c.useMemo(() => g, Object.values(g));
|
|
5725
5729
|
return /* @__PURE__ */ m.jsx(v.Provider, { value: b, children: h });
|
|
5726
5730
|
};
|
|
5727
5731
|
l.displayName = a + "Provider";
|
|
5728
|
-
function f(
|
|
5732
|
+
function f(u, p) {
|
|
5729
5733
|
var v;
|
|
5730
|
-
const h = ((v = p == null ? void 0 : p[e]) == null ? void 0 : v[
|
|
5734
|
+
const h = ((v = p == null ? void 0 : p[e]) == null ? void 0 : v[d]) || s, g = c.useContext(h);
|
|
5731
5735
|
if (g) return g;
|
|
5732
5736
|
if (i !== void 0) return i;
|
|
5733
|
-
throw new Error(`\`${
|
|
5737
|
+
throw new Error(`\`${u}\` must be used within \`${a}\``);
|
|
5734
5738
|
}
|
|
5735
5739
|
return [l, f];
|
|
5736
5740
|
}
|
|
5737
5741
|
const o = () => {
|
|
5738
5742
|
const a = n.map((i) => c.createContext(i));
|
|
5739
5743
|
return function(s) {
|
|
5740
|
-
const
|
|
5744
|
+
const d = (s == null ? void 0 : s[e]) || a;
|
|
5741
5745
|
return c.useMemo(
|
|
5742
|
-
() => ({ [`__scope${e}`]: { ...s, [e]:
|
|
5743
|
-
[s,
|
|
5746
|
+
() => ({ [`__scope${e}`]: { ...s, [e]: d } }),
|
|
5747
|
+
[s, d]
|
|
5744
5748
|
);
|
|
5745
5749
|
};
|
|
5746
5750
|
};
|
|
@@ -5755,9 +5759,9 @@ function Td(...e) {
|
|
|
5755
5759
|
scopeName: o.scopeName
|
|
5756
5760
|
}));
|
|
5757
5761
|
return function(a) {
|
|
5758
|
-
const i = r.reduce((s, { useScope:
|
|
5759
|
-
const
|
|
5760
|
-
return { ...s, ...
|
|
5762
|
+
const i = r.reduce((s, { useScope: d, scopeName: l }) => {
|
|
5763
|
+
const u = d(a)[`__scope${l}`];
|
|
5764
|
+
return { ...s, ...u };
|
|
5761
5765
|
}, {});
|
|
5762
5766
|
return c.useMemo(() => ({ [`__scope${t.scopeName}`]: i }), [i]);
|
|
5763
5767
|
};
|
|
@@ -5776,9 +5780,9 @@ function kd(e) {
|
|
|
5776
5780
|
const t = /* @__PURE__ */ Id(e), n = c.forwardRef((r, o) => {
|
|
5777
5781
|
let { children: a, ...i } = r;
|
|
5778
5782
|
Ka(a) && typeof _t == "function" && (a = _t(a._payload));
|
|
5779
|
-
const s = c.Children.toArray(a),
|
|
5780
|
-
if (
|
|
5781
|
-
const l =
|
|
5783
|
+
const s = c.Children.toArray(a), d = s.find(Dd);
|
|
5784
|
+
if (d) {
|
|
5785
|
+
const l = d.props.children, f = s.map((u) => u === d ? c.Children.count(l) > 1 ? c.Children.only(null) : c.isValidElement(l) ? l.props.children : null : u);
|
|
5782
5786
|
return /* @__PURE__ */ m.jsx(t, { ...i, ref: o, children: c.isValidElement(l) ? c.cloneElement(l, void 0, f) : null });
|
|
5783
5787
|
}
|
|
5784
5788
|
return /* @__PURE__ */ m.jsx(t, { ...i, ref: o, children: a });
|
|
@@ -5806,8 +5810,8 @@ function Nd(e, t) {
|
|
|
5806
5810
|
for (const r in t) {
|
|
5807
5811
|
const o = e[r], a = t[r];
|
|
5808
5812
|
/^on[A-Z]/.test(r) ? o && a ? n[r] = (...s) => {
|
|
5809
|
-
const
|
|
5810
|
-
return o(...s),
|
|
5813
|
+
const d = a(...s);
|
|
5814
|
+
return o(...s), d;
|
|
5811
5815
|
} : o && (n[r] = o) : r === "style" ? n[r] = { ...o, ...a } : r === "className" && (n[r] = [o, a].filter(Boolean).join(" "));
|
|
5812
5816
|
}
|
|
5813
5817
|
return { ...e, ...n };
|
|
@@ -5837,8 +5841,8 @@ var Fd = [
|
|
|
5837
5841
|
"ul"
|
|
5838
5842
|
], lr = Fd.reduce((e, t) => {
|
|
5839
5843
|
const n = /* @__PURE__ */ kd(`Primitive.${t}`), r = c.forwardRef((o, a) => {
|
|
5840
|
-
const { asChild: i, ...s } = o,
|
|
5841
|
-
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ m.jsx(
|
|
5844
|
+
const { asChild: i, ...s } = o, d = i ? n : t;
|
|
5845
|
+
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ m.jsx(d, { ...s, ref: a });
|
|
5842
5846
|
});
|
|
5843
5847
|
return r.displayName = `Primitive.${t}`, { ...e, [t]: r };
|
|
5844
5848
|
}, {}), un = { exports: {} }, Jt = {};
|
|
@@ -5856,37 +5860,37 @@ function $d() {
|
|
|
5856
5860
|
if (Hr) return Jt;
|
|
5857
5861
|
Hr = 1;
|
|
5858
5862
|
var e = ae;
|
|
5859
|
-
function t(
|
|
5860
|
-
return
|
|
5863
|
+
function t(u, p) {
|
|
5864
|
+
return u === p && (u !== 0 || 1 / u === 1 / p) || u !== u && p !== p;
|
|
5861
5865
|
}
|
|
5862
5866
|
var n = typeof Object.is == "function" ? Object.is : t, r = e.useState, o = e.useEffect, a = e.useLayoutEffect, i = e.useDebugValue;
|
|
5863
|
-
function s(
|
|
5867
|
+
function s(u, p) {
|
|
5864
5868
|
var h = p(), g = r({ inst: { value: h, getSnapshot: p } }), v = g[0].inst, b = g[1];
|
|
5865
5869
|
return a(
|
|
5866
5870
|
function() {
|
|
5867
|
-
v.value = h, v.getSnapshot = p,
|
|
5871
|
+
v.value = h, v.getSnapshot = p, d(v) && b({ inst: v });
|
|
5868
5872
|
},
|
|
5869
|
-
[
|
|
5873
|
+
[u, h, p]
|
|
5870
5874
|
), o(
|
|
5871
5875
|
function() {
|
|
5872
|
-
return
|
|
5873
|
-
|
|
5876
|
+
return d(v) && b({ inst: v }), u(function() {
|
|
5877
|
+
d(v) && b({ inst: v });
|
|
5874
5878
|
});
|
|
5875
5879
|
},
|
|
5876
|
-
[
|
|
5880
|
+
[u]
|
|
5877
5881
|
), i(h), h;
|
|
5878
5882
|
}
|
|
5879
|
-
function u
|
|
5880
|
-
var p =
|
|
5881
|
-
|
|
5883
|
+
function d(u) {
|
|
5884
|
+
var p = u.getSnapshot;
|
|
5885
|
+
u = u.value;
|
|
5882
5886
|
try {
|
|
5883
5887
|
var h = p();
|
|
5884
|
-
return !n(
|
|
5888
|
+
return !n(u, h);
|
|
5885
5889
|
} catch {
|
|
5886
5890
|
return !0;
|
|
5887
5891
|
}
|
|
5888
5892
|
}
|
|
5889
|
-
function l(
|
|
5893
|
+
function l(u, p) {
|
|
5890
5894
|
return p();
|
|
5891
5895
|
}
|
|
5892
5896
|
var f = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? l : s;
|
|
@@ -5913,17 +5917,17 @@ function Bd() {
|
|
|
5913
5917
|
"You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
|
|
5914
5918
|
));
|
|
5915
5919
|
var v = g();
|
|
5916
|
-
if (!
|
|
5920
|
+
if (!u) {
|
|
5917
5921
|
var b = g();
|
|
5918
5922
|
a(v, b) || (console.error(
|
|
5919
5923
|
"The result of getSnapshot should be cached to avoid an infinite loop"
|
|
5920
|
-
),
|
|
5924
|
+
), u = !0);
|
|
5921
5925
|
}
|
|
5922
5926
|
b = i({
|
|
5923
5927
|
inst: { value: v, getSnapshot: g }
|
|
5924
5928
|
});
|
|
5925
5929
|
var x = b[0].inst, S = b[1];
|
|
5926
|
-
return
|
|
5930
|
+
return d(
|
|
5927
5931
|
function() {
|
|
5928
5932
|
x.value = v, x.getSnapshot = g, n(x) && S({ inst: x });
|
|
5929
5933
|
},
|
|
@@ -5951,7 +5955,7 @@ function Bd() {
|
|
|
5951
5955
|
return g();
|
|
5952
5956
|
}
|
|
5953
5957
|
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
5954
|
-
var o = ae, a = typeof Object.is == "function" ? Object.is : e, i = o.useState, s = o.useEffect,
|
|
5958
|
+
var o = ae, a = typeof Object.is == "function" ? Object.is : e, i = o.useState, s = o.useEffect, d = o.useLayoutEffect, l = o.useDebugValue, f = !1, u = !1, p = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? r : t;
|
|
5955
5959
|
Qt.useSyncExternalStore = o.useSyncExternalStore !== void 0 ? o.useSyncExternalStore : p, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
5956
5960
|
}()), Qt;
|
|
5957
5961
|
}
|
|
@@ -5986,12 +5990,12 @@ Xa.displayName = ur;
|
|
|
5986
5990
|
var qa = "AvatarImage", Za = c.forwardRef(
|
|
5987
5991
|
(e, t) => {
|
|
5988
5992
|
const { __scopeAvatar: n, src: r, onLoadingStatusChange: o = () => {
|
|
5989
|
-
}, ...a } = e, i = Ya(qa, n), s = zd(r, a),
|
|
5993
|
+
}, ...a } = e, i = Ya(qa, n), s = zd(r, a), d = ne((l) => {
|
|
5990
5994
|
o(l), i.onImageLoadingStatusChange(l);
|
|
5991
5995
|
});
|
|
5992
5996
|
return te(() => {
|
|
5993
|
-
s !== "idle" &&
|
|
5994
|
-
}, [s,
|
|
5997
|
+
s !== "idle" && d(s);
|
|
5998
|
+
}, [s, d]), s === "loaded" ? /* @__PURE__ */ m.jsx(lr.img, { ...a, ref: t, src: r }) : null;
|
|
5995
5999
|
}
|
|
5996
6000
|
);
|
|
5997
6001
|
Za.displayName = qa;
|
|
@@ -6000,8 +6004,8 @@ var Ja = "AvatarFallback", Qa = c.forwardRef(
|
|
|
6000
6004
|
const { __scopeAvatar: n, delayMs: r, ...o } = e, a = Ya(Ja, n), [i, s] = c.useState(r === void 0);
|
|
6001
6005
|
return c.useEffect(() => {
|
|
6002
6006
|
if (r !== void 0) {
|
|
6003
|
-
const
|
|
6004
|
-
return () => window.clearTimeout(
|
|
6007
|
+
const d = window.setTimeout(() => s(!0), r);
|
|
6008
|
+
return () => window.clearTimeout(d);
|
|
6005
6009
|
}
|
|
6006
6010
|
}, [r]), i && a.imageLoadingStatus !== "loaded" ? /* @__PURE__ */ m.jsx(lr.span, { ...o, ref: t }) : null;
|
|
6007
6011
|
}
|
|
@@ -6017,11 +6021,11 @@ function zd(e, { referrerPolicy: t, crossOrigin: n }) {
|
|
|
6017
6021
|
return te(() => {
|
|
6018
6022
|
s(Kr(a, e));
|
|
6019
6023
|
}, [a, e]), te(() => {
|
|
6020
|
-
const
|
|
6021
|
-
s(
|
|
6024
|
+
const d = (u) => () => {
|
|
6025
|
+
s(u);
|
|
6022
6026
|
};
|
|
6023
6027
|
if (!a) return;
|
|
6024
|
-
const l =
|
|
6028
|
+
const l = d("loaded"), f = d("error");
|
|
6025
6029
|
return a.addEventListener("load", l), a.addEventListener("error", f), t && (a.referrerPolicy = t), typeof n == "string" && (a.crossOrigin = n), () => {
|
|
6026
6030
|
a.removeEventListener("load", l), a.removeEventListener("error", f);
|
|
6027
6031
|
};
|
|
@@ -6036,7 +6040,7 @@ const xf = ({
|
|
|
6036
6040
|
isHasCamera: a = !1,
|
|
6037
6041
|
classNames: i
|
|
6038
6042
|
}) => {
|
|
6039
|
-
const s = vt.root,
|
|
6043
|
+
const s = vt.root, d = vt.image, l = vt.badge;
|
|
6040
6044
|
return /* @__PURE__ */ m.jsxs(
|
|
6041
6045
|
Xa,
|
|
6042
6046
|
{
|
|
@@ -6056,7 +6060,7 @@ const xf = ({
|
|
|
6056
6060
|
"data-testid": "avatar-img",
|
|
6057
6061
|
src: e,
|
|
6058
6062
|
alt: t ?? "empty-avatar",
|
|
6059
|
-
className: A(
|
|
6063
|
+
className: A(d, i == null ? void 0 : i.img)
|
|
6060
6064
|
}
|
|
6061
6065
|
) : /* @__PURE__ */ m.jsx(Qa, { children: a ? /* @__PURE__ */ m.jsx(
|
|
6062
6066
|
gr,
|
|
@@ -6137,7 +6141,7 @@ export {
|
|
|
6137
6141
|
vd as R,
|
|
6138
6142
|
mf as S,
|
|
6139
6143
|
hf as T,
|
|
6140
|
-
|
|
6144
|
+
Pe as U,
|
|
6141
6145
|
wn as V,
|
|
6142
6146
|
Sn as W,
|
|
6143
6147
|
Pt as X,
|
|
@@ -6164,28 +6168,28 @@ export {
|
|
|
6164
6168
|
ie as ag,
|
|
6165
6169
|
lf as ah,
|
|
6166
6170
|
Ye as b,
|
|
6167
|
-
|
|
6168
|
-
|
|
6169
|
-
|
|
6171
|
+
Oe as c,
|
|
6172
|
+
ke as d,
|
|
6173
|
+
ge as e,
|
|
6170
6174
|
vf as f,
|
|
6171
|
-
|
|
6175
|
+
_e as g,
|
|
6172
6176
|
gf as h,
|
|
6173
|
-
|
|
6177
|
+
Me as i,
|
|
6174
6178
|
Zt as j,
|
|
6175
6179
|
bf as k,
|
|
6176
6180
|
br as l,
|
|
6177
|
-
|
|
6178
|
-
|
|
6181
|
+
Ne as m,
|
|
6182
|
+
Le as n,
|
|
6179
6183
|
vt as o,
|
|
6180
6184
|
m as p,
|
|
6181
6185
|
Jr as q,
|
|
6182
6186
|
he as r,
|
|
6183
6187
|
Gr as s,
|
|
6184
6188
|
Xe as t,
|
|
6185
|
-
|
|
6189
|
+
we as u,
|
|
6186
6190
|
K as v,
|
|
6187
6191
|
af as w,
|
|
6188
6192
|
Ue as x,
|
|
6189
|
-
|
|
6193
|
+
Se as y,
|
|
6190
6194
|
k as z
|
|
6191
6195
|
};
|