@a2v2ai/uikit 0.0.36 → 0.0.38
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/Alert/Alert.stories.tsx +121 -0
- package/Alert/Alert.tsx +71 -0
- package/AlertDialog/AlertDialog.stories.tsx +665 -0
- package/AlertDialog/AlertDialog.tsx +241 -0
- package/Avatar/Avatar.stories.tsx +128 -0
- package/Avatar/Avatar.tsx +71 -0
- package/Badge/Badge.stories.tsx +76 -0
- package/Badge/Badge.tsx +39 -0
- package/Breadcrumb/Breadcrumb.stories.tsx +231 -0
- package/Breadcrumb/Breadcrumb.tsx +114 -0
- package/Button/Button.stories.tsx +684 -0
- package/Button/Button.tsx +107 -0
- package/Calendar/Calendar.stories.tsx +291 -0
- package/Calendar/Calendar.tsx +246 -0
- package/Card/Card.stories.tsx +136 -0
- package/Card/Card.tsx +96 -0
- package/Carousel/Carousel.stories.tsx +256 -0
- package/Carousel/Carousel.tsx +301 -0
- package/ChatBubble/ChatBubble.stories.tsx +339 -0
- package/ChatBubble/ChatBubble.tsx +179 -0
- package/Checkbox/Checkbox.stories.tsx +137 -0
- package/Checkbox/Checkbox.tsx +53 -0
- package/DataTable/DataTable.stories.tsx +400 -0
- package/DataTable/DataTable.tsx +207 -0
- package/Drawer/Drawer.stories.tsx +721 -0
- package/Drawer/Drawer.tsx +201 -0
- package/DropdownMenu/DropdownMenu.stories.tsx +251 -0
- package/DropdownMenu/DropdownMenu.tsx +199 -0
- package/ErrorMessage/ErrorMessage.stories.tsx +159 -0
- package/ErrorMessage/ErrorMessage.tsx +55 -0
- package/Flex/Flex.stories.tsx +390 -0
- package/Flex/Flex.tsx +102 -0
- package/IconButton/IconButton.stories.tsx +566 -0
- package/IconButton/IconButton.tsx +95 -0
- package/Input/Input.stories.tsx +566 -0
- package/Input/Input.tsx +168 -0
- package/InputOTP/InputOTP.stories.tsx +246 -0
- package/InputOTP/InputOTP.tsx +127 -0
- package/Label/Label.stories.tsx +110 -0
- package/Label/Label.tsx +44 -0
- package/Loader/Loader.stories.tsx +170 -0
- package/Loader/Loader.tsx +62 -0
- package/Menubar/Menubar.stories.tsx +382 -0
- package/Menubar/Menubar.tsx +274 -0
- package/Menubar/index.ts +18 -0
- package/Pagination/Pagination.stories.tsx +196 -0
- package/Pagination/Pagination.tsx +122 -0
- package/Popover/Popover.stories.tsx +133 -0
- package/Popover/Popover.tsx +31 -0
- package/Progress/Progress.stories.tsx +146 -0
- package/Progress/Progress.tsx +67 -0
- package/RadioGroup/RadioGroup.stories.tsx +159 -0
- package/RadioGroup/RadioGroup.tsx +68 -0
- package/ScrollArea/ScrollArea.stories.tsx +136 -0
- package/ScrollArea/ScrollArea.tsx +46 -0
- package/Select/Select.stories.tsx +378 -0
- package/Select/Select.tsx +230 -0
- package/Separator/Separator.stories.tsx +110 -0
- package/Separator/Separator.tsx +29 -0
- package/Sidebar/Sidebar.stories.tsx +340 -0
- package/Sidebar/Sidebar.tsx +414 -0
- package/Sidebar/index.ts +28 -0
- package/Skeleton/Skeleton.stories.tsx +117 -0
- package/Skeleton/Skeleton.tsx +16 -0
- package/Slider/Slider.stories.tsx +216 -0
- package/Slider/Slider.tsx +29 -0
- package/Spinner/Spinner.stories.tsx +210 -0
- package/Spinner/Spinner.tsx +78 -0
- package/Switch/Switch.stories.tsx +146 -0
- package/Switch/Switch.tsx +59 -0
- package/Table/Table.stories.tsx +510 -0
- package/Table/Table.tsx +114 -0
- package/Tabs/Tabs.stories.tsx +197 -0
- package/Tabs/Tabs.tsx +74 -0
- package/Textarea/Textarea.stories.tsx +187 -0
- package/Textarea/Textarea.tsx +73 -0
- package/Toast/Toast.stories.tsx +285 -0
- package/Toast/Toast.tsx +59 -0
- package/Tooltip/Tooltip.stories.tsx +463 -0
- package/Tooltip/Tooltip.tsx +96 -0
- package/Typography/Typography.stories.tsx +425 -0
- package/Typography/Typography.tsx +106 -0
- package/helpers.ts +5 -0
- package/{icons.js → icons.ts} +1 -1
- package/index.ts +217 -0
- package/lib/typography-types.ts +223 -0
- package/lib/utils.ts +15 -0
- package/package.json +36 -33
- package/tsconfig.json +22 -0
- package/Alert/Alert.d.ts +0 -13
- package/Alert/Alert.js +0 -25
- package/AlertDialog/AlertDialog.d.ts +0 -43
- package/AlertDialog/AlertDialog.js +0 -71
- package/Avatar/Avatar.d.ts +0 -14
- package/Avatar/Avatar.js +0 -25
- package/Badge/Badge.d.ts +0 -11
- package/Badge/Badge.js +0 -23
- package/Breadcrumb/Breadcrumb.d.ts +0 -19
- package/Breadcrumb/Breadcrumb.js +0 -23
- package/Button/Button.d.ts +0 -23
- package/Button/Button.js +0 -52
- package/Calendar/Calendar.d.ts +0 -20
- package/Calendar/Calendar.js +0 -78
- package/Card/Card.d.ts +0 -16
- package/Card/Card.js +0 -28
- package/Carousel/Carousel.d.ts +0 -37
- package/Carousel/Carousel.js +0 -132
- package/ChatBubble/ChatBubble.d.ts +0 -33
- package/ChatBubble/ChatBubble.js +0 -107
- package/Checkbox/Checkbox.d.ts +0 -12
- package/Checkbox/Checkbox.js +0 -20
- package/DataTable/DataTable.d.ts +0 -35
- package/DataTable/DataTable.js +0 -51
- package/Dialog/Dialog.d.ts +0 -35
- package/Dialog/Dialog.js +0 -130
- package/Drawer/Drawer.d.ts +0 -33
- package/Drawer/Drawer.js +0 -55
- package/DropdownMenu/DropdownMenu.d.ts +0 -27
- package/DropdownMenu/DropdownMenu.js +0 -35
- package/ErrorMessage/ErrorMessage.d.ts +0 -27
- package/ErrorMessage/ErrorMessage.js +0 -14
- package/Flex/Flex.d.ts +0 -31
- package/Flex/Flex.js +0 -64
- package/IconButton/IconButton.d.ts +0 -23
- package/IconButton/IconButton.js +0 -48
- package/Input/Input.d.ts +0 -27
- package/Input/Input.js +0 -42
- package/InputOTP/InputOTP.d.ts +0 -20
- package/InputOTP/InputOTP.js +0 -44
- package/Label/Label.d.ts +0 -13
- package/Label/Label.js +0 -19
- package/Loader/Loader.d.ts +0 -21
- package/Loader/Loader.js +0 -30
- package/Menubar/Menubar.d.ts +0 -26
- package/Menubar/Menubar.js +0 -54
- package/Menubar/index.d.ts +0 -1
- package/Menubar/index.js +0 -1
- package/Pagination/Pagination.d.ts +0 -35
- package/Pagination/Pagination.js +0 -37
- package/Popover/Popover.d.ts +0 -7
- package/Popover/Popover.js +0 -10
- package/Progress/Progress.d.ts +0 -17
- package/Progress/Progress.js +0 -33
- package/RadioGroup/RadioGroup.d.ts +0 -13
- package/RadioGroup/RadioGroup.js +0 -26
- package/ScrollArea/ScrollArea.d.ts +0 -5
- package/ScrollArea/ScrollArea.js +0 -11
- package/Select/Select.d.ts +0 -29
- package/Select/Select.js +0 -50
- package/Separator/Separator.d.ts +0 -4
- package/Separator/Separator.js +0 -7
- package/Sidebar/Sidebar.d.ts +0 -48
- package/Sidebar/Sidebar.js +0 -116
- package/Sidebar/index.d.ts +0 -2
- package/Sidebar/index.js +0 -1
- package/Skeleton/Skeleton.d.ts +0 -4
- package/Skeleton/Skeleton.js +0 -7
- package/Slider/Slider.d.ts +0 -6
- package/Slider/Slider.js +0 -7
- package/Spinner/Spinner.d.ts +0 -19
- package/Spinner/Spinner.js +0 -31
- package/Switch/Switch.d.ts +0 -12
- package/Switch/Switch.js +0 -30
- package/Table/Table.d.ts +0 -10
- package/Table/Table.js +0 -20
- package/Tabs/Tabs.d.ts +0 -15
- package/Tabs/Tabs.js +0 -24
- package/Textarea/Textarea.d.ts +0 -19
- package/Textarea/Textarea.js +0 -31
- package/Toast/Toast.d.ts +0 -12
- package/Toast/Toast.js +0 -25
- package/Tooltip/Tooltip.d.ts +0 -17
- package/Tooltip/Tooltip.js +0 -29
- package/Typography/Typography.d.ts +0 -20
- package/Typography/Typography.js +0 -43
- package/helpers.d.ts +0 -4
- package/helpers.js +0 -5
- package/icons.d.ts +0 -1
- package/index.d.ts +0 -42
- package/index.js +0 -45
- package/lib/typography-types.d.ts +0 -4
- package/lib/typography-types.js +0 -90
- package/lib/utils.d.ts +0 -3
- package/lib/utils.js +0 -14
- package/tmpclaude-2407-cwd +0 -1
package/Flex/Flex.js
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import { cva } from "class-variance-authority";
|
|
4
|
-
import { cn } from "../lib/utils";
|
|
5
|
-
const flexVariants = cva("flex", {
|
|
6
|
-
variants: {
|
|
7
|
-
direction: {
|
|
8
|
-
row: "flex-row",
|
|
9
|
-
column: "flex-col",
|
|
10
|
-
"row-reverse": "flex-row-reverse",
|
|
11
|
-
"column-reverse": "flex-col-reverse",
|
|
12
|
-
},
|
|
13
|
-
align: {
|
|
14
|
-
start: "items-start",
|
|
15
|
-
center: "items-center",
|
|
16
|
-
end: "items-end",
|
|
17
|
-
stretch: "items-stretch",
|
|
18
|
-
baseline: "items-baseline",
|
|
19
|
-
},
|
|
20
|
-
justify: {
|
|
21
|
-
start: "justify-start",
|
|
22
|
-
center: "justify-center",
|
|
23
|
-
end: "justify-end",
|
|
24
|
-
between: "justify-between",
|
|
25
|
-
around: "justify-around",
|
|
26
|
-
evenly: "justify-evenly",
|
|
27
|
-
},
|
|
28
|
-
wrap: {
|
|
29
|
-
nowrap: "flex-nowrap",
|
|
30
|
-
wrap: "flex-wrap",
|
|
31
|
-
"wrap-reverse": "flex-wrap-reverse",
|
|
32
|
-
},
|
|
33
|
-
gap: {
|
|
34
|
-
0: "gap-0",
|
|
35
|
-
1: "gap-1",
|
|
36
|
-
2: "gap-2",
|
|
37
|
-
3: "gap-3",
|
|
38
|
-
4: "gap-4",
|
|
39
|
-
5: "gap-5",
|
|
40
|
-
6: "gap-6",
|
|
41
|
-
8: "gap-8",
|
|
42
|
-
10: "gap-10",
|
|
43
|
-
12: "gap-12",
|
|
44
|
-
16: "gap-16",
|
|
45
|
-
20: "gap-20",
|
|
46
|
-
24: "gap-24",
|
|
47
|
-
32: "gap-32",
|
|
48
|
-
40: "gap-40",
|
|
49
|
-
48: "gap-48",
|
|
50
|
-
},
|
|
51
|
-
},
|
|
52
|
-
defaultVariants: {
|
|
53
|
-
direction: "column",
|
|
54
|
-
align: "start",
|
|
55
|
-
justify: "start",
|
|
56
|
-
wrap: "nowrap",
|
|
57
|
-
gap: 0,
|
|
58
|
-
},
|
|
59
|
-
});
|
|
60
|
-
const Flex = React.forwardRef(({ className, direction, align, justify, wrap, gap, as: Component = "div", ...props }, ref) => {
|
|
61
|
-
return (_jsx(Component, { ref: ref, className: cn(flexVariants({ direction, align, justify, wrap, gap, className })), ...props }));
|
|
62
|
-
});
|
|
63
|
-
Flex.displayName = "Flex";
|
|
64
|
-
export { Flex, flexVariants };
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
type IconButtonVariant = "primary" | "secondary" | "outline" | "ghost";
|
|
3
|
-
type IconButtonSize = "mini" | "small" | "regular" | "large";
|
|
4
|
-
type IconButtonRoundness = "default" | "round";
|
|
5
|
-
declare const iconButtonVariants: (props?: ({
|
|
6
|
-
variant?: "secondary" | "outline" | "primary" | "ghost" | null | undefined;
|
|
7
|
-
size?: "small" | "regular" | "large" | "mini" | null | undefined;
|
|
8
|
-
roundness?: "default" | "round" | null | undefined;
|
|
9
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
10
|
-
export interface IconButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
11
|
-
variant?: IconButtonVariant;
|
|
12
|
-
size?: IconButtonSize;
|
|
13
|
-
roundness?: IconButtonRoundness;
|
|
14
|
-
/** Use the Slot component to render a different element */
|
|
15
|
-
asChild?: boolean;
|
|
16
|
-
/** The icon to render inside the button */
|
|
17
|
-
icon?: React.ReactNode;
|
|
18
|
-
/** Accessible label for screen readers */
|
|
19
|
-
"aria-label": string;
|
|
20
|
-
}
|
|
21
|
-
declare const IconButton: React.ForwardRefExoticComponent<IconButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
22
|
-
export { IconButton, iconButtonVariants };
|
|
23
|
-
export type { IconButtonVariant, IconButtonSize, IconButtonRoundness };
|
package/IconButton/IconButton.js
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import { Slot } from "@radix-ui/react-slot";
|
|
4
|
-
import { cva } from "class-variance-authority";
|
|
5
|
-
import { cn } from "../lib/utils";
|
|
6
|
-
const iconButtonVariants = cva("inline-flex items-center justify-center shrink-0 cursor-pointer transition-colors focus-visible:outline-none focus-visible:shadow-[0_0_0_3px_#d4d4d4] disabled:pointer-events-none disabled:opacity-50 disabled:cursor-not-allowed [&_svg]:pointer-events-none [&_svg]:shrink-0", {
|
|
7
|
-
variants: {
|
|
8
|
-
variant: {
|
|
9
|
-
primary: "bg-accent-600 text-white hover:bg-accent-700",
|
|
10
|
-
secondary: "bg-main-100 text-main-950 hover:bg-main-200",
|
|
11
|
-
outline: "border border-main-300 bg-transparent text-main-950 hover:bg-main-100",
|
|
12
|
-
ghost: "bg-transparent text-main-600 hover:bg-main-100 hover:text-main-950",
|
|
13
|
-
},
|
|
14
|
-
size: {
|
|
15
|
-
mini: "size-6 [&_svg]:size-3",
|
|
16
|
-
small: "size-8 [&_svg]:size-4",
|
|
17
|
-
regular: "size-9 [&_svg]:size-4",
|
|
18
|
-
large: "size-10 [&_svg]:size-5",
|
|
19
|
-
},
|
|
20
|
-
roundness: {
|
|
21
|
-
default: "rounded-lg",
|
|
22
|
-
round: "rounded-full",
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
compoundVariants: [
|
|
26
|
-
{
|
|
27
|
-
size: "mini",
|
|
28
|
-
roundness: "default",
|
|
29
|
-
className: "rounded-md",
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
size: "small",
|
|
33
|
-
roundness: "default",
|
|
34
|
-
className: "rounded-md",
|
|
35
|
-
},
|
|
36
|
-
],
|
|
37
|
-
defaultVariants: {
|
|
38
|
-
variant: "primary",
|
|
39
|
-
size: "regular",
|
|
40
|
-
roundness: "default",
|
|
41
|
-
},
|
|
42
|
-
});
|
|
43
|
-
const IconButton = React.forwardRef(({ className, variant, size, roundness, asChild = false, icon, children, ...props }, ref) => {
|
|
44
|
-
const Comp = asChild ? Slot : "button";
|
|
45
|
-
return (_jsx(Comp, { className: cn(iconButtonVariants({ variant, size, roundness, className })), ref: ref, ...props, children: icon || children }));
|
|
46
|
-
});
|
|
47
|
-
IconButton.displayName = "IconButton";
|
|
48
|
-
export { IconButton, iconButtonVariants };
|
package/Input/Input.d.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { type TextVariant, type TextColor } from "../lib/typography-types";
|
|
3
|
-
type InputSize = "mini" | "small" | "regular" | "large";
|
|
4
|
-
type InputRoundness = "default" | "round";
|
|
5
|
-
type InputVariant = "default" | "error";
|
|
6
|
-
declare const inputVariants: (props?: ({
|
|
7
|
-
size?: "small" | "regular" | "large" | "mini" | null | undefined;
|
|
8
|
-
roundness?: "default" | "round" | null | undefined;
|
|
9
|
-
variant?: "default" | "error" | null | undefined;
|
|
10
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
11
|
-
export interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, "size"> {
|
|
12
|
-
size?: InputSize;
|
|
13
|
-
roundness?: InputRoundness;
|
|
14
|
-
variant?: InputVariant;
|
|
15
|
-
label?: string;
|
|
16
|
-
labelVariant?: TextVariant;
|
|
17
|
-
labelColor?: TextColor;
|
|
18
|
-
leftIcon?: React.ReactNode;
|
|
19
|
-
rightIcon?: React.ReactNode;
|
|
20
|
-
leftAddon?: React.ReactNode;
|
|
21
|
-
rightAddon?: React.ReactNode;
|
|
22
|
-
rightElement?: React.ReactNode;
|
|
23
|
-
error?: string;
|
|
24
|
-
}
|
|
25
|
-
declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
|
|
26
|
-
export { Input, inputVariants };
|
|
27
|
-
export type { InputSize, InputRoundness, InputVariant };
|
package/Input/Input.js
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import { cva } from "class-variance-authority";
|
|
4
|
-
import { cn } from "../lib/utils";
|
|
5
|
-
import { Typography } from "../Typography/Typography";
|
|
6
|
-
import { Label } from "../Label/Label";
|
|
7
|
-
import {} from "../lib/typography-types";
|
|
8
|
-
const inputVariants = cva("flex w-full bg-white border font-normal font-sans transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-grey-400 focus-visible:outline-none disabled:cursor-not-allowed disabled:opacity-50 disabled:bg-grey-50", {
|
|
9
|
-
variants: {
|
|
10
|
-
size: {
|
|
11
|
-
mini: "h-6 px-3 text-xs rounded-md",
|
|
12
|
-
small: "h-8 px-3 text-sm rounded-md",
|
|
13
|
-
regular: "h-9 px-3 text-sm rounded-lg",
|
|
14
|
-
large: "h-10 px-3 text-base rounded-lg",
|
|
15
|
-
},
|
|
16
|
-
roundness: {
|
|
17
|
-
default: "",
|
|
18
|
-
round: "!rounded-full",
|
|
19
|
-
},
|
|
20
|
-
variant: {
|
|
21
|
-
default: "border-grey-300 focus-visible:border-grey-300 focus-visible:ring-[3px] focus-visible:ring-grey-300/50",
|
|
22
|
-
error: "border-error-500 focus-visible:border-error-500 focus-visible:ring-[3px] focus-visible:ring-error-200",
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
defaultVariants: {
|
|
26
|
-
size: "regular",
|
|
27
|
-
roundness: "default",
|
|
28
|
-
variant: "default",
|
|
29
|
-
},
|
|
30
|
-
});
|
|
31
|
-
const Input = React.forwardRef(({ className, type = "text", size, roundness, variant, label, labelVariant = "body2", labelColor = "main-800", leftIcon, rightIcon, leftAddon, rightAddon, rightElement, error, id, ...props }, ref) => {
|
|
32
|
-
const hasAddons = leftIcon || rightIcon || leftAddon || rightAddon || rightElement;
|
|
33
|
-
const computedVariant = error ? "error" : variant;
|
|
34
|
-
if (hasAddons) {
|
|
35
|
-
return (_jsxs("div", { className: "flex flex-col gap-2 w-full", children: [label && (_jsx(Label, { htmlFor: id, variant: labelVariant, color: labelColor, children: label })), _jsxs("div", { className: cn("flex items-center gap-2 bg-white border font-sans transition-colors w-full", "focus-within:ring-[3px]", computedVariant === "error"
|
|
36
|
-
? "border-error-500 focus-within:border-error-500 focus-within:ring-error-200"
|
|
37
|
-
: "border-grey-300 focus-within:border-grey-300 focus-within:ring-grey-300/50", size === "mini" && "h-6 pl-3 pr-0.5 text-xs rounded-md", size === "small" && "h-8 pl-3 pr-0.5 text-sm rounded-md", size === "regular" && "h-9 pl-3 pr-0.5 text-sm rounded-lg", size === "large" && "h-10 pl-3 pr-0.5 text-base rounded-lg", !size && "h-9 pl-3 pr-0.5 text-sm rounded-lg", !rightElement && "pr-3", roundness === "round" && "!rounded-full", props.disabled && "opacity-50 cursor-not-allowed bg-grey-50", className), children: [leftIcon && (_jsx("span", { className: "shrink-0 text-grey-500 [&_svg]:size-4", children: leftIcon })), leftAddon && (_jsx("span", { className: "shrink-0 text-grey-500", children: leftAddon })), _jsx("input", { type: type, id: id, className: cn("flex-1 min-w-0 bg-transparent border-0 outline-none placeholder:text-grey-400", "disabled:cursor-not-allowed"), ref: ref, ...props }), rightAddon && (_jsx("span", { className: "shrink-0 text-grey-500", children: rightAddon })), rightIcon && (_jsx("span", { className: "shrink-0 text-grey-500 [&_svg]:size-4", children: rightIcon })), rightElement && (_jsx("span", { className: "shrink-0", children: rightElement }))] }), error && (_jsx(Typography, { variant: "caption", color: "error-600", className: "mt-1", children: error }))] }));
|
|
38
|
-
}
|
|
39
|
-
return (_jsxs("div", { className: "flex flex-col gap-2 w-full", children: [label && (_jsx(Label, { htmlFor: id, variant: labelVariant, color: labelColor, children: label })), _jsx("input", { type: type, id: id, className: cn(inputVariants({ size, roundness, variant: computedVariant, className })), ref: ref, ...props }), error && (_jsx(Typography, { variant: "caption", color: "error-600", className: "mt-1", children: error }))] }));
|
|
40
|
-
});
|
|
41
|
-
Input.displayName = "Input";
|
|
42
|
-
export { Input, inputVariants };
|
package/InputOTP/InputOTP.d.ts
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { OTPInput } from "input-otp";
|
|
3
|
-
type InputOTPSlotSize = "sm" | "default" | "lg";
|
|
4
|
-
declare const inputOTPVariants: (props?: ({} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
5
|
-
export interface InputOTPProps extends Omit<React.ComponentPropsWithoutRef<typeof OTPInput>, "render"> {
|
|
6
|
-
children?: React.ReactNode;
|
|
7
|
-
}
|
|
8
|
-
declare const InputOTP: React.ForwardRefExoticComponent<InputOTPProps & React.RefAttributes<HTMLInputElement>>;
|
|
9
|
-
declare const InputOTPGroup: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
-
declare const inputOTPSlotVariants: (props?: ({
|
|
11
|
-
slotSize?: "default" | "sm" | "lg" | null | undefined;
|
|
12
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
13
|
-
export interface InputOTPSlotProps extends React.ComponentPropsWithoutRef<"div"> {
|
|
14
|
-
index: number;
|
|
15
|
-
slotSize?: InputOTPSlotSize;
|
|
16
|
-
}
|
|
17
|
-
declare const InputOTPSlot: React.ForwardRefExoticComponent<InputOTPSlotProps & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
-
declare const InputOTPSeparator: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
19
|
-
export { InputOTP, InputOTPGroup, InputOTPSlot, InputOTPSeparator, inputOTPVariants, inputOTPSlotVariants, };
|
|
20
|
-
export type { InputOTPSlotSize };
|
package/InputOTP/InputOTP.js
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
-
import * as React from "react";
|
|
4
|
-
import { OTPInput, OTPInputContext } from "input-otp";
|
|
5
|
-
import { Minus } from "lucide-react";
|
|
6
|
-
import { cva } from "class-variance-authority";
|
|
7
|
-
import { cn } from "../lib/utils";
|
|
8
|
-
const inputOTPVariants = cva("flex items-center gap-2 has-[:disabled]:opacity-50", {
|
|
9
|
-
variants: {},
|
|
10
|
-
defaultVariants: {},
|
|
11
|
-
});
|
|
12
|
-
const InputOTP = React.forwardRef(({ className, containerClassName, children, ...props }, ref) => (_jsx(OTPInput, { ref: ref, containerClassName: cn("flex items-center gap-2 has-[:disabled]:opacity-50", containerClassName), className: cn("disabled:cursor-not-allowed", className), ...props, render: ({ slots, isFocused, isHovering }) => (_jsx(OTPInputContext.Provider, { value: { slots, isFocused, isHovering }, children: children })) })));
|
|
13
|
-
InputOTP.displayName = "InputOTP";
|
|
14
|
-
const InputOTPGroup = React.forwardRef(({ className, ...props }, ref) => (_jsx("div", { ref: ref, className: cn("flex items-center", className), ...props })));
|
|
15
|
-
InputOTPGroup.displayName = "InputOTPGroup";
|
|
16
|
-
const inputOTPSlotVariants = cva(
|
|
17
|
-
// Match Input component styles: border-grey-300, rounded-lg, focus ring
|
|
18
|
-
"relative flex items-center justify-center bg-white border border-grey-300 text-main-950 font-sans transition-all first:rounded-l-lg last:rounded-r-lg first:border-l border-l-0", {
|
|
19
|
-
variants: {
|
|
20
|
-
slotSize: {
|
|
21
|
-
sm: "h-8 w-8 text-sm rounded-md first:rounded-l-md last:rounded-r-md",
|
|
22
|
-
default: "h-9 w-9 text-sm",
|
|
23
|
-
lg: "h-10 w-10 text-base",
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
defaultVariants: {
|
|
27
|
-
slotSize: "default",
|
|
28
|
-
},
|
|
29
|
-
});
|
|
30
|
-
const InputOTPSlot = React.forwardRef(({ index, className, slotSize, ...props }, ref) => {
|
|
31
|
-
const inputOTPContext = React.useContext(OTPInputContext);
|
|
32
|
-
const slot = inputOTPContext.slots[index];
|
|
33
|
-
if (!slot) {
|
|
34
|
-
return null;
|
|
35
|
-
}
|
|
36
|
-
const { char, hasFakeCaret, isActive } = slot;
|
|
37
|
-
return (_jsxs("div", { ref: ref, className: cn(inputOTPSlotVariants({ slotSize }),
|
|
38
|
-
// Match Input focus style: ring-[3px] ring-grey-300/50
|
|
39
|
-
isActive && "z-10 border-grey-300 ring-[3px] ring-grey-300/50", className), ...props, children: [char, hasFakeCaret && (_jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: _jsx("div", { className: "h-4 w-px animate-caret-blink bg-main-950 duration-1000" }) }))] }));
|
|
40
|
-
});
|
|
41
|
-
InputOTPSlot.displayName = "InputOTPSlot";
|
|
42
|
-
const InputOTPSeparator = React.forwardRef(({ ...props }, ref) => (_jsx("div", { ref: ref, role: "separator", ...props, children: _jsx(Minus, { className: "text-grey-400" }) })));
|
|
43
|
-
InputOTPSeparator.displayName = "InputOTPSeparator";
|
|
44
|
-
export { InputOTP, InputOTPGroup, InputOTPSlot, InputOTPSeparator, inputOTPVariants, inputOTPSlotVariants, };
|
package/Label/Label.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
3
|
-
import { type TextVariant, type TextColor } from "../lib/typography-types";
|
|
4
|
-
declare const labelVariants: (props?: ({
|
|
5
|
-
textVariant?: TextVariant | null | undefined;
|
|
6
|
-
color?: TextColor | null | undefined;
|
|
7
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
-
export interface LabelProps extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root> {
|
|
9
|
-
variant?: TextVariant;
|
|
10
|
-
color?: TextColor;
|
|
11
|
-
}
|
|
12
|
-
declare const Label: React.ForwardRefExoticComponent<LabelProps & React.RefAttributes<HTMLLabelElement>>;
|
|
13
|
-
export { Label, labelVariants };
|
package/Label/Label.js
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
4
|
-
import { cva } from "class-variance-authority";
|
|
5
|
-
import { cn } from "../lib/utils";
|
|
6
|
-
import { textVariantClasses, textColorClasses, } from "../lib/typography-types";
|
|
7
|
-
const labelVariants = cva("font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70", {
|
|
8
|
-
variants: {
|
|
9
|
-
textVariant: textVariantClasses,
|
|
10
|
-
color: textColorClasses,
|
|
11
|
-
},
|
|
12
|
-
defaultVariants: {
|
|
13
|
-
textVariant: "body2",
|
|
14
|
-
color: "main-950",
|
|
15
|
-
},
|
|
16
|
-
});
|
|
17
|
-
const Label = React.forwardRef(({ className, variant, color, ...props }, ref) => (_jsx(LabelPrimitive.Root, { ref: ref, className: cn(labelVariants({ textVariant: variant, color }), className), ...props })));
|
|
18
|
-
Label.displayName = LabelPrimitive.Root.displayName;
|
|
19
|
-
export { Label, labelVariants };
|
package/Loader/Loader.d.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
type LoaderSize = "mini" | "small" | "regular" | "large";
|
|
3
|
-
type LoaderColor = "main" | "grey" | "white" | "current";
|
|
4
|
-
declare const loaderVariants: (props?: ({
|
|
5
|
-
size?: "small" | "regular" | "large" | "mini" | null | undefined;
|
|
6
|
-
color?: "main" | "current" | "grey" | "white" | null | undefined;
|
|
7
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
-
export type LoaderProps = Omit<React.HTMLAttributes<HTMLDivElement>, "color"> & {
|
|
9
|
-
size?: LoaderSize;
|
|
10
|
-
color?: LoaderColor;
|
|
11
|
-
/** Optional label for accessibility */
|
|
12
|
-
label?: string;
|
|
13
|
-
};
|
|
14
|
-
declare const Loader: React.ForwardRefExoticComponent<Omit<React.HTMLAttributes<HTMLDivElement>, "color"> & {
|
|
15
|
-
size?: LoaderSize;
|
|
16
|
-
color?: LoaderColor;
|
|
17
|
-
/** Optional label for accessibility */
|
|
18
|
-
label?: string;
|
|
19
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
20
|
-
export { Loader, loaderVariants };
|
|
21
|
-
export type { LoaderSize, LoaderColor };
|
package/Loader/Loader.js
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import { Loader2 } from "lucide-react";
|
|
4
|
-
import { cva } from "class-variance-authority";
|
|
5
|
-
import { Flex } from "../Flex/Flex";
|
|
6
|
-
import { Typography } from "../Typography/Typography";
|
|
7
|
-
import { cn } from "../lib/utils";
|
|
8
|
-
const loaderVariants = cva("animate-spin", {
|
|
9
|
-
variants: {
|
|
10
|
-
size: {
|
|
11
|
-
mini: "size-3",
|
|
12
|
-
small: "size-4",
|
|
13
|
-
regular: "size-6",
|
|
14
|
-
large: "size-8",
|
|
15
|
-
},
|
|
16
|
-
color: {
|
|
17
|
-
main: "text-main-600",
|
|
18
|
-
grey: "text-grey-600",
|
|
19
|
-
white: "text-white",
|
|
20
|
-
current: "text-current",
|
|
21
|
-
},
|
|
22
|
-
},
|
|
23
|
-
defaultVariants: {
|
|
24
|
-
size: "regular",
|
|
25
|
-
color: "main",
|
|
26
|
-
},
|
|
27
|
-
});
|
|
28
|
-
const Loader = React.forwardRef(({ className, size, color, label = "Loading...", ...props }, ref) => (_jsxs(Flex, { ref: ref, role: "status", "aria-label": label, align: "center", justify: "center", className: cn("inline-flex", className), ...props, children: [_jsx(Loader2, { className: cn(loaderVariants({ size, color })) }), _jsx(Typography, { className: "sr-only", children: label })] })));
|
|
29
|
-
Loader.displayName = "Loader";
|
|
30
|
-
export { Loader, loaderVariants };
|
package/Menubar/Menubar.d.ts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as MenubarPrimitive from "@radix-ui/react-menubar";
|
|
3
|
-
declare function Menubar({ className, ...props }: React.ComponentProps<typeof MenubarPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
-
declare function MenubarMenu({ ...props }: React.ComponentProps<typeof MenubarPrimitive.Menu>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
-
declare function MenubarGroup({ ...props }: React.ComponentProps<typeof MenubarPrimitive.Group>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
-
declare function MenubarPortal({ ...props }: React.ComponentProps<typeof MenubarPrimitive.Portal>): import("react/jsx-runtime").JSX.Element;
|
|
7
|
-
declare function MenubarRadioGroup({ ...props }: React.ComponentProps<typeof MenubarPrimitive.RadioGroup>): import("react/jsx-runtime").JSX.Element;
|
|
8
|
-
declare function MenubarTrigger({ className, ...props }: React.ComponentProps<typeof MenubarPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
declare function MenubarContent({ className, align, alignOffset, sideOffset, ...props }: React.ComponentProps<typeof MenubarPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
-
declare function MenubarItem({ className, inset, variant, ...props }: React.ComponentProps<typeof MenubarPrimitive.Item> & {
|
|
11
|
-
inset?: boolean;
|
|
12
|
-
variant?: "default" | "destructive";
|
|
13
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
14
|
-
declare function MenubarCheckboxItem({ className, children, checked, ...props }: React.ComponentProps<typeof MenubarPrimitive.CheckboxItem>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
-
declare function MenubarRadioItem({ className, children, ...props }: React.ComponentProps<typeof MenubarPrimitive.RadioItem>): import("react/jsx-runtime").JSX.Element;
|
|
16
|
-
declare function MenubarLabel({ className, inset, ...props }: React.ComponentProps<typeof MenubarPrimitive.Label> & {
|
|
17
|
-
inset?: boolean;
|
|
18
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
19
|
-
declare function MenubarSeparator({ className, ...props }: React.ComponentProps<typeof MenubarPrimitive.Separator>): import("react/jsx-runtime").JSX.Element;
|
|
20
|
-
declare function MenubarShortcut({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
|
|
21
|
-
declare function MenubarSub({ ...props }: React.ComponentProps<typeof MenubarPrimitive.Sub>): import("react/jsx-runtime").JSX.Element;
|
|
22
|
-
declare function MenubarSubTrigger({ className, inset, children, ...props }: React.ComponentProps<typeof MenubarPrimitive.SubTrigger> & {
|
|
23
|
-
inset?: boolean;
|
|
24
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
25
|
-
declare function MenubarSubContent({ className, ...props }: React.ComponentProps<typeof MenubarPrimitive.SubContent>): import("react/jsx-runtime").JSX.Element;
|
|
26
|
-
export { Menubar, MenubarPortal, MenubarMenu, MenubarTrigger, MenubarContent, MenubarGroup, MenubarSeparator, MenubarLabel, MenubarItem, MenubarShortcut, MenubarCheckboxItem, MenubarRadioGroup, MenubarRadioItem, MenubarSub, MenubarSubTrigger, MenubarSubContent, };
|
package/Menubar/Menubar.js
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import * as MenubarPrimitive from "@radix-ui/react-menubar";
|
|
4
|
-
import { CheckIcon, ChevronRightIcon, CircleIcon } from "lucide-react";
|
|
5
|
-
import { cn } from "../lib/utils";
|
|
6
|
-
function Menubar({ className, ...props }) {
|
|
7
|
-
return (_jsx(MenubarPrimitive.Root, { "data-slot": "menubar", className: cn("bg-background flex h-9 items-center gap-1 rounded-md border p-1 shadow-xs", className), ...props }));
|
|
8
|
-
}
|
|
9
|
-
function MenubarMenu({ ...props }) {
|
|
10
|
-
return _jsx(MenubarPrimitive.Menu, { "data-slot": "menubar-menu", ...props });
|
|
11
|
-
}
|
|
12
|
-
function MenubarGroup({ ...props }) {
|
|
13
|
-
return _jsx(MenubarPrimitive.Group, { "data-slot": "menubar-group", ...props });
|
|
14
|
-
}
|
|
15
|
-
function MenubarPortal({ ...props }) {
|
|
16
|
-
return _jsx(MenubarPrimitive.Portal, { "data-slot": "menubar-portal", ...props });
|
|
17
|
-
}
|
|
18
|
-
function MenubarRadioGroup({ ...props }) {
|
|
19
|
-
return (_jsx(MenubarPrimitive.RadioGroup, { "data-slot": "menubar-radio-group", ...props }));
|
|
20
|
-
}
|
|
21
|
-
function MenubarTrigger({ className, ...props }) {
|
|
22
|
-
return (_jsx(MenubarPrimitive.Trigger, { "data-slot": "menubar-trigger", className: cn("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex items-center rounded-sm px-2 py-1 text-sm font-medium outline-hidden select-none", className), ...props }));
|
|
23
|
-
}
|
|
24
|
-
function MenubarContent({ className, align = "start", alignOffset = -4, sideOffset = 8, ...props }) {
|
|
25
|
-
return (_jsx(MenubarPortal, { children: _jsx(MenubarPrimitive.Content, { "data-slot": "menubar-content", align: align, alignOffset: alignOffset, sideOffset: sideOffset, className: cn("bg-popover text-popover-foreground 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 z-50 min-w-[12rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-md", className), ...props }) }));
|
|
26
|
-
}
|
|
27
|
-
function MenubarItem({ className, inset, variant = "default", ...props }) {
|
|
28
|
-
return (_jsx(MenubarPrimitive.Item, { "data-slot": "menubar-item", "data-inset": inset, "data-variant": variant, className: cn("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className), ...props }));
|
|
29
|
-
}
|
|
30
|
-
function MenubarCheckboxItem({ className, children, checked, ...props }) {
|
|
31
|
-
return (_jsxs(MenubarPrimitive.CheckboxItem, { "data-slot": "menubar-checkbox-item", className: cn("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-xs py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className), checked: checked, ...props, children: [_jsx("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: _jsx(MenubarPrimitive.ItemIndicator, { children: _jsx(CheckIcon, { className: "size-4" }) }) }), children] }));
|
|
32
|
-
}
|
|
33
|
-
function MenubarRadioItem({ className, children, ...props }) {
|
|
34
|
-
return (_jsxs(MenubarPrimitive.RadioItem, { "data-slot": "menubar-radio-item", className: cn("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-xs py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className), ...props, children: [_jsx("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: _jsx(MenubarPrimitive.ItemIndicator, { children: _jsx(CircleIcon, { className: "size-2 fill-current" }) }) }), children] }));
|
|
35
|
-
}
|
|
36
|
-
function MenubarLabel({ className, inset, ...props }) {
|
|
37
|
-
return (_jsx(MenubarPrimitive.Label, { "data-slot": "menubar-label", "data-inset": inset, className: cn("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8", className), ...props }));
|
|
38
|
-
}
|
|
39
|
-
function MenubarSeparator({ className, ...props }) {
|
|
40
|
-
return (_jsx(MenubarPrimitive.Separator, { "data-slot": "menubar-separator", className: cn("bg-border -mx-1 my-1 h-px", className), ...props }));
|
|
41
|
-
}
|
|
42
|
-
function MenubarShortcut({ className, ...props }) {
|
|
43
|
-
return (_jsx("span", { "data-slot": "menubar-shortcut", className: cn("text-muted-foreground ml-auto text-xs tracking-widest", className), ...props }));
|
|
44
|
-
}
|
|
45
|
-
function MenubarSub({ ...props }) {
|
|
46
|
-
return _jsx(MenubarPrimitive.Sub, { "data-slot": "menubar-sub", ...props });
|
|
47
|
-
}
|
|
48
|
-
function MenubarSubTrigger({ className, inset, children, ...props }) {
|
|
49
|
-
return (_jsxs(MenubarPrimitive.SubTrigger, { "data-slot": "menubar-sub-trigger", "data-inset": inset, className: cn("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-none select-none data-[inset]:pl-8", className), ...props, children: [children, _jsx(ChevronRightIcon, { className: "ml-auto h-4 w-4" })] }));
|
|
50
|
-
}
|
|
51
|
-
function MenubarSubContent({ className, ...props }) {
|
|
52
|
-
return (_jsx(MenubarPrimitive.SubContent, { "data-slot": "menubar-sub-content", className: cn("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg", className), ...props }));
|
|
53
|
-
}
|
|
54
|
-
export { Menubar, MenubarPortal, MenubarMenu, MenubarTrigger, MenubarContent, MenubarGroup, MenubarSeparator, MenubarLabel, MenubarItem, MenubarShortcut, MenubarCheckboxItem, MenubarRadioGroup, MenubarRadioItem, MenubarSub, MenubarSubTrigger, MenubarSubContent, };
|
package/Menubar/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { Menubar, MenubarPortal, MenubarMenu, MenubarTrigger, MenubarContent, MenubarGroup, MenubarSeparator, MenubarLabel, MenubarItem, MenubarShortcut, MenubarCheckboxItem, MenubarRadioGroup, MenubarRadioItem, MenubarSub, MenubarSubTrigger, MenubarSubContent, } from "./Menubar";
|
package/Menubar/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { Menubar, MenubarPortal, MenubarMenu, MenubarTrigger, MenubarContent, MenubarGroup, MenubarSeparator, MenubarLabel, MenubarItem, MenubarShortcut, MenubarCheckboxItem, MenubarRadioGroup, MenubarRadioItem, MenubarSub, MenubarSubTrigger, MenubarSubContent, } from "./Menubar";
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
declare function Pagination({ className, ...props }: React.ComponentProps<"nav">): import("react/jsx-runtime").JSX.Element;
|
|
3
|
-
declare namespace Pagination {
|
|
4
|
-
var displayName: string;
|
|
5
|
-
}
|
|
6
|
-
declare function PaginationContent({ className, ...props }: React.ComponentProps<"ul">): import("react/jsx-runtime").JSX.Element;
|
|
7
|
-
declare namespace PaginationContent {
|
|
8
|
-
var displayName: string;
|
|
9
|
-
}
|
|
10
|
-
declare function PaginationItem({ ...props }: React.ComponentProps<"li">): import("react/jsx-runtime").JSX.Element;
|
|
11
|
-
declare namespace PaginationItem {
|
|
12
|
-
var displayName: string;
|
|
13
|
-
}
|
|
14
|
-
type PaginationLinkProps = {
|
|
15
|
-
isActive?: boolean;
|
|
16
|
-
disabled?: boolean;
|
|
17
|
-
} & React.ComponentProps<"button">;
|
|
18
|
-
declare function PaginationLink({ className, isActive, disabled, ...props }: PaginationLinkProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
-
declare namespace PaginationLink {
|
|
20
|
-
var displayName: string;
|
|
21
|
-
}
|
|
22
|
-
declare function PaginationPrevious({ className, ...props }: React.ComponentProps<typeof PaginationLink>): import("react/jsx-runtime").JSX.Element;
|
|
23
|
-
declare namespace PaginationPrevious {
|
|
24
|
-
var displayName: string;
|
|
25
|
-
}
|
|
26
|
-
declare function PaginationNext({ className, ...props }: React.ComponentProps<typeof PaginationLink>): import("react/jsx-runtime").JSX.Element;
|
|
27
|
-
declare namespace PaginationNext {
|
|
28
|
-
var displayName: string;
|
|
29
|
-
}
|
|
30
|
-
declare function PaginationEllipsis({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
|
|
31
|
-
declare namespace PaginationEllipsis {
|
|
32
|
-
var displayName: string;
|
|
33
|
-
}
|
|
34
|
-
export { Pagination, PaginationContent, PaginationLink, PaginationItem, PaginationPrevious, PaginationNext, PaginationEllipsis, };
|
|
35
|
-
export type { PaginationLinkProps };
|
package/Pagination/Pagination.js
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import { ChevronLeft, ChevronRight, MoreHorizontal } from "lucide-react";
|
|
4
|
-
import { cn } from "../lib/utils";
|
|
5
|
-
import { buttonVariants } from "../Button/Button";
|
|
6
|
-
function Pagination({ className, ...props }) {
|
|
7
|
-
return (_jsx("nav", { role: "navigation", "aria-label": "pagination", className: cn("mx-auto flex w-full justify-center", className), ...props }));
|
|
8
|
-
}
|
|
9
|
-
Pagination.displayName = "Pagination";
|
|
10
|
-
function PaginationContent({ className, ...props }) {
|
|
11
|
-
return (_jsx("ul", { className: cn("flex flex-row items-center gap-1", className), ...props }));
|
|
12
|
-
}
|
|
13
|
-
PaginationContent.displayName = "PaginationContent";
|
|
14
|
-
function PaginationItem({ ...props }) {
|
|
15
|
-
return _jsx("li", { ...props });
|
|
16
|
-
}
|
|
17
|
-
PaginationItem.displayName = "PaginationItem";
|
|
18
|
-
function PaginationLink({ className, isActive, disabled, ...props }) {
|
|
19
|
-
return (_jsx("button", { type: "button", "aria-current": isActive ? "page" : undefined, disabled: disabled, className: cn(buttonVariants({
|
|
20
|
-
variant: isActive ? "outline" : "ghost",
|
|
21
|
-
size: "small",
|
|
22
|
-
}), "size-9", disabled && "pointer-events-none opacity-50", className), ...props }));
|
|
23
|
-
}
|
|
24
|
-
PaginationLink.displayName = "PaginationLink";
|
|
25
|
-
function PaginationPrevious({ className, ...props }) {
|
|
26
|
-
return (_jsxs(PaginationLink, { "aria-label": "Go to previous page", className: cn("gap-1 pl-2.5 pr-4 w-auto", className), ...props, children: [_jsx(ChevronLeft, { className: "size-4" }), _jsx("span", { className: "hidden sm:block", children: "Previous" })] }));
|
|
27
|
-
}
|
|
28
|
-
PaginationPrevious.displayName = "PaginationPrevious";
|
|
29
|
-
function PaginationNext({ className, ...props }) {
|
|
30
|
-
return (_jsxs(PaginationLink, { "aria-label": "Go to next page", className: cn("gap-1 pl-4 pr-2.5 w-auto", className), ...props, children: [_jsx("span", { className: "hidden sm:block", children: "Next" }), _jsx(ChevronRight, { className: "size-4" })] }));
|
|
31
|
-
}
|
|
32
|
-
PaginationNext.displayName = "PaginationNext";
|
|
33
|
-
function PaginationEllipsis({ className, ...props }) {
|
|
34
|
-
return (_jsxs("span", { "aria-hidden": true, className: cn("flex size-9 items-center justify-center", className), ...props, children: [_jsx(MoreHorizontal, { className: "size-4" }), _jsx("span", { className: "sr-only", children: "More pages" })] }));
|
|
35
|
-
}
|
|
36
|
-
PaginationEllipsis.displayName = "PaginationEllipsis";
|
|
37
|
-
export { Pagination, PaginationContent, PaginationLink, PaginationItem, PaginationPrevious, PaginationNext, PaginationEllipsis, };
|
package/Popover/Popover.d.ts
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
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 PopoverAnchor: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
-
declare const PopoverContent: React.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
-
export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor };
|
package/Popover/Popover.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
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 PopoverAnchor = PopoverPrimitive.Anchor;
|
|
8
|
-
const PopoverContent = React.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => (_jsx(PopoverPrimitive.Portal, { children: _jsx(PopoverPrimitive.Content, { ref: ref, align: align, sideOffset: sideOffset, className: cn("z-50 w-72 rounded-lg border border-grey-200 bg-white p-4 text-main-950 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
|
-
PopoverContent.displayName = PopoverPrimitive.Content.displayName;
|
|
10
|
-
export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor };
|
package/Progress/Progress.d.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
|
3
|
-
type ProgressSize = "small" | "regular" | "large";
|
|
4
|
-
type ProgressVariant = "default" | "success" | "warning" | "destructive";
|
|
5
|
-
declare const progressVariants: (props?: ({
|
|
6
|
-
size?: "small" | "regular" | "large" | null | undefined;
|
|
7
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
-
declare const progressIndicatorVariants: (props?: ({
|
|
9
|
-
variant?: "default" | "destructive" | "success" | "warning" | null | undefined;
|
|
10
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
11
|
-
export interface ProgressProps extends React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root> {
|
|
12
|
-
size?: ProgressSize;
|
|
13
|
-
variant?: ProgressVariant;
|
|
14
|
-
}
|
|
15
|
-
declare const Progress: React.ForwardRefExoticComponent<ProgressProps & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
-
export { Progress, progressVariants, progressIndicatorVariants };
|
|
17
|
-
export type { ProgressSize, ProgressVariant };
|
package/Progress/Progress.js
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
|
4
|
-
import { cva } from "class-variance-authority";
|
|
5
|
-
import { cn } from "../lib/utils";
|
|
6
|
-
const progressVariants = cva("relative w-full overflow-hidden rounded-full bg-grey-100", {
|
|
7
|
-
variants: {
|
|
8
|
-
size: {
|
|
9
|
-
small: "h-1",
|
|
10
|
-
regular: "h-2",
|
|
11
|
-
large: "h-3",
|
|
12
|
-
},
|
|
13
|
-
},
|
|
14
|
-
defaultVariants: {
|
|
15
|
-
size: "regular",
|
|
16
|
-
},
|
|
17
|
-
});
|
|
18
|
-
const progressIndicatorVariants = cva("h-full w-full flex-1 transition-all", {
|
|
19
|
-
variants: {
|
|
20
|
-
variant: {
|
|
21
|
-
default: "bg-accent-600",
|
|
22
|
-
success: "bg-success-600",
|
|
23
|
-
warning: "bg-warning-500",
|
|
24
|
-
destructive: "bg-error-600",
|
|
25
|
-
},
|
|
26
|
-
},
|
|
27
|
-
defaultVariants: {
|
|
28
|
-
variant: "default",
|
|
29
|
-
},
|
|
30
|
-
});
|
|
31
|
-
const Progress = React.forwardRef(({ className, value, size, variant, ...props }, ref) => (_jsx(ProgressPrimitive.Root, { ref: ref, className: cn(progressVariants({ size }), className), ...props, children: _jsx(ProgressPrimitive.Indicator, { className: cn(progressIndicatorVariants({ variant })), style: { transform: `translateX(-${100 - (value || 0)}%)` } }) })));
|
|
32
|
-
Progress.displayName = ProgressPrimitive.Root.displayName;
|
|
33
|
-
export { Progress, progressVariants, progressIndicatorVariants };
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
3
|
-
type RadioGroupItemSize = "small" | "regular";
|
|
4
|
-
declare const RadioGroup: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
-
declare const radioGroupItemVariants: (props?: ({
|
|
6
|
-
size?: "small" | "regular" | null | undefined;
|
|
7
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
-
export interface RadioGroupItemProps extends React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item> {
|
|
9
|
-
size?: RadioGroupItemSize;
|
|
10
|
-
}
|
|
11
|
-
declare const RadioGroupItem: React.ForwardRefExoticComponent<RadioGroupItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
12
|
-
export { RadioGroup, RadioGroupItem, radioGroupItemVariants };
|
|
13
|
-
export type { RadioGroupItemSize };
|