Skip to content

Commit 49a098c

Browse files
committed
Decode appearance keys of checkboxes
1 parent 293506a commit 49a098c

3 files changed

Lines changed: 11 additions & 1 deletion

File tree

src/core/annotation.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3290,7 +3290,7 @@ class ButtonWidgetAnnotation extends WidgetAnnotation {
32903290
? this.data.fieldValue
32913291
: "Yes";
32923292

3293-
const exportValues = normalAppearance.getKeys();
3293+
const exportValues = this._decodeFormValue(normalAppearance.getKeys());
32943294
if (exportValues.length === 0) {
32953295
exportValues.push("Off", yes);
32963296
} else if (exportValues.length === 1) {

test/pdfs/issue19753.pdf.link

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
https://github.com/user-attachments/files/19566810/PDFjs_fails_checkboxState.pdf

test/test_manifest.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12114,5 +12114,14 @@
1211412114
"md5": "2abe67c8b34522feb6b85d252dde9d3e",
1211512115
"rounds": 1,
1211612116
"type": "eq"
12117+
},
12118+
{
12119+
"id": "issue19753",
12120+
"file": "pdfs/issue19753.pdf",
12121+
"md5": "6b1fe0af506860002a9411f5f0d6437f",
12122+
"rounds": 1,
12123+
"type": "eq",
12124+
"forms": true,
12125+
"link": true
1211712126
}
1211812127
]

0 commit comments

Comments
 (0)