@cbrl/design 0.0.0-stage → 0.2.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 (114) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +124 -2
  3. package/dist/components/alert-dialog.d.ts +14 -0
  4. package/dist/components/alert-dialog.js +82 -0
  5. package/dist/components/app-shell.d.ts +38 -0
  6. package/dist/components/app-shell.js +72 -0
  7. package/dist/components/auth-split-screen.d.ts +30 -0
  8. package/dist/components/auth-split-screen.js +45 -0
  9. package/dist/components/avatar.d.ts +11 -0
  10. package/dist/components/avatar.js +50 -0
  11. package/dist/components/badge.d.ts +9 -0
  12. package/dist/components/badge.js +27 -0
  13. package/dist/components/breadcrumb.d.ts +11 -0
  14. package/dist/components/breadcrumb.js +69 -0
  15. package/dist/components/button.d.ts +10 -0
  16. package/dist/components/button.js +47 -0
  17. package/dist/components/calendar.d.ts +7 -0
  18. package/dist/components/calendar.js +142 -0
  19. package/dist/components/card.d.ts +13 -0
  20. package/dist/components/card.js +57 -0
  21. package/dist/components/checkbox.d.ts +4 -0
  22. package/dist/components/checkbox.js +20 -0
  23. package/dist/components/collapsible.d.ts +5 -0
  24. package/dist/components/collapsible.js +23 -0
  25. package/dist/components/date-field.d.ts +31 -0
  26. package/dist/components/date-field.js +129 -0
  27. package/dist/components/dialog.d.ts +17 -0
  28. package/dist/components/dialog.js +95 -0
  29. package/dist/components/dropdown-menu.d.ts +29 -0
  30. package/dist/components/dropdown-menu.js +127 -0
  31. package/dist/components/empty-state.d.ts +32 -0
  32. package/dist/components/empty-state.js +61 -0
  33. package/dist/components/field.d.ts +25 -0
  34. package/dist/components/field.js +121 -0
  35. package/dist/components/highlighted-textarea.d.ts +6 -0
  36. package/dist/components/highlighted-textarea.js +68 -0
  37. package/dist/components/icons/brand-icon.d.ts +6 -0
  38. package/dist/components/icons/brand-icon.js +13 -0
  39. package/dist/components/icons/google-icon.d.ts +7 -0
  40. package/dist/components/icons/google-icon.js +33 -0
  41. package/dist/components/icons/whatsapp-icon.d.ts +7 -0
  42. package/dist/components/icons/whatsapp-icon.js +18 -0
  43. package/dist/components/input-group.d.ts +8 -0
  44. package/dist/components/input-group.js +28 -0
  45. package/dist/components/input.d.ts +3 -0
  46. package/dist/components/input.js +13 -0
  47. package/dist/components/label.d.ts +4 -0
  48. package/dist/components/label.js +14 -0
  49. package/dist/components/list.d.ts +174 -0
  50. package/dist/components/list.js +281 -0
  51. package/dist/components/main.d.ts +10 -0
  52. package/dist/components/main.js +36 -0
  53. package/dist/components/pagination.d.ts +25 -0
  54. package/dist/components/pagination.js +104 -0
  55. package/dist/components/popover.d.ts +6 -0
  56. package/dist/components/popover.js +28 -0
  57. package/dist/components/radio-group.d.ts +5 -0
  58. package/dist/components/radio-group.js +27 -0
  59. package/dist/components/scroll-area.d.ts +5 -0
  60. package/dist/components/scroll-area.js +35 -0
  61. package/dist/components/select.d.ts +15 -0
  62. package/dist/components/select.js +95 -0
  63. package/dist/components/separator.d.ts +4 -0
  64. package/dist/components/separator.js +16 -0
  65. package/dist/components/setting-row.d.ts +8 -0
  66. package/dist/components/setting-row.js +36 -0
  67. package/dist/components/settings-section.d.ts +7 -0
  68. package/dist/components/settings-section.js +36 -0
  69. package/dist/components/sheet.d.ts +14 -0
  70. package/dist/components/sheet.js +89 -0
  71. package/dist/components/sidebar-core.d.ts +33 -0
  72. package/dist/components/sidebar-core.js +220 -0
  73. package/dist/components/sidebar-menu.d.ts +38 -0
  74. package/dist/components/sidebar-menu.js +168 -0
  75. package/dist/components/sidebar.d.ts +3 -0
  76. package/dist/components/skeleton.d.ts +2 -0
  77. package/dist/components/skeleton.js +11 -0
  78. package/dist/components/sonner.d.ts +3 -0
  79. package/dist/components/sonner.js +31 -0
  80. package/dist/components/stepper.d.ts +8 -0
  81. package/dist/components/stepper.js +58 -0
  82. package/dist/components/switch.d.ts +6 -0
  83. package/dist/components/switch.js +19 -0
  84. package/dist/components/table.d.ts +10 -0
  85. package/dist/components/table.js +65 -0
  86. package/dist/components/tabs.d.ts +7 -0
  87. package/dist/components/tabs.js +35 -0
  88. package/dist/components/textarea.d.ts +3 -0
  89. package/dist/components/textarea.js +12 -0
  90. package/dist/components/theme-provider.d.ts +15 -0
  91. package/dist/components/theme-provider.js +22 -0
  92. package/dist/components/tooltip.d.ts +7 -0
  93. package/dist/components/tooltip.js +35 -0
  94. package/dist/components/typography.d.ts +9 -0
  95. package/dist/components/typography.js +45 -0
  96. package/dist/components/user-menu.d.ts +27 -0
  97. package/dist/components/user-menu.js +49 -0
  98. package/dist/globals.css +60 -0
  99. package/dist/hooks/use-mobile.d.ts +1 -0
  100. package/dist/hooks/use-mobile.js +17 -0
  101. package/dist/index.d.ts +53 -0
  102. package/dist/index.js +51 -0
  103. package/dist/lib/cn.d.ts +2 -0
  104. package/dist/lib/cn.js +7 -0
  105. package/dist/lib/css-vars.js +5 -0
  106. package/dist/lib/date.js +38 -0
  107. package/dist/lib/initials.d.ts +8 -0
  108. package/dist/lib/initials.js +15 -0
  109. package/dist/lib/nav.d.ts +15 -0
  110. package/dist/lib/nav.js +11 -0
  111. package/dist/lib/toaster-theme.js +5 -0
  112. package/dist/shadcn.css +635 -0
  113. package/dist/tokens.css +160 -0
  114. package/package.json +85 -3
