Encountering the same issue with Chrome and Firefox on Windows, I have noticed that it only happens with pure black, pure white, or any color very close to them.
Upon observing the Color picker, it becomes apparent that the RGB values remain unchanged when moving the cursor in the main square (they only change when using the vertical slider on the right, which the average user may not be inclined to do).
https://i.sstatic.net/9tZbH.png
Similar behavior is witnessed in other applications that utilize the same color picker, such as MSpaint or Tkinter's tkColorChooser.askcolor()
. Presumably, this is the default color picker in Windows, as indicated by the British English spelling of "colour" being my default language choice.
To resolve this issue, simply avoid using colors that are #ffffff
or #000000
(or colors very close to them) as your starting color.
<label for="doesntWork1">doesn't work</label> <input type="color" id="doesntWork1" value="#ffffff" onchange="alert(this.value);" />
<p>
<label for="doesntWork2">doesn't work</label> <input type="color" id="doesntWork2" value="#000000" onchange="alert(this.value);" />
<p>
<label for="works1">works</label> <input type="color" id="works1" value="#fdffff" onchange="alert(this.value);" />
<p>
<label for="works2">works</label> <input type="color" id="works2" value="#000002" onchange="alert(this.value);" />