How Would I Position A Widget Out Of The Visible Area On The Screen


I am trying to create a custom alert / modal of sorts which slides up into the screen view on a button press. How do I go about positioned my widget outside of the normal widget tree and out of view from the screen, only on the button press should it come into view. All the other times it should be out of view. How do I go about doing this.

You could make a widget that is positioned in front of the rest of your app using the Stack widget.
Then you’d use either the Positioned or the Transform.translate widget to move the modal in and out of view.

1 Like