Skip to content

Make Delete Cell button reachable via arrow keys in notebook cell toolbar#320852

Draft
Copilot wants to merge 2 commits into
mainfrom
copilot/fix-delete-cell-button-accessibility
Draft

Make Delete Cell button reachable via arrow keys in notebook cell toolbar#320852
Copilot wants to merge 2 commits into
mainfrom
copilot/fix-delete-cell-button-accessibility

Conversation

Copilot AI commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

The notebook cell title toolbar rendered the main actions and the Delete Cell action as two separate ToolBar instances inside the same container. Since arrow-key navigation is scoped to a single ActionBar, keyboard users had to press Tab to move focus from the main toolbar actions onto the Delete Cell button, breaking the expected navigation pattern within a single toolbar group.

Description

  • Single toolbar rendering (src/vs/workbench/contrib/notebook/browser/view/cellParts/cellToolbars.ts): Dropped the separate deleteToolbar/createDeleteToolbar helper and render the delete menu's actions in the existing WorkbenchToolBar, appending them after the title actions to preserve visual order.
  • Change listeners: setupChangeListeners now subscribes to both titleMenu and deleteMenu change events and recomputes the combined action list, so contributions to either menu still update correctly. The dropdown-deferred-update path is preserved.
  • Menus unchanged: MenuId.NotebookCellTitle and MenuId.NotebookCellDelete remain distinct, so extension contributions to either continue to work.
// Combine the main title actions and delete actions into a single toolbar
// so that arrow-key navigation reaches all items (including Delete Cell).
const primary = model.actions.primary.concat(model.deleteActions.primary);
const secondary = model.actions.secondary.concat(model.deleteActions.secondary);
toolbar.setActions(primary, secondary);

…for arrow-key navigation

Co-authored-by: amunger <2019016+amunger@users.noreply.github.com>
Copilot AI requested review from Copilot and removed request for Copilot June 10, 2026 22:21
Copilot AI changed the title [WIP] Fix Delete Cell button accessibility via arrow key navigation Make Delete Cell button reachable via arrow keys in notebook cell toolbar Jun 10, 2026
Copilot AI requested a review from amunger June 10, 2026 22:22
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.

Delete Cell button is not accessible using arrow key navigation in notebook toolbar:A11y_Visual Studio Code Jupyter Extensions_Home_Keyboard

2 participants