Skip to content

[A11y]: Sidebar is not accessible #31267

@leagrdv

Description

@leagrdv

Note

This issue was rewritten by @Sidnioulz to track related issues in-place.

Links and buttons in the sidebar cannot be focused (original issue)

Describe the bug

The buttons in the sidebar have a tabindex="-1", which makes them unfocusable and therefore unclickable. The same issue applies to all the links—each one also has a tabindex="-1", so I can't focus on them either. While I can navigate through the items using the up and down arrow keys, the parent categories (e.g., "Foundations" in the screenshot) require using the tab key instead. This creates a disjointed navigation experience, as the arrow keys don't work in conjunction with the tab navigation, which is not ideal for accessibility.
Image

Reproduction link

https://design-system.post.ch/

Reproduction steps

No response

System

Version 8.2.7

Screen readers does not announce state and position count on controls present at the left navigation in windows

Describe the bug

User Impact:
Visually Impaired users who uses screen readers will be impacted as Screen readers (Narrator) does not announce state and position count on controls present at the left navigation in windows.

Pre-Requisites:
Enable Narrator

Actual Result:
Screen readers (Narrator) does not announce state and position count on controls present at the left navigation in windows.
Narrator announces: Link Docs

Refer Attachment:
1.Screen readers (Narrator) does not announce state and position count on controls present at the left navigation in windows.png
2.Screen readers (Narrator) does not announce state and position count on controls present at the left navigation in windows.mp4

Image https://github.com/user-attachments/assets/29b4bb54-d88e-414d-8036-54dd44def19f

Expected Result:
Screen readers (Narrator) should announce state as selected/ not selected and position count as 1 of 18 on controls present at the left navigation in windows.

Reproduction link

https://vivacommonstorybooktest.z13.web.core.windows.net/?path=/docs/app-bar--docs

Reproduction steps

  1. Open URL: https://vivacommonstorybooktest.z13.web.core.windows.net/?path=/docs/app-bar--docs in edge browser in windows.
  2. 'App Bar - Docs' page will be open.
  3. Press tab key to navigate to the 'Docs' control present at the left navigation.
  4. Verify whether screen reader announces the state and position count on controls present at the left navigation in windows or not.

System

not relevant

Work to do

Sidebar UI - Tree 2.0 project

  • Implement the sidebar using a Primer TreeView
  • Make relevant UI changes to match the Tree 2.0 2025 design file
    • New icons for roots and composed roots?
    • Code new sidear UI
    • Scope out UI rework of testing module and search/header
  • Make it possible for tree items to advertise a secondary actions menu
  • Implement keyboard actions: keyboard actions should always have a single effect, e.g. opening/close a tree node, and navigating on a leaf node
  • Implement mouse actions:
    • Decide: either do both expand+navigate as we used to, or stick to the same model as keyboard actions and require more clicks (@MichaelArestad wants to test that)
    • Perform user research for validation if needed
  • RefBlocks: header can be aria-expanded but needs a supporting role
  • RefBlocks: error state, Show Error has aria-expanded without supporting role
  • RefBlocks: has an aside element which is wrong (multiple aside violation)
  • Tree: if we still have disabled items, they need an aria-disabled attr

Sidebar-adjacent APIs

Sidebar accessibility followups

cc @MichaelArestad feel free to grow this list and I'll move it into a proper tracking issue later

  • Search bar rework? sticky, top-level icon + replace header with input
  • Consider top-level tree node for Recently Opened items instead of the current UI
  • Consider adding a pinned stories tree node (then how do we pin stories?)

Metadata

Metadata

Assignees

Labels

a11y: ariaAccessibility issues related to ARIA markup usagea11y: keyboardAccessibility issues related to keyboard navigation or shortcutsaccessibilityui

Type

No type

Projects

Status

In progress

Relationships

None yet

Development

No branches or pull requests

Issue actions