scttcper / tinycolor

🎨 Color manipulation and conversion
https://tinycolor.vercel.app
MIT License
543 stars 36 forks source link

Support Lab color #238

Open justinfagnani opened 1 year ago

justinfagnani commented 1 year ago

The Lab color space is part of CSS color 4, and is implemented in Safari already. There are also some operations, like color distance, nicely defined in Lab space.

It's be great to support the lab() syntax in parsing, and toLab() and toLabString() methods.

petr001 commented 1 year ago

Actually landing to all major browsers: https://caniuse.com/css-lch-lab

Screenshot 2023-03-14 at 17 03 29