From d9ecb0c2fd44b85a24fa0426b17f76880dd64997 Mon Sep 17 00:00:00 2001 From: Bartosz Prusinowski Date: Mon, 8 Jul 2024 15:49:41 +0200 Subject: [PATCH] fix: Editing aspect ratio --- CHANGELOG.md | 3 ++- app/charts/shared/containers.tsx | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cb568ed52..ecb649fd5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,7 +11,8 @@ You can also check the # Unreleased -Nothing yet. +- Fixes + - Going back to edit mode from free canvas layout no longer hides the chart # [4.7.1] - 2024-07-08 diff --git a/app/charts/shared/containers.tsx b/app/charts/shared/containers.tsx index ebb6fb470..8895770ce 100644 --- a/app/charts/shared/containers.tsx +++ b/app/charts/shared/containers.tsx @@ -10,6 +10,7 @@ import { useObserverRef } from "@/charts/shared/use-size"; import { ChartConfig, hasChartConfigs, + isConfiguring, useConfiguratorState, } from "@/configurator"; import { useTransitionStore } from "@/stores/transition"; @@ -67,7 +68,9 @@ export const ChartContainer = ({ className={clsx( classes.chartContainer, classes[type], - state.layout.type === "dashboard" && state.layout.layout === "canvas" + !isConfiguring(state) && + state.layout.type === "dashboard" && + state.layout.layout === "canvas" ? null : classes.constrainMinHeight )}