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,22 +1,22 @@
|
|
|
1
|
+
import { c as xr, r as kt } from "./theme-B1jMC8En.js";
|
|
1
2
|
import { t as S } from "./isDefined-fMi6eQ4r.js";
|
|
2
3
|
import { t as pe } from "./isRenderableSlot-DT_depzM.js";
|
|
3
|
-
import { $a as
|
|
4
|
+
import { $a as Dr, $s as Or, Aa as Ar, Bo as $r, Dt as tt, Ec as Hr, Lt as Rt, Ot as Mr, kt as Fr, sc as Vr, uo as Lr, wc as zr } from "./TablerIcons-B6BhOlW_.js";
|
|
4
5
|
import { t as P } from "./doNotTranslate-BSVT8Xyd.js";
|
|
5
|
-
import { l as zr, r as Rt } from "./theme-CuGIQBsJ.js";
|
|
6
6
|
import { t as ge } from "./mergeClassNames-ClFMR1v0.js";
|
|
7
7
|
import { t as be } from "./normalizeSearchText-DLmPiBUZ.js";
|
|
8
|
-
import { r as Nt, t as ae } from "./Button-
|
|
9
|
-
import { r as Ur, t as rt } from "./OverflowingTextWithTooltip-
|
|
8
|
+
import { r as Nt, t as ae } from "./Button-wpJzTy9O.js";
|
|
9
|
+
import { r as Ur, t as rt } from "./OverflowingTextWithTooltip-aPLt9O1-.js";
|
|
10
10
|
import { t as Yr } from "./Separator-0LzwPfOn.js";
|
|
11
|
-
import { a as ct, n as Br, r as Wr, s as Ne, t as T } from "./Dropdown-
|
|
12
|
-
import { n as Fe, t as Tt } from "./Input-
|
|
13
|
-
import { a as Q, i as ut, n as Gr, o as We, r as He, t as qr } from "./Radio-
|
|
14
|
-
import { t as Kr } from "./Skeleton-
|
|
15
|
-
import {
|
|
16
|
-
import { isFunction as Ve, isNonEmptyArray as Pe, isNonEmptyString as L, isNull as Pt, isNumber as Jr, isString as Xr, isUndefined as Le } from "@sniptt/guards";
|
|
11
|
+
import { a as ct, n as Br, r as Wr, s as Ne, t as T } from "./Dropdown-CWXJOVhy.js";
|
|
12
|
+
import { n as Fe, t as Tt } from "./Input-B9glruH9.js";
|
|
13
|
+
import { a as Q, i as ut, n as Gr, o as We, r as He, t as qr } from "./Radio-Bg-zmy-1.js";
|
|
14
|
+
import { t as Kr } from "./Skeleton-gAiz2xVU.js";
|
|
15
|
+
import { isFunction as Ve, isNonEmptyArray as Te, isNonEmptyString as L, isNull as Pt, isNumber as Jr, isString as Xr, isUndefined as Le } from "@sniptt/guards";
|
|
17
16
|
import { clsx as G } from "clsx";
|
|
18
|
-
import { Fragment as Zr, Suspense as Qr, createContext as Ye, createElement as en, forwardRef as xe, lazy as tn, memo as De, useCallback as z, useContext as ye, useDebugValue as rn, useDeferredValue as nn, useEffect as te, useId as oe, useImperativeHandle as Be, useLayoutEffect as an, useMemo as he, useRef as U, useState as K } from "react";
|
|
19
17
|
import { Fragment as Z, jsx as i, jsxs as I } from "react/jsx-runtime";
|
|
18
|
+
import { useRender as Pe } from "@base-ui/react/use-render";
|
|
19
|
+
import { Fragment as Zr, Suspense as Qr, createContext as Ye, createElement as en, forwardRef as xe, lazy as tn, memo as De, useCallback as z, useContext as ye, useDebugValue as rn, useDeferredValue as nn, useEffect as te, useId as oe, useImperativeHandle as Be, useLayoutEffect as an, useMemo as he, useRef as U, useState as K } from "react";
|
|
20
20
|
import { useMergedRefs as xt } from "@base-ui/utils/useMergedRefs";
|
|
21
21
|
import { useControlled as Dt } from "@base-ui/utils/useControlled";
|
|
22
22
|
import { useDirection as on } from "@base-ui/react/direction-provider";
|
|
@@ -34,7 +34,7 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
34
34
|
...m,
|
|
35
35
|
selectionValue: $t(m.value),
|
|
36
36
|
searchText: be(m.label)
|
|
37
|
-
})), [e]), d = he(() => new Map(h.map((m) => [m.value, m])), [h]), g = o || !
|
|
37
|
+
})), [e]), d = he(() => new Map(h.map((m) => [m.value, m])), [h]), g = o || !Te(h);
|
|
38
38
|
return /* @__PURE__ */ i(At.Provider, {
|
|
39
39
|
value: {
|
|
40
40
|
countries: h,
|
|
@@ -79,7 +79,7 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
79
79
|
ariaLabelledBy: f,
|
|
80
80
|
ariaLabel: M,
|
|
81
81
|
visibleLabelId: $ ? _ : void 0
|
|
82
|
-
}), H = [b, (S(O) || S(M)) && !S(r) ? N : void 0].filter(L), x = w?.label ?? j, R = S(w) ? w.flag : /* @__PURE__ */ i(
|
|
82
|
+
}), H = [b, (S(O) || S(M)) && !S(r) ? N : void 0].filter(L), x = w?.label ?? j, R = S(w) ? w.flag : /* @__PURE__ */ i(Rt, {}), A = (Y) => ({
|
|
83
83
|
...Y,
|
|
84
84
|
disabled: p
|
|
85
85
|
}), re = ge(G(Fe.input, Fe.md, We.trigger), n);
|
|
@@ -103,7 +103,7 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
103
103
|
id: E,
|
|
104
104
|
"aria-label": M,
|
|
105
105
|
"aria-labelledby": O,
|
|
106
|
-
"aria-describedby":
|
|
106
|
+
"aria-describedby": Te(H) ? H.join(" ") : void 0,
|
|
107
107
|
"aria-disabled": p || void 0,
|
|
108
108
|
openOnHover: p ? !1 : d,
|
|
109
109
|
"data-disabled": p ? "" : void 0,
|
|
@@ -136,13 +136,13 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
136
136
|
]
|
|
137
137
|
});
|
|
138
138
|
}, gn = "no-country", vn = ({ searchLabel: e = P("Search"), noResultsLabel: t = P("No results"), searchProps: r, render: n, ...o }) => {
|
|
139
|
-
const { countries: a, value: s, changeValue: c, disabled: l, noCountryLabel: u, selectionGroupId: h } = nt(), { titleId: d, triggerId: g } = Ne(), m = S(o["aria-label"]) || S(o["aria-labelledby"]) ? void 0 : d ?? g, [f, b] = K(""), y = be(f.trim()), w = L(y), p = a.filter((v) => v.searchText.includes(y)), j = be(u).includes(y), k = j ||
|
|
139
|
+
const { countries: a, value: s, changeValue: c, disabled: l, noCountryLabel: u, selectionGroupId: h } = nt(), { titleId: d, triggerId: g } = Ne(), m = S(o["aria-label"]) || S(o["aria-labelledby"]) ? void 0 : d ?? g, [f, b] = K(""), y = be(f.trim()), w = L(y), p = a.filter((v) => v.searchText.includes(y)), j = be(u).includes(y), k = j || Te(p), C = j && /* @__PURE__ */ i(T.OptionItem, {
|
|
140
140
|
value: "no-country",
|
|
141
141
|
disabled: l,
|
|
142
142
|
startIcon: /* @__PURE__ */ i("span", {
|
|
143
143
|
className: je.flag,
|
|
144
144
|
"aria-hidden": "true",
|
|
145
|
-
children: /* @__PURE__ */ i(
|
|
145
|
+
children: /* @__PURE__ */ i(Rt, {})
|
|
146
146
|
}),
|
|
147
147
|
children: u
|
|
148
148
|
});
|
|
@@ -246,8 +246,8 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
246
246
|
if (!S(e)) throw new Error(P("CurrencyPicker parts must be inside CurrencyPicker.Root"));
|
|
247
247
|
return e;
|
|
248
248
|
}, Ut = ({ disabled: e = !1, searchable: t = !0, searchLabel: r = P("Search"), listLabel: n, emptyLabel: o = P("No results"), searchProps: a, className: s, render: c, ref: l, ...u }) => {
|
|
249
|
-
const { state: h, groupId: d, options: g, selectionProps: m } = zt(), { titleId: f, triggerId: b } = Ne(), { value: y, defaultValue: w = "", onValueChange: p, ...j } = a ?? {}, [k, C] = K(w), v = y ?? k, E = t ? String(v).trim().toLowerCase() : "", _ = g.filter(({ searchText: O }) => O.includes(E)), N =
|
|
250
|
-
return
|
|
249
|
+
const { state: h, groupId: d, options: g, selectionProps: m } = zt(), { titleId: f, triggerId: b } = Ne(), { value: y, defaultValue: w = "", onValueChange: p, ...j } = a ?? {}, [k, C] = K(w), v = y ?? k, E = t ? String(v).trim().toLowerCase() : "", _ = g.filter(({ searchText: O }) => O.includes(E)), N = Te(_), $ = h.disabled || e, M = S(n) ? void 0 : f ?? b;
|
|
250
|
+
return Pe({
|
|
251
251
|
render: c,
|
|
252
252
|
ref: l,
|
|
253
253
|
props: {
|
|
@@ -405,7 +405,7 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
405
405
|
/* @__PURE__ */ i(Q.Portal, {
|
|
406
406
|
container: a,
|
|
407
407
|
children: /* @__PURE__ */ i(Q.Positioner, {
|
|
408
|
-
sideOffset:
|
|
408
|
+
sideOffset: xr.spacingMultiplicator,
|
|
409
409
|
alignItemWithTrigger: !1,
|
|
410
410
|
children: /* @__PURE__ */ i(Q.Popup, { children: t.map(({ value: l, label: u }) => /* @__PURE__ */ I(Q.Item, {
|
|
411
411
|
value: l,
|
|
@@ -483,13 +483,13 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
483
483
|
disabled: f || a,
|
|
484
484
|
"aria-label": l,
|
|
485
485
|
onClick: t,
|
|
486
|
-
children: /* @__PURE__ */ i(
|
|
486
|
+
children: /* @__PURE__ */ i(Mr, { className: se.chevron })
|
|
487
487
|
}), /* @__PURE__ */ i(ct, {
|
|
488
488
|
size: "md",
|
|
489
489
|
disabled: f || s,
|
|
490
490
|
"aria-label": u,
|
|
491
491
|
onClick: r,
|
|
492
|
-
children: /* @__PURE__ */ i(
|
|
492
|
+
children: /* @__PURE__ */ i(Fr, { className: se.chevron })
|
|
493
493
|
})]
|
|
494
494
|
})
|
|
495
495
|
]
|
|
@@ -585,7 +585,7 @@ var At = Ye(void 0), cn = "country:", $t = (e) => `${cn}${e}`, Ht = ({ countries
|
|
|
585
585
|
selected: S(e) ? ce(e) : null,
|
|
586
586
|
onChange: re
|
|
587
587
|
});
|
|
588
|
-
return
|
|
588
|
+
return Pe({
|
|
589
589
|
render: E,
|
|
590
590
|
ref: _,
|
|
591
591
|
props: {
|
|
@@ -1857,7 +1857,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
1857
1857
|
"--form-field-row-content-padding-inline": S(s) ? ut(s) : void 0,
|
|
1858
1858
|
...g
|
|
1859
1859
|
};
|
|
1860
|
-
return
|
|
1860
|
+
return Pe({
|
|
1861
1861
|
render: u,
|
|
1862
1862
|
ref: h,
|
|
1863
1863
|
props: {
|
|
@@ -1911,8 +1911,8 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
1911
1911
|
helperText: oo,
|
|
1912
1912
|
errorMessage: io
|
|
1913
1913
|
}, lo = ({ src: e }) => {
|
|
1914
|
-
const t =
|
|
1915
|
-
return !L(e) || r ? /* @__PURE__ */ i(
|
|
1914
|
+
const t = kt(), [r, n] = K(!1);
|
|
1915
|
+
return !L(e) || r ? /* @__PURE__ */ i(Dr, {
|
|
1916
1916
|
size: t.icon.size.lg,
|
|
1917
1917
|
"aria-hidden": !0
|
|
1918
1918
|
}) : /* @__PURE__ */ i("img", {
|
|
@@ -1937,7 +1937,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
1937
1937
|
}
|
|
1938
1938
|
R || !S(Oe) || t?.(Oe);
|
|
1939
1939
|
};
|
|
1940
|
-
return
|
|
1940
|
+
return Pe({
|
|
1941
1941
|
render: p,
|
|
1942
1942
|
ref: j,
|
|
1943
1943
|
props: {
|
|
@@ -1980,14 +1980,14 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
1980
1980
|
}),
|
|
1981
1981
|
re ? /* @__PURE__ */ i(ae, {
|
|
1982
1982
|
type: "button",
|
|
1983
|
-
startIcon: /* @__PURE__ */ i(
|
|
1983
|
+
startIcon: /* @__PURE__ */ i(Hr, {}),
|
|
1984
1984
|
onClick: n,
|
|
1985
1985
|
disabled: o,
|
|
1986
1986
|
variant: "outline",
|
|
1987
1987
|
children: h
|
|
1988
1988
|
}) : /* @__PURE__ */ i(ae, {
|
|
1989
1989
|
type: "button",
|
|
1990
|
-
startIcon: /* @__PURE__ */ i(
|
|
1990
|
+
startIcon: /* @__PURE__ */ i(Vr, {}),
|
|
1991
1991
|
onClick: ve,
|
|
1992
1992
|
disabled: R,
|
|
1993
1993
|
focusableWhenDisabled: a && !H,
|
|
@@ -1997,7 +1997,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
1997
1997
|
}),
|
|
1998
1998
|
/* @__PURE__ */ i(ae, {
|
|
1999
1999
|
type: "button",
|
|
2000
|
-
startIcon: /* @__PURE__ */ i(
|
|
2000
|
+
startIcon: /* @__PURE__ */ i(Or, {}),
|
|
2001
2001
|
onClick: r,
|
|
2002
2002
|
disabled: A,
|
|
2003
2003
|
focusableWhenDisabled: a && !x,
|
|
@@ -2093,7 +2093,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
2093
2093
|
className: fe.button,
|
|
2094
2094
|
startIcon: /* @__PURE__ */ i("span", {
|
|
2095
2095
|
className: fe.icon,
|
|
2096
|
-
children: /* @__PURE__ */ i(
|
|
2096
|
+
children: /* @__PURE__ */ i(Ar, {})
|
|
2097
2097
|
})
|
|
2098
2098
|
})
|
|
2099
2099
|
}),
|
|
@@ -2110,7 +2110,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
2110
2110
|
className: fe.button,
|
|
2111
2111
|
startIcon: /* @__PURE__ */ i("span", {
|
|
2112
2112
|
className: fe.icon,
|
|
2113
|
-
children: /* @__PURE__ */ i(
|
|
2113
|
+
children: /* @__PURE__ */ i(Lr, {})
|
|
2114
2114
|
})
|
|
2115
2115
|
})
|
|
2116
2116
|
})
|
|
@@ -2134,7 +2134,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
2134
2134
|
normalizedSearch: w,
|
|
2135
2135
|
callingCodeSearch: p
|
|
2136
2136
|
})), k = j.find((v) => v.value === u), C = S(k) ? [k, ...j.filter((v) => v.value !== u)] : j;
|
|
2137
|
-
return
|
|
2137
|
+
return Pe({
|
|
2138
2138
|
render: a,
|
|
2139
2139
|
ref: s,
|
|
2140
2140
|
props: {
|
|
@@ -2186,7 +2186,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
2186
2186
|
}),
|
|
2187
2187
|
/* @__PURE__ */ i(T.Empty, {
|
|
2188
2188
|
className: me.emptyStatus,
|
|
2189
|
-
children:
|
|
2189
|
+
children: Te(C) ? null : r
|
|
2190
2190
|
})
|
|
2191
2191
|
] })
|
|
2192
2192
|
}
|
|
@@ -2219,7 +2219,7 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
2219
2219
|
children: [e ?? /* @__PURE__ */ I(Z, { children: [/* @__PURE__ */ i("span", {
|
|
2220
2220
|
className: me.triggerFlag,
|
|
2221
2221
|
"aria-hidden": !0,
|
|
2222
|
-
children: l?.flag ?? /* @__PURE__ */ i(
|
|
2222
|
+
children: l?.flag ?? /* @__PURE__ */ i(zr, {})
|
|
2223
2223
|
}), /* @__PURE__ */ i(tt, {
|
|
2224
2224
|
className: me.chevron,
|
|
2225
2225
|
"aria-hidden": !0
|
|
@@ -2277,14 +2277,14 @@ var Da = "_root_1elk3_1", Oa = "_search_1elk3_29", Aa = "_viewport_1elk3_33", $a
|
|
|
2277
2277
|
inputGroup: $o,
|
|
2278
2278
|
searchIcon: Ho
|
|
2279
2279
|
}, Ti = ({ placeholder: e, actions: t, size: r = "md", hasFocusRing: n = !1, id: o, "aria-label": a, "aria-labelledby": s, ...c }) => {
|
|
2280
|
-
const l =
|
|
2280
|
+
const l = kt(), u = oe(), h = o ?? u;
|
|
2281
2281
|
return /* @__PURE__ */ I("div", {
|
|
2282
2282
|
className: Je.wrapper,
|
|
2283
2283
|
children: [/* @__PURE__ */ i(Gr, {
|
|
2284
2284
|
className: Je.inputGroup,
|
|
2285
2285
|
size: r,
|
|
2286
2286
|
hasFocusRing: n,
|
|
2287
|
-
startElement: /* @__PURE__ */ i(
|
|
2287
|
+
startElement: /* @__PURE__ */ i($r, {
|
|
2288
2288
|
className: Je.searchIcon,
|
|
2289
2289
|
size: l.icon.size.md,
|
|
2290
2290
|
"aria-hidden": !0
|
|
@@ -0,0 +1,379 @@
|
|
|
1
|
+
import { t as te } from "./theme-B1jMC8En.js";
|
|
2
|
+
import { t as m } from "./isDefined-fMi6eQ4r.js";
|
|
3
|
+
import { t as w } from "./isRenderableSlot-DT_depzM.js";
|
|
4
|
+
import { Aa as ae, Tt as ie } from "./TablerIcons-B6BhOlW_.js";
|
|
5
|
+
import { t as n } from "./mergeClassNames-ClFMR1v0.js";
|
|
6
|
+
import { r as le } from "./Button-wpJzTy9O.js";
|
|
7
|
+
import { t as D } from "./useProvidedTextDirection-Dk8LBQeF.js";
|
|
8
|
+
import { n as p, t as d } from "./ListItem.module-BV1vQ5hr.js";
|
|
9
|
+
import { n as G, r as ne } from "./Input-B9glruH9.js";
|
|
10
|
+
import { i as se } from "./Radio-Bg-zmy-1.js";
|
|
11
|
+
import { isFunction as k, isUndefined as ce } from "@sniptt/guards";
|
|
12
|
+
import { clsx as b } from "clsx";
|
|
13
|
+
import { Fragment as me, jsx as a, jsxs as A } from "react/jsx-runtime";
|
|
14
|
+
import { useRender as z } from "@base-ui/react/use-render";
|
|
15
|
+
import { forwardRef as y, useContext as ue, useLayoutEffect as x, useMemo as de, useRef as pe, useState as ve } from "react";
|
|
16
|
+
import { mergeProps as _e } from "@base-ui/react/merge-props";
|
|
17
|
+
import { Input as fe } from "@base-ui/react/input";
|
|
18
|
+
import { RadioGroup as he } from "@base-ui/react/radio-group";
|
|
19
|
+
import { Autocomplete as l } from "@base-ui/react/autocomplete";
|
|
20
|
+
import { Checkbox as B } from "@base-ui/react/checkbox";
|
|
21
|
+
import { Field as h } from "@base-ui/react/field";
|
|
22
|
+
import { Slider as N } from "@base-ui/react/slider";
|
|
23
|
+
var be = "_inputGroup_17li0_1", Ne = "_positioner_17li0_8", Ie = "_popup_17li0_12", Ce = "_arrow_17li0_31", ge = "_separator_17li0_72", Ae = "_list_17li0_86", Se = "_empty_17li0_93", I = {
|
|
24
|
+
inputGroup: be,
|
|
25
|
+
positioner: Ne,
|
|
26
|
+
popup: Ie,
|
|
27
|
+
arrow: Ce,
|
|
28
|
+
separator: ge,
|
|
29
|
+
list: Ae,
|
|
30
|
+
empty: Se
|
|
31
|
+
}, Fe = ({ className: e, ...r }) => /* @__PURE__ */ a(l.Arrow, {
|
|
32
|
+
...r,
|
|
33
|
+
className: n(I.arrow, e)
|
|
34
|
+
}), we = ({ className: e, ...r }) => /* @__PURE__ */ a(l.Empty, {
|
|
35
|
+
...r,
|
|
36
|
+
className: n(I.empty, e)
|
|
37
|
+
}), Te = ({ size: e, className: r, render: o, ...t }) => {
|
|
38
|
+
const i = ue(ne);
|
|
39
|
+
if (m(o)) return /* @__PURE__ */ a(l.Input, {
|
|
40
|
+
...t,
|
|
41
|
+
className: r,
|
|
42
|
+
render: o
|
|
43
|
+
});
|
|
44
|
+
const s = e ?? i?.size ?? "md";
|
|
45
|
+
return /* @__PURE__ */ a(l.Input, {
|
|
46
|
+
...t,
|
|
47
|
+
className: n(b(G.input, G[s]), r),
|
|
48
|
+
"data-grouped": m(i) || void 0
|
|
49
|
+
});
|
|
50
|
+
}, ke = ({ className: e, ...r }) => /* @__PURE__ */ a(l.InputGroup, {
|
|
51
|
+
...r,
|
|
52
|
+
className: n(I.inputGroup, e)
|
|
53
|
+
}), Re = ({ className: e, children: r, startIcon: o, endIcon: t, description: i, descriptionPlacement: s = "inline", ...c }) => /* @__PURE__ */ A(l.Item, {
|
|
54
|
+
...c,
|
|
55
|
+
className: n(d.root, e),
|
|
56
|
+
"data-color": "neutral",
|
|
57
|
+
children: [
|
|
58
|
+
w(o) && /* @__PURE__ */ a("div", {
|
|
59
|
+
className: d.startIcon,
|
|
60
|
+
"aria-hidden": !0,
|
|
61
|
+
children: o
|
|
62
|
+
}),
|
|
63
|
+
/* @__PURE__ */ A("div", {
|
|
64
|
+
className: d.label,
|
|
65
|
+
children: [/* @__PURE__ */ a("div", {
|
|
66
|
+
className: d.text,
|
|
67
|
+
children: r
|
|
68
|
+
}), w(i) && s === "inline" && /* @__PURE__ */ a("div", {
|
|
69
|
+
className: b(d.description, d.inlineDescription),
|
|
70
|
+
children: i
|
|
71
|
+
})]
|
|
72
|
+
}),
|
|
73
|
+
w(i) && s === "end" && /* @__PURE__ */ a("div", {
|
|
74
|
+
className: b(d.description, d.endDescription),
|
|
75
|
+
children: i
|
|
76
|
+
}),
|
|
77
|
+
w(t) && /* @__PURE__ */ a("div", {
|
|
78
|
+
className: d.endIcon,
|
|
79
|
+
"aria-hidden": !0,
|
|
80
|
+
children: t
|
|
81
|
+
})
|
|
82
|
+
]
|
|
83
|
+
}), Le = ({ className: e, ...r }) => /* @__PURE__ */ a(l.List, {
|
|
84
|
+
...r,
|
|
85
|
+
className: n(I.list, e)
|
|
86
|
+
}), ye = ({ width: e, style: r, className: o, ...t }) => /* @__PURE__ */ a(l.Popup, {
|
|
87
|
+
...t,
|
|
88
|
+
className: n(I.popup, o),
|
|
89
|
+
style: (i) => ({
|
|
90
|
+
width: e,
|
|
91
|
+
minInlineSize: m(e) ? 0 : void 0,
|
|
92
|
+
...k(r) ? r(i) : r
|
|
93
|
+
})
|
|
94
|
+
}), Ge = ({ container: e, ...r }) => {
|
|
95
|
+
const o = te(), t = D();
|
|
96
|
+
return /* @__PURE__ */ a(l.Portal, {
|
|
97
|
+
dir: t,
|
|
98
|
+
...r,
|
|
99
|
+
container: ce(e) ? o ?? void 0 : e
|
|
100
|
+
});
|
|
101
|
+
}, xe = ({ className: e, align: r = "start", sideOffset: o = 8, ...t }) => {
|
|
102
|
+
const i = D();
|
|
103
|
+
return /* @__PURE__ */ a(l.Positioner, {
|
|
104
|
+
dir: i,
|
|
105
|
+
align: r,
|
|
106
|
+
sideOffset: o,
|
|
107
|
+
...t,
|
|
108
|
+
className: n(I.positioner, e)
|
|
109
|
+
});
|
|
110
|
+
}, Pe = ({ className: e, ...r }) => /* @__PURE__ */ a(l.Separator, {
|
|
111
|
+
...r,
|
|
112
|
+
className: n(I.separator, e)
|
|
113
|
+
}), Ee = () => ({
|
|
114
|
+
Root: l.Root,
|
|
115
|
+
Value: l.Value,
|
|
116
|
+
Trigger: l.Trigger,
|
|
117
|
+
InputGroup: ke,
|
|
118
|
+
Input: Te,
|
|
119
|
+
Icon: l.Icon,
|
|
120
|
+
Clear: l.Clear,
|
|
121
|
+
Portal: Ge,
|
|
122
|
+
Backdrop: l.Backdrop,
|
|
123
|
+
Positioner: xe,
|
|
124
|
+
Popup: ye,
|
|
125
|
+
Arrow: Fe,
|
|
126
|
+
List: Le,
|
|
127
|
+
Status: l.Status,
|
|
128
|
+
Group: l.Group,
|
|
129
|
+
GroupLabel: l.GroupLabel,
|
|
130
|
+
Item: Re,
|
|
131
|
+
Row: l.Row,
|
|
132
|
+
Collection: l.Collection,
|
|
133
|
+
Empty: we,
|
|
134
|
+
Separator: Pe,
|
|
135
|
+
useFilter: l.useFilter,
|
|
136
|
+
useFilteredItems: l.useFilteredItems
|
|
137
|
+
}), $r = /* @__PURE__ */ Ee(), De = "_container_262rx_1", ze = { container: De }, Wr = ({ attached: e = !0, framed: r = !1, className: o, children: t, variant: i, size: s, color: c, render: v, ref: C, ..._ }) => {
|
|
138
|
+
const u = z({
|
|
139
|
+
render: v,
|
|
140
|
+
ref: C,
|
|
141
|
+
props: {
|
|
142
|
+
role: "group",
|
|
143
|
+
"data-attached": e || void 0,
|
|
144
|
+
"data-framed": r || void 0,
|
|
145
|
+
..._,
|
|
146
|
+
className: b(ze.container, o),
|
|
147
|
+
children: t
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
return /* @__PURE__ */ a(le.Provider, {
|
|
151
|
+
value: {
|
|
152
|
+
variant: i,
|
|
153
|
+
color: c,
|
|
154
|
+
size: s
|
|
155
|
+
},
|
|
156
|
+
children: u
|
|
157
|
+
});
|
|
158
|
+
}, V = ({ className: e, ...r }) => /* @__PURE__ */ a(B.Indicator, {
|
|
159
|
+
...r,
|
|
160
|
+
className: n(p.indicator, e)
|
|
161
|
+
}), $ = ({ size: e = "sm", variant: r = "solid", shape: o = "square", color: t = "accent", hoverable: i = !0, className: s, ...c }) => /* @__PURE__ */ a(B.Root, {
|
|
162
|
+
...c,
|
|
163
|
+
className: n(b(p.root, p[e], p[r], p[o], p[t], i && p.hoverable), s)
|
|
164
|
+
}), Be = ({ children: e, ...r }) => /* @__PURE__ */ A($, {
|
|
165
|
+
...r,
|
|
166
|
+
children: [/* @__PURE__ */ A(V, { children: [/* @__PURE__ */ a(ie, {
|
|
167
|
+
className: p.check,
|
|
168
|
+
"aria-hidden": !0
|
|
169
|
+
}), /* @__PURE__ */ a(ae, {
|
|
170
|
+
className: p.minus,
|
|
171
|
+
"aria-hidden": !0
|
|
172
|
+
})] }), e]
|
|
173
|
+
}), Or = Object.assign(Be, {
|
|
174
|
+
Root: $,
|
|
175
|
+
Indicator: V
|
|
176
|
+
}), Ve = "_description_yrj5x_1", $e = { description: Ve }, W = y(({ className: e, ...r }, o) => /* @__PURE__ */ a(h.Description, {
|
|
177
|
+
ref: o,
|
|
178
|
+
className: n($e.description, e),
|
|
179
|
+
...r
|
|
180
|
+
}));
|
|
181
|
+
W.displayName = "FieldDescription";
|
|
182
|
+
var We = "_error_179et_1", Oe = { error: We }, O = y(({ className: e, ...r }, o) => /* @__PURE__ */ a(h.Error, {
|
|
183
|
+
ref: o,
|
|
184
|
+
className: n(Oe.error, e),
|
|
185
|
+
...r
|
|
186
|
+
}));
|
|
187
|
+
O.displayName = "FieldError";
|
|
188
|
+
var je = "_label_ual6o_1", qe = { label: je }, j = y(({ className: e, ...r }, o) => /* @__PURE__ */ a(h.Label, {
|
|
189
|
+
ref: o,
|
|
190
|
+
className: n(qe.label, e),
|
|
191
|
+
...r
|
|
192
|
+
}));
|
|
193
|
+
j.displayName = "FieldLabel";
|
|
194
|
+
var jr = {
|
|
195
|
+
Root: h.Root,
|
|
196
|
+
Item: h.Item,
|
|
197
|
+
Label: j,
|
|
198
|
+
Control: h.Control,
|
|
199
|
+
Description: W,
|
|
200
|
+
Error: O,
|
|
201
|
+
Validity: h.Validity
|
|
202
|
+
}, He = "_root_1qhv2_1", Me = { root: He }, Ue = 148, qr = ({ className: e, orientation: r = "vertical", layout: o = "list", minColumnWidth: t = Ue, style: i, ...s }) => /* @__PURE__ */ a(he, {
|
|
203
|
+
...s,
|
|
204
|
+
className: n(Me.root, e),
|
|
205
|
+
"data-orientation": r,
|
|
206
|
+
"data-layout": o,
|
|
207
|
+
style: (c) => ({
|
|
208
|
+
"--tw-radio-group-min-column-width": `${t}px`,
|
|
209
|
+
...k(i) ? i(c) : i
|
|
210
|
+
})
|
|
211
|
+
}), Je = "_root_1mh0w_1", Ke = "_accent_1mh0w_16", Qe = "_success_1mh0w_20", Xe = "_control_1mh0w_24", Ye = "_track_1mh0w_42", Ze = "_indicator_1mh0w_55", er = "_thumb_1mh0w_66", rr = "_label_1mh0w_80", or = "_value_1mh0w_81", f = {
|
|
212
|
+
root: Je,
|
|
213
|
+
accent: Ke,
|
|
214
|
+
success: Qe,
|
|
215
|
+
control: Xe,
|
|
216
|
+
track: Ye,
|
|
217
|
+
indicator: Ze,
|
|
218
|
+
thumb: er,
|
|
219
|
+
label: rr,
|
|
220
|
+
value: or
|
|
221
|
+
}, tr = ({ className: e, color: r = "accent", thumbAlignment: o = "edge", ...t }) => /* @__PURE__ */ a(N.Root, {
|
|
222
|
+
...t,
|
|
223
|
+
thumbAlignment: o,
|
|
224
|
+
className: n(b(f.root, f[r]), e)
|
|
225
|
+
}), ar = ({ className: e, ...r }) => /* @__PURE__ */ a(N.Control, {
|
|
226
|
+
...r,
|
|
227
|
+
className: n(f.control, e)
|
|
228
|
+
}), ir = ({ className: e, ...r }) => /* @__PURE__ */ a(N.Track, {
|
|
229
|
+
...r,
|
|
230
|
+
className: n(f.track, e)
|
|
231
|
+
}), lr = ({ className: e, ...r }) => /* @__PURE__ */ a(N.Indicator, {
|
|
232
|
+
...r,
|
|
233
|
+
className: n(f.indicator, e)
|
|
234
|
+
}), nr = ({ className: e, ...r }) => /* @__PURE__ */ a(N.Thumb, {
|
|
235
|
+
...r,
|
|
236
|
+
className: n(f.thumb, e)
|
|
237
|
+
}), sr = ({ className: e, ...r }) => /* @__PURE__ */ a(N.Label, {
|
|
238
|
+
...r,
|
|
239
|
+
className: n(f.label, e)
|
|
240
|
+
}), cr = ({ className: e, ...r }) => /* @__PURE__ */ a(N.Value, {
|
|
241
|
+
...r,
|
|
242
|
+
className: n(f.value, e)
|
|
243
|
+
}), Hr = {
|
|
244
|
+
Root: tr,
|
|
245
|
+
Control: ar,
|
|
246
|
+
Track: ir,
|
|
247
|
+
Indicator: lr,
|
|
248
|
+
Thumb: nr,
|
|
249
|
+
Label: sr,
|
|
250
|
+
Value: cr
|
|
251
|
+
}, mr = ({ controlProps: e, nativeProps: r, state: o, render: t }) => {
|
|
252
|
+
const { ref: i, ...s } = e, { ref: c, ...v } = r;
|
|
253
|
+
return z({
|
|
254
|
+
defaultTagName: "textarea",
|
|
255
|
+
render: t,
|
|
256
|
+
state: { ...o },
|
|
257
|
+
ref: [i ?? null, c ?? null],
|
|
258
|
+
props: _e(s, v)
|
|
259
|
+
});
|
|
260
|
+
}, ur = (e) => m(e) ? se(e) : "", T = (e) => {
|
|
261
|
+
e.style.blockSize = "auto";
|
|
262
|
+
const r = e.offsetHeight - e.clientHeight;
|
|
263
|
+
e.style.blockSize = `${e.scrollHeight + r}px`;
|
|
264
|
+
}, dr = (e) => {
|
|
265
|
+
if (!m(globalThis.ResizeObserver)) return;
|
|
266
|
+
let r, o = e.clientWidth;
|
|
267
|
+
const t = new ResizeObserver(() => {
|
|
268
|
+
const i = e.clientWidth;
|
|
269
|
+
i !== o && (o = i, m(r) && cancelAnimationFrame(r), r = requestAnimationFrame(() => {
|
|
270
|
+
r = void 0, T(e);
|
|
271
|
+
}));
|
|
272
|
+
});
|
|
273
|
+
return t.observe(e), () => {
|
|
274
|
+
t.disconnect(), m(r) && cancelAnimationFrame(r);
|
|
275
|
+
};
|
|
276
|
+
}, pr = ({ textarea: e, autoResize: r, value: o, maxRows: t, rows: i, size: s, variant: c, consumerBlockSize: v, form: C }) => {
|
|
277
|
+
const _ = pe(!1);
|
|
278
|
+
return x(() => {
|
|
279
|
+
if (!m(e)) return;
|
|
280
|
+
const u = _.current;
|
|
281
|
+
if (_.current = r ?? !1, r) {
|
|
282
|
+
T(e);
|
|
283
|
+
return;
|
|
284
|
+
}
|
|
285
|
+
u && (e.style.blockSize = ur(v));
|
|
286
|
+
}, [
|
|
287
|
+
e,
|
|
288
|
+
r,
|
|
289
|
+
o,
|
|
290
|
+
t,
|
|
291
|
+
i,
|
|
292
|
+
s,
|
|
293
|
+
c,
|
|
294
|
+
v
|
|
295
|
+
]), x(() => {
|
|
296
|
+
if (!r || !m(e)) return;
|
|
297
|
+
let u = !0;
|
|
298
|
+
const g = (L) => {
|
|
299
|
+
requestAnimationFrame(() => {
|
|
300
|
+
u && !L.defaultPrevented && T(e);
|
|
301
|
+
});
|
|
302
|
+
}, S = e.form, R = dr(e);
|
|
303
|
+
return S?.addEventListener("reset", g), () => {
|
|
304
|
+
u = !1, S?.removeEventListener("reset", g), R?.();
|
|
305
|
+
};
|
|
306
|
+
}, [
|
|
307
|
+
e,
|
|
308
|
+
r,
|
|
309
|
+
C
|
|
310
|
+
]), null;
|
|
311
|
+
}, P = (e, r) => {
|
|
312
|
+
if (m(e)) {
|
|
313
|
+
if (k(e)) return e(r);
|
|
314
|
+
e.current = r;
|
|
315
|
+
}
|
|
316
|
+
}, vr = (...e) => (r) => {
|
|
317
|
+
const o = e.map((t) => {
|
|
318
|
+
const i = P(t, r);
|
|
319
|
+
return k(i) ? i : () => P(t, null);
|
|
320
|
+
});
|
|
321
|
+
return () => {
|
|
322
|
+
for (const t of o) t();
|
|
323
|
+
};
|
|
324
|
+
}, _r = "_textarea_hz3iw_1", fr = "_sm_hz3iw_58", hr = "_md_hz3iw_62", E = {
|
|
325
|
+
textarea: _r,
|
|
326
|
+
sm: fr,
|
|
327
|
+
md: hr
|
|
328
|
+
}, Mr = ({ size: e = "md", variant: r = "default", autoResize: o = !1, maxRows: t, className: i, style: s, ref: c, render: v, onChange: C, value: _, rows: u, ...g }) => {
|
|
329
|
+
const [S, R] = ve(null), L = de(() => vr(c, R), [c]), q = m(_), H = s?.blockSize, M = (F) => {
|
|
330
|
+
o && !q && T(F.currentTarget), C?.(F);
|
|
331
|
+
}, U = m(t) ? {
|
|
332
|
+
...s,
|
|
333
|
+
"--tw-textarea-max-rows": t
|
|
334
|
+
} : s, { "aria-describedby": J, id: K, name: Q, disabled: X, autoFocus: Y, defaultValue: Z, onValueChange: ee, ...re } = g;
|
|
335
|
+
return /* @__PURE__ */ A(me, { children: [/* @__PURE__ */ a(fe, {
|
|
336
|
+
"aria-describedby": J,
|
|
337
|
+
id: K,
|
|
338
|
+
name: Q,
|
|
339
|
+
disabled: X,
|
|
340
|
+
autoFocus: Y,
|
|
341
|
+
defaultValue: Z,
|
|
342
|
+
onValueChange: ee,
|
|
343
|
+
render: (F, oe) => /* @__PURE__ */ a(mr, {
|
|
344
|
+
controlProps: F,
|
|
345
|
+
nativeProps: {
|
|
346
|
+
...re,
|
|
347
|
+
rows: u,
|
|
348
|
+
onChange: M,
|
|
349
|
+
ref: L
|
|
350
|
+
},
|
|
351
|
+
state: oe,
|
|
352
|
+
render: v
|
|
353
|
+
}),
|
|
354
|
+
value: _,
|
|
355
|
+
className: n(b(E.textarea, E[e]), i),
|
|
356
|
+
style: U,
|
|
357
|
+
"data-auto-resize": o || void 0,
|
|
358
|
+
"data-variant": r
|
|
359
|
+
}), /* @__PURE__ */ a(pr, {
|
|
360
|
+
textarea: S,
|
|
361
|
+
autoResize: o,
|
|
362
|
+
value: _,
|
|
363
|
+
maxRows: t,
|
|
364
|
+
rows: u,
|
|
365
|
+
size: e,
|
|
366
|
+
variant: r,
|
|
367
|
+
consumerBlockSize: H,
|
|
368
|
+
form: g.form
|
|
369
|
+
})] });
|
|
370
|
+
};
|
|
371
|
+
export {
|
|
372
|
+
Or as a,
|
|
373
|
+
jr as i,
|
|
374
|
+
Hr as n,
|
|
375
|
+
Wr as o,
|
|
376
|
+
qr as r,
|
|
377
|
+
$r as s,
|
|
378
|
+
Mr as t
|
|
379
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const re=require("./theme-CeIzO6UU.cjs"),d=require("./isDefined-DS2Q42p5.cjs"),S=require("./isRenderableSlot-Guryb6Nf.cjs"),i=require("./mergeClassNames-D4lshrT6.cjs"),te=require("./Button-CbJ3qEQ9.cjs"),D=require("./useProvidedTextDirection-PVaoQCLH.cjs"),n=require("./ListItem.module-Cw0dbXxo.cjs"),R=require("./Input-D0yWU3vB.cjs"),oe=require("./Radio-CjaEN7Bt.cjs");let j=require("@sniptt/guards"),x=require("clsx"),t=require("react/jsx-runtime"),P=require("@base-ui/react/use-render"),_=require("react"),ae=require("@base-ui/react/merge-props"),se=require("@base-ui/react/input"),le=require("@base-ui/react/radio-group"),l=require("@base-ui/react/autocomplete"),T=require("@base-ui/react/checkbox"),b=require("@base-ui/react/field"),h=require("@base-ui/react/slider"),L=require("@tabler/icons-react");var ie="_inputGroup_17li0_1",ue="_positioner_17li0_8",ne="_popup_17li0_12",ce="_arrow_17li0_31",de="_separator_17li0_72",me="_list_17li0_86",_e="_empty_17li0_93",C={inputGroup:ie,positioner:ue,popup:ne,arrow:ce,separator:de,list:me,empty:_e},pe=({className:e,...r})=>(0,t.jsx)(l.Autocomplete.Arrow,{...r,className:i.mergeClassNames(C.arrow,e)}),ve=({className:e,...r})=>(0,t.jsx)(l.Autocomplete.Empty,{...r,className:i.mergeClassNames(C.empty,e)}),fe=({size:e,className:r,render:o,...a})=>{const s=(0,_.useContext)(R.InputGroupContext);if(d.isDefined(o))return(0,t.jsx)(l.Autocomplete.Input,{...a,className:r,render:o});const u=e??s?.size??"md";return(0,t.jsx)(l.Autocomplete.Input,{...a,className:i.mergeClassNames((0,x.clsx)(R.Input_module_default.input,R.Input_module_default[u]),r),"data-grouped":d.isDefined(s)||void 0})},be=({className:e,...r})=>(0,t.jsx)(l.Autocomplete.InputGroup,{...r,className:i.mergeClassNames(C.inputGroup,e)}),xe=({className:e,children:r,startIcon:o,endIcon:a,description:s,descriptionPlacement:u="inline",...c})=>(0,t.jsxs)(l.Autocomplete.Item,{...c,className:i.mergeClassNames(n.ListItem_module_default.root,e),"data-color":"neutral",children:[S.isRenderableSlot(o)&&(0,t.jsx)("div",{className:n.ListItem_module_default.startIcon,"aria-hidden":!0,children:o}),(0,t.jsxs)("div",{className:n.ListItem_module_default.label,children:[(0,t.jsx)("div",{className:n.ListItem_module_default.text,children:r}),S.isRenderableSlot(s)&&u==="inline"&&(0,t.jsx)("div",{className:(0,x.clsx)(n.ListItem_module_default.description,n.ListItem_module_default.inlineDescription),children:s})]}),S.isRenderableSlot(s)&&u==="end"&&(0,t.jsx)("div",{className:(0,x.clsx)(n.ListItem_module_default.description,n.ListItem_module_default.endDescription),children:s}),S.isRenderableSlot(a)&&(0,t.jsx)("div",{className:n.ListItem_module_default.endIcon,"aria-hidden":!0,children:a})]}),he=({className:e,...r})=>(0,t.jsx)(l.Autocomplete.List,{...r,className:i.mergeClassNames(C.list,e)}),Ce=({width:e,style:r,className:o,...a})=>(0,t.jsx)(l.Autocomplete.Popup,{...a,className:i.mergeClassNames(C.popup,o),style:s=>({width:e,minInlineSize:d.isDefined(e)?0:void 0,...(0,j.isFunction)(r)?r(s):r})}),Ne=({container:e,...r})=>{const o=re.useThemeContainer(),a=D.useProvidedTextDirection();return(0,t.jsx)(l.Autocomplete.Portal,{dir:a,...r,container:(0,j.isUndefined)(e)?o??void 0:e})},ge=({className:e,align:r="start",sideOffset:o=8,...a})=>{const s=D.useProvidedTextDirection();return(0,t.jsx)(l.Autocomplete.Positioner,{dir:s,align:r,sideOffset:o,...a,className:i.mergeClassNames(C.positioner,e)})},je=({className:e,...r})=>(0,t.jsx)(l.Autocomplete.Separator,{...r,className:i.mergeClassNames(C.separator,e)}),Ae=()=>({Root:l.Autocomplete.Root,Value:l.Autocomplete.Value,Trigger:l.Autocomplete.Trigger,InputGroup:be,Input:fe,Icon:l.Autocomplete.Icon,Clear:l.Autocomplete.Clear,Portal:Ne,Backdrop:l.Autocomplete.Backdrop,Positioner:ge,Popup:Ce,Arrow:pe,List:he,Status:l.Autocomplete.Status,Group:l.Autocomplete.Group,GroupLabel:l.Autocomplete.GroupLabel,Item:xe,Row:l.Autocomplete.Row,Collection:l.Autocomplete.Collection,Empty:ve,Separator:je,useFilter:l.Autocomplete.useFilter,useFilteredItems:l.Autocomplete.useFilteredItems}),Ie=Ae(),Se="_container_262rx_1",qe={container:Se},Fe=({attached:e=!0,framed:r=!1,className:o,children:a,variant:s,size:u,color:c,render:p,ref:N,...v})=>{const m=(0,P.useRender)({render:p,ref:N,props:{role:"group","data-attached":e||void 0,"data-framed":r||void 0,...v,className:(0,x.clsx)(qe.container,o),children:a}});return(0,t.jsx)(te.ButtonGroupContext.Provider,{value:{variant:s,color:c,size:u},children:m})},G=({className:e,...r})=>(0,t.jsx)(T.Checkbox.Indicator,{...r,className:i.mergeClassNames(n.Checkbox_module_default.indicator,e)}),E=({size:e="sm",variant:r="solid",shape:o="square",color:a="accent",hoverable:s=!0,className:u,...c})=>(0,t.jsx)(T.Checkbox.Root,{...c,className:i.mergeClassNames((0,x.clsx)(n.Checkbox_module_default.root,n.Checkbox_module_default[e],n.Checkbox_module_default[r],n.Checkbox_module_default[o],n.Checkbox_module_default[a],s&&n.Checkbox_module_default.hoverable),u)}),ke=({children:e,...r})=>(0,t.jsxs)(E,{...r,children:[(0,t.jsxs)(G,{children:[(0,t.jsx)(L.IconCheck,{className:n.Checkbox_module_default.check,"aria-hidden":!0}),(0,t.jsx)(L.IconMinus,{className:n.Checkbox_module_default.minus,"aria-hidden":!0})]}),e]}),Re=Object.assign(ke,{Root:E,Indicator:G}),Le="_description_yrj5x_1",we={description:Le},O=(0,_.forwardRef)(({className:e,...r},o)=>(0,t.jsx)(b.Field.Description,{ref:o,className:i.mergeClassNames(we.description,e),...r}));O.displayName="FieldDescription";var ye="_error_179et_1",De={error:ye},z=(0,_.forwardRef)(({className:e,...r},o)=>(0,t.jsx)(b.Field.Error,{ref:o,className:i.mergeClassNames(De.error,e),...r}));z.displayName="FieldError";var Pe="_label_ual6o_1",Te={label:Pe},B=(0,_.forwardRef)(({className:e,...r},o)=>(0,t.jsx)(b.Field.Label,{ref:o,className:i.mergeClassNames(Te.label,e),...r}));B.displayName="FieldLabel";var Ge={Root:b.Field.Root,Item:b.Field.Item,Label:B,Control:b.Field.Control,Description:O,Error:z,Validity:b.Field.Validity},Ee="_root_1qhv2_1",Oe={root:Ee},ze=148,Be=({className:e,orientation:r="vertical",layout:o="list",minColumnWidth:a=ze,style:s,...u})=>(0,t.jsx)(le.RadioGroup,{...u,className:i.mergeClassNames(Oe.root,e),"data-orientation":r,"data-layout":o,style:c=>({"--tw-radio-group-min-column-width":`${a}px`,...(0,j.isFunction)(s)?s(c):s})}),Ve="_root_1mh0w_1",We="_accent_1mh0w_16",He="_success_1mh0w_20",Me="_control_1mh0w_24",$e="_track_1mh0w_42",Ue="_indicator_1mh0w_55",Je="_thumb_1mh0w_66",Ke="_label_1mh0w_80",Qe="_value_1mh0w_81",f={root:Ve,accent:We,success:He,control:Me,track:$e,indicator:Ue,thumb:Je,label:Ke,value:Qe},Xe=({className:e,color:r="accent",thumbAlignment:o="edge",...a})=>(0,t.jsx)(h.Slider.Root,{...a,thumbAlignment:o,className:i.mergeClassNames((0,x.clsx)(f.root,f[r]),e)}),Ye=({className:e,...r})=>(0,t.jsx)(h.Slider.Control,{...r,className:i.mergeClassNames(f.control,e)}),Ze=({className:e,...r})=>(0,t.jsx)(h.Slider.Track,{...r,className:i.mergeClassNames(f.track,e)}),er=({className:e,...r})=>(0,t.jsx)(h.Slider.Indicator,{...r,className:i.mergeClassNames(f.indicator,e)}),rr=({className:e,...r})=>(0,t.jsx)(h.Slider.Thumb,{...r,className:i.mergeClassNames(f.thumb,e)}),tr=({className:e,...r})=>(0,t.jsx)(h.Slider.Label,{...r,className:i.mergeClassNames(f.label,e)}),or=({className:e,...r})=>(0,t.jsx)(h.Slider.Value,{...r,className:i.mergeClassNames(f.value,e)}),ar={Root:Xe,Control:Ye,Track:Ze,Indicator:er,Thumb:rr,Label:tr,Value:or},sr=({controlProps:e,nativeProps:r,state:o,render:a})=>{const{ref:s,...u}=e,{ref:c,...p}=r;return(0,P.useRender)({defaultTagName:"textarea",render:a,state:{...o},ref:[s??null,c??null],props:(0,ae.mergeProps)(u,p)})},lr=e=>d.isDefined(e)?oe.formatCssLength(e):"",q=e=>{e.style.blockSize="auto";const r=e.offsetHeight-e.clientHeight;e.style.blockSize=`${e.scrollHeight+r}px`},ir=e=>{if(!d.isDefined(globalThis.ResizeObserver))return;let r,o=e.clientWidth;const a=new ResizeObserver(()=>{const s=e.clientWidth;s!==o&&(o=s,d.isDefined(r)&&cancelAnimationFrame(r),r=requestAnimationFrame(()=>{r=void 0,q(e)}))});return a.observe(e),()=>{a.disconnect(),d.isDefined(r)&&cancelAnimationFrame(r)}},ur=({textarea:e,autoResize:r,value:o,maxRows:a,rows:s,size:u,variant:c,consumerBlockSize:p,form:N})=>{const v=(0,_.useRef)(!1);return(0,_.useLayoutEffect)(()=>{if(!d.isDefined(e))return;const m=v.current;if(v.current=r??!1,r){q(e);return}m&&(e.style.blockSize=lr(p))},[e,r,o,a,s,u,c,p]),(0,_.useLayoutEffect)(()=>{if(!r||!d.isDefined(e))return;let m=!0;const g=k=>{requestAnimationFrame(()=>{m&&!k.defaultPrevented&&q(e)})},A=e.form,F=ir(e);return A?.addEventListener("reset",g),()=>{m=!1,A?.removeEventListener("reset",g),F?.()}},[e,r,N]),null},w=(e,r)=>{if(d.isDefined(e)){if((0,j.isFunction)(e))return e(r);e.current=r}},nr=(...e)=>r=>{const o=e.map(a=>{const s=w(a,r);return(0,j.isFunction)(s)?s:()=>w(a,null)});return()=>{for(const a of o)a()}},cr="_textarea_hz3iw_1",dr="_sm_hz3iw_58",mr="_md_hz3iw_62",y={textarea:cr,sm:dr,md:mr},_r=({size:e="md",variant:r="default",autoResize:o=!1,maxRows:a,className:s,style:u,ref:c,render:p,onChange:N,value:v,rows:m,...g})=>{const[A,F]=(0,_.useState)(null),k=(0,_.useMemo)(()=>nr(c,F),[c]),V=d.isDefined(v),W=u?.blockSize,H=I=>{o&&!V&&q(I.currentTarget),N?.(I)},M=d.isDefined(a)?{...u,"--tw-textarea-max-rows":a}:u,{"aria-describedby":$,id:U,name:J,disabled:K,autoFocus:Q,defaultValue:X,onValueChange:Y,...Z}=g;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(se.Input,{"aria-describedby":$,id:U,name:J,disabled:K,autoFocus:Q,defaultValue:X,onValueChange:Y,render:(I,ee)=>(0,t.jsx)(sr,{controlProps:I,nativeProps:{...Z,rows:m,onChange:H,ref:k},state:ee,render:p}),value:v,className:i.mergeClassNames((0,x.clsx)(y.textarea,y[e]),s),style:M,"data-auto-resize":o||void 0,"data-variant":r}),(0,t.jsx)(ur,{textarea:A,autoResize:o,value:v,maxRows:a,rows:m,size:e,variant:r,consumerBlockSize:W,form:g.form})]})};Object.defineProperty(exports,"Autocomplete",{enumerable:!0,get:function(){return Ie}});Object.defineProperty(exports,"ButtonGroup",{enumerable:!0,get:function(){return Fe}});Object.defineProperty(exports,"Checkbox",{enumerable:!0,get:function(){return Re}});Object.defineProperty(exports,"Field",{enumerable:!0,get:function(){return Ge}});Object.defineProperty(exports,"RadioGroup",{enumerable:!0,get:function(){return Be}});Object.defineProperty(exports,"Slider",{enumerable:!0,get:function(){return ar}});Object.defineProperty(exports,"Textarea",{enumerable:!0,get:function(){return _r}});
|