PDF export doesn't show user-edited styles #792

Closed
opened 2026-02-04 22:18:00 +03:00 by OVERLORD · 3 comments
Owner

Originally created by @pth0rn on GitHub (Aug 22, 2018).

Is there a way to get the PDF export to include the CSS changes that I've added? In my case I've changed the line spacing (via changing the margins on the p and h elements) and the font color to black with different font-family. However these changes don't show when exported to PDF (wkhtmltopdf).
Edit: same issue with export to HTML

Originally created by @pth0rn on GitHub (Aug 22, 2018). Is there a way to get the PDF export to include the CSS changes that I've added? In my case I've changed the line spacing (via changing the margins on the p and h elements) and the font color to black with different font-family. However these changes don't show when exported to PDF (wkhtmltopdf). Edit: same issue with export to HTML
OVERLORD added the 🛠️ Enhancement label 2026-02-04 22:18:00 +03:00
Author
Owner

@derek-shnosh commented on GitHub (Aug 23, 2018):

This is on my short-list of requests as well, thanks for posting.

@derek-shnosh commented on GitHub (Aug 23, 2018): This is on my short-list of requests as well, thanks for posting.
Author
Owner

@ssddanbrown commented on GitHub (Aug 23, 2018):

Thanks @Vicvinegar0 for reporting this. Should be a simple one to implement so will mark to be in the next release.

@ssddanbrown commented on GitHub (Aug 23, 2018): Thanks @Vicvinegar0 for reporting this. Should be a simple one to implement so will mark to be in the next release.
Author
Owner

@derek-shnosh commented on GitHub (Oct 6, 2018):

@ssddanbrown I know this is closed, but figured this was the best place to ask.

Thanks for implementing this! I'm wondering if there is any way to get the export to render the CodeMirror theme.

Also, it seems that any callouts with MD formatting in them are rendered properly by bookstack, but any space characted leading the MD annotation are replaced/omitted from the PDF export.

Example;

Code from markdown editor;

<c><p class="callout info">Static route statements will not affect traffic for VL-192 clients until SVI is migrated; i.e. the *attached* route on the Resort Cores for the associated subnet will supersede the configured static routes.</p>
  • Note: This comment explains why the <c> is included before the <p class...> for the callout; in short, it is a workaround to get markdown formatting to work inside a callout.

Bookstack Render

image

PDF Export Render

image

  • Notice the missing space between the attached; I initially thought this was due to italics, but it affected bold formatting as well.

image

@derek-shnosh commented on GitHub (Oct 6, 2018): @ssddanbrown I know this is closed, but figured this was the best place to ask. Thanks for implementing this! I'm wondering if there is any way to get the export to render the CodeMirror theme. Also, it seems that any callouts with MD formatting in them are rendered properly by bookstack, but any space characted leading the MD annotation are replaced/omitted from the PDF export. ## Example; ### *Code* from markdown editor; ``` <c><p class="callout info">Static route statements will not affect traffic for VL-192 clients until SVI is migrated; i.e. the *attached* route on the Resort Cores for the associated subnet will supersede the configured static routes.</p> ``` * Note: [**This comment** ](https://github.com/BookStackApp/BookStack/issues/927#issuecomment-416652456)explains why the `<c>` is included before the `<p class...>` for the callout; in short, it is a workaround to get markdown formatting to work inside a callout. ### Bookstack Render ![image](https://user-images.githubusercontent.com/21090563/46562019-1875b780-c8af-11e8-9e9b-a114da88b336.png) ### PDF Export Render ![image](https://user-images.githubusercontent.com/21090563/46562027-2592a680-c8af-11e8-9fdc-8ea06c6c97c7.png) * Notice the missing space between `the attached`; I initially thought this was due to italics, but it affected bold formatting as well. ![image](https://user-images.githubusercontent.com/21090563/46562129-933ed280-c8af-11e8-875b-cf28695ac4cf.png)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#792