06 · Slide Decks
← Docs home · Task: turn a published section into a curated Slidev deck, then export it to editable + rasterised PowerPoint.
Source of truth:
slidev-deck-builder,slidev-curated-deck,slidev-pptx-export, and the baseslidevskill. Scripts:scripts/transpile_slidev_to_pptx.py,scripts/embed_pptx_videos.py.
Procedure
Say: “build a deck for section 3.2”. The slidev-deck-builder skill then:
- Enumerate every teachable object in the section HTML — Learning Objectives, Definitions, Theorems, Examples, Try-It-Nows, Media, Figures.
- Write an inventory checklist to
_workspace/deck-builder/<slug>.inventory.md(document order; everything included by default). - Curate with you — an
AskUserQuestionper category; your picks sync back to the inventory file. - Extract real content from the source numbered MD (clean LaTeX:
\(…\)→$…$). - Build the curated deck →
docs/<book>/slides/<slug>.md, mirroring the §3.1 / §3.2 reference decks exactly. - Hand off to
slidev-pptx-exportfor the PPTX exports.
Export to PowerPoint (two files, on purpose)
# Editable: native PowerPoint shapes + equations, no video
python scripts/transpile_slidev_to_pptx.py \
docs/<book>/slides/<slug>.md docs/<book>/slides/<slug>.editable.pptx
# Rasterised: delivery-grade, with embedded autoplay video
slidev export docs/<book>/slides/<slug>.md --format pptx
python scripts/embed_pptx_videos.py # overlays the section MP4s
| File | Nature | Use it for |
|---|---|---|
<slug>.editable.pptx |
Native shapes, editable text, OMML math (with LaTeX fallback) | Editing in PowerPoint / OnlyOffice |
<slug>.pptx |
Rasterised slides + embedded autoplay MP4 | Presenting / delivery |
Math in the editable export is wrapped as mc:AlternateContent (OMML + fallback)
for OnlyOffice compatibility.
On the web
Published sections expose a “Present” button linking the Slidev SPA at
docs/<book>/slides/<slug>/index.html. Decks can also be uploaded/stored via the
Cloudflare backend (R2 bookshelf-decks + D1), surfaced through the
/api/decks/* and /slides/* Functions — see
02 · Architecture.
Gotchas
- The PPTX template path is hardcoded:
scripts/assets/slidev_wedgwood.pptx. - Build the curated
.mdto mirror the §3.1/§3.2 decks — the export scripts assume that structure. - Keep the editable and rasterised files side by side; they coexist by naming
convention (
.editable.pptxvs.pptx).