fix(shopping): remove old flat-list li styles causing visual doubling

.shopping-items li was the old single-list item rule. After the
multi-list refactor, the direct children of .shopping-items are
<li class="shopping-list-box"> wrappers, not individual items.
The old rule gave the box the same background + border + padding +
tap-target as the .shopping-item divs inside it — making each list
look like it appeared twice.

Drop the generic li rule entirely. Items are styled via
.shopping-item, boxes via .shopping-list-box, empty state via
.shopping-items .empty. Also dedup by card_uid in loadShopping JS
as a safety net.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
thandClaude Opus 4.6 committed 2026-04-16 17:35:27 +02:00
1 parent 59be08a8f8
commit 5c9e9254d1
2 files changed
+10 -11

No files matched your search

+8 -1
View File
@@ -773,7 +773,14 @@ async function loadShopping(quiet = false) {
const list = $('shopping-items');
if (!list) return;
if (!data?.ok) { if (!quiet) shoppingErr(data?.error || 'load failed'); return; }
const lists = data.lists || [];
// Dedup by card_uid — belt and suspenders in case the relay DB
// has stale rows from earlier schema migrations.
const seen = new Set();
const lists = (data.lists || []).filter(l => {
if (seen.has(l.card_uid)) return false;
seen.add(l.card_uid);
return true;
});
if (!lists.length) {
if (title) title.textContent = 'Shopping';
list.innerHTML = '<li class="empty">no active shopping lists</li>';