advi-ui 0.1.4 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/advi-ui.cjs.js +12 -12
- package/dist/advi-ui.cjs.js.map +1 -1
- package/dist/advi-ui.css +1 -1
- package/dist/advi-ui.es.js +1738 -1220
- package/dist/advi-ui.es.js.map +1 -1
- package/dist/src/components/CircularProgressBar.d.ts +12 -0
- package/dist/src/components/Footer.d.ts +13 -0
- package/dist/src/components/Header.d.ts +2 -1
- package/dist/src/components/HoverPopup.d.ts +9 -0
- package/dist/src/components/ui/accordion.d.ts +19 -0
- package/dist/src/components/ui/badge.d.ts +11 -0
- package/dist/src/components/ui/checkbox.d.ts +27 -0
- package/dist/src/components/ui/form-field.d.ts +15 -0
- package/dist/src/components/ui/modal.d.ts +2 -1
- package/dist/src/components/ui/multi-select.d.ts +14 -0
- package/dist/src/components/ui/radio.d.ts +27 -0
- package/dist/src/components/ui/select.d.ts +18 -0
- package/dist/src/components/ui/switch.d.ts +8 -0
- package/dist/src/components/ui/tabs.d.ts +18 -0
- package/dist/src/components/ui/textarea.d.ts +0 -1
- package/dist/src/index.d.ts +7 -0
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface CircularProgressBarProps {
|
|
3
|
+
percentage: number;
|
|
4
|
+
children?: ReactNode;
|
|
5
|
+
label?: string;
|
|
6
|
+
size?: number;
|
|
7
|
+
strokeWidth?: number;
|
|
8
|
+
animate?: boolean;
|
|
9
|
+
className?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare const CircularProgressBar: import('react').ForwardRefExoticComponent<CircularProgressBarProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Link as LinkType, LogoLinkProps } from '../../components/ui/link';
|
|
2
|
+
export interface FooterLinkGroup {
|
|
3
|
+
title?: string;
|
|
4
|
+
links: LinkType[];
|
|
5
|
+
}
|
|
6
|
+
interface FooterProps {
|
|
7
|
+
logo?: Omit<LogoLinkProps, "className">;
|
|
8
|
+
linkGroups?: FooterLinkGroup[];
|
|
9
|
+
copyright?: string;
|
|
10
|
+
className?: string;
|
|
11
|
+
}
|
|
12
|
+
export declare const Footer: ({ logo, linkGroups, copyright, className }: FooterProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -9,6 +9,7 @@ interface HeaderProps {
|
|
|
9
9
|
link: Link;
|
|
10
10
|
};
|
|
11
11
|
ctaLinks?: Link[];
|
|
12
|
+
modalRootSelector?: string;
|
|
12
13
|
}
|
|
13
|
-
export declare const Header: ({ logo, ctaLinks }: HeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare const Header: ({ logo, ctaLinks, modalRootSelector }: HeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
15
|
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface HoverPopupProps {
|
|
3
|
+
text: string;
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
className?: string;
|
|
6
|
+
triggerClassName?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const HoverPopup: ({ text, children, className, triggerClassName, }: HoverPopupProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export interface AccordionItem {
|
|
3
|
+
value: string;
|
|
4
|
+
title: string;
|
|
5
|
+
content: ReactNode;
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
}
|
|
8
|
+
export interface AccordionProps {
|
|
9
|
+
items: AccordionItem[];
|
|
10
|
+
value?: string | string[];
|
|
11
|
+
defaultValue?: string | string[];
|
|
12
|
+
onChange?: (value: string | string[]) => void;
|
|
13
|
+
multiple?: boolean;
|
|
14
|
+
className?: string;
|
|
15
|
+
}
|
|
16
|
+
export declare const Accordion: {
|
|
17
|
+
({ items, value, defaultValue, onChange, multiple, className, }: AccordionProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
displayName: string;
|
|
19
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'react';
|
|
2
|
+
export type BadgeVariant = "default" | "secondary" | "destructive" | "outline";
|
|
3
|
+
export type BadgeSize = "sm" | "default" | "lg";
|
|
4
|
+
export interface BadgeProps extends HTMLAttributes<HTMLSpanElement> {
|
|
5
|
+
variant?: BadgeVariant;
|
|
6
|
+
size?: BadgeSize;
|
|
7
|
+
}
|
|
8
|
+
export declare const Badge: {
|
|
9
|
+
({ variant, size, className, children, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
displayName: string;
|
|
11
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { InputHTMLAttributes } from 'react';
|
|
2
|
+
export interface CheckboxOption {
|
|
3
|
+
value: string;
|
|
4
|
+
label: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export type CheckboxSize = "sm" | "default" | "lg";
|
|
8
|
+
export interface CheckboxProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "type" | "size"> {
|
|
9
|
+
label?: string;
|
|
10
|
+
size?: CheckboxSize;
|
|
11
|
+
indeterminate?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export declare const Checkbox: import('react').ForwardRefExoticComponent<CheckboxProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
14
|
+
interface CheckboxGroupProps {
|
|
15
|
+
options: CheckboxOption[];
|
|
16
|
+
value?: string[];
|
|
17
|
+
defaultValue?: string[];
|
|
18
|
+
onChange?: (value: string[]) => void;
|
|
19
|
+
label?: string;
|
|
20
|
+
description?: string;
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
direction?: "vertical" | "horizontal";
|
|
23
|
+
size?: CheckboxSize;
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
export declare const CheckboxGroup: import('react').ForwardRefExoticComponent<CheckboxGroupProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface FormFieldProps {
|
|
3
|
+
label?: string;
|
|
4
|
+
htmlFor?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
error?: string;
|
|
7
|
+
required?: boolean;
|
|
8
|
+
className?: string;
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
}
|
|
11
|
+
export declare const FormField: {
|
|
12
|
+
({ label, htmlFor, description, error, required, className, children, }: FormFieldProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
export {};
|
|
@@ -8,7 +8,8 @@ interface ModalProps {
|
|
|
8
8
|
children?: ReactNode;
|
|
9
9
|
footer?: ReactNode;
|
|
10
10
|
className?: string;
|
|
11
|
+
modalRootSelector?: string;
|
|
11
12
|
duration?: number;
|
|
12
13
|
}
|
|
13
|
-
export declare const Modal: ({ open, onOpenChange, trigger, title, description, children, footer, className, duration, }: ModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare const Modal: ({ open, onOpenChange, trigger, title, description, children, footer, className, modalRootSelector, duration, }: ModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
15
|
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { SelectOption } from './select';
|
|
2
|
+
export type { SelectOption };
|
|
3
|
+
interface MultiSelectProps {
|
|
4
|
+
options: SelectOption[];
|
|
5
|
+
value?: string[];
|
|
6
|
+
onChange?: (value: string[]) => void;
|
|
7
|
+
placeholder?: string;
|
|
8
|
+
label?: string;
|
|
9
|
+
description?: string;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
className?: string;
|
|
12
|
+
maxCount?: number;
|
|
13
|
+
}
|
|
14
|
+
export declare const MultiSelect: import('react').ForwardRefExoticComponent<MultiSelectProps & import('react').RefAttributes<HTMLButtonElement>>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { InputHTMLAttributes } from 'react';
|
|
2
|
+
export interface RadioOption {
|
|
3
|
+
value: string;
|
|
4
|
+
label: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export type RadioSize = "sm" | "default" | "lg";
|
|
8
|
+
export interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "type" | "size"> {
|
|
9
|
+
label?: string;
|
|
10
|
+
size?: RadioSize;
|
|
11
|
+
}
|
|
12
|
+
export declare const Radio: import('react').ForwardRefExoticComponent<RadioProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
13
|
+
interface RadioGroupProps {
|
|
14
|
+
options: RadioOption[];
|
|
15
|
+
value?: string;
|
|
16
|
+
defaultValue?: string;
|
|
17
|
+
onChange?: (value: string) => void;
|
|
18
|
+
label?: string;
|
|
19
|
+
description?: string;
|
|
20
|
+
disabled?: boolean;
|
|
21
|
+
name?: string;
|
|
22
|
+
direction?: "vertical" | "horizontal";
|
|
23
|
+
size?: RadioSize;
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
export declare const RadioGroup: import('react').ForwardRefExoticComponent<RadioGroupProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export interface SelectOption {
|
|
2
|
+
value: string;
|
|
3
|
+
label: string;
|
|
4
|
+
disabled?: boolean;
|
|
5
|
+
}
|
|
6
|
+
interface SelectProps {
|
|
7
|
+
options: SelectOption[];
|
|
8
|
+
value?: string;
|
|
9
|
+
onChange?: (value: string) => void;
|
|
10
|
+
placeholder?: string;
|
|
11
|
+
label?: string;
|
|
12
|
+
description?: string;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
className?: string;
|
|
15
|
+
name?: string;
|
|
16
|
+
}
|
|
17
|
+
export declare const Select: import('react').ForwardRefExoticComponent<SelectProps & import('react').RefAttributes<HTMLButtonElement>>;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { InputHTMLAttributes } from 'react';
|
|
2
|
+
export type SwitchSize = "sm" | "default" | "lg";
|
|
3
|
+
export interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "type" | "size"> {
|
|
4
|
+
label?: string;
|
|
5
|
+
size?: SwitchSize;
|
|
6
|
+
labelPosition?: "left" | "right";
|
|
7
|
+
}
|
|
8
|
+
export declare const Switch: import('react').ForwardRefExoticComponent<SwitchProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export interface TabItem {
|
|
3
|
+
value: string;
|
|
4
|
+
label: string;
|
|
5
|
+
content: ReactNode;
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
}
|
|
8
|
+
export interface TabsProps {
|
|
9
|
+
tabs: TabItem[];
|
|
10
|
+
value?: string;
|
|
11
|
+
defaultValue?: string;
|
|
12
|
+
onChange?: (value: string) => void;
|
|
13
|
+
className?: string;
|
|
14
|
+
}
|
|
15
|
+
export declare const Tabs: {
|
|
16
|
+
({ tabs, value, defaultValue, onChange, className }: TabsProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
displayName: string;
|
|
18
|
+
};
|
|
@@ -2,7 +2,6 @@ import { ComponentProps } from 'react';
|
|
|
2
2
|
interface TextareaProps extends ComponentProps<"textarea"> {
|
|
3
3
|
label?: string;
|
|
4
4
|
description?: string;
|
|
5
|
-
maskedLength?: number;
|
|
6
5
|
hidden?: boolean;
|
|
7
6
|
validate?: (value: string) => string | null;
|
|
8
7
|
onValidationChange?: (valid: boolean) => void;
|
package/dist/src/index.d.ts
CHANGED
|
@@ -2,12 +2,19 @@ export * from './lib/utils';
|
|
|
2
2
|
export * from './components/ui/button';
|
|
3
3
|
export * from './components/ui/card';
|
|
4
4
|
export * from './components/ui/dialog';
|
|
5
|
+
export * from './components/ui/form-field';
|
|
5
6
|
export * from './components/ui/input';
|
|
6
7
|
export * from './components/ui/link';
|
|
7
8
|
export * from './components/ui/loading';
|
|
8
9
|
export * from './components/ui/modal';
|
|
10
|
+
export * from './components/ui/multi-select';
|
|
11
|
+
export * from './components/ui/radio';
|
|
12
|
+
export * from './components/ui/select';
|
|
9
13
|
export * from './components/ui/textarea';
|
|
10
14
|
export * from './components/ui/toast';
|
|
15
|
+
export * from './components/CircularProgressBar';
|
|
16
|
+
export * from './components/Footer';
|
|
11
17
|
export * from './components/Header';
|
|
18
|
+
export * from './components/HoverPopup';
|
|
12
19
|
export * from './components/PageNotFound';
|
|
13
20
|
export * from './components/PageAside';
|