cShadow method

Widget cShadow({
  1. BoxShape shape = BoxShape.rectangle,
  2. Clip clipBehavior = Clip.none,
  3. BorderRadius? borderRadius,
  4. double elevation = 0.0,
  5. Color color = Colors.transparent,
})

Add a shadow effect to the widget.

This extension allows you to add a shadow effect to a widget using PhysicalModel.

shape specifies the shape of the widget.

clipBehavior specifies the clipping behavior.

borderRadius specifies the border radius for rounded corners (optional).

elevation specifies the shadow elevation.

color specifies the color of the shadow.

Implementation

Widget cShadow({
  BoxShape shape = BoxShape.rectangle,
  Clip clipBehavior = Clip.none,
  BorderRadius? borderRadius,
  double elevation = 0.0,
  Color color = Colors.transparent,
}) =>
    PhysicalModel(
      shape: shape,
      clipBehavior: clipBehavior,
      borderRadius: borderRadius,
      elevation: elevation,
      color: color,
      child: this,
    );