artem-sedykh / mini-climate-card

Minimalistic climate card for Home Assistant Lovelace UI
MIT License
262 stars 19 forks source link

Button Color change not working in themes #142

Closed i4mr000t closed 5 months ago

i4mr000t commented 5 months ago

I would like to change the button color in my theme but its not working. i tried to set icon & button color to white in my_theme.yaml

my_theme:
  mini-climate-icon-color: "#FFFFFF"
  mini-climate-button-color: "#FFFFFF"

The first one (icon-color) is working as expected but the second does not. It doesn´t change color to white. It stays default as yellow

regevbr commented 5 months ago

screenshot please so I can be sure on what icon you are referring to

i4mr000t commented 5 months ago

image

regevbr commented 5 months ago

yellow is the default value for active buttons. You need to change state-binary_sensor-active-color

i4mr000t commented 5 months ago

in that same file?

theme:
  mini-climate-icon-color: "#FFFFFF"
  mini-climate-button-color: "#FFFFFF"
  state-binary_sensor-active-color: "#FFFFFF"
regevbr commented 5 months ago

Think so never tried it before

i4mr000t commented 5 months ago

it doesnt work....

i4mr000t commented 5 months ago

is it possible to change the upper left icon as well?

regevbr commented 5 months ago

It works great, you need to call the frontend them reload service to see the changes

regevbr commented 5 months ago

image

i4mr000t commented 5 months ago

ok thx. i will try that

regevbr commented 5 months ago

It should affect the upper icon as well

i4mr000t commented 5 months ago

i restarted homeassistant but it didnt change color.

what do you exactly mean with call frontend and restart service?

regevbr commented 5 months ago

image

i4mr000t commented 5 months ago

it doenst work.

i did a service restart. restarted homeassistant. cleared browser cache. no error in yaml.... idk

regevbr commented 5 months ago

No idea, you will have to use the debug console to understand where the color comes from on the HTML element

regevbr commented 5 months ago

Just another guess - seems you have dark mode enabled. maybe you need to do something like the following:


frontend:
  themes:
    default2:
      ha-card-border-width: 0px
      ha-card-border-radius: 0px
      modes:
        dark:
          ha-card-border-width: 1px
          ha-card-border-radius: 0px
i4mr000t commented 5 months ago

yes i have it enabled but tried your suggestions without success

regevbr commented 5 months ago

Sorry not sure I can help. Are you sure you are on the latest version of the plugin?

i4mr000t commented 5 months ago

no im not 100% sure. will check it immediatly :-D

i4mr000t commented 5 months ago

im on the latest release

regevbr commented 5 months ago

Sorry, you will have to debug yourself

i4mr000t commented 5 months ago

ok thank you anyway for the fast reply :-)

i4mr000t commented 5 months ago

this one was the right:

state-binary_sensor-active-color: "#FFFFFF"

i dont know how but now i got it. did the same as before....