diff --git a/frontend/src/routes/home3/+page.svelte b/frontend/src/routes/home3/+page.svelte index 5850bcd..bd1d8a5 100644 --- a/frontend/src/routes/home3/+page.svelte +++ b/frontend/src/routes/home3/+page.svelte @@ -26,10 +26,16 @@ // truncation handled by CSS (-webkit-line-clamp:2) — breaks on whole words, fills 2 full lines let headline = $derived(news?.title ?? 'What went right this week: the good news that actually matters'); - // The badge shows how long the FULL source article takes — the contrast that sells - // the gist ("the calm 1-min version here; ~10 min if you want the deep dive"). Computed - // server-side from the source word count; hidden entirely when we couldn't measure it. - let fullRead = $derived(news?.source_read_minutes ? `Full story · ~${news.source_read_minutes} min` : ''); + // Sell the value proposition right on the card: the quick UB brief vs. the full article. + // "1 min brief · ~10 min full story" (both known) + // "1 min brief" (full-story time unknown — never fake it) + // hidden (no brief/summary yet) + const briefMins = (t) => Math.max(1, Math.round((t || '').trim().split(/\s+/).filter(Boolean).length / 200)); + let readBadge = $derived.by(() => { + if (!news?.summary) return ''; + const brief = `${briefMins(news.summary)} min brief`; + return news.source_read_minutes ? `${brief} · ~${news.source_read_minutes} min full story` : brief; + }); // small-joys shelf: 3 cells shown two at a time, rotated by the reader (no auto-motion) const JOY_ACCENTS = ['#4f7da8', '#b06a86', '#b06a45']; @@ -130,7 +136,7 @@

{news?.summary || "We read the week so you don't have to doomscroll it. Five quietly hopeful stories, summarised to the gist."}

- {#if fullRead}{fullRead}{/if} + {#if readBadge}{readBadge}{/if}

Read more good news →