diff --git a/common/components/WalletDecrypt/Web3.tsx b/common/components/WalletDecrypt/Web3.tsx index cadd7da8ddc..f2edeae6c94 100644 --- a/common/components/WalletDecrypt/Web3.tsx +++ b/common/components/WalletDecrypt/Web3.tsx @@ -1,5 +1,6 @@ import React, { Component } from 'react'; import translate from 'translations'; +import { NewTabLink } from 'components/ui'; import './Web3.scss'; interface Props { @@ -20,14 +21,11 @@ export default class Web3Decrypt extends Component {
- - {translate('Download MetaMask')} - + />
); diff --git a/common/components/ui/NewTabLink.tsx b/common/components/ui/NewTabLink.tsx index 520986fedb6..fa74a270e34 100644 --- a/common/components/ui/NewTabLink.tsx +++ b/common/components/ui/NewTabLink.tsx @@ -2,6 +2,7 @@ import React from 'react'; interface AAttributes { charset?: string; + className?: string; coords?: string; download?: string; href: string; @@ -28,14 +29,15 @@ interface AAttributes { type?: string; } -interface NewTabLinkProps extends AAttributes { +interface NewTabLinkProps extends AAttributes { content?: React.ReactElement | string; children?: React.ReactElement | string; } -const NewTabLink = ({ content, children, ...rest }: NewTabLinkProps) => +const NewTabLink = ({ content, children, ...rest }: NewTabLinkProps) => ( {content || children} {/* Keep content for short-hand text insertion */} - ; + +); export default NewTabLink;