RangeError when the image has no opaque pixels, or an error when it cannot be read (not
CORS-readable, no DOM to decode it).
Example
// A File from an <input type="file">, a Blob, an <img>, an ImageBitmap or a CORS-readable URL styling.setMapColors(awaitderiveMapColorsFromImage(fileInput.files[0], { mode:'dark' }));
Derives the map colours from an image (a photo, a logo, a poster) by extracting its dominant colours and assigning them roles with deriveMapColors.