瀏覽代碼

Renamed Thresholds to ThresholdsEditor

Hugo Häggmark 7 年之前
父節點
當前提交
0b6e21e9ac

+ 2 - 2
packages/grafana-ui/src/components/Thresholds/Threshold.test.tsx

@@ -4,7 +4,7 @@ import { PanelOptionsProps } from '@grafana/ui';
 import { defaultProps } from 'app/plugins/panel/gauge/GaugePanelOptions';
 import { Options } from 'app/plugins/panel/gauge/types';
 import { BasicGaugeColor } from 'app/types';
-import { Thresholds } from './Thresholds';
+import { ThresholdsEditor } from './Thresholds';
 
 const setup = (propOverrides?: object) => {
   const props: PanelOptionsProps<Options> = {
@@ -17,7 +17,7 @@ const setup = (propOverrides?: object) => {
 
   Object.assign(props, propOverrides);
 
-  return shallow(<Thresholds {...props} />).instance() as Thresholds;
+  return shallow(<ThresholdsEditor {...props} />).instance() as ThresholdsEditor;
 };
 
 describe('Add threshold', () => {

+ 1 - 1
packages/grafana-ui/src/components/Thresholds/Thresholds.tsx

@@ -10,7 +10,7 @@ interface State {
   baseColor: string;
 }
 
-export class Thresholds extends PureComponent<PanelOptionsProps<Options>, State> {
+export class ThresholdsEditor extends PureComponent<PanelOptionsProps<Options>, State> {
   constructor(props) {
     super(props);
 

+ 1 - 1
packages/grafana-ui/src/components/index.ts

@@ -5,4 +5,4 @@ export { CustomScrollbar } from './CustomScrollbar/CustomScrollbar';
 export { ColorPicker } from './ColorPicker/ColorPicker';
 export { SeriesColorPickerPopover } from './ColorPicker/SeriesColorPickerPopover';
 export { SeriesColorPicker } from './ColorPicker/SeriesColorPicker';
-export { Thresholds } from './Thresholds/Thresholds';
+export { ThresholdsEditor } from './Thresholds/Thresholds';

+ 2 - 2
public/app/plugins/panel/gauge/GaugePanelOptions.tsx

@@ -1,7 +1,7 @@
 import React, { PureComponent } from 'react';
 import ValueOptions from 'app/plugins/panel/gauge/ValueOptions';
 import { BasicGaugeColor } from 'app/types';
-import { PanelOptionsProps, Thresholds } from '@grafana/ui';
+import { PanelOptionsProps, ThresholdsEditor } from '@grafana/ui';
 import ValueMappings from 'app/plugins/panel/gauge/ValueMappings';
 import { Options } from './types';
 import GaugeOptions from './GaugeOptions';
@@ -33,7 +33,7 @@ export default class GaugePanelOptions extends PureComponent<PanelOptionsProps<O
         <div className="form-section">
           <ValueOptions onChange={onChange} options={options} />
           <GaugeOptions onChange={onChange} options={options} />
-          <Thresholds onChange={onChange} options={options} />
+          <ThresholdsEditor onChange={onChange} options={options} />
         </div>
 
         <div className="form-section">