import type { CurlingOptions, CurlingStone, CurlingTotals, Chart, KeyItem } from "./charts.types.ts"; /** The colours of the two teams' stones, the handles' colours of a game: red and yellow. */ export declare const CURLING_COLORS: { readonly home: "#cf2e2e"; readonly away: "#f2c230"; }; /** * Judge the stones of an end by the rules. A stone is out of play, and taken off the sheet, when it touches a sideline, when it does not come to rest * wholly beyond the hog line, or when it has wholly crossed the back line. A stone with any part within 6 feet of the button (in or touching the * house) can score; the team with the stone nearest the button scores one point for each of its stones that are nearer than every stone of the other * team. Stones as near as each other are equal, and equal stones do not count: if the two nearest are of different teams and as near, the end is * blank. Places are feet from the button (in `units`, feet by default), x across and y along. * @example * ```ts * import { curlingScore } from "@johnmorrisdotca/kyogijo-stadiums/charts"; * const end = curlingScore([ * { x: 0.3, y: 0.2, team: "home" }, * { x: -1.5, y: 1, team: "home" }, * { x: 2, y: -2, team: "away" }, * ]); * console.log(end.scoring, end.points, end.shot); * // home 2 0 * ``` */ export declare function curlingScore(stones: readonly CurlingStone[], options?: { units?: CurlingOptions["units"]; width?: number; }): CurlingTotals; /** * A chart of the stones of an end on the house: each stone as seen from above (grey granite and its team's handle, with its number), the stones * that score ringed and the shot rock, the nearest, ringed twice, and the score of the end under the rules (`curlingScore`). It shows the half of * the sheet from the hog line to the back line, with the free guard zone shaded, at the house on the left (the top of a tall drawing) or the right. * Stones out of play are taken off, as the rules take them. `layerTable` and `chart.table()` list every stone with its distance from the button. * @example * ```ts * import { curlingStones } from "@johnmorrisdotca/kyogijo-stadiums/charts"; * const chart = curlingStones( * [ * { x: 0.4, y: 0.3, team: "home", number: 8 }, * { x: -1.2, y: -0.8, team: "home", number: 6 }, * { x: 1.9, y: 1.1, team: "away", number: 7 }, * { x: 0, y: -12, team: "away", number: 3 }, * ], * { end: 6, hammer: "home", names: { home: "Canada", away: "Japan" } }, * ); * console.log(chart.totals.points, chart.totals.scoring, chart.title); * // 2 home Curling stones, End 6 * ``` */ export declare function curlingStones(stones: readonly CurlingStone[], options?: CurlingOptions): Chart & { key: KeyItem[]; };