kazzkiq / balloon.css

Simple tooltips made of pure CSS
https://kazzkiq.github.io/balloon.css/
MIT License
5.03k stars 448 forks source link

Tooltip does not appear when triggered for a svg <line> element #151

Closed AlanKrygowski closed 3 years ago

AlanKrygowski commented 3 years ago

I'm trying to use tippy to display hover contents on a Chartist graph. When attempting to fire the tooltip on a svg line component, the tooltip itself does not show.

<line x1="xxx" x2="xxx" y1="xxx" y2="xxx" class="ct-bar" ct:value="3" aria-label="3" data-balloon-pos="up" data-balloon-blunt="true"></line>

The very same configuration works for all other dom elements that have a closing tag.

kazzkiq commented 3 years ago

AFAIK SVG elements do not support pseudo elements (::before and ::after).

This means it is not possible to use Balloon.css directly with SVG elements.