isDark property

bool get isDark

Whether this theme represents a dark theme based on backgroundColor luminance.

Implementation

bool get isDark => backgroundColor.computeLuminance() < 0.5;