fix(Snackbar): announce toasts via persistent portal live regions - #774
Merged
Conversation
johnleider
force-pushed
the
fix/snackbar-deferred-announcement-615
branch
from
August 3, 2026 16:51
34fbc74 to
8b9b622
Compare
johnleider
force-pushed
the
fix/snackbar-deferred-announcement-615
branch
from
August 3, 2026 16:54
8b9b622 to
9208368
Compare
johnleider
force-pushed
the
fix/snackbar-deferred-announcement-615
branch
from
August 3, 2026 17:19
9208368 to
eb5d54c
Compare
johnleider
added a commit
that referenced
this pull request
Aug 3, 2026
No ESLint rule enforces this header: grepping eslint.config.js and the resolved eslint-config-vuetify output finds no Foundational subgroup in the perfectionist/sort-imports groups. The comments were hand-written in the original feature commits (e6dcb42, e601c19) and merely preserved by perfectionist, which keeps comments attached to the import below them. Remove the stray subgroup comments so the Composables section matches the single-header norm used everywhere else. SnackbarRoot.vue keeps its copy for now - it is being cleaned on the open PR #774 branch. Verified: full pnpm lint:fix re-run does not re-insert the comments and produces no other changes.
johnleider
force-pushed
the
fix/snackbar-deferred-announcement-615
branch
2 times, most recently
from
August 3, 2026 17:53
7423656 to
1b38d18
Compare
johnleider
force-pushed
the
fix/snackbar-deferred-announcement-615
branch
from
August 3, 2026 17:57
1b38d18 to
2471895
Compare
johnleider
marked this pull request as ready for review
August 3, 2026 18:00
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.
Closes #615
Review of the sources replaced the original deferred-fill approach in this PR: the 100ms delay was unsourced (MDN recommends ≥2s for freshly-inserted regions), it coupled visible rendering to AT timing, and NVDA does not announce JS-injected
role="status"regions (nvaccess/nvda#14591) — full rationale in #615 (comment). Announcement duty now lives in the persistent layer instead, per the tetralogical article's first recommendation.Snackbar.Announcer(new sub-component, HiddenInput-style) — a visually-hidden announcer pair: polite (role="status") + assertive (role="alert"), botharia-atomic, mounted empty so the regions pre-exist any toast.Snackbar.Portalowns the announcement state and auto-renders it;:announcer="false"opts out for removal or explicit placement.Snackbar.Rootrenders immediately (no deferral anywhere) and mirrors its renderedtextContentinto the matching announcer on the next tick via an optionally-injected Portal context;urgentroutes to the assertive region, sidestepping the NVDA status-injection bug. Text is cleared before filling on the next frame (viauseRaf) so identical consecutive messages re-announce, and rapid-fire announces coalesce to the latest message per region instead of queuing stale intermediates for SRs to speak.Snackbar.Rootwithout a Portal: no announcer available — role attributes remain as documented best-effort (JS-injected status regions are unreliable, see role="status" live region not announced when injected into DOM nvaccess/nvda#14591).Part 1 of #615 (the
urgentprop /role="alert"path) landed in #624.Sources: tetralogical — why are my live regions not working, adrianroselli — live region support, nvaccess/nvda#14591