omgovich / colord

👑 A tiny yet powerful tool for high-performance color manipulations and conversions
https://colord.omgovich.ru
MIT License
1.67k stars 50 forks source link

Incorrectly parse hexa to rgba to hexa #97

Open MrKou47 opened 2 years ago

MrKou47 commented 2 years ago

actual:

const expectValue = '#cc88'
colord(colord(expectValue).toRgbString()).toHex() !== expectValue // #cccc8887

expect:

const expectValue = '#cc88'
colord(colord(expectValue).toRgbString()).toHex() !== expectValue // toHex() return value should equal to expectValue