blog-cover-poster
它能做什么
这个技能根据博客文章或笔记制作封面图和一系列幻灯片图片。适合想为文章配上视觉内容的作者和社交媒体创作者。
适用场景
- ✓你想为博客文章或社交文章制作封面图和内容幻灯片的时候。
- ✓你需要为社交媒体轮播准备一组竖版图片的时候。
- ✓你希望幻灯片能讲清楚素材主要要点的时候。
技能链接
https://github.com/digoal/blog/blob/master/skills/blog-cover-poster/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我把关于数据库备份的博客文章做成一张封面和五张竖版幻灯片图片。”
每周 5 个新技能,1 分钟读完。
工作原理
它为每个主要要点规划一张幻灯片,为每张写一个 HTML 页面,再用无界面浏览器把页面渲染成尺寸精确的 PNG 图片。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Blog Cover Poster
Overview
Generate a cover image (1.png) plus N coherent content slides (2.png, 3.png, …) from source material. Each image is an exact 1080×1920 PNG. The pipeline authors one HTML file per page using bundled CSS/templates, then renders them to PNG with headless Chrome — this gives precise control over Chinese/English typography, color semantics, and emphasis.
Workflow
- Read the source. Take the file/text the user provides. Extract the title/hook and the core points. Verify facts against the source only — do not invent stats, names, or claims that aren't in the material.
- Plan the deck (do this before writing any HTML):
- Pick a theme:
theme-dark(tech / AI / finance / dev topics) ortheme-light(knowledge / tutorial / lifestyle / business explainer). Default to the topic fit; honor an explicit user request. - Decide page count automatically from the number of distinct core points: cover + one slide per point. Typical total is 4–8 images. Merge thin points; split overloaded ones. One idea per content slide.
- Sketch a one-line outline:
1 cover → 2 <point> → 3 <point> …. If the user gave a fixed count, follow it.
- Pick a theme:
- Set up a scratch working dir — author intermediate HTML/CSS here, not in the source directory and not littering the project dir:
Author pages asWORK=$(mktemp -d) cp <SKILL_DIR>/assets/poster.css "$WORK"/$WORK/page-1.html(cover),$WORK/page-2.html, … using the templates as a starting point (see Authoring pages). The relative<link href="poster.css">resolves because the CSS sits beside them. - Render PNGs into the current project directory (
$PWD— where the user invoked the skill), never the source file's directory:
This writespython3 <SKILL_DIR>/scripts/render.py --in "$WORK" --out "$PWD"1.png,2.png, … (exact 1080×1920) into$PWD.page-1.htmlalways becomes the cover1.png. If the user names a different output dir, use that instead — but default to$PWD. - Inspect every PNG with the Read tool. Check the checklist below. Fix the HTML in
$WORKand re-render until clean. - Clean up the scratch dir (
rm -rf "$WORK"). Only theN.pngfiles remain in the project dir — that is the deliverable. The source directory is never touched.
Authoring pages
Start from the templates and edit — don't write markup from scratch:
assets/template-cover.html→page-1.htmlassets/template-content.html→page-2.html,page-3.html, …
Keep the same theme-* class on <body> across all pages.
Content-slide layouts
The content template ships three layout blocks — keep one per page, delete the rest:
- Points (
ul.points): 2–4 scannable items, best default for "reasons / steps / features". - Paragraph (
.body): 2–3 short sentences for a concept that needs prose. - Big stat (
.stat): one large number for a data point that deserves a full slide.
Emphasis rules (semantic coloring & sizing)
Emphasis must track meaning and importance, not decoration:
.hl/.hl2— filled color chip. At most ONE per page, on the single most important term..hl2(warm) for contrast/warning/payoff;.hl(cool) otherwise..ul— underline. Softer emphasis, for 1–2 secondary terms..accent— colored text, for the lead word of each list item..muted— de-emphasized text (subtitles, footers, labels).- Type hierarchy is pre-tuned in the CSS: cover title 132px, content heading 84px, body 50–52px. Bigger = more important. If text overflows the 1920px height, cut words or split into another slide — do not shrink below the template sizes.
Copywriting for posters
- Cover title: a punchy hook, ≤ ~14 CJK chars per line, ≤ 2 lines.
- Content headings: short, one idea. Content body: fragments over full paragraphs — these are read in seconds.
- Number the deck in the content
.index(e.g.01 / 05) so the series reads as coherent.
Verification checklist (per image)
- Size is exactly 1080×1920 (render.py enforces & prints this).
- No text is clipped at edges or overflows the bottom.
- Exactly one filled highlight chip per page, on the right term.
- Emphasis reflects the actual key point, not random words.
- Theme is consistent across all pages; contrast is readable.
- Content slides read as a coherent, ordered series (indices match count).
- Every claim traces t
常见问题
图片尺寸是多少?
每张图都是精确的 1080 × 1920 像素 PNG。
会生成多少张图片?
数量取决于要点多少,通常一组有四到八张。
它会添加事实内容吗?
不会,技能要求只对照原始素材核对事实。
详情
作者的原始描述
Turn a blog post, article, notes, or any source material into a set of vertical poster images — one cover plus several coherent content slides that explain the core points. Renders HTML/CSS to exact-size PNGs via headless Chrome. Use whenever the user wants cover art, 讲解图/配图, carousel slides, 封面图, poster series, or "content images" from an article/文章/素材/文件, especially for blog, 公众号, 小红书, or social posts. Default output is 1080×1920 PNG named 1.png (cover), 2.png, 3.png … written to the current working directory (the project the user is in) — never the source file's directory.
repo: digoal/blog
热度
- GitHub 星标
- 8.6k
- 排名
- #12352
- 许可证
- GPL-2.0
- 更新时间
- 2026/11/1
评论
- …
同一仓库的更多技能
article-to-podcast-script
8.6k帮你的智能体把 Markdown 文章改写成播客脚本,支持一到四位说话人,并保存为文本文件,默认使用中文。
axiom-explainer
8.6k帮你的智能体写一篇清晰的中文文章,讲解一个观点、定律或理论,并附上例子、适用范围和简单示意图。
buffett
8.6k帮你的智能体用沃伦·巴菲特的思路分析公司和股票,参考他关于护城河、管理层和安全边际的观点。
daily-finance
8.6k帮你的智能体根据可靠的最新来源,撰写每日财经新闻简报,附上核对过的数字和链接,供市场摘要使用。