{"name":"color-convert","description":"Plain color conversion functions","version":"1.9.2","author":{"name":"Heather Arthur","email":"fayearthur@gmail.com"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Qix-/color-convert.git"},"scripts":{"pretest":"xo","test":"node test/basic.js"},"keywords":["color","colour","convert","converter","conversion","rgb","hsl","hsv","hwb","cmyk","ansi","ansi16"],"files":["index.js","conversions.js","css-keywords.js","route.js"],"xo":{"rules":{"default-case":0,"no-inline-comments":0,"operator-linebreak":0}},"devDependencies":{"chalk":"1.1.1","xo":"0.11.2"},"dependencies":{"color-name":"1.1.1"},"gitHead":"2c3f959f055bda471749a3d9d27f6ff9218c875b","bugs":{"url":"https://github.com/Qix-/color-convert/issues"},"homepage":"https://github.com/Qix-/color-convert#readme","_id":"color-convert@1.9.2","_npmVersion":"5.6.0","_nodeVersion":"9.6.1","_npmUser":{"name":"qix","email":"i.am.qix@gmail.com"},"dist":{"integrity":"sha512-3NUJZdhMhcdPn8vJ9v2UQJoH0qqoGUkYTgFEPZaPjEtwmmKUfNV46zZmgB2M5M4DCEQHMaCfWHCxiBflLm04Tg==","shasum":"49881b8fba67df12a96bdf3f56c0aab9e7913147","tarball":"http://registry-npm.ywwl.com/color-convert/download/color-convert-1.9.2.tgz","fileCount":7,"unpackedSize":26964,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbHyBFCRA9TVsSAnZWagAAEt4P+QG7yaLhjk4RsjyN2ql+\nIFw0QwJ7kZnkHrFpl787XEOamf/Co/EoY1fj0ZV848wnGYu44RIk55Xp3ZFc\nWisi5QtGjOKyX1RueJ8Y1tYbEsQ/8jeAUEAPA+hj7P4ZPTJIkqkz3gC4qbz0\nsVbdA0h0kYzKw9cHOUQIBmPQFxuRPRoJcImkSK+YaFSatKDFWbMo4D5gEvCV\nY6xfCREm4cFD1Ql8jV89PQc93+qTAWdODCtsPPDRTmmspamzalIBmdOOMiEw\n9SC3YLOJK+8OytNR7fA3JPcxn1RFDpFNNuRF9DRjfYns2cwFd8LGoeZvvOYK\nHadq72Ox3x4etT+eDqrjM+IJxxjYPJSF3CWC8p8BZab1ZXk9K8h6VJm/o7/d\nS3JLtyUQREfGUmUonH5KUuOYXO7Z3RLu4G1amiqPAn5BvFUqHCGuf7qZ58vL\nZ487Lv9Wjwq523KpuYaKGJhX0Wz61e0oT0VXCbYLY9/Ih9pZYrlj2vhOZewF\nXm+vhEatUdHmhDG5ezMsagc0mm46h2TB7A6O66RFcv9K7PHal9XMxpqQslg1\nyOD23N/l7BTdf//A5DOd1qKNOz/D2GOD4zjSy31JSHyAPjPC63k1h2Tb3bcz\ntjKZANSBfc4QVGMV91RT1tn0g+xl+aKGFEaJNO35HBxmEDMfGrIdaE4zAG5X\nrWJM\r\n=KzXz\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDt691if4a3Vow3ll37ecO72QpwY0jfhaQOq4Po/tM8jAIhAOkIeDyzdRxP/MftS0Hi/BGhkbt1LDUmhQIyM+dYsBf5"}],"size":8910,"noattachment":false,"key":"/color-convert/-/color-convert-1.9.2.tgz"},"maintainers":[{"email":"m@moox.io","name":"moox"},{"email":"i.am.qix@gmail.com","name":"qix"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/color-convert_1.9.2_1528766532123_0.40888513473984656"},"_hasShrinkwrap":false,"readme":"# color-convert\n\n[![Build Status](https://travis-ci.org/Qix-/color-convert.svg?branch=master)](https://travis-ci.org/Qix-/color-convert)\n\nColor-convert is a color conversion library for JavaScript and node.\nIt converts all ways between `rgb`, `hsl`, `hsv`, `hwb`, `cmyk`, `ansi`, `ansi16`, `hex` strings, and CSS `keyword`s (will round to closest):\n\n```js\nvar convert = require('color-convert');\n\nconvert.rgb.hsl(140, 200, 100);             // [96, 48, 59]\nconvert.keyword.rgb('blue');                // [0, 0, 255]\n\nvar rgbChannels = convert.rgb.channels;     // 3\nvar cmykChannels = convert.cmyk.channels;   // 4\nvar ansiChannels = convert.ansi16.channels; // 1\n```\n\n# Install\n\n```console\n$ npm install color-convert\n```\n\n# API\n\nSimply get the property of the _from_ and _to_ conversion that you're looking for.\n\nAll functions have a rounded and unrounded variant. By default, return values are rounded. To get the unrounded (raw) results, simply tack on `.raw` to the function.\n\nAll 'from' functions have a hidden property called `.channels` that indicates the number of channels the function expects (not including alpha).\n\n```js\nvar convert = require('color-convert');\n\n// Hex to LAB\nconvert.hex.lab('DEADBF');         // [ 76, 21, -2 ]\nconvert.hex.lab.raw('DEADBF');     // [ 75.56213190997677, 20.653827952644754, -2.290532499330533 ]\n\n// RGB to CMYK\nconvert.rgb.cmyk(167, 255, 4);     // [ 35, 0, 98, 0 ]\nconvert.rgb.cmyk.raw(167, 255, 4); // [ 34.509803921568626, 0, 98.43137254901961, 0 ]\n```\n\n### Arrays\nAll functions that accept multiple arguments also support passing an array.\n\nNote that this does **not** apply to functions that convert from a color that only requires one value (e.g. `keyword`, `ansi256`, `hex`, etc.)\n\n```js\nvar convert = require('color-convert');\n\nconvert.rgb.hex(123, 45, 67);      // '7B2D43'\nconvert.rgb.hex([123, 45, 67]);    // '7B2D43'\n```\n\n## Routing\n\nConversions that don't have an _explicitly_ defined conversion (in [conversions.js](conversions.js)), but can be converted by means of sub-conversions (e.g. XYZ -> **RGB** -> CMYK), are automatically routed together. This allows just about any color model supported by `color-convert` to be converted to any other model, so long as a sub-conversion path exists. This is also true for conversions requiring more than one step in between (e.g. LCH -> **LAB** -> **XYZ** -> **RGB** -> Hex).\n\nKeep in mind that extensive conversions _may_ result in a loss of precision, and exist only to be complete. For a list of \"direct\" (single-step) conversions, see [conversions.js](conversions.js).\n\n# Contribute\n\nIf there is a new model you would like to support, or want to add a direct conversion between two existing models, please send us a pull request.\n\n# License\nCopyright &copy; 2011-2016, Heather Arthur and Josh Junon. Licensed under the [MIT License](LICENSE).\n","publish_time":1528766532214,"_cnpm_publish_time":1528766532214,"dist-tags":{"latest":"3.1.3"}}