atomiks / tippyjs

Tooltip, popover, dropdown, and menu library
https://atomiks.github.io/tippyjs/
MIT License
11.92k stars 520 forks source link

Wrong positioning for ellipsis inline element #916

Closed zhaoyao91 closed 3 years ago

zhaoyao91 commented 3 years ago

Bug description

If the reference is an inline element and is truncked by text ellipsis, the position is wrong

image

Reproduction

https://codepen.io/zhaoyao91/pen/MWbXJVP

atomiks commented 3 years ago

I'm not sure why the <span> in the example is stretching to the whole width as if it weren't clipped at 100px, but if you apply it to the outer div it works. It's not possible to fix this because the element is actually that wide and there's no way to detect otherwise.

zhaoyao91 commented 3 years ago

oh thanks, it works