Closed paolo1983 closed 6 months ago
Why this style should work? The fact that this style worked before does not mean that this is going to be forever since the Tile card may be changed in HA. Have you checked a content of this card in Code Inspector? Probably the Tile card's structure changed - that is why your old style stopped working. Now you will have to find out how to style the new changed card.
P.S. what is a "tile color"? Is it a color of the card or some card's element?
Sorry i'm not Expert. Yeah i mean the icon color of tile. With my config i changed It by status of entity (with if then else check). Can you help me to find the new code to change the icon color instead "--tile-color: red"? I'm not able to use inspect Sorry Thanks
card_mod:
style: |
.tile {
{% if states(config.entity)|float(0) > 3000 %}
--tile-color: red;
{% elif states(config.entity)|float(0) > 1500 %}
--tile-color: yellow;
{% else %}
--tile-color: green;
{% endif %}
}
Inability to style some UI element could be a bug. But also could be a "user does not know". So, suggest to ask this questions in the dedicated card-mod Community thread (in general, questions should be asked in Community, Github should be used for reporting bugs & proposing FRs). If it turns out that this is a bug - then you will give it a go here.
Ok thanks! Have a good day Ciao
Try this:
card_mod:
style: |
ha-card {
--tile-color: green !important;
}
Consider closing the issue if you can solve your task with this proposal.
Friends thanks you very much It works. I have to offer you a beer! Thanks!
My Home Assistant version: december 2023
My lovelace configuration method: yaml
What I am doing:
What I expected to happen:
The tile color should become Red
What happened instead:
The tile color doesn't change (It remains black)
This issue Is started with december version of home assistant. I'm using this config since 1 year and It always worked until the previous home assistant version (November)