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

Added Skeleton Loader for loading Coins list #246

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

ilaki
Copy link
Contributor

@ilaki ilaki commented Feb 6, 2025

Fixes #234

Changes

  • Add skeleton loader (fade effect) until all visible items are loaded
  • Scroll bar style (pending)
  • Rerender and getting to the top of the list during user scroll (pending)

Copy link

vercel bot commented Feb 6, 2025

@ilaki is attempting to deploy a commit to the Mira-dex Team on Vercel.

A member of the Team first needs to authorize it.

@ilaki ilaki force-pushed the coins-list-latency-fix branch 2 times, most recently from 3d3b2e0 to 8430d28 Compare February 6, 2025 18:04
Copy link

vercel bot commented Feb 7, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
mira-amm-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 8, 2025 7:03am

@amaljosea
Copy link
Contributor

Hi @ilaki

Screenshot 2025-02-07 at 2 24 45 PM

Looks like the build is failing.

Please changeskeleton.module.css to Skeleton.module.css

@ilaki ilaki force-pushed the coins-list-latency-fix branch 2 times, most recently from 17c0de4 to 73a7ee4 Compare February 7, 2025 16:47
@amaljosea
Copy link
Contributor

amaljosea commented Feb 8, 2025

Hi @ilaki

To explore:

Lots of API calls when opening the token picker:

  • Can you check if the API calls are required?
    • If required why?
      • Can we merge them into a single call?

Large images:

  • Are smaller thumbnail images available? Can you research?
  • Why can't we take the icons from the asset.json?
  • If there is no solution, can we add a loading skeleton to the image to make it look nice?

We could handle these in a separate PR also if needed, but just wanted to get your thoughts first. Let me know before you implement.

@ilaki
Copy link
Contributor Author

ilaki commented Feb 9, 2025

@amaljosea
Update:

  1. The multiple fetch by asset Id calls inside useAssetImage hook is made redundantly since its querying same data(l1Address & image) which is already coming in assets query in parent component, so removing them.

I have some doubts:

  1. For image, we dont have compressed or thumbnail size images for assets in database. Can we add them? or can we add as local image file under frontend assets and update/overwrite in case database image doesnt match?
  2. Also loading assets.json url from verifiedAssetData is preferred over image url from sqdIndexer for some reason ? I am asking because latency looks the same when observed.

@amaljosea
Copy link
Contributor

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.

Slow load for the token picker and weird scroll bar
2 participants