Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Semantic-UI: Add line break in tooltip

I want to have line breaks in my tooltip:

<span data:data-tooltip="line 1 ...\n 
                              line 2 ...">

I tried several proposals from here: Add line break within tooltips

Nothing did the trick. I use it without Javascript (v.2.2)

like image 492
pme Avatar asked Dec 14 '22 18:12

pme


1 Answers

You may use data-html instead of data-tooltip with a <br/> tag.

<div class="ui icon button" data-html="<p>First line <br/> Second line</p>">
  <i class="add icon"></i>
</div>

This solution needs Javascript, see PEN

like image 126
Gibin Ealias Avatar answered Dec 17 '22 22:12

Gibin Ealias