diff --git a/frontend/src/container/NewWidget/index.tsx b/frontend/src/container/NewWidget/index.tsx index c4a1bee824..f9384fbf5b 100644 --- a/frontend/src/container/NewWidget/index.tsx +++ b/frontend/src/container/NewWidget/index.tsx @@ -88,7 +88,7 @@ function NewWidget({ selectedGraph }: NewWidgetProps): JSX.Element { const { featureResponse } = useSelector( (state) => state.app, ); - const { selectedTime: globalSelectedInterval } = useSelector< + const { selectedTime: globalSelectedInterval, minTime, maxTime } = useSelector< AppState, GlobalReducer >((state) => state.globalTime); @@ -350,6 +350,7 @@ function NewWidget({ selectedGraph }: NewWidgetProps): JSX.Element { formatForWeb: getGraphTypeForFormat(selectedGraph || selectedWidget.panelTypes) === PANEL_TYPES.TABLE, + timeRange: { start: minTime, end: maxTime }, })); } // eslint-disable-next-line react-hooks/exhaustive-deps @@ -358,6 +359,8 @@ function NewWidget({ selectedGraph }: NewWidgetProps): JSX.Element { selectedTime, selectedWidget.fillSpans, globalSelectedInterval, + minTime, + maxTime, ]); const onClickSaveHandler = useCallback(() => {