@ichaingo/ui 1.1.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/.babelrc +12 -0
- package/README.md +103 -0
- package/components.json +21 -0
- package/dist/accordion.d.ts +13 -0
- package/dist/accordion.mjs +64 -0
- package/dist/alert-dialog.d.ts +27 -0
- package/dist/alert-dialog.mjs +146 -0
- package/dist/alert.d.ts +16 -0
- package/dist/alert.mjs +66 -0
- package/dist/aspect-ratio.d.ts +6 -0
- package/dist/aspect-ratio.mjs +10 -0
- package/dist/avatar.d.ts +11 -0
- package/dist/avatar.mjs +53 -0
- package/dist/badge.d.ts +14 -0
- package/dist/badge.mjs +39 -0
- package/dist/breadcrumb.d.ts +20 -0
- package/dist/breadcrumb.mjs +102 -0
- package/dist/button.d.ts +15 -0
- package/dist/button.mjs +49 -0
- package/dist/calendar.d.ts +23 -0
- package/dist/calendar.mjs +173 -0
- package/dist/card.d.ts +18 -0
- package/dist/card.mjs +90 -0
- package/dist/carousel.d.ts +42 -0
- package/dist/carousel.mjs +177 -0
- package/dist/checkbox.d.ts +7 -0
- package/dist/checkbox.mjs +31 -0
- package/dist/collapsible.d.ts +10 -0
- package/dist/collapsible.mjs +34 -0
- package/dist/command.d.ts +31 -0
- package/dist/command.mjs +170 -0
- package/dist/context-menu.d.ts +42 -0
- package/dist/context-menu.mjs +223 -0
- package/dist/dialog.d.ts +27 -0
- package/dist/dialog.mjs +136 -0
- package/dist/dropdown-menu.d.ts +42 -0
- package/dist/dropdown-menu.mjs +231 -0
- package/dist/form.d.ts +38 -0
- package/dist/form.mjs +101 -0
- package/dist/hover-card.d.ts +11 -0
- package/dist/hover-card.mjs +38 -0
- package/dist/input.d.ts +6 -0
- package/dist/input.mjs +21 -0
- package/dist/label.d.ts +7 -0
- package/dist/label.mjs +23 -0
- package/dist/menubar.d.ts +44 -0
- package/dist/menubar.mjs +251 -0
- package/dist/navigation-menu.d.ts +26 -0
- package/dist/navigation-menu.mjs +170 -0
- package/dist/pagination.d.ts +33 -0
- package/dist/pagination.mjs +116 -0
- package/dist/popover.d.ts +13 -0
- package/dist/popover.mjs +44 -0
- package/dist/progress.d.ts +7 -0
- package/dist/progress.mjs +31 -0
- package/dist/radio-group.d.ts +9 -0
- package/dist/radio-group.mjs +45 -0
- package/dist/resizable.d.ts +13 -0
- package/dist/resizable.mjs +48 -0
- package/dist/scroll-area.d.ts +9 -0
- package/dist/scroll-area.mjs +60 -0
- package/dist/select.d.ts +27 -0
- package/dist/select.mjs +169 -0
- package/dist/separator.d.ts +7 -0
- package/dist/separator.mjs +26 -0
- package/dist/sheet.d.ts +23 -0
- package/dist/sheet.mjs +126 -0
- package/dist/skeleton.d.ts +5 -0
- package/dist/skeleton.mjs +15 -0
- package/dist/slider.d.ts +7 -0
- package/dist/slider.mjs +63 -0
- package/dist/sonner.d.ts +6 -0
- package/dist/sonner.mjs +22 -0
- package/dist/switch.d.ts +7 -0
- package/dist/switch.mjs +31 -0
- package/dist/table.d.ts +20 -0
- package/dist/table.mjs +114 -0
- package/dist/tabs.d.ts +13 -0
- package/dist/tabs.mjs +67 -0
- package/dist/textarea.d.ts +6 -0
- package/dist/textarea.mjs +18 -0
- package/dist/toggle-group.d.ts +16 -0
- package/dist/toggle-group.mjs +62 -0
- package/dist/toggle.d.ts +14 -0
- package/dist/toggle.mjs +43 -0
- package/dist/tooltip.d.ts +13 -0
- package/dist/tooltip.mjs +55 -0
- package/dist/utils-B7J70Nno.js +8 -0
- package/eslint.config.mjs +12 -0
- package/package.json +273 -0
- package/postcss.config.js +6 -0
- package/src/components/ui/accordion.tsx +64 -0
- package/src/components/ui/alert-dialog.tsx +155 -0
- package/src/components/ui/alert.tsx +66 -0
- package/src/components/ui/aspect-ratio.tsx +9 -0
- package/src/components/ui/avatar.tsx +51 -0
- package/src/components/ui/badge.tsx +46 -0
- package/src/components/ui/breadcrumb.tsx +109 -0
- package/src/components/ui/button.tsx +59 -0
- package/src/components/ui/calendar.tsx +211 -0
- package/src/components/ui/card.tsx +92 -0
- package/src/components/ui/carousel.tsx +239 -0
- package/src/components/ui/checkbox.tsx +30 -0
- package/src/components/ui/collapsible.tsx +31 -0
- package/src/components/ui/command.tsx +182 -0
- package/src/components/ui/context-menu.tsx +250 -0
- package/src/components/ui/dialog.tsx +141 -0
- package/src/components/ui/dropdown-menu.tsx +255 -0
- package/src/components/ui/form.tsx +165 -0
- package/src/components/ui/hover-card.tsx +42 -0
- package/src/components/ui/input.tsx +21 -0
- package/src/components/ui/label.tsx +24 -0
- package/src/components/ui/menubar.tsx +274 -0
- package/src/components/ui/navigation-menu.tsx +168 -0
- package/src/components/ui/pagination.tsx +125 -0
- package/src/components/ui/popover.tsx +46 -0
- package/src/components/ui/progress.tsx +29 -0
- package/src/components/ui/radio-group.tsx +43 -0
- package/src/components/ui/resizable.tsx +54 -0
- package/src/components/ui/scroll-area.tsx +56 -0
- package/src/components/ui/select.tsx +183 -0
- package/src/components/ui/separator.tsx +26 -0
- package/src/components/ui/sheet.tsx +137 -0
- package/src/components/ui/skeleton.tsx +13 -0
- package/src/components/ui/slider.tsx +61 -0
- package/src/components/ui/sonner.tsx +23 -0
- package/src/components/ui/switch.tsx +29 -0
- package/src/components/ui/table.tsx +114 -0
- package/src/components/ui/tabs.tsx +64 -0
- package/src/components/ui/textarea.tsx +18 -0
- package/src/components/ui/toggle-group.tsx +71 -0
- package/src/components/ui/toggle.tsx +45 -0
- package/src/components/ui/tooltip.tsx +59 -0
- package/src/index.ts +46 -0
- package/src/lib/utils.ts +6 -0
- package/src/style.css +0 -0
- package/tailwind.config.js +52 -0
- package/tsconfig.json +19 -0
- package/tsconfig.lib.json +54 -0
- package/tsconfig.spec.json +32 -0
- package/vite.config.ts +136 -0
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
|
|
2
|
+
import { JSX } from 'react/jsx-runtime';
|
|
3
|
+
import * as React_2 from 'react';
|
|
4
|
+
|
|
5
|
+
export declare function Checkbox({ className, ...props }: React_2.ComponentProps<typeof CheckboxPrimitive.Root>): JSX.Element;
|
|
6
|
+
|
|
7
|
+
export { }
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import * as e from "@radix-ui/react-checkbox";
|
|
3
|
+
import { CheckIcon as a } from "lucide-react";
|
|
4
|
+
import { c as o } from "./utils-B7J70Nno.js";
|
|
5
|
+
function n({
|
|
6
|
+
className: i,
|
|
7
|
+
...t
|
|
8
|
+
}) {
|
|
9
|
+
return /* @__PURE__ */ r(
|
|
10
|
+
e.Root,
|
|
11
|
+
{
|
|
12
|
+
"data-slot": "checkbox",
|
|
13
|
+
className: o(
|
|
14
|
+
"peer border-input dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",
|
|
15
|
+
i
|
|
16
|
+
),
|
|
17
|
+
...t,
|
|
18
|
+
children: /* @__PURE__ */ r(
|
|
19
|
+
e.Indicator,
|
|
20
|
+
{
|
|
21
|
+
"data-slot": "checkbox-indicator",
|
|
22
|
+
className: "flex items-center justify-center text-current transition-none",
|
|
23
|
+
children: /* @__PURE__ */ r(a, { className: "size-3.5" })
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
}
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
export {
|
|
30
|
+
n as Checkbox
|
|
31
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as CollapsiblePrimitive from '@radix-ui/react-collapsible';
|
|
2
|
+
import { JSX } from 'react/jsx-runtime';
|
|
3
|
+
|
|
4
|
+
export declare function Collapsible({ ...props }: React.ComponentProps<typeof CollapsiblePrimitive.Root>): JSX.Element;
|
|
5
|
+
|
|
6
|
+
export declare function CollapsibleContent({ ...props }: React.ComponentProps<typeof CollapsiblePrimitive.CollapsibleContent>): JSX.Element;
|
|
7
|
+
|
|
8
|
+
export declare function CollapsibleTrigger({ ...props }: React.ComponentProps<typeof CollapsiblePrimitive.CollapsibleTrigger>): JSX.Element;
|
|
9
|
+
|
|
10
|
+
export { }
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import * as t from "@radix-ui/react-collapsible";
|
|
3
|
+
function i({
|
|
4
|
+
...l
|
|
5
|
+
}) {
|
|
6
|
+
return /* @__PURE__ */ o(t.Root, { "data-slot": "collapsible", ...l });
|
|
7
|
+
}
|
|
8
|
+
function r({
|
|
9
|
+
...l
|
|
10
|
+
}) {
|
|
11
|
+
return /* @__PURE__ */ o(
|
|
12
|
+
t.CollapsibleTrigger,
|
|
13
|
+
{
|
|
14
|
+
"data-slot": "collapsible-trigger",
|
|
15
|
+
...l
|
|
16
|
+
}
|
|
17
|
+
);
|
|
18
|
+
}
|
|
19
|
+
function a({
|
|
20
|
+
...l
|
|
21
|
+
}) {
|
|
22
|
+
return /* @__PURE__ */ o(
|
|
23
|
+
t.CollapsibleContent,
|
|
24
|
+
{
|
|
25
|
+
"data-slot": "collapsible-content",
|
|
26
|
+
...l
|
|
27
|
+
}
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
export {
|
|
31
|
+
i as Collapsible,
|
|
32
|
+
a as CollapsibleContent,
|
|
33
|
+
r as CollapsibleTrigger
|
|
34
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Command as Command_2 } from 'cmdk';
|
|
2
|
+
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
3
|
+
import { JSX } from 'react/jsx-runtime';
|
|
4
|
+
import * as React_2 from 'react';
|
|
5
|
+
|
|
6
|
+
export declare function Command({ className, ...props }: React_2.ComponentProps<typeof Command_2>): JSX.Element;
|
|
7
|
+
|
|
8
|
+
export declare function CommandDialog({ title, description, children, className, showCloseButton, ...props }: React_2.ComponentProps<typeof Dialog> & {
|
|
9
|
+
title?: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
className?: string;
|
|
12
|
+
showCloseButton?: boolean;
|
|
13
|
+
}): JSX.Element;
|
|
14
|
+
|
|
15
|
+
export declare function CommandEmpty({ ...props }: React_2.ComponentProps<typeof Command_2.Empty>): JSX.Element;
|
|
16
|
+
|
|
17
|
+
export declare function CommandGroup({ className, ...props }: React_2.ComponentProps<typeof Command_2.Group>): JSX.Element;
|
|
18
|
+
|
|
19
|
+
export declare function CommandInput({ className, ...props }: React_2.ComponentProps<typeof Command_2.Input>): JSX.Element;
|
|
20
|
+
|
|
21
|
+
export declare function CommandItem({ className, ...props }: React_2.ComponentProps<typeof Command_2.Item>): JSX.Element;
|
|
22
|
+
|
|
23
|
+
export declare function CommandList({ className, ...props }: React_2.ComponentProps<typeof Command_2.List>): JSX.Element;
|
|
24
|
+
|
|
25
|
+
export declare function CommandSeparator({ className, ...props }: React_2.ComponentProps<typeof Command_2.Separator>): JSX.Element;
|
|
26
|
+
|
|
27
|
+
export declare function CommandShortcut({ className, ...props }: React_2.ComponentProps<"span">): JSX.Element;
|
|
28
|
+
|
|
29
|
+
declare function Dialog({ ...props }: React_2.ComponentProps<typeof DialogPrimitive.Root>): JSX.Element;
|
|
30
|
+
|
|
31
|
+
export { }
|
package/dist/command.mjs
ADDED
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
import { jsx as o, jsxs as d } from "react/jsx-runtime";
|
|
2
|
+
import { Command as n } from "cmdk";
|
|
3
|
+
import { SearchIcon as i } from "lucide-react";
|
|
4
|
+
import { c as a } from "./utils-B7J70Nno.js";
|
|
5
|
+
import { Dialog as l, DialogHeader as u, DialogTitle as p, DialogDescription as g, DialogContent as f } from "./dialog.mjs";
|
|
6
|
+
function h({
|
|
7
|
+
className: e,
|
|
8
|
+
...t
|
|
9
|
+
}) {
|
|
10
|
+
return /* @__PURE__ */ o(
|
|
11
|
+
n,
|
|
12
|
+
{
|
|
13
|
+
"data-slot": "command",
|
|
14
|
+
className: a(
|
|
15
|
+
"bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",
|
|
16
|
+
e
|
|
17
|
+
),
|
|
18
|
+
...t
|
|
19
|
+
}
|
|
20
|
+
);
|
|
21
|
+
}
|
|
22
|
+
function y({
|
|
23
|
+
title: e = "Command Palette",
|
|
24
|
+
description: t = "Search for a command to run...",
|
|
25
|
+
children: r,
|
|
26
|
+
className: m,
|
|
27
|
+
showCloseButton: s = !0,
|
|
28
|
+
...c
|
|
29
|
+
}) {
|
|
30
|
+
return /* @__PURE__ */ d(l, { ...c, children: [
|
|
31
|
+
/* @__PURE__ */ d(u, { className: "sr-only", children: [
|
|
32
|
+
/* @__PURE__ */ o(p, { children: e }),
|
|
33
|
+
/* @__PURE__ */ o(g, { children: t })
|
|
34
|
+
] }),
|
|
35
|
+
/* @__PURE__ */ o(
|
|
36
|
+
f,
|
|
37
|
+
{
|
|
38
|
+
className: a("overflow-hidden p-0", m),
|
|
39
|
+
showCloseButton: s,
|
|
40
|
+
children: /* @__PURE__ */ o(h, { className: "[&_[cmdk-group-heading]]:text-muted-foreground **:data-[slot=command-input-wrapper]:h-12 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]]:px-2 [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children: r })
|
|
41
|
+
}
|
|
42
|
+
)
|
|
43
|
+
] });
|
|
44
|
+
}
|
|
45
|
+
function C({
|
|
46
|
+
className: e,
|
|
47
|
+
...t
|
|
48
|
+
}) {
|
|
49
|
+
return /* @__PURE__ */ d(
|
|
50
|
+
"div",
|
|
51
|
+
{
|
|
52
|
+
"data-slot": "command-input-wrapper",
|
|
53
|
+
className: "flex h-9 items-center gap-2 border-b px-3",
|
|
54
|
+
children: [
|
|
55
|
+
/* @__PURE__ */ o(i, { className: "size-4 shrink-0 opacity-50" }),
|
|
56
|
+
/* @__PURE__ */ o(
|
|
57
|
+
n.Input,
|
|
58
|
+
{
|
|
59
|
+
"data-slot": "command-input",
|
|
60
|
+
className: a(
|
|
61
|
+
"placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",
|
|
62
|
+
e
|
|
63
|
+
),
|
|
64
|
+
...t
|
|
65
|
+
}
|
|
66
|
+
)
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
);
|
|
70
|
+
}
|
|
71
|
+
function N({
|
|
72
|
+
className: e,
|
|
73
|
+
...t
|
|
74
|
+
}) {
|
|
75
|
+
return /* @__PURE__ */ o(
|
|
76
|
+
n.List,
|
|
77
|
+
{
|
|
78
|
+
"data-slot": "command-list",
|
|
79
|
+
className: a(
|
|
80
|
+
"max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",
|
|
81
|
+
e
|
|
82
|
+
),
|
|
83
|
+
...t
|
|
84
|
+
}
|
|
85
|
+
);
|
|
86
|
+
}
|
|
87
|
+
function b({
|
|
88
|
+
...e
|
|
89
|
+
}) {
|
|
90
|
+
return /* @__PURE__ */ o(
|
|
91
|
+
n.Empty,
|
|
92
|
+
{
|
|
93
|
+
"data-slot": "command-empty",
|
|
94
|
+
className: "py-6 text-center text-sm",
|
|
95
|
+
...e
|
|
96
|
+
}
|
|
97
|
+
);
|
|
98
|
+
}
|
|
99
|
+
function D({
|
|
100
|
+
className: e,
|
|
101
|
+
...t
|
|
102
|
+
}) {
|
|
103
|
+
return /* @__PURE__ */ o(
|
|
104
|
+
n.Group,
|
|
105
|
+
{
|
|
106
|
+
"data-slot": "command-group",
|
|
107
|
+
className: a(
|
|
108
|
+
"text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",
|
|
109
|
+
e
|
|
110
|
+
),
|
|
111
|
+
...t
|
|
112
|
+
}
|
|
113
|
+
);
|
|
114
|
+
}
|
|
115
|
+
function I({
|
|
116
|
+
className: e,
|
|
117
|
+
...t
|
|
118
|
+
}) {
|
|
119
|
+
return /* @__PURE__ */ o(
|
|
120
|
+
n.Separator,
|
|
121
|
+
{
|
|
122
|
+
"data-slot": "command-separator",
|
|
123
|
+
className: a("bg-border -mx-1 h-px", e),
|
|
124
|
+
...t
|
|
125
|
+
}
|
|
126
|
+
);
|
|
127
|
+
}
|
|
128
|
+
function S({
|
|
129
|
+
className: e,
|
|
130
|
+
...t
|
|
131
|
+
}) {
|
|
132
|
+
return /* @__PURE__ */ o(
|
|
133
|
+
n.Item,
|
|
134
|
+
{
|
|
135
|
+
"data-slot": "command-item",
|
|
136
|
+
className: a(
|
|
137
|
+
"data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
138
|
+
e
|
|
139
|
+
),
|
|
140
|
+
...t
|
|
141
|
+
}
|
|
142
|
+
);
|
|
143
|
+
}
|
|
144
|
+
function z({
|
|
145
|
+
className: e,
|
|
146
|
+
...t
|
|
147
|
+
}) {
|
|
148
|
+
return /* @__PURE__ */ o(
|
|
149
|
+
"span",
|
|
150
|
+
{
|
|
151
|
+
"data-slot": "command-shortcut",
|
|
152
|
+
className: a(
|
|
153
|
+
"text-muted-foreground ml-auto text-xs tracking-widest",
|
|
154
|
+
e
|
|
155
|
+
),
|
|
156
|
+
...t
|
|
157
|
+
}
|
|
158
|
+
);
|
|
159
|
+
}
|
|
160
|
+
export {
|
|
161
|
+
h as Command,
|
|
162
|
+
y as CommandDialog,
|
|
163
|
+
b as CommandEmpty,
|
|
164
|
+
D as CommandGroup,
|
|
165
|
+
C as CommandInput,
|
|
166
|
+
S as CommandItem,
|
|
167
|
+
N as CommandList,
|
|
168
|
+
I as CommandSeparator,
|
|
169
|
+
z as CommandShortcut
|
|
170
|
+
};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
|
2
|
+
import { JSX } from 'react/jsx-runtime';
|
|
3
|
+
import * as React_2 from 'react';
|
|
4
|
+
|
|
5
|
+
export declare function ContextMenu({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Root>): JSX.Element;
|
|
6
|
+
|
|
7
|
+
export declare function ContextMenuCheckboxItem({ className, children, checked, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.CheckboxItem>): JSX.Element;
|
|
8
|
+
|
|
9
|
+
export declare function ContextMenuContent({ className, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Content>): JSX.Element;
|
|
10
|
+
|
|
11
|
+
export declare function ContextMenuGroup({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Group>): JSX.Element;
|
|
12
|
+
|
|
13
|
+
export declare function ContextMenuItem({ className, inset, variant, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Item> & {
|
|
14
|
+
inset?: boolean;
|
|
15
|
+
variant?: "default" | "destructive";
|
|
16
|
+
}): JSX.Element;
|
|
17
|
+
|
|
18
|
+
export declare function ContextMenuLabel({ className, inset, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Label> & {
|
|
19
|
+
inset?: boolean;
|
|
20
|
+
}): JSX.Element;
|
|
21
|
+
|
|
22
|
+
export declare function ContextMenuPortal({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Portal>): JSX.Element;
|
|
23
|
+
|
|
24
|
+
export declare function ContextMenuRadioGroup({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.RadioGroup>): JSX.Element;
|
|
25
|
+
|
|
26
|
+
export declare function ContextMenuRadioItem({ className, children, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.RadioItem>): JSX.Element;
|
|
27
|
+
|
|
28
|
+
export declare function ContextMenuSeparator({ className, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Separator>): JSX.Element;
|
|
29
|
+
|
|
30
|
+
export declare function ContextMenuShortcut({ className, ...props }: React_2.ComponentProps<"span">): JSX.Element;
|
|
31
|
+
|
|
32
|
+
export declare function ContextMenuSub({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Sub>): JSX.Element;
|
|
33
|
+
|
|
34
|
+
export declare function ContextMenuSubContent({ className, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.SubContent>): JSX.Element;
|
|
35
|
+
|
|
36
|
+
export declare function ContextMenuSubTrigger({ className, inset, children, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.SubTrigger> & {
|
|
37
|
+
inset?: boolean;
|
|
38
|
+
}): JSX.Element;
|
|
39
|
+
|
|
40
|
+
export declare function ContextMenuTrigger({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Trigger>): JSX.Element;
|
|
41
|
+
|
|
42
|
+
export { }
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
import { jsx as e, jsxs as i } from "react/jsx-runtime";
|
|
2
|
+
import * as o from "@radix-ui/react-context-menu";
|
|
3
|
+
import { CheckIcon as d, CircleIcon as c, ChevronRightIcon as u } from "lucide-react";
|
|
4
|
+
import { c as s } from "./utils-B7J70Nno.js";
|
|
5
|
+
function x({
|
|
6
|
+
...t
|
|
7
|
+
}) {
|
|
8
|
+
return /* @__PURE__ */ e(o.Root, { "data-slot": "context-menu", ...t });
|
|
9
|
+
}
|
|
10
|
+
function p({
|
|
11
|
+
...t
|
|
12
|
+
}) {
|
|
13
|
+
return /* @__PURE__ */ e(o.Trigger, { "data-slot": "context-menu-trigger", ...t });
|
|
14
|
+
}
|
|
15
|
+
function g({
|
|
16
|
+
...t
|
|
17
|
+
}) {
|
|
18
|
+
return /* @__PURE__ */ e(o.Group, { "data-slot": "context-menu-group", ...t });
|
|
19
|
+
}
|
|
20
|
+
function v({
|
|
21
|
+
...t
|
|
22
|
+
}) {
|
|
23
|
+
return /* @__PURE__ */ e(o.Portal, { "data-slot": "context-menu-portal", ...t });
|
|
24
|
+
}
|
|
25
|
+
function b({
|
|
26
|
+
...t
|
|
27
|
+
}) {
|
|
28
|
+
return /* @__PURE__ */ e(o.Sub, { "data-slot": "context-menu-sub", ...t });
|
|
29
|
+
}
|
|
30
|
+
function h({
|
|
31
|
+
...t
|
|
32
|
+
}) {
|
|
33
|
+
return /* @__PURE__ */ e(
|
|
34
|
+
o.RadioGroup,
|
|
35
|
+
{
|
|
36
|
+
"data-slot": "context-menu-radio-group",
|
|
37
|
+
...t
|
|
38
|
+
}
|
|
39
|
+
);
|
|
40
|
+
}
|
|
41
|
+
function C({
|
|
42
|
+
className: t,
|
|
43
|
+
inset: n,
|
|
44
|
+
children: a,
|
|
45
|
+
...r
|
|
46
|
+
}) {
|
|
47
|
+
return /* @__PURE__ */ i(
|
|
48
|
+
o.SubTrigger,
|
|
49
|
+
{
|
|
50
|
+
"data-slot": "context-menu-sub-trigger",
|
|
51
|
+
"data-inset": n,
|
|
52
|
+
className: s(
|
|
53
|
+
"focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
54
|
+
t
|
|
55
|
+
),
|
|
56
|
+
...r,
|
|
57
|
+
children: [
|
|
58
|
+
a,
|
|
59
|
+
/* @__PURE__ */ e(u, { className: "ml-auto" })
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
);
|
|
63
|
+
}
|
|
64
|
+
function z({
|
|
65
|
+
className: t,
|
|
66
|
+
...n
|
|
67
|
+
}) {
|
|
68
|
+
return /* @__PURE__ */ e(
|
|
69
|
+
o.SubContent,
|
|
70
|
+
{
|
|
71
|
+
"data-slot": "context-menu-sub-content",
|
|
72
|
+
className: s(
|
|
73
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-context-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
|
|
74
|
+
t
|
|
75
|
+
),
|
|
76
|
+
...n
|
|
77
|
+
}
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
function M({
|
|
81
|
+
className: t,
|
|
82
|
+
...n
|
|
83
|
+
}) {
|
|
84
|
+
return /* @__PURE__ */ e(o.Portal, { children: /* @__PURE__ */ e(
|
|
85
|
+
o.Content,
|
|
86
|
+
{
|
|
87
|
+
"data-slot": "context-menu-content",
|
|
88
|
+
className: s(
|
|
89
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--radix-context-menu-content-available-height) min-w-[8rem] origin-(--radix-context-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",
|
|
90
|
+
t
|
|
91
|
+
),
|
|
92
|
+
...n
|
|
93
|
+
}
|
|
94
|
+
) });
|
|
95
|
+
}
|
|
96
|
+
function N({
|
|
97
|
+
className: t,
|
|
98
|
+
inset: n,
|
|
99
|
+
variant: a = "default",
|
|
100
|
+
...r
|
|
101
|
+
}) {
|
|
102
|
+
return /* @__PURE__ */ e(
|
|
103
|
+
o.Item,
|
|
104
|
+
{
|
|
105
|
+
"data-slot": "context-menu-item",
|
|
106
|
+
"data-inset": n,
|
|
107
|
+
"data-variant": a,
|
|
108
|
+
className: s(
|
|
109
|
+
"focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
110
|
+
t
|
|
111
|
+
),
|
|
112
|
+
...r
|
|
113
|
+
}
|
|
114
|
+
);
|
|
115
|
+
}
|
|
116
|
+
function I({
|
|
117
|
+
className: t,
|
|
118
|
+
children: n,
|
|
119
|
+
checked: a,
|
|
120
|
+
...r
|
|
121
|
+
}) {
|
|
122
|
+
return /* @__PURE__ */ i(
|
|
123
|
+
o.CheckboxItem,
|
|
124
|
+
{
|
|
125
|
+
"data-slot": "context-menu-checkbox-item",
|
|
126
|
+
className: s(
|
|
127
|
+
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
128
|
+
t
|
|
129
|
+
),
|
|
130
|
+
checked: a,
|
|
131
|
+
...r,
|
|
132
|
+
children: [
|
|
133
|
+
/* @__PURE__ */ e("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ e(o.ItemIndicator, { children: /* @__PURE__ */ e(d, { className: "size-4" }) }) }),
|
|
134
|
+
n
|
|
135
|
+
]
|
|
136
|
+
}
|
|
137
|
+
);
|
|
138
|
+
}
|
|
139
|
+
function _({
|
|
140
|
+
className: t,
|
|
141
|
+
children: n,
|
|
142
|
+
...a
|
|
143
|
+
}) {
|
|
144
|
+
return /* @__PURE__ */ i(
|
|
145
|
+
o.RadioItem,
|
|
146
|
+
{
|
|
147
|
+
"data-slot": "context-menu-radio-item",
|
|
148
|
+
className: s(
|
|
149
|
+
"focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
150
|
+
t
|
|
151
|
+
),
|
|
152
|
+
...a,
|
|
153
|
+
children: [
|
|
154
|
+
/* @__PURE__ */ e("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ e(o.ItemIndicator, { children: /* @__PURE__ */ e(c, { className: "size-2 fill-current" }) }) }),
|
|
155
|
+
n
|
|
156
|
+
]
|
|
157
|
+
}
|
|
158
|
+
);
|
|
159
|
+
}
|
|
160
|
+
function y({
|
|
161
|
+
className: t,
|
|
162
|
+
inset: n,
|
|
163
|
+
...a
|
|
164
|
+
}) {
|
|
165
|
+
return /* @__PURE__ */ e(
|
|
166
|
+
o.Label,
|
|
167
|
+
{
|
|
168
|
+
"data-slot": "context-menu-label",
|
|
169
|
+
"data-inset": n,
|
|
170
|
+
className: s(
|
|
171
|
+
"text-foreground px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",
|
|
172
|
+
t
|
|
173
|
+
),
|
|
174
|
+
...a
|
|
175
|
+
}
|
|
176
|
+
);
|
|
177
|
+
}
|
|
178
|
+
function k({
|
|
179
|
+
className: t,
|
|
180
|
+
...n
|
|
181
|
+
}) {
|
|
182
|
+
return /* @__PURE__ */ e(
|
|
183
|
+
o.Separator,
|
|
184
|
+
{
|
|
185
|
+
"data-slot": "context-menu-separator",
|
|
186
|
+
className: s("bg-border -mx-1 my-1 h-px", t),
|
|
187
|
+
...n
|
|
188
|
+
}
|
|
189
|
+
);
|
|
190
|
+
}
|
|
191
|
+
function S({
|
|
192
|
+
className: t,
|
|
193
|
+
...n
|
|
194
|
+
}) {
|
|
195
|
+
return /* @__PURE__ */ e(
|
|
196
|
+
"span",
|
|
197
|
+
{
|
|
198
|
+
"data-slot": "context-menu-shortcut",
|
|
199
|
+
className: s(
|
|
200
|
+
"text-muted-foreground ml-auto text-xs tracking-widest",
|
|
201
|
+
t
|
|
202
|
+
),
|
|
203
|
+
...n
|
|
204
|
+
}
|
|
205
|
+
);
|
|
206
|
+
}
|
|
207
|
+
export {
|
|
208
|
+
x as ContextMenu,
|
|
209
|
+
I as ContextMenuCheckboxItem,
|
|
210
|
+
M as ContextMenuContent,
|
|
211
|
+
g as ContextMenuGroup,
|
|
212
|
+
N as ContextMenuItem,
|
|
213
|
+
y as ContextMenuLabel,
|
|
214
|
+
v as ContextMenuPortal,
|
|
215
|
+
h as ContextMenuRadioGroup,
|
|
216
|
+
_ as ContextMenuRadioItem,
|
|
217
|
+
k as ContextMenuSeparator,
|
|
218
|
+
S as ContextMenuShortcut,
|
|
219
|
+
b as ContextMenuSub,
|
|
220
|
+
z as ContextMenuSubContent,
|
|
221
|
+
C as ContextMenuSubTrigger,
|
|
222
|
+
p as ContextMenuTrigger
|
|
223
|
+
};
|
package/dist/dialog.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
2
|
+
import { JSX } from 'react/jsx-runtime';
|
|
3
|
+
import * as React_2 from 'react';
|
|
4
|
+
|
|
5
|
+
export declare function Dialog({ ...props }: React_2.ComponentProps<typeof DialogPrimitive.Root>): JSX.Element;
|
|
6
|
+
|
|
7
|
+
export declare function DialogClose({ ...props }: React_2.ComponentProps<typeof DialogPrimitive.Close>): JSX.Element;
|
|
8
|
+
|
|
9
|
+
export declare function DialogContent({ className, children, showCloseButton, ...props }: React_2.ComponentProps<typeof DialogPrimitive.Content> & {
|
|
10
|
+
showCloseButton?: boolean;
|
|
11
|
+
}): JSX.Element;
|
|
12
|
+
|
|
13
|
+
export declare function DialogDescription({ className, ...props }: React_2.ComponentProps<typeof DialogPrimitive.Description>): JSX.Element;
|
|
14
|
+
|
|
15
|
+
export declare function DialogFooter({ className, ...props }: React_2.ComponentProps<"div">): JSX.Element;
|
|
16
|
+
|
|
17
|
+
export declare function DialogHeader({ className, ...props }: React_2.ComponentProps<"div">): JSX.Element;
|
|
18
|
+
|
|
19
|
+
export declare function DialogOverlay({ className, ...props }: React_2.ComponentProps<typeof DialogPrimitive.Overlay>): JSX.Element;
|
|
20
|
+
|
|
21
|
+
export declare function DialogPortal({ ...props }: React_2.ComponentProps<typeof DialogPrimitive.Portal>): JSX.Element;
|
|
22
|
+
|
|
23
|
+
export declare function DialogTitle({ className, ...props }: React_2.ComponentProps<typeof DialogPrimitive.Title>): JSX.Element;
|
|
24
|
+
|
|
25
|
+
export declare function DialogTrigger({ ...props }: React_2.ComponentProps<typeof DialogPrimitive.Trigger>): JSX.Element;
|
|
26
|
+
|
|
27
|
+
export { }
|