From anzchy-skills
Turn ONE input — a project/source folder, a single Markdown file, a local repo, or a GitHub repo URL — into ONE self-contained interactive HTML file that explains the input end-to-end (structure, architecture, and the data-and-control flow from entry point to output). Produces a single .html with all CSS/JS inlined, styled to the Claude/Anthropic design language, that opens by double-click and is shareable as one file. Use whenever someone wants to visualize, explain, walk through, document, or "make an interactive page" for a codebase, repo, folder, or Markdown doc. Invoke manually as "/jack-html-preview <path-or-url>".
How this skill is triggered — by the user, by Claude, or both
Slash command
/anzchy-skills:jack-html-previewThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Reading a codebase or a long doc top-to-bottom is slow, and a static README can't show how the pieces connect. This skill produces ONE self-contained interactive HTML file that explains an input end-to-end — its structure, its architecture, and the underlying mechanism (how data and control flow from the entry point to the output). The file inlines all CSS and JS, fetches nothing at runtime, an...
Reading a codebase or a long doc top-to-bottom is slow, and a static README can't show how the pieces connect. This skill produces ONE self-contained interactive HTML file that explains an input end-to-end — its structure, its architecture, and the underlying mechanism (how data and control flow from the entry point to the output). The file inlines all CSS and JS, fetches nothing at runtime, and opens by double-click, so it's shareable as a single attachment.
The input to explain: $ARGUMENTS
A single .html file that:
<link>/<script src>, no web fonts or data fetched over the network. It must open offline by double-click and survive being emailed as one file. Fonts fall back to the system stack (the design language is preserved via the CSS variables, not by loading Anthropic's fonts).reference/claude-design-spec.md — paper background (#FAF9F5), charcoal text, serif display headings, the leaf-shaped (asymmetric) border radius, restrained orange accent, generous line-height. Read that file before rendering; don't invent a different look.Classify $ARGUMENTS into exactly one of four types and prepare its source:
| Input | How to detect | How to prepare |
|---|---|---|
| GitHub repo URL | starts with https://github.com/ or [email protected]: | shallow-clone into a temp dir: git clone --depth 1 <url> "$(mktemp -d)/repo" (or gh repo clone). Before cloning, stop and ask if the repo is likely over ~200 MB. |
| Local repo | a directory containing .git/ | use in place, read-only. Don't modify the working tree. |
| Project/source folder | a directory without .git/ | use in place, read-only. |
| Single Markdown file | a path ending in .md/.markdown | read the file directly. |
If the input is ambiguous (e.g. a bare name), ask one clarifying question rather than guessing.
The HTML is only as good as this mapping — spend the effort here, not on chrome.
For code (folder / local repo / GitHub repo):
main(), a bin/CLI entry, a server bootstrap, index.*, a framework root. This anchors the flow diagram's "ENTRY".node_modules, .git, build artifacts, lockfiles, vendored deps).For a single Markdown file:
Use Explore/Glob/Grep/Read for big inputs rather than reading every file — you need an accurate map, not a full transcript. For a large repo, sample entry points and representative modules.
reference/claude-design-spec.md for the exact colors, type scale, spacing, and the leaf-radius motif.reference/html-template.html — it already encodes the design language and the three interactive features (collapsible tree, click-to-explain panel, CSS flow diagram). Copy it and fill it in; it's a starting point, not a fixed form — add or drop tree nodes, flow steps, and panels to match the real input. A 3-file CLI and a 200-file monorepo must not look identical.NODE_DATA explanations keyed by node id.<link>, no src=/href= pointing at a network resource, and no runtime fetch — the file must work with the network off../<name>-preview.html (derive <name> from the repo/folder/file). Honor an explicit path if the user gave one.open <path>) and wait for the user to say yes.git/gh, already present) or any build step.reference/claude-design-spec.md — the Claude/Anthropic design system (colors, type, spacing, leaf radius, components). Read in step 3 before rendering.reference/html-template.html — the self-contained HTML scaffold with the three interactive features wired up. Copy and fill it in.Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub anzchy/skills --plugin anzchy-skills