htmlslides
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "htmlslides" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-3977a7edf0ba15baf1a8eecb2532251f8c4fc5edcdccd3d4734549e9874363d6. Verify the upstream source and version against https://skillhub.cn/skills/user_c830ad09/htmlslides before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
skillhub.cn
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
Generate stunning, animation-rich, self-contained HTML presentations from scratch or by converting PowerPoint files. Use when the user wants to create slides, build a presentation or pitch deck, convert PPT/PPTX to web format, or enhance an existing HTML deck; helps users discover their aesthetic through visual previews.
Introduction source: third_party · user_c830ad09 · 1.0.0 Reference
SkillPi interpretation
- Tasks
- Generate stunning, animation-rich, self-contained HTML presentations from scratch or by converting PowerPoint files. This skill should be used when the user wants to create slides, build a presentation, make a pitch deck, convert a PPT/PPTX to web format, or enhance an existing HTML deck. Helps users discover their aesthetic through visual previews rather than abstract choices.
- Testing
- Not tested
Browse files
Frontmatter
name: html-slides
description: Generate stunning, animation-rich, self-contained HTML presentations from scratch or by converting PowerPoint files. This skill should be used when the user wants to create slides, build a presentation, make a pitch deck, convert a PPT/PPTX to web format, or enhance an existing HTML deck. Helps users discover their aesthetic through visual previews rather than abstract choices.
agent_created: trueHTML Slides — Self-Contained Presentation Generator
Create zero-dependency, animation-rich HTML presentations that run entirely in the browser. Single HTML file, all CSS/JS inline. No npm, no build tools. Open in any browser and present.
Core Principles
- Zero Dependencies — Single HTML files with inline CSS/JS. No npm, no build tools, no frameworks. The file works 10 years later.
- Show, Don't Tell — Generate visual previews for style selection. People discover what they want by seeing it, not by describing it.
- Distinctive Design — No generic "AI slop." Every presentation must feel custom-crafted. Avoid purple-gradient-on-white clichés, Inter/Roboto/Arial as display fonts, cookie-cutter card grids.
- Progressive Disclosure — This SKILL.md is a workflow map. Read lightweight indexes first; load detailed references only at the appropriate phase.
- Fixed 16:9 Stage (NON-NEGOTIABLE) — Every deck uses a 1920×1080 slide canvas scaled as a whole to the viewport. Slides stay 16:9 on every screen including phones. Do NOT reflow slide content.
Design Aesthetics Guidance
When generating presentations, focus on:
- Typography: Choose distinctive, beautiful fonts. Avoid Inter, Roboto, Arial, system fonts. Use Google Fonts or Fontshare. Pair display + body fonts thoughtfully.
- Color & Theme: Commit to a cohesive aesthetic via CSS variables. Dominant colors with sharp accents. Draw from cultural aesthetics and IDE themes for inspiration.
- Motion: Use animations for high-impact moments. Staggered reveals (animation-delay) create more delight than scattered micro-interactions. Reference animation-patterns.md.
- Backgrounds: Layer CSS gradients, geometric patterns, or contextual effects. Never default to solid colors alone.
Avoid these generic patterns:
- Overused fonts (Inter, Roboto, Arial, Space Grotesk on every deck)
- Clichéd color schemes (purple gradients on white)
- Predictable layouts and identical card grids
- Gratuitous glassmorphism, drop shadows without purpose
Workflow
Phase 0: Detect Mode
Determine what the user wants:
| Mode | Trigger | Next Phase |
|---|---|---|
| A: New Presentation | "做一份演示文稿", "create slides", "pitch deck" | Phase 1 |
| B: PPT Conversion | User provides a .pptx/.ppt file | Phase 4 |
| C: Enhancement | User wants to modify an existing HTML deck | Modify directly, following Fixed Stage Rules |
| D: Style Transfer | "change to X style", "switch theme", "换成X风格" | Style Transfer Protocol |
Phase 1: Content Discovery
Ask ALL questions together using AskUserQuestion tool. Do not ask one at a time.
Question 1 — Purpose: What is this presentation for? Options: Pitch deck / Teaching-Tutorial / Conference talk / Internal presentation
Question 2 — Length: Approximately how many slides? Options: Short 5-10 / Medium 10-20 / Long 20+
Question 3 — Content: Do you have content ready? Options: All content ready / Rough notes / Topic only
Question 4 — Density: How dense should the deck feel?
- "Low density / speaker-led" — Big ideas, fewer words, more visual breathing room. One idea per slide, 1-3 bullets max.
- "High density / reading-first" — More self-contained detail for async reading. 4-8 bullets or 4-6 cards per slide.
If user has content, ask them to share it. Do NOT ask about inline editing at this stage — include it by default after draft generation.
Image handling (if user provides images):
- Scan all image files (.png, .jpg, .svg, .webp)
- Inspect each image using Read tool (multimodal)
- Evaluate: what it shows, usable or not, what concept it represents, dominant colors
- Co-design the outline — images inform slide structure alongside text
- Confirm the outline with user
Phase 2: Style Discovery
This is the "show, don't tell" phase. Most people cannot articulate design preferences in words.
Generate 3 distinct single-slide HTML previews showing typography, colors, animation, and overall aesthetic. Each preview must look like a real first slide from the user's deck, not a diagnostic card.
Preview mix rules:
- 1 safe preset from style-presets.md
- 1 adventurous/wildcard option (another preset or custom design)
- 1 contextual option that best matches the user's purpose and mood
Preview authenticity rules (NON-NEGOTIABLE):
- Never render internal workflow text on a slide: no "preview", "Option A/B/C", "generated from", preset names, or file paths
- Never render user requirement notes as slide content (e.g. "bold and provocative")
- Use real deck chrome only: deck title, section title, date, author, page number, or genuine content phrases
Save previews to a temp directory (style-a.html, style-b.html, style-c.html). Open each preview via present_files for the user.
Ask user to pick: Style A / Style B / Style C / Mix elements.
Phase 3: Generate Presentation
Generate the full presentation using content from Phase 1 and style from Phase 2.
Before generating, read these reference files:
| File | Purpose | When |
|---|---|---|
| references/viewport-base.css | Mandatory fixed-stage CSS — include FULL contents in every presentation | Phase 3 (before generation) |
| references/html-template.md | HTML structure, JS features, code quality standards | Phase 3 (before generation) |
| references/animation-patterns.md | Animation snippets and effect-to-feeling guide | Phase 3 (during generation) |
| references/style-presets.md | Full preset definitions for the chosen style | Phase 2-3 (after user picks) |
Key generation requirements:
- Single self-contained HTML file, all CSS/JS inline
- Include FULL contents of viewport-base.css in the
<style>block - Use fonts from Fontshare or Google Fonts — never system fonts
- Add detailed comments explaining each section:
/* === SECTION NAME === */ - Include SlidePresentation class with keyboard/touch/wheel navigation
- Include stage scaling JS (1920×1080 → viewport fit)
- Include inline editing feature by default (hover hotzone + E key toggle)
- Include Speaker View — press
Skey to open speaker window with BroadcastChannel sync (see html-template.md Speaker View section) - Include Print/PDF styles —
@media printCSS for PDF export via browser print (see html-template.md Print/PDF section) - Support speaker notes via
.speaker-noteelement ordata-speaker-noteattribute - Every element with animation uses
.revealclass pattern - Support
prefers-reduced-motion - Apply density choice throughout: speaker-led → fewer ideas per slide; reading-first → more self-contained detail
- NO style-specific classes in HTML content — Decorations (gold lines, vertical signatures, brush decorations, wavy lines, etc.) must be implemented via CSS pseudo-elements (
::before,::after) in the preset's Signature CSS (seestyle-presets.md). Never add style-specific divs/classes (e.g.,.gold-line-left,.vertical-sig,.brush-deco) to the HTML content. This is CRITICAL for Style Transfer to work — the HTML must only use semantic classes from the system defined inhtml-template.md.
Content overflow guardrails:
- No scrolling, no overflow, no overlapping panels inside any slide
- No text below comfortable reading size at 1920×1080
- If content exceeds density limits, split into more slides instead of shrinking
Phase 4: PPT Conversion
When converting PowerPoint files:
- Run
python scripts/extract-pptx.py <input.pptx> <output_dir>(install python-pptx if needed) - Present extracted slide titles, content summaries, image counts to user for confirmation
- Proceed to Phase 2 for style discovery
- Generate HTML preserving all text, images, slide order, and speaker notes (as HTML comments)
Style Transfer Protocol
When user says: "change to X style", "switch to X theme", "换成X风格", "迁移到X风格"
How it works
- Parse target style — Identify which of the 12 presets the user wants
- Extract the contract — Read the
:root {}block and<link>font tags fromreferences/style-presets.mdfor the target style - Replace in HTML — Only replace these parts in the existing HTML file:
- The
:root {}CSS block (the entire block) - The font
<link>/<style>tags in<head> - The
var(--theme-name)value (optional, for identification)
- The
- Do NOT touch — Any
.slidecontent,.revealclasses, or semantic class names
Why this works
The semantic class system (see references/html-template.md) ensures that HTML content is decoupled from visual style. The :root {} CSS variables are the contract:
.slide-titlemaps tovar(--title-size),var(--font-display),var(--text-primary).highlightmaps tovar(--accent).quote-blockmaps tovar(--quote-border),var(--quote-bg).col-2usesvar(--col-2-gap)
Step-by-step
1. IDENTIFY target style preset (from user input)
2. READ references/style-presets.md → extract the `:root {}` block for that preset
3. READ the existing HTML file
4. FIND the current `:root {}` block in the HTML's `<style>` tag
5. REPLACE the `:root {}` block with the new one from the preset
6. FIND and REPLACE any font `<link>` tags in `<head>`
7. SAVE the updated HTML file
8. PREVIEW to verify
Important notes
- Font loading: If the target style uses different fonts (Google Fonts vs Fontshare), update the
<link>tags accordingly - Background gradient: Some styles define
--bg-gradient(e.g., Aurora, Lava). Make sure to include it - Print styles: The
@media print {}block should be preserved as-is (it's style-agnostic) - Speaker View: The speaker view CSS is also style-agnostic and should be preserved
- Verify: After transfer, open the HTML and check that:
- Colors changed to target style
- Fonts changed to target style
- Content is untouched (same text, same layout)
Example
User says: "把这个演示文稿换成芭乐风格" (Change this presentation to Guava style)
1. Target style: 芭乐 Guava
2. Extract from style-presets.md:
:root {
--bg-primary: #fef5f0;
--text-primary: #2a2a2a;
--accent: #ff8fa3;
...
}
Font link: <link href="https://fonts.googleapis.com/css2?family=Caveat:wght@400;700&family=Nunito:wght@400;700&display=swap" rel="stylesheet">
3. In the HTML file, find and replace:
- OLD `:root {}` → NEW `:root {}` (Guava version)
- OLD font link → NEW font link (Caveat + Nunito)
4. Save and preview
Phase 5: Delivery
- Save the final HTML file to the project directory
- Open via present_files for browser preview
- Summarize: file location, style name, slide count, navigation controls (Arrow keys, Space, swipe), CSS variable customization, inline editing (hover top-left or press E)
- Tell user about Speaker View: press
Skey to open speaker window (current slide + next slide + timer + notes) - Tell user about PDF export: press
Ctrl+P→ "另存为 PDF",speaker notes print below each slide
Phase 6: Share & Export (Optional)
After delivery, ask: "Would you like to share this presentation? I can deploy it to a live URL or export it as a PDF."
Options: Deploy to URL / Export to PDF / Both / No thanks
- Deploy: Use CloudStudio deploy tool (workbuddy_cloudstudio_deploy) for instant live URL
- PDF: User prints from browser (
Ctrl+P→ "另存为 PDF"),@media printstyles included automatically
Fixed Stage Rules (Reference)
For detailed CSS and implementation, read references/viewport-base.css before generating. Key invariants:
- Every slide is authored at fixed 1920×1080 inside
.deck-stage - The stage scales uniformly via JS transform — letterbox/pillarbox is acceptable, reflow is NOT
- Slide visibility controlled by
.active/.visibleclasses — never usedisplay: none/block - No responsive breakpoints for slide content
- Use
calc(-1 * ...)to negate CSS functions — browsers silently ignore-clamp(),-min() - Include
prefers-reduced-motionsupport
Supporting Files Index
| File | Purpose | Load When |
|---|---|---|
| references/viewport-base.css | Mandatory fixed-stage CSS | Phase 3 |
| references/html-template.md | HTML architecture, JS features, editing system | Phase 3 |
| references/animation-patterns.md | Animation snippets and feeling guide | Phase 3 |
| references/style-presets.md | Visual style definitions | Phase 2-3 |
| scripts/extract-pptx.py | PPT content extraction | Phase 4 |
Current listing version
1.0.0
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 解决用户创建高质量HTML演示文稿的核心需求
- 支持多种模式:新建、PPT转换、增强、风格迁移
- 零依赖单文件输出,具有长期可用性
- 强调视觉美学和个性化设计,避免AI模板化
Highlights
- 触发词覆盖全面,包含中英文多种表达
- 明确区分四种使用模式及其触发条件
- 边界清晰,不易与其他Skill混淆
Areas to improve
-
缺少When to Use章节 Reported severity: Minor
文档结构完整但缺少显式的When to Use章节标题
Recommendation: 建议在frontmatter后添加When to Use章节以符合标准模板
Highlights
- 采用渐进式披露原则,结构层次清晰
- 包含完整的6个阶段工作流程
- 提供详细的参考文件索引和加载时机
- 文档组织遵循最佳实践
Areas to improve
-
PPT转换依赖外部Python库 Reported severity: Major
Phase 4的PPT转换功能依赖python-pptx库,但未提供明确的安装指导或错误处理
Recommendation: 建议添加python-pptx安装说明和库缺失时的错误处理机制
-
引用文件缺失处理 Reported severity: Minor
未明确说明当reference文件缺失时的fallback机制
Recommendation: 建议添加reference文件缺失时的默认处理方案
Highlights
- 详细的生成要求和检查清单确保输出质量
- 包含完整的错误防护机制(内容溢出防护)
- 支持无障碍特性(prefers-reduced-motion)
- 提供Speaker View和PDF导出等增值功能
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
These common operations were not identified in the main document. This does not mean no permissions or risks exist.
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- fonts.googleapis.com
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.