Skip to content

Conversation

@personalizedrefrigerator
Copy link
Owner

@personalizedrefrigerator personalizedrefrigerator commented Mar 28, 2024

Summary

Adds support for PDF annotation through a new @js-draw/pdf-support package. This package exposes an interface that must be implemented for whichever PDF backend is to be used.

It should be possible to access a built version of the PDF editor example here.

To-do

  • Fix exported text bounding box.
  • Refactor MuPDF-related logic out of docs/examples/pdf-support and into a package that can be published to NPM.
    • Note: MuPDF is licensed under the GNU AGPLv3 — it will need to be made clear that this is the case in the package's README.
  • Better page memory management.
    • Page images should be freed if not recently used.
    • Support caching pages at different zoom levels, perhaps by forcing the use of js-draw's rendering cache?.
  • Support image annotations
  • Support highlight annotations
  • Support searching for PDF text
  • (Optional/follow-up PR) Support selecting PDF text
  • (Optional/follow-up PR) Support links
  • (Optional/follow-up PR) Support form conrols
  • (Optional) More memory-efficient saving of strokes.

@github-actions
Copy link

github-actions bot commented Mar 28, 2024

Visit the preview URL for this PR (updated for commit 5661b19):

https://js-draw--pr67-work-pdf-support-9v0zw3ml.web.app

(expires Mon, 13 Jan 2025 10:46:32 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: e560ee6f7bb6b79cb55b42fb4c05e9fd1b5c506e

@personalizedrefrigerator personalizedrefrigerator changed the title Support PDF annotation feat: Support PDF annotation Nov 21, 2024
Only a watch command was available.
@personalizedrefrigerator
Copy link
Owner Author

personalizedrefrigerator commented Nov 21, 2024

Direct link to example: https://js-draw--pr67-work-pdf-support-9v0zw3ml.web.app/examples/example-pdf/example.html

personalizedrefrigerator added a commit that referenced this pull request Nov 25, 2024
@personalizedrefrigerator
Copy link
Owner Author

Closing for now. This pull request (or a similar one with a different approach) may be re-opened in the future.

@github-project-automation github-project-automation bot moved this from In Progress to Done in js-draw Jan 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants