So considering the image attached, is it possible to somehow use dynamic names for the cards?
In this case I would like to show the remaining battery percentage.
Yeah, I just could add new sensor card for this but just wondering other options.
You can do it with this:
Oh, cool! Thanks for the tip! Seem to work just like I wanted!
This Home Assistant is just awesome platform! And the whole community for sure!
If you don’t like javascript too much, you can use css as well…
type: entities
entities:
- entity: lock.entrance_door_lock
card_mod:
style: |
{% if states('lock.entrance_door_lock') == "locked" %}
:host {color: lime}
{% else %}
:host {display:none !important}
{% endif %}
name: Door Locked
- entity: lock.entrance_door_lock
card_mod:
style: |
{% if states('lock.entrance_door_lock') == "unlocked" %}
:host {color: red}
{% else %}
:host {display:none !important}
{% endif %}
name: Door Unlocked
title: Entrance Door