Added color translation in js.