createToastWidget method
Implementation
Widget createToastWidget() {
decoration ??= BoxDecoration(
color: backgroundColor ?? Colors.black,
borderRadius: radius ?? const BorderRadius.all(Radius.circular(6)),
boxShadow: [shadow ?? const BoxShadow(color: Colors.grey, blurRadius: 25.0 /*, offset: Offset(4.0, 4.0)*/)],
);
return Container(
width: width,
height: height,
decoration: decoration,
clipBehavior: clipBehavior,
child: Padding(
padding: padding ??= const EdgeInsets.all(8.0),
child: builder?.call(this) ?? Text(text, style: textStyle ?? const TextStyle(color: Colors.white, fontSize: 15)),
),
);
}