mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Only render tooltip component if swap network is disabled (#15733)
This commit is contained in:
parent
9cf401bb92
commit
e8232aa714
@ -165,15 +165,18 @@ const EthOverview = ({ className }) => {
|
||||
}
|
||||
}}
|
||||
label={t('swap')}
|
||||
tooltipRender={(contents) => (
|
||||
<Tooltip
|
||||
title={t('currentlyUnavailable')}
|
||||
position="bottom"
|
||||
disabled={isSwapsChain}
|
||||
>
|
||||
{contents}
|
||||
</Tooltip>
|
||||
)}
|
||||
tooltipRender={
|
||||
isSwapsChain
|
||||
? null
|
||||
: (contents) => (
|
||||
<Tooltip
|
||||
title={t('currentlyUnavailable')}
|
||||
position="bottom"
|
||||
>
|
||||
{contents}
|
||||
</Tooltip>
|
||||
)
|
||||
}
|
||||
/>
|
||||
</>
|
||||
}
|
||||
|
@ -143,15 +143,19 @@ const TokenOverview = ({ className, token }) => {
|
||||
}
|
||||
}}
|
||||
label={t('swap')}
|
||||
tooltipRender={(contents) => (
|
||||
<Tooltip
|
||||
title={t('currentlyUnavailable')}
|
||||
position="bottom"
|
||||
disabled={isSwapsChain}
|
||||
>
|
||||
{contents}
|
||||
</Tooltip>
|
||||
)}
|
||||
tooltipRender={
|
||||
isSwapsChain
|
||||
? null
|
||||
: (contents) => (
|
||||
<Tooltip
|
||||
title={t('currentlyUnavailable')}
|
||||
position="bottom"
|
||||
disabled={isSwapsChain}
|
||||
>
|
||||
{contents}
|
||||
</Tooltip>
|
||||
)
|
||||
}
|
||||
/>
|
||||
</>
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user