MetaMask / metamask-mobile

Mobile web browser providing access to websites that use the Ethereum blockchain
https://metamask.io
Other
2.04k stars 1.06k forks source link

feat: add account display component #10030

Closed mirceanis closed 1 week ago

mirceanis commented 2 weeks ago

Description

This adds a component that can display the stylized address and account label for the currently selected account. The component gets used in the ReceiveRequest QR code view.

This PR also updates the unit tests and related snapshots for the ReceiveRequest view, as the previous unit tests didn't validate the correct snapshot.

Related issues

Fixes: https://github.com/MetaMask/MetaMask-planning/issues/2574 This is part of the https://github.com/MetaMask/MetaMask-planning/issues/2384 epic

The final component depends on some typography fixes from this PR.

Manual testing steps

  1. From the home screen, open the bottom drawer
  2. Pick Receive
  3. Observe the Account label and stylized address and copy button under the QR code.

Screenshots/Recordings

Before

Screenshot 2024-06-18 at 13 00 39

After

new fonts

Pre-merge author checklist

Pre-merge reviewer checklist

github-actions[bot] commented 2 weeks ago

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.

sonarcloud[bot] commented 2 weeks ago

Quality Gate Passed Quality Gate passed

Issues
4 New issues
0 Accepted issues

Measures
0 Security Hotspots
83.3% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

mirceanis commented 1 week ago

changes were cherry picked in https://github.com/MetaMask/metamask-mobile/pull/10061