agentleFS
sohaibdevvsohaibdevv/claude-skills/markdown-html/CLAUDE.md

claude-skills / markdown-html

CLAUDE.md2 starsChanged 42 days agoMITView on GitHub

This file provides domain-specific guidance for skills in markdown-html/. The markdown-html domain converts long markdown files (the actual artifacts produced inside a Claude project — specs, reports, RFCs, PR writeups, slide outlines) into world-class, single-file, lightly-interactive HTML. Inspired by Thariq Shihipar's argument (Medium, 2026): markdown collapses past ~100 lines because it lacks visual machinery for density and lateral navigation; HTML restores both. It is not an interactive prompt-tuning playground (/playground plugin owns that lane), not a landing-page generator (marketing/landing/), not…

We split this CLAUDE.md into the rules it gives an agent

4 rules. About 0 are common, 1 is distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    All three converters are shipped.

    line 21
  2. Very specific:

    Single-file HTML output: All CSS and JS inline. The only permitted external CDN entries are Google Fonts CSS and Prism.js.

    line 28
  3. Very specific:

    Customization in use, not decoration: Every converter MUST render differently when the user changes design_style, brand.primary, …

    line 31
  4. Very specific:

    Every converter sub-skill imports config_loader.py and calls load_config() to read project > global > defaults.

    line 68

≈ “Common” is an estimate: at least 1 in 5 of the 25,680 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
CLAUDE.md

Markdown → HTML — Domain Guide

This file provides domain-specific guidance for skills in markdown-html/.

Purpose

The markdown-html domain converts long markdown files (the actual artifacts produced inside a Claude project — specs, reports, RFCs, PR writeups, slide outlines) into world-class, single-file, lightly-interactive HTML. Inspired by Thariq Shihipar's argument (Medium, 2026): markdown collapses past ~100 lines because it lacks visual machinery for density and lateral navigation; HTML restores both.

It is not an interactive prompt-tuning playground (/playground plugin owns that lane), not a landing-page generator (marketing/landing/), not a session-handoff brief generator (engineering/handoff/ + productivity/handoff/), and not a static-site generator (single-file artifacts, not site indices).

Skills (v2.10.3 — domain complete)

SkillPurposecontext: fork?Status
markdown-html-orchestratorDomain orchestrator — classifies doctype, gates on threshold + onboarding, routes to converterYES✓ live
design-systemOne-time onboarding wizard + WCAG-AA-validated brand palette (12 CSS custom properties) + shared configNO✓ live
md-documentLong-form converter: sticky TOC, collapsibles, search, code-copy, scrollspyNO✓ live
md-reviewCode-review converter: 2-col diff + severity-tagged margin annotations + jump-navNO✓ live
md-slidesSlide-deck converter: arrow-key nav + presenter mode + print-to-PDFNO✓ live

All three converters are shipped. Routing always targets the converter skill's scripts — never hand-render HTML inline.

Hard rules (domain-specific)

  1. Refuses input < 100 lines. Markdown still wins below the threshold (Shihipar). Every converter (and the orchestrator) prints the line count and a "keep as markdown" recommendation.
  2. Refuses without design-system onboarding. The orchestrator's route_explainer.py checks config_loader.setup_completed(). If false, refuse and surface onboarding (python3 markdown-html/skills/design-system/scripts/onboard.py).
  3. WCAG AA enforced. brand_palette_validator.py rejects color combinations whose body-text contrast falls below 4.5:1 on bg. Link contrast is iteratively walked to 4.5:1 by adjusting luminance.
  4. Single-file HTML output. All CSS and JS inline. The only permitted external CDN entries are Google Fonts CSS and Prism.js. No bundler, no build step, no JS framework runtimes (vanilla JS + IntersectionObserver only).
  5. Never silently chain converters. "Convert this markdown AND make slides from it AND a code review" is three operations. Pick one, finish, ask before chaining.
  6. Stdlib-only Python. Deterministic logic, no LLM calls in scripts.
  7. Customization in use, not decoration. Every converter MUST render differently when the user changes design_style, brand.primary, code_theme, or toc.behavior. If a token doesn't change behavior, it doesn't belong in the schema.
  8. Onboarding-first. The orchestrator surfaces onboarding the moment it detects a missing setup_completed_at. Don't render with placeholder defaults silently.

Build pattern

Path-B contract per skill: SKILL.md + 3 stdlib scripts + 3 references (each citing 5-7 sources) + (optional) 1 asset template. The orchestrator skill ships context: fork in its frontmatter. The design-system skill is the shared brand owner — every converter imports its config_loader.py via sys.path.insert(0, .../design-system/scripts).

Each SKILL.md ships a "Forcing-question library" section (cited-canon grilling, one question at a time) — same discipline as research-ops, commercial, and business-operations.

Agent + command pattern

  • cs-markdown-html-orchestrator — density-first markdown-to-HTML converter. Voice: "What decision does this HTML drive — is the reader skimming, deciding, or presenting?"
  • /cs:markdown-html <path>.md — top-level router (classifier + route + recommend)
  • /cs:grill-markdown-html <path>.md — Matt-Pocock-style 5-question grill before conversion
  • /cs:design-system — surface the onboarding wizard

Per-sub-skill commands (all live):

  • /cs:md-document, /cs:md-review, /cs:md-slides

Anti-patterns (domain-level)

  • ❌ Converting markdown < 100 lines — markdown still wins. Refuse + cite Shihipar.
  • ❌ Skipping onboarding because "the user wants it done now." Surface onboarding — it's 60 seconds.
  • ❌ Multi-file output (separate CSS / JS / image folders). Single file or nothing.
  • ❌ External JS framework runtimes (React, Vue, Svelte, Alpine). Vanilla JS + IntersectionObserver only.
  • ❌ Silently overwriting existing output files. output_path_resolver.py suffixes -2, -3, … by default.
  • ❌ Setting MARKDOWN_HTML_NO_CONFIG=1 silently for an interactive user.
  • ❌ Decorative tokens — every token must change at least one converter's output.
  • ❌ Inventing brand colors when the user hasn't onboarded.
  • ❌ A skill that overlaps Anthropic's official Playground plugin (sliders/knobs/prompt-copy-back).
  • ❌ A skill that overlaps marketing/landing/ (landing-page generation from scratch).

Customization pipeline

  1. User runs python3 markdown-html/skills/design-system/scripts/onboard.py.
  2. Wizard validates brand colors via brand_palette_validator.py, derives 12-token palette.
  3. Result written to ~/.config/markdown-html/design-system.json (or ./.markdown-html/design-system.json with --scope project).
  4. Every converter sub-skill imports config_loader.py and calls load_config() to read project > global > defaults.
  5. Each converter's renderer emits a single <style> block with :root { --md-bg: ...; } for all 12 tokens, then references those variables throughout the CSS.
  6. Result: change a single field via --set brand.primary=#FF6B35 → next conversion re-renders with the new brand.

References

  • Spec: Thariq Shihipar — Claude Code HTML output: Why Markdown Lost and How to Switch (Medium, 2026)
  • Forking pattern source: research-ops/skills/research-ops-skills/SKILL.md (context: fork, two-signal routing)
  • Onboarding pattern source: research-ops/skills/clinical-research/scripts/onboard.py + config_loader.py
  • Brand palette math source: marketing/landing/skills/landing/scripts/brand_palette_validator.py
  • Matt Pocock grill-with-docs: engineering/grill-with-docs
  • Single-file HTML discipline source: marketing/landing/skills/landing/SKILL.md

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.