Hi all,
I’m creating a new dashboard for a tablet and one of the views i want to control only the lights. I want 2 columns. On the left are Buttons for the rooms/locations and the right are the lights for each location. I’ve created this so far and i’m just thinking a simpler way must exist as it’s pretty time consuming. Has anyone got any insights on a better way?
Family room concept
Kitchen Concept
On the right we have a horizontal stack card below that we have vertical stacks one for each button/location which are turned on when the input_boolean is triggered.
each button has a toggle helper/Input_boolean this is then used by the logic for card visibility below.
Logic example one required for each button. This only shows one vertical stack at a time without it you could have multiple stacks visible.
description: Family Room Lights ONLY visible
triggers:
- trigger: state
entity_id:
- input_boolean.family_room_lights_card_boolean
from: 'off'
to: 'on'
conditions: []
actions:
- target:
entity_id:
- input_boolean.kitchen_lights_card_boolean
- input_boolean.living_room_lights_card_boolean
action: input_boolean.turn_off
mode: single
yaml that genterates the right hand side column
type: horizontal-stack
cards:
- type: vertical-stack
cards:
- type: conditional
conditions:
- condition: state
entity: input_boolean.family_room_lights_card_boolean
state: "on"
card:
type: vertical-stack
cards:
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: light.family_room_lights
- type: markdown
content: "-------------------------------------------"
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: switch.familyroom_tx_ultimate_family_room_chandelier_l2
name: Sofa Area Chandelier
icon: mdi:chandelier
show_entity_picture: false
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: switch.familyroom_tx_ultimate_family_room_chandelier_l1
name: Dining Table Chandelier
icon: mdi:chandelier
show_entity_picture: false
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: light.family_down_light_lh
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: light.family_down_light_rh
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: light.extended_color_light_1_9
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
rows: 2
entity: light.extended_color_light_1_8
- type: conditional
conditions:
- condition: state
entity: input_boolean.kitchen_lights_card_boolean
state: "on"
card:
type: vertical-stack
cards:
- type: tile
entity: light.kitchen_light_group
features:
- type: light-brightness
grid_options:
columns: full
- type: markdown
content: "-------------------------------------------"
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.kitchen_light_step
name: Light Strip
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1_5
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1_2
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1_7
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1_3
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1_4
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_1_6
- features:
- type: light-brightness
type: tile
grid_options:
columns: full
entity: light.extended_color_light_2