more-info-camera: disable "download_snapshot" if idle (#25027)

* disable download_snapshot if idle

* prettier
This commit is contained in:
ildar170975 2025-04-13 10:02:36 +03:00 committed by GitHub
parent f4e3fdb98e
commit 6793753755
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -45,7 +45,8 @@ class MoreInfoCamera extends LitElement {
<ha-progress-button
@click=${this._downloadSnapshot}
.progress=${this._waiting}
.disabled=${this.stateObj.state === UNAVAILABLE}
.disabled=${this.stateObj.state === UNAVAILABLE ||
this.stateObj.state === "idle"}
>
${this.hass.localize(
"ui.dialogs.more_info_control.camera.download_snapshot"