setting an RGBA value might set a slightly different one
Issue #8
new
I am using the plugin with rgba values, but sometimes calling colorPicker('setColor', color)
with a color like "rgba(193,68,60,1)"
might end up setting the color "rgba(193,67,59,1)"
.
I think the problem comes from the _toRgba function, which should return rounded values, as such:
return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255), a];
instead of
return [parseInt(r * 255), parseInt(g * 255), parseInt(b * 255), a];