1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-22 01:47:00 +01:00

UX: Multichain: Only show the account picker with a selected identity (#19236)

This commit is contained in:
David Walsh 2023-05-23 14:44:24 -05:00 committed by GitHub
parent 627ff3c0ad
commit c5a35b70c7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -219,22 +219,24 @@ export const AppHeader = ({ location }) => {
/>
) : null}
<AccountPicker
address={identity.address}
name={identity.name}
onClick={() => {
dispatch(toggleAccountMenu());
{identity ? (
<AccountPicker
address={identity.address}
name={identity.name}
onClick={() => {
dispatch(toggleAccountMenu());
trackEvent({
event: MetaMetricsEventName.NavAccountMenuOpened,
category: MetaMetricsEventCategory.Navigation,
properties: {
location: 'Home',
},
});
}}
disabled={disablePickers}
/>
trackEvent({
event: MetaMetricsEventName.NavAccountMenuOpened,
category: MetaMetricsEventCategory.Navigation,
properties: {
location: 'Home',
},
});
}}
disabled={disablePickers}
/>
) : null}
<Box
display={DISPLAY.FLEX}
alignItems={AlignItems.center}