Skip to content

Commit

Permalink
Address feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
pedronfigueiredo committed Sep 5, 2024
1 parent ec9c7ad commit 912ccef
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 28 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export const ApproveStaticSimulation = () => {
</Text>
);

const simulationElements = (
const SpendingCapRow = (
<ConfirmInfoRow
label={isNFT ? t('simulationApproveHeading') : t('spendingCap')}
>
Expand Down Expand Up @@ -93,6 +93,8 @@ export const ApproveStaticSimulation = () => {
</ConfirmInfoRow>
);

const simulationElements = SpendingCapRow;

return (
<StaticSimulation
title={t('simulationDetailsTitle')}
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -16,29 +16,36 @@ export const RevokeStaticSimulation = () => {
currentConfirmation: TransactionMeta;
};

const simulationElements = (
<>
<ConfirmInfoRow label={t('spendingCap')}>
<Box style={{ marginLeft: 'auto', maxWidth: '100%' }}>
<Box display={Display.Flex}>
<Name
value={transactionMeta.txParams.to as string}
type={NameType.ETHEREUM_ADDRESS}
/>
</Box>
const TokenContractRow = (
<ConfirmInfoRow label={t('spendingCap')}>
<Box style={{ marginLeft: 'auto', maxWidth: '100%' }}>
<Box display={Display.Flex}>
<Name
value={transactionMeta.txParams.to as string}
type={NameType.ETHEREUM_ADDRESS}
/>
</Box>
</ConfirmInfoRow>
</Box>
</ConfirmInfoRow>
);

<ConfirmInfoRow label={t('spender')}>
<Box style={{ marginLeft: 'auto', maxWidth: '100%' }}>
<Box display={Display.Flex}>
<Name
value={transactionMeta.txParams.from as string}
type={NameType.ETHEREUM_ADDRESS}
/>
</Box>
const SpenderRow = (
<ConfirmInfoRow label={t('spender')}>
<Box style={{ marginLeft: 'auto', maxWidth: '100%' }}>
<Box display={Display.Flex}>
<Name
value={transactionMeta.txParams.from as string}
type={NameType.ETHEREUM_ADDRESS}
/>
</Box>
</ConfirmInfoRow>
</Box>
</ConfirmInfoRow>
);

const simulationElements = (
<>
{TokenContractRow}
{SpenderRow}
</>
);

Expand Down

0 comments on commit 912ccef

Please sign in to comment.