简体   繁体   English

AngularStrap弹出框:对象弹出框上没有方法

[英]AngularStrap popover: Object popover has no method on

I'm trying to integrate AngularStrap popover in my app. 我正在尝试将AngularStrap弹出框集成到我的应用程序中。 I have the following code on the button: 我在按钮上有以下代码:

    <button class="btn btn-primary" data-bs-popover="views/login.html" data-unique="1" data-placement="bottom">
        <span>Login</span>
    </button>

I have the appropriate dependencies added to my app. 我有适当的依赖项添加到我的应用程序。 When I try to execute this on Chrome, I get the following in the console: 当我尝试在Chrome上执行此操作时,控制台中显示以下内容:

    TypeError: Object popover has no method 'on'

It also says this: 它还说:

    TypeError: Object tooltip has no method 'on'

What am I missing? 我想念什么? I'd really appreciate it if someone can post a working code sample here. 如果有人可以在此处发布有效的代码示例,我将不胜感激。

Do you mix ui-bootstrap and mgcrea.ngStrap? 您是否将ui-bootstrap和mgcrea.ngStrap混合使用? This happened when ui-bootstrap invokes tooltip from mgcrea.ngStrap: ui-bootstrap从mgcrea.ngStrap调用工具提示时,会发生这种情况:

return $tooltip( 'popover', 'popover', 'click' );

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM