The colours a stylesheet paints with, most used first, as hex strings. It resolves var()
references, weights fills over borders and shadows, drops translucent colours and a colour's
shades, and keeps at most two greys while colourful ones remain. Feed the result to
deriveMapColors. deriveMapColorsFromCss does both.
Rules for one colour scheme (prefers-color-scheme, a .dark or .light class, a data-*="dark"
attribute) are read only with that mode, then override the defaults. auto reads neither.
A var() resolves against its own rule or the page root, not a custom property set on another selector.
The colours a stylesheet paints with, most used first, as hex strings. It resolves
var()references, weights fills over borders and shadows, drops translucent colours and a colour's shades, and keeps at most two greys while colourful ones remain. Feed the result to deriveMapColors. deriveMapColorsFromCss does both.Rules for one colour scheme (
prefers-color-scheme, a.darkor.lightclass, adata-*="dark"attribute) are read only with thatmode, then override the defaults.autoreads neither. Avar()resolves against its own rule or the page root, not a custom property set on another selector.