openSheetOverlay<T> function

DrawerOverlayCompleter<T?> openSheetOverlay<T>({
  1. required BuildContext context,
  2. required WidgetBuilder builder,
  3. required OverlayPosition position,
  4. bool barrierDismissible = true,
  5. bool transformBackdrop = false,
  6. WidgetBuilder? backdropBuilder,
  7. Color? barrierColor,
  8. bool draggable = false,
  9. AnimationController? animationController,
  10. bool autoOpen = true,
  11. BoxConstraints? constraints,
  12. AlignmentGeometry? alignment,
})

Implementation

DrawerOverlayCompleter<T?> openSheetOverlay<T>({
  required BuildContext context,
  required WidgetBuilder builder,
  required OverlayPosition position,
  bool barrierDismissible = true,
  bool transformBackdrop = false,
  WidgetBuilder? backdropBuilder,
  Color? barrierColor,
  bool draggable = false,
  AnimationController? animationController,
  bool autoOpen = true,
  BoxConstraints? constraints,
  AlignmentGeometry? alignment,
}) {
  return openRawDrawer<T>(
    context: context,
    transformBackdrop: transformBackdrop,
    barrierDismissible: barrierDismissible,
    useSafeArea: false, // handled by the sheet itself
    animationController: animationController,
    backdropBuilder: backdropBuilder,
    autoOpen: autoOpen,
    constraints: constraints,
    alignment: alignment,
    builder: (context, extraSize, size, padding, stackIndex) {
      return SheetWrapper(
        position: position,
        expands: true,
        draggable: draggable,
        extraSize: extraSize,
        size: size,
        padding: padding,
        barrierColor: barrierColor,
        stackIndex: stackIndex,
        child: Builder(builder: (context) {
          return builder(context);
        }),
      );
    },
    position: position,
  );
}