Important: This documentation is about an older version. It's relevant only to the release noted, many of the features and functions have been updated or replaced. Please view the current version.
UPlotConfigBuilder class
Signature
export declare class UPlotConfigBuilder
Import
import { UPlotConfigBuilder } from '@grafana/ui';
Constructors
Constructor | Modifiers | Description |
---|---|---|
constructor(timeZone) | Constructs a new instance of the UPlotConfigBuilder class |
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
prepData | PrepData | undefined | ||
scaleKeys | [string, string] |
Methods
constructor(timeZone)
Constructs a new instance of the UPlotConfigBuilder
class
Signature
constructor(timeZone?: TimeZone);
Parameters
Parameter | Type | Description |
---|---|---|
timeZone | TimeZone |
prepData property
Signature
prepData: PrepData | undefined;
scaleKeys property
Signature
scaleKeys: [string, string];
addAxis method
Signature
addAxis(props: AxisProps): void;
Parameters
Parameter | Type | Description |
---|---|---|
props | AxisProps |
Returns:
void
addBand method
Signature
addBand(band: Band): void;
Parameters
Parameter | Type | Description |
---|---|---|
band | Band |
Returns:
void
addHook method
Signature
addHook<T extends keyof Hooks.Defs>(type: T, hook: Hooks.Defs[T]): void;
Parameters
Parameter | Type | Description |
---|---|---|
type | T | |
hook | Hooks.Defs[T] |
Returns:
void
addScale method
Add or update the scale with the scale key
Signature
addScale(props: ScaleProps): void;
Parameters
Parameter | Type | Description |
---|---|---|
props | ScaleProps |
Returns:
void
addSeries method
Signature
addSeries(props: SeriesProps): void;
Parameters
Parameter | Type | Description |
---|---|---|
props | SeriesProps |
Returns:
void
addThresholds method
Signature
addThresholds(options: UPlotThresholdOptions): void;
Parameters
Parameter | Type | Description |
---|---|---|
options | UPlotThresholdOptions |
Returns:
void
getAxisPlacement method
Signature
getAxisPlacement(scaleKey: string): AxisPlacement;
Parameters
Parameter | Type | Description |
---|---|---|
scaleKey | string |
Returns:
AxisPlacement
getConfig method
Signature
getConfig(): PlotConfig;
Returns:
PlotConfig
getSeries method
Signature
getSeries(): UPlotSeriesBuilder[];
Returns:
UPlotSeriesBuilder[]
getTooltipInterpolator method
Signature
getTooltipInterpolator(): PlotTooltipInterpolator | undefined;
Returns:
PlotTooltipInterpolator | undefined
hasSync method
Signature
hasSync(): boolean;
Returns:
boolean
setCursor method
Signature
setCursor(cursor?: Cursor): void;
Parameters
Parameter | Type | Description |
---|---|---|
cursor | Cursor |
Returns:
void
setMode method
Signature
setMode(mode: uPlot.Mode): void;
Parameters
Parameter | Type | Description |
---|---|---|
mode | uPlot.Mode |
Returns:
void
setPadding method
Signature
setPadding(padding: Padding): void;
Parameters
Parameter | Type | Description |
---|---|---|
padding | Padding |
Returns:
void
setPrepData method
Signature
setPrepData(prepData: PrepData): void;
Parameters
Parameter | Type | Description |
---|---|---|
prepData | PrepData |
Returns:
void
setSelect method
Signature
setSelect(select: Select): void;
Parameters
Parameter | Type | Description |
---|---|---|
select | Select |
Returns:
void
setSync method
Signature
setSync(): void;
Returns:
void
setTooltipInterpolator method
Signature
setTooltipInterpolator(interpolator: PlotTooltipInterpolator): void;
Parameters
Parameter | Type | Description |
---|---|---|
interpolator | PlotTooltipInterpolator |
Returns:
void