useThemeSelector method
Implementation
void useThemeSelector(
BuildContext context, {
T Function(T)? light,
T Function(T)? dark,
}) {
final isDark = Theme.of(context).brightness == Brightness.dark;
if (isDark && dark != null)
apply = dark(self);
else if (!isDark && light != null) apply = light(self);
}