agentleFS
PMDevSolutionsPMDevSolutions/Flavian/.claude/skills/indesign-conversion/SKILL.md

indesign-conversion

Skill19 starsChanged 11 days agoMITView on GitHub

Use when converting an Adobe InDesign document (.idml or PDF) into a WordPress FSE block theme. Covers prerequisites, the parse → map-tokens → generate pipeline, expected outputs, and gotchas (CMYK→sRGB shifts, missing fonts, oversized print images). Keywords: InDesign to WordPress, IDML, IDML to FSE, InDesign PDF, print to web, design tokens from InDesign

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 1 is distinctive, and 1 is 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.

  • 1

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Do not use this for live Figma or Canva sources — use figma-to-fse-autonomous-workflow or canva-to-fse-autonomous-workflow instead.

    line 22
  2. Distinctive:

    Convert: Run the unified CLI:

    line 34

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill 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
SKILL.md

InDesign Conversion

Overview

This skill converts an Adobe InDesign document into a complete WordPress Full Site Editing (FSE) block theme using the @flavian/pipeline InDesign stages. It parses an exported .idml (or a PDF fallback), maps the document's paragraph/character styles and swatches into theme.json design tokens, and generates FSE block patterns (one per spread), templates, header/footer parts, and a merged theme.json.

Key principle: the design system comes from the document. Swatches → color palette, paragraph styles → typography scale, frame geometry → spacing — then patterns reference those token slugs, never inline values.

Pair this skill with the indesign-to-wordpress agent, which runs the steps end-to-end and reviews the generation report for follow-ups.

When to use

  • A client/designer hands you an InDesign layout (brochure, flyer, catalog, report) and wants it as a WordPress theme.
  • You have an exported .idml file, or only a PDF exported from InDesign.
  • You want a deterministic, re-runnable conversion (same input → same output, no diff churn).

Do not use this for live Figma or Canva sources — use figma-to-fse-autonomous-workflow or canva-to-fse-autonomous-workflow instead.

Prerequisites

  • An exported .idml (strongly preferred). In InDesign: File → Export → Format: InDesign Markup (IDML). IDML preserves stories, frames, styles, swatches, and master spreads.
  • Or a PDF fallback. File → Export → Adobe PDF. PDF reconstruction is lossy — text is rebuilt from glyph runs, styles are synthesized from font sizes, and every approximation is recorded as a fidelity warning. Use only when no .idml is available.
  • Node 20+ and the workspace installed (pnpm install).
  • Image bytes (optional). Patterns reference images by a deterministic filename; to stage the actual bytes, point --asset-dir at the IDML package's Links/ folder or a directory of extracted PDF assets.

Workflow

  1. Branch. git checkout -b indesign-import/<slug> — never convert on main.
  2. Convert. Run the unified CLI:
    flavian pipeline indesign <input.idml> --output themes/<slug>
    # add --seed-content to also emit bin/seed-content.sh (a draft page per spread)
    # add --asset-dir <dir> to stage real image bytes into assets/
    This parses, maps tokens, and generates the theme in one step.
  3. Review the report. Open themes/<slug>/indesign-pipeline-report.md (and the .json twin for tooling). Act on unmapped frames, font fallbacks, out-of-gamut colors, and missing alt text.
  4. Verify. Activate the theme locally and open the Site Editor; the imported patterns appear under InDesign Imports in the inserter. Confirm theme.json is valid (the report says so).
  5. Seed media. Drop image bytes into themes/<slug>/assets/ (if not already staged) and run bash themes/<slug>/bin/import-media.sh.

Expected outputs

themes/<slug>/
├── theme.json                      # base theme merged with the mapped tokens (schema-valid)
├── style.css, functions.php        # theme header + bootstrap (registers the InDesign Imports category)
├── patterns/spread-1.php …         # one block pattern per spread, category: indesign-imports
├── templates/                      # index.html (stitches the patterns), page.html, 404.html
├── parts/header.html, footer.html  # from master-spread chrome, or sensible defaults
├── bin/import-media.sh             # WP-CLI media import for staged assets
├── indesign-pipeline-report.md     # human-readable generation report
└── indesign-pipeline-report.json   # machine-readable counterpart

Frame → block mapping

  • Text frames → core/heading / core/paragraph, grouped in core/group (role from the paragraph-style name: Heading N, Body, Caption).
  • Image frames → core/image, or core/cover when text sits on top of the image.
  • Side-by-side frames → core/columns.
  • Master-spread top/bottom chrome → header/footer template parts.

Worked example (committed fixture)

The pipeline ships a code fixture (no committed binaries) and an end-to-end smoke test that builds a two-spread brochure, runs the real CLI, and asserts the theme is valid:

node scripts/indesign-fse/smoke-test.mjs
# ✓ smoke: InDesign pipeline generated a valid theme (2 spreads, theme.json v3)

To convert your own document end-to-end and inspect a generated pattern:

flavian pipeline indesign ./brochure.idml --output themes/brochure
sed -n '1,20p' themes/brochure/patterns/spread-1.php
cat themes/brochure/indesign-pipeline-report.md

You can also drive the stages individually (useful for debugging):

node packages/pipeline/bin/parse-idml.mjs brochure.idml > ir.json
node packages/pipeline/bin/map-tokens.mjs ir.json --out-dir ./tokens
node packages/pipeline/bin/generate-theme.mjs ir.json --out-dir themes/brochure

Common gotchas

  • CMYK/LAB → sRGB shifts. Print color spaces don't map 1:1 to screen. The mapper converts and flags any out-of-gamut swatch in the report; expect brand colors to look slightly different on screen and confirm them with the designer.
  • Missing / substituted fonts. InDesign fonts that aren't web-safe fall back via packages/pipeline/config/font-map.json (often a Google font). The report lists every fallback — confirm each, or self-host the real font and update the font map.
  • Oversized print images. Print assets are often huge (300 DPI, CMYK). Resize/recompress for web and convert CMYK images to sRGB before importing, or they'll bloat the page and render with muddy color.
  • PDF fidelity. A PDF parse always carries warnings — text reconstructed from glyphs, synthesized styles, dropped vector art. Prefer .idml; treat PDF output as a starting point that needs review.
  • Empty alt text. Generated images have alt="". Add meaningful alt text (the agent proposes some from surrounding story text) before shipping.
  • Don't hand-edit patterns destructively. Patterns are deterministic; re-running the pipeline regenerates them. Fix the source document or the pipeline rather than patching generated files.

Related

  • Agent: indesign-to-wordpress (orchestrates + reviews the report)
  • Docs: docs/pipelines/indesign.md, docs/pipeline/indesign-output-generator.md
  • Skills: fse-pattern-first-architecture, block-pattern-creation, visual-qa-verification

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.