diff --git a/b0esche_cloud/lib/pages/document_viewer.dart b/b0esche_cloud/lib/pages/document_viewer.dart index 139f8eb..0491e0d 100644 --- a/b0esche_cloud/lib/pages/document_viewer.dart +++ b/b0esche_cloud/lib/pages/document_viewer.dart @@ -562,9 +562,14 @@ class _DocumentViewerModalState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, - overlayColor: WidgetStateProperty.all( - Colors.transparent, - ), + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(false), child: const Text( @@ -575,9 +580,14 @@ class _DocumentViewerModalState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, - overlayColor: WidgetStateProperty.all( - Colors.transparent, - ), + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(true), child: const Text( @@ -1010,9 +1020,14 @@ class _DocumentViewerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, - overlayColor: WidgetStateProperty.all( - Colors.transparent, - ), + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(false), child: const Text( @@ -1023,9 +1038,14 @@ class _DocumentViewerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, - overlayColor: WidgetStateProperty.all( - Colors.transparent, - ), + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(true), child: const Text( diff --git a/b0esche_cloud/lib/pages/file_explorer.dart b/b0esche_cloud/lib/pages/file_explorer.dart index f5cead9..c672079 100644 --- a/b0esche_cloud/lib/pages/file_explorer.dart +++ b/b0esche_cloud/lib/pages/file_explorer.dart @@ -224,6 +224,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(), child: const Text( @@ -234,6 +242,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () { final folderName = controller.text.trim(); @@ -337,6 +353,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(), child: const Text( @@ -347,6 +371,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () { final docName = controller.text.trim(); @@ -535,6 +567,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(), child: const Text( @@ -545,6 +585,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () { final newName = controller.text.trim(); @@ -759,6 +807,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(false), child: const Text( @@ -769,6 +825,14 @@ class _FileExplorerState extends State { TextButton( style: ButtonStyle( splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), ), onPressed: () => Navigator.of(context).pop(true), child: const Text( @@ -1428,10 +1492,25 @@ class _FileExplorerState extends State { child: Row( children: state.breadcrumbs.map((breadcrumb) { return TextButton( - style: TextButton.styleFrom( + style: ButtonStyle( splashFactory: NoSplash.splashFactory, - padding: EdgeInsets.zero, - minimumSize: Size.zero, + overlayColor: + WidgetStateProperty.resolveWith< + Color? + >((Set states) { + if (states.contains( + WidgetState.pressed, + )) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), + padding: WidgetStateProperty.all( + EdgeInsets.zero, + ), + minimumSize: WidgetStateProperty.all( + Size.zero, + ), tapTargetSize: MaterialTapTargetSize.shrinkWrap, ), diff --git a/b0esche_cloud/lib/pages/home_page.dart b/b0esche_cloud/lib/pages/home_page.dart index ec862ef..931e4bf 100644 --- a/b0esche_cloud/lib/pages/home_page.dart +++ b/b0esche_cloud/lib/pages/home_page.dart @@ -238,7 +238,17 @@ class _HomePageState extends State with TickerProviderStateMixin { final highlightColor = const Color.fromARGB(255, 100, 200, 255); final defaultColor = AppTheme.secondaryText; return TextButton( - style: ButtonStyle(splashFactory: NoSplash.splashFactory), + style: ButtonStyle( + splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), + ), onPressed: onTap, child: Text( org.name, @@ -254,7 +264,17 @@ class _HomePageState extends State with TickerProviderStateMixin { final highlightColor = const Color.fromARGB(255, 100, 200, 255); final defaultColor = AppTheme.secondaryText; return TextButton( - style: ButtonStyle(splashFactory: NoSplash.splashFactory), + style: ButtonStyle( + splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), + ), onPressed: onTap, child: Text( 'Personal', @@ -269,7 +289,17 @@ class _HomePageState extends State with TickerProviderStateMixin { Widget _buildAddButton(VoidCallback onTap) { final defaultColor = AppTheme.secondaryText; return TextButton( - style: ButtonStyle(splashFactory: NoSplash.splashFactory), + style: ButtonStyle( + splashFactory: NoSplash.splashFactory, + overlayColor: WidgetStateProperty.resolveWith(( + Set states, + ) { + if (states.contains(WidgetState.pressed)) { + return Colors.transparent; + } + return null; // Use default for other states (like hover) + }), + ), onPressed: onTap, child: Text('+ Add Organization', style: TextStyle(color: defaultColor)), );