@codefast/ui 0.3.15 → 0.3.16-canary.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/dist/components/accordion.d.mts +30 -0
- package/dist/components/accordion.mjs +15 -0
- package/dist/components/alert-dialog.d.mts +60 -0
- package/dist/components/alert-dialog.mjs +30 -0
- package/dist/components/alert.d.mts +21 -0
- package/dist/components/alert.mjs +12 -0
- package/dist/components/aspect-ratio.d.mts +6 -0
- package/dist/components/aspect-ratio.mjs +3 -0
- package/dist/components/avatar.d.mts +18 -0
- package/dist/components/avatar.mjs +9 -0
- package/dist/components/badge.d.mts +9 -0
- package/dist/components/badge.mjs +6 -0
- package/dist/components/breadcrumb.d.mts +42 -0
- package/dist/components/breadcrumb.mjs +21 -0
- package/dist/components/button-group.d.mts +21 -0
- package/dist/components/button-group.mjs +12 -0
- package/dist/components/button.d.mts +9 -0
- package/dist/components/button.mjs +6 -0
- package/dist/components/calendar.d.mts +12 -0
- package/dist/components/calendar.mjs +7 -1
- package/dist/components/card.d.mts +42 -0
- package/dist/components/card.mjs +21 -0
- package/dist/components/carousel.d.mts +33 -0
- package/dist/components/carousel.mjs +15 -0
- package/dist/components/chart.d.mts +40 -1
- package/dist/components/chart.mjs +18 -0
- package/dist/components/checkbox-cards.d.mts +12 -0
- package/dist/components/checkbox-cards.mjs +6 -0
- package/dist/components/checkbox-group.d.mts +12 -0
- package/dist/components/checkbox-group.mjs +6 -0
- package/dist/components/checkbox.d.mts +6 -0
- package/dist/components/checkbox.mjs +3 -0
- package/dist/components/collapsible.d.mts +18 -0
- package/dist/components/collapsible.mjs +9 -0
- package/dist/components/command.d.mts +60 -0
- package/dist/components/command.mjs +30 -0
- package/dist/components/context-menu.d.mts +90 -0
- package/dist/components/context-menu.mjs +45 -0
- package/dist/components/dialog.d.mts +54 -0
- package/dist/components/dialog.mjs +27 -0
- package/dist/components/drawer.d.mts +54 -0
- package/dist/components/drawer.mjs +27 -0
- package/dist/components/dropdown-menu.d.mts +90 -0
- package/dist/components/dropdown-menu.mjs +45 -0
- package/dist/components/empty.d.mts +39 -0
- package/dist/components/empty.mjs +21 -0
- package/dist/components/field.d.mts +64 -1
- package/dist/components/field.mjs +33 -0
- package/dist/components/form.d.mts +42 -0
- package/dist/components/form.mjs +21 -0
- package/dist/components/hover-card.d.mts +24 -0
- package/dist/components/hover-card.mjs +12 -0
- package/dist/components/input-group.d.mts +45 -0
- package/dist/components/input-group.mjs +27 -0
- package/dist/components/input-number.d.mts +6 -0
- package/dist/components/input-number.mjs +3 -0
- package/dist/components/input-otp.d.mts +24 -0
- package/dist/components/input-otp.mjs +12 -0
- package/dist/components/input-password.d.mts +6 -0
- package/dist/components/input-password.mjs +3 -0
- package/dist/components/input-search.d.mts +6 -0
- package/dist/components/input-search.mjs +3 -0
- package/dist/components/input.d.mts +6 -0
- package/dist/components/input.mjs +3 -0
- package/dist/components/item.d.mts +66 -0
- package/dist/components/item.mjs +36 -0
- package/dist/components/kbd.d.mts +12 -0
- package/dist/components/kbd.mjs +6 -0
- package/dist/components/label.d.mts +6 -0
- package/dist/components/label.mjs +3 -0
- package/dist/components/menubar.d.mts +96 -0
- package/dist/components/menubar.mjs +48 -0
- package/dist/components/native-select.d.mts +18 -0
- package/dist/components/native-select.mjs +9 -0
- package/dist/components/navigation-menu.d.mts +39 -0
- package/dist/components/navigation-menu.mjs +21 -0
- package/dist/components/pagination.d.mts +42 -0
- package/dist/components/pagination.mjs +21 -0
- package/dist/components/popover.d.mts +30 -0
- package/dist/components/popover.mjs +15 -0
- package/dist/components/progress-circle.d.mts +9 -0
- package/dist/components/progress-circle.mjs +6 -0
- package/dist/components/progress.d.mts +6 -0
- package/dist/components/progress.mjs +3 -0
- package/dist/components/radio-cards.d.mts +12 -0
- package/dist/components/radio-cards.mjs +6 -0
- package/dist/components/radio-group.d.mts +12 -0
- package/dist/components/radio-group.mjs +6 -0
- package/dist/components/radio.d.mts +6 -0
- package/dist/components/radio.mjs +3 -0
- package/dist/components/resizable.d.mts +18 -0
- package/dist/components/resizable.mjs +9 -0
- package/dist/components/scroll-area.d.mts +15 -0
- package/dist/components/scroll-area.mjs +9 -0
- package/dist/components/select.d.mts +60 -0
- package/dist/components/select.mjs +30 -0
- package/dist/components/separator.d.mts +15 -0
- package/dist/components/separator.mjs +9 -0
- package/dist/components/sheet.d.mts +57 -0
- package/dist/components/sheet.mjs +30 -0
- package/dist/components/sidebar.d.mts +141 -0
- package/dist/components/sidebar.mjs +72 -0
- package/dist/components/skeleton.d.mts +6 -0
- package/dist/components/skeleton.mjs +3 -0
- package/dist/components/slider.d.mts +6 -0
- package/dist/components/slider.mjs +3 -0
- package/dist/components/sonner.d.mts +6 -0
- package/dist/components/sonner.mjs +3 -0
- package/dist/components/spinner.d.mts +6 -0
- package/dist/components/spinner.mjs +3 -0
- package/dist/components/switch.d.mts +6 -0
- package/dist/components/switch.mjs +3 -0
- package/dist/components/table.d.mts +48 -0
- package/dist/components/table.mjs +24 -0
- package/dist/components/tabs.d.mts +24 -0
- package/dist/components/tabs.mjs +12 -0
- package/dist/components/textarea.d.mts +6 -0
- package/dist/components/textarea.mjs +3 -0
- package/dist/components/toggle-group.d.mts +12 -0
- package/dist/components/toggle-group.mjs +6 -0
- package/dist/components/toggle.d.mts +12 -0
- package/dist/components/toggle.mjs +6 -0
- package/dist/components/tooltip.d.mts +30 -0
- package/dist/components/tooltip.mjs +15 -0
- package/dist/hooks/use-animated-value.d.mts +2 -0
- package/dist/hooks/use-animated-value.mjs +2 -0
- package/dist/hooks/use-copy-to-clipboard.d.mts +2 -0
- package/dist/hooks/use-copy-to-clipboard.mjs +2 -0
- package/dist/hooks/use-is-mobile.d.mts +2 -0
- package/dist/hooks/use-is-mobile.mjs +2 -0
- package/dist/hooks/use-media-query.d.mts +2 -0
- package/dist/hooks/use-media-query.mjs +2 -0
- package/dist/hooks/use-mutation-observer.d.mts +2 -0
- package/dist/hooks/use-mutation-observer.mjs +2 -0
- package/dist/hooks/use-pagination.d.mts +8 -1
- package/dist/hooks/use-pagination.mjs +4 -0
- package/dist/lib/utils.d.mts +1 -1
- package/dist/primitives/checkbox-group.d.mts +15 -3
- package/dist/primitives/checkbox-group.mjs +6 -0
- package/dist/primitives/input-number.d.mts +22 -0
- package/dist/primitives/input-number.mjs +12 -0
- package/dist/primitives/input.d.mts +10 -0
- package/dist/primitives/input.mjs +6 -0
- package/dist/primitives/progress-circle.d.mts +31 -1
- package/dist/primitives/progress-circle.mjs +12 -0
- package/package.json +17 -9
|
@@ -2,6 +2,9 @@ import { cn } from "../lib/utils.mjs";
|
|
|
2
2
|
import { ChevronDownIcon } from "lucide-react";
|
|
3
3
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
4
|
//#region src/components/native-select.tsx
|
|
5
|
+
/**
|
|
6
|
+
* @since 0.3.16-canary.0
|
|
7
|
+
*/
|
|
5
8
|
function NativeSelect({ className, ...props }) {
|
|
6
9
|
return /* @__PURE__ */ jsxs("div", {
|
|
7
10
|
className: cn("group/native-select relative", "w-fit", "has-[select:disabled]:opacity-50"),
|
|
@@ -17,12 +20,18 @@ function NativeSelect({ className, ...props }) {
|
|
|
17
20
|
})]
|
|
18
21
|
});
|
|
19
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
* @since 0.3.16-canary.0
|
|
25
|
+
*/
|
|
20
26
|
function NativeSelectOption({ ...props }) {
|
|
21
27
|
return /* @__PURE__ */ jsx("option", {
|
|
22
28
|
"data-slot": "native-select-option",
|
|
23
29
|
...props
|
|
24
30
|
});
|
|
25
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* @since 0.3.16-canary.0
|
|
34
|
+
*/
|
|
26
35
|
function NativeSelectOptGroup({ className, ...props }) {
|
|
27
36
|
return /* @__PURE__ */ jsx("optgroup", {
|
|
28
37
|
className: cn(className),
|
|
@@ -3,39 +3,78 @@ import { ComponentProps, JSX } from "react";
|
|
|
3
3
|
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
|
|
4
4
|
|
|
5
5
|
//#region src/components/navigation-menu.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
declare const navigationMenuTriggerVariants: _$_codefast_tailwind_variants0.VariantFunctionType<_$_codefast_tailwind_variants0.ConfigurationSchema, Record<string, never>>;
|
|
10
|
+
/**
|
|
11
|
+
* @since 0.3.16-canary.0
|
|
12
|
+
*/
|
|
7
13
|
interface NavigationMenuProps extends ComponentProps<typeof NavigationMenuPrimitive.Root> {
|
|
8
14
|
viewport?: boolean;
|
|
9
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* @since 0.3.16-canary.0
|
|
18
|
+
*/
|
|
10
19
|
declare function NavigationMenu({
|
|
11
20
|
children,
|
|
12
21
|
className,
|
|
13
22
|
viewport,
|
|
14
23
|
...props
|
|
15
24
|
}: NavigationMenuProps): JSX.Element;
|
|
25
|
+
/**
|
|
26
|
+
* @since 0.3.16-canary.0
|
|
27
|
+
*/
|
|
16
28
|
type NavigationMenuListProps = ComponentProps<typeof NavigationMenuPrimitive.List>;
|
|
29
|
+
/**
|
|
30
|
+
* @since 0.3.16-canary.0
|
|
31
|
+
*/
|
|
17
32
|
declare function NavigationMenuList({
|
|
18
33
|
children,
|
|
19
34
|
className,
|
|
20
35
|
...props
|
|
21
36
|
}: NavigationMenuListProps): JSX.Element;
|
|
37
|
+
/**
|
|
38
|
+
* @since 0.3.16-canary.0
|
|
39
|
+
*/
|
|
22
40
|
type NavigationMenuItemProps = ComponentProps<typeof NavigationMenuPrimitive.Item>;
|
|
41
|
+
/**
|
|
42
|
+
* @since 0.3.16-canary.0
|
|
43
|
+
*/
|
|
23
44
|
declare function NavigationMenuItem({
|
|
24
45
|
className,
|
|
25
46
|
...props
|
|
26
47
|
}: NavigationMenuItemProps): JSX.Element;
|
|
48
|
+
/**
|
|
49
|
+
* @since 0.3.16-canary.0
|
|
50
|
+
*/
|
|
27
51
|
type NavigationMenuTriggerProps = ComponentProps<typeof NavigationMenuPrimitive.Trigger>;
|
|
52
|
+
/**
|
|
53
|
+
* @since 0.3.16-canary.0
|
|
54
|
+
*/
|
|
28
55
|
declare function NavigationMenuTrigger({
|
|
29
56
|
children,
|
|
30
57
|
className,
|
|
31
58
|
...props
|
|
32
59
|
}: NavigationMenuTriggerProps): JSX.Element;
|
|
60
|
+
/**
|
|
61
|
+
* @since 0.3.16-canary.0
|
|
62
|
+
*/
|
|
33
63
|
type NavigationMenuContentProps = ComponentProps<typeof NavigationMenuPrimitive.Content>;
|
|
64
|
+
/**
|
|
65
|
+
* @since 0.3.16-canary.0
|
|
66
|
+
*/
|
|
34
67
|
declare function NavigationMenuContent({
|
|
35
68
|
className,
|
|
36
69
|
...props
|
|
37
70
|
}: NavigationMenuContentProps): JSX.Element;
|
|
71
|
+
/**
|
|
72
|
+
* @since 0.3.16-canary.0
|
|
73
|
+
*/
|
|
38
74
|
type NavigationMenuLinkProps = ComponentProps<typeof NavigationMenuPrimitive.Link>;
|
|
75
|
+
/**
|
|
76
|
+
* @since 0.3.16-canary.0
|
|
77
|
+
*/
|
|
39
78
|
declare function NavigationMenuLink({
|
|
40
79
|
className,
|
|
41
80
|
...props
|
|
@@ -4,10 +4,16 @@ import { ChevronDownIcon } from "lucide-react";
|
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
|
|
6
6
|
//#region src/components/navigation-menu.tsx
|
|
7
|
+
/**
|
|
8
|
+
* @since 0.3.16-canary.0
|
|
9
|
+
*/
|
|
7
10
|
const navigationMenuTriggerVariants = tv({ base: buttonVariants({
|
|
8
11
|
className: "data-open:bg-secondary/50 data-open:text-secondary-foreground group/navigation-menu-trigger focus-visible:bg-secondary dark:hover:not-disabled:bg-secondary",
|
|
9
12
|
variant: "ghost"
|
|
10
13
|
}) });
|
|
14
|
+
/**
|
|
15
|
+
* @since 0.3.16-canary.0
|
|
16
|
+
*/
|
|
11
17
|
function NavigationMenu({ children, className, viewport = true, ...props }) {
|
|
12
18
|
return /* @__PURE__ */ jsxs(NavigationMenuPrimitive.Root, {
|
|
13
19
|
className: cn("group/navigation-menu relative flex max-w-max flex-1 items-center justify-center", className),
|
|
@@ -17,6 +23,9 @@ function NavigationMenu({ children, className, viewport = true, ...props }) {
|
|
|
17
23
|
children: [children, viewport ? /* @__PURE__ */ jsx(NavigationMenuViewport, {}) : null]
|
|
18
24
|
});
|
|
19
25
|
}
|
|
26
|
+
/**
|
|
27
|
+
* @since 0.3.16-canary.0
|
|
28
|
+
*/
|
|
20
29
|
function NavigationMenuList({ children, className, ...props }) {
|
|
21
30
|
return /* @__PURE__ */ jsxs(NavigationMenuPrimitive.List, {
|
|
22
31
|
className: cn("flex flex-1 items-center justify-center gap-1", "list-none", className),
|
|
@@ -25,6 +34,9 @@ function NavigationMenuList({ children, className, ...props }) {
|
|
|
25
34
|
children: [children, /* @__PURE__ */ jsx(NavigationMenuIndicator, { className: "invisible" })]
|
|
26
35
|
});
|
|
27
36
|
}
|
|
37
|
+
/**
|
|
38
|
+
* @since 0.3.16-canary.0
|
|
39
|
+
*/
|
|
28
40
|
function NavigationMenuItem({ className, ...props }) {
|
|
29
41
|
return /* @__PURE__ */ jsx(NavigationMenuPrimitive.Item, {
|
|
30
42
|
className: cn("group-data-[viewport=false]/navigation-menu:relative", className),
|
|
@@ -32,6 +44,9 @@ function NavigationMenuItem({ className, ...props }) {
|
|
|
32
44
|
...props
|
|
33
45
|
});
|
|
34
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* @since 0.3.16-canary.0
|
|
49
|
+
*/
|
|
35
50
|
function NavigationMenuTrigger({ children, className, ...props }) {
|
|
36
51
|
return /* @__PURE__ */ jsxs(NavigationMenuPrimitive.Trigger, {
|
|
37
52
|
className: navigationMenuTriggerVariants({ className }),
|
|
@@ -43,6 +58,9 @@ function NavigationMenuTrigger({ children, className, ...props }) {
|
|
|
43
58
|
})]
|
|
44
59
|
});
|
|
45
60
|
}
|
|
61
|
+
/**
|
|
62
|
+
* @since 0.3.16-canary.0
|
|
63
|
+
*/
|
|
46
64
|
function NavigationMenuContent({ className, ...props }) {
|
|
47
65
|
return /* @__PURE__ */ jsx(NavigationMenuPrimitive.Content, {
|
|
48
66
|
className: cn("top-0 left-0", "w-full", "group-data-[viewport=false]/navigation-menu:top-full group-data-[viewport=false]/navigation-menu:mt-2 group-data-[viewport=false]/navigation-menu:overflow-hidden group-data-[viewport=false]/navigation-menu:rounded-lg group-data-[viewport=false]/navigation-menu:border group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:p-1 group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:shadow", "group-data-[viewport=true]/navigation-menu:p-2", "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", "ease-ui data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in-0", "data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out-0", "md:absolute md:w-auto", "group-data-[viewport=false]/navigation-menu:data-open:animate-in group-data-[viewport=false]/navigation-menu:data-open:fade-in-0 group-data-[viewport=false]/navigation-menu:data-open:zoom-in-95", "group-data-[viewport=false]/navigation-menu:data-closed:animate-out group-data-[viewport=false]/navigation-menu:data-closed:fade-out-0 group-data-[viewport=false]/navigation-menu:data-closed:zoom-out-95", className),
|
|
@@ -50,6 +68,9 @@ function NavigationMenuContent({ className, ...props }) {
|
|
|
50
68
|
...props
|
|
51
69
|
});
|
|
52
70
|
}
|
|
71
|
+
/**
|
|
72
|
+
* @since 0.3.16-canary.0
|
|
73
|
+
*/
|
|
53
74
|
function NavigationMenuLink({ className, ...props }) {
|
|
54
75
|
return /* @__PURE__ */ jsx(NavigationMenuPrimitive.Link, {
|
|
55
76
|
className: cn("flex flex-col gap-1", "p-2", "rounded-sm outline-hidden", "text-sm", "transition", "hover:bg-accent hover:text-accent-foreground", "focus:bg-accent focus:text-accent-foreground", "data-active:bg-accent/50 data-active:text-accent-foreground", "data-active:hover:bg-accent", "data-active:focus:bg-accent", "data-[variant=destructive]:[&_svg:not([class*='text-'])]:text-destructive/80", "[&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", "[&_svg:not([class*='text-'])]:text-muted-foreground", className),
|
|
@@ -3,21 +3,45 @@ import { buttonVariants } from "./button.mjs";
|
|
|
3
3
|
import { ComponentProps, JSX } from "react";
|
|
4
4
|
|
|
5
5
|
//#region src/components/pagination.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
type PaginationProps = ComponentProps<"nav">;
|
|
10
|
+
/**
|
|
11
|
+
* @since 0.3.16-canary.0
|
|
12
|
+
*/
|
|
7
13
|
declare function Pagination({
|
|
8
14
|
className,
|
|
9
15
|
...props
|
|
10
16
|
}: PaginationProps): JSX.Element;
|
|
17
|
+
/**
|
|
18
|
+
* @since 0.3.16-canary.0
|
|
19
|
+
*/
|
|
11
20
|
type PaginationContentProps = ComponentProps<"ul">;
|
|
21
|
+
/**
|
|
22
|
+
* @since 0.3.16-canary.0
|
|
23
|
+
*/
|
|
12
24
|
declare function PaginationContent({
|
|
13
25
|
className,
|
|
14
26
|
...props
|
|
15
27
|
}: PaginationContentProps): JSX.Element;
|
|
28
|
+
/**
|
|
29
|
+
* @since 0.3.16-canary.0
|
|
30
|
+
*/
|
|
16
31
|
type PaginationItemProps = ComponentProps<"li">;
|
|
32
|
+
/**
|
|
33
|
+
* @since 0.3.16-canary.0
|
|
34
|
+
*/
|
|
17
35
|
declare function PaginationItem(props: PaginationItemProps): JSX.Element;
|
|
36
|
+
/**
|
|
37
|
+
* @since 0.3.16-canary.0
|
|
38
|
+
*/
|
|
18
39
|
interface PaginationLinkProps extends ComponentProps<"a">, Pick<VariantProps<typeof buttonVariants>, "size"> {
|
|
19
40
|
isActive?: boolean;
|
|
20
41
|
}
|
|
42
|
+
/**
|
|
43
|
+
* @since 0.3.16-canary.0
|
|
44
|
+
*/
|
|
21
45
|
declare function PaginationLink({
|
|
22
46
|
children,
|
|
23
47
|
className,
|
|
@@ -25,19 +49,37 @@ declare function PaginationLink({
|
|
|
25
49
|
size,
|
|
26
50
|
...props
|
|
27
51
|
}: PaginationLinkProps): JSX.Element;
|
|
52
|
+
/**
|
|
53
|
+
* @since 0.3.16-canary.0
|
|
54
|
+
*/
|
|
28
55
|
interface PaginationPreviousProps extends ComponentProps<"a">, Pick<VariantProps<typeof buttonVariants>, "size"> {
|
|
29
56
|
isActive?: boolean;
|
|
30
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* @since 0.3.16-canary.0
|
|
60
|
+
*/
|
|
31
61
|
declare function PaginationPrevious({
|
|
32
62
|
...props
|
|
33
63
|
}: PaginationPreviousProps): JSX.Element;
|
|
64
|
+
/**
|
|
65
|
+
* @since 0.3.16-canary.0
|
|
66
|
+
*/
|
|
34
67
|
interface PaginationNextProps extends ComponentProps<"a">, Pick<VariantProps<typeof buttonVariants>, "size"> {
|
|
35
68
|
isActive?: boolean;
|
|
36
69
|
}
|
|
70
|
+
/**
|
|
71
|
+
* @since 0.3.16-canary.0
|
|
72
|
+
*/
|
|
37
73
|
declare function PaginationNext({
|
|
38
74
|
...props
|
|
39
75
|
}: PaginationNextProps): JSX.Element;
|
|
76
|
+
/**
|
|
77
|
+
* @since 0.3.16-canary.0
|
|
78
|
+
*/
|
|
40
79
|
type PaginationEllipsisProps = ComponentProps<"span">;
|
|
80
|
+
/**
|
|
81
|
+
* @since 0.3.16-canary.0
|
|
82
|
+
*/
|
|
41
83
|
declare function PaginationEllipsis({
|
|
42
84
|
className,
|
|
43
85
|
...props
|
|
@@ -3,6 +3,9 @@ import { buttonVariants } from "./button.mjs";
|
|
|
3
3
|
import { ChevronLeftIcon, ChevronRightIcon, EllipsisIcon } from "lucide-react";
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/pagination.tsx
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
function Pagination({ className, ...props }) {
|
|
7
10
|
return /* @__PURE__ */ jsx("nav", {
|
|
8
11
|
"aria-label": "pagination",
|
|
@@ -11,6 +14,9 @@ function Pagination({ className, ...props }) {
|
|
|
11
14
|
...props
|
|
12
15
|
});
|
|
13
16
|
}
|
|
17
|
+
/**
|
|
18
|
+
* @since 0.3.16-canary.0
|
|
19
|
+
*/
|
|
14
20
|
function PaginationContent({ className, ...props }) {
|
|
15
21
|
return /* @__PURE__ */ jsx("ul", {
|
|
16
22
|
className: cn("flex flex-row items-center gap-1", className),
|
|
@@ -18,12 +24,18 @@ function PaginationContent({ className, ...props }) {
|
|
|
18
24
|
...props
|
|
19
25
|
});
|
|
20
26
|
}
|
|
27
|
+
/**
|
|
28
|
+
* @since 0.3.16-canary.0
|
|
29
|
+
*/
|
|
21
30
|
function PaginationItem(props) {
|
|
22
31
|
return /* @__PURE__ */ jsx("li", {
|
|
23
32
|
"data-slot": "pagination-item",
|
|
24
33
|
...props
|
|
25
34
|
});
|
|
26
35
|
}
|
|
36
|
+
/**
|
|
37
|
+
* @since 0.3.16-canary.0
|
|
38
|
+
*/
|
|
27
39
|
function PaginationLink({ children, className, isActive, size = "icon", ...props }) {
|
|
28
40
|
return /* @__PURE__ */ jsx("a", {
|
|
29
41
|
"aria-current": isActive ? "page" : void 0,
|
|
@@ -37,6 +49,9 @@ function PaginationLink({ children, className, isActive, size = "icon", ...props
|
|
|
37
49
|
children
|
|
38
50
|
});
|
|
39
51
|
}
|
|
52
|
+
/**
|
|
53
|
+
* @since 0.3.16-canary.0
|
|
54
|
+
*/
|
|
40
55
|
function PaginationPrevious({ ...props }) {
|
|
41
56
|
return /* @__PURE__ */ jsxs(PaginationLink, {
|
|
42
57
|
"aria-label": "Go to previous page",
|
|
@@ -46,6 +61,9 @@ function PaginationPrevious({ ...props }) {
|
|
|
46
61
|
children: [/* @__PURE__ */ jsx(ChevronLeftIcon, { className: "size-4" }), /* @__PURE__ */ jsx("span", { children: "Previous" })]
|
|
47
62
|
});
|
|
48
63
|
}
|
|
64
|
+
/**
|
|
65
|
+
* @since 0.3.16-canary.0
|
|
66
|
+
*/
|
|
49
67
|
function PaginationNext({ ...props }) {
|
|
50
68
|
return /* @__PURE__ */ jsxs(PaginationLink, {
|
|
51
69
|
"aria-label": "Go to next page",
|
|
@@ -55,6 +73,9 @@ function PaginationNext({ ...props }) {
|
|
|
55
73
|
children: [/* @__PURE__ */ jsx("span", { children: "Next" }), /* @__PURE__ */ jsx(ChevronRightIcon, {})]
|
|
56
74
|
});
|
|
57
75
|
}
|
|
76
|
+
/**
|
|
77
|
+
* @since 0.3.16-canary.0
|
|
78
|
+
*/
|
|
58
79
|
function PaginationEllipsis({ className, ...props }) {
|
|
59
80
|
return /* @__PURE__ */ jsxs("span", {
|
|
60
81
|
"aria-hidden": true,
|
|
@@ -2,26 +2,56 @@ import { ComponentProps, JSX } from "react";
|
|
|
2
2
|
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
|
3
3
|
|
|
4
4
|
//#region src/components/popover.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* @since 0.3.16-canary.0
|
|
7
|
+
*/
|
|
5
8
|
type PopoverProps = ComponentProps<typeof PopoverPrimitive.Root>;
|
|
9
|
+
/**
|
|
10
|
+
* @since 0.3.16-canary.0
|
|
11
|
+
*/
|
|
6
12
|
declare function Popover({
|
|
7
13
|
...props
|
|
8
14
|
}: PopoverProps): JSX.Element;
|
|
15
|
+
/**
|
|
16
|
+
* @since 0.3.16-canary.0
|
|
17
|
+
*/
|
|
9
18
|
type PopoverTriggerProps = ComponentProps<typeof PopoverPrimitive.Trigger>;
|
|
19
|
+
/**
|
|
20
|
+
* @since 0.3.16-canary.0
|
|
21
|
+
*/
|
|
10
22
|
declare function PopoverTrigger({
|
|
11
23
|
...props
|
|
12
24
|
}: PopoverTriggerProps): JSX.Element;
|
|
25
|
+
/**
|
|
26
|
+
* @since 0.3.16-canary.0
|
|
27
|
+
*/
|
|
13
28
|
type PopoverAnchorProps = ComponentProps<typeof PopoverPrimitive.Anchor>;
|
|
29
|
+
/**
|
|
30
|
+
* @since 0.3.16-canary.0
|
|
31
|
+
*/
|
|
14
32
|
declare function PopoverAnchor({
|
|
15
33
|
...props
|
|
16
34
|
}: PopoverAnchorProps): JSX.Element;
|
|
35
|
+
/**
|
|
36
|
+
* @since 0.3.16-canary.0
|
|
37
|
+
*/
|
|
17
38
|
type PopoverContentProps = ComponentProps<typeof PopoverPrimitive.Content>;
|
|
39
|
+
/**
|
|
40
|
+
* @since 0.3.16-canary.0
|
|
41
|
+
*/
|
|
18
42
|
declare function PopoverContent({
|
|
19
43
|
align,
|
|
20
44
|
className,
|
|
21
45
|
sideOffset,
|
|
22
46
|
...props
|
|
23
47
|
}: PopoverContentProps): JSX.Element;
|
|
48
|
+
/**
|
|
49
|
+
* @since 0.3.16-canary.0
|
|
50
|
+
*/
|
|
24
51
|
type PopoverArrowProps = ComponentProps<typeof PopoverPrimitive.Arrow>;
|
|
52
|
+
/**
|
|
53
|
+
* @since 0.3.16-canary.0
|
|
54
|
+
*/
|
|
25
55
|
declare function PopoverArrow({
|
|
26
56
|
className,
|
|
27
57
|
...props
|
|
@@ -3,24 +3,36 @@ import { cn } from "../lib/utils.mjs";
|
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
|
5
5
|
//#region src/components/popover.tsx
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
function Popover({ ...props }) {
|
|
7
10
|
return /* @__PURE__ */ jsx(PopoverPrimitive.Root, {
|
|
8
11
|
"data-slot": "popover",
|
|
9
12
|
...props
|
|
10
13
|
});
|
|
11
14
|
}
|
|
15
|
+
/**
|
|
16
|
+
* @since 0.3.16-canary.0
|
|
17
|
+
*/
|
|
12
18
|
function PopoverTrigger({ ...props }) {
|
|
13
19
|
return /* @__PURE__ */ jsx(PopoverPrimitive.Trigger, {
|
|
14
20
|
"data-slot": "popover-trigger",
|
|
15
21
|
...props
|
|
16
22
|
});
|
|
17
23
|
}
|
|
24
|
+
/**
|
|
25
|
+
* @since 0.3.16-canary.0
|
|
26
|
+
*/
|
|
18
27
|
function PopoverAnchor({ ...props }) {
|
|
19
28
|
return /* @__PURE__ */ jsx(PopoverPrimitive.Anchor, {
|
|
20
29
|
"data-slot": "popover-anchor",
|
|
21
30
|
...props
|
|
22
31
|
});
|
|
23
32
|
}
|
|
33
|
+
/**
|
|
34
|
+
* @since 0.3.16-canary.0
|
|
35
|
+
*/
|
|
24
36
|
function PopoverContent({ align = "center", className, sideOffset = 4, ...props }) {
|
|
25
37
|
return /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsx(PopoverPrimitive.Content, {
|
|
26
38
|
align,
|
|
@@ -30,6 +42,9 @@ function PopoverContent({ align = "center", className, sideOffset = 4, ...props
|
|
|
30
42
|
...props
|
|
31
43
|
}) });
|
|
32
44
|
}
|
|
45
|
+
/**
|
|
46
|
+
* @since 0.3.16-canary.0
|
|
47
|
+
*/
|
|
33
48
|
function PopoverArrow({ className, ...props }) {
|
|
34
49
|
return /* @__PURE__ */ jsx(PopoverPrimitive.Arrow, {
|
|
35
50
|
className: cn("fill-popover", className),
|
|
@@ -4,6 +4,9 @@ import * as _$_codefast_tailwind_variants0 from "@codefast/tailwind-variants";
|
|
|
4
4
|
import { ComponentProps, JSX } from "react";
|
|
5
5
|
|
|
6
6
|
//#region src/components/progress-circle.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* @since 0.3.16-canary.0
|
|
9
|
+
*/
|
|
7
10
|
declare const progressCircleVariants: _$_codefast_tailwind_variants0.VariantFunctionType<{
|
|
8
11
|
size: {
|
|
9
12
|
sm: {
|
|
@@ -44,6 +47,9 @@ declare const progressCircleVariants: _$_codefast_tailwind_variants0.VariantFunc
|
|
|
44
47
|
svg: string;
|
|
45
48
|
track: string;
|
|
46
49
|
}>;
|
|
50
|
+
/**
|
|
51
|
+
* @since 0.3.16-canary.0
|
|
52
|
+
*/
|
|
47
53
|
interface ProgressCircleProps extends Omit<ComponentProps<typeof ProgressCircleProvider>, "children" | "size">, VariantProps<typeof progressCircleVariants> {
|
|
48
54
|
/**
|
|
49
55
|
* Enables animation effect when value changes
|
|
@@ -102,6 +108,9 @@ interface ProgressCircleProps extends Omit<ComponentProps<typeof ProgressCircleP
|
|
|
102
108
|
*/
|
|
103
109
|
sizeInPixels?: number;
|
|
104
110
|
}
|
|
111
|
+
/**
|
|
112
|
+
* @since 0.3.16-canary.0
|
|
113
|
+
*/
|
|
105
114
|
declare function ProgressCircle({
|
|
106
115
|
animate,
|
|
107
116
|
animationDuration,
|
|
@@ -5,6 +5,9 @@ import { Indicator as ProgressCircleIndicator, ProgressCircle as ProgressCircle$
|
|
|
5
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
6
|
import { useCallback, useMemo } from "react";
|
|
7
7
|
//#region src/components/progress-circle.tsx
|
|
8
|
+
/**
|
|
9
|
+
* @since 0.3.16-canary.0
|
|
10
|
+
*/
|
|
8
11
|
const progressCircleVariants = tv({
|
|
9
12
|
defaultVariants: {
|
|
10
13
|
size: "md",
|
|
@@ -47,6 +50,9 @@ const progressCircleVariants = tv({
|
|
|
47
50
|
}
|
|
48
51
|
}
|
|
49
52
|
});
|
|
53
|
+
/**
|
|
54
|
+
* @since 0.3.16-canary.0
|
|
55
|
+
*/
|
|
50
56
|
function ProgressCircle({ animate = true, animationDuration = 1e3, className, classNames, customLabel, showValue = false, size, sizeInPixels, strokeWidth, thickness = "regular", value = 0, variant = "default", ...props }) {
|
|
51
57
|
const displayValue = useAnimatedValue(value, animationDuration, animate);
|
|
52
58
|
const actualSize = useMemo(() => sizeInPixels ?? getActualSize(size), [sizeInPixels, size]);
|
|
@@ -2,7 +2,13 @@ import { ComponentProps, JSX } from "react";
|
|
|
2
2
|
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
|
3
3
|
|
|
4
4
|
//#region src/components/progress.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* @since 0.3.16-canary.0
|
|
7
|
+
*/
|
|
5
8
|
type ProgressProps = ComponentProps<typeof ProgressPrimitive.Root>;
|
|
9
|
+
/**
|
|
10
|
+
* @since 0.3.16-canary.0
|
|
11
|
+
*/
|
|
6
12
|
declare function Progress({
|
|
7
13
|
className,
|
|
8
14
|
value,
|
|
@@ -3,6 +3,9 @@ import { cn } from "../lib/utils.mjs";
|
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
|
5
5
|
//#region src/components/progress.tsx
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
function Progress({ className, value, ...props }) {
|
|
7
10
|
return /* @__PURE__ */ jsx(ProgressPrimitive.Root, {
|
|
8
11
|
className: cn("relative", "h-2 w-full overflow-hidden", "rounded-full", "bg-primary/20", className),
|
|
@@ -2,9 +2,21 @@ import { ComponentProps, JSX } from "react";
|
|
|
2
2
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
3
3
|
|
|
4
4
|
//#region src/components/radio-cards.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* @since 0.3.16-canary.0
|
|
7
|
+
*/
|
|
5
8
|
type RadioCardsProps = ComponentProps<typeof RadioGroupPrimitive.Root>;
|
|
9
|
+
/**
|
|
10
|
+
* @since 0.3.16-canary.0
|
|
11
|
+
*/
|
|
6
12
|
declare function RadioCards(props: RadioCardsProps): JSX.Element;
|
|
13
|
+
/**
|
|
14
|
+
* @since 0.3.16-canary.0
|
|
15
|
+
*/
|
|
7
16
|
type RadioCardsItemProps = ComponentProps<typeof RadioGroupPrimitive.Item>;
|
|
17
|
+
/**
|
|
18
|
+
* @since 0.3.16-canary.0
|
|
19
|
+
*/
|
|
8
20
|
declare function RadioCardsItem({
|
|
9
21
|
children,
|
|
10
22
|
className,
|
|
@@ -4,12 +4,18 @@ import { Label } from "./label.mjs";
|
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
6
6
|
//#region src/components/radio-cards.tsx
|
|
7
|
+
/**
|
|
8
|
+
* @since 0.3.16-canary.0
|
|
9
|
+
*/
|
|
7
10
|
function RadioCards(props) {
|
|
8
11
|
return /* @__PURE__ */ jsx(RadioGroupPrimitive.Root, {
|
|
9
12
|
"data-slot": "radio-cards",
|
|
10
13
|
...props
|
|
11
14
|
});
|
|
12
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* @since 0.3.16-canary.0
|
|
18
|
+
*/
|
|
13
19
|
function RadioCardsItem({ children, className, ...props }) {
|
|
14
20
|
return /* @__PURE__ */ jsxs(Label, {
|
|
15
21
|
className: cn("flex items-start gap-3", "p-3", "rounded-lg border border-input", "transition", "hover:not-has-disabled:not-has-aria-checked:bg-secondary", "has-focus-visible:border-ring", "has-disabled:opacity-50", "has-aria-checked:border-primary has-aria-checked:bg-primary/10"),
|
|
@@ -2,12 +2,24 @@ import { ComponentProps, JSX } from "react";
|
|
|
2
2
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
3
3
|
|
|
4
4
|
//#region src/components/radio-group.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* @since 0.3.16-canary.0
|
|
7
|
+
*/
|
|
5
8
|
type RadioGroupProps = ComponentProps<typeof RadioGroupPrimitive.Root>;
|
|
9
|
+
/**
|
|
10
|
+
* @since 0.3.16-canary.0
|
|
11
|
+
*/
|
|
6
12
|
declare function RadioGroup({
|
|
7
13
|
className,
|
|
8
14
|
...props
|
|
9
15
|
}: RadioGroupProps): JSX.Element;
|
|
16
|
+
/**
|
|
17
|
+
* @since 0.3.16-canary.0
|
|
18
|
+
*/
|
|
10
19
|
type RadioGroupItemProps = ComponentProps<typeof RadioGroupPrimitive.Item>;
|
|
20
|
+
/**
|
|
21
|
+
* @since 0.3.16-canary.0
|
|
22
|
+
*/
|
|
11
23
|
declare function RadioGroupItem({
|
|
12
24
|
className,
|
|
13
25
|
...props
|
|
@@ -3,6 +3,9 @@ import { cn } from "../lib/utils.mjs";
|
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
5
5
|
//#region src/components/radio-group.tsx
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
function RadioGroup({ className, ...props }) {
|
|
7
10
|
return /* @__PURE__ */ jsx(RadioGroupPrimitive.Root, {
|
|
8
11
|
className: cn("grid gap-2", className),
|
|
@@ -10,6 +13,9 @@ function RadioGroup({ className, ...props }) {
|
|
|
10
13
|
...props
|
|
11
14
|
});
|
|
12
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* @since 0.3.16-canary.0
|
|
18
|
+
*/
|
|
13
19
|
function RadioGroupItem({ className, ...props }) {
|
|
14
20
|
return /* @__PURE__ */ jsx(RadioGroupPrimitive.Item, {
|
|
15
21
|
className: cn("peer inline-flex size-4 shrink-0 items-center justify-center", "rounded-full border border-input shadow-xs outline-hidden", "transition", "hover:not-disabled:not-aria-checked:border-ring/60", "focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50", "disabled:opacity-50", "aria-checked:border-primary aria-checked:bg-primary", "focus-visible:aria-checked:ring-primary/20", "aria-invalid:border-destructive aria-invalid:ring-destructive/20", "hover:not-disabled:not-aria-checked:aria-invalid:border-destructive/60", "aria-checked:aria-invalid:bg-destructive", "dark:bg-input/30", "dark:focus-visible:aria-checked:ring-primary/40", "dark:aria-invalid:ring-destructive/40", className),
|
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
import { ComponentProps, JSX } from "react";
|
|
2
2
|
|
|
3
3
|
//#region src/components/radio.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* @since 0.3.16-canary.0
|
|
6
|
+
*/
|
|
4
7
|
interface RadioProps extends Omit<ComponentProps<"input">, "type"> {
|
|
5
8
|
onValueChange?: (value: string) => void;
|
|
6
9
|
}
|
|
10
|
+
/**
|
|
11
|
+
* @since 0.3.16-canary.0
|
|
12
|
+
*/
|
|
7
13
|
declare function Radio({
|
|
8
14
|
className,
|
|
9
15
|
onChange,
|
|
@@ -3,6 +3,9 @@ import { cn } from "../lib/utils.mjs";
|
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import { composeEventHandlers } from "@radix-ui/primitive";
|
|
5
5
|
//#region src/components/radio.tsx
|
|
6
|
+
/**
|
|
7
|
+
* @since 0.3.16-canary.0
|
|
8
|
+
*/
|
|
6
9
|
function Radio({ className, onChange, onValueChange, ...props }) {
|
|
7
10
|
return /* @__PURE__ */ jsx("input", {
|
|
8
11
|
className: cn("peer inline-flex size-4 shrink-0 items-center justify-center", "rounded-full border border-input shadow-xs outline-hidden", "appearance-none", "after:size-full after:rounded-full after:bg-background after:transition-[width,height]", "checked:border-primary checked:bg-primary", "checked:after:size-1", "hover:not-disabled:not-checked:border-ring/60", "focus-visible:ring-3 focus-visible:ring-ring/50", "focus-visible:not-checked:border-ring", "focus-visible:checked:ring-primary/20", "disabled:opacity-50", "aria-invalid:border-destructive aria-invalid:ring-destructive/20", "checked:aria-invalid:bg-destructive", "hover:not-disabled:not-checked:aria-invalid:border-destructive/60", "dark:not-checked:after:bg-input/30", "dark:focus-visible:checked:ring-primary/40", "dark:aria-invalid:ring-destructive/40", className),
|
|
@@ -2,18 +2,36 @@ import { ComponentProps, JSX } from "react";
|
|
|
2
2
|
import * as ResizablePrimitive from "react-resizable-panels";
|
|
3
3
|
|
|
4
4
|
//#region src/components/resizable.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* @since 0.3.16-canary.0
|
|
7
|
+
*/
|
|
5
8
|
type ResizableGroupProps = ComponentProps<typeof ResizablePrimitive.Group>;
|
|
9
|
+
/**
|
|
10
|
+
* @since 0.3.16-canary.0
|
|
11
|
+
*/
|
|
6
12
|
declare function ResizableGroup({
|
|
7
13
|
className,
|
|
8
14
|
...props
|
|
9
15
|
}: ResizableGroupProps): JSX.Element;
|
|
16
|
+
/**
|
|
17
|
+
* @since 0.3.16-canary.0
|
|
18
|
+
*/
|
|
10
19
|
type ResizablePanelProps = ComponentProps<typeof ResizablePrimitive.Panel>;
|
|
20
|
+
/**
|
|
21
|
+
* @since 0.3.16-canary.0
|
|
22
|
+
*/
|
|
11
23
|
declare function ResizablePanel({
|
|
12
24
|
...props
|
|
13
25
|
}: ResizablePanelProps): JSX.Element;
|
|
26
|
+
/**
|
|
27
|
+
* @since 0.3.16-canary.0
|
|
28
|
+
*/
|
|
14
29
|
interface ResizableSeparatorProps extends ComponentProps<typeof ResizablePrimitive.Separator> {
|
|
15
30
|
withHandle?: boolean;
|
|
16
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* @since 0.3.16-canary.0
|
|
34
|
+
*/
|
|
17
35
|
declare function ResizableSeparator({
|
|
18
36
|
className,
|
|
19
37
|
withHandle,
|