PKM-er / obsidian-zotlit

A third-party project that aims to facilitate the integration between Obsidian.md and Zotero, by providing a set of community plugins for both Obsidian and Zotero.
https://zotlit.aidenlx.top
MIT License
589 stars 25 forks source link

Quick copy citations leads to invalid HTML code on Ubuntu #300

Closed NicoJG closed 5 months ago

NicoJG commented 5 months ago

Usually in Zotero you can just quick copy a standalone reference/citation to text form. Or at least you can choose if you want it in HTML or Markdown form. When I do this now, I always get an HTML code in Obsidian (only in Obsidian), which has invalid characters in it. Regardless of what I choose in Zotero.

What I want to get from a quick copy or right click -> "Create Bibliography from item":

[1] F. F. Chen, Introduction to Plasma Physics and Controlled Fusion. Cham: Springer International Publishing, 2016. doi: [10.1007/978-3-319-22309-4](https://doi.org/10.1007/978-3-319-22309-4).

What I get in Obsidian if ZotLit is enabled:

��<�div class="csl-bib-body" style="line-height: 1.35; "> <�div class="csl-entry" style="clear: left; "> <�div class="csl-left-margin" style="float: left; padding-right: 0.5em;text-align: right; width: 1em;">[1]<�/div><�div class="csl-right-inline" style="margin: 0 .4em 0 1.5em;">F. F. Chen, <�i>Introduction to Plasma Physics and Controlled Fusion<�/i>. Cham: Springer International Publishing, 2016. doi: <�a href="https://doi.org/10.1007/978-3-319-22309-4">10.1007/978-3-319-22309-4<�/a>.<�/div> <�/div> <�span class="Z3988" title="url_ver=Z39.88-2004&amp;ctx_ver=Z39.88-2004&amp;rfr_id=info%3Asid%2Fzotero.org%3A2&amp;rft_id=urn%3Aisbn%3A978-3-319-22308-7%20978-3-319-22309-4&amp;rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Abook&amp;rft.genre=book&amp;rft.btitle=Introduction%20to%20Plasma%20Physics%20and%20Controlled%20Fusion&amp;rft.place=Cham&amp;rft.publisher=Springer%20International%20Publishing&amp;rft.aufirst=Francis%20F.&amp;rft.aulast=Chen&amp;rft.au=Francis%20F.%20Chen&amp;rft.date=2016&amp;rft.isbn=978-3-319-22308-7%20978-3-319-22309-4&amp;rft.language=en"><�/span> <�/div>

This happens once the ZotLit plugin in Obsidian is enabled. I tested it with both the Zotero addons (ZotLit and BetterBibTex) enabled and disabled. I have Ubuntu 22.04 with Zotero v6.0.30, Obsidian v1.5.3, ZotLit v1.1.4. Can you please fix this bug and maybe add an option in Obsidian if the copied citations should be altered or not?

NicoJG commented 5 months ago

I was mistaken. This is not a problem of ZotLit. It also happens without any addons in Zotero or Obsidian. But if I insert it into Obsidian via Ctrl+Shift+V then it is normal text.