File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,10 +5,10 @@ import {
55 ImageBackground ,
66 ScrollView ,
77 Pressable ,
8- Modal ,
98 TouchableWithoutFeedback ,
109 View ,
1110} from 'react-native' ;
11+ import { FullWindowOverlay } from 'react-native-screens' ;
1212import { BlurView } from '@sbaiahmed1/react-native-blur' ;
1313import { DEMO_IMAGES } from '@/constants/blur' ;
1414
@@ -65,21 +65,23 @@ export default function HomeScreen() {
6565 </ BlurView >
6666 </ ScrollView >
6767
68- < Modal visible = { isModalVisible } transparent statusBarTranslucent >
69- < TouchableWithoutFeedback onPress = { ( ) => setIsModalVisible ( false ) } >
70- < BlurView
71- ignoreSafeArea
72- blurType = { 'dark' }
73- style = { StyleSheet . absoluteFill }
74- />
75- </ TouchableWithoutFeedback >
68+ { isModalVisible && (
69+ < FullWindowOverlay >
70+ < TouchableWithoutFeedback onPress = { ( ) => setIsModalVisible ( false ) } >
71+ < BlurView
72+ ignoreSafeArea
73+ blurType = { 'dark' }
74+ style = { StyleSheet . absoluteFill }
75+ />
76+ </ TouchableWithoutFeedback >
7677
77- < View style = { styles . modalContent } >
78- < View style = { styles . modalCard } >
79- < Text > Hello this is a centred text in a modal</ Text >
78+ < View style = { styles . modalContent } pointerEvents = "none" >
79+ < View style = { styles . modalCard } >
80+ < Text > Hello this is a centred text in a modal</ Text >
81+ </ View >
8082 </ View >
81- </ View >
82- </ Modal >
83+ </ FullWindowOverlay >
84+ ) }
8385 </ ImageBackground >
8486 ) ;
8587}
You can’t perform that action at this time.
0 commit comments