Files
inji-wallet/screens/Issuers/ConfirmationModal.tsx
abhip2565 bd90b342e0 [INJIMOB-3193]add preauth and credential offer support (#1949)
[INJIMOB-3058]temp commit2



[INJIMOB-3058]temp commit2



[INJIMOB-3058] add support for pre-auth flow by credential-offer



[INJIMOB-3187] animo working chcekpoint

Signed-off-by: Abhishek Paul <paul.apaul.abhishek.ap@gmail.com>
2025-06-04 14:46:07 +05:30

57 lines
1.9 KiB
TypeScript

import React from 'react';
import { Modal, View, Text, TouchableWithoutFeedback } from 'react-native';
import { Button } from '../../components/ui';
import { Theme } from '../../components/ui/styleUtils';
import { useTranslation } from 'react-i18next';
interface CancelDownloadModalProps {
visible: boolean;
onCancel: () => void;
onConfirm: () => void;
}
export const CancelDownloadModal: React.FC<CancelDownloadModalProps> = ({
visible,
onCancel,
onConfirm,
}) => {
const {t} = useTranslation('cancelDownloadModal');
return (
<Modal visible={visible} transparent={true} onRequestClose={onCancel}>
<TouchableWithoutFeedback onPress={null}>
<View
style={Theme.TransactionCodeScreenStyle.confirmationModalView}>
<TouchableWithoutFeedback>
<View
style={Theme.TransactionCodeScreenStyle.confirmationModalInnerView}>
<Text testID="cancelDownoadModalHeading" style={Theme.TransactionCodeScreenStyle.confirmationModalContentHeading}>
{t('heading')}
</Text>
<Text
testID='cancelDownoadModalSubHeading'
style={Theme.TransactionCodeScreenStyle.confirmationModalContentSubHeading}>
{t('subHeading')}
</Text>
<Button
testID="cancelDownloadModalNoButton"
styles={{ marginTop: 24 }}
type="gradient"
title={t('cancel')}
onPress={onCancel}
/>
<Button
testID='cancelDownloadModalYesButton'
styles={{ marginTop: 12, marginBottom: -20 }}
type="clear"
title={t('confirm')}
onPress={onConfirm}
/>
</View>
</TouchableWithoutFeedback>
</View>
</TouchableWithoutFeedback>
</Modal>
);
};