Commit 0f7db054 by CodeEagle Committed by GitHub

[feat]: add support for custom child inside without padding (#408)

parent cb7de7ed
...@@ -25,7 +25,8 @@ enum ToastGravity { ...@@ -25,7 +25,8 @@ enum ToastGravity {
BOTTOM_RIGHT, BOTTOM_RIGHT,
CENTER_LEFT, CENTER_LEFT,
CENTER_RIGHT, CENTER_RIGHT,
SNACKBAR SNACKBAR,
NONE
} }
/// Plugin to show a toast message on screen /// Plugin to show a toast message on screen
...@@ -245,6 +246,8 @@ class FToast { ...@@ -245,6 +246,8 @@ class FToast {
left: 0, left: 0,
right: 0, right: 0,
child: child); child: child);
case ToastGravity.NONE:
return Positioned.fill(child: child);
case ToastGravity.BOTTOM: case ToastGravity.BOTTOM:
default: default:
return Positioned(bottom: 50.0, left: 24.0, right: 24.0, child: child); return Positioned(bottom: 50.0, left: 24.0, right: 24.0, child: child);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment