Improved error messages

This commit is contained in:
Juan Gilsanz Polo
2024-02-24 01:57:39 +01:00
parent f11b112f97
commit ac340c108b
8 changed files with 69 additions and 36 deletions

View File

@@ -0,0 +1,36 @@
import 'package:flutter/material.dart';
class NoDataScreen extends StatelessWidget {
final String message;
const NoDataScreen({
Key? key,
required this.message,
}) : super(key: key);
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.all(16),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(
Icons.clear_rounded,
size: 50,
color: Theme.of(context).colorScheme.onSurfaceVariant,
),
const SizedBox(height: 30),
Text(
message,
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 24,
color: Theme.of(context).colorScheme.onSurfaceVariant,
),
),
],
),
);
}
}