logseq
logseq copied to clipboard
[bug] Zotero-linked-files: * and # in PDF filename are not properly encoded in the url
Search first
- [X] I searched and no similar issues were found
What Happened?
Special characters in the names of Zotero linked files are not percent-encoded.
For example,
[[test]]{{zotero-linked-file "This is a PDF with * in title.pdf"}}
[[test]]{{zotero-linked-file "This is a PDF with # in title.pdf"}}
It results in this error information in console when clicking the button to open the PDF
core.cljs:943 [PDF loader] MissingPDFException {message: 'Missing PDF "file:///C:/Users/ZoteroLib/This%20is%20a%20PDF%20with%20*%20in%20the%20title.pdf".' name: 'MissingPDFException', stack: 'Error\n at BaseExceptionClosure (file:///C:/User…s/WorkDir/java/logseq/static/js/pdfjs/pdf.js:32:3'}
* is still here
Reproduce the Bug
Add * or # to the title of a linked file in Zotero, import it into Logseq and click its open
button.
Expected Behavior
No response
Screenshots
No response
Desktop or Mobile Platform Information
No response
Additional Context
No response
Are you willing to submit a PR? If you know how to fix the bug.
- [ ] I'm willing to submit a PR (Thank you!)
Have the same problem here.