Crayola color definitions for lightningcss-plugin-extended-colors
npm install @lightningcss-plugin-extended-colors/crayolaCrayola color definitions for lightningcss-plugin-extended-colors. This collection includes 169 named colors from the famous crayon manufacturer.
``bash`
npm install lightningcss-plugin-extended-colors @lightningcss-plugin-extended-colors/crayola
`ts
import { transform, composeVisitors } from 'lightningcss';
import extendedColorsVisitor from 'lightningcss-plugin-extended-colors';
import crayola from '@lightningcss-plugin-extended-colors/crayola';
let res = transform({
filename: 'test.css',
minify: true,
code: Buffer.from(
.foo {
color: macaroniandcheese;
background: wildblueyonder;
}
),
visitor: composeVisitors([
extendedColorsVisitor({ colorspaces: [crayola] })
])
});
assert.equal(res.code.toString(), '.foo{color:#ffb97b;background:#7a89b8}');
``
See the full color chart for all 169 colors.
- Crayola - Collection of named colors from the crayon manufacturer