pIvan / ngx-color-picker

Pure Angular color picker library.
MIT License
94 stars 17 forks source link

Hue component slider drifting in the wrap color picker example #72

Closed mtinnes closed 10 months ago

mtinnes commented 1 year ago

The wrap color picker demo has an issue where the hue slider drifts during color selection. I've uploaded a video showing the issue on the official demo page.

https://github.com/pIvan/ngx-color-picker/assets/6729389/bfe3b173-82a7-4693-975b-96f27bec6af8

pIvan commented 11 months ago

Hi @mtinnes, the issue arises when we make two way data binding in RGB, RGBA, or HEX format to the component. The reason for this is that internally within the library, HSVa format is used, and during the conversion from HSVa to RGBA and vice versa, a little precision is lost, which is why it appears that the pointer jumps. This will also be corrected within the library components, and the demo example.