-
Notifications
You must be signed in to change notification settings - Fork 581
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: Add AssetSelector
#3166
feat: Add AssetSelector
#3166
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3166 +/- ##
==========================================
+ Coverage 94.93% 94.98% +0.04%
==========================================
Files 508 510 +2
Lines 11219 11303 +84
Branches 1730 1750 +20
==========================================
+ Hits 10651 10736 +85
+ Misses 568 567 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
## Explanation This adds an action to the `MultichainAssetsController` called `getAssetMetada` which allows to get a specific asset Metadata. This allows us to get a specific metadata without having to pull the entire controller state. ## References * Related to MetaMask/snaps#3166 ## Changelog <!-- If you're making any consumer-facing changes, list those changes here as if you were updating a changelog, using the template below as a guide. (CATEGORY is one of BREAKING, ADDED, CHANGED, DEPRECATED, REMOVED, or FIXED. For security-related issues, follow the Security Advisory process.) Please take care to name the exact pieces of the API you've added or changed (e.g. types, interfaces, functions, or methods). If there are any breaking changes, make sure to offer a solution for consumers to follow once they upgrade to the changes. Finally, if you're only making changes to development scripts or tests, you may replace the template below with "None". --> ### `@metamask/assets-controller` - **ADDED**: Add `getAssetMetadata` action to `MultichainAssetsController`. ## Checklist - [ ] I've updated the test suite for new or updated code as appropriate - [ ] I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate - [ ] I've highlighted breaking changes using the "BREAKING" category above as appropriate - [ ] I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes
97d2969
to
c47feb1
Compare
packages/snaps-controllers/src/interface/SnapInterfaceController.test.tsx
Show resolved
Hide resolved
e1cbe37
to
bd0292b
Compare
packages/snaps-controllers/src/interface/SnapInterfaceController.ts
Outdated
Show resolved
Hide resolved
packages/snaps-controllers/src/interface/SnapInterfaceController.ts
Outdated
Show resolved
Hide resolved
packages/snaps-controllers/src/interface/SnapInterfaceController.ts
Outdated
Show resolved
Hide resolved
packages/snaps-controllers/src/interface/SnapInterfaceController.test.tsx
Show resolved
Hide resolved
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. Is there an extension PR up yet?
Working on it right now 🫡 |
Co-authored-by: Frederik Bolding <frederik.bolding@gmail.com>
… `CaipAccountIdsMatchedByAddressAndNamespaceStruct`
This adds a new component
AssetSelector
.Fixes: #3163