OxfordRSE / gutenberg

https://oxfordrse.github.io/gutenberg
BSD 3-Clause "New" or "Revised" License
5 stars 7 forks source link

export to pdf #171

Closed martinjrobins closed 3 months ago

martinjrobins commented 8 months ago

Add a button to each course that would render that course as a pdf and download it to the users computer, as a way to get a local copy of the material

alasdairwilson commented 5 months ago

We need to covnert the actual dom rather than the markdown as we add custom directives

dankimberley commented 3 months ago

As discussed - I came up with a solution using html2canvas and jspdf (example attached below) on the create-pdf branch. This works but has the pretty significant limitations of the pdfs having both low dpi text and non-selectable text. Proposed solution is to instead implement a download markdown button on the pages. Whether this would actually be useful though might need to be discussed further.

https://github.com/user-attachments/assets/362801ad-4e47-4624-935b-ad5c88cb3ceb