mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
parent
cfc653ada6
commit
c5954e73ec
@ -5,6 +5,7 @@ import { useSelector } from 'react-redux';
|
|||||||
import { toChecksumHexAddress } from '../../../../shared/modules/hexstring-utils';
|
import { toChecksumHexAddress } from '../../../../shared/modules/hexstring-utils';
|
||||||
import { getSelectedIdentity } from '../../../selectors';
|
import { getSelectedIdentity } from '../../../selectors';
|
||||||
import { AddressCopyButton } from '../../multichain';
|
import { AddressCopyButton } from '../../multichain';
|
||||||
|
import Box from '../../ui/box/box';
|
||||||
|
|
||||||
const WalletOverview = ({ balance, buttons, className, icon, loading }) => {
|
const WalletOverview = ({ balance, buttons, className, icon, loading }) => {
|
||||||
const selectedIdentity = useSelector(getSelectedIdentity);
|
const selectedIdentity = useSelector(getSelectedIdentity);
|
||||||
@ -13,7 +14,9 @@ const WalletOverview = ({ balance, buttons, className, icon, loading }) => {
|
|||||||
<div className={classnames('wallet-overview', className)}>
|
<div className={classnames('wallet-overview', className)}>
|
||||||
<div className="wallet-overview__balance">
|
<div className="wallet-overview__balance">
|
||||||
{process.env.MULTICHAIN ? (
|
{process.env.MULTICHAIN ? (
|
||||||
|
<Box marginTop={2}>
|
||||||
<AddressCopyButton address={checksummedAddress} shorten />
|
<AddressCopyButton address={checksummedAddress} shorten />
|
||||||
|
</Box>
|
||||||
) : (
|
) : (
|
||||||
<>{loading ? null : icon}</>
|
<>{loading ? null : icon}</>
|
||||||
)}
|
)}
|
||||||
|
@ -38,7 +38,7 @@ export const AddressCopyButton = ({
|
|||||||
paddingRight={4}
|
paddingRight={4}
|
||||||
paddingLeft={4}
|
paddingLeft={4}
|
||||||
size={Size.SM}
|
size={Size.SM}
|
||||||
variant={TextVariant.bodyXs}
|
variant={TextVariant.bodySm}
|
||||||
color={TextColor.primaryDefault}
|
color={TextColor.primaryDefault}
|
||||||
endIconName={copied ? ICON_NAMES.COPY_SUCCESS : ICON_NAMES.COPY}
|
endIconName={copied ? ICON_NAMES.COPY_SUCCESS : ICON_NAMES.COPY}
|
||||||
className={classnames('multichain-address-copy-button', {
|
className={classnames('multichain-address-copy-button', {
|
||||||
|
Loading…
Reference in New Issue
Block a user