Skip to content

Documentation / @finchart/core / index / SeriesContext

Interface: SeriesContext<T> ​

Defined in: packages/core/src/series/types.ts:14

The stage information Plot hands a series when it draws.

Type Parameters ​

T ​

T extends BaseDataPoint = BaseDataPoint

Properties ​

area ​

area: PlotArea

Defined in: packages/core/src/series/types.ts:33


data ​

data: DataView<T>

Defined in: packages/core/src/series/types.ts:16

Borrowed points for this frame. Neither the array nor its points are writable.


fullData? ​

optional fullData?: DataView<T>

Defined in: packages/core/src/series/types.ts:48

The full registered dataset (before slicing to the viewport). Used only by slotWidth, to re-measure slot width at the current zoom level when the viewport has no neighbor left at all (panning past the end of the data) — drawing itself still only looks at data.


places? ​

optional places?: number[] | null

Defined in: packages/core/src/series/types.ts:31

data[i]'s screen place (a scale domain value) — carried by the decimation cache. null or omitted means asking the mapping directly. A series should never read this array itself — go through screenXAt instead, so the choice between a place and the mapping lives in one spot and there's no way for a stale place to end up drawn.


readStyle ​

readStyle: StyleReader

Defined in: packages/core/src/series/types.ts:41

Turns a CSS variable into a resolved value. It receives a way to read, not the element itself, because getComputedStyle flushes pending style recalculation — this is built once per render and shared across series. That's why a series never has to know about the DOM at all.


x ​

x: XMapping

Defined in: packages/core/src/series/types.ts:22

Where a point's x lands on screen. Not a Scale — a series has no reason to know whether the domain is time or a bar index; ask, and the answer comes back.


yScale ​

yScale: Scale

Defined in: packages/core/src/series/types.ts:32