showSnackbar static method
Future<ABUSResult>
showSnackbar({
- required String message,
- SnackbarType type = SnackbarType.info,
- String? actionLabel,
- VoidCallback? onAction,
- Duration? duration,
- Set<
String> ? tags, - int priority = 0,
- bool replace = false,
Show a snackbar
Implementation
static Future<ABUSResult> showSnackbar({
required String message,
SnackbarType type = SnackbarType.info,
String? actionLabel,
VoidCallback? onAction,
Duration? duration,
Set<String>? tags,
int priority = 0,
bool replace = false,
}) {
final event = SnackbarEvent(
id: 'snackbar_${DateTime.now().millisecondsSinceEpoch}',
message: message,
type: type,
actionLabel: actionLabel,
onAction: onAction,
duration: duration,
tags: tags ?? {},
priority: priority,
);
return ABUS
.execute(ShowFeedbackInteraction(event: event, replace: replace));
}