I'm using FilterChip
with a CircleAvatar
for avatar, but the selected state has a nasty rectangle that I can't seem to find any reference for. How do I remove it?
Code:
child: FilterChip(
avatar: CircleAvatar(
backgroundColor: category.color
),
label: Text(category.name),
selected: badCategoryIds.contains(category.id),
onSelected: (bool value) {
if (value) {
badCategoryIds.add(category.id);
}
else {
badCategoryIds.remove(category.id);
}
categoryChoiceCallback(badCategoryIds);
},
)
Result:
How I want it to appear (taken from material.io documentation):
FilterChip documentation.
You can try to adapt this solution for a Circle Image for your Chip Circle as well
new Container(
width: 190.0,
height: 190.0,
decoration: new BoxDecoration(
shape: BoxShape.circle,
image: new DecorationImage(
fit: BoxFit.fill,
image: new NetworkImage(
"https://i.imgur.com/BoN9kdC.png")
)
)),
from this Medium Post https://medium.com/@boldijar.paul/circle-image-view-in-flutter-965963c46cf5
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With