error static method

void error({
  1. required String title,
  2. required String message,
  3. String description = "",
  4. List<Widget>? actions,
})

Implementation

static void error({
  required final String title,
  required final String message,
  final String description = "",
  final List<Widget>? actions,
}) {
  ShellToast.modal(
    title: 'Failed to run shell',
    content: Column(mainAxisSize: MainAxisSize.min, children: [
      const Icon(
        Icons.error_outline,
        color: Colors.red,
        size: 48,
      ),
      const SizedBox(height: 10),
      Text(message, style: const TextStyle(fontWeight: FontWeight.bold)),
      const SizedBox(height: 10),
      Text(message),
      const SizedBox(height: 10),
      Text(
        description,
        textAlign: TextAlign.left,
      ),
    ]),
  );
}