animateWidgetNotifyRipple method

Widget animateWidgetNotifyRipple({
  1. Color color = Colors.redAccent,
  2. int durationMs = 1500,
  3. bool repeat = true,
  4. bool animate = true,
})
  1. Notification Ripple

Implementation

Widget animateWidgetNotifyRipple({
  Color color = Colors.redAccent,
  int durationMs = 1500,
  bool repeat = true,
  bool animate = true,
}) {
  if (!animate) return this;
  return _baseAnimate(repeat: repeat).custom(
    duration: durationMs.ms,
    builder:
        (_, v, c) => Container(
          decoration: BoxDecoration(
            shape: BoxShape.circle,
            boxShadow: [
              BoxShadow(
                color: color.withColorOpacity(0.4 * (1 - v)),
                blurRadius: 20 * v,
                spreadRadius: 10 * v,
              ),
            ],
          ),
          child: c,
        ),
  );
}