You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remove aria-live="polite" from the entire writing assistant panel.
Scope polite live announcements to the suggestions container only.
Add a small regression test for the live-region markup.
Accessibility impact
The panel updates while users type. Making the whole panel a live region can cause screen readers to announce unrelated changes such as tone, stats, and server status repeatedly. This keeps announcements focused on writing suggestions instead of every panel update.
The core change here is exactly right — scoping aria-live to #mt-suggestions instead of the whole panel will cut down on the noise a lot. The test approach (reading the source file and asserting on the HTML string) is lightweight and fits the existing pattern in this test suite well.
One thing worth considering before this merges: the Grammar & Spelling section (#mt-lt-issues and #mt-lt-state) also updates dynamically — when a server check completes, the issues list gets rewritten and the status message ("Checking grammar…", "Server unavailable", etc.) changes. Neither of those elements has a live region right now. For a keyboard/screen reader user who triggered the analysis, they'll get the suggestions announced but hear nothing when the grammar check resolves.
Probably the right move is aria-live="polite" on #mt-lt-issues or its wrapper #mt-lt-section, and a separate aria-live="assertive" (or at least polite) on #mt-lt-state for status messages — though polite is probably fine for both given the context. Whether that should be part of this PR or a follow-up is up to you, but it'd be worth an issue if it isn't tackled here since fixing half the live region problem is still a real improvement.
The change itself looks good to me — happy to see this land.
Aster1630
changed the title
Fix writing assistant live region scope
fix: writing assistant live region scope
May 18, 2026
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
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.
Summary
aria-live="polite"from the entire writing assistant panel.Accessibility impact
The panel updates while users type. Making the whole panel a live region can cause screen readers to announce unrelated changes such as tone, stats, and server status repeatedly. This keeps announcements focused on writing suggestions instead of every panel update.
Fixes #14.
Tests
npm test