adaptive_action_sheet 1.0.1 copy "adaptive_action_sheet: ^1.0.1" to clipboard
adaptive_action_sheet: ^1.0.1 copied to clipboard

outdated

A Flutter package for action bottom sheet that adapts to the platform (Android/iOS).

Adaptive action sheet (Developers Preview) #

pub package

A action bottom sheet that adapts to the platform (Android/iOS).

iOS Android
n1 n2

Getting Started #

Add the package to your pubspec.yaml:

adaptive_action_sheet: ^1.0.1

In your dart file, import the library:

import 'package:adaptive_action_sheet/adaptive_action_sheet.dart';

Instead of using a showModalBottomSheet use showAdaptiveActionSheet Widget:

showAdaptiveActionSheet(
 context: context,
 actions: <BottomSheetAction>[
    BottomSheetAction(title: 'Item 1', onPressed: () {}),
    BottomSheetAction(title: 'Item 2', onPressed: () {}),
    BottomSheetAction(title: 'Item 3', onPressed: () {}),
 ],
);

Parameters: #

showAdaptiveActionSheet:

  • actions: The Actions list that will appear on the ActionSheet. (required)

BottomSheetAction:

  • title: The string that will appear in the title bar of the action item. (required)
  • onPressed: The callback that is called when the action item is tapped. (required)
102
likes
0
pub points
97%
popularity

Publisher

unverified uploader

A Flutter package for action bottom sheet that adapts to the platform (Android/iOS).

Homepage
Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on adaptive_action_sheet