1.0.0 • Published 5 years ago

postcss-palette-tool v1.0.0

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

postcss-palette-tool

🎨 PostCSS plugin to mixin monochromatic colors scheme

Color palettes calculator of Ant Design.

Install

npm install --dev postcss-palette-tool

Usage

Add to postcss.config.js:

module.exports = {
    plugins: [
        require('postcss-palette-tool'),
    ],
};

This plugin can mix a color based on a variable and then output a new color.

before:

body {
    color: palette(#d92424, 1);
    background: palette(#24acd9, 8) radial-gradient(palette(#24acd9, 9), #ffffff);
}

after:

body {
    color: #fff2f0;
    background: #0a638c radial-gradient(#024366, #ffffff);
}

Options

vardescrequired
colorcss color✔️
level1 - 10 (6 is default color)✔️