Theme changes #4

Merged
marco merged 3 commits from development into main 2026-01-21 16:38:04 +01:00
Showing only changes of commit 3032e13dc9 - Show all commits

View File

@@ -8,15 +8,32 @@ class Notifying {
required String text,
bool isError = false,
}) {
ScaffoldMessenger.of(context).hideCurrentSnackBar();
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
backgroundColor: Theme.of(context).colorScheme.error,
content: Text(
content: SizedBox(
height: 30,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text(
text,
style: isError
? TextStyle(color: Theme.of(context).colorScheme.onError)
: null,
),
IconButton(
onPressed: () =>
ScaffoldMessenger.of(context).hideCurrentSnackBar(),
icon: Icon(
Icons.close_rounded,
color: Theme.of(context).colorScheme.onError,
),
),
],
),
),
),
);
}