-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
chore(runway): cherry-pick fix: fix recipient account icons cp-7.60.0 #23375
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
chore(runway): cherry-pick fix: fix recipient account icons cp-7.60.0 #23375
Conversation
…#23362) ## **Description** The icon being used for each recipient addresses was not re-using their account group icons (we use the EVM address of a multichain account group as the seed of account's icons). This PR fixes this while keeping the original `recipient.address` as a fallback (which should never happen anyway). ## **Changelog** CHANGELOG entry: Fix account's icons for send flows ## **Related issues** Fixes: - #22806 ## **Manual testing steps** ```gherkin Feature: Send non-EVM token Scenario: user starts a send flow for Solana Given the user has funds When user selects the recipient address Then he should see the same icons than the one used for the account list ``` ## **Screenshots/Recordings** ### **Before** https://github.com/user-attachments/assets/100969c2-15e9-49c4-a2f3-cd24aac8e839 <img width="382" height="192" alt="Screenshot 2025-11-27 at 13 28 36" src="https://github.com/user-attachments/assets/53225dd9-8e47-4788-850e-09579c312e96" /> <img width="377" height="250" alt="Screenshot 2025-11-27 at 13 28 22" src="https://github.com/user-attachments/assets/07e5b9aa-4a1c-44ff-ac6a-402a0712bd1a" /> ### **After** https://github.com/user-attachments/assets/221c05e4-b040-4583-b81f-de674f716db1 <img width="385" height="220" alt="Screenshot 2025-11-27 at 13 29 52" src="https://github.com/user-attachments/assets/02b959f4-7334-454f-8939-931054f68bf3" /> <img width="383" height="194" alt="Screenshot 2025-11-27 at 13 29 36" src="https://github.com/user-attachments/assets/a1eb109d-e74a-4de2-9844-ec5675e565c3" /> ## **Pre-merge author checklist** - [ ] I’ve followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile Coding Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md). - [ ] I've completed the PR template to the best of my ability - [ ] I’ve included tests if applicable - [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [ ] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots. <!-- CURSOR_SUMMARY --> --- > [!NOTE] > Recipient avatars now derive from the account group’s icon seed (with address fallback), and useAccounts returns accountGroupId; tests updated accordingly. > > - **UI (recipient)**: > - Avatar `accountAddress` now sourced from account group icon seed via `selectIconSeedAddressByAccountGroupId`, with fallback to `recipient.address`. > - `RecipientType` extended with `accountGroupId`; Redux selector added to compute avatar seed. > - **Hooks**: > - `useAccounts` now includes `accountGroupId` in returned recipient objects. > - **Tests**: > - Updated `useAccounts.test.ts` expectations to include `accountGroupId` across EVM, Solana, Bitcoin, and Tron cases. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit bcc1017. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
|
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. |
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsFallback: AI analysis did not complete successfully. Running all tests. |
| } catch { | ||
| return recipient.address; | ||
| } | ||
| }); |
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.
Bug: Selector recreated on every render causing performance issues
The selector selectIconSeedAddressByAccountGroupId is created inside the useSelector callback without memoization, causing a new selector instance to be created on every render. This defeats the selector's memoization and causes unnecessary recomputations. The selector should be created using useMemo with recipient.accountGroupId as a dependency, then passed to useSelector, following the pattern used in AccountCell.tsx.
|
|
No release label on PR. Adding release label release-7.60.0 on PR, as PR was cherry-picked in branch 7.60.0. |


Description
The icon being used for each recipient addresses was not re-using their
account group icons (we use the EVM address of a multichain account
group as the seed of account's icons).
This PR fixes this while keeping the original
recipient.addressas afallback (which should never happen anyway).
Changelog
CHANGELOG entry: Fix account's icons for send flows
Related issues
Fixes:
Manual testing steps
Screenshots/Recordings
Before
Simulator.Screen.Recording.-.iPhone.16.Plus.-.2025-11-27.at.13.25.36.mov
After
Simulator.Screen.Recording.-.iPhone.16.Plus.-.2025-11-27.at.13.14.06.mov
Pre-merge author checklist
Docs and MetaMask Mobile
Coding
Standards.
if applicable
guidelines).
Not required for external contributors.
Pre-merge reviewer checklist
app, test code being changed).
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.
Note
Recipient avatars now use the account group’s icon seed with address fallback; useAccounts adds accountGroupId and tests updated accordingly.
app/components/Views/confirmations/components/UI/recipient/recipient.tsxaccountAddressnow sourced from account group seed viaselectIconSeedAddressByAccountGroupId(recipient.accountGroupId)with fallback torecipient.address.AccountGroupIdtyping.app/components/Views/confirmations/hooks/send/useAccounts.tsaccountGroupIdin returned recipient objects.useAccounts.test.tsexpectations updated to includeaccountGroupIdacross EVM, Solana, Bitcoin, and Tron cases.Written by Cursor Bugbot for commit f41df4d. This will update automatically on new commits. Configure here.
0f7ac87