HBO
January 10, 2025, 4:39pm
1080
I am trying to edit the mushroom light card, I want to increase the font size and increase the height of the card.
I tried the following:
card_mod:
style:
mushroom-state-info$: |
.container {
--card-secondary-font-size: 20px;
}
and
card_mod:
style: |
ha-card {
height: 100px !important;
}
works seperatly. But how to combine these? I cannot figure it out.
Frosty
January 10, 2025, 6:57pm
1081
type: custom:mushroom-light-card
entity: light.bridge_light
card_mod:
style:
mushroom-state-info$: |
.container {
--card-secondary-font-size: 20px;
}
.: |
ha-card {
height: 100px !important;
}
2 Likes
ChenH
(chen )
January 12, 2025, 10:00am
1082
How can I move the rectangle a bit down?
Please post your card code.
ChenH
(chen )
January 12, 2025, 10:14am
1084
type: custom:stack-in-card
mode: horizontal
cards:
type: custom:mushroom-template-card
entity: XXXXXXXXXXXX
icon: mdi:sprinkler-variant
tap_action:
action: toggle
data:
bed_side: XXXXXXX
timer: timer.sh_vn_hshqyyh
target: {}
icon_color: “{% if is_state(‘XXXXXXX’,‘on’)%}green{%else%}{%endif%}”
primary: השקייה אחורית
card_mod:
style:
.: |
ha-card {
width: 200px;
min-height: 70px;
background: none !important;
border: none !important;
box-shadow: none !important;
}
mushroom-shape-icon $: |
div {
box-shadow: -4px -4px 5px rgba(255, 255, 255, 0.3),
4px 4px 5px 1px rgba(00, 00, 00, 0.3),
inset 1px 1px 2px 0px rgba(255, 255, 255, 0.10),
inset -1px -1px 2px 1.5px rgba(00, 00, 00, 0.10) !important;
border: none;
border-radius: 50px !important;
outline: none;
display: flex;
align-items: center;
justify-content: center;
width: 48px !important;
height: 48px !important;
box-sizing: border-box;
type: conditional
conditions:
entity: XXXXXXX
state: “off”
card:
type: custom:mushroom-number-card
entity: input_number.zmn_hshqyyh
primary_info: none
fill_container: false
hold_action:
action: none
double_tap_action:
action: none
display_mode: buttons
layout: horizontal
icon_type: none
secondary_info: none
card_mod:
style:
.: |
ha-card {
width: 200px;
min-height: 70px;
background: none !important;
border: none !important;
box-shadow: none !important;
}
mushroom-number-value-control$: |
mushroom-input-number {
font-size: 14px;
–text-color: black;
–icon-color: blue;
–bg-color: rgba(var(–rgb-black), 0.05);
}
type: conditional
conditions:
entity: XXXXXXX
state: “on”
entity: timer.sh_vn_hshqyyh
state: active
card:
type: custom:timer-bar-card
entities:
timer.sh_vn_hshqyyh
sync_issues: ignore
compressed: true
bar_radius: 4px
text_width: 40px
layout: full_row
bar_foreground: orange
icon: mdi:stop-circle
tap_action:
action: none
Check out this link to format your code. #11
Before we begin…
This forum is not a helpdesk
The people here don’t work for Home Assistant, that’s an open source project. We are volunteering our free time to help others. Not all topics may get an answer, never mind one that helps you solve your problem.
[image]
This also isn’t a general home automation forum, this is a forum for Home Assistant and things related to it. Any question about Home Assistant, and about using things with Home Assistant, is welcome here. We can’t help you with eve…
It helps expedite resolutions.
1 Like
HBO
January 12, 2025, 2:19pm
1086
I want to change the background of my light card based on the state. When the light is on, I want an yellow background and a dark yellow border. How can I achieve this? the solutions from chatgpt didnt work.
this is my current code:
type: custom:mushroom-light-card
entity: light.hue_white_light_1
show_brightness_control: true
fill_container: false
use_light_color: false
show_color_temp_control: false
show_color_control: false
collapsible_controls: false
layout: horizontal
secondary_info: none
name: Spots
card_mod:
style:
mushroom-state-info$: |
.container {
--card-primary-font-size: 22px;
}
.: |
ha-card {
height: 80px !important;
background-color: rgba(245, 245, 245, 0.1); /* Grijze achtergrond */
border: 5px solid rgb(100,100,100); /* Donkergrijze rand */
border-radius: 10px; /* Optioneel: afgeronde hoeken */
}
HBO:
light.hue_white_light_1
Test this out…
type: custom:mushroom-light-card
entity: light.hue_white_light_1
show_brightness_control: true
fill_container: false
use_light_color: false
show_color_temp_control: false
show_color_control: false
collapsible_controls: false
layout: horizontal
secondary_info: none
name: Spots
card_mod:
style: |
ha-card {
background-color: {{ 'yellow' if is_state(config.entity, 'on') else 'grey' }} !important;
border-color: {{ 'goldenrod' if is_state(config.entity, 'on') else 'grey' }} !important;
border-width: 5px !important;
--card-primary-font-size: 22px;
height: 80px !important;
border-radius: 10px;
}
1 Like
GSD
(Gabriel Dragan)
January 13, 2025, 10:54am
1088
Hi,
Is there a way to force the list in the Select Card to always drop to bottom?
Thank you!
Do you still need assistance with the Select card?
GSD
(Gabriel Dragan)
January 14, 2025, 5:43am
1091
Yes please. Couldn’t figure out how.
Can you be a little clear about what “always drop to bottom? ” means?
I took a little time to messing with the code, but was unsure exactly what you were looking for.
Simple Example
type: custom:mushroom-select-card
entity: input_select.test
card_mod:
style:
mushroom-select-option-control$:
mushroom-select$:
mwc-menu $: |
mwc-list {
height: 480px !important;
}
That helps a bunch. I’ll take a look.
GSD
(Gabriel Dragan)
January 14, 2025, 8:39am
1096
Sorry, not sure what to look at. Couldn’t find anything related.
This portion…
card_mod:
style:
mushroom-select-option-control$:
mushroom-select$: |
.mdc-select__anchor{
background: none !important;
border-radius: 20px !important;
}
.mdc-line-ripple::before {
border-bottom-width: 0px !important;
}
.mdc-line-ripple::after {
border-bottom-width: 0px !important;
}
.mdc-select__selected-text {
color: transparent !important;
}
.mdc-select__dropdown-icon {
fill: transparent !important;
}
.mdc-select {
position: absolute !important;
width: 100% !important;
--select-height: 97px;
top: 0%;
right: 0%;
}
GSD
(Gabriel Dragan)
January 14, 2025, 9:08am
1098
OK, I’ll look into it when I get home and let you know how it works. Thank you!
GSD
(Gabriel Dragan)
January 14, 2025, 12:31pm
1099
So far this is what I’ve found while inspecting the CSS. It seems that the list is created under the “.mdc-menu-surface” class, and one property that drew my attention was “transform-origin”, not sure if I’m on the right track though, nor how to reference that, in order to overwrite the properties there.