Move the focus back to the previous focused element for dialog.close()
Categories
(Core :: DOM: Core & HTML, enhancement, P3)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox90 | --- | fixed |
People
(Reporter: sefeng211, Assigned: sefeng211)
References
Details
(Keywords: access, Whiteboard: , [wptsync upstream])
Attachments
(1 file)
Per discussion in https://github.com/whatwg/html/issues/5678, browser vendors agree that we should move the focus back to previously focused element upon dialog.close(). This improves the a11y support of dialog, so that we can enable <dialog> in Release.
We'll start with By default, dialog.close() returns the focus to the previously focused element if the element is still focusable and within the viewport, otherwise move the focus to <body>;
(Web developers should be able to use the close event to move the focus to a different element if they want)
| Assignee | ||
Comment 1•4 years ago
|
||
This change is based on the agreement that browser vendors are maded
in https://github.com/whatwg/html/issues/5678, such that closing
<dialog> should move the focus to the previously focused element.
Updated•4 years ago
|
Comment 2•4 years ago
|
||
There's a r+ patch which didn't land and no activity in this bug for 2 weeks.
:sefeng, could you have a look please?
For more information, please visit auto_nag documentation.
Updated•4 years ago
|
| Assignee | ||
Updated•4 years ago
|
Comment 5•4 years ago
|
||
| bugherder | ||
Updated•2 years ago
|
Description
•