且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

工具提示未显示在fontawesome图标按钮上

更新时间:2023-11-14 22:11:34

如果使用的工具提示插件使用::before伪元素,则它与fontawesome冲突,因为它也使用pesudo元素显示图标

If you are using a tooltip plugin that uses the ::before pseudo element then it conflicts with fontawesome because it also uses the pesudo element to display the icon.

***将图标包装在另一个获得工具提示类的标签中:

It is best to wrap your icon inside another tag that gets the tooltip class:

<span class="tooltip" title="hello world"><i class="fa fa-random"></i></span>