/** * Declared markers into the chart's bar anchored markers. * * **A marker is a discrete event with a label, not a column of prices.** Its * declaration fixes where it sits, what shape it is drawn as and what colour it * is, all before bar 0; only the text is read per bar, and a bar whose channel * holds no string has no marker at all (`compiled-program.md` 2.8). So this * walks one string channel per call site and produces an entry for each bar that * wrote one, which is why a `signal()` under an `if` marks the bars the branch * was taken and nothing anywhere else. * * **The text cannot travel in the values table**, which holds numbers, so the * markers are built here, once per calculation, and left in the run record that * `produced.ts` keeps for the hook to read. * * **Two of the chart's words are not the language's, and the translation is * here.** A position is `"above"` in the language and `aboveBar` on the chart; * `"price"` names no price for the language to put a marker at, so it becomes * the chart's in-bar position rather than a price this module chose. A shape is * the same word in both worlds for nine of the ten, and the tenth, `"label"`, is * a plate whose tail points at the anchor, so the side the marker sits on is * what decides which of the chart's two plates it is. * * A marker is anchored to a bar's time rather than to its index, because an * index moves when more history loads and a time does not. */ import type { CompiledProgram } from '../../core/emit/index.js'; import type { ChartBar } from './contract.js'; import type { InputLookup } from './fields.js'; import type { Columns } from './run.js'; import type { ChartMarker } from './surfaces.js'; /** * Every marker the run produced, oldest bar first. * * The bars are walked once per call site rather than once in total, so the * entries of one call site are contiguous; the sort afterwards is what puts the * whole set in bar order, and it is stable, so two call sites that marked one * bar stay in declaration order on it. */ export declare function buildMarkers(program: CompiledProgram, lookup: InputLookup, bars: readonly ChartBar[], columns: Columns, defaultColour: string): readonly ChartMarker[]; //# sourceMappingURL=markers.d.ts.map