i wrote a widget which should display an icon based by it’s state.
<a class="dashboard-link" href="#/view/Batterie">
<widget-icon iconset="'custom-icon'" icon="'batterie'" size="32" state="itemValue('Batterie_Problem')" />
This does only display the “default” icon.
As you can see i made sure i have an icon set, means default and all states i need.
What i am doing wrong here?
Built in iconpicker servlet wants image filenames all in lowercase
@rossko57 THANK YOU !!!
After changing the filenames to lowercase AND the transform file to lowercase “voll” and “leer” it is working now.
You should not need to transform the states. The iconpicker servlet does that for itself, i.e. it will look for
blah-voll.svg for a state of VOLL (which is what gave you the problem) or Voll or VoLl
I use transform cause i get different state formats back, heating giving back on or off for battery warning, window sensors may give back 1 or 0 and i have some yes and no states coming back To have it all clean i transform them to “voll” and “leer”