SearchInput constructor
const
SearchInput({
- Key? key,
- String? label,
- bool isRequired = false,
- int? characterLimit,
- InputControlType type = InputControlType.gray,
- IconData? leftIcon = Icons.search_rounded,
- Widget? leftIconWidget,
- String? prefix,
- Widget? prefixWidget,
- String placeholder = 'Search...',
- String? value,
- TextEditingController? controller,
- FocusNode? focusNode,
- String? suffix,
- Widget? suffixWidget,
- bool showClearButton = true,
- ButtonIconGhost? customRightButton,
- bool isError = false,
- bool showErrorMessage = true,
- String errorMessage = 'Error Message',
- List<
String> ? errorMessages, - Widget? errorIconWidget,
- bool enabled = true,
- bool readOnly = false,
- bool autofocus = false,
- ValueChanged<
String> ? onChanged, - ValueChanged<
String> ? onSubmitted, - ValueChanged<
String> ? onSearch, - VoidCallback? onClear,
- VoidCallback? onTap,
Creates a SearchInput instance.
Implementation
const SearchInput({
super.key,
this.label,
this.isRequired = false,
this.characterLimit,
this.type = InputControlType.gray,
this.leftIcon = Icons.search_rounded,
this.leftIconWidget,
this.prefix,
this.prefixWidget,
this.placeholder = 'Search...',
this.value,
this.controller,
this.focusNode,
this.suffix,
this.suffixWidget,
this.showClearButton = true,
this.customRightButton,
this.isError = false,
this.showErrorMessage = true,
this.errorMessage = 'Error Message',
this.errorMessages,
this.errorIconWidget,
this.enabled = true,
this.readOnly = false,
this.autofocus = false,
this.onChanged,
this.onSubmitted,
this.onSearch,
this.onClear,
this.onTap,
});