CircularRevealAnimation constructor

CircularRevealAnimation({
  1. required Widget child,
  2. required Animation<double> animation,
  3. Alignment? centerAlignment,
  4. Offset? centerOffset,
  5. double? minRadius,
  6. double? maxRadius,
})

Creates CircularRevealAnimation with given params. For open animation animation should run forward: AnimationController.forward. For close animation animation should run reverse: AnimationController.reverse.

centerAlignment center of circular reveal. centerOffset if not specified. centerOffset center of circular reveal. Child's center if not specified. centerAlignment or centerOffset must be null (or both).

minRadius minimum radius of circular reveal. 0 if not if not specified. maxRadius maximum radius of circular reveal. Distance from center to further child's corner if not specified.

Implementation

CircularRevealAnimation({
  required this.child,
  required this.animation,
  this.centerAlignment,
  this.centerOffset,
  this.minRadius,
  this.maxRadius,
}) : assert(centerAlignment == null || centerOffset == null);