hassio-conf/templates/kitchen.yaml
2024-10-17 21:45:45 +02:00

13 lines
481 B
YAML

- binary_sensor:
- name: ki_fridge_door_sensor_contact_state
state: "{{ states('binary_sensor.ki_fridge_door_sensor_contact') }}"
device_class: door
icon: >
{% if states.binary_sensor.ki_fridge_door_sensor_contact.state is defined %}
{% if is_state('binary_sensor.ki_fridge_door_sensor_contact', 'off') %}
mdi:fridge-industrial
{% else %}
mdi:fridge-industrial-alert-outline
{% endif %}
{% endif %}