plugin-bibtex icon indicating copy to clipboard operation
plugin-bibtex copied to clipboard

Exporting or Printing Note Excludes Reference List

Open chk86 opened this issue 3 years ago • 3 comments

I just started using this plugin and it works wonderfully. I did notice that in the side-by-side editor layout, the viewer screen shows a References list containing the citation for all the references in the note. However, when I either print the note or export the note, that References list is not included. I included a screenshot of the References List in the viewer mode. I did try exporting it as a PDF, html, and markdown, and none of them included the list.

Screen Shot 2021-08-31 at 1 53 40 PM

chk86 avatar Aug 31 '21 17:08 chk86

+1. Pity I did not pay attention to this issue until I rediscovered it with my students during a live demonstration. I guess for now the solution is to copy rich text from the preview into a context that supports rich text (e.g., ms word). But then, if you're using a dark theme like we apparently do, you have to also change the style or paste as plain text and then fix the style.

extall avatar Sep 09 '21 15:09 extall

Yes that was discussed here and the reason why I was trying to encourage the use of a [citation] tag that would then be rendered. Right now the plugin is doing some magic to display the references, and that magic doesn't happen when printing.

laurent22 avatar Sep 09 '21 15:09 laurent22

Yes that was discussed here and the reason why I was trying to encourage the use of a [citation] tag that would then be rendered. Right now the plugin is doing some magic to display the references, and that magic doesn't happen when printing.

I've studied the code, the Joplin plugin API, the linked discussion, and the way MarkdownIt works. I wonder how else you would pass the data about the cited references loaded from the file from the plugin to the contentScript for rendering purposes if not through the webviewApi.postMessage() by executing the script that upon fetching the data from the plugin adds the references into the desired placeholder in the generated HTML?

Looking at the HTML export, the script does not get executed prior to export and so what we see in the exported file is a call to webviewApi which is no longer valid...

extall avatar Sep 14 '21 13:09 extall