2016-09-02 2 views
0

Я использую библиотеку javascript tooltipster, и я не знаю, почему текст обертывается в всплывающей подсказке.Всплывающая подсказка Javascript неожиданной оболочки текста (Tooltipster)

enter image description here

HTML:

<div id="spanBackground" style="background: rgba(238, 0, 140, 120);" 
class="tooltipjs" title="Touch to interact"> 

Javascript:

function AnimateUpDown(toolTipElement) { 
     $(toolTipElement).animate({ top: '+=20' }, 1000); 
     $(toolTipElement).animate({ top: '-=20' }, 1000, AnimateUpDown); 
    } 

    $(document).ready(function() { 
     $('.tooltipjs') 
      .tooltipster(
      { 
       animation: 'grow', 
       arrow: false, 
       //Custom trigger effectively disables the default onhover trigger 
       trigger: 'custom', 
       functionReady: function (instance, helper) { 
        AnimateUpDown(helper.tooltip); 
       } 

      }); 
     toolTipOpenAndClose(); 
    }); 

ответ

Смежные вопросы