mirror of
https://github.com/mosip/inji-wallet.git
synced 2026-01-08 21:18:14 -05:00
* feat(INJI-364): add new ui for successful activation of VC * feat(INJI-364): update VC receive UI * feat(INJI-364): extract banner notification component * feat(INJI-364): re suse banner notification component * feat(INJI-364): add successfully share popup and translations * feat(INJI-364): use proper state for showing the success modal * fix(INJI-364): show activate popup in respective screens only * refactor(INJI-364): rename props * refactor(INJI-364): remove logs * fix(INJI-372): fix hindi translation * chore(INJI-364): update package-lock.json * refactor(INJI-364): add proper testID implementation for BannerNotification * refactor(INJI-364): remove unused imports * refactor(INJI-364): remove multiple state set * refactor(INJI-364): add missing testID * refactor(INJI-364): add missing testID * feat(INJI-364): add activated notification to esignet VC also * chore(INJI-364): update package-lock.json
59 lines
1.8 KiB
TypeScript
59 lines
1.8 KiB
TypeScript
import React from 'react';
|
|
import {useTranslation} from 'react-i18next';
|
|
import {Theme} from '../../components/ui/styleUtils';
|
|
import {Modal} from '../../components/ui/Modal';
|
|
import {Image} from 'react-native';
|
|
import {Column, Text} from '../../components/ui';
|
|
import {Button} from '../../components/ui';
|
|
import {useScanLayout} from './ScanLayoutController';
|
|
import {useSendVcScreen} from './SendVcScreenController';
|
|
import testIDProps from '../../shared/commonUtil';
|
|
|
|
export const SharingSuccessModal: React.FC<
|
|
SharingSuccessModalProps
|
|
> = props => {
|
|
const {t} = useTranslation('ScanScreen');
|
|
const scanLayoutController = useScanLayout();
|
|
const sendVcScreenController = useSendVcScreen();
|
|
|
|
return (
|
|
<React.Fragment>
|
|
<Modal
|
|
isVisible={props.isVisible}
|
|
showClose={false}
|
|
{...testIDProps(props.testId)}>
|
|
<Column
|
|
margin="64 0"
|
|
crossAlign="center"
|
|
style={Theme.SelectVcOverlayStyles.sharedSuccessfully}>
|
|
<Image source={Theme.SuccessLogo} height={22} width={22} />
|
|
<Text margin="20 0" style={Theme.TextStyles.bold} size={'large'}>
|
|
{t('ScanScreen:status.accepted.title')}
|
|
</Text>
|
|
<Text
|
|
align="center"
|
|
style={Theme.TextStyles.regular}
|
|
color={Theme.Colors.statusMessage}>
|
|
{t('ScanScreen:status.accepted.message')}
|
|
</Text>
|
|
<Text style={Theme.TextStyles.bold}>
|
|
{sendVcScreenController.receiverInfo.name}
|
|
</Text>
|
|
</Column>
|
|
<Column margin="0 0 0">
|
|
<Button
|
|
type="gradient"
|
|
title={t('ScanScreen:status.accepted.gotohome')}
|
|
onPress={scanLayoutController.DISMISS}
|
|
/>
|
|
</Column>
|
|
</Modal>
|
|
</React.Fragment>
|
|
);
|
|
};
|
|
|
|
interface SharingSuccessModalProps {
|
|
isVisible: boolean;
|
|
testId: string;
|
|
}
|