Skip to content

Add Open Graph + Twitter Card social preview image - #314

Open
astra-intelligence wants to merge 1 commit into
haoel:masterfrom
astra-intelligence:add-og-social-preview
Open

astra-intelligence wants to merge 1 commit into
haoel:masterfrom
astra-intelligence:add-og-social-preview

Conversation

@astra-intelligence

Copy link
Copy Markdown

This page (科学上网 / 左耳朵's circumvention guide, 13k★) currently has no og:image and no twitter:image — every share of the site renders a blank preview card. The {% seo %} tag emits og:title/description/url/site_name/type but no image.

This PR adds a proper 1200×630 social preview card via the theme's documented _includes/head-custom.html hook:

  • _includes/head-custom.html — emits og:image (+ type/width/height) and twitter:card=summary_large_image + twitter:image, absolute prod URLs (https://haoel.github.io/og-image.png).
  • og-image.png — 1200×630 card matching the Cayman theme: light ground, #157878 teal accent, CJK title 科学上网 + author 左耳朵 · coolshell.cn, section pills, domain chip.
  • tools/make-og-image.py — Pillow-only generator, byte-reproducible from a clean dir (CJK via WenQuanYi Zen Hei).

3 files, +99/-0. No layout or content changes.

Add a 1200x630 og:image via the jekyll-theme-cayman head-custom.html hook
plus twitter:card=summary_large_image. The {% seo %} tag emits
og:title/description/url/site_name/type but no image, so every share of
this page renders a blank preview card.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant