android: the whole discography, on a page of its own

The artist page already filed every release the desktop's way, but it only
ever showed one category at a time and it showed all of it: no slice anywhere
in that grid, so an artist with 140 releases drew 140 cards. There is a page
now — All in front of the categories, a sort, a grouping by year, and the
editions opened in place under their own record, which is the part a flat
list loses — and the grid behind it stops at twelve with the way down under
it. It is the same classifier twice over the same cached albums, which the
desktop cannot do because its filing waits on a background description
harvest; the three things its own page has and this one does not — a
tracklist per record, an accent sampled per cover, the scroll-led banner —
are 140 calls and 140 decodes over mobile data for rows that are one tap
away, and ANDROID.md says so rather than leaving them looking forgotten.

The list caps at sixty with the rest a button away, before the grouping, so
the last year on screen can be a part of itself; under a name order By year
is not offered, because the years would repeat out of sequence. The mock
gains a 140-record artist so both caps are walked rather than argued about.
This commit is contained in:
KeelrLeek committed 2026-09-14 03:41:16 -05:00
1 parent 1258b2b78d
commit f2cde4ec7c
9 files changed
+491 -12

No files matched your search

+25
View File
@@ -62,6 +62,7 @@
if (!h) return null;
if (h.kind !== "more") return h.kind;
const t = top();
if (t.n === "disco") return "discosort";
if (t.n === "album") return "album-more";
if (t.n === "library") return "library-more";
if (t.n === "playlist") return "playlist-more";
@@ -722,6 +723,30 @@
{@render row("refresh", "Forget and look again", "", act(() => { void forgetLyrics(); }))}
</div>
{/if}
{:else if kind === "discosort"}
{@const c = top().c}
{@const ord = c.order || "new"}
{@const byName = ord === "az" || ord === "za"}
{@const grp = byName ? "none" : (c.group ?? "year")}
<!-- the four orders are written out here rather than imported
from disco.js: this file is edited by every round and a new
import line is a collision waiting to happen. ORDER_LABEL
there carries the same four, and the walk asserts both. -->
<div class="sheet-title">Sort &amp; group</div>
<div class="sheet-sec">Order</div>
<div class="chips" style="padding-bottom:12px">
{#each [["new", "Newest first"], ["old", "Oldest first"], ["az", "A–Z"], ["za", "Z–A"]] as [k, l] (k)}
<button class="chip" class:on={ord === k} class:quiet={ord !== k} aria-pressed={ord === k} onclick={() => patch({ order: k })}>{l}</button>
{/each}
</div>
<div class="sheet-sec">Group</div>
<div class="chips" style="padding-bottom:12px">
{#each [["year", "By year"], ["none", "None"]] as [k, l] (k)}
<button class="chip" class:on={grp === k} class:quiet={grp !== k} aria-pressed={grp === k} disabled={byName && k === "year"} onclick={() => patch({ group: k })}>{l}</button>
{/each}
</div>
{#if byName}<div class="sec-note">By year needs a date order — under A–Z the years would repeat out of sequence.</div>{/if}
<div style="padding: 4px var(--pad) 16px"><button class="btn btn-fill wide" onclick={closeHalf}>Done</button></div>
{:else if kind === "librarysort"}
<div class="sheet-title">Sort &amp; view</div>
<div class="sheet-sec">Order</div>