twenty-ui 2.52.0 → 2.53.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AllIcons-fCCVOqoJ.js → AllIcons-B9FfQJ70.js} +1 -1
- package/dist/{Dropdown-D3LPyrQI.js → Dropdown-COpO_G9D.js} +51 -50
- package/dist/Dropdown-DaSktKdb.cjs +1 -0
- package/dist/{ListItem-g1B--M70.cjs → ListItem-Br5oDPc-.cjs} +1 -1
- package/dist/{ListItem-DR7Xh2WV.js → ListItem-txrdGXhb.js} +2 -2
- package/dist/{OverflowingTextWithTooltip-Cky5WlIk.js → OverflowingTextWithTooltip-CAQ-5aUp.js} +34 -33
- package/dist/OverflowingTextWithTooltip-CuWHF8_e.cjs +1 -0
- package/dist/{ProgressBar-BO0MkswY.js → ProgressBar-CPm791xc.js} +11 -11
- package/dist/Radio-BdbEXBOH.cjs +1 -0
- package/dist/Radio-D1PpZdqz.js +176 -0
- package/dist/TablerIcons-B6BhOlW_.js +463 -0
- package/dist/components/data-display.mjs +1 -1
- package/dist/components/feedback.cjs +1 -1
- package/dist/components/feedback.mjs +1 -1
- package/dist/components/input/FormFieldRow/FormFieldRow.d.ts +1 -1
- package/dist/components/input/FormFieldRow/types/FormFieldRowProps.d.ts +1 -0
- 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 +7 -7
- package/dist/{data-display-B7beM2yK.js → data-display-BhQyFKeZ.js} +1 -1
- package/dist/{data-display-C3Q_8G-N.cjs → data-display-CZEwUZlM.cjs} +1 -1
- package/dist/{data-display-CHKKTmH_.js → data-display-DVEhI2Rt.js} +89 -89
- package/dist/{feedback-DHATp8in.js → feedback-B3Qc_Igx.js} +65 -65
- package/dist/{feedback-3S9S-Xi9.cjs → feedback-BvCwRZad.cjs} +1 -1
- package/dist/icon/components/TablerIcons.d.ts +1 -1
- package/dist/icon/index.d.ts +1 -1
- package/dist/{icon-C3fz8p3W.js → icon-BlUO7C4w.js} +2 -2
- package/dist/icon.cjs +1 -1
- package/dist/icon.mjs +491 -490
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +639 -638
- package/dist/input-B8_4jnPT.cjs +1 -0
- package/dist/{input-jkwxjdtI.js → input-Btg-WsT6.js} +121 -120
- package/dist/{input-BLU0vrJM.js → input-BwQqV8Wf.js} +538 -536
- package/dist/input-CEiXoyRz.cjs +1 -0
- package/dist/{layout-4nLOjbJA.js → layout-4p7UQD7l.js} +29 -28
- package/dist/{layout-DEoY3Qd0.cjs → layout-DHW99Ejj.cjs} +1 -1
- package/dist/{navigation-CSSOuhFm.cjs → navigation-CP1g7ng9.cjs} +1 -1
- package/dist/{navigation-iP54gZTV.js → navigation-DQe6WaUF.js} +4 -4
- package/dist/primitives/data-display.cjs +1 -1
- package/dist/primitives/data-display.mjs +1 -1
- package/dist/primitives/feedback.mjs +1 -1
- package/dist/primitives/input.cjs +1 -1
- package/dist/primitives/input.mjs +4 -4
- package/dist/primitives/navigation.cjs +1 -1
- package/dist/primitives/navigation.mjs +1 -1
- package/dist/primitives/typography.cjs +1 -1
- package/dist/primitives/typography.mjs +2 -2
- package/dist/primitives.cjs +1 -1
- package/dist/primitives.mjs +7 -7
- package/dist/{settings-BmsLbd-g.js → settings-D3AWPKyH.js} +1 -1
- package/dist/{settings-DGwyi63i.cjs → settings-RYocb2Xg.cjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/{typography-sorTYmvG.js → typography-BisXuVpu.js} +1 -1
- package/dist/{typography-DeFnsH3k.cjs → typography-D7VnzZiR.cjs} +1 -1
- package/dist/utilities/internal/formatCssLength.d.ts +1 -0
- package/package.json +2 -2
- package/dist/Dropdown-h5-yIsU7.cjs +0 -1
- package/dist/OverflowingTextWithTooltip-Dmsmy-9g.cjs +0 -1
- package/dist/Radio-BK47Ig6J.cjs +0 -1
- package/dist/Radio-WuoC3hJ5.js +0 -175
- package/dist/TablerIcons-CqzhliLC.js +0 -462
- package/dist/input-BLUZOGq8.cjs +0 -1
- package/dist/input-DRIIJ4Zd.cjs +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
const R=require("./isDefined-DS2Q42p5.cjs"),i=require("./isRenderableSlot-Guryb6Nf.cjs"),D=require("./Shortcut-CbbRd1uM.cjs"),w=require("./OverflowingTextWithTooltip-
|
|
1
|
+
const R=require("./isDefined-DS2Q42p5.cjs"),i=require("./isRenderableSlot-Guryb6Nf.cjs"),D=require("./Shortcut-CbbRd1uM.cjs"),w=require("./OverflowingTextWithTooltip-CuWHF8_e.cjs"),e=require("./ListItem.module-DiUK6-0Z.cjs");let T=require("@base-ui/react/use-render"),y=require("@sniptt/guards"),r=require("clsx"),t=require("react/jsx-runtime"),o=require("@tabler/icons-react");var O=({checked:l,disabled:a})=>(0,t.jsx)("span",{"aria-hidden":!0,className:(0,r.clsx)(e.Checkbox_module_default.root,e.Checkbox_module_default.solid,e.Checkbox_module_default.sm,e.Checkbox_module_default.square,e.Checkbox_module_default.accent),"data-checked":l||void 0,"data-disabled":a||void 0,children:l&&(0,t.jsx)("span",{className:e.Checkbox_module_default.indicator,children:(0,t.jsx)(o.IconCheck,{"aria-hidden":!0})})}),W=({color:l="neutral",selected:a=!1,selectionAppearance:I="default",active:j=!1,focused:p=!1,disabled:c=!1,indicator:d="none",startIcon:_,endIcon:m,description:u,descriptionPlacement:s="inline",actions:h,actionsVisibility:L="hover",actionsPlacement:q="auto",shortcut:x,shortcutJoinLabel:k,hasSubmenu:N=!1,className:C,children:n,render:g,ref:v,...S})=>{const f=i.isRenderableSlot(u),b=i.isRenderableSlot(h)?(0,t.jsx)("span",{className:e.ListItem_module_default.actions,children:h}):null;return(0,T.useRender)({render:g,ref:v,state:{color:l,indicator:d,selected:a,active:j,highlighted:p,disabled:c},props:{...S,"data-actions-visibility":L,"data-actions-placement":q,"data-description-placement":s,"data-selection-appearance":I,className:(0,r.clsx)(e.ListItem_module_default.root,C),children:(0,t.jsxs)(t.Fragment,{children:[d==="checkbox"&&(0,t.jsx)(O,{checked:a,disabled:c}),i.isRenderableSlot(_)&&(0,t.jsx)("span",{className:e.ListItem_module_default.startIcon,children:_}),(0,t.jsxs)("span",{className:e.ListItem_module_default.label,children:[(0,t.jsx)("span",{className:e.ListItem_module_default.text,children:(0,y.isString)(n)?(0,t.jsx)(w.OverflowingTextWithTooltip,{text:n}):n}),f&&s!=="end"&&(0,t.jsx)("span",{className:(0,r.clsx)(e.ListItem_module_default.description,s==="inline"&&e.ListItem_module_default.inlineDescription),children:u})]}),f&&s==="end"&&(0,t.jsx)("span",{className:(0,r.clsx)(e.ListItem_module_default.description,e.ListItem_module_default.endDescription),children:u}),s!=="below"&&b,R.isDefined(x)&&(0,t.jsx)(D.Shortcut,{className:e.ListItem_module_default.hotkeys,shortcut:x,sequenceJoinLabel:k}),i.isRenderableSlot(m)&&(0,t.jsx)("span",{className:e.ListItem_module_default.endIcon,children:m}),d==="check"&&a&&(0,t.jsx)(o.IconCheck,{className:e.ListItem_module_default.checkIndicator,"aria-hidden":!0}),N&&(0,t.jsx)(o.IconChevronRight,{className:e.ListItem_module_default.submenuIcon,"aria-hidden":!0}),s==="below"&&b]})}})};Object.defineProperty(exports,"ListItem",{enumerable:!0,get:function(){return W}});
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { t as j } from "./isDefined-fMi6eQ4r.js";
|
|
2
2
|
import { t as n } from "./isRenderableSlot-DT_depzM.js";
|
|
3
|
-
import { Tt as k, kt as q } from "./TablerIcons-
|
|
3
|
+
import { Tt as k, kt as q } from "./TablerIcons-B6BhOlW_.js";
|
|
4
4
|
import { t as y } from "./Shortcut-YMhkp7f6.js";
|
|
5
|
-
import { t as F } from "./OverflowingTextWithTooltip-
|
|
5
|
+
import { t as F } from "./OverflowingTextWithTooltip-CAQ-5aUp.js";
|
|
6
6
|
import { n as t, t as e } from "./ListItem.module-B31VK9XZ.js";
|
|
7
7
|
import { useRender as J } from "@base-ui/react/use-render";
|
|
8
8
|
import { isString as O } from "@sniptt/guards";
|
package/dist/{OverflowingTextWithTooltip-Cky5WlIk.js → OverflowingTextWithTooltip-CAQ-5aUp.js}
RENAMED
|
@@ -7,84 +7,85 @@ import { createContext as J, memo as K, useContext as L, useRef as Q, useState a
|
|
|
7
7
|
import { jsx as r, jsxs as U } from "react/jsx-runtime";
|
|
8
8
|
import { mergeProps as V } from "@base-ui/react/merge-props";
|
|
9
9
|
import { useMergedRefs as X } from "@base-ui/utils/useMergedRefs";
|
|
10
|
-
var Y = "_typography_qms7s_1", Z = "_truncate_qms7s_44", $ = "_lineClamp_qms7s_50",
|
|
10
|
+
var Y = "_typography_qms7s_1", Z = "_truncate_qms7s_44", $ = "_lineClamp_qms7s_50", h = {
|
|
11
11
|
typography: Y,
|
|
12
12
|
truncate: Z,
|
|
13
13
|
lineClamp: $
|
|
14
|
-
}, ee = ({ render: t, size: i, weight:
|
|
14
|
+
}, ee = ({ render: t, size: i, weight: p, color: u, truncate: d, lineClamp: o, className: m, style: n, ref: a, ...v }) => {
|
|
15
15
|
const c = s(o) && Number.isInteger(o) && o > 0;
|
|
16
16
|
return G({
|
|
17
17
|
render: t,
|
|
18
18
|
ref: a,
|
|
19
19
|
props: {
|
|
20
|
-
...
|
|
20
|
+
...v,
|
|
21
21
|
"data-size": i,
|
|
22
|
-
"data-weight":
|
|
23
|
-
"data-color":
|
|
24
|
-
className: D(
|
|
22
|
+
"data-weight": p,
|
|
23
|
+
"data-color": u,
|
|
24
|
+
className: D(h.typography, d && h.truncate, c && h.lineClamp, m),
|
|
25
25
|
style: c ? {
|
|
26
26
|
...n,
|
|
27
27
|
"--text-line-clamp": o
|
|
28
28
|
} : n
|
|
29
29
|
}
|
|
30
30
|
});
|
|
31
|
-
}, te = (t) => s(t) && (t.scrollHeight > t.clientHeight || t.scrollWidth > t.clientWidth), oe = J("measure-on-hover"), re = "_overflowingMultilineText_1fi6s_1", ie = "_overflowingText_1fi6s_24", ne = "_multilineTooltip_1fi6s_45",
|
|
31
|
+
}, te = (t) => s(t) && (t.scrollHeight > t.clientHeight || t.scrollWidth > t.clientWidth), oe = J("measure-on-hover"), re = "_overflowingMultilineText_1fi6s_1", ie = "_overflowingText_1fi6s_24", ne = "_multilineTooltip_1fi6s_45", x = {
|
|
32
32
|
overflowingMultilineText: re,
|
|
33
33
|
overflowingText: ie,
|
|
34
34
|
multilineTooltip: ne
|
|
35
|
-
}, ve = K(function({ text: i, size:
|
|
36
|
-
const
|
|
37
|
-
const e = te(
|
|
35
|
+
}, ve = K(function({ text: i, size: p, weight: u, color: d, isTooltipMultiline: o, truncate: m, lineClamp: n, tooltipContent: a, tooltipDelay: v = 500, tooltipPlace: c = "bottom", alwaysShowTooltip: _ = !1, isFocusable: I = !1, render: k, ref: q, className: j, ...H }) {
|
|
36
|
+
const w = L(oe), O = w === "disabled", g = Q(null), [y, S] = W(!1), [z, C] = W(!1), B = X(g, q), M = () => {
|
|
37
|
+
const e = te(g.current);
|
|
38
38
|
return S(e), e;
|
|
39
|
-
},
|
|
39
|
+
}, b = (e) => {
|
|
40
40
|
if (!e) {
|
|
41
|
-
|
|
41
|
+
C(!1);
|
|
42
42
|
return;
|
|
43
43
|
}
|
|
44
|
-
|
|
44
|
+
const f = M();
|
|
45
|
+
C(f || _);
|
|
45
46
|
}, F = (e) => {
|
|
46
47
|
e.stopPropagation(), e.preventDefault();
|
|
47
|
-
},
|
|
48
|
-
...
|
|
48
|
+
}, T = N(a) ? a : N(i) ? i : null, P = s(n), R = /* @__PURE__ */ r(ee, {
|
|
49
|
+
...P ? { lineClamp: n } : { truncate: m ?? !0 },
|
|
49
50
|
dir: "auto",
|
|
50
|
-
"data-content-overflowing":
|
|
51
|
-
className: D(
|
|
51
|
+
"data-content-overflowing": y ? "" : void 0,
|
|
52
|
+
className: D(P ? x.overflowingMultilineText : x.overflowingText, j),
|
|
52
53
|
render: k,
|
|
53
54
|
ref: B,
|
|
54
55
|
...V({
|
|
55
56
|
tabIndex: I ? 0 : void 0,
|
|
56
|
-
...
|
|
57
|
-
onPointerEnter:
|
|
58
|
-
onFocus: () =>
|
|
57
|
+
...O ? {} : {
|
|
58
|
+
onPointerEnter: M,
|
|
59
|
+
onFocus: () => b(!0)
|
|
59
60
|
}
|
|
60
61
|
}, H),
|
|
61
|
-
size:
|
|
62
|
-
weight:
|
|
63
|
-
color:
|
|
62
|
+
size: p,
|
|
63
|
+
weight: u,
|
|
64
|
+
color: d,
|
|
64
65
|
children: i
|
|
65
66
|
});
|
|
66
|
-
return
|
|
67
|
-
open: z && s(
|
|
67
|
+
return O ? R : /* @__PURE__ */ U(l.Root, {
|
|
68
|
+
open: z && s(T),
|
|
68
69
|
onOpenChange: (...e) => {
|
|
69
|
-
const [
|
|
70
|
-
if (!
|
|
70
|
+
const [f, E] = e;
|
|
71
|
+
if (!f && E.reason === "trigger-hover" && g.current?.contains(document.activeElement)) {
|
|
71
72
|
E.cancel();
|
|
72
73
|
return;
|
|
73
74
|
}
|
|
74
|
-
|
|
75
|
+
b(f);
|
|
75
76
|
},
|
|
76
|
-
disabled: !s(
|
|
77
|
+
disabled: !s(T) || w === "measure-on-hover" && !y && !_,
|
|
77
78
|
children: [/* @__PURE__ */ r(l.Trigger, {
|
|
78
|
-
delay:
|
|
79
|
+
delay: v,
|
|
79
80
|
closeOnClick: !1,
|
|
80
|
-
render:
|
|
81
|
+
render: R
|
|
81
82
|
}), /* @__PURE__ */ r(l.Portal, { children: /* @__PURE__ */ r(l.Positioner, {
|
|
82
83
|
sideOffset: 5,
|
|
83
84
|
side: c,
|
|
84
85
|
children: /* @__PURE__ */ r(l.Popup, {
|
|
85
|
-
className: o ?
|
|
86
|
+
className: o ? x.multilineTooltip : void 0,
|
|
86
87
|
onClick: F,
|
|
87
|
-
children: /* @__PURE__ */ r(A, { children:
|
|
88
|
+
children: /* @__PURE__ */ r(A, { children: T })
|
|
88
89
|
})
|
|
89
90
|
}) })]
|
|
90
91
|
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a=require("./isDefined-DS2Q42p5.cjs"),o=require("./Tooltip-BXeUFCdb.cjs");let J=require("@base-ui/react/use-render"),R=require("@sniptt/guards"),E=require("clsx"),n=require("react"),r=require("react/jsx-runtime"),K=require("@base-ui/react/merge-props"),L=require("@base-ui/utils/useMergedRefs");var Q="_typography_qms7s_1",U="_truncate_qms7s_44",V="_lineClamp_qms7s_50",m={typography:Q,truncate:U,lineClamp:V},N=({render:t,size:l,weight:d,color:p,truncate:g,lineClamp:i,className:_,style:s,ref:u,...v})=>{const c=a.isDefined(i)&&Number.isInteger(i)&&i>0;return(0,J.useRender)({render:t,ref:u,props:{...v,"data-size":l,"data-weight":d,"data-color":p,className:(0,E.clsx)(m.typography,g&&m.truncate,c&&m.lineClamp,_),style:c?{...s,"--text-line-clamp":i}:s}})},X=t=>a.isDefined(t)&&(t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth),W=(0,n.createContext)("measure-on-hover"),Y="_overflowingMultilineText_1fi6s_1",Z="_overflowingText_1fi6s_24",$="_multilineTooltip_1fi6s_45",h={overflowingMultilineText:Y,overflowingText:Z,multilineTooltip:$},ee=(0,n.memo)(function({text:l,size:d,weight:p,color:g,isTooltipMultiline:i,truncate:_,lineClamp:s,tooltipContent:u,tooltipDelay:v=500,tooltipPlace:c="bottom",alwaysShowTooltip:O=!1,isFocusable:I=!1,render:S,ref:k,className:H,...z}){const w=(0,n.useContext)(W),b=w==="disabled",T=(0,n.useRef)(null),[q,B]=(0,n.useState)(!1),[F,y]=(0,n.useState)(!1),A=(0,L.useMergedRefs)(T,k),j=()=>{const e=X(T.current);return B(e),e},D=e=>{if(!e){y(!1);return}const f=j();y(f||O)},G=e=>{e.stopPropagation(),e.preventDefault()},x=(0,R.isNonEmptyString)(u)?u:(0,R.isNonEmptyString)(l)?l:null,M=a.isDefined(s),P=(0,r.jsx)(N,{...M?{lineClamp:s}:{truncate:_??!0},dir:"auto","data-content-overflowing":q?"":void 0,className:(0,E.clsx)(M?h.overflowingMultilineText:h.overflowingText,H),render:S,ref:A,...(0,K.mergeProps)({tabIndex:I?0:void 0,...b?{}:{onPointerEnter:j,onFocus:()=>D(!0)}},z),size:d,weight:p,color:g,children:l});return b?P:(0,r.jsxs)(o.Tooltip.Root,{open:F&&a.isDefined(x),onOpenChange:(...e)=>{const[f,C]=e;if(!f&&C.reason==="trigger-hover"&&T.current?.contains(document.activeElement)){C.cancel();return}D(f)},disabled:!a.isDefined(x)||w==="measure-on-hover"&&!q&&!O,children:[(0,r.jsx)(o.Tooltip.Trigger,{delay:v,closeOnClick:!1,render:P}),(0,r.jsx)(o.Tooltip.Portal,{children:(0,r.jsx)(o.Tooltip.Positioner,{sideOffset:5,side:c,children:(0,r.jsx)(o.Tooltip.Popup,{className:i?h.multilineTooltip:void 0,onClick:G,children:(0,r.jsx)(o.TooltipBody,{children:x})})})})]})});Object.defineProperty(exports,"OverflowingTextTooltipModeContext",{enumerable:!0,get:function(){return W}});Object.defineProperty(exports,"OverflowingTextWithTooltip",{enumerable:!0,get:function(){return ee}});Object.defineProperty(exports,"Text",{enumerable:!0,get:function(){return N}});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as u } from "./isDefined-fMi6eQ4r.js";
|
|
2
2
|
import { t as b } from "./isRenderableSlot-DT_depzM.js";
|
|
3
|
-
import {
|
|
3
|
+
import { Ec as B } from "./TablerIcons-B6BhOlW_.js";
|
|
4
4
|
import { t as N } from "./doNotTranslate-BSVT8Xyd.js";
|
|
5
5
|
import { t as j } from "./mergeClassNames-ClFMR1v0.js";
|
|
6
6
|
import { n as g, t as y } from "./getProgressIndicatorPercentage-ejfaM6XU.js";
|
|
@@ -9,24 +9,24 @@ import { useRender as k } from "@base-ui/react/use-render";
|
|
|
9
9
|
import { isFunction as I, isNonEmptyString as C } from "@sniptt/guards";
|
|
10
10
|
import { clsx as P } from "clsx";
|
|
11
11
|
import { Fragment as S, jsx as r, jsxs as h } from "react/jsx-runtime";
|
|
12
|
-
var
|
|
12
|
+
var w = {
|
|
13
13
|
neutral: "gray",
|
|
14
14
|
info: "blue",
|
|
15
15
|
success: "green",
|
|
16
16
|
warning: "orange",
|
|
17
17
|
error: "red"
|
|
18
|
-
},
|
|
18
|
+
}, x = (a) => /* @__PURE__ */ r(f, {
|
|
19
19
|
...a,
|
|
20
20
|
size: "sm",
|
|
21
21
|
variant: "outline",
|
|
22
22
|
color: "inherit"
|
|
23
|
-
}),
|
|
24
|
-
banner:
|
|
25
|
-
icon:
|
|
23
|
+
}), A = "_banner_8yjvn_1", E = "_icon_8yjvn_52", F = "_action_8yjvn_53", T = "_dismissible_8yjvn_59", z = "_closeButton_8yjvn_64", i = {
|
|
24
|
+
banner: A,
|
|
25
|
+
icon: E,
|
|
26
26
|
action: F,
|
|
27
|
-
dismissible:
|
|
28
|
-
closeButton:
|
|
29
|
-
}, O = ({ status: a = "info", variant: l = "solid", color: o =
|
|
27
|
+
dismissible: T,
|
|
28
|
+
closeButton: z
|
|
29
|
+
}, O = ({ status: a = "info", variant: l = "solid", color: o = w[a], icon: s, action: n, onDismiss: t, closeLabel: c = N("Close"), className: d, children: _, render: e, ref: m, ...v }) => k({
|
|
30
30
|
render: e,
|
|
31
31
|
ref: m,
|
|
32
32
|
state: {
|
|
@@ -59,7 +59,7 @@ var T = {
|
|
|
59
59
|
})
|
|
60
60
|
] })
|
|
61
61
|
}
|
|
62
|
-
}), Z = Object.assign(O, { Action:
|
|
62
|
+
}), Z = Object.assign(O, { Action: x }), R = "_bar_o09oi_1", K = "_track_o09oi_17", L = "_indicator_o09oi_23", M = "_progressBarIndeterminate_o09oi_1", p = {
|
|
63
63
|
bar: R,
|
|
64
64
|
track: K,
|
|
65
65
|
indicator: L,
|
|
@@ -94,6 +94,6 @@ var T = {
|
|
|
94
94
|
});
|
|
95
95
|
export {
|
|
96
96
|
Z as n,
|
|
97
|
-
|
|
97
|
+
w as r,
|
|
98
98
|
$ as t
|
|
99
99
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const R=require("./theme-BJRNJNPO.cjs"),F=require("./isDefined-DS2Q42p5.cjs"),o=require("./mergeClassNames-D4lshrT6.cjs"),j=require("./Button-Du8T-dOv.cjs"),S=require("./useProvidedTextDirection-PVaoQCLH.cjs"),d=require("./ListItem.module-DiUK6-0Z.cjs"),_=require("./Input-DS19vWhl.cjs");let G=require("@base-ui/react/use-render"),b=require("@sniptt/guards"),i=require("clsx"),t=require("react/jsx-runtime"),a=require("@base-ui/react/select"),c=require("@base-ui/react/number-field"),x=require("@base-ui/react/radio"),I=require("@tabler/icons-react");var A="_trigger_hijh9_1",D="_value_hijh9_12",T="_icon_hijh9_31",w="_positioner_hijh9_42",O="_popup_hijh9_46",y="_item_hijh9_71",B="_indicator_hijh9_75",k="_groupLabel_hijh9_81",$="_separator_hijh9_89",l={trigger:A,value:D,icon:T,positioner:w,popup:O,item:y,indicator:B,groupLabel:k,separator:$},E=({className:e,...r})=>(0,t.jsx)(a.Select.GroupLabel,{...r,className:o.mergeClassNames(l.groupLabel,e)}),U=({className:e,children:r=(0,t.jsx)(I.IconChevronDown,{}),...s})=>(0,t.jsx)(a.Select.Icon,{...s,className:o.mergeClassNames(l.icon,e),children:r}),V=({className:e,...r})=>(0,t.jsx)(a.Select.Item,{"data-color":"neutral","data-indicator":"check",...r,className:o.mergeClassNames((0,i.clsx)(d.ListItem_module_default.root,l.item),e)}),H=({className:e,children:r=(0,t.jsx)(I.IconCheck,{className:d.ListItem_module_default.checkIndicator}),...s})=>(0,t.jsx)(a.Select.ItemIndicator,{...s,className:o.mergeClassNames(l.indicator,e),children:r}),J=({className:e,...r})=>(0,t.jsx)(a.Select.ItemText,{...r,className:o.mergeClassNames((0,i.clsx)(d.ListItem_module_default.label,d.ListItem_module_default.text),e)}),K=({className:e,...r})=>(0,t.jsx)(a.Select.Popup,{...r,className:o.mergeClassNames(l.popup,e)}),M=({container:e,...r})=>{const s=R.useThemeContainer(),u=S.useProvidedTextDirection();return(0,t.jsx)(a.Select.Portal,{dir:u,...r,container:(0,b.isUndefined)(e)?s??void 0:e})},Q=({className:e,...r})=>{const s=S.useProvidedTextDirection();return(0,t.jsx)(a.Select.Positioner,{dir:s,...r,className:o.mergeClassNames(l.positioner,e)})},W=({className:e,...r})=>(0,t.jsx)(a.Select.Separator,{...r,className:o.mergeClassNames(l.separator,e)}),X=({size:e="md",className:r,...s})=>(0,t.jsx)(a.Select.Trigger,{...s,className:o.mergeClassNames((0,i.clsx)(_.Input_module_default.input,_.Input_module_default[e],l.trigger),r)}),Y=({className:e,...r})=>(0,t.jsx)(a.Select.Value,{...r,className:o.mergeClassNames(l.value,e)}),Z=()=>({Root:a.Select.Root,Label:a.Select.Label,Trigger:X,Value:Y,Icon:U,Portal:M,Backdrop:a.Select.Backdrop,Positioner:Q,Popup:K,List:a.Select.List,Item:V,ItemIndicator:H,ItemText:J,Arrow:a.Select.Arrow,ScrollDownArrow:a.Select.ScrollDownArrow,ScrollUpArrow:a.Select.ScrollUpArrow,Group:a.Select.Group,GroupLabel:E,Separator:W}),z=Z(),ee=e=>(0,b.isNumber)(e)?`${e}px`:e,re="_group_mv9ls_1",te="_button_mv9ls_7",N={group:re,button:te},ae=({className:e,...r})=>(0,t.jsx)(c.NumberField.Decrement,{...r,className:o.mergeClassNames((0,i.clsx)(j.Button_module_default.button,N.button),e)}),oe=({className:e,...r})=>(0,t.jsx)(c.NumberField.Group,{...r,className:o.mergeClassNames(N.group,e)}),se=({className:e,...r})=>(0,t.jsx)(c.NumberField.Increment,{...r,className:o.mergeClassNames((0,i.clsx)(j.Button_module_default.button,N.button),e)}),le=({className:e,...r})=>(0,t.jsx)(c.NumberField.Input,{...r,className:o.mergeClassNames(_.Input_module_default.input,e)}),ue={Root:c.NumberField.Root,Group:oe,Input:le,Increment:se,Decrement:ae,ScrubArea:c.NumberField.ScrubArea,ScrubAreaCursor:c.NumberField.ScrubAreaCursor},ce="_root_g72rh_1",ie="_sm_g72rh_30",ne="_md_g72rh_34",me="_startElement_g72rh_38",de="_endElement_g72rh_39",m={root:ce,sm:ie,md:ne,startElement:me,endElement:de},g=e=>F.isDefined(e)&&!(0,b.isBoolean)(e)&&e!=="",_e=({size:e="md",hasFocusRing:r=!0,startElement:s,endElement:u,className:p,children:v,render:C,ref:q,...P})=>{const L=(0,G.useRender)({render:C,ref:q,props:{...P,className:(0,i.clsx)(m.root,m[e],p),"data-focus-ring":r,children:(0,t.jsxs)(t.Fragment,{children:[g(s)&&(0,t.jsx)("span",{className:m.startElement,children:s}),v,g(u)&&(0,t.jsx)("span",{className:m.endElement,children:u})]})}});return(0,t.jsx)(_.InputGroupContext.Provider,{value:{size:e},children:L})},pe="_root_1pdpj_1",ve="_control_1pdpj_18",be="_sm_1pdpj_33",Ne="_md_1pdpj_38",ge="_indicator_1pdpj_49",je="_card_1pdpj_90",Se="_cardContent_1pdpj_111",n={root:pe,control:ve,sm:be,md:Ne,indicator:ge,card:je,cardContent:Se},h=x.Radio.Indicator,f=x.Radio.Root,xe=({children:e,className:r,size:s="sm",variant:u="default",render:p=u==="card"?(0,t.jsx)("div",{}):void 0,...v})=>(0,t.jsxs)(f,{...v,render:p,className:o.mergeClassNames((0,i.clsx)(n.root,n[s],u==="card"&&n.card),r),children:[(0,t.jsx)("span",{className:n.control,"aria-hidden":!0,children:(0,t.jsx)(h,{className:n.indicator})}),u==="card"?(0,t.jsx)("span",{className:n.cardContent,children:e}):e]}),Ie=Object.assign(xe,{Root:f,Indicator:h});Object.defineProperty(exports,"InputGroup",{enumerable:!0,get:function(){return _e}});Object.defineProperty(exports,"NumberField",{enumerable:!0,get:function(){return ue}});Object.defineProperty(exports,"Radio",{enumerable:!0,get:function(){return Ie}});Object.defineProperty(exports,"Select",{enumerable:!0,get:function(){return z}});Object.defineProperty(exports,"Select_module_default",{enumerable:!0,get:function(){return l}});Object.defineProperty(exports,"formatCssLength",{enumerable:!0,get:function(){return ee}});
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
import { t as A } from "./isDefined-fMi6eQ4r.js";
|
|
2
|
+
import { Dt as G, Tt as P } from "./TablerIcons-B6BhOlW_.js";
|
|
3
|
+
import { t as w } from "./theme-CuGIQBsJ.js";
|
|
4
|
+
import { t } from "./mergeClassNames-ClFMR1v0.js";
|
|
5
|
+
import { n as N } from "./Button-Dd8cNsn1.js";
|
|
6
|
+
import { t as b } from "./useProvidedTextDirection-Dk8LBQeF.js";
|
|
7
|
+
import { t as p } from "./ListItem.module-B31VK9XZ.js";
|
|
8
|
+
import { n as v, r as D } from "./Input-BKRR1xlO.js";
|
|
9
|
+
import { useRender as T } from "@base-ui/react/use-render";
|
|
10
|
+
import { isBoolean as F, isNumber as $, isUndefined as k } from "@sniptt/guards";
|
|
11
|
+
import { clsx as c } from "clsx";
|
|
12
|
+
import { Fragment as B, jsx as a, jsxs as g } from "react/jsx-runtime";
|
|
13
|
+
import { Select as o } from "@base-ui/react/select";
|
|
14
|
+
import { NumberField as s } from "@base-ui/react/number-field";
|
|
15
|
+
import { Radio as f } from "@base-ui/react/radio";
|
|
16
|
+
var E = "_trigger_hijh9_1", U = "_value_hijh9_12", V = "_icon_hijh9_31", O = "_positioner_hijh9_42", q = "_popup_hijh9_46", y = "_item_hijh9_71", H = "_indicator_hijh9_75", J = "_groupLabel_hijh9_81", K = "_separator_hijh9_89", m = {
|
|
17
|
+
trigger: E,
|
|
18
|
+
value: U,
|
|
19
|
+
icon: V,
|
|
20
|
+
positioner: O,
|
|
21
|
+
popup: q,
|
|
22
|
+
item: y,
|
|
23
|
+
indicator: H,
|
|
24
|
+
groupLabel: J,
|
|
25
|
+
separator: K
|
|
26
|
+
}, M = ({ className: r, ...e }) => /* @__PURE__ */ a(o.GroupLabel, {
|
|
27
|
+
...e,
|
|
28
|
+
className: t(m.groupLabel, r)
|
|
29
|
+
}), Q = ({ className: r, children: e = /* @__PURE__ */ a(G, {}), ...i }) => /* @__PURE__ */ a(o.Icon, {
|
|
30
|
+
...i,
|
|
31
|
+
className: t(m.icon, r),
|
|
32
|
+
children: e
|
|
33
|
+
}), W = ({ className: r, ...e }) => /* @__PURE__ */ a(o.Item, {
|
|
34
|
+
"data-color": "neutral",
|
|
35
|
+
"data-indicator": "check",
|
|
36
|
+
...e,
|
|
37
|
+
className: t(c(p.root, m.item), r)
|
|
38
|
+
}), X = ({ className: r, children: e = /* @__PURE__ */ a(P, { className: p.checkIndicator }), ...i }) => /* @__PURE__ */ a(o.ItemIndicator, {
|
|
39
|
+
...i,
|
|
40
|
+
className: t(m.indicator, r),
|
|
41
|
+
children: e
|
|
42
|
+
}), Y = ({ className: r, ...e }) => /* @__PURE__ */ a(o.ItemText, {
|
|
43
|
+
...e,
|
|
44
|
+
className: t(c(p.label, p.text), r)
|
|
45
|
+
}), Z = ({ className: r, ...e }) => /* @__PURE__ */ a(o.Popup, {
|
|
46
|
+
...e,
|
|
47
|
+
className: t(m.popup, r)
|
|
48
|
+
}), z = ({ container: r, ...e }) => {
|
|
49
|
+
const i = w(), n = b();
|
|
50
|
+
return /* @__PURE__ */ a(o.Portal, {
|
|
51
|
+
dir: n,
|
|
52
|
+
...e,
|
|
53
|
+
container: k(r) ? i ?? void 0 : r
|
|
54
|
+
});
|
|
55
|
+
}, rr = ({ className: r, ...e }) => {
|
|
56
|
+
const i = b();
|
|
57
|
+
return /* @__PURE__ */ a(o.Positioner, {
|
|
58
|
+
dir: i,
|
|
59
|
+
...e,
|
|
60
|
+
className: t(m.positioner, r)
|
|
61
|
+
});
|
|
62
|
+
}, er = ({ className: r, ...e }) => /* @__PURE__ */ a(o.Separator, {
|
|
63
|
+
...e,
|
|
64
|
+
className: t(m.separator, r)
|
|
65
|
+
}), ar = ({ size: r = "md", className: e, ...i }) => /* @__PURE__ */ a(o.Trigger, {
|
|
66
|
+
...i,
|
|
67
|
+
className: t(c(v.input, v[r], m.trigger), e)
|
|
68
|
+
}), or = ({ className: r, ...e }) => /* @__PURE__ */ a(o.Value, {
|
|
69
|
+
...e,
|
|
70
|
+
className: t(m.value, r)
|
|
71
|
+
}), tr = () => ({
|
|
72
|
+
Root: o.Root,
|
|
73
|
+
Label: o.Label,
|
|
74
|
+
Trigger: ar,
|
|
75
|
+
Value: or,
|
|
76
|
+
Icon: Q,
|
|
77
|
+
Portal: z,
|
|
78
|
+
Backdrop: o.Backdrop,
|
|
79
|
+
Positioner: rr,
|
|
80
|
+
Popup: Z,
|
|
81
|
+
List: o.List,
|
|
82
|
+
Item: W,
|
|
83
|
+
ItemIndicator: X,
|
|
84
|
+
ItemText: Y,
|
|
85
|
+
Arrow: o.Arrow,
|
|
86
|
+
ScrollDownArrow: o.ScrollDownArrow,
|
|
87
|
+
ScrollUpArrow: o.ScrollUpArrow,
|
|
88
|
+
Group: o.Group,
|
|
89
|
+
GroupLabel: M,
|
|
90
|
+
Separator: er
|
|
91
|
+
}), Ur = /* @__PURE__ */ tr(), Vr = (r) => $(r) ? `${r}px` : r, ir = "_group_mv9ls_1", mr = "_button_mv9ls_7", h = {
|
|
92
|
+
group: ir,
|
|
93
|
+
button: mr
|
|
94
|
+
}, nr = ({ className: r, ...e }) => /* @__PURE__ */ a(s.Decrement, {
|
|
95
|
+
...e,
|
|
96
|
+
className: t(c(N.button, h.button), r)
|
|
97
|
+
}), sr = ({ className: r, ...e }) => /* @__PURE__ */ a(s.Group, {
|
|
98
|
+
...e,
|
|
99
|
+
className: t(h.group, r)
|
|
100
|
+
}), cr = ({ className: r, ...e }) => /* @__PURE__ */ a(s.Increment, {
|
|
101
|
+
...e,
|
|
102
|
+
className: t(c(N.button, h.button), r)
|
|
103
|
+
}), lr = ({ className: r, ...e }) => /* @__PURE__ */ a(s.Input, {
|
|
104
|
+
...e,
|
|
105
|
+
className: t(v.input, r)
|
|
106
|
+
}), Or = {
|
|
107
|
+
Root: s.Root,
|
|
108
|
+
Group: sr,
|
|
109
|
+
Input: lr,
|
|
110
|
+
Increment: cr,
|
|
111
|
+
Decrement: nr,
|
|
112
|
+
ScrubArea: s.ScrubArea,
|
|
113
|
+
ScrubAreaCursor: s.ScrubAreaCursor
|
|
114
|
+
}, dr = "_root_g72rh_1", pr = "_sm_g72rh_30", ur = "_md_g72rh_34", _r = "_startElement_g72rh_38", vr = "_endElement_g72rh_39", d = {
|
|
115
|
+
root: dr,
|
|
116
|
+
sm: pr,
|
|
117
|
+
md: ur,
|
|
118
|
+
startElement: _r,
|
|
119
|
+
endElement: vr
|
|
120
|
+
}, I = (r) => A(r) && !F(r) && r !== "", qr = ({ size: r = "md", hasFocusRing: e = !0, startElement: i, endElement: n, className: u, children: _, render: R, ref: C, ...L }) => {
|
|
121
|
+
const x = T({
|
|
122
|
+
render: R,
|
|
123
|
+
ref: C,
|
|
124
|
+
props: {
|
|
125
|
+
...L,
|
|
126
|
+
className: c(d.root, d[r], u),
|
|
127
|
+
"data-focus-ring": e,
|
|
128
|
+
children: /* @__PURE__ */ g(B, { children: [
|
|
129
|
+
I(i) && /* @__PURE__ */ a("span", {
|
|
130
|
+
className: d.startElement,
|
|
131
|
+
children: i
|
|
132
|
+
}),
|
|
133
|
+
_,
|
|
134
|
+
I(n) && /* @__PURE__ */ a("span", {
|
|
135
|
+
className: d.endElement,
|
|
136
|
+
children: n
|
|
137
|
+
})
|
|
138
|
+
] })
|
|
139
|
+
}
|
|
140
|
+
});
|
|
141
|
+
return /* @__PURE__ */ a(D.Provider, {
|
|
142
|
+
value: { size: r },
|
|
143
|
+
children: x
|
|
144
|
+
});
|
|
145
|
+
}, hr = "_root_1pdpj_1", Ir = "_control_1pdpj_18", Nr = "_sm_1pdpj_33", br = "_md_1pdpj_38", gr = "_indicator_1pdpj_49", fr = "_card_1pdpj_90", Sr = "_cardContent_1pdpj_111", l = {
|
|
146
|
+
root: hr,
|
|
147
|
+
control: Ir,
|
|
148
|
+
sm: Nr,
|
|
149
|
+
md: br,
|
|
150
|
+
indicator: gr,
|
|
151
|
+
card: fr,
|
|
152
|
+
cardContent: Sr
|
|
153
|
+
}, S = f.Indicator, j = f.Root, jr = ({ children: r, className: e, size: i = "sm", variant: n = "default", render: u = n === "card" ? /* @__PURE__ */ a("div", {}) : void 0, ..._ }) => /* @__PURE__ */ g(j, {
|
|
154
|
+
..._,
|
|
155
|
+
render: u,
|
|
156
|
+
className: t(c(l.root, l[i], n === "card" && l.card), e),
|
|
157
|
+
children: [/* @__PURE__ */ a("span", {
|
|
158
|
+
className: l.control,
|
|
159
|
+
"aria-hidden": !0,
|
|
160
|
+
children: /* @__PURE__ */ a(S, { className: l.indicator })
|
|
161
|
+
}), n === "card" ? /* @__PURE__ */ a("span", {
|
|
162
|
+
className: l.cardContent,
|
|
163
|
+
children: r
|
|
164
|
+
}) : r]
|
|
165
|
+
}), yr = Object.assign(jr, {
|
|
166
|
+
Root: j,
|
|
167
|
+
Indicator: S
|
|
168
|
+
});
|
|
169
|
+
export {
|
|
170
|
+
Ur as a,
|
|
171
|
+
Vr as i,
|
|
172
|
+
qr as n,
|
|
173
|
+
m as o,
|
|
174
|
+
Or as r,
|
|
175
|
+
yr as t
|
|
176
|
+
};
|