EyeDropper API in JavaScript