wrap method
Wraps the child widget with this specific visual effect.
Implementation
@override
Widget wrap(BuildContext context, Widget child, double progress) {
return Stack(
alignment: Alignment.center,
children: [
// Backing ripple painter
SizedBox(
width: maxRadius * 2,
height: maxRadius * 2,
child: CustomPaint(
painter: _RippleEffectPainter(
progress: progress, color: color, maxRadius: maxRadius),
),
),
child,
],
);
}