-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #52614 from callstack-internal/feat/50902-GR-step-…
…6-agreements-and-finish-screen Feat/50902 gr step 6 agreements and finish screen
- Loading branch information
Showing
8 changed files
with
216 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
94 changes: 93 additions & 1 deletion
94
src/pages/ReimbursementAccount/NonUSD/Agreements/substeps/Confirmation.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
import React from 'react'; | ||
import {View} from 'react-native'; | ||
import {useOnyx} from 'react-native-onyx'; | ||
import Button from '@components/Button'; | ||
import HeaderWithBackButton from '@components/HeaderWithBackButton'; | ||
import * as Expensicons from '@components/Icon/Expensicons'; | ||
import * as Illustrations from '@components/Icon/Illustrations'; | ||
import ScreenWrapper from '@components/ScreenWrapper'; | ||
import ScrollView from '@components/ScrollView'; | ||
import Section from '@components/Section'; | ||
import Text from '@components/Text'; | ||
import useLocalize from '@hooks/useLocalize'; | ||
import useThemeStyles from '@hooks/useThemeStyles'; | ||
import Navigation from '@navigation/Navigation'; | ||
import * as Report from '@userActions/Report'; | ||
import ONYXKEYS from '@src/ONYXKEYS'; | ||
import ROUTES from '@src/ROUTES'; | ||
|
||
function Finish() { | ||
const styles = useThemeStyles(); | ||
const {translate} = useLocalize(); | ||
|
||
const [reimbursementAccount] = useOnyx(ONYXKEYS.REIMBURSEMENT_ACCOUNT); | ||
const policyID = reimbursementAccount?.achData?.policyID ?? '-1'; | ||
|
||
const handleBackButtonPress = () => { | ||
Navigation.goBack(); | ||
}; | ||
const handleNavigateToConciergeChat = () => Report.navigateToConciergeChat(true); | ||
|
||
return ( | ||
<ScreenWrapper | ||
testID={Finish.displayName} | ||
includeSafeAreaPaddingBottom={false} | ||
shouldEnablePickerAvoiding={false} | ||
shouldEnableMaxHeight | ||
> | ||
<HeaderWithBackButton | ||
title={translate('finishStep.connect')} | ||
onBackButtonPress={handleBackButtonPress} | ||
/> | ||
<ScrollView style={[styles.flex1]}> | ||
<Section | ||
title={translate('finishStep.letsFinish')} | ||
icon={Illustrations.ConciergeBubble} | ||
containerStyles={[styles.mb8, styles.mh5]} | ||
titleStyles={[styles.mb3, styles.textHeadline]} | ||
> | ||
<Text style={[styles.mb6, styles.mt3, styles.textLabelSupportingEmptyValue]}>{translate('finishStep.thanksFor')}</Text> | ||
<Button | ||
text={translate('finishStep.iHaveA')} | ||
onPress={handleNavigateToConciergeChat} | ||
icon={Expensicons.ChatBubble} | ||
success | ||
large | ||
innerStyles={[styles.h13]} | ||
/> | ||
</Section> | ||
<Section | ||
title={translate('finishStep.enable2FA')} | ||
icon={Illustrations.ShieldYellow} | ||
titleStyles={[styles.mb4, styles.textHeadline]} | ||
containerStyles={[styles.mh5]} | ||
menuItems={[ | ||
{ | ||
title: translate('finishStep.secure'), | ||
onPress: () => { | ||
Navigation.navigate(ROUTES.SETTINGS_2FA.getRoute(ROUTES.BANK_ACCOUNT_WITH_STEP_TO_OPEN.getRoute('', policyID))); | ||
}, | ||
icon: Expensicons.Shield, | ||
shouldShowRightIcon: true, | ||
iconRight: Expensicons.NewWindow, | ||
wrapperStyle: [styles.cardMenuItem], | ||
}, | ||
]} | ||
> | ||
<View style={styles.mb6}> | ||
<Text style={[styles.mt3, styles.textLabelSupportingEmptyValue]}>{translate('finishStep.weTake')}</Text> | ||
</View> | ||
</Section> | ||
</ScrollView> | ||
</ScreenWrapper> | ||
); | ||
} | ||
|
||
Finish.displayName = 'Finish'; | ||
|
||
export default Finish; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters