NestedCircularProgress constructor

const NestedCircularProgress({
  1. Key? key,
  2. required double progress,
  3. Color? progressColor = Colors.blue,
  4. Color? progressBackgroundColor = Colors.grey,
  5. double size = 150,
  6. Duration animationDuration = const Duration(seconds: 2),
  7. double? strokeWidth = 12,
  8. Widget? child,
})

Creates a NestedCircularProgress widget.

  • progress must be between 0 and 100.
  • progressColor sets the arc color (default: Colors.blue).
  • progressBackgroundColor sets the circle color (default: Colors.grey).
  • size controls the diameter of the widget (default: 150).
  • animationDuration controls how long the progress animates (default: 2s).
  • strokeWidth controls the arc thickness (default: 12).
  • child places a widget in the center.

Implementation

const NestedCircularProgress({
  super.key,
  required this.progress,
  this.progressColor = Colors.blue,
  this.progressBackgroundColor = Colors.grey,
  this.size = 150,
  this.animationDuration = const Duration(seconds: 2),
  this.strokeWidth = 12,
  this.child,
});