ics-ui-kit 0.1.8 → 0.1.9
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/README.md +36 -36
- package/dist/AlertContext-CxjW1LVL.js.map +1 -1
- package/dist/AlertIcon-5B6AgZpe.js.map +1 -1
- package/dist/Button-Dg89xRSi.js.map +1 -1
- package/dist/ButtonBase-e6qyv6mD.js.map +1 -1
- package/dist/CheckboxField-cX09-eBX.js.map +1 -1
- package/dist/Command-DrFVm_8w.js +562 -0
- package/dist/Command-DrFVm_8w.js.map +1 -0
- package/dist/ComponentVariantProvider-brk0g-hm.js +9 -0
- package/dist/ComponentVariantProvider-brk0g-hm.js.map +1 -0
- package/dist/Description-BTPMlTT-.js.map +1 -1
- package/dist/Dialog-Bs1B5Iu8.js.map +1 -1
- package/dist/Divider-DPW5ZhZ8.js.map +1 -1
- package/dist/EmptyState-DRKjscH-.js.map +1 -1
- package/dist/ErrorState-B26k67-z.js.map +1 -1
- package/dist/FeatureIcon-BGE0Orkc.js.map +1 -1
- package/dist/Field-BiIWtq9o.js.map +1 -1
- package/dist/FieldLabel-QJ4rJFOi.js.map +1 -1
- package/dist/FolderSvg-cw0DxNVy.js.map +1 -1
- package/dist/FormFooterTemplate-DPB6Dkxn.js.map +1 -1
- package/dist/FormHeader--F6b2aRk.js.map +1 -1
- package/dist/FormStack-DO15vBgd.js.map +1 -1
- package/dist/HintState-BxrCAWqq.js.map +1 -1
- package/dist/Icon-DH3ev9GK.js.map +1 -1
- package/dist/IconButton-DwkpNgn3.js.map +1 -1
- package/dist/IconTooltip-CKJKGHbk.js.map +1 -1
- package/dist/Indicator-AqxHWPA9.js.map +1 -1
- package/dist/InputGroup-BvD9Igmt.js.map +1 -1
- package/dist/InputOTP-B2e1nfSO.js.map +1 -1
- package/dist/Loader-BpHiL6W-.js.map +1 -1
- package/dist/MenuItem-d19Ty84F.js +39 -0
- package/dist/MenuItem-d19Ty84F.js.map +1 -0
- package/dist/MenuItemShortcut-D1faeIXp.js +21 -0
- package/dist/MenuItemShortcut-D1faeIXp.js.map +1 -0
- package/dist/MenuItemText-CRpaPbvg.js +20 -0
- package/dist/MenuItemText-CRpaPbvg.js.map +1 -0
- package/dist/Overlay-CVt011mY.js.map +1 -1
- package/dist/Popover-Dvr7y0YY.js.map +1 -1
- package/dist/RichButton-DuPTenmS.js.map +1 -1
- package/dist/ScrollArea-CuuTeDn3.js.map +1 -1
- package/dist/ScrollShadowContainer-DdrnF8qU.js.map +1 -1
- package/dist/SearchSelectTag-DFCX9zT1.js.map +1 -1
- package/dist/{Select-DRwv6-eZ.js → Select-B2WcoFf5.js} +2 -2
- package/dist/Select-B2WcoFf5.js.map +1 -0
- package/dist/Sheet-zTMuP7C8.js.map +1 -1
- package/dist/Shortcut-D8L15_ed.js.map +1 -1
- package/dist/Skeleton-y6I-i9q5.js.map +1 -1
- package/dist/Tag-DdHXTyKF.js.map +1 -1
- package/dist/Text-DeBE8AKl.js.map +1 -1
- package/dist/TextInput-Cj50ImXi.js.map +1 -1
- package/dist/TextOverflowTooltip-DlUgic5y.js.map +1 -1
- package/dist/Toggle-v_HT3Gm2.js.map +1 -1
- package/dist/Tooltip-C4rVuWr4.js.map +1 -1
- package/dist/TriggerButton-CfDObWP9.js.map +1 -1
- package/dist/blocks/auth/otp-form.js.map +1 -1
- package/dist/cn-dsXlqdJg.js.map +1 -1
- package/dist/components/alert-dialog.js.map +1 -1
- package/dist/components/alert.js.map +1 -1
- package/dist/components/avatar.js.map +1 -1
- package/dist/components/badge.js.map +1 -1
- package/dist/components/banner.js.map +1 -1
- package/dist/components/breadcrumb.js.map +1 -1
- package/dist/components/button.js.map +1 -1
- package/dist/components/calendar.js.map +1 -1
- package/dist/components/card.js.map +1 -1
- package/dist/components/carousel.js.map +1 -1
- package/dist/components/collapsible.js.map +1 -1
- package/dist/components/color-tile.js.map +1 -1
- package/dist/components/command.js +1 -1
- package/dist/components/container.js.map +1 -1
- package/dist/components/counter.js.map +1 -1
- package/dist/components/dialog.js.map +1 -1
- package/dist/components/divider.js.map +1 -1
- package/dist/components/drawer.js.map +1 -1
- package/dist/components/dropdown/Dropdown.d.ts +1 -0
- package/dist/components/dropdown/Dropdown.stories.d.ts +1 -0
- package/dist/components/dropdown.js +603 -543
- package/dist/components/dropdown.js.map +1 -1
- package/dist/components/error-state.js.map +1 -1
- package/dist/components/file-upload.js.map +1 -1
- package/dist/components/form.js.map +1 -1
- package/dist/components/glass-toolbar/GlassToolbar.stories.d.ts +1 -0
- package/dist/components/glass-toolbar.js.map +1 -1
- package/dist/components/image-placeholder.js.map +1 -1
- package/dist/components/image-preview.js.map +1 -1
- package/dist/components/image-uploader.js.map +1 -1
- package/dist/components/input.js.map +1 -1
- package/dist/components/menu-item/MenuItem.d.ts +12 -5
- package/dist/components/menu-item/index.d.ts +1 -1
- package/dist/components/menu-item.js +91 -90
- package/dist/components/menu-item.js.map +1 -1
- package/dist/components/page-state.js.map +1 -1
- package/dist/components/portal-container.js.map +1 -1
- package/dist/components/progress-circle.js.map +1 -1
- package/dist/components/progress.js.map +1 -1
- package/dist/components/prose.js.map +1 -1
- package/dist/components/radio-group.js.map +1 -1
- package/dist/components/resizable.js.map +1 -1
- package/dist/components/scheduler.js.map +1 -1
- package/dist/components/search-select.js +3 -3
- package/dist/components/search-select.js.map +1 -1
- package/dist/components/select.js +1 -1
- package/dist/components/sidebar.js +22 -22
- package/dist/components/sidebar.js.map +1 -1
- package/dist/components/slider.js.map +1 -1
- package/dist/components/stepper.js.map +1 -1
- package/dist/components/switch.js +47 -47
- package/dist/components/switch.js.map +1 -1
- package/dist/components/system-state.js.map +1 -1
- package/dist/components/table.js.map +1 -1
- package/dist/components/tabs.js.map +1 -1
- package/dist/components/tag-input.js +1 -1
- package/dist/components/tag-input.js.map +1 -1
- package/dist/components/textarea.js.map +1 -1
- package/dist/components/timer.js.map +1 -1
- package/dist/components/toast.js.map +1 -1
- package/dist/components/toggle-group.js.map +1 -1
- package/dist/components/toolbar.js.map +1 -1
- package/dist/design-tokens.source.json +1 -0
- package/dist/formatBytes-C4QXq5lC.js.map +1 -1
- package/dist/index-0ioNhtNM.js.map +1 -1
- package/dist/index-437EL2iq.js.map +1 -1
- package/dist/index-BDrapWDv.js.map +1 -1
- package/dist/index-BGQepRFJ.js.map +1 -1
- package/dist/index-BVqs-uqP.js.map +1 -1
- package/dist/index-BZPx6jYI.js.map +1 -1
- package/dist/index-Bb23HztA.js.map +1 -1
- package/dist/index-BpWB3aFK.js.map +1 -1
- package/dist/index-ByaXH_ih.js.map +1 -1
- package/dist/index-BzCriPiK.js.map +1 -1
- package/dist/index-CCKe-Mpx.js.map +1 -1
- package/dist/index-CFaU3UXv.js.map +1 -1
- package/dist/index-CLuiUUQ8.js.map +1 -1
- package/dist/index-CQD-Njgt.js.map +1 -1
- package/dist/index-CmBeyp2d.js.map +1 -1
- package/dist/index-DFZozV_h.js.map +1 -1
- package/dist/index-DHsfW5Rj.js.map +1 -1
- package/dist/index-DHyZ_0Ut.js.map +1 -1
- package/dist/index-DLcqcWxM.js.map +1 -1
- package/dist/index-DRo26PBK.js.map +1 -1
- package/dist/index-DnnQs07z.js.map +1 -1
- package/dist/index-Uiy0Xwy2.js.map +1 -1
- package/dist/index-_ITz1IyW.js.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/inputBaseStyles-DbzD_jvq.js.map +1 -1
- package/dist/lib/utils.js.map +1 -1
- package/dist/providers/component-variant-context/ComponentVariantProvider.d.ts +41 -4
- package/dist/providers/component-variant-context/index.d.ts +1 -1
- package/dist/providers/component-variant-context.js +4 -3
- package/dist/styles-scoped.css +6392 -6356
- package/dist/styles.css +6131 -6095
- package/dist/theme.css +362 -362
- package/dist/types/css.d.ts +4 -4
- package/dist/useBreakpoints-D8wKOvil.js.map +1 -1
- package/dist/useDebounce-BRah78CF.js.map +1 -1
- package/dist/useFileUpload-Bnl3P8mP.js.map +1 -1
- package/dist/useItemsKeyboardNavigation-CmeOR30y.js.map +1 -1
- package/dist/useMergeRefs-qoKniYqT.js.map +1 -1
- package/dist/usePortalContainer-ae6EzS08.js.map +1 -1
- package/dist/vendors/tanstack/react-table.js.map +1 -1
- package/dist/zod-BMNoK3aM.js.map +1 -1
- package/package.json +183 -183
- package/tailwind.preset.js +448 -448
- package/dist/Command-CiZHptkR.js +0 -554
- package/dist/Command-CiZHptkR.js.map +0 -1
- package/dist/ComponentVariantProvider-B0SFUaXB.js +0 -8
- package/dist/ComponentVariantProvider-B0SFUaXB.js.map +0 -1
- package/dist/MenuItem-pvsONHlh.js +0 -32
- package/dist/MenuItem-pvsONHlh.js.map +0 -1
- package/dist/MenuItemShortcut-DgPol9Nz.js +0 -21
- package/dist/MenuItemShortcut-DgPol9Nz.js.map +0 -1
- package/dist/MenuItemText-7uPl9P3z.js +0 -20
- package/dist/MenuItemText-7uPl9P3z.js.map +0 -1
- package/dist/Select-DRwv6-eZ.js.map +0 -1
|
@@ -1,64 +1,64 @@
|
|
|
1
1
|
import { jsx as c, jsxs as H } from "react/jsx-runtime";
|
|
2
|
-
import { c as
|
|
3
|
-
import { u as
|
|
4
|
-
import * as
|
|
5
|
-
import { P as E, c as
|
|
6
|
-
import { u as F, c as
|
|
7
|
-
import { c as
|
|
8
|
-
import { u as
|
|
9
|
-
import { c as
|
|
10
|
-
import { u as
|
|
11
|
-
import { P as
|
|
12
|
-
import { h as
|
|
13
|
-
import { u as
|
|
14
|
-
import { c as
|
|
2
|
+
import { c as jn } from "../cn-dsXlqdJg.js";
|
|
3
|
+
import { u as S, n as ie } from "../ComponentVariantProvider-brk0g-hm.js";
|
|
4
|
+
import * as s from "react";
|
|
5
|
+
import { P as E, c as h, d as Yn, a as Xn } from "../index-CFaU3UXv.js";
|
|
6
|
+
import { u as F, c as He } from "../index-DLcqcWxM.js";
|
|
7
|
+
import { c as We } from "../index-DFZozV_h.js";
|
|
8
|
+
import { u as Ze } from "../index-437EL2iq.js";
|
|
9
|
+
import { c as Hn } from "../index-DHsfW5Rj.js";
|
|
10
|
+
import { u as Wn } from "../index-ByaXH_ih.js";
|
|
11
|
+
import { P as Zn, D as qn } from "../index-_ITz1IyW.js";
|
|
12
|
+
import { h as Jn, u as Qn, R as eo, F as no } from "../index-BzCriPiK.js";
|
|
13
|
+
import { u as j } from "../index-xqkGMOJ8.js";
|
|
14
|
+
import { c as qe, R as Je, A as oo, a as to, C as ro } from "../index-DRo26PBK.js";
|
|
15
15
|
import { P as W } from "../index-BpWB3aFK.js";
|
|
16
|
-
import { c as
|
|
17
|
-
import { u as
|
|
18
|
-
import { T as
|
|
19
|
-
import { T as
|
|
20
|
-
import { I as
|
|
21
|
-
import {
|
|
22
|
-
import { m as
|
|
23
|
-
import { u as
|
|
24
|
-
import { M as
|
|
25
|
-
import { C as
|
|
26
|
-
import { C as
|
|
27
|
-
import { S as
|
|
28
|
-
var
|
|
29
|
-
ltr: [...
|
|
30
|
-
rtl: [...
|
|
31
|
-
},
|
|
16
|
+
import { c as Qe, I as ao, R as so } from "../index-DHyZ_0Ut.js";
|
|
17
|
+
import { u as ue } from "../index-0ioNhtNM.js";
|
|
18
|
+
import { T as M } from "../index-BVqs-uqP.js";
|
|
19
|
+
import { T as co } from "../TriggerButton-CfDObWP9.js";
|
|
20
|
+
import { I as io } from "../Icon-DH3ev9GK.js";
|
|
21
|
+
import { M as Z, m as q } from "../MenuItem-d19Ty84F.js";
|
|
22
|
+
import { m as uo } from "../MenuItemShortcut-D1faeIXp.js";
|
|
23
|
+
import { u as en } from "../usePortalContainer-ae6EzS08.js";
|
|
24
|
+
import { M as lo } from "../minus-BltQa7Q2.js";
|
|
25
|
+
import { C as nn } from "../check-CeyaOoZv.js";
|
|
26
|
+
import { C as po } from "../chevron-right-D3juAhA-.js";
|
|
27
|
+
import { S as mo } from "../search-CDdgqSGg.js";
|
|
28
|
+
var ce = ["Enter", " "], fo = ["ArrowDown", "PageUp", "Home"], on = ["ArrowUp", "PageDown", "End"], go = [...fo, ...on], ho = {
|
|
29
|
+
ltr: [...ce, "ArrowRight"],
|
|
30
|
+
rtl: [...ce, "ArrowLeft"]
|
|
31
|
+
}, vo = {
|
|
32
32
|
ltr: ["ArrowLeft"],
|
|
33
33
|
rtl: ["ArrowRight"]
|
|
34
|
-
}, K = "Menu", [L,
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
]), $ =
|
|
39
|
-
const { __scopeMenu: o, open: n = !1, children: t, dir: r, onOpenChange:
|
|
40
|
-
return
|
|
41
|
-
const
|
|
42
|
-
l.current = !0, document.addEventListener("pointerdown",
|
|
43
|
-
},
|
|
44
|
-
return document.addEventListener("keydown",
|
|
45
|
-
document.removeEventListener("keydown",
|
|
34
|
+
}, K = "Menu", [L, wo, Mo] = Hn(K), [D, tn] = We(K, [
|
|
35
|
+
Mo,
|
|
36
|
+
qe,
|
|
37
|
+
Qe
|
|
38
|
+
]), $ = qe(), rn = Qe(), [an, _] = D(K), [bo, U] = D(K), sn = (e) => {
|
|
39
|
+
const { __scopeMenu: o, open: n = !1, children: t, dir: r, onOpenChange: a, modal: i = !0 } = e, u = $(o), [m, f] = s.useState(null), l = s.useRef(!1), d = ue(a), g = Wn(r);
|
|
40
|
+
return s.useEffect(() => {
|
|
41
|
+
const w = () => {
|
|
42
|
+
l.current = !0, document.addEventListener("pointerdown", v, { capture: !0, once: !0 }), document.addEventListener("pointermove", v, { capture: !0, once: !0 });
|
|
43
|
+
}, v = () => l.current = !1;
|
|
44
|
+
return document.addEventListener("keydown", w, { capture: !0 }), () => {
|
|
45
|
+
document.removeEventListener("keydown", w, { capture: !0 }), document.removeEventListener("pointerdown", v, { capture: !0 }), document.removeEventListener("pointermove", v, { capture: !0 });
|
|
46
46
|
};
|
|
47
|
-
}, []), /* @__PURE__ */ c(
|
|
48
|
-
|
|
47
|
+
}, []), /* @__PURE__ */ c(Je, { ...u, children: /* @__PURE__ */ c(
|
|
48
|
+
an,
|
|
49
49
|
{
|
|
50
50
|
scope: o,
|
|
51
51
|
open: n,
|
|
52
|
-
onOpenChange:
|
|
53
|
-
content:
|
|
54
|
-
onContentChange:
|
|
52
|
+
onOpenChange: d,
|
|
53
|
+
content: m,
|
|
54
|
+
onContentChange: f,
|
|
55
55
|
children: /* @__PURE__ */ c(
|
|
56
|
-
|
|
56
|
+
bo,
|
|
57
57
|
{
|
|
58
58
|
scope: o,
|
|
59
|
-
onClose:
|
|
59
|
+
onClose: s.useCallback(() => d(!1), [d]),
|
|
60
60
|
isUsingKeyboardRef: l,
|
|
61
|
-
dir:
|
|
61
|
+
dir: g,
|
|
62
62
|
modal: i,
|
|
63
63
|
children: t
|
|
64
64
|
}
|
|
@@ -66,53 +66,53 @@ var ae = ["Enter", " "], lo = ["ArrowDown", "PageUp", "Home"], Qe = ["ArrowUp",
|
|
|
66
66
|
}
|
|
67
67
|
) });
|
|
68
68
|
};
|
|
69
|
-
|
|
70
|
-
var
|
|
69
|
+
sn.displayName = K;
|
|
70
|
+
var Co = "MenuAnchor", de = s.forwardRef(
|
|
71
71
|
(e, o) => {
|
|
72
72
|
const { __scopeMenu: n, ...t } = e, r = $(n);
|
|
73
|
-
return /* @__PURE__ */ c(
|
|
73
|
+
return /* @__PURE__ */ c(oo, { ...r, ...t, ref: o });
|
|
74
74
|
}
|
|
75
75
|
);
|
|
76
|
-
|
|
77
|
-
var
|
|
76
|
+
de.displayName = Co;
|
|
77
|
+
var le = "MenuPortal", [yo, cn] = D(le, {
|
|
78
78
|
forceMount: void 0
|
|
79
|
-
}),
|
|
80
|
-
const { __scopeMenu: o, forceMount: n, children: t, container: r } = e,
|
|
81
|
-
return /* @__PURE__ */ c(
|
|
79
|
+
}), un = (e) => {
|
|
80
|
+
const { __scopeMenu: o, forceMount: n, children: t, container: r } = e, a = _(le, o);
|
|
81
|
+
return /* @__PURE__ */ c(yo, { scope: o, forceMount: n, children: /* @__PURE__ */ c(W, { present: n || a.open, children: /* @__PURE__ */ c(Zn, { asChild: !0, container: r, children: t }) }) });
|
|
82
82
|
};
|
|
83
|
-
|
|
84
|
-
var
|
|
83
|
+
un.displayName = le;
|
|
84
|
+
var y = "MenuContent", [So, pe] = D(y), dn = s.forwardRef(
|
|
85
85
|
(e, o) => {
|
|
86
|
-
const n =
|
|
87
|
-
return /* @__PURE__ */ c(L.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ c(W, { present: t ||
|
|
86
|
+
const n = cn(y, e.__scopeMenu), { forceMount: t = n.forceMount, ...r } = e, a = _(y, e.__scopeMenu), i = U(y, e.__scopeMenu);
|
|
87
|
+
return /* @__PURE__ */ c(L.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ c(W, { present: t || a.open, children: /* @__PURE__ */ c(L.Slot, { scope: e.__scopeMenu, children: i.modal ? /* @__PURE__ */ c(_o, { ...r, ref: o }) : /* @__PURE__ */ c(Ro, { ...r, ref: o }) }) }) });
|
|
88
88
|
}
|
|
89
|
-
),
|
|
89
|
+
), _o = s.forwardRef(
|
|
90
90
|
(e, o) => {
|
|
91
|
-
const n = _(
|
|
92
|
-
return
|
|
93
|
-
const
|
|
94
|
-
if (
|
|
91
|
+
const n = _(y, e.__scopeMenu), t = s.useRef(null), r = F(o, t);
|
|
92
|
+
return s.useEffect(() => {
|
|
93
|
+
const a = t.current;
|
|
94
|
+
if (a) return Jn(a);
|
|
95
95
|
}, []), /* @__PURE__ */ c(
|
|
96
|
-
|
|
96
|
+
me,
|
|
97
97
|
{
|
|
98
98
|
...e,
|
|
99
99
|
ref: r,
|
|
100
100
|
trapFocus: n.open,
|
|
101
101
|
disableOutsidePointerEvents: n.open,
|
|
102
102
|
disableOutsideScroll: !0,
|
|
103
|
-
onFocusOutside:
|
|
103
|
+
onFocusOutside: h(
|
|
104
104
|
e.onFocusOutside,
|
|
105
|
-
(
|
|
105
|
+
(a) => a.preventDefault(),
|
|
106
106
|
{ checkForDefaultPrevented: !1 }
|
|
107
107
|
),
|
|
108
108
|
onDismiss: () => n.onOpenChange(!1)
|
|
109
109
|
}
|
|
110
110
|
);
|
|
111
111
|
}
|
|
112
|
-
),
|
|
113
|
-
const n = _(
|
|
112
|
+
), Ro = s.forwardRef((e, o) => {
|
|
113
|
+
const n = _(y, e.__scopeMenu);
|
|
114
114
|
return /* @__PURE__ */ c(
|
|
115
|
-
|
|
115
|
+
me,
|
|
116
116
|
{
|
|
117
117
|
...e,
|
|
118
118
|
ref: o,
|
|
@@ -122,122 +122,122 @@ var C = "MenuContent", [bo, ue] = D(C), sn = a.forwardRef(
|
|
|
122
122
|
onDismiss: () => n.onOpenChange(!1)
|
|
123
123
|
}
|
|
124
124
|
);
|
|
125
|
-
}),
|
|
125
|
+
}), Do = Xn("MenuContent.ScrollLock"), me = s.forwardRef(
|
|
126
126
|
(e, o) => {
|
|
127
127
|
const {
|
|
128
128
|
__scopeMenu: n,
|
|
129
129
|
loop: t = !1,
|
|
130
130
|
trapFocus: r,
|
|
131
|
-
onOpenAutoFocus:
|
|
131
|
+
onOpenAutoFocus: a,
|
|
132
132
|
onCloseAutoFocus: i,
|
|
133
|
-
disableOutsidePointerEvents:
|
|
134
|
-
onEntryFocus:
|
|
135
|
-
onEscapeKeyDown:
|
|
133
|
+
disableOutsidePointerEvents: u,
|
|
134
|
+
onEntryFocus: m,
|
|
135
|
+
onEscapeKeyDown: f,
|
|
136
136
|
onPointerDownOutside: l,
|
|
137
|
-
onFocusOutside:
|
|
138
|
-
onInteractOutside:
|
|
139
|
-
onDismiss:
|
|
140
|
-
disableOutsideScroll:
|
|
137
|
+
onFocusOutside: d,
|
|
138
|
+
onInteractOutside: g,
|
|
139
|
+
onDismiss: w,
|
|
140
|
+
disableOutsideScroll: v,
|
|
141
141
|
...x
|
|
142
|
-
} = e, T = _(
|
|
143
|
-
const N =
|
|
144
|
-
(function
|
|
145
|
-
|
|
146
|
-
})(N),
|
|
142
|
+
} = e, T = _(y, n), I = U(y, n), Gn = $(n), Fn = rn(n), Ve = wo(n), [Kn, Be] = s.useState(null), V = s.useRef(null), $n = F(o, V, T.onContentChange), B = s.useRef(0), z = s.useRef(""), Un = s.useRef(0), te = s.useRef(null), ze = s.useRef("right"), re = s.useRef(0), Vn = v ? eo : s.Fragment, Bn = v ? { as: Do, allowPinchZoom: !0 } : void 0, zn = (p) => {
|
|
143
|
+
const N = z.current + p, R = Ve().filter((C) => !C.disabled), A = document.activeElement, ae = R.find((C) => C.ref.current === A)?.textValue, se = R.map((C) => C.textValue), je = Fo(se, N, ae), k = R.find((C) => C.textValue === je)?.ref.current;
|
|
144
|
+
(function C(Ye) {
|
|
145
|
+
z.current = Ye, window.clearTimeout(B.current), Ye !== "" && (B.current = window.setTimeout(() => C(""), 1e3));
|
|
146
|
+
})(N), k && setTimeout(() => k.focus());
|
|
147
147
|
};
|
|
148
|
-
|
|
149
|
-
const P =
|
|
148
|
+
s.useEffect(() => () => window.clearTimeout(B.current), []), Qn();
|
|
149
|
+
const P = s.useCallback((p) => ze.current === te.current?.side && $o(p, te.current?.area), []);
|
|
150
150
|
return /* @__PURE__ */ c(
|
|
151
|
-
|
|
151
|
+
So,
|
|
152
152
|
{
|
|
153
153
|
scope: n,
|
|
154
|
-
searchRef:
|
|
155
|
-
onItemEnter:
|
|
154
|
+
searchRef: z,
|
|
155
|
+
onItemEnter: s.useCallback(
|
|
156
156
|
(p) => {
|
|
157
157
|
P(p) && p.preventDefault();
|
|
158
158
|
},
|
|
159
159
|
[P]
|
|
160
160
|
),
|
|
161
|
-
onItemLeave:
|
|
161
|
+
onItemLeave: s.useCallback(
|
|
162
162
|
(p) => {
|
|
163
|
-
P(p) || (
|
|
163
|
+
P(p) || (V.current?.focus(), Be(null));
|
|
164
164
|
},
|
|
165
165
|
[P]
|
|
166
166
|
),
|
|
167
|
-
onTriggerLeave:
|
|
167
|
+
onTriggerLeave: s.useCallback(
|
|
168
168
|
(p) => {
|
|
169
169
|
P(p) && p.preventDefault();
|
|
170
170
|
},
|
|
171
171
|
[P]
|
|
172
172
|
),
|
|
173
|
-
pointerGraceTimerRef:
|
|
174
|
-
onPointerGraceIntentChange:
|
|
175
|
-
|
|
173
|
+
pointerGraceTimerRef: Un,
|
|
174
|
+
onPointerGraceIntentChange: s.useCallback((p) => {
|
|
175
|
+
te.current = p;
|
|
176
176
|
}, []),
|
|
177
|
-
children: /* @__PURE__ */ c(
|
|
178
|
-
|
|
177
|
+
children: /* @__PURE__ */ c(Vn, { ...Bn, children: /* @__PURE__ */ c(
|
|
178
|
+
no,
|
|
179
179
|
{
|
|
180
180
|
asChild: !0,
|
|
181
181
|
trapped: r,
|
|
182
|
-
onMountAutoFocus:
|
|
183
|
-
p.preventDefault(),
|
|
182
|
+
onMountAutoFocus: h(a, (p) => {
|
|
183
|
+
p.preventDefault(), V.current?.focus({ preventScroll: !0 });
|
|
184
184
|
}),
|
|
185
185
|
onUnmountAutoFocus: i,
|
|
186
186
|
children: /* @__PURE__ */ c(
|
|
187
|
-
|
|
187
|
+
qn,
|
|
188
188
|
{
|
|
189
189
|
asChild: !0,
|
|
190
|
-
disableOutsidePointerEvents:
|
|
191
|
-
onEscapeKeyDown:
|
|
190
|
+
disableOutsidePointerEvents: u,
|
|
191
|
+
onEscapeKeyDown: f,
|
|
192
192
|
onPointerDownOutside: l,
|
|
193
|
-
onFocusOutside:
|
|
194
|
-
onInteractOutside:
|
|
195
|
-
onDismiss:
|
|
193
|
+
onFocusOutside: d,
|
|
194
|
+
onInteractOutside: g,
|
|
195
|
+
onDismiss: w,
|
|
196
196
|
children: /* @__PURE__ */ c(
|
|
197
|
-
|
|
197
|
+
so,
|
|
198
198
|
{
|
|
199
199
|
asChild: !0,
|
|
200
|
-
...
|
|
200
|
+
...Fn,
|
|
201
201
|
dir: I.dir,
|
|
202
202
|
orientation: "vertical",
|
|
203
203
|
loop: t,
|
|
204
|
-
currentTabStopId:
|
|
205
|
-
onCurrentTabStopIdChange:
|
|
206
|
-
onEntryFocus:
|
|
204
|
+
currentTabStopId: Kn,
|
|
205
|
+
onCurrentTabStopIdChange: Be,
|
|
206
|
+
onEntryFocus: h(m, (p) => {
|
|
207
207
|
I.isUsingKeyboardRef.current || p.preventDefault();
|
|
208
208
|
}),
|
|
209
209
|
preventScrollOnEntryFocus: !0,
|
|
210
210
|
children: /* @__PURE__ */ c(
|
|
211
|
-
|
|
211
|
+
ro,
|
|
212
212
|
{
|
|
213
213
|
role: "menu",
|
|
214
214
|
"aria-orientation": "vertical",
|
|
215
|
-
"data-state":
|
|
215
|
+
"data-state": xn(T.open),
|
|
216
216
|
"data-radix-menu-content": "",
|
|
217
217
|
dir: I.dir,
|
|
218
|
-
...
|
|
218
|
+
...Gn,
|
|
219
219
|
...x,
|
|
220
|
-
ref:
|
|
220
|
+
ref: $n,
|
|
221
221
|
style: { outline: "none", ...x.style },
|
|
222
|
-
onKeyDown:
|
|
223
|
-
const
|
|
224
|
-
|
|
225
|
-
const
|
|
226
|
-
if (p.target !==
|
|
222
|
+
onKeyDown: h(x.onKeyDown, (p) => {
|
|
223
|
+
const R = p.target.closest("[data-radix-menu-content]") === p.currentTarget, A = p.ctrlKey || p.altKey || p.metaKey, ae = p.key.length === 1;
|
|
224
|
+
R && (p.key === "Tab" && p.preventDefault(), !A && ae && zn(p.key));
|
|
225
|
+
const se = V.current;
|
|
226
|
+
if (p.target !== se || !go.includes(p.key)) return;
|
|
227
227
|
p.preventDefault();
|
|
228
|
-
const
|
|
229
|
-
|
|
228
|
+
const k = Ve().filter((C) => !C.disabled).map((C) => C.ref.current);
|
|
229
|
+
on.includes(p.key) && k.reverse(), Lo(k);
|
|
230
230
|
}),
|
|
231
|
-
onBlur:
|
|
232
|
-
p.currentTarget.contains(p.target) || (window.clearTimeout(
|
|
231
|
+
onBlur: h(e.onBlur, (p) => {
|
|
232
|
+
p.currentTarget.contains(p.target) || (window.clearTimeout(B.current), z.current = "");
|
|
233
233
|
}),
|
|
234
|
-
onPointerMove:
|
|
234
|
+
onPointerMove: h(
|
|
235
235
|
e.onPointerMove,
|
|
236
236
|
G((p) => {
|
|
237
|
-
const N = p.target,
|
|
238
|
-
if (p.currentTarget.contains(N) &&
|
|
239
|
-
const A = p.clientX >
|
|
240
|
-
|
|
237
|
+
const N = p.target, R = re.current !== p.clientX;
|
|
238
|
+
if (p.currentTarget.contains(N) && R) {
|
|
239
|
+
const A = p.clientX > re.current ? "right" : "left";
|
|
240
|
+
ze.current = A, re.current = p.clientX;
|
|
241
241
|
}
|
|
242
242
|
})
|
|
243
243
|
)
|
|
@@ -253,134 +253,134 @@ var C = "MenuContent", [bo, ue] = D(C), sn = a.forwardRef(
|
|
|
253
253
|
);
|
|
254
254
|
}
|
|
255
255
|
);
|
|
256
|
-
|
|
257
|
-
var
|
|
256
|
+
dn.displayName = y;
|
|
257
|
+
var xo = "MenuGroup", fe = s.forwardRef(
|
|
258
258
|
(e, o) => {
|
|
259
259
|
const { __scopeMenu: n, ...t } = e;
|
|
260
260
|
return /* @__PURE__ */ c(E.div, { role: "group", ...t, ref: o });
|
|
261
261
|
}
|
|
262
262
|
);
|
|
263
|
-
|
|
264
|
-
var
|
|
263
|
+
fe.displayName = xo;
|
|
264
|
+
var Io = "MenuLabel", ln = s.forwardRef(
|
|
265
265
|
(e, o) => {
|
|
266
266
|
const { __scopeMenu: n, ...t } = e;
|
|
267
267
|
return /* @__PURE__ */ c(E.div, { ...t, ref: o });
|
|
268
268
|
}
|
|
269
269
|
);
|
|
270
|
-
|
|
271
|
-
var
|
|
270
|
+
ln.displayName = Io;
|
|
271
|
+
var Y = "MenuItem", Xe = "menu.itemSelect", J = s.forwardRef(
|
|
272
272
|
(e, o) => {
|
|
273
|
-
const { disabled: n = !1, onSelect: t, ...r } = e,
|
|
274
|
-
const
|
|
275
|
-
if (!n &&
|
|
276
|
-
const
|
|
277
|
-
|
|
273
|
+
const { disabled: n = !1, onSelect: t, ...r } = e, a = s.useRef(null), i = U(Y, e.__scopeMenu), u = pe(Y, e.__scopeMenu), m = F(o, a), f = s.useRef(!1), l = () => {
|
|
274
|
+
const d = a.current;
|
|
275
|
+
if (!n && d) {
|
|
276
|
+
const g = new CustomEvent(Xe, { bubbles: !0, cancelable: !0 });
|
|
277
|
+
d.addEventListener(Xe, (w) => t?.(w), { once: !0 }), Yn(d, g), g.defaultPrevented ? f.current = !1 : i.onClose();
|
|
278
278
|
}
|
|
279
279
|
};
|
|
280
280
|
return /* @__PURE__ */ c(
|
|
281
|
-
|
|
281
|
+
pn,
|
|
282
282
|
{
|
|
283
283
|
...r,
|
|
284
|
-
ref:
|
|
284
|
+
ref: m,
|
|
285
285
|
disabled: n,
|
|
286
|
-
onClick:
|
|
287
|
-
onPointerDown: (
|
|
288
|
-
e.onPointerDown?.(
|
|
286
|
+
onClick: h(e.onClick, l),
|
|
287
|
+
onPointerDown: (d) => {
|
|
288
|
+
e.onPointerDown?.(d), f.current = !0;
|
|
289
289
|
},
|
|
290
|
-
onPointerUp:
|
|
291
|
-
|
|
290
|
+
onPointerUp: h(e.onPointerUp, (d) => {
|
|
291
|
+
f.current || d.currentTarget?.click();
|
|
292
292
|
}),
|
|
293
|
-
onKeyDown:
|
|
294
|
-
const
|
|
295
|
-
n ||
|
|
293
|
+
onKeyDown: h(e.onKeyDown, (d) => {
|
|
294
|
+
const g = u.searchRef.current !== "";
|
|
295
|
+
n || g && d.key === " " || ce.includes(d.key) && (d.currentTarget.click(), d.preventDefault());
|
|
296
296
|
})
|
|
297
297
|
}
|
|
298
298
|
);
|
|
299
299
|
}
|
|
300
300
|
);
|
|
301
|
-
|
|
302
|
-
var
|
|
301
|
+
J.displayName = Y;
|
|
302
|
+
var pn = s.forwardRef(
|
|
303
303
|
(e, o) => {
|
|
304
|
-
const { __scopeMenu: n, disabled: t = !1, textValue: r, ...
|
|
305
|
-
return
|
|
306
|
-
const
|
|
307
|
-
|
|
308
|
-
}, [
|
|
304
|
+
const { __scopeMenu: n, disabled: t = !1, textValue: r, ...a } = e, i = pe(Y, n), u = rn(n), m = s.useRef(null), f = F(o, m), [l, d] = s.useState(!1), [g, w] = s.useState("");
|
|
305
|
+
return s.useEffect(() => {
|
|
306
|
+
const v = m.current;
|
|
307
|
+
v && w((v.textContent ?? "").trim());
|
|
308
|
+
}, [a.children]), /* @__PURE__ */ c(
|
|
309
309
|
L.ItemSlot,
|
|
310
310
|
{
|
|
311
311
|
scope: n,
|
|
312
312
|
disabled: t,
|
|
313
|
-
textValue: r ??
|
|
314
|
-
children: /* @__PURE__ */ c(
|
|
313
|
+
textValue: r ?? g,
|
|
314
|
+
children: /* @__PURE__ */ c(ao, { asChild: !0, ...u, focusable: !t, children: /* @__PURE__ */ c(
|
|
315
315
|
E.div,
|
|
316
316
|
{
|
|
317
317
|
role: "menuitem",
|
|
318
318
|
"data-highlighted": l ? "" : void 0,
|
|
319
319
|
"aria-disabled": t || void 0,
|
|
320
320
|
"data-disabled": t ? "" : void 0,
|
|
321
|
-
...
|
|
322
|
-
ref:
|
|
323
|
-
onPointerMove:
|
|
321
|
+
...a,
|
|
322
|
+
ref: f,
|
|
323
|
+
onPointerMove: h(
|
|
324
324
|
e.onPointerMove,
|
|
325
|
-
G((
|
|
326
|
-
t ? i.onItemLeave(
|
|
325
|
+
G((v) => {
|
|
326
|
+
t ? i.onItemLeave(v) : (i.onItemEnter(v), v.defaultPrevented || v.currentTarget.focus({ preventScroll: !0 }));
|
|
327
327
|
})
|
|
328
328
|
),
|
|
329
|
-
onPointerLeave:
|
|
329
|
+
onPointerLeave: h(
|
|
330
330
|
e.onPointerLeave,
|
|
331
|
-
G((
|
|
331
|
+
G((v) => i.onItemLeave(v))
|
|
332
332
|
),
|
|
333
|
-
onFocus:
|
|
334
|
-
onBlur:
|
|
333
|
+
onFocus: h(e.onFocus, () => d(!0)),
|
|
334
|
+
onBlur: h(e.onBlur, () => d(!1))
|
|
335
335
|
}
|
|
336
336
|
) })
|
|
337
337
|
}
|
|
338
338
|
);
|
|
339
339
|
}
|
|
340
|
-
),
|
|
340
|
+
), Po = "MenuCheckboxItem", mn = s.forwardRef(
|
|
341
341
|
(e, o) => {
|
|
342
342
|
const { checked: n = !1, onCheckedChange: t, ...r } = e;
|
|
343
|
-
return /* @__PURE__ */ c(
|
|
344
|
-
|
|
343
|
+
return /* @__PURE__ */ c(wn, { scope: e.__scopeMenu, checked: n, children: /* @__PURE__ */ c(
|
|
344
|
+
J,
|
|
345
345
|
{
|
|
346
346
|
role: "menuitemcheckbox",
|
|
347
|
-
"aria-checked":
|
|
347
|
+
"aria-checked": X(n) ? "mixed" : n,
|
|
348
348
|
...r,
|
|
349
349
|
ref: o,
|
|
350
|
-
"data-state":
|
|
351
|
-
onSelect:
|
|
350
|
+
"data-state": ve(n),
|
|
351
|
+
onSelect: h(
|
|
352
352
|
r.onSelect,
|
|
353
|
-
() => t?.(
|
|
353
|
+
() => t?.(X(n) ? !0 : !n),
|
|
354
354
|
{ checkForDefaultPrevented: !1 }
|
|
355
355
|
)
|
|
356
356
|
}
|
|
357
357
|
) });
|
|
358
358
|
}
|
|
359
359
|
);
|
|
360
|
-
|
|
361
|
-
var
|
|
362
|
-
|
|
360
|
+
mn.displayName = Po;
|
|
361
|
+
var fn = "MenuRadioGroup", [No, Eo] = D(
|
|
362
|
+
fn,
|
|
363
363
|
{ value: void 0, onValueChange: () => {
|
|
364
364
|
} }
|
|
365
|
-
),
|
|
365
|
+
), gn = s.forwardRef(
|
|
366
366
|
(e, o) => {
|
|
367
|
-
const { value: n, onValueChange: t, ...r } = e,
|
|
368
|
-
return /* @__PURE__ */ c(
|
|
367
|
+
const { value: n, onValueChange: t, ...r } = e, a = ue(t);
|
|
368
|
+
return /* @__PURE__ */ c(No, { scope: e.__scopeMenu, value: n, onValueChange: a, children: /* @__PURE__ */ c(fe, { ...r, ref: o }) });
|
|
369
369
|
}
|
|
370
370
|
);
|
|
371
|
-
|
|
372
|
-
var
|
|
371
|
+
gn.displayName = fn;
|
|
372
|
+
var hn = "MenuRadioItem", vn = s.forwardRef(
|
|
373
373
|
(e, o) => {
|
|
374
|
-
const { value: n, ...t } = e, r =
|
|
375
|
-
return /* @__PURE__ */ c(
|
|
376
|
-
|
|
374
|
+
const { value: n, ...t } = e, r = Eo(hn, e.__scopeMenu), a = n === r.value;
|
|
375
|
+
return /* @__PURE__ */ c(wn, { scope: e.__scopeMenu, checked: a, children: /* @__PURE__ */ c(
|
|
376
|
+
J,
|
|
377
377
|
{
|
|
378
378
|
role: "menuitemradio",
|
|
379
|
-
"aria-checked":
|
|
379
|
+
"aria-checked": a,
|
|
380
380
|
...t,
|
|
381
381
|
ref: o,
|
|
382
|
-
"data-state":
|
|
383
|
-
onSelect:
|
|
382
|
+
"data-state": ve(a),
|
|
383
|
+
onSelect: h(
|
|
384
384
|
t.onSelect,
|
|
385
385
|
() => r.onValueChange?.(n),
|
|
386
386
|
{ checkForDefaultPrevented: !1 }
|
|
@@ -389,31 +389,31 @@ var fn = "MenuRadioItem", mn = a.forwardRef(
|
|
|
389
389
|
) });
|
|
390
390
|
}
|
|
391
391
|
);
|
|
392
|
-
|
|
393
|
-
var
|
|
394
|
-
|
|
392
|
+
vn.displayName = hn;
|
|
393
|
+
var ge = "MenuItemIndicator", [wn, To] = D(
|
|
394
|
+
ge,
|
|
395
395
|
{ checked: !1 }
|
|
396
|
-
),
|
|
396
|
+
), Mn = s.forwardRef(
|
|
397
397
|
(e, o) => {
|
|
398
|
-
const { __scopeMenu: n, forceMount: t, ...r } = e,
|
|
398
|
+
const { __scopeMenu: n, forceMount: t, ...r } = e, a = To(ge, n);
|
|
399
399
|
return /* @__PURE__ */ c(
|
|
400
400
|
W,
|
|
401
401
|
{
|
|
402
|
-
present: t ||
|
|
402
|
+
present: t || X(a.checked) || a.checked === !0,
|
|
403
403
|
children: /* @__PURE__ */ c(
|
|
404
404
|
E.span,
|
|
405
405
|
{
|
|
406
406
|
...r,
|
|
407
407
|
ref: o,
|
|
408
|
-
"data-state":
|
|
408
|
+
"data-state": ve(a.checked)
|
|
409
409
|
}
|
|
410
410
|
)
|
|
411
411
|
}
|
|
412
412
|
);
|
|
413
413
|
}
|
|
414
414
|
);
|
|
415
|
-
|
|
416
|
-
var
|
|
415
|
+
Mn.displayName = ge;
|
|
416
|
+
var Ao = "MenuSeparator", bn = s.forwardRef(
|
|
417
417
|
(e, o) => {
|
|
418
418
|
const { __scopeMenu: n, ...t } = e;
|
|
419
419
|
return /* @__PURE__ */ c(
|
|
@@ -427,266 +427,266 @@ var No = "MenuSeparator", gn = a.forwardRef(
|
|
|
427
427
|
);
|
|
428
428
|
}
|
|
429
429
|
);
|
|
430
|
-
|
|
431
|
-
var
|
|
430
|
+
bn.displayName = Ao;
|
|
431
|
+
var ko = "MenuArrow", Cn = s.forwardRef(
|
|
432
432
|
(e, o) => {
|
|
433
433
|
const { __scopeMenu: n, ...t } = e, r = $(n);
|
|
434
|
-
return /* @__PURE__ */ c(
|
|
434
|
+
return /* @__PURE__ */ c(to, { ...r, ...t, ref: o });
|
|
435
435
|
}
|
|
436
436
|
);
|
|
437
|
-
|
|
438
|
-
var
|
|
439
|
-
const { __scopeMenu: o, children: n, open: t = !1, onOpenChange: r } = e,
|
|
440
|
-
return
|
|
441
|
-
|
|
437
|
+
Cn.displayName = ko;
|
|
438
|
+
var he = "MenuSub", [Oo, yn] = D(he), Sn = (e) => {
|
|
439
|
+
const { __scopeMenu: o, children: n, open: t = !1, onOpenChange: r } = e, a = _(he, o), i = $(o), [u, m] = s.useState(null), [f, l] = s.useState(null), d = ue(r);
|
|
440
|
+
return s.useEffect(() => (a.open === !1 && d(!1), () => d(!1)), [a.open, d]), /* @__PURE__ */ c(Je, { ...i, children: /* @__PURE__ */ c(
|
|
441
|
+
an,
|
|
442
442
|
{
|
|
443
443
|
scope: o,
|
|
444
444
|
open: t,
|
|
445
|
-
onOpenChange:
|
|
446
|
-
content:
|
|
445
|
+
onOpenChange: d,
|
|
446
|
+
content: f,
|
|
447
447
|
onContentChange: l,
|
|
448
448
|
children: /* @__PURE__ */ c(
|
|
449
|
-
|
|
449
|
+
Oo,
|
|
450
450
|
{
|
|
451
451
|
scope: o,
|
|
452
|
-
contentId:
|
|
453
|
-
triggerId:
|
|
454
|
-
trigger:
|
|
455
|
-
onTriggerChange:
|
|
452
|
+
contentId: j(),
|
|
453
|
+
triggerId: j(),
|
|
454
|
+
trigger: u,
|
|
455
|
+
onTriggerChange: m,
|
|
456
456
|
children: n
|
|
457
457
|
}
|
|
458
458
|
)
|
|
459
459
|
}
|
|
460
460
|
) });
|
|
461
461
|
};
|
|
462
|
-
|
|
463
|
-
var
|
|
462
|
+
Sn.displayName = he;
|
|
463
|
+
var O = "MenuSubTrigger", _n = s.forwardRef(
|
|
464
464
|
(e, o) => {
|
|
465
|
-
const n = _(
|
|
465
|
+
const n = _(O, e.__scopeMenu), t = U(O, e.__scopeMenu), r = yn(O, e.__scopeMenu), a = pe(O, e.__scopeMenu), i = s.useRef(null), { pointerGraceTimerRef: u, onPointerGraceIntentChange: m } = a, f = { __scopeMenu: e.__scopeMenu }, l = s.useCallback(() => {
|
|
466
466
|
i.current && window.clearTimeout(i.current), i.current = null;
|
|
467
467
|
}, []);
|
|
468
|
-
return
|
|
469
|
-
const
|
|
468
|
+
return s.useEffect(() => l, [l]), s.useEffect(() => {
|
|
469
|
+
const d = u.current;
|
|
470
470
|
return () => {
|
|
471
|
-
window.clearTimeout(
|
|
471
|
+
window.clearTimeout(d), m(null);
|
|
472
472
|
};
|
|
473
|
-
}, [
|
|
474
|
-
|
|
473
|
+
}, [u, m]), /* @__PURE__ */ c(de, { asChild: !0, ...f, children: /* @__PURE__ */ c(
|
|
474
|
+
pn,
|
|
475
475
|
{
|
|
476
476
|
id: r.triggerId,
|
|
477
477
|
"aria-haspopup": "menu",
|
|
478
478
|
"aria-expanded": n.open,
|
|
479
479
|
"aria-controls": r.contentId,
|
|
480
|
-
"data-state":
|
|
480
|
+
"data-state": xn(n.open),
|
|
481
481
|
...e,
|
|
482
|
-
ref:
|
|
483
|
-
onClick: (
|
|
484
|
-
e.onClick?.(
|
|
482
|
+
ref: He(o, r.onTriggerChange),
|
|
483
|
+
onClick: (d) => {
|
|
484
|
+
e.onClick?.(d), !(e.disabled || d.defaultPrevented) && (d.currentTarget.focus(), n.open || n.onOpenChange(!0));
|
|
485
485
|
},
|
|
486
|
-
onPointerMove:
|
|
486
|
+
onPointerMove: h(
|
|
487
487
|
e.onPointerMove,
|
|
488
|
-
G((
|
|
489
|
-
|
|
488
|
+
G((d) => {
|
|
489
|
+
a.onItemEnter(d), !d.defaultPrevented && !e.disabled && !n.open && !i.current && (a.onPointerGraceIntentChange(null), i.current = window.setTimeout(() => {
|
|
490
490
|
n.onOpenChange(!0), l();
|
|
491
491
|
}, 100));
|
|
492
492
|
})
|
|
493
493
|
),
|
|
494
|
-
onPointerLeave:
|
|
494
|
+
onPointerLeave: h(
|
|
495
495
|
e.onPointerLeave,
|
|
496
|
-
G((
|
|
496
|
+
G((d) => {
|
|
497
497
|
l();
|
|
498
|
-
const
|
|
499
|
-
if (
|
|
500
|
-
const
|
|
501
|
-
|
|
498
|
+
const g = n.content?.getBoundingClientRect();
|
|
499
|
+
if (g) {
|
|
500
|
+
const w = n.content?.dataset.side, v = w === "right", x = v ? -5 : 5, T = g[v ? "left" : "right"], I = g[v ? "right" : "left"];
|
|
501
|
+
a.onPointerGraceIntentChange({
|
|
502
502
|
area: [
|
|
503
503
|
// Apply a bleed on clientX to ensure that our exit point is
|
|
504
504
|
// consistently within polygon bounds
|
|
505
|
-
{ x:
|
|
506
|
-
{ x: T, y:
|
|
507
|
-
{ x: I, y:
|
|
508
|
-
{ x: I, y:
|
|
509
|
-
{ x: T, y:
|
|
505
|
+
{ x: d.clientX + x, y: d.clientY },
|
|
506
|
+
{ x: T, y: g.top },
|
|
507
|
+
{ x: I, y: g.top },
|
|
508
|
+
{ x: I, y: g.bottom },
|
|
509
|
+
{ x: T, y: g.bottom }
|
|
510
510
|
],
|
|
511
|
-
side:
|
|
512
|
-
}), window.clearTimeout(
|
|
513
|
-
() =>
|
|
511
|
+
side: w
|
|
512
|
+
}), window.clearTimeout(u.current), u.current = window.setTimeout(
|
|
513
|
+
() => a.onPointerGraceIntentChange(null),
|
|
514
514
|
300
|
|
515
515
|
);
|
|
516
516
|
} else {
|
|
517
|
-
if (
|
|
518
|
-
|
|
517
|
+
if (a.onTriggerLeave(d), d.defaultPrevented) return;
|
|
518
|
+
a.onPointerGraceIntentChange(null);
|
|
519
519
|
}
|
|
520
520
|
})
|
|
521
521
|
),
|
|
522
|
-
onKeyDown:
|
|
523
|
-
const
|
|
524
|
-
e.disabled ||
|
|
522
|
+
onKeyDown: h(e.onKeyDown, (d) => {
|
|
523
|
+
const g = a.searchRef.current !== "";
|
|
524
|
+
e.disabled || g && d.key === " " || ho[t.dir].includes(d.key) && (n.onOpenChange(!0), n.content?.focus(), d.preventDefault());
|
|
525
525
|
})
|
|
526
526
|
}
|
|
527
527
|
) });
|
|
528
528
|
}
|
|
529
529
|
);
|
|
530
|
-
|
|
531
|
-
var
|
|
530
|
+
_n.displayName = O;
|
|
531
|
+
var Rn = "MenuSubContent", Dn = s.forwardRef(
|
|
532
532
|
(e, o) => {
|
|
533
|
-
const n =
|
|
534
|
-
return /* @__PURE__ */ c(L.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ c(W, { present: t ||
|
|
535
|
-
|
|
533
|
+
const n = cn(y, e.__scopeMenu), { forceMount: t = n.forceMount, ...r } = e, a = _(y, e.__scopeMenu), i = U(y, e.__scopeMenu), u = yn(Rn, e.__scopeMenu), m = s.useRef(null), f = F(o, m);
|
|
534
|
+
return /* @__PURE__ */ c(L.Provider, { scope: e.__scopeMenu, children: /* @__PURE__ */ c(W, { present: t || a.open, children: /* @__PURE__ */ c(L.Slot, { scope: e.__scopeMenu, children: /* @__PURE__ */ c(
|
|
535
|
+
me,
|
|
536
536
|
{
|
|
537
|
-
id:
|
|
538
|
-
"aria-labelledby":
|
|
537
|
+
id: u.contentId,
|
|
538
|
+
"aria-labelledby": u.triggerId,
|
|
539
539
|
...r,
|
|
540
|
-
ref:
|
|
540
|
+
ref: f,
|
|
541
541
|
align: "start",
|
|
542
542
|
side: i.dir === "rtl" ? "left" : "right",
|
|
543
543
|
disableOutsidePointerEvents: !1,
|
|
544
544
|
disableOutsideScroll: !1,
|
|
545
545
|
trapFocus: !1,
|
|
546
546
|
onOpenAutoFocus: (l) => {
|
|
547
|
-
i.isUsingKeyboardRef.current &&
|
|
547
|
+
i.isUsingKeyboardRef.current && m.current?.focus(), l.preventDefault();
|
|
548
548
|
},
|
|
549
549
|
onCloseAutoFocus: (l) => l.preventDefault(),
|
|
550
|
-
onFocusOutside:
|
|
551
|
-
l.target !==
|
|
550
|
+
onFocusOutside: h(e.onFocusOutside, (l) => {
|
|
551
|
+
l.target !== u.trigger && a.onOpenChange(!1);
|
|
552
552
|
}),
|
|
553
|
-
onEscapeKeyDown:
|
|
553
|
+
onEscapeKeyDown: h(e.onEscapeKeyDown, (l) => {
|
|
554
554
|
i.onClose(), l.preventDefault();
|
|
555
555
|
}),
|
|
556
|
-
onKeyDown:
|
|
557
|
-
const
|
|
558
|
-
|
|
556
|
+
onKeyDown: h(e.onKeyDown, (l) => {
|
|
557
|
+
const d = l.currentTarget.contains(l.target), g = vo[i.dir].includes(l.key);
|
|
558
|
+
d && g && (a.onOpenChange(!1), u.trigger?.focus(), l.preventDefault());
|
|
559
559
|
})
|
|
560
560
|
}
|
|
561
561
|
) }) }) });
|
|
562
562
|
}
|
|
563
563
|
);
|
|
564
|
-
|
|
565
|
-
function
|
|
564
|
+
Dn.displayName = Rn;
|
|
565
|
+
function xn(e) {
|
|
566
566
|
return e ? "open" : "closed";
|
|
567
567
|
}
|
|
568
|
-
function
|
|
568
|
+
function X(e) {
|
|
569
569
|
return e === "indeterminate";
|
|
570
570
|
}
|
|
571
|
-
function
|
|
572
|
-
return
|
|
571
|
+
function ve(e) {
|
|
572
|
+
return X(e) ? "indeterminate" : e ? "checked" : "unchecked";
|
|
573
573
|
}
|
|
574
|
-
function
|
|
574
|
+
function Lo(e) {
|
|
575
575
|
const o = document.activeElement;
|
|
576
576
|
for (const n of e)
|
|
577
577
|
if (n === o || (n.focus(), document.activeElement !== o)) return;
|
|
578
578
|
}
|
|
579
|
-
function
|
|
579
|
+
function Go(e, o) {
|
|
580
580
|
return e.map((n, t) => e[(o + t) % e.length]);
|
|
581
581
|
}
|
|
582
|
-
function
|
|
583
|
-
const r = o.length > 1 && Array.from(o).every((
|
|
584
|
-
let i =
|
|
585
|
-
r.length === 1 && (i = i.filter((
|
|
586
|
-
const
|
|
587
|
-
(
|
|
582
|
+
function Fo(e, o, n) {
|
|
583
|
+
const r = o.length > 1 && Array.from(o).every((f) => f === o[0]) ? o[0] : o, a = n ? e.indexOf(n) : -1;
|
|
584
|
+
let i = Go(e, Math.max(a, 0));
|
|
585
|
+
r.length === 1 && (i = i.filter((f) => f !== n));
|
|
586
|
+
const m = i.find(
|
|
587
|
+
(f) => f.toLowerCase().startsWith(r.toLowerCase())
|
|
588
588
|
);
|
|
589
|
-
return
|
|
589
|
+
return m !== n ? m : void 0;
|
|
590
590
|
}
|
|
591
|
-
function
|
|
591
|
+
function Ko(e, o) {
|
|
592
592
|
const { x: n, y: t } = e;
|
|
593
593
|
let r = !1;
|
|
594
|
-
for (let
|
|
595
|
-
const
|
|
596
|
-
l > t !=
|
|
594
|
+
for (let a = 0, i = o.length - 1; a < o.length; i = a++) {
|
|
595
|
+
const u = o[a], m = o[i], f = u.x, l = u.y, d = m.x, g = m.y;
|
|
596
|
+
l > t != g > t && n < (d - f) * (t - l) / (g - l) + f && (r = !r);
|
|
597
597
|
}
|
|
598
598
|
return r;
|
|
599
599
|
}
|
|
600
|
-
function
|
|
600
|
+
function $o(e, o) {
|
|
601
601
|
if (!o) return !1;
|
|
602
602
|
const n = { x: e.clientX, y: e.clientY };
|
|
603
|
-
return
|
|
603
|
+
return Ko(n, o);
|
|
604
604
|
}
|
|
605
605
|
function G(e) {
|
|
606
606
|
return (o) => o.pointerType === "mouse" ? e(o) : void 0;
|
|
607
607
|
}
|
|
608
|
-
var
|
|
609
|
-
|
|
610
|
-
[
|
|
611
|
-
),
|
|
608
|
+
var Uo = sn, Vo = de, Bo = un, zo = dn, jo = fe, Yo = ln, Xo = J, Ho = mn, Wo = gn, Zo = vn, qo = Mn, Jo = bn, Qo = Cn, et = Sn, nt = _n, ot = Dn, Q = "DropdownMenu", [tt, rt] = We(
|
|
609
|
+
Q,
|
|
610
|
+
[tn]
|
|
611
|
+
), b = tn(), [at, In] = tt(Q), we = (e) => {
|
|
612
612
|
const {
|
|
613
613
|
__scopeDropdownMenu: o,
|
|
614
614
|
children: n,
|
|
615
615
|
dir: t,
|
|
616
616
|
open: r,
|
|
617
|
-
defaultOpen:
|
|
617
|
+
defaultOpen: a,
|
|
618
618
|
onOpenChange: i,
|
|
619
|
-
modal:
|
|
620
|
-
} = e,
|
|
619
|
+
modal: u = !0
|
|
620
|
+
} = e, m = b(o), f = s.useRef(null), [l, d] = Ze({
|
|
621
621
|
prop: r,
|
|
622
|
-
defaultProp:
|
|
622
|
+
defaultProp: a ?? !1,
|
|
623
623
|
onChange: i,
|
|
624
|
-
caller:
|
|
624
|
+
caller: Q
|
|
625
625
|
});
|
|
626
626
|
return /* @__PURE__ */ c(
|
|
627
|
-
|
|
627
|
+
at,
|
|
628
628
|
{
|
|
629
629
|
scope: o,
|
|
630
|
-
triggerId:
|
|
631
|
-
triggerRef:
|
|
632
|
-
contentId:
|
|
630
|
+
triggerId: j(),
|
|
631
|
+
triggerRef: f,
|
|
632
|
+
contentId: j(),
|
|
633
633
|
open: l,
|
|
634
|
-
onOpenChange:
|
|
635
|
-
onOpenToggle:
|
|
636
|
-
modal:
|
|
637
|
-
children: /* @__PURE__ */ c(
|
|
634
|
+
onOpenChange: d,
|
|
635
|
+
onOpenToggle: s.useCallback(() => d((g) => !g), [d]),
|
|
636
|
+
modal: u,
|
|
637
|
+
children: /* @__PURE__ */ c(Uo, { ...m, open: l, onOpenChange: d, dir: t, modal: u, children: n })
|
|
638
638
|
}
|
|
639
639
|
);
|
|
640
640
|
};
|
|
641
|
-
|
|
642
|
-
var
|
|
641
|
+
we.displayName = Q;
|
|
642
|
+
var Pn = "DropdownMenuTrigger", Me = s.forwardRef(
|
|
643
643
|
(e, o) => {
|
|
644
|
-
const { __scopeDropdownMenu: n, disabled: t = !1, ...r } = e,
|
|
645
|
-
return /* @__PURE__ */ c(
|
|
644
|
+
const { __scopeDropdownMenu: n, disabled: t = !1, ...r } = e, a = In(Pn, n), i = b(n);
|
|
645
|
+
return /* @__PURE__ */ c(Vo, { asChild: !0, ...i, children: /* @__PURE__ */ c(
|
|
646
646
|
E.button,
|
|
647
647
|
{
|
|
648
648
|
type: "button",
|
|
649
|
-
id:
|
|
649
|
+
id: a.triggerId,
|
|
650
650
|
"aria-haspopup": "menu",
|
|
651
|
-
"aria-expanded":
|
|
652
|
-
"aria-controls":
|
|
653
|
-
"data-state":
|
|
651
|
+
"aria-expanded": a.open,
|
|
652
|
+
"aria-controls": a.open ? a.contentId : void 0,
|
|
653
|
+
"data-state": a.open ? "open" : "closed",
|
|
654
654
|
"data-disabled": t ? "" : void 0,
|
|
655
655
|
disabled: t,
|
|
656
656
|
...r,
|
|
657
|
-
ref:
|
|
658
|
-
onPointerDown:
|
|
659
|
-
!t &&
|
|
657
|
+
ref: He(o, a.triggerRef),
|
|
658
|
+
onPointerDown: h(e.onPointerDown, (u) => {
|
|
659
|
+
!t && u.button === 0 && u.ctrlKey === !1 && (a.onOpenToggle(), a.open || u.preventDefault());
|
|
660
660
|
}),
|
|
661
|
-
onKeyDown:
|
|
662
|
-
t || (["Enter", " "].includes(
|
|
661
|
+
onKeyDown: h(e.onKeyDown, (u) => {
|
|
662
|
+
t || (["Enter", " "].includes(u.key) && a.onOpenToggle(), u.key === "ArrowDown" && a.onOpenChange(!0), ["Enter", " ", "ArrowDown"].includes(u.key) && u.preventDefault());
|
|
663
663
|
})
|
|
664
664
|
}
|
|
665
665
|
) });
|
|
666
666
|
}
|
|
667
667
|
);
|
|
668
|
-
|
|
669
|
-
var
|
|
670
|
-
const { __scopeDropdownMenu: o, ...n } = e, t =
|
|
671
|
-
return /* @__PURE__ */ c(
|
|
668
|
+
Me.displayName = Pn;
|
|
669
|
+
var st = "DropdownMenuPortal", be = (e) => {
|
|
670
|
+
const { __scopeDropdownMenu: o, ...n } = e, t = b(o);
|
|
671
|
+
return /* @__PURE__ */ c(Bo, { ...t, ...n });
|
|
672
672
|
};
|
|
673
|
-
|
|
674
|
-
var
|
|
673
|
+
be.displayName = st;
|
|
674
|
+
var Nn = "DropdownMenuContent", Ce = s.forwardRef(
|
|
675
675
|
(e, o) => {
|
|
676
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
676
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = In(Nn, n), a = b(n), i = s.useRef(!1);
|
|
677
677
|
return /* @__PURE__ */ c(
|
|
678
|
-
|
|
678
|
+
zo,
|
|
679
679
|
{
|
|
680
680
|
id: r.contentId,
|
|
681
681
|
"aria-labelledby": r.triggerId,
|
|
682
|
-
...
|
|
682
|
+
...a,
|
|
683
683
|
...t,
|
|
684
684
|
ref: o,
|
|
685
|
-
onCloseAutoFocus:
|
|
686
|
-
i.current || r.triggerRef.current?.focus(), i.current = !1,
|
|
685
|
+
onCloseAutoFocus: h(e.onCloseAutoFocus, (u) => {
|
|
686
|
+
i.current || r.triggerRef.current?.focus(), i.current = !1, u.preventDefault();
|
|
687
687
|
}),
|
|
688
|
-
onInteractOutside:
|
|
689
|
-
const
|
|
688
|
+
onInteractOutside: h(e.onInteractOutside, (u) => {
|
|
689
|
+
const m = u.detail.originalEvent, f = m.button === 0 && m.ctrlKey === !0, l = m.button === 2 || f;
|
|
690
690
|
(!r.modal || l) && (i.current = !0);
|
|
691
691
|
}),
|
|
692
692
|
style: {
|
|
@@ -701,77 +701,77 @@ var xn = "DropdownMenuContent", Me = a.forwardRef(
|
|
|
701
701
|
);
|
|
702
702
|
}
|
|
703
703
|
);
|
|
704
|
-
|
|
705
|
-
var
|
|
704
|
+
Ce.displayName = Nn;
|
|
705
|
+
var ct = "DropdownMenuGroup", ye = s.forwardRef(
|
|
706
706
|
(e, o) => {
|
|
707
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
708
|
-
return /* @__PURE__ */ c(
|
|
707
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
708
|
+
return /* @__PURE__ */ c(jo, { ...r, ...t, ref: o });
|
|
709
709
|
}
|
|
710
710
|
);
|
|
711
|
-
|
|
712
|
-
var
|
|
711
|
+
ye.displayName = ct;
|
|
712
|
+
var it = "DropdownMenuLabel", Se = s.forwardRef(
|
|
713
713
|
(e, o) => {
|
|
714
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
715
|
-
return /* @__PURE__ */ c(
|
|
714
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
715
|
+
return /* @__PURE__ */ c(Yo, { ...r, ...t, ref: o });
|
|
716
716
|
}
|
|
717
717
|
);
|
|
718
|
-
|
|
719
|
-
var
|
|
718
|
+
Se.displayName = it;
|
|
719
|
+
var ut = "DropdownMenuItem", _e = s.forwardRef(
|
|
720
720
|
(e, o) => {
|
|
721
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
722
|
-
return /* @__PURE__ */ c(
|
|
721
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
722
|
+
return /* @__PURE__ */ c(Xo, { ...r, ...t, ref: o });
|
|
723
723
|
}
|
|
724
724
|
);
|
|
725
|
-
Ce.displayName = st;
|
|
726
|
-
var ct = "DropdownMenuCheckboxItem", ye = a.forwardRef((e, o) => {
|
|
727
|
-
const { __scopeDropdownMenu: n, ...t } = e, r = w(n);
|
|
728
|
-
return /* @__PURE__ */ c(zo, { ...r, ...t, ref: o });
|
|
729
|
-
});
|
|
730
|
-
ye.displayName = ct;
|
|
731
|
-
var it = "DropdownMenuRadioGroup", Re = a.forwardRef((e, o) => {
|
|
732
|
-
const { __scopeDropdownMenu: n, ...t } = e, r = w(n);
|
|
733
|
-
return /* @__PURE__ */ c(Xo, { ...r, ...t, ref: o });
|
|
734
|
-
});
|
|
735
|
-
Re.displayName = it;
|
|
736
|
-
var ut = "DropdownMenuRadioItem", _e = a.forwardRef((e, o) => {
|
|
737
|
-
const { __scopeDropdownMenu: n, ...t } = e, r = w(n);
|
|
738
|
-
return /* @__PURE__ */ c(Yo, { ...r, ...t, ref: o });
|
|
739
|
-
});
|
|
740
725
|
_e.displayName = ut;
|
|
741
|
-
var dt = "
|
|
742
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
726
|
+
var dt = "DropdownMenuCheckboxItem", Re = s.forwardRef((e, o) => {
|
|
727
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
743
728
|
return /* @__PURE__ */ c(Ho, { ...r, ...t, ref: o });
|
|
744
729
|
});
|
|
745
|
-
|
|
746
|
-
var lt = "
|
|
747
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
730
|
+
Re.displayName = dt;
|
|
731
|
+
var lt = "DropdownMenuRadioGroup", De = s.forwardRef((e, o) => {
|
|
732
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
748
733
|
return /* @__PURE__ */ c(Wo, { ...r, ...t, ref: o });
|
|
749
734
|
});
|
|
750
735
|
De.displayName = lt;
|
|
751
|
-
var pt = "
|
|
736
|
+
var pt = "DropdownMenuRadioItem", xe = s.forwardRef((e, o) => {
|
|
737
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
738
|
+
return /* @__PURE__ */ c(Zo, { ...r, ...t, ref: o });
|
|
739
|
+
});
|
|
740
|
+
xe.displayName = pt;
|
|
741
|
+
var mt = "DropdownMenuItemIndicator", Ie = s.forwardRef((e, o) => {
|
|
742
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
743
|
+
return /* @__PURE__ */ c(qo, { ...r, ...t, ref: o });
|
|
744
|
+
});
|
|
745
|
+
Ie.displayName = mt;
|
|
746
|
+
var ft = "DropdownMenuSeparator", Pe = s.forwardRef((e, o) => {
|
|
747
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
748
|
+
return /* @__PURE__ */ c(Jo, { ...r, ...t, ref: o });
|
|
749
|
+
});
|
|
750
|
+
Pe.displayName = ft;
|
|
751
|
+
var gt = "DropdownMenuArrow", Ne = s.forwardRef(
|
|
752
752
|
(e, o) => {
|
|
753
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
754
|
-
return /* @__PURE__ */ c(
|
|
753
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
754
|
+
return /* @__PURE__ */ c(Qo, { ...r, ...t, ref: o });
|
|
755
755
|
}
|
|
756
756
|
);
|
|
757
|
-
|
|
758
|
-
var
|
|
759
|
-
const { __scopeDropdownMenu: o, children: n, open: t, onOpenChange: r, defaultOpen:
|
|
757
|
+
Ne.displayName = gt;
|
|
758
|
+
var En = (e) => {
|
|
759
|
+
const { __scopeDropdownMenu: o, children: n, open: t, onOpenChange: r, defaultOpen: a } = e, i = b(o), [u, m] = Ze({
|
|
760
760
|
prop: t,
|
|
761
|
-
defaultProp:
|
|
761
|
+
defaultProp: a ?? !1,
|
|
762
762
|
onChange: r,
|
|
763
763
|
caller: "DropdownMenuSub"
|
|
764
764
|
});
|
|
765
|
-
return /* @__PURE__ */ c(
|
|
766
|
-
},
|
|
767
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
768
|
-
return /* @__PURE__ */ c(
|
|
765
|
+
return /* @__PURE__ */ c(et, { ...i, open: u, onOpenChange: m, children: n });
|
|
766
|
+
}, ht = "DropdownMenuSubTrigger", Ee = s.forwardRef((e, o) => {
|
|
767
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
768
|
+
return /* @__PURE__ */ c(nt, { ...r, ...t, ref: o });
|
|
769
769
|
});
|
|
770
|
-
|
|
771
|
-
var
|
|
772
|
-
const { __scopeDropdownMenu: n, ...t } = e, r =
|
|
770
|
+
Ee.displayName = ht;
|
|
771
|
+
var vt = "DropdownMenuSubContent", Te = s.forwardRef((e, o) => {
|
|
772
|
+
const { __scopeDropdownMenu: n, ...t } = e, r = b(n);
|
|
773
773
|
return /* @__PURE__ */ c(
|
|
774
|
-
|
|
774
|
+
ot,
|
|
775
775
|
{
|
|
776
776
|
...r,
|
|
777
777
|
...t,
|
|
@@ -787,47 +787,51 @@ var mt = "DropdownMenuSubContent", Pe = a.forwardRef((e, o) => {
|
|
|
787
787
|
}
|
|
788
788
|
);
|
|
789
789
|
});
|
|
790
|
-
|
|
791
|
-
var
|
|
792
|
-
const
|
|
790
|
+
Te.displayName = vt;
|
|
791
|
+
var Tn = we, An = Me, ee = be, Ae = Ce, kn = ye, ke = Se, Oe = _e, Le = Re, ne = De, Ge = xe, Fe = Ie, Ke = Pe, wt = Ne, On = En, $e = Ee, Ue = Te;
|
|
792
|
+
const Cr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
793
793
|
__proto__: null,
|
|
794
|
-
Arrow:
|
|
795
|
-
CheckboxItem:
|
|
796
|
-
Content:
|
|
797
|
-
DropdownMenu:
|
|
798
|
-
DropdownMenuArrow:
|
|
799
|
-
DropdownMenuCheckboxItem:
|
|
800
|
-
DropdownMenuContent:
|
|
801
|
-
DropdownMenuGroup:
|
|
802
|
-
DropdownMenuItem:
|
|
803
|
-
DropdownMenuItemIndicator:
|
|
804
|
-
DropdownMenuLabel:
|
|
805
|
-
DropdownMenuPortal:
|
|
806
|
-
DropdownMenuRadioGroup:
|
|
807
|
-
DropdownMenuRadioItem:
|
|
808
|
-
DropdownMenuSeparator:
|
|
809
|
-
DropdownMenuSub:
|
|
810
|
-
DropdownMenuSubContent:
|
|
811
|
-
DropdownMenuSubTrigger:
|
|
812
|
-
DropdownMenuTrigger:
|
|
813
|
-
Group:
|
|
814
|
-
Item:
|
|
815
|
-
ItemIndicator:
|
|
816
|
-
Label:
|
|
817
|
-
Portal:
|
|
818
|
-
RadioGroup:
|
|
819
|
-
RadioItem:
|
|
820
|
-
Root:
|
|
821
|
-
Separator:
|
|
822
|
-
Sub:
|
|
823
|
-
SubContent:
|
|
824
|
-
SubTrigger:
|
|
825
|
-
Trigger:
|
|
826
|
-
createDropdownMenuScope:
|
|
827
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
794
|
+
Arrow: wt,
|
|
795
|
+
CheckboxItem: Le,
|
|
796
|
+
Content: Ae,
|
|
797
|
+
DropdownMenu: we,
|
|
798
|
+
DropdownMenuArrow: Ne,
|
|
799
|
+
DropdownMenuCheckboxItem: Re,
|
|
800
|
+
DropdownMenuContent: Ce,
|
|
801
|
+
DropdownMenuGroup: ye,
|
|
802
|
+
DropdownMenuItem: _e,
|
|
803
|
+
DropdownMenuItemIndicator: Ie,
|
|
804
|
+
DropdownMenuLabel: Se,
|
|
805
|
+
DropdownMenuPortal: be,
|
|
806
|
+
DropdownMenuRadioGroup: De,
|
|
807
|
+
DropdownMenuRadioItem: xe,
|
|
808
|
+
DropdownMenuSeparator: Pe,
|
|
809
|
+
DropdownMenuSub: En,
|
|
810
|
+
DropdownMenuSubContent: Te,
|
|
811
|
+
DropdownMenuSubTrigger: Ee,
|
|
812
|
+
DropdownMenuTrigger: Me,
|
|
813
|
+
Group: kn,
|
|
814
|
+
Item: Oe,
|
|
815
|
+
ItemIndicator: Fe,
|
|
816
|
+
Label: ke,
|
|
817
|
+
Portal: ee,
|
|
818
|
+
RadioGroup: ne,
|
|
819
|
+
RadioItem: Ge,
|
|
820
|
+
Root: Tn,
|
|
821
|
+
Separator: Ke,
|
|
822
|
+
Sub: On,
|
|
823
|
+
SubContent: Ue,
|
|
824
|
+
SubTrigger: $e,
|
|
825
|
+
Trigger: An,
|
|
826
|
+
createDropdownMenuScope: rt
|
|
827
|
+
}, Symbol.toStringTag, { value: "Module" })), oe = [
|
|
828
|
+
"rounded-lg bg-transparent text-primary-fg",
|
|
829
|
+
"hover:bg-secondary-border focus:bg-secondary-bg-hover",
|
|
830
|
+
"[&:has([data-menu-item-action]:hover)]:bg-secondary-bg"
|
|
831
|
+
], yr = Tn, Mt = An, Sr = kn, _r = ee, Rr = On, Dr = ne, Ln = s.createContext(null), bt = s.forwardRef(({ indicatorIcon: e, indicatorIconClassName: o, indicatorIconPosition: n, children: t, ...r }, a) => /* @__PURE__ */ c(Ln.Provider, { value: { indicatorIcon: e, indicatorIconClassName: o, indicatorIconPosition: n }, children: /* @__PURE__ */ c(ne, { ref: a, ...r, children: t }) }));
|
|
832
|
+
bt.displayName = ne.displayName;
|
|
833
|
+
const Ct = M({
|
|
834
|
+
extend: q,
|
|
831
835
|
base: "data-[state=open]:bg-secondary-bg-hover",
|
|
832
836
|
slots: {
|
|
833
837
|
chevron: "ml-auto h-4 w-4"
|
|
@@ -843,15 +847,28 @@ const Mt = y({
|
|
|
843
847
|
defaultVariants: {
|
|
844
848
|
inset: !1
|
|
845
849
|
}
|
|
846
|
-
}),
|
|
847
|
-
|
|
848
|
-
|
|
850
|
+
}), yt = M({
|
|
851
|
+
slots: {
|
|
852
|
+
base: [...Z, ...oe, "data-[state=open]:bg-secondary-border"],
|
|
853
|
+
chevron: "ml-auto h-4 w-4"
|
|
854
|
+
},
|
|
855
|
+
variants: {
|
|
856
|
+
inset: {
|
|
857
|
+
true: "pl-8"
|
|
858
|
+
}
|
|
859
|
+
},
|
|
860
|
+
defaultVariants: {
|
|
861
|
+
inset: !1
|
|
862
|
+
}
|
|
863
|
+
}), St = s.forwardRef(({ className: e, inset: o, children: n, ...t }, r) => {
|
|
864
|
+
const { variant: a } = S(), i = a === "glass" ? yt({ inset: o }) : Ct({ inset: o, theme: a });
|
|
865
|
+
return /* @__PURE__ */ H($e, { ref: r, className: i.base({ className: e }), ...t, children: [
|
|
849
866
|
n,
|
|
850
|
-
/* @__PURE__ */ c(
|
|
867
|
+
/* @__PURE__ */ c(po, { className: i.chevron() })
|
|
851
868
|
] });
|
|
852
869
|
});
|
|
853
|
-
|
|
854
|
-
const
|
|
870
|
+
St.displayName = $e.displayName;
|
|
871
|
+
const _t = M({
|
|
855
872
|
base: [
|
|
856
873
|
"relative z-50 min-w-[8rem] overflow-hidden rounded-lg border border-secondary-border bg-secondary-bg p-1 shadow-soft-md",
|
|
857
874
|
"origin-[--radix-dropdown-menu-content-transform-origin]",
|
|
@@ -867,19 +884,23 @@ const bt = y({
|
|
|
867
884
|
inverse: "border-inverse-border bg-inverse-primary-bg"
|
|
868
885
|
}
|
|
869
886
|
}
|
|
870
|
-
}),
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
887
|
+
}), Rt = M({
|
|
888
|
+
base: [
|
|
889
|
+
"shadow-glass-md backdrop-glass-regular relative z-50 min-w-[8rem] overflow-hidden rounded-2xl bg-alpha-40 p-2",
|
|
890
|
+
"origin-[--radix-dropdown-menu-content-transform-origin]",
|
|
891
|
+
"data-[state=open]:animate-in data-[state=closed]:animate-out",
|
|
892
|
+
"data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
|
|
893
|
+
"data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
|
|
894
|
+
"data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2",
|
|
895
|
+
"data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
|
|
896
|
+
"data-[side=left]:-top-1 data-[side=right]:-top-1"
|
|
897
|
+
]
|
|
898
|
+
}), Dt = s.forwardRef(({ className: e, portalContainer: o, ...n }, t) => {
|
|
899
|
+
const { variant: r } = S(), a = en(o), i = r === "glass" ? Rt({ className: e }) : _t({ className: e, theme: r });
|
|
900
|
+
return /* @__PURE__ */ c(ee, { container: a, children: /* @__PURE__ */ c(Ue, { ref: t, className: i, ...n }) });
|
|
880
901
|
});
|
|
881
|
-
|
|
882
|
-
const
|
|
902
|
+
Dt.displayName = Ue.displayName;
|
|
903
|
+
const xt = M({
|
|
883
904
|
base: [
|
|
884
905
|
"group/dropdown-menu-content z-50 min-w-32 rounded-lg border border-secondary-border bg-secondary-bg p-1 shadow-soft-md",
|
|
885
906
|
"max-h-[var(--radix-dropdown-menu-content-available-height)] overflow-y-auto overflow-x-hidden",
|
|
@@ -895,43 +916,55 @@ const yt = y({
|
|
|
895
916
|
inverse: "border-inverse-border bg-inverse-primary-bg"
|
|
896
917
|
}
|
|
897
918
|
}
|
|
898
|
-
}),
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
919
|
+
}), It = M({
|
|
920
|
+
base: [
|
|
921
|
+
"group/glass-dropdown-content shadow-glass-md backdrop-glass-regular z-50 min-w-32 rounded-2xl bg-alpha-40 p-2",
|
|
922
|
+
"max-h-[var(--radix-dropdown-menu-content-available-height)] overflow-y-auto overflow-x-hidden",
|
|
923
|
+
"origin-[--radix-dropdown-menu-content-transform-origin]",
|
|
924
|
+
"data-[state=open]:animate-in data-[state=closed]:animate-out",
|
|
925
|
+
"data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
|
|
926
|
+
"data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
|
|
927
|
+
"data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2",
|
|
928
|
+
"data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2"
|
|
929
|
+
]
|
|
930
|
+
}), Pt = s.forwardRef(({ className: e, sideOffset: o = 4, portalContainer: n, ...t }, r) => {
|
|
931
|
+
const { variant: a } = S(), i = en(n), u = a === "glass" ? It({ className: e }) : xt({ theme: a, className: e });
|
|
932
|
+
return /* @__PURE__ */ c(ee, { container: i, children: /* @__PURE__ */ c(
|
|
933
|
+
Ae,
|
|
902
934
|
{
|
|
903
935
|
ref: r,
|
|
904
936
|
sideOffset: o,
|
|
905
|
-
className:
|
|
937
|
+
className: u,
|
|
906
938
|
...t
|
|
907
939
|
}
|
|
908
940
|
) });
|
|
909
941
|
});
|
|
910
|
-
|
|
911
|
-
const
|
|
912
|
-
extend:
|
|
942
|
+
Pt.displayName = Ae.displayName;
|
|
943
|
+
const Nt = M({
|
|
944
|
+
extend: q,
|
|
913
945
|
base: "",
|
|
914
946
|
variants: {
|
|
915
947
|
inset: {
|
|
916
948
|
true: "!pl-8"
|
|
917
949
|
}
|
|
918
950
|
}
|
|
919
|
-
}),
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
...r,
|
|
928
|
-
children: t
|
|
951
|
+
}), Et = M({
|
|
952
|
+
base: [...Z, ...oe],
|
|
953
|
+
variants: {
|
|
954
|
+
disabled: {
|
|
955
|
+
true: "pointer-events-none opacity-50"
|
|
956
|
+
},
|
|
957
|
+
inset: {
|
|
958
|
+
true: "pl-8"
|
|
929
959
|
}
|
|
930
|
-
|
|
960
|
+
}
|
|
961
|
+
}), Tt = s.forwardRef(({ className: e, disabled: o, inset: n, children: t, ...r }, a) => {
|
|
962
|
+
const { variant: i } = S(), u = i === "glass" ? Et({ className: e, disabled: o, inset: n }) : Nt({ className: e, disabled: o, inset: n, theme: i });
|
|
963
|
+
return /* @__PURE__ */ c(Oe, { ref: a, disabled: o, className: u, ...r, children: t });
|
|
931
964
|
});
|
|
932
|
-
|
|
933
|
-
const
|
|
934
|
-
extend:
|
|
965
|
+
Tt.displayName = Oe.displayName;
|
|
966
|
+
const At = M({
|
|
967
|
+
extend: q,
|
|
935
968
|
base: "",
|
|
936
969
|
slots: {
|
|
937
970
|
checkbox: "flex h-4 w-4 items-center justify-center rounded-sm border transition-colors",
|
|
@@ -965,27 +998,59 @@ const Dt = y({
|
|
|
965
998
|
defaultVariants: {
|
|
966
999
|
checked: !1
|
|
967
1000
|
}
|
|
968
|
-
}),
|
|
969
|
-
|
|
1001
|
+
}), kt = M({
|
|
1002
|
+
slots: {
|
|
1003
|
+
base: [...Z, ...oe],
|
|
1004
|
+
checkbox: "flex h-4 w-4 items-center justify-center rounded-sm border transition-colors",
|
|
1005
|
+
icon: "h-3.5 w-3.5 text-primary-bg"
|
|
1006
|
+
},
|
|
1007
|
+
variants: {
|
|
1008
|
+
disabled: {
|
|
1009
|
+
true: "pointer-events-none opacity-50"
|
|
1010
|
+
},
|
|
1011
|
+
checked: {
|
|
1012
|
+
indeterminate: {
|
|
1013
|
+
checkbox: "border-primary-accent bg-primary-accent data-[disabled]:opacity-50"
|
|
1014
|
+
},
|
|
1015
|
+
true: {
|
|
1016
|
+
checkbox: "border-primary-accent bg-primary-accent data-[disabled]:opacity-50"
|
|
1017
|
+
},
|
|
1018
|
+
false: {
|
|
1019
|
+
checkbox: "border-primary-border bg-secondary-bg"
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
},
|
|
1023
|
+
defaultVariants: {
|
|
1024
|
+
checked: !1
|
|
1025
|
+
}
|
|
1026
|
+
}), Ot = s.forwardRef(({ className: e, children: o, checked: n, disabled: t, ...r }, a) => {
|
|
1027
|
+
const { variant: i } = S(), u = i === "glass" ? kt({ checked: n, disabled: t }) : At({ checked: n, theme: i, disabled: t });
|
|
970
1028
|
return /* @__PURE__ */ H(
|
|
971
|
-
|
|
1029
|
+
Le,
|
|
972
1030
|
{
|
|
973
|
-
ref:
|
|
974
|
-
className:
|
|
1031
|
+
ref: a,
|
|
1032
|
+
className: u.base({ className: e }),
|
|
975
1033
|
checked: n,
|
|
976
1034
|
disabled: t,
|
|
977
1035
|
...r,
|
|
978
1036
|
children: [
|
|
979
|
-
/* @__PURE__ */ c("span", { className:
|
|
1037
|
+
/* @__PURE__ */ c("span", { className: u.checkbox(), children: /* @__PURE__ */ c(Fe, { children: n === "indeterminate" ? /* @__PURE__ */ c(lo, { className: u.icon() }) : /* @__PURE__ */ c(nn, { className: u.icon() }) }) }),
|
|
980
1038
|
o
|
|
981
1039
|
]
|
|
982
1040
|
}
|
|
983
1041
|
);
|
|
984
1042
|
});
|
|
985
|
-
|
|
986
|
-
const
|
|
987
|
-
extend:
|
|
988
|
-
}),
|
|
1043
|
+
Ot.displayName = Le.displayName;
|
|
1044
|
+
const Lt = M({
|
|
1045
|
+
extend: q
|
|
1046
|
+
}), Gt = M({
|
|
1047
|
+
base: [...Z, ...oe],
|
|
1048
|
+
variants: {
|
|
1049
|
+
disabled: {
|
|
1050
|
+
true: "pointer-events-none opacity-50"
|
|
1051
|
+
}
|
|
1052
|
+
}
|
|
1053
|
+
}), Ft = M({
|
|
989
1054
|
base: "flex h-4 w-4 items-center justify-center",
|
|
990
1055
|
variants: {
|
|
991
1056
|
position: {
|
|
@@ -993,15 +1058,15 @@ const It = y({
|
|
|
993
1058
|
end: "order-last ml-auto"
|
|
994
1059
|
}
|
|
995
1060
|
}
|
|
996
|
-
}),
|
|
997
|
-
const { variant:
|
|
998
|
-
return /* @__PURE__ */ H(
|
|
999
|
-
|
|
1061
|
+
}), Kt = s.forwardRef(({ className: e, children: o, disabled: n, ...t }, r) => {
|
|
1062
|
+
const { variant: a } = S(), i = s.useContext(Ln), u = i?.indicatorIcon || nn, m = i?.indicatorIconPosition || "start", f = i?.indicatorIconClassName, l = a === "glass" ? Gt({ disabled: n, className: e }) : Lt({ theme: a, disabled: n, className: e }), d = /* @__PURE__ */ c("span", { className: Ft({ position: m }), children: /* @__PURE__ */ c(Fe, { children: /* @__PURE__ */ c(u, { className: jn("h-4 w-4", f) }) }) });
|
|
1063
|
+
return /* @__PURE__ */ H(Ge, { ref: r, className: l, disabled: n, ...t, children: [
|
|
1064
|
+
d,
|
|
1000
1065
|
o
|
|
1001
1066
|
] });
|
|
1002
1067
|
});
|
|
1003
|
-
|
|
1004
|
-
const
|
|
1068
|
+
Kt.displayName = Ge.displayName;
|
|
1069
|
+
const $t = M({
|
|
1005
1070
|
base: "flex items-center gap-2 px-2 py-1.5 text-sm font-semibold text-primary-fg",
|
|
1006
1071
|
variants: {
|
|
1007
1072
|
inset: {
|
|
@@ -1014,48 +1079,43 @@ const Et = y({
|
|
|
1014
1079
|
defaultVariants: {
|
|
1015
1080
|
inset: !1
|
|
1016
1081
|
}
|
|
1017
|
-
}),
|
|
1018
|
-
const { variant: r } =
|
|
1082
|
+
}), Ut = s.forwardRef(({ className: e, inset: o, ...n }, t) => {
|
|
1083
|
+
const { variant: r } = S(), a = ie(r, ["inverse"]);
|
|
1019
1084
|
return /* @__PURE__ */ c(
|
|
1020
|
-
|
|
1085
|
+
ke,
|
|
1021
1086
|
{
|
|
1022
1087
|
ref: t,
|
|
1023
|
-
className:
|
|
1088
|
+
className: $t({ inset: o, className: e, theme: a }),
|
|
1024
1089
|
...n
|
|
1025
1090
|
}
|
|
1026
1091
|
);
|
|
1027
1092
|
});
|
|
1028
|
-
|
|
1029
|
-
const
|
|
1093
|
+
Ut.displayName = ke.displayName;
|
|
1094
|
+
const Vt = M({
|
|
1030
1095
|
base: "-mx-1 my-1 h-px bg-secondary-border",
|
|
1031
1096
|
variants: {
|
|
1032
1097
|
theme: {
|
|
1033
1098
|
inverse: "bg-inverse-border"
|
|
1034
1099
|
}
|
|
1035
1100
|
}
|
|
1036
|
-
}),
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
ref: n,
|
|
1042
|
-
className: At({ className: e, theme: t }),
|
|
1043
|
-
...o
|
|
1044
|
-
}
|
|
1045
|
-
);
|
|
1101
|
+
}), Bt = M({
|
|
1102
|
+
base: "-mx-1 my-2 h-px bg-primary-border"
|
|
1103
|
+
}), zt = s.forwardRef(({ className: e, ...o }, n) => {
|
|
1104
|
+
const { variant: t } = S(), r = t === "glass" ? Bt({ className: e }) : Vt({ className: e, theme: t });
|
|
1105
|
+
return /* @__PURE__ */ c(Ke, { ref: n, className: r, ...o });
|
|
1046
1106
|
});
|
|
1047
|
-
|
|
1048
|
-
const
|
|
1049
|
-
extend:
|
|
1107
|
+
zt.displayName = Ke.displayName;
|
|
1108
|
+
const jt = M({
|
|
1109
|
+
extend: uo,
|
|
1050
1110
|
base: "ml-auto text-xs tracking-widest opacity-60"
|
|
1051
|
-
}),
|
|
1052
|
-
const { variant: n } =
|
|
1053
|
-
return /* @__PURE__ */ c("span", { className:
|
|
1111
|
+
}), Yt = ({ className: e, ...o }) => {
|
|
1112
|
+
const { variant: n } = S(), t = ie(n, ["inverse"]);
|
|
1113
|
+
return /* @__PURE__ */ c("span", { className: jt({ className: e, theme: t }), ...o });
|
|
1054
1114
|
};
|
|
1055
|
-
|
|
1056
|
-
const
|
|
1057
|
-
|
|
1058
|
-
const
|
|
1115
|
+
Yt.displayName = "DropdownMenuShortcut";
|
|
1116
|
+
const Xt = s.forwardRef(({ children: e, ...o }, n) => /* @__PURE__ */ c(Mt, { asChild: !0, ref: n, children: /* @__PURE__ */ c(co, { ...o, children: e }) }));
|
|
1117
|
+
Xt.displayName = "DropdownMenuTriggerButton";
|
|
1118
|
+
const Ht = M({
|
|
1059
1119
|
slots: {
|
|
1060
1120
|
wrapper: "flex items-center border-0 p-2 py-0",
|
|
1061
1121
|
search: "mr-2 h-4 w-4 shrink-0 text-muted",
|
|
@@ -1068,85 +1128,85 @@ const Ft = y({
|
|
|
1068
1128
|
}
|
|
1069
1129
|
}
|
|
1070
1130
|
}
|
|
1071
|
-
}),
|
|
1131
|
+
}), xr = s.forwardRef(
|
|
1072
1132
|
({ className: e, ...o }, n) => {
|
|
1073
|
-
const { variant: t } =
|
|
1074
|
-
return /* @__PURE__ */ H("label", { className:
|
|
1075
|
-
/* @__PURE__ */ c(
|
|
1133
|
+
const { variant: t } = S(), r = ie(t, ["inverse"]), a = Ht({ theme: r });
|
|
1134
|
+
return /* @__PURE__ */ H("label", { className: a.wrapper({ className: e }), children: [
|
|
1135
|
+
/* @__PURE__ */ c(io, { icon: mo, className: a.search(), "aria-hidden": "true" }),
|
|
1076
1136
|
/* @__PURE__ */ c(
|
|
1077
1137
|
"input",
|
|
1078
1138
|
{
|
|
1079
1139
|
type: "search",
|
|
1080
1140
|
ref: n,
|
|
1081
1141
|
"data-slot": "command-input",
|
|
1082
|
-
className:
|
|
1142
|
+
className: a.input({ className: e }),
|
|
1083
1143
|
...o
|
|
1084
1144
|
}
|
|
1085
1145
|
)
|
|
1086
1146
|
] });
|
|
1087
1147
|
}
|
|
1088
1148
|
);
|
|
1089
|
-
function
|
|
1090
|
-
const { openDelay: o = 200, closeDelay: n = 300 } = e, [t, r] =
|
|
1091
|
-
|
|
1149
|
+
function Ir(e = {}) {
|
|
1150
|
+
const { openDelay: o = 200, closeDelay: n = 300 } = e, [t, r] = s.useState(!1), a = s.useRef(null), i = s.useRef(null), u = s.useCallback(() => {
|
|
1151
|
+
a.current && (clearTimeout(a.current), a.current = null), i.current && (clearTimeout(i.current), i.current = null);
|
|
1092
1152
|
}, []);
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
}, [
|
|
1096
|
-
const
|
|
1097
|
-
|
|
1153
|
+
s.useEffect(() => () => {
|
|
1154
|
+
u();
|
|
1155
|
+
}, [u]);
|
|
1156
|
+
const m = s.useCallback(() => {
|
|
1157
|
+
u(), a.current = setTimeout(() => {
|
|
1098
1158
|
r(!0);
|
|
1099
1159
|
}, o);
|
|
1100
|
-
}, [o,
|
|
1101
|
-
|
|
1160
|
+
}, [o, u]), f = s.useCallback(() => {
|
|
1161
|
+
u(), i.current = setTimeout(() => {
|
|
1102
1162
|
r(!1);
|
|
1103
1163
|
}, n);
|
|
1104
|
-
}, [n,
|
|
1105
|
-
|
|
1106
|
-
}, []),
|
|
1107
|
-
|
|
1108
|
-
}, []),
|
|
1109
|
-
r(
|
|
1164
|
+
}, [n, u]), l = s.useCallback((w) => {
|
|
1165
|
+
w.preventDefault(), w.stopPropagation();
|
|
1166
|
+
}, []), d = s.useCallback((w) => {
|
|
1167
|
+
w.preventDefault();
|
|
1168
|
+
}, []), g = s.useCallback((w) => {
|
|
1169
|
+
r(w);
|
|
1110
1170
|
}, []);
|
|
1111
1171
|
return {
|
|
1112
1172
|
rootProps: {
|
|
1113
1173
|
open: t,
|
|
1114
|
-
onOpenChange:
|
|
1174
|
+
onOpenChange: g,
|
|
1115
1175
|
modal: !1
|
|
1116
1176
|
},
|
|
1117
1177
|
triggerProps: {
|
|
1118
|
-
onMouseEnter:
|
|
1119
|
-
onMouseLeave:
|
|
1178
|
+
onMouseEnter: m,
|
|
1179
|
+
onMouseLeave: f,
|
|
1120
1180
|
onPointerDown: l
|
|
1121
1181
|
},
|
|
1122
1182
|
contentProps: {
|
|
1123
|
-
onMouseEnter:
|
|
1124
|
-
onMouseLeave:
|
|
1125
|
-
onCloseAutoFocus:
|
|
1183
|
+
onMouseEnter: m,
|
|
1184
|
+
onMouseLeave: f,
|
|
1185
|
+
onCloseAutoFocus: d
|
|
1126
1186
|
}
|
|
1127
1187
|
};
|
|
1128
1188
|
}
|
|
1129
1189
|
export {
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1190
|
+
yr as DropdownMenu,
|
|
1191
|
+
Ot as DropdownMenuCheckboxItem,
|
|
1192
|
+
Pt as DropdownMenuContent,
|
|
1193
|
+
Sr as DropdownMenuGroup,
|
|
1194
|
+
Tt as DropdownMenuItem,
|
|
1195
|
+
Ut as DropdownMenuLabel,
|
|
1196
|
+
_r as DropdownMenuPortal,
|
|
1197
|
+
Cr as DropdownMenuPrimitive,
|
|
1198
|
+
Dr as DropdownMenuPrimitiveRadioGroup,
|
|
1199
|
+
bt as DropdownMenuRadioGroup,
|
|
1200
|
+
Kt as DropdownMenuRadioItem,
|
|
1201
|
+
xr as DropdownMenuSearchItem,
|
|
1202
|
+
zt as DropdownMenuSeparator,
|
|
1203
|
+
Yt as DropdownMenuShortcut,
|
|
1204
|
+
Rr as DropdownMenuSub,
|
|
1205
|
+
Dt as DropdownMenuSubContent,
|
|
1206
|
+
St as DropdownMenuSubTrigger,
|
|
1207
|
+
Mt as DropdownMenuTrigger,
|
|
1208
|
+
Xt as DropdownMenuTriggerButton,
|
|
1209
|
+
xt as dropdownMenuContentStyles,
|
|
1210
|
+
Ir as useHoverDropdown
|
|
1151
1211
|
};
|
|
1152
1212
|
//# sourceMappingURL=dropdown.js.map
|