showModal<T> method

Future<T?> showModal<T>(
  1. BuildContext context, {
  2. ThemeData? themeData,
  3. bool isScrollControlled = false,
  4. bool useRootNavigator = false,
  5. Color? backgroundColor,
  6. PickerWidgetBuilder? builder,
})

Display modal picker

Implementation

Future<T?> showModal<T>(BuildContext context,
    {ThemeData? themeData,
    bool isScrollControlled = false,
    bool useRootNavigator = false,
    Color? backgroundColor,
    PickerWidgetBuilder? builder}) async {


  return await showModalBottomSheet<T>(

      context: context, //state.context,
       shape: const RoundedRectangleBorder( // <-- SEE HERE
        borderRadius: BorderRadius.vertical(
          top: Radius.circular(25.0),
        ),
      ),
      isScrollControlled: isScrollControlled,
      useRootNavigator: useRootNavigator,
      backgroundColor: backgroundColor,
      builder: (BuildContext context) {

          final picker = makePicker(themeData, true);

        return builder == null ? picker : builder(context, picker);

      });
}