refactor: migrate WalletDetails to design-system-react-native#30074
Conversation
WalletDetails to design-system-react-native
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection:
Performance Test Selection: |
|
| const mockInitialState: Partial<RootState> = { | ||
| settings: { | ||
| avatarAccountType: AvatarAccountType.Maskicon, | ||
| avatarAccountType: 'Maskicon', |
There was a problem hiding this comment.
Do we have this value as a const somewhere else so we can use it here instead of having string literal? 🤔
There was a problem hiding this comment.
technically no, the value in the DS is all lowercase meanwhile the value we need is Maskicon cc @MetaMask/design-system



Description
WalletDetails,BaseWalletDetailsandAddAccountItemimports from deprecated component-library components to@metamask/design-system-react-nativenamed imports.ButtonLinkback button with HeaderBasestartButtonIconProps.BaseWalletDetailstest to avoid importing the deprecatedAvatarAccountTypeenum.Changelog
CHANGELOG entry: null
Related issues
Refs: https://consensyssoftware.atlassian.net/browse/MUL-1690
Manual testing steps
Screenshots/Recordings
Pre-merge author checklist
Performance checks (if applicable)
trace()for usage andaddTokenfor an exampleFor performance guidelines and tooling, see the Performance Guide.
Pre-merge reviewer checklist
Note
Low Risk
Low risk UI refactor that primarily swaps component imports/props and updates tests; main risk is minor visual/accessibility regressions from design-system prop/variant changes.
Overview
Migrates
BaseWalletDetailsandAddAccountItemfrom deprecated component-libraryText/Icon/HeaderBase/ButtonLinkusage to@metamask/design-system-react-native, including updated typography variants, colors, and icon color tokens.Replaces the custom back
ButtonLinkwithHeaderBasestartButtonIconProps(addsaccessibilityLabel) and convertsAddAccountItemto a named export, updating imports accordingly.Updates
BaseWalletDetailstests to avoid importing deprecatedAvatarAccountTypeby using the'Maskicon'literal in initial state.Reviewed by Cursor Bugbot for commit f97a1b2. Bugbot is set up for automated code reviews on this repo. Configure here.