stephanrauh / ngx-extended-pdf-viewer

A full-blown PDF viewer for Angular 16, 17, and beyond
https://pdfviewer.net
Apache License 2.0
450 stars 167 forks source link

Is it possible to delete a signature form field ? #2300

Closed farisshomali closed 2 months ago

farisshomali commented 2 months ago

I know that unverified signature fields can't be used but is there any possible way to delete them from the form ?

I accessed the signature fields like this:

    this.ngxService.getFormData().then(form => {
      let signatureFields = form.filter(el => (el as any)['fieldAnnotation'].fieldType === "Sig")
    })
stephanrauh commented 2 months ago

Unverified signature can be displayed. It's just that I can't verify them, so I insist on adding a red warning above the PDF file.

I'm not sure if I want to support filtering annotations. I'm afraid that undermines trust in PDF files. However, if you insist, you can modify the JavaScript method PDFPageProxy.getAnnotations().