1

I am using font awesome brand icons (e.g fab fa-css3-alt) but I cannot add tooltips on hover, I saw some suggestions but they are not working. I tried title attribute and data-toggle attribute but they did not help.

For example:

<i class="fab fa-python"></i>

How can I add tooltip on hover?

HARUN SASMAZ
  • 567
  • 1
  • 7
  • 17

1 Answers1

1

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>

Aziz Response

I. Anas
  • 11
  • 1