Skip to content

Commit a6c67a4

Browse files
committed
rename the blocked view file
1 parent a7eb837 commit a6c67a4

4 files changed

Lines changed: 12 additions & 10 deletions

File tree

src/CONST/index.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1792,6 +1792,7 @@ const CONST = {
17921792
GATEWAY_TIMEOUT: 'Gateway Timeout',
17931793
EXPENSIFY_SERVICE_INTERRUPTED: 'Expensify service interrupted',
17941794
DUPLICATE_RECORD: 'A record already exists with this ID',
1795+
ONBOARDING_2FA_REQUIRED_ERROR_MESSAGE: '401 work account uses 2FA',
17951796

17961797
// The "Upgrade" is intentional as the 426 HTTP code means "Upgrade Required" and sent by the API. We use the "Update" language everywhere else in the front end when this gets returned.
17971798
UPDATE_REQUIRED: 'Upgrade Required',
@@ -7358,8 +7359,6 @@ const CONST = {
73587359
REGISTER_FOR_WEBINAR: 'registerForWebinar',
73597360
},
73607361

7361-
ONBOARDING_2FA_REQUIRED_ERROR_MESSAGE: '401 work account uses 2FA',
7362-
73637362
SCHEDULE_CALL_STATUS: {
73647363
CREATED: 'created',
73657364
RESCHEDULED: 'rescheduled',

src/components/OnboardingMergingAccountBlocked.tsx renamed to src/components/OnboardingMergingAccountBlockedView.tsx

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@ import BlockingView from './BlockingViews/BlockingView';
99
import Button from './Button';
1010
import {ToddBehindCloud} from './Icon/Illustrations';
1111

12-
type OnboardingMergingAccountBlockedProps = {
12+
type OnboardingMergingAccountBlockedViewProps = {
1313
// Work email to display in the subtitle
1414
workEmail: string | undefined;
1515
isVsb: boolean | undefined;
1616
};
17-
function OnboardingMergingAccountBlocked({workEmail, isVsb}: OnboardingMergingAccountBlockedProps) {
17+
18+
function OnboardingMergingAccountBlockedView({workEmail, isVsb}: OnboardingMergingAccountBlockedViewProps) {
1819
const styles = useThemeStyles();
1920
const {translate} = useLocalize();
2021
return (
@@ -45,4 +46,6 @@ function OnboardingMergingAccountBlocked({workEmail, isVsb}: OnboardingMergingAc
4546
);
4647
}
4748

48-
export default OnboardingMergingAccountBlocked;
49+
OnboardingMergingAccountBlockedView.displayName = 'OnboardingMergingAccountBlockedView';
50+
51+
export default OnboardingMergingAccountBlockedView;

src/pages/OnboardingWorkEmail/BaseOnboardingWorkEmail.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import HeaderWithBackButton from '@components/HeaderWithBackButton';
1212
import Icon from '@components/Icon';
1313
import * as Illustrations from '@components/Icon/Illustrations';
1414
import OfflineWithFeedback from '@components/OfflineWithFeedback';
15-
import OnboardingMergingAccountBlocked from '@components/OnboardingMergingAccountBlocked';
15+
import OnboardingMergingAccountBlockedView from '@components/OnboardingMergingAccountBlockedView';
1616
import ScreenWrapper from '@components/ScreenWrapper';
1717
import Text from '@components/Text';
1818
import TextInput from '@components/TextInput';
@@ -129,7 +129,7 @@ function BaseOnboardingWorkEmail({shouldUseNativeStyles}: BaseOnboardingWorkEmai
129129
},
130130
];
131131

132-
const isMergingAccountBlocked = onboardingErrorMessage === CONST.ONBOARDING_2FA_REQUIRED_ERROR_MESSAGE;
132+
const isMergingAccountBlocked = onboardingErrorMessage === CONST.ERROR.ONBOARDING_2FA_REQUIRED_ERROR_MESSAGE;
133133

134134
return (
135135
<ScreenWrapper
@@ -144,7 +144,7 @@ function BaseOnboardingWorkEmail({shouldUseNativeStyles}: BaseOnboardingWorkEmai
144144
/>
145145
{isMergingAccountBlocked ? (
146146
<View style={[styles.flex1, onboardingIsMediumOrLargerScreenWidth && styles.mt5, onboardingIsMediumOrLargerScreenWidth ? styles.mh8 : styles.mh5]}>
147-
<OnboardingMergingAccountBlocked
147+
<OnboardingMergingAccountBlockedView
148148
workEmail={workEmail}
149149
isVsb={isVsb}
150150
/>

src/pages/OnboardingWorkEmailValidation/BaseOnboardingWorkEmailValidation.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import React, {useCallback, useEffect} from 'react';
33
import {View} from 'react-native';
44
import {useOnyx} from 'react-native-onyx';
55
import HeaderWithBackButton from '@components/HeaderWithBackButton';
6-
import OnboardingMergingAccountBlocked from '@components/OnboardingMergingAccountBlocked';
6+
import OnboardingMergingAccountBlockedView from '@components/OnboardingMergingAccountBlockedView';
77
import ScreenWrapper from '@components/ScreenWrapper';
88
import Text from '@components/Text';
99
import ValidateCodeForm from '@components/ValidateCodeActionModal/ValidateCodeForm';
@@ -92,7 +92,7 @@ function BaseOnboardingWorkEmailValidation({shouldUseNativeStyles}: BaseOnboardi
9292
/>
9393
{onboardingValues?.isMergingAccountBlocked ? (
9494
<View style={[styles.flex1, onboardingIsMediumOrLargerScreenWidth && styles.mt5, onboardingIsMediumOrLargerScreenWidth ? styles.mh8 : styles.mh5]}>
95-
<OnboardingMergingAccountBlocked
95+
<OnboardingMergingAccountBlockedView
9696
workEmail={workEmail}
9797
isVsb={isVsb}
9898
/>

0 commit comments

Comments
 (0)