Refactor button color logic and improve readability in home page and organization settings dialog
This commit is contained in:
@@ -378,7 +378,9 @@ class _HomePageState extends State<HomePage> with TickerProviderStateMixin {
|
||||
}) {
|
||||
final isSelected = _selectedTab == label;
|
||||
final highlightColor = const Color.fromARGB(255, 100, 200, 255);
|
||||
final defaultColor = onTap != null ? AppTheme.primaryText : AppTheme.secondaryText;
|
||||
final defaultColor = onTap != null
|
||||
? AppTheme.primaryText
|
||||
: AppTheme.secondaryText;
|
||||
|
||||
return GestureDetector(
|
||||
onTap:
|
||||
|
||||
@@ -550,7 +550,9 @@ class _OrganizationSettingsDialogState
|
||||
TextButton(
|
||||
style: ButtonStyle(
|
||||
splashFactory: NoSplash.splashFactory,
|
||||
overlayColor: WidgetStateProperty.resolveWith<Color?>((Set<WidgetState> states) {
|
||||
overlayColor: WidgetStateProperty.resolveWith<Color?>((
|
||||
Set<WidgetState> states,
|
||||
) {
|
||||
if (states.contains(WidgetState.pressed)) {
|
||||
return Colors.transparent;
|
||||
}
|
||||
@@ -563,7 +565,9 @@ class _OrganizationSettingsDialogState
|
||||
TextButton(
|
||||
style: ButtonStyle(
|
||||
splashFactory: NoSplash.splashFactory,
|
||||
overlayColor: WidgetStateProperty.resolveWith<Color?>((Set<WidgetState> states) {
|
||||
overlayColor: WidgetStateProperty.resolveWith<Color?>((
|
||||
Set<WidgetState> states,
|
||||
) {
|
||||
if (states.contains(WidgetState.pressed)) {
|
||||
return Colors.transparent;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user