@aic-kits/react 0.0.21 → 0.1.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/dist/components/Art/BrandArt.d.ts +3 -0
- package/dist/components/Art/EmojiArt.d.ts +3 -0
- package/dist/components/Art/IconArt.d.ts +3 -0
- package/dist/components/Art/ImageArt.d.ts +3 -0
- package/dist/components/Art/SvgArt.d.ts +3 -0
- package/dist/components/Art/index.d.ts +11 -0
- package/dist/components/Art/types.d.ts +75 -0
- package/dist/components/Art/utils.d.ts +16 -0
- package/dist/components/Base/index.d.ts +4 -0
- package/dist/components/Base/types.d.ts +15 -0
- package/dist/components/Button/StyledButton.d.ts +30 -0
- package/dist/components/Button/index.d.ts +54 -0
- package/dist/components/Button/utils.d.ts +3 -0
- package/dist/components/Divider/StyledDivider.d.ts +12 -0
- package/dist/components/Divider/index.d.ts +21 -0
- package/dist/components/Header/index.d.ts +4 -0
- package/dist/components/Header/types.d.ts +57 -0
- package/dist/components/Input/StyledInput.d.ts +11 -0
- package/dist/components/Input/index.d.ts +54 -0
- package/dist/components/List/index.d.ts +46 -0
- package/dist/components/Loading/StyledLoading.d.ts +10 -0
- package/dist/components/Loading/index.d.ts +4 -0
- package/dist/components/Loading/types.d.ts +28 -0
- package/dist/components/Skeleton/SkeletonBackground.d.ts +11 -0
- package/dist/components/Skeleton/SkeletonWrapper.d.ts +37 -0
- package/dist/components/Skeleton/index.d.ts +4 -0
- package/dist/components/Skeleton/types.d.ts +19 -0
- package/dist/components/Touchable/index.d.ts +4 -0
- package/dist/components/Touchable/types.d.ts +21 -0
- package/dist/components/Vimeo/Player.d.ts +26 -0
- package/dist/components/Vimeo/constants.d.ts +17 -0
- package/dist/components/Vimeo/index.d.ts +5 -0
- package/dist/components/Vimeo/types.d.ts +115 -0
- package/dist/components/Vimeo/utils.d.ts +17 -0
- package/dist/components/index.d.ts +11 -0
- package/dist/index.cjs +181 -25
- package/dist/index.js +4508 -3368
- package/dist/theme/components/art.d.ts +5 -0
- package/dist/theme/components/base.d.ts +8 -0
- package/dist/theme/components/button.d.ts +12 -0
- package/dist/theme/components/divider.d.ts +6 -0
- package/dist/theme/components/header.d.ts +7 -0
- package/dist/theme/components/index.d.ts +37 -0
- package/dist/theme/components/input.d.ts +14 -0
- package/dist/theme/components/list.d.ts +6 -0
- package/dist/theme/components/loading.d.ts +16 -0
- package/dist/theme/components/skeleton.d.ts +22 -0
- package/dist/theme/components/touchable.d.ts +14 -0
- package/dist/theme/components/vimeo.d.ts +15 -0
- package/dist/theme/getTheme.d.ts +10 -21
- package/dist/theme/index.d.ts +2 -0
- package/package.json +2 -2
- package/dist/components/Example.d.ts +0 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { BrandArt as Brand } from './BrandArt';
|
|
3
|
+
import { EmojiArt as Emoji } from './EmojiArt';
|
|
4
|
+
import { IconArt as Icon } from './IconArt';
|
|
5
|
+
import { ImageArt as Image } from './ImageArt';
|
|
6
|
+
import { SvgArt as Svg } from './SvgArt';
|
|
7
|
+
import { ArtProps } from './types';
|
|
8
|
+
export declare const Art: (props: ArtProps) => React.ReactElement;
|
|
9
|
+
export * from './types';
|
|
10
|
+
export * from './utils';
|
|
11
|
+
export { Image, Svg, Emoji, Icon, Brand };
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { BoxProps } from '../Box';
|
|
3
|
+
export interface BaseArtProps extends BoxProps {
|
|
4
|
+
/**
|
|
5
|
+
* Width of the art
|
|
6
|
+
*/
|
|
7
|
+
width?: string | number;
|
|
8
|
+
/**
|
|
9
|
+
* Height of the art
|
|
10
|
+
*/
|
|
11
|
+
height?: string | number;
|
|
12
|
+
/**
|
|
13
|
+
* Testing id of the component
|
|
14
|
+
*/
|
|
15
|
+
'data-testid'?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Additional styles
|
|
18
|
+
*/
|
|
19
|
+
style?: React.CSSProperties;
|
|
20
|
+
}
|
|
21
|
+
export interface IconArtProps extends BaseArtProps {
|
|
22
|
+
/**
|
|
23
|
+
* Type of the art
|
|
24
|
+
*/
|
|
25
|
+
type?: 'icon';
|
|
26
|
+
/**
|
|
27
|
+
* Icon name
|
|
28
|
+
*/
|
|
29
|
+
art: string;
|
|
30
|
+
/**
|
|
31
|
+
* Color of the icon
|
|
32
|
+
*/
|
|
33
|
+
color?: string;
|
|
34
|
+
}
|
|
35
|
+
export interface EmojiArtProps extends BaseArtProps {
|
|
36
|
+
/**
|
|
37
|
+
* Type of the art
|
|
38
|
+
*/
|
|
39
|
+
type?: 'emoji';
|
|
40
|
+
/**
|
|
41
|
+
* Emoji character
|
|
42
|
+
*/
|
|
43
|
+
art: string;
|
|
44
|
+
}
|
|
45
|
+
export interface SvgArtProps extends BaseArtProps {
|
|
46
|
+
/**
|
|
47
|
+
* Type of the art
|
|
48
|
+
*/
|
|
49
|
+
type?: 'svg';
|
|
50
|
+
/**
|
|
51
|
+
* SVG content
|
|
52
|
+
*/
|
|
53
|
+
art: string;
|
|
54
|
+
}
|
|
55
|
+
export interface ImageArtProps extends BaseArtProps {
|
|
56
|
+
/**
|
|
57
|
+
* Type of the art
|
|
58
|
+
*/
|
|
59
|
+
type?: 'image';
|
|
60
|
+
/**
|
|
61
|
+
* Image URL
|
|
62
|
+
*/
|
|
63
|
+
art: string;
|
|
64
|
+
}
|
|
65
|
+
export interface BrandArtProps extends BaseArtProps {
|
|
66
|
+
/**
|
|
67
|
+
* Type of the art
|
|
68
|
+
*/
|
|
69
|
+
type: 'brand';
|
|
70
|
+
/**
|
|
71
|
+
* Brand name
|
|
72
|
+
*/
|
|
73
|
+
art: string;
|
|
74
|
+
}
|
|
75
|
+
export type ArtProps = IconArtProps | EmojiArtProps | SvgArtProps | ImageArtProps | BrandArtProps;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Check if an art is an emoji
|
|
3
|
+
*/
|
|
4
|
+
export declare const isEmoji: (art: string) => boolean;
|
|
5
|
+
/**
|
|
6
|
+
* Check if an art is an icon
|
|
7
|
+
*/
|
|
8
|
+
export declare const isIcon: (art: string) => boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Check if an art is an image
|
|
11
|
+
*/
|
|
12
|
+
export declare const isImage: (art: string) => boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Check if an art is an SVG
|
|
15
|
+
*/
|
|
16
|
+
export declare const isSvg: (art: string) => boolean;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Color } from '../../theme';
|
|
2
|
+
import { BoxProps } from '../Box';
|
|
3
|
+
import { HeaderProps } from '../Header/types';
|
|
4
|
+
export interface BaseProps extends BoxProps {
|
|
5
|
+
/**
|
|
6
|
+
* The background color of the Base component
|
|
7
|
+
*/
|
|
8
|
+
backgroundColor?: Color;
|
|
9
|
+
/**
|
|
10
|
+
* The params for the header
|
|
11
|
+
* Can be set to false to hide the header
|
|
12
|
+
* Can provide a HeaderProps object to customize the header
|
|
13
|
+
*/
|
|
14
|
+
header?: HeaderProps | false;
|
|
15
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Color } from '../../theme/common';
|
|
2
|
+
type ButtonContainerProps = {
|
|
3
|
+
backgroundColor: Color | 'disabled';
|
|
4
|
+
borderRadius: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
};
|
|
7
|
+
declare const StyledButtonContainer: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('..').BoxProps & {
|
|
8
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
9
|
+
}, ButtonContainerProps>> & string & Omit<(props: import('..').BoxProps & {
|
|
10
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
11
|
+
}) => ReturnType<({ children, style, "data-testid": testId, ...otherProps }: import('..').BoxProps, ref: import('react').ForwardedRef<HTMLDivElement>) => import("react/jsx-runtime").JSX.Element>, keyof import('react').Component<any, {}, any>>;
|
|
12
|
+
type ButtonTextProps = {
|
|
13
|
+
themeColor: Color | 'disabled';
|
|
14
|
+
themeTextColor?: Color;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
};
|
|
17
|
+
declare const StyledButtonText: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('..').TextProps & {
|
|
18
|
+
useRichText?: boolean;
|
|
19
|
+
}, ButtonTextProps>> & string & Omit<(props: import('..').TextProps & {
|
|
20
|
+
useRichText?: boolean;
|
|
21
|
+
}) => import("react/jsx-runtime").JSX.Element, keyof import('react').Component<any, {}, any>>;
|
|
22
|
+
type ButtonIconWrapperProps = {
|
|
23
|
+
themePosition: 'left' | 'right';
|
|
24
|
+
};
|
|
25
|
+
declare const StyledButtonIconWrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('..').BoxProps & {
|
|
26
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
27
|
+
}, ButtonIconWrapperProps>> & string & Omit<(props: import('..').BoxProps & {
|
|
28
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
29
|
+
}) => ReturnType<({ children, style, "data-testid": testId, ...otherProps }: import('..').BoxProps, ref: import('react').ForwardedRef<HTMLDivElement>) => import("react/jsx-runtime").JSX.Element>, keyof import('react').Component<any, {}, any>>;
|
|
30
|
+
export { StyledButtonContainer, StyledButtonText, StyledButtonIconWrapper, };
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Color } from '../../theme/common';
|
|
3
|
+
export interface ButtonProps {
|
|
4
|
+
/**
|
|
5
|
+
* Disable state of button.
|
|
6
|
+
*/
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
/**
|
|
9
|
+
* Places an icon within the button, before the button's text
|
|
10
|
+
*/
|
|
11
|
+
icon?: React.ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* Visual color to apply to button.
|
|
14
|
+
*/
|
|
15
|
+
color?: Color;
|
|
16
|
+
/**
|
|
17
|
+
* Visual color to apply to button's text.
|
|
18
|
+
*/
|
|
19
|
+
textColor?: Color;
|
|
20
|
+
/**
|
|
21
|
+
* Loading state of button.
|
|
22
|
+
*/
|
|
23
|
+
loading?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Set the handler to handle click event.
|
|
26
|
+
*/
|
|
27
|
+
onClick?: React.MouseEventHandler<HTMLDivElement>;
|
|
28
|
+
/**
|
|
29
|
+
* Places an icon within the button, after the button's text
|
|
30
|
+
*/
|
|
31
|
+
rightIcon?: React.ReactNode;
|
|
32
|
+
/**
|
|
33
|
+
* Corner style of button.
|
|
34
|
+
*/
|
|
35
|
+
corner?: 'circle' | 'rounded' | 'square';
|
|
36
|
+
/**
|
|
37
|
+
* Additional style.
|
|
38
|
+
*/
|
|
39
|
+
style?: React.CSSProperties;
|
|
40
|
+
/**
|
|
41
|
+
* Testing id of the component.
|
|
42
|
+
*/
|
|
43
|
+
'data-testid'?: string;
|
|
44
|
+
/**
|
|
45
|
+
* Button text.
|
|
46
|
+
*/
|
|
47
|
+
text: React.ReactNode;
|
|
48
|
+
/**
|
|
49
|
+
* For flex layout
|
|
50
|
+
*/
|
|
51
|
+
flex?: number | string;
|
|
52
|
+
}
|
|
53
|
+
export declare const Button: ({ disabled, icon, color, textColor, loading, onClick, rightIcon, corner, style, "data-testid": testId, text, ...rest }: ButtonProps) => React.ReactElement;
|
|
54
|
+
export * from './utils';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Color } from '../../theme/common';
|
|
2
|
+
interface StyledDividerProps {
|
|
3
|
+
$orientation: 'horizontal' | 'vertical';
|
|
4
|
+
$color: Color;
|
|
5
|
+
$thickness: number;
|
|
6
|
+
}
|
|
7
|
+
export declare const StyledDivider: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('..').BoxProps & {
|
|
8
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
9
|
+
}, StyledDividerProps>> & string & Omit<(props: import('..').BoxProps & {
|
|
10
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
11
|
+
}) => ReturnType<({ children, style, "data-testid": testId, ...otherProps }: import('..').BoxProps, ref: import('react').ForwardedRef<HTMLDivElement>) => import("react/jsx-runtime").JSX.Element>, keyof import('react').Component<any, {}, any>>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Color } from '../../theme/common';
|
|
3
|
+
import { BoxProps } from '../Box';
|
|
4
|
+
export interface DividerProps extends BoxProps {
|
|
5
|
+
/**
|
|
6
|
+
* The orientation of the divider.
|
|
7
|
+
* @default 'horizontal'
|
|
8
|
+
*/
|
|
9
|
+
orientation?: 'horizontal' | 'vertical';
|
|
10
|
+
/**
|
|
11
|
+
* The color of the divider.
|
|
12
|
+
* @default 'grey300'
|
|
13
|
+
*/
|
|
14
|
+
color?: Color;
|
|
15
|
+
/**
|
|
16
|
+
* The thickness of the divider in pixels.
|
|
17
|
+
* @default 1
|
|
18
|
+
*/
|
|
19
|
+
thickness?: number;
|
|
20
|
+
}
|
|
21
|
+
export declare const Divider: React.FC<DividerProps>;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { Color } from '../../theme';
|
|
2
|
+
import { BoxProps } from '../Box';
|
|
3
|
+
export interface NavItem {
|
|
4
|
+
/**
|
|
5
|
+
* Label for the navigation item
|
|
6
|
+
*/
|
|
7
|
+
label: string;
|
|
8
|
+
/**
|
|
9
|
+
* URL or path for the navigation item
|
|
10
|
+
*/
|
|
11
|
+
path: string;
|
|
12
|
+
/**
|
|
13
|
+
* Whether this navigation item is currently active
|
|
14
|
+
*/
|
|
15
|
+
isActive?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export interface HeaderProps extends BoxProps {
|
|
18
|
+
/**
|
|
19
|
+
* Background color of the header
|
|
20
|
+
*/
|
|
21
|
+
backgroundColor?: Color;
|
|
22
|
+
/**
|
|
23
|
+
* Navigation items to display in the center of the header
|
|
24
|
+
*/
|
|
25
|
+
navItems?: NavItem[];
|
|
26
|
+
/**
|
|
27
|
+
* Whether to show the user is signed in
|
|
28
|
+
*/
|
|
29
|
+
isSignedIn?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* User profile information, shown when signed in
|
|
32
|
+
*/
|
|
33
|
+
userProfile?: {
|
|
34
|
+
name?: string;
|
|
35
|
+
avatar?: string;
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* Called when the logo is clicked
|
|
39
|
+
*/
|
|
40
|
+
onLogoClick?: () => void;
|
|
41
|
+
/**
|
|
42
|
+
* Called when a navigation item is clicked
|
|
43
|
+
*/
|
|
44
|
+
onNavItemClick?: (item: NavItem) => void;
|
|
45
|
+
/**
|
|
46
|
+
* Called when the sign in button is clicked
|
|
47
|
+
*/
|
|
48
|
+
onSignInClick?: () => void;
|
|
49
|
+
/**
|
|
50
|
+
* Called when the register button is clicked
|
|
51
|
+
*/
|
|
52
|
+
onRegisterClick?: () => void;
|
|
53
|
+
/**
|
|
54
|
+
* Called when the profile button is clicked
|
|
55
|
+
*/
|
|
56
|
+
onProfileClick?: () => void;
|
|
57
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Color } from '../../theme/common';
|
|
2
|
+
interface StyledInputContainerProps {
|
|
3
|
+
$isFocused: boolean;
|
|
4
|
+
$isDisabled: boolean;
|
|
5
|
+
$error: boolean;
|
|
6
|
+
$borderColor?: Color;
|
|
7
|
+
$bgColor?: Color;
|
|
8
|
+
}
|
|
9
|
+
export declare const StyledInputContainer: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, StyledInputContainerProps>> & string;
|
|
10
|
+
export declare const StyledInput: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, never>> & string;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Color } from '../../theme/common';
|
|
3
|
+
export interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'onChange'> {
|
|
4
|
+
/**
|
|
5
|
+
* The value of the input field
|
|
6
|
+
*/
|
|
7
|
+
value?: string;
|
|
8
|
+
/**
|
|
9
|
+
* Callback when the input value changes
|
|
10
|
+
*/
|
|
11
|
+
onChange?: (text: string) => void;
|
|
12
|
+
/**
|
|
13
|
+
* The placeholder text
|
|
14
|
+
*/
|
|
15
|
+
placeholder?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Whether the input is disabled
|
|
18
|
+
*/
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* Error message to display
|
|
22
|
+
*/
|
|
23
|
+
error?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Label text to display above the input
|
|
26
|
+
*/
|
|
27
|
+
label?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Helper text to display below the input
|
|
30
|
+
*/
|
|
31
|
+
helperText?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Icon to display on the left side of the input
|
|
34
|
+
*/
|
|
35
|
+
leftIcon?: React.ReactNode;
|
|
36
|
+
/**
|
|
37
|
+
* Icon to display on the right side of the input
|
|
38
|
+
*/
|
|
39
|
+
rightIcon?: React.ReactNode;
|
|
40
|
+
/**
|
|
41
|
+
* Border color when focused
|
|
42
|
+
*/
|
|
43
|
+
borderColor?: Color;
|
|
44
|
+
/**
|
|
45
|
+
* Background color
|
|
46
|
+
*/
|
|
47
|
+
bgColor?: Color;
|
|
48
|
+
}
|
|
49
|
+
export interface InputRef {
|
|
50
|
+
focus: () => void;
|
|
51
|
+
blur: () => void;
|
|
52
|
+
value: string;
|
|
53
|
+
}
|
|
54
|
+
export declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<InputRef>>;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Space } from '../../theme/common';
|
|
3
|
+
import { BoxProps } from '../Box';
|
|
4
|
+
export interface ListProps<T = any> extends BoxProps {
|
|
5
|
+
/**
|
|
6
|
+
* The data array to be rendered
|
|
7
|
+
*/
|
|
8
|
+
data?: T[];
|
|
9
|
+
/**
|
|
10
|
+
* Function to render an item from the data array
|
|
11
|
+
*/
|
|
12
|
+
renderItem?: (item: T, index: number) => React.ReactNode;
|
|
13
|
+
/**
|
|
14
|
+
* Optional key extractor function
|
|
15
|
+
*/
|
|
16
|
+
keyExtractor?: (item: T, index: number) => string;
|
|
17
|
+
/**
|
|
18
|
+
* Component to render when the list is empty
|
|
19
|
+
*/
|
|
20
|
+
ListEmptyComponent?: React.ReactNode;
|
|
21
|
+
/**
|
|
22
|
+
* Component to render at the top of the list
|
|
23
|
+
*/
|
|
24
|
+
ListHeaderComponent?: React.ReactNode;
|
|
25
|
+
/**
|
|
26
|
+
* Component to render at the bottom of the list
|
|
27
|
+
*/
|
|
28
|
+
ListFooterComponent?: React.ReactNode;
|
|
29
|
+
/**
|
|
30
|
+
* Component to render between each item
|
|
31
|
+
*/
|
|
32
|
+
ItemSeparatorComponent?: React.ReactNode;
|
|
33
|
+
/**
|
|
34
|
+
* Gap between items (overrides the theme gap)
|
|
35
|
+
*/
|
|
36
|
+
itemGap?: Space;
|
|
37
|
+
/**
|
|
38
|
+
* Additional props
|
|
39
|
+
*/
|
|
40
|
+
[key: string]: any;
|
|
41
|
+
}
|
|
42
|
+
declare function InternalList<T>({ data, renderItem, keyExtractor, ListEmptyComponent, ListHeaderComponent, ListFooterComponent, ItemSeparatorComponent, itemGap, ...rest }: ListProps<T>, ref: React.Ref<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
43
|
+
export declare const List: <T>(props: ListProps<T> & {
|
|
44
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
45
|
+
}) => ReturnType<typeof InternalList>;
|
|
46
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const StyledLoadingContainer: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('..').BoxProps & {
|
|
2
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
3
|
+
}, never>> & string & Omit<(props: import('..').BoxProps & {
|
|
4
|
+
ref?: import('react').ForwardedRef<HTMLDivElement>;
|
|
5
|
+
}) => ReturnType<({ children, style, "data-testid": testId, ...otherProps }: import('..').BoxProps, ref: import('react').ForwardedRef<HTMLDivElement>) => import("react/jsx-runtime").JSX.Element>, keyof import('react').Component<any, {}, any>>;
|
|
6
|
+
export declare const StyledSpinner: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
|
|
7
|
+
size: string;
|
|
8
|
+
color: string;
|
|
9
|
+
strokeWidth: string;
|
|
10
|
+
}>> & string;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Color } from '../../theme';
|
|
3
|
+
import { LoadingSize } from '../../theme/components/loading';
|
|
4
|
+
import { BoxProps } from '../Box';
|
|
5
|
+
export interface LoadingProps extends BoxProps {
|
|
6
|
+
/**
|
|
7
|
+
* Size of the loading indicator
|
|
8
|
+
*/
|
|
9
|
+
size: LoadingSize | string;
|
|
10
|
+
/**
|
|
11
|
+
* Loading state of the loading indicator
|
|
12
|
+
* @default true
|
|
13
|
+
*/
|
|
14
|
+
loading?: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Color of the loading indicator
|
|
17
|
+
* @default 'primary'
|
|
18
|
+
*/
|
|
19
|
+
color?: Color;
|
|
20
|
+
/**
|
|
21
|
+
* Children of the loading indicator (will be shown when loading is false)
|
|
22
|
+
*/
|
|
23
|
+
children?: React.ReactNode;
|
|
24
|
+
/**
|
|
25
|
+
* Test ID for testing
|
|
26
|
+
*/
|
|
27
|
+
'data-testid'?: string;
|
|
28
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface SkeletonBackgroundProps {
|
|
3
|
+
$variant: 'circle' | 'rectangle' | 'rounded';
|
|
4
|
+
$duration: number;
|
|
5
|
+
}
|
|
6
|
+
export declare const SkeletonBackgroundContainer: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, SkeletonBackgroundProps>> & string;
|
|
7
|
+
export declare const SkeletonBackground: React.FC<{
|
|
8
|
+
variant: 'circle' | 'rectangle' | 'rounded';
|
|
9
|
+
duration?: number;
|
|
10
|
+
}>;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface SkeletonWrapperProps {
|
|
3
|
+
/**
|
|
4
|
+
* Whether the skeleton is visible
|
|
5
|
+
*/
|
|
6
|
+
visible: boolean;
|
|
7
|
+
/**
|
|
8
|
+
* Style of the skeleton
|
|
9
|
+
*/
|
|
10
|
+
variant: 'circle' | 'rectangle' | 'rounded';
|
|
11
|
+
/**
|
|
12
|
+
* Duration of the animation in ms
|
|
13
|
+
*/
|
|
14
|
+
animationDuration?: number;
|
|
15
|
+
/**
|
|
16
|
+
* Children to render when not in skeleton state
|
|
17
|
+
*/
|
|
18
|
+
children?: React.ReactNode;
|
|
19
|
+
/**
|
|
20
|
+
* Style of the wrapper
|
|
21
|
+
*/
|
|
22
|
+
style?: React.CSSProperties;
|
|
23
|
+
/**
|
|
24
|
+
* Class name for the wrapper
|
|
25
|
+
*/
|
|
26
|
+
className?: string;
|
|
27
|
+
/**
|
|
28
|
+
* Width of the skeleton
|
|
29
|
+
*/
|
|
30
|
+
width?: string | number;
|
|
31
|
+
/**
|
|
32
|
+
* Height of the skeleton
|
|
33
|
+
*/
|
|
34
|
+
height?: string | number;
|
|
35
|
+
}
|
|
36
|
+
export declare const SkeletonWrapper: React.FC<SkeletonWrapperProps>;
|
|
37
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { BoxProps } from '../Box';
|
|
2
|
+
export interface SkeletonProps extends BoxProps {
|
|
3
|
+
/**
|
|
4
|
+
* Whether the skeleton is visible
|
|
5
|
+
*/
|
|
6
|
+
visible?: boolean;
|
|
7
|
+
/**
|
|
8
|
+
* Style of the skeleton
|
|
9
|
+
*/
|
|
10
|
+
variant?: 'circle' | 'rectangle' | 'rounded';
|
|
11
|
+
/**
|
|
12
|
+
* Children to render when not in skeleton state
|
|
13
|
+
*/
|
|
14
|
+
children?: React.ReactNode;
|
|
15
|
+
/**
|
|
16
|
+
* Duration of the animation in ms
|
|
17
|
+
*/
|
|
18
|
+
animationDuration?: number;
|
|
19
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { TouchableHapticFeedbackType } from '../../theme';
|
|
3
|
+
import { BoxProps } from '../Box';
|
|
4
|
+
export interface TouchableProps extends React.HTMLAttributes<HTMLDivElement>, BoxProps {
|
|
5
|
+
/**
|
|
6
|
+
* Haptic feedback type (not used in web, but kept for API compatibility)
|
|
7
|
+
*/
|
|
8
|
+
hapticFeedback?: TouchableHapticFeedbackType;
|
|
9
|
+
/**
|
|
10
|
+
* Touchable's content.
|
|
11
|
+
*/
|
|
12
|
+
children?: React.ReactNode;
|
|
13
|
+
/**
|
|
14
|
+
* Additional styles.
|
|
15
|
+
*/
|
|
16
|
+
style?: React.CSSProperties;
|
|
17
|
+
/**
|
|
18
|
+
* Testing id of the component.
|
|
19
|
+
*/
|
|
20
|
+
'data-testid'?: string;
|
|
21
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { VimeoCallbacks, VimeoConfig } from './types';
|
|
3
|
+
interface PlayerProps {
|
|
4
|
+
/**
|
|
5
|
+
* The ID of the Vimeo video to play
|
|
6
|
+
*/
|
|
7
|
+
videoId: string;
|
|
8
|
+
/**
|
|
9
|
+
* Width of the player
|
|
10
|
+
*/
|
|
11
|
+
width?: string | number;
|
|
12
|
+
/**
|
|
13
|
+
* Height of the player
|
|
14
|
+
*/
|
|
15
|
+
height?: string | number;
|
|
16
|
+
/**
|
|
17
|
+
* Configuration options for the Vimeo player
|
|
18
|
+
*/
|
|
19
|
+
config?: VimeoConfig;
|
|
20
|
+
/**
|
|
21
|
+
* Callbacks for Vimeo player events
|
|
22
|
+
*/
|
|
23
|
+
callbacks?: VimeoCallbacks;
|
|
24
|
+
}
|
|
25
|
+
export declare const Player: React.FC<PlayerProps>;
|
|
26
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare const DEFAULT_VIMEO_CONFIG: {
|
|
2
|
+
color: string;
|
|
3
|
+
autoplay: boolean;
|
|
4
|
+
muted: boolean;
|
|
5
|
+
loop: boolean;
|
|
6
|
+
title: boolean;
|
|
7
|
+
byline: boolean;
|
|
8
|
+
portrait: boolean;
|
|
9
|
+
dnt: boolean;
|
|
10
|
+
playsinline: boolean;
|
|
11
|
+
background: boolean;
|
|
12
|
+
controls: boolean;
|
|
13
|
+
pip: boolean;
|
|
14
|
+
responsive: boolean;
|
|
15
|
+
width: string;
|
|
16
|
+
};
|
|
17
|
+
export declare const VIMEO_HOST = "https://player.vimeo.com";
|