background method
Implementation
Widget background(
{
EdgeInsetsGeometry? padding,
Border? border,
Color color = Colors.green,
double radius = 0,
List<BoxShadow>? boxShadow,
Gradient? gradient,
}) {
return Container(
padding: padding,
decoration: BoxDecoration(
color: color,
borderRadius: radius == 0 ? null : BorderRadius.circular(radius),
border: border,
boxShadow: boxShadow,
gradient: gradient,
),
child: this,
);
}