polish(ux): drop the checkmark on selected filter chips

The tick overlapped the leading icon on selected chips, reading as a
confusing blob. The solid fill already signals 'on', so hide the
checkmark. Also make the selected label reliably white via an explicit
per-chip style: the global ChipTheme's secondaryLabelStyle was not
applied to FilterChips, leaving dark text on green. Plain attribute/
market chips now share a PlainFilterChip widget; swatch and month chips
just drop their tick.
This commit is contained in:
vjrj 2026-07-11 08:05:56 +02:00
parent 5ecdd1222a
commit 9f01c3893a
5 changed files with 68 additions and 59 deletions

View file

@ -13,6 +13,7 @@ import '../services/social_service.dart';
import '../services/social_settings.dart';
import '../state/offers_cubit.dart';
import 'edge_fade.dart';
import 'filter_chips.dart';
import 'market_widgets.dart';
import 'theme.dart';
@ -488,28 +489,24 @@ class _MarketFilterBar extends StatelessWidget {
final chips = <Widget>[
if (hasOrganic)
FilterChip(
PlainFilterChip(
key: const Key('market.filter.organic'),
avatar: Icon(
Icons.eco,
size: 18,
color: state.organicOnly ? Colors.white : seedGreen,
),
label: Text(t.editVariety.organic),
icon: Icons.eco,
label: t.editVariety.organic,
selected: state.organicOnly,
onSelected: (_) => cubit.toggleOrganicOnly(),
),
for (final type in types)
FilterChip(
PlainFilterChip(
key: Key('market.filter.type.${type.name}'),
label: Text(offerTypeLabel(t, type)),
label: offerTypeLabel(t, type),
selected: state.typeFilter.contains(type),
onSelected: (_) => cubit.toggleType(type),
),
for (final category in categories)
FilterChip(
PlainFilterChip(
key: Key('market.filter.category.$category'),
label: Text(category),
label: category,
selected: state.categoryFilter.contains(category),
onSelected: (_) => cubit.toggleCategory(category),
),