thomasloven / lovelace-card-mod

🔹 Add CSS styles to (almost) any lovelace card
MIT License
1.12k stars 167 forks source link

Style syntax ignored when a theme is set #155

Closed vulcablack closed 8 months ago

vulcablack commented 2 years ago

My Home Assistant version: 2021.11.2

My lovelace configuration method (GUI or yaml): yaml

What I am doing: Setting active state color for button icons

What I expected to happen: Color to change when entity is active

What happened instead: Nothing, when "theme" is set

Minimal steps to reproduce:

Error messages from the browser console: Object { code: "template_error", message: "TemplateSyntaxError: expected token 'end of statement block', got 'if'" }


By putting an X in the boxes ([]) below, I indicate that I:

thomasloven commented 2 years ago

Try yaml card_mod: style: | ... instead.

ildar170975 commented 2 years ago
  • type: button

I think you should not use :host for button. Use ha-card instead.