Skip to content
This repository has been archived by the owner on May 10, 2024. It is now read-only.

Fix #7202: Wallet Market Tab #7298

Merged
merged 7 commits into from
Apr 25, 2023
Merged

Fix #7202: Wallet Market Tab #7298

merged 7 commits into from
Apr 25, 2023

Conversation

nuo-xu
Copy link
Contributor

@nuo-xu nuo-xu commented Apr 20, 2023

Summary of Changes

We are introducing a tab Market which will display the top 250 tokens in the market from CoinGecko

This pull request fixes #7202

Submitter Checklist:

  • Unit Tests are updated to cover new or changed functionality
  • User-facing strings use NSLocalizableString()
  • New or updated UI has been tested across:
    • Light & dark mode
    • Different size classes (iPhone, landscape, iPad)
    • Different dynamic type sizes

Test Plan:

  1. Open wallet and go to the new Market tab
  2. Observe there is a loading state before listing top 250 tokens
  3. Observe token's name, symbol, logo, current price and price delta is being displayed
  4. Check click any token will bring you to token detail screen
  5. Inside token detail screen there shouldn't be any information related to current selected network (which you can check you current selected network inside buy/send/swap screen)
  6. Inside token detail screen, there shouldn't be any account balances or transactions listed
  7. Inside token detail screen, check if price, price delta and price history are being listed.
  8. Inside token detail screen, check if rank, 24h volume and market cap information are being listed
  9. Some tokens will have a Buy button available inside token detail screen, when this token's symbol can be found in all available buy tokens with all supported providers in CURRENT SELECTED network (For example, if your current selected network is Eth mainnet, then Eth token detail screen will have the Buy button, but not Solana token)

Screenshots:

simulator_screenshot_727EAAD0-BA40-4F01-B4E8-C6F0A9B361FE Simulator Screen Shot - iPhone 14 Pro - 2023-04-20 at 13 16 21 simulator_screenshot_B28821FC-DF45-4C39-9F47-A3EA6C27E976

Reviewer Checklist:

  • Issues include necessary QA labels:
    • QA/(Yes|No)
    • bug / enhancement
  • Necessary security reviews have taken place.
  • Adequate unit test coverage exists to prevent regressions.
  • Adequate test plan exists for QA to validate (if applicable).
  • Issue and pull request is assigned to a milestone (should happen at merge time).

@nuo-xu nuo-xu requested a review from StephenHeaps April 20, 2023 17:17
@nuo-xu nuo-xu requested a review from a team as a code owner April 20, 2023 17:17
@nuo-xu nuo-xu self-assigned this Apr 20, 2023
@nuo-xu nuo-xu added this to the 1.51 milestone Apr 20, 2023
@nuo-xu nuo-xu force-pushed the wallet/market-tab branch from 4f16586 to b2281fb Compare April 20, 2023 17:22
@nuo-xu nuo-xu force-pushed the wallet/market-tab branch from b2281fb to eb5ed03 Compare April 20, 2023 17:45
Copy link
Contributor

@StephenHeaps StephenHeaps left a comment

Choose a reason for hiding this comment

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

We may want to cache the token details so it doesn't reload when popping the asset detail off navigation stack which causes us to lose scroll position (same logic would apply when switching to this activity tab after previously loading the market data):

cache.market.data.mp4

Update: Resolved by checking if marketStore.coins.isEmpty before showing loading state.

@nuo-xu nuo-xu force-pushed the wallet/market-tab branch 2 times, most recently from b10b4ab to b27af08 Compare April 21, 2023 16:59
@nuo-xu nuo-xu requested a review from StephenHeaps April 21, 2023 17:33
Copy link
Contributor

@StephenHeaps StephenHeaps left a comment

Choose a reason for hiding this comment

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

A few code comments, functionality wise it's working great 👍.

Copy link
Contributor

@StephenHeaps StephenHeaps left a comment

Choose a reason for hiding this comment

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

Nice work 🎉

@nuo-xu nuo-xu force-pushed the wallet/market-tab branch from 75465de to e82f244 Compare April 24, 2023 21:16
@nuo-xu nuo-xu merged commit 2774b5f into development Apr 25, 2023
@nuo-xu nuo-xu deleted the wallet/market-tab branch April 25, 2023 20:29
@srirambv srirambv mentioned this pull request May 5, 2023
arthuredelstein pushed a commit to brave/brave-core that referenced this pull request Feb 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Wallet: Market Tab
3 participants