[w3c/uievents] Clarify `mousemove` event target if preceding `mouseout`, `mouseleave`, `mouseover` or `mouseenter` event listener removes the `mouseover` target (Issue #393)

For example if website does:

```js
foo.addEventListener("mouseover", event => event.target.remove());
```

Then, where `mousemove` event should be targeted?

Firefox started targeting the closest connected ancestor of the removed target since 135.0.1 or later (not yet fixed the schedule, see [bug 1944191](https://bugzilla.mozilla.org/show_bug.cgi?id=1944191). Before that, Firefox dispatched `mousemove` event on the `Document` node.

Chrome does same thing if enabling the new experimental behavior of mouse/pointer boundary events. However, Chrome with disabling the feature dispatches `mousemove` on the removed target.

According to [the test result](https://wpt.fyi/results/uievents/mouse/mousemove_after_mouseover_target_removed.html?label=experimental&label=master&aligned), Safari does not dispatch `mousemove` event or dispatches on the root element or dispatching to the `Document` or the `Window`.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/uievents/issues/393
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/uievents/issues/393@github.com>

Received on Wednesday, 5 February 2025 08:56:17 UTC