kalkih / mini-graph-card

Minimalistic graph card for Home Assistant Lovelace UI
MIT License
2.85k stars 231 forks source link

[Question] Is it possible to link the color threshold value to a sensor so it changes dynamically? #1099

Closed Boerny41 closed 2 months ago

Boerny41 commented 2 months ago
type: custom:mini-graph-card
entities:
  - sensor.bme280_temp
icon_adaptive_color: true
icon: mdi:home-thermometer-outline
font_size: 140
name: null
hour24: true
hours_to_show: 24
points_per_hour: 6
show:
  labels: false
color_thresholds_transition: smooth
color_thresholds:
  - value: 20
    color: blue
  - value: 21
    color: turquoise
  - value: 22
    color: lightgreen
  - value: 23
    color: yellow
  - value: 24
    color: orange
  - value: '{{ states("sensor.max_temperature") }}'
    color: red

I tried it like this but it didn't work. The sensor has a valid number (26.7) and is online. All I could finde was one guide but he used "value_template" which doesn't seem to be supported anymore.

ildar170975 commented 2 months ago

Card does not support jinja templates (and never did before). Please close if resolved. Suggest to ask questions here: https://community.home-assistant.io/t/lovelace-mini-graph-card/71385

P.S. There is a registered FR about supporting templates, you may find it & start monitoring.

Boerny41 commented 2 months ago

I'll ask in there, thanks for the link.

What is a "registered FR"?

ildar170975 commented 2 months ago

What is a "registered FR"?

feature request = issue containing a detailed description of a desired functionality.

I'll ask in there, thanks for the link.

There is nothing to ask in Community about THIS particular thing, templates are not supported...