Skip to content

Remove PDF gen#426

Open
SteveLLamb wants to merge 5 commits into
mainfrom
feature/remove-pdf-gen
Open

Remove PDF gen#426
SteveLLamb wants to merge 5 commits into
mainfrom
feature/remove-pdf-gen

Conversation

@SteveLLamb

@SteveLLamb SteveLLamb commented Jun 9, 2026

Copy link
Copy Markdown
Member

Summary

Removes the tooling-based PDF rendering pipeline. HTML is the authoritative version of
SMPTE Engineering Documents; the generated PDF was convenience-only and consistently low
quality. Anyone who needs a PDF can use their browser's Print to PDF. This implements
the direction agreed in #407.

What changed

  • Dropped the PDF build pass (scripts/build.mjs): removed the makePDF() Puppeteer +
    paged.js renderer, the PDF filename assembly, and all PDF plumbing — review-link entry,
    S3 URL, review-zip file, artifact link, and the application/pdf manifest entry (~108 lines).
  • Removed the client-side paged.js injection (smpte.js): the ?media=print debug path
    that pulled paged.polyfill.js from a CDN is gone.
  • Doc note (doc/main.html): reworded the tbody page-break note from "when generating
    PDF" to "when printing."

Puppeteer is intentionally retainedrender() still uses headless Chromium to execute
the page and emit the authoritative static HTML. It was never PDF-only.

Also on this branch:

  • Formula numbering (css/smpte.css): the equation is now centered to the page with the
    number right-aligned at the margin (3-column grid).
  • Boilerplate (smpte.js): replaced literal smart-punctuation codepoints (curly
    apostrophes, ©, em dashes) with straight characters / references, in line with
    ILLEGAL_CHARS_RE.

Print CSS

The print stylesheet is kept as-is — the @media print / @page rules and break-* hints
remain so browser Print to PDF still produces sensible page breaks. Running headers/footers
are now browser-native rather than paged.js-driven.

Verification

  • npm test (validation suite) — passes.
  • node --check passes for build.mjs and smpte.js; module imports resolve.
  • No residual makePDF / pagedjs / application/pdf references.
  • End-to-end build: validated in the test-document repo by pointing its tooling
    submodule at this change and running a full publish build — produces the rendered HTML
    and zips with no PDF and no Puppeteer PDF pass.
    See SMPTE/tst123-4-private#1 (test PDF gen removal, commit 3e8008f).

Issues

Closes #407

Resolved by retiring the PDF tooling:

Partially addressed — PDF rendering is removed, but the HTML-side issue remains open:

@SteveLLamb SteveLLamb marked this pull request as draft June 9, 2026 23:43
@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

@SteveLLamb SteveLLamb marked this pull request as ready for review June 10, 2026 00:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant