Skip to content

Per-repo social cards for docs-site repos#23

Merged
lesnik512 merged 7 commits into
mainfrom
brand-social-cards
Jun 30, 2026
Merged

Per-repo social cards for docs-site repos#23
lesnik512 merged 7 commits into
mainfrom
brand-social-cards

Conversation

@lesnik512

Copy link
Copy Markdown
Member

What

Generates a social card (1280×640 og:image) for each org repo that has a
live docs site — built on the per-project marks. Two-panel composition: a green
panel with the repo's mark (cream + gold-dark) beside a cream panel holding the
repo name, its one-line tagline, and its docs URL. Output:
brand/projects/<repo>/social-card.svg + social-card.png, for the 7
docs-site repos only
.

The seven were determined by probing https://<repo>.modern-python.org/ (HTTP
200): modern-di, that-depends, lite-bootstrap, httpware,
faststream-redis-timers, faststream-outbox, semvertag. The other ten don't
resolve and get no card.

Design

  • Spec: planning/changes/2026-06-30.01-per-repo-social-cards/design.md
  • Plan: same bundle's plan.md

How it's built

  • brand/build/tokens.py — new GREEN_MUTED token (tagline colour).
  • brand/build/projects.py:
    • _measure / fit_text (auto-shrink a name to the column width) / wrap_text
      (greedy word-wrap) text helpers.
    • DOCS_REPOS: dict[str, str] — the 7 docs repos → taglines, verbatim from
      profile/README.md
      (the canonical one-liner, kept in sync with GitHub
      description + pyproject per the org's "three surfaces" rule).
    • project_social_card(repo, *, tagline) — composes the two-panel card.
    • render_projects gains a pass writing social-card.svg|png for DOCS_REPOS.
  • Regenerate: uv run python -m brand.build.render.

Cards use only palette tokens (a test enforces it). 88 tests pass;
just check-planning OK. Architecture promoted in architecture/brand-marks.md.

Notes

  • Wiring each card into its docs site's og:image meta is per-repo follow-up.
  • DOCS_REPOS is a hand-maintained mirror of which repos have a docs site;
    re-probe and edit the table if that set changes.

🤖 Generated with Claude Code

lesnik512 and others added 7 commits June 30, 2026 13:37
Two-panel green/cream 1280x640 og:image for the 7 docs-site repos, built on the
project marks: green panel holds the repo mark, cream panel holds name, canonical
tagline, and docs URL. Generated into brand/projects/<repo>/social-card.svg|png.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Five TDD tasks: GREEN_MUTED token, fit/wrap text helpers, DOCS_REPOS table +
project_social_card, the docs-only render pass, and docs/architecture.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@lesnik512 lesnik512 merged commit b41d4d9 into main Jun 30, 2026
1 check passed
@lesnik512 lesnik512 deleted the brand-social-cards branch June 30, 2026 12:35
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