Closed Apollo108 closed 1 year ago
Should any checks be performed before showing or hiding dialogs in order to do it safely?
Hello, @Apollo108.
Thanks for the issue. I will take a close look now.
EasyDialogPosition
is an identifier itself for the PositionedDialog
. Additionally, you can use the hide
method from a specific dialog
instance:
final dialog = EasyDialog.positioned(
content: Container(
height: 150.0,
color: Colors.blue[900],
alignment: Alignment.center,
child: Text(
'dialog',
style: const TextStyle(
color: Colors.white,
fontSize: 30.0,
),
),
),
);
dialog.show();
dialog.hide();
@Apollo108 I have published 3.1.2 version that fixes this bug. You may try it out.
I wrote that the problem doesn't happen when I'm using FlutterEasyDialogs.hide(PositionedDialog.identifier(position: EasyDialogPosition.top));
. Thanks for quick fixes, the package is awesome!
What happened?
My code:
Usage:
I'm hiding it right after showing, according to logs. It doesn't happen when I'm using
FlutterEasyDialogs.hide(PositionedDialog.identifier(position: EasyDialogPosition.top));
though.But I'm trying to target a specific dialog when I'm hiding, can we expect working with dialogs by 'id's?
Relevant log output
Code of Conduct