FlexibleBottomSheet constructor Null safety

FlexibleBottomSheet(
  1. {Key? key,
  2. double minHeight = 0,
  3. double initHeight = 0.5,
  4. double maxHeight = 1,
  5. FlexibleDraggableScrollableWidgetBuilder? builder,
  6. FlexibleDraggableScrollableHeaderWidgetBuilder? headerBuilder,
  7. FlexibleDraggableScrollableWidgetBodyBuilder? bodyBuilder,
  8. bool isCollapsible = false,
  9. bool isExpand = true,
  10. AnimationController? animationController,
  11. List<double>? anchors,
  12. double? minHeaderHeight,
  13. double? maxHeaderHeight,
  14. Decoration? decoration,
  15. VoidCallback? onDismiss}
)

Implementation

FlexibleBottomSheet({
  Key? key,
  this.minHeight = 0,
  this.initHeight = 0.5,
  this.maxHeight = 1,
  this.builder,
  this.headerBuilder,
  this.bodyBuilder,
  this.isCollapsible = false,
  this.isExpand = true,
  this.animationController,
  this.anchors,
  this.minHeaderHeight,
  this.maxHeaderHeight,
  this.decoration,
  this.onDismiss,
})  : assert(minHeight >= 0 && minHeight <= 1),
      assert(maxHeight > 0 && maxHeight <= 1),
      assert(maxHeight > minHeight),
      assert(!isCollapsible || minHeight == 0),
      assert(anchors == null || !anchors.any((anchor) => anchor > maxHeight)),
      assert(anchors == null || !anchors.any((anchor) => anchor < minHeight)),
      super(key: key);