Skip to content

Add ToastProvider to wrap AppRouter#12

Merged
elvisdragonmao merged 1 commit intomainfrom
feat/add-toast-provider
Feb 4, 2026
Merged

Add ToastProvider to wrap AppRouter#12
elvisdragonmao merged 1 commit intomainfrom
feat/add-toast-provider

Conversation

@Kyle9410-Chen
Copy link
Member

Type of changes

  • Feature

Purpose

  • Add ToastProvider to wrap AppRouter

@Kyle9410-Chen Kyle9410-Chen self-assigned this Feb 4, 2026
Copilot AI review requested due to automatic review settings February 4, 2026 05:50
@elvisdragonmao elvisdragonmao merged commit e512fba into main Feb 4, 2026
8 checks passed
@Kyle9410-Chen Kyle9410-Chen deleted the feat/add-toast-provider branch February 4, 2026 05:52
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds a global toast context by wrapping the application router with ToastProvider, enabling toast UI to be rendered across routes.

Changes:

  • Import ToastProvider from shared components.
  • Wrap AppRouter with ToastProvider in App.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +5 to +8
return (
<ToastProvider>
<AppRouter />
</ToastProvider>
Copy link

Copilot AI Feb 4, 2026

Choose a reason for hiding this comment

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

Wrapping the whole app in ToastProvider means any route/component that also mounts its own ToastProvider will create nested Radix toast providers/viewports. In this repo, ComponentsDemo already wraps itself in , so visiting /demo will render two toast viewports and can lead to duplicated UI/stacking issues. Consider removing the inner ToastProvider usage (or otherwise ensuring only a single provider is mounted at a time).

Copilot uses AI. Check for mistakes.
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.

3 participants