atomiks / tippyjs

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

Incorrect positioning for wrapped span #905

Closed xpe closed 3 years ago

xpe commented 3 years ago

Bug description

With the cursor over a wrapped span (also called a multiline span), the default tooltip shows up in an incorrect place.

Reproduction

Moving the cursor over "and get to what's real" looks like this:

jump-misplaced-tooltip

CodePen link: https://codepen.io/xpe/pen/yLVMbwp

xpe commented 3 years ago

Related ticket #398 (but not fixed)

atomiks commented 3 years ago

Use inlinePositioning plugin which is available by default in the UMD version (as in the CodePen)

tippy('span', {
  inlinePositioning: true
});