diff --git a/src/panels/lovelace/components/hui-image.ts b/src/panels/lovelace/components/hui-image.ts index 555bca93ad..573210f86d 100644 --- a/src/panels/lovelace/components/hui-image.ts +++ b/src/panels/lovelace/components/hui-image.ts @@ -193,7 +193,7 @@ export class HuiImage extends LitElement { style=${styleMap({ paddingBottom: useRatio ? `${((100 * this._ratio!.h) / this._ratio!.w).toFixed(2)}%` - : !this._lastImageHeight + : this._lastImageHeight === undefined ? "56.25%" : undefined, backgroundImage: @@ -206,7 +206,7 @@ export class HuiImage extends LitElement { : undefined, })} class="container ${classMap({ - ratio: useRatio || !this._lastImageHeight, + ratio: useRatio || this._lastImageHeight === undefined, })}" > ${this.cameraImage && this.cameraView === "live"