diff options
| author | Adam Soltys <[email protected]> | 2026-10-07 08:34:45 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-10-07 08:34:45 -0700 |
| commit | 1d6786265f4d86b2260b30060df473a51774fb72 (patch) | |
| tree | 150a845df799240a6eb86cc2a42591f6d91925de | |
| parent | faad243486666eb4cbefcd7ff813329e707106dd (diff) | |
| download | coinosv3-1d6786265f4d86b2260b30060df473a51774fb72.tar.gz coinosv3-1d6786265f4d86b2260b30060df473a51774fb72.zip | |
Feed: a picture with no column-sized copy is decoded ahead too, so its row paints it on the first frame
Since column-sized copies (8249fbe), a picture small enough to keep (or a GIF)
was fetched for its size but never decoded ahead: the row's <img> decoded it
on sight, from the network again when the host says no-store. Decode the
original ahead when there is no copy. (feed-live-test caught it.)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
| -rw-r--r-- | src/features/messages.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/features/messages.js b/src/features/messages.js index f98df3a..bad4a60 100644 --- a/src/features/messages.js +++ b/src/features/messages.js @@ -5654,7 +5654,9 @@ export function messagesFeature(ctx) { const task = (async () => { const got = (await storedMediaThumb(url)) || (await makeMediaThumb(url).catch(() => null)); if (got) { - if (got.thumb) await decodeAhead(got.thumb); + // no copy (small already, or a GIF): the original is what paints, + // so it's the one decoded ahead — the row mustn't decode it on sight + await decodeAhead(got.thumb || url); mediaReady.set(url, got); return; } |
