DocDraw v1 is feature-complete. DD-PDF-1 golden PDFs + hashes are live (see Examples). Details

Golden examples

This page is generated from examples/golden-manifest.json. Do not edit by hand.

Golden examples are the “trust builder” for a standard: input + deterministic compiler + expected output that implementations can compare against.

Phase 2 (live): golden PDFs + hashes

These examples now include compiler-produced golden PDFs with a recorded pdf_sha256 in the manifest.

  • Do not edit PDFs by hand. Regenerate via the toolchain.
  • Each example also includes a deterministic text-only golden (*.normalized.docdraw) + SHA256.

Source of truth:

  • examples/golden-manifest.json
  • examples/source/ (inputs)
  • assets/examples/ (compiler-produced PDFs + normalized outputs)

Examples

Quickstart

  • id: quickstart
  • expected: PASS
  • DocDraw input: examples/source/quickstart.docdraw
  • DMP-1 input: examples/source/quickstart.md
  • Golden PDF: /assets/examples/quickstart.pdf
  • renderer_profile: DD-PDF-1
  • Normalized golden: /assets/examples/quickstart.normalized.docdraw
  • normalized_sha256: c3e3cace236789fe8b917df7ed262e4478467f68169dfa7b4e4f6dcc18bf7808
  • compiler_version: docdraw-php-ddpdf1-proto
  • pdf_sha256: d15ed72d56c73c7d2f60b5029e60c43321c8af7d7cc7488c4c8f80b773511967
  • last_generated: TBD
  • Expected Output Contract:
    • MUST: Bullets render with explicit nesting from -L levels.
    • MUST: Continuation lines (..:) align to the list text start and MUST NOT introduce extra vertical spacing.
    • MUST: Wrapped list lines use hanging indent alignment (text start X).
    • SHOULD: Headings keep-with-next (avoid orphan headings).
    • MUST: Divider (---) renders as a horizontal rule with consistent spacing above and below.
    • MUST: Rendering is deterministic: same input yields same PDF.

List wrapping & continuations

Mixed lists & numbering restart

DMP-1 ambiguous indent (FAIL)

  • id: dmp1-ambiguous-indent
  • expected: FAIL (markdown_import) codes: AMBIGUOUS_LIST_INDENT
  • DMP-1 input: examples/source/dmp1-ambiguous-indent.md
  • compiler_version: TBD
  • pdf_sha256: TBD
  • last_generated: TBD
  • Expected Output Contract:
    • MUST: Converter fails (no guessing) because list indentation does not increase by exactly 4 spaces per level.

DocDraw invalid list level jump (FAIL)

  • id: docdraw-invalid-list-level-jump
  • expected: FAIL (docdraw_validation) codes: DDV1_LIST_LEVEL_JUMP
  • DocDraw input: examples/source/docdraw-invalid-list-level-jump.docdraw
  • compiler_version: TBD
  • pdf_sha256: TBD
  • last_generated: TBD
  • Expected Output Contract:
    • MUST: Validator fails because list level jumps from -1 to -3 without an intervening -2.
    • MUST: Validator reports a stable error code (e.g. DDV1_LIST_LEVEL_JUMP) and a fix suggestion.

Reproduce

In the docdraw repo:

make examples-update
make examples-check