Hi Michael, I didn't know you were on HN! For those who don't know, "Nielsen and Chuang" is the bible of the field of quantum information science.
The eqref-expanded-in-margin is a very cool idea. It could probably make sense for referencable environments like theorems and lemmas.
Do you have any recommendation for the .tex --> .html conversion?