HTML5 input type='number' polyfill in pure JavaScript, no requirements