gstack/make-pdf/src
Garry Tan 58482b3c69
fix(make-pdf): correct CJK rendering — NUL sentinel hardening, SC-first fonts, CJK quote context
Three CJK fixes in the PDF pipeline:

- smartypants strips stray input NULs up front so document text can never
  forge the U+0000 placeholder sentinel and leak a preserved-zone marker
  into the output.
- The CJK font stack led with Japanese families, so Simplified-Chinese
  text rendered han glyphs with JP variants. Lead with PingFang SC /
  Heiti SC / Noto Sans CJK SC / Source Han Sans SC before the JP
  fallbacks.
- Quote-smartening only recognized ASCII openers as "start of quote"
  context; the fullwidth colon and CJK brackets now count, so quotes
  after them curl the right way.

Contributed by @rssprivacy-commits (PR #2012).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-14 20:21:02 -07:00
..
browseClient.ts fix(make-pdf): write browse-bound temp files under the safe-dirs allowlist 2026-08-14 20:20:51 -07:00
cli.ts v1.58.0.0 feat: diagram + multi-format document engine (mermaid, excalidraw, single-file HTML, DOCX) (#1990) 2026-06-12 15:38:53 -07:00
commands.ts feat(v1.4.0.0): /make-pdf — markdown to publication-quality PDFs (#1086) 2026-04-20 13:20:30 +08:00
diagram-prepass.ts v1.58.0.0 feat: diagram + multi-format document engine (mermaid, excalidraw, single-file HTML, DOCX) (#1990) 2026-06-12 15:38:53 -07:00
image-policy.ts v1.58.0.0 feat: diagram + multi-format document engine (mermaid, excalidraw, single-file HTML, DOCX) (#1990) 2026-06-12 15:38:53 -07:00
image-size.ts v1.58.0.0 feat: diagram + multi-format document engine (mermaid, excalidraw, single-file HTML, DOCX) (#1990) 2026-06-12 15:38:53 -07:00
orchestrator.ts fix(make-pdf): write browse-bound temp files under the safe-dirs allowlist 2026-08-14 20:20:51 -07:00
pdftotext.ts v1.52.2.0 fix(make-pdf): render emoji instead of tofu (▯) on Linux (#1787) 2026-05-29 18:06:19 -07:00
print-css.ts fix(make-pdf): correct CJK rendering — NUL sentinel hardening, SC-first fonts, CJK quote context 2026-08-14 20:21:02 -07:00
render.ts fix(make-pdf): no blank first page when content precedes the first H1 2026-08-14 20:20:51 -07:00
setup.ts fix(make-pdf): write browse-bound temp files under the safe-dirs allowlist 2026-08-14 20:20:51 -07:00
smartypants.ts fix(make-pdf): correct CJK rendering — NUL sentinel hardening, SC-first fonts, CJK quote context 2026-08-14 20:21:02 -07:00
types.ts v1.58.0.0 feat: diagram + multi-format document engine (mermaid, excalidraw, single-file HTML, DOCX) (#1990) 2026-06-12 15:38:53 -07:00