OPF Spec/Reference layer

OPF reference layer

OpenPresentation/opf 4761091 adds named content colors, a top-level variables map, stable payload id values, and the portable-deck command (opf bundle then, opf embed since OPF 0.15). The original reference-layer integration used @openpresentation/opf 0.11.2 (with opf-render 0.11.5, opf-pptx 0.11.3, opf-editor 0.10.3). Inspector and POST /api/v1/validate now use the schema synchronized from the installed core package, with the registered catalogs. The versions above describe that historical integration, not the current dependency pins.

ColorRef

Content color fields accept literal hex, color-scheme slots (accent1…followedHyperlink), semantic roles (primary, textSecondary, …), or var:<id>. Styled table cell fill, color, and border colors enforce the three forms at the schema level; rich-text run colors tolerate any string (unknown values warn).

"variables": { "risk": "#B42318" },
"slides": [{
  "text": [
    "Status ",
    { "text": "at risk", "color": "var:risk", "bold": true }
  ]
}]

variables

The top-level map holds reusable values. Color entries may be a hex string or { "type": "color", "value": "#…", "description": "…" }. Unknown var: references warn; they do not fail validation.

opf embed

The OpenPresentation CLI embeds every catalog record a document references (once, under the catalog group it came from, with the records those reference) so the output renders the same with no catalog registered:

opf embed <input.opf.json> <output.opf.json>

Remote media and data assets remain separate. pptx.dev does not host embed as a product action; its own downloads, exports, shared links and account saves already embed through core's embed, and the CLI or your CI pipeline does it for files you keep elsewhere.

Inspector

On color and variables paths, the right rail explains ColorRef resolution and links scheme slots to design.colorScheme. Preview and hosted PPTX generation resolve named colors through the effective scheme and document variables before emitting OOXML hex. Full pixel fidelity still depends on the coordinated renderer and PPTX packages.

Canonical compressed reference: format-card.md in the OPF repository.

Open Inspector →