Teaching HTML Story Deck
Create a polished, self-contained teaching webpage that explains a topic through a coherent story. Do not produce a generic dashboard or a collection of unrelated cards.
The default deliverable is one .html file containing HTML, CSS, JavaScript, inline SVG, presenter notes, keyboard controls, responsive behavior, and reduced-motion support.
Core promise
Transform raw content into:
Problem
→ Why it matters
→ Use cases and boundaries
→ Mental model
→ Core method
→ Data flow
→ Architecture / mind map
→ Practical example
→ Decision / result
→ Final reveal / CTA
The final product, Skill, repository, framework, or CTA should usually appear only after the audience understands the problem and method.
Non-negotiable principles
- Narrative before decoration. Decide what the audience must understand, and in what order, before choosing visuals.
- Show relationships. Turn sequence, dependency, authority, scope, uncertainty, and transformation into visuals rather than repeated bullet lists.
- Generate visuals from the content. Do not reuse the same diagram blindly.
- Motion explains state. Animation should reveal hierarchy, direction, progress, uncertainty, or state change.
- One file, no build step. Inline CSS, JavaScript, and SVG. Avoid CDNs, external fonts, frameworks, and remote images unless requested.
- High finish, restrained design. Prefer near-black surfaces, large typography, fine borders, sparse luminous accents, subtle grids, and quiet depth.
- No invented evidence. Never fabricate metrics, benchmarks, quotes, user counts, or research results.
- Label conceptual models. A proposed mental model is not measured data.
- The deck must work without animation. Respect
prefers-reduced-motion.
- Do not imitate brands exactly. Borrow broad qualities such as precision and restraint; never copy logos, proprietary illustrations, or exact branded layouts.
Default user preferences
Read references/user-preferences.md before designing unless the user explicitly asks for a different style.
Workflow
1. Understand the teaching job
Extract:
- topic and source material;
- target audience and starting knowledge;
- final understanding or action;
- facts that must remain exact;
- concepts that may be shown as models;
- delivery context: desktop, Bilibili, Douyin, blog, course, or product demo;
- desired final reveal;
- existing HTML that should be preserved or upgraded.
Do not ask a question when the context is already sufficient. Make a best-effort assumption and note it in presenter notes when necessary.
2. Build the narrative spine
Create a page blueprint before coding.
Default sequence when appropriate:
- Hook or contradiction;
- Problem definition;
- Use cases and trigger boundary;
- Principle or mental model;
- Core method;
- Content-specific data flow;
- Architecture or mind map;
- Practical before/after example;
- Progress, evidence, or operating decision;
- Final reveal and CTA.
Shorten or reorder the sequence to fit the subject. Never force ten pages.
Read references/story-and-visual-framework.md.
3. Map concepts to visuals
For every major idea, determine the relationship type:
- ordered transformation → flow or pipeline;
- simultaneous components → architecture graph;
- one core with related capabilities → radial mind map;
- trigger conditions → 2×2 matrix;
- sequence over time → timeline;
- uncertainty becoming execution → Hill Chart or confidence curve;
- input/output change → before/after;
- responsibility and authority → role-permission graph;
- approval criteria → evidence gate;
- repeating improvement → feedback loop;
- inclusion/exclusion → scope boundary map;
- message exchange → sequence diagram.
Use one primary visual per page. Read references/story-and-visual-framework.md.
4. Generate content-specific SVG
Read references/svg-and-motion-system.md.
Requirements:
- inline SVG only by default;
- readable labels and a clear reading direction;
- minimal line crossings;
- semantic groups;
- arrow markers for directional paths;
- animation only on meaningful paths or states;
role="img" and aria-label;
- labels large enough at 1280×720;
- nearby text explanation for complex diagrams.
Do not create pseudo-technical complexity. Remove any node that does not affect the explanation.
5. Define the motion system
Default layers:
- ambient: subtle grid, grain, pointer glow;
- transition: page enter/exit;
- reveal: staged title, thesis, visual, details;
- semantic: path flow, pulse, progress, state change;
- interaction: hover lift, overview, presenter notes, fullscreen.
Use CSS first. JavaScript should mainly control navigation, pointer position, toggles, and simple state changes.
6. Implement the single-file deck
Minimum controls:
- previous / next;
- left and right arrows;
- space for next;
- Home / End;
F fullscreen;
O overview for multi-page decks;
N presenter notes when notes exist.
Use CSS variables for the design system. Default to one primary accent and at most one supporting semantic accent.
7. Add presenter support
Each page should contain a hidden note with:
- the purpose of the page;
- the transition from the previous page;
- the main sentence to say;
- what not to over-explain.
Presenter notes are hidden by default and toggled with N.
8. Validate
Run:
python scripts/validate_deck.py output.html
Check:
- problem appears before solution;
- each page has one teaching job;
- SVG labels are readable;
- keyboard navigation works;
- fullscreen and overview work where included;
- reduced-motion is supported;
- no external dependencies unless requested;
- no fake data;
- final reveal follows naturally;
- the output is genuinely one file.
Read references/quality-gates.md.
Upgrade mode
When improving an existing HTML:
- preserve useful content and structure;
- diagnose narrative, hierarchy, diagram, motion, and accessibility problems;
- improve hierarchy before adding effects;
- replace generic cards with content-specific visuals where helpful;
- keep the file standalone;
- create a new output file unless destructive overwrite is requested.
Default style
Use precision dark editorial:
- near-black background;
- restrained monochrome panels;
- fine borders;
- large editorial typography;
- subtle grid and grain;
- sparse fluorescent yellow-green accent;
- quiet spatial depth;
- advanced but restrained motion.
This is inspired by qualities associated with modern developer products such as clarity, precision, and continuity—not exact brand imitation.
Output contract
Deliver:
- the final standalone HTML;
- a concise explanation of the narrative and controls;
- assumptions or unverified conceptual models;
- optionally a story blueprint and visual map when ongoing editing is useful.
Delivery contract (default handoff)
The default delivery path is automatic anonymous-drop hosting — do not ask the user "要不要部署" unless they have already said they want local-only output.
- After the deck passes
python3 scripts/validate_deck.py <deck>.html, automatically invoke the html-stable-publish skill to upload the file and return the public link as part of the deliverable.
- If the user explicitly says "不要部署" / "本地就行" / "给我文件就行" — skip the handoff and deliver the file path only.
- If the user explicitly wants postplan hosting instead of (or in addition to) the anonymous drop — run
npx postplan upload ./<deck>.html. The postplan platform picks the URL; do not hard-code a publish URL in this skill.
- Never publish a deck that fails validation. The quality bar in
references/quality-gates.md is non-negotiable for any handoff.
Failure modes
Avoid:
- opening with the product name when the problem should be taught first;
- generic SaaS dashboard layouts;
- many accent colors;
- decorative 3D objects unrelated to the subject;
- paragraphs squeezed into tiny cards;
- unreadable SVG labels;
- fake quantitative charts;
- animation used to hide weak hierarchy;
- dense architecture before the problem is established;
- the same bullet-list page repeated throughout;
- external dependencies that break offline use;
- an early product reveal that weakens the story.
1---2name: teaching-html-story-deck3description: Create or upgrade standalone interactive teaching HTML story decks with problem-first narrative, content-specific inline SVG diagrams, presenter notes, keyboard navigation, responsive layout, and accessibility checks. Use for teaching HTML, 讲解页, 教学网页, 教学演示, story deck, explainer webpage, course page, 架构可视化, 产品/系统设计 walkthrough, 升级既有 HTML 演示页, 出一份 HTML 报告, B 站/抖音讲解页. Do not use for: copying a single short article to HTML, marketing landing pages without a teaching arc, dashboards, or any task whose output is not a self-contained HTML file. Default delivery contract: after producing the deck, automatically hand it to html-stable-publish for anonymous-drop hosting and return the public link as part of the deliverable; only fall back to local-file-only / postplan when the user explicitly asks for it.4license: MIT5---67# Teaching HTML Story Deck89Create a polished, self-contained teaching webpage that explains a topic through a coherent story. Do not produce a generic dashboard or a collection of unrelated cards.1011The default deliverable is one `.html` file containing HTML, CSS, JavaScript, inline SVG, presenter notes, keyboard controls, responsive behavior, and reduced-motion support.1213## Core promise1415Transform raw content into:1617```text18Problem19→ Why it matters20→ Use cases and boundaries21→ Mental model22→ Core method23→ Data flow24→ Architecture / mind map25→ Practical example26→ Decision / result27→ Final reveal / CTA28```2930The final product, Skill, repository, framework, or CTA should usually appear only after the audience understands the problem and method.3132## Non-negotiable principles33341. **Narrative before decoration.** Decide what the audience must understand, and in what order, before choosing visuals.352. **Show relationships.** Turn sequence, dependency, authority, scope, uncertainty, and transformation into visuals rather than repeated bullet lists.363. **Generate visuals from the content.** Do not reuse the same diagram blindly.374. **Motion explains state.** Animation should reveal hierarchy, direction, progress, uncertainty, or state change.385. **One file, no build step.** Inline CSS, JavaScript, and SVG. Avoid CDNs, external fonts, frameworks, and remote images unless requested.396. **High finish, restrained design.** Prefer near-black surfaces, large typography, fine borders, sparse luminous accents, subtle grids, and quiet depth.407. **No invented evidence.** Never fabricate metrics, benchmarks, quotes, user counts, or research results.418. **Label conceptual models.** A proposed mental model is not measured data.429. **The deck must work without animation.** Respect `prefers-reduced-motion`.4310. **Do not imitate brands exactly.** Borrow broad qualities such as precision and restraint; never copy logos, proprietary illustrations, or exact branded layouts.4445## Default user preferences4647Read `references/user-preferences.md` before designing unless the user explicitly asks for a different style.4849## Workflow5051### 1. Understand the teaching job5253Extract:5455- topic and source material;56- target audience and starting knowledge;57- final understanding or action;58- facts that must remain exact;59- concepts that may be shown as models;60- delivery context: desktop, Bilibili, Douyin, blog, course, or product demo;61- desired final reveal;62- existing HTML that should be preserved or upgraded.6364Do not ask a question when the context is already sufficient. Make a best-effort assumption and note it in presenter notes when necessary.6566### 2. Build the narrative spine6768Create a page blueprint before coding.6970Default sequence when appropriate:71721. Hook or contradiction;732. Problem definition;743. Use cases and trigger boundary;754. Principle or mental model;765. Core method;776. Content-specific data flow;787. Architecture or mind map;798. Practical before/after example;809. Progress, evidence, or operating decision;8110. Final reveal and CTA.8283Shorten or reorder the sequence to fit the subject. Never force ten pages.8485Read `references/story-and-visual-framework.md`.8687### 3. Map concepts to visuals8889For every major idea, determine the relationship type:9091- ordered transformation → flow or pipeline;92- simultaneous components → architecture graph;93- one core with related capabilities → radial mind map;94- trigger conditions → 2×2 matrix;95- sequence over time → timeline;96- uncertainty becoming execution → Hill Chart or confidence curve;97- input/output change → before/after;98- responsibility and authority → role-permission graph;99- approval criteria → evidence gate;100- repeating improvement → feedback loop;101- inclusion/exclusion → scope boundary map;102- message exchange → sequence diagram.103104Use one primary visual per page. Read `references/story-and-visual-framework.md`.105106### 4. Generate content-specific SVG107108Read `references/svg-and-motion-system.md`.109110Requirements:111112- inline SVG only by default;113- readable labels and a clear reading direction;114- minimal line crossings;115- semantic groups;116- arrow markers for directional paths;117- animation only on meaningful paths or states;118- `role="img"` and `aria-label`;119- labels large enough at 1280×720;120- nearby text explanation for complex diagrams.121122Do not create pseudo-technical complexity. Remove any node that does not affect the explanation.123124### 5. Define the motion system125126Default layers:127128- ambient: subtle grid, grain, pointer glow;129- transition: page enter/exit;130- reveal: staged title, thesis, visual, details;131- semantic: path flow, pulse, progress, state change;132- interaction: hover lift, overview, presenter notes, fullscreen.133134Use CSS first. JavaScript should mainly control navigation, pointer position, toggles, and simple state changes.135136### 6. Implement the single-file deck137138Minimum controls:139140- previous / next;141- left and right arrows;142- space for next;143- Home / End;144- `F` fullscreen;145- `O` overview for multi-page decks;146- `N` presenter notes when notes exist.147148Use CSS variables for the design system. Default to one primary accent and at most one supporting semantic accent.149150### 7. Add presenter support151152Each page should contain a hidden note with:153154- the purpose of the page;155- the transition from the previous page;156- the main sentence to say;157- what not to over-explain.158159Presenter notes are hidden by default and toggled with `N`.160161### 8. Validate162163Run:164165```bash166python scripts/validate_deck.py output.html167```168169Check:170171- problem appears before solution;172- each page has one teaching job;173- SVG labels are readable;174- keyboard navigation works;175- fullscreen and overview work where included;176- reduced-motion is supported;177- no external dependencies unless requested;178- no fake data;179- final reveal follows naturally;180- the output is genuinely one file.181182Read `references/quality-gates.md`.183184## Upgrade mode185186When improving an existing HTML:1871881. preserve useful content and structure;1892. diagnose narrative, hierarchy, diagram, motion, and accessibility problems;1903. improve hierarchy before adding effects;1914. replace generic cards with content-specific visuals where helpful;1925. keep the file standalone;1936. create a new output file unless destructive overwrite is requested.194195## Default style196197Use **precision dark editorial**:198199- near-black background;200- restrained monochrome panels;201- fine borders;202- large editorial typography;203- subtle grid and grain;204- sparse fluorescent yellow-green accent;205- quiet spatial depth;206- advanced but restrained motion.207208This is inspired by qualities associated with modern developer products such as clarity, precision, and continuity—not exact brand imitation.209210## Output contract211212Deliver:2132141. the final standalone HTML;2152. a concise explanation of the narrative and controls;2163. assumptions or unverified conceptual models;2174. optionally a story blueprint and visual map when ongoing editing is useful.218219## Delivery contract (default handoff)220221The default delivery path is **automatic anonymous-drop hosting** — do not ask the user "要不要部署" unless they have already said they want local-only output.2222231. After the deck passes `python3 scripts/validate_deck.py <deck>.html`, automatically invoke the `html-stable-publish` skill to upload the file and return the public link as part of the deliverable.2242. If the user explicitly says "不要部署" / "本地就行" / "给我文件就行" — skip the handoff and deliver the file path only.2253. If the user explicitly wants postplan hosting instead of (or in addition to) the anonymous drop — run `npx postplan upload ./<deck>.html`. The postplan platform picks the URL; do not hard-code a publish URL in this skill.2264. Never publish a deck that fails validation. The quality bar in `references/quality-gates.md` is non-negotiable for any handoff.227228## Failure modes229230Avoid:231232- opening with the product name when the problem should be taught first;233- generic SaaS dashboard layouts;234- many accent colors;235- decorative 3D objects unrelated to the subject;236- paragraphs squeezed into tiny cards;237- unreadable SVG labels;238- fake quantitative charts;239- animation used to hide weak hierarchy;240- dense architecture before the problem is established;241- the same bullet-list page repeated throughout;242- external dependencies that break offline use;243- an early product reveal that weakens the story.