【问题标题】:Increase tooltip character limit - md-angular tooltip增加工具提示字符限制 - md-angular 工具提示
【发布时间】:2015-05-05 18:14:50
【问题描述】:
嗯,
我正在尝试使用角度材料设计工具提示指令,但由于我的工具提示消息大小,我面临一个问题,这完全显示。
我尝试查看 md 存储库,但找不到如何配置它
这是我正在尝试的代码:
<md-content >
<md-button class="badge-blue">
<span>?</span>
<md-tooltip>
This is the tootip message that i need to see, without ...
</md-tooltip>
</md-button>
<md-content>
内容和按钮样式设置宽度为 100%。
使用上面的消息,我只能看到:“This is the tootip message that i ne...”
我非常感谢任何帮助。谢谢!
【问题讨论】:
标签:
angularjs
material-design
angular-material
【解决方案1】:
您可以简单地调整/覆盖样式表:
HTML:
<md-content >
<md-button class="badge-blue">
<span>?</span>
<md-tooltip class="large">
This is the tootip message that i need to see, without ...
</md-tooltip>
</md-button>
<md-content>
CSS:
md-tooltip.large .md-content {
max-width: 500px; // Or whatever you need.
}
http://codepen.io/anon/pen/aOvWGb
【解决方案3】:
我看到的解决方案只会使工具提示更长,但仍然在一行。
我更喜欢覆盖 css 上的空白:
md-tooltip .md-content{
white-space: inherit;
}