Skip to content

fix(site/src/pages/WorkspacesPage): move selection checkboxes out of table header cells - #32322

Open
jeremyruppel wants to merge 1 commit into
mainfrom
a11y/table-data-not-header
Open

jeremyruppel wants to merge 1 commit into
mainfrom
a11y/table-data-not-header

Conversation

@jeremyruppel

@jeremyruppel jeremyruppel commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

The Workspaces table put the "Select all workspaces" checkbox inside the Name column header and each row checkbox inside its row header, so screen readers announced the control as part of the header (axe table-data-not-header, WCAG 1.3.1). The checkboxes now live in their own leading column of td cells; the Name column header and row headers contain only their labels.

Closes DEQ-233

Ticket Surface Screenshots
DEQ-233 Workspaces table (WorkspacesTable.tsx) before/after

Visible change: the checkbox-to-avatar gap shrinks from about 25px to 17px (the Table primitive's checkbox-cell padding), and Template/Status shift a few pixels. Vertical alignment and table borders are unchanged.

Dropped review finding: axe's experimental td-has-header flags the new checkbox cells because no header labels them. Experimental rules are out of the audit scope, and labelling the column with a th would put the control back inside a header cell, which is this ticket's issue. Each checkbox keeps its own accessible name.

Grouping and decision log
  • Batch table-data-not-header had one eligible ticket (DEQ-233), one root cause.
  • Options: (a) th with sr-only text plus the checkbox: still a control in a header cell, rejected; (b) separate leading column of td cells: chosen.
  • The header checkbox cell is a td inside thead; TableHeader already removes td borders there.
  • Each checkbox is wrapped in <div className="flex"> so it sits centred like before; without it, the inline-block checkbox sat about 2px low and the header grew 3px.
  • Loading skeleton row split to match the new column count.
  • Pre-existing, not touched: aria-valid-attr-value on the filter combobox input; aria-progressbar-name / button-name in the loading skeleton.
  • Checks: Vitest regression test fails on main and passes here; pnpm check, pnpm lint, pnpm format; axe run on AllStates, Loading, OwnerHasNoWorkspaces and SelectAllMixedEligibility, before and after (no new violations); frontend-review, frontend-deep-review and frontend-accessibility self-review.

🤖 Generated by Coder Agents on behalf of @jeremyruppel.

…table header cells

The select-all checkbox sat inside the Name column header and each row
checkbox inside its row header, so screen readers announced the control
labels as part of the headers (DEQ-233, axe table-data-not-header).
Give the checkboxes their own leading column of data cells.
@jeremyruppel
jeremyruppel temporarily deployed to main November 17, 2026 14:25 — with GitHub Actions Inactive
@jeremyruppel
jeremyruppel temporarily deployed to main November 17, 2026 14:25 — with GitHub Actions Inactive
@linear-code

linear-code Bot commented Nov 17, 2026

Copy link
Copy Markdown

DEQ-233

@jeremyruppel
jeremyruppel temporarily deployed to main November 17, 2026 14:27 — with GitHub Actions Inactive
@jeremyruppel
jeremyruppel marked this pull request as ready for review November 17, 2026 14:35
@jeremyruppel
jeremyruppel temporarily deployed to main November 17, 2026 14:36 — with GitHub Actions Inactive
@jeremyruppel

Copy link
Copy Markdown
Collaborator Author

easier to view the table diff without whitespace https://github.com/coder/coder/pull/32322/changes?w=1

This branch was previously deployed

1 inactive deployment
main — 0e1eee09 Deployed Nov 17, 2026 by jeremyruppel via cla #258695
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.

1 participant