-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Card Mod Styles Disappearing #23034
Comments
|
Do not reproduce with stock frontend. I do not use card mod but just doing this to note that the editor does not eat the keys on its own. Unless someone can show that the actual core frontend has a bug, I will probably close this as off topic, as it seems like a card mod bug. Can you reproduce this behavior of missing yaml in safe mode? I will say that I note that when I add a card_mod key it disables the visual editor. Yet in all the screenshots of this issue show card mod still has the visual editor available when using a card_mod key. I would tend to suspect something in the way that is hacked in might be contributing to this, I have seen issues where visual editor can mess up the yaml if it is not properly disabled. |
Try with custom:bar-card (thomasloven/lovelace-card-mod#337 (comment)), Tile (thomasloven/lovelace-card-mod#337 (comment)) |
Interesting that it disables the visual editor for you. When use the mushroom cards or vertical/horizontal stack it doesn't disable the editor when card_mod key is present. |
Correct I am not using card mod, I said that in my original post.
Just trying to prove that this is not something frontend is responsible for, and belongs on card mod repo. |
Seems to be so. Also,
I do you think that a custom bar-card may affect Editor differently than a stock Tile? Do not think so. |
I would suspect it's something related to custom visual editors. I suspect the visual editor is somehow eating it. Do not know if that behavior is part of custom bar-card or card-mod itself. |
As for card-mod - it does not have a custom visual editor. Interesting that it happens to some cards only. For instance, does not to Entities card - but does to Tile. |
When you add card_mod key to stock Tile, does it show the "visual editor disabled" warning? |
Some custom code you have installed is allowing you to use the visual editor still when unknown keys are present. I guess that has to be card mod patching over the normal code overriding that behavior. |
Hmm, this file (at least it's name) proves that card-mod does something to Editor. Another observation is that the problem more happens with cards with single "entity" key, not "entities". |
@karwosts, @ildar170975 type: entities
This allowed me to color the value and consequently the unit of measurement, leaving the entity text unchanged. Now, if I am not mistaken, the color variable is inherited from :host @karwosts, I understand your point of view, but since something broke the themes (I assume to several people), and the last card-mod update was on March 13, I don't agree with closing this bug. |
@ildar170975 |
This bug was about the visual editor only. It has nothing to do with your themes being applied outside the visual editor. |
Checklist
Describe the issue you are experiencing
I know card mod is custom but it appears that everytime I save a card mod style it saves but when I go to edit the card the style is removed so if I make a change elsewhere and save the styles are removed.
This is happening on all cards with different card mod style configurations.
I noticed this happening lately and I recall a similar issue years ago with fire dom event not being recognized by the frontend and dropping the keys.
Is it possible these keys are now being dropped too?
Describe the behavior you expected
My card mod style to be saved and still remain when I come back and edit the file.
Steps to reproduce the issue
...
What version of Home Assistant Core has the issue?
2024.11.3
What was the last working version of Home Assistant Core?
No response
In which browser are you experiencing the issue with?
Companion app
Which operating system are you using to run this browser?
No response
State of relevant entities
No response
Problem-relevant frontend configuration
No response
Javascript errors shown in your browser console/inspector
No response
Additional information
No response
The text was updated successfully, but these errors were encountered: