[Bug]: Screen readers say "Message" twice when focus enters the composer#26675
Before submitting
- I searched existing issues and did not find a duplicate.
- I included enough detail to reproduce or investigate the problem.
Area
apps/web
Steps to reproduce
- Turn on NVDA (Windows) and open any thread, for example one titled "Screen Reader Thread List Regression".
- Move focus into the composer from outside it, using a click, Tab, F6, or a thread switch.
Expected behavior
NVDA announces the composer once: "Message Screen Reader Thread List Regression, edit, has auto complete, multi line".
Actual behavior
NVDA says "Message input, Message Screen Reader Thread List Regression, edit, has auto complete, multi line, opens list". It reads the region name first, then the text box name, which repeats "Message".
Cause: #25877 added workspaceAreaProps("composer", 2, "Message input") (apps/web/src/components/ChatView.tsx:703). That gives the composer wrapper role="region" and aria-label="Message input". Screen readers announce a region's name when focus enters it. The text box inside it is already labelled Message <thread title> (apps/web/src/components/chat/ChatComposer.tsx:3334, from #23676), so you hear both names.
Suggested fix: Don't revert #25877, because that would remove F6 navigation and the keyboard-navigable sidebar. Make label optional in workspaceAreaProps (apps/web/src/lib/workspaceFocus.ts:12) and leave out role and aria-label when no label is given. Then call it without a label for the composer. F6 only needs data-workspace-area, data-workspace-order and tabIndex=-1. F6 always focuses the composer's labelled text box, so the wrapper's name is never needed. Areas where F6 can land on the wrapper itself, such as Conversation, keep their labels.
Impact
Minor bug or occasional failure
Version or commit
main @ 125b61954d (regression from 2525252c96 / #25877)
Environment
Windows 11, NVDA, T3 Code desktop
Workaround
None.