diff --git a/src/chart/canvas/canvas-bounds-container.ts b/src/chart/canvas/canvas-bounds-container.ts index ddb0155..2a02b5b 100644 --- a/src/chart/canvas/canvas-bounds-container.ts +++ b/src/chart/canvas/canvas-bounds-container.ts @@ -1,8 +1,3 @@ -/* - * Copyright (C) 2019 - 2024 Devexperts Solutions IE Limited - * This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. - * If a copy of the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/. - */ /* * Copyright (C) 2019 - 2024 Devexperts Solutions IE Limited * This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. @@ -560,11 +555,11 @@ export class CanvasBoundsContainer { } //#region chart height ratio logic - if (this.graphsHeightRatio[CHART_UUID] === 0) { + if (!this.graphsHeightRatio[CHART_UUID] || this.graphsHeightRatio[CHART_UUID] === 0) { chartRatio = 0; } - if (this.graphsHeightRatio[CHART_UUID] !== 0) { + if (this.graphsHeightRatio[CHART_UUID] && this.graphsHeightRatio[CHART_UUID] !== 0) { if (paneIsAdded) { chartRatio = 1 * ratioForOldPec; } else {