Translate human metric value strings into integers in JavaScript. (1kg -> 1000)