How can I get a color name using JS/JQuery, knowing the code RBG/HEX?
For example:
Colorname RGB black #000000 white #FFFFFF red #FF0000 green #008000
You can do that with color_classifier.js plugin. It works good and returns the name of nearest color that has name.
Just use like this
window.classifier = new ColorClassifier(); get_dataset('dataset.js', function (data){ window.classifier.learn(data); }); var result_name = window.classifier.classify("#aaf000");
1.4m articles
1.4m replys
5 comments
57.0k users