postcss-palette

0.0.1 • Public • Published

PostCSS Palette Build Status

PostCSS plugin for colors management using external palettes.

Example

/* palette.js */

module.exports = {
    red: '#fa1200',
    green: '#1f0',
    blue: 'rgb(0, 42, 240)'
}
var palette = require('postcss-palette');

postcss([ palette({ palette: require('/path/to/palette') }) ]);
.foo {
    background-color: red;
    color: green;
    text-shadow: 0 0 5px blue;
    box-shadow: 0 0 5px blue;
    border-color: green;
}
.foo {
    background-color: #fa1200;
    color: #1f0;
    text-shadow: 0 0 5px rgb(0, 42, 240);
    box-shadow: 0 0 5px rgb(0, 42, 240);
    border-color: #1f0;
}

Usage

postcss([ require('postcss-palette') ])

See PostCSS docs for examples for your environment.

Package Sidebar

Install

npm i postcss-palette

Weekly Downloads

0

Version

0.0.1

License

MIT

Last publish

Collaborators

  • stcherenkov