I hope the following is some sort of comfort after the accident(some sort of rescue i hope!).
Obviously, the passport will need to be replaced in future. Assuming its an Irish passport, it will cost €80.
1) Dry the passport by placing it near some radiator...(not direct fire/heat), so that the pages would become separable more or less. Dont use any cloth to wipe, otherwise it will do more damage to the stamps.
2) Make a note of what you can read about the stamps: date and where issued, the Vignette number, anything you can read really.
3) Make a photocopy of the details about the passport: ie the Passport number, ID, issue details etc
4) Its a good thing to keep a backup photocopy of the passport, you may have one. Its good practice, i keep a copy of mine. No idea why, just feels more safe that way.
Is this going to be a huge problem? Is there anything that we should do?
I dont know if it is going to be a problem, but i know something can be done so that it does not become a problem. Its likely/possible the Home Office (or Irish equivalent, sorry dont know what its called. Read 'last port of entry, passport issuing authority') may have kept a photocopy of the passport. So ask if a copy can to be sent to you. I would speak to the passport office and request a copy for future reference (if ever you need it), Their contact details are
http://www.dfa.ie/home/index.aspx?id=401.