Open garykac opened 6 years ago
This runs into the tricky area of hit-testing, which we probably should leave for another time. But we'll want to at least roughly gesture in the direction of what "into element A" / "out of element A" mean.
For example, one interpretation is that given A nested inside B nested inside C, you're moving into A, B, and C, each of which fires a bubbling event, so that you get three mouseovers on C (1 directly + 1 bubbled from A + 1 bubbled from B). I'm pretty sure that's not what browsers do. Is the algorithm instead something like "the deepest thing in the DOM tree"?
TPAC discussion doc: https://docs.google.com/document/d/1AoNnGTGabWOQoAH-M34Jdw2rbbwb_pSZz2-69mysx_U/edit
We need a algorithmic description of how mouse events are fired.
mousedown
,mouseenter
,mouseleave
,mousemove
,mouseout
,mouseover
,mouseup
See https://w3c.github.io/uievents/#events-mouseevent-event-order
Starting point: