Skip to content

feat(cards): name the product on a quickstart page's social card - #36

Merged
xgame92 merged 2 commits into
mainfrom
devin/1796375139-quickstart-card-titles
Dec 4, 2026
Merged

xgame92 merged 2 commits into
mainfrom
devin/1796375139-quickstart-card-titles

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

What and why

Every product's quickstart page is titled "Quickstart", so the five Open Graph cards drawn for them carried identical title text and could come out as identical PNG bytes (reproduced on ID and Guard), and their og:image:alt was the same generic word. A media preview of a shared quickstart link could not tell one product's card from another's.

The card title and its alt text now go through one shared pure helper (cardTitle in src/social-card.ts) that names the product the page was copied from (entry.data.source.product), product first: the ID card reads "Gateweave ID quickstart", the Guard card "Gateweave Guard quickstart". Putting the product first also keeps it off an orphan line of its own. When such a page has no description of its own, the card falls back to one concise line naming the product — "Set up Gateweave ID on your own Cloudflare account." — instead of the site-wide default. Any other page, and any authored description, is untouched.

Unchanged on purpose: the pages' own headings, the sidebar labels, canonical URLs, generated source files, the card's look and logo.

Where the change belongs

  • It does not edit a copied page. Pages under a product's folder in src/content/docs/, and
    public/<product>/, public/markdown/ and src/generated/, are written by pnpm sync; a fix
    to their text goes to the product's own repository.

Only src/social-card.ts, src/routeData.ts, src/pages/og/[...slug].ts and the test file change.

How it was tested

  • pnpm verify

pnpm verify green at the exact head d4740c4f38b451989c28729859a181e1235643b6: Biome and type checks, 108/108 tests, 67 pages built, internal links valid, social card and llms.txt checks pass.

New regression test: two products produce distinct quickstart card titles, the product leads the title, the fallback description names the product and differs per product, the no-product fallbacks keep the bare title and no description, and a non-quickstart title is never rewritten.

Both cards re-rendered and visually checked: the ID card holds "Gateweave ID quickstart" on one line with its fallback line beneath; the Guard card breaks after "Gateweave Guard" with no orphaned product fragment.

The built PNGs (final assets at this head):

Card Bytes sha256
dist/og/id/quickstart.png 43471 d21c3231b280d4ff90b43e21960c5d18c20a250299b6b61549881c83ffbe7534
dist/og/guard/quickstart.png 46486 be129b4d01078f7ff0fc9105da671ce268e5f20db6855790f5b95cc7cf72ced0

Built og:image:alt per product: Gateweave ID quickstart / Gateweave Guard quickstart / Gateweave Track quickstart, while og:title and the page heading stay "Quickstart".

Link to Devin session: https://app.devin.ai/sessions/3b1e78af34ad411493440e1a25ee171e
Open in Devin Desktop: https://app.devin.ai/desktop/session/3b1e78af34ad411493440e1a25ee171e?variant=devin
Requested by: @[REDACTED SECRET]

Every product's quickstart page is titled "Quickstart", so the five cards
drawn for them carried identical text and could come out as identical PNG
bytes, and their og:image:alt was the same generic word. The card title and
its alt text now go through one shared helper that names the product the page
was copied from; the pages' own headings, sidebar labels and URLs are
unchanged.

Co-Authored-By: Yigit Tanriverdi <[email protected]>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

Review of the first rendering showed the product name wrapping onto an
orphan line of its own. The card title now leads with the product, and a
quickstart page without its own description falls back to one concise
line naming the product instead of the site-wide default.

Co-Authored-By: Yigit Tanriverdi <[email protected]>
@xgame92

xgame92 commented Dec 4, 2026

Copy link
Copy Markdown
Member

APPROVE from independent Codex review of exact d4740c4f38b451989c28729859a181e1235643b6 against 2c24bf44c49739bf5acb0f00c611dddbe67f9f19.

The shared title helper supplies the image and alt text. The authored description stays first in the fallback order. Independent Windows pnpm verify passed all 108 tests, 67 pages, internal links, and the card and LLM checks. All five product Quickstart cards decode at 1200 by 630, have distinct SHA-256 digests and present the correct product in alt text. I inspected the ID and Guard PNGs. Both product names fit together and the headings are readable.

@xgame92
xgame92 merged commit 3c5a330 into main Dec 4, 2026
4 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 4, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant