put translation javascript code in separate file