CustomToasts class

自定义 Toastification

Constructors

CustomToasts()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

dismissAll({bool delayForAnimation = true}) → void
关闭所有
show({required Widget title, BuildContext? context, OverlayState? overlayState, AlignmentGeometry? alignment, Duration? autoCloseDuration, Duration? animationDuration, ToastificationAnimationBuilder? animationBuilder, ToastificationType? type, ToastificationStyle? style, Widget? description, Widget? icon, Color? primaryColor, Color? backgroundColor, Color? foregroundColor, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, BorderRadiusGeometry? borderRadius, BorderSide? borderSide, List<BoxShadow>? boxShadow, TextDirection? direction, bool? showProgressBar, ProgressIndicatorThemeData? progressBarTheme, ToastCloseButton? closeButton, bool? closeOnClick, bool? dragToClose, bool? showIcon, DismissDirection? dismissDirection, bool? pauseOnHover, bool? applyBlurEffect, ToastificationCallbacks callbacks = const ToastificationCallbacks(), bool? blockBackgroundInteraction}) → void
显示
showError({int? duration, String? titleText, Widget? title, String? subtitleText, Widget? subtitle, bool showProgressBar = false, ToastificationCallbacks? callbacks}) → void
显示错误通知
showLoading({bool showBgColor = true, String? description, int? duration}) → void
显示 Loading
showSuccess({int? duration, String? titleText, Widget? title, String? subtitleText, Widget? subtitle, bool showProgressBar = false, ToastificationCallbacks? callbacks}) → void
显示成功通知
showText(String text, {int? duration}) → void
显示文本
showWarn({int? duration, String? titleText, Widget? title, String? subtitleText, Widget? subtitle, bool showProgressBar = false, ToastificationCallbacks? callbacks}) → void
显示警告通知