kshowInfo function
显示提示 seconds:显示时长,单位-秒
Implementation
void kshowInfo(
String? text, {
int? seconds,
}) {
if (text == null || text.kisBlank()) {
return;
}
var config = UiPlatform.get.getEasyLoadingConfig();
EasyLoading.instance
..backgroundColor = config.infoBackgroundColor
..textColor = config.infoTextColor
..fontSize = config.fontSize ?? 15.sp
..indicatorColor = Colors.white
..infoWidget = config.infoWidget
..loadingStyle = EasyLoadingStyle.custom;
// ..infoWidget = Icon(
// Icons.info_outline,
// color: Colors.white,
// size: EasyLoading.instance.indicatorSize,
if (seconds != null && seconds > 0) {
EasyLoading.showInfo(text, duration: Duration(seconds: seconds));
} else {
EasyLoading.showInfo(text);
}
}