Skip to content

Commit

Permalink
Prevent back navigation with gestures on iOS for borrow and BYO screens
Browse files Browse the repository at this point in the history
  • Loading branch information
tsh22 committed Dec 22, 2021
1 parent f531a75 commit a292a54
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions screens/HomeStack.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const Stack = createStackNavigator();

export default function HomeStack() {
return (
<Stack.Navigator>
<Stack.Navigator options={{ gestureEnabled: false }}>
<Stack.Screen
name="Home Screen"
component={HomeScreen}
Expand All @@ -25,7 +25,7 @@ export default function HomeStack() {
<Stack.Screen
name="BYO Stack"
component={BYOStack}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
/>
{/* <Stack.Screen
name="Rewards Screen"
Expand Down
12 changes: 6 additions & 6 deletions screens/borrow-screens/BorrowStack.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const Stack = createStackNavigator();

export default function BorrowStack() {
return (
<Stack.Navigator>
<Stack.Navigator options={{ gestureEnabled: false }}>
<Stack.Screen
name="Borrow QR Screen"
component={BorrowQRScreen}
Expand All @@ -20,22 +20,22 @@ export default function BorrowStack() {
<Stack.Screen
name="Selection Screen"
component={BorrowSelectionScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
></Stack.Screen>
<Stack.Screen
name="Success Screen"
component={BorrowSuccessfulScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
></Stack.Screen>
<Stack.Screen
{/* <Stack.Screen
name="Quota Exceeded"
component={BorrowExceededScreen}
options={{ headerShown: false }}
></Stack.Screen>
></Stack.Screen> */}
<Stack.Screen
name="Unsuccess Screen"
component={BorrowUnsuccessfulScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
></Stack.Screen>
<Stack.Screen
name="QR Generator"
Expand Down
10 changes: 5 additions & 5 deletions screens/byo-screens/BYOStack.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,26 +9,26 @@ const Stack = createStackNavigator();

export default function BYOStack() {
return (
<Stack.Navigator>
<Stack.Navigator options={{ gestureEnabled: false }}>
<Stack.Screen
name="BYO Screen"
component={BYOScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
/>
<Stack.Screen
name="BYO Selection Screen"
component={BYOSelectionScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
/>
<Stack.Screen
name="BYO Unsuccessful Screen"
component={BYOUnsuccessfulScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
/>
<Stack.Screen
name="BYO Success Screen"
component={BYOSuccessScreen}
options={{ headerShown: false }}
options={{ headerShown: false, gestureEnabled: false }}
/>
</Stack.Navigator>
);
Expand Down

0 comments on commit a292a54

Please sign in to comment.