Skip to content

Commit 0591b9c

Browse files
Merge pull request Expensify#60064 from Themoonalsofall/update-2FA-page
Improvements Two-Factor Authentication Required Page
2 parents 1ec3e83 + 60f6b50 commit 0591b9c

5 files changed

Lines changed: 16 additions & 15 deletions

File tree

src/languages/en.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1534,7 +1534,7 @@ const translations = {
15341534
twoFactorAuthIsRequiredDescription: 'For security purposes, Xero requires two-factor authentication to connect the integration.',
15351535
twoFactorAuthIsRequiredForAdminsHeader: 'Two-factor authentication required',
15361536
twoFactorAuthIsRequiredForAdminsTitle: 'Please enable two-factor authentication',
1537-
twoFactorAuthIsRequiredForAdminsDescription: 'Your Xero accounting connection requires two-factor authentication. Please enable it to continue.',
1537+
twoFactorAuthIsRequiredForAdminsDescription: 'Your Xero accounting connection requires the use of two-factor authentication. To continue using Expensify, please enable it.',
15381538
twoFactorAuthCannotDisable: 'Cannot disable 2FA',
15391539
twoFactorAuthRequired: 'Two-factor authentication (2FA) is required for your Xero connection and cannot be disabled.',
15401540
},

src/languages/es.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1534,7 +1534,8 @@ const translations = {
15341534
twoFactorAuthIsRequiredDescription: 'Por razones de seguridad, Xero requiere la autenticación de dos factores para conectar la integración.',
15351535
twoFactorAuthIsRequiredForAdminsHeader: 'Autenticación de dos factores requerida',
15361536
twoFactorAuthIsRequiredForAdminsTitle: 'Por favor, habilita la autenticación de dos factores',
1537-
twoFactorAuthIsRequiredForAdminsDescription: 'Tu conexión de contabilidad con Xero requiere autenticación de dos factores. Por favor, habilítala para continuar.',
1537+
twoFactorAuthIsRequiredForAdminsDescription:
1538+
'Tu conexión de contabilidad con Xero requiere el uso de autenticación de dos factores. Por favor, habilítala para seguir usando Expensify.',
15381539
twoFactorAuthCannotDisable: 'No se puede desactivar la autenticación de dos factores (2FA)',
15391540
twoFactorAuthRequired: 'La autenticación de dos factores (2FA) es obligatoria para tu conexión a Xero y no se puede desactivar.',
15401541
},

src/pages/RequireTwoFactorAuthenticationPage.tsx

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import React from 'react';
22
import {View} from 'react-native';
33
import Button from '@components/Button';
4-
import HeaderWithBackButton from '@components/HeaderWithBackButton';
54
import Icon from '@components/Icon';
65
import {Encryption} from '@components/Icon/Illustrations';
76
import ScreenWrapper from '@components/ScreenWrapper';
@@ -18,22 +17,17 @@ function RequireTwoFactorAuthenticationPage() {
1817

1918
return (
2019
<ScreenWrapper testID={RequireTwoFactorAuthenticationPage.displayName}>
21-
<HeaderWithBackButton
22-
title={translate('twoFactorAuth.twoFactorAuthIsRequiredForAdminsHeader')}
23-
shouldShowBackButton={false}
24-
shouldDisplayHelpButton={false}
25-
/>
2620
<View style={[styles.twoFARequiredContainer]}>
27-
<View style={[styles.cardSectionIllustration, styles.alignItemsCenter]}>
21+
<View style={[styles.twoFAIllustration, styles.alignItemsCenter]}>
2822
<Icon
2923
src={Encryption}
30-
width={variables.modalTopIconHeight}
31-
height={variables.modalTopIconHeight}
24+
width={variables.twoFAIconHeight}
25+
height={variables.twoFAIconHeight}
3226
/>
3327
</View>
34-
<View style={[styles.mt5, styles.mh5]}>
35-
<View style={[styles.gap2, styles.mb10]}>
36-
<Text style={[styles.textHeadlineH1, styles.textAlignCenter]}>{translate('twoFactorAuth.twoFactorAuthIsRequiredForAdminsTitle')}</Text>
28+
<View style={[styles.mt2, styles.mh5, styles.dFlex, styles.alignItemsCenter]}>
29+
<View style={[styles.mb5]}>
30+
<Text style={[styles.textHeadlineH1, styles.textAlignCenter, styles.mv2]}>{translate('twoFactorAuth.twoFactorAuthIsRequiredForAdminsHeader')}</Text>
3731
<Text style={[styles.textSupporting, styles.textAlignCenter]}>{translate('twoFactorAuth.twoFactorAuthIsRequiredForAdminsDescription')}</Text>
3832
</View>
3933
<Button

src/styles/index.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4006,6 +4006,11 @@ const styles = (theme: ThemeColors) =>
40064006
height: variables.sectionIllustrationHeight,
40074007
},
40084008

4009+
twoFAIllustration: {
4010+
width: 'auto',
4011+
height: 140,
4012+
},
4013+
40094014
cardSectionTitle: {
40104015
fontSize: variables.fontSizeLarge,
40114016
lineHeight: variables.lineHeightXLarge,
@@ -5394,7 +5399,7 @@ const styles = (theme: ThemeColors) =>
53945399
},
53955400

53965401
twoFARequiredContainer: {
5397-
maxWidth: 350,
5402+
maxWidth: 520,
53985403
margin: 'auto',
53995404
},
54005405

src/styles/variables.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ export default {
138138
emptyListIconHeight: 144,
139139
modalTopIconWidth: 200,
140140
modalTopIconHeight: 164,
141+
twoFAIconHeight: 140,
141142
modalTopMediumIconHeight: 203,
142143
modalTopBigIconHeight: 244,
143144
modalWordmarkWidth: 154,

0 commit comments

Comments
 (0)