DropdownField<T> constructor

const DropdownField<T>({
  1. Key? key,
  2. required List<T> items,
  3. required T? selectedItem,
  4. required String itemAsString(
    1. T
    ),
  5. required dynamic onChanged(
    1. T?
    ),
  6. TextStyle? textStyle,
  7. String? labelText,
  8. String? validator(
    1. T?
    )?,
  9. bool readOnly = false,
  10. bool compare(
    1. T?,
    2. T?
    )?,
  11. bool showSearchBox = false,
  12. TextStyle? labelStyle,
  13. bool autoValidate = false,
})

Implementation

const DropdownField({
  super.key,
  required this.items,
  required this.selectedItem,
  required this.itemAsString,
  required this.onChanged,
  this.textStyle,
  this.labelText,
  this.validator,
  this.readOnly = false,
  this.compare,
  this.showSearchBox = false,
  this.labelStyle,
  this.autoValidate = false,
});