Feature request: add alignment to PrefDropdown
Closed this issue · 2 comments
First, thank you for the excellent and useful package.
I have a feature request for PrefDropdown, maybe something can be done.
I can make an alignment for individual item:
DropdownMenuItem(... alignment: AlignmentDirectional.center)
But in the PrefDropdown itself it is always defaulted to AlignmentDirectional.centerStart, because it is a default value for DropdownButton.
Will appreciate if PrefDropdown will take 'alignment' as an argument and pass it to DropdownButton, so behavior will be consistent.
Also, do you think that definitions like:
class _PrefDropdownState extends State<PrefDropdown>
can be changed to:
class PrefDropdownState extends State<PrefDropdown>?
That will make classes public like in Flutter (typical example is PopupMenuItemState, it is public, so hard-coded behavior can be changed), so it will be possible to create wrappers and enhance functionality.
You're right, the _ on State classes is a bad practice.
the alignment property is a good idea.
You can work on a pull request if you like.
Implemented in version 2.7.0