deck-to-pptxlisted
Install: claude install-skill ak3ne/deck-to-pptx
# deck-to-pptx — HTML deck → editable PPTX
Rebuild an HTML slide deck as a native, editable PowerPoint. The trick: don't recreate
the layout by hand — render the HTML in a real browser, read each element's *computed*
geometry, and rebuild those as native PPT objects, baking only the un-reproducible
decoration (gradients, card fills, rules, SVG charts) as one flat background image per slide.
This is **inspect-then-adapt**, not zero-touch: every deck differs (fonts, slide selector,
chrome), so read the HTML and tune the marked knobs before running.
## Pipeline (4 stages, run from the build folder)
1. **`build_fonts.py`** — download the families the deck uses (Google Fonts, OFL = embed-clean),
flatten variable→static weights, subset CJK to GB2312 + the deck's charset (small but typeable).
2. **`extract.py`** — Playwright renders each slide at 1920×1080, reads geometry+style → `deck.json`,
and bakes a text/media-hidden "decoration plate" PNG per slide.
3. **`generate.py`** — python-pptx lays the plate full-bleed + native text/photo/video objects at
`1px = 0.5pt` (13.333"×7.5", 16:9).
4. **`embed_fonts.py`** — OOXML-inject the fonts (`embeddedFontLst` + `saveSubsetFonts="0"` =
full characters → client can edit, not just view). No PowerPoint needed.
## Workflow
1. **Inspect the HTML**: slide selector (default `section.slide`), every font used (flag CJK +
Apple system Chinese → remap to Noto Sans SC), chrome to hide (nav/progress/key-hints), and
any count-up