Repository navigation
fix: consistent full-width dashboard errors, background failures as toasts - #172
Merged
Merged
Conversation
…ailures to toasts Error banners span their section and lead with a warning icon instead of labels like "This run failed". Errors from the user's own request stay inline next to it. Failures of background loads (projects, recent sources, credits, session lists, billing, preferences, API keys, access checks and sign-out) now use the bottom-right toast with a retry action.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Sonner dismisses a toast after its action runs. A retry that failed with the same message left the error state unchanged, so the warning and its retry button never returned. The retry action now keeps the toast, which closes once the error clears. Monitors uses the same hook.
This branch was successfully deployed
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.
Problem
Dashboard errors rendered inconsistently. The agent run failure was inset (the global
.alertkept a42pxside margin) and split into a "This run failed" label column. Other pages mixed inline banners, bare text and a custom bottom-right box, including for background failures the user didn't trigger.What changed
One error style.
.alert.error,.trend-alert,.plan-errorand.source-data-warningshare a full-width banner that leads with a warning icon (added in CSS, so call sites need no markup). Retry actions sit on the right. The run failure drops its label, and screen readers still hear "Run failed."Inline only for the user's own request. Background loads now report through the existing sonner toast (bottom-right) with a retry action, via a new
useLoadErrorToasthook:Testing
npx tsc --noEmitinwebnpm run test:agent:dashboard: 139 passed (assertions for errors that moved to toasts now use the existing[data-sonner-toast][data-type=error]locator)