ExpandableAnimatedCard.sheet constructor

const ExpandableAnimatedCard.sheet({
  1. Key? key,
  2. required WidgetBuilder collapsedBuilder,
  3. required WidgetBuilder expandedBuilder,
  4. BorderRadiusGeometry? borderRadius = const BorderRadius.all(Radius.circular(20)),
  5. EdgeInsetsGeometry margin = const EdgeInsets.fromLTRB(16, 16, 16, 16),
  6. Color? backgroundColor = const Color(0xFF5D5D5D),
  7. double elevation = 8.0,
  8. Color? shadowColor,
  9. double? maxHeight,
  10. double? maxHeightFraction,
  11. double? dragDismissThresholdFraction,
  12. Color overlayBackgroundColor = Colors.black54,
  13. double blurSigma = 0.0,
  14. Color barrierColor = Colors.transparent,
  15. bool dragToClose = true,
  16. double dragDismissThreshold = 120.0,
  17. bool barrierDismissible = true,
  18. bool useRootNavigator = false,
  19. RouteSettings? routeSettings,
  20. String? barrierLabel,
  21. Duration animationDuration = const Duration(milliseconds: 500),
  22. Curve animationCurve = Curves.easeInOutCubic,
  23. VoidCallback? onClose,
  24. VoidCallback? onOpened,
  25. VoidCallback? onClosed,
  26. ValueChanged<bool>? onStateChanged,
  27. ExpandableAnimatedCardController? controller,
  28. bool autoOpenOnTap = true,
})

Factory: sheet

Implementation

const ExpandableAnimatedCard.sheet({
  super.key,
  required this.collapsedBuilder,
  required this.expandedBuilder,
  this.borderRadius = const BorderRadius.all(Radius.circular(20)),
  EdgeInsetsGeometry margin = const EdgeInsets.fromLTRB(
    16,
    16,
    16,
    16,
  ), // Retro-compatibility
  this.backgroundColor = const Color(0xFF5D5D5D),
  this.elevation = 8.0,
  this.shadowColor,
  double? maxHeight,
  double? maxHeightFraction,
  double? dragDismissThresholdFraction,
  this.overlayBackgroundColor = Colors.black54,
  this.blurSigma = 0.0,
  this.barrierColor = Colors.transparent,
  bool dragToClose = true, // Retro-compatibility
  this.dragDismissThreshold = 120.0,
  this.barrierDismissible = true,
  this.useRootNavigator = false,
  this.routeSettings,
  this.barrierLabel,
  this.animationDuration = const Duration(milliseconds: 500),
  this.animationCurve = Curves.easeInOutCubic,
  this.onClose,
  this.onOpened,
  this.onClosed,
  this.onStateChanged,
  this.controller,
  this.autoOpenOnTap = true,
}) : _type = CardType.sheet,
     expandedMargin = margin,
     // Mapped
     enableDragToDismiss = dragToClose,
     // Mapped
     fadeInterval = const Interval(
       0.35,
       1.0,
       curve: Cubic(0.5, 0.0, 0.3, 1.0),
     ),
     expandedPadding = EdgeInsets.zero,
     maxWidth = null,
     useSafeArea = false,
     backgroundGradient = null,
     borderColor = null,
     borderWidth = 0.0,
     headerMode = HeaderMode.none,
     headerHeight = 0.0,
     headerBuilder = null,
     scrimBuilder = null,
     clipBehavior = Clip.antiAlias,
     menuOffset = 0.0,
     menuAlignment = Alignment.topCenter,
     _sheetMaxHeight = maxHeight,
     _sheetMaxHeightFraction = maxHeightFraction,
     _sheetDragDismissThresholdFraction = dragDismissThresholdFraction;