[Feature]: Add Skeleton Loading States for All Dashboard Cards#119
Merged
Conversation
|
@ErebAsh is attempting to deploy a commit to the Aditya Mahajan's projects Team on Vercel. A member of the Team first needs to authorize it. |
Contributor
Author
Screen.Recording.2026-07-09.135506.mp4 |
… conflicts in App.jsx
Contributor
Author
|
@Aditya8369 please review now |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
🎉 Your PR just got merged, @ErebAsh — thank you for contributing to Pollution Control Hub! Your work is now part of the project. Here's what to do next:
We really appreciate you taking the time. See you in the next PR! 🚀 |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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 upgrades the initial loading experience of the application.
Previously, while live AQI data was fetching, users would stare at a static text message ("Preparing live pollution intelligence...") and an empty screen, leading to a jarring layout shift once the data arrived.
To provide a more polished, premium feel, we have implemented an animated skeleton placeholder system (shimmer effect). The skeletons exactly mirror the layout, dimensions, and padding of the actual dashboard cards, completely eliminating layout shifts and providing users with immediate visual feedback on what content is about to load.
Key Changes
Skeleton.jsx):SkeletonDashboard.jsx):styles.css):linear-gradientand@keyframesanimation on pseudo-elements, requiring zero external libraries.data-theme="dark"), gracefully adapting the shimmer opacity for darker themes.App.jsx):Herocomponent immediately alongside theSkeletonDashboard..panelclass utilizes arise-inanimation, the transition from the skeleton state to the live data is buttery smooth with no jarring flashes.Testing Instructions
Impact
Significantly improves the perceived performance and overall user experience during initial data fetching, creating a premium feel and eliminating CLS (Cumulative Layout Shift).