WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
247416
focus-visible is triggered when opening dialog using mouse
https://bugs.webkit.org/show_bug.cgi?id=247416
Summary
focus-visible is triggered when opening dialog using mouse
Andreas Ehrencrona
Reported
2022-11-03 01:33:30 PDT
Created
attachment 463380
[details]
Repro When opening a dialog using `showModal`, the first focusable element is given focus. So far so good. However, the element always receives a focus highlight. In fact, `:focus-visible` is triggered. I would expect this not happen if I use a mouse to open the dialog. See the attached reproduction, where clicking the open button shows a dialog with button with a pink border. The pink border is from a `:focus-visible` style.
Attachments
Repro
(616 bytes, text/html)
2022-11-03 01:33 PDT
,
Andreas Ehrencrona
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2022-11-10 00:34:18 PST
<
rdar://problem/102181392
>
Brian Birtles
Comment 2
2024-01-08 00:46:58 PST
This affects iOS too. Additional repro:
https://developer.mozilla.org/en-US/play?id=rinvhv4MRjLWRSyElPfnYRbOVnUv3WDOuI9WLVn0DjHYPdO2rPvcp1b5itMuo4KLtQ2QRjEdUUvv0oqn
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug