import { test } from "node:test"; import assert from "node:assert/strict"; import * as React from "react"; import { renderToStaticMarkup } from "react-dom/server"; import { ChartView } from "./ChartView"; import { newChart, type ChartConfig } from "../../lib/chartConfig"; import type { ChartData } from "../../lib/chartAggregate"; import { seriesColor } from "../../lib/homepageChart"; // ChartView's colours (release 13, slice W2): a series' colour — and a pie // slice's — is seriesColor(i), so the sixth reaches --chart-6 instead of // wrapping back to --chart-1 (the old `i % 5`). What a server render can see // is the ChartContainer's