Skip to content

fix(platform): name the editor tab by a level-two heading - #4862

Merged
yannickmonney merged 1 commit into
mainfrom
fix/editor-heading-outline
Oct 12, 2026
Merged

yannickmonney merged 1 commit into
mainfrom
fix/editor-heading-outline

Conversation

@yannickmonney

Copy link
Copy Markdown
Contributor

What

On a wide screen the editor's outline went from the page's title (level 1, the breadcrumb) straight to the open inspector's title (level 3), whichever box was open: a node, Start, End or a test. axe's heading-order (a best practice, not a WCAG A or AA criterion) flagged it on all four, in light, dark and forced colours, in English, German and French. The phone's sheet was already in order: its own title is a level 2.

Runs, Versions and General each carry a level-2 title; the Editor tab, a workbench, had none. It does now: an h2 that only a screen reader sees, holding the existing navigation.editor string ("Editor"), as the first child of the editor region. The region takes its name from it (aria-labelledby instead of aria-label), so its accessible name is the same word as before. The outline reads: page title, Editor, the open box's title, its sections. Nothing visible changes and there is no new string.

I did not shift the inspectors down a level instead (title to level 2, sections to 3, the test setup form's to 3 and 4): that is eight files, the run step detail is shared with the run page under other parents, and the phone's sheet would then carry two level-2 headings in a row.

How it was found, and a correction to #4847

#4847 said the audit found no violations on the test inspector. That held for the phone's sheet only. The desktop inspector's locator in my audit script was complementary.last(), which is the dashboard's own sidebar, so the inspector itself had never been audited on a wide screen. The script now finds the inspector by its name, skips the visually hidden one-pixel boxes its clipped-text probe used to count, and covers the node, Start and End inspectors too.

Re-run on the capture stack: 128 audits over the testing and versioning surfaces (English in light, dark, forced colours and phone; German and French in light, dark, phone and 320 px). The only finding in any of them is this one, on the four wide inspectors. No overflow, no clipped text, no contrast, name or label violations, in any of the three languages; the control page still reports its three planted faults.

Tests

AutomationEditor outline in automation-editor.test.tsx, six tests:

  • the editor region's first heading is a level 2 named "Editor";
  • the node's, Start's, End's and a test's inspector open under it without a skipped level (headings listed in reading order, each at most one level below the one before, the page title counted as level 1);
  • the phone's sheet, whose headings sit outside the region, stays in order across the whole screen.

Five fail on the old code. Demoting the inspector titles to level 4 (a mutation) fails the same four plus the sheet.

Checks

  • Platform tsc, oxlint --type-aware on both files, format check.
  • Live, before and after (heading-order, per surface and mode): node, Start, End, test and failed-test inspectors, light, dark, forced colours, phone, German, French. Before: one violation on every wide combination; after: 30 audits, none.
  • Platform UI suite (736 files, 7,675 tests), the automations browser suite (95), server and PII suites (88,114), lint:manual (1,764 boxes), knip: all green.

Manual: AUTO-A16 (a screen reader on Start, a condition and End) also reads the headings list; the reference row says the unit test owns the structure.

On a wide screen the editor's outline went from the page's title (level 1)
straight to the open inspector's title (level 3), whichever box was open:
Runs, Versions and General each carry a level-two title and the Editor tab,
a workbench, had none. The editor region now takes its name from an
sr-only h2 holding the same word, so its accessible name is unchanged and
the outline reads title, Editor, the box's title, its sections. A phone's
sheet already brings its own level 2.

The tests list each inspector's headings in reading order and fail on a
level that rises by more than one; AUTO-A16 gains the headings list.
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