M3ECarousel constructor

const M3ECarousel({
  1. Key? key,
  2. M3ECarouselController? controller,
  3. double? width,
  4. double? height,
  5. Axis axis = Axis.horizontal,
  6. M3ECarouselType type = M3ECarouselType.hero,
  7. bool? isExtended,
  8. bool? freeScroll,
  9. M3ECarouselHeroAlignment heroAlignment = M3ECarouselHeroAlignment.center,
  10. double uncontainedItemExtent = M3ECarouselTheme.defaultUncontainedItemExtent,
  11. double uncontainedShrinkExtent = M3ECarouselTheme.defaultUncontainedShrinkExtent,
  12. double? childElementBorderRadius,
  13. double? largeMaxWidth,
  14. EdgeInsetsGeometry? itemPadding,
  15. int scrollAnimationDuration = M3ECarouselTheme.defaultScrollAnimationDuration,
  16. double fixedPulseDelta = 4,
  17. int singleSwipeGestureSensitivityRange = M3ECarouselTheme.defaultSingleSwipeGestureSensitivityRange,
  18. void onTap(
    1. int selectedIndex
    )?,
  19. ValueChanged<M3ECarouselChangeDetails>? onChange,
  20. M3EHapticFeedback haptic = M3EHapticFeedback.none,
  21. Widget? header,
  22. bool showAll = false,
  23. required List<M3ECarouselItem> children,
})

Creates a Material Design carousel.

Implementation

const M3ECarousel({
  super.key,
  this.controller,
  this.width,
  this.height,
  this.axis = Axis.horizontal,
  this.type = M3ECarouselType.hero,
  this.isExtended,
  this.freeScroll,
  this.heroAlignment = M3ECarouselHeroAlignment.center,
  this.uncontainedItemExtent = M3ECarouselTheme.defaultUncontainedItemExtent,
  this.uncontainedShrinkExtent =
      M3ECarouselTheme.defaultUncontainedShrinkExtent,
  this.childElementBorderRadius,
  this.largeMaxWidth,
  this.itemPadding,
  this.scrollAnimationDuration =
      M3ECarouselTheme.defaultScrollAnimationDuration,
  this.fixedPulseDelta = 4,
  this.singleSwipeGestureSensitivityRange =
      M3ECarouselTheme.defaultSingleSwipeGestureSensitivityRange,
  this.onTap,
  this.onChange,
  this.haptic = M3EHapticFeedback.none,
  this.header,
  this.showAll = false,
  required this.children,
});