mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Refactor: move more files to @grafana/data (#17972)
This commit is contained in:
@@ -9,7 +9,8 @@ import templateSrv from 'app/features/templating/template_srv';
|
||||
|
||||
import { DashboardModel } from 'app/features/dashboard/state/DashboardModel';
|
||||
import { PanelModel } from 'app/features/dashboard/state/PanelModel';
|
||||
import { ClickOutsideWrapper, DataLink } from '@grafana/ui';
|
||||
import { ClickOutsideWrapper } from '@grafana/ui';
|
||||
import { DataLink } from '@grafana/data';
|
||||
|
||||
export interface Props {
|
||||
panel: PanelModel;
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import React, { Component } from 'react';
|
||||
|
||||
import { renderMarkdown } from '@grafana/data';
|
||||
import { Tooltip, ScopedVars, DataLink } from '@grafana/ui';
|
||||
import { Tooltip, ScopedVars } from '@grafana/ui';
|
||||
import { DataLink } from '@grafana/data';
|
||||
|
||||
import { PanelModel } from 'app/features/dashboard/state/PanelModel';
|
||||
import templateSrv from 'app/features/templating/template_srv';
|
||||
|
||||
@@ -8,7 +8,8 @@ import './../../panel/GeneralTabCtrl';
|
||||
|
||||
// Types
|
||||
import { PanelModel } from '../state/PanelModel';
|
||||
import { DataLink, PanelOptionsGroup, DataLinksEditor } from '@grafana/ui';
|
||||
import { DataLink } from '@grafana/data';
|
||||
import { PanelOptionsGroup, DataLinksEditor } from '@grafana/ui';
|
||||
import { getPanelLinksVariableSuggestions } from 'app/features/panel/panellinks/link_srv';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -9,7 +9,7 @@ import kbn from 'app/core/utils/kbn';
|
||||
// Types
|
||||
import { PanelModel } from './PanelModel';
|
||||
import { DashboardModel } from './DashboardModel';
|
||||
import { DataLink } from '@grafana/ui/src/types/panel';
|
||||
import { DataLink } from '@grafana/data';
|
||||
|
||||
// Constants
|
||||
import {
|
||||
|
||||
@@ -6,7 +6,9 @@ import { Emitter } from 'app/core/utils/emitter';
|
||||
import { getNextRefIdChar } from 'app/core/utils/query';
|
||||
|
||||
// Types
|
||||
import { DataQuery, ScopedVars, DataQueryResponseData, PanelPlugin, DataLink } from '@grafana/ui';
|
||||
import { DataQuery, ScopedVars, DataQueryResponseData, PanelPlugin } from '@grafana/ui';
|
||||
import { DataLink } from '@grafana/data';
|
||||
|
||||
import config from 'app/core/config';
|
||||
|
||||
import { PanelQueryRunner } from './PanelQueryRunner';
|
||||
|
||||
@@ -3,9 +3,8 @@ import { TimeSrv } from 'app/features/dashboard/services/TimeSrv';
|
||||
import templateSrv, { TemplateSrv } from 'app/features/templating/template_srv';
|
||||
import coreModule from 'app/core/core_module';
|
||||
import { appendQueryToUrl, toUrlParams } from 'app/core/utils/url';
|
||||
import { DataLink, VariableSuggestion, KeyValue, ScopedVars } from '@grafana/ui';
|
||||
import { TimeSeriesValue, DateTime, dateTime } from '@grafana/data';
|
||||
import { deprecationWarning, VariableOrigin } from '@grafana/ui';
|
||||
import { VariableSuggestion, KeyValue, ScopedVars, deprecationWarning, VariableOrigin } from '@grafana/ui';
|
||||
import { TimeSeriesValue, DateTime, dateTime, DataLink } from '@grafana/data';
|
||||
|
||||
export const DataLinkBuiltInVars = {
|
||||
keepTime: '__url_time_range',
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
// Libraries
|
||||
import React, { PureComponent } from 'react';
|
||||
|
||||
// Components
|
||||
import {
|
||||
ThresholdsEditor,
|
||||
ValueMappingsEditor,
|
||||
@@ -10,11 +9,13 @@ import {
|
||||
FieldDisplayOptions,
|
||||
FieldPropertiesEditor,
|
||||
PanelOptionsGroup,
|
||||
FormLabel,
|
||||
PanelEditorProps,
|
||||
Select,
|
||||
} from '@grafana/ui';
|
||||
import { Field } from '@grafana/data';
|
||||
|
||||
// Types
|
||||
import { FormLabel, PanelEditorProps, Threshold, Select, ValueMapping } from '@grafana/ui';
|
||||
import { Threshold, ValueMapping } from '@grafana/data';
|
||||
import { BarGaugeOptions, orientationOptions, displayModes } from './types';
|
||||
|
||||
export class BarGaugePanelEditor extends PureComponent<PanelEditorProps<BarGaugeOptions>> {
|
||||
|
||||
@@ -3,17 +3,15 @@ import React, { PureComponent } from 'react';
|
||||
import {
|
||||
PanelEditorProps,
|
||||
ThresholdsEditor,
|
||||
Threshold,
|
||||
PanelOptionsGrid,
|
||||
ValueMappingsEditor,
|
||||
ValueMapping,
|
||||
FieldDisplayOptions,
|
||||
FieldDisplayEditor,
|
||||
FieldPropertiesEditor,
|
||||
Switch,
|
||||
PanelOptionsGroup,
|
||||
} from '@grafana/ui';
|
||||
import { Field } from '@grafana/data';
|
||||
import { Field, Threshold, ValueMapping } from '@grafana/data';
|
||||
|
||||
import { GaugeOptions } from './types';
|
||||
|
||||
|
||||
@@ -25,9 +25,9 @@ import ReactDOM from 'react-dom';
|
||||
import { GraphLegendProps, Legend } from './Legend/Legend';
|
||||
|
||||
import { GraphCtrl } from './module';
|
||||
import { getValueFormat, ContextMenuItem, ContextMenuGroup, DataLink } from '@grafana/ui';
|
||||
import { getValueFormat, ContextMenuItem, ContextMenuGroup } from '@grafana/ui';
|
||||
import { provideTheme } from 'app/core/utils/ConfigProvider';
|
||||
import { toUtc } from '@grafana/data';
|
||||
import { DataLink, toUtc } from '@grafana/data';
|
||||
import { GraphContextMenuCtrl, FlotDataPoint } from './GraphContextMenuCtrl';
|
||||
import { TimeSrv } from 'app/features/dashboard/services/TimeSrv';
|
||||
import { ContextSrv } from 'app/core/services/context_srv';
|
||||
|
||||
@@ -11,8 +11,8 @@ import { DataProcessor } from './data_processor';
|
||||
import { axesEditorComponent } from './axes_editor';
|
||||
import config from 'app/core/config';
|
||||
import TimeSeries from 'app/core/time_series2';
|
||||
import { DataFrame } from '@grafana/data';
|
||||
import { getColorFromHexRgbOrName, LegacyResponseData, DataLink, VariableSuggestion } from '@grafana/ui';
|
||||
import { DataFrame, DataLink } from '@grafana/data';
|
||||
import { getColorFromHexRgbOrName, LegacyResponseData, VariableSuggestion } from '@grafana/ui';
|
||||
import { getProcessedDataFrame } from 'app/features/dashboard/state/PanelQueryState';
|
||||
import { PanelQueryRunnerFormat } from 'app/features/dashboard/state/PanelQueryRunner';
|
||||
import { GraphContextMenuCtrl } from './GraphContextMenuCtrl';
|
||||
|
||||
@@ -3,13 +3,12 @@ import {
|
||||
PanelEditorProps,
|
||||
PanelOptionsGrid,
|
||||
ValueMappingsEditor,
|
||||
ValueMapping,
|
||||
FieldDisplayEditor,
|
||||
FieldDisplayOptions,
|
||||
FieldPropertiesEditor,
|
||||
PanelOptionsGroup,
|
||||
} from '@grafana/ui';
|
||||
import { Field } from '@grafana/data';
|
||||
import { ValueMapping, Field } from '@grafana/data';
|
||||
|
||||
import { PieChartOptionsBox } from './PieChartOptionsBox';
|
||||
import { PieChartOptions } from './types';
|
||||
|
||||
@@ -3,16 +3,14 @@ import React, { PureComponent } from 'react';
|
||||
import {
|
||||
PanelEditorProps,
|
||||
ThresholdsEditor,
|
||||
Threshold,
|
||||
PanelOptionsGrid,
|
||||
ValueMappingsEditor,
|
||||
ValueMapping,
|
||||
FieldDisplayOptions,
|
||||
FieldDisplayEditor,
|
||||
FieldPropertiesEditor,
|
||||
PanelOptionsGroup,
|
||||
} from '@grafana/ui';
|
||||
import { Field } from '@grafana/data';
|
||||
import { Threshold, ValueMapping, Field } from '@grafana/data';
|
||||
|
||||
import { SingleStatOptions, SparklineOptions } from './types';
|
||||
import { ColoringEditor } from './ColoringEditor';
|
||||
|
||||
Reference in New Issue
Block a user