SelectProps<T> constructor

const SelectProps<T>({
  1. required List<SelectOptionProps<T>> options,
  2. T? value,
  3. List<T>? values,
  4. String placeholder = 'Select...',
  5. bool disabled = false,
  6. bool clearable = false,
  7. bool searchable = false,
  8. bool multiSelect = false,
  9. String? label,
  10. String? helperText,
  11. String? error,
  12. ComponentSize size = ComponentSize.md,
  13. bool required = false,
  14. String? maxDropdownHeight,
  15. bool loading = false,
  16. String loadingText = 'Loading...',
  17. String emptyMessage = 'No options found',
  18. String searchPlaceholder = 'Search...',
  19. SelectDropdownDirection dropdownDirection = SelectDropdownDirection.down,
  20. bool closeOnSelect = true,
  21. bool showSelectedCount = true,
  22. Widget? prefix,
  23. int? maxSelections,
  24. bool showCheckboxes = true,
  25. bool isOpen = false,
  26. String searchQuery = '',
  27. List<SelectOptionProps<T>> filteredOptions = const [],
  28. void onToggle()?,
  29. void onSelect(
    1. T value
    )?,
  30. void onClear()?,
  31. void onSearchChange(
    1. String query
    )?,
})

Implementation

const SelectProps({
  required this.options,
  this.value,
  this.values,
  this.placeholder = 'Select...',
  this.disabled = false,
  this.clearable = false,
  this.searchable = false,
  this.multiSelect = false,
  this.label,
  this.helperText,
  this.error,
  this.size = ComponentSize.md,
  this.required = false,
  this.maxDropdownHeight,
  this.loading = false,
  this.loadingText = 'Loading...',
  this.emptyMessage = 'No options found',
  this.searchPlaceholder = 'Search...',
  this.dropdownDirection = SelectDropdownDirection.down,
  this.closeOnSelect = true,
  this.showSelectedCount = true,
  this.prefix,
  this.maxSelections,
  this.showCheckboxes = true,
  this.isOpen = false,
  this.searchQuery = '',
  this.filteredOptions = const [],
  this.onToggle,
  this.onSelect,
  this.onClear,
  this.onSearchChange,
});