-
Notifications
You must be signed in to change notification settings - Fork 15.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: do not allow the window to grab focus when tabbing / shift+tabbing #16042
fix: do not allow the window to grab focus when tabbing / shift+tabbing #16042
Conversation
Very cool, looking forward to have this in VSCode 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, can you also add a test with <webview>
just to confirm there aren't any regressions. Thanks!
In this change, the tab traversal is made effective only if its the outer most webContents which isn't the case for <webview>
, but just to be sure.
@deepak1556 Thanks for the review and great suggestion to include a webview in the tests, I had tested it manually but we should ensure it doesn't regress. It has been included in the tests.. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice 👍
Release Notes Persisted
|
Description of Change
Keep the focus restrained to the set of focusable elements when the user tabs or SHIFT + tabs through the focusable elements in a page. Do not allow it to move to the browser window as it is unexpected in a desktop app and no visual indication is given that the browser window is focused.
Fixes #12919.
Checklist
npm test
passesRelease Notes
Notes: Fixed a problem where the focus would move to the browser window after the user (SHIFT +) tabbed through all the elements in the page (#12919).