Files
pdfcraft/crates/annot/tests/it
b026f59f32 fix(annot): a comment without text is saved without /Contents (#7434) (#7662)
* fix(annot): a comment without text is saved without /Contents (#7434)

Every new comment got a /Contents entry, an empty string when nothing
was typed, and clearing a comment's text wrote an empty one too. macOS
Preview marks a markup comment that has the key, even empty, as holding
a note, so highlights made in PdfCraft showed a note bubble there.
Acrobat writes no /Contents for a highlight without a note.

New comments now get /Contents only when they have text, and clearing a
comment's text removes it. Summaries already read an empty /Contents as
no text, so nothing else changes.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(annot): test the empty-comment case with an open pop-up (#7434)

The test described a double-click but made a closed pop-up. It now
opens it, checks it is open, and checks the comment is still saved
without /Contents.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* Align empty comment property with omitted contents

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: FredApps <[email protected]>
Co-authored-by: FredApps <[email protected]>
2026-12-04 15:07:54 +01:00
..