BaseMultiSearchField<T extends Object> class
A base multi-select search field widget with customizable options.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- BaseMultiSearchField
Constructors
-
BaseMultiSearchField.new({required void onSelected(String text)?, required String? labelText, required List<
T> dropDownList, required List<String> ? values, required void removeEvent(String text)?, required Widget item(T element), required FutureOr<Iterable< optionsBuilder(TextEditingValue), required String getItemText(T value)?, required Widget fieldSuffixIcon({required VoidCallback onCloseIconTap, required VoidCallback onlyCloseMenu})?, String? errorText, bool? showErrorText, double selectListSpacing = 8, double selectListItemSpacing = 8, double selectListItemRunSpacing = 8, EdgeInsets listPadding = const EdgeInsets.symmetric(vertical: 16), Clip listClipBehavior = Clip.hardEdge, bool usePrototype = true, Key? textFieldKey, bool? isRequired, Key? key, List<T> >Widget> ? trailingList, Icon? unfocusSuffixIcon, double? suffixIconPadding, FocusNode? focusNode, int? errorMaxLines, String? description, T? allElements, double? itemsSpace, ButtonStyle? itemStyle, InputDecoration? fieldDecoration, Widget customTextField({required TextEditingController controller, required FocusNode focusNode, required GlobalKey<State< key, required void onChanged(String)?, required void onSubmitted(String)?, required Widget? suffixIcon, required Key? textFieldKey})?, Widget selectedWidget(String value)?, int? selectedItemMaxLines, ButtonStyle? selectedItemStyle, TextStyle? selectedItemTextStyle, Clip? selectedItemClipBehavior, Widget? selectedItemIcon, double? selectedItemSpacing, TextAlign? selectedItemTextAlign, TextOverflow? selectedItemTextOverflow, List<StatefulWidget> >TextInputFormatter> ? fieldInputFormatters, TextEditingController? controller, TextStyle? labelTextStyle, OptionsViewOpenDirection optionsViewOpenDirection = OptionsViewOpenDirection.down, Widget listButtonItem({required int index, required bool isEnabled, required Key? key, required void onPressed(), required T value})?, double? listCacheExtent, bool listAddSemanticIndexes = true, ScrollController? listController, String? listRestorationId, int? listSemanticChildCount, DragStartBehavior listDragStartBehavior = DragStartBehavior.start, ScrollPhysics? listPhysics, bool? listPrimary, Key? fieldIconKey, Key? listKey, Key? listItemKey, Key? selectedListKey, Key? selectedListItemKey, bool useFindChildIndexCallback = true}) -
const
Properties
- allElements → T?
-
final
- controller → TextEditingController?
-
final
-
customTextField
→ Widget Function({required TextEditingController controller, required FocusNode focusNode, required GlobalKey<
State< key, required void onChanged(String)?, required void onSubmitted(String)?, required Widget? suffixIcon, required Key? textFieldKey})?StatefulWidget> > -
final
- description → String?
-
final
-
dropDownList
→ List<
T> -
final
- errorMaxLines → int?
-
final
- errorText → String?
-
final
- fieldDecoration → InputDecoration?
-
final
- fieldIconKey → Key?
-
final
-
fieldInputFormatters
→ List<
TextInputFormatter> ? -
final
- fieldSuffixIcon → Widget Function({required VoidCallback onCloseIconTap, required VoidCallback onlyCloseMenu})?
-
Suffix icon for the search field
final
- focusNode → FocusNode?
-
final
- getItemText → String Function(T value)?
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- isRequired → bool?
-
final
- item → Widget Function(T element)
-
final
- itemsSpace → double?
-
final
- itemStyle → ButtonStyle?
-
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- labelText → String?
-
final
- labelTextStyle → TextStyle?
-
final
- listAddSemanticIndexes → bool
-
final
- listButtonItem → Widget Function({required int index, required bool isEnabled, required Key? key, required void onPressed(), required T value})?
-
final
- listCacheExtent → double?
-
final
- listClipBehavior → Clip
-
final
- listController → ScrollController?
-
final
- listDragStartBehavior → DragStartBehavior
-
final
- listItemKey → Key?
-
final
- listKey → Key?
-
final
- listPadding → EdgeInsets
-
final
- listPhysics → ScrollPhysics?
-
final
- listPrimary → bool?
-
final
- listRestorationId → String?
-
final
- listSemanticChildCount → int?
-
final
-
final
-
Custom list widget
final
-
final
-
final
- onSelected → void Function(String text)?
-
final
-
optionsBuilder
→ FutureOr<
Iterable< Function(TextEditingValue)T> > -
final
- optionsViewOpenDirection → OptionsViewOpenDirection
-
final
- removeEvent → void Function(String text)?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- selectedItemClipBehavior → Clip?
-
final
- selectedItemIcon → Widget?
-
final
- selectedItemMaxLines → int?
-
final
- selectedItemSpacing → double?
-
final
- selectedItemStyle → ButtonStyle?
-
final
- selectedItemTextAlign → TextAlign?
-
final
- selectedItemTextOverflow → TextOverflow?
-
final
- selectedItemTextStyle → TextStyle?
-
final
- selectedListItemKey → Key?
-
final
- selectedListKey → Key?
-
final
- selectedWidget → Widget Function(String value)?
-
final
- selectListItemRunSpacing → double
-
final
- selectListItemSpacing → double
-
final
- selectListSpacing → double
-
final
- showErrorText → bool?
-
final
- suffixIconPadding → double?
-
final
- textFieldKey → Key?
-
final
-
trailingList
→ List<
Widget> ? -
final
- unfocusSuffixIcon → Icon?
-
final
- useFindChildIndexCallback → bool
-
Whether to use the find child index callback
final
- usePrototype → bool
-
final
-
values
→ List<
String> ? -
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< BaseMultiSearchField< 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