feat(art): replace all 72 posts' artwork with the v2 pipeline
Deploy / build (push) Successful in 17s

Every post now carries one unique local-ComfyUI/Ideogram 4 base frame, composited
into EN + ZH share cards, a banner and list thumbs.

- the shipped prompts_catalog held only 21 distinct metaphors for 72 posts (16
  shared one visual), so all 72 were rewritten as unique object+state metaphors
  and 10 frames re-rolled after OCR found pseudo-text rendered at legible size
- render_from_art.mjs emits JPEG by default (558 KB PNG -> 84 KB mozjpeg q85);
  the ZH 1200x630 card did not exist before this batch
- 288 frontmatter fields migrated; the 144 v1 PNGs are gone
- PostList's thumb helper keys off the base slug (a ZH card is zh-<slug>.jpg while
  the thumb is <slug>-800.webp, which 404'd the whole ZH listing)
- [...slug].astro's <picture> regex accepts .jpg
- the repo now carries the art inputs (metaphors.json, captions/<slug>.json,
  refreshed prompts_catalog.json) so a frame is reproducible from git alone
This commit is contained in:
hoelee committed 2026-10-19 04:18:59 +08:00
1 parent 72a9a2af6f
commit 327d516ed9
802 files changed
+1289 -519

No files matched your search

+6 -2
View File
@@ -38,8 +38,12 @@ const hasThumb = (post: CollectionEntry<'posts'>) => {
const p = og(post);
return p.startsWith('/og/') && p !== '/og-default.png' && p !== '/og-default.jpg';
};
const thumb = (post: CollectionEntry<'posts'>, w: 400 | 800) =>
og(post).replace('/og/', '/og/thumb/').replace(/\.png$/, `-${w}.webp`);
const thumb = (post: CollectionEntry<'posts'>, w: 400 | 800) => {
// Thumbs are keyed by the base slug, not by the og file: a ZH post's ogImage is
// /og/zh-<slug>.jpg while the renderer only emits /og/thumb/<slug>-<w>.webp.
const base = post.slug.replace(/^zh\//, '');
return `/og/thumb/${base}-${w}.webp`;
};
---
<ul class="post-list">