refactor: Merge PanelChrome and DataPanel, do query execution in PanelQueryRunner (#16632)

Moves query execution logic to PanelQueryRunner and structures PanelChrome so it subscribes to the query results rather than necessarily controlling their execution.
This commit is contained in:
Ryan McKinley
2019-04-17 10:51:50 -07:00
committed by GitHub
parent 36d64fecea
commit ed0192104c
7 changed files with 401 additions and 417 deletions

View File

@@ -1,7 +1,7 @@
import { ComponentClass } from 'react';
import { LoadingState, SeriesData } from './data';
import { TimeRange } from './time';
import { ScopedVars, DataRequestInfo, DataQueryError } from './datasource';
import { ScopedVars, DataRequestInfo, DataQueryError, LegacyResponseData } from './datasource';
export type InterpolateFunction = (value: string, scopedVars?: ScopedVars, format?: string | Function) => string;
@@ -10,6 +10,9 @@ export interface PanelData {
series: SeriesData[];
request?: DataRequestInfo;
error?: DataQueryError;
// Data format expected by Angular panels
legacy?: LegacyResponseData[];
}
export interface PanelProps<T = any> {