Hidabroot (here) writes
It is a well-known fact that Rabbi Yaakov [Ben Asher, the Baal Haturim] wrote his entire commentary
on the Torah in one night, orally, although no reliable source has
which is what you might have heard, although they don't connect it to his wedding night.
Thanks to @msh210, I found an official source in the ...