Pre-pend to a widget

Hi,

I have a bunch of ui-switches in my dashboard and I would like to prepend to each Label an icon (or a "led") like this mock-up:

example

Maybe I could use a template node, but I am not clear about how/where to start....

Thanks for any assistance.

Fabio

Here is basics how to achieve that.

[{"id":"b10e16c2.e095d8","type":"ui_switch","z":"a05ff4cd.1ae7e8","name":"","label":"<i class=\"fa fa-circle glowyellow\"></i> FIRE","tooltip":"","group":"2caa6e4c.830752","order":2,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"topic","topicType":"msg","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","animate":false,"x":430,"y":420,"wires":[[]]},{"id":"fc0a6f9b.54409","type":"ui_template","z":"a05ff4cd.1ae7e8","group":"2caa6e4c.830752","name":"dashboard CSS","order":2,"width":0,"height":0,"format":"<style id=\"customized-styles\">\n    .glowyellow{\n        color: yellow;\n        text-shadow: 0 0 8px yellow;\n    }\n</style>","storeOutMessages":true,"fwdInMessages":true,"resendOnRefresh":true,"templateScope":"global","x":340,"y":380,"wires":[[]]},{"id":"2caa6e4c.830752","type":"ui_group","name":"Default","tab":"20934cee.3e6c14","order":1,"disp":true,"width":"6","collapse":false},{"id":"20934cee.3e6c14","type":"ui_tab","name":"Tab 1","icon":"dashboard","order":1,"disabled":false,"hidden":false}]
1 Like

Great, thank you very much!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.