Icon templates for presence sensors

This commit is contained in:
2022-08-31 09:40:51 -04:00
parent 7c59d8a409
commit 978e8aa8e2

View File

@ -60,6 +60,13 @@ sensor:
{{ states('person.tony_stork') }}
{%- endif %}
{%- endif %}
icon_template: >-
{% set person = states.person.tony_stork.state %}
{% if person in ['Home','home'] %}
mdi:home
{% else %}
mdi:car
{% endif %}
- platform: template
sensors:
tina_location:
@ -80,6 +87,13 @@ sensor:
{{ states('person.christina_stork') }}
{%- endif %}
{%- endif %}
icon_template: >-
{% set person = states.person.christina_stork.state %}
{% if person in ['Home','home'] %}
mdi:home
{% else %}
mdi:car
{% endif %}
- platform: template
sensors:
kallen_location: