-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Draft: Network filter asset list integration #28095
Closed
gambinish
wants to merge
85
commits into
develop
from
feat/mmassets-432_network-filter-extension--integration--marketData
Closed
Draft: Network filter asset list integration #28095
gambinish
wants to merge
85
commits into
develop
from
feat/mmassets-432_network-filter-extension--integration--marketData
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…g custom filter logic
…om:MetaMask/metamask-extension into feat/mmassets-432_network-filter-extension
…om:MetaMask/metamask-extension into feat/mmassets-432_network-filter-extension
7 tasks
…--marketData' of github.com:MetaMask/metamask-extension into feat/mmassets-432_network-filter-extension--integration--marketData
darkwing
reviewed
Nov 11, 2024
@@ -68,6 +68,7 @@ type AssetPickerModalProps = { | |||
header: JSX.Element | string | null; | |||
isOpen: boolean; | |||
onClose: () => void; | |||
action?: 'send' | 'receive'; |
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.
Let's make these constants
Closing this in favor of this: #28386 |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
DO-NOT-MERGE
Pull requests that should not be merged
portfolio-view
Used for PRs and issues related to Q4 2024 portfolio view
team-assets
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Opening this PR in the hopes that it will be helpful in getting us on the same page. My proposal is that we use this as an integration branch for the multi chain asset list view. As patterns emerge, and backend polling updates are integrated, we can begin incrementally introducing this onto
develop
I think this is a really key feature that touches a lot of different things that are in flight.This branch includes several things:
marketData
here: fix: should not reset market data after switch network core#4832 to provide marketData across chains@jonybur You'll notice that we still are not including the native tokens in the lists. I think it would be great if we could find a good way to do this. We are currently only supporting a single native token on develop. I think we should have all the data we need to get this working and integrated into the list and would be a great next step.
You'll also notice that only the selected network icons are rendering. I think that may partially be fixed with this PR: #27724 but I haven't look too much into it.
There's also some weirdness when rendering token list after switching networks, but this might be related to how we are mocking the token balances.
How to run:
You will need to have core checked out to following commit:
401ba30f
Run
yarn && yarn build
In extension, resolve
@metamask/assets-controllers
tofile:../core/packages/assets-controllers
andyarn && FILTER_TOKENS_TOGGLE=1 yarn start
⏰ A couple of things to keep in mind:
marketData
should now get selected and appended as networks are changed. Note however, that we still are not preloading this market data for all chains when app first loads. This will be introduced with the polling updates. Workaround is to switch between your networks to load the requiredmarketData
You'll notice that erc20 balances are being mocked. This is because we are moving away from
useTokenTracker
. We will be introducing a new piece of statetokenBalances
that will represent the account => chainId => balance relationship for us. Until then, we are mocking this in the selector to unblock.Related issues
Manual testing steps
Screenshots/Recordings
Screen.Recording.2024-10-25.at.2.33.58.PM.mov
Pre-merge author checklist
Pre-merge reviewer checklist