mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Pass "maxFeePerGas" to the <GasTiming> component from Swaps (#11684)
This commit is contained in:
parent
66eb4fb5a0
commit
24f5cc009b
@ -39,6 +39,7 @@ export default function FeeCard({
|
|||||||
chainId,
|
chainId,
|
||||||
EIP1559Network,
|
EIP1559Network,
|
||||||
maxPriorityFeePerGasDecGWEI,
|
maxPriorityFeePerGasDecGWEI,
|
||||||
|
maxFeePerGasDecGWEI,
|
||||||
}) {
|
}) {
|
||||||
const t = useContext(I18nContext);
|
const t = useContext(I18nContext);
|
||||||
|
|
||||||
@ -143,6 +144,7 @@ export default function FeeCard({
|
|||||||
subTitle={
|
subTitle={
|
||||||
<GasTiming
|
<GasTiming
|
||||||
maxPriorityFeePerGas={maxPriorityFeePerGasDecGWEI}
|
maxPriorityFeePerGas={maxPriorityFeePerGasDecGWEI}
|
||||||
|
maxFeePerGas={maxFeePerGasDecGWEI}
|
||||||
/>
|
/>
|
||||||
}
|
}
|
||||||
subText={
|
subText={
|
||||||
@ -304,4 +306,5 @@ FeeCard.propTypes = {
|
|||||||
chainId: PropTypes.string.isRequired,
|
chainId: PropTypes.string.isRequired,
|
||||||
EIP1559Network: PropTypes.bool.isRequired,
|
EIP1559Network: PropTypes.bool.isRequired,
|
||||||
maxPriorityFeePerGasDecGWEI: PropTypes.string,
|
maxPriorityFeePerGasDecGWEI: PropTypes.string,
|
||||||
|
maxFeePerGasDecGWEI: PropTypes.string,
|
||||||
};
|
};
|
||||||
|
@ -86,6 +86,7 @@ describe('FeeCard', () => {
|
|||||||
const props = createProps({
|
const props = createProps({
|
||||||
EIP1559Network: true,
|
EIP1559Network: true,
|
||||||
maxPriorityFeePerGasDecGWEI: '3',
|
maxPriorityFeePerGasDecGWEI: '3',
|
||||||
|
maxFeePerGasDecGWEI: '4',
|
||||||
});
|
});
|
||||||
const { getByText } = renderWithProvider(<FeeCard {...props} />, store);
|
const { getByText } = renderWithProvider(<FeeCard {...props} />, store);
|
||||||
expect(getByText('Using the best quote')).toBeInTheDocument();
|
expect(getByText('Using the best quote')).toBeInTheDocument();
|
||||||
|
@ -754,6 +754,7 @@ export default function ViewQuote() {
|
|||||||
chainId={chainId}
|
chainId={chainId}
|
||||||
EIP1559Network={EIP1559Network}
|
EIP1559Network={EIP1559Network}
|
||||||
maxPriorityFeePerGasDecGWEI={hexWEIToDecGWEI(maxPriorityFeePerGas)}
|
maxPriorityFeePerGasDecGWEI={hexWEIToDecGWEI(maxPriorityFeePerGas)}
|
||||||
|
maxFeePerGasDecGWEI={hexWEIToDecGWEI(maxFeePerGas)}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user