Dashboard Text Node : Can we use a font awesome icon as a label

2,270 views
Skip to first unread message

Dominic Giles

unread,
Apr 6, 2018, 3:25:23 PM4/6/18
to Node-RED
Before I go down the template route can some tell me if its possible to use a font awesome icon as a label?

The template approach looks ok but it would save a bunch of time if I could use the Label filed rather than coding CSS for each item I want to display.... 

Thanks Dom.

Dave C-J

unread,
Apr 6, 2018, 5:16:45 PM4/6/18
to node...@googlegroups.com

Dominic Giles

unread,
Apr 6, 2018, 5:52:38 PM4/6/18
to Node-RED
Sort of.... But this focuses just on the value... I thought it would still be of value to specify the icon in the label... You'd then still have control over positioning without changing code...

Dave C-J

unread,
Apr 6, 2018, 6:18:01 PM4/6/18
to node...@googlegroups.com
Did you try just putting the html in the label ?
--
Sent from phone.

Dominic Giles

unread,
Apr 7, 2018, 4:40:52 AM4/7/18
to Node-RED
Thanks Dave...

I was confused by the fact that whilst Value has "Value Format"... Label just has the description "Label"


Inserting just the html in the label field gave me (as you rightly pointed out) the correct layout.

<font>
 
<i class="fa fa-thermometer-empty fa-2x"></i>
</font

Which in turn gave me


Many Thanks

Dom

>

Dave C-J

unread,
Apr 7, 2018, 5:41:30 AM4/7/18
to node...@googlegroups.com
Great. Don’t think you need the font tag either. But meh. 
--
Sent from phone.
Reply all
Reply to author
Forward
0 new messages