mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-09 09:45:42 +02:00
Annotation - Some checkboxes have an empty N dictionary
- it aims to fix #14021; - the N dict is empty here so just create a default one; - it implies that the checked checkbox has no appearance so create a default one too in order to print it; - in the pdf in the issue, a checked box is not printed because it has no default appearance so we need to guess its appearance from its state.
This commit is contained in:
parent
cc110b8542
commit
c0e9108d00
4 changed files with 162 additions and 47 deletions
|
@ -1013,10 +1013,7 @@ class CheckboxWidgetAnnotationElement extends WidgetAnnotationElement {
|
|||
const data = this.data;
|
||||
const id = data.id;
|
||||
let value = storage.getValue(id, {
|
||||
value:
|
||||
data.fieldValue &&
|
||||
((data.exportValue && data.exportValue === data.fieldValue) ||
|
||||
(!data.exportValue && data.fieldValue !== "Off")),
|
||||
value: data.exportValue === data.fieldValue,
|
||||
}).value;
|
||||
if (typeof value === "string") {
|
||||
// The value has been changed through js and set in annotationStorage.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue