show static method
Implementation
static void show(
BuildContext context,
String title,
String message,
MessageConfig config,
) {
showDialog(
context: context,
builder:
(_) => AlertDialog(
backgroundColor: config.backgroundColor,
title: Row(
children: [
Icon(config.icon, color: config.textColor),
const SizedBox(width: 8),
Text(title, style: TextStyle(color: config.textColor)),
],
),
content: Text(message, style: TextStyle(color: config.textColor)),
actions: [
TextButton(
child: Text('OK', style: TextStyle(color: config.textColor)),
onPressed: () => Navigator.of(context).pop(),
),
],
),
);
}