/** * Sparkline path maths, kept separate from the component so it can be tested in * the node project without a browser. * * This consolidates six divergent implementations that disagreed on * normalisation, flat-series handling and stroke inset. `normalize` makes the * first of those an explicit caller decision rather than an accident. */ export type SparklineNormalize = 'minMax' | 'zeroMax'; export interface SparklineGeometryOptions { width: number; height: number; strokeWidth: number; normalize: SparklineNormalize; } export interface SparklineGeometry { /** SVG path `d` for the line. Empty string when there is no data. */ line: string; /** SVG path `d` for the filled area, closed to the baseline. */ area: string; /** Last plotted point, for the optional end marker. */ endPoint: { x: number; y: number; } | null; } export declare function buildSparklinePath(values: readonly number[], { width, height, strokeWidth, normalize }: SparklineGeometryOptions): SparklineGeometry;