I’m working a dashboard and need to style out Expander Card. Expander Card is creating a Vertical Stack Card; the only way I can figure out how to apply styles is to wrap it with Card Mod; but I’m getting a “You’re doing it wrong” notice in the terminal.
Anyone know of a better way to do this without breaking things?
- type: custom:mod-card
style: |
ha-card {
border: 1px solid #FFFFFF;
background: #004068;
}
card:
type: custom:expander-card
title: Kitchen
button-background: 4068
expanded: false
padding: '0'
child-padding: '0'
gap: '0'
clear: true
title-card:
type: custom:mushroom-light-card
entity: light.kitchen_lights
name: Kitchen
show_brightness_control: true
layout: horizontal
icon_type: icon
icon: mdi:countertop
secondary_info: none
icon_color: yellow
card_mod:
style:
mushroom-shape-icon$: |
.shape {
background: #004068 !important;
border: 1px solid #236289;
}
mushroom-light-brightness-control$: |
mushroom-slider {
--main-color: #3596d3 !important;
--bg-color: #82cbf8 !important;
}
.: |
ha-card {
background: #004068;
border: transparent;
}
cards:
- type: custom:mushroom-light-card
entity: light.kitchen_can_lights_island
name: Island
show_brightness_control: true
layout: horizontal
icon_color: yellow
secondary_info: none
card_mod:
style:
mushroom-shape-icon$: |
.shape {
background: #004068 !important;
border: 1px solid #236289;
}
mushroom-light-brightness-control$: |
mushroom-slider {
--main-color: #3596d3 !important;
--bg-color: #82cbf8 !important;
}
.: |
ha-card {
background: #004068;
border: transparent;
}
- type: custom:mushroom-light-card
entity: light.kitchen_can_lights_table
name: Table
show_brightness_control: true
layout: horizontal
icon_color: yellow
secondary_info: none
card_mod:
style:
mushroom-shape-icon$: |
.shape {
background: #004068 !important;
border: 1px solid #236289;
}
mushroom-light-brightness-control$: |
mushroom-slider {
--main-color: #3596d3 !important;
--bg-color: #82cbf8 !important;
}
.: |
ha-card {
background: #004068;
border: transparent;
}
- type: custom:mushroom-light-card
entity: light.kitchen_china_cabinet
name: China Cabinet
show_brightness_control: true
layout: horizontal
icon_color: yellow
secondary_info: none
card_mod:
style:
mushroom-shape-icon$: |
.shape {
background: #004068 !important;
border: 1px solid #236289;
}
mushroom-light-brightness-control$: |
mushroom-slider {
--main-color: #3596d3 !important;
--bg-color: #82cbf8 !important;
}
.: |
ha-card {
background: #004068;
border: transparent;
}
- type: horizontal-stack
cards:
- type: button
name: Island
show_name: true
show_icon: true
tap_action:
action: toggle
entity: switch.kitchen_island_light
card_mod:
style: |
ha-card {
background: #004068;
border: transparent;
font-size: 12px !important;
}
- type: button
name: Kitchen Up
show_name: true
show_icon: true
tap_action:
action: toggle
entity: script.shades_kitchen_all_up_script
card_mod:
style: |
ha-card {
background: #004068;
border: transparent;
font-size: 12px !important;
}
- type: button
name: Kitchen Down
show_name: true
show_icon: true
tap_action:
action: toggle
entity: script.shades_kitchen_all_down_script
card_mod:
style: |
ha-card {
background: #004068;
border: transparent;
font-size: 12px !important;
}