Turn off cameras if anyone is home

This commit is contained in:
Thomas Lovén 2019-05-23 12:36:26 +02:00
parent b1b83a8a29
commit 151804e7a9
3 changed files with 21 additions and 7 deletions

View File

@ -1,5 +1,6 @@
{% set entity='"camera.barnrum"' %}
type: picture-elements
title: Barnrum
image: /local/images/placeholder-1280x720.png
elements:
- type: image

View File

@ -1,7 +1,14 @@
type: picture-elements
title: Kontoret
image: /local/images/placeholder-800x600.png
elements:
- type: image
# Only show camera feed if noone is home
- type: custom:hui-conditional-card
conditions:
- entity: binary_sensor.home_occupied
state: "off"
card:
type: custom:hui-image-element
camera_image: camera.kontor
style:
left: 50%
@ -15,10 +22,10 @@ elements:
action: none
style:
left: 50%
top: 0%
height: 100px
top: 25px
height: 50px
width: 100%
background: rgba(0,0,0,0.3)
background: rgba(128,128,128,0.3)
- type: state-icon
entity: light.taklampa_kontoret

View File

@ -1,7 +1,13 @@
type: picture-elements
title: Vardagsrum
image: /local/images/placeholder-800x600.png
elements:
- type: image
- type: custom:hui-conditional-card
conditions:
- entity: binary_sensor.home_occupied
state: "off"
card:
type: custom:hui-image-element
camera_image: camera.vardagsrum
style:
left: 50%