TF-1594 Move SendEmailInteractor to MailboxDashboardController to handle async send email

(cherry picked from commit 63aec51a6ea6e827ea924e91a13ec78d7f48edf7)
This commit is contained in:
dab246
2023-03-15 15:06:59 +07:00
committed by Dat Vu
parent ee91963e53
commit fe05df3477
5 changed files with 54 additions and 42 deletions
+13 -8
View File
@@ -145,11 +145,19 @@ class AppToast {
);
}
void showToastWithIcon(BuildContext context, {
String? message, String? icon, Color? bgColor, Color? iconColor,
Color? textColor, double? radius, EdgeInsets? padding,
TextStyle? textStyle, double? widthToast, Duration? toastLength,
Duration? delayTime}) async {
void showToastWithIcon(
BuildContext context, {
String? message,
String? icon,
Color? bgColor,
Color? iconColor,
Color? textColor,
double? radius,
EdgeInsets? padding,
TextStyle? textStyle,
double? widthToast,
Duration? toastLength
}) async {
double sizeWidth = context.width > 360 ? 360 : context.width - 40;
final toast = Material(
color: bgColor ?? Colors.white,
@@ -182,9 +190,6 @@ class AppToast {
),
);
fToast.init(context);
if (delayTime != null) {
await Future.delayed(delayTime);
}
fToast.showToast(
child: toast,
gravity: ToastGravity.BOTTOM,