@clasing/ui 2.6.0 → 2.7.1
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/badge-DK9gdPpu.cjs +91 -0
- package/dist/badge-aFyTFGVU.js +173 -0
- package/dist/button-2VesFn_C.js +256 -0
- package/dist/button-DWBp81pk.cjs +70 -0
- package/dist/card-DkYKwjsA.cjs +12 -0
- package/dist/{card-Cv2M4wv8.js → card-aAzRmGVH.js} +19 -5
- package/dist/chip-BlWb6w16.cjs +17 -0
- package/dist/chip-BmqvnZuy.js +116 -0
- package/dist/{clasing-icon-Bym32_-4.cjs → clasing-icon-CHt2Otn8.cjs} +1 -1
- package/dist/{clasing-icon-BIYMLc8o.js → clasing-icon-CJQQN554.js} +1 -1
- package/dist/command-DNjJookC.cjs +35 -0
- package/dist/command-peXi2dFX.js +209 -0
- package/dist/components/accordion.cjs.js +20 -1
- package/dist/components/accordion.es.js +38 -16
- package/dist/components/alert-dialog.cjs.js +17 -1
- package/dist/components/alert-dialog.es.js +23 -7
- package/dist/components/alert.cjs.js +6 -1
- package/dist/components/alert.d.ts +1 -2
- package/dist/components/alert.es.js +54 -50
- package/dist/components/avatar.cjs.js +1 -1
- package/dist/components/avatar.es.js +1 -1
- package/dist/components/badge.cjs.js +1 -1
- package/dist/components/badge.d.ts +1 -1
- package/dist/components/badge.es.js +1 -1
- package/dist/components/blocks/interactive-card.cjs.js +5 -1
- package/dist/components/blocks/interactive-card.es.js +60 -56
- package/dist/components/blocks/selectable-chips.cjs.js +1 -1
- package/dist/components/blocks/selectable-chips.d.ts +6 -6
- package/dist/components/blocks/selectable-chips.es.js +88 -55
- package/dist/components/breadcrumb.cjs.js +1 -1
- package/dist/components/breadcrumb.es.js +1 -1
- package/dist/components/button-group.cjs.js +1 -1
- package/dist/components/button-group.es.js +3 -3
- package/dist/components/button.cjs.js +1 -1
- package/dist/components/button.d.ts +8 -17
- package/dist/components/button.es.js +2 -4
- package/dist/components/calendar.cjs.js +73 -1
- package/dist/components/calendar.es.js +120 -42
- package/dist/components/card.cjs.js +1 -1
- package/dist/components/card.es.js +1 -1
- package/dist/components/chart.cjs.js +27 -2
- package/dist/components/chart.es.js +38 -7
- package/dist/components/checkbox.cjs.js +15 -1
- package/dist/components/checkbox.es.js +28 -14
- package/dist/components/chip.cjs.js +1 -1
- package/dist/components/chip.d.ts +3 -3
- package/dist/components/chip.es.js +1 -1
- package/dist/components/clasing-icon.cjs.js +1 -1
- package/dist/components/clasing-icon.es.js +1 -1
- package/dist/components/collapsible.cjs.js +10 -1
- package/dist/components/collapsible.es.js +17 -8
- package/dist/components/command.cjs.js +1 -1
- package/dist/components/command.es.js +1 -1
- package/dist/components/context-menu.cjs.js +70 -1
- package/dist/components/context-menu.es.js +95 -14
- package/dist/components/dialog.cjs.js +1 -1
- package/dist/components/dialog.es.js +1 -1
- package/dist/components/divider.cjs.js +1 -1
- package/dist/components/divider.es.js +1 -1
- package/dist/components/drawer.cjs.js +42 -1
- package/dist/components/drawer.es.js +63 -17
- package/dist/components/dropdown-menu.cjs.js +70 -1
- package/dist/components/dropdown-menu.es.js +133 -52
- package/dist/components/form.cjs.js +1 -1
- package/dist/components/form.es.js +21 -21
- package/dist/components/hover-card.cjs.js +13 -1
- package/dist/components/hover-card.es.js +14 -2
- package/dist/components/input-otp.cjs.js +19 -1
- package/dist/components/input-otp.es.js +49 -25
- package/dist/components/input.cjs.js +1 -1
- package/dist/components/input.es.js +1 -1
- package/dist/components/kbd.cjs.js +9 -1
- package/dist/components/kbd.es.js +11 -3
- package/dist/components/label.cjs.js +1 -1
- package/dist/components/label.es.js +1 -1
- package/dist/components/menubar.cjs.js +74 -1
- package/dist/components/menubar.es.js +121 -36
- package/dist/components/multi-select.cjs.js +22 -1
- package/dist/components/multi-select.es.js +54 -27
- package/dist/components/navigation-menu.cjs.js +70 -1
- package/dist/components/navigation-menu.es.js +85 -11
- package/dist/components/phone-input.cjs.js +21 -1
- package/dist/components/phone-input.es.js +267 -174
- package/dist/components/popover.cjs.js +1 -1
- package/dist/components/popover.es.js +1 -1
- package/dist/components/progress.cjs.js +1 -1
- package/dist/components/progress.es.js +3 -3
- package/dist/components/resizable.cjs.js +22 -1
- package/dist/components/resizable.d.ts +1 -1
- package/dist/components/resizable.es.js +52 -17
- package/dist/components/scroll-area.cjs.js +1 -1
- package/dist/components/scroll-area.es.js +1 -1
- package/dist/components/select.cjs.js +56 -1
- package/dist/components/select.d.ts +2 -1
- package/dist/components/select.es.js +86 -27
- package/dist/components/sheet.cjs.js +36 -1
- package/dist/components/sheet.es.js +75 -34
- package/dist/components/skeleton.cjs.js +1 -1
- package/dist/components/skeleton.es.js +1 -1
- package/dist/components/slider.cjs.js +23 -1
- package/dist/components/slider.es.js +46 -24
- package/dist/components/sonner.cjs.js +15 -1
- package/dist/components/sonner.es.js +67 -41
- package/dist/components/switch.cjs.js +19 -1
- package/dist/components/switch.es.js +29 -11
- package/dist/components/table.cjs.js +20 -1
- package/dist/components/table.es.js +56 -34
- package/dist/components/textarea.cjs.js +22 -1
- package/dist/components/textarea.es.js +46 -25
- package/dist/components/toggle-group.cjs.js +12 -1
- package/dist/components/toggle-group.es.js +15 -4
- package/dist/components/toggle.cjs.js +1 -1
- package/dist/components/toggle.es.js +1 -1
- package/dist/components/tooltip.cjs.js +1 -1
- package/dist/components/tooltip.es.js +1 -1
- package/dist/dialog-BUaX7IId.cjs +28 -0
- package/dist/{dialog-CH4VxKX4.js → dialog-CdmsVmRe.js} +41 -14
- package/dist/divider-D4EfIlt3.cjs +1 -0
- package/dist/{divider-BMxVoyPg.js → divider-DumyhJI_.js} +6 -6
- package/dist/entries/button.d.ts +2 -2
- package/dist/index-Bfismeyo.cjs +6 -0
- package/dist/{index-ECyCsPX0.cjs → index-BmhzhLcV.cjs} +1 -1
- package/dist/{index-DEha_UuN.js → index-CnqageB2.js} +1 -1
- package/dist/{index-BCEGphus.js → index-CwFDnnd3.js} +678 -519
- package/dist/input-kOA9xJIa.js +122 -0
- package/dist/input-u-OTHOPe.cjs +28 -0
- package/dist/label-BteX4MEt.js +27 -0
- package/dist/label-O3mSiGyx.cjs +7 -0
- package/dist/popover-A1-x5q-F.cjs +13 -0
- package/dist/{popover-BzUZg2od.js → popover-eQq2Is-I.js} +14 -2
- package/dist/{scroll-area-CxpVQq0v.js → scroll-area-CJy_EOqT.js} +10 -5
- package/dist/scroll-area-DFyIQG6Z.cjs +6 -0
- package/dist/toggle-BdWGPLza.cjs +21 -0
- package/dist/toggle-DuhnqdDT.js +63 -0
- package/dist/tooltip-BYeLeBei.js +74 -0
- package/dist/tooltip-BZWEHWmU.cjs +14 -0
- package/dist/ui.css +210 -210
- package/package.json +32 -28
- package/dist/badge-C29hQNIG.js +0 -84
- package/dist/badge-Da_xHgvC.cjs +0 -1
- package/dist/button-BIGg5o8m.js +0 -213
- package/dist/button-BsQuxg6u.cjs +0 -1
- package/dist/card-COFAc2zN.cjs +0 -1
- package/dist/chip-C_Uh7fe6.cjs +0 -1
- package/dist/chip-ZryYiiU1.js +0 -89
- package/dist/command-CGrOI2Z9.js +0 -169
- package/dist/command-CrtCQpi_.cjs +0 -1
- package/dist/dialog-DHZARK1o.cjs +0 -1
- package/dist/divider-BcIwJzm7.cjs +0 -1
- package/dist/index-9HRzXEQf.cjs +0 -6
- package/dist/input-BdGPpUZ8.js +0 -82
- package/dist/input-DDgYyRSP.cjs +0 -1
- package/dist/label-Bl6V6esj.js +0 -21
- package/dist/label-D3iN3bzS.cjs +0 -1
- package/dist/popover-Cj78cvz1.cjs +0 -1
- package/dist/scroll-area-D74XszlE.cjs +0 -1
- package/dist/toggle-99EXLQgX.js +0 -43
- package/dist/toggle-CtoQhQby.cjs +0 -1
- package/dist/tooltip-CHBabriJ.js +0 -56
- package/dist/tooltip-Dd6ylN0m.cjs +0 -1
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { j as e, c as l } from "./index-CwFDnnd3.js";
|
|
2
|
+
import { c as m } from "./index-CnqageB2.js";
|
|
3
|
+
import { forwardRef as c } from "react";
|
|
4
|
+
const g = m(
|
|
5
|
+
`
|
|
6
|
+
inline-flex items-center gap-1 rounded-full border px-3 py-1.5
|
|
7
|
+
transition-colors
|
|
8
|
+
focus-visible:ring-[1.5px] focus-visible:ring-ring-default
|
|
9
|
+
focus-visible:ring-offset-1 focus-visible:outline-hidden
|
|
10
|
+
`,
|
|
11
|
+
{
|
|
12
|
+
variants: {
|
|
13
|
+
variant: {
|
|
14
|
+
selected: [
|
|
15
|
+
`
|
|
16
|
+
border-info-foreground bg-info/20 font-semibold text-info-foreground
|
|
17
|
+
dark:text-info-foreground
|
|
18
|
+
`
|
|
19
|
+
],
|
|
20
|
+
unselected: [
|
|
21
|
+
`
|
|
22
|
+
border bg-background text-foreground
|
|
23
|
+
hover:bg-muted
|
|
24
|
+
`
|
|
25
|
+
],
|
|
26
|
+
error: [
|
|
27
|
+
`
|
|
28
|
+
border-destructive-foreground bg-destructive
|
|
29
|
+
text-destructive-foreground
|
|
30
|
+
`
|
|
31
|
+
]
|
|
32
|
+
},
|
|
33
|
+
size: {
|
|
34
|
+
sm: "paragraph-xs",
|
|
35
|
+
md: "paragraph-sm",
|
|
36
|
+
lg: "paragraph-md"
|
|
37
|
+
},
|
|
38
|
+
weight: {
|
|
39
|
+
regular: "font-regular",
|
|
40
|
+
medium: "font-medium",
|
|
41
|
+
semibold: "font-semibold"
|
|
42
|
+
},
|
|
43
|
+
disabled: {
|
|
44
|
+
false: null,
|
|
45
|
+
true: `
|
|
46
|
+
cursor-default border-muted-foreground bg-muted text-muted-foreground
|
|
47
|
+
`
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
defaultVariants: {
|
|
51
|
+
variant: "unselected",
|
|
52
|
+
size: "md",
|
|
53
|
+
weight: "regular"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
), b = c(
|
|
57
|
+
({
|
|
58
|
+
className: o,
|
|
59
|
+
variant: t,
|
|
60
|
+
size: i,
|
|
61
|
+
weight: s,
|
|
62
|
+
children: d,
|
|
63
|
+
notification: n,
|
|
64
|
+
onClick: a,
|
|
65
|
+
disabled: r,
|
|
66
|
+
...u
|
|
67
|
+
}, f) => a ? /* @__PURE__ */ e.jsxs(
|
|
68
|
+
"button",
|
|
69
|
+
{
|
|
70
|
+
ref: f,
|
|
71
|
+
className: l(
|
|
72
|
+
g({ variant: t, size: i, weight: s, className: o, disabled: r })
|
|
73
|
+
),
|
|
74
|
+
type: "button",
|
|
75
|
+
disabled: r ?? void 0,
|
|
76
|
+
onClick: a,
|
|
77
|
+
...u,
|
|
78
|
+
children: [
|
|
79
|
+
d,
|
|
80
|
+
n && /* @__PURE__ */ e.jsx(
|
|
81
|
+
"span",
|
|
82
|
+
{
|
|
83
|
+
"data-slot": "notification",
|
|
84
|
+
"aria-hidden": "true",
|
|
85
|
+
className: "size-1 min-w-1 rounded-full bg-destructive-foreground"
|
|
86
|
+
}
|
|
87
|
+
)
|
|
88
|
+
]
|
|
89
|
+
}
|
|
90
|
+
) : /* @__PURE__ */ e.jsxs(
|
|
91
|
+
"div",
|
|
92
|
+
{
|
|
93
|
+
ref: f,
|
|
94
|
+
className: l(
|
|
95
|
+
g({ variant: t, size: i, weight: s, className: o, disabled: r })
|
|
96
|
+
),
|
|
97
|
+
...u,
|
|
98
|
+
children: [
|
|
99
|
+
d,
|
|
100
|
+
n && /* @__PURE__ */ e.jsx(
|
|
101
|
+
"span",
|
|
102
|
+
{
|
|
103
|
+
"data-slot": "notification",
|
|
104
|
+
"aria-hidden": "true",
|
|
105
|
+
className: "size-1 min-w-1 rounded-full bg-destructive-foreground"
|
|
106
|
+
}
|
|
107
|
+
)
|
|
108
|
+
]
|
|
109
|
+
}
|
|
110
|
+
)
|
|
111
|
+
);
|
|
112
|
+
b.displayName = "Chip";
|
|
113
|
+
export {
|
|
114
|
+
b as C,
|
|
115
|
+
g as c
|
|
116
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("./index-
|
|
1
|
+
"use strict";const t=require("./index-Bfismeyo.cjs");function e({className:i,variant:l,color:x="currentColor",...L}){let s=[];return l==="default"?s=["#6CC422","#FF7BAA","#FF6F03","#0243F1","#00DBB7","#CF161C","#DD6DFF","#F6AF00"]:s=Array(8).fill(x),t.jsxRuntimeExports.jsxs("svg",{width:"48",height:"48",viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:t.cn(i),...L,children:[t.jsxRuntimeExports.jsx("path",{d:"M22.0316 19.2438L9.82361 6.99085C9.05365 6.2205 7.80528 6.2205 7.0353 6.99085L7.03328 6.99289C6.26332 7.76325 6.26332 9.01224 7.03328 9.78259L19.1481 21.9646L22.0316 24.1086V19.2438Z",fill:s[0]}),t.jsxRuntimeExports.jsx("path",{d:"M40.9576 38.2141L28.8136 25.9861L22.0315 24.1099L26.0506 28.8388L38.1672 41.0059C38.9372 41.7762 40.1856 41.7762 40.9556 41.0059L40.9576 41.0038C41.7275 40.2335 41.7275 38.9845 40.9576 38.2141Z",fill:s[1]}),t.jsxRuntimeExports.jsx("path",{d:"M28.7858 21.9952L40.9823 9.77469C41.7437 9.00615 41.7437 7.76007 40.9823 6.99153L40.9803 6.98949C40.2188 6.22095 38.9843 6.22095 38.2229 6.98949L25.9939 19.087L22.0315 24.1086L28.7858 21.9952Z",fill:s[2]}),t.jsxRuntimeExports.jsx("path",{d:"M19.1799 26.0002L7.03063 38.1476C6.2599 38.9162 6.26441 40.2079 7.03514 40.9765L7.03717 40.9785C7.8079 41.747 9.0575 41.747 9.82824 40.9785L22.0309 28.782V24.1099L19.1799 26.0002Z",fill:s[3]}),t.jsxRuntimeExports.jsx("path",{d:"M19.1588 21.961L1.94788 21.9965C0.872081 21.9965 0 22.8889 0 23.9898V23.9928C0 25.0937 0.872081 25.9862 1.94788 25.9862L19.1803 26.0002L22.0312 24.1099L19.1588 21.961Z",fill:s[4]}),t.jsxRuntimeExports.jsx("path",{d:"M28.6254 25.9858H46.0272C47.1167 25.9858 47.9999 25.0933 47.9999 23.9924V23.9895C47.9999 22.8886 47.1167 21.9961 46.0272 21.9961H28.7858L22.0315 24.1096L28.6254 25.9858Z",fill:s[5]}),t.jsxRuntimeExports.jsx("path",{d:"M22.0059 45.9811C22.0051 47.0967 22.896 48.0012 23.9948 48.0004C25.0914 47.9995 25.98 47.0973 25.9809 45.9841L26.0502 28.8388L22.0311 24.1099",fill:s[6]}),t.jsxRuntimeExports.jsx("path",{d:"M22.0319 24.109L25.9943 19.0874V1.84509C25.9943 0.7448 25.0315 0 23.9311 0H23.9282C22.8278 0 21.9263 0.891965 21.9263 1.99226",fill:s[7]})]})}exports.ClasingIcon=e;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";const e=require("./index-Bfismeyo.cjs"),o=require("cmdk"),a=require("./dialog-BUaX7IId.cjs"),c=require("@phosphor-icons/react");function r({className:n,...t}){return e.jsxRuntimeExports.jsx(o.Command,{"data-slot":"command",className:e.cn(`
|
|
2
|
+
flex size-full flex-col overflow-hidden rounded-md bg-popover
|
|
3
|
+
text-popover-foreground
|
|
4
|
+
`,n),...t})}function p({title:n="Command Palette",description:t="Search for a command to run...",children:m,className:s,showCloseButton:d=!0,...i}){return e.jsxRuntimeExports.jsxs(a.Dialog,{...i,children:[e.jsxRuntimeExports.jsxs(a.DialogHeader,{className:"sr-only",children:[e.jsxRuntimeExports.jsx(a.DialogTitle,{children:n}),e.jsxRuntimeExports.jsx(a.DialogDescription,{children:t})]}),e.jsxRuntimeExports.jsx(a.DialogContent,{className:e.cn("overflow-hidden p-0",s),showCloseButton:d,children:e.jsxRuntimeExports.jsx(r,{className:`\r
|
|
5
|
+
**:data-[slot=command-input-wrapper]:h-12\r
|
|
6
|
+
[&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0\r
|
|
7
|
+
[&_[cmdk-input-wrapper]_svg]:size-5\r
|
|
8
|
+
[&_[cmdk-item]_svg]:size-5\r
|
|
9
|
+
**:[[cmdk-group-heading]]:px-2\r
|
|
10
|
+
**:[[cmdk-group-heading]]:font-semibold\r
|
|
11
|
+
**:[[cmdk-group-heading]]:text-muted-foreground\r
|
|
12
|
+
**:[[cmdk-group]]:px-2\r
|
|
13
|
+
**:[[cmdk-input]]:h-12\r
|
|
14
|
+
**:[[cmdk-item]]:px-2 **:[[cmdk-item]]:py-3\r
|
|
15
|
+
`,children:m})})]})}function u({className:n,...t}){return e.jsxRuntimeExports.jsxs("div",{"data-slot":"command-input-wrapper",className:"flex h-9 items-center gap-2 border-b px-3",children:[e.jsxRuntimeExports.jsx(c.MagnifyingGlassIcon,{className:"size-4 shrink-0 opacity-50"}),e.jsxRuntimeExports.jsx(o.Command.Input,{"data-slot":"command-input",className:e.cn(`
|
|
16
|
+
flex h-10 w-full rounded-md bg-transparent py-3 paragraph-sm
|
|
17
|
+
outline-hidden
|
|
18
|
+
placeholder:text-muted-foreground
|
|
19
|
+
disabled:cursor-not-allowed disabled:opacity-50
|
|
20
|
+
`,n),...t})]})}function l({className:n,...t}){return e.jsxRuntimeExports.jsx(o.Command.List,{"data-slot":"command-list",className:e.cn("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",n),...t})}function x({...n}){return e.jsxRuntimeExports.jsx(o.Command.Empty,{"data-slot":"command-empty",className:"py-6 text-center paragraph-sm",...n})}function g({className:n,...t}){return e.jsxRuntimeExports.jsx(o.Command.Group,{"data-slot":"command-group",className:e.cn(`
|
|
21
|
+
overflow-hidden p-1 text-foreground
|
|
22
|
+
**:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5
|
|
23
|
+
**:[[cmdk-group-heading]]:paragraph-xs
|
|
24
|
+
**:[[cmdk-group-heading]]:font-semibold
|
|
25
|
+
**:[[cmdk-group-heading]]:text-muted-foreground
|
|
26
|
+
`,n),...t})}function h({className:n,...t}){return e.jsxRuntimeExports.jsx(o.Command.Separator,{"data-slot":"command-separator",className:e.cn("-mx-1 h-px bg-border",n),...t})}function f({className:n,...t}){return e.jsxRuntimeExports.jsx(o.Command.Item,{"data-slot":"command-item",className:e.cn(`
|
|
27
|
+
relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5
|
|
28
|
+
paragraph-sm outline-hidden select-none
|
|
29
|
+
data-[disabled=true]:pointer-events-none
|
|
30
|
+
data-[disabled=true]:opacity-50
|
|
31
|
+
data-[selected=true]:bg-accent
|
|
32
|
+
data-[selected=true]:text-accent-foreground
|
|
33
|
+
[&_svg]:pointer-events-none [&_svg]:shrink-0
|
|
34
|
+
[&_svg:not([class*='size-'])]:size-4
|
|
35
|
+
`,n),...t})}function j({className:n,...t}){return e.jsxRuntimeExports.jsx("span",{"data-slot":"command-shortcut",className:e.cn("ml-auto paragraph-xs tracking-widest text-muted-foreground",n),...t})}exports.Command=r;exports.CommandDialog=p;exports.CommandEmpty=x;exports.CommandGroup=g;exports.CommandInput=u;exports.CommandItem=f;exports.CommandList=l;exports.CommandSeparator=h;exports.CommandShortcut=j;
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
import { j as e, c as t } from "./index-CwFDnnd3.js";
|
|
2
|
+
import { Command as r } from "cmdk";
|
|
3
|
+
import { D as i, e as c, h as p, c as l, b as u } from "./dialog-CdmsVmRe.js";
|
|
4
|
+
import { MagnifyingGlassIcon as g } from "@phosphor-icons/react";
|
|
5
|
+
function x({
|
|
6
|
+
className: a,
|
|
7
|
+
...o
|
|
8
|
+
}) {
|
|
9
|
+
return /* @__PURE__ */ e.jsx(
|
|
10
|
+
r,
|
|
11
|
+
{
|
|
12
|
+
"data-slot": "command",
|
|
13
|
+
className: t(
|
|
14
|
+
`
|
|
15
|
+
flex size-full flex-col overflow-hidden rounded-md bg-popover
|
|
16
|
+
text-popover-foreground
|
|
17
|
+
`,
|
|
18
|
+
a
|
|
19
|
+
),
|
|
20
|
+
...o
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
function v({
|
|
25
|
+
title: a = "Command Palette",
|
|
26
|
+
description: o = "Search for a command to run...",
|
|
27
|
+
children: n,
|
|
28
|
+
className: s,
|
|
29
|
+
showCloseButton: d = !0,
|
|
30
|
+
...m
|
|
31
|
+
}) {
|
|
32
|
+
return /* @__PURE__ */ e.jsxs(i, { ...m, children: [
|
|
33
|
+
/* @__PURE__ */ e.jsxs(c, { className: "sr-only", children: [
|
|
34
|
+
/* @__PURE__ */ e.jsx(p, { children: a }),
|
|
35
|
+
/* @__PURE__ */ e.jsx(l, { children: o })
|
|
36
|
+
] }),
|
|
37
|
+
/* @__PURE__ */ e.jsx(
|
|
38
|
+
u,
|
|
39
|
+
{
|
|
40
|
+
className: t("overflow-hidden p-0", s),
|
|
41
|
+
showCloseButton: d,
|
|
42
|
+
children: /* @__PURE__ */ e.jsx(
|
|
43
|
+
x,
|
|
44
|
+
{
|
|
45
|
+
className: `\r
|
|
46
|
+
**:data-[slot=command-input-wrapper]:h-12\r
|
|
47
|
+
[&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0\r
|
|
48
|
+
[&_[cmdk-input-wrapper]_svg]:size-5\r
|
|
49
|
+
[&_[cmdk-item]_svg]:size-5\r
|
|
50
|
+
**:[[cmdk-group-heading]]:px-2\r
|
|
51
|
+
**:[[cmdk-group-heading]]:font-semibold\r
|
|
52
|
+
**:[[cmdk-group-heading]]:text-muted-foreground\r
|
|
53
|
+
**:[[cmdk-group]]:px-2\r
|
|
54
|
+
**:[[cmdk-input]]:h-12\r
|
|
55
|
+
**:[[cmdk-item]]:px-2 **:[[cmdk-item]]:py-3\r
|
|
56
|
+
`,
|
|
57
|
+
children: n
|
|
58
|
+
}
|
|
59
|
+
)
|
|
60
|
+
}
|
|
61
|
+
)
|
|
62
|
+
] });
|
|
63
|
+
}
|
|
64
|
+
function b({
|
|
65
|
+
className: a,
|
|
66
|
+
...o
|
|
67
|
+
}) {
|
|
68
|
+
return /* @__PURE__ */ e.jsxs(
|
|
69
|
+
"div",
|
|
70
|
+
{
|
|
71
|
+
"data-slot": "command-input-wrapper",
|
|
72
|
+
className: "flex h-9 items-center gap-2 border-b px-3",
|
|
73
|
+
children: [
|
|
74
|
+
/* @__PURE__ */ e.jsx(g, { className: "size-4 shrink-0 opacity-50" }),
|
|
75
|
+
/* @__PURE__ */ e.jsx(
|
|
76
|
+
r.Input,
|
|
77
|
+
{
|
|
78
|
+
"data-slot": "command-input",
|
|
79
|
+
className: t(
|
|
80
|
+
`
|
|
81
|
+
flex h-10 w-full rounded-md bg-transparent py-3 paragraph-sm
|
|
82
|
+
outline-hidden
|
|
83
|
+
placeholder:text-muted-foreground
|
|
84
|
+
disabled:cursor-not-allowed disabled:opacity-50
|
|
85
|
+
`,
|
|
86
|
+
a
|
|
87
|
+
),
|
|
88
|
+
...o
|
|
89
|
+
}
|
|
90
|
+
)
|
|
91
|
+
]
|
|
92
|
+
}
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
function y({
|
|
96
|
+
className: a,
|
|
97
|
+
...o
|
|
98
|
+
}) {
|
|
99
|
+
return /* @__PURE__ */ e.jsx(
|
|
100
|
+
r.List,
|
|
101
|
+
{
|
|
102
|
+
"data-slot": "command-list",
|
|
103
|
+
className: t(
|
|
104
|
+
"max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",
|
|
105
|
+
a
|
|
106
|
+
),
|
|
107
|
+
...o
|
|
108
|
+
}
|
|
109
|
+
);
|
|
110
|
+
}
|
|
111
|
+
function C({
|
|
112
|
+
...a
|
|
113
|
+
}) {
|
|
114
|
+
return /* @__PURE__ */ e.jsx(
|
|
115
|
+
r.Empty,
|
|
116
|
+
{
|
|
117
|
+
"data-slot": "command-empty",
|
|
118
|
+
className: "py-6 text-center paragraph-sm",
|
|
119
|
+
...a
|
|
120
|
+
}
|
|
121
|
+
);
|
|
122
|
+
}
|
|
123
|
+
function N({
|
|
124
|
+
className: a,
|
|
125
|
+
...o
|
|
126
|
+
}) {
|
|
127
|
+
return /* @__PURE__ */ e.jsx(
|
|
128
|
+
r.Group,
|
|
129
|
+
{
|
|
130
|
+
"data-slot": "command-group",
|
|
131
|
+
className: t(
|
|
132
|
+
`
|
|
133
|
+
overflow-hidden p-1 text-foreground
|
|
134
|
+
**:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5
|
|
135
|
+
**:[[cmdk-group-heading]]:paragraph-xs
|
|
136
|
+
**:[[cmdk-group-heading]]:font-semibold
|
|
137
|
+
**:[[cmdk-group-heading]]:text-muted-foreground
|
|
138
|
+
`,
|
|
139
|
+
a
|
|
140
|
+
),
|
|
141
|
+
...o
|
|
142
|
+
}
|
|
143
|
+
);
|
|
144
|
+
}
|
|
145
|
+
function w({
|
|
146
|
+
className: a,
|
|
147
|
+
...o
|
|
148
|
+
}) {
|
|
149
|
+
return /* @__PURE__ */ e.jsx(
|
|
150
|
+
r.Separator,
|
|
151
|
+
{
|
|
152
|
+
"data-slot": "command-separator",
|
|
153
|
+
className: t("-mx-1 h-px bg-border", a),
|
|
154
|
+
...o
|
|
155
|
+
}
|
|
156
|
+
);
|
|
157
|
+
}
|
|
158
|
+
function _({
|
|
159
|
+
className: a,
|
|
160
|
+
...o
|
|
161
|
+
}) {
|
|
162
|
+
return /* @__PURE__ */ e.jsx(
|
|
163
|
+
r.Item,
|
|
164
|
+
{
|
|
165
|
+
"data-slot": "command-item",
|
|
166
|
+
className: t(
|
|
167
|
+
`
|
|
168
|
+
relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5
|
|
169
|
+
paragraph-sm outline-hidden select-none
|
|
170
|
+
data-[disabled=true]:pointer-events-none
|
|
171
|
+
data-[disabled=true]:opacity-50
|
|
172
|
+
data-[selected=true]:bg-accent
|
|
173
|
+
data-[selected=true]:text-accent-foreground
|
|
174
|
+
[&_svg]:pointer-events-none [&_svg]:shrink-0
|
|
175
|
+
[&_svg:not([class*='size-'])]:size-4
|
|
176
|
+
`,
|
|
177
|
+
a
|
|
178
|
+
),
|
|
179
|
+
...o
|
|
180
|
+
}
|
|
181
|
+
);
|
|
182
|
+
}
|
|
183
|
+
function D({
|
|
184
|
+
className: a,
|
|
185
|
+
...o
|
|
186
|
+
}) {
|
|
187
|
+
return /* @__PURE__ */ e.jsx(
|
|
188
|
+
"span",
|
|
189
|
+
{
|
|
190
|
+
"data-slot": "command-shortcut",
|
|
191
|
+
className: t(
|
|
192
|
+
"ml-auto paragraph-xs tracking-widest text-muted-foreground",
|
|
193
|
+
a
|
|
194
|
+
),
|
|
195
|
+
...o
|
|
196
|
+
}
|
|
197
|
+
);
|
|
198
|
+
}
|
|
199
|
+
export {
|
|
200
|
+
x as C,
|
|
201
|
+
v as a,
|
|
202
|
+
C as b,
|
|
203
|
+
N as c,
|
|
204
|
+
b as d,
|
|
205
|
+
_ as e,
|
|
206
|
+
y as f,
|
|
207
|
+
w as g,
|
|
208
|
+
D as h
|
|
209
|
+
};
|
|
@@ -1 +1,20 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../index-Bfismeyo.cjs"),s=require("@radix-ui/react-accordion"),a=require("@phosphor-icons/react");function c(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:()=>e[r]})}}return n.default=e,Object.freeze(n)}const o=c(s);function d({...e}){return t.jsxRuntimeExports.jsx(o.Root,{"data-slot":"accordion",...e})}function u({className:e,...n}){return t.jsxRuntimeExports.jsx(o.Item,{"data-slot":"accordion-item",className:t.cn(`
|
|
2
|
+
border-b
|
|
3
|
+
last:border-b-0
|
|
4
|
+
`,e),...n})}function l({className:e,children:n,...r}){return t.jsxRuntimeExports.jsx(o.Header,{className:"flex",children:t.jsxRuntimeExports.jsxs(o.Trigger,{"data-slot":"accordion-trigger",className:t.cn(`
|
|
5
|
+
flex flex-1 items-start justify-between gap-4 rounded-md py-4
|
|
6
|
+
text-left paragraph-sm font-semibold text-foreground transition-all
|
|
7
|
+
outline-none
|
|
8
|
+
hover:underline
|
|
9
|
+
focus-visible:border-ring focus-visible:ring-[3px]
|
|
10
|
+
focus-visible:ring-ring/50
|
|
11
|
+
disabled:pointer-events-none disabled:opacity-50
|
|
12
|
+
[&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:translate-y-0.5
|
|
13
|
+
[&_svg]:text-muted-foreground [&_svg]:transition-transform
|
|
14
|
+
[&_svg]:duration-200
|
|
15
|
+
[&[data-state=open]>svg]:rotate-180
|
|
16
|
+
`,e),...r,children:[n,t.jsxRuntimeExports.jsx(a.CaretDownIcon,{})]})})}function g({className:e,children:n,...r}){return t.jsxRuntimeExports.jsx(o.Content,{"data-slot":"accordion-content",className:`\r
|
|
17
|
+
overflow-hidden paragraph-sm text-foreground\r
|
|
18
|
+
data-[state=closed]:animate-accordion-up\r
|
|
19
|
+
data-[state=open]:animate-accordion-down\r
|
|
20
|
+
`,...r,children:t.jsxRuntimeExports.jsx("div",{className:t.cn("pt-0 pb-4",e),children:n})})}exports.Accordion=d;exports.AccordionContent=g;exports.AccordionItem=u;exports.AccordionTrigger=l;
|
|
@@ -1,20 +1,26 @@
|
|
|
1
|
-
import { j as e, c as a } from "../index-
|
|
2
|
-
import * as
|
|
1
|
+
import { j as e, c as a } from "../index-CwFDnnd3.js";
|
|
2
|
+
import * as r from "@radix-ui/react-accordion";
|
|
3
3
|
import { CaretDownIcon as s } from "@phosphor-icons/react";
|
|
4
|
-
function
|
|
4
|
+
function c({
|
|
5
5
|
...t
|
|
6
6
|
}) {
|
|
7
|
-
return /* @__PURE__ */ e.jsx(
|
|
7
|
+
return /* @__PURE__ */ e.jsx(r.Root, { "data-slot": "accordion", ...t });
|
|
8
8
|
}
|
|
9
9
|
function l({
|
|
10
10
|
className: t,
|
|
11
11
|
...o
|
|
12
12
|
}) {
|
|
13
13
|
return /* @__PURE__ */ e.jsx(
|
|
14
|
-
|
|
14
|
+
r.Item,
|
|
15
15
|
{
|
|
16
16
|
"data-slot": "accordion-item",
|
|
17
|
-
className: a(
|
|
17
|
+
className: a(
|
|
18
|
+
`
|
|
19
|
+
border-b
|
|
20
|
+
last:border-b-0
|
|
21
|
+
`,
|
|
22
|
+
t
|
|
23
|
+
),
|
|
18
24
|
...o
|
|
19
25
|
}
|
|
20
26
|
);
|
|
@@ -22,17 +28,29 @@ function l({
|
|
|
22
28
|
function m({
|
|
23
29
|
className: t,
|
|
24
30
|
children: o,
|
|
25
|
-
...
|
|
31
|
+
...n
|
|
26
32
|
}) {
|
|
27
|
-
return /* @__PURE__ */ e.jsx(
|
|
28
|
-
|
|
33
|
+
return /* @__PURE__ */ e.jsx(r.Header, { className: "flex", children: /* @__PURE__ */ e.jsxs(
|
|
34
|
+
r.Trigger,
|
|
29
35
|
{
|
|
30
36
|
"data-slot": "accordion-trigger",
|
|
31
37
|
className: a(
|
|
32
|
-
|
|
38
|
+
`
|
|
39
|
+
flex flex-1 items-start justify-between gap-4 rounded-md py-4
|
|
40
|
+
text-left paragraph-sm font-semibold text-foreground transition-all
|
|
41
|
+
outline-none
|
|
42
|
+
hover:underline
|
|
43
|
+
focus-visible:border-ring focus-visible:ring-[3px]
|
|
44
|
+
focus-visible:ring-ring/50
|
|
45
|
+
disabled:pointer-events-none disabled:opacity-50
|
|
46
|
+
[&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:translate-y-0.5
|
|
47
|
+
[&_svg]:text-muted-foreground [&_svg]:transition-transform
|
|
48
|
+
[&_svg]:duration-200
|
|
49
|
+
[&[data-state=open]>svg]:rotate-180
|
|
50
|
+
`,
|
|
33
51
|
t
|
|
34
52
|
),
|
|
35
|
-
...
|
|
53
|
+
...n,
|
|
36
54
|
children: [
|
|
37
55
|
o,
|
|
38
56
|
/* @__PURE__ */ e.jsx(s, {})
|
|
@@ -43,20 +61,24 @@ function m({
|
|
|
43
61
|
function g({
|
|
44
62
|
className: t,
|
|
45
63
|
children: o,
|
|
46
|
-
...
|
|
64
|
+
...n
|
|
47
65
|
}) {
|
|
48
66
|
return /* @__PURE__ */ e.jsx(
|
|
49
|
-
|
|
67
|
+
r.Content,
|
|
50
68
|
{
|
|
51
69
|
"data-slot": "accordion-content",
|
|
52
|
-
className:
|
|
53
|
-
|
|
70
|
+
className: `\r
|
|
71
|
+
overflow-hidden paragraph-sm text-foreground\r
|
|
72
|
+
data-[state=closed]:animate-accordion-up\r
|
|
73
|
+
data-[state=open]:animate-accordion-down\r
|
|
74
|
+
`,
|
|
75
|
+
...n,
|
|
54
76
|
children: /* @__PURE__ */ e.jsx("div", { className: a("pt-0 pb-4", t), children: o })
|
|
55
77
|
}
|
|
56
78
|
);
|
|
57
79
|
}
|
|
58
80
|
export {
|
|
59
|
-
|
|
81
|
+
c as Accordion,
|
|
60
82
|
g as AccordionContent,
|
|
61
83
|
l as AccordionItem,
|
|
62
84
|
m as AccordionTrigger
|
|
@@ -1 +1,17 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../index-Bfismeyo.cjs"),u=require("@radix-ui/react-alert-dialog"),n=require("../button-DWBp81pk.cjs");function c(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const l in t)if(l!=="default"){const r=Object.getOwnPropertyDescriptor(t,l);Object.defineProperty(a,l,r.get?r:{enumerable:!0,get:()=>t[l]})}}return a.default=t,Object.freeze(a)}const o=c(u);function d({...t}){return e.jsxRuntimeExports.jsx(o.Root,{"data-slot":"alert-dialog",...t})}function g({...t}){return e.jsxRuntimeExports.jsx(o.Trigger,{"data-slot":"alert-dialog-trigger",...t})}function i({...t}){return e.jsxRuntimeExports.jsx(o.Portal,{"data-slot":"alert-dialog-portal",...t})}function s({className:t,...a}){return e.jsxRuntimeExports.jsx(o.Overlay,{"data-slot":"alert-dialog-overlay",className:e.cn(`
|
|
2
|
+
fixed inset-0 z-50 bg-black/50
|
|
3
|
+
data-[state=closed]:animate-out data-[state=closed]:fade-out-0
|
|
4
|
+
data-[state=open]:animate-in data-[state=open]:fade-in-0
|
|
5
|
+
`,t),...a})}function x({className:t,...a}){return e.jsxRuntimeExports.jsxs(i,{children:[e.jsxRuntimeExports.jsx(s,{}),e.jsxRuntimeExports.jsx(o.Content,{"data-slot":"alert-dialog-content",className:e.cn(`
|
|
6
|
+
fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)]
|
|
7
|
+
translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border
|
|
8
|
+
bg-background p-6 shadow-lg duration-200 ease-in-out
|
|
9
|
+
data-[state=closed]:animate-out data-[state=closed]:fade-out-0
|
|
10
|
+
data-[state=closed]:zoom-out-90
|
|
11
|
+
data-[state=open]:animate-in data-[state=open]:fade-in-0
|
|
12
|
+
data-[state=open]:zoom-in-90
|
|
13
|
+
sm:max-w-lg
|
|
14
|
+
`,t),...a})]})}function m({className:t,...a}){return e.jsxRuntimeExports.jsx("div",{"data-slot":"alert-dialog-header",className:e.cn("flex flex-col gap-2 text-left",t),...a})}function f({className:t,...a}){return e.jsxRuntimeExports.jsx("div",{"data-slot":"alert-dialog-footer",className:e.cn(`
|
|
15
|
+
flex flex-col-reverse gap-2
|
|
16
|
+
sm:flex-row sm:justify-end
|
|
17
|
+
`,t),...a})}function p({className:t,...a}){return e.jsxRuntimeExports.jsx(o.Title,{"data-slot":"alert-dialog-title",className:e.cn("label-2xl font-semibold text-foreground",t),...a})}function j({className:t,...a}){return e.jsxRuntimeExports.jsx(o.Description,{"data-slot":"alert-dialog-description",className:e.cn("paragraph-md text-muted-foreground",t),...a})}function D({className:t,...a}){return e.jsxRuntimeExports.jsx(o.Action,{className:e.cn(n.buttonStyles(),t),...a})}function A({className:t,...a}){return e.jsxRuntimeExports.jsx(o.Cancel,{className:e.cn(n.buttonStyles({variant:"outline"}),t),...a})}exports.AlertDialog=d;exports.AlertDialogAction=D;exports.AlertDialogCancel=A;exports.AlertDialogContent=x;exports.AlertDialogDescription=j;exports.AlertDialogFooter=f;exports.AlertDialogHeader=m;exports.AlertDialogOverlay=s;exports.AlertDialogPortal=i;exports.AlertDialogTitle=p;exports.AlertDialogTrigger=g;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { j as e, c as l } from "../index-
|
|
1
|
+
import { j as e, c as l } from "../index-CwFDnnd3.js";
|
|
2
2
|
import * as o from "@radix-ui/react-alert-dialog";
|
|
3
|
-
import {
|
|
3
|
+
import { b as r } from "../button-2VesFn_C.js";
|
|
4
4
|
function c({
|
|
5
5
|
...t
|
|
6
6
|
}) {
|
|
@@ -25,7 +25,11 @@ function i({
|
|
|
25
25
|
{
|
|
26
26
|
"data-slot": "alert-dialog-overlay",
|
|
27
27
|
className: l(
|
|
28
|
-
|
|
28
|
+
`
|
|
29
|
+
fixed inset-0 z-50 bg-black/50
|
|
30
|
+
data-[state=closed]:animate-out data-[state=closed]:fade-out-0
|
|
31
|
+
data-[state=open]:animate-in data-[state=open]:fade-in-0
|
|
32
|
+
`,
|
|
29
33
|
t
|
|
30
34
|
),
|
|
31
35
|
...a
|
|
@@ -43,7 +47,16 @@ function u({
|
|
|
43
47
|
{
|
|
44
48
|
"data-slot": "alert-dialog-content",
|
|
45
49
|
className: l(
|
|
46
|
-
|
|
50
|
+
`
|
|
51
|
+
fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)]
|
|
52
|
+
translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border
|
|
53
|
+
bg-background p-6 shadow-lg duration-200 ease-in-out
|
|
54
|
+
data-[state=closed]:animate-out data-[state=closed]:fade-out-0
|
|
55
|
+
data-[state=closed]:zoom-out-90
|
|
56
|
+
data-[state=open]:animate-in data-[state=open]:fade-in-0
|
|
57
|
+
data-[state=open]:zoom-in-90
|
|
58
|
+
sm:max-w-lg
|
|
59
|
+
`,
|
|
47
60
|
t
|
|
48
61
|
),
|
|
49
62
|
...a
|
|
@@ -73,7 +86,10 @@ function m({
|
|
|
73
86
|
{
|
|
74
87
|
"data-slot": "alert-dialog-footer",
|
|
75
88
|
className: l(
|
|
76
|
-
|
|
89
|
+
`
|
|
90
|
+
flex flex-col-reverse gap-2
|
|
91
|
+
sm:flex-row sm:justify-end
|
|
92
|
+
`,
|
|
77
93
|
t
|
|
78
94
|
),
|
|
79
95
|
...a
|
|
@@ -88,7 +104,7 @@ function x({
|
|
|
88
104
|
o.Title,
|
|
89
105
|
{
|
|
90
106
|
"data-slot": "alert-dialog-title",
|
|
91
|
-
className: l("label-2xl font-semibold", t),
|
|
107
|
+
className: l("label-2xl font-semibold text-foreground", t),
|
|
92
108
|
...a
|
|
93
109
|
}
|
|
94
110
|
);
|
|
@@ -101,7 +117,7 @@ function p({
|
|
|
101
117
|
o.Description,
|
|
102
118
|
{
|
|
103
119
|
"data-slot": "alert-dialog-description",
|
|
104
|
-
className: l("text-muted-foreground
|
|
120
|
+
className: l("paragraph-md text-muted-foreground", t),
|
|
105
121
|
...a
|
|
106
122
|
}
|
|
107
123
|
);
|
|
@@ -1 +1,6 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../index-Bfismeyo.cjs"),s=require("@phosphor-icons/react"),g=require("../index-BmhzhLcV.cjs"),x=g.cva(`
|
|
2
|
+
relative grid w-full grid-cols-[0_1fr] items-start gap-y-2 rounded-2xl
|
|
3
|
+
border px-6 py-6 paragraph-sm text-foreground
|
|
4
|
+
has-[>svg]:grid-cols-[calc(var(--spacing)*5)_1fr] has-[>svg]:gap-x-3
|
|
5
|
+
[&>svg]:size-5 [&>svg]:translate-y-0.5 [&>svg]:text-current
|
|
6
|
+
`,{variants:{variant:{info:"border-info-foreground/50 bg-info/50",success:"border-success-foreground/50 bg-success/50",warning:"border-warning-foreground/50 bg-warning/50",error:"border-destructive-foreground/50 bg-destructive/50",neutral:"border-muted bg-muted/50"}},defaultVariants:{variant:"neutral"}}),p={info:s.InfoIcon,success:s.CheckCircleIcon,warning:s.WarningIcon,error:s.WarningCircleIcon,neutral:s.QuestionIcon},f={info:"text-info-foreground!",success:"text-success-foreground!",warning:"text-warning-foreground!",error:"text-destructive-foreground!",neutral:"text-muted-foreground!"};function m({className:t,title:e,content:o,variant:n="neutral",showIcon:c,children:l,...u}){const d=p[n];return r.jsxRuntimeExports.jsxs("div",{"data-slot":"alert",role:"alert",className:r.cn(x({variant:n}),t),...u,children:[c&&n&&r.jsxRuntimeExports.jsx(d,{className:r.cn("size-5 min-w-5",f[n])}),e&&r.jsxRuntimeExports.jsx(a,{children:r.jsxRuntimeExports.jsx("p",{className:"label-lg font-semibold",children:e})}),o&&r.jsxRuntimeExports.jsx(i,{children:r.jsxRuntimeExports.jsx("p",{className:"paragraph-sm",children:o})}),l]})}function a({className:t,...e}){return r.jsxRuntimeExports.jsx("div",{"data-slot":"alert-title",className:r.cn("col-start-2 label-lg font-semibold",t),...e})}function i({className:t,...e}){return r.jsxRuntimeExports.jsx("div",{"data-slot":"alert-description",className:r.cn("col-start-2 grid justify-items-start gap-1 paragraph-sm",t),...e})}exports.Alert=m;exports.AlertDescription=i;exports.AlertTitle=a;
|
|
@@ -3,12 +3,11 @@ export interface IAlertProps extends React.HTMLAttributes<HTMLDivElement>, Varia
|
|
|
3
3
|
title?: string;
|
|
4
4
|
content?: string;
|
|
5
5
|
showIcon?: boolean;
|
|
6
|
-
icon?: React.ElementType | React.ReactNode;
|
|
7
6
|
}
|
|
8
7
|
declare const alertVariants: (props?: ({
|
|
9
8
|
variant?: "info" | "success" | "warning" | "error" | "neutral" | null | undefined;
|
|
10
9
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
11
|
-
declare function Alert({ className, title, content, variant, showIcon,
|
|
10
|
+
declare function Alert({ className, title, content, variant, showIcon, children, ...props }: React.ComponentProps<'div'> & VariantProps<typeof alertVariants> & IAlertProps): import("react/jsx-runtime").JSX.Element;
|
|
12
11
|
declare function AlertTitle({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
13
12
|
declare function AlertDescription({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
14
13
|
export { Alert, AlertDescription, AlertTitle };
|