shadcn-packaged 0.0.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.
Files changed (106) hide show
  1. package/README.md +50 -0
  2. package/hooks/use-mobile.d.ts +1 -0
  3. package/hooks/use-mobile.jsx +15 -0
  4. package/hooks/use-toast.d.ts +44 -0
  5. package/hooks/use-toast.js +128 -0
  6. package/index.d.ts +51 -0
  7. package/lib/utils.d.ts +2 -0
  8. package/lib/utils.js +5 -0
  9. package/package.json +76 -0
  10. package/tailwind.config.js +89 -0
  11. package/ui/accordion.d.ts +7 -0
  12. package/ui/accordion.jsx +20 -0
  13. package/ui/alert-dialog.d.ts +20 -0
  14. package/ui/alert-dialog.jsx +29 -0
  15. package/ui/alert.d.ts +8 -0
  16. package/ui/alert.jsx +21 -0
  17. package/ui/aspect-ratio.d.ts +3 -0
  18. package/ui/aspect-ratio.jsx +4 -0
  19. package/ui/avatar.d.ts +6 -0
  20. package/ui/avatar.jsx +11 -0
  21. package/ui/badge.d.ts +9 -0
  22. package/ui/badge.jsx +20 -0
  23. package/ui/breadcrumb.d.ts +19 -0
  24. package/ui/breadcrumb.jsx +27 -0
  25. package/ui/button.d.ts +11 -0
  26. package/ui/button.jsx +32 -0
  27. package/ui/calendar.d.ts +8 -0
  28. package/ui/calendar.jsx +37 -0
  29. package/ui/card.d.ts +8 -0
  30. package/ui/card.jsx +15 -0
  31. package/ui/carousel.d.ts +18 -0
  32. package/ui/carousel.jsx +110 -0
  33. package/ui/chart.d.ts +62 -0
  34. package/ui/chart.jsx +164 -0
  35. package/ui/checkbox.d.ts +4 -0
  36. package/ui/checkbox.jsx +12 -0
  37. package/ui/collapsible.d.ts +5 -0
  38. package/ui/collapsible.jsx +6 -0
  39. package/ui/command.d.ts +80 -0
  40. package/ui/command.jsx +37 -0
  41. package/ui/context-menu.d.ts +27 -0
  42. package/ui/context-menu.jsx +52 -0
  43. package/ui/dialog.d.ts +19 -0
  44. package/ui/dialog.jsx +31 -0
  45. package/ui/drawer.d.ts +22 -0
  46. package/ui/drawer.jsx +28 -0
  47. package/ui/dropdown-menu.d.ts +27 -0
  48. package/ui/dropdown-menu.jsx +54 -0
  49. package/ui/form.d.ts +23 -0
  50. package/ui/form.jsx +68 -0
  51. package/ui/hover-card.d.ts +6 -0
  52. package/ui/hover-card.jsx +9 -0
  53. package/ui/input-otp.d.ts +34 -0
  54. package/ui/input-otp.jsx +25 -0
  55. package/ui/input.d.ts +3 -0
  56. package/ui/input.jsx +7 -0
  57. package/ui/label.d.ts +5 -0
  58. package/ui/label.jsx +9 -0
  59. package/ui/menubar.d.ts +33 -0
  60. package/ui/menubar.jsx +54 -0
  61. package/ui/navigation-menu.d.ts +12 -0
  62. package/ui/navigation-menu.jsx +33 -0
  63. package/ui/pagination.d.ts +28 -0
  64. package/ui/pagination.jsx +31 -0
  65. package/ui/popover.d.ts +6 -0
  66. package/ui/popover.jsx +11 -0
  67. package/ui/progress.d.ts +4 -0
  68. package/ui/progress.jsx +9 -0
  69. package/ui/radio-group.d.ts +5 -0
  70. package/ui/radio-group.jsx +18 -0
  71. package/ui/resizable.d.ts +23 -0
  72. package/ui/resizable.jsx +12 -0
  73. package/ui/scroll-area.d.ts +5 -0
  74. package/ui/scroll-area.jsx +19 -0
  75. package/ui/select.d.ts +13 -0
  76. package/ui/select.jsx +51 -0
  77. package/ui/separator.d.ts +4 -0
  78. package/ui/separator.jsx +7 -0
  79. package/ui/sheet.d.ts +25 -0
  80. package/ui/sheet.jsx +45 -0
  81. package/ui/sidebar.d.ts +66 -0
  82. package/ui/sidebar.jsx +253 -0
  83. package/ui/skeleton.d.ts +2 -0
  84. package/ui/skeleton.jsx +5 -0
  85. package/ui/slider.d.ts +4 -0
  86. package/ui/slider.jsx +12 -0
  87. package/ui/sonner.d.ts +4 -0
  88. package/ui/sonner.jsx +15 -0
  89. package/ui/switch.d.ts +4 -0
  90. package/ui/switch.jsx +9 -0
  91. package/ui/table.d.ts +10 -0
  92. package/ui/table.jsx +21 -0
  93. package/ui/tabs.d.ts +7 -0
  94. package/ui/tabs.jsx +12 -0
  95. package/ui/textarea.d.ts +3 -0
  96. package/ui/textarea.jsx +7 -0
  97. package/ui/toast.d.ts +15 -0
  98. package/ui/toast.jsx +35 -0
  99. package/ui/toaster.d.ts +1 -0
  100. package/ui/toaster.jsx +19 -0
  101. package/ui/toggle-group.d.ts +12 -0
  102. package/ui/toggle-group.jsx +26 -0
  103. package/ui/toggle.d.ts +12 -0
  104. package/ui/toggle.jsx +25 -0
  105. package/ui/tooltip.d.ts +7 -0
  106. package/ui/tooltip.jsx +10 -0
