twenty-ui 2.54.3 → 2.56.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/CHANGELOG.md +2 -0
- package/README.md +4 -3
- package/dist/{AllIcons-B9FfQJ70.js → AllIcons-DbdVWsOq.js} +260 -260
- package/dist/AllIcons-RgvlIG_O.cjs +1 -0
- package/dist/{Button-C3IE0Kup.cjs → Button-CbJ3qEQ9.cjs} +1 -1
- package/dist/{Button-By-nG5vV.js → Button-wpJzTy9O.js} +3 -3
- package/dist/{Dropdown-CyEoMEjR.cjs → Dropdown-CTTQTn7B.cjs} +1 -1
- package/dist/{Dropdown-Zdc0J7Bg.js → Dropdown-CWXJOVhy.js} +13 -13
- package/dist/{Heading-CHvEXL6n.cjs → Heading-DnDEfr6w.cjs} +1 -1
- package/dist/{Heading-Nj5BlPqB.js → Heading-prj1BR5x.js} +4 -4
- package/dist/IconAddressBook-B6S_w1Z7.cjs +1 -0
- package/dist/IconAddressBook-yE-1oV2W.js +41 -0
- package/dist/{Input-BKRR1xlO.js → Input-B9glruH9.js} +5 -5
- package/dist/{Input-DS19vWhl.cjs → Input-D0yWU3vB.cjs} +1 -1
- package/dist/{ListItem-D0WDJG-e.cjs → ListItem-D6FYdx6v.cjs} +1 -1
- package/dist/{ListItem-BgRDvHQG.js → ListItem-mIMpO2Ia.js} +8 -8
- package/dist/Loader-9tUcz6Y9.js +29 -0
- package/dist/Loader-r-OAVzF_.cjs +1 -0
- package/dist/{OverflowingTextWithTooltip-CuWHF8_e.cjs → OverflowingTextWithTooltip-B21zZWP6.cjs} +1 -1
- package/dist/{OverflowingTextWithTooltip-CAQ-5aUp.js → OverflowingTextWithTooltip-aPLt9O1-.js} +9 -9
- package/dist/{Popover-DhFCYRtv.js → Popover-5bTsqA1R.js} +1 -1
- package/dist/{Popover-B-VIhr5g.cjs → Popover-JaBFWSK-.cjs} +1 -1
- package/dist/{ProgressBar-km29TA-7.cjs → ProgressBar-BYw2pGjr.cjs} +1 -1
- package/dist/{ProgressBar-B_QvBWbI.js → ProgressBar-Bjj3a1R3.js} +10 -10
- package/dist/Radio-Bg-zmy-1.js +176 -0
- package/dist/{Radio-DUQ6MLGc.cjs → Radio-CjaEN7Bt.cjs} +1 -1
- package/dist/{ResizeHandle-B30OYZxS.js → ResizeHandle-BWoKp0dV.js} +11 -11
- package/dist/{ResizeHandle-B1MuHTNA.cjs → ResizeHandle-D4Q-ffcT.cjs} +1 -1
- package/dist/{Shortcut-CThgcmn_.js → Shortcut-04Wkuy0i.js} +10 -10
- package/dist/{Shortcut-CLngfg7s.cjs → Shortcut-Gp5Ix8K2.cjs} +1 -1
- package/dist/{Skeleton-tXeIy4qq.cjs → Skeleton-DSloDuSJ.cjs} +1 -1
- package/dist/{Skeleton-BbIF780H.js → Skeleton-gAiz2xVU.js} +4 -4
- package/dist/{Tooltip-BXeUFCdb.cjs → Tooltip-BTv1a0nT.cjs} +1 -1
- package/dist/{Tooltip-CT9YCDaV.js → Tooltip-C60MawQS.js} +10 -10
- package/dist/VisuallyHidden-BOlbK5vT.cjs +1 -0
- package/dist/{VisuallyHidden-CFZP7ybO.js → VisuallyHidden-EWkEBgpc.js} +4 -4
- package/dist/components/code-editor.cjs +1 -1
- package/dist/components/code-editor.mjs +11 -11
- package/dist/components/data-display/AssistantAvatar/AssistantAvatar.d.ts +2 -0
- package/dist/components/data-display/AssistantAvatar/internal/components/AnimatedAssistantAvatarFace.d.ts +6 -0
- package/dist/components/data-display/AssistantAvatar/internal/constants/assistantAvatarBodyAssetByShape.constant.d.ts +12 -0
- package/dist/components/data-display/AssistantAvatar/internal/constants/assistantAvatarColors.constant.d.ts +1 -0
- package/dist/components/data-display/AssistantAvatar/internal/constants/assistantAvatarFaceAssetByFace.constant.d.ts +8 -0
- package/dist/components/data-display/AssistantAvatar/internal/constants/assistantAvatarFaces.constant.d.ts +1 -0
- package/dist/components/data-display/AssistantAvatar/internal/constants/assistantAvatarShapes.constant.d.ts +1 -0
- package/dist/components/data-display/AssistantAvatar/internal/constants/assistantAvatarSizes.constant.d.ts +1 -0
- package/dist/components/data-display/AssistantAvatar/types/AssistantAvatarColor.d.ts +3 -0
- package/dist/components/data-display/AssistantAvatar/types/AssistantAvatarFace.d.ts +2 -0
- package/dist/components/data-display/AssistantAvatar/types/AssistantAvatarProps.d.ts +12 -0
- package/dist/components/data-display/AssistantAvatar/types/AssistantAvatarShape.d.ts +2 -0
- package/dist/components/data-display/AssistantAvatar/types/AssistantAvatarSize.d.ts +2 -0
- package/dist/components/data-display/index.d.ts +6 -0
- package/dist/components/data-display.cjs +1 -1
- package/dist/components/data-display.mjs +9 -8
- package/dist/components/feedback.cjs +1 -1
- package/dist/components/feedback.mjs +1 -1
- package/dist/components/input/SegmentedControl/types/SegmentedControlProps.d.ts +2 -2
- package/dist/components/input.cjs +1 -1
- package/dist/components/input.mjs +2 -2
- package/dist/components/layout.cjs +1 -1
- package/dist/components/layout.mjs +1 -1
- package/dist/components/navigation.cjs +1 -1
- package/dist/components/navigation.mjs +2 -2
- package/dist/components/settings.cjs +1 -1
- package/dist/components/settings.mjs +1 -1
- package/dist/components.cjs +1 -1
- package/dist/components.mjs +43 -42
- package/dist/{data-display-DlmWaxYb.cjs → data-display-B0ANuV9c.cjs} +1 -1
- package/dist/data-display-Czu6NhqA.cjs +2 -0
- package/dist/data-display-_j--U7HG.js +520 -0
- package/dist/{data-display-DKSUI3GC.js → data-display-njtZTjjY.js} +24 -24
- package/dist/{feedback-DFTvn5aL.js → feedback-B-wGbbew.js} +31 -31
- package/dist/{feedback-Cvmm1EZX.cjs → feedback-DZF40uJe.cjs} +1 -1
- package/dist/icon/index.d.ts +0 -4
- package/dist/icon/{components → provider/components}/Icon.d.ts +1 -1
- package/dist/icon/provider/hooks/useIcons.d.ts +4 -0
- package/dist/icon/provider/index.d.ts +4 -0
- package/dist/icon/{internal → provider/internal}/IconsContext.d.ts +1 -1
- package/dist/icon/provider.cjs +1 -0
- package/dist/icon/provider.mjs +35 -0
- package/dist/{icon-BlUO7C4w.js → icon-6Nun996H.js} +360 -424
- package/dist/icon-BhAcFxaJ.cjs +1 -0
- package/dist/icon.cjs +1 -1
- package/dist/icon.mjs +143 -145
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +605 -605
- package/dist/{input-Clzu-UFH.js → input-BaXuEzOr.js} +36 -36
- package/dist/input-BlZ0RHaV.js +379 -0
- package/dist/input-DQfXFl5C.cjs +1 -0
- package/dist/{input-E1x0D2jA.cjs → input-cZCDLL4-.cjs} +1 -1
- package/dist/{layout-DHW99Ejj.cjs → layout-CpDps22m.cjs} +1 -1
- package/dist/{layout-4p7UQD7l.js → layout-DGrag6ua.js} +99 -99
- package/dist/{navigation-BY8X2w04.js → navigation-B4F-yaFC.js} +6 -6
- package/dist/{navigation-4RI9GlzA.js → navigation-CmTgub0K.js} +14 -14
- package/dist/{navigation-B9jOHv99.cjs → navigation-CuI3MVOM.cjs} +1 -1
- package/dist/{navigation-ByYN6NgX.cjs → navigation-Dqiqv2rb.cjs} +1 -1
- package/dist/primitives/accessibility.cjs +1 -1
- package/dist/primitives/accessibility.mjs +1 -1
- package/dist/primitives/data-display/Badge/types/BadgeColor.d.ts +1 -1
- 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 +3 -3
- package/dist/primitives/input/RadioGroup/RadioGroup.d.ts +1 -1
- package/dist/primitives/input/RadioGroup/types/RadioGroupProps.d.ts +2 -0
- package/dist/primitives/input.cjs +1 -1
- package/dist/primitives/input.mjs +4 -4
- package/dist/primitives/layout.cjs +1 -1
- package/dist/primitives/layout.mjs +1 -1
- package/dist/primitives/navigation.cjs +1 -1
- package/dist/primitives/navigation.mjs +2 -2
- 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 +2 -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 +4 -4
- package/dist/primitives.cjs +1 -1
- package/dist/primitives.mjs +19 -19
- package/dist/{settings-2ZhNkDgW.js → settings-BSIBOXgt.js} +2 -2
- package/dist/{settings-DR3dpWzy.cjs → settings-gd-ps3zs.cjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/surfaces-BpIdyqtX.js +227 -0
- package/dist/surfaces-GkxUWBN6.cjs +1 -0
- package/dist/testing.cjs +1 -1
- package/dist/testing.mjs +2 -2
- package/dist/theme/constants/ThemeLight.d.ts +1 -0
- package/dist/theme/internal/ThemeNumericValueByCssVariable.d.ts +1 -0
- package/dist/theme/internal/ThemeTokenTree.d.ts +3 -0
- package/dist/theme/internal/resolveThemeTokens.d.ts +2 -0
- package/dist/theme/themeCssVariables.d.ts +1 -0
- package/dist/theme/themeTypes.d.ts +1 -0
- package/dist/{theme-CuGIQBsJ.js → theme-B1jMC8En.js} +2577 -2544
- package/dist/theme-CeIzO6UU.cjs +1 -0
- package/dist/theme-dark.css +1 -0
- package/dist/theme-light.css +1 -0
- package/dist/theme.cjs +1 -1
- package/dist/theme.mjs +13 -13
- package/dist/{typography-B4hug-TZ.cjs → typography-BQbeIT60.cjs} +1 -1
- package/dist/{typography-jl1UzvVu.js → typography-DvK5mDnG.js} +2 -2
- package/dist/{useIsMobile-CZeJLJJN.js → useIsMobile-B0P21Ov9.js} +1 -1
- package/dist/{useIsMobile-VmnhfE8g.cjs → useIsMobile-BnW-j5Bq.cjs} +1 -1
- package/dist/utilities/color/utils/themeColorSchema.d.ts +15 -15
- package/dist/utilities/index.d.ts +1 -0
- package/dist/utilities/zoom/utils/isPageZoomGesture.d.ts +1 -0
- package/dist/utilities-9ARl_uku.cjs +1 -0
- package/dist/{utilities-E91ftFp_.js → utilities-IyA_ho0H.js} +19 -18
- package/dist/utilities.cjs +1 -1
- package/dist/utilities.mjs +18 -17
- package/package.json +9 -1
- package/dist/AllIcons-HGLkp696.cjs +0 -1
- package/dist/Loader-Dau0YQpY.cjs +0 -1
- package/dist/Loader-U1LuZtJf.js +0 -29
- package/dist/Radio-rURvQ923.js +0 -176
- package/dist/VisuallyHidden-B-n4x1KY.cjs +0 -1
- package/dist/data-display-Cg9gF6Cb.cjs +0 -2
- package/dist/data-display-CuvXSBLo.js +0 -422
- package/dist/icon/hooks/useIcons.d.ts +0 -4
- package/dist/icon-C688lfSq.cjs +0 -1
- package/dist/input-BIUZSrhq.js +0 -374
- package/dist/input-CX8QPMDn.cjs +0 -1
- package/dist/surfaces-C70biBA8.js +0 -225
- package/dist/surfaces-DcGz8LO-.cjs +0 -1
- package/dist/theme-BJRNJNPO.cjs +0 -1
- package/dist/utilities-YhvQ2XFb.cjs +0 -1
- /package/dist/icon/{providers → provider}/IconsProvider.d.ts +0 -0
- /package/dist/icon/{providers → provider}/internal/AllIcons.d.ts +0 -0
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { t as f } from "./isDefined-fMi6eQ4r.js";
|
|
2
2
|
import { t as Y } from "./doNotTranslate-BSVT8Xyd.js";
|
|
3
|
-
import { r as de, t as Ne } from "./OverflowingTextWithTooltip-
|
|
3
|
+
import { r as de, t as Ne } from "./OverflowingTextWithTooltip-aPLt9O1-.js";
|
|
4
4
|
import { t as se } from "./Separator-0LzwPfOn.js";
|
|
5
|
-
import { t as B } from "./Popover-
|
|
6
|
-
import { t as Oe } from "./Heading-
|
|
7
|
-
import { useRender as Q } from "@base-ui/react/use-render";
|
|
5
|
+
import { t as B } from "./Popover-5bTsqA1R.js";
|
|
6
|
+
import { t as Oe } from "./Heading-prj1BR5x.js";
|
|
8
7
|
import { isFunction as Z, isNonEmptyString as Le, isString as X, isUndefined as Ee } from "@sniptt/guards";
|
|
9
8
|
import { clsx as S } from "clsx";
|
|
10
|
-
import { cloneElement as Se, isValidElement as Me, memo as me, useCallback as J, useId as Te, useLayoutEffect as P, useRef as k, useState as q } from "react";
|
|
11
9
|
import { Fragment as j, jsx as u, jsxs as M } from "react/jsx-runtime";
|
|
10
|
+
import { useRender as Q } from "@base-ui/react/use-render";
|
|
11
|
+
import { cloneElement as Se, isValidElement as Me, memo as me, useCallback as J, useId as Te, useLayoutEffect as P, useRef as k, useState as q } from "react";
|
|
12
12
|
import { mergeProps as xe } from "@base-ui/react/merge-props";
|
|
13
|
-
import { useMergedRefs as
|
|
13
|
+
import { useMergedRefs as $ } from "@base-ui/utils/useMergedRefs";
|
|
14
14
|
import { useControlled as De } from "@base-ui/utils/useControlled";
|
|
15
15
|
import { useStableCallback as z } from "@base-ui/utils/useStableCallback";
|
|
16
16
|
var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23", ze = "_hidden_1hm4x_28", A = {
|
|
@@ -18,9 +18,9 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
18
18
|
layer: Ae,
|
|
19
19
|
visible: ke,
|
|
20
20
|
hidden: ze
|
|
21
|
-
}, Et = ({ isActive: r, activeIcon: e, inactiveIcon: t, className: n, render:
|
|
21
|
+
}, Et = ({ isActive: r, activeIcon: e, inactiveIcon: t, className: n, render: a, ref: s, ...l }) => Q({
|
|
22
22
|
defaultTagName: "span",
|
|
23
|
-
render:
|
|
23
|
+
render: a,
|
|
24
24
|
ref: s,
|
|
25
25
|
props: {
|
|
26
26
|
...l,
|
|
@@ -41,7 +41,7 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
41
41
|
line: Ke,
|
|
42
42
|
marker: Ve,
|
|
43
43
|
label: Be
|
|
44
|
-
}, St = ({ children: r, labelPosition: e = "center", tone: t = "neutral", hasStartMarker: n = !1, className:
|
|
44
|
+
}, St = ({ children: r, labelPosition: e = "center", tone: t = "neutral", hasStartMarker: n = !1, className: a, render: s, ref: l, ...i }) => Q({
|
|
45
45
|
render: s,
|
|
46
46
|
ref: l,
|
|
47
47
|
props: {
|
|
@@ -50,7 +50,7 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
50
50
|
"aria-label": r,
|
|
51
51
|
...i,
|
|
52
52
|
"data-tone": t,
|
|
53
|
-
className: S(K.root,
|
|
53
|
+
className: S(K.root, a),
|
|
54
54
|
children: /* @__PURE__ */ M(j, { children: [
|
|
55
55
|
/* @__PURE__ */ M("span", {
|
|
56
56
|
className: K.rule,
|
|
@@ -73,25 +73,25 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
73
73
|
})
|
|
74
74
|
] })
|
|
75
75
|
}
|
|
76
|
-
}),
|
|
77
|
-
root:
|
|
78
|
-
items:
|
|
76
|
+
}), He = "_root_eheyl_1", $e = "_items_eheyl_11", qe = "_item_eheyl_11", je = "_popupItem_eheyl_45", Ge = "_trigger_eheyl_49", Je = "_popup_eheyl_45", V = {
|
|
77
|
+
root: He,
|
|
78
|
+
items: $e,
|
|
79
79
|
item: qe,
|
|
80
80
|
popupItem: je,
|
|
81
81
|
trigger: Ge,
|
|
82
82
|
popup: Je
|
|
83
83
|
}, Qe = ({ props: r, state: e, render: t }) => {
|
|
84
|
-
const n = Me(t) ? t : void 0,
|
|
84
|
+
const n = Me(t) ? t : void 0, a = $(r.ref, n?.props.ref);
|
|
85
85
|
if (Z(t)) return t(r, e);
|
|
86
86
|
const s = {
|
|
87
87
|
...xe(r, n?.props),
|
|
88
88
|
children: r.children,
|
|
89
|
-
ref:
|
|
89
|
+
ref: a
|
|
90
90
|
};
|
|
91
91
|
return f(n) ? Se(n, s) : /* @__PURE__ */ u("div", { ...s });
|
|
92
92
|
}, Xe = me(({ elementRef: r, isHidden: e, onFocusLost: t }) => (P(() => {
|
|
93
|
-
const n = r.current,
|
|
94
|
-
e &&
|
|
93
|
+
const n = r.current, a = f(n) && n.contains(n.ownerDocument.activeElement);
|
|
94
|
+
e && a && t(n);
|
|
95
95
|
}, [
|
|
96
96
|
r,
|
|
97
97
|
e,
|
|
@@ -101,21 +101,21 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
101
101
|
return () => {
|
|
102
102
|
const t = e.ownerDocument, n = e.contains(t.activeElement);
|
|
103
103
|
queueMicrotask(() => {
|
|
104
|
-
const
|
|
105
|
-
n && !e.isConnected &&
|
|
104
|
+
const a = t.activeElement === t.body;
|
|
105
|
+
n && !e.isConnected && a && r(e);
|
|
106
106
|
});
|
|
107
107
|
};
|
|
108
|
-
}, [r]), ie = ({ children: r, index: e, isHidden: t, isLastVisible: n, isInPopup:
|
|
109
|
-
const l = k(null), i = z((
|
|
108
|
+
}, [r]), ie = ({ children: r, index: e, isHidden: t, isLastVisible: n, isInPopup: a, onFocusLost: s }) => {
|
|
109
|
+
const l = k(null), i = z((o) => {
|
|
110
110
|
s({
|
|
111
111
|
index: e,
|
|
112
|
-
element:
|
|
113
|
-
isInPopup:
|
|
112
|
+
element: o,
|
|
113
|
+
isInPopup: a
|
|
114
114
|
});
|
|
115
115
|
});
|
|
116
116
|
return /* @__PURE__ */ M(j, { children: [/* @__PURE__ */ u("div", {
|
|
117
|
-
ref:
|
|
118
|
-
className:
|
|
117
|
+
ref: $(l, fe(i)),
|
|
118
|
+
className: a ? V.popupItem : V.item,
|
|
119
119
|
"data-item-index": e,
|
|
120
120
|
"data-hidden": t || void 0,
|
|
121
121
|
"data-last-visible": n || void 0,
|
|
@@ -128,61 +128,61 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
128
128
|
onFocusLost: i
|
|
129
129
|
})] });
|
|
130
130
|
}, le = ({ itemWidths: r, availableWidth: e, gap: t, includePartialItem: n }) => {
|
|
131
|
-
let
|
|
131
|
+
let a = 0, s = 0;
|
|
132
132
|
for (const l of r) {
|
|
133
|
-
const i =
|
|
133
|
+
const i = a + l + (s > 0 ? t : 0);
|
|
134
134
|
if (s !== 0 && i > e) {
|
|
135
|
-
const
|
|
136
|
-
return n &&
|
|
135
|
+
const o = a + t < e;
|
|
136
|
+
return n && o ? s + 1 : s;
|
|
137
137
|
}
|
|
138
|
-
|
|
138
|
+
a = i, s += 1;
|
|
139
139
|
}
|
|
140
140
|
return s;
|
|
141
141
|
}, Ye = ({ items: r, itemElements: e }) => {
|
|
142
142
|
r.setAttribute("data-measuring", "");
|
|
143
143
|
const t = e.map((n) => n.clientWidth);
|
|
144
144
|
return r.removeAttribute("data-measuring"), t;
|
|
145
|
-
}, Ze = ({ container: r, items: e, trigger: t, itemElements: n, itemCount:
|
|
145
|
+
}, Ze = ({ container: r, items: e, trigger: t, itemElements: n, itemCount: a, reserveCountSpace: s }) => {
|
|
146
146
|
const l = Ye({
|
|
147
147
|
items: e,
|
|
148
148
|
itemElements: n
|
|
149
|
-
}), i = parseFloat(getComputedStyle(e).columnGap) || 0,
|
|
149
|
+
}), i = parseFloat(getComputedStyle(e).columnGap) || 0, o = r.clientWidth, d = a > le({
|
|
150
150
|
itemWidths: l,
|
|
151
|
-
availableWidth:
|
|
151
|
+
availableWidth: o,
|
|
152
152
|
gap: i,
|
|
153
153
|
includePartialItem: !1
|
|
154
154
|
}), p = t?.offsetWidth ?? 0;
|
|
155
155
|
return {
|
|
156
156
|
visibleItemCount: le({
|
|
157
157
|
itemWidths: l,
|
|
158
|
-
availableWidth: s && d ? Math.max(0,
|
|
158
|
+
availableWidth: s && d ? Math.max(0, o - p - i) : o,
|
|
159
159
|
gap: i,
|
|
160
160
|
includePartialItem: !0
|
|
161
161
|
}),
|
|
162
162
|
hasOverflow: d
|
|
163
163
|
};
|
|
164
|
-
}, Pe = 100, et = me(({ containerRef: r, itemsRef: e, triggerRef: t, itemCount: n, inlineItemCount:
|
|
164
|
+
}, Pe = 100, et = me(({ containerRef: r, itemsRef: e, triggerRef: t, itemCount: n, inlineItemCount: a, reserveCountSpace: s, isMeasurementEnabled: l, isOpen: i, onLayoutChange: o, onOverflowUnavailable: d }) => {
|
|
165
165
|
const p = k(void 0), O = k(void 0), C = z(() => ({
|
|
166
166
|
itemCount: n,
|
|
167
|
-
inlineItemCount:
|
|
167
|
+
inlineItemCount: a,
|
|
168
168
|
reserveCountSpace: s,
|
|
169
169
|
isOpen: i
|
|
170
|
-
})), F = z(
|
|
170
|
+
})), F = z(o), T = z(d);
|
|
171
171
|
return P(() => {
|
|
172
|
-
const
|
|
173
|
-
if (!l || !f(
|
|
172
|
+
const y = r.current, I = e.current;
|
|
173
|
+
if (!l || !f(y) || !f(I)) {
|
|
174
174
|
O.current = void 0;
|
|
175
175
|
return;
|
|
176
176
|
}
|
|
177
|
-
const L = /* @__PURE__ */ new Set(),
|
|
178
|
-
const _ = Array.from(I.children), W = /* @__PURE__ */ new Set([
|
|
177
|
+
const L = /* @__PURE__ */ new Set(), g = () => {
|
|
178
|
+
const _ = Array.from(I.children), W = /* @__PURE__ */ new Set([y, ..._]);
|
|
179
179
|
f(t.current) && W.add(t.current);
|
|
180
180
|
for (const b of L) W.has(b) || (E?.unobserve(b), L.delete(b));
|
|
181
181
|
for (const b of W) L.has(b) || (E?.observe(b), L.add(b));
|
|
182
182
|
const D = C();
|
|
183
183
|
if (_.length !== D.inlineItemCount) return;
|
|
184
184
|
const c = Ze({
|
|
185
|
-
container:
|
|
185
|
+
container: y,
|
|
186
186
|
items: I,
|
|
187
187
|
trigger: t.current,
|
|
188
188
|
itemElements: _,
|
|
@@ -193,9 +193,9 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
193
193
|
layout: c,
|
|
194
194
|
isOpen: D.isOpen
|
|
195
195
|
}, F(c), R && !h && T();
|
|
196
|
-
}, E = f(globalThis.ResizeObserver) ? new ResizeObserver(
|
|
197
|
-
p.current =
|
|
198
|
-
const x = new MutationObserver(
|
|
196
|
+
}, E = f(globalThis.ResizeObserver) ? new ResizeObserver(g) : void 0;
|
|
197
|
+
p.current = g, g();
|
|
198
|
+
const x = new MutationObserver(g);
|
|
199
199
|
if (x.observe(I, {
|
|
200
200
|
attributes: !0,
|
|
201
201
|
attributeFilter: [
|
|
@@ -206,10 +206,10 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
206
206
|
characterData: !0,
|
|
207
207
|
childList: !0,
|
|
208
208
|
subtree: !0
|
|
209
|
-
}), x.observe(
|
|
210
|
-
const _ = setInterval(
|
|
211
|
-
return window.addEventListener("resize",
|
|
212
|
-
p.current = void 0, clearInterval(_), x.disconnect(), window.removeEventListener("resize",
|
|
209
|
+
}), x.observe(y, { childList: !0 }), !f(E)) {
|
|
210
|
+
const _ = setInterval(g, Pe);
|
|
211
|
+
return window.addEventListener("resize", g), () => {
|
|
212
|
+
p.current = void 0, clearInterval(_), x.disconnect(), window.removeEventListener("resize", g);
|
|
213
213
|
};
|
|
214
214
|
}
|
|
215
215
|
return () => {
|
|
@@ -227,34 +227,34 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
227
227
|
p.current?.();
|
|
228
228
|
}, [
|
|
229
229
|
n,
|
|
230
|
-
|
|
230
|
+
a,
|
|
231
231
|
s,
|
|
232
232
|
i
|
|
233
233
|
]), null;
|
|
234
234
|
}), tt = ({ itemCount: r, inlineItemCount: e }) => {
|
|
235
|
-
const t = k(null), n = k(null),
|
|
235
|
+
const t = k(null), n = k(null), a = k(null), [s, l] = q({
|
|
236
236
|
visibleItemCount: e,
|
|
237
237
|
hasOverflow: r > e
|
|
238
238
|
});
|
|
239
239
|
return {
|
|
240
240
|
containerRef: t,
|
|
241
241
|
itemsRef: n,
|
|
242
|
-
triggerRef:
|
|
242
|
+
triggerRef: a,
|
|
243
243
|
updateLayout: J((i) => {
|
|
244
|
-
l((
|
|
244
|
+
l((o) => o.visibleItemCount !== i.visibleItemCount || o.hasOverflow !== i.hasOverflow ? i : o);
|
|
245
245
|
}, []),
|
|
246
246
|
...s
|
|
247
247
|
};
|
|
248
|
-
}, rt = Y("button, a[href], input, select, textarea, [tabindex]"), ce = ({ items: r, popup: e, trigger: t, root: n, removedIndex:
|
|
249
|
-
const l = [...Array.from(r?.children ?? []), ...Array.from(e?.children ?? [])].filter((i) => i !== s).sort((i,
|
|
248
|
+
}, rt = Y("button, a[href], input, select, textarea, [tabindex]"), ce = ({ items: r, popup: e, trigger: t, root: n, removedIndex: a, excludedItem: s }) => {
|
|
249
|
+
const l = [...Array.from(r?.children ?? []), ...Array.from(e?.children ?? [])].filter((i) => i !== s).sort((i, o) => Math.abs(Number(i.getAttribute("data-item-index")) - a) - Math.abs(Number(o.getAttribute("data-item-index")) - a) || Number(o.getAttribute("data-item-index")) - Number(i.getAttribute("data-item-index")));
|
|
250
250
|
for (const i of l)
|
|
251
251
|
if (!i.hasAttribute("inert")) {
|
|
252
|
-
for (const
|
|
252
|
+
for (const o of Array.from(i.querySelectorAll(rt))) if (!o.matches(":disabled") && !f(o.closest("[inert]")) && (o.focus(), o.ownerDocument.activeElement === o))
|
|
253
253
|
return;
|
|
254
254
|
}
|
|
255
255
|
t?.focus(), !(f(t) && t.ownerDocument.activeElement === t) && n?.focus();
|
|
256
|
-
}, nt = ({ containerRef: r, itemsRef: e, triggerRef: t, popup: n, itemCount:
|
|
257
|
-
const [C, F] = q(!1), [T,
|
|
256
|
+
}, nt = ({ containerRef: r, itemsRef: e, triggerRef: t, popup: n, itemCount: a, canExpand: s, isPopupOpen: l, isOpen: i, isHovered: o, showOverflowCount: d, onFocusCapture: p, onBlurCapture: O }) => {
|
|
257
|
+
const [C, F] = q(!1), [T, y] = q(), I = d ?? T ?? (o || C || i), L = z(({ index: c, element: v, isInPopup: h }) => {
|
|
258
258
|
ce({
|
|
259
259
|
items: h && s ? null : e.current,
|
|
260
260
|
popup: h && l ? n : null,
|
|
@@ -263,9 +263,9 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
263
263
|
removedIndex: c,
|
|
264
264
|
excludedItem: v
|
|
265
265
|
});
|
|
266
|
-
}),
|
|
266
|
+
}), g = J(() => {
|
|
267
267
|
const c = r.current;
|
|
268
|
-
c?.focus(), F(c?.ownerDocument.activeElement === c),
|
|
268
|
+
c?.focus(), F(c?.ownerDocument.activeElement === c), y(void 0);
|
|
269
269
|
}, [r]), E = z(() => {
|
|
270
270
|
if (l) return;
|
|
271
271
|
const c = r.current, v = c?.ownerDocument, h = v?.activeElement, R = f(h) && e.current?.contains(h) && !f(h.closest("[inert]")), b = f(h) && h !== v?.body && !c?.contains(h) && !n?.contains(h);
|
|
@@ -276,7 +276,7 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
276
276
|
popup: null,
|
|
277
277
|
trigger: null,
|
|
278
278
|
root: c,
|
|
279
|
-
removedIndex:
|
|
279
|
+
removedIndex: a
|
|
280
280
|
});
|
|
281
281
|
return;
|
|
282
282
|
}
|
|
@@ -286,7 +286,7 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
286
286
|
return;
|
|
287
287
|
}
|
|
288
288
|
c?.focus({ preventScroll: !0 });
|
|
289
|
-
}), x = J(() => (queueMicrotask(E), !1), [E]), _ = fe(
|
|
289
|
+
}), x = J(() => (queueMicrotask(E), !1), [E]), _ = fe(g);
|
|
290
290
|
return {
|
|
291
291
|
hasFocus: C,
|
|
292
292
|
isCountVisible: I,
|
|
@@ -294,23 +294,23 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
294
294
|
schedulePopupFocusRestoration: x,
|
|
295
295
|
resetFocusWhenFocusedTriggerUnmounts: _,
|
|
296
296
|
handleFocusCapture: (c) => {
|
|
297
|
-
F(!0), e.current?.contains(c.target) &&
|
|
297
|
+
F(!0), e.current?.contains(c.target) && y((v) => v ?? I), p?.(c);
|
|
298
298
|
},
|
|
299
299
|
handleBlurCapture: (c) => {
|
|
300
300
|
const v = c.currentTarget.contains(c.relatedTarget) || (n?.contains(c.relatedTarget) ?? !1);
|
|
301
|
-
F(v), e.current?.contains(c.relatedTarget) ||
|
|
301
|
+
F(v), e.current?.contains(c.relatedTarget) || y(void 0), O?.(c);
|
|
302
302
|
}
|
|
303
303
|
};
|
|
304
|
-
}, N = (r) => r.stopPropagation(), Mt = ({ children: r, showOverflowCount: e, maxInlineCount: t, overflowLabel: n = Y("Show all items"), open:
|
|
305
|
-
const [L,
|
|
306
|
-
controlled:
|
|
304
|
+
}, N = (r) => r.stopPropagation(), Mt = ({ children: r, showOverflowCount: e, maxInlineCount: t, overflowLabel: n = Y("Show all items"), open: a, defaultOpen: s = !1, onOpenChange: l, actionsRef: i, triggerProps: o, popupProps: d, className: p, onMouseEnter: O, onMouseLeave: C, onFocusCapture: F, onBlurCapture: T, ref: y, ...I }) => {
|
|
305
|
+
const [L, g] = q(!1), [E, x] = q(null), [_, W] = De({
|
|
306
|
+
controlled: a,
|
|
307
307
|
default: s,
|
|
308
308
|
name: Y("OverflowingList"),
|
|
309
309
|
state: "open"
|
|
310
310
|
}), D = k(null), c = i ?? D, v = f(t) && Number.isFinite(t) ? Math.min(r.length, Math.max(0, Math.floor(t))) : r.length, { containerRef: h, itemsRef: R, triggerRef: b, visibleItemCount: U, hasOverflow: ve, updateLayout: he } = tt({
|
|
311
311
|
itemCount: r.length,
|
|
312
312
|
inlineItemCount: v
|
|
313
|
-
}), G = ve && (_ || e !== !1), ee = _ && G, { hasFocus: _e, isCountVisible: te, restoreItemFocus: re, schedulePopupFocusRestoration: be, resetFocusWhenFocusedTriggerUnmounts: pe, handleFocusCapture:
|
|
313
|
+
}), G = ve && (_ || e !== !1), ee = _ && G, { hasFocus: _e, isCountVisible: te, restoreItemFocus: re, schedulePopupFocusRestoration: be, resetFocusWhenFocusedTriggerUnmounts: pe, handleFocusCapture: ye, handleBlurCapture: ge } = nt({
|
|
314
314
|
containerRef: h,
|
|
315
315
|
itemsRef: R,
|
|
316
316
|
triggerRef: b,
|
|
@@ -323,7 +323,7 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
323
323
|
showOverflowCount: e,
|
|
324
324
|
onFocusCapture: F,
|
|
325
325
|
onBlurCapture: T
|
|
326
|
-
}), ne = (e ?? (L || _e)) || _, we =
|
|
326
|
+
}), ne = (e ?? (L || _e)) || _, we = $(h, y), Fe = $(b, pe, o?.ref), Ce = $(x, d?.ref), oe = ne && e !== !1 ? U : v, ae = r.length - U, Ie = z(() => {
|
|
327
327
|
c.current?.close();
|
|
328
328
|
});
|
|
329
329
|
return /* @__PURE__ */ M(j, { children: [/* @__PURE__ */ M("div", {
|
|
@@ -332,20 +332,20 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
332
332
|
tabIndex: I.tabIndex ?? -1,
|
|
333
333
|
className: S(V.root, p),
|
|
334
334
|
onMouseEnter: (m) => {
|
|
335
|
-
|
|
335
|
+
g(!0), O?.(m);
|
|
336
336
|
},
|
|
337
337
|
onMouseLeave: (m) => {
|
|
338
|
-
|
|
338
|
+
g(!1), C?.(m);
|
|
339
339
|
},
|
|
340
|
-
onFocusCapture:
|
|
341
|
-
onBlurCapture:
|
|
340
|
+
onFocusCapture: ye,
|
|
341
|
+
onBlurCapture: ge,
|
|
342
342
|
children: [/* @__PURE__ */ u("div", {
|
|
343
343
|
ref: R,
|
|
344
344
|
className: V.items,
|
|
345
345
|
children: r.slice(0, v).map((m, w) => /* @__PURE__ */ u(ie, {
|
|
346
346
|
index: w,
|
|
347
|
-
isHidden: w >=
|
|
348
|
-
isLastVisible: e !== !1 && w ===
|
|
347
|
+
isHidden: w >= oe,
|
|
348
|
+
isLastVisible: e !== !1 && w === oe - 1,
|
|
349
349
|
isInPopup: !1,
|
|
350
350
|
onFocusLost: re,
|
|
351
351
|
children: m
|
|
@@ -358,17 +358,17 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
358
358
|
},
|
|
359
359
|
children: [G && /* @__PURE__ */ u(B.Trigger, {
|
|
360
360
|
type: "button",
|
|
361
|
-
"aria-label": `+${
|
|
362
|
-
...
|
|
363
|
-
onClick:
|
|
364
|
-
onMouseDown:
|
|
365
|
-
onPointerDown:
|
|
366
|
-
onKeyDown:
|
|
367
|
-
onKeyUp:
|
|
361
|
+
"aria-label": `+${ae} ${n}`,
|
|
362
|
+
...o,
|
|
363
|
+
onClick: o?.onClick ?? N,
|
|
364
|
+
onMouseDown: o?.onMouseDown ?? N,
|
|
365
|
+
onPointerDown: o?.onPointerDown ?? N,
|
|
366
|
+
onKeyDown: o?.onKeyDown ?? N,
|
|
367
|
+
onKeyUp: o?.onKeyUp ?? N,
|
|
368
368
|
ref: Fe,
|
|
369
|
-
className: (m) => S(V.trigger, Z(
|
|
369
|
+
className: (m) => S(V.trigger, Z(o?.className) ? o.className(m) : o?.className),
|
|
370
370
|
"data-visible": te || void 0,
|
|
371
|
-
children: Ee(
|
|
371
|
+
children: Ee(o?.children) ? `+${ae}` : o.children
|
|
372
372
|
}), /* @__PURE__ */ u(B.Portal, { children: /* @__PURE__ */ u(B.Positioner, {
|
|
373
373
|
anchor: h,
|
|
374
374
|
align: "start",
|
|
@@ -414,53 +414,53 @@ var Re = "_container_1hm4x_1", Ae = "_layer_1hm4x_9", ke = "_visible_1hm4x_23",
|
|
|
414
414
|
onLayoutChange: he,
|
|
415
415
|
onOverflowUnavailable: Ie
|
|
416
416
|
})] });
|
|
417
|
-
},
|
|
418
|
-
header:
|
|
419
|
-
titleRow:
|
|
417
|
+
}, ot = "_header_1dz7y_1", at = "_titleRow_1dz7y_8", st = "_title_1dz7y_8", it = "_actions_1dz7y_21", lt = "_description_1dz7y_27", H = {
|
|
418
|
+
header: ot,
|
|
419
|
+
titleRow: at,
|
|
420
420
|
title: st,
|
|
421
421
|
actions: it,
|
|
422
422
|
description: lt
|
|
423
|
-
}, ct = ({ title: r, description: e, actions: t, level: n = 2, size:
|
|
424
|
-
const C = Te(), F = X(e) ? Le(e) : f(e) && e !== !1, T = X(e) && l !== !1,
|
|
423
|
+
}, ct = ({ title: r, description: e, actions: t, level: n = 2, size: a = "md", color: s = "primary", descriptionLineClamp: l = 5, isDescriptionFocusable: i = !1, render: o, ref: d, className: p, ...O }) => {
|
|
424
|
+
const C = Te(), F = X(e) ? Le(e) : f(e) && e !== !1, T = X(e) && l !== !1, y = X(e) ? /* @__PURE__ */ u(de, {
|
|
425
425
|
style: { whiteSpace: "pre-wrap" },
|
|
426
426
|
children: e
|
|
427
427
|
}) : e;
|
|
428
428
|
return Q({
|
|
429
|
-
render:
|
|
429
|
+
render: o,
|
|
430
430
|
ref: d,
|
|
431
431
|
props: {
|
|
432
432
|
...O,
|
|
433
|
-
className: S(
|
|
433
|
+
className: S(H.header, p),
|
|
434
434
|
children: /* @__PURE__ */ M(j, { children: [/* @__PURE__ */ M("div", {
|
|
435
|
-
className:
|
|
435
|
+
className: H.titleRow,
|
|
436
436
|
children: [/* @__PURE__ */ u(Oe, {
|
|
437
437
|
level: n,
|
|
438
|
-
size:
|
|
438
|
+
size: a,
|
|
439
439
|
color: s,
|
|
440
|
-
className:
|
|
440
|
+
className: H.title,
|
|
441
441
|
"aria-describedby": F ? C : void 0,
|
|
442
442
|
children: r
|
|
443
443
|
}), f(t) && /* @__PURE__ */ u("div", {
|
|
444
|
-
className:
|
|
444
|
+
className: H.actions,
|
|
445
445
|
children: t
|
|
446
446
|
})]
|
|
447
447
|
}), F && /* @__PURE__ */ u("div", {
|
|
448
448
|
id: C,
|
|
449
|
-
className:
|
|
449
|
+
className: H.description,
|
|
450
450
|
children: T ? /* @__PURE__ */ u(Ne, {
|
|
451
451
|
text: e,
|
|
452
452
|
lineClamp: l,
|
|
453
453
|
isTooltipMultiline: !0,
|
|
454
454
|
isFocusable: i
|
|
455
|
-
}) :
|
|
455
|
+
}) : y
|
|
456
456
|
})] })
|
|
457
457
|
}
|
|
458
458
|
});
|
|
459
459
|
}, ut = "_root_ztxxm_1", dt = "_fullWidth_ztxxm_20", ue = {
|
|
460
460
|
root: ut,
|
|
461
461
|
fullWidth: dt
|
|
462
|
-
}, mt = ({ align: r = "left", color: e = "primary", fullWidth: t = !0, className: n, render:
|
|
463
|
-
render:
|
|
462
|
+
}, mt = ({ align: r = "left", color: e = "primary", fullWidth: t = !0, className: n, render: a, ref: s, ...l }) => Q({
|
|
463
|
+
render: a,
|
|
464
464
|
ref: s,
|
|
465
465
|
props: {
|
|
466
466
|
...l,
|
|
@@ -2,10 +2,10 @@ import { t as p } from "./isDefined-fMi6eQ4r.js";
|
|
|
2
2
|
import { t as T } from "./doNotTranslate-BSVT8Xyd.js";
|
|
3
3
|
import { t as _ } from "./mergeClassNames-ClFMR1v0.js";
|
|
4
4
|
import { n as g, t as B } from "./TabsTabContent-DPkLTBi2.js";
|
|
5
|
-
import { useRender as E } from "@base-ui/react/use-render";
|
|
6
5
|
import { isString as L } from "@sniptt/guards";
|
|
7
|
-
import { clsx as
|
|
6
|
+
import { clsx as E } from "clsx";
|
|
8
7
|
import { jsx as d, jsxs as R } from "react/jsx-runtime";
|
|
8
|
+
import { useRender as I } from "@base-ui/react/use-render";
|
|
9
9
|
import { useDirection as K } from "@base-ui/react/direction-provider";
|
|
10
10
|
import { Tabs as h } from "@base-ui/react/tabs";
|
|
11
11
|
var C = "_root_1iwl8_1", O = "_list_1iwl8_14", S = "_item_1iwl8_25", D = "_content_1iwl8_36", H = "_separator_1iwl8_56", b = {
|
|
@@ -14,7 +14,7 @@ var C = "_root_1iwl8_1", O = "_list_1iwl8_14", S = "_item_1iwl8_25", D = "_conte
|
|
|
14
14
|
item: S,
|
|
15
15
|
content: D,
|
|
16
16
|
separator: H
|
|
17
|
-
}, P = ({ children: a, href: r, render: i, title: o, current: t, className: s, ref: e, "aria-current": n = t ? "page" : void 0, ...m }) =>
|
|
17
|
+
}, P = ({ children: a, href: r, render: i, title: o, current: t, className: s, ref: e, "aria-current": n = t ? "page" : void 0, ...m }) => I({
|
|
18
18
|
defaultTagName: p(r) ? "a" : "span",
|
|
19
19
|
render: i,
|
|
20
20
|
ref: e,
|
|
@@ -25,16 +25,16 @@ var C = "_root_1iwl8_1", O = "_list_1iwl8_14", S = "_item_1iwl8_25", D = "_conte
|
|
|
25
25
|
title: o ?? (L(a) ? a : void 0),
|
|
26
26
|
"aria-current": n,
|
|
27
27
|
"data-linked": p(r) || void 0,
|
|
28
|
-
className:
|
|
28
|
+
className: E(b.content, s)
|
|
29
29
|
}
|
|
30
|
-
}), sa = ({ links: a, className: r, render: i, ref: o, "aria-label": t = T("Breadcrumb"), ...s }) =>
|
|
30
|
+
}), sa = ({ links: a, className: r, render: i, ref: o, "aria-label": t = T("Breadcrumb"), ...s }) => I({
|
|
31
31
|
defaultTagName: "nav",
|
|
32
32
|
render: i,
|
|
33
33
|
ref: o,
|
|
34
34
|
props: {
|
|
35
35
|
...s,
|
|
36
36
|
"aria-label": t,
|
|
37
|
-
className:
|
|
37
|
+
className: E(b.root, r),
|
|
38
38
|
children: /* @__PURE__ */ d("ol", {
|
|
39
39
|
className: b.list,
|
|
40
40
|
children: a.map((e, n) => /* @__PURE__ */ R("li", {
|
|
@@ -2,21 +2,21 @@ import { t as k } from "./isDefined-fMi6eQ4r.js";
|
|
|
2
2
|
import { Ot as P, kt as D } from "./TablerIcons-B6BhOlW_.js";
|
|
3
3
|
import { t as C } from "./doNotTranslate-BSVT8Xyd.js";
|
|
4
4
|
import { t as y } from "./mergeClassNames-ClFMR1v0.js";
|
|
5
|
-
import { r as I, t as L } from "./Button-
|
|
6
|
-
import { r as N } from "./OverflowingTextWithTooltip-
|
|
7
|
-
import { t as x } from "./ListItem-
|
|
8
|
-
import { a as w, i as z, s as G } from "./Dropdown-
|
|
5
|
+
import { r as I, t as L } from "./Button-wpJzTy9O.js";
|
|
6
|
+
import { r as N } from "./OverflowingTextWithTooltip-aPLt9O1-.js";
|
|
7
|
+
import { t as x } from "./ListItem-mIMpO2Ia.js";
|
|
8
|
+
import { a as w, i as z, s as G } from "./Dropdown-CWXJOVhy.js";
|
|
9
9
|
import { n as O, t as R } from "./TabsTabContent-DPkLTBi2.js";
|
|
10
|
-
import { useRender as A } from "@base-ui/react/use-render";
|
|
11
10
|
import { isInteger as _ } from "@sniptt/guards";
|
|
12
11
|
import { clsx as h } from "clsx";
|
|
12
|
+
import { Fragment as A, jsx as r, jsxs as q } from "react/jsx-runtime";
|
|
13
|
+
import { useRender as j } from "@base-ui/react/use-render";
|
|
13
14
|
import { useContext as B } from "react";
|
|
14
|
-
import { Fragment as q, jsx as r, jsxs as j } from "react/jsx-runtime";
|
|
15
15
|
import { Button as E } from "@base-ui/react/button";
|
|
16
|
-
var
|
|
17
|
-
pager:
|
|
18
|
-
position:
|
|
19
|
-
icon:
|
|
16
|
+
var S = "_pager_wkox0_1", F = "_position_wkox0_11", J = "_icon_wkox0_21", g = {
|
|
17
|
+
pager: S,
|
|
18
|
+
position: F,
|
|
19
|
+
icon: J
|
|
20
20
|
}, no = ({ index: o, count: e, onIndexChange: t, positionText: s, previousLabel: n, nextLabel: i, disabled: a = !1, positionPlacement: m = "between", render: l, ref: u, className: b, ...f }) => {
|
|
21
21
|
const p = _(o) && _(e) && o >= 0 && o < e, c = a || !p || o === 0, v = a || !p || o === e - 1, d = /* @__PURE__ */ r(N, {
|
|
22
22
|
render: /* @__PURE__ */ r("span", {}),
|
|
@@ -25,7 +25,7 @@ var F = "_pager_wkox0_1", S = "_position_wkox0_11", $ = "_icon_wkox0_21", g = {
|
|
|
25
25
|
"aria-atomic": "true",
|
|
26
26
|
children: s
|
|
27
27
|
});
|
|
28
|
-
return
|
|
28
|
+
return j({
|
|
29
29
|
render: l,
|
|
30
30
|
ref: u,
|
|
31
31
|
props: {
|
|
@@ -33,7 +33,7 @@ var F = "_pager_wkox0_1", S = "_position_wkox0_11", $ = "_icon_wkox0_21", g = {
|
|
|
33
33
|
...f,
|
|
34
34
|
className: h(g.pager, b),
|
|
35
35
|
"data-position-placement": m,
|
|
36
|
-
children: /* @__PURE__ */
|
|
36
|
+
children: /* @__PURE__ */ q(A, { children: [
|
|
37
37
|
m === "start" && d,
|
|
38
38
|
/* @__PURE__ */ r(w, {
|
|
39
39
|
size: "sm",
|
|
@@ -114,14 +114,14 @@ var F = "_pager_wkox0_1", S = "_position_wkox0_11", $ = "_icon_wkox0_21", g = {
|
|
|
114
114
|
orange: "Orange",
|
|
115
115
|
amber: "Amber",
|
|
116
116
|
yellow: "Yellow"
|
|
117
|
-
}),
|
|
117
|
+
}), M = "_button_quwcq_1", U = { button: M }, po = ({ active: o = !1, className: e, children: t, startIcon: s, endIcon: n, badge: i, size: a, ...m }) => {
|
|
118
118
|
const l = B(I), u = a ?? l?.size ?? "sm";
|
|
119
119
|
return /* @__PURE__ */ r(L, {
|
|
120
120
|
...m,
|
|
121
121
|
variant: "ghost",
|
|
122
122
|
size: u,
|
|
123
123
|
"data-active": o || void 0,
|
|
124
|
-
className: y(h(O.tab,
|
|
124
|
+
className: y(h(O.tab, U.button), e),
|
|
125
125
|
children: /* @__PURE__ */ r(R, {
|
|
126
126
|
startIcon: s,
|
|
127
127
|
endIcon: n,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const h=require("./isDefined-DS2Q42p5.cjs"),C=require("./doNotTranslate-CHE7WmRS.cjs"),L=require("./mergeClassNames-D4lshrT6.cjs"),v=require("./Button-
|
|
1
|
+
const h=require("./isDefined-DS2Q42p5.cjs"),C=require("./doNotTranslate-CHE7WmRS.cjs"),L=require("./mergeClassNames-D4lshrT6.cjs"),v=require("./Button-CbJ3qEQ9.cjs"),y=require("./OverflowingTextWithTooltip-B21zZWP6.cjs"),D=require("./ListItem-D6FYdx6v.cjs"),g=require("./Dropdown-CTTQTn7B.cjs"),f=require("./TabsTabContent-6rkARU9F.cjs");let T=require("@sniptt/guards"),P=require("clsx"),r=require("react/jsx-runtime"),O=require("@base-ui/react/use-render"),j=require("react"),I=require("@base-ui/react/button"),x=require("@tabler/icons-react");var k="_pager_wkox0_1",N="_position_wkox0_11",z="_icon_wkox0_21",m={pager:k,position:N,icon:z},A=({index:e,count:t,onIndexChange:n,positionText:a,previousLabel:s,nextLabel:i,disabled:o=!1,positionPlacement:u="between",render:l,ref:c,className:p,...q})=>{const d=(0,T.isInteger)(e)&&(0,T.isInteger)(t)&&e>=0&&e<t,_=o||!d||e===0,w=o||!d||e===t-1,b=(0,r.jsx)(y.Text,{render:(0,r.jsx)("span",{}),className:m.position,"aria-live":"polite","aria-atomic":"true",children:a});return(0,O.useRender)({render:l,ref:c,props:{role:"group",...q,className:(0,P.clsx)(m.pager,p),"data-position-placement":u,children:(0,r.jsxs)(r.Fragment,{children:[u==="start"&&b,(0,r.jsx)(g.LightIconButton,{size:"sm",disabled:_,onClick:()=>n(e-1),"aria-label":s,children:(0,r.jsx)(x.IconChevronLeft,{className:m.icon})}),u==="between"&&b,(0,r.jsx)(g.LightIconButton,{size:"sm",disabled:w,onClick:()=>n(e+1),"aria-label":i,children:(0,r.jsx)(x.IconChevronRight,{className:m.icon})})]})}})},G=()=>{const{pageId:e,isPageActive:t,open:n,goToPage:a,goBack:s,canGoBack:i}=g.useDropdownContext();return{page:e,isActive:t&&n,goToPage:o=>a({id:o}),goBack:s,canGoBack:i}},R=()=>{const e=(0,j.useContext)(g.DropdownPlacementContext);if(!h.isDefined(e))throw new Error(C.doNotTranslate("useDropdownPlacementOrThrow must be used within Dropdown.Content"));return e},E=({color:e,selected:t,selectionAppearance:n,active:a,focused:s,indicator:i,startIcon:o,endIcon:u,description:l,descriptionPlacement:c,shortcut:p,shortcutJoinLabel:q,hasSubmenu:d,disabled:_=!1,type:w="button",children:b,...B})=>(0,r.jsx)(D.ListItem,{color:e,selected:t,selectionAppearance:n,active:a,focused:s,indicator:i,startIcon:o,endIcon:u,description:l,descriptionPlacement:c,shortcut:p,shortcutJoinLabel:q,hasSubmenu:d,disabled:_,render:(0,r.jsx)(I.Button,{...B,nativeButton:!0,type:w,disabled:_}),children:b}),S=C.doNotTranslate({gray:"Gray",tomato:"Tomato",red:"Red",ruby:"Ruby",crimson:"Crimson",pink:"Pink",plum:"Plum",purple:"Purple",violet:"Violet",iris:"Iris",cyan:"Cyan",turquoise:"Turquoise",sky:"Sky",blue:"Blue",jade:"Jade",green:"Green",grass:"Grass",mint:"Mint",lime:"Lime",bronze:"Bronze",gold:"Gold",brown:"Brown",orange:"Orange",amber:"Amber",yellow:"Yellow"}),F="_button_quwcq_1",U={button:F},J=({active:e=!1,className:t,children:n,startIcon:a,endIcon:s,badge:i,size:o,...u})=>{const l=(0,j.useContext)(v.ButtonGroupContext),c=o??l?.size??"sm";return(0,r.jsx)(v.Button,{...u,variant:"ghost",size:c,"data-active":e||void 0,className:L.mergeClassNames((0,P.clsx)(f.Tab_module_default.tab,U.button),t),children:(0,r.jsx)(f.TabsTabContent,{startIcon:a,endIcon:s,badge:i,children:n})})};Object.defineProperty(exports,"CountPager",{enumerable:!0,get:function(){return A}});Object.defineProperty(exports,"DEFAULT_COLOR_LABELS",{enumerable:!0,get:function(){return S}});Object.defineProperty(exports,"ListItemButton",{enumerable:!0,get:function(){return E}});Object.defineProperty(exports,"TabButton",{enumerable:!0,get:function(){return J}});Object.defineProperty(exports,"useDropdownPage",{enumerable:!0,get:function(){return G}});Object.defineProperty(exports,"useDropdownPlacementOrThrow",{enumerable:!0,get:function(){return R}});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const g=require("./isDefined-DS2Q42p5.cjs"),f=require("./doNotTranslate-CHE7WmRS.cjs"),N=require("./mergeClassNames-D4lshrT6.cjs"),c=require("./TabsTabContent-6rkARU9F.cjs");let
|
|
1
|
+
const g=require("./isDefined-DS2Q42p5.cjs"),f=require("./doNotTranslate-CHE7WmRS.cjs"),N=require("./mergeClassNames-D4lshrT6.cjs"),c=require("./TabsTabContent-6rkARU9F.cjs");let C=require("@sniptt/guards"),A=require("clsx"),o=require("react/jsx-runtime"),q=require("@base-ui/react/use-render"),I=require("@base-ui/react/direction-provider"),p=require("@base-ui/react/tabs");var B="_root_1iwl8_1",k="_list_1iwl8_14",D="_item_1iwl8_25",L="_content_1iwl8_36",R="_separator_1iwl8_56",T={root:B,list:k,item:D,content:L,separator:R},K=({children:e,href:a,render:i,title:n,current:r,className:s,ref:t,"aria-current":l=r?"page":void 0,...b})=>(0,q.useRender)({defaultTagName:g.isDefined(a)?"a":"span",render:i,ref:t,props:{...b,children:e,href:a,title:n??((0,C.isString)(e)?e:void 0),"aria-current":l,"data-linked":g.isDefined(a)||void 0,className:(0,A.clsx)(T.content,s)}}),O=({links:e,className:a,render:i,ref:n,"aria-label":r=f.doNotTranslate("Breadcrumb"),...s})=>(0,q.useRender)({defaultTagName:"nav",render:i,ref:n,props:{...s,"aria-label":r,className:(0,A.clsx)(T.root,a),children:(0,o.jsx)("ol",{className:T.list,children:e.map((t,l)=>(0,o.jsxs)("li",{className:T.item,children:[l>0&&(0,o.jsx)("span",{className:T.separator,"aria-hidden":"true",children:"/"}),(0,o.jsx)(K,{...t,current:l===e.length-1})]},l))})}}),P=({className:e,...a})=>(0,o.jsx)(p.Tabs.Indicator,{...a,className:N.mergeClassNames(c.Tab_module_default.indicator,e)}),S='[role="tab"]',H='[role="tablist"]',U=f.doNotTranslate("[hidden], [inert]"),w=e=>e.hasAttribute("data-disabled")||e.hasAttribute("disabled")||e.getAttribute("aria-disabled")==="true"||g.isDefined(e.closest(U)),z=({event:e,direction:a,loopFocus:i})=>{if(e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)return;const n=e.currentTarget,r=[];n.querySelectorAll(S).forEach(d=>{d.closest(H)===n&&r.push(d)});const s=r.findIndex(d=>d===e.target);if(s===-1)return;const t=f.doNotTranslate(a==="rtl"?["ArrowLeft","ArrowRight"]:["ArrowRight","ArrowLeft"]),[l,b]=n.getAttribute("data-orientation")==="vertical"?f.doNotTranslate(["ArrowDown","ArrowUp"]):t;if(!f.doNotTranslate([l,b,"Home","End"]).includes(e.key))return;const x=e.key===b;let _=s+(x?-1:1);e.key==="Home"&&(_=0),e.key==="End"&&(_=r.length-1);const E=_<0||_>=r.length,j=x?r.length-1:0,h=r[E&&i?j:_];if(!g.isDefined(h)||!w(h))return;e.preventBaseUIHandler(),e.preventDefault();const m=r.filter(d=>!w(d));let u;if(e.key==="Home"&&(u=m[0]),e.key==="End"&&(u=m[m.length-1]),e.key===l||e.key===b){const d=x?[...m].reverse():m;u=d.find(y=>x?r.indexOf(y)<s:r.indexOf(y)>s),u??=i?d[0]:void 0}if(!g.isDefined(u)||u===e.target)return;e.stopPropagation();const v=u;queueMicrotask(()=>v.focus())},M=({className:e,onKeyDown:a,loopFocus:i=!0,...n})=>{const r=(0,I.useDirection)(),s=t=>{if(a?.(t),t.defaultPrevented){t.preventBaseUIHandler();return}t.baseUIHandlerPrevented||z({event:t,direction:r,loopFocus:i})};return(0,o.jsx)(p.Tabs.List,{...n,loopFocus:i,onKeyDown:s,className:N.mergeClassNames(c.Tab_module_default.list,e)})},V=({className:e,...a})=>(0,o.jsx)(p.Tabs.Panel,{...a,className:N.mergeClassNames(c.Tab_module_default.panel,e)}),G=({className:e,...a})=>(0,o.jsx)(p.Tabs.Root,{...a,className:N.mergeClassNames(c.Tab_module_default.root,e)}),J=({className:e,children:a,startIcon:i,endIcon:n,badge:r,highlighted:s=!1,size:t="sm",...l})=>(0,o.jsx)(p.Tabs.Tab,{...l,className:N.mergeClassNames(c.Tab_module_default.tab,e),"data-size":t,"data-highlighted":s||void 0,children:(0,o.jsx)(c.TabsTabContent,{startIcon:i,endIcon:n,badge:r,children:a})}),Q={Root:G,List:M,Tab:J,Indicator:P,Panel:V};Object.defineProperty(exports,"Breadcrumb",{enumerable:!0,get:function(){return O}});Object.defineProperty(exports,"Tabs",{enumerable:!0,get:function(){return Q}});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../VisuallyHidden-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../VisuallyHidden-BOlbK5vT.cjs"),l=require("../accessibility-CByqtBhO.cjs");exports.VisuallyHidden=e.VisuallyHidden;exports.handleClickableElementKeyDown=l.handleClickableElementKeyDown;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type BadgeColor = 'tertiary' | 'inherit' | 'primary' | 'secondary' | 'accent';
|
|
1
|
+
export type BadgeColor = 'tertiary' | 'inherit' | 'primary' | 'red' | 'secondary' | 'accent';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../data-display-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../data-display-B0ANuV9c.cjs");exports.AVATAR_PROPERTIES_BY_SIZE=e.AVATAR_PROPERTIES_BY_SIZE;exports.Avatar=e.Avatar;exports.Badge=e.Badge;exports.Chip=e.Chip;exports.ColorSample=e.ColorSample;exports.Status=e.Status;exports.Tag=e.Tag;
|