1twan
June 6, 2025, 8:30pm
1
Dear all,
I am trying to fix some buttons with the mushroom entity card with card mod install. Everything works fine, and after some editing I get some nice button.
When I click save, the button is saved and everybody is happy you would say. Unless you want to edit it again, now the code is gone again and the button looks very default. I am running the latest HA 2025.5 with all the updates done as of today. So after I click edit again, or if I want to duplicate it, everything is gone.
Help is greatly appreciated
Regards,
Twan
1twan
June 6, 2025, 8:35pm
2
Since I can add only one embedded item, this is how it looks after I saved it, and click edit again. This goes for all the mushroom card apparently.
karwosts
(karwosts)
June 6, 2025, 8:36pm
3
Sounds like a card-mod bug:
opened 09:08PM - 30 Dec 23 UTC
Chrome 120.0.6099.130 (Win10x64).
FF 121 (Win10x64).
My Home Assistant vers… ion: 2023.12.1
My lovelace configuration method (GUI or yaml): storage
What I am doing:
Adding card-mod code for `custom:bar-card` inside a standard `vertical-stack`.
Using a standard HA UI editor.
What I expected to happen:
Card-mod code is saved after saving a card.
What happened instead:
1. Either card-mod code is not saved after saving a card.
2. Or card-mod code is automatically deleted after typing.
**Minimal** steps to reproduce:
1. Add a new card - select any card like "Alarm card".
2. Switch to yaml editor.
3. Paste a code provided below.
4. Start typing "card_mod" for the "bar-card".
5. If you manage to type the "card_mod" line - then type the whole card-mod code (see below).
6. Save the card.
7. Reopen the card in the Editor.
8. Check that card-mod code was deleted.
9. Start typing card-mod again.
10. Check that "card_mod" line is auto-deleted after typing.

```
type: vertical-stack
cards:
- type: custom:bar-card
entities:
- entity: sensor.processor_use
```
```
type: vertical-stack
cards:
- type: custom:bar-card
entities:
- entity: sensor.processor_use
card_mod:
style: |
ha-card {color: red;}
```
Error messages from the browser console:
none related.
---
**By putting an X in the boxes ([]) below, I indicate that I:**
- [x] Understand that this is a channel for reporting bugs, not a support forum (https://community.home-assistant.io/).
- [x] Have made sure I am using the latest version of the plugin.
- [x] Have followed the troubleshooting steps of the "Common Problems" section of https://github.com/thomasloven/hass-config/wiki/Lovelace-Plugins.
- [x] Understand that leaving one or more boxes unticked or failure to follow the template above may increase the time required to handle my bug-report, or cause it to be closed without further action.
1 Like
1twan
June 6, 2025, 8:49pm
4
Thanks! You pointed me in the right direction.
I removed:
frontend:
extra_module_url:
- /hacsfiles/lovelace-card-mod/card-mod.js
From configuration.yaml and cleared my browser cache as decribed here:
https://github.com/thomasloven/lovelace-card-mod/issues/337#issuecomment-1884560935
This is a great forum should have subscribed when I started with HA
Regards and thanks again,
Twan
1twan:
removed
This is not a “solution” and in general does not help to fix the issue; but it is good that you stopped observing the issue.