How to create a shortcut to get link to current position in pdf?

Hi everyone. First of all a big and sincere "thank you" to the Zotero developers for the awesome work!

I am looking for a way to quickly create a link to the current position in the pdf document I'm reading in Zotero.
My ideal workflow would be the following: while I'm reading a pdf I'd like to have a keyboard shortcut that copies a Markdown link to the current location in the pdf so that I can paste it in an Obsidian note. In this way, when I later read the note I can immediately jump back to the relevant section of the pdf (e.g. a particular formula).

At the moment I am simply using the "Markdown Item URI" quick copy action, which is already great, but only copies a link to the Zotero entry, not to any particular location in the document.

The action itself is already doable in a few steps and essentially I'd like to understand how to automate them to reduce as much friction as I can. Currently, I can highlight some text in the PDF viewer, use the awesome "Add note from Annotations" function, then export the note in Markdown including Zotero links and finally copy the relevant part from the exported file. In particular I'm interested in the portion containing a link of the form: (zotero://open-pdf/library/items/9FQCU888?page=1&annotation=G2L66F4P)).

For reference, I'm trying to loosely replicate this workflow https://castel.dev/post/research-workflow/ using Zotero and Obsidian. In particular I was intrigued by the idea of having a "friction-free" approach to inserting links to specific pages of a reference.

Instinctively this seems doable, but I have no idea how to approach the problem. I hope this will be useful to somebody else as well.
  • edited May 14, 2022
    Currently, I can highlight some text in the PDF viewer, use the awesome "Add note from Annotations" function
    You don't need to do that. You can just copy an annotation directly and get the Markdown link.

    (Note that this doesn't work if you just copy selected text. It could, but it seems a bit less clear that that should generate links in the same way as an annotation rather than just copying the text.)
  • @dstillman Thanks for the reply!

    The behaviour you describe would satisfy my needs, but it doesn't work for me. If I select the pdf annotation and press cmd+c (I'm on macOS) when I paste I get nothing at all... I'm using Zotero 6.0.7. Am I missing something or doing something stupid?
  • Have you tested pasting into TextEdit in plain-text mode?

    If you get nothing for that, we'd want to see a Debug ID for attempting to copy.
  • edited May 14, 2022
    Yes I get nothing when I paste, whatever text editor I use.

    The debug ID for copying a PDF annotation is D732340279
  • Disable your third-party plugins.
  • I have now disabled all the plugins.
    Something weird happened this time: I started Zotero with the pdf already open, I copied an annotation, pasted into a text editor but nothing happened, then selected and copied a different annotation and it worked. New debug ID for this behaviour: D1714052793

    It's not the particular annotation or document, it seems that it doesn't copy the annotation correctly the first time I do it after opening Zotero.

    Anyway, even when I successfully copy the annotation the pasted text is "highlighted text" (author, year, page) without any markdown link. Do I need to change some options? (haven't found any)

    Thank you so much for looking into this!
  • edited May 14, 2022
    By the way, in case it is useful information: if I re-enable Better BibTeX for Zotero I can't copy any annotation.
  • Zotero copies Markdown for plain text. You have to change a setting in Obsidian to see it: https://forums.zotero.org/discussion/comment/400374#Comment_400374
  • edited May 14, 2022
    You can report the BBT problem to the BBT developer on GitHub.
  • Thanks a lot @dstillman ! This resolves my problem, sorry for only pasting into Obsidian. I'll get in touch with the BBT developer.

    The only quirk that seems due Zotero is not copying the annotation at the first attempt, but it's absolutely minor.
  • edited May 15, 2022
    I can't reproduce that. I'd guess you're just trying before the export translators are initialized, which can take a few seconds after startup.
Sign In or Register to comment.