Mushroom Cards - Build a beautiful dashboard easily 🍄 (Part 1)

It sounds like lovelace was caching your images. You can add a ‘?v=1’ to the image URL to get it to reload the images.

1 Like

Thank you again… that fixed the original url I was using…

My pleasure :grinning:

1 Like

Just started playing with Mushroom cards yesterday LOL I must admit they are fun and interesting!! PLUS I can use templates directly in them and it makes sense to me!!!

Where’d you get the pics? Those look good.

I found some here. They just need to be resized.

Moon Phases by bthoven

2 Likes

While you wait for the new feature, you can achieve what you want with a little CSS.

Vertical:

type: custom:mushroom-template-card
icon: mdi
primary: LS50
secondary: '{{ ''On'' if is_state(entity, ''on'') else ''Off'' }} '
entity: switch.ls50-1
fill_container: false
multiline_secondary: false
layout: vertical
card_mod:
   style: |
     mushroom-card {
       background: var(--card-background-color) url( '/local/LS50.png' ) no-repeat center 0px;
       background-size: 42px 42px;
       {% if is_state(config.entity, 'on') %}
       {% else %}
         filter: grayscale(100%);
       {% endif %} 
     }

Horizontal:

type: custom:mushroom-template-card
icon: mdi
primary: LS50
secondary: '{{ ''On'' if is_state(entity, ''on'') else ''Off'' }} '
entity: switch.ls50-2
fill_container: false
multiline_secondary: false
card_mod:
   style: |
     mushroom-card {
       background: var(--card-background-color) url( '/local/LS50.png' ) no-repeat 0px center;
       background-size: 42px 42px;
       {% if is_state(config.entity, 'on') %}
       {% else %}
         filter: grayscale(100%);
       {% endif %} 
     }

Rounded:

type: custom:mushroom-template-card
icon: mdi
primary: LS50
secondary: '{{ ''On'' if is_state(entity, ''on'') else ''Off'' }} '
entity: switch.ls50-3
fill_container: false
multiline_secondary: false
layout: vertical
card_mod:
   style: |
     mushroom-card {
       background: var(--card-background-color) url( '/local/LS50.png' ) no-repeat center 0px;
       background-size: 42px 42px;
       {% if is_state(config.entity, 'on') %}
       {% else %}
         filter: grayscale(100%);
       {% endif %} 
     }
     ha-card {
       width: 66px;
       border-radius: 30px;
       margin-left: auto;
       margin-right: auto;
     }

Edit: Update to stop icon floating in

13 Likes

Yes those are the ones I have :slight_smile:

Those are excellent!! Thank you so much!

So I’m using a cover card to control my two garage doors and would like to be able to make the open and close buttons a little less vulnerable to accidental activation. Is there any way to change them from a tap action to a hold action?

I love seeing the album art in my media players, but wanted to keep the Mushroom aesthetic. What do I do?

This one took a bit of figuring out. The problem was having the background overlay adapting to dark & light themes. I like the result, I hope you do too.

Media Player Dark:

Media Player Light:

type: custom:mushroom-media-player-card
entity: media_player.lounge
use_media_artwork: false
use_media_info: true
media_controls:
  - play_pause_stop
  - previous
  - next
collapsible_controls: true
volume_controls:
  - volume_set
show_volume_level: false
fill_container: false
tap_action:
  action: toggle
card_mod:
   style: |
     ha-card {
       {% if not is_state(config.entity, 'off') %}
         background-image: url( '{{ state_attr( config.entity, "entity_picture" ) }}' );
         background-position: center;
         background-repeat: no-repeat;
         background-size: cover;
         position: relative;
         background-blend-mode: overlay;
         background-color: rgba(var(--rgb-card-background-color),0.5);
       {% endif %}  
     }
23 Likes

Hi Rhys,

Look nice, just tried your code but… seems background is still overlay.

Any idea ?

2022-06-06 08_56_20-Overview – Home Assistant

made you beautiful.
I added this one too, but it looks slightly different.
what could that be?
I have created an input boolean switch.

you drop down looks different from mine

Schermafbeelding 2022-06-06 om 09.39.56
Schermafbeelding 2022-06-06 om 09.46.16

Share my media card here.
Thanks for the great mushrooms…

8 Likes

I have minimalist-desktop theme enabled. It seems that --rgb-primary-background-color is present in the Minimalist theme but not Mushroom theme. I’ll see if I can find another one to use.

1 Like

Do you have card-mod installed?

Nope, not installed yet.
Only Mushroom & Mushroom themes.

Ok, try installing card-mod. That does the fun CSS stuff.

thanks, that looks much better already!
Schermafbeelding 2022-06-06 om 11.53.30

Change --rgb-primary-background-color to --rgb-card-background-color. Should fix it for Mushroom theme.