AdvancedSearch constructor

const AdvancedSearch({
  1. required List<String> searchItems,
  2. required OnTap onItemTap,
  3. int maxElementsToDisplay = 7,
  4. SearchClear onSearchClear = _searchClearDefaultFunction,
  5. Color? selectedTextColor,
  6. Color? unSelectedTextColor,
  7. Color? enabledBorderColor,
  8. Color? disabledBorderColor,
  9. Color? focusedBorderColor,
  10. Color? cursorColor,
  11. double borderRadius = 10.0,
  12. double fontSize = 14.0,
  13. double singleItemHeight = 45.0,
  14. int itemsShownAtStart = 10,
  15. String hintText = 'Enter a name',
  16. bool autoCorrect = false,
  17. bool enabled = true,
  18. SubmitResults? onSubmitted,
  19. SubmitResults? onEditingProgress,
  20. Color? inputTextFieldBgColor,
  21. Color searchResultsBgColor = Colors.white,
  22. SearchMode searchMode = SearchMode.CONTAINS,
  23. bool caseSensitive = false,
  24. int minLettersForSearch = 0,
  25. Color borderColor = const Color(0xFFFAFAFA),
  26. Color hintTextColor = Colors.grey,
  27. bool clearSearchEnabled = true,
  28. bool showListOfResults = true,
  29. bool hideHintOnTextInputFocus = false,
  30. double verticalPadding = 10,
  31. double horizontalPadding = 10,
  32. WidgetItems? searchItemsWidget,
  33. bool autoListing = false,
})

Implementation

const AdvancedSearch({
  required this.searchItems,
  required this.onItemTap,
  this.maxElementsToDisplay = 7,
  this.onSearchClear = _searchClearDefaultFunction,
  this.selectedTextColor,
  this.unSelectedTextColor,
  this.enabledBorderColor,
  this.disabledBorderColor,
  this.focusedBorderColor,
  this.cursorColor,
  this.borderRadius = 10.0,
  this.fontSize = 14.0,
  this.singleItemHeight = 45.0,
  this.itemsShownAtStart = 10,
  this.hintText = 'Enter a name',
  this.autoCorrect = false,
  this.enabled = true,
  this.onSubmitted,
  this.onEditingProgress,
  this.inputTextFieldBgColor,
  this.searchResultsBgColor = Colors.white,
  this.searchMode = SearchMode.CONTAINS,
  this.caseSensitive = false,
  this.minLettersForSearch = 0,
  this.borderColor = const Color(0xFFFAFAFA),
  this.hintTextColor = Colors.grey,
  this.clearSearchEnabled = true,
  this.showListOfResults = true,
  this.hideHintOnTextInputFocus = false,
  this.verticalPadding = 10,
  this.horizontalPadding = 10,
  this.searchItemsWidget,
  this.autoListing = false,
});