Skip to content
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: expanded state v2 phase 1 #6332

Merged
merged 93 commits into from
Jan 24, 2025
Merged

Conversation

benisgold
Copy link
Contributor

@benisgold benisgold commented Dec 14, 2024

Fixes APP-2097, APP-2088, APP-2092, APP-2096, APP-2091

What changed (plus any additional context for devs)

Initial work on expanded states v2 feature including:

  • v2 sheet
  • Reusable collapse / row components
  • About section
  • Balance section
  • Market section
  • New footer with new context menu
  • Chart header redesign
  • Buy section (Currently defaults to native asset for token's chain, but in the future will be changable)

Other changes

  • Change deep links to fetch the asset remotely rather than just from cache, did not previously work for assets you don't own
  • Some chart related refactoring
  • Some style extensions of the TextShadow component
  • Subtitle support for the DropdownMenu component
  • Add support for <1 day formats to the formatDate util
  • Fix for react-native-linear-gradient patch to fix p3 color space
  • Refactor how expanded state handles asset types, always fetch latest asset / price data
  • Updated SF fonts to include missing symbols

Testing Notes

  • The market stats card (with the buys / sells for different timeframes) is currently blocked by not having the data. I left it in there for testing but will comment out before merging.
  • When you select an amount from the buy section, the resulting amount in the swap screen might be +/-$0.01 due to how the swap store nudges the input amount to a certain amount of decimals. The fix for this resulted in the swap store not correctly fetching the price quote, am still looking into how to fix this.
  • The latest testflight / tophat broke the fonts, working on fixing this now.

Future improvements / follow ups

  • New chart design where the last point does not go to the edge of the screen
  • Refactor useChartInfo and useExternalToken to use the new query store
  • Override swap store amount nudging when navigated to with exact amount
  • Cleanup / delete now unused old expanded state components and hooks
  • The chart in the Figma has a slightly updated design where the last point does not go to the edge of the screen
  • Ability to change pay with asset on instant buy section
  • Row highlight should animate background color transparency so that collapsing / uncollapsing does not cause minor flicker
  • Sort instant buy section assets buy account balance and allow changing between buy with assets directly in the section

Screen recordings / screenshots

RPReplay_Final1737599042.MP4

What to test

Click into token expanded state from main screen assets, trending tokens, and discover search.

@brunobar79 brunobar79 added the release for release blockers and release candidate branches label Dec 19, 2024
@derHowie derHowie removed the release for release blockers and release candidate branches label Dec 20, 2024
@benisgold benisgold changed the title feat: expanded state v2 feat: expanded state v2 phase 1 Jan 1, 2025
Copy link

linear bot commented Jan 23, 2025

@maxbbb maxbbb marked this pull request as ready for review January 23, 2025 02:41
@brunobar79
Copy link
Member

Launch in simulator or device for a4825ab

@brunobar79
Copy link
Member

Launch in simulator or device for 85b24f0

@brunobar79 brunobar79 added the release for release blockers and release candidate branches label Jan 23, 2025
@maxbbb maxbbb requested review from walmat and derHowie January 23, 2025 19:26
@maxbbb
Copy link
Contributor

maxbbb commented Jan 23, 2025

Heads up for anyone reviewing there is an occasional bug with the relative change on the chart header not showing, fixing it now.

Should be fixed in latest build

Copy link
Member

@derHowie derHowie left a comment

Choose a reason for hiding this comment

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

This is gorgeous stuff 👨‍🎨

Kane and I spoke off gh regarding a couple small issues.

the first Kane addressed here: https://www.loom.com/share/10a11004ea084793a2b63809316dafca

i left a couple small qs on the code itself, but none are blocking 🚢

src/handlers/deeplinks.ts Outdated Show resolved Hide resolved
@brunobar79
Copy link
Member

Launch in simulator or device for 2a5d738

@brunobar79
Copy link
Member

Launch in simulator or device for 0d05c08

@brunobar79
Copy link
Member

Launch in simulator or device for 60cfe59

@brunobar79 brunobar79 merged commit 6dafdcb into develop Jan 24, 2025
7 of 8 checks passed
@brunobar79 brunobar79 deleted the @benisgold/expanded-state-phase-1 branch January 24, 2025 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release for release blockers and release candidate branches
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants