microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.65k stars 28.68k forks source link

[A11y] Focus changes to custom editor when clicking on notebook toolbar overflow menu #210627

Open pwang347 opened 5 months ago

pwang347 commented 5 months ago

Does this issue occur when all extensions are disabled?: No (requires custom editor)

Steps to Reproduce:

  1. Run the custom-editor-sample in the extension samples repository and open a .pawDraw or .cscratch file

  2. Create a new notebook editor (ipynb file) in side by side orientation

    image
  3. First focus the notebook and observe that the tab title is highlighted

    image
  4. Now click the toolbar overflow button and observe that the custom editor tab is now highlighted

    image image

The focus should not change here but it does.

bmingles commented 3 months ago

I am also experiencing this when clicking the dropdown arrow of the editor/title/run button.

image

Seems if there is a custom panel visible (I'm using vscode.window.createWebviewPanel()), it will steal focus when certain editor menus are clicked.