Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support PDF Form Field Calculations is missing #1851

Open
4 tasks done
paritosh-mahale opened this issue Aug 5, 2024 · 6 comments
Open
4 tasks done

Support PDF Form Field Calculations is missing #1851

paritosh-mahale opened this issue Aug 5, 2024 · 6 comments
Labels
enhancement New feature or request

Comments

@paritosh-mahale
Copy link

paritosh-mahale commented Aug 5, 2024

Before you start - checklist

  • I followed instructions in documentation written for my React-PDF version
  • I have checked if this bug is not already reported
  • I have checked if an issue is not listed in Known issues
  • If I have a problem with PDF rendering, I checked if my PDF renders properly in PDF.js demo

Description

There is a functionality available in pdf.js that allows for automatic calculations within PDF form fields if formulas are set. When a PDF form field changes value, the calculations are triggered, and the results are automatically updated in the respective form fields. However, this feature is not currently available in react-pdf.

This is screenshot from pdf.js where on selecting of QTY from dropdown is automatically calculates total by multiplying price per * QTY also the grand total get calculated automatically.
image

this functionality is not working in react-pdf
image

Adding document for ref
calculation-issue (2).pdf

pdf.js team also fixed wrong calculation issue recently please consider that to which fixing this

I have been struggling with this issue for the past 2-3 days and would greatly appreciate any assistance or guidance. Thank you in advance for your help.

Steps to reproduce

  1. Load attached PDF using react-pdf.
  2. Change QTY from dropdown and observe that the calculations are not triggered.

Expected behavior

When a form field is changed in a PDF loaded by react-pdf, the calculations set within the PDF should be triggered, and the result should be reflected in the respective form fields.

Actual behavior

The calculations set within the PDF are not getting trigger.

Additional information

No response

Environment

  • Browser (if applicable): any standard browser
  • React-PDF version: 7.7.1
  • React version: 17.0.2
  • Bundler name and version (if applicable):
@paritosh-mahale paritosh-mahale added the bug Something isn't working label Aug 5, 2024
@rahulrajpal2911
Copy link

I am facing the same issue. Did you get any support, @paritosh-mahale?

@shivanijaiswal610
Copy link

Hi @paritosh-mahale, I’m facing a similar issue. Were you able to find any solutions or receive any assistance?

@wojtekmaj
Copy link
Owner

Forms rendered by React-PDF are at the moment read-only.

@wojtekmaj wojtekmaj added enhancement New feature or request and removed bug Something isn't working labels Aug 22, 2024
@rahulrajpal2911

This comment was marked as spam.

@paritosh-mahale

This comment was marked as spam.

@paritosh-mahale

This comment was marked as spam.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants