diff --git a/src/components/chart/state-history-charts.ts b/src/components/chart/state-history-charts.ts index 0ce32a583e..2ed678b01c 100644 --- a/src/components/chart/state-history-charts.ts +++ b/src/components/chart/state-history-charts.ts @@ -184,7 +184,17 @@ export class StateHistoryCharts extends LitElement { }; protected shouldUpdate(changedProps: PropertyValues): boolean { - return !(changedProps.size === 1 && changedProps.has("hass")); + if (changedProps.size === 1 && changedProps.has("hass")) { + return false; + } + if ( + changedProps.size === 1 && + changedProps.has("_maxYWidth") && + changedProps.get("_maxYWidth") === this._maxYWidth + ) { + return false; + } + return true; } protected willUpdate() {