Enhance close button in PublicFileViewer: add custom button style to remove splash effect

This commit is contained in:
Leon Bösche
2026-01-25 01:05:29 +01:00
parent 8fd0ded519
commit 73db23f590

View File

@@ -229,6 +229,17 @@ class _PublicFileViewerState extends State<PublicFileViewer> {
actions: [
IconButton(
icon: const Icon(Icons.close, color: AppTheme.primaryText),
style: ButtonStyle(
splashFactory: NoSplash.splashFactory,
overlayColor: WidgetStateProperty.resolveWith<Color?>((
Set<WidgetState> states,
) {
if (states.contains(WidgetState.pressed)) {
return Colors.transparent;
}
return null;
}),
),
onPressed: () => context.go('/'),
),
],