@@ -0,0 +1,33 @@
1
+ import * as React from "react";
2
+ import * as MenubarPrimitive from "@radix-ui/react-menubar";
3
+ declare const MenubarMenu: {
4
+ (props: MenubarPrimitive.MenubarMenuProps & {
5
+ __scopeMenubar?: import("@radix-ui/react-context").Scope;
6
+ }): import("react/jsx-runtime").JSX.Element;
7
+ displayName: string;
8
+ };
9
+ declare const MenubarGroup: React.ForwardRefExoticComponent<MenubarPrimitive.MenubarGroupProps & React.RefAttributes<HTMLDivElement>>;
10
+ declare const MenubarPortal: React.FC<MenubarPrimitive.MenubarPortalProps>;
11
+ declare const MenubarSub: React.FC<MenubarPrimitive.MenubarSubProps>;
12
+ declare const MenubarRadioGroup: React.ForwardRefExoticComponent<MenubarPrimitive.MenubarRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
13
+ declare const Menubar: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
14
+ declare const MenubarTrigger: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
15
+ declare const MenubarSubTrigger: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
16
+ inset?: boolean;
17
+ } & React.RefAttributes<HTMLDivElement>>;
18
+ declare const MenubarSubContent: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
19
+ declare const MenubarContent: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
20
+ declare const MenubarItem: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
21
+ inset?: boolean;
22
+ } & React.RefAttributes<HTMLDivElement>>;
23
+ declare const MenubarCheckboxItem: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
24
+ declare const MenubarRadioItem: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
25
+ declare const MenubarLabel: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
26
+ inset?: boolean;
27
+ } & React.RefAttributes<HTMLDivElement>>;
28
+ declare const MenubarSeparator: React.ForwardRefExoticComponent<Omit<MenubarPrimitive.MenubarSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
29
+ declare const MenubarShortcut: {
30
+ ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>): React.JSX.Element;
31
+ displayname: string;
32
+ };
33
+ export { Menubar, MenubarMenu, MenubarTrigger, MenubarContent, MenubarItem, MenubarSeparator, MenubarLabel, MenubarCheckboxItem, MenubarRadioGroup, MenubarRadioItem, MenubarPortal, MenubarSubContent, MenubarSubTrigger, MenubarGroup, MenubarSub, MenubarShortcut, };
package/ui/menubar.jsx ADDED
@@ -0,0 +1,54 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as MenubarPrimitive from "@radix-ui/react-menubar";
4
+ import { Check, ChevronRight, Circle } from "lucide-react";
5
+ import { cn } from "../lib/utils";
6
+ const MenubarMenu = MenubarPrimitive.Menu;
7
+ const MenubarGroup = MenubarPrimitive.Group;
8
+ const MenubarPortal = MenubarPrimitive.Portal;
9
+ const MenubarSub = MenubarPrimitive.Sub;
10
+ const MenubarRadioGroup = MenubarPrimitive.RadioGroup;
11
+ const Menubar = React.forwardRef(({ className, ...props }, ref) => (<MenubarPrimitive.Root ref={ref} className={cn("flex h-10 items-center space-x-1 rounded-md border bg-background p-1", className)} {...props}/>));
12
+ Menubar.displayName = MenubarPrimitive.Root.displayName;
13
+ const MenubarTrigger = React.forwardRef(({ className, ...props }, ref) => (<MenubarPrimitive.Trigger ref={ref} className={cn("flex cursor-default select-none items-center rounded-sm px-3 py-1.5 text-sm font-medium outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground", className)} {...props}/>));
14
+ MenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName;
15
+ const MenubarSubTrigger = React.forwardRef(({ className, inset, children, ...props }, ref) => (<MenubarPrimitive.SubTrigger ref={ref} className={cn("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", inset && "pl-8", className)} {...props}>
16
+ {children}
17
+ <ChevronRight className="ml-auto h-4 w-4"/>
18
+ </MenubarPrimitive.SubTrigger>));
19
+ MenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;
20
+ const MenubarSubContent = React.forwardRef(({ className, ...props }, ref) => (<MenubarPrimitive.SubContent ref={ref} className={cn("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 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", className)} {...props}/>));
21
+ MenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;
22
+ const MenubarContent = React.forwardRef(({ className, align = "start", alignOffset = -4, sideOffset = 8, ...props }, ref) => (<MenubarPrimitive.Portal>
23
+ <MenubarPrimitive.Content ref={ref} align={align} alignOffset={alignOffset} sideOffset={sideOffset} className={cn("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", className)} {...props}/>
24
+ </MenubarPrimitive.Portal>));
25
+ MenubarContent.displayName = MenubarPrimitive.Content.displayName;
26
+ const MenubarItem = React.forwardRef(({ className, inset, ...props }, ref) => (<MenubarPrimitive.Item ref={ref} className={cn("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", inset && "pl-8", className)} {...props}/>));
27
+ MenubarItem.displayName = MenubarPrimitive.Item.displayName;
28
+ const MenubarCheckboxItem = React.forwardRef(({ className, children, checked, ...props }, ref) => (<MenubarPrimitive.CheckboxItem ref={ref} className={cn("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", className)} checked={checked} {...props}>
29
+ <span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
30
+ <MenubarPrimitive.ItemIndicator>
31
+ <Check className="h-4 w-4"/>
32
+ </MenubarPrimitive.ItemIndicator>
33
+ </span>
34
+ {children}
35
+ </MenubarPrimitive.CheckboxItem>));
36
+ MenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;
37
+ const MenubarRadioItem = React.forwardRef(({ className, children, ...props }, ref) => (<MenubarPrimitive.RadioItem ref={ref} className={cn("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", className)} {...props}>
38
+ <span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
39
+ <MenubarPrimitive.ItemIndicator>
40
+ <Circle className="h-2 w-2 fill-current"/>
41
+ </MenubarPrimitive.ItemIndicator>
42
+ </span>
43
+ {children}
44
+ </MenubarPrimitive.RadioItem>));
45
+ MenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;
46
+ const MenubarLabel = React.forwardRef(({ className, inset, ...props }, ref) => (<MenubarPrimitive.Label ref={ref} className={cn("px-2 py-1.5 text-sm font-semibold", inset && "pl-8", className)} {...props}/>));
47
+ MenubarLabel.displayName = MenubarPrimitive.Label.displayName;
48
+ const MenubarSeparator = React.forwardRef(({ className, ...props }, ref) => (<MenubarPrimitive.Separator ref={ref} className={cn("-mx-1 my-1 h-px bg-muted", className)} {...props}/>));
49
+ MenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;
50
+ const MenubarShortcut = ({ className, ...props }) => {
51
+ return (<span className={cn("ml-auto text-xs tracking-widest text-muted-foreground", className)} {...props}/>);
52
+ };
53
+ MenubarShortcut.displayname = "MenubarShortcut";
54
+ export { Menubar, MenubarMenu, MenubarTrigger, MenubarContent, MenubarItem, MenubarSeparator, MenubarLabel, MenubarCheckboxItem, MenubarRadioGroup, MenubarRadioItem, MenubarPortal, MenubarSubContent, MenubarSubTrigger, MenubarGroup, MenubarSub, MenubarShortcut, };
@@ -0,0 +1,12 @@
1
+ import * as React from "react";
2
+ import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
3
+ declare const NavigationMenu: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuProps & React.RefAttributes<HTMLElement>, "ref"> & React.RefAttributes<HTMLElement>>;
4
+ declare const NavigationMenuList: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuListProps & React.RefAttributes<HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
5
+ declare const NavigationMenuItem: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuItemProps & React.RefAttributes<HTMLLIElement>>;
6
+ declare const navigationMenuTriggerStyle: (props?: import("class-variance-authority/dist/types").ClassProp) => string;
7
+ declare const NavigationMenuTrigger: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
8
+ declare const NavigationMenuContent: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const NavigationMenuLink: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuLinkProps & React.RefAttributes<HTMLAnchorElement>>;
10
+ declare const NavigationMenuViewport: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuViewportProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const NavigationMenuIndicator: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuIndicatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ export { navigationMenuTriggerStyle, NavigationMenu, NavigationMenuList, NavigationMenuItem, NavigationMenuContent, NavigationMenuTrigger, NavigationMenuLink, NavigationMenuIndicator, NavigationMenuViewport, };
@@ -0,0 +1,33 @@
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
+ import { cn } from "../lib/utils";
6
+ const NavigationMenu = React.forwardRef(({ className, children, ...props }, ref) => (<NavigationMenuPrimitive.Root ref={ref} className={cn("relative z-10 flex max-w-max flex-1 items-center justify-center", className)} {...props}>
7
+ {children}
8
+ <NavigationMenuViewport />
9
+ </NavigationMenuPrimitive.Root>));
10
+ NavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;
11
+ const NavigationMenuList = React.forwardRef(({ className, ...props }, ref) => (<NavigationMenuPrimitive.List ref={ref} className={cn("group flex flex-1 list-none items-center justify-center space-x-1", className)} {...props}/>));
12
+ NavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;
13
+ const NavigationMenuItem = NavigationMenuPrimitive.Item;
14
+ const navigationMenuTriggerStyle = cva("group inline-flex h-10 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-[active]:bg-accent/50 data-[state=open]:bg-accent/50");
15
+ const NavigationMenuTrigger = React.forwardRef(({ className, children, ...props }, ref) => (<NavigationMenuPrimitive.Trigger ref={ref} className={cn(navigationMenuTriggerStyle(), "group", className)} {...props}>
16
+ {children}{" "}
17
+ <ChevronDown className="relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180" aria-hidden="true"/>
18
+ </NavigationMenuPrimitive.Trigger>));
19
+ NavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;
20
+ const NavigationMenuContent = React.forwardRef(({ className, ...props }, ref) => (<NavigationMenuPrimitive.Content ref={ref} className={cn("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 ", className)} {...props}/>));
21
+ NavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;
22
+ const NavigationMenuLink = NavigationMenuPrimitive.Link;
23
+ const NavigationMenuViewport = React.forwardRef(({ className, ...props }, ref) => (<div className={cn("absolute left-0 top-full flex justify-center")}>
24
+ <NavigationMenuPrimitive.Viewport className={cn("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-lg 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)]", className)} ref={ref} {...props}/>
25
+ </div>));
26
+ NavigationMenuViewport.displayName =
27
+ NavigationMenuPrimitive.Viewport.displayName;
28
+ const NavigationMenuIndicator = React.forwardRef(({ className, ...props }, ref) => (<NavigationMenuPrimitive.Indicator ref={ref} className={cn("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", className)} {...props}>
29
+ <div className="relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"/>
30
+ </NavigationMenuPrimitive.Indicator>));
31
+ NavigationMenuIndicator.displayName =
32
+ NavigationMenuPrimitive.Indicator.displayName;
33
+ export { navigationMenuTriggerStyle, NavigationMenu, NavigationMenuList, NavigationMenuItem, NavigationMenuContent, NavigationMenuTrigger, NavigationMenuLink, NavigationMenuIndicator, NavigationMenuViewport, };
@@ -0,0 +1,28 @@
1
+ import * as React from "react";
2
+ import { ButtonProps } from "../ui/button";
3
+ declare const Pagination: {
4
+ ({ className, ...props }: React.ComponentProps<"nav">): React.JSX.Element;
5
+ displayName: string;
6
+ };
7
+ declare const PaginationContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
8
+ declare const PaginationItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
9
+ type PaginationLinkProps = {
10
+ isActive?: boolean;
11
+ } & Pick<ButtonProps, "size"> & React.ComponentProps<"a">;
12
+ declare const PaginationLink: {
13
+ ({ className, isActive, size, ...props }: PaginationLinkProps): React.JSX.Element;
14
+ displayName: string;
15
+ };
16
+ declare const PaginationPrevious: {
17
+ ({ className, ...props }: React.ComponentProps<typeof PaginationLink>): React.JSX.Element;
18
+ displayName: string;
19
+ };
20
+ declare const PaginationNext: {
21
+ ({ className, ...props }: React.ComponentProps<typeof PaginationLink>): React.JSX.Element;
22
+ displayName: string;
23
+ };
24
+ declare const PaginationEllipsis: {
25
+ ({ className, ...props }: React.ComponentProps<"span">): React.JSX.Element;
26
+ displayName: string;
27
+ };
28
+ export { Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, };
@@ -0,0 +1,31 @@
1
+ import * as React from "react";
2
+ import { ChevronLeft, ChevronRight, MoreHorizontal } from "lucide-react";
3
+ import { cn } from "../lib/utils";
4
+ import { buttonVariants } from "../ui/button";
5
+ const Pagination = ({ className, ...props }) => (<nav role="navigation" aria-label="pagination" className={cn("mx-auto flex w-full justify-center", className)} {...props}/>);
6
+ Pagination.displayName = "Pagination";
7
+ const PaginationContent = React.forwardRef(({ className, ...props }, ref) => (<ul ref={ref} className={cn("flex flex-row items-center gap-1", className)} {...props}/>));
8
+ PaginationContent.displayName = "PaginationContent";
9
+ const PaginationItem = React.forwardRef(({ className, ...props }, ref) => (<li ref={ref} className={cn("", className)} {...props}/>));
10
+ PaginationItem.displayName = "PaginationItem";
11
+ const PaginationLink = ({ className, isActive, size = "icon", ...props }) => (<a aria-current={isActive ? "page" : undefined} className={cn(buttonVariants({
12
+ variant: isActive ? "outline" : "ghost",
13
+ size,
14
+ }), className)} {...props}/>);
15
+ PaginationLink.displayName = "PaginationLink";
16
+ const PaginationPrevious = ({ className, ...props }) => (<PaginationLink aria-label="Go to previous page" size="default" className={cn("gap-1 pl-2.5", className)} {...props}>
17
+ <ChevronLeft className="h-4 w-4"/>
18
+ <span>Previous</span>
19
+ </PaginationLink>);
20
+ PaginationPrevious.displayName = "PaginationPrevious";
21
+ const PaginationNext = ({ className, ...props }) => (<PaginationLink aria-label="Go to next page" size="default" className={cn("gap-1 pr-2.5", className)} {...props}>
22
+ <span>Next</span>
23
+ <ChevronRight className="h-4 w-4"/>
24
+ </PaginationLink>);
25
+ PaginationNext.displayName = "PaginationNext";
26
+ const PaginationEllipsis = ({ className, ...props }) => (<span aria-hidden className={cn("flex h-9 w-9 items-center justify-center", className)} {...props}>
27
+ <MoreHorizontal className="h-4 w-4"/>
28
+ <span className="sr-only">More pages</span>
29
+ </span>);
30
+ PaginationEllipsis.displayName = "PaginationEllipsis";
31
+ export { Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, };
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ import * as PopoverPrimitive from "@radix-ui/react-popover";
3
+ declare const Popover: React.FC<PopoverPrimitive.PopoverProps>;
4
+ declare const PopoverTrigger: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React.RefAttributes<HTMLButtonElement>>;
5
+ declare const PopoverContent: React.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
6
+ export { Popover, PopoverTrigger, PopoverContent };
package/ui/popover.jsx ADDED
@@ -0,0 +1,11 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as PopoverPrimitive from "@radix-ui/react-popover";
4
+ import { cn } from "../lib/utils";
5
+ const Popover = PopoverPrimitive.Root;
6
+ const PopoverTrigger = PopoverPrimitive.Trigger;
7
+ const PopoverContent = React.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => (<PopoverPrimitive.Portal>
8
+ <PopoverPrimitive.Content ref={ref} align={align} sideOffset={sideOffset} className={cn("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", className)} {...props}/>
9
+ </PopoverPrimitive.Portal>));
10
+ PopoverContent.displayName = PopoverPrimitive.Content.displayName;
11
+ export { Popover, PopoverTrigger, PopoverContent };
@@ -0,0 +1,4 @@
1
+ import * as React from "react";
2
+ import * as ProgressPrimitive from "@radix-ui/react-progress";
3
+ declare const Progress: React.ForwardRefExoticComponent<Omit<ProgressPrimitive.ProgressProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
+ export { Progress };
@@ -0,0 +1,9 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as ProgressPrimitive from "@radix-ui/react-progress";
4
+ import { cn } from "../lib/utils";
5
+ const Progress = React.forwardRef(({ className, value, ...props }, ref) => (<ProgressPrimitive.Root ref={ref} className={cn("relative h-4 w-full overflow-hidden rounded-full bg-secondary", className)} {...props}>
6
+ <ProgressPrimitive.Indicator className="h-full w-full flex-1 bg-primary transition-all" style={{ transform: `translateX(-${100 - (value || 0)}%)` }}/>
7
+ </ProgressPrimitive.Root>));
8
+ Progress.displayName = ProgressPrimitive.Root.displayName;
9
+ export { Progress };
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
3
+ declare const RadioGroup: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
+ declare const RadioGroupItem: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
5
+ export { RadioGroup, RadioGroupItem };
@@ -0,0 +1,18 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
4
+ import { Circle } from "lucide-react";
5
+ import { cn } from "../lib/utils";
6
+ const RadioGroup = React.forwardRef(({ className, ...props }, ref) => {
7
+ return (<RadioGroupPrimitive.Root className={cn("grid gap-2", className)} {...props} ref={ref}/>);
8
+ });
9
+ RadioGroup.displayName = RadioGroupPrimitive.Root.displayName;
10
+ const RadioGroupItem = React.forwardRef(({ className, ...props }, ref) => {
11
+ return (<RadioGroupPrimitive.Item ref={ref} className={cn("aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50", className)} {...props}>
12
+ <RadioGroupPrimitive.Indicator className="flex items-center justify-center">
13
+ <Circle className="h-2.5 w-2.5 fill-current text-current"/>
14
+ </RadioGroupPrimitive.Indicator>
15
+ </RadioGroupPrimitive.Item>);
16
+ });
17
+ RadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;
18
+ export { RadioGroup, RadioGroupItem };
@@ -0,0 +1,23 @@
1
+ import * as ResizablePrimitive from "react-resizable-panels";
2
+ declare const ResizablePanelGroup: ({ className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => import("react").JSX.Element;
3
+ declare const ResizablePanel: import("react").ForwardRefExoticComponent<Omit<import("react").HTMLAttributes<HTMLElement | HTMLCanvasElement | HTMLImageElement | HTMLVideoElement | HTMLAnchorElement | HTMLScriptElement | HTMLEmbedElement | HTMLFormElement | HTMLHeadElement | HTMLAreaElement | HTMLObjectElement | HTMLLinkElement | HTMLMapElement | HTMLInputElement | HTMLBaseElement | HTMLTimeElement | HTMLDataElement | HTMLProgressElement | HTMLTrackElement | HTMLSourceElement | HTMLButtonElement | HTMLAudioElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLTableCaptionElement | HTMLTableColElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDivElement | HTMLDListElement | HTMLFieldSetElement | HTMLHeadingElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLabelElement | HTMLLegendElement | HTMLLIElement | HTMLMenuElement | HTMLMetaElement | HTMLMeterElement | HTMLOListElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLParagraphElement | HTMLPictureElement | HTMLPreElement | HTMLSelectElement | HTMLSlotElement | HTMLSpanElement | HTMLStyleElement | HTMLTableElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTemplateElement | HTMLTextAreaElement | HTMLTitleElement | HTMLTableRowElement | HTMLUListElement>, "id" | "onResize"> & {
4
+ className?: string | undefined;
5
+ collapsedSize?: number | undefined;
6
+ collapsible?: boolean | undefined;
7
+ defaultSize?: number | undefined;
8
+ id?: string | undefined;
9
+ maxSize?: number | undefined;
10
+ minSize?: number | undefined;
11
+ onCollapse?: ResizablePrimitive.PanelOnCollapse | undefined;
12
+ onExpand?: ResizablePrimitive.PanelOnExpand | undefined;
13
+ onResize?: ResizablePrimitive.PanelOnResize | undefined;
14
+ order?: number | undefined;
15
+ style?: object | undefined;
16
+ tagName?: keyof HTMLElementTagNameMap | undefined;
17
+ } & {
18
+ children?: import("react").ReactNode;
19
+ } & import("react").RefAttributes<ResizablePrimitive.ImperativePanelHandle>>;
20
+ declare const ResizableHandle: ({ withHandle, className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelResizeHandle> & {
21
+ withHandle?: boolean;
22
+ }) => import("react").JSX.Element;
23
+ export { ResizablePanelGroup, ResizablePanel, ResizableHandle };
@@ -0,0 +1,12 @@
1
+ "use client";
2
+ import { GripVertical } from "lucide-react";
3
+ import * as ResizablePrimitive from "react-resizable-panels";
4
+ import { cn } from "../lib/utils";
5
+ const ResizablePanelGroup = ({ className, ...props }) => (<ResizablePrimitive.PanelGroup className={cn("flex h-full w-full data-[panel-group-direction=vertical]:flex-col", className)} {...props}/>);
6
+ const ResizablePanel = ResizablePrimitive.Panel;
7
+ const ResizableHandle = ({ withHandle, className, ...props }) => (<ResizablePrimitive.PanelResizeHandle className={cn("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", className)} {...props}>
8
+ {withHandle && (<div className="z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border">
9
+ <GripVertical className="h-2.5 w-2.5"/>
10
+ </div>)}
11
+ </ResizablePrimitive.PanelResizeHandle>);
12
+ export { ResizablePanelGroup, ResizablePanel, ResizableHandle };
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
3
+ declare const ScrollArea: React.ForwardRefExoticComponent<Omit<ScrollAreaPrimitive.ScrollAreaProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
+ declare const ScrollBar: React.ForwardRefExoticComponent<Omit<ScrollAreaPrimitive.ScrollAreaScrollbarProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
5
+ export { ScrollArea, ScrollBar };
@@ -0,0 +1,19 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
4
+ import { cn } from "../lib/utils";
5
+ const ScrollArea = React.forwardRef(({ className, children, ...props }, ref) => (<ScrollAreaPrimitive.Root ref={ref} className={cn("relative overflow-hidden", className)} {...props}>
6
+ <ScrollAreaPrimitive.Viewport className="h-full w-full rounded-[inherit]">
7
+ {children}
8
+ </ScrollAreaPrimitive.Viewport>
9
+ <ScrollBar />
10
+ <ScrollAreaPrimitive.Corner />
11
+ </ScrollAreaPrimitive.Root>));
12
+ ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
13
+ const ScrollBar = React.forwardRef(({ className, orientation = "vertical", ...props }, ref) => (<ScrollAreaPrimitive.ScrollAreaScrollbar ref={ref} orientation={orientation} className={cn("flex touch-none select-none transition-colors", orientation === "vertical" &&
14
+ "h-full w-2.5 border-l border-l-transparent p-[1px]", orientation === "horizontal" &&
15
+ "h-2.5 flex-col border-t border-t-transparent p-[1px]", className)} {...props}>
16
+ <ScrollAreaPrimitive.ScrollAreaThumb className="relative flex-1 rounded-full bg-border"/>
17
+ </ScrollAreaPrimitive.ScrollAreaScrollbar>));
18
+ ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
19
+ export { ScrollArea, ScrollBar };
package/ui/select.d.ts ADDED
@@ -0,0 +1,13 @@
1
+ import * as React from "react";
2
+ import * as SelectPrimitive from "@radix-ui/react-select";
3
+ declare const Select: React.FC<SelectPrimitive.SelectProps>;
4
+ declare const SelectGroup: React.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React.RefAttributes<HTMLDivElement>>;
5
+ declare const SelectValue: React.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React.RefAttributes<HTMLSpanElement>>;
6
+ declare const SelectTrigger: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
7
+ declare const SelectScrollUpButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
8
+ declare const SelectScrollDownButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const SelectContent: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
10
+ declare const SelectLabel: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const SelectItem: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ declare const SelectSeparator: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
13
+ export { Select, SelectGroup, SelectValue, SelectTrigger, SelectContent, SelectLabel, SelectItem, SelectSeparator, SelectScrollUpButton, SelectScrollDownButton, };
package/ui/select.jsx ADDED
@@ -0,0 +1,51 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as SelectPrimitive from "@radix-ui/react-select";
4
+ import { Check, ChevronDown, ChevronUp } from "lucide-react";
5
+ import { cn } from "../lib/utils";
6
+ const Select = SelectPrimitive.Root;
7
+ const SelectGroup = SelectPrimitive.Group;
8
+ const SelectValue = SelectPrimitive.Value;
9
+ const SelectTrigger = React.forwardRef(({ className, children, ...props }, ref) => (<SelectPrimitive.Trigger ref={ref} className={cn("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1", className)} {...props}>
10
+ {children}
11
+ <SelectPrimitive.Icon asChild>
12
+ <ChevronDown className="h-4 w-4 opacity-50"/>
13
+ </SelectPrimitive.Icon>
14
+ </SelectPrimitive.Trigger>));
15
+ SelectTrigger.displayName = SelectPrimitive.Trigger.displayName;
16
+ const SelectScrollUpButton = React.forwardRef(({ className, ...props }, ref) => (<SelectPrimitive.ScrollUpButton ref={ref} className={cn("flex cursor-default items-center justify-center py-1", className)} {...props}>
17
+ <ChevronUp className="h-4 w-4"/>
18
+ </SelectPrimitive.ScrollUpButton>));
19
+ SelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;
20
+ const SelectScrollDownButton = React.forwardRef(({ className, ...props }, ref) => (<SelectPrimitive.ScrollDownButton ref={ref} className={cn("flex cursor-default items-center justify-center py-1", className)} {...props}>
21
+ <ChevronDown className="h-4 w-4"/>
22
+ </SelectPrimitive.ScrollDownButton>));
23
+ SelectScrollDownButton.displayName =
24
+ SelectPrimitive.ScrollDownButton.displayName;
25
+ const SelectContent = React.forwardRef(({ className, children, position = "popper", ...props }, ref) => (<SelectPrimitive.Portal>
26
+ <SelectPrimitive.Content ref={ref} className={cn("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md 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", position === "popper" &&
27
+ "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1", className)} position={position} {...props}>
28
+ <SelectScrollUpButton />
29
+ <SelectPrimitive.Viewport className={cn("p-1", position === "popper" &&
30
+ "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]")}>
31
+ {children}
32
+ </SelectPrimitive.Viewport>
33
+ <SelectScrollDownButton />
34
+ </SelectPrimitive.Content>
35
+ </SelectPrimitive.Portal>));
36
+ SelectContent.displayName = SelectPrimitive.Content.displayName;
37
+ const SelectLabel = React.forwardRef(({ className, ...props }, ref) => (<SelectPrimitive.Label ref={ref} className={cn("py-1.5 pl-8 pr-2 text-sm font-semibold", className)} {...props}/>));
38
+ SelectLabel.displayName = SelectPrimitive.Label.displayName;
39
+ const SelectItem = React.forwardRef(({ className, children, ...props }, ref) => (<SelectPrimitive.Item ref={ref} className={cn("relative flex w-full 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", className)} {...props}>
40
+ <span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
41
+ <SelectPrimitive.ItemIndicator>
42
+ <Check className="h-4 w-4"/>
43
+ </SelectPrimitive.ItemIndicator>
44
+ </span>
45
+
46
+ <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>
47
+ </SelectPrimitive.Item>));
48
+ SelectItem.displayName = SelectPrimitive.Item.displayName;
49
+ const SelectSeparator = React.forwardRef(({ className, ...props }, ref) => (<SelectPrimitive.Separator ref={ref} className={cn("-mx-1 my-1 h-px bg-muted", className)} {...props}/>));
50
+ SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
51
+ export { Select, SelectGroup, SelectValue, SelectTrigger, SelectContent, SelectLabel, SelectItem, SelectSeparator, SelectScrollUpButton, SelectScrollDownButton, };
@@ -0,0 +1,4 @@
1
+ import * as React from "react";
2
+ import * as SeparatorPrimitive from "@radix-ui/react-separator";
3
+ declare const Separator: React.ForwardRefExoticComponent<Omit<SeparatorPrimitive.SeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
+ export { Separator };
@@ -0,0 +1,7 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as SeparatorPrimitive from "@radix-ui/react-separator";
4
+ import { cn } from "../lib/utils";
5
+ const Separator = React.forwardRef(({ className, orientation = "horizontal", decorative = true, ...props }, ref) => (<SeparatorPrimitive.Root ref={ref} decorative={decorative} orientation={orientation} className={cn("shrink-0 bg-border", orientation === "horizontal" ? "h-[1px] w-full" : "h-full w-[1px]", className)} {...props}/>));
6
+ Separator.displayName = SeparatorPrimitive.Root.displayName;
7
+ export { Separator };
package/ui/sheet.d.ts ADDED
@@ -0,0 +1,25 @@
1
+ import * as React from "react";
2
+ import * as SheetPrimitive from "@radix-ui/react-dialog";
3
+ import { type VariantProps } from "class-variance-authority";
4
+ declare const Sheet: React.FC<SheetPrimitive.DialogProps>;
5
+ declare const SheetTrigger: React.ForwardRefExoticComponent<SheetPrimitive.DialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
6
+ declare const SheetClose: React.ForwardRefExoticComponent<SheetPrimitive.DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
7
+ declare const SheetPortal: React.FC<SheetPrimitive.DialogPortalProps>;
8
+ declare const SheetOverlay: React.ForwardRefExoticComponent<Omit<SheetPrimitive.DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const sheetVariants: (props?: {
10
+ side?: "left" | "top" | "bottom" | "right";
11
+ } & import("class-variance-authority/dist/types").ClassProp) => string;
12
+ interface SheetContentProps extends React.ComponentPropsWithoutRef<typeof SheetPrimitive.Content>, VariantProps<typeof sheetVariants> {
13
+ }
14
+ declare const SheetContent: React.ForwardRefExoticComponent<SheetContentProps & React.RefAttributes<HTMLDivElement>>;
15
+ declare const SheetHeader: {
16
+ ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): React.JSX.Element;
17
+ displayName: string;
18
+ };
19
+ declare const SheetFooter: {
20
+ ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): React.JSX.Element;
21
+ displayName: string;
22
+ };
23
+ declare const SheetTitle: React.ForwardRefExoticComponent<Omit<SheetPrimitive.DialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
24
+ declare const SheetDescription: React.ForwardRefExoticComponent<Omit<SheetPrimitive.DialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
25
+ export { Sheet, SheetPortal, SheetOverlay, SheetTrigger, SheetClose, SheetContent, SheetHeader, SheetFooter, SheetTitle, SheetDescription, };
package/ui/sheet.jsx ADDED
@@ -0,0 +1,45 @@
1
+ "use client";
2
+ import * as React from "react";
3
+ import * as SheetPrimitive from "@radix-ui/react-dialog";
4
+ import { cva } from "class-variance-authority";
5
+ import { X } from "lucide-react";
6
+ import { cn } from "../lib/utils";
7
+ const Sheet = SheetPrimitive.Root;
8
+ const SheetTrigger = SheetPrimitive.Trigger;
9
+ const SheetClose = SheetPrimitive.Close;
10
+ const SheetPortal = SheetPrimitive.Portal;
11
+ const SheetOverlay = React.forwardRef(({ className, ...props }, ref) => (<SheetPrimitive.Overlay className={cn("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", className)} {...props} ref={ref}/>));
12
+ SheetOverlay.displayName = SheetPrimitive.Overlay.displayName;
13
+ const sheetVariants = cva("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500", {
14
+ variants: {
15
+ side: {
16
+ top: "inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",
17
+ bottom: "inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",
18
+ left: "inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",
19
+ right: "inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm",
20
+ },
21
+ },
22
+ defaultVariants: {
23
+ side: "right",
24
+ },
25
+ });
26
+ const SheetContent = React.forwardRef(({ side = "right", className, children, ...props }, ref) => (<SheetPortal>
27
+ <SheetOverlay />
28
+ <SheetPrimitive.Content ref={ref} className={cn(sheetVariants({ side }), className)} {...props}>
29
+ {children}
30
+ <SheetPrimitive.Close className="absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary">
31
+ <X className="h-4 w-4"/>
32
+ <span className="sr-only">Close</span>
33
+ </SheetPrimitive.Close>
34
+ </SheetPrimitive.Content>
35
+ </SheetPortal>));
36
+ SheetContent.displayName = SheetPrimitive.Content.displayName;
37
+ const SheetHeader = ({ className, ...props }) => (<div className={cn("flex flex-col space-y-2 text-center sm:text-left", className)} {...props}/>);
38
+ SheetHeader.displayName = "SheetHeader";
39
+ const SheetFooter = ({ className, ...props }) => (<div className={cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className)} {...props}/>);
40
+ SheetFooter.displayName = "SheetFooter";
41
+ const SheetTitle = React.forwardRef(({ className, ...props }, ref) => (<SheetPrimitive.Title ref={ref} className={cn("text-lg font-semibold text-foreground", className)} {...props}/>));
42
+ SheetTitle.displayName = SheetPrimitive.Title.displayName;
43
+ const SheetDescription = React.forwardRef(({ className, ...props }, ref) => (<SheetPrimitive.Description ref={ref} className={cn("text-sm text-muted-foreground", className)} {...props}/>));
44
+ SheetDescription.displayName = SheetPrimitive.Description.displayName;
45
+ export { Sheet, SheetPortal, SheetOverlay, SheetTrigger, SheetClose, SheetContent, SheetHeader, SheetFooter, SheetTitle, SheetDescription, };
@@ -0,0 +1,66 @@
1
+ import * as React from "react";
2
+ import { VariantProps } from "class-variance-authority";
3
+ import { TooltipContent } from "../ui/tooltip";
4
+ type SidebarContext = {
5
+ state: "expanded" | "collapsed";
6
+ open: boolean;
7
+ setOpen: (open: boolean) => void;
8
+ openMobile: boolean;
9
+ setOpenMobile: (open: boolean) => void;
10
+ isMobile: boolean;
11
+ toggleSidebar: () => void;
12
+ };
13
+ declare const SidebarContext: React.Context<SidebarContext>;
14
+ declare function useSidebar(): SidebarContext;
15
+ declare const SidebarProvider: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
16
+ defaultOpen?: boolean;
17
+ open?: boolean;
18
+ onOpenChange?: (open: boolean) => void;
19
+ }, "ref"> & React.RefAttributes<HTMLDivElement>>;
20
+ declare const Sidebar: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
21
+ side?: "left" | "right";
22
+ variant?: "sidebar" | "floating" | "inset";
23
+ collapsible?: "offcanvas" | "icon" | "none";
24
+ }, "ref"> & React.RefAttributes<HTMLDivElement>>;
25
+ declare const SidebarTrigger: React.ForwardRefExoticComponent<Omit<import("../ui/button").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
26
+ declare const SidebarRail: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
27
+ declare const SidebarInset: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
28
+ declare const SidebarInput: React.ForwardRefExoticComponent<Omit<Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
29
+ declare const SidebarHeader: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
30
+ declare const SidebarFooter: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
31
+ declare const SidebarSeparator: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-separator").SeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
32
+ declare const SidebarContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
33
+ declare const SidebarGroup: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
34
+ declare const SidebarGroupLabel: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
35
+ asChild?: boolean;
36
+ }, "ref"> & React.RefAttributes<HTMLDivElement>>;
37
+ declare const SidebarGroupAction: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
38
+ asChild?: boolean;
39
+ }, "ref"> & React.RefAttributes<HTMLButtonElement>>;
40
+ declare const SidebarGroupContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
41
+ declare const SidebarMenu: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
42
+ declare const SidebarMenuItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
43
+ declare const SidebarMenuButton: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
44
+ asChild?: boolean;
45
+ isActive?: boolean;
46
+ tooltip?: string | React.ComponentProps<typeof TooltipContent>;
47
+ } & VariantProps<(props?: {
48
+ variant?: "default" | "outline";
49
+ size?: "default" | "sm" | "lg";
50
+ } & import("class-variance-authority/dist/types").ClassProp) => string>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
51
+ declare const SidebarMenuAction: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
52
+ asChild?: boolean;
53
+ showOnHover?: boolean;
54
+ }, "ref"> & React.RefAttributes<HTMLButtonElement>>;
55
+ declare const SidebarMenuBadge: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
56
+ declare const SidebarMenuSkeleton: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
57
+ showIcon?: boolean;
58
+ }, "ref"> & React.RefAttributes<HTMLDivElement>>;
59
+ declare const SidebarMenuSub: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
60
+ declare const SidebarMenuSubItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
61
+ declare const SidebarMenuSubButton: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLAnchorElement> & React.AnchorHTMLAttributes<HTMLAnchorElement> & {
62
+ asChild?: boolean;
63
+ size?: "sm" | "md";
64
+ isActive?: boolean;
65
+ }, "ref"> & React.RefAttributes<HTMLAnchorElement>>;
66
+ export { Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, useSidebar, };