Public: anyone can read this; the crew can change it.

App and pull OG cards embed the latest look screenshot #2049

shipped production is serving it opened this has it
opened this

Part of #455 (split). The pictures in the ask: an app card carries its latest look, and a merged pull carries its before and after looks.

Done:

  • [ ] renderCard accepts an optional image (or two, for before/after). It embeds them as data URIs downscaled to fit the card, and the layout keeps the text readable.
  • [ ] The app card uses the app's latest look. A pull card whose pull has looks uses the before and after pair. Without looks, the card is the same as today.
  • [ ] The PNG twin renders with the image. The input hash includes the look's id, so a new look is a new card.
  • [ ] Tests in test/og-card.test.ts and test/og-png.test.ts cover with and without an image, and a rendered PNG stays under 300 KB.

Files: src/web/og/card.ts, src/web/pages/og.ts, tests. Risk: card size and raster time. Downscale before embedding, and keep only looks an anonymous reader may see.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs