Skip to content

Commit 835dfef

Browse files
authored
Have a return fallback when using targetFrame for Hint component (#1457)
1 parent 416aa6a commit 835dfef

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

generatedTypes/components/hint/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ declare class Hint extends Component<HintProps, HintState> {
166166
renderHint(): JSX.Element | undefined;
167167
renderHintContainer(): JSX.Element;
168168
renderChildren(): React.ReactElement<any, string | React.JSXElementConstructor<any>> | undefined;
169-
render(): React.ReactNode;
169+
render(): {} | null;
170170
}
171171
declare const _default: React.ComponentClass<HintProps & {
172172
useCustomTheme?: boolean | undefined;

src/components/hint/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -535,7 +535,7 @@ class Hint extends Component<HintProps, HintState> {
535535
const {onBackgroundPress, testID} = this.props;
536536

537537
if (!this.props.visible && this.state.hintUnmounted) {
538-
return this.props.children;
538+
return this.props.children || null;
539539
}
540540

541541
return (

0 commit comments

Comments
 (0)