createShadow function

List<BoxShadow> createShadow(
  1. {Color color,
  2. Offset offset,
  3. double blurRadius,
  4. double spreadRadius}
)

Implementation

List<BoxShadow> createShadow({Color color, Offset offset, double blurRadius, double spreadRadius}) {
  return [
    BoxShadow(
        color: color != null ? color : Colors.black54,
        offset: offset != null ? offset : Offset(0.0, 4.0),
        blurRadius: blurRadius != null ? blurRadius : 10.0,
        spreadRadius: spreadRadius != null ? spreadRadius : 0.0
    ),
  ];
}