Open Bug 1875617 Opened 7 months ago Updated 3 months ago

Mouse event not delivered when through a pseudo inside a display:contents element

Categories

(Core :: DOM: Events, defect)

Firefox 121
defect

Tracking

()

UNCONFIRMED

People

(Reporter: nige.animal, Unassigned)

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36

Steps to reproduce:

Related to, but not the same as this Chromium issue: https://bugs.chromium.org/p/chromium/issues/detail?id=1518093

Actual results:

Run this with the debugger console open and follow instructions: https://codepen.io/Animal-Nige/pen/qBvqxjz

Clicking in the center of the red box should log to the console and report the event's offsetX and offsetY.

But the event is not delivered, and nothing is logged when the listener is added to to #inner.

If you catch the event at the document level on the bubble, it will log. with the correct offsets.

Expected results:

It should log the click point as the approximate center of #inner (Assuming you clicked on the blue "target")

It in fact logs nothing unless you move the listener to document

The Bugbug bot thinks this bug should belong to the 'DevTools::Debugger' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Debugger
Product: Firefox → DevTools
Component: Debugger → Core
Product: DevTools → GeckoView

No?

Here's the W3C spec issue about the ambiguity of delivering offsetX and offsetY to an element like this: : https://github.com/w3c/csswg-drafts/issues/9869

The severity field is not set for this bug.
:boek, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(jboek)

Nige, it this issue for Android only, or all platform?

Flags: needinfo?(nige.animal)

Although reporter doesn't reply this, this seems to be DOM: Events instead of GeckoView. Sorry for late.

Component: Core → DOM: Events
Flags: needinfo?(jboek)
Product: GeckoView → Core
Severity: -- → S3

(In reply to Makoto Kato [:m_kato] from comment #5)

Nige, it this issue for Android only, or all platform?

Sorry, was away from this issue with work commitments. I don't know anything about Android. I'm running FF on Mac. I suspect this is a base DOM level issue. The selection of which component to assign a ticket to is almost impossible for an outsider to the project.

Flags: needinfo?(nige.animal)
You need to log in before you can comment on or make changes to this bug.