【问题标题】:How to use tooltip on bootstrip with angularjs?如何在带有 angularjs 的引导条上使用工具提示?
【发布时间】:2014-10-14 22:03:06
【问题描述】:

您好,我在我的项目中使用带有 angularjs 的引导程序。我搜索并尝试了一些在工具提示中显示一些文本的方法。但它不起作用。代码在这里...请帮帮我

帮助?

帮助?

这两种方法也不起作用...如何解决?

【问题讨论】:

  • 您的问题看起来有点奇怪,但请查看 Angular UI Bootstrap 项目:angular-ui.github.io/bootstrap。使用它通过角度指令替换引导 javascript。
  • 我想做普通的 Angular js

标签: angularjs twitter-bootstrap tooltip


【解决方案1】:

您可以使用 uiJqConfig 了解详情

http://angular-ui.github.io/ui-utils/

只需要添加这个模块

myapp.value('uiJqConfig', {
// The Tooltip namespace
tooltip: {
    // Tooltip options. This object will be used as the defaults
    placement: 'right'
 }

});

你可以像这样在你的html中使用它

<span title="this is my text" ui-jq="tooltip">

 you can also change the position like

<span title="this is my text" ui-jq="tooltip"  tooltip-placement="left">

【讨论】:

  • 普通的angularjs不行吗?
  • 为此你需要添加 ui bootstrap
  • 如果我添加了ui bootstrap,是否会影响我正常的bootstrap样式?
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2014-01-07
  • 2017-03-02
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多