showStyledToast function

Future<void> showStyledToast(
  1. {required Widget child,
  2. required BuildContext context,
  3. Color? backgroundColor,
  4. EdgeInsetsGeometry? contentPadding,
  5. EdgeInsetsGeometry? margin,
  6. BorderRadiusGeometry? borderRadius,
  7. Duration? duration,
  8. Duration? animationDuration,
  9. VoidCallback? onDismiss,
  10. AlignmentGeometry? alignment,
  11. ToastAnimationBuilder? animationBuilder}
)

Shows a styledToast

Implementation

Future<void> showStyledToast({
  required Widget child,
  required BuildContext context,
  Color? backgroundColor,
  EdgeInsetsGeometry? contentPadding,
  EdgeInsetsGeometry? margin,
  BorderRadiusGeometry? borderRadius,
  Duration? duration,
  Duration? animationDuration,
  VoidCallback? onDismiss,
  AlignmentGeometry? alignment,
  ToastAnimationBuilder? animationBuilder,
}) {
  return showToast(
    child: child is StyledToast
        ? child
        : StyledToast(
            child: child,
            backgroundColor: backgroundColor,
            contentPadding: contentPadding,
            margin: margin,
            borderRadius: borderRadius,
          ),
    context: context,
    duration: duration,
    animationDuration: animationDuration,
    alignment: alignment,
    padding: EdgeInsets.zero,
    animationBuilder: animationBuilder,
  );
}