Javascript 大尺寸时引导工具提示位置混乱

Javascript 大尺寸时引导工具提示位置混乱,javascript,css,bootstrap-4,tooltip,Javascript,Css,Bootstrap 4,Tooltip,我在fullcalendar.js中使用引导工具提示(但问题不在fullcalendar库中,我只是将其包括在内) 问题就在这里。您将看到持续闪烁的工具提示 如果我删除.container中的overflow-y:scroll,这很容易修复,看起来像这样 .container{ height:300px; width:220px; display:block; margin:auto; } 不幸的是,我需要overflow-y:scroll 有什么想法吗?谢谢。您只需添加: 边

我在fullcalendar.js中使用引导工具提示(但问题不在fullcalendar库中,我只是将其包括在内)

问题就在这里。您将看到持续闪烁的工具提示

如果我删除.container中的
overflow-y:scroll
,这很容易修复,看起来像这样

.container{
  height:300px;
  width:220px;
  display:block;
  margin:auto;
}
不幸的是,我需要
overflow-y:scroll

有什么想法吗?谢谢。

您只需添加:

边界:“视口”

在工具提示函数调用的选项中:

$( document ).ready($('.hastooltip').tooltip({
        container: 'body',
        boundary: 'viewport',
        trigger: 'hover',
        template: '<div class="tooltip ' + tooptipClass + '" role="tooltip"><div class="arrow"></div><div class="tooltip-inner"></div></div>'}));
$(文档).ready($('.hastooltip').tooltip({
容器:'主体',
边界:“视口”,
触发器:“悬停”,
模板:'}');
检查示例