build static method

Widget build({
  1. Widget? child,
  2. List<BoxShadow>? boxShadow,
  3. Color? color,
  4. EdgeInsets? padding,
  5. EdgeInsets? margin,
  6. BorderRadiusGeometry? borderRadius,
  7. double? width,
  8. double? height,
  9. Matrix4? transform,
  10. Gradient? gradient,
  11. DecorationImage? image,
  12. BoxBorder? border,
  13. BoxConstraints? constraints,
  14. BlendMode? backgroundBlendMode,
  15. Clip clipBehavior = Clip.hardEdge,
  16. BoxShape shape = BoxShape.rectangle,
})

Implementation

static Widget build({
  Widget? child,
  List<BoxShadow>? boxShadow,
  Color? color,
  EdgeInsets? padding,
  EdgeInsets? margin,
  BorderRadiusGeometry? borderRadius,
  double? width,
  double? height,
  Matrix4? transform,
  Gradient? gradient,
  DecorationImage? image,
  BoxBorder? border,
  BoxConstraints? constraints,
  BlendMode? backgroundBlendMode,
  Clip clipBehavior = Clip.hardEdge,
  BoxShape shape = BoxShape.rectangle
}) {
  return Container (
    width: width,
    height: height,
    margin: margin,
    padding: padding,
    transform: transform,
    constraints: constraints,
    clipBehavior: clipBehavior,
    decoration: BoxDecoration(
        boxShadow: boxShadow,
        borderRadius: shape == BoxShape.circle ? null : borderRadius,
        color: color,
        gradient: gradient,
        image: image,
        border: border,
        backgroundBlendMode: backgroundBlendMode,
        shape: shape
    ),
    child: child,
  );
}