1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Working on some lint issues in 2 files. (#18633)

* Addressed some lint issues.

* Worked on the mentioned lint issue.

* Worked on the CRLF lint issues.

---------

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
Co-authored-by: George Marshall <george.marshall@consensys.net>
This commit is contained in:
Harsh Shukla 2023-05-08 19:25:25 +05:30 committed by GitHub
parent 1c199d3223
commit dd04913e7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 12 deletions

View File

@ -4,20 +4,19 @@ import { useSelector, useDispatch } from 'react-redux';
import { useTransactionEventFragment } from '../../../../hooks/useTransactionEventFragment';
import { EditGasModes } from '../../../../../shared/constants/gas';
import Box from '../../../ui/box';
import Typography from '../../../ui/typography';
import CheckBox from '../../../ui/check-box';
import {
DISPLAY,
FLEX_DIRECTION,
TextColor,
TypographyVariant,
TextVariant,
} from '../../../../helpers/constants/design-system';
import { getAdvancedGasFeeValues } from '../../../../selectors';
import { setAdvancedGasFee } from '../../../../store/actions';
import { useGasFeeContext } from '../../../../contexts/gasFee';
import { useAdvancedGasFeePopoverContext } from '../context';
import { useI18nContext } from '../../../../hooks/useI18nContext';
import { Text } from '../../../component-library';
const AdvancedGasFeeDefaults = () => {
const t = useI18nContext();
@ -87,8 +86,9 @@ const AdvancedGasFeeDefaults = () => {
onClick={handleUpdateDefaultSettings}
disabled={gasErrors.maxFeePerGas || gasErrors.maxPriorityFeePerGas}
/>
<Typography
variant={TypographyVariant.H7}
<Text
variant={TextVariant.bodySm}
as="h6"
color={TextColor.textAlternative}
margin={0}
>
@ -97,7 +97,7 @@ const AdvancedGasFeeDefaults = () => {
: t('advancedGasFeeDefaultOptIn', [
<strong key="default-value-change">{t('newValues')}</strong>,
])}
</Typography>
</Text>
</label>
</Box>
);

View File

@ -2,14 +2,14 @@ import React, { useEffect, useState } from 'react';
import { useGasFeeContext } from '../../../../contexts/gasFee';
import { bnGreaterThan, bnLessThan } from '../../../../helpers/utils/util';
import { TypographyVariant } from '../../../../helpers/constants/design-system';
import { TextVariant } from '../../../../helpers/constants/design-system';
import { useI18nContext } from '../../../../hooks/useI18nContext';
import { MAX_GAS_LIMIT_DEC } from '../../../../pages/send/send.constants';
import Button from '../../../ui/button';
import FormField from '../../../ui/form-field';
import Typography from '../../../ui/typography';
import { useAdvancedGasFeePopoverContext } from '../context';
import { Text } from '../../../component-library';
const validateGasLimit = (gasLimit, minimumGasLimitDec) => {
return bnLessThan(gasLimit, minimumGasLimitDec) ||
@ -58,9 +58,10 @@ const AdvancedGasFeeGasLimit = () => {
}
return (
<Typography
tag={TypographyVariant.paragraph}
variant={TypographyVariant.H7}
<Text
tag={TextVariant.bodyMd}
variant={TextVariant.bodySm}
as="h6"
className="advanced-gas-fee-gas-limit"
marginTop={4}
marginLeft={2}
@ -76,7 +77,7 @@ const AdvancedGasFeeGasLimit = () => {
>
{t('edit')}
</Button>
</Typography>
</Text>
);
};