diff --git a/frontend/app/components/Dashboard/components/WidgetChart/WidgetChart.tsx b/frontend/app/components/Dashboard/components/WidgetChart/WidgetChart.tsx index 0858b41af..809f0977a 100644 --- a/frontend/app/components/Dashboard/components/WidgetChart/WidgetChart.tsx +++ b/frontend/app/components/Dashboard/components/WidgetChart/WidgetChart.tsx @@ -197,10 +197,10 @@ function WidgetChart(props: Props) { if (!inView || !props.isPreview) return; loadComparisonData(); }, [ - dashboardStore.comparisonPeriods[_metric.metricId], - _metric.metricId, inView, props.isPreview, + dashboardStore.comparisonPeriods[_metric.metricId], + _metric.metricId, drillDownPeriod, period, depsString, diff --git a/frontend/app/components/Dashboard/components/WidgetDateRange/WidgetDateRange.tsx b/frontend/app/components/Dashboard/components/WidgetDateRange/WidgetDateRange.tsx index 40f688f32..b8f5158cd 100644 --- a/frontend/app/components/Dashboard/components/WidgetDateRange/WidgetDateRange.tsx +++ b/frontend/app/components/Dashboard/components/WidgetDateRange/WidgetDateRange.tsx @@ -36,6 +36,11 @@ function WidgetDateRange({ }; const onChangeComparison = (period: any) => { + if (compPeriod) { + if (compPeriod.start === period.start && compPeriod.end === period.end) { + return; + } + } dashboardStore.setComparisonPeriod(period, metricStore.instance.metricId); }