md-slides — Markdown deck → single-file HTML presentation
Reads a markdown deck (HR or H1 boundaries, optional presenter notes), emits a single-file HTML presentation that runs in any browser. Pipeline: split slides → parse presenter notes → render deck HTML.
- slide_splitter — split on
---HR or#H1 (auto: HR wins ≥3, else H1 ≥5). First heading per slide = title. - presenter_notes_parser — extract
<!-- notes: ... -->(alsospeaker-notes:/presenter:) per slide, strip from body, track coverage %. - deck_html_renderer — single-file HTML deck.
What ships in the HTML
- All slides as
<section class="slide">, one visible at a time (JS-controlled). - Keyboard nav —
→/Space/PgDnadvance;←/PgUpprevious;Home/Endjump;Ppresenter mode;Escexits presenter. - URL-hash deep linking —
#3jumps to slide 3; browser back/forward walks slides; sharedeck.html#5. - Progress bar (3px top) + slide counter (bottom-right "3 / 12").
- Presenter mode (P) — split view: current slide left (60%), panel right (clock + speaker notes + next-slide preview).
- Print stylesheet —
@media print { section { display:block; page-break-after:always } }→Cmd+P= one slide per page PDF. prefers-reduced-motionhonored; 12 brand CSS custom properties from design-system; reuses md-document's markdown parser for slide bodies.
Hard rules
- Refuse no-boundary input (auto needs ≥3 HR or ≥5 H1) → route to md-document.
- Refuse 1-slide decks (it's a poster).
- Refuse input < 100 lines (Shihipar threshold).
- Refuse without design-system onboarding.
--strict-notesrefuses < 50% notes coverage (not set up for presenter mode).- Soft-warn slides > 40 source lines (signal-to-noise; renders anyway).
- Single-file output — all CSS+JS inline; only external is Google Fonts CSS; Prism.js opt-in via
--syntax. - Vanilla JS only, no framework runtime.
Forcing questions
- Is this actually a deck or a long document? (If you can't draw clear boundaries, it's not a deck.)
- HR (
---) or H1 boundaries? (HR for typical decks; H1 for outline-driven.) - Presented live or self-paced? (Live → need presenter notes.)
- Any slide over 40 source lines? (Split it — attention drops past ~6 bullets / 200 words.)
- Is
--syntaxneeded? (Only for substantial code blocks; default off.)
Distinct from md-document (one continuous doc), md-review (diff hunks), and Keynote/PowerPoint (graphic-design tools). Output: {output_dir}/deck-{slug}.html.