Hi guys, I’m trying out a floorplan with picture-elements for the first time after having installed HA last week.
I appear to have everything working on my floorplan and can correctly initiate the toggling of a Hue bulb by clicking on the image accordingly, but when I try and add another both bulbs don’t respond.
I have a left_bulb and right_bulb; if I place just the left in the code, it works. If I place just the right in the code, it works. If I have both, and left is first, left will work; if I have both, and right is first, right will work.
I’m using the below code - could someone advise where I’m going wrong please? (Forgive the poor formatting/lack of indentations - this didn’t seem to copy/paste across too well).
views:
- panel: true
title: Floor Plan
icon: 'mdi:floor-plan'
cards:
- type: picture-elements
image: /local/on.png
elements:
- type: image
entity: light.left_light
tap_action: none
hold_action: none
state_image:
'on': /local/transparent_square.png
'off': /local/right_light off.png
style:
top: 50%
left: 50%
width: 100%
- type: image
entity: light.left_light
tap_action:
action: toggle
image: /local/transparent_square.png
style:
top: 30%
left: 54.5%
border: 5px solid red
- type: image
entity: light.right_light
tap_action: none
hold_action: none
state_image:
'on': /local/transparent_square.png
'off': /local/left_light off.png
style:
top: 50%
left: 50%
width: 100%
- type: image
entity: light.right_light
tap_action:
action: toggle
image: /local/transparent_square.png
style:
top: 41%
left: 61.5%
width: 50px
height: 50px
border: 5px solid blue