Dismiss modal on cardOverlay press (Web use case)
closed
Marc Glasser
Since gestures are not enabled for
react-native-web
it seems impossible to dismiss a modal by pressing on the cardOverlay
area. It looks like we are using an Animated.View
with pointerEvents
set to "none".However, this makes it difficult to detect taps or mouse clicks on the overlay. Is it possible to add some way to fix this? Perhaps allow passing in a custom
cardOverlay
component?satya164
closed
You can implement such an overlay inside the screen where you have full control about how you want to handle it. There's an example for this in 6.x docs, but same code (just the custom overlay part) will work in 5.x
https://reactnavigation.org/docs/6.x/stack-navigator/#transparent-modals