ruhley / angular-color-picker

Vanilla AngularJS Color Picker Directive with no requirement on jQuery
http://ruhley.github.io/angular-color-picker/
MIT License
166 stars 79 forks source link

round + white = problem #152

Closed tarankov88 closed 7 years ago

tarankov88 commented 7 years ago

Great plug-in!

Problem: options.round = true; $scope.color = 'rgb (255,255,255)'; // white

Color does not change when changed. The sliders on the right are transparent. Your demo page reproduces this issue(https://ruhley.github.io/angular-color-picker/)

ruhley commented 7 years ago

This is because at 100% lightness changing hue or saturation will always just output a white color. I have updated the slider backgrounds to be more accurate

tarankov88 commented 7 years ago

Thanks for the response!

Are you sure you did what you wanted? I do not see any visible changes in the demo =(

ruhley commented 7 years ago

I have only just created the new release of v3.2.0

OffbeatPlanet commented 7 years ago

Hi, I'm having the same problem in "round mode". If the color is white or black it can't be changed. I'm using version 3.2.0 pulled from npm. By now I went back to using round: false. Aside from that, thanks for this directive, really useful! :clap:

ruhley commented 7 years ago

@outreal To use the round color picker it is strongly recommended to also show the lightness slider. This is because the angle of the circle changes hue, the distance from the center changes saturation, but there is nothing in the circle to change the lightness. In the hsl format, if lightness is either 0% or 100% then it will always be black or white, no matter what is selected for hue and saturation.

OffbeatPlanet commented 7 years ago

@ruhley ok, thanks!