diff --git a/src/components/Dashboard/common/HistoryDisplay.jsx b/src/components/Dashboard/common/HistoryDisplay.jsx index ae03bcd5..cfd86243 100644 --- a/src/components/Dashboard/common/HistoryDisplay.jsx +++ b/src/components/Dashboard/common/HistoryDisplay.jsx @@ -204,8 +204,11 @@ const HistoryDisplay = ({ }) }, [config, themeColors]) - const { slotRef, measureRef, overlay: legendOverflow } = - useHistoryLegendOverlay(seriesLabels) + const { + slotRef, + measureRef, + overlay: legendOverflow + } = useHistoryLegendOverlay(seriesLabels) if (!objectType || !config) { return null @@ -247,9 +250,9 @@ const HistoryDisplay = ({ return ( - + {!startDate && !endDate && ( @@ -325,6 +328,7 @@ const HistoryDisplay = ({ style={{ height: toCssHeight(height), display: 'flex', + gap: 12, flexDirection: 'column', minHeight: 0 }} @@ -334,8 +338,7 @@ const HistoryDisplay = ({ style={{ flexShrink: 0, display: 'flex', - justifyContent: 'center', - paddingBottom: 4 + justifyContent: 'center' }} > )} -
+
{chartRows.length > 0 && ( )} {loading == false && chartRows.length == 0 && ( - + )} diff --git a/src/components/Dashboard/common/ModelHistoryDisplay.jsx b/src/components/Dashboard/common/ModelHistoryDisplay.jsx index 618fa03d..8a49af56 100644 --- a/src/components/Dashboard/common/ModelHistoryDisplay.jsx +++ b/src/components/Dashboard/common/ModelHistoryDisplay.jsx @@ -164,8 +164,11 @@ const ModelHistoryDisplay = ({ }) }, [modelStats, themeColors]) - const { slotRef, measureRef, overlay: legendOverflow } = - useHistoryLegendOverlay(seriesLabels) + const { + slotRef, + measureRef, + overlay: legendOverflow + } = useHistoryLegendOverlay(seriesLabels) if (!objectType) { return null @@ -371,9 +374,9 @@ const ModelHistoryDisplay = ({ return ( - + {!startDate && !endDate && ( @@ -434,7 +437,9 @@ const ModelHistoryDisplay = ({ {!startDate && !endDate && ( <> - {loading == true && chartRows.length != 0 && } + {loading == true && chartRows.length != 0 && ( + + )}
)} -
+
{chartRows.length > 0 && ( )} {loading == true && chartRows.length == 0 && ( - + )} {loading == false && chartRows.length == 0 && ( - + )}