HcDropdownSearch<T>.multiSelection constructor
HcDropdownSearch<T>.multiSelection ({
- Key? key,
- AutovalidateMode? autoValidateMode = AutovalidateMode.disabled,
- List<
T> items = const [], - HcDropdownSearchOnFind<
T> ? asyncItems, - HcDropDownDecoratorProps dropdownDecoratorProps = const HcDropDownDecoratorProps(),
- HcClearButtonProps clearButtonProps = const HcClearButtonProps(),
- HcDropdownButtonProps dropdownButtonProps = const HcDropdownButtonProps(),
- bool enabled = true,
- HcDropdownSearchFilterFunction<
T> ? filterFn, - HcDropdownSearchItemAsString<
T> ? itemAsString, - HcDropdownSearchCompareFunction<
T> ? compareFn, - List<
T> selectedItems = const [], - HcPopupPropsMultiSelection<
T> popupProps = const HcPopupPropsMultiSelection.menu(), - FormFieldSetter<
List< ? onSaved,T> > - ValueChanged<
List< ? onChanged,T> > - BeforeChangeMultiSelection<
T> ? onBeforeChange, - BeforePopupOpeningMultiSelection<
T> ? onBeforePopupOpening, - FormFieldValidator<
List< ? validator,T> > - HcDropdownSearchBuilderMultiSelection<
T> ? dropdownBuilder,
Implementation
HcDropdownSearch.multiSelection({
Key? key,
this.autoValidateMode = AutovalidateMode.disabled,
this.items = const [],
this.asyncItems,
this.dropdownDecoratorProps = const HcDropDownDecoratorProps(),
this.clearButtonProps = const HcClearButtonProps(),
this.dropdownButtonProps = const HcDropdownButtonProps(),
this.enabled = true,
this.filterFn,
this.itemAsString,
this.compareFn,
this.selectedItems = const [],
this.popupProps = const HcPopupPropsMultiSelection.menu(),
FormFieldSetter<List<T>>? onSaved,
ValueChanged<List<T>>? onChanged,
BeforeChangeMultiSelection<T>? onBeforeChange,
BeforePopupOpeningMultiSelection<T>? onBeforePopupOpening,
FormFieldValidator<List<T>>? validator,
HcDropdownSearchBuilderMultiSelection<T>? dropdownBuilder,
}) : assert(
!popupProps.showSelectedItems || T == String || compareFn != null,
),
onChangedMultiSelection = onChanged,
onBeforePopupOpeningMultiSelection = onBeforePopupOpening,
onSavedMultiSelection = onSaved,
onBeforeChangeMultiSelection = onBeforeChange,
validatorMultiSelection = validator,
dropdownBuilderMultiSelection = dropdownBuilder,
isMultiSelectionMode = true,
dropdownBuilder = null,
validator = null,
onBeforeChange = null,
selectedItem = null,
onSaved = null,
onChanged = null,
onBeforePopupOpening = null,
super(key: key);