Closed willhhf closed 1 year ago
Hello @willhhf ,
Thanks a lot for your question.
I don't see any other reason than an historical one. I tried removing this assertion and running an example with both validator
and fieldDecoration
and it ran with no issue.
I removed the assertion and will publish a new version as soon as possible to pub.dev . Before that, I must run the automated integration tests.
In the meanwhile, you can use the latest GitHub repository code with the following in your pubspec.yaml
file:
search_choices:
git:
url: https://github.com/lcuis/search_choices.git
Hi Lcuis,
Thanks for your prompt reply.
The fixed version run well on my code.
Excellent, thanks a lot for the confirmation!
There is an error when use fieldDecoration and validator together, but why they are related and how can we decorate layour and use validator together?
my code:
SearchChoices.single( //underline: const Divider(), items: items, value: value, style: Theme.of(context).textTheme.displaySmall, fieldDecoration: BoxDecoration( color: Colors.grey.shade200, shape: BoxShape.rectangle, borderRadius: BorderRadius.circular(5), border: Border.all( color: Colors.blueGrey, width: 3, style: BorderStyle.solid, )), hint: hint, searchHint: searchHint, onClear: onClear, onChanged: onChanged, isExpanded: true, validator: validator, );