showZeroBottomSheet<T> function

Future<PersistentBottomSheetController> showZeroBottomSheet<T>(
  1. BuildContext context, {
  2. required WidgetBuilder builder,
  3. ZeroBottomSheetStyle? style,
  4. Widget? handleBar,
  5. bool enableDrag = true,
})

Implementation

Future<PersistentBottomSheetController<T>> showZeroBottomSheet<T>(
  BuildContext context, {
  required WidgetBuilder builder,
  ZeroBottomSheetStyle? style,
  Widget? handleBar,
  bool enableDrag = true,
}) async {
  final adaptiveStyle = context.theme.bottomSheetStyle.merge(style);

  return showBottomSheet(
    context: context,
    enableDrag: enableDrag,
    backgroundColor: adaptiveStyle.backgroundColor,
    elevation: adaptiveStyle.elevation,
    shape: RoundedRectangleBorder(
      borderRadius: adaptiveStyle.borderRadius ?? BorderRadius.zero,
    ),
    builder: (context) {
      return _BottomSheetContent(
        style: adaptiveStyle,
        content: builder(context),
        handleBar: handleBar,
      );
    },
  );
}