HI,
Is there any way to get a gauge to blink when in certain %? I’m trying to get my solar battery gauge card to blink when below 20%, and gauge card to blink when consumption is more than 6kw/h.
Welcome, you’ll need the Card Mod addon
type: gauge
entity: input_number.test3
card_mod:
style: |
ha-card {
{% if states('input_number.test3') | int <= 20 %}
animation: blink 2s linear infinite;
{% endif %}
}
@keyframes blink {
100% {opacity: 0;}
}
refer and post to this thread if you choose to install Card Mod
Thank you so much, new to Ha with no coding experience, so every day is a learning curve. Is there a way that I can change the background color to blink red? Once again…THANK YOU!!!
Yes
type: gauge
entity: input_number.test3
card_mod:
style: |
ha-card {
{% if states('input_number.test3') | int <= 20 %}
animation: blink 2s linear infinite;
background: red;
{% endif %} }
@keyframes blink {
100% {opacity: 0;}
}
Thank you, works 100%. I hope I will be able to be of help to someone to, in the future!
I would like to make a gauge “Car Battery” blink when the car is charging …
when entity “Mercedes GLA250e Charging Power” is NOT zero, it means the car is charging, and then the gauge should blink (or change its background color, or whatever other indication …)
when entity “Mercedes GLA250e Charging Power” is back to zero, it means the car is charged and the gauge should display “normal” …
I feel it could be done, but I’m a newbie at yaml … so please help …