error static method
Displays an error-themed SnackBar message.
显示带有错误主题的 SnackBar 消息。
Implementation
static void error(
BuildContext context,
String message, {
Duration duration = _defaultShowDuration,
}) {
_showStyledSnackBar(
context,
message,
Colors.red,
Icons.error,
duration,
);
}