@pond-ts/charts API Reference
    Preparing search index...

    Interface BaselineProps

    interface BaselineProps {
        axis?: string;
        editing?: boolean;
        hovered?: boolean;
        id?: string;
        indicator?: boolean;
        label?: string | false;
        labelPosition?: "center" | "above";
        labelSide?: "left" | "right";
        onChange?: (value: number) => void;
        selectable?: boolean;
        selected?: boolean;
        value: number;
    }
    Index

    Properties

    axis?: string

    Which <YAxis> (by id) to measure against; omit for the row's default axis.

    editing?: boolean

    When true, this mark is in single-annotation edit (the double-click target): handles stay out, it's draggable, and it reads as level 1 — while other marks stay static. Independent of the container's global editAnnotations. Pair with onEditAnnotation (the consumer holds an editingId and sets editing={editingId === id}).

    hovered?: boolean

    Controlled hover (OR'd with pointer hover) — lets a legend row light the mark remotely. Pair with the container's onHoverAnnotation to sync both ways.

    id?: string

    Stable consumer id — a click reports it via onSelectAnnotation.

    indicator?: boolean

    Also pin this baseline's value to its y-axis as an on-axis pill (in the annotation colour) — the axis-edge counterpart of the near-line chip. Default false. The pill always shows the formatted value (the axis coordinate), never the custom label (which stays the near-line chip) — an indicator reads like a tick.

    label?: string | false

    Chip label. Omit to format value with that axis's formatter; pass false (or '') to render no label chip.

    labelPosition?: "center" | "above"

    Where the label chip sits relative to the line: center (default) rides on the line, vertically centred; above sits just on top of it.

    labelSide?: "left" | "right"

    Which side of the chart the near-line label chip sits. Default left.

    onChange?: (value: number) => void

    Make the baseline editable (in edit mode): dragging it vertically reports the new value (controlled — wire it back to value).

    selectable?: boolean

    Whether the baseline responds to hover + selection (default true). When false it's inert background context — drawn at the back (level 3) always.

    selected?: boolean

    Controlled selection — brightens to the front (level 1). Handles are an edit-mode hover affordance, not a selection cue. Ignored if not selectable.

    value: number

    y value in the linked axis's units.