The colours a stylesheet paints with, most used first, as hex strings: var() references
resolved, fills weighted over borders and shadows, translucent colours and a colour's shades left
out, and 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, and 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:
var()references resolved, fills weighted over borders and shadows, translucent colours and a colour's shades left out, and 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, and then override the defaults;autoreads neither. Avar()resolves against its own rule or the page root, not a custom property set on another selector.