DropdownFlutter<T>.searchRequest constructor
const
DropdownFlutter<T>.searchRequest ({
- Key? key,
- required Future<
List< futureRequest()?,T> > - required dynamic onChanged(
- T?
- Duration? futureRequestDelay,
- T? initialItem,
- List<
T> ? items, - SingleSelectController<
T?> ? controller, - ScrollController? itemsScrollController,
- String? hintText,
- CustomDropdownDecoration? decoration,
- dynamic visibility()?,
- OverlayPortalController? overlayController,
- String? searchHintText,
- String? noResultFoundText,
- _ListItemBuilder<
T> ? listItemBuilder, - _HeaderBuilder<
T> ? headerBuilder, - _HintBuilder? hintBuilder,
- _NoResultFoundBuilder? noResultFoundBuilder,
- String? validator(
- T?
- bool validateOnChange = true,
- int maxlines = 1,
- double? overlayHeight,
- EdgeInsets? closedHeaderPadding,
- EdgeInsets? expandedHeaderPadding,
- EdgeInsets? itemsListPadding,
- EdgeInsets? listItemPadding,
- Widget? searchRequestLoadingIndicator,
- bool excludeSelected = true,
- bool canCloseOutsideBounds = true,
- bool hideSelectedFieldWhenExpanded = false,
- bool enabled = true,
- CustomDropdownDisabledDecoration? disabledDecoration,
- bool closeDropDownOnClearFilterSearch = false,
- bool shouldResetSelection = false,
Implementation
const DropdownFlutter.searchRequest({
super.key,
required this.futureRequest,
required this.onChanged,
this.futureRequestDelay,
this.initialItem,
this.items,
this.controller,
this.itemsScrollController,
this.hintText,
this.decoration,
this.visibility,
this.overlayController,
this.searchHintText,
this.noResultFoundText,
this.listItemBuilder,
this.headerBuilder,
this.hintBuilder,
this.noResultFoundBuilder,
this.validator,
this.validateOnChange = true,
this.maxlines = 1,
this.overlayHeight,
this.closedHeaderPadding,
this.expandedHeaderPadding,
this.itemsListPadding,
this.listItemPadding,
this.searchRequestLoadingIndicator,
this.excludeSelected = true,
this.canCloseOutsideBounds = true,
this.hideSelectedFieldWhenExpanded = false,
this.enabled = true,
this.disabledDecoration,
this.closeDropDownOnClearFilterSearch = false,
this.shouldResetSelection = false,
}) : assert(
initialItem == null || controller == null,
'Only one of initialItem or controller can be specified at a time',
),
_searchType = _SearchType.onRequestData,
_dropdownType = _DropdownType.singleSelect,
initialItems = null,
onListChanged = null,
listValidator = null,
headerListBuilder = null,
multiSelectController = null;