Ultralight icon indicating copy to clipboard operation
Ultralight copied to clipboard

SVG pointer-events attribute not working properly

Open DrJonki opened this issue 3 years ago • 0 comments

OS: Windows 10 Ultralight version: 1.3.0 (3e70dc7) CPU renderer

<svg width="100" height="100">
  <polyline
    id="line"  
    points="0,0 20,0 80,60 100,50"
    style="fill:none; stroke: red; stroke-width: 5;"
    pointer-events="stroke"
  ></polyline>
</svg>

<script>
document.getElementById("line").addEventListener("mouseenter", () => {
  console.log("mouse enter");
});
</script>

Expected: mouseenter event is triggered when cursor enters the stroked polyline.

What actually happens: mouseenter event is triggered when cursor enters polyline bounding rectangle.

DrJonki avatar Nov 02 '22 11:11 DrJonki