/** The built-in ramps. The sequential ones go from the least to the most; the diverging ones from the lowest through a neutral middle to the highest. */ export type HeatRampName = "ember" | "ocean" | "mono" | "balance" | "tide"; /** A built-in ramp: nine stops for a light page and nine for a dark one. */ export interface HeatRampDef { kind: "sequential" | "diverging"; light: readonly string[]; dark: readonly string[]; } /** * The built-in ramps. On a light page a sequential ramp runs from a pale colour to a dark one, because the more there is the more ink it takes; * on a dark page it runs from near the ground to a bright one, because the more there is the more light it gives. A diverging ramp has its neutral * middle at the ground's colour and its two ends at full strength. */ export declare const HEAT_RAMPS: Readonly>; /** Names of the built-in ramps. */ export declare const HEAT_RAMP_NAMES: readonly HeatRampName[]; /** * A ramp for a layer: the name of a built-in one, a list of colour stops (the same on a light and a dark page), or a `light` and a `dark` list. * Stops are anything `safeColour` accepts. */ export type HeatRamp = HeatRampName | readonly string[] | { light: readonly string[]; dark?: readonly string[]; }; /** A ramp, resolved: the stops for a light page, and for a dark one when it differs. */ export interface ResolvedRamp { name: HeatRampName | undefined; kind: "sequential" | "diverging"; light: string[]; dark: string[] | undefined; } /** The ramp a layer asks for; `ember` when it asks for none (`fallback` for a diverging statistic). */ export declare function resolveRamp(ramp: HeatRamp | undefined, fallback?: HeatRampName): ResolvedRamp; /** The colour of step `k` of `steps` (0 to `steps - 1`) of some stops, as a hex colour (or the nearest stop for a colour that cannot be read without a browser). */ export declare function stepColour(stops: readonly string[], k: number, steps: number): string; /** The step (0 to `steps - 1`) a value falls in, on a domain: the share of the way through it, to the nearest step. */ export declare function stepOf(value: number, domain: readonly [number, number], steps: number): number;