Change amount of time Bootstrap tooltips display / fade in and out

限于喜欢 提交于 2019-12-10 21:31:44

问题


I'm adding tooltips using Twitter Bootstrap, is there an attribute I can add which determines how long a tooltip displays for / how long it takes to fade in and out?

<span class="myClass" data-tooltip="{{myData}}" data-tooltip-placement="right"></span>

Cheers


回答1:


Bootstrap uses the class .fade for the opacity change of the tooltips. It looks like this in the CSS file:

.fade {
    opacity:0;
    -webkit-transition: opacity .15s linear;
    -o-transition: opacity .15s linear;
    transition: opacity .15s linear;
}

Just change the .15s of the transition properties to your desired duration.



来源:https://stackoverflow.com/questions/25845874/change-amount-of-time-bootstrap-tooltips-display-fade-in-and-out

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!