DropdownSearch<T> class

Inheritance

Constructors

Properties

autoFocusSearchBox → bool
the search box will be focused if true
final
autoValidateMode → AutovalidateMode
final
clearButton → Widget?
custom dropdown clear button icon widget
final
clearButtonBuilder → IconButtonBuilder?
custom clear button widget builder
final
clearButtonSplashRadius → double?
custom splash radius for the clear button If null, default splash radius of icon_button is used.
final
compareFn → DropdownSearchCompareFn<T>?
function that compares two object with the same type to detected if it's the selected item or not
final
dialogMaxWidth → double?
the max width for the dialog
final
to customize list of items UI
final
If true, the dropdownBuilder will continue the uses of material behavior This will be useful if you want to handle a custom UI only if the item !=null
final
custom dropdown icon button widget
final
custom dropdown button widget builder
final
custom splash radius for the dropdown button If null, default splash radius of icon_button is used.
final
style on which to base the label
final
dropdownSearch input decoration
final
How the text in the decoration should be aligned horizontally.
final
How the text should be aligned vertically.
final
emptyBuilder → EmptyBuilder?
custom layout for empty results
final
enabled → bool
enable/disable dropdownSearch
final
errorBuilder → ErrorBuilder?
custom layout for error
final
favoriteItemBuilder → FavoriteItemsBuilder<T>?
to customize favorites chips
final
favoriteItems → FavoriteItems<T>?
favorites items list
final
favoriteItemsAlignment → MainAxisAlignment?
favorite items alignment
final
filterFn → DropdownSearchFilterFn<T>?
custom filter function
final
hashCode → int
The hash code for this object.
no setterinherited
hint → String?
DropDownSearch hint
final
isFilteredOnline → bool
true if the filter on items is applied onlie (via API)
final
itemAsString → DropdownSearchItemAsString<T>?
customize the fields the be shown
final
items → List<T>?
offline items list
final
itemStyle → TextStyle
final
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
label → String?
DropDownSearch label
final
loadingBuilder → EmptyBuilder?
custom layout for loading items
final
maxHeight → double?
the max height for dialog/bottomSheet/Menu
final
mode → Mode
MENU / DIALOG/ BOTTOM_SHEET
final
onBeforeChange → BeforeChange<T?>?
callback executed before applying value change
final
onChanged → ValueChanged<T?>?
called when a new item is selected
final
onFind → DropdownSearchOnFind<T>?
function that returns item from API
final
onPopupDismissed → VoidCallback?
called when popup is dismissed
final
onSaved → ValueChanged<T?>?
An optional method to call with the final value when the form is saved via
final
popupBackgroundColor → Color?
the title for dialog/menu/bottomSheet
final
popupBarrierColor → Color?
set a custom color for the popup barrier
final
popupBarrierDismissible → bool
whether modal can be dismissed by tapping the modal barrier
final
popupItemBuilder → DropdownSearchPopupItemBuilder<T>?
to customize selected item
final
popupItemDisabled → DropdownSearchPopupItemEnabled<T>?
defines if an item of the popup is enabled or not, if the item is disabled, it cannot be clicked
final
popupSafeArea → PopupSafeArea
set properties of popup safe area
final
popupShape → ShapeBorder?
custom shape for the popup
final
popupTitle → Widget?
custom widget for the popup title
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scrollbarProps → ScrollbarProps?
scrollbar properties
final
searchBoxController → TextEditingController?
text controller to set default search word for example
final
searchBoxDecoration → InputDecoration?
decoration for search box
final
searchBoxStyle → TextStyle?
final
searchDelay → Duration?
callback executed before applying value change delay before searching, change it to Duration(milliseconds: 0) if you do not use online search
final
searchFieldProps → TextFieldProps?
object that passes all props to search field
final
selectedItem → T?
selected item
final
showAsSuffixIcons → bool
whether to manage the clear and dropdown icons via InputDecoration suffixIcon
final
showClearButton → bool
show/hide clear selected item
final
showFavoriteItems → bool
show or hide favorites items
final
showSearchBox → bool
show/hide the search box
final
showSelectedItem → bool
select the selected item in the menu/dialog/bottomSheet of items
final
style → TextStyle
final
title → String?
final
validator → FormFieldValidator<T>?
An optional method that validates an input. Returns an error string to display if the input is invalid, or null otherwise.
final

Methods

createElement() → StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → DropdownSearchState<T>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() → List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String
Returns a one-line detailed description of the object.
inherited
toStringShort() → String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited