MCU Dynamic Color
Dynamic color system for Material Design 3.
Provides runtime color resolution based on:
- Source color (theme seed)
- Variant (style: TonalSpot, Vibrant, etc.)
- Dark/light mode
- Contrast level (-1.0 to 1.0)
- Platform (phone, watch)
Example
use ;
use Hct;
// Create a scheme from a source color
let source_color = from_int; // Blue
let options = new;
let scheme = new;
// Access palettes
let primary_palette = &scheme.primary_palette;
let surface_tone = primary_palette.get_hct;