copyWith method
SearchProps
copyWith({
- String? placeholder,
- String? value,
- void onChanged(
- String value
- void onSubmitted(
- String value
- bool? showClear,
- bool? showIcon,
- bool? loading,
- Widget? icon,
- bool? autofocus,
- bool? disabled,
- ComponentSize? size,
- SearchStyle? style,
- String? id,
- Map<
String, String> ? attributes, - List<
SearchResult> ? results, - String? resultsId,
- bool? showDropdown,
- String? dropdownMaxHeight,
- String? width,
Implementation
SearchProps copyWith({
String? placeholder,
String? value,
void Function(String value)? onChanged,
void Function(String value)? onSubmitted,
bool? showClear,
bool? showIcon,
bool? loading,
Widget? icon,
bool? autofocus,
bool? disabled,
ComponentSize? size,
SearchStyle? style,
String? id,
Map<String, String>? attributes,
List<SearchResult>? results,
String? resultsId,
bool? showDropdown,
String? dropdownMaxHeight,
String? width,
}) {
return SearchProps(
placeholder: placeholder ?? this.placeholder,
value: value ?? this.value,
onChanged: onChanged ?? this.onChanged,
onSubmitted: onSubmitted ?? this.onSubmitted,
showClear: showClear ?? this.showClear,
showIcon: showIcon ?? this.showIcon,
loading: loading ?? this.loading,
icon: icon ?? this.icon,
autofocus: autofocus ?? this.autofocus,
disabled: disabled ?? this.disabled,
size: size ?? this.size,
style: style ?? this.style,
id: id ?? this.id,
attributes: attributes ?? this.attributes,
results: results ?? this.results,
resultsId: resultsId ?? this.resultsId,
showDropdown: showDropdown ?? this.showDropdown,
dropdownMaxHeight: dropdownMaxHeight ?? this.dropdownMaxHeight,
width: width ?? this.width,
);
}