CarouselView constructor
- Key? key,
- EdgeInsets? padding,
- Color? backgroundColor,
- double? elevation,
- ShapeBorder? shape,
- WidgetStateProperty<
Color?> ? overlayColor, - bool itemSnapping = false,
- double shrinkExtent = 0.0,
- CarouselController? controller,
- Axis scrollDirection = Axis.horizontal,
- bool reverse = false,
- ValueChanged<
int> ? onTap, - bool enableSplash = true,
- required double itemExtent,
- required List<
Widget> children,
Creates a Material Design carousel.
Implementation
const CarouselView({
super.key,
this.padding,
this.backgroundColor,
this.elevation,
this.shape,
this.overlayColor,
this.itemSnapping = false,
this.shrinkExtent = 0.0,
this.controller,
this.scrollDirection = Axis.horizontal,
this.reverse = false,
this.onTap,
this.enableSplash = true,
required double this.itemExtent,
required this.children,
}) : consumeMaxWeight = true,
flexWeights = null;