/Flutter_Drop_Down_List

Flutter Drop Down List

Primary LanguageDart

Flutter Drop Down List

Highly versatile Widget to search through a single or multiple choices from bottom sheet list in a dialog box or a menu.

Platforms

This plugin has been successfully tested on iOS, Android & web.

How to Use

DropDownState(
   DropDown(
     bottomSheetTitle: const Text(
       kCities,
       style: TextStyle(
         fontWeight: FontWeight.bold,
         fontSize: 20.0,
       ),
     ),
     submitButtonChild: const Text(
       'Done',
       style: TextStyle(
         fontSize: 16,
         fontWeight: FontWeight.bold,
       ),
     ),
     data: widget.cities ?? [],
     selectedItems: (List<dynamic> selectedList) {
       List<String> list = [];
       for(var item in selectedList) {
         if(item is SelectedListItem) {
           list.add(item.name);
         }
       }
       showSnackBar(list.toString());
     },
     enableMultipleSelection: true,
   ),
 ).showModal(context);