Skip to content

Commit

Permalink
hide back button in wide screen
Browse files Browse the repository at this point in the history
  • Loading branch information
mkzie2 committed Nov 15, 2024
1 parent cfff1f6 commit 5ab2011
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/components/ValidateCode/ValidateCodeModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import * as Illustrations from '@components/Icon/Illustrations';
import Text from '@components/Text';
import TextLink from '@components/TextLink';
import useLocalize from '@hooks/useLocalize';
import useResponsiveLayout from '@hooks/useResponsiveLayout';
import useTheme from '@hooks/useTheme';
import useThemeStyles from '@hooks/useThemeStyles';
import Navigation from '@libs/Navigation/Navigation';
Expand All @@ -29,10 +30,12 @@ function ValidateCodeModal({code, accountID}: ValidateCodeModalProps) {
const [session] = useOnyx(ONYXKEYS.SESSION);
const signInHere = useCallback(() => Session.signInWithValidateCode(accountID, code), [accountID, code]);
const {translate} = useLocalize();
const {shouldUseNarrowLayout} = useResponsiveLayout();

return (
<FullPageNotFoundView
shouldShow={!ValidationUtils.isValidValidateCode(code)}
shouldShowBackButton={shouldUseNarrowLayout}
onLinkPress={() => {
Navigation.goBack();
}}
Expand Down

0 comments on commit 5ab2011

Please sign in to comment.