JavaScript Roman numeral to base 10 equivalent converter