Skip to content

fix(site/src/pages/AgentsPage): expose the agent chat panel toggle's expanded state - #32409

Merged
aqandrew merged 1 commit into
mainfrom
a11y/state-aria-expanded-missing-incorrect
Nov 18, 2026
Merged

aqandrew merged 1 commit into
mainfrom
a11y/state-aria-expanded-missing-incorrect

Conversation

@aqandrew

@aqandrew aqandrew commented Nov 18, 2026 •

Copy link
Copy Markdown
Collaborator

The agent chat top bar's "Toggle panel" button showed whether the right panel was open only through its icon. It now sets aria-expanded from the same showSidebarPanel state, so screen readers announce expanded or collapsed (WCAG 4.1.2, Deque state-aria-expanded-missing-incorrect).

Closes DEQ-427

Ticket UI surface
DEQ-427 /agents/:id top bar, "Toggle panel" button (ChatTopBar)

No screenshots: the change is ARIA-only and does not alter the rendered UI.

The existing AgentChatPage test now asserts the button reports expanded: true while the panel is open and expanded: false after it closes.

Decision log
  • Root cause: the toggle in ChatTopBar.tsx had no aria-expanded. One attribute fixes it; no shared primitive is involved.
  • aria-controls is not added: the panel lives in a separate RightPanel with no id today, and aria-expanded alone satisfies the checkpoint. Keeping the diff to one attribute.
  • Extended the existing test that already clicks "Toggle panel" instead of adding a new one.

🤖 Generated by Coder Agents on behalf of @aqandrew.

@linear-code

linear-code Bot commented Nov 18, 2026

Copy link
Copy Markdown

DEQ-427

@aqandrew
aqandrew marked this pull request as ready for review November 18, 2026 18:26
@aqandrew
aqandrew requested a review from a team as a code owner November 18, 2026 18:26

@jeremyruppel jeremyruppel left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

amazing 👏

@aqandrew
aqandrew merged commit a6ca18a into main Nov 18, 2026
60 checks passed
@aqandrew
aqandrew deleted the a11y/state-aria-expanded-missing-incorrect branch November 18, 2026 20:27
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 18, 2026

This branch had an error being deployed

1 failed and 1 inactive deployments
docs-preview — 7ddc6579 Deployed Nov 18, 2026 by aqandrew via cleanup #223
main — 7ddc6579 Deployed Nov 18, 2026 by aqandrew via cla #259818
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants