Skip to content

Commit

Permalink
[feat]: add support for custom child inside without padding (#408)
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeEagle committed Dec 11, 2022
1 parent cb7de7e commit 0f7db05
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/fluttertoast.dart
Expand Up @@ -25,7 +25,8 @@ enum ToastGravity {
BOTTOM_RIGHT,
CENTER_LEFT,
CENTER_RIGHT,
SNACKBAR
SNACKBAR,
NONE
}

/// Plugin to show a toast message on screen
Expand Down Expand Up @@ -245,6 +246,8 @@ class FToast {
left: 0,
right: 0,
child: child);
case ToastGravity.NONE:
return Positioned.fill(child: child);
case ToastGravity.BOTTOM:
default:
return Positioned(bottom: 50.0, left: 24.0, right: 24.0, child: child);
Expand Down

0 comments on commit 0f7db05

Please sign in to comment.