@dimasbaguspm/versaur 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +81 -0
- package/dist/alert-DzSPXqwS.js +167 -0
- package/dist/app-bar-B4nQkgdL.js +92 -0
- package/dist/avatar-Bsn24V6g.js +91 -0
- package/dist/badge-DqLCHm9q.js +184 -0
- package/dist/bottom-bar-DOQ3gVwW.js +73 -0
- package/dist/breadcrumbs-PJV3izUu.js +59 -0
- package/dist/button-C8OibEPE.js +81 -0
- package/dist/button-float-B8tdLJkX.js +107 -0
- package/dist/button-icon-CWji4cBA.js +89 -0
- package/dist/calendar-CkLj89o2.js +112 -0
- package/dist/checkbox-input-CSboebwt.js +167 -0
- package/dist/chip-input-C1PJPDFq.js +189 -0
- package/dist/cn-Ca4KprQ1.js +2730 -0
- package/dist/components/alert/alert.atoms.d.ts +6 -0
- package/dist/components/alert/alert.d.ts +31 -0
- package/dist/components/alert/alert.stories.d.ts +42 -0
- package/dist/components/alert/helpers.d.ts +14 -0
- package/dist/components/alert/index.d.ts +2 -0
- package/dist/components/alert/types.d.ts +50 -0
- package/dist/components/alert.js +4 -0
- package/dist/components/app-bar/app-bar.atoms.d.ts +21 -0
- package/dist/components/app-bar/app-bar.d.ts +8 -0
- package/dist/components/app-bar/app-bar.stories.d.ts +19 -0
- package/dist/components/app-bar/helpers.d.ts +6 -0
- package/dist/components/app-bar/index.d.ts +2 -0
- package/dist/components/app-bar/types.d.ts +39 -0
- package/dist/components/app-bar.js +4 -0
- package/dist/components/avatar/avatar.atoms.d.ts +13 -0
- package/dist/components/avatar/avatar.d.ts +24 -0
- package/dist/components/avatar/avatar.stories.d.ts +42 -0
- package/dist/components/avatar/helpers.d.ts +14 -0
- package/dist/components/avatar/index.d.ts +2 -0
- package/dist/components/avatar/types.d.ts +46 -0
- package/dist/components/avatar.js +4 -0
- package/dist/components/badge/badge.d.ts +24 -0
- package/dist/components/badge/badge.stories.d.ts +46 -0
- package/dist/components/badge/helpers.d.ts +10 -0
- package/dist/components/badge/index.d.ts +2 -0
- package/dist/components/badge/types.d.ts +44 -0
- package/dist/components/badge.js +4 -0
- package/dist/components/bottom-bar/bottom-bar.atoms.d.ts +2 -0
- package/dist/components/bottom-bar/bottom-bar.d.ts +4 -0
- package/dist/components/bottom-bar/bottom-bar.stories.d.ts +6 -0
- package/dist/components/bottom-bar/helpers.d.ts +7 -0
- package/dist/components/bottom-bar/index.d.ts +2 -0
- package/dist/components/bottom-bar/types.d.ts +32 -0
- package/dist/components/bottom-bar.js +4 -0
- package/dist/components/breadcrumbs/breadcrumbs.atoms.d.ts +9 -0
- package/dist/components/breadcrumbs/breadcrumbs.d.ts +16 -0
- package/dist/components/breadcrumbs/breadcrumbs.stories.d.ts +7 -0
- package/dist/components/breadcrumbs/helpers.d.ts +7 -0
- package/dist/components/breadcrumbs/index.d.ts +2 -0
- package/dist/components/breadcrumbs/types.d.ts +21 -0
- package/dist/components/breadcrumbs.js +4 -0
- package/dist/components/button/button.d.ts +3 -0
- package/dist/components/button/button.stories.d.ts +50 -0
- package/dist/components/button/index.d.ts +2 -0
- package/dist/components/button/types.d.ts +30 -0
- package/dist/components/button-float/button-float.d.ts +8 -0
- package/dist/components/button-float/button-float.stories.d.ts +27 -0
- package/dist/components/button-float/helpers.d.ts +4 -0
- package/dist/components/button-float/index.d.ts +2 -0
- package/dist/components/button-float/types.d.ts +31 -0
- package/dist/components/button-float.js +4 -0
- package/dist/components/button-icon/button-icon.d.ts +3 -0
- package/dist/components/button-icon/button-icon.stories.d.ts +45 -0
- package/dist/components/button-icon/index.d.ts +2 -0
- package/dist/components/button-icon/types.d.ts +48 -0
- package/dist/components/button-icon.js +4 -0
- package/dist/components/button.js +4 -0
- package/dist/components/calendar/calendar.d.ts +8 -0
- package/dist/components/calendar/calendar.stories.d.ts +6 -0
- package/dist/components/calendar/index.d.ts +2 -0
- package/dist/components/calendar/types.d.ts +20 -0
- package/dist/components/calendar.js +4 -0
- package/dist/components/checkbox-input/checkbox-input.atoms.d.ts +9 -0
- package/dist/components/checkbox-input/checkbox-input.d.ts +5 -0
- package/dist/components/checkbox-input/checkbox-input.stories.d.ts +44 -0
- package/dist/components/checkbox-input/context.d.ts +10 -0
- package/dist/components/checkbox-input/helpers.d.ts +11 -0
- package/dist/components/checkbox-input/index.d.ts +2 -0
- package/dist/components/checkbox-input/types.d.ts +46 -0
- package/dist/components/checkbox-input.js +4 -0
- package/dist/components/chip-input/chip-input.atoms.d.ts +10 -0
- package/dist/components/chip-input/chip-input.d.ts +5 -0
- package/dist/components/chip-input/chip-input.stories.d.ts +12 -0
- package/dist/components/chip-input/context.d.ts +11 -0
- package/dist/components/chip-input/helpers.d.ts +4 -0
- package/dist/components/chip-input/index.d.ts +2 -0
- package/dist/components/chip-input/types.d.ts +51 -0
- package/dist/components/chip-input.js +4 -0
- package/dist/components/date-single-picker-input/date-single-picker-input.atoms.d.ts +13 -0
- package/dist/components/date-single-picker-input/date-single-picker-input.d.ts +10 -0
- package/dist/components/date-single-picker-input/date-single-picker-input.docked.d.ts +14 -0
- package/dist/components/date-single-picker-input/date-single-picker-input.docked.stories.d.ts +10 -0
- package/dist/components/date-single-picker-input/date-single-picker-input.modal.d.ts +15 -0
- package/dist/components/date-single-picker-input/date-single-picker-input.modal.stories.d.ts +10 -0
- package/dist/components/date-single-picker-input/helpers.d.ts +3 -0
- package/dist/components/date-single-picker-input/index.d.ts +2 -0
- package/dist/components/date-single-picker-input/types.d.ts +75 -0
- package/dist/components/date-single-picker-input/use-date-single-picker.d.ts +10 -0
- package/dist/components/date-single-picker-input.js +4 -0
- package/dist/components/drawer/context.d.ts +11 -0
- package/dist/components/drawer/drawer.atoms.d.ts +23 -0
- package/dist/components/drawer/drawer.d.ts +16 -0
- package/dist/components/drawer/drawer.stories.d.ts +41 -0
- package/dist/components/drawer/helpers.d.ts +39 -0
- package/dist/components/drawer/index.d.ts +10 -0
- package/dist/components/drawer/types.d.ts +93 -0
- package/dist/components/drawer.js +9 -0
- package/dist/components/icon/helpers.d.ts +4 -0
- package/dist/components/icon/icon.d.ts +8 -0
- package/dist/components/icon/icon.stories.d.ts +39 -0
- package/dist/components/icon/index.d.ts +2 -0
- package/dist/components/icon/types.d.ts +13 -0
- package/dist/components/icon.js +4 -0
- package/dist/components/index.d.ts +29 -0
- package/dist/components/loading-indicator/helpers.d.ts +9 -0
- package/dist/components/loading-indicator/index.d.ts +1 -0
- package/dist/components/loading-indicator/loading-indicator.atoms.d.ts +10 -0
- package/dist/components/loading-indicator/loading-indicator.d.ts +7 -0
- package/dist/components/loading-indicator/loading-indicator.stories.d.ts +16 -0
- package/dist/components/loading-indicator/types.d.ts +29 -0
- package/dist/components/loading-indicator.js +4 -0
- package/dist/components/menu/context.d.ts +13 -0
- package/dist/components/menu/helpers.d.ts +8 -0
- package/dist/components/menu/index.d.ts +2 -0
- package/dist/components/menu/menu.atoms.d.ts +14 -0
- package/dist/components/menu/menu.d.ts +7 -0
- package/dist/components/menu/menu.stories.d.ts +22 -0
- package/dist/components/menu/types.d.ts +36 -0
- package/dist/components/menu/use-menu.d.ts +3 -0
- package/dist/components/menu.js +4 -0
- package/dist/components/modal/helpers.d.ts +7 -0
- package/dist/components/modal/index.d.ts +2 -0
- package/dist/components/modal/modal.atoms.d.ts +8 -0
- package/dist/components/modal/modal.d.ts +7 -0
- package/dist/components/modal/modal.stories.d.ts +13 -0
- package/dist/components/modal/types.d.ts +48 -0
- package/dist/components/modal/use-escape-close.d.ts +6 -0
- package/dist/components/modal/use-focus-trap.d.ts +6 -0
- package/dist/components/modal.js +4 -0
- package/dist/components/radio-input/context.d.ts +11 -0
- package/dist/components/radio-input/helpers.d.ts +11 -0
- package/dist/components/radio-input/index.d.ts +2 -0
- package/dist/components/radio-input/radio-input.atoms.d.ts +9 -0
- package/dist/components/radio-input/radio-input.d.ts +5 -0
- package/dist/components/radio-input/radio-input.stories.d.ts +74 -0
- package/dist/components/radio-input/types.d.ts +54 -0
- package/dist/components/radio-input.js +4 -0
- package/dist/components/segment-multiple-input/context.d.ts +12 -0
- package/dist/components/segment-multiple-input/helpers.d.ts +15 -0
- package/dist/components/segment-multiple-input/index.d.ts +2 -0
- package/dist/components/segment-multiple-input/segment-multiple-input.atoms.d.ts +12 -0
- package/dist/components/segment-multiple-input/segment-multiple-input.d.ts +7 -0
- package/dist/components/segment-multiple-input/segment-multiple-input.stories.d.ts +66 -0
- package/dist/components/segment-multiple-input/types.d.ts +55 -0
- package/dist/components/segment-multiple-input.js +4 -0
- package/dist/components/segment-single-input/context.d.ts +12 -0
- package/dist/components/segment-single-input/helpers.d.ts +15 -0
- package/dist/components/segment-single-input/index.d.ts +2 -0
- package/dist/components/segment-single-input/segment-single-input.atoms.d.ts +11 -0
- package/dist/components/segment-single-input/segment-single-input.d.ts +7 -0
- package/dist/components/segment-single-input/segment-single-input.stories.d.ts +57 -0
- package/dist/components/segment-single-input/types.d.ts +55 -0
- package/dist/components/segment-single-input.js +4 -0
- package/dist/components/select-input/helpers.d.ts +3 -0
- package/dist/components/select-input/index.d.ts +2 -0
- package/dist/components/select-input/select-input.d.ts +9 -0
- package/dist/components/select-input/select-input.stories.d.ts +50 -0
- package/dist/components/select-input/types.d.ts +29 -0
- package/dist/components/select-input.js +4 -0
- package/dist/components/skeleton/helpers.d.ts +6 -0
- package/dist/components/skeleton/index.d.ts +2 -0
- package/dist/components/skeleton/skeleton.d.ts +6 -0
- package/dist/components/skeleton/skeleton.stories.d.ts +25 -0
- package/dist/components/skeleton/types.d.ts +17 -0
- package/dist/components/skeleton.js +4 -0
- package/dist/components/snackbar/helpers.d.ts +8 -0
- package/dist/components/snackbar/index.d.ts +2 -0
- package/dist/components/snackbar/snackbar.atoms.d.ts +10 -0
- package/dist/components/snackbar/snackbar.d.ts +6 -0
- package/dist/components/snackbar/snackbar.stories.d.ts +8 -0
- package/dist/components/snackbar/types.d.ts +40 -0
- package/dist/components/snackbar.js +4 -0
- package/dist/components/switch-input/helpers.d.ts +18 -0
- package/dist/components/switch-input/index.d.ts +3 -0
- package/dist/components/switch-input/switch-input.atoms.d.ts +28 -0
- package/dist/components/switch-input/switch-input.d.ts +6 -0
- package/dist/components/switch-input/switch-input.stories.d.ts +10 -0
- package/dist/components/switch-input/types.d.ts +49 -0
- package/dist/components/switch-input.js +7 -0
- package/dist/components/tabs/context.d.ts +3 -0
- package/dist/components/tabs/helpers.d.ts +8 -0
- package/dist/components/tabs/index.d.ts +2 -0
- package/dist/components/tabs/tabs.atoms.d.ts +10 -0
- package/dist/components/tabs/tabs.d.ts +5 -0
- package/dist/components/tabs/tabs.stories.d.ts +17 -0
- package/dist/components/tabs/types.d.ts +41 -0
- package/dist/components/tabs/use-tab-indicator.d.ts +13 -0
- package/dist/components/tabs.js +4 -0
- package/dist/components/text/helpers.d.ts +18 -0
- package/dist/components/text/index.d.ts +2 -0
- package/dist/components/text/text.d.ts +7 -0
- package/dist/components/text/text.stories.d.ts +14 -0
- package/dist/components/text/types.d.ts +30 -0
- package/dist/components/text-input/helpers.d.ts +3 -0
- package/dist/components/text-input/index.d.ts +2 -0
- package/dist/components/text-input/text-input.d.ts +9 -0
- package/dist/components/text-input/text-input.stories.d.ts +20 -0
- package/dist/components/text-input/types.d.ts +33 -0
- package/dist/components/text-input.js +4 -0
- package/dist/components/text.js +4 -0
- package/dist/components/textarea-input/helpers.d.ts +4 -0
- package/dist/components/textarea-input/index.d.ts +2 -0
- package/dist/components/textarea-input/textarea-input.d.ts +10 -0
- package/dist/components/textarea-input/textarea-input.stories.d.ts +50 -0
- package/dist/components/textarea-input/types.d.ts +40 -0
- package/dist/components/textarea-input.js +4 -0
- package/dist/components/tile/helpers.d.ts +8 -0
- package/dist/components/tile/index.d.ts +2 -0
- package/dist/components/tile/tile.d.ts +11 -0
- package/dist/components/tile/tile.stories.d.ts +35 -0
- package/dist/components/tile/types.d.ts +23 -0
- package/dist/components/tile.js +4 -0
- package/dist/components/top-bar/helpers.d.ts +26 -0
- package/dist/components/top-bar/index.d.ts +2 -0
- package/dist/components/top-bar/top-bar.atoms.d.ts +6 -0
- package/dist/components/top-bar/top-bar.d.ts +8 -0
- package/dist/components/top-bar/top-bar.stories.d.ts +15 -0
- package/dist/components/top-bar/types.d.ts +38 -0
- package/dist/components/top-bar.js +4 -0
- package/dist/date-single-picker-input--Ew0O9NQ.js +252 -0
- package/dist/drawer-DrnAR2a4.js +218 -0
- package/dist/helpers-CEDtBUGM.js +37 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/index.js +1 -0
- package/dist/icon-D-lTZMHY.js +44 -0
- package/dist/index-DU1SCUkk.js +329 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +68 -0
- package/dist/loading-indicator-BZMnT5PA.js +168 -0
- package/dist/menu-BZvilMF7.js +174 -0
- package/dist/modal-BGAtqMl9.js +149 -0
- package/dist/radio-input-BRGoevZY.js +173 -0
- package/dist/segment-multiple-input-VwHCqFd6.js +229 -0
- package/dist/segment-single-input-Cqoo7-C2.js +228 -0
- package/dist/select-input-DCb0usvK.js +108 -0
- package/dist/skeleton-D4X5USf_.js +59 -0
- package/dist/snackbar-CYias-fJ.js +79 -0
- package/dist/styles.css +115 -0
- package/dist/switch-input-C5s1lvYh.js +186 -0
- package/dist/tabs-C8aRKfxS.js +216 -0
- package/dist/text-B7e-au41.js +120 -0
- package/dist/text-input-BsWvUk_H.js +73 -0
- package/dist/textarea-input-DZExXEE8.js +102 -0
- package/dist/tile-Du7YciCG.js +51 -0
- package/dist/top-bar-ErHvwR4K.js +62 -0
- package/package.json +97 -0
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { InputHTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Props for the ChipInput component
|
|
4
|
+
*/
|
|
5
|
+
export interface ChipInputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'size' | 'onChange' | 'value'> {
|
|
6
|
+
/**
|
|
7
|
+
* Visual style variant supporting Versaur color system
|
|
8
|
+
* Core variants: primary (coral), secondary (sage), tertiary (mist), ghost (slate), neutral (light gray)
|
|
9
|
+
* Semantic variants: success, info, warning, danger
|
|
10
|
+
* Each variant supports outline form for flexible design expression
|
|
11
|
+
*/
|
|
12
|
+
variant?: 'primary' | 'secondary' | 'tertiary' | 'ghost' | 'neutral' | 'success' | 'info' | 'warning' | 'danger';
|
|
13
|
+
/**
|
|
14
|
+
* Label text to display above the chip group
|
|
15
|
+
*/
|
|
16
|
+
label?: ReactNode;
|
|
17
|
+
/**
|
|
18
|
+
* Helper text to display below the chip group
|
|
19
|
+
*/
|
|
20
|
+
helperText?: ReactNode;
|
|
21
|
+
/**
|
|
22
|
+
* Error message for invalid state
|
|
23
|
+
*/
|
|
24
|
+
error?: ReactNode;
|
|
25
|
+
/**
|
|
26
|
+
* The name attribute for the checkbox group - required for checkbox functionality
|
|
27
|
+
*/
|
|
28
|
+
name: string;
|
|
29
|
+
/**
|
|
30
|
+
* Current selected values (controlled component)
|
|
31
|
+
* Array of strings representing selected option values
|
|
32
|
+
*/
|
|
33
|
+
value?: string[];
|
|
34
|
+
/**
|
|
35
|
+
* Callback when value changes
|
|
36
|
+
*/
|
|
37
|
+
onChange?: (value: string[]) => void;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Props for the ChipInput.Option component
|
|
41
|
+
*/
|
|
42
|
+
export interface ChipInputOptionProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'name'> {
|
|
43
|
+
/**
|
|
44
|
+
* The option label content
|
|
45
|
+
*/
|
|
46
|
+
children: ReactNode;
|
|
47
|
+
/**
|
|
48
|
+
* The value for this chip option
|
|
49
|
+
*/
|
|
50
|
+
value: string;
|
|
51
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DateSinglePickerModalFooterProps, DateSinglePickerInputProps } from './types';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
export interface DateSinglePickerTriggerProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'value'> {
|
|
4
|
+
leftContent?: React.ReactNode;
|
|
5
|
+
rightContent?: React.ReactNode;
|
|
6
|
+
hasError?: boolean;
|
|
7
|
+
variant?: DateSinglePickerInputProps['variant'];
|
|
8
|
+
value?: Date;
|
|
9
|
+
placeholder?: string;
|
|
10
|
+
formatDate?: (date?: Date) => string;
|
|
11
|
+
}
|
|
12
|
+
export declare const DateSinglePickerTrigger: React.ForwardRefExoticComponent<DateSinglePickerTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
13
|
+
export declare const DateSinglePickerModalFooter: ({ onCancel, onConfirm, confirmDisabled, }: DateSinglePickerModalFooterProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { DateSinglePickerInputProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* DateSinglePickerInput component for Versaur UI
|
|
5
|
+
*
|
|
6
|
+
* Styled like TextInput, but acts as a button to pick a single date
|
|
7
|
+
* Clicking opens a docked Calendar below the input
|
|
8
|
+
* Strictly typed, accessible, and visually consistent with TextInput
|
|
9
|
+
*/
|
|
10
|
+
export declare const DateSinglePickerInput: React.ForwardRefExoticComponent<DateSinglePickerInputProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface DateSinglePickerDockedProps {
|
|
3
|
+
open: boolean;
|
|
4
|
+
value: Date | undefined;
|
|
5
|
+
onChange: (date: Date) => void;
|
|
6
|
+
inputId: string;
|
|
7
|
+
handleMenuClose: () => void;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Docked calendar atom for DateSinglePickerInput
|
|
11
|
+
* Handles Menu and Calendar rendering for docked type
|
|
12
|
+
*/
|
|
13
|
+
export declare const DateSinglePickerDocked: React.FC<DateSinglePickerDockedProps>;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { DateSinglePickerInput } from './date-single-picker-input';
|
|
3
|
+
declare const meta: Meta<typeof DateSinglePickerInput>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof DateSinglePickerInput>;
|
|
6
|
+
export declare const DockedDefault: Story;
|
|
7
|
+
export declare const DockedWithLeftIcon: Story;
|
|
8
|
+
export declare const DockedErrorState: Story;
|
|
9
|
+
export declare const DockedDisabled: Story;
|
|
10
|
+
export declare const DockedAllVariants: Story;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface DateSinglePickerModalProps {
|
|
3
|
+
open: boolean;
|
|
4
|
+
setOpen: (open: boolean) => void;
|
|
5
|
+
value: Date | undefined;
|
|
6
|
+
onChange: (date: Date) => void;
|
|
7
|
+
label?: string;
|
|
8
|
+
buttonRef: React.RefObject<HTMLButtonElement>;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Modal calendar atom for DateSinglePickerInput
|
|
12
|
+
* Handles Modal, Calendar, and ModalFooter for modal type
|
|
13
|
+
*/
|
|
14
|
+
export declare const DateSinglePickerModal: React.FC<DateSinglePickerModalProps>;
|
|
15
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { DateSinglePickerInput } from './date-single-picker-input';
|
|
3
|
+
declare const meta: Meta<typeof DateSinglePickerInput>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof DateSinglePickerInput>;
|
|
6
|
+
export declare const ModalDefault: Story;
|
|
7
|
+
export declare const ModalWithLeftIcon: Story;
|
|
8
|
+
export declare const ModalErrorState: Story;
|
|
9
|
+
export declare const ModalDisabled: Story;
|
|
10
|
+
export declare const ModalAllVariants: Story;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export declare const dateSinglePickerInputVariants: (props?: ({
|
|
2
|
+
variant?: "primary" | "secondary" | "tertiary" | "ghost" | "neutral" | "success" | "info" | "warning" | "danger" | "primary-outline" | "secondary-outline" | "tertiary-outline" | "ghost-outline" | "neutral-outline" | "success-outline" | "info-outline" | "warning-outline" | "danger-outline" | null | undefined;
|
|
3
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Props for the DateSinglePickerInput component
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Props for the DateSinglePickerInput component
|
|
7
|
+
*/
|
|
8
|
+
export interface DateSinglePickerInputProps {
|
|
9
|
+
/**
|
|
10
|
+
* Picker display type: 'docked' (default) or 'modal'.
|
|
11
|
+
* 'docked' shows calendar below input, 'modal' opens a modal at top.
|
|
12
|
+
*/
|
|
13
|
+
type?: 'docked' | 'modal';
|
|
14
|
+
/**
|
|
15
|
+
* The selected date value
|
|
16
|
+
*/
|
|
17
|
+
value?: Date;
|
|
18
|
+
/**
|
|
19
|
+
* Callback when a date is selected
|
|
20
|
+
*/
|
|
21
|
+
onChange?: (date: Date) => void;
|
|
22
|
+
/**
|
|
23
|
+
* Label text to display above the input
|
|
24
|
+
*/
|
|
25
|
+
label?: ReactNode;
|
|
26
|
+
/**
|
|
27
|
+
* Optional content to display inside the input (left)
|
|
28
|
+
*/
|
|
29
|
+
leftContent?: ReactNode;
|
|
30
|
+
/**
|
|
31
|
+
* Optional content to display inside the input (right)
|
|
32
|
+
*/
|
|
33
|
+
rightContent?: ReactNode;
|
|
34
|
+
/**
|
|
35
|
+
* Helper text to display below the input
|
|
36
|
+
*/
|
|
37
|
+
helperText?: ReactNode;
|
|
38
|
+
/**
|
|
39
|
+
* Error message for invalid state
|
|
40
|
+
*/
|
|
41
|
+
error?: ReactNode;
|
|
42
|
+
/**
|
|
43
|
+
* Visual style variant supporting Versaur color system
|
|
44
|
+
*/
|
|
45
|
+
variant?: 'primary' | 'primary-outline' | 'secondary' | 'secondary-outline' | 'tertiary' | 'tertiary-outline' | 'ghost' | 'ghost-outline' | 'neutral' | 'neutral-outline' | 'success' | 'success-outline' | 'info' | 'info-outline' | 'warning' | 'warning-outline' | 'danger' | 'danger-outline';
|
|
46
|
+
/**
|
|
47
|
+
* Disabled state
|
|
48
|
+
*/
|
|
49
|
+
disabled?: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Placeholder text when no date is selected
|
|
52
|
+
*/
|
|
53
|
+
placeholder?: ReactNode;
|
|
54
|
+
/**
|
|
55
|
+
* Optional id for the input element
|
|
56
|
+
*/
|
|
57
|
+
id?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Optional custom date formatter. If not provided, uses default format.
|
|
60
|
+
* @param date Date to format
|
|
61
|
+
* @returns Formatted date string
|
|
62
|
+
*/
|
|
63
|
+
formatDate?: (date?: Date) => string;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Atoms for DateSinglePickerInput modal type
|
|
67
|
+
*/
|
|
68
|
+
export interface DateSinglePickerModalContentProps {
|
|
69
|
+
children: ReactNode;
|
|
70
|
+
}
|
|
71
|
+
export interface DateSinglePickerModalFooterProps {
|
|
72
|
+
onCancel: () => void;
|
|
73
|
+
onConfirm: () => void;
|
|
74
|
+
confirmDisabled?: boolean;
|
|
75
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare function useDateSinglePicker({ id }: {
|
|
2
|
+
id?: string;
|
|
3
|
+
}): {
|
|
4
|
+
open: boolean;
|
|
5
|
+
setOpen: import('react').Dispatch<import('react').SetStateAction<boolean>>;
|
|
6
|
+
inputId: string;
|
|
7
|
+
buttonRef: import('react').RefObject<HTMLButtonElement | null>;
|
|
8
|
+
handleKeyDown: (e: React.KeyboardEvent<HTMLButtonElement>) => void;
|
|
9
|
+
handleMenuClose: () => void;
|
|
10
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DrawerContextValue } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Context for the Drawer compound component
|
|
4
|
+
* Provides shared state and functions across all drawer sub-components
|
|
5
|
+
*/
|
|
6
|
+
export declare const DrawerContext: import('react').Context<DrawerContextValue | null>;
|
|
7
|
+
/**
|
|
8
|
+
* Hook to access drawer context
|
|
9
|
+
* Throws an error if used outside of a DrawerRoot component
|
|
10
|
+
*/
|
|
11
|
+
export declare function useDrawerContext(): DrawerContextValue;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { DrawerHeaderProps, DrawerBodyProps, DrawerFooterProps, DrawerOverlayProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* DrawerOverlay - Background overlay that appears behind the drawer
|
|
5
|
+
* Always provides a dark blurred background to help users focus on the drawer content
|
|
6
|
+
*/
|
|
7
|
+
export declare const DrawerOverlay: React.ForwardRefExoticComponent<DrawerOverlayProps & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
/**
|
|
9
|
+
* DrawerHeader - Header section of the drawer
|
|
10
|
+
* Typically contains the title and close button
|
|
11
|
+
*/
|
|
12
|
+
export declare const DrawerHeader: React.ForwardRefExoticComponent<DrawerHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
/**
|
|
14
|
+
* DrawerBody - Main content area of the drawer
|
|
15
|
+
* Scrollable container for the drawer content
|
|
16
|
+
*/
|
|
17
|
+
export declare const DrawerBody: React.ForwardRefExoticComponent<DrawerBodyProps & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
+
/**
|
|
19
|
+
* DrawerFooter - Footer section of the drawer
|
|
20
|
+
* Typically contains action buttons
|
|
21
|
+
* Supports responsive flex behavior for optimal button layout across screen sizes
|
|
22
|
+
*/
|
|
23
|
+
export declare const DrawerFooter: React.ForwardRefExoticComponent<DrawerFooterProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { DrawerProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* Drawer - A controlled sliding drawer overlay component
|
|
5
|
+
* Provides additional space for content with positioning, sizing, and glass variant options
|
|
6
|
+
*/
|
|
7
|
+
export declare const DrawerRoot: React.FC<DrawerProps>;
|
|
8
|
+
/**
|
|
9
|
+
* Drawer - Compound component with sub-components attached
|
|
10
|
+
* Provides a convenient API for using the drawer with all its parts
|
|
11
|
+
*/
|
|
12
|
+
export declare const Drawer: React.FC<DrawerProps> & {
|
|
13
|
+
Header: React.ForwardRefExoticComponent<import('./types').DrawerHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
14
|
+
Body: React.ForwardRefExoticComponent<import('./types').DrawerBodyProps & React.RefAttributes<HTMLDivElement>>;
|
|
15
|
+
Footer: React.ForwardRefExoticComponent<import('./types').DrawerFooterProps & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Drawer } from './drawer';
|
|
3
|
+
declare const meta: Meta<typeof Drawer>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof Drawer>;
|
|
6
|
+
/**
|
|
7
|
+
* Default drawer with standard settings
|
|
8
|
+
* Shows a basic controlled drawer with header, body, and footer sections
|
|
9
|
+
*/
|
|
10
|
+
export declare const Default: Story;
|
|
11
|
+
/**
|
|
12
|
+
* Left position drawer
|
|
13
|
+
* Demonstrates a drawer that slides in from the left side
|
|
14
|
+
*/
|
|
15
|
+
export declare const LeftPosition: Story;
|
|
16
|
+
/**
|
|
17
|
+
* Glass variant drawer
|
|
18
|
+
* Shows the glass variant with transparent backdrop blur effects on the drawer content
|
|
19
|
+
* The overlay remains dark to maintain focus, while the drawer itself becomes glass-like
|
|
20
|
+
*/
|
|
21
|
+
export declare const GlassVariant: Story;
|
|
22
|
+
/**
|
|
23
|
+
* Large size drawer
|
|
24
|
+
* Demonstrates different drawer sizes
|
|
25
|
+
*/
|
|
26
|
+
export declare const LargeSize: Story;
|
|
27
|
+
/**
|
|
28
|
+
* Three-quarters width drawer
|
|
29
|
+
* Shows a drawer that takes 75% of the viewport width, ideal for dashboards or complex forms
|
|
30
|
+
*/
|
|
31
|
+
export declare const ThreeQuartersWidth: Story;
|
|
32
|
+
/**
|
|
33
|
+
* Full width drawer
|
|
34
|
+
* Shows a drawer that takes the full width of the viewport
|
|
35
|
+
*/
|
|
36
|
+
export declare const FullWidth: Story;
|
|
37
|
+
/**
|
|
38
|
+
* Custom footer layout (non-responsive)
|
|
39
|
+
* Shows how to disable the responsive behavior for custom button arrangements
|
|
40
|
+
*/
|
|
41
|
+
export declare const CustomFooterLayout: Story;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Drawer overlay variants using CVA
|
|
3
|
+
* Always provides a dark blurred background to help users focus on the drawer content
|
|
4
|
+
*/
|
|
5
|
+
export declare const drawerOverlayVariants: (props?: ({
|
|
6
|
+
state?: "open" | "closed" | null | undefined;
|
|
7
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
8
|
+
/**
|
|
9
|
+
* Drawer content variants using CVA
|
|
10
|
+
* Provides different sizes, positions, and visual styles for the drawer content
|
|
11
|
+
* Glass variant creates a transparent glass-like appearance with backdrop blur
|
|
12
|
+
*/
|
|
13
|
+
export declare const drawerVariants: (props?: ({
|
|
14
|
+
position?: "right" | "left" | null | undefined;
|
|
15
|
+
size?: "sm" | "md" | "lg" | "xl" | "3/4" | "full" | null | undefined;
|
|
16
|
+
variant?: "default" | "glass" | null | undefined;
|
|
17
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
18
|
+
/**
|
|
19
|
+
* Drawer header variants
|
|
20
|
+
* Glass variant creates a transparent header that maintains layout structure
|
|
21
|
+
*/
|
|
22
|
+
export declare const drawerHeaderVariants: (props?: ({
|
|
23
|
+
variant?: "default" | "glass" | null | undefined;
|
|
24
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
25
|
+
/**
|
|
26
|
+
* Drawer body variants
|
|
27
|
+
*/
|
|
28
|
+
export declare const drawerBodyVariants: (props?: ({
|
|
29
|
+
variant?: "default" | "glass" | null | undefined;
|
|
30
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
31
|
+
/**
|
|
32
|
+
* Drawer footer variants
|
|
33
|
+
* Glass variant creates a transparent footer that maintains layout structure
|
|
34
|
+
* Responsive flex behavior: on small screens children expand, on larger screens children are right-aligned and sized to content
|
|
35
|
+
*/
|
|
36
|
+
export declare const drawerFooterVariants: (props?: ({
|
|
37
|
+
variant?: "default" | "glass" | null | undefined;
|
|
38
|
+
responsiveFlex?: boolean | null | undefined;
|
|
39
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Drawer component exports
|
|
3
|
+
*
|
|
4
|
+
* Provides a sliding drawer overlay component with compound pattern
|
|
5
|
+
* Supports left/right positioning, multiple sizes, and glass variant
|
|
6
|
+
*/
|
|
7
|
+
export { Drawer } from './drawer';
|
|
8
|
+
export { DrawerOverlay, DrawerHeader, DrawerBody, DrawerFooter, } from './drawer.atoms';
|
|
9
|
+
export { useDrawerContext } from './context';
|
|
10
|
+
export type { DrawerProps, DrawerHeaderProps, DrawerBodyProps, DrawerFooterProps, DrawerOverlayProps, DrawerContextValue, DrawerPosition, DrawerSize, DrawerVariant, DrawerVariantProps, } from './types';
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
+
import { VariantProps } from '../../utils/variants';
|
|
3
|
+
import { drawerVariants } from './helpers';
|
|
4
|
+
/**
|
|
5
|
+
* Base drawer variant props derived from the drawer variants
|
|
6
|
+
*/
|
|
7
|
+
export type DrawerVariantProps = VariantProps<typeof drawerVariants>;
|
|
8
|
+
/**
|
|
9
|
+
* Drawer positioning options
|
|
10
|
+
*/
|
|
11
|
+
export type DrawerPosition = 'left' | 'right';
|
|
12
|
+
/**
|
|
13
|
+
* Drawer size options
|
|
14
|
+
*/
|
|
15
|
+
export type DrawerSize = 'sm' | 'md' | 'lg' | 'xl' | '3/4' | 'full';
|
|
16
|
+
/**
|
|
17
|
+
* Drawer variant options
|
|
18
|
+
*/
|
|
19
|
+
export type DrawerVariant = 'default' | 'glass';
|
|
20
|
+
/**
|
|
21
|
+
* Context value for the Drawer compound component
|
|
22
|
+
*/
|
|
23
|
+
export interface DrawerContextValue {
|
|
24
|
+
/** Whether the drawer is open */
|
|
25
|
+
isOpen: boolean;
|
|
26
|
+
/** Function to close the drawer */
|
|
27
|
+
onClose: () => void;
|
|
28
|
+
/** Drawer position (left or right) */
|
|
29
|
+
position: DrawerPosition;
|
|
30
|
+
/** Drawer size */
|
|
31
|
+
size: DrawerSize;
|
|
32
|
+
/** Drawer variant */
|
|
33
|
+
variant: DrawerVariant;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Props for the Drawer component (controlled component)
|
|
37
|
+
*/
|
|
38
|
+
export interface DrawerProps extends ComponentPropsWithoutRef<'div'> {
|
|
39
|
+
/** Whether the drawer is open (required - controlled component) */
|
|
40
|
+
isOpen: boolean;
|
|
41
|
+
/** Callback when the drawer should close */
|
|
42
|
+
onClose: (open: boolean) => void;
|
|
43
|
+
/** Drawer position */
|
|
44
|
+
position?: DrawerPosition;
|
|
45
|
+
/** Drawer size */
|
|
46
|
+
size?: DrawerSize;
|
|
47
|
+
/** Drawer variant */
|
|
48
|
+
variant?: DrawerVariant;
|
|
49
|
+
/** Children components */
|
|
50
|
+
children: ReactNode;
|
|
51
|
+
/** Additional CSS classes */
|
|
52
|
+
className?: string;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Props for the DrawerHeader component
|
|
56
|
+
*/
|
|
57
|
+
export interface DrawerHeaderProps extends ComponentPropsWithoutRef<'div'> {
|
|
58
|
+
/** Children components */
|
|
59
|
+
children: ReactNode;
|
|
60
|
+
/** Additional CSS classes */
|
|
61
|
+
className?: string;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Props for the DrawerBody component
|
|
65
|
+
*/
|
|
66
|
+
export interface DrawerBodyProps extends ComponentPropsWithoutRef<'div'> {
|
|
67
|
+
/** Children components */
|
|
68
|
+
children: ReactNode;
|
|
69
|
+
/** Additional CSS classes */
|
|
70
|
+
className?: string;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Props for the DrawerFooter component
|
|
74
|
+
*/
|
|
75
|
+
export interface DrawerFooterProps extends ComponentPropsWithoutRef<'div'> {
|
|
76
|
+
/** Children components */
|
|
77
|
+
children: ReactNode;
|
|
78
|
+
/** Additional CSS classes */
|
|
79
|
+
className?: string;
|
|
80
|
+
/**
|
|
81
|
+
* Enable responsive flex behavior
|
|
82
|
+
* When true (default): on small screens children expand (flex-grow), on larger screens children are right-aligned and sized to content
|
|
83
|
+
* When false: children behavior is not modified by responsive rules
|
|
84
|
+
*/
|
|
85
|
+
responsiveFlex?: boolean;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Props for the DrawerOverlay component
|
|
89
|
+
*/
|
|
90
|
+
export interface DrawerOverlayProps extends ComponentPropsWithoutRef<'div'> {
|
|
91
|
+
/** Additional CSS classes */
|
|
92
|
+
className?: string;
|
|
93
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const iconVariants: (props?: ({
|
|
2
|
+
size?: "sm" | "md" | "lg" | "xs" | "xl" | null | undefined;
|
|
3
|
+
color?: "primary" | "secondary" | "tertiary" | "ghost" | "neutral" | "success" | "info" | "warning" | "danger" | null | undefined;
|
|
4
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { IconProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* Icon component for Versaur UI
|
|
5
|
+
* Wraps Lucide icons and enforces consistent size and color
|
|
6
|
+
* @example <Icon color="primary" size="md"><LucideIcon /></Icon>
|
|
7
|
+
*/
|
|
8
|
+
export declare const Icon: React.FC<IconProps>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
title: string;
|
|
3
|
+
component: import('react').FC<import('./types').IconProps>;
|
|
4
|
+
tags: string[];
|
|
5
|
+
};
|
|
6
|
+
export default _default;
|
|
7
|
+
export declare const Basic: {
|
|
8
|
+
render: () => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
name: string;
|
|
10
|
+
parameters: {
|
|
11
|
+
docs: {
|
|
12
|
+
description: {
|
|
13
|
+
story: string;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
export declare const AllSizes: {
|
|
19
|
+
render: () => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
name: string;
|
|
21
|
+
parameters: {
|
|
22
|
+
docs: {
|
|
23
|
+
description: {
|
|
24
|
+
story: string;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
export declare const AllColors: {
|
|
30
|
+
render: () => import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
name: string;
|
|
32
|
+
parameters: {
|
|
33
|
+
docs: {
|
|
34
|
+
description: {
|
|
35
|
+
story: string;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* IconProps defines the props for the Icon component
|
|
4
|
+
* @property color - Color variant based on Versaur color system
|
|
5
|
+
* @property size - Size of the icon (xs, sm, md, lg, xl)
|
|
6
|
+
* @property children - The icon element (usually from lucide-react)
|
|
7
|
+
* Extends HTMLAttributes<HTMLSpanElement> for native span props
|
|
8
|
+
*/
|
|
9
|
+
export interface IconProps extends HTMLAttributes<HTMLSpanElement> {
|
|
10
|
+
color?: 'primary' | 'secondary' | 'tertiary' | 'ghost' | 'neutral' | 'success' | 'info' | 'warning' | 'danger';
|
|
11
|
+
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
12
|
+
children: ReactNode;
|
|
13
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export * from './alert';
|
|
2
|
+
export * from './app-bar';
|
|
3
|
+
export * from './avatar';
|
|
4
|
+
export * from './badge';
|
|
5
|
+
export * from './bottom-bar';
|
|
6
|
+
export * from './breadcrumbs';
|
|
7
|
+
export * from './button';
|
|
8
|
+
export * from './button-icon';
|
|
9
|
+
export * from './button-float';
|
|
10
|
+
export * from './checkbox-input';
|
|
11
|
+
export * from './chip-input';
|
|
12
|
+
export * from './date-single-picker-input';
|
|
13
|
+
export * from './drawer';
|
|
14
|
+
export * from './icon';
|
|
15
|
+
export * from './menu';
|
|
16
|
+
export * from './radio-input';
|
|
17
|
+
export * from './segment-single-input';
|
|
18
|
+
export * from './segment-multiple-input';
|
|
19
|
+
export * from './select-input';
|
|
20
|
+
export * from './snackbar';
|
|
21
|
+
export * from './tabs';
|
|
22
|
+
export * from './text';
|
|
23
|
+
export * from './text-input';
|
|
24
|
+
export * from './textarea-input';
|
|
25
|
+
export * from './tile';
|
|
26
|
+
export * from './top-bar';
|
|
27
|
+
export * from './loading-indicator';
|
|
28
|
+
export * from './switch-input';
|
|
29
|
+
export * from './skeleton';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const spinnerVariants: (props?: ({
|
|
2
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
3
|
+
color?: "primary" | "secondary" | "tertiary" | "ghost" | "neutral" | "success" | "info" | "warning" | "danger" | null | undefined;
|
|
4
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
5
|
+
export declare const barVariants: (props?: ({
|
|
6
|
+
color?: "primary" | "secondary" | "tertiary" | "ghost" | "neutral" | "success" | "info" | "warning" | "danger" | null | undefined;
|
|
7
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
8
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
9
|
+
export declare const getBarBgClass: (color: string) => "bg-coral" | "bg-sage" | "bg-mist" | "bg-slate" | "bg-neutral" | "bg-success" | "bg-info" | "bg-warning" | "bg-danger";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './loading-indicator';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { LoadingIndicatorProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* SpinnerAtom - circular loading indicator
|
|
5
|
+
*/
|
|
6
|
+
export declare const SpinnerAtom: React.ForwardRefExoticComponent<LoadingIndicatorProps & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
/**
|
|
8
|
+
* BarAtom - linear loading indicator
|
|
9
|
+
*/
|
|
10
|
+
export declare const BarAtom: React.ForwardRefExoticComponent<LoadingIndicatorProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { LoadingIndicatorProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* LoadingIndicator displays a visual loading state using spinner or bar type
|
|
5
|
+
* Follows Versaur design system and Material guidelines for loading indicators
|
|
6
|
+
*/
|
|
7
|
+
export declare const LoadingIndicator: React.ForwardRefExoticComponent<LoadingIndicatorProps & React.RefAttributes<HTMLDivElement>>;
|