PanelOptionsEditorBuilder class

Fluent API for declarative creation of panel options

Signature

  1. export declare class PanelOptionsEditorBuilder<TOptions> extends OptionsUIRegistryBuilder<TOptions, StandardEditorProps, PanelOptionsEditorItem<TOptions>>

Import

  1. import { PanelOptionsEditorBuilder } from '@grafana/data';

Methods

MethodModifiersDescription
addBooleanSwitch(config)
addColorPicker(config)
addMultiSelect(config)
addNumberInput(config)
addRadio(config)
addSelect(config)
addSliderInput(config)
addStringArray(config)
addTextInput(config)
addTimeZonePicker(config)
addUnitPicker(config)

addBooleanSwitch method

Signature

  1. addBooleanSwitch<TSettings = any>(config: PanelOptionsEditorConfig<TOptions, TSettings, boolean>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings, boolean>

Returns:

this

addColorPicker method

Signature

  1. addColorPicker<TSettings = any>(config: PanelOptionsEditorConfig<TOptions, TSettings, string>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings, string>

Returns:

this

addMultiSelect method

Signature

  1. addMultiSelect<TOption, TSettings extends SelectFieldConfigSettings<TOption>>(config: PanelOptionsEditorConfig<TOptions, TSettings, TOption>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings, TOption>

Returns:

this

addNumberInput method

Signature

  1. addNumberInput<TSettings>(config: PanelOptionsEditorConfig<TOptions, TSettings & NumberFieldConfigSettings, number>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings & NumberFieldConfigSettings, number>

Returns:

this

addRadio method

Signature

  1. addRadio<TOption, TSettings extends SelectFieldConfigSettings<TOption>>(config: PanelOptionsEditorConfig<TOptions, TSettings, TOption>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings, TOption>

Returns:

this

addSelect method

Signature

  1. addSelect<TOption, TSettings extends SelectFieldConfigSettings<TOption>>(config: PanelOptionsEditorConfig<TOptions, TSettings, TOption>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings, TOption>

Returns:

this

addSliderInput method

Signature

  1. addSliderInput<TSettings>(config: PanelOptionsEditorConfig<TOptions, TSettings & SliderFieldConfigSettings, number>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings & SliderFieldConfigSettings, number>

Returns:

this

addStringArray method

Signature

  1. addStringArray<TSettings>(config: PanelOptionsEditorConfig<TOptions, TSettings & StringFieldConfigSettings, string[]>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings & StringFieldConfigSettings, string[]>

Returns:

this

addTextInput method

Signature

  1. addTextInput<TSettings>(config: PanelOptionsEditorConfig<TOptions, TSettings & StringFieldConfigSettings, string>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings & StringFieldConfigSettings, string>

Returns:

this

addTimeZonePicker method

Signature

  1. addTimeZonePicker<TSettings = any>(config: PanelOptionsEditorConfig<TOptions, TSettings, string>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings, string>

Returns:

this

addUnitPicker method

Signature

  1. addUnitPicker<TSettings = any>(config: PanelOptionsEditorConfig<TOptions, TSettings & UnitFieldConfigSettings, string>): this;

Parameters

ParameterTypeDescription
configPanelOptionsEditorConfig<TOptions, TSettings & UnitFieldConfigSettings, string>

Returns:

this