This issue has been created
 
 
XWiki Platform / cid:jira-generated-image-avatar-27736bfd-42e2-4f62-921a-df1f067ecb33 XWIKI-23380 Open

Include an outline (bookmarks) in the generated PDF

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-df6622ce-62aa-4bef-9165-9dbdcf61f79f Marius Dumitru Florea created this issue on 15/Jul/25 12:45
 
Summary: Include an outline (bookmarks) in the generated PDF
Issue Type: cid:jira-generated-image-avatar-27736bfd-42e2-4f62-921a-df1f067ecb33 New Feature
Affects Versions: 17.5.0
Assignee: Unassigned
Components: Export - PDF
Created: 15/Jul/25 12:45
Priority: cid:jira-generated-image-static-major-0d5196e3-6155-445b-8524-066e68a2d651 Major
Reporter: Marius Dumitru Florea
Description:

Chrome headless has an experimental parameter to generate a PDF outline (bookmarks). See https://chromedevtools.github.io/devtools-protocol/tot/Page/#method-printToPDF

generateDocumentOutline boolean
Whether or not to embed the document outline into the PDF. Experimental

But, there are open issues about it, such as https://issues.chromium.org/issues/383706655 . So:

  • We need to check how it works with the way paged.js is splitting the content into print pages.
  • We shouldn't enable the outline by default as long as it is experimental. I'd rather expose a configuration on the PDF Export Options modal, but only when the headless Chrome PDF generator is used.
  • We need to run all PDF export tests with this option enabled to see if we have failures
  • We need to add an automated test specifically for checking the produced outline / bookmarks. For this we need to see how to read the bookmarks from the generated PDF using PDFBox.
  • We need to check if the produced PDF with outline is still crashing Adobe Reader (we might have to use a newer version of headless Chrome Docker image).

    This fix for the outline entries pointing to themselves as their own parent (leading to issues with Reader) should be in 136.0.7067.0 and later.