Open Bug 1587745 Opened 5 years ago Updated 2 years ago

Events not fired for 1px elements

Categories

(Core :: DOM: Events, defect, P3)

69 Branch
defect

Tracking

()

UNCONFIRMED

People

(Reporter: pawel.fus.88, Unassigned)

Details

Attachments

(1 file)

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

Steps to reproduce:

Demo: https://jsfiddle.net/56azmgfb/1/

Mouse over rectangles.

Simplified demo: https://jsfiddle.net/pfez3qaw/
Real use case: hovering bars should display tooltip: https://jsfiddle.net/BlackLabel/r9ey7am4/

Actual results:

mouseOver event is fired only sometimes.

Expected results:

mouseOver event should be repeatedly called for every rectangle. Just like in other browsers.

It seems to be related to pointer-events: visiblePainted - setting to all resolves the issue: https://jsfiddle.net/56azmgfb/2/

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → DOM: Events
Product: Firefox → Core

In which version is this failing? I have a hard time reproducing this in Firefox Nightly. If I move the "mouse" quickly it'll skip sometimes, but that happens in Safari too.

Flags: needinfo?(pawel.fus.88)

Tested with:

  • v69.0.2
  • v69.0.3
Flags: needinfo?(pawel.fus.88)

Can you attach your about:support? Also what does window.devicePixelRatio say? This is probably a hit testing issue, but I can't reproduce either here :/

Attached file about-support
> Also what does window.devicePixelRatio say?

It says `1`

>

On linux Firefox gets fewer mouseover events than Chrome, but in general neither guarantees mouseover is fired on the line, which
makes sense since OS itself doesn't guarantee mouse is ever exactly on top of the 1px line and also mousemove events are coalesced in browsers.
That said, I think Firefox should get more events - for some reason hit testing doesn't find the line often enough.

Priority: -- → P3
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: