Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 | 2x 132x | export const COVERAGE_METRICS = ["lines", "statements", "functions", "branches"] as const;
type CoverageMetricName = (typeof COVERAGE_METRICS)[number];
/** One table cell: the percentage as a meter width, a label and its tone class. */
export const coverageCell = (key: CoverageMetricName, pct: number | null | undefined) => ({
key,
pct: pct ?? 0,
label: dash(pct, "%"),
tone: toneClass(coverageTone(pct ?? null)),
});
|