diff --git a/packages/core-mobile/app/navigation/AppNavigation.ts b/packages/core-mobile/app/navigation/AppNavigation.ts index f4a73849d6..3da41c917d 100644 --- a/packages/core-mobile/app/navigation/AppNavigation.ts +++ b/packages/core-mobile/app/navigation/AppNavigation.ts @@ -3,8 +3,7 @@ enum Root { Onboard = 'Root.Onboard', RefreshToken = 'Root.RefreshToken', CopyPhraseWarning = 'Root.CopyPhraseWarning', - ForgotPin = 'Root.ForgotPin', - Login = 'Root.Login' + ForgotPin = 'Root.ForgotPin' } enum OnboardScreens { diff --git a/packages/core-mobile/app/navigation/RootScreenStack.tsx b/packages/core-mobile/app/navigation/RootScreenStack.tsx index 9b1e87cd59..17686a580a 100644 --- a/packages/core-mobile/app/navigation/RootScreenStack.tsx +++ b/packages/core-mobile/app/navigation/RootScreenStack.tsx @@ -43,7 +43,6 @@ export type RootScreenStackParamList = { title: string message: string } - [AppNavigation.Root.Login]: undefined } const RootStack = createStackNavigator() @@ -51,6 +50,7 @@ const RootStack = createStackNavigator() const WalletScreenStackWithContext: FC = () => { const { onExit } = useApplicationContext().appHook const { inBackground } = useBgDetect() + const walletState = useSelector(selectWalletState) const doExit = useCallback(() => { onExit((confirmExit, cancel) => { @@ -75,6 +75,7 @@ const WalletScreenStackWithContext: FC = () => { return ( <> + {walletState === WalletState.INACTIVE && } {/* This protects from leaking last screen in "recent apps" list. */} {/* For Android it is additionally implemented natively in MainActivity.java because react-native */} @@ -101,7 +102,7 @@ const RootScreenStack: FC = () => { animationEnabled: false }} /> - ) : walletState === WalletState.ACTIVE ? ( + ) : ( { presentation: 'card' }} /> - ) : ( - )}