feat(edit): add, edit and remove PDF link annotations (#35) - #55
Open
nonamexishere wants to merge 3 commits into
Open
feat(edit): add, edit and remove PDF link annotations (#35)#55nonamexishere wants to merge 3 commits into
nonamexishere wants to merge 3 commits into
Conversation
Validate staged Edit PDF output before the destination rename so a truncated or structurally wrong file cannot replace the user's dest. qpdf --check errors are fatal; warnings are recorded and do not block. Fixes McanKul#34.
Re-check cancel after qpdf --check and before publish so a mid-gate Cancel returns CANCELLED, deletes staging, and does not replace dest. Production --check registers on the job handle like overlay qpdf.
Detect existing allowlisted URI and in-document GoTo annotations, show them on the Edit PDF canvas, and write real /Link dictionaries on save after overlay. Unsupported actions are left in place. Uses the McanKul#34 staged-output gate. Fixes McanKul#35.
8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements #35: manage standard URI and in-document GoTo link annotations on Edit PDF.
This is a different job from #54 (#34 publish gate). Save still uses that gate, so this branch is stacked on it.
Depends on #54. Please merge #54 first. After that this PR rebases to link-only commits. Merging this before #54 would also land the validation gate.
In scope
/Linkannotations whose action is allowlisted URI (https/http/mailto) or in-document GoTo/Annots, then the test(editor): validate and round-trip edited PDF outputs before publish #34qpdf --check+ snapshot gateOut of scope
Why
Overlay stamps are not PDF links. Viewers need
/Subtype /Link+/A.Validation
npm run typechecknpm test(180)cargo test --manifest-path src-tauri/Cargo.toml --lib(120)Privacy Checklist