Skip to content
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

feat: AccountSelector #3088

Draft
wants to merge 10 commits into
base: main
Choose a base branch
from
Draft

feat: AccountSelector #3088

wants to merge 10 commits into from

Conversation

GuillaumeRx
Copy link
Contributor

@GuillaumeRx GuillaumeRx commented Feb 12, 2025

This PR adds a new component called AccountSelector.

This component uses the account list of the client to display and select an account. The list can be filtered via the component props.

Progresses: #2810

Copy link

socket-security bot commented Feb 12, 2025

New dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@metamask/[email protected] Transitive: environment +7 809 kB metamaskbot

View full report↗︎

Copy link

codecov bot commented Feb 12, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.90%. Comparing base (c37ba73) to head (23230f6).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3088      +/-   ##
==========================================
+ Coverage   94.88%   94.90%   +0.01%     
==========================================
  Files         506      508       +2     
  Lines       11123    11162      +39     
  Branches     1709     1717       +8     
==========================================
+ Hits        10554    10593      +39     
  Misses        569      569              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

packages/snaps-controllers/src/interface/utils.ts Outdated Show resolved Hide resolved
packages/snaps-controllers/src/interface/utils.ts Outdated Show resolved Hide resolved
packages/snaps-controllers/src/test-utils/controller.ts Outdated Show resolved Hide resolved
{
name: string(),
hideExternalAccounts: optional(boolean()),
chainIds: optional(array(CaipChainIdStruct)) as unknown as Struct<
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this need a type cast?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

packages/snaps-utils/src/address.ts Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants