fix(meditate): a chosen chip in Explore keeps its icon
The check Material draws on a chosen chip covered the category's or the kind's icon. The chip's colour says it is chosen. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
parent
3e69e6b2f7
commit
f10236b186
4 changed files with 17 additions and 0 deletions
|
|
@ -328,6 +328,7 @@ class _DreamScreenState() extends State<DreamScreen> {
|
|||
children: [
|
||||
for (final mark in DreamMark.values)
|
||||
FilterChip(
|
||||
showCheckmark: false,
|
||||
avatar: Icon(markIcon(mark)),
|
||||
label: Text(markText(l10n, mark)),
|
||||
selected: _marks.contains(mark),
|
||||
|
|
|
|||
|
|
@ -85,6 +85,7 @@ class _ExploreTabState() extends State<ExploreTab> {
|
|||
for (final kind in PracticeKind.values) ...[
|
||||
const SizedBox(width: 8),
|
||||
ChoiceChip(
|
||||
showCheckmark: false,
|
||||
avatar: Icon(kindIcon(kind)),
|
||||
label: Text(kindText(l10n, kind)),
|
||||
selected: _kind == kind,
|
||||
|
|
@ -242,6 +243,7 @@ class _LibraryState() extends State<_Library> {
|
|||
),
|
||||
for (final key in catalogue.categoriesUsed)
|
||||
ChoiceChip(
|
||||
showCheckmark: false,
|
||||
avatar: Icon(categoryIcon(key)),
|
||||
label: Text(categoryName(context, catalogue, key)),
|
||||
selected: _category == key,
|
||||
|
|
|
|||
|
|
@ -64,6 +64,7 @@ class _JournalTabState() extends State<JournalTab> {
|
|||
children: [
|
||||
for (final mark in DreamMark.values)
|
||||
FilterChip(
|
||||
showCheckmark: false,
|
||||
avatar: Icon(markIcon(mark)),
|
||||
label: Text(markText(l10n, mark)),
|
||||
selected: _marks.contains(mark),
|
||||
|
|
|
|||
|
|
@ -1282,6 +1282,19 @@ void main() {
|
|||
expect(find.text('Library credits'), findsNothing);
|
||||
});
|
||||
|
||||
testWidgets('a chosen chip keeps its icon: no check over it (the '
|
||||
"developer's review, 5 Nov 2026)", (tester) async {
|
||||
await exploreLibrary(tester);
|
||||
await scrollTo(tester, find.text('From meditate.example.org'));
|
||||
final chips = tester.widgetList<ChoiceChip>(
|
||||
find.byWidgetPredicate(
|
||||
(widget) => widget is ChoiceChip && widget.avatar != null,
|
||||
),
|
||||
);
|
||||
expect(chips, isNotEmpty);
|
||||
expect(chips.every((chip) => chip.showCheckmark == false), isTrue);
|
||||
});
|
||||
|
||||
group('spoken languages (5 Nov 2026)', () {
|
||||
final german = LibraryItem(
|
||||
id: 'abendruhe',
|
||||
|
|
|
|||
Loading…
Reference in a new issue