Reputation: 2000
I have a new RN project (0.73.6).
I am adding a modal with the package react-native-modal.
Simplified code:
const TimeModal = (props) => {
return (
<Modal
isVisible={props.show}
hasBackdrop={true}
onBackdropPress={props.hide}
>
<Pressable onPress={props.hide}>
<Text>Hide this modal</Text>
</Pressable>
</Modal>
);
}
The problem seems to be that Pressable
-components are not working inside the modal. When I switch the Pressable in the modal with a TouchableWithoutFeedback
, the modal is hiding. But the backdropPress-function is still not working.
Is this a known bug in RN 0.73.6? I can't find anything about it, I searched on both the github repos for RN and react-native-modal.
I wrapped the main component App in gestureHandlerRootHOC.
Upvotes: 0
Views: 126