Hello,
I can create for you a javascript module faithful to specification, with a simple, clean and maintenable code.
It will be really independant, injectable inside the page where you need it.
I just finish a measure converter, and bigger projects that sounds just like yours, and customer were really satisfied !
See you soon,
Loïc