Skip to content

Commit

Permalink
Merge pull request #7 from RyanHow/3.10
Browse files Browse the repository at this point in the history
render the initial state of checkboxes correctly even if they are radiobuttons in disguise and the first checkbox is not checked
  • Loading branch information
stephanrauh authored Sep 27, 2024
2 parents cb0a594 + 4924400 commit cc30dd4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/display/annotation_layer.js
Original file line number Diff line number Diff line change
Expand Up @@ -1165,6 +1165,7 @@ class TextWidgetAnnotationElement extends WidgetAnnotationElement {
const storedData = angularData.value ? angularData : formData;
if (angularData !== formData) {
storage.setValue(id, { value: angularData.value });
storedData.formattedValue = angularData.value;
}
// #1737 + #1887 end of modification by ngx-extended-pdf-viewer
let textContent = storedData.value || "";
Expand Down Expand Up @@ -1579,7 +1580,7 @@ class CheckboxWidgetAnnotationElement extends WidgetAnnotationElement {
});

// #1737 modified by ngx-extended-pdf-viewer
window.registerAcroformField(id, element, value ? data.exportValue : false);
window.registerAcroformField(id, element, value ? data.exportValue : undefined, undefined, data.fieldValue);
element.addEventListener("updateFromAngular", newvalue => storage.setValue(id, { value: newvalue.detail }));
// #1887 end of modification by ngx-extended-pdf-viewer
if (updateAngularValueNecessary) {
Expand Down
2 changes: 1 addition & 1 deletion web/ngx-extended-pdf-viewer-version.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const ngxExtendedPdfViewerVersion = '18.1.12';
export const ngxExtendedPdfViewerVersion = '18.1.15';

0 comments on commit cc30dd4

Please sign in to comment.