//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // This file is autogenerated. DO NOT EDIT. // // To regenerate, run "make gen-cue" from the repository root. //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /** * TODO docs */ export enum AxisPlacement { Auto = 'auto', Bottom = 'bottom', Hidden = 'hidden', Left = 'left', Right = 'right', Top = 'top', } /** * TODO docs */ export enum AxisColorMode { Series = 'series', Text = 'text', } /** * TODO docs */ export enum VisibilityMode { Always = 'always', Auto = 'auto', Never = 'never', } /** * TODO docs */ export enum GraphDrawStyle { Bars = 'bars', Line = 'line', Points = 'points', } /** * TODO docs */ export enum GraphTransform { Constant = 'constant', NegativeY = 'negative-Y', } /** * TODO docs */ export enum LineInterpolation { Linear = 'linear', Smooth = 'smooth', StepAfter = 'stepAfter', StepBefore = 'stepBefore', } /** * TODO docs */ export enum ScaleDistribution { Linear = 'linear', Log = 'log', Ordinal = 'ordinal', Symlog = 'symlog', } /** * TODO docs */ export enum GraphGradientMode { Hue = 'hue', None = 'none', Opacity = 'opacity', Scheme = 'scheme', } /** * TODO docs */ export enum StackingMode { None = 'none', Normal = 'normal', Percent = 'percent', } /** * TODO docs */ export enum BarAlignment { After = 1, Before = -1, Center = 0, } /** * TODO docs */ export enum ScaleOrientation { Horizontal = 0, Vertical = 1, } /** * TODO docs */ export enum ScaleDirection { Down = -1, Left = -1, Right = 1, Up = 1, } /** * TODO docs */ export interface LineStyle { dash?: Array; fill?: ('solid' | 'dash' | 'dot' | 'square'); } export const defaultLineStyle: Partial = { dash: [], }; /** * TODO docs */ export interface LineConfig { lineColor?: string; lineInterpolation?: LineInterpolation; lineStyle?: LineStyle; lineWidth?: number; /** * Indicate if null values should be treated as gaps or connected. * When the value is a number, it represents the maximum delta in the * X axis that should be considered connected. For timeseries, this is milliseconds */ spanNulls?: (boolean | number); } /** * TODO docs */ export interface BarConfig { barAlignment?: BarAlignment; barMaxWidth?: number; barWidthFactor?: number; } /** * TODO docs */ export interface FillConfig { fillBelowTo?: string; fillColor?: string; fillOpacity?: number; } /** * TODO docs */ export interface PointsConfig { pointColor?: string; pointSize?: number; pointSymbol?: string; showPoints?: VisibilityMode; } /** * TODO docs */ export interface ScaleDistributionConfig { linearThreshold?: number; log?: number; type: ScaleDistribution; } /** * TODO docs */ export interface AxisConfig { axisCenteredZero?: boolean; axisColorMode?: AxisColorMode; axisGridShow?: boolean; axisLabel?: string; axisPlacement?: AxisPlacement; axisSoftMax?: number; axisSoftMin?: number; axisWidth?: number; scaleDistribution?: ScaleDistributionConfig; } /** * TODO docs */ export interface HideSeriesConfig { legend: boolean; tooltip: boolean; viz: boolean; } /** * TODO docs */ export interface StackingConfig { group?: string; mode?: StackingMode; } /** * TODO docs */ export interface StackableFieldConfig { stacking?: StackingConfig; } /** * TODO docs */ export interface HideableFieldConfig { hideFrom?: HideSeriesConfig; } /** * TODO docs */ export enum GraphTresholdsStyleMode { Area = 'area', Line = 'line', LineAndArea = 'line+area', Off = 'off', Series = 'series', } /** * TODO docs */ export interface GraphThresholdsStyleConfig { mode: GraphTresholdsStyleMode; } /** * TODO docs */ export type LegendPlacement = ('bottom' | 'right'); /** * TODO docs * Note: "hidden" needs to remain as an option for plugins compatibility */ export enum LegendDisplayMode { Hidden = 'hidden', List = 'list', Table = 'table', } /** * TODO docs */ export interface TableSortByFieldState { desc?: boolean; displayName: string; } /** * TODO docs */ export interface SingleStatBaseOptions extends OptionsWithTextFormatting { orientation: VizOrientation; reduceOptions: ReduceDataOptions; } /** * TODO docs */ export interface ReduceDataOptions { /** * When !values, pick one value for the whole field */ calcs: Array; /** * Which fields to show. By default this is only numeric fields */ fields?: string; /** * if showing all values limit */ limit?: number; /** * If true show each row value */ values?: boolean; } export const defaultReduceDataOptions: Partial = { calcs: [], }; /** * TODO docs */ export enum VizOrientation { Auto = 'auto', Horizontal = 'horizontal', Vertical = 'vertical', } /** * TODO docs */ export interface OptionsWithTooltip { tooltip: VizTooltipOptions; } /** * TODO docs */ export interface OptionsWithLegend { legend: VizLegendOptions; } /** * TODO docs */ export interface OptionsWithTimezones { timezone?: Array; } export const defaultOptionsWithTimezones: Partial = { timezone: [], }; /** * TODO docs */ export interface OptionsWithTextFormatting { text?: VizTextDisplayOptions; } /** * TODO docs */ export enum BigValueColorMode { Background = 'background', None = 'none', Value = 'value', } /** * TODO docs */ export enum BigValueGraphMode { Area = 'area', Line = 'line', None = 'none', } /** * TODO docs */ export enum BigValueJustifyMode { Auto = 'auto', Center = 'center', } /** * TODO docs */ export enum BigValueTextMode { Auto = 'auto', Name = 'name', None = 'none', Value = 'value', ValueAndName = 'value_and_name', } /** * TODO -- should not be table specific! * TODO docs */ export type FieldTextAlignment = ('auto' | 'left' | 'right' | 'center'); /** * TODO docs */ export enum TableCellDisplayMode { Auto = 'auto', BasicGauge = 'basic', ColorBackground = 'color-background', ColorBackgroundSolid = 'color-background-solid', ColorText = 'color-text', GradientGauge = 'gradient-gauge', Image = 'image', JSONView = 'json-view', LcdGauge = 'lcd-gauge', } /** * TODO docs */ export interface VizTextDisplayOptions { /** * Explicit title text size */ titleSize?: number; /** * Explicit value text size */ valueSize?: number; } /** * TODO docs */ export enum TooltipDisplayMode { Multi = 'multi', None = 'none', Single = 'single', } /** * TODO docs */ export enum SortOrder { Ascending = 'asc', Descending = 'desc', None = 'none', } /** * TODO docs */ export interface GraphFieldConfig extends LineConfig, FillConfig, PointsConfig, AxisConfig, BarConfig, StackableFieldConfig, HideableFieldConfig { drawStyle?: GraphDrawStyle; gradientMode?: GraphGradientMode; thresholdsStyle?: GraphThresholdsStyleConfig; transform?: GraphTransform; } /** * TODO docs */ export interface VizLegendOptions { asTable?: boolean; calcs: Array; displayMode: LegendDisplayMode; isVisible?: boolean; placement: LegendPlacement; showLegend: boolean; sortBy?: string; sortDesc?: boolean; width?: number; } export const defaultVizLegendOptions: Partial = { calcs: [], }; /** * TODO docs */ export enum BarGaugeDisplayMode { Basic = 'basic', Gradient = 'gradient', Lcd = 'lcd', } /** * TODO docs */ export interface TableFieldOptions { align: FieldTextAlignment; displayMode: TableCellDisplayMode; filterable?: boolean; hidden?: boolean; inspect: boolean; minWidth?: number; width?: number; } export const defaultTableFieldOptions: Partial = { align: 'auto', displayMode: TableCellDisplayMode.Auto, inspect: false, }; /** * TODO docs */ export interface VizTooltipOptions { mode: TooltipDisplayMode; sort: SortOrder; }