From social-media-tools
Creates platform-aware social copy and a dark-mode card for a blog post. Fetches OG tags, populates blog-card.html, and screenshots via Playwright. Use when asked to share a blog post on social media.
How this skill is triggered — by the user, by Claude, or both
Slash command
/social-media-tools:share-blogThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Draft platform-aware social media copy and generate a styled dark-mode card image
Draft platform-aware social media copy and generate a styled dark-mode card image for a blog post URL or local markdown file.
| Phase | Action |
|---|---|
| 0 — Locate | Locate templates/ and derive PLUGIN_DIR |
| 1 — Collect Input | Detect URL vs local file; resolve relative paths; ask platform + tone |
| 1c — Reuse check | Scan docs/media/social/ for existing blog posts; offer reuse |
| 2 — Fetch Metadata | WebFetch OG tags (URL) or Read front matter (local); HTML-escape all values |
| 3 — Draft Copy | Write platform-aware copy |
| 4 — Populate Template | Fill blog-card.html; inject conditional elements + {{COPY_PANELS}} |
| 4b — Save | Persistent save to docs/media/social/ |
| 5 — Screenshot | Serve HTML locally; Playwright screenshot |
| 6 — Deliver | Present copy + attach PNG + show saved path |
ExitPlanMode is a deferred tool. Only call it if currently in plan mode — skip this step entirely when not in plan mode. When calling: use ToolSearch with select:ExitPlanMode first, then call ExitPlanMode silently.
Run silently:
[ -n "${CLAUDE_PLUGIN_ROOT}" ] && [ -d "${CLAUDE_PLUGIN_ROOT}/templates" ] && \
echo "${CLAUDE_PLUGIN_ROOT}/templates"
find ~/.claude/plugins -path "*/social-media-tools/templates" -type d 2>/dev/null | head -1
find ~/.claude -path "*/social-media-tools/templates" -type d 2>/dev/null | head -1
Use the first non-empty result as TEMPLATES_DIR. Derive:
PLUGIN_DIR=$(dirname "$TEMPLATES_DIR")
If not found: output "Templates not found. Install the plugin or load it with --plugin-dir." and STOP.
Detect the source type:
http:// or https://.md, .mdx, or .markdownIf the user provides a relative path, resolve it:
realpath "$USER_PATH" 2>/dev/null || echo "$PWD/$USER_PATH"
Use AskUserQuestion to collect whatever is missing. Batch all questions in one call:
| Input | Options | Notes |
|---|---|---|
SOURCE | URL or file path | Required |
PLATFORM | See Platform Options in $PLUGIN_DIR/references/platforms.md | Required |
TONE | Professional, Casual, Punchy | Default: Professional (LinkedIn), Punchy (Twitter/Bluesky) |
HOOK_ANGLE | Free text | Optional |
FILE_PREFIX=blog
Read $PLUGIN_DIR/references/reuse-check.md and follow its procedure.
Use ToolSearch with select:WebFetch first (silent, no user output), then call WebFetch.
Both steps happen silently.
Call WebFetch on SOURCE. Extract:
| Variable | Source |
|---|---|
TITLE | <meta property="og:title"> → <title> fallback |
EXCERPT | <meta property="og:description"> → first <p>, truncated to 280 chars |
AUTHOR | <meta property="article:author"> → "" if not found |
DATE | <meta property="article:published_time"> → MMM D, YYYY → "" if not found |
SOURCE_DOMAIN | Hostname, strip www. |
TAGS | <meta property="article:tag">, up to 5 |
READ_TIME | "" — do not compute for URL sources |
Call Read on the resolved absolute path. Extract:
| Variable | Source |
|---|---|
TITLE | YAML front matter title: → first # H1 |
EXCERPT | YAML description: → first non-heading paragraph, truncated to 280 chars |
AUTHOR | YAML author: → "" |
DATE | YAML date: → MMM D, YYYY → "" |
SOURCE_DOMAIN | YAML site: or url: hostname → "local file" |
TAGS | YAML tags: array, up to 5 |
READ_TIME | Word count of body (excl. front matter + headings) / 200 wpm, rounded |
Before any template substitution, apply to every text value:
& → & (must be first)< → <> → >Read $PLUGIN_DIR/references/platforms.md for character limits, universal copy rules,
and Draft Copy — Standard Procedure.
For copy format and filled examples per platform, read the skill-local references/platforms.md
(adjacent to this SKILL.md).
{{READ_TIME_BADGE}}
READ_TIME is non-empty: <span class="read-time">N min read</span>""{{TAGS_FOOTER}}
TAGS has at least one value:
<div class="card-footer"><span class="tag">tag1</span><span class="tag">tag2</span></div>
(each tag value HTML-escaped)""Read $PLUGIN_DIR/references/copy-panels.md for markup and escaping rules.
Replace all {{VARIABLE}} placeholders. Write to ~/.claude/tmp/share-blog-card.html:
mkdir -p ~/.claude/tmp
TEMP_HTML=share-blog-card.html
FILE_PREFIX=blog
SLUG_INPUT=$TITLE
Read $PLUGIN_DIR/references/saving-and-delivery.md — Persistent Save section.
Read $PLUGIN_DIR/references/rendering-pipeline.md and follow the full pipeline.
Read $PLUGIN_DIR/references/saving-and-delivery.md — Deliver section.
npx claudepluginhub shawn-sandy/agentics-kit --plugin social-media-toolsProvides UI/UX resources: 50+ styles, color palettes, font pairings, guidelines, charts for web/mobile across React, Next.js, Vue, Svelte, Tailwind, React Native, Flutter. Aids planning, building, reviewing interfaces.
Fetches up-to-date documentation from Context7 for libraries and frameworks like React, Next.js, Prisma. Use for setup questions, API references, and code examples.