View as Markdown

API reference: @salmonui/charts/chart

ChartCrosshairOptionsinterface

import type { ChartCrosshairOptions } from '@salmonui/charts/chart';
interface ChartCrosshairOptions {
    readonly lines?: 'both' | 'x' | 'y' | undefined;
    readonly snap?: boolean | undefined;
    readonly highlightCategory?: boolean | undefined;
    readonly axisLabels?: boolean | undefined;
    readonly formatLabel?: ((value: unknown, axisId: string) => string) | undefined;
}
ChartCrosshairOptions members (5)
NameSignatureDescription
linesoptionalreadonly lines?: 'both' | 'x' | 'y' | undefined;
snapoptionalreadonly snap?: boolean | undefined;
highlightCategoryoptionalreadonly highlightCategory?: boolean | undefined;

Shades the hovered category band of a category x axis.

axisLabelsoptionalreadonly axisLabels?: boolean | undefined;

Value labels on the axes at the crosshair lines.

formatLabeloptionalreadonly formatLabel?: ((value: unknown, axisId: string) => string) | undefined;

Axis label text; the axis format otherwise.