minor refactoring

This commit is contained in:
Neeraj Gupta 2022-09-23 15:07:07 +05:30
parent 9a23700573
commit 1aeb49d7f7
No known key found for this signature in database
GPG key ID: 3C5A1684DC1729E1
4 changed files with 5 additions and 13 deletions

View file

@ -349,14 +349,6 @@ extension CustomColorScheme on ColorScheme {
? const Color.fromRGBO(180, 180, 180, 1)
: const Color.fromRGBO(100, 100, 100, 1);
Color get themeSwitchIndicatorColor => brightness == Brightness.light
? const Color.fromRGBO(0, 0, 0, 1).withOpacity(0.75)
: const Color.fromRGBO(255, 255, 255, 1);
Color get themeSwitchActiveIconColor => brightness == Brightness.light
? const Color.fromRGBO(255, 255, 255, 1)
: const Color.fromRGBO(0, 0, 0, 1);
Color get themeSwitchInactiveIconColor => brightness == Brightness.light
? const Color.fromRGBO(0, 0, 0, 1).withOpacity(0.5)
: const Color.fromRGBO(255, 255, 255, 1).withOpacity(0.5);

View file

@ -20,7 +20,7 @@ class EnteTheme {
}
EnteTheme lightTheme = EnteTheme(
lightTextStyle,
lightTextTheme,
lightScheme,
shadowFloat: shadowFloatLight,
shadowMenu: shadowMenuLight,
@ -28,7 +28,7 @@ EnteTheme lightTheme = EnteTheme(
);
EnteTheme darkTheme = EnteTheme(
darkTextStyle,
darkTextTheme,
darkScheme,
shadowFloat: shadowFloatDark,
shadowMenu: shadowMenuDark,

View file

@ -92,8 +92,8 @@ class EnteTextTheme {
});
}
EnteTextTheme lightTextStyle = _buildEnteTextStyle(textBaseLight);
EnteTextTheme darkTextStyle = _buildEnteTextStyle(textBaseDark);
EnteTextTheme lightTextTheme = _buildEnteTextStyle(textBaseLight);
EnteTextTheme darkTextTheme = _buildEnteTextStyle(textBaseDark);
EnteTextTheme _buildEnteTextStyle(Color color) {
return EnteTextTheme(

View file

@ -45,7 +45,7 @@ class NotificationWarningWidget extends StatelessWidget {
Flexible(
child: Text(
text,
style: darkTextStyle.bodyBold,
style: darkTextTheme.bodyBold,
textAlign: TextAlign.left,
),
),