// Libraries import React, { PureComponent } from 'react'; // Components import { LegacyForms, InlineFormLabel, PanelOptionsGroup } from '@grafana/ui'; const { Select, FormField } = LegacyForms; // Types import { PanelEditorProps } from '@grafana/data'; import { PieChartType } from '@grafana/ui'; import { PieChartOptions } from './types'; const labelWidth = 8; const pieChartOptions = [ { value: PieChartType.PIE, label: 'Pie' }, { value: PieChartType.DONUT, label: 'Donut' }, ]; export class PieChartOptionsBox extends PureComponent> { onPieTypeChange = (pieType: any) => this.props.onOptionsChange({ ...this.props.options, pieType: pieType.value }); onStrokeWidthChange = ({ target }: any) => this.props.onOptionsChange({ ...this.props.options, strokeWidth: target.value }); render() { const { options } = this.props; const { pieType, strokeWidth } = options; return (
Type