Yoinkz
December 26, 2018, 7:14pm
1
Hi,
I’ve been playing around with the vertical-stack function in my lovelace ui and it seems to do exactly what I was looking for. One of the things that I just can’t get working is the conditional card, while using it along with other entities.
I have this one, which works:
cards:
- entities:
- light.led_hobbyrum
- input_boolean.disable_motionsensor_hobbyroom_automation
- light.hobbyrum_ikea_light
title: Lys
type: entities
type: vertical-stack
What I’m trying to add is this, but no matter how I format the syntax it doesn’t work out for me:
type: conditional
conditions:
- entity: light.hobbyrum_ikea_lys
state: 'on'
card:
type: entities
entities:
- light.hobbyroom_led1
- light.hobbyroom_led2
- light.hobbyroom_led3
- light.hobbyroom_led4
- light.hobbyroom_led5
- light.hobbyroom_led6
- light.hobbyroom_led7
The above works alone.
How can I merge the two of them? I want only the LED1-7 to be shown if the condition is true.
Thanks…
Hi, not 100% sure, but the conditional impacts entire card, and not separate entities?
Here is an example of a vertical stack card that is shown only when it’s not summer.
The vertical stack has 3 other cards - an entities card, a picture-elements and a history graph card.
type: conditional
conditions:
- entity: sensor.season
state_not: "summer"
card:
type: vertical-stack
cards:
- entities:
- entity: sensor.temperature
name: Temperature
- entity: switch.heater_switch
name: Heater Switch
show_header_toggle: false
type: entities
- elements:
- entity: sensor.insolation
prefix: 'Insolation '
style:
font-size: 17px
left: 50%
top: 55%
tap_action:
action: more-info
type: state-label
- entity: sensor.heater_temp_0
style:
font-size: 17px
left: 90%
top: 10%
type: state-label
- entity: sensor.heater_temp_1
style:
font-size: 17px
left: 90%
top: 30%
type: state-label
image: /local/some-solar-water-heater-image.png
type: picture-elements
- entities:
- entity: sensor.insolation
name: Insolation
- entity: sensor.ideal_insolation
name: Ideal
- entity: sensor.cloud_coverage
hours_to_show: 48
refresh_interval: 120
type: history-graph