get-image-colors
get-image-colors copied to clipboard
When the count is set more than 7, the return colors are one less.
example: count: 7 => return 7colors count: 8 => return 7 colors count: 30 => return 29 colors
@ynynl
If you will set to options.count
negative number you will get something like this:
options = {
count: -1
}
[ "color", "color" ]
options = {
count: -2
}
[ "color" ]
options = {
count: -3
}
[ ]
And so one. Decreasing the number further will also result in an empty array.
It seems to me that the problem is most likely in the packages that this utility uses. That is chroma.js or get-rgba-palette. Since I did not see any strange logic in the index.js file of this library.