Import fails after editing freetext annotation

Test Setup
I created an simple environment to reproduce the problem.

  1. $ git clone https://github.com/nolnol2/pdfjs-express-react-sample
  2. $ git checkout origin/freetext_issue -b freetext_issue
  3. npm start

Test scenario

This sample is exported when mouseRightDown and imported when dblClick.

  1. Modify the contents of FreetextAnnoation.
  2. Export.
  3. import
  4. An error occurred.

If you do not modify the contents of FreetextAnnoation, no error occurs.

Detailed description of issue
After edting, export annotation and I get this xfdf string
An error occurs when importing. And importing all annotations fail… :cold_sweat: :disappointed_relieved: :cry:

This is a very critical issue for us. :disappointed_relieved:
Hope it solves.

Expected behaviour
I hope that the freetext annotation can be properly modified and exported.
I would like to see the modified contents when importing.

Error
CoreControls.js:789 Uncaught TypeError: Cannot read property ‘AU’ of undefined
at webpack_exports .e.Rv (VM451 CoreControls.js:789)
at webpack_exports .e.Rk (VM451 CoreControls.js:790)
at ba.Rk (VM451 CoreControls.js:217)
at ba.Rk (VM451 CoreControls.js:331)
at ba.DX (VM451 CoreControls.js:324)
at ba.Pd (VM451 CoreControls.js:323)
at n.f.Nk (VM451 CoreControls.js:293)
at VM451 CoreControls.js:242
at Array.forEach ()
at VM451 CoreControls.js:242

Hi there!

Thanks for sending a sample repo, that helps a lot.

I was able to reproduce the error in version 6.3.1 (the one you were using).

That issue appears to be fixed in version 7.1.0, so upgrading to that should fix it.

Thanks!
Logan