Skip to content

fix(react-tree): expose tree selection control to assistive technologies#36384

Open
PaulGMardling wants to merge 4 commits into
microsoft:masterfrom
PaulGMardling:fix/a11y-tree-selection
Open

fix(react-tree): expose tree selection control to assistive technologies#36384
PaulGMardling wants to merge 4 commits into
microsoft:masterfrom
PaulGMardling:fix/a11y-tree-selection

Conversation

@PaulGMardling

Copy link
Copy Markdown

Previous Behavior

Voice access users are unable to access selection tree controls.

New Behavior

The Tree selection control (a checkbox in multiselect, a radio in single-select) now participates in the accessibility tree with an accessible name derived from the item's content. Previously it was hidden from assistive technologies, leaving any tool that operates the visible control directly unable to reach it.

Although the issue was reported against Windows Voice Access, the gap was platform-agnostic and equally affected macOS Voice Control and comparable technologies. Exposing the control resolves it at the source: the selector is now discoverable and operable by assistive technologies across platforms.

Selection state remains on the tree item via aria-checked / aria-selected, so screen readers announce it once (no double-announcement), and keyboard behavior is unchanged (the selector stays tabIndex -1; Space toggles). The fix applies to both the standard tree item layout and the persona tree item layout.

Testing/Verification

Windows 11:

Voice Access — "Show numbers" now places a number on each selection control; saying that number toggles selection, and "Click (item name)" works, confirming the accessible name resolves.
Narrator — selection state is announced once (no double-announcement); the row and the checkbox are both reachable as expected.

macOS (supplementary proxy):

Voice Control number-targeting toggles selection; VoiceOver reads the state once (no doubling). The browser accessibility tree confirms the control is exposed with the correct name.

Automated:

Added unit regression tests asserting the selection control is exposed (found by role) and named; verified they fail if the fix is reverted.

Fixes

https://dev.azure.com/microsoftdesign/fluent-ui/_workitems/edit/36260

@github-actions

Copy link
Copy Markdown

📊 Bundle size report

Package & Exports Baseline (minified/GZIP) PR Change
react-components
react-components: entire library
1.293 MB
325.78 kB
1.293 MB
325.822 kB
92 B
42 B
react-tree
FlatTree
135.571 kB
40.413 kB
135.646 kB
40.448 kB
75 B
35 B
react-tree
PersonaFlatTree
137.417 kB
40.931 kB
137.509 kB
40.982 kB
92 B
51 B
react-tree
PersonaTree
133.498 kB
39.718 kB
133.59 kB
39.77 kB
92 B
52 B
react-tree
Tree
131.658 kB
39.221 kB
131.733 kB
39.257 kB
75 B
36 B
Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-components
react-components: Button, FluentProvider & webLightTheme
66.281 kB
19.002 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
225.836 kB
67.998 kB
react-components
react-components: FluentProvider & webLightTheme
39.504 kB
13.112 kB
react-portal-compat
PortalCompatProvider
5.341 kB
2.146 kB
react-timepicker-compat
TimePicker
140.677 kB
45.99 kB
🤖 This report was generated against e75edae32b44d1733e392f420e5dd2d6fa8bfa0d

@github-actions

Copy link
Copy Markdown

Pull request demo site: URL

@PaulGMardling PaulGMardling force-pushed the fix/a11y-tree-selection branch from a4b0786 to 7574e86 Compare July 10, 2026 12:40
@@ -0,0 +1,7 @@
{

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🕵🏾‍♀️ visual changes to review in the Visual Change Report

vr-tests-react-components/Positioning 2 screenshots
Image Name Diff(in Pixels) Image Type
vr-tests-react-components/Positioning.Positioning end.updated 2 times.chromium.png 727 Changed
vr-tests-react-components/Positioning.Positioning end.chromium.png 761 Changed
vr-tests-react-components/ProgressBar converged 3 screenshots
Image Name Diff(in Pixels) Image Type
vr-tests-react-components/ProgressBar converged.Indeterminate + thickness - High Contrast.default.chromium.png 67 Changed
vr-tests-react-components/ProgressBar converged.Indeterminate + thickness.default.chromium.png 117 Changed
vr-tests-react-components/ProgressBar converged.Indeterminate + thickness - Dark Mode.default.chromium.png 34 Changed
vr-tests-react-components/Skeleton converged 1 screenshots
Image Name Diff(in Pixels) Image Type
vr-tests-react-components/Skeleton converged.Opaque Skeleton with circle - High Contrast.default.chromium.png 1 Changed

@PaulGMardling PaulGMardling marked this pull request as ready for review July 10, 2026 13:35
@PaulGMardling PaulGMardling requested a review from a team as a code owner July 10, 2026 13:35
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