isDarkMode property

bool get isDarkMode

return true if the current app mode is dark

Implementation

bool get isDarkMode => Theme.of(this).brightness == Brightness.dark;