Skip to content

[Enhancement] Toast auto-dismiss doesn't pause on hover or focus #653

Description

@collinsezedike

Description

apps/web/src/store/toast.ts:19-26's push always fires an unconditional 4-second setTimeout regardless of toast kind or whether the user is currently interacting with it. There's no hover/focus handler anywhere in apps/web/src/components/ui/Toasts.tsx to pause or extend the timer.

An error toast (rendered with role="alert"/aria-live="assertive") gets exactly the same 4-second window as a short success toast, even though error messages tend to be longer and more important to actually read.

Steps to Reproduce

  1. Trigger an error toast with a longer message (e.g. a failed deposit with a detailed reason).
  2. Try to read it while hovering over it.
  3. Observe it disappears at 4 seconds regardless of the hover.

Expected Behavior

Hovering or focusing a toast should pause its dismiss timer; moving away or blurring resumes (or restarts) it.

Actual Behavior

The timer runs unconditionally to completion no matter what the user is doing.

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programenhancementNew feature or requestfrontendInvolves React components, Tailwind styling, or Next.js pagestrivialSelf-contained task, completable in < 2 hours with no deep protocol knowledge requireduiPurely presentational work — layout, spacing, visual polish

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions