TomTom Maps for JavaScript
    Preparing search index...

    Variable cssColorsConst

    cssColors: (cssText: string, options?: MapThemeExtractionOptions) => string[]

    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.

    Type Declaration