Skip to content

Commit

Permalink
Merge pull request #41975 from Krishna2323/krishna2323/issue/41252
Browse files Browse the repository at this point in the history
fix: [Held requests] Approval popup for a report with hold expense has X Close option it.
  • Loading branch information
cristipaval authored May 13, 2024
2 parents a9ffa4e + e33fc84 commit 3cc5152
Showing 1 changed file with 0 additions and 22 deletions.
22 changes: 0 additions & 22 deletions src/components/DecisionModal.tsx
Original file line number Diff line number Diff line change
@@ -1,17 +1,11 @@
import React from 'react';
import {View} from 'react-native';
import useLocalize from '@hooks/useLocalize';
import useTheme from '@hooks/useTheme';
import useThemeStyles from '@hooks/useThemeStyles';
import CONST from '@src/CONST';
import Button from './Button';
import Header from './Header';
import Icon from './Icon';
import * as Expensicons from './Icon/Expensicons';
import Modal from './Modal';
import PressableWithoutFeedback from './Pressable/PressableWithoutFeedback';
import Text from './Text';
import Tooltip from './Tooltip';

type DecisionModalProps = {
/** Title describing purpose of modal */
Expand Down Expand Up @@ -43,8 +37,6 @@ type DecisionModalProps = {
};

function DecisionModal({title, prompt = '', firstOptionText, secondOptionText, onFirstOptionSubmit, onSecondOptionSubmit, isSmallScreenWidth, onClose, isVisible}: DecisionModalProps) {
const {translate} = useLocalize();
const theme = useTheme();
const styles = useThemeStyles();

return (
Expand All @@ -60,21 +52,7 @@ function DecisionModal({title, prompt = '', firstOptionText, secondOptionText, o
title={title}
containerStyles={[styles.alignItemsCenter]}
/>
<Tooltip text={translate('common.close')}>
<PressableWithoutFeedback
onPress={onClose}
style={[styles.touchableButtonImage]}
accessibilityRole={CONST.ACCESSIBILITY_ROLE.BUTTON}
accessibilityLabel={translate('common.close')}
>
<Icon
src={Expensicons.Close}
fill={theme.icon}
/>
</PressableWithoutFeedback>
</Tooltip>
</View>

<Text>{prompt}</Text>
</View>
{firstOptionText && (
Expand Down

0 comments on commit 3cc5152

Please sign in to comment.