diff --git a/apps/wallet-mobile/src/AppNavigator.tsx b/apps/wallet-mobile/src/AppNavigator.tsx index 69d986fd38..108013fb24 100644 --- a/apps/wallet-mobile/src/AppNavigator.tsx +++ b/apps/wallet-mobile/src/AppNavigator.tsx @@ -9,6 +9,7 @@ import {Alert, AppState, AppStateStatus, InteractionManager, Platform} from 'rea import RNBootSplash from 'react-native-bootsplash' import StorybookScreen from '../.storybook' +import {ClipboardProvider} from './components/Clipboard/ClipboardProvider' import {ModalProvider} from './components/Modal/ModalContext' import {ModalScreen} from './components/Modal/ModalScreen' import {useAuth} from './features/Auth/AuthProvider' @@ -99,112 +100,114 @@ export const AppNavigator = () => { onReady={onReady} ref={navRef} > - - - {/* Not Authenticated */} - - {isLoggedOut && ( - - {firstAction === 'first-run' && ( - - {() => ( - - - - )} - - )} - - {firstAction === 'show-agreement-changed-notice' && ( - {() => } - )} - - {firstAction === 'auth-with-pin' && ( - - )} - - {firstAction === 'auth-with-os' && ( - - )} - - {firstAction === 'request-new-pin' && ( - - )} - - )} - - {/* Authenticated */} - - {isLoggedIn && ( - <> + + + + {/* Not Authenticated */} + + {isLoggedOut && ( - {afterLoginAction === 'choose-biometric-login' && ( - + {firstAction === 'first-run' && ( + + {() => ( + + + + )} + )} - {afterLoginAction === 'dark-theme-announcement' && ( - + {firstAction === 'show-agreement-changed-notice' && ( + {() => } )} - {afterLoginAction === 'setup-wallet' && ( - )} - {afterLoginAction === 'manage-wallets' && ( - WalletNavigator} /> + {firstAction === 'auth-with-os' && ( + )} - - - + {firstAction === 'request-new-pin' && ( + + )} - - )} + )} + + {/* Authenticated */} + + {isLoggedIn && ( + <> + + {afterLoginAction === 'choose-biometric-login' && ( + + )} + + {afterLoginAction === 'dark-theme-announcement' && ( + + )} - {/* Development */} + {afterLoginAction === 'setup-wallet' && ( + + )} - {__DEV__ && ( - - + {afterLoginAction === 'manage-wallets' && ( + WalletNavigator} /> + )} + + + + + + + )} + + {/* Development */} + + {__DEV__ && ( + + - + - - - )} - - + + + )} + + + ) } diff --git a/apps/wallet-mobile/src/components/Analytics/Analytics.tsx b/apps/wallet-mobile/src/components/Analytics/Analytics.tsx index 1f580b428f..0e433a0a40 100644 --- a/apps/wallet-mobile/src/components/Analytics/Analytics.tsx +++ b/apps/wallet-mobile/src/components/Analytics/Analytics.tsx @@ -4,12 +4,12 @@ import {defineMessages, useIntl} from 'react-intl' import {StyleSheet, TextStyle, TouchableOpacity, useWindowDimensions, View} from 'react-native' import {ScrollView} from 'react-native-gesture-handler' -import {Button} from '../../components/Button/Button' import {Spacer} from '../../components/Spacer/Spacer' import {Text} from '../../components/Text' import {YoroiLogo} from '../../components/YoroiLogo/YoroiLogo' import {SettingsSwitch} from '../../features/Settings/common/SettingsSwitch' import {useMetrics} from '../../kernel/metrics/metricsManager' +import {Button, ButtonType} from '../Button/Button' import {AnalyticsImage} from './AnalyticsImage' type Props = { @@ -64,15 +64,13 @@ const Notice = ({onClose, onReadMore}: {onClose?: () => void; onReadMore?: () =>