enhanced_drop_down 0.1.4 copy "enhanced_drop_down: ^0.1.4" to clipboard
enhanced_drop_down: ^0.1.4 copied to clipboard

outdated

A completely customizable drop down widget that comes with a label built in. You can customize the label, the data, the default value and more.

Enhanced Dropdown Widget #

A completely customizable drop down widget, which wraps a label and a dropdown widget together into one component.

Usage #

To use this package add enhanced_drop_down as a dependency in your pubspec.yaml file..

API #

An Enhanced Dropdown Widget (or EDW), is based on flutter's dropdown widget, but enhances it in the following manner:

  • Attached to the dropdown is a label, to help point out to the user what values the dropdown might have

  • You can pass in the data source from where the dropdown will get its values

  • You can pass a default value to be the visible choice when the dropdown is not selected

  • You want to know what choice the user made, so a callback function must be supplied to get the user's choice back

  • In case you are relying on an external source to provide the data for the dropdown, you can pass in the url to fetch that data

Please be aware that currently, the parsing of the url is in JSON and only valid for key-value pairs that are in String format and type

Instantiating an EDW is as follows: #

new EnhancedDropDownWidget(
    key: UniqueKey(),
    dropdownLabelTitle: "Label",
    defaultOptionText: "Select One",
    urlToFetchData: "https://pub.dev/",
    dataSource: ["Option A", "Option B"],
    valueReturned: (chosen) {

      },
    )
6
likes
0
pub points
71%
popularity

Publisher

unverified uploader

A completely customizable drop down widget that comes with a label built in. You can customize the label, the data, the default value and more.

Homepage

License

unknown (LICENSE)

Dependencies

flutter, http

More

Packages that depend on enhanced_drop_down