Skip to content

a11y: focus ring on the reply card; aria-controls names the listbox - #385

Open
LetMeSleep8h wants to merge 1 commit into
useagenthq:mainfrom
LetMeSleep8h:a11y/reply-box-focus
Open

LetMeSleep8h wants to merge 1 commit into
useagenthq:mainfrom
LetMeSleep8h:a11y/reply-box-focus

Conversation

@LetMeSleep8h

@LetMeSleep8h LetMeSleep8h commented Oct 26, 2026 •

Copy link
Copy Markdown

Fixes #328, exactly the three steps the issue lays out:

  1. The composer card (frontend/components/chat/composer.tsx) gains focus-within:border-border-focus-ring focus-within:ring-border-focus-ring focus-within:ring-1 — tabbing to the textarea now draws a visible ring around the card (the textarea itself keeps its outline-none focus-visible:ring-0, since the card is the focus indicator now).
  2. The role="listbox" element in slash-command.tsx gets id="slashcmd-listbox", and the textarea's aria-controls points at it instead of the slashcmd-label heading's id — a screen reader now hears that the combobox controls the list, not a paragraph.
  3. New render test slash-command-listbox.test.tsx pins the listbox id.

bun test components green (all existing suites + the new one).


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

Tabbing into the reply box showed nothing: the card gains a
focus-within ring (border-border-focus-ring token), and while the /
command list is open the textarea's aria-controls now points at the
listbox's own id instead of the heading's.

Fixes useagenthq#328
@github-actions

Copy link
Copy Markdown


Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I hereby sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot.

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.

Give the reply box a focus ring and point it at the command list

1 participant