-
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
feat: Sort/Import Tokens in Extension #27184
Merged
gambinish
merged 210 commits into
develop
from
feat/mmassets-356_sort-import-tokens-extension--persistence-telemetry
Oct 8, 2024
Merged
feat: Sort/Import Tokens in Extension #27184
gambinish
merged 210 commits into
develop
from
feat/mmassets-356_sort-import-tokens-extension--persistence-telemetry
Oct 8, 2024
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
…ub.com:MetaMask/metamask-extension into feat/mmassets-356_sort-import-tokens-extension
…ub.com:MetaMask/metamask-extension into feat/mmassets-356_sort-import-tokens-extension
…ub.com:MetaMask/metamask-extension into feat/mmassets-356_sort-import-tokens-extension
Builds ready [e7a879e]
Page Load Metrics (2543 ± 485 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
…nsion--persistence-telemetry
Builds ready [f4ef0da]
Page Load Metrics (2007 ± 107 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
bergeron
previously approved these changes
Oct 7, 2024
bergeron
approved these changes
Oct 8, 2024
Builds ready [0cd3e25]
Page Load Metrics (1840 ± 89 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
salimtb
approved these changes
Oct 8, 2024
sahar-fehri
approved these changes
Oct 8, 2024
…nsion--persistence-telemetry
Quality Gate passedIssues Measures |
Builds ready [c8467f6]
Page Load Metrics (1934 ± 79 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
darkwing
approved these changes
Oct 8, 2024
github-merge-queue
bot
removed this pull request from the merge queue due to failed status checks
Oct 8, 2024
gambinish
deleted the
feat/mmassets-356_sort-import-tokens-extension--persistence-telemetry
branch
October 8, 2024 22:42
metamaskbot
added
the
release-12.7.0
Issue or pull request that will be included in release 12.7.0
label
Oct 8, 2024
gauthierpetetin
added
release-12.6.0
Issue or pull request that will be included in release 12.6.0
and removed
release-12.7.0
Issue or pull request that will be included in release 12.7.0
labels
Oct 21, 2024
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
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
This PR adds Token sorting to the Asset List page, and also moves Token importing to the top of the Token List. A few of the main changes introduced:
NativeToken
inTokenList
component to be included in sorting logic, and treated (as far as sorting is concerned) as any other token in the listtokenSortConfig
into state that keeps track of the sort order, the key being sorted by, and the direction of the sort order. Also includes an action to update this state.useEffect
that subscribes totokenSortConfig
as well as a few other application state variables to update and sort tokenList when appropriate.asset-list
component, and move some of it's relevant code into theuseAccountTotalFiatBalance
Acceptance Criteria:
A couple of disclaimers. There are still (at least) two bugs that I discovered that were not caught by tests:
When toggling preferred currency setting, Native Token sorted incorrectly by decreasing fiat balance✅ fixedWhen switching between accounts, token list does not update✅ fixedRelated issues
Fixes: https://consensyssoftware.atlassian.net/browse/MMASSETS-356
Manual testing steps
Screenshots/Recordings
Screen.Recording.2024-09-16.at.7.57.32.PM.mov
Pre-merge author checklist
Pre-merge reviewer checklist