Skip to content

Conversation

@DeckerSU
Copy link
Contributor

@DeckerSU DeckerSU commented Nov 3, 2025

This PR adds priority-based sorting for the asset list displayed to unauthenticated users on the wallet page. Priority coins (BTC, KMD, ETH, BNB, LTC, DASH, ZEC, DOGE) are now displayed first in a specified order, followed by all other coins sorted alphabetically.

This change improves user experience by ensuring that when users first launch the wallet, they immediately see familiar and popular cryptocurrencies (such as Bitcoin, Ethereum, Komodo) instead of less-known assets that might appear first in alphabetical order (e.g., "1inch", "Aave", etc.). This makes the onboarding experience more intuitive and helps users quickly identify well-known assets.

Changes

1. Priority Tickers Configuration

  • Added unauthenticatedUserPriorityTickers constant in lib/app_config/app_config.dart
  • Defined as a List<String> to preserve order (BTC, KMD, ETH, BNB, LTC, DASH, ZEC, DOGE)
  • Order of coins in this list determines their display order

2. Asset List Sorting Logic

  • Modified AssetsList._groupAssetsByTicker() in lib/views/wallet/wallet_page/common/assets_list.dart
  • Implemented priority-based sorting for grouped asset view:
    • Priority tickers appear first, maintaining the order from unauthenticatedUserPriorityTickers
    • Non-priority tickers follow, sorted alphabetically

Behavior

For unauthenticated users (AuthorizeMode.noLogin and AuthorizeMode.hiddenLogin):

  1. Assets are grouped by ticker symbol
  2. Priority ticker groups appear first in the order: BTC → KMD → ETH → BNB → LTC → DASH → ZEC → DOGE
  3. Remaining ticker groups are displayed alphabetically after priority groups

For authenticated users:

  • No changes - existing sorting logic remains unchanged (balance and priority-based sorting)
image

- Added a set of priority ticker symbols for unauthenticated users.
- Implemented sorting logic in `sortAssetIdsWithPriority` to prioritize these tickers.
- Updated `AssetsList` to sort asset groups by priority tickers first, followed by others.
- Adjusted comments in `wallet_main.dart` to reflect the new sorting behavior.
…rting logic

- Deleted the set of priority ticker symbols for unauthenticated users.
- Removed the `sortAssetIdsWithPriority` function that utilized these tickers for sorting.
- Updated comments to reflect the removal of the priority sorting feature.
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 3, 2025

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch patch-assets-main-list

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

github-actions bot commented Nov 3, 2025

Visit the preview URL for this PR (updated for commit 10358e2):

https://walletrc--pull-3351-merge-54qrouam.web.app

(expires Mon, 10 Nov 2025 16:55:14 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: f66a4ff03faa546f12f0ae5a841bd9eff2714dcc

Copy link
Collaborator

@smk762 smk762 left a comment

Choose a reason for hiding this comment

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

Confirm functioning as explained. Coins to be included in this list may be up to debate, and modified in future, but this PR functionally adds the described changes.

@smk762 smk762 added this to the v0.9.4 milestone Nov 5, 2025
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.

3 participants