0

Is there a way to delay bootstraps popover from showing for x milliseconds?

Maybe I missed it, but I haven't found it yet, and I want to use Bootstraps popover as a tooltip for CRUD icons in a grid where I show these on each row.
When the user now hovers over all these icons it keeps flashing on and on off.
Hence I'd like to define a delay / hoverIntent so it only shows when the user stops over an icon.

Is this possible in angular-ui-bootstrap? This is what I currently have :

<button 
    ng-click="release(row)" 
    class="btn btn-mini"  
    popover="Release account" 
    popover-trigger="mouseenter">
    <i class="icon-trash"></i>
</button>
4

1 回答 1

4

好的,这很愚蠢。在我创建这个问题 5 分钟后,我在这里的 angular-ui 文档中找到了解决方案

在弹出框属性列表中有这个:

  • popover-popup-delay在弹出框显示之前,用户必须将鼠标悬停在元素上多长时间(以毫秒为单位)?默认为 0。

因此,我的 html 代码只需更改为:

<button 
    ng-click="release(row)" 
    class="btn btn-mini"  
    popover="Release account" 
    popover-trigger="mouseenter"
    popover-popup-delay=200>
    <i class="icon-trash"></i>
</button>

我希望将其添加为答案可以节省其他人的时间....

于 2013-10-17T10:07:20.427 回答