AbdullahChauhan / custom-dropdown

Custom dropdown widget allows to add highly customizable dropdown widget in your projects. Features includes Search on list data, Network search, Multi-selection and many more.
https://pub.dev/packages/animated_custom_dropdown
BSD 3-Clause "New" or "Revised" License
158 stars 73 forks source link

How to change color of items in the dropdown? #41

Closed Besufikad17 closed 1 year ago

Besufikad17 commented 1 year ago

Hey there, I have used CustomDropdown widget without closedFillColor and expandedFillColor parameters but the color of the test inside the menu is white. Is there a way to change it?

AbdullahChauhan commented 1 year ago

Hey @Besufikad17 You can use listItemBuilder property and take full control of items customisation.

Besufikad17 commented 1 year ago

Thanks for responding @AbdullahChauhan Can u provide some examples?

ibrar9523 commented 1 year ago

Widget defaultListItemBuilder(BuildContext context, T result) { return Text( result.toString(), maxLines: widget.maxlines, overflow: TextOverflow.ellipsis, style: const TextStyle(fontSize: 16), ); }

Besufikad17 commented 1 year ago

Thanks a lot