animate method

AnimatedPhysicalModel animate({
  1. Curve curve = Curves.linear,
  2. Duration duration = const Duration(milliseconds: 300),
  3. VoidCallback? onEnd,
  4. required Color color,
  5. double borderRadius = 5.0,
  6. Clip clipBehavior = Clip.none,
  7. double elevation = 0,
  8. Color shadowColor = Colors.grey,
  9. BoxShape shape = BoxShape.rectangle,
  10. required Widget child,
})

Implementation

AnimatedPhysicalModel animate(
    {Curve curve = Curves.linear,
    Duration duration = const Duration(milliseconds: 300),
    VoidCallback? onEnd,
    required Color color,
    double borderRadius = 5.0,
    Clip clipBehavior = Clip.none,
    double elevation = 0,
    Color shadowColor = Colors.grey,
    BoxShape shape = BoxShape.rectangle,
    required Widget child}) {
  return AnimatedPhysicalModel(
      key: key,
      color: color,
      borderRadius: BorderRadius.circular(borderRadius),
      clipBehavior: clipBehavior,
      shape: shape,
      curve: curve,
      duration: duration,
      onEnd: onEnd,
      elevation: elevation,
      shadowColor: shadowColor,
      child: child);
}