flutter_easy_autocomplete
flutter_easy_autocomplete copied to clipboard
disabling the edit field
How do I disable the edit field?
In easy_autocomplete.dart file do next:
- On line 97 implement a boolean property like this:
final bool? isTextFormFieldEnabled;. - On line 119 after property called
validatorimplement the new boolean like this:this.isTextFormFieldEnabled. - On line 252 where you have the
TextFormField(), there you need to implement the new property like this:enabled: isTextFormFieldEnabled. - When you instantiate the EasyAutocomplete in your app, pass your own boolean to control the TextFormField (enable/disable).
I haven't tested, but it should work.