@hero-design/rn 8.113.0 → 8.113.1
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 +11 -0
- package/es/index.js +116 -133
- package/lib/index.js +115 -132
- package/package.json +4 -4
- package/src/components/Alert/index.tsx +1 -1
- package/src/components/Badge/Count.tsx +2 -2
- package/src/components/Badge/Status.tsx +2 -2
- package/src/components/Badge/index.tsx +2 -1
- package/src/components/BottomNavigation/StyledBottomNavigation.tsx +1 -1
- package/src/components/BottomNavigation/__tests__/__snapshots__/index.spec.tsx.snap +32 -36
- package/src/components/BottomNavigation/__tests__/index.spec.tsx +17 -8
- package/src/components/BottomNavigation/index.tsx +4 -5
- package/src/components/BottomSheet/ScrollView.tsx +2 -1
- package/src/components/BottomSheet/index.tsx +1 -1
- package/src/components/Button/Button.tsx +2 -2
- package/src/components/Calendar/__tests__/index.spec.tsx +3 -8
- package/src/components/Card/DataCard/index.tsx +2 -2
- package/src/components/Card/index.tsx +2 -2
- package/src/components/Carousel/index.tsx +2 -2
- package/src/components/DatePicker/Dialog/__tests__/IOSDialog.spec.tsx +0 -6
- package/src/components/DatePicker/__tests__/DatePickerCalendar.spec.tsx +2 -10
- package/src/components/DatePicker/__tests__/DatePickerIOS.spec.tsx +27 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerIOS.spec.tsx.snap +176 -728
- package/src/components/Drawer/DragableDrawer/index.tsx +2 -2
- package/src/components/Drawer/index.tsx +2 -2
- package/src/components/FAB/__tests__/index.spec.tsx +33 -8
- package/src/components/Image/index.tsx +2 -1
- package/src/components/List/BasicListItem.tsx +2 -1
- package/src/components/List/ListItem.tsx +1 -1
- package/src/components/MapPin/Focussed.tsx +2 -1
- package/src/components/MapPin/index.tsx +2 -1
- package/src/components/Modal/__tests__/index.spec.tsx +46 -0
- package/src/components/Modal/index.tsx +121 -149
- package/src/components/Progress/ProgressBar.tsx +2 -1
- package/src/components/Progress/ProgressCircle.tsx +2 -1
- package/src/components/RichTextEditor/MentionList.tsx +2 -1
- package/src/components/Tabs/ScrollableTabsHeader/ScrollableTabsHeader.tsx +4 -6
- package/src/components/Tabs/__tests__/ScrollableTabs.spec.tsx +43 -32
- package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabs.spec.tsx.snap +105 -129
- package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabsHeader.spec.tsx.snap +30 -42
- package/src/components/Tabs/__tests__/__snapshots__/index.spec.tsx.snap +0 -683
- package/src/components/Tabs/__tests__/index.spec.tsx +37 -25
- package/src/components/Tabs/index.tsx +2 -2
- package/src/components/Tag/index.tsx +1 -1
- package/src/components/TimePicker/__tests__/TimePickerIOS.spec.tsx +0 -6
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerIOS.spec.tsx.snap +237 -282
- package/src/components/Toast/Toast.tsx +2 -1
- package/src/components/Toolbar/ToolbarItem.tsx +2 -1
- package/src/components/Typography/Label/index.tsx +1 -1
- package/src/testHelpers/renderWithTheme.tsx +2 -1
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +1 -1
- package/src/theme/components/bottomNavigation.ts +1 -1
- package/types/components/Alert/index.d.ts +1 -1
- package/types/components/Badge/Count.d.ts +2 -2
- package/types/components/Badge/Status.d.ts +2 -2
- package/types/components/Badge/index.d.ts +4 -3
- package/types/components/BottomNavigation/StyledBottomNavigation.d.ts +1 -1
- package/types/components/BottomNavigation/index.d.ts +2 -2
- package/types/components/BottomSheet/index.d.ts +1 -1
- package/types/components/Button/Button.d.ts +2 -2
- package/types/components/Card/DataCard/index.d.ts +2 -2
- package/types/components/Card/index.d.ts +3 -3
- package/types/components/Carousel/index.d.ts +2 -2
- package/types/components/Drawer/DragableDrawer/index.d.ts +2 -2
- package/types/components/Drawer/index.d.ts +3 -3
- package/types/components/Image/index.d.ts +2 -1
- package/types/components/List/BasicListItem.d.ts +2 -1
- package/types/components/List/ListItem.d.ts +1 -1
- package/types/components/MapPin/Focussed.d.ts +2 -1
- package/types/components/MapPin/index.d.ts +3 -2
- package/types/components/Modal/index.d.ts +2 -2
- package/types/components/Progress/ProgressBar.d.ts +2 -1
- package/types/components/Progress/ProgressCircle.d.ts +2 -1
- package/types/components/Progress/index.d.ts +2 -2
- package/types/components/RichTextEditor/MentionList.d.ts +2 -1
- package/types/components/Tabs/index.d.ts +2 -2
- package/types/components/Tag/index.d.ts +1 -1
- package/types/components/Toast/Toast.d.ts +2 -1
- package/types/components/Typography/Label/index.d.ts +1 -1
- package/types/testHelpers/renderWithTheme.d.ts +84 -1
|
@@ -62,5 +62,5 @@ type AlertProps = (BasicAlertProps & {
|
|
|
62
62
|
*/
|
|
63
63
|
actionLabel: string;
|
|
64
64
|
});
|
|
65
|
-
declare const Alert: ({ content, icon, title, intent, onClose, variant, style, testID, actionLabel, }: AlertProps) =>
|
|
65
|
+
declare const Alert: ({ content, icon, title, intent, onClose, variant, style, testID, actionLabel, }: AlertProps) => ReactElement;
|
|
66
66
|
export default Alert;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { StyleProp, ViewStyle, ViewProps } from 'react-native';
|
|
2
|
-
import type { ReactNode } from 'react';
|
|
2
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
3
3
|
export interface CountProps extends ViewProps {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
/**
|
|
@@ -23,5 +23,5 @@ export interface CountProps extends ViewProps {
|
|
|
23
23
|
*/
|
|
24
24
|
max?: number;
|
|
25
25
|
}
|
|
26
|
-
declare const Status: ({ children, visible, style, max, testID, content: originalContent, ...nativeProps }: CountProps) =>
|
|
26
|
+
declare const Status: ({ children, visible, style, max, testID, content: originalContent, ...nativeProps }: CountProps) => ReactElement;
|
|
27
27
|
export default Status;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { StyleProp, ViewStyle, ViewProps } from 'react-native';
|
|
2
|
-
import type { ReactNode } from 'react';
|
|
2
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
3
3
|
export interface StatusProps extends ViewProps {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
/**
|
|
@@ -19,5 +19,5 @@ export interface StatusProps extends ViewProps {
|
|
|
19
19
|
*/
|
|
20
20
|
testID?: string;
|
|
21
21
|
}
|
|
22
|
-
declare const Status: ({ children, visible, intent, style, testID, ...nativeProps }: StatusProps) =>
|
|
22
|
+
declare const Status: ({ children, visible, intent, style, testID, ...nativeProps }: StatusProps) => ReactElement;
|
|
23
23
|
export default Status;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import type { BasicBadgeProps, IconBadgeProps } from './types';
|
|
2
3
|
export type BadgeProps = BasicBadgeProps | IconBadgeProps;
|
|
3
|
-
declare const _default: (({ content: originalContent, visible, max, intent, style, testID, size, variant, icon, ...nativeProps }: BadgeProps) =>
|
|
4
|
-
Status: ({ children, visible, intent, style, testID, ...nativeProps }: import("./Status").StatusProps) =>
|
|
5
|
-
Count: ({ children, visible, style, max, testID, content: originalContent, ...nativeProps }: import("./Count").CountProps) =>
|
|
4
|
+
declare const _default: (({ content: originalContent, visible, max, intent, style, testID, size, variant, icon, ...nativeProps }: BadgeProps) => ReactElement) & {
|
|
5
|
+
Status: ({ children, visible, intent, style, testID, ...nativeProps }: import("./Status").StatusProps) => ReactElement;
|
|
6
|
+
Count: ({ children, visible, style, max, testID, content: originalContent, ...nativeProps }: import("./Count").CountProps) => ReactElement;
|
|
6
7
|
};
|
|
7
8
|
export default _default;
|
|
@@ -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("../Typography/Label").LabelProps & {
|
|
48
48
|
theme?: import("@emotion/react").Theme;
|
|
49
49
|
as?: React.ElementType;
|
|
50
50
|
}, {}, {}>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
2
|
import type { StyleProp, ViewStyle, ViewProps } from 'react-native';
|
|
3
3
|
import type { IconName } from '../Icon';
|
|
4
4
|
export type BottomNavigationTabType = {
|
|
@@ -41,5 +41,5 @@ interface BottomNavigationProps extends ViewProps {
|
|
|
41
41
|
*/
|
|
42
42
|
testID?: string;
|
|
43
43
|
}
|
|
44
|
-
declare const BottomNavigation: ({ onTabPress, renderActiveTabOnly, selectedTabKey, tabs, ...nativeProps }: BottomNavigationProps) =>
|
|
44
|
+
declare const BottomNavigation: ({ onTabPress, renderActiveTabOnly, selectedTabKey, tabs, ...nativeProps }: BottomNavigationProps) => ReactElement;
|
|
45
45
|
export default BottomNavigation;
|
|
@@ -68,7 +68,7 @@ export interface BottomSheetProps {
|
|
|
68
68
|
*/
|
|
69
69
|
variant?: 'fixed' | 'floating';
|
|
70
70
|
}
|
|
71
|
-
declare const _default: (({ open, header, footer, children, onAnimationEnd, onOpen, onRequestClose, onDismiss, showCloseButton, hasBackdrop, showDivider, style, testID, keyboardAvoidingViewProps, supportedOrientations, variant, }: BottomSheetProps) =>
|
|
71
|
+
declare const _default: (({ open, header, footer, children, onAnimationEnd, onOpen, onRequestClose, onDismiss, showCloseButton, hasBackdrop, showDivider, style, testID, keyboardAvoidingViewProps, supportedOrientations, variant, }: BottomSheetProps) => ReactElement) & {
|
|
72
72
|
ScrollView: React.ForwardRefExoticComponent<import("react-native").ScrollViewProps & React.RefAttributes<import("react-native").ScrollView>>;
|
|
73
73
|
};
|
|
74
74
|
export default _default;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactChild, ReactNode } from 'react';
|
|
1
|
+
import type { ReactChild, ReactElement, ReactNode } from 'react';
|
|
2
2
|
import type { StyleProp, ViewStyle } from 'react-native';
|
|
3
3
|
import type { IconName } from '../Icon';
|
|
4
4
|
import type { Intent, ThemeVariant } from './StyledButton';
|
|
@@ -60,5 +60,5 @@ export interface ButtonProps {
|
|
|
60
60
|
variant?: 'filled' | 'outlined' | 'text' | 'inline-text' | 'filled-medium' | 'outlined-medium' | 'text-medium' | 'filled-compact' | 'outlined-compact' | 'text-compact' | 'inline-text-compact';
|
|
61
61
|
}
|
|
62
62
|
export declare const getThemeVariant: (variant: "filled" | "outlined" | "text" | "filled-medium" | "outlined-medium" | "text-medium" | "filled-compact" | "outlined-compact" | "text-compact", intent: Intent) => ThemeVariant;
|
|
63
|
-
declare const Button: ({ accessibilityHint, accessibilityLabel, disabled, icon, intent, loading, onPress, rightIcon, style, testID, text, variant, }: ButtonProps) =>
|
|
63
|
+
declare const Button: ({ accessibilityHint, accessibilityLabel, disabled, icon, intent, loading, onPress, rightIcon, style, testID, text, variant, }: ButtonProps) => ReactElement;
|
|
64
64
|
export default Button;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
2
|
import type { StyleProp, ViewStyle, ViewProps } from 'react-native';
|
|
3
3
|
export interface DataCardProps extends ViewProps {
|
|
4
4
|
/**
|
|
@@ -18,5 +18,5 @@ export interface DataCardProps extends ViewProps {
|
|
|
18
18
|
*/
|
|
19
19
|
testID?: string;
|
|
20
20
|
}
|
|
21
|
-
declare const DataCard: ({ intent, children, ...nativeProps }: DataCardProps) =>
|
|
21
|
+
declare const DataCard: ({ intent, children, ...nativeProps }: DataCardProps) => ReactElement;
|
|
22
22
|
export default DataCard;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import type { StyleProp, ViewProps, ViewStyle } from 'react-native';
|
|
4
4
|
export interface CardProps extends ViewProps {
|
|
@@ -20,8 +20,8 @@ export interface CardProps extends ViewProps {
|
|
|
20
20
|
testID?: string;
|
|
21
21
|
variant?: 'basic' | 'super-round';
|
|
22
22
|
}
|
|
23
|
-
declare const _default: (({ intent, children, variant, ...nativeProps }: CardProps) =>
|
|
24
|
-
Data: ({ intent, children, ...nativeProps }: import("./DataCard").DataCardProps) =>
|
|
23
|
+
declare const _default: (({ intent, children, variant, ...nativeProps }: CardProps) => ReactElement) & {
|
|
24
|
+
Data: ({ intent, children, ...nativeProps }: import("./DataCard").DataCardProps) => ReactElement;
|
|
25
25
|
DataContent: import("@emotion/native").StyledComponent<ViewProps & {
|
|
26
26
|
theme?: import("@emotion/react").Theme;
|
|
27
27
|
as?: React.ElementType;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Dispatch, SetStateAction } from 'react';
|
|
1
|
+
import type { Dispatch, ReactElement, SetStateAction } from 'react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import type { StyleProp, ViewProps, ViewStyle } from 'react-native';
|
|
4
4
|
import type { CarouselData } from './types';
|
|
@@ -22,7 +22,7 @@ interface CarouselProps extends ViewProps {
|
|
|
22
22
|
/**
|
|
23
23
|
* Render action elements function.
|
|
24
24
|
*/
|
|
25
|
-
renderActions?: (pageIndex: number) =>
|
|
25
|
+
renderActions?: (pageIndex: number) => ReactElement;
|
|
26
26
|
/**
|
|
27
27
|
* @deprecated will be removed in 9.0.0
|
|
28
28
|
*
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
2
|
export interface DragableDrawerProps {
|
|
3
3
|
/**
|
|
4
4
|
* Drawer's content.
|
|
@@ -29,5 +29,5 @@ export interface DragableDrawerProps {
|
|
|
29
29
|
*/
|
|
30
30
|
snapPoints?: number[];
|
|
31
31
|
}
|
|
32
|
-
declare const DragableDrawer: ({ children, initialHeightPercentage, minimumHeightPercentage, snapPoints, onExpanded, onCollapsed, testID, }: DragableDrawerProps) =>
|
|
32
|
+
declare const DragableDrawer: ({ children, initialHeightPercentage, minimumHeightPercentage, snapPoints, onExpanded, onCollapsed, testID, }: DragableDrawerProps) => ReactElement;
|
|
33
33
|
export default DragableDrawer;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
2
|
interface DrawerProps {
|
|
3
3
|
/**
|
|
4
4
|
* Drawer's visibility.
|
|
@@ -21,7 +21,7 @@ interface DrawerProps {
|
|
|
21
21
|
* */
|
|
22
22
|
testID?: string;
|
|
23
23
|
}
|
|
24
|
-
declare const _default: (({ visible, children, hasBackdrop, onDismiss, testID, }: DrawerProps) =>
|
|
25
|
-
Dragable: ({ children, initialHeightPercentage, minimumHeightPercentage, snapPoints, onExpanded, onCollapsed, testID, }: import("./DragableDrawer").DragableDrawerProps) =>
|
|
24
|
+
declare const _default: (({ visible, children, hasBackdrop, onDismiss, testID, }: DrawerProps) => ReactElement) & {
|
|
25
|
+
Dragable: ({ children, initialHeightPercentage, minimumHeightPercentage, snapPoints, onExpanded, onCollapsed, testID, }: import("./DragableDrawer").DragableDrawerProps) => ReactElement;
|
|
26
26
|
};
|
|
27
27
|
export default _default;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import type { ImageProps as RNImageProps } from 'react-native';
|
|
2
3
|
export interface ImageProps extends RNImageProps {
|
|
3
4
|
/**
|
|
@@ -16,5 +17,5 @@ export interface ImageProps extends RNImageProps {
|
|
|
16
17
|
/**
|
|
17
18
|
* @deprecated Image component will soon be deprecated. Please use `Image` from `react-native` instead.
|
|
18
19
|
*/
|
|
19
|
-
declare const Image: ({ rounded, size, testID, style, ...imageNativeProps }: ImageProps) =>
|
|
20
|
+
declare const Image: ({ rounded, size, testID, style, ...imageNativeProps }: ImageProps) => ReactElement;
|
|
20
21
|
export default Image;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import React from 'react';
|
|
2
3
|
import type { StyleProp, ViewStyle } from 'react-native';
|
|
3
4
|
import type { IconName } from '../Icon';
|
|
@@ -39,5 +40,5 @@ interface ListItemProps {
|
|
|
39
40
|
*/
|
|
40
41
|
onPress?: () => void;
|
|
41
42
|
}
|
|
42
|
-
declare const BasicListItem: ({ prefix, suffix, title, subtitle, style, testID, selected, disabled, onPress, }: ListItemProps) =>
|
|
43
|
+
declare const BasicListItem: ({ prefix, suffix, title, subtitle, style, testID, selected, disabled, onPress, }: ListItemProps) => ReactElement;
|
|
43
44
|
export default BasicListItem;
|
|
@@ -48,5 +48,5 @@ export interface ListItemProps {
|
|
|
48
48
|
*/
|
|
49
49
|
onPress?: () => void;
|
|
50
50
|
}
|
|
51
|
-
declare const ListItem: ({ prefix, suffix, title, subtitle, style, testID, selected, children, leadingStatus, variant, onPress, disabled, }: ListItemProps) =>
|
|
51
|
+
declare const ListItem: ({ prefix, suffix, title, subtitle, style, testID, selected, children, leadingStatus, variant, onPress, disabled, }: ListItemProps) => ReactElement;
|
|
52
52
|
export default ListItem;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import type { ViewProps, StyleProp, ViewStyle } from 'react-native';
|
|
2
3
|
export interface MapPinFocussedProps extends ViewProps {
|
|
3
4
|
/**
|
|
@@ -9,5 +10,5 @@ export interface MapPinFocussedProps extends ViewProps {
|
|
|
9
10
|
*/
|
|
10
11
|
testID?: string;
|
|
11
12
|
}
|
|
12
|
-
declare const MapPinFocussed: ({ style, testID, ...nativeProps }: MapPinFocussedProps) =>
|
|
13
|
+
declare const MapPinFocussed: ({ style, testID, ...nativeProps }: MapPinFocussedProps) => ReactElement;
|
|
13
14
|
export default MapPinFocussed;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import type { MapPinProps } from './types';
|
|
2
|
-
declare const _default: (({ style, testID, state, image, icon, ...nativeProps }: MapPinProps) =>
|
|
3
|
-
Focussed: ({ style, testID, ...nativeProps }: import("./Focussed").MapPinFocussedProps) =>
|
|
3
|
+
declare const _default: (({ style, testID, state, image, icon, ...nativeProps }: MapPinProps) => ReactElement) & {
|
|
4
|
+
Focussed: ({ style, testID, ...nativeProps }: import("./Focussed").MapPinFocussedProps) => ReactElement;
|
|
4
5
|
};
|
|
5
6
|
export default _default;
|
|
@@ -34,5 +34,5 @@ export interface ModalProps {
|
|
|
34
34
|
*/
|
|
35
35
|
onDismiss?: () => void;
|
|
36
36
|
}
|
|
37
|
-
declare const
|
|
38
|
-
export default
|
|
37
|
+
declare const Modal: ({ children, visible, onShow, onRequestClose, testID, animationType, transparent, onDismiss, }: ModalProps) => React.JSX.Element | null;
|
|
38
|
+
export default Modal;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import type { StyleProp, ViewStyle, ViewProps } from 'react-native';
|
|
2
3
|
export interface ProgressBarProps extends ViewProps {
|
|
3
4
|
/**
|
|
@@ -14,5 +15,5 @@ export interface ProgressBarProps extends ViewProps {
|
|
|
14
15
|
style?: StyleProp<ViewStyle>;
|
|
15
16
|
testID?: string;
|
|
16
17
|
}
|
|
17
|
-
declare const ProgressBar: ({ value, intent, style, testID, ...nativeProps }: ProgressBarProps) =>
|
|
18
|
+
declare const ProgressBar: ({ value, intent, style, testID, ...nativeProps }: ProgressBarProps) => ReactElement;
|
|
18
19
|
export default ProgressBar;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import React from 'react';
|
|
2
3
|
import type { ViewProps, StyleProp, ViewStyle } from 'react-native';
|
|
3
4
|
export interface ProgressCircleProps extends ViewProps {
|
|
@@ -16,5 +17,5 @@ export interface ProgressCircleProps extends ViewProps {
|
|
|
16
17
|
style?: StyleProp<ViewStyle>;
|
|
17
18
|
testID?: string;
|
|
18
19
|
}
|
|
19
|
-
declare const ProgressCircle: ({ value, renderValue, intent, style, testID, ...nativeProps }: ProgressCircleProps) =>
|
|
20
|
+
declare const ProgressCircle: ({ value, renderValue, intent, style, testID, ...nativeProps }: ProgressCircleProps) => ReactElement;
|
|
20
21
|
export default ProgressCircle;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare const Progress: {
|
|
2
|
-
readonly Circle: ({ value, renderValue, intent, style, testID, ...nativeProps }: import("./ProgressCircle").ProgressCircleProps) =>
|
|
3
|
-
readonly Bar: ({ value, intent, style, testID, ...nativeProps }: import("./ProgressBar").ProgressBarProps) =>
|
|
2
|
+
readonly Circle: ({ value, renderValue, intent, style, testID, ...nativeProps }: import("./ProgressCircle").ProgressCircleProps) => import("react").ReactElement;
|
|
3
|
+
readonly Bar: ({ value, intent, style, testID, ...nativeProps }: import("./ProgressBar").ProgressBarProps) => import("react").ReactElement;
|
|
4
4
|
readonly Step: ({ steps, current, onLayout, ...props }: import("./ProgressStep").ProgressStepProps) => import("react").JSX.Element;
|
|
5
5
|
};
|
|
6
6
|
export default Progress;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import React from 'react';
|
|
2
3
|
interface OnSelectOptionsType<TMetaData> {
|
|
3
4
|
highlighted: boolean;
|
|
@@ -11,7 +12,7 @@ export interface MentionListProps<TMetaData = unknown> {
|
|
|
11
12
|
/**
|
|
12
13
|
* Function used to render mention options
|
|
13
14
|
*/
|
|
14
|
-
render: (searchText: string, onSelect: (id: string, name: string, options?: OnSelectOptionsType<TMetaData>) => void) =>
|
|
15
|
+
render: (searchText: string, onSelect: (id: string, name: string, options?: OnSelectOptionsType<TMetaData>) => void) => ReactElement;
|
|
15
16
|
}
|
|
16
17
|
declare const MentionList: <TMetaData>({ name: eventPrefix, render, }: MentionListProps<TMetaData>) => React.JSX.Element | null;
|
|
17
18
|
export default MentionList;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import type { StyleProp, ViewProps, ViewStyle } from 'react-native';
|
|
4
4
|
import type { IconName } from '../Icon';
|
|
@@ -55,7 +55,7 @@ export interface TabsProps extends ViewProps {
|
|
|
55
55
|
*/
|
|
56
56
|
testID?: string;
|
|
57
57
|
}
|
|
58
|
-
declare const _default: (({ onTabPress, selectedTabKey, tabs, containerStyle, barStyle, lazy, lazyPreloadDistance, swipeEnabled, testID: componentTestID, }: TabsProps) =>
|
|
58
|
+
declare const _default: (({ onTabPress, selectedTabKey, tabs, containerStyle, barStyle, lazy, lazyPreloadDistance, swipeEnabled, testID: componentTestID, }: TabsProps) => ReactElement) & {
|
|
59
59
|
Scroll: ({ onTabPress, selectedTabKey, tabs, containerStyle, barStyle, lazy, lazyPreloadDistance, swipeEnabled, testID: componentTestID, variant, }: import("./ScrollableTabs").ScrollableTabProps) => React.JSX.Element;
|
|
60
60
|
useIsFocused: () => boolean | undefined;
|
|
61
61
|
};
|
|
@@ -24,5 +24,5 @@ interface TagProps extends ViewProps {
|
|
|
24
24
|
*/
|
|
25
25
|
testID?: string;
|
|
26
26
|
}
|
|
27
|
-
declare const Tag: ({ content, variant, intent, style, testID, ...nativeProps }: TagProps) =>
|
|
27
|
+
declare const Tag: ({ content, variant, intent, style, testID, ...nativeProps }: TagProps) => ReactElement;
|
|
28
28
|
export default Tag;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
1
2
|
import type { ToastProps } from './types';
|
|
2
|
-
declare const Toast: ({ content, icon, variant, intent, style, duration, autoDismiss, onAction, actionLabel, onDismiss, distance, }: ToastProps) =>
|
|
3
|
+
declare const Toast: ({ content, icon, variant, intent, style, duration, autoDismiss, onAction, actionLabel, onDismiss, distance, }: ToastProps) => ReactElement;
|
|
3
4
|
export default Toast;
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import type { ReactNode } from 'react';
|
|
3
3
|
import type { TextProps as NativeTextProps, StyleProp, TextStyle } from 'react-native';
|
|
4
4
|
import type { TypographyIntent } from '../types';
|
|
5
|
-
interface LabelProps extends NativeTextProps {
|
|
5
|
+
export interface LabelProps extends NativeTextProps {
|
|
6
6
|
/**
|
|
7
7
|
* Text content.
|
|
8
8
|
*/
|
|
@@ -1,3 +1,86 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
2
|
+
import React from 'react';
|
|
1
3
|
import type { RenderOptions } from '@testing-library/react-native';
|
|
2
|
-
declare const renderWithTheme: (ui:
|
|
4
|
+
declare const renderWithTheme: (ui: ReactElement, options?: RenderOptions) => {
|
|
5
|
+
rerender: (component: React.ReactElement) => void;
|
|
6
|
+
rerenderAsync: (component: React.ReactElement) => Promise<void>;
|
|
7
|
+
update: (component: React.ReactElement) => void;
|
|
8
|
+
updateAsync: (component: React.ReactElement) => Promise<void>;
|
|
9
|
+
unmount: () => void;
|
|
10
|
+
unmountAsync: () => Promise<void>;
|
|
11
|
+
toJSON: () => null | import("react-test-renderer").ReactTestRendererJSON | import("react-test-renderer").ReactTestRendererJSON[];
|
|
12
|
+
debug: import("@testing-library/react-native").DebugFunction;
|
|
13
|
+
root: ReactTestInstance;
|
|
14
|
+
UNSAFE_root: ReactTestInstance;
|
|
15
|
+
UNSAFE_getByProps: (props: {
|
|
16
|
+
[x: string]: unknown;
|
|
17
|
+
}) => ReactTestInstance;
|
|
18
|
+
UNSAFE_getAllByProps: (props: {
|
|
19
|
+
[x: string]: unknown;
|
|
20
|
+
}) => Array<ReactTestInstance>;
|
|
21
|
+
UNSAFE_queryByProps: (props: {
|
|
22
|
+
[x: string]: unknown;
|
|
23
|
+
}) => ReactTestInstance | null;
|
|
24
|
+
UNSAFE_queryAllByProps: (props: {
|
|
25
|
+
[x: string]: unknown;
|
|
26
|
+
}) => Array<ReactTestInstance>;
|
|
27
|
+
UNSAFE_getByType: <P>(type: React.ComponentType<P>) => ReactTestInstance;
|
|
28
|
+
UNSAFE_getAllByType: <P>(type: React.ComponentType<P>) => Array<ReactTestInstance>;
|
|
29
|
+
UNSAFE_queryByType: <P>(type: React.ComponentType<P>) => ReactTestInstance | null;
|
|
30
|
+
UNSAFE_queryAllByType: <P>(type: React.ComponentType<P>) => Array<ReactTestInstance>;
|
|
31
|
+
getByRole: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/queries/role").ByRoleMatcher, import("@testing-library/react-native/build/queries/role").ByRoleOptions>;
|
|
32
|
+
getAllByRole: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/queries/role").ByRoleMatcher, import("@testing-library/react-native/build/queries/role").ByRoleOptions>;
|
|
33
|
+
queryByRole: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/queries/role").ByRoleMatcher, import("@testing-library/react-native/build/queries/role").ByRoleOptions>;
|
|
34
|
+
queryAllByRole: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/queries/role").ByRoleMatcher, import("@testing-library/react-native/build/queries/role").ByRoleOptions>;
|
|
35
|
+
findByRole: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/queries/role").ByRoleMatcher, import("@testing-library/react-native/build/queries/role").ByRoleOptions>;
|
|
36
|
+
findAllByRole: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/queries/role").ByRoleMatcher, import("@testing-library/react-native/build/queries/role").ByRoleOptions>;
|
|
37
|
+
getByHintText: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
38
|
+
getAllByHintText: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
39
|
+
queryByHintText: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
40
|
+
queryAllByHintText: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
41
|
+
findByHintText: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
42
|
+
findAllByHintText: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
43
|
+
getByA11yHint: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
44
|
+
getAllByA11yHint: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
45
|
+
queryByA11yHint: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
46
|
+
queryAllByA11yHint: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
47
|
+
findByA11yHint: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
48
|
+
findAllByA11yHint: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
49
|
+
getByAccessibilityHint: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
50
|
+
getAllByAccessibilityHint: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
51
|
+
queryByAccessibilityHint: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
52
|
+
queryAllByAccessibilityHint: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
53
|
+
findByAccessibilityHint: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
54
|
+
findAllByAccessibilityHint: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
55
|
+
getByLabelText: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
56
|
+
getAllByLabelText: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
57
|
+
queryByLabelText: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
58
|
+
queryAllByLabelText: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
59
|
+
findByLabelText: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
60
|
+
findAllByLabelText: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
61
|
+
getByPlaceholderText: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
62
|
+
getAllByPlaceholderText: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
63
|
+
queryByPlaceholderText: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
64
|
+
queryAllByPlaceholderText: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
65
|
+
findByPlaceholderText: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
66
|
+
findAllByPlaceholderText: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
67
|
+
getByDisplayValue: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
68
|
+
getAllByDisplayValue: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
69
|
+
queryByDisplayValue: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
70
|
+
queryAllByDisplayValue: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
71
|
+
findByDisplayValue: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
72
|
+
findAllByDisplayValue: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
73
|
+
getByTestId: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
74
|
+
getAllByTestId: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
75
|
+
queryByTestId: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
76
|
+
queryAllByTestId: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
77
|
+
findByTestId: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
78
|
+
findAllByTestId: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
79
|
+
getByText: import("@testing-library/react-native/build/queries/make-queries").GetByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
80
|
+
getAllByText: import("@testing-library/react-native/build/queries/make-queries").GetAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
81
|
+
queryByText: import("@testing-library/react-native/build/queries/make-queries").QueryByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
82
|
+
queryAllByText: import("@testing-library/react-native/build/queries/make-queries").QueryAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
83
|
+
findByText: import("@testing-library/react-native/build/queries/make-queries").FindByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
84
|
+
findAllByText: import("@testing-library/react-native/build/queries/make-queries").FindAllByQuery<import("@testing-library/react-native/build/matches").TextMatch, import("@testing-library/react-native/build/queries/options").CommonQueryOptions & import("@testing-library/react-native/build/matches").TextMatchOptions>;
|
|
85
|
+
};
|
|
3
86
|
export default renderWithTheme;
|