-
Notifications
You must be signed in to change notification settings - Fork 56
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
Add API to switch focus from sidePanel
to main document to enable accessibility features
#693
Comments
In contrast, when the side panel is opening, the focus remains on main webpage and does not move to the side panel, which makes some functions impossible. For example, a typical user requirement is to focus on the input box when the side panel opens, so that the user can input something immediately. So I hope there is a way to solve the problem of bidirectional focus movement. |
We discussed this during an in-person triage meeting at TPAC. We are aligned on the following:
|
sidePanel
to main document to enable accessibility features
A typical case comes to mind. When opening a new tab page(by shortcut or mouse), the focus is on the address bar for user input. Now the new tab page extension would like to call tabs.focus() to move the focus into the NTP for its own searching or shortcut function. Do browsers allow this behavior? There may be other risks of abuse. |
I raised that exact question and the answer is that the content area would be focused indeed. The meeting notes for the TPAC 2024 meeting will be published soon, here is the relevant excerpt:
|
Any movement on this? |
Description:
Interacting with the extension’s side panel (
chrome.sidePanel
) shifts focus away from the main webpage, and there is no way to programmatically return focus to the main document. This limitation makes it impossible to implement some features related to accessibility.Context:
Managing focus between the main document and the side panel's document within the same tab is essential for accessibility.
With proper focus management, the user can select something from the side panel, and the side panel can simulate certain events that only work when the main document is in focus.
Currently, extensions can switch focus between tabs, but not within the main document and side panel document.
Proposed Solution:
Introduce a new API that allows extensions to programmatically shift focus from the side panel back to the main document.
The text was updated successfully, but these errors were encountered: