twenty-ui 2.51.3 → 2.52.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AllIcons-1tBWXXrE.cjs → AllIcons-HGLkp696.cjs} +1 -1
- package/dist/{AllIcons-ayl8BCtV.js → AllIcons-fCCVOqoJ.js} +1 -1
- package/dist/{Button-CU8BS-Yd.js → Button-Dd8cNsn1.js} +2 -2
- package/dist/{Button-iVyxlrwO.cjs → Button-Du8T-dOv.cjs} +1 -1
- package/dist/Dropdown-D3LPyrQI.js +1163 -0
- package/dist/Dropdown-h5-yIsU7.cjs +1 -0
- package/dist/Input-BKRR1xlO.js +26 -0
- package/dist/Input-DS19vWhl.cjs +1 -0
- package/dist/{ListItem-WLONJMo5.js → ListItem-DR7Xh2WV.js} +3 -3
- package/dist/{ListItem-B-SFWJZb.cjs → ListItem-g1B--M70.cjs} +1 -1
- package/dist/{Loader-Bb72CUQ9.cjs → Loader-Dau0YQpY.cjs} +1 -1
- package/dist/{Loader-DtHWQH8w.js → Loader-U1LuZtJf.js} +1 -1
- package/dist/{OverflowingTextWithTooltip-D4eZc-7P.js → OverflowingTextWithTooltip-Cky5WlIk.js} +1 -1
- package/dist/{OverflowingTextWithTooltip-ClpPsdpP.cjs → OverflowingTextWithTooltip-Dmsmy-9g.cjs} +1 -1
- package/dist/{Popover-CneCJTvD.cjs → Popover-B-VIhr5g.cjs} +1 -1
- package/dist/{Popover-CWeCV7X9.js → Popover-DhFCYRtv.js} +1 -1
- package/dist/{ProgressBar-goqxS9NE.cjs → ProgressBar-BG38LPgC.cjs} +1 -1
- package/dist/{ProgressBar-8pjpGrmZ.js → ProgressBar-BO0MkswY.js} +14 -14
- package/dist/{Radio-CpQPRHXa.cjs → Radio-BK47Ig6J.cjs} +1 -1
- package/dist/{Radio-VTjpEz8M.js → Radio-WuoC3hJ5.js} +4 -4
- package/dist/{Shortcut-N8TELGPI.cjs → Shortcut-CbbRd1uM.cjs} +1 -1
- package/dist/{Shortcut-Bp9iDdQg.js → Shortcut-YMhkp7f6.js} +1 -1
- package/dist/TablerIcons-CqzhliLC.js +462 -0
- package/dist/{Tooltip-08dDawT_.cjs → Tooltip-BXeUFCdb.cjs} +1 -1
- package/dist/{Tooltip-C7zc16gI.js → Tooltip-CT9YCDaV.js} +1 -1
- package/dist/components/code-editor.cjs +1 -1
- package/dist/components/code-editor.mjs +2 -2
- package/dist/components/data-display.cjs +1 -1
- package/dist/components/data-display.mjs +1 -1
- package/dist/components/feedback.cjs +1 -1
- package/dist/components/feedback.mjs +1 -1
- package/dist/components/input/SegmentedControl/SegmentedControl.d.ts +1 -1
- package/dist/components/input/SegmentedControl/types/SegmentedControlProps.d.ts +1 -0
- package/dist/components/input.cjs +1 -1
- package/dist/components/input.mjs +6 -6
- package/dist/components/layout.cjs +1 -1
- package/dist/components/layout.mjs +1 -1
- package/dist/components/navigation/Dropdown/Dropdown.d.ts +1 -1
- package/dist/components/navigation/Dropdown/__stories__/DropdownPlacementExample.d.ts +6 -0
- package/dist/components/navigation/Dropdown/hooks/useDropdownPlacementOrThrow.d.ts +1 -0
- package/dist/components/navigation/Dropdown/internal/DropdownContent.d.ts +1 -1
- package/dist/components/navigation/Dropdown/internal/DropdownContentRenderer.d.ts +10 -0
- package/dist/components/navigation/Dropdown/internal/DropdownPlacementContext.d.ts +1 -0
- package/dist/components/navigation/Dropdown/internal/compareDropdownElementOrder.d.ts +4 -0
- package/dist/components/navigation/Dropdown/internal/getDropdownTabNavigation.d.ts +7 -0
- package/dist/components/navigation/Dropdown/internal/getDropdownTriggerTabTarget.d.ts +1 -0
- package/dist/components/navigation/index.d.ts +1 -0
- package/dist/components/navigation.cjs +1 -1
- package/dist/components/navigation.mjs +8 -7
- package/dist/components/settings.cjs +1 -1
- package/dist/components/settings.mjs +1 -1
- package/dist/components.cjs +1 -1
- package/dist/components.mjs +27 -26
- package/dist/{data-display-DUMj_z1t.js → data-display-B7beM2yK.js} +54 -54
- package/dist/{data-display-DzHM5j7j.cjs → data-display-C3Q_8G-N.cjs} +1 -1
- package/dist/{data-display-b-9s0RTe.js → data-display-CHKKTmH_.js} +63 -63
- package/dist/{data-display-D_kbXJJd.cjs → data-display-VghHkQY5.cjs} +1 -1
- package/dist/{feedback-BzR4ggrP.cjs → feedback-3S9S-Xi9.cjs} +1 -1
- package/dist/{feedback-EaZszoXf.js → feedback-DHATp8in.js} +51 -51
- package/dist/icon/components/TablerIcons.d.ts +1 -1
- package/dist/icon/index.d.ts +1 -1
- package/dist/{icon-ICz2_dVB.js → icon-C3fz8p3W.js} +3 -3
- package/dist/{icon-TSBamkxk.cjs → icon-C688lfSq.cjs} +1 -1
- package/dist/icon.cjs +1 -1
- package/dist/icon.mjs +505 -503
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +658 -655
- package/dist/{input-CuySKbhm.js → input-BLU0vrJM.js} +585 -584
- package/dist/{input-ExCbk62Y.cjs → input-BLUZOGq8.cjs} +1 -1
- package/dist/{input-BQABEELu.cjs → input-DRIIJ4Zd.cjs} +1 -1
- package/dist/{input-DxoXgI5-.js → input-jkwxjdtI.js} +6 -6
- package/dist/{layout-B2KvJ900.js → layout-4nLOjbJA.js} +2 -2
- package/dist/{layout-B1Iwc9ku.cjs → layout-DEoY3Qd0.cjs} +1 -1
- package/dist/navigation-CSSOuhFm.cjs +1 -0
- package/dist/navigation-iP54gZTV.js +140 -0
- package/dist/primitives/data-display.cjs +1 -1
- package/dist/primitives/data-display.mjs +1 -1
- package/dist/primitives/feedback.cjs +1 -1
- package/dist/primitives/feedback.mjs +2 -2
- package/dist/primitives/input/Input/Input.d.ts +1 -1
- package/dist/primitives/input/Input/types/InputProps.d.ts +1 -0
- package/dist/primitives/input.cjs +1 -1
- package/dist/primitives/input.mjs +4 -4
- package/dist/primitives/navigation.cjs +1 -1
- package/dist/primitives/navigation.mjs +1 -1
- package/dist/primitives/surfaces/Card/Card.d.ts +1 -1
- package/dist/primitives/surfaces/Card/internal/CardRoot.d.ts +1 -1
- package/dist/primitives/surfaces/Card/types/CardRootProps.d.ts +1 -0
- package/dist/primitives/surfaces.cjs +1 -1
- package/dist/primitives/surfaces.mjs +3 -3
- package/dist/primitives/typography.cjs +1 -1
- package/dist/primitives/typography.mjs +3 -3
- package/dist/primitives.cjs +1 -1
- package/dist/primitives.mjs +14 -14
- package/dist/{settings-BTFAqYrD.js → settings-BmsLbd-g.js} +1 -1
- package/dist/{settings-D_iT1ngl.cjs → settings-DGwyi63i.cjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/surfaces-C70biBA8.js +225 -0
- package/dist/surfaces-DcGz8LO-.cjs +1 -0
- package/dist/testing.cjs +1 -1
- package/dist/testing.mjs +1 -1
- package/dist/theme/constants/ThemeLight.d.ts +1 -0
- package/dist/theme/themeCssVariables.d.ts +1 -0
- package/dist/theme/themeTypes.d.ts +1 -0
- package/dist/theme-BJRNJNPO.cjs +1 -0
- package/dist/{theme-B2EaXhye.js → theme-CuGIQBsJ.js} +7 -4
- package/dist/theme-dark.css +1 -0
- package/dist/theme-light.css +1 -0
- package/dist/theme.cjs +1 -1
- package/dist/theme.mjs +1 -1
- package/dist/{typography-B05olPwL.cjs → typography-DeFnsH3k.cjs} +1 -1
- package/dist/{typography-BwyZEDDi.js → typography-sorTYmvG.js} +2 -2
- package/dist/{useIsMobile-D1ImfQnE.js → useIsMobile-CZeJLJJN.js} +1 -1
- package/dist/{useIsMobile-Byp9AIq-.cjs → useIsMobile-VmnhfE8g.cjs} +1 -1
- package/dist/{utilities-xZh8D2gd.cjs → utilities-Bfnz_GAC.cjs} +1 -1
- package/dist/{utilities-BKCMZyqZ.js → utilities-D0KcLLtO.js} +2 -2
- package/dist/utilities.cjs +1 -1
- package/dist/utilities.mjs +2 -2
- package/package.json +7 -7
- package/dist/Dropdown-D_hFndP5.cjs +0 -1
- package/dist/Dropdown-xXsGBv57.js +0 -1056
- package/dist/Input-D1sIHUZ5.js +0 -25
- package/dist/Input-D69M4UwD.cjs +0 -1
- package/dist/TablerIcons-B-5Ua_Ne.js +0 -460
- package/dist/navigation-DP5Edsq_.cjs +0 -1
- package/dist/navigation-DXMjQMPm.js +0 -134
- package/dist/surfaces-DtZwsfms.cjs +0 -1
- package/dist/surfaces-v0kQLZYO.js +0 -224
- package/dist/theme-1XkFz8Qu.cjs +0 -1
|
@@ -1,1056 +0,0 @@
|
|
|
1
|
-
import { t as i } from "./isDefined-fMi6eQ4r.js";
|
|
2
|
-
import { t as Be } from "./isRenderableSlot-DT_depzM.js";
|
|
3
|
-
import { Cc as it, Ot as st, Tt as ct, kt as dt } from "./TablerIcons-B-5Ua_Ne.js";
|
|
4
|
-
import { t as ne } from "./doNotTranslate-BSVT8Xyd.js";
|
|
5
|
-
import { t as Z } from "./mergeClassNames-ClFMR1v0.js";
|
|
6
|
-
import { t as lt } from "./preventDismissingClickActivation-BQFMKRey.js";
|
|
7
|
-
import { r as qe, t as ut } from "./Button-CU8BS-Yd.js";
|
|
8
|
-
import { t as pt } from "./Tooltip-C7zc16gI.js";
|
|
9
|
-
import { r as Ke } from "./OverflowingTextWithTooltip-D4eZc-7P.js";
|
|
10
|
-
import { t as me } from "./ListItem.module-B31VK9XZ.js";
|
|
11
|
-
import { t as Ae } from "./ListItem-WLONJMo5.js";
|
|
12
|
-
import { t as oe } from "./Popover-CWeCV7X9.js";
|
|
13
|
-
import { t as ft } from "./Input-D1sIHUZ5.js";
|
|
14
|
-
import { useRender as we } from "@base-ui/react/use-render";
|
|
15
|
-
import { isBoolean as mt, isFunction as gt, isNonEmptyString as ve, isPositiveInteger as Ve, isUndefined as ge } from "@sniptt/guards";
|
|
16
|
-
import { clsx as V } from "clsx";
|
|
17
|
-
import { Fragment as wt, createContext as Ue, isValidElement as vt, useCallback as Q, useContext as de, useEffect as ht, useId as he, useLayoutEffect as le, useRef as Ce, useState as L } from "react";
|
|
18
|
-
import { Fragment as bt, jsx as d, jsxs as ee } from "react/jsx-runtime";
|
|
19
|
-
import { Button as ze } from "@base-ui/react/button";
|
|
20
|
-
import { useMergedRefs as ue } from "@base-ui/utils/useMergedRefs";
|
|
21
|
-
import { Popover as He } from "@base-ui/react/popover";
|
|
22
|
-
import { areArraysEqual as It } from "@base-ui/utils/areArraysEqual";
|
|
23
|
-
import { useDirection as We } from "@base-ui/react/direction-provider";
|
|
24
|
-
import { Menu as Ee } from "@base-ui/react/menu";
|
|
25
|
-
var Dt = "_content_nig04_1", Tt = "_inactivePositioner_nig04_13", yt = "_page_nig04_17", _t = "_selectionGroup_nig04_24", At = "_group_nig04_28", Ct = "_groupLabel_nig04_34", Et = "_separator_nig04_43", St = "_section_nig04_50", Pt = "_back_nig04_84", kt = "_backIcon_nig04_96", Rt = "_searchContainer_nig04_100", Ot = "_search_nig04_100", Nt = "_status_nig04_113", xt = "_header_nig04_117", Ft = "_title_nig04_130", Lt = "_itemWithActions_nig04_139", Mt = "_itemWithActionsPrimary_nig04_145", Gt = "_itemActions_nig04_160", Bt = "_itemDecoration_nig04_164", E = {
|
|
26
|
-
content: Dt,
|
|
27
|
-
inactivePositioner: Tt,
|
|
28
|
-
page: yt,
|
|
29
|
-
selectionGroup: _t,
|
|
30
|
-
group: At,
|
|
31
|
-
groupLabel: Ct,
|
|
32
|
-
separator: Et,
|
|
33
|
-
section: St,
|
|
34
|
-
back: Pt,
|
|
35
|
-
backIcon: kt,
|
|
36
|
-
searchContainer: Rt,
|
|
37
|
-
search: Ot,
|
|
38
|
-
status: Nt,
|
|
39
|
-
header: xt,
|
|
40
|
-
title: Ft,
|
|
41
|
-
itemWithActions: Lt,
|
|
42
|
-
itemWithActionsPrimary: Mt,
|
|
43
|
-
itemActions: Gt,
|
|
44
|
-
itemDecoration: Bt
|
|
45
|
-
}, $e = ({ render: e, ref: t, disabled: r, ...o }) => we({
|
|
46
|
-
render: e,
|
|
47
|
-
ref: t,
|
|
48
|
-
defaultTagName: "button",
|
|
49
|
-
props: {
|
|
50
|
-
...o,
|
|
51
|
-
disabled: r
|
|
52
|
-
}
|
|
53
|
-
}), Se = ({ nativeButton: e, renderProps: t }) => e && "disabled" in t && mt(t.disabled) ? t.disabled : void 0, qt = "[data-dropdown-item]", Ye = ({ actions: e, actionsVisibility: t = "hover", color: r = "neutral", selected: o = !1, focused: a = !1, indicator: s = "none", disabled: c = !1, hasSubmenu: p = !1, children: n }) => /* @__PURE__ */ ee("div", {
|
|
54
|
-
className: V(me.root, E.itemWithActions),
|
|
55
|
-
role: "none",
|
|
56
|
-
"data-actions-visibility": t,
|
|
57
|
-
"data-color": r,
|
|
58
|
-
"data-selected": o ? "" : void 0,
|
|
59
|
-
"data-highlighted": a ? "" : void 0,
|
|
60
|
-
"data-indicator": s,
|
|
61
|
-
"data-disabled": c ? "" : void 0,
|
|
62
|
-
onClick: (u) => {
|
|
63
|
-
u.target === u.currentTarget && u.currentTarget.querySelector(qt)?.click();
|
|
64
|
-
},
|
|
65
|
-
children: [
|
|
66
|
-
n,
|
|
67
|
-
/* @__PURE__ */ d("span", {
|
|
68
|
-
className: V(me.actions, E.itemActions),
|
|
69
|
-
children: e
|
|
70
|
-
}),
|
|
71
|
-
s === "check" && o && /* @__PURE__ */ d(ct, {
|
|
72
|
-
className: V(me.checkIndicator, E.itemDecoration),
|
|
73
|
-
"aria-hidden": !0
|
|
74
|
-
}),
|
|
75
|
-
p && /* @__PURE__ */ d(dt, {
|
|
76
|
-
className: V(me.submenuIcon, E.itemDecoration),
|
|
77
|
-
"aria-hidden": !0
|
|
78
|
-
})
|
|
79
|
-
]
|
|
80
|
-
}), Pe = ({ id: e, render: t }) => vt(t) ? t.props.id ?? e : e, ke = (e) => e.getAttribute("aria-label") ?? e.textContent ?? "", Kt = "[hidden],[inert]", ie = (e) => !i(e.closest(Kt)), Re = ({ content: e, item: t }) => t.getAttribute("aria-disabled") !== "true" && !t.hasAttribute("disabled") && ie(t) && t.closest("[data-dropdown-content]") === e, be = (e) => Array.from(e.querySelectorAll("[data-dropdown-item]")).filter((t) => Re({
|
|
81
|
-
content: e,
|
|
82
|
-
item: t
|
|
83
|
-
})), se = Ue(void 0), M = () => {
|
|
84
|
-
const e = de(se);
|
|
85
|
-
if (!i(e)) throw new Error(ne("Dropdown components must be inside Dropdown.Root"));
|
|
86
|
-
return e;
|
|
87
|
-
}, Oe = ({ id: e, disabled: t, isSubmenuTrigger: r = !1 }) => {
|
|
88
|
-
const o = M(), a = r ? o.parentType : o.type, s = r ? o.parentRowFocus : o.rowFocus, c = a !== "panel" && (s?.rowIds?.includes(e) ?? !0);
|
|
89
|
-
return { tabIndex: t || c && s?.tabStopRowId !== e ? -1 : 0 };
|
|
90
|
-
}, je = ({ color: e, startIcon: t, endIcon: r, description: o, descriptionPlacement: a, shortcut: s, shortcutJoinLabel: c, hasSubmenu: p, actions: n, actionsVisibility: u, children: l, render: g, disabled: h = !1, nativeButton: v = !i(g), closeOnClick: m = !0, onClick: _, page: S, id: D, ...f }) => {
|
|
91
|
-
const { type: T, closeTree: w, goToPage: b } = M(), R = he(), F = Pe({
|
|
92
|
-
id: D,
|
|
93
|
-
render: g
|
|
94
|
-
}), x = F ?? R, O = Oe({
|
|
95
|
-
id: x,
|
|
96
|
-
disabled: h
|
|
97
|
-
}), C = Be(n), P = p ?? i(S), G = /* @__PURE__ */ d(ze, {
|
|
98
|
-
...f,
|
|
99
|
-
id: x,
|
|
100
|
-
disabled: h,
|
|
101
|
-
nativeButton: v,
|
|
102
|
-
role: f.role ?? (T === "menu" ? "menuitem" : void 0),
|
|
103
|
-
tabIndex: O.tabIndex,
|
|
104
|
-
"data-dropdown-item": "",
|
|
105
|
-
"data-dropdown-page": S,
|
|
106
|
-
onClick: (y) => {
|
|
107
|
-
if (_?.(y), !y.defaultPrevented) {
|
|
108
|
-
if (i(S)) {
|
|
109
|
-
const A = y.currentTarget.closest("[data-dropdown-content]");
|
|
110
|
-
if (!i(A)) return;
|
|
111
|
-
b({
|
|
112
|
-
id: S,
|
|
113
|
-
trigger: {
|
|
114
|
-
id: F,
|
|
115
|
-
index: be(A).indexOf(y.currentTarget),
|
|
116
|
-
page: S,
|
|
117
|
-
label: ke(y.currentTarget)
|
|
118
|
-
}
|
|
119
|
-
});
|
|
120
|
-
return;
|
|
121
|
-
}
|
|
122
|
-
m && w();
|
|
123
|
-
}
|
|
124
|
-
},
|
|
125
|
-
render: (y) => {
|
|
126
|
-
const A = Se({
|
|
127
|
-
nativeButton: v,
|
|
128
|
-
renderProps: y
|
|
129
|
-
});
|
|
130
|
-
return /* @__PURE__ */ d(Ae, {
|
|
131
|
-
...y,
|
|
132
|
-
render: /* @__PURE__ */ d($e, {
|
|
133
|
-
render: g,
|
|
134
|
-
disabled: A
|
|
135
|
-
}),
|
|
136
|
-
className: V(y.className, C && E.itemWithActionsPrimary),
|
|
137
|
-
disabled: h,
|
|
138
|
-
color: e,
|
|
139
|
-
startIcon: t,
|
|
140
|
-
endIcon: r,
|
|
141
|
-
actionsVisibility: u,
|
|
142
|
-
description: o,
|
|
143
|
-
descriptionPlacement: a,
|
|
144
|
-
shortcut: s,
|
|
145
|
-
shortcutJoinLabel: c,
|
|
146
|
-
hasSubmenu: !C && P,
|
|
147
|
-
children: l
|
|
148
|
-
});
|
|
149
|
-
}
|
|
150
|
-
});
|
|
151
|
-
return C ? /* @__PURE__ */ d(Ye, {
|
|
152
|
-
actions: n,
|
|
153
|
-
actionsVisibility: u,
|
|
154
|
-
color: e,
|
|
155
|
-
disabled: h,
|
|
156
|
-
hasSubmenu: P,
|
|
157
|
-
children: G
|
|
158
|
-
}) : G;
|
|
159
|
-
}, Vt = ({ children: e = ne("Back"), className: t, onClick: r, ...o }) => {
|
|
160
|
-
const { goBack: a, canGoBack: s } = M();
|
|
161
|
-
return /* @__PURE__ */ d(je, {
|
|
162
|
-
...o,
|
|
163
|
-
className: V(E.back, t),
|
|
164
|
-
"data-dropdown-back": "",
|
|
165
|
-
disabled: o.disabled || !s,
|
|
166
|
-
startIcon: /* @__PURE__ */ d(st, { className: E.backIcon }),
|
|
167
|
-
closeOnClick: !1,
|
|
168
|
-
onClick: (c) => {
|
|
169
|
-
r?.(c), !c.defaultPrevented && a();
|
|
170
|
-
},
|
|
171
|
-
children: e
|
|
172
|
-
});
|
|
173
|
-
}, Ut = "_button_1qwl0_1", zt = "_tooltipAnchor_1qwl0_29", Ht = "_icon_1qwl0_33", Te = {
|
|
174
|
-
button: Ut,
|
|
175
|
-
tooltipAnchor: zt,
|
|
176
|
-
icon: Ht
|
|
177
|
-
}, Wt = ({ children: e, size: t, shape: r = "square", className: o, tooltip: a, tooltipPlace: s = "bottom", tooltipDelay: c = 1e3, tooltipOffset: p = 5, disabled: n, loading: u, ...l }) => {
|
|
178
|
-
const g = de(qe), h = t ?? g?.size ?? "md", v = ve(a), m = n || u, _ = /* @__PURE__ */ d(ut, {
|
|
179
|
-
...l,
|
|
180
|
-
size: h === "xs" ? "sm" : h,
|
|
181
|
-
"data-icon-size": h,
|
|
182
|
-
"data-shape": r,
|
|
183
|
-
disabled: n,
|
|
184
|
-
loading: u,
|
|
185
|
-
startIcon: /* @__PURE__ */ d("span", {
|
|
186
|
-
className: Te.icon,
|
|
187
|
-
children: e
|
|
188
|
-
}),
|
|
189
|
-
className: Z(Te.button, o)
|
|
190
|
-
});
|
|
191
|
-
return v ? /* @__PURE__ */ d(pt, {
|
|
192
|
-
content: a,
|
|
193
|
-
delay: c,
|
|
194
|
-
side: s,
|
|
195
|
-
sideOffset: p,
|
|
196
|
-
children: m ? /* @__PURE__ */ d("span", {
|
|
197
|
-
className: Te.tooltipAnchor,
|
|
198
|
-
children: _
|
|
199
|
-
}) : _
|
|
200
|
-
}) : _;
|
|
201
|
-
}, $t = "_button_prhtf_1", Yt = { button: $t }, jt = ({ className: e, emphasis: t = "standard", size: r, variant: o, ...a }) => {
|
|
202
|
-
const s = de(qe), c = r ?? s?.size ?? "sm", p = o ?? s?.variant ?? "ghost";
|
|
203
|
-
return /* @__PURE__ */ d(Wt, {
|
|
204
|
-
...a,
|
|
205
|
-
size: c,
|
|
206
|
-
variant: p,
|
|
207
|
-
"data-emphasis": t,
|
|
208
|
-
className: Z(Yt.button, e)
|
|
209
|
-
});
|
|
210
|
-
}, Xt = ({ render: e, children: t, "aria-label": r, ...o }) => /* @__PURE__ */ d(He.Close, {
|
|
211
|
-
...o,
|
|
212
|
-
"aria-label": r,
|
|
213
|
-
render: e ?? /* @__PURE__ */ d(jt, {
|
|
214
|
-
size: "sm",
|
|
215
|
-
"aria-label": r,
|
|
216
|
-
children: t ?? /* @__PURE__ */ d(it, {})
|
|
217
|
-
}),
|
|
218
|
-
children: i(e) ? t : void 0
|
|
219
|
-
}), Ie = (e) => Array.from(e.querySelectorAll("[data-dropdown-search]:not(:disabled)")).find((t) => t.closest("[data-dropdown-content]") === e && ie(t)) ?? null, Ne = ({ content: e, target: t, edge: r = "first", type: o }) => {
|
|
220
|
-
const a = i(t?.id) ? e.ownerDocument.getElementById(t.id) : null;
|
|
221
|
-
if (i(a) && Re({
|
|
222
|
-
content: e,
|
|
223
|
-
item: a
|
|
224
|
-
})) return a;
|
|
225
|
-
const s = be(e), c = i(t) ? s.filter((m) => m.dataset.dropdownPage === t.page) : [], [p] = c;
|
|
226
|
-
if (c.length === 1 && i(p)) return p;
|
|
227
|
-
const n = ve(t?.label) ? c.filter((m) => ke(m) === t?.label) : [], [u] = n;
|
|
228
|
-
if (n.length === 1 && i(u)) return u;
|
|
229
|
-
const l = i(t) ? s[t.index] : void 0;
|
|
230
|
-
if (i(l)) return l;
|
|
231
|
-
const g = Array.from(e.querySelectorAll('input:not(:disabled):not([type="hidden"]),button:not(:disabled),textarea:not(:disabled),select:not(:disabled),a[href],[tabindex="0"]')).find(ie), h = Array.from(e.querySelectorAll("[data-dropdown-page-type]")).find((m) => m.closest("[data-dropdown-content]") === e && ie(m))?.dataset.dropdownPageType ?? o ?? e.dataset.type;
|
|
232
|
-
if (h === "panel") return g ?? e;
|
|
233
|
-
const v = Ie(e);
|
|
234
|
-
return i(v) ? v : r === "last" ? s[s.length - 1] ?? g ?? e : (h === "picker" ? s.find((m) => m.hasAttribute("data-dropdown-option-item") && (m.getAttribute("aria-selected") === "true" || m.getAttribute("aria-pressed") === "true" || m.getAttribute("aria-checked") === "true" || m.getAttribute("aria-current") === "true")) : void 0) ?? s.find((m) => !m.hasAttribute("data-dropdown-back")) ?? s[0] ?? g ?? e;
|
|
235
|
-
}, Jt = ({ contentRef: e }) => {
|
|
236
|
-
const { open: t, pageId: r, pageFocusRequest: o, setPageFocusRequest: a } = M();
|
|
237
|
-
return le(() => {
|
|
238
|
-
i(o) && (a(void 0), !(!t || o.pageId !== r || !i(e.current)) && Ne({
|
|
239
|
-
content: e.current,
|
|
240
|
-
target: o.target
|
|
241
|
-
}).focus());
|
|
242
|
-
}, [
|
|
243
|
-
e,
|
|
244
|
-
t,
|
|
245
|
-
r,
|
|
246
|
-
o,
|
|
247
|
-
a
|
|
248
|
-
]), null;
|
|
249
|
-
}, Xe = ({ content: e, item: t }) => t.hasAttribute("data-dropdown-item") && Re({
|
|
250
|
-
content: e,
|
|
251
|
-
item: t
|
|
252
|
-
}) && (!t.hasAttribute("data-dropdown-back") || !i(Ie(e))), Je = (e) => Array.from(e.querySelectorAll("[data-dropdown-item]")).filter((t) => Xe({
|
|
253
|
-
content: e,
|
|
254
|
-
item: t
|
|
255
|
-
})), ce = (e) => {
|
|
256
|
-
if (e.dataset.type === "panel") return;
|
|
257
|
-
const t = Ie(e);
|
|
258
|
-
if (!(!i(t) || t !== e.ownerDocument.activeElement || !ve(t.value.trim())))
|
|
259
|
-
return be(e).find((r) => r.hasAttribute("data-dropdown-option-item"));
|
|
260
|
-
}, Qt = ({ content: e }) => {
|
|
261
|
-
const { setRowIds: t, setSearchTargetId: r } = M();
|
|
262
|
-
return le(() => {
|
|
263
|
-
if (!i(e)) return;
|
|
264
|
-
const o = () => {
|
|
265
|
-
const s = Je(e).map((c) => c.id);
|
|
266
|
-
t((c) => i(c) && It(c, s) ? c : s), r(ce(e)?.id);
|
|
267
|
-
};
|
|
268
|
-
o();
|
|
269
|
-
const a = new MutationObserver(o);
|
|
270
|
-
return a.observe(e, {
|
|
271
|
-
childList: !0,
|
|
272
|
-
subtree: !0,
|
|
273
|
-
attributes: !0,
|
|
274
|
-
attributeFilter: [
|
|
275
|
-
"disabled",
|
|
276
|
-
"aria-disabled",
|
|
277
|
-
"id",
|
|
278
|
-
"hidden",
|
|
279
|
-
"inert"
|
|
280
|
-
]
|
|
281
|
-
}), () => {
|
|
282
|
-
a.disconnect(), t(void 0), r(void 0);
|
|
283
|
-
};
|
|
284
|
-
}, [
|
|
285
|
-
e,
|
|
286
|
-
t,
|
|
287
|
-
r
|
|
288
|
-
]), null;
|
|
289
|
-
}, Zt = (e) => (e.ctrlKey || e.metaKey) && !e.defaultPrevented, ye = /* @__PURE__ */ new WeakMap(), Qe = {
|
|
290
|
-
activate: ({ item: e, event: t }) => {
|
|
291
|
-
ye.set(e, t);
|
|
292
|
-
try {
|
|
293
|
-
e.click();
|
|
294
|
-
} finally {
|
|
295
|
-
ye.delete(e);
|
|
296
|
-
}
|
|
297
|
-
},
|
|
298
|
-
getEvent: ({ item: e, event: t }) => ye.get(e) ?? t
|
|
299
|
-
}, er = (e) => Array.from(e.ownerDocument.querySelectorAll("[data-dropdown-item][aria-controls]")).find((t) => t.getAttribute("aria-controls") === e.id && ie(t)), tr = ({ rowCells: e, column: t, isEnabledCell: r }) => {
|
|
300
|
-
const o = Math.min(t, e.length - 1);
|
|
301
|
-
for (let a = 0; a < e.length; a++) {
|
|
302
|
-
const s = [e[o - a], e[o + a]].find(r);
|
|
303
|
-
if (i(s)) return s;
|
|
304
|
-
}
|
|
305
|
-
}, Ze = ({ key: e, items: t, currentItem: r, search: o, isRightToLeft: a }) => {
|
|
306
|
-
const s = r?.closest("[data-dropdown-columns]"), c = Number(s?.dataset.dropdownColumns), p = ne([
|
|
307
|
-
"ArrowUp",
|
|
308
|
-
"ArrowDown",
|
|
309
|
-
"ArrowLeft",
|
|
310
|
-
"ArrowRight"
|
|
311
|
-
]).includes(e);
|
|
312
|
-
if (!i(s) || !i(r) || !p || !Ve(c)) return;
|
|
313
|
-
const n = Array.from(s.children).filter((f) => f instanceof HTMLElement && !f.hasAttribute("data-dropdown-section-label")), u = n.indexOf(r);
|
|
314
|
-
if (u < 0) return;
|
|
315
|
-
const l = Math.floor(u / c), g = u % c, h = e === "ArrowUp" || e === "ArrowDown", v = ne(a ? "ArrowLeft" : "ArrowRight"), m = e === "ArrowDown" || e === v ? 1 : -1, _ = Math.ceil(n.length / c), S = new Set(t), D = (f) => i(f) && S.has(f);
|
|
316
|
-
if (h) {
|
|
317
|
-
for (let w = l + m; w >= 0 && w < _; w += m) {
|
|
318
|
-
const b = n[Math.min(w * c + g, n.length - 1)];
|
|
319
|
-
if (D(b)) return b;
|
|
320
|
-
}
|
|
321
|
-
for (let w = l + m; w >= 0 && w < _; w += m) {
|
|
322
|
-
const b = tr({
|
|
323
|
-
rowCells: n.slice(w * c, (w + 1) * c),
|
|
324
|
-
column: g,
|
|
325
|
-
isEnabledCell: D
|
|
326
|
-
});
|
|
327
|
-
if (i(b)) return b;
|
|
328
|
-
}
|
|
329
|
-
const f = n.filter(D), T = m < 0 ? f[0] : f[f.length - 1];
|
|
330
|
-
return (i(T) ? t[t.indexOf(T) + m] : void 0) ?? (m < 0 ? o : void 0) ?? r;
|
|
331
|
-
}
|
|
332
|
-
for (let f = g + m; f >= 0 && f < c; f += m) {
|
|
333
|
-
const T = n[l * c + f];
|
|
334
|
-
if (D(T)) return T;
|
|
335
|
-
}
|
|
336
|
-
return r;
|
|
337
|
-
}, rr = ({ key: e, items: t, currentIndex: r, search: o, isSearch: a, isRightToLeft: s = !1 }) => {
|
|
338
|
-
const c = Ze({
|
|
339
|
-
key: e,
|
|
340
|
-
items: t,
|
|
341
|
-
currentItem: t[r],
|
|
342
|
-
search: o,
|
|
343
|
-
isRightToLeft: s
|
|
344
|
-
});
|
|
345
|
-
if (i(c)) return c;
|
|
346
|
-
const p = t.length - 1;
|
|
347
|
-
if (e === "ArrowDown") return t[r === p ? 0 : r + 1];
|
|
348
|
-
if (e === "ArrowUp" && r === 0 && i(o)) return o;
|
|
349
|
-
if (e === "ArrowUp") return t[r <= 0 ? p : r - 1];
|
|
350
|
-
if (!a && e === "Home") return t[0];
|
|
351
|
-
if (!a && e === "End") return t[p];
|
|
352
|
-
}, or = 500, nr = 229, ar = () => {
|
|
353
|
-
const { type: e, isSubmenu: t, setOpen: r, closeTree: o, tabForwardOutOfTree: a } = M(), s = We(), [c, p] = L({
|
|
354
|
-
text: "",
|
|
355
|
-
timestamp: 0
|
|
356
|
-
});
|
|
357
|
-
return (n) => {
|
|
358
|
-
if (n.defaultPrevented || n.nativeEvent.isComposing || n.nativeEvent.keyCode === nr) return;
|
|
359
|
-
const u = n.currentTarget, l = n.target;
|
|
360
|
-
if (!(l instanceof HTMLElement) || l.closest("[data-dropdown-content]") !== u) return;
|
|
361
|
-
const g = l.matches('input,textarea,select,[contenteditable="true"]'), h = s === "rtl", v = ne(h ? "ArrowRight" : "ArrowLeft"), m = t && !g && n.key === v, _ = m && e !== "panel" ? Ze({
|
|
362
|
-
key: n.key,
|
|
363
|
-
items: be(u),
|
|
364
|
-
currentItem: l,
|
|
365
|
-
search: null,
|
|
366
|
-
isRightToLeft: h
|
|
367
|
-
}) : void 0, S = i(_) && _ !== l;
|
|
368
|
-
if (t && (n.key === "Escape" || m && !S)) {
|
|
369
|
-
n.preventDefault(), n.stopPropagation(), er(u)?.focus(), r(!1);
|
|
370
|
-
return;
|
|
371
|
-
}
|
|
372
|
-
if (e === "panel") return;
|
|
373
|
-
if (e === "menu" && n.key === "Tab" && n.shiftKey) {
|
|
374
|
-
n.preventDefault(), o(n.nativeEvent);
|
|
375
|
-
return;
|
|
376
|
-
}
|
|
377
|
-
if (e === "menu" && n.key === "Tab" && t) {
|
|
378
|
-
n.preventDefault(), a({
|
|
379
|
-
ownerDocument: u.ownerDocument,
|
|
380
|
-
tabOutEvent: n.nativeEvent
|
|
381
|
-
});
|
|
382
|
-
return;
|
|
383
|
-
}
|
|
384
|
-
const D = Ie(u), f = l === D;
|
|
385
|
-
if (g && !f) return;
|
|
386
|
-
const T = Je(u), w = f && n.key === "Enter" ? ce(u) : void 0;
|
|
387
|
-
if (i(w)) {
|
|
388
|
-
n.preventDefault(), Qe.activate({
|
|
389
|
-
item: w,
|
|
390
|
-
event: n.nativeEvent
|
|
391
|
-
});
|
|
392
|
-
return;
|
|
393
|
-
}
|
|
394
|
-
const b = T.indexOf(l), R = rr({
|
|
395
|
-
key: n.key,
|
|
396
|
-
items: T,
|
|
397
|
-
currentIndex: b,
|
|
398
|
-
search: D,
|
|
399
|
-
isSearch: f,
|
|
400
|
-
isRightToLeft: h
|
|
401
|
-
});
|
|
402
|
-
if (i(R)) {
|
|
403
|
-
n.preventDefault(), R.focus();
|
|
404
|
-
return;
|
|
405
|
-
}
|
|
406
|
-
if (g || n.key.length !== 1 || n.key === " " || n.altKey || n.ctrlKey || n.metaKey) return;
|
|
407
|
-
const F = Date.now(), x = F - c.timestamp > or ? n.key : c.text + n.key;
|
|
408
|
-
p({
|
|
409
|
-
text: x,
|
|
410
|
-
timestamp: F
|
|
411
|
-
});
|
|
412
|
-
const O = ([...x].every((P) => P === x[0]) ? n.key : x).toLocaleLowerCase(), C = [...T.slice(b + 1), ...T.slice(0, b + 1)].find((P) => ke(P).trim().toLocaleLowerCase().startsWith(O));
|
|
413
|
-
i(C) && (n.preventDefault(), C.focus());
|
|
414
|
-
};
|
|
415
|
-
}, ir = ({ side: e, align: t = "start", sideOffset: r = 0, alignOffset: o, anchor: a, collisionPadding: s, container: c, keepMounted: p, width: n = 200, className: u, style: l, children: g, initialFocus: h, finalFocus: v, onKeyDown: m, onFocus: _, onInput: S, onClick: D, onMouseDown: f, onPointerDown: T, "aria-label": w, "aria-labelledby": b, ref: R, ...F }) => {
|
|
416
|
-
const x = M(), { type: O, isPageActive: C, sessionId: P, isSubmenu: G, rowFocus: y, initialFocusEdge: A, focusOnOpen: U, triggerId: B, titleId: W, setSearchTargetId: te } = x, z = Ce(null), [ae, re] = L(null), X = ue(z, R, re), J = ar(), Y = i(w) ? void 0 : W ?? B;
|
|
417
|
-
return /* @__PURE__ */ ee(bt, { children: [
|
|
418
|
-
/* @__PURE__ */ d(oe.Portal, {
|
|
419
|
-
container: c,
|
|
420
|
-
keepMounted: p,
|
|
421
|
-
children: /* @__PURE__ */ d(oe.Positioner, {
|
|
422
|
-
className: C ? void 0 : E.inactivePositioner,
|
|
423
|
-
inert: !C || void 0,
|
|
424
|
-
side: e ?? (G ? "inline-end" : "bottom"),
|
|
425
|
-
align: t,
|
|
426
|
-
sideOffset: r,
|
|
427
|
-
alignOffset: o,
|
|
428
|
-
anchor: a,
|
|
429
|
-
collisionPadding: s,
|
|
430
|
-
children: /* @__PURE__ */ d(oe.Popup, {
|
|
431
|
-
...F,
|
|
432
|
-
ref: X,
|
|
433
|
-
role: O === "menu" ? "menu" : "dialog",
|
|
434
|
-
"aria-label": w,
|
|
435
|
-
"aria-labelledby": b ?? Y,
|
|
436
|
-
"data-dropdown-content": "",
|
|
437
|
-
"data-type": O,
|
|
438
|
-
className: Z(E.content, u),
|
|
439
|
-
style: (I) => ({
|
|
440
|
-
width: n,
|
|
441
|
-
...gt(l) ? l(I) : l
|
|
442
|
-
}),
|
|
443
|
-
initialFocus: h ?? (() => U ? i(z.current) ? Ne({
|
|
444
|
-
content: z.current,
|
|
445
|
-
edge: A,
|
|
446
|
-
type: O
|
|
447
|
-
}) : !0 : !1),
|
|
448
|
-
finalFocus: C ? v : !1,
|
|
449
|
-
onKeyDown: (I) => {
|
|
450
|
-
m?.(I), J(I), Zt(I) || I.stopPropagation();
|
|
451
|
-
},
|
|
452
|
-
onFocus: (I) => {
|
|
453
|
-
_?.(I), te(ce(I.currentTarget)?.id);
|
|
454
|
-
const { target: H } = I;
|
|
455
|
-
H instanceof HTMLElement && Xe({
|
|
456
|
-
content: I.currentTarget,
|
|
457
|
-
item: H
|
|
458
|
-
}) && y.focusRow(H.id);
|
|
459
|
-
},
|
|
460
|
-
onInput: (I) => {
|
|
461
|
-
S?.(I), te(ce(I.currentTarget)?.id);
|
|
462
|
-
},
|
|
463
|
-
onClick: (I) => {
|
|
464
|
-
I.stopPropagation(), D?.(I);
|
|
465
|
-
},
|
|
466
|
-
onMouseDown: (I) => {
|
|
467
|
-
I.stopPropagation(), f?.(I);
|
|
468
|
-
},
|
|
469
|
-
onPointerDown: (I) => {
|
|
470
|
-
I.stopPropagation(), T?.(I);
|
|
471
|
-
},
|
|
472
|
-
children: /* @__PURE__ */ d(se.Provider, {
|
|
473
|
-
value: {
|
|
474
|
-
...x,
|
|
475
|
-
isInsideContent: !0
|
|
476
|
-
},
|
|
477
|
-
children: /* @__PURE__ */ d(wt, { children: g }, P)
|
|
478
|
-
})
|
|
479
|
-
})
|
|
480
|
-
})
|
|
481
|
-
}),
|
|
482
|
-
/* @__PURE__ */ d(Jt, { contentRef: z }),
|
|
483
|
-
/* @__PURE__ */ d(Qt, { content: ae })
|
|
484
|
-
] });
|
|
485
|
-
}, sr = ({ color: e, className: t, ...r }) => /* @__PURE__ */ d(Ke, {
|
|
486
|
-
...r,
|
|
487
|
-
render: /* @__PURE__ */ d("div", { color: e }),
|
|
488
|
-
size: "sm",
|
|
489
|
-
color: "secondary",
|
|
490
|
-
role: "status",
|
|
491
|
-
"aria-live": "polite",
|
|
492
|
-
className: V(E.status, t)
|
|
493
|
-
}), cr = ({ render: e, ref: t, className: r, ...o }) => we({
|
|
494
|
-
render: e,
|
|
495
|
-
ref: t,
|
|
496
|
-
props: {
|
|
497
|
-
...o,
|
|
498
|
-
className: V(E.header, r)
|
|
499
|
-
}
|
|
500
|
-
}), dr = ({ color: e, className: t, ...r }) => /* @__PURE__ */ d(Ke, {
|
|
501
|
-
...r,
|
|
502
|
-
render: /* @__PURE__ */ d("div", { color: e }),
|
|
503
|
-
size: "sm",
|
|
504
|
-
color: "secondary",
|
|
505
|
-
role: "status",
|
|
506
|
-
"aria-live": "polite",
|
|
507
|
-
"aria-busy": "true",
|
|
508
|
-
className: V(E.status, t)
|
|
509
|
-
}), lr = ({ render: e, ref: t, state: r, ...o }) => we({
|
|
510
|
-
render: e,
|
|
511
|
-
ref: t,
|
|
512
|
-
state: r,
|
|
513
|
-
defaultTagName: "button",
|
|
514
|
-
props: o
|
|
515
|
-
}), xe = Ue(void 0), ur = ({ event: e, trigger: t }) => {
|
|
516
|
-
let r = !1;
|
|
517
|
-
return {
|
|
518
|
-
reason: "item-press",
|
|
519
|
-
event: e,
|
|
520
|
-
trigger: t,
|
|
521
|
-
cancel: () => {
|
|
522
|
-
r = !0;
|
|
523
|
-
},
|
|
524
|
-
get isCanceled() {
|
|
525
|
-
return r;
|
|
526
|
-
}
|
|
527
|
-
};
|
|
528
|
-
}, pr = ({ type: e, hasSelectionState: t, hasSelectionOwner: r, multiple: o, role: a }) => e === "menu" && t ? o ? "menuitemcheckbox" : "menuitemradio" : e === "menu" ? "menuitem" : e === "picker" && r ? "option" : a, fr = ({ selection: e, value: t, standaloneSelected: r }) => !i(e) || !i(t) ? r : e.multiple ? e.value.includes(t) : e.value === t, mr = ({ value: e, selected: t, indicator: r, onSelect: o, closeOnSelect: a, color: s, startIcon: c, endIcon: p, description: n, descriptionPlacement: u, shortcut: l, shortcutJoinLabel: g, hasSubmenu: h, actions: v, actionsVisibility: m, children: _, render: S, disabled: D = !1, nativeButton: f = !i(S), onClick: T, id: w, ...b }) => {
|
|
529
|
-
const { type: R, multiple: F, closeTree: x, searchTargetId: O } = M(), C = de(xe), P = i(C) && i(e), G = P ? C.multiple : F, y = fr({
|
|
530
|
-
selection: C,
|
|
531
|
-
value: e,
|
|
532
|
-
standaloneSelected: t
|
|
533
|
-
}), A = R === "menu", U = R === "picker" && P, B = i(y), W = !A && !U && (f || b.role === "button"), te = !A && !U && !W && B && y, z = pr({
|
|
534
|
-
type: R,
|
|
535
|
-
hasSelectionState: B,
|
|
536
|
-
hasSelectionOwner: P,
|
|
537
|
-
multiple: G,
|
|
538
|
-
role: b.role
|
|
539
|
-
}), ae = G ? "checkbox" : "check", re = he(), X = Pe({
|
|
540
|
-
id: w,
|
|
541
|
-
render: S
|
|
542
|
-
}) ?? re, J = Oe({
|
|
543
|
-
id: X,
|
|
544
|
-
disabled: D
|
|
545
|
-
}), Y = Be(v), I = O === X, H = r ?? (B ? ae : "none"), De = Y && H === "check", pe = /* @__PURE__ */ d(ze, {
|
|
546
|
-
...b,
|
|
547
|
-
id: X,
|
|
548
|
-
disabled: D,
|
|
549
|
-
nativeButton: f,
|
|
550
|
-
role: z,
|
|
551
|
-
"aria-checked": A && B ? y : void 0,
|
|
552
|
-
"aria-selected": U ? y : void 0,
|
|
553
|
-
"aria-pressed": W && B ? y : void 0,
|
|
554
|
-
"aria-current": te ? "true" : void 0,
|
|
555
|
-
tabIndex: J.tabIndex,
|
|
556
|
-
"data-dropdown-item": "",
|
|
557
|
-
"data-dropdown-option-item": "",
|
|
558
|
-
onClick: (q) => {
|
|
559
|
-
if (T?.(q), q.defaultPrevented) return;
|
|
560
|
-
const $ = ur({
|
|
561
|
-
event: Qe.getEvent({
|
|
562
|
-
item: q.currentTarget,
|
|
563
|
-
event: q.nativeEvent
|
|
564
|
-
}),
|
|
565
|
-
trigger: q.currentTarget
|
|
566
|
-
});
|
|
567
|
-
o?.($), !($.isCanceled || q.defaultPrevented) && (P && C.select({
|
|
568
|
-
value: e,
|
|
569
|
-
eventDetails: $
|
|
570
|
-
}), !($.isCanceled || q.defaultPrevented) && (a ?? (P ? C.closeOnSelect : !G)) && x());
|
|
571
|
-
},
|
|
572
|
-
render: (q) => {
|
|
573
|
-
const $ = Se({
|
|
574
|
-
nativeButton: f,
|
|
575
|
-
renderProps: q
|
|
576
|
-
});
|
|
577
|
-
return /* @__PURE__ */ d(Ae, {
|
|
578
|
-
...q,
|
|
579
|
-
render: /* @__PURE__ */ d(lr, {
|
|
580
|
-
render: S,
|
|
581
|
-
disabled: $,
|
|
582
|
-
state: {
|
|
583
|
-
selected: y ?? !1,
|
|
584
|
-
multiple: G,
|
|
585
|
-
disabled: D
|
|
586
|
-
}
|
|
587
|
-
}),
|
|
588
|
-
className: V(q.className, Y && E.itemWithActionsPrimary),
|
|
589
|
-
disabled: D,
|
|
590
|
-
selected: y,
|
|
591
|
-
focused: I,
|
|
592
|
-
indicator: De ? "none" : H,
|
|
593
|
-
color: s,
|
|
594
|
-
startIcon: c,
|
|
595
|
-
endIcon: p,
|
|
596
|
-
actionsVisibility: m,
|
|
597
|
-
description: n,
|
|
598
|
-
descriptionPlacement: u,
|
|
599
|
-
shortcut: l,
|
|
600
|
-
shortcutJoinLabel: g,
|
|
601
|
-
hasSubmenu: !Y && h,
|
|
602
|
-
children: _
|
|
603
|
-
});
|
|
604
|
-
}
|
|
605
|
-
});
|
|
606
|
-
return Y ? /* @__PURE__ */ d(Ye, {
|
|
607
|
-
actions: v,
|
|
608
|
-
actionsVisibility: m,
|
|
609
|
-
color: s,
|
|
610
|
-
selected: y,
|
|
611
|
-
focused: I,
|
|
612
|
-
indicator: H,
|
|
613
|
-
disabled: D,
|
|
614
|
-
hasSubmenu: h,
|
|
615
|
-
children: pe
|
|
616
|
-
}) : pe;
|
|
617
|
-
}, gr = ({ id: e, type: t, isActive: r }) => {
|
|
618
|
-
const { registerPage: o } = M();
|
|
619
|
-
return le(() => {
|
|
620
|
-
r && o({
|
|
621
|
-
id: e,
|
|
622
|
-
type: t
|
|
623
|
-
});
|
|
624
|
-
}, [
|
|
625
|
-
e,
|
|
626
|
-
t,
|
|
627
|
-
r,
|
|
628
|
-
o
|
|
629
|
-
]), null;
|
|
630
|
-
}, wr = ({ id: e, type: t, children: r }) => {
|
|
631
|
-
const o = M(), { registerTitle: a } = o, [s, c] = L(), p = o.isPageActive && o.pageId === e, n = p && o.open, u = Q((l) => p ? a(l) : () => {
|
|
632
|
-
}, [p, a]);
|
|
633
|
-
return n && s !== e && c(e), s !== e && !n ? null : /* @__PURE__ */ ee(se.Provider, {
|
|
634
|
-
value: {
|
|
635
|
-
...o,
|
|
636
|
-
type: t ?? o.rootType,
|
|
637
|
-
isPageActive: p,
|
|
638
|
-
registerTitle: u
|
|
639
|
-
},
|
|
640
|
-
children: [/* @__PURE__ */ d("div", {
|
|
641
|
-
hidden: !p,
|
|
642
|
-
inert: !p,
|
|
643
|
-
className: E.page,
|
|
644
|
-
"data-dropdown-page-type": t ?? o.rootType,
|
|
645
|
-
children: r
|
|
646
|
-
}), /* @__PURE__ */ d(gr, {
|
|
647
|
-
id: e,
|
|
648
|
-
type: t,
|
|
649
|
-
isActive: p
|
|
650
|
-
})]
|
|
651
|
-
});
|
|
652
|
-
}, vr = ({ open: e, registerOpenNestedRoot: t }) => (ht(() => {
|
|
653
|
-
if (e)
|
|
654
|
-
return t?.();
|
|
655
|
-
}, [e, t]), null), hr = ({ rowIds: e = [], focusedRowId: t }) => i(t) && e.includes(t) ? t : e[0], br = "data-base-ui-focus-guard", Ir = (e) => {
|
|
656
|
-
const t = e?.nextElementSibling;
|
|
657
|
-
if (!(!(t instanceof HTMLElement) || !t.hasAttribute(br)))
|
|
658
|
-
return t;
|
|
659
|
-
}, Dr = (e) => e instanceof FocusEvent ? e.type === "focusout" && e.relatedTarget instanceof Element ? e.relatedTarget : null : e.target instanceof Element ? e.target : null, _e = ({ onDismiss: e, event: t, target: r = Dr(t) }) => {
|
|
660
|
-
if (!i(e)) return !1;
|
|
661
|
-
let o = !1;
|
|
662
|
-
return e({
|
|
663
|
-
target: r,
|
|
664
|
-
type: t.type,
|
|
665
|
-
preventDefault: () => {
|
|
666
|
-
o = !0;
|
|
667
|
-
}
|
|
668
|
-
}), o;
|
|
669
|
-
}, Ge = () => {
|
|
670
|
-
const [e, t] = L();
|
|
671
|
-
return [e, Q((r) => (t(r), () => t((o) => o === r ? void 0 : o)), [])];
|
|
672
|
-
}, Tr = () => {
|
|
673
|
-
const [e, t] = L(() => /* @__PURE__ */ new Map());
|
|
674
|
-
return {
|
|
675
|
-
selections: e,
|
|
676
|
-
initializeSelection: Q(({ id: r, state: o }) => {
|
|
677
|
-
t((a) => a.get(r)?.multiple === o.multiple ? a : new Map(a).set(r, o));
|
|
678
|
-
}, []),
|
|
679
|
-
updateSelection: Q(({ id: r, state: o }) => {
|
|
680
|
-
t((a) => new Map(a).set(r, o));
|
|
681
|
-
}, [])
|
|
682
|
-
};
|
|
683
|
-
}, et = ({ children: e, type: t, open: r, defaultOpen: o = !1, onOpenChange: a, onEscapeKeyDown: s, onInteractOutside: c, multiple: p = !1, defaultPage: n = "root", isSubmenu: u = !1 }) => {
|
|
684
|
-
const l = de(se), g = Tr(), { selections: h, initializeSelection: v, updateSelection: m } = u && i(l) ? l : g, _ = Ce(0), S = Q(() => (_.current += 1, () => {
|
|
685
|
-
_.current -= 1;
|
|
686
|
-
}), []), [D, f] = L(o), T = !i(l) || l.isPageActive && (!l.isInsideContent || l.open), w = T && (r ?? D), [b, R] = L(w), [F, x] = L(0), [O, C] = L([{ id: n }]), [P, G] = L(), [y, A] = L(), [U, B] = L(), W = O[O.length - 1]?.id, [te, z] = L(), [ae, re] = L("first"), [X, J] = L(!0), [Y, I] = L(), [H, De] = Ge(), [pe, q] = Ge(), $ = w && !b, Le = !w && b;
|
|
687
|
-
!T && D && !i(r) && f(!1), ($ || Le) && R(w), $ && (x(F + 1), C([{ id: n }]), G(void 0), z(void 0), B(void 0), A(void 0)), Le && (re("first"), J(!0), I(void 0));
|
|
688
|
-
const fe = (k) => {
|
|
689
|
-
i(r) || f(k), a?.(k);
|
|
690
|
-
}, Me = (k) => {
|
|
691
|
-
i(k) && _e({
|
|
692
|
-
onDismiss: c,
|
|
693
|
-
event: k,
|
|
694
|
-
target: null
|
|
695
|
-
}) || (fe(!1), u && l?.closeTree(k));
|
|
696
|
-
}, tt = ({ ownerDocument: k, tabOutEvent: N }) => {
|
|
697
|
-
const K = i(H) ? k.getElementById(H) : null;
|
|
698
|
-
if (u && i(l)) {
|
|
699
|
-
fe(!1), K?.focus(), l.tabForwardOutOfTree({
|
|
700
|
-
ownerDocument: k,
|
|
701
|
-
tabOutEvent: N
|
|
702
|
-
});
|
|
703
|
-
return;
|
|
704
|
-
}
|
|
705
|
-
const j = Ir(K);
|
|
706
|
-
if (!i(j)) {
|
|
707
|
-
Me(N);
|
|
708
|
-
return;
|
|
709
|
-
}
|
|
710
|
-
j.focus();
|
|
711
|
-
}, rt = ({ id: k, trigger: N }) => {
|
|
712
|
-
z({ pageId: k }), C((K) => [...K, {
|
|
713
|
-
id: k,
|
|
714
|
-
trigger: N
|
|
715
|
-
}]);
|
|
716
|
-
}, ot = () => {
|
|
717
|
-
const k = O[O.length - 2];
|
|
718
|
-
if (!i(k)) return;
|
|
719
|
-
const N = O[O.length - 1]?.trigger;
|
|
720
|
-
z({
|
|
721
|
-
pageId: k.id,
|
|
722
|
-
target: N
|
|
723
|
-
}), C((K) => K.slice(0, -1));
|
|
724
|
-
}, nt = Q(({ id: k, type: N }) => {
|
|
725
|
-
if (!w) return;
|
|
726
|
-
const K = N ?? t;
|
|
727
|
-
G((j) => j?.id === k && j.type === K ? j : {
|
|
728
|
-
id: k,
|
|
729
|
-
type: K
|
|
730
|
-
});
|
|
731
|
-
}, [w, t]);
|
|
732
|
-
return /* @__PURE__ */ d(oe.Root, {
|
|
733
|
-
open: w,
|
|
734
|
-
onOpenChange: (k, N) => {
|
|
735
|
-
if (!T || !k && !w) {
|
|
736
|
-
N.cancel();
|
|
737
|
-
return;
|
|
738
|
-
}
|
|
739
|
-
const K = N.reason === "outside-press" || N.reason === "focus-out";
|
|
740
|
-
if (K && _.current > 0) {
|
|
741
|
-
N.cancel();
|
|
742
|
-
return;
|
|
743
|
-
}
|
|
744
|
-
const j = N.reason === "escape-key" && _e({
|
|
745
|
-
onDismiss: s,
|
|
746
|
-
event: N.event
|
|
747
|
-
}), at = K && _e({
|
|
748
|
-
onDismiss: c,
|
|
749
|
-
event: N.event
|
|
750
|
-
});
|
|
751
|
-
if (j || at) {
|
|
752
|
-
N.cancel();
|
|
753
|
-
return;
|
|
754
|
-
}
|
|
755
|
-
K && lt(N.event), J(N.reason !== "trigger-hover"), fe(k);
|
|
756
|
-
},
|
|
757
|
-
children: /* @__PURE__ */ ee(se.Provider, {
|
|
758
|
-
value: {
|
|
759
|
-
type: i(P) && P.id === W ? P.type : t,
|
|
760
|
-
rootType: t,
|
|
761
|
-
open: w,
|
|
762
|
-
isPageActive: T,
|
|
763
|
-
isInsideContent: !1,
|
|
764
|
-
sessionId: F,
|
|
765
|
-
multiple: p,
|
|
766
|
-
selections: h,
|
|
767
|
-
initializeSelection: v,
|
|
768
|
-
updateSelection: m,
|
|
769
|
-
isSubmenu: u,
|
|
770
|
-
parentType: l?.type,
|
|
771
|
-
rowFocus: {
|
|
772
|
-
rowIds: y,
|
|
773
|
-
tabStopRowId: hr({
|
|
774
|
-
rowIds: y,
|
|
775
|
-
focusedRowId: U
|
|
776
|
-
}),
|
|
777
|
-
focusRow: B
|
|
778
|
-
},
|
|
779
|
-
parentRowFocus: l?.rowFocus,
|
|
780
|
-
setRowIds: A,
|
|
781
|
-
pageId: W,
|
|
782
|
-
pageFocusRequest: te,
|
|
783
|
-
setPageFocusRequest: z,
|
|
784
|
-
canGoBack: O.length > 1,
|
|
785
|
-
initialFocusEdge: ae,
|
|
786
|
-
setInitialFocusEdge: re,
|
|
787
|
-
focusOnOpen: X,
|
|
788
|
-
setFocusOnOpen: J,
|
|
789
|
-
setOpen: fe,
|
|
790
|
-
closeTree: Me,
|
|
791
|
-
tabForwardOutOfTree: tt,
|
|
792
|
-
goToPage: rt,
|
|
793
|
-
goBack: ot,
|
|
794
|
-
registerPage: nt,
|
|
795
|
-
registerOpenNestedRoot: S,
|
|
796
|
-
searchTargetId: Y,
|
|
797
|
-
setSearchTargetId: I,
|
|
798
|
-
triggerId: H,
|
|
799
|
-
registerTrigger: De,
|
|
800
|
-
titleId: pe,
|
|
801
|
-
registerTitle: q
|
|
802
|
-
},
|
|
803
|
-
children: [/* @__PURE__ */ d(vr, {
|
|
804
|
-
open: w,
|
|
805
|
-
registerOpenNestedRoot: u ? void 0 : l?.registerOpenNestedRoot
|
|
806
|
-
}), /* @__PURE__ */ d(xe.Provider, {
|
|
807
|
-
value: void 0,
|
|
808
|
-
children: e
|
|
809
|
-
})]
|
|
810
|
-
})
|
|
811
|
-
});
|
|
812
|
-
}, yr = ({ searchRef: e, value: t }) => {
|
|
813
|
-
const { setSearchTargetId: r } = M();
|
|
814
|
-
return le(() => {
|
|
815
|
-
const o = e.current?.closest("[data-dropdown-content]");
|
|
816
|
-
i(o) && r(ce(o)?.id);
|
|
817
|
-
}, [
|
|
818
|
-
e,
|
|
819
|
-
t,
|
|
820
|
-
r
|
|
821
|
-
]), null;
|
|
822
|
-
}, _r = ({ onValueChange: e, onBlur: t, className: r, hasFocusRing: o = !1, value: a, ref: s, ...c }) => {
|
|
823
|
-
const { searchTargetId: p, setSearchTargetId: n } = M(), u = Ce(null), l = ue(u, s);
|
|
824
|
-
return /* @__PURE__ */ ee("div", {
|
|
825
|
-
className: E.searchContainer,
|
|
826
|
-
children: [/* @__PURE__ */ d(ft, {
|
|
827
|
-
type: "search",
|
|
828
|
-
autoComplete: "off",
|
|
829
|
-
"aria-activedescendant": p,
|
|
830
|
-
...c,
|
|
831
|
-
ref: l,
|
|
832
|
-
value: a,
|
|
833
|
-
"data-dropdown-search": "",
|
|
834
|
-
variant: "plain",
|
|
835
|
-
hasFocusRing: o,
|
|
836
|
-
className: Z(E.search, r),
|
|
837
|
-
onValueChange: (g) => e?.(g),
|
|
838
|
-
onBlur: (g) => {
|
|
839
|
-
n(void 0), t?.(g);
|
|
840
|
-
}
|
|
841
|
-
}), /* @__PURE__ */ d(yr, {
|
|
842
|
-
searchRef: u,
|
|
843
|
-
value: a
|
|
844
|
-
})]
|
|
845
|
-
});
|
|
846
|
-
}, Ar = ({ className: e, ...t }) => /* @__PURE__ */ d(Ee.Group, {
|
|
847
|
-
...t,
|
|
848
|
-
className: Z(E.group, e)
|
|
849
|
-
}), Cr = ({ className: e, ...t }) => /* @__PURE__ */ d(Ee.GroupLabel, {
|
|
850
|
-
...t,
|
|
851
|
-
className: Z(E.groupLabel, e)
|
|
852
|
-
}), Er = ({ label: e, scrollable: t, columns: r, style: o, className: a, children: s, ...c }) => {
|
|
853
|
-
const p = Ve(r) ? r : void 0;
|
|
854
|
-
return /* @__PURE__ */ ee(Ar, {
|
|
855
|
-
...c,
|
|
856
|
-
"data-scrollable": t || void 0,
|
|
857
|
-
"data-dropdown-columns": p,
|
|
858
|
-
style: {
|
|
859
|
-
...o,
|
|
860
|
-
...i(p) && { gridTemplateColumns: `repeat(${p}, minmax(0, 1fr))` }
|
|
861
|
-
},
|
|
862
|
-
className: V(E.section, a),
|
|
863
|
-
children: [i(e) && /* @__PURE__ */ d(Cr, {
|
|
864
|
-
"data-dropdown-section-label": "",
|
|
865
|
-
children: e
|
|
866
|
-
}), s]
|
|
867
|
-
});
|
|
868
|
-
}, Sr = ({ id: e, initialState: t, initializeSelection: r }) => (le(() => {
|
|
869
|
-
r({
|
|
870
|
-
id: e,
|
|
871
|
-
state: t
|
|
872
|
-
});
|
|
873
|
-
}, [
|
|
874
|
-
e,
|
|
875
|
-
t,
|
|
876
|
-
r
|
|
877
|
-
]), null), Pr = ({ props: e, storedState: t }) => e.multiple ? {
|
|
878
|
-
multiple: !0,
|
|
879
|
-
value: e.value ?? (t?.multiple ? t.value : e.defaultValue ?? [])
|
|
880
|
-
} : ge(e.value) ? {
|
|
881
|
-
multiple: !1,
|
|
882
|
-
value: t?.multiple === !1 ? t.value : e.defaultValue ?? null
|
|
883
|
-
} : {
|
|
884
|
-
multiple: !1,
|
|
885
|
-
value: e.value
|
|
886
|
-
}, kr = (e) => {
|
|
887
|
-
const { id: t, multiple: r = !1, value: o, defaultValue: a, onValueChange: s, closeOnSelect: c = !r, render: p, ref: n, className: u, children: l, ...g } = e, { type: h, selections: v, initializeSelection: m, updateSelection: _ } = M(), S = he(), D = t ?? S, f = Pr({
|
|
888
|
-
props: e,
|
|
889
|
-
storedState: v.get(D)
|
|
890
|
-
}), T = ({ value: b, eventDetails: R }) => {
|
|
891
|
-
if (!(!f.multiple && f.value === b)) {
|
|
892
|
-
if (f.multiple && e.multiple) {
|
|
893
|
-
const F = f.value.includes(b) ? f.value.filter((x) => x !== b) : [...f.value, b];
|
|
894
|
-
e.onValueChange?.(F, R), !R.isCanceled && ge(o) && _({
|
|
895
|
-
id: D,
|
|
896
|
-
state: {
|
|
897
|
-
multiple: !0,
|
|
898
|
-
value: F
|
|
899
|
-
}
|
|
900
|
-
});
|
|
901
|
-
return;
|
|
902
|
-
}
|
|
903
|
-
e.multiple || (e.onValueChange?.(b, R), !R.isCanceled && ge(o) && _({
|
|
904
|
-
id: D,
|
|
905
|
-
state: {
|
|
906
|
-
multiple: !1,
|
|
907
|
-
value: b
|
|
908
|
-
}
|
|
909
|
-
}));
|
|
910
|
-
}
|
|
911
|
-
}, w = we({
|
|
912
|
-
render: p,
|
|
913
|
-
ref: n,
|
|
914
|
-
state: f,
|
|
915
|
-
props: {
|
|
916
|
-
...g,
|
|
917
|
-
id: D,
|
|
918
|
-
className: V(E.selectionGroup, u),
|
|
919
|
-
role: h === "picker" ? "listbox" : "group",
|
|
920
|
-
"aria-multiselectable": h === "picker" ? r : void 0,
|
|
921
|
-
children: l
|
|
922
|
-
}
|
|
923
|
-
});
|
|
924
|
-
return /* @__PURE__ */ ee(xe.Provider, {
|
|
925
|
-
value: {
|
|
926
|
-
...f,
|
|
927
|
-
closeOnSelect: c,
|
|
928
|
-
select: T
|
|
929
|
-
},
|
|
930
|
-
children: [ge(o) && /* @__PURE__ */ d(Sr, {
|
|
931
|
-
id: D,
|
|
932
|
-
initialState: f,
|
|
933
|
-
initializeSelection: m
|
|
934
|
-
}), w]
|
|
935
|
-
});
|
|
936
|
-
}, Rr = ({ className: e, ...t }) => /* @__PURE__ */ d(Ee.Separator, {
|
|
937
|
-
...t,
|
|
938
|
-
role: "separator",
|
|
939
|
-
"data-dropdown-separator": "",
|
|
940
|
-
className: V(E.separator, e)
|
|
941
|
-
}), Or = ({ type: e = "menu", ...t }) => /* @__PURE__ */ d(et, {
|
|
942
|
-
...t,
|
|
943
|
-
type: e,
|
|
944
|
-
isSubmenu: !0
|
|
945
|
-
}), Fe = (e) => Q((t) => {
|
|
946
|
-
if (!(!i(t) || !ve(t.id)))
|
|
947
|
-
return e(t.id);
|
|
948
|
-
}, [e]), Nr = ({ color: e, startIcon: t, endIcon: r, description: o, descriptionPlacement: a, shortcut: s, shortcutJoinLabel: c, hasSubmenu: p = !0, children: n, render: u, disabled: l = !1, nativeButton: g = !i(u), openOnHover: h = !0, onKeyDown: v, id: m, ref: _, ...S }) => {
|
|
949
|
-
const D = We(), { type: f, rootType: T, parentType: w, open: b, setOpen: R, setFocusOnOpen: F, registerTrigger: x } = M(), O = b ? f : T, C = he(), P = Pe({
|
|
950
|
-
id: m,
|
|
951
|
-
render: u
|
|
952
|
-
}) ?? C, G = Oe({
|
|
953
|
-
id: P,
|
|
954
|
-
disabled: l,
|
|
955
|
-
isSubmenuTrigger: !0
|
|
956
|
-
}), y = ue(_, Fe(x));
|
|
957
|
-
return /* @__PURE__ */ d(oe.Trigger, {
|
|
958
|
-
...S,
|
|
959
|
-
ref: y,
|
|
960
|
-
id: P,
|
|
961
|
-
disabled: l,
|
|
962
|
-
nativeButton: g,
|
|
963
|
-
openOnHover: h,
|
|
964
|
-
role: w === "menu" ? "menuitem" : void 0,
|
|
965
|
-
"aria-haspopup": O === "menu" ? "menu" : "dialog",
|
|
966
|
-
tabIndex: G.tabIndex,
|
|
967
|
-
"data-dropdown-item": "",
|
|
968
|
-
onKeyDown: (A) => {
|
|
969
|
-
if (v?.(A), A.defaultPrevented || l) return;
|
|
970
|
-
const U = ne(D === "rtl" ? "ArrowLeft" : "ArrowRight");
|
|
971
|
-
if (A.key === U) {
|
|
972
|
-
A.preventDefault(), A.stopPropagation(), F(!0);
|
|
973
|
-
const B = A.currentTarget.getAttribute("aria-controls"), W = i(B) ? A.currentTarget.ownerDocument.getElementById(B) : null;
|
|
974
|
-
if (b && i(W)) {
|
|
975
|
-
Ne({
|
|
976
|
-
content: W,
|
|
977
|
-
type: f
|
|
978
|
-
}).focus();
|
|
979
|
-
return;
|
|
980
|
-
}
|
|
981
|
-
R(!0);
|
|
982
|
-
}
|
|
983
|
-
},
|
|
984
|
-
render: (A) => {
|
|
985
|
-
const U = Se({
|
|
986
|
-
nativeButton: g,
|
|
987
|
-
renderProps: A
|
|
988
|
-
});
|
|
989
|
-
return /* @__PURE__ */ d(Ae, {
|
|
990
|
-
...A,
|
|
991
|
-
render: /* @__PURE__ */ d($e, {
|
|
992
|
-
render: u,
|
|
993
|
-
disabled: U
|
|
994
|
-
}),
|
|
995
|
-
disabled: l,
|
|
996
|
-
color: e,
|
|
997
|
-
startIcon: t,
|
|
998
|
-
endIcon: r,
|
|
999
|
-
description: o,
|
|
1000
|
-
descriptionPlacement: a,
|
|
1001
|
-
shortcut: s,
|
|
1002
|
-
shortcutJoinLabel: c,
|
|
1003
|
-
hasSubmenu: p,
|
|
1004
|
-
children: n
|
|
1005
|
-
});
|
|
1006
|
-
}
|
|
1007
|
-
});
|
|
1008
|
-
}, xr = ({ className: e, render: t, ref: r, ...o }) => {
|
|
1009
|
-
const { registerTitle: a } = M(), s = ue(r, Fe(a));
|
|
1010
|
-
return /* @__PURE__ */ d(He.Title, {
|
|
1011
|
-
...o,
|
|
1012
|
-
ref: s,
|
|
1013
|
-
render: t ?? /* @__PURE__ */ d("div", {}),
|
|
1014
|
-
className: Z(E.title, e)
|
|
1015
|
-
});
|
|
1016
|
-
}, Fr = ({ onKeyDown: e, onClick: t, ref: r, ...o }) => {
|
|
1017
|
-
const { type: a, rootType: s, open: c, setOpen: p, setInitialFocusEdge: n, setFocusOnOpen: u, registerTrigger: l } = M(), g = c ? a : s, h = ue(r, Fe(l));
|
|
1018
|
-
return /* @__PURE__ */ d(oe.Trigger, {
|
|
1019
|
-
...o,
|
|
1020
|
-
ref: h,
|
|
1021
|
-
"aria-haspopup": g === "menu" ? "menu" : "dialog",
|
|
1022
|
-
onClick: (v) => {
|
|
1023
|
-
v.stopPropagation(), v.preventDefault(), t?.(v);
|
|
1024
|
-
},
|
|
1025
|
-
onKeyDown: (v) => {
|
|
1026
|
-
e?.(v), !(v.defaultPrevented || v.baseUIHandlerPrevented || o.disabled || g === "panel") && (v.key !== "ArrowDown" && v.key !== "ArrowUp" || (v.preventDefault(), u(!0), n(v.key === "ArrowUp" ? "last" : "first"), p(!0)));
|
|
1027
|
-
}
|
|
1028
|
-
});
|
|
1029
|
-
}, Lr = et, so = {
|
|
1030
|
-
Root: Lr,
|
|
1031
|
-
Trigger: Fr,
|
|
1032
|
-
Content: ir,
|
|
1033
|
-
ActionItem: je,
|
|
1034
|
-
OptionItem: mr,
|
|
1035
|
-
SelectionGroup: kr,
|
|
1036
|
-
Search: _r,
|
|
1037
|
-
Header: cr,
|
|
1038
|
-
Title: xr,
|
|
1039
|
-
Close: Xt,
|
|
1040
|
-
Page: wr,
|
|
1041
|
-
Back: Vt,
|
|
1042
|
-
Submenu: Or,
|
|
1043
|
-
SubmenuTrigger: Nr,
|
|
1044
|
-
Section: Er,
|
|
1045
|
-
Separator: Rr,
|
|
1046
|
-
Loading: dr,
|
|
1047
|
-
Empty: sr
|
|
1048
|
-
};
|
|
1049
|
-
export {
|
|
1050
|
-
Wt as a,
|
|
1051
|
-
jt as i,
|
|
1052
|
-
Pr as n,
|
|
1053
|
-
M as o,
|
|
1054
|
-
Sr as r,
|
|
1055
|
-
so as t
|
|
1056
|
-
};
|