Solution 1:

If you want the text to be locked in when they submit, a alternative would to tell the player to sign the book when they're done, and test for a written_book in the inventory.

/say Enter your text, and sign the book when you're done!
/execute if entity @p[nbt={Inventory:[{id:"minecraft:written_book"}]}] run say Thanks for writing your text!

Also, it appears that the Book and Quill uses plain text in NBT for its pages, not JSON text. Signed books use JSON text, but editable books do not.