@@ -0,0 +1,38 @@
1
+ import { TooltipContent } from "./tooltip.js";
2
+ import * as React from "react";
3
+ import { VariantProps } from "class-variance-authority";
4
+ export declare function SidebarGroup({ className, ...props }: React.ComponentProps<'div'>): React.JSX.Element;
5
+ export declare function SidebarGroupLabel({ className, asChild, ...props }: React.ComponentProps<'div'> & {
6
+ asChild?: boolean;
7
+ }): React.JSX.Element;
8
+ export declare function SidebarGroupAction({ className, asChild, ...props }: React.ComponentProps<'button'> & {
9
+ asChild?: boolean;
10
+ }): React.JSX.Element;
11
+ export declare function SidebarGroupContent({ className, ...props }: React.ComponentProps<'div'>): React.JSX.Element;
12
+ export declare function SidebarMenu({ className, ...props }: React.ComponentProps<'ul'>): React.JSX.Element;
13
+ export declare function SidebarMenuItem({ className, ...props }: React.ComponentProps<'li'>): React.JSX.Element;
14
+ declare const sidebarMenuButtonVariants: (props?: ({
15
+ variant?: "default" | "outline" | null | undefined;
16
+ size?: "default" | "sm" | "lg" | null | undefined;
17
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
18
+ export declare function SidebarMenuButton({ asChild, isActive, variant, size, tooltip, className, ...props }: React.ComponentProps<'button'> & {
19
+ asChild?: boolean;
20
+ isActive?: boolean;
21
+ tooltip?: string | React.ComponentProps<typeof TooltipContent>;
22
+ } & VariantProps<typeof sidebarMenuButtonVariants>): React.JSX.Element;
23
+ export declare function SidebarMenuAction({ className, asChild, showOnHover, ...props }: React.ComponentProps<'button'> & {
24
+ asChild?: boolean;
25
+ showOnHover?: boolean;
26
+ }): React.JSX.Element;
27
+ export declare function SidebarMenuBadge({ className, ...props }: React.ComponentProps<'div'>): React.JSX.Element;
28
+ export declare function SidebarMenuSkeleton({ className, showIcon, ...props }: React.ComponentProps<'div'> & {
29
+ showIcon?: boolean;
30
+ }): React.JSX.Element;
31
+ export declare function SidebarMenuSub({ className, ...props }: React.ComponentProps<'ul'>): React.JSX.Element;
32
+ export declare function SidebarMenuSubItem({ className, ...props }: React.ComponentProps<'li'>): React.JSX.Element;
33
+ export declare function SidebarMenuSubButton({ asChild, size, isActive, className, ...props }: React.ComponentProps<'a'> & {
34
+ asChild?: boolean;
35
+ size?: 'sm' | 'md';
36
+ isActive?: boolean;
37
+ }): React.JSX.Element;
38
+ export {};
@@ -0,0 +1,168 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.js";
3
+ import { cssVars } from "../lib/css-vars.js";
4
+ import { Skeleton } from "./skeleton.js";
5
+ import { Tooltip as Tooltip$1, TooltipContent, TooltipTrigger } from "./tooltip.js";
6
+ import { useSidebar } from "./sidebar-core.js";
7
+ import * as React from "react";
8
+ import { cva } from "class-variance-authority";
9
+ import { Slot } from "radix-ui";
10
+ import { jsx, jsxs } from "react/jsx-runtime";
11
+ // src/components/sidebar-menu.tsx
12
+ function SidebarGroup({ className, ...props }) {
13
+ return /* @__PURE__ */ jsx("div", {
14
+ "data-slot": "sidebar-group",
15
+ "data-sidebar": "group",
16
+ className: cn("relative flex w-full min-w-0 flex-col p-2", className),
17
+ ...props
18
+ });
19
+ }
20
+ function SidebarGroupLabel({ className, asChild = false, ...props }) {
21
+ const Comp = asChild ? Slot.Root : "div";
22
+ return /* @__PURE__ */ jsx(Comp, {
23
+ "data-slot": "sidebar-group-label",
24
+ "data-sidebar": "group-label",
25
+ className: cn("text-sidebar-foreground/70 ring-sidebar-ring flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium outline-hidden transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0", className),
26
+ ...props
27
+ });
28
+ }
29
+ function SidebarGroupAction({ className, asChild = false, ...props }) {
30
+ const Comp = asChild ? Slot.Root : "button";
31
+ return /* @__PURE__ */ jsx(Comp, {
32
+ "data-slot": "sidebar-group-action",
33
+ "data-sidebar": "group-action",
34
+ className: cn("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform group-data-[collapsible=icon]:hidden after:absolute after:-inset-2 focus-visible:ring-2 md:after:hidden [&>svg]:size-4 [&>svg]:shrink-0", className),
35
+ ...props
36
+ });
37
+ }
38
+ function SidebarGroupContent({ className, ...props }) {
39
+ return /* @__PURE__ */ jsx("div", {
40
+ "data-slot": "sidebar-group-content",
41
+ "data-sidebar": "group-content",
42
+ className: cn("w-full text-sm", className),
43
+ ...props
44
+ });
45
+ }
46
+ function SidebarMenu({ className, ...props }) {
47
+ return /* @__PURE__ */ jsx("ul", {
48
+ "data-slot": "sidebar-menu",
49
+ "data-sidebar": "menu",
50
+ className: cn("flex w-full min-w-0 flex-col gap-0", className),
51
+ ...props
52
+ });
53
+ }
54
+ function SidebarMenuItem({ className, ...props }) {
55
+ return /* @__PURE__ */ jsx("li", {
56
+ "data-slot": "sidebar-menu-item",
57
+ "data-sidebar": "menu-item",
58
+ className: cn("group/menu-item relative", className),
59
+ ...props
60
+ });
61
+ }
62
+ const sidebarMenuButtonVariants = cva("peer/menu-button group/menu-button ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground flex w-full cursor-pointer items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! focus-visible:ring-2 disabled:pointer-events-none disabled:cursor-default disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-active:font-medium [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate", {
63
+ variants: {
64
+ variant: {
65
+ default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
66
+ outline: "bg-background hover:bg-sidebar-accent hover:text-sidebar-accent-foreground shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"
67
+ },
68
+ size: {
69
+ default: "h-8 text-sm",
70
+ sm: "h-7 text-xs",
71
+ lg: "h-12 text-sm group-data-[collapsible=icon]:p-0!"
72
+ }
73
+ },
74
+ defaultVariants: {
75
+ variant: "default",
76
+ size: "default"
77
+ }
78
+ });
79
+ function SidebarMenuButton({ asChild = false, isActive = false, variant = "default", size = "default", tooltip, className, ...props }) {
80
+ const Comp = asChild ? Slot.Root : "button";
81
+ const { isMobile, state } = useSidebar();
82
+ const button = /* @__PURE__ */ jsx(Comp, {
83
+ "data-slot": "sidebar-menu-button",
84
+ "data-sidebar": "menu-button",
85
+ "data-size": size,
86
+ "data-active": isActive,
87
+ className: cn(sidebarMenuButtonVariants({
88
+ variant,
89
+ size
90
+ }), className),
91
+ ...props
92
+ });
93
+ if (!tooltip) return button;
94
+ if (typeof tooltip === "string") tooltip = { children: tooltip };
95
+ return /* @__PURE__ */ jsxs(Tooltip$1, { children: [/* @__PURE__ */ jsx(TooltipTrigger, {
96
+ asChild: true,
97
+ children: button
98
+ }), /* @__PURE__ */ jsx(TooltipContent, {
99
+ side: "right",
100
+ align: "center",
101
+ hidden: state !== "collapsed" || isMobile,
102
+ ...tooltip
103
+ })] });
104
+ }
105
+ function SidebarMenuAction({ className, asChild = false, showOnHover = false, ...props }) {
106
+ const Comp = asChild ? Slot.Root : "button";
107
+ return /* @__PURE__ */ jsx(Comp, {
108
+ "data-slot": "sidebar-menu-action",
109
+ "data-sidebar": "menu-action",
110
+ className: cn("text-sidebar-foreground ring-sidebar-ring peer-hover/menu-button:text-sidebar-accent-foreground hover:bg-sidebar-accent hover:text-sidebar-accent-foreground absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform group-data-[collapsible=icon]:hidden peer-data-[size=default]/menu-button:top-1.5 peer-data-[size=lg]/menu-button:top-2.5 peer-data-[size=sm]/menu-button:top-1 after:absolute after:-inset-2 focus-visible:ring-2 md:after:hidden [&>svg]:size-4 [&>svg]:shrink-0", showOnHover && "peer-data-active/menu-button:text-sidebar-accent-foreground group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 aria-expanded:opacity-100 md:opacity-0", className),
111
+ ...props
112
+ });
113
+ }
114
+ function SidebarMenuBadge({ className, ...props }) {
115
+ return /* @__PURE__ */ jsx("div", {
116
+ "data-slot": "sidebar-menu-badge",
117
+ "data-sidebar": "menu-badge",
118
+ className: cn("text-sidebar-foreground peer-hover/menu-button:text-sidebar-accent-foreground peer-data-active/menu-button:text-sidebar-accent-foreground pointer-events-none absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums select-none group-data-[collapsible=icon]:hidden peer-data-[size=default]/menu-button:top-1.5 peer-data-[size=lg]/menu-button:top-2.5 peer-data-[size=sm]/menu-button:top-1", className),
119
+ ...props
120
+ });
121
+ }
122
+ function SidebarMenuSkeleton({ className, showIcon = false, ...props }) {
123
+ const [width] = React.useState(() => {
124
+ return `${Math.floor(Math.random() * 40) + 50}%`;
125
+ });
126
+ return /* @__PURE__ */ jsxs("div", {
127
+ "data-slot": "sidebar-menu-skeleton",
128
+ "data-sidebar": "menu-skeleton",
129
+ className: cn("flex h-8 items-center gap-2 rounded-md px-2", className),
130
+ ...props,
131
+ children: [showIcon && /* @__PURE__ */ jsx(Skeleton, {
132
+ className: "size-4 rounded-md",
133
+ "data-sidebar": "menu-skeleton-icon"
134
+ }), /* @__PURE__ */ jsx(Skeleton, {
135
+ className: "h-4 max-w-(--skeleton-width) flex-1",
136
+ "data-sidebar": "menu-skeleton-text",
137
+ style: cssVars({ "--skeleton-width": width })
138
+ })]
139
+ });
140
+ }
141
+ function SidebarMenuSub({ className, ...props }) {
142
+ return /* @__PURE__ */ jsx("ul", {
143
+ "data-slot": "sidebar-menu-sub",
144
+ "data-sidebar": "menu-sub",
145
+ className: cn("border-sidebar-border mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l px-2.5 py-0.5 group-data-[collapsible=icon]:hidden", className),
146
+ ...props
147
+ });
148
+ }
149
+ function SidebarMenuSubItem({ className, ...props }) {
150
+ return /* @__PURE__ */ jsx("li", {
151
+ "data-slot": "sidebar-menu-sub-item",
152
+ "data-sidebar": "menu-sub-item",
153
+ className: cn("group/menu-sub-item relative", className),
154
+ ...props
155
+ });
156
+ }
157
+ function SidebarMenuSubButton({ asChild = false, size = "md", isActive = false, className, ...props }) {
158
+ const Comp = asChild ? Slot.Root : "a";
159
+ return /* @__PURE__ */ jsx(Comp, {
160
+ "data-slot": "sidebar-menu-sub-button",
161
+ "data-sidebar": "menu-sub-button",
162
+ "data-size": size,
163
+ "data-active": isActive,
164
+ className: cn("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground [&>svg]:text-sidebar-accent-foreground flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 outline-hidden group-data-[collapsible=icon]:hidden focus-visible:ring-2 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[size=md]:text-sm data-[size=sm]:text-xs [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0", className),
165
+ ...props
166
+ });
167
+ }
168
+ export { SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem };
@@ -0,0 +1,3 @@
1
+ import { Sidebar, SidebarContent, SidebarFooter, SidebarHeader, SidebarInput, SidebarInset, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, useSidebar } from "./sidebar-core.js";
2
+ import { SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem } from "./sidebar-menu.js";
3
+ 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 };
@@ -0,0 +1,2 @@
1
+ declare function Skeleton({ className, ...props }: React.ComponentProps<'div'>): import("react").JSX.Element;
2
+ export { Skeleton };
@@ -0,0 +1,11 @@
1
+ import { cn } from "../lib/cn.js";
2
+ import { jsx } from "react/jsx-runtime";
3
+ // src/components/skeleton.tsx
4
+ function Skeleton({ className, ...props }) {
5
+ return /* @__PURE__ */ jsx("div", {
6
+ "data-slot": "skeleton",
7
+ className: cn("bg-muted animate-pulse rounded-md", className),
8
+ ...props
9
+ });
10
+ }
11
+ export { Skeleton };
@@ -0,0 +1,3 @@
1
+ import { ToasterProps } from "sonner";
2
+ declare const Toaster: ({ ...props }: ToasterProps) => import("react").JSX.Element;
3
+ export { Toaster };
@@ -0,0 +1,31 @@
1
+ "use client";
2
+ import { cssVars } from "../lib/css-vars.js";
3
+ import { toasterTheme } from "../lib/toaster-theme.js";
4
+ import { jsx } from "react/jsx-runtime";
5
+ import { CircleCheckIcon, InfoIcon, Loader2Icon, OctagonXIcon, TriangleAlertIcon } from "lucide-react";
6
+ import { useTheme } from "next-themes";
7
+ import { Toaster as Toaster$1 } from "sonner";
8
+ // src/components/sonner.tsx
9
+ const Toaster = ({ ...props }) => {
10
+ const { theme = "system" } = useTheme();
11
+ return /* @__PURE__ */ jsx(Toaster$1, {
12
+ theme: toasterTheme(theme),
13
+ className: "toaster group",
14
+ icons: {
15
+ success: /* @__PURE__ */ jsx(CircleCheckIcon, { className: "size-4" }),
16
+ info: /* @__PURE__ */ jsx(InfoIcon, { className: "size-4" }),
17
+ warning: /* @__PURE__ */ jsx(TriangleAlertIcon, { className: "size-4" }),
18
+ error: /* @__PURE__ */ jsx(OctagonXIcon, { className: "size-4" }),
19
+ loading: /* @__PURE__ */ jsx(Loader2Icon, { className: "size-4 animate-spin" })
20
+ },
21
+ style: cssVars({
22
+ "--normal-bg": "var(--popover)",
23
+ "--normal-text": "var(--popover-foreground)",
24
+ "--normal-border": "var(--border)",
25
+ "--border-radius": "var(--radius)"
26
+ }),
27
+ toastOptions: { classNames: { toast: "cn-toast" } },
28
+ ...props
29
+ });
30
+ };
31
+ export { Toaster };
@@ -0,0 +1,8 @@
1
+ import * as React from "react";
2
+ type StepperProps = React.ComponentProps<'nav'> & {
3
+ steps: readonly string[];
4
+ activeIndex: number;
5
+ onStepSelect?: (index: number) => void;
6
+ };
7
+ declare function Stepper({ steps, activeIndex, onStepSelect, className, ...props }: StepperProps): React.JSX.Element;
8
+ export { Stepper };
@@ -0,0 +1,58 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.js";
3
+ import "react";
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
+ import { CheckIcon } from "lucide-react";
6
+ // src/components/stepper.tsx
7
+ function stepState(index, activeIndex) {
8
+ if (index < activeIndex) return "done";
9
+ if (index === activeIndex) return "active";
10
+ return "todo";
11
+ }
12
+ function Stepper({ steps, activeIndex, onStepSelect, className, ...props }) {
13
+ return /* @__PURE__ */ jsxs("nav", {
14
+ "data-slot": "stepper",
15
+ "aria-label": `Passo ${activeIndex + 1} de ${steps.length}`,
16
+ className: cn("flex flex-col gap-2", className),
17
+ ...props,
18
+ children: [/* @__PURE__ */ jsxs("p", {
19
+ "data-slot": "stepper-counter",
20
+ className: "text-muted-foreground text-xs font-medium",
21
+ children: [
22
+ "Passo ",
23
+ activeIndex + 1,
24
+ " de ",
25
+ steps.length
26
+ ]
27
+ }), /* @__PURE__ */ jsx("ol", {
28
+ className: "flex items-start gap-2",
29
+ children: steps.map((label, index) => {
30
+ const state = stepState(index, activeIndex);
31
+ const clickable = state === "done" && onStepSelect !== void 0;
32
+ return /* @__PURE__ */ jsx("li", {
33
+ className: "min-w-0 flex-1",
34
+ children: /* @__PURE__ */ jsxs("button", {
35
+ type: "button",
36
+ "data-slot": "stepper-step",
37
+ "data-state": state,
38
+ "aria-current": state === "active" ? "step" : void 0,
39
+ disabled: !clickable && state !== "active",
40
+ onClick: clickable ? () => onStepSelect(index) : void 0,
41
+ className: cn("group flex w-full flex-col gap-1.5 outline-none", clickable ? "cursor-pointer" : "cursor-default"),
42
+ children: [/* @__PURE__ */ jsx("span", { className: cn("h-1 w-full rounded-full transition-colors", state === "todo" ? "bg-muted" : "bg-primary", state === "active" && "bg-primary/70", clickable && "group-focus-visible:ring-ring/50 group-focus-visible:ring-3") }), /* @__PURE__ */ jsxs("span", {
43
+ className: cn("flex items-center gap-1 truncate text-xs", state === "active" && "text-foreground font-medium", state === "done" && "text-muted-foreground group-hover:text-foreground", state === "todo" && "text-muted-foreground/60"),
44
+ children: [state === "done" ? /* @__PURE__ */ jsx(CheckIcon, {
45
+ "aria-hidden": true,
46
+ className: "size-3 shrink-0"
47
+ }) : null, /* @__PURE__ */ jsx("span", {
48
+ className: "truncate",
49
+ children: label
50
+ })]
51
+ })]
52
+ })
53
+ }, label);
54
+ })
55
+ })]
56
+ });
57
+ }
58
+ export { Stepper };
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ import { Switch as Switch$1 } from "radix-ui";
3
+ declare function Switch({ className, size, ...props }: React.ComponentProps<typeof Switch$1.Root> & {
4
+ size?: 'sm' | 'default';
5
+ }): React.JSX.Element;
6
+ export { Switch };
@@ -0,0 +1,19 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.js";
3
+ import "react";
4
+ import { Switch as Switch$1 } from "radix-ui";
5
+ import { jsx } from "react/jsx-runtime";
6
+ // src/components/switch.tsx
7
+ function Switch({ className, size = "default", ...props }) {
8
+ return /* @__PURE__ */ jsx(Switch$1.Root, {
9
+ "data-slot": "switch",
10
+ "data-size": size,
11
+ className: cn("peer group/switch focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:bg-primary data-unchecked:bg-input dark:data-unchecked:bg-input/80 relative inline-flex shrink-0 items-center rounded-full border border-transparent transition-all outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:ring-3 aria-invalid:ring-3 data-disabled:cursor-not-allowed data-disabled:opacity-50 data-[size=default]:h-[18.4px] data-[size=default]:w-[32px] data-[size=sm]:h-[14px] data-[size=sm]:w-[24px]", className),
12
+ ...props,
13
+ children: /* @__PURE__ */ jsx(Switch$1.Thumb, {
14
+ "data-slot": "switch-thumb",
15
+ className: "bg-background dark:data-checked:bg-primary-foreground dark:data-unchecked:bg-foreground pointer-events-none block rounded-full ring-0 transition-transform group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=sm]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=default]/switch:data-unchecked:translate-x-0 group-data-[size=sm]/switch:data-unchecked:translate-x-0"
16
+ })
17
+ });
18
+ }
19
+ export { Switch };
@@ -0,0 +1,10 @@
1
+ import * as React from "react";
2
+ declare function Table({ className, ...props }: React.ComponentProps<'table'>): React.JSX.Element;
3
+ declare function TableHeader({ className, ...props }: React.ComponentProps<'thead'>): React.JSX.Element;
4
+ declare function TableBody({ className, ...props }: React.ComponentProps<'tbody'>): React.JSX.Element;
5
+ declare function TableFooter({ className, ...props }: React.ComponentProps<'tfoot'>): React.JSX.Element;
6
+ declare function TableRow({ className, ...props }: React.ComponentProps<'tr'>): React.JSX.Element;
7
+ declare function TableHead({ className, ...props }: React.ComponentProps<'th'>): React.JSX.Element;
8
+ declare function TableCell({ className, ...props }: React.ComponentProps<'td'>): React.JSX.Element;
9
+ declare function TableCaption({ className, ...props }: React.ComponentProps<'caption'>): React.JSX.Element;
10
+ export { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow };
@@ -0,0 +1,65 @@
1
+ import { cn } from "../lib/cn.js";
2
+ import "react";
3
+ import { jsx } from "react/jsx-runtime";
4
+ // src/components/table.tsx
5
+ function Table({ className, ...props }) {
6
+ return /* @__PURE__ */ jsx("div", {
7
+ "data-slot": "table-container",
8
+ className: "relative w-full overflow-x-auto",
9
+ children: /* @__PURE__ */ jsx("table", {
10
+ "data-slot": "table",
11
+ className: cn("w-full caption-bottom text-sm", className),
12
+ ...props
13
+ })
14
+ });
15
+ }
16
+ function TableHeader({ className, ...props }) {
17
+ return /* @__PURE__ */ jsx("thead", {
18
+ "data-slot": "table-header",
19
+ className: cn("[&_tr]:border-b", className),
20
+ ...props
21
+ });
22
+ }
23
+ function TableBody({ className, ...props }) {
24
+ return /* @__PURE__ */ jsx("tbody", {
25
+ "data-slot": "table-body",
26
+ className: cn("[&_tr:last-child]:border-0", className),
27
+ ...props
28
+ });
29
+ }
30
+ function TableFooter({ className, ...props }) {
31
+ return /* @__PURE__ */ jsx("tfoot", {
32
+ "data-slot": "table-footer",
33
+ className: cn("bg-muted/50 border-t font-medium [&>tr]:last:border-b-0", className),
34
+ ...props
35
+ });
36
+ }
37
+ function TableRow({ className, ...props }) {
38
+ return /* @__PURE__ */ jsx("tr", {
39
+ "data-slot": "table-row",
40
+ className: cn("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors", className),
41
+ ...props
42
+ });
43
+ }
44
+ function TableHead({ className, ...props }) {
45
+ return /* @__PURE__ */ jsx("th", {
46
+ "data-slot": "table-head",
47
+ className: cn("text-muted-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]", className),
48
+ ...props
49
+ });
50
+ }
51
+ function TableCell({ className, ...props }) {
52
+ return /* @__PURE__ */ jsx("td", {
53
+ "data-slot": "table-cell",
54
+ className: cn("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]", className),
55
+ ...props
56
+ });
57
+ }
58
+ function TableCaption({ className, ...props }) {
59
+ return /* @__PURE__ */ jsx("caption", {
60
+ "data-slot": "table-caption",
61
+ className: cn("text-muted-foreground mt-4 text-sm", className),
62
+ ...props
63
+ });
64
+ }
65
+ export { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow };
@@ -0,0 +1,7 @@
1
+ import * as React from "react";
2
+ import { Tabs as Tabs$1 } from "radix-ui";
3
+ declare function Tabs({ className, ...props }: React.ComponentProps<typeof Tabs$1.Root>): React.JSX.Element;
4
+ declare function TabsList({ className, ...props }: React.ComponentProps<typeof Tabs$1.List>): React.JSX.Element;
5
+ declare function TabsTrigger({ className, ...props }: React.ComponentProps<typeof Tabs$1.Trigger>): React.JSX.Element;
6
+ declare function TabsContent({ className, ...props }: React.ComponentProps<typeof Tabs$1.Content>): React.JSX.Element;
7
+ export { Tabs, TabsContent, TabsList, TabsTrigger };
@@ -0,0 +1,35 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.js";
3
+ import "react";
4
+ import { Tabs as Tabs$1 } from "radix-ui";
5
+ import { jsx } from "react/jsx-runtime";
6
+ // src/components/tabs.tsx
7
+ function Tabs({ className, ...props }) {
8
+ return /* @__PURE__ */ jsx(Tabs$1.Root, {
9
+ "data-slot": "tabs",
10
+ className: cn("flex flex-col gap-2", className),
11
+ ...props
12
+ });
13
+ }
14
+ function TabsList({ className, ...props }) {
15
+ return /* @__PURE__ */ jsx(Tabs$1.List, {
16
+ "data-slot": "tabs-list",
17
+ className: cn("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-1", className),
18
+ ...props
19
+ });
20
+ }
21
+ function TabsTrigger({ className, ...props }) {
22
+ return /* @__PURE__ */ jsx(Tabs$1.Trigger, {
23
+ "data-slot": "tabs-trigger",
24
+ className: cn("text-foreground focus-visible:ring-ring/50 data-[state=active]:bg-background inline-flex items-center justify-center gap-1.5 rounded-md px-2 py-1 text-sm font-medium whitespace-nowrap transition-all focus-visible:ring-[3px] focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
25
+ ...props
26
+ });
27
+ }
28
+ function TabsContent({ className, ...props }) {
29
+ return /* @__PURE__ */ jsx(Tabs$1.Content, {
30
+ "data-slot": "tabs-content",
31
+ className: cn("focus-visible:ring-ring/50 flex-1 outline-none focus-visible:ring-[3px]", className),
32
+ ...props
33
+ });
34
+ }
35
+ export { Tabs, TabsContent, TabsList, TabsTrigger };
@@ -0,0 +1,3 @@
1
+ import * as React from "react";
2
+ declare function Textarea({ className, ...props }: React.ComponentProps<'textarea'>): React.JSX.Element;
3
+ export { Textarea };
@@ -0,0 +1,12 @@
1
+ import { cn } from "../lib/cn.js";
2
+ import "react";
3
+ import { jsx } from "react/jsx-runtime";
4
+ // src/components/textarea.tsx
5
+ function Textarea({ className, ...props }) {
6
+ return /* @__PURE__ */ jsx("textarea", {
7
+ "data-slot": "textarea",
8
+ className: cn("border-input placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 disabled:bg-input/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 flex field-sizing-content min-h-16 w-full rounded-lg border bg-transparent px-2.5 py-2 text-base transition-colors outline-none focus-visible:ring-3 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:ring-3 md:text-sm", className),
9
+ ...props
10
+ });
11
+ }
12
+ export { Textarea };
@@ -0,0 +1,15 @@
1
+ import * as React from "react";
2
+ import { ThemeProvider as ThemeProvider$1 } from "next-themes";
3
+ /**
4
+ * Client boundary around `next-themes`' provider, so a Server Component root
5
+ * layout can mount it. Props are passed through unchanged.
6
+ *
7
+ * @example
8
+ * ```tsx
9
+ * <ThemeProvider attribute="class" defaultTheme="system" enableSystem disableTransitionOnChange>
10
+ * {children}
11
+ * </ThemeProvider>
12
+ * ```
13
+ */
14
+ declare function ThemeProvider({ children, ...props }: React.ComponentProps<typeof ThemeProvider$1>): React.JSX.Element;
15
+ export { ThemeProvider };
@@ -0,0 +1,22 @@
1
+ "use client";
2
+ import { jsx } from "react/jsx-runtime";
3
+ import { ThemeProvider as ThemeProvider$1 } from "next-themes";
4
+ // src/components/theme-provider.tsx
5
+ /**
6
+ * Client boundary around `next-themes`' provider, so a Server Component root
7
+ * layout can mount it. Props are passed through unchanged.
8
+ *
9
+ * @example
10
+ * ```tsx
11
+ * <ThemeProvider attribute="class" defaultTheme="system" enableSystem disableTransitionOnChange>
12
+ * {children}
13
+ * </ThemeProvider>
14
+ * ```
15
+ */
16
+ function ThemeProvider({ children, ...props }) {
17
+ return /* @__PURE__ */ jsx(ThemeProvider$1, {
18
+ ...props,
19
+ children
20
+ });
21
+ }
22
+ export { ThemeProvider };
@@ -0,0 +1,7 @@
1
+ import * as React from "react";
2
+ import { Tooltip as Tooltip$1 } from "radix-ui";
3
+ declare function TooltipProvider({ delayDuration, ...props }: React.ComponentProps<typeof Tooltip$1.Provider>): React.JSX.Element;
4
+ declare function Tooltip({ ...props }: React.ComponentProps<typeof Tooltip$1.Root>): React.JSX.Element;
5
+ declare function TooltipTrigger({ ...props }: React.ComponentProps<typeof Tooltip$1.Trigger>): React.JSX.Element;
6
+ declare function TooltipContent({ className, sideOffset, children, ...props }: React.ComponentProps<typeof Tooltip$1.Content>): React.JSX.Element;
7
+ export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };
@@ -0,0 +1,35 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.js";
3
+ import "react";
4
+ import { Tooltip as Tooltip$1 } from "radix-ui";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
+ // src/components/tooltip.tsx
7
+ function TooltipProvider({ delayDuration = 0, ...props }) {
8
+ return /* @__PURE__ */ jsx(Tooltip$1.Provider, {
9
+ "data-slot": "tooltip-provider",
10
+ delayDuration,
11
+ ...props
12
+ });
13
+ }
14
+ function Tooltip({ ...props }) {
15
+ return /* @__PURE__ */ jsx(Tooltip$1.Root, {
16
+ "data-slot": "tooltip",
17
+ ...props
18
+ });
19
+ }
20
+ function TooltipTrigger({ ...props }) {
21
+ return /* @__PURE__ */ jsx(Tooltip$1.Trigger, {
22
+ "data-slot": "tooltip-trigger",
23
+ ...props
24
+ });
25
+ }
26
+ function TooltipContent({ className, sideOffset = 0, children, ...props }) {
27
+ return /* @__PURE__ */ jsx(Tooltip$1.Portal, { children: /* @__PURE__ */ jsxs(Tooltip$1.Content, {
28
+ "data-slot": "tooltip-content",
29
+ sideOffset,
30
+ className: cn("bg-foreground text-background 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 data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 z-50 inline-flex w-fit max-w-xs origin-(--radix-tooltip-content-transform-origin) items-center gap-1.5 rounded-md px-3 py-1.5 text-xs has-data-[slot=kbd]:pr-1.5 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm", className),
31
+ ...props,
32
+ children: [children, /* @__PURE__ */ jsx(Tooltip$1.Arrow, { className: "bg-foreground fill-foreground z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]" })]
33
+ }) });
34
+ }
35
+ export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };
@@ -0,0 +1,9 @@
1
+ import * as React from "react";
2
+ import { VariantProps } from "class-variance-authority";
3
+ declare const typographyVariants: (props?: ({
4
+ variant?: "blockquote" | "code" | "h1" | "h2" | "h3" | "h4" | "p" | "small" | "pageTitle" | "lead" | "large" | "muted" | null | undefined;
5
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
+ declare function Typography({ variant, as, className, ...props }: VariantProps<typeof typographyVariants> & {
7
+ as?: React.ElementType;
8
+ } & React.HTMLAttributes<HTMLElement>): React.JSX.Element;
9
+ export { Typography, typographyVariants };