Skip to content

Changing color of value using map_state or when #157

@woobenjamin

Description

@woobenjamin

Hi,
I'm having a problem with trying to change the color of the value (not icon) based on a set of parameters.

For example, I want to show the Air Quality Index (AQI)
So, I use something like

- entity: sensor.aqi
  name: AQI

I haven't fully figured out the when or map_state logic yet, but I can read some more, but essentially, what I want to do is show the value of the AQI, for any value <25, it's green, 25 to 50, yellow, and 50+ red.
I don't know how to change the color of the VALUE
If I use value: mdi:icon, I seem to be able to use color: , but for just value, I can't seem to figure it out.

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions