@okam/stack-ui 1.6.1 → 1.6.2
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/ArrowDown-2bdc734f.mjs +7 -0
- package/ArrowDown-a6edacd9.js +1 -0
- package/ArrowLeft-4eeead7e.js +1 -0
- package/ArrowLeft-cfc85f6d.mjs +10 -0
- package/BrandArrowRight-686606ab.mjs +7 -0
- package/BrandArrowRight-810d374a.js +1 -0
- package/Check-5b690106.js +1 -0
- package/Check-f0e31d77.mjs +7 -0
- package/ChevronLeft-3d464239.js +1 -0
- package/ChevronLeft-50f70f08.mjs +7 -0
- package/ChevronRight-5709c683.js +1 -0
- package/ChevronRight-ea754d4d.mjs +7 -0
- package/CloseBtn-2f4aad79.mjs +13 -0
- package/CloseBtn-e65fe8bd.js +1 -0
- package/Facebook-0c77fec8.mjs +13 -0
- package/Facebook-f2646126.js +1 -0
- package/FacebookColored-9be40f21.mjs +15 -0
- package/FacebookColored-d986225c.js +1 -0
- package/Globe-cb458fad.mjs +48 -0
- package/Globe-cbe70168.js +1 -0
- package/Instagram-2f8ef20d.js +1 -0
- package/Instagram-bf4a1667.mjs +10 -0
- package/InstagramColored-6a2b2b7a.js +1 -0
- package/InstagramColored-c4931693.mjs +73 -0
- package/Link-4ef5aaf2.mjs +10 -0
- package/Link-db71325e.js +1 -0
- package/Mail-a1aec200.js +1 -0
- package/Mail-c45e037a.mjs +12 -0
- package/Plus-144cf5f8.mjs +19 -0
- package/Plus-75849570.js +1 -0
- package/Share-608e1dd8.js +1 -0
- package/Share-c707352d.mjs +15 -0
- package/Twitter-1eb11c0c.js +1 -0
- package/Twitter-78d0ccc7.mjs +15 -0
- package/TwitterColored-334512f5.mjs +15 -0
- package/TwitterColored-8b72aa64.js +1 -0
- package/Upload-1f27bbaa.mjs +13 -0
- package/Upload-578304b2.js +1 -0
- package/YouTube-5dbf2e75.js +1 -0
- package/YouTube-782a6434.mjs +15 -0
- package/YouTubeColored-45e92b0e.mjs +16 -0
- package/YouTubeColored-5baa4a6c.js +1 -0
- package/components/Accordion/index.d.ts +3 -0
- package/components/Accordion/interface.d.ts +16 -0
- package/components/Box/index.d.ts +5 -0
- package/components/Box/interface.d.ts +10 -0
- package/components/Button/index.d.ts +5 -0
- package/components/Button/interface.d.ts +16 -0
- package/components/Calendar/components/CalendarCell.d.ts +3 -0
- package/components/Calendar/components/CalendarGrid.d.ts +3 -0
- package/components/Calendar/index.d.ts +3 -0
- package/components/Calendar/interface.d.ts +32 -0
- package/components/Date/index.d.ts +3 -0
- package/components/Date/interface.d.ts +6 -0
- package/components/Dialog/index.d.ts +2 -0
- package/components/Dialog/interface.d.ts +6 -0
- package/components/Icon/index.d.ts +3 -0
- package/components/Icon/interface.d.ts +7 -0
- package/components/Lightbox/hooks/overlay/index.d.ts +12 -0
- package/components/Lightbox/hooks/overlay/interface.d.ts +2 -0
- package/components/Lightbox/index.d.ts +3 -0
- package/components/Lightbox/interface.d.ts +20 -0
- package/components/Modal/Dialog.d.ts +3 -0
- package/components/Modal/index.d.ts +3 -0
- package/components/Modal/interface.d.ts +11 -0
- package/components/Popover/index.d.ts +10 -0
- package/components/Popover/interface.d.ts +11 -0
- package/components/ShareButton/index.d.ts +4 -0
- package/components/ShareButton/interface.d.ts +23 -0
- package/components/ShareButton/utils/generateUtmTags.d.ts +2 -0
- package/components/ShareButton/utils/useFacebookShareUrl.d.ts +2 -0
- package/components/ShareButton/utils/useMailToShareUrl.d.ts +2 -0
- package/components/ShareButton/utils/useTwitterShareUrl.d.ts +2 -0
- package/components/ShareButton/utils/useWindow.d.ts +5 -0
- package/components/SidePanel/index.d.ts +4 -0
- package/components/SidePanel/interface.d.ts +9 -0
- package/components/Typography/index.d.ts +5 -0
- package/components/Typography/interface.d.ts +9 -0
- package/components/WysiwygBlock/index.d.ts +3 -0
- package/components/WysiwygBlock/interface.d.ts +5 -0
- package/components/fields/Checkbox/Checkbox.interface.d.ts +24 -0
- package/components/fields/Checkbox/index.d.ts +3 -0
- package/components/fields/DatePicker/components/CalendarPopover.d.ts +2 -0
- package/components/fields/DatePicker/components/DateField.d.ts +4 -0
- package/components/fields/DatePicker/index.d.ts +3 -0
- package/components/fields/DatePicker/interface.d.ts +37 -0
- package/components/fields/Select/Select.d.ts +4 -0
- package/components/fields/Select/Select.interface.d.ts +21 -0
- package/components/fields/Select/components/Listbox.d.ts +4 -0
- package/components/fields/Select/components/Listbox.interface.d.ts +12 -0
- package/components/fields/Select/components/Popover.d.ts +3 -0
- package/components/fields/Select/components/Popover.interface.d.ts +12 -0
- package/components/fields/TextArea/index.d.ts +3 -0
- package/components/fields/TextArea/interface.d.ts +17 -0
- package/components/fields/TextInputField/index.d.ts +4 -0
- package/components/fields/TextInputField/interface.d.ts +23 -0
- package/components/icons/ArrowDown.d.ts +3 -0
- package/components/icons/ArrowLeft.d.ts +3 -0
- package/components/icons/ArrowRight.d.ts +3 -0
- package/components/icons/BrandArrowRight.d.ts +3 -0
- package/components/icons/Check.d.ts +3 -0
- package/components/icons/ChevronLeft.d.ts +3 -0
- package/components/icons/ChevronRight.d.ts +3 -0
- package/components/icons/CloseBtn.d.ts +3 -0
- package/components/icons/Facebook.d.ts +3 -0
- package/components/icons/FacebookColored.d.ts +3 -0
- package/components/icons/Globe.d.ts +3 -0
- package/components/icons/IconFallback.d.ts +3 -0
- package/components/icons/Instagram.d.ts +3 -0
- package/components/icons/InstagramColored.d.ts +3 -0
- package/components/icons/Link.d.ts +3 -0
- package/components/icons/Mail.d.ts +3 -0
- package/components/icons/Plus.d.ts +3 -0
- package/components/icons/Share.d.ts +3 -0
- package/components/icons/Twitter.d.ts +3 -0
- package/components/icons/TwitterColored.d.ts +3 -0
- package/components/icons/Upload.d.ts +3 -0
- package/components/icons/YouTube.d.ts +3 -0
- package/components/icons/YouTubeColored.d.ts +3 -0
- package/index.d.ts +32 -0
- package/index.js +46 -4536
- package/index.mjs +9221 -0
- package/package.json +16 -12
- package/providers/Client/index.d.ts +4 -0
- package/providers/Client/interface.d.ts +10 -0
- package/providers/SidePanel/index.d.ts +4 -0
- package/providers/SidePanel/interface.d.ts +17 -0
- package/providers/Theme/hooks.d.ts +3 -0
- package/providers/Theme/index.d.ts +10 -0
- package/providers/Theme/interface.d.ts +23 -0
- package/providers/Theme/utils.d.ts +2 -0
- package/theme/Accordion/index.d.ts +154 -0
- package/theme/Box/index.d.ts +100 -0
- package/theme/Button/index.d.ts +70 -0
- package/theme/Calendar/index.d.ts +237 -0
- package/theme/Checkbox/index.d.ts +75 -0
- package/theme/DatePicker/index.d.ts +51 -0
- package/theme/LightBox/index.d.ts +143 -0
- package/theme/ShareButton/index.d.ts +110 -0
- package/theme/SidePanel/index.d.ts +15 -0
- package/theme/TextArea/index.d.ts +17 -0
- package/theme/Typography/index.d.ts +134 -0
- package/theme/index.d.ts +5 -0
- package/transitions/ModalTransition.d.ts +7 -0
- package/transitions/RenderWithSlide.d.ts +7 -0
- package/transitions/SidePanelTransition.d.ts +7 -0
- package/types/components.d.ts +23 -0
- package/README.md +0 -8
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { CalendarDate, DateValue } from '@internationalized/date';
|
|
2
|
+
import type { CalendarProps, RangeCalendarProps } from '@react-aria/calendar';
|
|
3
|
+
import type { CalendarState, RangeCalendarState } from '@react-stately/calendar';
|
|
4
|
+
import type { AriaCalendarGridProps } from 'react-aria';
|
|
5
|
+
import type { TDefaultComponent } from '../../types/components';
|
|
6
|
+
export interface TCalendarProps extends CalendarProps<DateValue>, TDefaultComponent {
|
|
7
|
+
buttons?: {
|
|
8
|
+
buttonPrev?: {
|
|
9
|
+
icon?: string;
|
|
10
|
+
};
|
|
11
|
+
buttonNext?: {
|
|
12
|
+
icon?: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
export interface TRangeCalendarProps extends RangeCalendarProps<DateValue>, TDefaultComponent {
|
|
17
|
+
buttons?: {
|
|
18
|
+
buttonPrev?: {
|
|
19
|
+
icon?: string;
|
|
20
|
+
};
|
|
21
|
+
buttonNext?: {
|
|
22
|
+
icon?: string;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
export interface TCalendarGridProps extends AriaCalendarGridProps, TDefaultComponent {
|
|
27
|
+
state: RangeCalendarState | CalendarState;
|
|
28
|
+
}
|
|
29
|
+
export interface TCalendarCellProps extends TDefaultComponent {
|
|
30
|
+
state: RangeCalendarState | CalendarState;
|
|
31
|
+
date: CalendarDate;
|
|
32
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { SVGProps } from 'react';
|
|
3
|
+
import type { TDefaultComponent } from '../../types/components';
|
|
4
|
+
export interface TIconProps extends TDefaultComponent, SVGProps<SVGSVGElement> {
|
|
5
|
+
icon?: string | React.ReactNode;
|
|
6
|
+
children?: React.ReactNode;
|
|
7
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { TOnCloseCallback, TOnOpenCallback } from './interface';
|
|
3
|
+
declare const useOverlayHook: (isOpen?: boolean, onOpenCallBack?: TOnOpenCallback, onCloseCallBack?: TOnCloseCallback) => {
|
|
4
|
+
state: import("@react-stately/overlays").OverlayTriggerState;
|
|
5
|
+
openButtonProps: React.HTMLAttributes<HTMLDivElement>;
|
|
6
|
+
closeButtonProps: React.ButtonHTMLAttributes<HTMLButtonElement>;
|
|
7
|
+
handleOpen: () => void;
|
|
8
|
+
handleClose: () => void;
|
|
9
|
+
openButtonRef: React.MutableRefObject<null>;
|
|
10
|
+
closeButtonRef: React.MutableRefObject<null>;
|
|
11
|
+
};
|
|
12
|
+
export default useOverlayHook;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { AriaOverlayProps } from '@react-aria/overlays';
|
|
2
|
+
import type { AriaDialogProps } from '@react-types/dialog';
|
|
3
|
+
import type { HTMLAttributes } from 'react';
|
|
4
|
+
import type React from 'react';
|
|
5
|
+
import type { TDefaultComponent } from '../../types/components';
|
|
6
|
+
export interface ModalProps {
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
}
|
|
9
|
+
export interface ILightboxProps extends HTMLAttributes<HTMLElement> {
|
|
10
|
+
id: string;
|
|
11
|
+
children?: React.ReactNode;
|
|
12
|
+
label?: string;
|
|
13
|
+
thumbnailContent?: React.ReactNode;
|
|
14
|
+
lightboxContent?: React.ReactNode;
|
|
15
|
+
isOpen?: boolean;
|
|
16
|
+
onOpenCallBack?: (bool: boolean) => void;
|
|
17
|
+
onCloseCallBack?: () => void;
|
|
18
|
+
}
|
|
19
|
+
export type LightboxProps = ILightboxProps & TDefaultComponent;
|
|
20
|
+
export type ModalDialogProps = AriaOverlayProps & AriaDialogProps & ModalProps;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { OverlayTriggerState } from '@react-stately/overlays';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
export interface TModalProps {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
state: OverlayTriggerState;
|
|
6
|
+
transitionComponent?: (props: {
|
|
7
|
+
isVisible: boolean;
|
|
8
|
+
children: React.ReactNode;
|
|
9
|
+
}) => JSX.Element;
|
|
10
|
+
onCloseCallBack?: () => void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { Placement } from '@react-types/overlays';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { TButtonProps } from '../Button/interface';
|
|
4
|
+
declare function PopoverButton({ children, buttonProps, placement, offset, }: {
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
buttonProps: TButtonProps;
|
|
7
|
+
placement: Placement;
|
|
8
|
+
offset: number;
|
|
9
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export default PopoverButton;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { DOMAttributes } from '@react-types/shared';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
import type { CSSProperties } from 'react';
|
|
4
|
+
export interface IPopoverProps {
|
|
5
|
+
isOpen: boolean;
|
|
6
|
+
onClose: () => void;
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
style?: CSSProperties;
|
|
9
|
+
}
|
|
10
|
+
export type TPopoverProps = DOMAttributes & IPopoverProps;
|
|
11
|
+
export type PopoverOrientation = 'left' | 'right';
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { TIconsContainerProps, TShareButtonProps } from './interface';
|
|
2
|
+
export declare const IconsContainer: (props: TIconsContainerProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare const ShareButton: (props: TShareButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export default ShareButton;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { TToken } from '../../providers/Theme/interface';
|
|
2
|
+
import type { TDefaultComponent } from '../../types/components';
|
|
3
|
+
export interface TShareButtonProps extends TDefaultComponent<TShareButtonTokens> {
|
|
4
|
+
id: string;
|
|
5
|
+
icon?: string;
|
|
6
|
+
ariaLabel: string;
|
|
7
|
+
sharingLinksList: TShareButtonLink[];
|
|
8
|
+
onShare?: (sharingMedium: string) => void;
|
|
9
|
+
}
|
|
10
|
+
interface TShareButtonTokens extends TToken {
|
|
11
|
+
listDirection: 'row' | 'column';
|
|
12
|
+
}
|
|
13
|
+
export interface TIconsContainerProps extends Omit<TShareButtonProps, 'ariaLabel' | 'icon'> {
|
|
14
|
+
isOpen: boolean;
|
|
15
|
+
}
|
|
16
|
+
export interface TShareButtonLink {
|
|
17
|
+
ariaLabel: string;
|
|
18
|
+
icon: string;
|
|
19
|
+
key: string;
|
|
20
|
+
onClick?: (linkKey: string) => void;
|
|
21
|
+
href?: string;
|
|
22
|
+
}
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { HTMLAttributes } from 'react';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
import type { TDefaultComponent } from '../../types/components';
|
|
4
|
+
export interface ISidePanelProps extends HTMLAttributes<HTMLElement> {
|
|
5
|
+
id: string;
|
|
6
|
+
children?: React.ReactNode;
|
|
7
|
+
closeBtnRender?: () => React.ReactNode;
|
|
8
|
+
}
|
|
9
|
+
export type TSidePanelProps = ISidePanelProps & TDefaultComponent;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { TTypographyProps } from './interface';
|
|
3
|
+
declare const Typography: ({ as: Component, themeName, tokens, customTheme, children, ...rest }: TTypographyProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export declare const TypographyWithForwardRef: React.ForwardRefExoticComponent<TTypographyProps<import("../..").TToken> & React.RefAttributes<HTMLElement>>;
|
|
5
|
+
export default Typography;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { TToken } from '../../providers/Theme/interface';
|
|
3
|
+
import type { TDefaultComponent } from '../../types/components';
|
|
4
|
+
export interface TTypographyProps<T = TToken> extends TDefaultComponent<T> {
|
|
5
|
+
children?: React.ReactNode;
|
|
6
|
+
dangerouslySetInnerHTML?: {
|
|
7
|
+
__html: string | TrustedHTML;
|
|
8
|
+
};
|
|
9
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { Noop, RefCallBack } from 'react-hook-form';
|
|
2
|
+
import type { TDefaultComponent } from '../../../types/components';
|
|
3
|
+
export interface TCheckboxProps extends TDefaultComponent {
|
|
4
|
+
id: string;
|
|
5
|
+
label: string;
|
|
6
|
+
name: string;
|
|
7
|
+
required?: boolean;
|
|
8
|
+
isDisabled?: boolean;
|
|
9
|
+
isError?: boolean;
|
|
10
|
+
errorMessage?: string;
|
|
11
|
+
ariaLabel?: string;
|
|
12
|
+
value?: string;
|
|
13
|
+
onBlur?: Noop;
|
|
14
|
+
onChange?: () => void;
|
|
15
|
+
inputRef?: RefCallBack;
|
|
16
|
+
}
|
|
17
|
+
export interface TCheckboxLabelStyles {
|
|
18
|
+
isDisabled?: boolean;
|
|
19
|
+
}
|
|
20
|
+
export interface TCheckboxStyles {
|
|
21
|
+
isDisabled?: boolean;
|
|
22
|
+
isFocused?: boolean;
|
|
23
|
+
isError?: boolean;
|
|
24
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { DateValue } from '@internationalized/date';
|
|
2
|
+
import type { DateFieldState, DateSegment, DatePickerStateOptions, DateRangePickerStateOptions } from '@react-stately/datepicker';
|
|
3
|
+
import type { RangeValue } from '@react-types/shared';
|
|
4
|
+
import type React from 'react';
|
|
5
|
+
import type { AriaPopoverProps } from 'react-aria';
|
|
6
|
+
import type { OverlayTriggerState } from 'react-stately';
|
|
7
|
+
import type { TDefaultComponent } from '../../../types/components';
|
|
8
|
+
export interface TDateSegmentProps {
|
|
9
|
+
segment: DateSegment;
|
|
10
|
+
state: DateFieldState;
|
|
11
|
+
}
|
|
12
|
+
type PopoverPlacement = 'bottom' | 'bottom left' | 'bottom right' | 'bottom start' | 'bottom end' | 'top' | 'top left' | 'top right' | 'top start' | 'top end' | 'left' | 'left top' | 'left bottom' | 'start' | 'start top' | 'start bottom' | 'right' | 'right top' | 'right bottom' | 'end' | 'end top' | 'end bottom';
|
|
13
|
+
export interface TDatePickerProps extends DatePickerStateOptions<DateValue>, TDefaultComponent {
|
|
14
|
+
label?: string;
|
|
15
|
+
popoverPlacement?: PopoverPlacement;
|
|
16
|
+
icon?: string;
|
|
17
|
+
buttonLabel?: string;
|
|
18
|
+
description?: string;
|
|
19
|
+
}
|
|
20
|
+
export interface TDateRangePickerProps extends DateRangePickerStateOptions<DateValue>, TDefaultComponent {
|
|
21
|
+
buttonLabel?: string;
|
|
22
|
+
label?: string;
|
|
23
|
+
description?: string;
|
|
24
|
+
icon?: string;
|
|
25
|
+
popoverPlacement?: PopoverPlacement;
|
|
26
|
+
minValue?: DateValue;
|
|
27
|
+
value?: {
|
|
28
|
+
start: DateValue;
|
|
29
|
+
end: DateValue;
|
|
30
|
+
};
|
|
31
|
+
onChange?: (value: RangeValue<DateValue>) => void;
|
|
32
|
+
}
|
|
33
|
+
export interface TCalendarPopoverProps extends Omit<AriaPopoverProps, 'popoverRef'>, TDefaultComponent {
|
|
34
|
+
children: React.ReactNode;
|
|
35
|
+
state: OverlayTriggerState;
|
|
36
|
+
}
|
|
37
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { TSelectProps } from './Select.interface';
|
|
2
|
+
declare const Select: (props: TSelectProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export declare const ReactHookFormSelect: (props: TSelectProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export default Select;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { CollectionChildren } from '@react-types/shared';
|
|
2
|
+
import type { Key } from 'react';
|
|
3
|
+
import type { RefCallBack } from 'react-hook-form';
|
|
4
|
+
import type { TDefaultComponent, TReactHookForm } from '../../../types/components';
|
|
5
|
+
export type TFieldReactHookForm = TReactHookForm & Omit<TDefaultComponent, 'children'>;
|
|
6
|
+
export interface TSelectProps extends TFieldReactHookForm {
|
|
7
|
+
id: string;
|
|
8
|
+
label?: string;
|
|
9
|
+
name: string;
|
|
10
|
+
required?: boolean;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
isError?: boolean;
|
|
13
|
+
errorMessage?: string;
|
|
14
|
+
children: CollectionChildren<object>;
|
|
15
|
+
fieldRef?: RefCallBack;
|
|
16
|
+
placeholderLabel: string;
|
|
17
|
+
hookFormRef?: RefCallBack;
|
|
18
|
+
onSelectionChange?: (value: Key) => void;
|
|
19
|
+
defaultValue?: string;
|
|
20
|
+
value?: string;
|
|
21
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { TListBoxProps, TOptionProps } from './Listbox.interface';
|
|
2
|
+
declare const Option: ({ item, state, themeName }: TOptionProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare const ListBox: (props: TListBoxProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export { ListBox, Option };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { AriaListBoxOptions, AriaOptionProps } from 'react-aria';
|
|
3
|
+
import type { ListState } from 'react-stately';
|
|
4
|
+
import type { TDefaultComponent } from '../../../../types/components';
|
|
5
|
+
export interface TListBoxProps extends AriaListBoxOptions<unknown>, TDefaultComponent {
|
|
6
|
+
listBoxRef?: React.RefObject<any>;
|
|
7
|
+
state: ListState<unknown>;
|
|
8
|
+
}
|
|
9
|
+
export interface TOptionProps extends AriaOptionProps, TDefaultComponent {
|
|
10
|
+
item: any;
|
|
11
|
+
state: ListState<unknown>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { AriaPopoverProps } from 'react-aria';
|
|
3
|
+
import type { OverlayTriggerState } from 'react-stately';
|
|
4
|
+
import type { TToken } from '../../../../providers/Theme/interface';
|
|
5
|
+
import type { TDefaultComponent } from '../../../../types/components';
|
|
6
|
+
export interface TPopoverProps extends Omit<AriaPopoverProps, 'popoverRef'>, TDefaultComponent {
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
state: OverlayTriggerState;
|
|
9
|
+
variant?: string;
|
|
10
|
+
popoverRef?: React.RefObject<HTMLDivElement>;
|
|
11
|
+
tokens: TToken;
|
|
12
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { RefCallBack } from 'react-hook-form';
|
|
2
|
+
import type { TDefaultComponent, TReactHookForm } from '../../../types/components';
|
|
3
|
+
export type TFieldReactHookForm = TReactHookForm & TDefaultComponent;
|
|
4
|
+
export interface TTextAreaProps extends TFieldReactHookForm {
|
|
5
|
+
id: string;
|
|
6
|
+
label?: string;
|
|
7
|
+
name: string;
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
required?: boolean;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
errorMessage?: string;
|
|
12
|
+
isError?: boolean;
|
|
13
|
+
ariaLabel?: string;
|
|
14
|
+
value?: string;
|
|
15
|
+
fieldRef?: RefCallBack;
|
|
16
|
+
type?: string;
|
|
17
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { TTextInputProps } from './interface';
|
|
2
|
+
declare const TextInputField: (props: TTextInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export declare const ReactHookFormInput: (props: TTextInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export default TextInputField;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { RefCallBack } from 'react-hook-form';
|
|
3
|
+
import type { TDefaultComponent, TReactHookForm } from '../../../types/components';
|
|
4
|
+
export type TFieldReactHookForm = TReactHookForm & TDefaultComponent;
|
|
5
|
+
export interface TTextInputProps extends TFieldReactHookForm {
|
|
6
|
+
id: string;
|
|
7
|
+
label?: string;
|
|
8
|
+
name: string;
|
|
9
|
+
placeholder?: string;
|
|
10
|
+
required?: boolean;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
errorMessage?: string;
|
|
13
|
+
isError?: boolean;
|
|
14
|
+
ariaLabel?: string;
|
|
15
|
+
value?: string;
|
|
16
|
+
fieldRef?: RefCallBack;
|
|
17
|
+
type?: string;
|
|
18
|
+
children?: React.ReactNode;
|
|
19
|
+
}
|
|
20
|
+
export interface TTextInputStyle extends TDefaultComponent {
|
|
21
|
+
isError?: boolean;
|
|
22
|
+
errorMessage?: string;
|
|
23
|
+
}
|