Why The Hack is it so hard to customize the icon and color of an entity to reflect the state of the entity?
Many entities (such as light, battery) already change the icon and color depending on the state.
The gauge card already has a mechanism to define colors based on the range of a sensor. It would be nice to have a similar mechanisme to specify the icon and color of an entity myself using the UI.
There are two places to define a custom icon and color which come to mind:
- Define state-based icons and colors on the entity itself.
- Configure state-based icons and colors in the dashboard card.
To further optimize the workflow, some form of “templates” for a certain type of entity would be nice.
For example:
- define a “temperature” template with the icon and color for a sensor entity:
0: color:cyan, icon: "mdi:thermostat-low"
10: color:red, icon: "mdi:thermostat"
20: color:"#8B0000", icon: "mdi:thermostat-high"
- for any indoor temperature sensor, simply choose the “temperature” template and the predefined icons and colors will be used.
source: https://youtu.be/ClxxjLSZZMw?feature=shared
Personally, I like to use colors on my dashboards to more quickly absorb information, but it’s tedious to setup. There are numerous forum discussions and guides on how to do this using card-mod, templates, and other custom integration.