1.0.9 • Published 6 years ago

colornamer v1.0.9

Weekly downloads
-
License
ISC
Repository
-
Last release
6 years ago

colornamer

A simple npm module/js client library that gives back the color-name of a hex or rgb value.

Created to provide accessible color names to people who are blind and visually impaired as part of the p5 accessible canvas project (https://github.com/processing/p5.accessibility) for the p5.js web editor (https://github.com/processing/p5.js-web-editor).

NPM module

For use with Node.js: npm install colornamer

var color = require('colornamer');

color.rgbColorName(255,0,0); //returns red
color.hexColorName('ff0000'); //returns red

Client library

Link to the library in your html: https://rawgit.com/lm-n/color-namer/master/lib/colorNamer.js Use the following functions to get a color name: rgbColorName(255,0,0); //returns red the expected input is three ints hexColorName('ff0000'); //returns red the expected input is a string of six characters without "#" at the beginning

1.0.9

6 years ago

1.0.8

6 years ago

1.0.7

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago