Rannie / flui

A powerful UI framework for Google Flutter.

Home Page:https://www.flui.xin/en/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

button in FLToast is unclickable

Mohammad-Adam opened this issue · comments

demo code:
`
toast(String value, {String buttonTitle = 'Dismiss', Function onButtonPress}) {
Function dismiss;
dismiss = FLToast.showToast(
text: value,
duration: Duration(seconds: 5),
contentBuilder: (cx){
return FlatButton(
onPressed: () {
if (onButtonPress == null) {
dismiss();
} else {
onButtonPress();
}
},
child: Text(
buttonTitle,
style: TextStyle(color: Colors.amber, fontSize: 18),
),
);
}
);
}

`

hi @EngDjango, I suggest you not add button on toast because toast view is wrapped by AbsorbPointer, also pointer event will be handled by provider to dismiss the existing toast view. Thanks all the same.