openAdaptiveModalBottomSheet function
Future
openAdaptiveModalBottomSheet(
- BuildContext context,
- Widget content,
- AdaptiveModalBottomSheetProps props,
- List<
CupertinoActionSheetAction> ? defaultCupertinoActions,
Implementation
Future openAdaptiveModalBottomSheet(
BuildContext context,
Widget content,
AdaptiveModalBottomSheetProps props,
List<CupertinoActionSheetAction>? defaultCupertinoActions,
) {
final ThemeData theme = Theme.of(context);
switch (theme.platform) {
case TargetPlatform.iOS:
case TargetPlatform.macOS:
return openCupertinoModalBottomSheet(
context, content, props.cupertinoProps, defaultCupertinoActions);
case TargetPlatform.android:
case TargetPlatform.fuchsia:
case TargetPlatform.linux:
case TargetPlatform.windows:
default:
return openMaterialModalBottomSheet(
context, content, props.materialProps);
}
}