-
Notifications
You must be signed in to change notification settings - Fork 5.4k
fix: add connection status back #36423
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
✨ Files requiring CODEOWNER review ✨🔑 @MetaMask/accounts-engineers (11 files, +476 -108)
✅ @MetaMask/confirmations (2 files, +10 -0)
👨🔧 @MetaMask/core-extension-ux (2 files, +28 -4)
|
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Results generated automatically by MetaMask CI |
Builds ready [5e68fbd]
UI Startup Metrics (1246 ± 67 ms)
Benchmark value 1074 exceeds gate value 1070 for chrome browserify home mean load Benchmark value 1062 exceeds gate value 1061 for chrome browserify home mean domContentLoaded Benchmark value 260 exceeds gate value 10 for chrome browserify home mean backgroundConnect Benchmark value 28 exceeds gate value 23 for chrome browserify home mean firstReactRender Benchmark value 5 exceeds gate value 1 for chrome browserify home mean initialActions Benchmark value 1192 exceeds gate value 1190 for chrome browserify home p95 load Benchmark value 1189 exceeds gate value 1180 for chrome browserify home p95 domContentLoaded Benchmark value 283 exceeds gate value 18 for chrome browserify home p95 backgroundConnect Benchmark value 52 exceeds gate value 45 for chrome browserify home p95 firstReactRender Benchmark value 12 exceeds gate value 1.2 for chrome browserify home p95 initialActions Benchmark value 10 exceeds gate value 7 for chrome webpack home mean initialActions Benchmark value 2507 exceeds gate value 2454 for chrome webpack home p95 uiStartup Benchmark value 17 exceeds gate value 7 for chrome webpack home p95 initialActions Benchmark value 1410 exceeds gate value 1405 for firefox browserify home mean uiStartup Benchmark value 30 exceeds gate value 25 for firefox browserify home mean backgroundConnect Benchmark value 29 exceeds gate value 25 for firefox browserify home mean firstReactRender Benchmark value 5 exceeds gate value 1 for firefox browserify home mean initialActions Benchmark value 13 exceeds gate value 9 for firefox browserify home mean setupStore Benchmark value 225 exceeds gate value 195 for firefox browserify home p95 domInteractive Benchmark value 28 exceeds gate value 24 for firefox browserify home p95 getState Benchmark value 10 exceeds gate value 2 for firefox browserify home p95 initialActions Benchmark value 51 exceeds gate value 27 for firefox browserify home p95 setupStore Benchmark value 1624 exceeds gate value 1615 for firefox webpack home mean uiStartup Benchmark value 1384 exceeds gate value 1380 for firefox webpack home mean load Benchmark value 1383 exceeds gate value 1380 for firefox webpack home mean domContentLoaded Benchmark value 114 exceeds gate value 100 for firefox webpack home mean domInteractive Benchmark value 32 exceeds gate value 26 for firefox webpack home mean backgroundConnect Benchmark value 40 exceeds gate value 38 for firefox webpack home mean firstReactRender Benchmark value 4 exceeds gate value 1 for firefox webpack home mean initialActions Benchmark value 1361 exceeds gate value 1360 for firefox webpack home mean loadScripts Benchmark value 298 exceeds gate value 156 for firefox webpack home p95 domInteractive Benchmark value 6 exceeds gate value 2 for firefox webpack home p95 initialActions Sum of mean exceeds: 343ms | Sum of p95 exceeds: 568.8ms Sum of all benchmark exceeds: 911.8ms Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Results generated automatically by MetaMask CI |
Builds ready [2500cbf]
UI Startup Metrics (1246 ± 80 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
ui/components/multichain-accounts/multichain-account-list/multichain-account-list.tsx
Show resolved
Hide resolved
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Results generated automatically by MetaMask CI |
Builds ready [06240a3]
UI Startup Metrics (1273 ± 89 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Results generated automatically by MetaMask CI |
Builds ready [e72e6b1]
UI Startup Metrics (1319 ± 89 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
OGPoyraz
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Confirmation changes LGTM
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Results generated automatically by MetaMask CI |
Builds ready [c17d907]
UI Startup Metrics (1284 ± 91 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
vinnyhoward
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other than the Cursor bot remarks the PR looks good. Could we look into the issues flagged?
| <PreferredAvatar address={seedAddressIcon} /> | ||
| <ConnectedStatus | ||
| address={seedAddressIcon} | ||
| isActive={connectionStatus === STATUS_CONNECTED} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Logic for active account is it should be connected and is the most recent one. I mean if more than one account is connected. How ill we get the active state?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that logic is handled in multichain-account-list, for each account cell, like this:
`const isConnectedAccount = connectedAccountGroups.find(
(accountGroup) => accountGroup.id === groupId,
);
let connectedStatus:
| typeof STATUS_CONNECTED
| typeof STATUS_CONNECTED_TO_ANOTHER_ACCOUNT
| undefined;
if (showConnectionStatus) {
if (isConnectedAccount) {
if (selectedAccountGroupsSet.has(groupId as AccountGroupId)) {
connectedStatus = STATUS_CONNECTED;
} else {
connectedStatus = STATUS_CONNECTED_TO_ANOTHER_ACCOUNT;
}
}
}`
Unless I misunderstood what you're asking
NidhiKJha
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Left a small comment. Once addressed, will review it again
…nd update permitted addresses logic
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Results generated automatically by MetaMask CI |
Builds ready [127bdf6]
UI Startup Metrics (1266 ± 77 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Description
This PR adds back the connection indicators to the account avatar
Changelog
CHANGELOG entry: Re-add connection indicator to bip44 account cell
Related issues
Fixes: https://consensyssoftware.atlassian.net/browse/MUL-1087?atlOrigin=eyJpIjoiZWZlY2YxNTE3MjA1NDIwODlkOGYwMjdlOTBhNzU0MzUiLCJwIjoiaiJ9
https://consensyssoftware.atlassian.net/browse/TMCU-161
Manual testing steps
Screenshots/Recordings
Selected connected account

Selected not connected account

Unconnected dapp

Before
After
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Restores and wires connection indicators on multichain account avatars using current tab permissions, with list/page integration and comprehensive tests/stories.
MultichainAccountCell: ReplacesPreferredAvatarwithConnectedStatus; adds optionalconnectionStatusprop (STATUS_CONNECTED|STATUS_CONNECTED_TO_ANOTHER_ACCOUNT) to control badge; maintains selection/privacy behavior.MultichainAccountList: AddsshowConnectionStatusprop; derives permitted addresses fromgetAllPermittedAccountsForCurrentTab, maps to connected account groups viagetAccountGroupsByAddress, and passes computedconnectionStatusto eachMultichainAccountCell.AccountListpage: EnablesshowConnectionStatuswhen there are permitted accounts for the active tab.ConnectedStatus: Updated to support state2 viagetIsMultichainAccountsState2EnabledandgetAccountGroupsByAddress; determines connected/active vs connected-to-another and sets badge/tooltip accordingly.multichain-account-cellandmultichain-account-list; updates snapshots; injectsactiveTabin stories/tests; minor fixture updates (e.g.,send.test, confirmation util).Written by Cursor Bugbot for commit 127bdf6. This will update automatically on new commits. Configure here.