fix(markdown): Render image-only pages in order and collapse dot leaders

Image-only pages (e.g. scanned cover pages) were appended at the end of
output instead of appearing in page order. Now flushes tables/images for
intermediate pages with no text lines during page transitions.

Also collapses dot-leader runs (4+ dots) into " ... " for cleaner TOC
rendering, and adds debug_pages binary for inspecting per-page items.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Abimael Martell
2026-02-14 18:36:41 -08:00
co-authored by Claude Opus 4.6
parent 2549167737
commit f77cbe9808
3 changed files with 155 additions and 67 deletions
+4
View File
@@ -45,3 +45,7 @@ path = "src/bin/detect_pdf.rs"
[[bin]]
name = "debug_ygaps"
path = "src/bin/debug_ygaps.rs"
[[bin]]
name = "debug_pages"
path = "src/bin/debug_pages.rs"