-
Notifications
You must be signed in to change notification settings - Fork 621
Dashboard: Improve Progress bar implmentation with useTransition hook #6769
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
Conversation
|
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6769 +/- ##
=======================================
Coverage 55.17% 55.17%
=======================================
Files 896 896
Lines 56921 56921
Branches 3942 3942
=======================================
Hits 31407 31407
Misses 25418 25418
Partials 96 96
🚀 New features to boost your workflow:
|
size-limit report 📦
|
dd1ccd0 to
d14be78
Compare
Merge activity
|
…#6769) <!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR refines the `useDashboardRouter` functionality by implementing a progress bar during route transitions and removing the use of `LoadingRouteHref`. It introduces `RouteStartTransitionFn` for managing transition states and modifies the `DashboardRouterTopProgressBar` to reflect these changes. ### Detailed summary - Removed `usePathname` and `useSearchParams` from `useRouterLoadingStatus`. - Replaced `LoadingRouteHref` with `RouteStartTransitionFn` for managing transition states. - Updated `replace` and `push` methods in `useDashboardRouter` to use `startTransition`. - Refactored `DashboardRouterTopProgressBarInner` to use `isRouteLoading`. - Adjusted progress bar visibility and state management based on `isRouteLoading`. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
d14be78 to
17b8368
Compare

PR-Codex overview
This PR refines the
useDashboardRouterfunctionality to improve navigation performance by implementing a transition mechanism, replacing the previous loading state management, and enhancing theDashboardRouterTopProgressBarfor better route loading indication.Detailed summary
usePathnameanduseSearchParamsfromuseRouterLoadingStatus.RouteStartTransitionFnto manage transition states.useDashboardRouterto usestartTransitionforrouter.pushandrouter.replace.isLoadingtoisRouteLoadingfor clarity.DashboardRouterTopProgressBarInnerto trackisRouteLoading.Suspensewrapping inDashboardRouterTopProgressBar.