Element with overflow-x: hidden can be focused by Tab key
Categories
(Core :: DOM: UI Events & Focus Handling, defect, P3)
Tracking
()
People
(Reporter: k3768z52, Unassigned, Mentored)
Details
(Keywords: good-first-bug)
Attachments
(1 file)
511 bytes,
text/html
|
Details |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:105.0) Gecko/20100101 Firefox/105.0
Steps to reproduce:
- Open the attached file (tab-focus-repro.html) in Firefox.
- Press the Tab key
Actual results:
The text can be focused using the Tab key, which does not make sense. It is neither scrollable nor clickable.
Expected results:
The text should not be focusable by the Tab key.
Updated•2 years ago
|
Comment 1•2 years ago
|
||
This code should be tweaked to handle each direction separately. Should be a trivial-ish bug fix + test.
Updated•2 years ago
|
Comment 2•2 years ago
|
||
Hello, I'm interested to fix this bug!
I need help how to create the test file. Is there any existing test as an example?
Comment 3•2 years ago
|
||
Yes, sure! dom/base/test/test_focus_scrollable_fieldset.html
is a somewhat related test you could probably copy as a start.
Instead of focusing <input>
s, you could be focusing <p>
elements with different overflow
values and contents.
Comment 4•2 years ago
|
||
you could be focusing
<p>
elements with different overflow values and contents.
Just to confirm, so I need to create test cases for all possible overflow value (visible, hidden, scroll, auto), also with combination of all direction (x, y, both), is that correct?
Comment 5•2 years ago
|
||
Might not be necessary to test visible, nor differentiate between scroll/auto, but you want to test overflow hidden in both and any axis, with and without scroll range on any of the axes.
Description
•