Skip to content

Fix permission picker screen reader issues#321474

Merged
meganrogge merged 1 commit into
mainfrom
meganrogge/fix-permission-picker-a11y
Jun 15, 2026
Merged

Fix permission picker screen reader issues#321474
meganrogge merged 1 commit into
mainfrom
meganrogge/fix-permission-picker-a11y

Conversation

@meganrogge

Copy link
Copy Markdown
Collaborator

Problem

Two accessibility issues with the Permission Picker combobox in Copilot chat:

  1. Incorrect position count (Screen reader announces incorrect numeric position for list items in Permission Picker combobox:A11y_VisualStudioCode_Permissions levels in Copilot CLI_ScreenReader #321403): NVDA announces "5 of 5" when there are only 4 items (Default, Bypass, Autopilot, Learn More). The separator between the main items and Learn More was being counted in aria-setsize/aria-posinset.

  2. Tooltip not announced (Screen reader does not announce tooltip associated with list items in Permission Picker combobox:A11y_VisualStudioCode_Permissions levels in Copilot CLI_ScreenReader #321415): Hover tooltip text associated with each permission level is not announced by screen readers. The tooltip content provides important context about each permission option.

Fix

actionWidgetDropdown.ts: Added getSetSize and getPosInSet to the accessibility provider to exclude separators and headers from the count. Now correctly announces "1 of 4", "2 of 4", etc.

actionList.ts: Enhanced getAriaLabel to include hover.content in the aria label when no other description text (ariaDescription or description) is already present, so the tooltip information is exposed to assistive technologies.

Fixes #321403
Fixes #321415

Copilot AI review requested due to automatic review settings June 15, 2026 18:06
@meganrogge meganrogge self-assigned this Jun 15, 2026
@meganrogge meganrogge added this to the 1.126.0 milestone Jun 15, 2026
@meganrogge meganrogge enabled auto-merge (squash) June 15, 2026 18:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR addresses two screen reader accessibility issues in the Copilot Chat Permission Picker/action widget lists by correcting aria-setsize/aria-posinset calculations (so separators/headers aren’t counted as items) and by exposing tooltip/hover text to assistive technologies via the computed ARIA label when no other descriptive text is provided.

Changes:

  • Add custom getSetSize/getPosInSet logic to exclude non-action rows (headers/separators) from item counts.
  • Extend action list ARIA label generation to include hover/tooltip content when no ariaDescription/description exists.
Show a summary per file
File Description
src/vs/platform/actionWidget/browser/actionWidgetDropdown.ts Adjusts list accessibility provider set size/position logic to exclude non-action rows from screen reader counts.
src/vs/platform/actionWidget/browser/actionList.ts Appends hover/tooltip text to the computed ARIA label when no other description text is present.

Copilot's findings

  • Files reviewed: 2/2 changed files
  • Comments generated: 2

Comment thread src/vs/platform/actionWidget/browser/actionWidgetDropdown.ts
Comment thread src/vs/platform/actionWidget/browser/actionList.ts
@meganrogge meganrogge force-pushed the meganrogge/fix-permission-picker-a11y branch 3 times, most recently from aa20ef0 to 7b7bb34 Compare June 15, 2026 18:23
@vs-code-engineering

Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

@benibenj

Matched files:

  • src/vs/sessions/browser/parts/chatCompositeBar.ts
  • src/vs/sessions/browser/parts/mobile/contributions/mobileChangesView.ts
  • src/vs/sessions/browser/parts/mobile/mobileTitlebarPart.ts
  • src/vs/sessions/browser/parts/sessionDropTarget.ts
  • src/vs/sessions/browser/parts/sessionsParts.ts
  • src/vs/sessions/browser/workbench.ts
  • src/vs/sessions/contrib/layout/browser/sessionLayoutController.ts
  • src/vs/sessions/contrib/layout/test/browser/sessionLayoutController.test.ts

@kycutler

Matched files:

  • src/vs/sessions/contrib/browserView/browser/sessionBrowserView.ts

@jruales

Matched files:

  • src/vs/sessions/contrib/browserView/browser/sessionBrowserView.ts

@sandy081

Matched files:

  • src/vs/sessions/services/sessions/browser/sessionNavigation.ts
  • src/vs/sessions/services/sessions/browser/sessionsListModelService.ts
  • src/vs/sessions/services/sessions/browser/sessionsManagementService.ts
  • src/vs/sessions/services/sessions/browser/sessionsService.ts
  • src/vs/sessions/services/sessions/common/sessionsManagement.ts
  • src/vs/sessions/services/sessions/test/browser/sessionNavigation.test.ts
  • src/vs/sessions/services/sessions/test/browser/sessionsListModelService.test.ts
  • src/vs/sessions/services/sessions/test/browser/sessionsManagementService.test.ts

@lszomoru

Matched files:

  • src/vs/sessions/services/sessions/browser/sessionNavigation.ts
  • src/vs/sessions/services/sessions/browser/sessionsListModelService.ts
  • src/vs/sessions/services/sessions/browser/sessionsManagementService.ts
  • src/vs/sessions/services/sessions/browser/sessionsService.ts
  • src/vs/sessions/services/sessions/common/sessionsManagement.ts
  • src/vs/sessions/services/sessions/test/browser/sessionNavigation.test.ts
  • src/vs/sessions/services/sessions/test/browser/sessionsListModelService.test.ts
  • src/vs/sessions/services/sessions/test/browser/sessionsManagementService.test.ts

@anthonykim1

Matched files:

  • src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.ts
  • src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.ts

@meganrogge meganrogge force-pushed the meganrogge/fix-permission-picker-a11y branch from bf90f81 to 7b7bb34 Compare June 15, 2026 21:15
Fix two accessibility issues in the action widget dropdown used by the
permission picker:

1. Screen reader announces incorrect position count (e.g. '5 of 5'
   instead of '4 of 4') because separators were included in
   aria-setsize/aria-posinset. Added getSetSize and getPosInSet to the
   accessibility provider to exclude non-action items from the count.

2. Screen reader does not announce hover tooltip text. Added
   hover.content to the aria label when no other description or
   ariaDescription is already present, so tooltip information is
   exposed to assistive technologies.

Fixes #321403
Fixes #321415

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@meganrogge meganrogge force-pushed the meganrogge/fix-permission-picker-a11y branch from 7b7bb34 to b7042b5 Compare June 15, 2026 21:16
@meganrogge meganrogge merged commit bf732ec into main Jun 15, 2026
25 checks passed
@meganrogge meganrogge deleted the meganrogge/fix-permission-picker-a11y branch June 15, 2026 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment