Closed eliselavy closed 1 year ago
R 's notebook - output data image/png and not data/image/jpeg
but doesn't seem related as in some article output data image/png are displayed:
https://journalofdigitalhistory.org/en/article/JJszM3GwAYDs?idx=137
The encoding was not right for the background-image css property, I've removed newlines in base64 encoding and it works. in principle this could be set from python code itself it seems, see https://stackoverflow.com/questions/30647219/remove-the-new-line-n-from-base64-encoded-strings-in-python3, they add newline=false
No idea why R outputs newlines, but it will be fixed as soon as PR https://github.com/C2DH/journal-of-digital-history/pull/510 is merged.
Problem of images displayed related to R's notebook :
https://github.com/jdh-observer/jdh001-9HcfToh7EYm8/blob/main/skim-article.ipynb https://journalofdigitalhistory.org/en/notebook-viewer/JTJGcHJveHktZ2l0aHVidXNlcmNvbnRlbnQlMkZqZGgtb2JzZXJ2ZXIlMkZqZGgwMDEtOUhjZlRvaDdFWW04JTJGbWFpbiUyRnNraW0tYXJ0aWNsZS5pcHluYg==
=> the table of content is ok - but no figures displayed
Other example here:
https://github.com/jdh-observer/jdh001-MyifnvNPDgUx/blob/main/taking-the-measure-of-social-democracy.ipynb
https://journalofdigitalhistory.org/en/notebook-viewer/JTJGcHJveHktZ2l0aHVidXNlcmNvbnRlbnQlMkZqZGgtb2JzZXJ2ZXIlMkZqZGgwMDEtTXlpZm52TlBEZ1V4JTJGbWFpbiUyRnRha2luZy10aGUtbWVhc3VyZS1vZi1zb2NpYWwtZGVtb2NyYWN5LmlweW5i?idx=75