Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
css-spec-colors
Advanced tools
A JSON with all CSS color keywords and their corresponding values in hex, RGB and HSL. Color list generated from W3C spec (https://www.w3.org/TR/css-color-4/#named-colors).
A JSON with all CSS color keywords and their corresponding values in hex, RGB and HSL. Color list generated from W3C spec (https://www.w3.org/TR/css-color-4/#named-colors).
Using npm:
$ npm install css-spec-colors
Using yarn:
$ yarn add css-spec-colors
import colors from 'css-spec-colors'; // or const colors = require('css-spec-colors');
// All colors
console.log(colors);
/**
* {
* aliceblue: {
* name: 'aliceblue',
* hex: '#f0f8ff',
* rgb: 'rgb(240, 248, 255)',
* hsl: 'hsl(208, 100%, 97.1%)'
* },
* ...
* }
*
*/
// Get a color by name
console.log(colors['aliceblue']);
/**
* {
* name: 'aliceblue',
* hex: '#f0f8ff',
* rgb: 'rgb(240, 248, 255)',
* hsl: 'hsl(208, 100%, 97.1%)'
* }
*/
// Get the hex value of a color
console.log(colors['aliceblue'].hex); // '#ff0000'
// Get the RGB value of a color
console.log(colors['aliceblue'].rgb); // 'rgb(255, 0, 0)'
// Get the HSL value of a color
console.log(colors['aliceblue'].hsl); // 'hsl(0, 100%, 50%)'
Colors are sorted alphabetically.
MIT © Aarón García
FAQs
A JSON with all CSS color keywords and their corresponding values in hex, RGB and HSL. Color list generated from W3C spec (https://www.w3.org/TR/css-color-4/#named-colors).
The npm package css-spec-colors receives a total of 5 weekly downloads. As such, css-spec-colors popularity was classified as not popular.
We found that css-spec-colors demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.