mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-23 10:30:04 +01:00
33cc8d587a
* replaced all the instances of collectibles with nfts * updated actions * updated e2e seeder * updated confirm Approve test * updated test dapp change * updated test dapp change * nit fix * nit fix * updated casing and snapshots * updated casinG * added migrations * updated ,igration * updated 078.test * updated tests for 078 migration * updated migration * updated 078 index.js
67 lines
2.0 KiB
JavaScript
67 lines
2.0 KiB
JavaScript
import React from 'react';
|
|
import { useHistory } from 'react-router-dom';
|
|
import Box from '../../ui/box';
|
|
import Dialog from '../../ui/dialog';
|
|
import Typography from '../../ui/typography/typography';
|
|
import {
|
|
TypographyVariant,
|
|
TEXT_ALIGN,
|
|
FONT_WEIGHT,
|
|
DISPLAY,
|
|
TextColor,
|
|
} from '../../../helpers/constants/design-system';
|
|
import { useI18nContext } from '../../../hooks/useI18nContext';
|
|
import Button from '../../ui/button';
|
|
import { EXPERIMENTAL_ROUTE } from '../../../helpers/constants/routes';
|
|
|
|
export default function NftsDetectionNotice() {
|
|
const t = useI18nContext();
|
|
const history = useHistory();
|
|
|
|
return (
|
|
<Box className="nfts-detection-notice">
|
|
<Dialog type="message" className="nfts-detection-notice__message">
|
|
<Box display={DISPLAY.FLEX}>
|
|
<Box paddingTop={1}>
|
|
<i
|
|
style={{
|
|
fontSize: '1rem',
|
|
color: 'var(--color-primary-default)',
|
|
}}
|
|
className="fa fa-info-circle"
|
|
/>
|
|
</Box>
|
|
<Box paddingLeft={2}>
|
|
<Typography
|
|
color={TextColor.textDefault}
|
|
align={TEXT_ALIGN.LEFT}
|
|
variant={TypographyVariant.H7}
|
|
fontWeight={FONT_WEIGHT.BOLD}
|
|
>
|
|
{t('newNFTsDetected')}
|
|
</Typography>
|
|
<Typography
|
|
color={TextColor.textDefault}
|
|
align={TEXT_ALIGN.LEFT}
|
|
variant={TypographyVariant.H7}
|
|
boxProps={{ marginBottom: 4 }}
|
|
>
|
|
{t('newNFTDetectedMessage')}
|
|
</Typography>
|
|
<Button
|
|
type="link"
|
|
onClick={(e) => {
|
|
e.preventDefault();
|
|
history.push(`${EXPERIMENTAL_ROUTE}#autodetect-nfts`);
|
|
}}
|
|
className="nfts-detection-notice__message__link"
|
|
>
|
|
{t('selectNFTPrivacyPreference')}
|
|
</Button>
|
|
</Box>
|
|
</Box>
|
|
</Dialog>
|
|
</Box>
|
|
);
|
|
}
|