@hero-design/rn 8.102.0 → 8.103.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/.turbo/turbo-build.log +3 -3
- package/CHANGELOG.md +12 -0
- package/es/index.js +5 -2
- package/lib/index.js +5 -2
- package/package.json +1 -1
- package/src/components/FAB/AnimatedFABIcon.tsx +3 -1
- package/src/components/Select/BaseOptionList.tsx +3 -3
- package/src/components/Select/MultiSelect/OptionList.tsx +3 -3
- package/src/components/Select/MultiSelect/index.tsx +6 -4
- package/src/components/Select/MultiSelect/utils.ts +2 -2
- package/src/components/Select/SingleSelect/OptionList.tsx +3 -3
- package/src/components/Select/SingleSelect/index.tsx +6 -4
- package/src/components/Select/helpers.tsx +11 -7
- package/src/components/Select/types.ts +6 -6
- package/src/components/Switch/SelectorSwitch/Option.tsx +2 -2
- package/src/components/Switch/SelectorSwitch/index.tsx +2 -2
- package/src/components/TextInput/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
- package/src/components/TextInput/__tests__/index.spec.tsx +18 -7
- package/src/components/TextInput/index.tsx +3 -1
- package/src/types.ts +48 -2
- package/stats/8.103.0/rn-stats.html +4842 -0
- package/types/components/Alert/StyledAlert.d.ts +1 -1
- package/types/components/Avatar/StyledAvatar.d.ts +1 -1
- package/types/components/Badge/StyledBadge.d.ts +1 -1
- package/types/components/BottomNavigation/StyledBottomNavigation.d.ts +1 -1
- package/types/components/Button/StyledButton.d.ts +4 -4
- package/types/components/Button/UtilityButton/StyledUtilityButton.d.ts +1 -1
- package/types/components/Carousel/StyledCarousel.d.ts +1 -1
- package/types/components/Checkbox/StyledCheckbox.d.ts +1 -1
- package/types/components/FAB/ActionGroup/StyledActionItem.d.ts +1 -1
- package/types/components/FAB/StyledFAB.d.ts +1 -1
- package/types/components/PinInput/StyledPinInput.d.ts +2 -2
- package/types/components/Radio/StyledRadio.d.ts +1 -1
- package/types/components/Select/BaseOptionList.d.ts +3 -3
- package/types/components/Select/MultiSelect/OptionList.d.ts +3 -3
- package/types/components/Select/MultiSelect/index.d.ts +3 -3
- package/types/components/Select/MultiSelect/utils.d.ts +2 -2
- package/types/components/Select/SingleSelect/OptionList.d.ts +3 -3
- package/types/components/Select/SingleSelect/index.d.ts +3 -3
- package/types/components/Select/helpers.d.ts +6 -6
- package/types/components/Select/index.d.ts +1 -1
- package/types/components/Select/types.d.ts +6 -6
- package/types/components/StatusScreens/Empty/StyledEmpty.d.ts +2 -2
- package/types/components/StatusScreens/Error/StyledError.d.ts +2 -2
- package/types/components/StatusScreens/Success/StyledSuccess.d.ts +2 -2
- package/types/components/Switch/SelectorSwitch/Option.d.ts +2 -2
- package/types/components/Switch/SelectorSwitch/index.d.ts +2 -2
- package/types/components/Tag/StyledTag.d.ts +1 -1
- package/types/components/TextInput/StyledTextInput.d.ts +4 -4
- package/types/components/Toast/StyledToast.d.ts +1 -1
- package/types/types.d.ts +22 -3
|
@@ -30,7 +30,7 @@ declare const TextContainer: import("@emotion/native").StyledComponent<ViewProps
|
|
|
30
30
|
}, {}, {
|
|
31
31
|
ref?: import("react").Ref<View> | undefined;
|
|
32
32
|
}>;
|
|
33
|
-
declare const StyledBody: import("@emotion/native").StyledComponent<import("
|
|
33
|
+
declare const StyledBody: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
34
34
|
theme?: import("@emotion/react").Theme;
|
|
35
35
|
as?: React.ElementType;
|
|
36
36
|
} & TextProps & {
|
|
@@ -15,7 +15,7 @@ declare const StyledTextWrapper: import("@emotion/native").StyledComponent<impor
|
|
|
15
15
|
}, {}, {
|
|
16
16
|
ref?: import("react").Ref<View> | undefined;
|
|
17
17
|
}>;
|
|
18
|
-
declare const StyledText: import("@emotion/native").StyledComponent<import("
|
|
18
|
+
declare const StyledText: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
19
19
|
theme?: import("@emotion/react").Theme;
|
|
20
20
|
as?: React.ElementType;
|
|
21
21
|
} & TextProps & {
|
|
@@ -12,7 +12,7 @@ declare const StyledView: import("@emotion/native").StyledComponent<Animated.Ani
|
|
|
12
12
|
themeSize: ThemeSize;
|
|
13
13
|
themeVariant: ThemeVariant;
|
|
14
14
|
}, {}, {}>;
|
|
15
|
-
declare const StyledText: import("@emotion/native").StyledComponent<import("
|
|
15
|
+
declare const StyledText: import("@emotion/native").StyledComponent<import("../..").CaptionProps & {
|
|
16
16
|
theme?: import("@emotion/react").Theme;
|
|
17
17
|
as?: React.ElementType;
|
|
18
18
|
} & {
|
|
@@ -44,7 +44,7 @@ declare const BottomBarItem: import("@emotion/native").StyledComponent<import("r
|
|
|
44
44
|
}, {}, {
|
|
45
45
|
ref?: import("react").Ref<View> | undefined;
|
|
46
46
|
}>;
|
|
47
|
-
declare const StyledBottomBarText: import("@emotion/native").StyledComponent<import("
|
|
47
|
+
declare const StyledBottomBarText: import("@emotion/native").StyledComponent<import("../..").CaptionProps & {
|
|
48
48
|
theme?: import("@emotion/react").Theme;
|
|
49
49
|
as?: React.ElementType;
|
|
50
50
|
}, {}, {}>;
|
|
@@ -12,21 +12,21 @@ declare const StyledButtonContainer: import("@emotion/native").StyledComponent<i
|
|
|
12
12
|
themeInlineText?: boolean;
|
|
13
13
|
themeIsCompact?: boolean;
|
|
14
14
|
}, {}, {}>;
|
|
15
|
-
declare const StyledButtonText: import("@emotion/native").StyledComponent<import("
|
|
15
|
+
declare const StyledButtonText: import("@emotion/native").StyledComponent<import("../..").TitleProps & {
|
|
16
16
|
theme?: Theme;
|
|
17
17
|
as?: React.ElementType;
|
|
18
18
|
} & {
|
|
19
19
|
disabled?: boolean;
|
|
20
20
|
themeButtonVariant: ThemeVariant;
|
|
21
21
|
}, {}, {}>;
|
|
22
|
-
declare const StyledSmallButtonText: import("@emotion/native").StyledComponent<import("
|
|
22
|
+
declare const StyledSmallButtonText: import("@emotion/native").StyledComponent<import("../..").TitleProps & {
|
|
23
23
|
theme?: Theme;
|
|
24
24
|
as?: React.ElementType;
|
|
25
25
|
} & {
|
|
26
26
|
disabled?: boolean;
|
|
27
27
|
themeButtonVariant: ThemeVariant;
|
|
28
|
-
} & import("
|
|
29
|
-
declare const StyledButtonTitleOfVariantText: import("@emotion/native").StyledComponent<import("
|
|
28
|
+
} & import("../..").BodyProps, {}, {}>;
|
|
29
|
+
declare const StyledButtonTitleOfVariantText: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
30
30
|
theme?: Theme;
|
|
31
31
|
as?: React.ElementType;
|
|
32
32
|
} & {
|
|
@@ -9,7 +9,7 @@ export declare const IconWrapper: import("@emotion/native").StyledComponent<impo
|
|
|
9
9
|
}, {}, {
|
|
10
10
|
ref?: import("react").Ref<View> | undefined;
|
|
11
11
|
}>;
|
|
12
|
-
export declare const ButtonText: import("@emotion/native").StyledComponent<import("
|
|
12
|
+
export declare const ButtonText: import("@emotion/native").StyledComponent<import("../../..").BodyProps & {
|
|
13
13
|
theme?: import("@emotion/react").Theme;
|
|
14
14
|
as?: React.ElementType;
|
|
15
15
|
}, {}, {}>;
|
|
@@ -13,7 +13,7 @@ declare const StyledCarouselView: import("@emotion/native").StyledComponent<impo
|
|
|
13
13
|
}, {}, {
|
|
14
14
|
ref?: import("react").Ref<View> | undefined;
|
|
15
15
|
}>;
|
|
16
|
-
declare const StyledCarouselHeading: import("@emotion/native").StyledComponent<import("
|
|
16
|
+
declare const StyledCarouselHeading: import("@emotion/native").StyledComponent<import("../..").TitleProps & {
|
|
17
17
|
theme?: import("@emotion/react").Theme;
|
|
18
18
|
as?: React.ElementType;
|
|
19
19
|
}, {}, {}>;
|
|
@@ -6,7 +6,7 @@ export declare const StyledWrapper: import("@emotion/native").StyledComponent<im
|
|
|
6
6
|
} & {
|
|
7
7
|
themeState: CheckboxThemeState;
|
|
8
8
|
}, {}, {}>;
|
|
9
|
-
export declare const StyledDescription: import("@emotion/native").StyledComponent<import("
|
|
9
|
+
export declare const StyledDescription: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
10
10
|
theme?: import("@emotion/react").Theme;
|
|
11
11
|
as?: React.ElementType;
|
|
12
12
|
}, {}, {}>;
|
|
@@ -4,7 +4,7 @@ declare const StyledActionItem: import("@emotion/native").StyledComponent<Toucha
|
|
|
4
4
|
theme?: import("@emotion/react").Theme;
|
|
5
5
|
as?: React.ElementType;
|
|
6
6
|
}, {}, {}>;
|
|
7
|
-
declare const StyledActionItemText: import("@emotion/native").StyledComponent<import("
|
|
7
|
+
declare const StyledActionItemText: import("@emotion/native").StyledComponent<import("../../..").BodyProps & {
|
|
8
8
|
theme?: import("@emotion/react").Theme;
|
|
9
9
|
as?: React.ElementType;
|
|
10
10
|
} & TouchableOpacityProps, {}, {}>;
|
|
@@ -10,7 +10,7 @@ declare const StyledFABIcon: import("@emotion/native").StyledComponent<IconProps
|
|
|
10
10
|
theme?: import("@emotion/react").Theme;
|
|
11
11
|
as?: React.ElementType;
|
|
12
12
|
}, {}, {}>;
|
|
13
|
-
declare const StyledFABText: import("@emotion/native").StyledComponent<import("
|
|
13
|
+
declare const StyledFABText: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
14
14
|
theme?: import("@emotion/react").Theme;
|
|
15
15
|
as?: React.ElementType;
|
|
16
16
|
} & TextProps, {}, {}>;
|
|
@@ -21,7 +21,7 @@ export declare const StyledCell: import("@emotion/native").StyledComponent<impor
|
|
|
21
21
|
}, {}, {
|
|
22
22
|
ref?: import("react").Ref<View> | undefined;
|
|
23
23
|
}>;
|
|
24
|
-
export declare const StyledCellText: import("@emotion/native").StyledComponent<import("
|
|
24
|
+
export declare const StyledCellText: import("@emotion/native").StyledComponent<import("../..").TitleProps & {
|
|
25
25
|
theme?: import("@emotion/react").Theme;
|
|
26
26
|
as?: React.ElementType;
|
|
27
27
|
} & {
|
|
@@ -63,7 +63,7 @@ export declare const StyledErrorContainer: import("@emotion/native").StyledCompo
|
|
|
63
63
|
}, {}, {
|
|
64
64
|
ref?: import("react").Ref<View> | undefined;
|
|
65
65
|
}>;
|
|
66
|
-
export declare const StyledErrorMessage: import("@emotion/native").StyledComponent<import("
|
|
66
|
+
export declare const StyledErrorMessage: import("@emotion/native").StyledComponent<import("../..").CaptionProps & {
|
|
67
67
|
theme?: import("@emotion/react").Theme;
|
|
68
68
|
as?: React.ElementType;
|
|
69
69
|
}, {}, {}>;
|
|
@@ -20,7 +20,7 @@ declare const Spacer: import("@emotion/native").StyledComponent<import("react-na
|
|
|
20
20
|
}, {}, {
|
|
21
21
|
ref?: import("react").Ref<View> | undefined;
|
|
22
22
|
}>;
|
|
23
|
-
declare const StyledRadio: import("@emotion/native").StyledComponent<import("
|
|
23
|
+
declare const StyledRadio: import("@emotion/native").StyledComponent<import("../..").ListItemProps & {
|
|
24
24
|
theme?: import("@emotion/react").Theme;
|
|
25
25
|
as?: React.ElementType;
|
|
26
26
|
} & {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { SectionList, SectionListProps } from 'react-native';
|
|
3
|
-
import type {
|
|
4
|
-
export type BaseOptionListProps<V, T extends
|
|
3
|
+
import type { SelectOptionType, SelectProps, SectionType } from './types';
|
|
4
|
+
export type BaseOptionListProps<V, T extends SelectOptionType<V>> = Pick<SelectProps<V, T>, 'keyExtractor' | 'loading' | 'onEndReached' | 'onQueryChange'> & {
|
|
5
5
|
sectionListRef?: React.RefObject<SectionList<T, SectionType>>;
|
|
6
6
|
} & SectionListProps<T, SectionType>;
|
|
7
|
-
declare const BaseOptionList: <V, T extends
|
|
7
|
+
declare const BaseOptionList: <V, T extends SelectOptionType<V>>({ keyExtractor, loading, onEndReached, onQueryChange, sections, renderItem, sectionListRef, ...rest }: BaseOptionListProps<V, T>) => React.JSX.Element;
|
|
8
8
|
export default BaseOptionList;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BaseOptionListProps } from '../BaseOptionList';
|
|
3
3
|
import type { MultiSelectProps } from '.';
|
|
4
|
-
import type {
|
|
5
|
-
type OptionListProps<V, T extends
|
|
4
|
+
import type { SelectOptionType } from '../types';
|
|
5
|
+
type OptionListProps<V, T extends SelectOptionType<V>> = Pick<MultiSelectProps<V, T>, 'keyExtractor' | 'loading' | 'onEndReached' | 'onQueryChange' | 'value' | 'renderOption'> & {
|
|
6
6
|
onPress: (value: V[]) => void;
|
|
7
7
|
} & BaseOptionListProps<V, T>;
|
|
8
|
-
declare const OptionList: <V, T extends
|
|
8
|
+
declare const OptionList: <V, T extends SelectOptionType<V>>({ keyExtractor, loading, onEndReached, onPress, onQueryChange, sections, renderOption, value, sectionListRef, ...rest }: OptionListProps<V, T>) => React.JSX.Element;
|
|
9
9
|
export default OptionList;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { TextInputProps as NativeTextInputProps } from 'react-native';
|
|
3
|
-
import type {
|
|
4
|
-
export interface MultiSelectProps<V, T extends
|
|
3
|
+
import type { SelectOptionType, SelectProps } from '../types';
|
|
4
|
+
export interface MultiSelectProps<V, T extends SelectOptionType<V> = SelectOptionType<V>> extends SelectProps<V, T> {
|
|
5
5
|
/**
|
|
6
6
|
* Current selected value.
|
|
7
7
|
*/
|
|
@@ -26,5 +26,5 @@ export interface MultiSelectProps<V, T extends OptionType<V> = OptionType<V>> ex
|
|
|
26
26
|
*/
|
|
27
27
|
supportedOrientations?: ('portrait' | 'landscape')[];
|
|
28
28
|
}
|
|
29
|
-
declare function MultiSelect<V, T extends
|
|
29
|
+
declare function MultiSelect<V, T extends SelectOptionType<V>>({ footerLabel, label, loading, inputProps, onConfirm, onDismiss, onEndReached, onQueryChange, options, renderOption, renderSelectedValue, query, error, editable, disabled, required, style, testID, value, supportedOrientations, bottomSheetConfig, }: MultiSelectProps<V, T>): React.JSX.Element;
|
|
30
30
|
export default MultiSelect;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const isOptionSelected: <V, T extends
|
|
1
|
+
import { SelectOptionType } from '../types';
|
|
2
|
+
export declare const isOptionSelected: <V, T extends SelectOptionType<V>>(value?: V[], option?: T) => boolean;
|
|
@@ -2,10 +2,10 @@ import React from 'react';
|
|
|
2
2
|
import { SectionList } from 'react-native';
|
|
3
3
|
import type { SingleSelectProps } from '.';
|
|
4
4
|
import { BaseOptionListProps } from '../BaseOptionList';
|
|
5
|
-
import type {
|
|
6
|
-
type OptionListProps<V, T extends
|
|
5
|
+
import type { SelectOptionType, SectionType } from '../types';
|
|
6
|
+
type OptionListProps<V, T extends SelectOptionType<V>> = Pick<SingleSelectProps<V, T>, 'keyExtractor' | 'loading' | 'onEndReached' | 'onQueryChange' | 'value' | 'renderOption'> & {
|
|
7
7
|
onPress: (value: V | null) => void;
|
|
8
8
|
sectionListRef?: React.RefObject<SectionList<T, SectionType>>;
|
|
9
9
|
} & BaseOptionListProps<V, T>;
|
|
10
|
-
declare const OptionList: <V, T extends
|
|
10
|
+
declare const OptionList: <V, T extends SelectOptionType<V>>({ keyExtractor, loading, onEndReached, onPress, onQueryChange, sections, renderOption, value, sectionListRef, ...rest }: OptionListProps<V, T>) => React.JSX.Element;
|
|
11
11
|
export default OptionList;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { TextInputProps as NativeTextInputProps } from 'react-native';
|
|
3
|
-
import type {
|
|
4
|
-
export interface SingleSelectProps<V, T extends
|
|
3
|
+
import type { SelectOptionType, SelectProps } from '../types';
|
|
4
|
+
export interface SingleSelectProps<V, T extends SelectOptionType<V> = SelectOptionType<V>> extends SelectProps<V, T> {
|
|
5
5
|
/**
|
|
6
6
|
* Current selected value.
|
|
7
7
|
*/
|
|
@@ -19,5 +19,5 @@ export interface SingleSelectProps<V, T extends OptionType<V> = OptionType<V>> e
|
|
|
19
19
|
*/
|
|
20
20
|
supportedOrientations?: ('portrait' | 'landscape')[];
|
|
21
21
|
}
|
|
22
|
-
declare const SingleSelect: <V, T extends
|
|
22
|
+
declare const SingleSelect: <V, T extends SelectOptionType<V>>({ label, loading, inputProps, onConfirm, onDismiss, onEndReached, onQueryChange, options, renderOption, renderSelectedValue, query, error, editable, disabled, required, style, testID, value, supportedOrientations, bottomSheetConfig, }: SingleSelectProps<V, T>) => React.JSX.Element;
|
|
23
23
|
export default SingleSelect;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type { SectionData, CombinedOptionsType,
|
|
2
|
-
export declare const getKey: <V, T extends
|
|
3
|
-
export declare const isSections: <V, T extends
|
|
4
|
-
export declare const toSections: <V, T extends
|
|
5
|
-
export declare const toFlatOptions: <V, T extends
|
|
1
|
+
import type { SectionData, CombinedOptionsType, SelectOptionType } from './types';
|
|
2
|
+
export declare const getKey: <V, T extends SelectOptionType<V>>(option: T, index: number, keyExtractor?: (opt: T, i?: number) => string) => string | number;
|
|
3
|
+
export declare const isSections: <V, T extends SelectOptionType<V>>(options: CombinedOptionsType<V, T>) => options is SectionData<V, T>[];
|
|
4
|
+
export declare const toSections: <V, T extends SelectOptionType<V>>(options: CombinedOptionsType<V, T>) => SectionData<V, T>[];
|
|
5
|
+
export declare const toFlatOptions: <V, T extends SelectOptionType<V>>(options: CombinedOptionsType<V, T>) => SelectOptionType<V>[];
|
|
6
6
|
export type ScrollParams = {
|
|
7
7
|
itemIndex: number;
|
|
8
8
|
sectionIndex: number;
|
|
9
9
|
};
|
|
10
|
-
export declare const getScrollParams: <V, T extends
|
|
10
|
+
export declare const getScrollParams: <V, T extends SelectOptionType<V>>(value: V, sections: SectionData<V, T>[]) => ScrollParams;
|
|
@@ -2,7 +2,7 @@ import MultiSelect from './MultiSelect';
|
|
|
2
2
|
import type { MultiSelectProps } from './MultiSelect';
|
|
3
3
|
import type { SingleSelectProps } from './SingleSelect';
|
|
4
4
|
export type { MultiSelectProps, SingleSelectProps };
|
|
5
|
-
declare const _default: (<V, T extends import("./types").
|
|
5
|
+
declare const _default: (<V, T extends import("./types").SelectOptionType<V>>({ label, loading, inputProps, onConfirm, onDismiss, onEndReached, onQueryChange, options, renderOption, renderSelectedValue, query, error, editable, disabled, required, style, testID, value, supportedOrientations, bottomSheetConfig, }: SingleSelectProps<V, T>) => import("react").JSX.Element) & {
|
|
6
6
|
Multi: typeof MultiSelect;
|
|
7
7
|
};
|
|
8
8
|
export default _default;
|
|
@@ -2,7 +2,7 @@ import type { ReactElement } from 'react';
|
|
|
2
2
|
import type { ListRenderItemInfo, SectionListData, SectionListRenderItemInfo, StyleProp, ViewStyle } from 'react-native';
|
|
3
3
|
import { BottomSheetProps } from '../BottomSheet';
|
|
4
4
|
import type { TextInputProps } from '../TextInput';
|
|
5
|
-
export type
|
|
5
|
+
export type SelectOptionType<V> = {
|
|
6
6
|
value: V;
|
|
7
7
|
text: string;
|
|
8
8
|
key?: string;
|
|
@@ -12,17 +12,17 @@ export type OptionType<V> = {
|
|
|
12
12
|
export type SectionType = {
|
|
13
13
|
category: string;
|
|
14
14
|
};
|
|
15
|
-
export type SectionData<V, T extends
|
|
16
|
-
export type CombinedOptionsType<V, T extends
|
|
17
|
-
export type ListRenderOptionInfo<V, T extends
|
|
15
|
+
export type SectionData<V, T extends SelectOptionType<V>> = SectionListData<T, SectionType>;
|
|
16
|
+
export type CombinedOptionsType<V, T extends SelectOptionType<V>> = T[] | SectionData<V, T>[];
|
|
17
|
+
export type ListRenderOptionInfo<V, T extends SelectOptionType<V>> = ListRenderItemInfo<T> & {
|
|
18
18
|
selected: boolean;
|
|
19
19
|
onPress: () => void;
|
|
20
20
|
};
|
|
21
|
-
export type SectionListRenderOptionInfo<V, T extends
|
|
21
|
+
export type SectionListRenderOptionInfo<V, T extends SelectOptionType<V>> = SectionListRenderItemInfo<T, SectionType> & {
|
|
22
22
|
selected: boolean;
|
|
23
23
|
onPress: () => void;
|
|
24
24
|
};
|
|
25
|
-
export interface SelectProps<V, T extends
|
|
25
|
+
export interface SelectProps<V, T extends SelectOptionType<V>> extends Pick<TextInputProps, 'editable' | 'disabled' | 'error' | 'required'> {
|
|
26
26
|
/**
|
|
27
27
|
* An array of options to be selected.
|
|
28
28
|
*/
|
|
@@ -6,13 +6,13 @@ declare const StyledWrapper: import("@emotion/native").StyledComponent<import("r
|
|
|
6
6
|
}, {}, {
|
|
7
7
|
ref?: import("react").Ref<View> | undefined;
|
|
8
8
|
}>;
|
|
9
|
-
declare const StyledTitle: import("@emotion/native").StyledComponent<import("
|
|
9
|
+
declare const StyledTitle: import("@emotion/native").StyledComponent<import("../../..").TitleProps & {
|
|
10
10
|
theme?: import("@emotion/react").Theme;
|
|
11
11
|
as?: React.ElementType;
|
|
12
12
|
} & {
|
|
13
13
|
themeVariant: ThemeVariant;
|
|
14
14
|
}, {}, {}>;
|
|
15
|
-
declare const StyledDescription: import("@emotion/native").StyledComponent<import("
|
|
15
|
+
declare const StyledDescription: import("@emotion/native").StyledComponent<import("../../..").BodyProps & {
|
|
16
16
|
theme?: import("@emotion/react").Theme;
|
|
17
17
|
as?: React.ElementType;
|
|
18
18
|
} & {
|
|
@@ -42,11 +42,11 @@ declare const StyledErrorImage: import("@emotion/native").StyledComponent<import
|
|
|
42
42
|
theme?: import("@emotion/react").Theme;
|
|
43
43
|
as?: React.ElementType;
|
|
44
44
|
}, {}, {}>;
|
|
45
|
-
declare const StyledErrorTitle: import("@emotion/native").StyledComponent<import("
|
|
45
|
+
declare const StyledErrorTitle: import("@emotion/native").StyledComponent<import("../../..").TitleProps & {
|
|
46
46
|
theme?: import("@emotion/react").Theme;
|
|
47
47
|
as?: React.ElementType;
|
|
48
48
|
}, {}, {}>;
|
|
49
|
-
declare const StyledErrorDescription: import("@emotion/native").StyledComponent<import("
|
|
49
|
+
declare const StyledErrorDescription: import("@emotion/native").StyledComponent<import("../../..").BodyProps & {
|
|
50
50
|
theme?: import("@emotion/react").Theme;
|
|
51
51
|
as?: React.ElementType;
|
|
52
52
|
}, {}, {}>;
|
|
@@ -24,11 +24,11 @@ declare const StyledSuccessImageContainer: import("@emotion/native").StyledCompo
|
|
|
24
24
|
}, {}, {
|
|
25
25
|
ref?: import("react").Ref<View> | undefined;
|
|
26
26
|
}>;
|
|
27
|
-
declare const StyledSuccessTitle: import("@emotion/native").StyledComponent<import("
|
|
27
|
+
declare const StyledSuccessTitle: import("@emotion/native").StyledComponent<import("../../..").TitleProps & {
|
|
28
28
|
theme?: import("@emotion/react").Theme;
|
|
29
29
|
as?: React.ElementType;
|
|
30
30
|
}, {}, {}>;
|
|
31
|
-
declare const StyledSuccessDescription: import("@emotion/native").StyledComponent<import("
|
|
31
|
+
declare const StyledSuccessDescription: import("@emotion/native").StyledComponent<import("../../..").BodyProps & {
|
|
32
32
|
theme?: import("@emotion/react").Theme;
|
|
33
33
|
as?: React.ElementType;
|
|
34
34
|
}, {}, {}>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type { ReactElement } from 'react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { LayoutChangeEvent } from 'react-native';
|
|
4
|
-
import type { BadgeConfigType,
|
|
4
|
+
import type { BadgeConfigType, SwitchOptionType } from '.';
|
|
5
5
|
export declare const OptionContent: ({ content, badge, }: {
|
|
6
6
|
content: ReactElement;
|
|
7
7
|
badge?: BadgeConfigType;
|
|
8
8
|
}) => React.JSX.Element;
|
|
9
|
-
declare const Option: <T>({ text, icon, badge, selected, onLayout, index, }: Pick<
|
|
9
|
+
declare const Option: <T>({ text, icon, badge, selected, onLayout, index, }: Pick<SwitchOptionType<T>, "text" | "icon" | "badge"> & {
|
|
10
10
|
selected: boolean;
|
|
11
11
|
onLayout?: (e: LayoutChangeEvent) => void;
|
|
12
12
|
index?: number;
|
|
@@ -5,7 +5,7 @@ type StatusBadgeType = {
|
|
|
5
5
|
type: 'status';
|
|
6
6
|
};
|
|
7
7
|
export type BadgeConfigType = StatusBadgeType;
|
|
8
|
-
export type
|
|
8
|
+
export type SwitchOptionType<T> = {
|
|
9
9
|
value: T;
|
|
10
10
|
text: string;
|
|
11
11
|
icon: IconName;
|
|
@@ -15,7 +15,7 @@ export interface SelectorSwitchProps<T> {
|
|
|
15
15
|
/**
|
|
16
16
|
* Array of exactly TWO options to switch between.
|
|
17
17
|
*/
|
|
18
|
-
options: [
|
|
18
|
+
options: [SwitchOptionType<T>, SwitchOptionType<T>];
|
|
19
19
|
/**
|
|
20
20
|
* Current selected value.
|
|
21
21
|
*/
|
|
@@ -8,7 +8,7 @@ declare const StyledView: import("@emotion/native").StyledComponent<import("reac
|
|
|
8
8
|
}, {}, {
|
|
9
9
|
ref?: import("react").Ref<View> | undefined;
|
|
10
10
|
}>;
|
|
11
|
-
declare const StyledText: import("@emotion/native").StyledComponent<import("
|
|
11
|
+
declare const StyledText: import("@emotion/native").StyledComponent<import("../..").CaptionProps & {
|
|
12
12
|
theme?: import("@emotion/react").Theme;
|
|
13
13
|
as?: React.ElementType;
|
|
14
14
|
} & {
|
|
@@ -22,7 +22,7 @@ declare const StyledLabelInsideTextInput: import("@emotion/native").StyledCompon
|
|
|
22
22
|
}, {}, {
|
|
23
23
|
ref?: import("react").Ref<View> | undefined;
|
|
24
24
|
}>;
|
|
25
|
-
declare const StyledAsteriskLabelInsideTextInput: import("@emotion/native").StyledComponent<import("
|
|
25
|
+
declare const StyledAsteriskLabelInsideTextInput: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
26
26
|
theme?: import("@emotion/react").Theme;
|
|
27
27
|
as?: React.ElementType;
|
|
28
28
|
} & {
|
|
@@ -34,17 +34,17 @@ declare const StyledErrorContainer: import("@emotion/native").StyledComponent<im
|
|
|
34
34
|
}, {}, {
|
|
35
35
|
ref?: import("react").Ref<View> | undefined;
|
|
36
36
|
}>;
|
|
37
|
-
declare const StyledError: import("@emotion/native").StyledComponent<import("
|
|
37
|
+
declare const StyledError: import("@emotion/native").StyledComponent<import("../..").CaptionProps & {
|
|
38
38
|
theme?: import("@emotion/react").Theme;
|
|
39
39
|
as?: React.ElementType;
|
|
40
40
|
}, {}, {}>;
|
|
41
|
-
declare const StyledMaxLengthMessage: import("@emotion/native").StyledComponent<import("
|
|
41
|
+
declare const StyledMaxLengthMessage: import("@emotion/native").StyledComponent<import("../..").CaptionProps & {
|
|
42
42
|
theme?: import("@emotion/react").Theme;
|
|
43
43
|
as?: React.ElementType;
|
|
44
44
|
} & {
|
|
45
45
|
themeState: State;
|
|
46
46
|
}, {}, {}>;
|
|
47
|
-
declare const StyledHelperText: ({ children, fontWeight, intent, allowFontScaling, ...nativeProps }: import("
|
|
47
|
+
declare const StyledHelperText: ({ children, fontWeight, intent, allowFontScaling, ...nativeProps }: import("../..").CaptionProps) => import("react").JSX.Element;
|
|
48
48
|
declare const StyledTextInput: import("@emotion/native").StyledComponent<import("react-native").TextInputProps & {
|
|
49
49
|
theme?: import("@emotion/react").Theme;
|
|
50
50
|
as?: React.ElementType;
|
|
@@ -42,7 +42,7 @@ declare const CTAWrapper: import("@emotion/native").StyledComponent<import("reac
|
|
|
42
42
|
theme?: import("@emotion/react").Theme;
|
|
43
43
|
as?: React.ElementType;
|
|
44
44
|
}, {}, {}>;
|
|
45
|
-
declare const StyledBody: import("@emotion/native").StyledComponent<import("
|
|
45
|
+
declare const StyledBody: import("@emotion/native").StyledComponent<import("../..").BodyProps & {
|
|
46
46
|
theme?: import("@emotion/react").Theme;
|
|
47
47
|
as?: React.ElementType;
|
|
48
48
|
} & TextProps & {
|
package/types/types.d.ts
CHANGED
|
@@ -1,20 +1,39 @@
|
|
|
1
1
|
import type { BottomNavigationTabType } from './components/BottomNavigation';
|
|
2
|
-
import type { IconName } from './components/Icon';
|
|
2
|
+
import type { IconName, IconProps } from './components/Icon';
|
|
3
3
|
import type { SingleSelectProps, MultiSelectProps } from './components/Select';
|
|
4
4
|
import type { TabType } from './components/Tabs';
|
|
5
5
|
import type { TextInputProps, TextInputHandles } from './components/TextInput';
|
|
6
6
|
import type { RichTextEditorRef, RichTextEditorProps } from './components/RichTextEditor';
|
|
7
7
|
import type { Theme } from './theme';
|
|
8
|
-
import
|
|
8
|
+
import { ListRenderOptionInfo, SectionListRenderOptionInfo, SelectOptionType } from './components/Select/types';
|
|
9
9
|
import { SwipeableProps } from './components/Swipeable';
|
|
10
10
|
import { TextProps } from './components/Typography/Text';
|
|
11
11
|
import { CardCarouselHandles } from './components/Carousel/CardCarousel';
|
|
12
12
|
import { FABHandles } from './components/FAB/FAB';
|
|
13
13
|
import { ActionGroupHandles, ActionGroupProps } from './components/FAB/ActionGroup';
|
|
14
|
+
import type { ActionItemProps } from './components/FAB/ActionGroup/ActionItem';
|
|
14
15
|
import type { SliderRangeValue } from './components/Slider/RangeSlider';
|
|
15
16
|
import type { CalendarDateRange } from './components/Calendar/CalendarRange';
|
|
16
17
|
import { LocaleCode, LocaleValues, DateTimeFormats } from './locales/types';
|
|
17
18
|
import type { ColumnChartProps } from './components/Chart/ColumnChart';
|
|
18
19
|
import { LineChartProps } from './components/Chart/Line';
|
|
19
20
|
import type { Scale, SystemPalette } from './theme/global';
|
|
20
|
-
|
|
21
|
+
import type { BrandSystemPalette, GlobalSystemPalette } from './theme/global/colors/types';
|
|
22
|
+
import { ToolbarItemProps } from './components/Toolbar/ToolbarItem';
|
|
23
|
+
import type { CheckboxProps } from './components/Checkbox';
|
|
24
|
+
import type { SwitchOptionType } from './components/Switch/SelectorSwitch';
|
|
25
|
+
import type { BoxProps } from './components/Box';
|
|
26
|
+
import type { BodyProps } from './components/Typography/Body';
|
|
27
|
+
import type { ToolbarButtonName } from './components/RichTextEditor/types';
|
|
28
|
+
import type { ListItemProps } from './components/List/ListItem';
|
|
29
|
+
import type { IconButtonProps } from './components/Button/IconButton';
|
|
30
|
+
import type { BadgeProps } from './components/Badge';
|
|
31
|
+
import { ToastProps } from './components/Toast/types';
|
|
32
|
+
import { Space } from './theme/global/space';
|
|
33
|
+
import { CaptionProps } from './components/Typography/Caption';
|
|
34
|
+
import { Radii } from './theme/global/borders';
|
|
35
|
+
import { TitleProps } from './components/Typography/Title';
|
|
36
|
+
import { CarouselData, CarouselImageProps } from './components/Carousel/types';
|
|
37
|
+
import { PinInputHandler } from './components/PinInput';
|
|
38
|
+
import { ThemeScale } from './components/Box/types';
|
|
39
|
+
export type { Space, CaptionProps, Radii, TitleProps, CarouselData, CarouselImageProps, PinInputHandler, ThemeScale, ToastProps, ActionGroupProps, ToolbarItemProps, BottomNavigationTabType, IconName, SingleSelectProps, MultiSelectProps, ListRenderOptionInfo, SectionListRenderOptionInfo, SelectOptionType, SwipeableProps, RichTextEditorProps, RichTextEditorRef, TabType, TextInputProps, TextProps, TextInputHandles, Theme, CardCarouselHandles, FABHandles, ActionGroupHandles, ActionItemProps, SliderRangeValue, CalendarDateRange, LocaleCode, LocaleValues, DateTimeFormats, ColumnChartProps, LineChartProps, Scale, SystemPalette, BrandSystemPalette, GlobalSystemPalette, IconProps, CheckboxProps, SwitchOptionType, BoxProps, BodyProps, ToolbarButtonName, ListItemProps, IconButtonProps, BadgeProps, };
|