quanht_auto_dropper 0.0.2
quanht_auto_dropper: ^0.0.2 copied to clipboard
AutoDropper adjusts dropdowns to open above or below the trigger, ensuring full visibility based on available space for a seamless user experience.
A lightweight library that intelligently adjusts dropdown positioning to ensure it remains fully visible by opening either above or below the trigger button based on available space.
Features v0.0.1 #
- The
AppAutoDropdownwidget support data list for not enough space. - The
parentScrollControllerthis is ScrollController of screen when scroll auto close dropdown. - The
DropItemclass has replaced theDropListWidgetclass. onSeletedhas been replaced withonSeleted. TheonSeletedcallback is called whenever the selection changes in the dropdown, whether it is selected or deselected.
Getting started #
TODO: List prerequisites and provide or point to information on how to start using the package.
Preview #
|
|
|
Usage #
Simple use #
If you want to control auto close dropdown when scroll need to add parentScrollController in widget parentScrollController is a scrollController of screen
TODO: Please check it to /example folder.
List dropitem need to convert like DropItem include name and id will required
Inaddition, DropItem allow add flag prefix in to dropdown
final DropItem listDrop = DropItem(name: '', id: -1);
AppAutoDropdown(
items: <DropItem>[],
label: '$Label',
hintText: '$Hint text',
parentScrollController: scrollController,
onSelected: (output){},
),