2021-11-18 19:30:56 +01:00
|
|
|
import React from 'react';
|
2021-12-14 00:41:10 +01:00
|
|
|
import { useHistory } from 'react-router-dom';
|
2023-07-17 17:58:36 +02:00
|
|
|
import { BannerAlert } from '../../component-library';
|
2021-11-18 19:30:56 +01:00
|
|
|
import { useI18nContext } from '../../../hooks/useI18nContext';
|
2021-12-14 00:41:10 +01:00
|
|
|
import { EXPERIMENTAL_ROUTE } from '../../../helpers/constants/routes';
|
2021-11-18 19:30:56 +01:00
|
|
|
|
2023-02-16 20:23:29 +01:00
|
|
|
export default function NftsDetectionNotice() {
|
2021-11-18 19:30:56 +01:00
|
|
|
const t = useI18nContext();
|
2021-12-14 00:41:10 +01:00
|
|
|
const history = useHistory();
|
2021-11-18 19:30:56 +01:00
|
|
|
|
|
|
|
return (
|
2023-07-17 17:58:36 +02:00
|
|
|
<BannerAlert
|
|
|
|
className="nfts-detection-notice"
|
|
|
|
title={t('newNFTsDetected')}
|
|
|
|
actionButtonLabel={t('selectNFTPrivacyPreference')}
|
|
|
|
actionButtonOnClick={(e) => {
|
|
|
|
e.preventDefault();
|
|
|
|
history.push(`${EXPERIMENTAL_ROUTE}#autodetect-nfts`);
|
|
|
|
}}
|
|
|
|
>
|
|
|
|
{t('newNFTDetectedMessage')}
|
|
|
|
</BannerAlert>
|
2021-11-18 19:30:56 +01:00
|
|
|
);
|
|
|
|
}
|