Skip to content

Import - Add support for pdf highlights #196

Closed

Description

@aforank

Search first

  • I searched and no similar issues were found

What Happened?

I imported my existing graph for the first time, and one of the most noticeable issues I encountered is that the Edn files were not imported. It seems these files contain my highlights from a PDF. However, when I open the corresponding PDF files, my highlights no longer appear, and any references to these highlights are also broken (appears in yellow), as shown below.

image

image

EDN file content

{:highlights [{:id #uuid "647f43c6-7439-4c97-851f-a4286c04b11e", :page 73, :position {:bounding {:x1 11, :y1 4, :x2 674, :y2 359, :width 682.0000000000001, :height 383.62500000000006}, :rects (), :page 73}, :content {:text "[:span]", :image 1686062020889}, :properties {:color "yellow"}}], :extra {:page 81}}

100's of similar errors were shown after import.

Reproduce the Bug

Import a page with any PDF highlighting.

Expected Behavior

No response

Files

No response

Browser, 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!)

Activity

  1. changed the title [-]Import - Skipped file since its format is not supported (edn file)[/-] [+]Import - Add support for pdf highlights[/+] on Dec 20, 2024
  2. logseq-cldwalker commented on Jan 13, 2025

    @logseq-cldwalker
    Contributor

    Hi. This is a known todo as described in https://github.com/logseq/docs/blob/feat/db/db-version.md#importer-todos. We'll get to this at some point. The more people that upvote or comment this issue, the sooner we'll address it

  3. logseq-cldwalker commented on Jan 13, 2025

    @logseq-cldwalker
    Contributor

    In the meantime I have improved the import ux so that only notification is displayed for all ignored files

  4. yingzhu146 commented on May 29, 2025

    @yingzhu146

    Basically the main missing thing for me to be able to use the DB version. So many PDF annotations :)

  5. Sininho commented on May 31, 2025

    @Sininho

    Basically the main missing thing for me to be able to use the DB version. So many PDF annotations :)

    Yes, it is a big problem for me too ;-( Large parts of my graph are unusable because they rely on pdf annotations...

  6. kerim commented on Jul 10, 2025

    @kerim

    I just tested this, creating the following graph with one PDF attachment and two annotations, and then trying to import it. The two annotations are marked as invalid blocks on import.

    annotation test.zip

  7. logseq-cldwalker commented on Jul 22, 2025

    @logseq-cldwalker
    Contributor

    This should be addressed and available on test.logseq.com in 10 min. If you're having an issue with specific pdf highlights, please open a new issue and share the relevant pdf, edn and md files. If those files are sensitive then please email them to me at [email protected]

    @kerim Thanks for sharing your test graph as it helped me catch a bug with file names having special characters

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancementimport

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions