Dashboards: Support an auto refresh interval that is based on the query range (#70479)

This commit is contained in:
Ryan McKinley
2023-06-26 09:46:23 -07:00
committed by GitHub
parent 2233886f80
commit 698b07518a
16 changed files with 126 additions and 38 deletions

View File

@@ -2,7 +2,7 @@ import { defaultIntervals } from '@grafana/ui';
interface Args {
urlRefresh: string | null;
currentRefresh: string | boolean | undefined;
currentRefresh: string | false | undefined;
isAllowedIntervalFn: (interval: string) => boolean;
minRefreshInterval: string;
refreshIntervals?: string[];
@@ -18,7 +18,7 @@ export function getRefreshFromUrl({
isAllowedIntervalFn,
minRefreshInterval,
refreshIntervals = defaultIntervals,
}: Args): string | boolean | undefined {
}: Args): string | false | undefined {
if (!urlRefresh) {
return currentRefresh;
}