ui-arreya-components 0.0.15 → 0.1.2
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/index.d.mts +342 -0
- package/dist/index.d.ts +342 -0
- package/dist/index.js +1682 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +1495 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +61 -106
- package/.storybook/main.ts +0 -18
- package/.storybook/preview.ts +0 -16
- package/.storybook/vitest.setup.ts +0 -9
- package/README.md +0 -54
- package/components.json +0 -21
- package/dist/styles.css +0 -3
- package/dist/ui.cjs.js +0 -119
- package/dist/ui.es.js +0 -7364
- package/dist/ui.umd.js +0 -119
- package/eslint.config.js +0 -28
- package/postcss.config.js +0 -6
- package/scripts/template.sh +0 -57
- package/src/components/feature/header.stories.tsx +0 -129
- package/src/components/feature/header.tsx +0 -78
- package/src/components/feature/login-form.stories.tsx +0 -35
- package/src/components/feature/login-form.tsx +0 -97
- package/src/components/index.ts +0 -1
- package/src/components/ui/accordion.stories.tsx.disabled +0 -36
- package/src/components/ui/accordion.tsx +0 -55
- package/src/components/ui/alert-dialog.stories.tsx +0 -46
- package/src/components/ui/alert-dialog.tsx +0 -139
- package/src/components/ui/alert.stories.tsx +0 -45
- package/src/components/ui/alert.tsx +0 -59
- package/src/components/ui/aspect-ratio.stories.tsx +0 -24
- package/src/components/ui/aspect-ratio.tsx +0 -5
- package/src/components/ui/avatar.stories.tsx +0 -29
- package/src/components/ui/avatar.tsx +0 -48
- package/src/components/ui/badge.stories.tsx +0 -43
- package/src/components/ui/badge.tsx +0 -36
- package/src/components/ui/breadcrumb.stories.tsx +0 -146
- package/src/components/ui/breadcrumb.tsx +0 -115
- package/src/components/ui/button.stories.tsx +0 -87
- package/src/components/ui/button.tsx +0 -57
- package/src/components/ui/card.stories.tsx +0 -99
- package/src/components/ui/card.tsx +0 -76
- package/src/components/ui/carousel.stories.tsx +0 -47
- package/src/components/ui/carousel.tsx +0 -260
- package/src/components/ui/chart.stories.tsx.disabled +0 -44
- package/src/components/ui/chart.tsx +0 -363
- package/src/components/ui/checkbox.stories.tsx +0 -56
- package/src/components/ui/checkbox.tsx +0 -28
- package/src/components/ui/collapsible.stories.tsx +0 -58
- package/src/components/ui/collapsible.tsx +0 -9
- package/src/components/ui/context-menu.stories.tsx +0 -34
- package/src/components/ui/context-menu.tsx +0 -198
- package/src/components/ui/dialog.stories.tsx +0 -40
- package/src/components/ui/dialog.tsx +0 -120
- package/src/components/ui/drawer.stories.tsx +0 -48
- package/src/components/ui/drawer.tsx +0 -116
- package/src/components/ui/dropdown-menu.stories.tsx +0 -92
- package/src/components/ui/dropdown-menu.tsx +0 -199
- package/src/components/ui/form.tsx +0 -176
- package/src/components/ui/hover-card.stories.tsx +0 -31
- package/src/components/ui/hover-card.tsx +0 -27
- package/src/components/ui/index.ts +0 -1
- package/src/components/ui/input-otp.tsx +0 -69
- package/src/components/ui/input.stories.tsx +0 -63
- package/src/components/ui/input.tsx +0 -22
- package/src/components/ui/label.tsx +0 -24
- package/src/components/ui/menubar.tsx +0 -254
- package/src/components/ui/navigation-menu.tsx +0 -128
- package/src/components/ui/pagination.tsx +0 -117
- package/src/components/ui/popover.tsx +0 -31
- package/src/components/ui/progress.tsx +0 -26
- package/src/components/ui/radio-group.tsx +0 -42
- package/src/components/ui/resizable.tsx +0 -43
- package/src/components/ui/scroll-area.tsx +0 -46
- package/src/components/ui/select.tsx +0 -157
- package/src/components/ui/separator.tsx +0 -29
- package/src/components/ui/sheet.tsx +0 -140
- package/src/components/ui/sidebar.tsx +0 -771
- package/src/components/ui/skeleton.tsx +0 -15
- package/src/components/ui/slider.tsx +0 -26
- package/src/components/ui/sonner.tsx +0 -29
- package/src/components/ui/switch.tsx +0 -27
- package/src/components/ui/table.tsx +0 -120
- package/src/components/ui/tabs.tsx +0 -53
- package/src/components/ui/textarea.tsx +0 -22
- package/src/components/ui/toast.tsx +0 -127
- package/src/components/ui/toaster.tsx +0 -33
- package/src/components/ui/toggle-group.tsx +0 -59
- package/src/components/ui/toggle.tsx +0 -43
- package/src/components/ui/tooltip.tsx +0 -30
- package/src/hooks/use-mobile.tsx +0 -19
- package/src/hooks/use-toast.ts +0 -194
- package/src/index.css +0 -3509
- package/src/index.ts +0 -51
- package/src/lib/types.ts +0 -5
- package/src/lib/utils.ts +0 -6
- package/src/styles/tailwind.css +0 -100
- package/tailwind.config.js +0 -96
- package/tsconfig.app.json +0 -30
- package/tsconfig.json +0 -13
- package/tsconfig.node.json +0 -24
- package/vite.config.ts +0 -33
- package/vitest.workspace.ts +0 -32
|
@@ -1,254 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import * as MenubarPrimitive from "@radix-ui/react-menubar"
|
|
3
|
-
import { Check, ChevronRight, Circle } from "lucide-react"
|
|
4
|
-
|
|
5
|
-
import { cn } from "@/lib/utils"
|
|
6
|
-
|
|
7
|
-
function MenubarMenu({
|
|
8
|
-
...props
|
|
9
|
-
}: React.ComponentProps<typeof MenubarPrimitive.Menu>) {
|
|
10
|
-
return <MenubarPrimitive.Menu {...props} />
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
function MenubarGroup({
|
|
14
|
-
...props
|
|
15
|
-
}: React.ComponentProps<typeof MenubarPrimitive.Group>) {
|
|
16
|
-
return <MenubarPrimitive.Group {...props} />
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
function MenubarPortal({
|
|
20
|
-
...props
|
|
21
|
-
}: React.ComponentProps<typeof MenubarPrimitive.Portal>) {
|
|
22
|
-
return <MenubarPrimitive.Portal {...props} />
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
function MenubarRadioGroup({
|
|
26
|
-
...props
|
|
27
|
-
}: React.ComponentProps<typeof MenubarPrimitive.RadioGroup>) {
|
|
28
|
-
return <MenubarPrimitive.RadioGroup {...props} />
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
function MenubarSub({
|
|
32
|
-
...props
|
|
33
|
-
}: React.ComponentProps<typeof MenubarPrimitive.Sub>) {
|
|
34
|
-
return <MenubarPrimitive.Sub data-slot="menubar-sub" {...props} />
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
const Menubar = React.forwardRef<
|
|
38
|
-
React.ElementRef<typeof MenubarPrimitive.Root>,
|
|
39
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Root>
|
|
40
|
-
>(({ className, ...props }, ref) => (
|
|
41
|
-
<MenubarPrimitive.Root
|
|
42
|
-
ref={ref}
|
|
43
|
-
className={cn(
|
|
44
|
-
"flex h-9 items-center space-x-1 rounded-md border bg-background p-1 shadow-sm",
|
|
45
|
-
className
|
|
46
|
-
)}
|
|
47
|
-
{...props}
|
|
48
|
-
/>
|
|
49
|
-
))
|
|
50
|
-
Menubar.displayName = MenubarPrimitive.Root.displayName
|
|
51
|
-
|
|
52
|
-
const MenubarTrigger = React.forwardRef<
|
|
53
|
-
React.ElementRef<typeof MenubarPrimitive.Trigger>,
|
|
54
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Trigger>
|
|
55
|
-
>(({ className, ...props }, ref) => (
|
|
56
|
-
<MenubarPrimitive.Trigger
|
|
57
|
-
ref={ref}
|
|
58
|
-
className={cn(
|
|
59
|
-
"flex cursor-default select-none items-center rounded-sm px-3 py-1 text-sm font-medium outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
|
|
60
|
-
className
|
|
61
|
-
)}
|
|
62
|
-
{...props}
|
|
63
|
-
/>
|
|
64
|
-
))
|
|
65
|
-
MenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName
|
|
66
|
-
|
|
67
|
-
const MenubarSubTrigger = React.forwardRef<
|
|
68
|
-
React.ElementRef<typeof MenubarPrimitive.SubTrigger>,
|
|
69
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubTrigger> & {
|
|
70
|
-
inset?: boolean
|
|
71
|
-
}
|
|
72
|
-
>(({ className, inset, children, ...props }, ref) => (
|
|
73
|
-
<MenubarPrimitive.SubTrigger
|
|
74
|
-
ref={ref}
|
|
75
|
-
className={cn(
|
|
76
|
-
"flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
|
|
77
|
-
inset && "pl-8",
|
|
78
|
-
className
|
|
79
|
-
)}
|
|
80
|
-
{...props}
|
|
81
|
-
>
|
|
82
|
-
{children}
|
|
83
|
-
<ChevronRight className="ml-auto h-4 w-4" />
|
|
84
|
-
</MenubarPrimitive.SubTrigger>
|
|
85
|
-
))
|
|
86
|
-
MenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName
|
|
87
|
-
|
|
88
|
-
const MenubarSubContent = React.forwardRef<
|
|
89
|
-
React.ElementRef<typeof MenubarPrimitive.SubContent>,
|
|
90
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubContent>
|
|
91
|
-
>(({ className, ...props }, ref) => (
|
|
92
|
-
<MenubarPrimitive.SubContent
|
|
93
|
-
ref={ref}
|
|
94
|
-
className={cn(
|
|
95
|
-
"z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg 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 origin-[--radix-menubar-content-transform-origin]",
|
|
96
|
-
className
|
|
97
|
-
)}
|
|
98
|
-
{...props}
|
|
99
|
-
/>
|
|
100
|
-
))
|
|
101
|
-
MenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName
|
|
102
|
-
|
|
103
|
-
const MenubarContent = React.forwardRef<
|
|
104
|
-
React.ElementRef<typeof MenubarPrimitive.Content>,
|
|
105
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Content>
|
|
106
|
-
>(
|
|
107
|
-
(
|
|
108
|
-
{ className, align = "start", alignOffset = -4, sideOffset = 8, ...props },
|
|
109
|
-
ref
|
|
110
|
-
) => (
|
|
111
|
-
<MenubarPrimitive.Portal>
|
|
112
|
-
<MenubarPrimitive.Content
|
|
113
|
-
ref={ref}
|
|
114
|
-
align={align}
|
|
115
|
-
alignOffset={alignOffset}
|
|
116
|
-
sideOffset={sideOffset}
|
|
117
|
-
className={cn(
|
|
118
|
-
"z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in 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 origin-[--radix-menubar-content-transform-origin]",
|
|
119
|
-
className
|
|
120
|
-
)}
|
|
121
|
-
{...props}
|
|
122
|
-
/>
|
|
123
|
-
</MenubarPrimitive.Portal>
|
|
124
|
-
)
|
|
125
|
-
)
|
|
126
|
-
MenubarContent.displayName = MenubarPrimitive.Content.displayName
|
|
127
|
-
|
|
128
|
-
const MenubarItem = React.forwardRef<
|
|
129
|
-
React.ElementRef<typeof MenubarPrimitive.Item>,
|
|
130
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Item> & {
|
|
131
|
-
inset?: boolean
|
|
132
|
-
}
|
|
133
|
-
>(({ className, inset, ...props }, ref) => (
|
|
134
|
-
<MenubarPrimitive.Item
|
|
135
|
-
ref={ref}
|
|
136
|
-
className={cn(
|
|
137
|
-
"relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
138
|
-
inset && "pl-8",
|
|
139
|
-
className
|
|
140
|
-
)}
|
|
141
|
-
{...props}
|
|
142
|
-
/>
|
|
143
|
-
))
|
|
144
|
-
MenubarItem.displayName = MenubarPrimitive.Item.displayName
|
|
145
|
-
|
|
146
|
-
const MenubarCheckboxItem = React.forwardRef<
|
|
147
|
-
React.ElementRef<typeof MenubarPrimitive.CheckboxItem>,
|
|
148
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.CheckboxItem>
|
|
149
|
-
>(({ className, children, checked, ...props }, ref) => (
|
|
150
|
-
<MenubarPrimitive.CheckboxItem
|
|
151
|
-
ref={ref}
|
|
152
|
-
className={cn(
|
|
153
|
-
"relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
154
|
-
className
|
|
155
|
-
)}
|
|
156
|
-
checked={checked}
|
|
157
|
-
{...props}
|
|
158
|
-
>
|
|
159
|
-
<span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
|
|
160
|
-
<MenubarPrimitive.ItemIndicator>
|
|
161
|
-
<Check className="h-4 w-4" />
|
|
162
|
-
</MenubarPrimitive.ItemIndicator>
|
|
163
|
-
</span>
|
|
164
|
-
{children}
|
|
165
|
-
</MenubarPrimitive.CheckboxItem>
|
|
166
|
-
))
|
|
167
|
-
MenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName
|
|
168
|
-
|
|
169
|
-
const MenubarRadioItem = React.forwardRef<
|
|
170
|
-
React.ElementRef<typeof MenubarPrimitive.RadioItem>,
|
|
171
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.RadioItem>
|
|
172
|
-
>(({ className, children, ...props }, ref) => (
|
|
173
|
-
<MenubarPrimitive.RadioItem
|
|
174
|
-
ref={ref}
|
|
175
|
-
className={cn(
|
|
176
|
-
"relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
177
|
-
className
|
|
178
|
-
)}
|
|
179
|
-
{...props}
|
|
180
|
-
>
|
|
181
|
-
<span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
|
|
182
|
-
<MenubarPrimitive.ItemIndicator>
|
|
183
|
-
<Circle className="h-4 w-4 fill-current" />
|
|
184
|
-
</MenubarPrimitive.ItemIndicator>
|
|
185
|
-
</span>
|
|
186
|
-
{children}
|
|
187
|
-
</MenubarPrimitive.RadioItem>
|
|
188
|
-
))
|
|
189
|
-
MenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName
|
|
190
|
-
|
|
191
|
-
const MenubarLabel = React.forwardRef<
|
|
192
|
-
React.ElementRef<typeof MenubarPrimitive.Label>,
|
|
193
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Label> & {
|
|
194
|
-
inset?: boolean
|
|
195
|
-
}
|
|
196
|
-
>(({ className, inset, ...props }, ref) => (
|
|
197
|
-
<MenubarPrimitive.Label
|
|
198
|
-
ref={ref}
|
|
199
|
-
className={cn(
|
|
200
|
-
"px-2 py-1.5 text-sm font-semibold",
|
|
201
|
-
inset && "pl-8",
|
|
202
|
-
className
|
|
203
|
-
)}
|
|
204
|
-
{...props}
|
|
205
|
-
/>
|
|
206
|
-
))
|
|
207
|
-
MenubarLabel.displayName = MenubarPrimitive.Label.displayName
|
|
208
|
-
|
|
209
|
-
const MenubarSeparator = React.forwardRef<
|
|
210
|
-
React.ElementRef<typeof MenubarPrimitive.Separator>,
|
|
211
|
-
React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Separator>
|
|
212
|
-
>(({ className, ...props }, ref) => (
|
|
213
|
-
<MenubarPrimitive.Separator
|
|
214
|
-
ref={ref}
|
|
215
|
-
className={cn("-mx-1 my-1 h-px bg-muted", className)}
|
|
216
|
-
{...props}
|
|
217
|
-
/>
|
|
218
|
-
))
|
|
219
|
-
MenubarSeparator.displayName = MenubarPrimitive.Separator.displayName
|
|
220
|
-
|
|
221
|
-
const MenubarShortcut = ({
|
|
222
|
-
className,
|
|
223
|
-
...props
|
|
224
|
-
}: React.HTMLAttributes<HTMLSpanElement>) => {
|
|
225
|
-
return (
|
|
226
|
-
<span
|
|
227
|
-
className={cn(
|
|
228
|
-
"ml-auto text-xs tracking-widest text-muted-foreground",
|
|
229
|
-
className
|
|
230
|
-
)}
|
|
231
|
-
{...props}
|
|
232
|
-
/>
|
|
233
|
-
)
|
|
234
|
-
}
|
|
235
|
-
MenubarShortcut.displayname = "MenubarShortcut"
|
|
236
|
-
|
|
237
|
-
export {
|
|
238
|
-
Menubar,
|
|
239
|
-
MenubarMenu,
|
|
240
|
-
MenubarTrigger,
|
|
241
|
-
MenubarContent,
|
|
242
|
-
MenubarItem,
|
|
243
|
-
MenubarSeparator,
|
|
244
|
-
MenubarLabel,
|
|
245
|
-
MenubarCheckboxItem,
|
|
246
|
-
MenubarRadioGroup,
|
|
247
|
-
MenubarRadioItem,
|
|
248
|
-
MenubarPortal,
|
|
249
|
-
MenubarSubContent,
|
|
250
|
-
MenubarSubTrigger,
|
|
251
|
-
MenubarGroup,
|
|
252
|
-
MenubarSub,
|
|
253
|
-
MenubarShortcut,
|
|
254
|
-
}
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu"
|
|
3
|
-
import { cva } from "class-variance-authority"
|
|
4
|
-
import { ChevronDown } from "lucide-react"
|
|
5
|
-
|
|
6
|
-
import { cn } from "@/lib/utils"
|
|
7
|
-
|
|
8
|
-
const NavigationMenu = React.forwardRef<
|
|
9
|
-
React.ElementRef<typeof NavigationMenuPrimitive.Root>,
|
|
10
|
-
React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>
|
|
11
|
-
>(({ className, children, ...props }, ref) => (
|
|
12
|
-
<NavigationMenuPrimitive.Root
|
|
13
|
-
ref={ref}
|
|
14
|
-
className={cn(
|
|
15
|
-
"relative z-10 flex max-w-max flex-1 items-center justify-center",
|
|
16
|
-
className
|
|
17
|
-
)}
|
|
18
|
-
{...props}
|
|
19
|
-
>
|
|
20
|
-
{children}
|
|
21
|
-
<NavigationMenuViewport />
|
|
22
|
-
</NavigationMenuPrimitive.Root>
|
|
23
|
-
))
|
|
24
|
-
NavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName
|
|
25
|
-
|
|
26
|
-
const NavigationMenuList = React.forwardRef<
|
|
27
|
-
React.ElementRef<typeof NavigationMenuPrimitive.List>,
|
|
28
|
-
React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>
|
|
29
|
-
>(({ className, ...props }, ref) => (
|
|
30
|
-
<NavigationMenuPrimitive.List
|
|
31
|
-
ref={ref}
|
|
32
|
-
className={cn(
|
|
33
|
-
"group flex flex-1 list-none items-center justify-center space-x-1",
|
|
34
|
-
className
|
|
35
|
-
)}
|
|
36
|
-
{...props}
|
|
37
|
-
/>
|
|
38
|
-
))
|
|
39
|
-
NavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName
|
|
40
|
-
|
|
41
|
-
const NavigationMenuItem = NavigationMenuPrimitive.Item
|
|
42
|
-
|
|
43
|
-
const navigationMenuTriggerStyle = cva(
|
|
44
|
-
"group inline-flex h-9 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=open]:text-accent-foreground data-[state=open]:bg-accent/50 data-[state=open]:hover:bg-accent data-[state=open]:focus:bg-accent"
|
|
45
|
-
)
|
|
46
|
-
|
|
47
|
-
const NavigationMenuTrigger = React.forwardRef<
|
|
48
|
-
React.ElementRef<typeof NavigationMenuPrimitive.Trigger>,
|
|
49
|
-
React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>
|
|
50
|
-
>(({ className, children, ...props }, ref) => (
|
|
51
|
-
<NavigationMenuPrimitive.Trigger
|
|
52
|
-
ref={ref}
|
|
53
|
-
className={cn(navigationMenuTriggerStyle(), "group", className)}
|
|
54
|
-
{...props}
|
|
55
|
-
>
|
|
56
|
-
{children}{" "}
|
|
57
|
-
<ChevronDown
|
|
58
|
-
className="relative top-[1px] ml-1 h-3 w-3 transition duration-300 group-data-[state=open]:rotate-180"
|
|
59
|
-
aria-hidden="true"
|
|
60
|
-
/>
|
|
61
|
-
</NavigationMenuPrimitive.Trigger>
|
|
62
|
-
))
|
|
63
|
-
NavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName
|
|
64
|
-
|
|
65
|
-
const NavigationMenuContent = React.forwardRef<
|
|
66
|
-
React.ElementRef<typeof NavigationMenuPrimitive.Content>,
|
|
67
|
-
React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>
|
|
68
|
-
>(({ className, ...props }, ref) => (
|
|
69
|
-
<NavigationMenuPrimitive.Content
|
|
70
|
-
ref={ref}
|
|
71
|
-
className={cn(
|
|
72
|
-
"left-0 top-0 w-full data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 md:absolute md:w-auto ",
|
|
73
|
-
className
|
|
74
|
-
)}
|
|
75
|
-
{...props}
|
|
76
|
-
/>
|
|
77
|
-
))
|
|
78
|
-
NavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName
|
|
79
|
-
|
|
80
|
-
const NavigationMenuLink = NavigationMenuPrimitive.Link
|
|
81
|
-
|
|
82
|
-
const NavigationMenuViewport = React.forwardRef<
|
|
83
|
-
React.ElementRef<typeof NavigationMenuPrimitive.Viewport>,
|
|
84
|
-
React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>
|
|
85
|
-
>(({ className, ...props }, ref) => (
|
|
86
|
-
<div className={cn("absolute left-0 top-full flex justify-center")}>
|
|
87
|
-
<NavigationMenuPrimitive.Viewport
|
|
88
|
-
className={cn(
|
|
89
|
-
"origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]",
|
|
90
|
-
className
|
|
91
|
-
)}
|
|
92
|
-
ref={ref}
|
|
93
|
-
{...props}
|
|
94
|
-
/>
|
|
95
|
-
</div>
|
|
96
|
-
))
|
|
97
|
-
NavigationMenuViewport.displayName =
|
|
98
|
-
NavigationMenuPrimitive.Viewport.displayName
|
|
99
|
-
|
|
100
|
-
const NavigationMenuIndicator = React.forwardRef<
|
|
101
|
-
React.ElementRef<typeof NavigationMenuPrimitive.Indicator>,
|
|
102
|
-
React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>
|
|
103
|
-
>(({ className, ...props }, ref) => (
|
|
104
|
-
<NavigationMenuPrimitive.Indicator
|
|
105
|
-
ref={ref}
|
|
106
|
-
className={cn(
|
|
107
|
-
"top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in",
|
|
108
|
-
className
|
|
109
|
-
)}
|
|
110
|
-
{...props}
|
|
111
|
-
>
|
|
112
|
-
<div className="relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md" />
|
|
113
|
-
</NavigationMenuPrimitive.Indicator>
|
|
114
|
-
))
|
|
115
|
-
NavigationMenuIndicator.displayName =
|
|
116
|
-
NavigationMenuPrimitive.Indicator.displayName
|
|
117
|
-
|
|
118
|
-
export {
|
|
119
|
-
navigationMenuTriggerStyle,
|
|
120
|
-
NavigationMenu,
|
|
121
|
-
NavigationMenuList,
|
|
122
|
-
NavigationMenuItem,
|
|
123
|
-
NavigationMenuContent,
|
|
124
|
-
NavigationMenuTrigger,
|
|
125
|
-
NavigationMenuLink,
|
|
126
|
-
NavigationMenuIndicator,
|
|
127
|
-
NavigationMenuViewport,
|
|
128
|
-
}
|
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import { ChevronLeft, ChevronRight, MoreHorizontal } from "lucide-react"
|
|
3
|
-
|
|
4
|
-
import { cn } from "@/lib/utils"
|
|
5
|
-
import { ButtonProps, buttonVariants } from "@/components/ui/button"
|
|
6
|
-
|
|
7
|
-
const Pagination = ({ className, ...props }: React.ComponentProps<"nav">) => (
|
|
8
|
-
<nav
|
|
9
|
-
role="navigation"
|
|
10
|
-
aria-label="pagination"
|
|
11
|
-
className={cn("mx-auto flex w-full justify-center", className)}
|
|
12
|
-
{...props}
|
|
13
|
-
/>
|
|
14
|
-
)
|
|
15
|
-
Pagination.displayName = "Pagination"
|
|
16
|
-
|
|
17
|
-
const PaginationContent = React.forwardRef<
|
|
18
|
-
HTMLUListElement,
|
|
19
|
-
React.ComponentProps<"ul">
|
|
20
|
-
>(({ className, ...props }, ref) => (
|
|
21
|
-
<ul
|
|
22
|
-
ref={ref}
|
|
23
|
-
className={cn("flex flex-row items-center gap-1", className)}
|
|
24
|
-
{...props}
|
|
25
|
-
/>
|
|
26
|
-
))
|
|
27
|
-
PaginationContent.displayName = "PaginationContent"
|
|
28
|
-
|
|
29
|
-
const PaginationItem = React.forwardRef<
|
|
30
|
-
HTMLLIElement,
|
|
31
|
-
React.ComponentProps<"li">
|
|
32
|
-
>(({ className, ...props }, ref) => (
|
|
33
|
-
<li ref={ref} className={cn("", className)} {...props} />
|
|
34
|
-
))
|
|
35
|
-
PaginationItem.displayName = "PaginationItem"
|
|
36
|
-
|
|
37
|
-
type PaginationLinkProps = {
|
|
38
|
-
isActive?: boolean
|
|
39
|
-
} & Pick<ButtonProps, "size"> &
|
|
40
|
-
React.ComponentProps<"a">
|
|
41
|
-
|
|
42
|
-
const PaginationLink = ({
|
|
43
|
-
className,
|
|
44
|
-
isActive,
|
|
45
|
-
size = "icon",
|
|
46
|
-
...props
|
|
47
|
-
}: PaginationLinkProps) => (
|
|
48
|
-
<a
|
|
49
|
-
aria-current={isActive ? "page" : undefined}
|
|
50
|
-
className={cn(
|
|
51
|
-
buttonVariants({
|
|
52
|
-
variant: isActive ? "outline" : "ghost",
|
|
53
|
-
size,
|
|
54
|
-
}),
|
|
55
|
-
className
|
|
56
|
-
)}
|
|
57
|
-
{...props}
|
|
58
|
-
/>
|
|
59
|
-
)
|
|
60
|
-
PaginationLink.displayName = "PaginationLink"
|
|
61
|
-
|
|
62
|
-
const PaginationPrevious = ({
|
|
63
|
-
className,
|
|
64
|
-
...props
|
|
65
|
-
}: React.ComponentProps<typeof PaginationLink>) => (
|
|
66
|
-
<PaginationLink
|
|
67
|
-
aria-label="Go to previous page"
|
|
68
|
-
size="default"
|
|
69
|
-
className={cn("gap-1 pl-2.5", className)}
|
|
70
|
-
{...props}
|
|
71
|
-
>
|
|
72
|
-
<ChevronLeft className="h-4 w-4" />
|
|
73
|
-
<span>Previous</span>
|
|
74
|
-
</PaginationLink>
|
|
75
|
-
)
|
|
76
|
-
PaginationPrevious.displayName = "PaginationPrevious"
|
|
77
|
-
|
|
78
|
-
const PaginationNext = ({
|
|
79
|
-
className,
|
|
80
|
-
...props
|
|
81
|
-
}: React.ComponentProps<typeof PaginationLink>) => (
|
|
82
|
-
<PaginationLink
|
|
83
|
-
aria-label="Go to next page"
|
|
84
|
-
size="default"
|
|
85
|
-
className={cn("gap-1 pr-2.5", className)}
|
|
86
|
-
{...props}
|
|
87
|
-
>
|
|
88
|
-
<span>Next</span>
|
|
89
|
-
<ChevronRight className="h-4 w-4" />
|
|
90
|
-
</PaginationLink>
|
|
91
|
-
)
|
|
92
|
-
PaginationNext.displayName = "PaginationNext"
|
|
93
|
-
|
|
94
|
-
const PaginationEllipsis = ({
|
|
95
|
-
className,
|
|
96
|
-
...props
|
|
97
|
-
}: React.ComponentProps<"span">) => (
|
|
98
|
-
<span
|
|
99
|
-
aria-hidden
|
|
100
|
-
className={cn("flex h-9 w-9 items-center justify-center", className)}
|
|
101
|
-
{...props}
|
|
102
|
-
>
|
|
103
|
-
<MoreHorizontal className="h-4 w-4" />
|
|
104
|
-
<span className="sr-only">More pages</span>
|
|
105
|
-
</span>
|
|
106
|
-
)
|
|
107
|
-
PaginationEllipsis.displayName = "PaginationEllipsis"
|
|
108
|
-
|
|
109
|
-
export {
|
|
110
|
-
Pagination,
|
|
111
|
-
PaginationContent,
|
|
112
|
-
PaginationLink,
|
|
113
|
-
PaginationItem,
|
|
114
|
-
PaginationPrevious,
|
|
115
|
-
PaginationNext,
|
|
116
|
-
PaginationEllipsis,
|
|
117
|
-
}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import * as PopoverPrimitive from "@radix-ui/react-popover"
|
|
3
|
-
|
|
4
|
-
import { cn } from "@/lib/utils"
|
|
5
|
-
|
|
6
|
-
const Popover = PopoverPrimitive.Root
|
|
7
|
-
|
|
8
|
-
const PopoverTrigger = PopoverPrimitive.Trigger
|
|
9
|
-
|
|
10
|
-
const PopoverAnchor = PopoverPrimitive.Anchor
|
|
11
|
-
|
|
12
|
-
const PopoverContent = React.forwardRef<
|
|
13
|
-
React.ElementRef<typeof PopoverPrimitive.Content>,
|
|
14
|
-
React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>
|
|
15
|
-
>(({ className, align = "center", sideOffset = 4, ...props }, ref) => (
|
|
16
|
-
<PopoverPrimitive.Portal>
|
|
17
|
-
<PopoverPrimitive.Content
|
|
18
|
-
ref={ref}
|
|
19
|
-
align={align}
|
|
20
|
-
sideOffset={sideOffset}
|
|
21
|
-
className={cn(
|
|
22
|
-
"z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none 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 origin-[--radix-popover-content-transform-origin]",
|
|
23
|
-
className
|
|
24
|
-
)}
|
|
25
|
-
{...props}
|
|
26
|
-
/>
|
|
27
|
-
</PopoverPrimitive.Portal>
|
|
28
|
-
))
|
|
29
|
-
PopoverContent.displayName = PopoverPrimitive.Content.displayName
|
|
30
|
-
|
|
31
|
-
export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor }
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import * as ProgressPrimitive from "@radix-ui/react-progress"
|
|
3
|
-
|
|
4
|
-
import { cn } from "@/lib/utils"
|
|
5
|
-
|
|
6
|
-
const Progress = React.forwardRef<
|
|
7
|
-
React.ElementRef<typeof ProgressPrimitive.Root>,
|
|
8
|
-
React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root>
|
|
9
|
-
>(({ className, value, ...props }, ref) => (
|
|
10
|
-
<ProgressPrimitive.Root
|
|
11
|
-
ref={ref}
|
|
12
|
-
className={cn(
|
|
13
|
-
"relative h-2 w-full overflow-hidden rounded-full bg-primary/20",
|
|
14
|
-
className
|
|
15
|
-
)}
|
|
16
|
-
{...props}
|
|
17
|
-
>
|
|
18
|
-
<ProgressPrimitive.Indicator
|
|
19
|
-
className="h-full w-full flex-1 bg-primary transition-all"
|
|
20
|
-
style={{ transform: `translateX(-${100 - (value || 0)}%)` }}
|
|
21
|
-
/>
|
|
22
|
-
</ProgressPrimitive.Root>
|
|
23
|
-
))
|
|
24
|
-
Progress.displayName = ProgressPrimitive.Root.displayName
|
|
25
|
-
|
|
26
|
-
export { Progress }
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group"
|
|
3
|
-
import { Circle } from "lucide-react"
|
|
4
|
-
|
|
5
|
-
import { cn } from "@/lib/utils"
|
|
6
|
-
|
|
7
|
-
const RadioGroup = React.forwardRef<
|
|
8
|
-
React.ElementRef<typeof RadioGroupPrimitive.Root>,
|
|
9
|
-
React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>
|
|
10
|
-
>(({ className, ...props }, ref) => {
|
|
11
|
-
return (
|
|
12
|
-
<RadioGroupPrimitive.Root
|
|
13
|
-
className={cn("grid gap-2", className)}
|
|
14
|
-
{...props}
|
|
15
|
-
ref={ref}
|
|
16
|
-
/>
|
|
17
|
-
)
|
|
18
|
-
})
|
|
19
|
-
RadioGroup.displayName = RadioGroupPrimitive.Root.displayName
|
|
20
|
-
|
|
21
|
-
const RadioGroupItem = React.forwardRef<
|
|
22
|
-
React.ElementRef<typeof RadioGroupPrimitive.Item>,
|
|
23
|
-
React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>
|
|
24
|
-
>(({ className, ...props }, ref) => {
|
|
25
|
-
return (
|
|
26
|
-
<RadioGroupPrimitive.Item
|
|
27
|
-
ref={ref}
|
|
28
|
-
className={cn(
|
|
29
|
-
"aspect-square h-4 w-4 rounded-full border border-primary text-primary shadow focus:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
|
|
30
|
-
className
|
|
31
|
-
)}
|
|
32
|
-
{...props}
|
|
33
|
-
>
|
|
34
|
-
<RadioGroupPrimitive.Indicator className="flex items-center justify-center">
|
|
35
|
-
<Circle className="h-3.5 w-3.5 fill-primary" />
|
|
36
|
-
</RadioGroupPrimitive.Indicator>
|
|
37
|
-
</RadioGroupPrimitive.Item>
|
|
38
|
-
)
|
|
39
|
-
})
|
|
40
|
-
RadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName
|
|
41
|
-
|
|
42
|
-
export { RadioGroup, RadioGroupItem }
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { GripVertical } from "lucide-react"
|
|
2
|
-
import * as ResizablePrimitive from "react-resizable-panels"
|
|
3
|
-
|
|
4
|
-
import { cn } from "@/lib/utils"
|
|
5
|
-
|
|
6
|
-
const ResizablePanelGroup = ({
|
|
7
|
-
className,
|
|
8
|
-
...props
|
|
9
|
-
}: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => (
|
|
10
|
-
<ResizablePrimitive.PanelGroup
|
|
11
|
-
className={cn(
|
|
12
|
-
"flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
|
|
13
|
-
className
|
|
14
|
-
)}
|
|
15
|
-
{...props}
|
|
16
|
-
/>
|
|
17
|
-
)
|
|
18
|
-
|
|
19
|
-
const ResizablePanel = ResizablePrimitive.Panel
|
|
20
|
-
|
|
21
|
-
const ResizableHandle = ({
|
|
22
|
-
withHandle,
|
|
23
|
-
className,
|
|
24
|
-
...props
|
|
25
|
-
}: React.ComponentProps<typeof ResizablePrimitive.PanelResizeHandle> & {
|
|
26
|
-
withHandle?: boolean
|
|
27
|
-
}) => (
|
|
28
|
-
<ResizablePrimitive.PanelResizeHandle
|
|
29
|
-
className={cn(
|
|
30
|
-
"relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",
|
|
31
|
-
className
|
|
32
|
-
)}
|
|
33
|
-
{...props}
|
|
34
|
-
>
|
|
35
|
-
{withHandle && (
|
|
36
|
-
<div className="z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border">
|
|
37
|
-
<GripVertical className="h-2.5 w-2.5" />
|
|
38
|
-
</div>
|
|
39
|
-
)}
|
|
40
|
-
</ResizablePrimitive.PanelResizeHandle>
|
|
41
|
-
)
|
|
42
|
-
|
|
43
|
-
export { ResizablePanelGroup, ResizablePanel, ResizableHandle }
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area"
|
|
3
|
-
|
|
4
|
-
import { cn } from "@/lib/utils"
|
|
5
|
-
|
|
6
|
-
const ScrollArea = React.forwardRef<
|
|
7
|
-
React.ElementRef<typeof ScrollAreaPrimitive.Root>,
|
|
8
|
-
React.ComponentPropsWithoutRef<typeof ScrollAreaPrimitive.Root>
|
|
9
|
-
>(({ className, children, ...props }, ref) => (
|
|
10
|
-
<ScrollAreaPrimitive.Root
|
|
11
|
-
ref={ref}
|
|
12
|
-
className={cn("relative overflow-hidden", className)}
|
|
13
|
-
{...props}
|
|
14
|
-
>
|
|
15
|
-
<ScrollAreaPrimitive.Viewport className="h-full w-full rounded-[inherit]">
|
|
16
|
-
{children}
|
|
17
|
-
</ScrollAreaPrimitive.Viewport>
|
|
18
|
-
<ScrollBar />
|
|
19
|
-
<ScrollAreaPrimitive.Corner />
|
|
20
|
-
</ScrollAreaPrimitive.Root>
|
|
21
|
-
))
|
|
22
|
-
ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName
|
|
23
|
-
|
|
24
|
-
const ScrollBar = React.forwardRef<
|
|
25
|
-
React.ElementRef<typeof ScrollAreaPrimitive.ScrollAreaScrollbar>,
|
|
26
|
-
React.ComponentPropsWithoutRef<typeof ScrollAreaPrimitive.ScrollAreaScrollbar>
|
|
27
|
-
>(({ className, orientation = "vertical", ...props }, ref) => (
|
|
28
|
-
<ScrollAreaPrimitive.ScrollAreaScrollbar
|
|
29
|
-
ref={ref}
|
|
30
|
-
orientation={orientation}
|
|
31
|
-
className={cn(
|
|
32
|
-
"flex touch-none select-none transition-colors",
|
|
33
|
-
orientation === "vertical" &&
|
|
34
|
-
"h-full w-2.5 border-l border-l-transparent p-[1px]",
|
|
35
|
-
orientation === "horizontal" &&
|
|
36
|
-
"h-2.5 flex-col border-t border-t-transparent p-[1px]",
|
|
37
|
-
className
|
|
38
|
-
)}
|
|
39
|
-
{...props}
|
|
40
|
-
>
|
|
41
|
-
<ScrollAreaPrimitive.ScrollAreaThumb className="relative flex-1 rounded-full bg-border" />
|
|
42
|
-
</ScrollAreaPrimitive.ScrollAreaScrollbar>
|
|
43
|
-
))
|
|
44
|
-
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName
|
|
45
|
-
|
|
46
|
-
export { ScrollArea, ScrollBar }
|