Fix scenes activate button being disabled (#11145)

This commit is contained in:
Paulus Schoutsen 2022-01-10 13:45:41 -08:00 committed by GitHub
parent 27fa34e24e
commit 3e22270c2c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9,7 +9,7 @@ import {
} from "lit";
import { customElement, property, state } from "lit/decorators";
import "../../../components/entity/ha-entity-toggle";
import { UNAVAILABLE_STATES } from "../../../data/entity";
import { UNAVAILABLE } from "../../../data/entity";
import { activateScene } from "../../../data/scene";
import { HomeAssistant } from "../../../types";
import { hasConfigOrEntityChanged } from "../common/has-changed";
@ -53,7 +53,7 @@ class HuiSceneEntityRow extends LitElement implements LovelaceRow {
<hui-generic-entity-row .hass=${this.hass} .config=${this._config}>
<mwc-button
@click=${this._callService}
.disabled=${UNAVAILABLE_STATES.includes(stateObj.state)}
.disabled=${stateObj.state === UNAVAILABLE}
class="text-content"
>
${this._config.action_name ||