Closed Bug 1782142 Opened 2 years ago Closed 2 years ago

[Bug]: :active pseudo-class doesn't get added when element is in shadow DOM

Categories

(Core :: Panning and Zooming, defect)

Unspecified
Android
defect

Tracking

()

RESOLVED FIXED
105 Branch
Tracking Status
firefox-esr91 --- wontfix
firefox-esr102 --- wontfix
firefox103 --- wontfix
firefox104 --- wontfix
firefox105 --- fixed

People

(Reporter: kbrosnan, Assigned: edgar)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

From github: https://github.com/mozilla-mobile/fenix/issues/26229.

Steps to reproduce

Minimal example: https://jsfiddle.net/jngbsn/6pjy8qvx/9/

Expected behaviour

Both buttons should turn red when pressed.

Actual behaviour

The bottom button does not apply its :active CSS rule when pressed. If the site is viewed with the desktop version of Firefox in Responsive Design Mode with touch simulation enabled, the result is the same, the bottom button does nothing.

The :active CSS rule works if you apply it manually in devtools, and the element responds to pointer and touch events. Initially the bug was found with button elements, but seems to do the same with anchor and even div elements (from what I tested). However I did not test any other pseudo-classes.

Works as expected in desktop Firefox, as well as mobile and desktop Chrome.

Device name

No response

Android version

Android 12

Firefox release type

Firefox

Firefox version

102.2.1

Device logs

No response

Additional information

No response

┆Issue is synchronized with this Jira Task

Change performed by the Move to Bugzilla add-on.

Still have the same bug in mobile 103.1.0 and desktop 103.0 in responsive design mode.

Blocks: shadowdom
Assignee: nobody → echen
Component: DOM: Core & HTML → Panning and Zooming
Attachment #9288180 - Attachment description: Bug 1782142 - Use unretargeted element to specify the active element for touch; → Bug 1782142 - Use unretargeted element to specify the active element for touch; r=smaug
Pushed by echen@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0b68ff23dbe5 Use unretargeted element to specify the active element for touch; r=smaug
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 105 Branch
Regressions: 1783657
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: