PostCSS plugin for HSLuv color model functions
HSL Lightness | HSLuv Lightness |
---|---|
npm install postcss-plugin-hsluv
module.exports = {
plugins: {
'postcss-plugin-hsluv': {}
}
}
div {
background: hsluv(120, 50%, 50%);
color: hsluv(120, 50%, 85%);
}
- Transform to HSL instead of hex
- Support for alpha values
- Tests
Full credit for HSLuv color model and its design goes to hsluv/shluv and its maintainers. This postcss plugin merely uses the javascript implementation from the repository.