fix(color): color wouldn't follow light color with `color: auto`

Fixes #737
This commit is contained in:
Jérôme Wiedemann 2023-08-03 13:22:59 +00:00
parent 0bf22d5c43
commit b63f0db220
1 changed files with 1 additions and 1 deletions

View File

@ -604,7 +604,7 @@ class ButtonCard extends LitElement {
colorValue = this._config!.color;
}
if (AUTO_COLORS.includes(colorValue)) {
if (!state || (state && !(computeDomain(state.entity_id) !== 'light'))) {
if (!state || (state && computeDomain(state.entity_id) !== 'light')) {
colorValue = '';
}
}