{"versions":{"2.3.2":{"name":"colorthief","version":"2.3.2","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle --no-sourcemap && node ./build/build.js","watch":"microbundle watch --no-sourcemap","dev":"http-server","test":"mocha && cypress run --config video=false","test:browser":"cypress open","test:node":"mocha"},"devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^3.4.0","eslint":"^5.16.0","http-server":"^0.11.1","microbundle":"^0.11.0","mocha":"^6.2.0","mustache":"^3.0.1"},"dependencies":{"get-pixels":"^3.3.2","quantize":"github:lokesh/quantize"},"gitHead":"ef231c711309dc32be1efa83bd4da7c0ed21cd6e","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.3.2","_nodeVersion":"12.4.0","_npmVersion":"6.9.0","dist":{"shasum":"00b984f421abe5a2af71c4d464c9d80d407fd53d","size":421879,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.3.2.tgz","integrity":"sha512-1r4nPW553JviRcFRvN3fS2V9nUSQGjRIws8UfEeFLIxk8j1tvtaX+AAYTkH3A4B5Muiys8SA1WJxf+00xVTXyg=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.3.2_1594009938531_0.12875240804434362"},"_hasShrinkwrap":false,"publish_time":1594009938763,"_cnpm_publish_time":1594009938763,"_cnpmcore_publish_time":"2021-12-18T20:16:56.835Z","contributors":[]},"2.3.1":{"name":"colorthief","version":"2.3.1","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle --no-sourcemap && node ./build/build.js","watch":"microbundle watch --no-sourcemap","dev":"http-server","test":"mocha && cypress run --config video=false","test:browser":"cypress open","test:node":"mocha"},"devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^3.4.0","eslint":"^5.16.0","http-server":"^0.11.1","microbundle":"^0.11.0","mocha":"^6.2.0","mustache":"^3.0.1"},"dependencies":{"get-pixels":"^3.3.2","quantize":"github:lokesh/quantize"},"gitHead":"4858a208d7f1b23002087d5859437f14277de13e","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.3.1","_nodeVersion":"12.4.0","_npmVersion":"6.9.0","dist":{"shasum":"80064e803dab5c49f9ebe50244c23d629ccd2100","size":421853,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.3.1.tgz","integrity":"sha512-UpPg/20UzOgUQnPNiz8TVZg5R2/L1kAW3zL4B/icCqJ7Pd3Xr9r/XUeXEipQCyN3rfSxZpvDcSzLCI6fDtSB1A=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.3.1_1594003338023_0.21368491635650688"},"_hasShrinkwrap":false,"publish_time":1594003338229,"_cnpm_publish_time":1594003338229,"_cnpmcore_publish_time":"2021-12-18T20:16:57.208Z","contributors":[]},"2.3.0":{"name":"colorthief","version":"2.3.0","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle --no-sourcemap; node ./build/build.js","watch":"microbundle watch --no-sourcemap","dev":" ./node_modules/http-server/bin/http-server","test":"mocha; ./node_modules/.bin/cypress run --config video=false","test:browser":"cypress open","test:node":"mocha"},"devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^3.4.0","eslint":"^5.16.0","http-server":"^0.11.1","microbundle":"^0.11.0","mocha":"^6.2.0","mustache":"^3.0.1"},"dependencies":{"get-pixels":"^3.3.2","quantize":"github:lokesh/quantize"},"gitHead":"043d65307864218eb51b6b54afdaeccda87e3636","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.3.0","_nodeVersion":"12.4.0","_npmVersion":"6.9.0","dist":{"shasum":"f1ba6322ff2434f684d248b17a291419a9f78cd5","size":421097,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.3.0.tgz","integrity":"sha512-tXmXEtB/la7R37ovhdh0b6KZ4yWQEbU50u20Fh94e537niZiB2cgOpnGxAaYy5B3s7SLJ2wHWdavn/JaCoEQjg=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.3.0_1564934188432_0.8752438155334401"},"_hasShrinkwrap":false,"publish_time":1564934188606,"_cnpm_publish_time":1564934188606,"_cnpmcore_publish_time":"2021-12-18T20:16:57.623Z","contributors":[]},"2.2.1":{"name":"colorthief","version":"2.2.1","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle; node ./build/build.js","watch":"microbundle watch","dev":" ./node_modules/http-server/bin/http-server","test":"cypress open"},"devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","cypress":"^3.4.0","eslint":"^5.16.0","http-server":"^0.11.1","microbundle":"^0.11.0","mustache":"^3.0.1"},"dependencies":{"get-pixels":"^3.3.2","quantize":"github:lokesh/quantize"},"gitHead":"ec98c39d42c1d6db58b988b20c89bb06e1afbf65","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.2.1","_nodeVersion":"12.4.0","_npmVersion":"6.9.0","dist":{"shasum":"a2631a3c5e73b7b12ecc1a89d8fbc963662c25a5","size":456964,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.2.1.tgz","integrity":"sha512-zkcmzz/sNWR1nIjV7e7fOqyZ+Z9Zkgz2adDb8oOYfsISSCQ7Hn0zr4Ihja+tXShXZe/aGXba6Ze2Y98KWYO0gw=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.2.1_1563806251717_0.2639265847868455"},"_hasShrinkwrap":false,"publish_time":1563806251937,"_cnpm_publish_time":1563806251937,"_cnpmcore_publish_time":"2021-12-18T20:16:58.034Z","contributors":[]},"2.2.0":{"name":"colorthief","version":"2.2.0","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle; node ./build/build.js","dev":"./node_modules/http-server/bin/http-server","test":"cypress open"},"devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","cypress":"^3.4.0","eslint":"^5.16.0","http-server":"^0.11.1","microbundle":"^0.11.0","mustache":"^3.0.1"},"engines":{"node":">=10.15.3"},"gitHead":"f0ae4e6a6b9b8aa8c3a446ac21b75b0a974b967c","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.2.0","_nodeVersion":"12.4.0","_npmVersion":"6.9.0","dist":{"shasum":"ed644b5de186e94f8d302cc35af196fe57770973","size":459182,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.2.0.tgz","integrity":"sha512-jtS2rrSQQMHqE4tkzpZu7l4MDOwKuZTxzsHdhFmxwshCX/5snPIzC+CwwHOwaACa6bwYV3qHwvnCSLqKvsC4Dw=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.2.0_1563160450639_0.8740064228151088"},"_hasShrinkwrap":false,"publish_time":1563160450812,"_cnpm_publish_time":1563160450812,"_cnpmcore_publish_time":"2021-12-18T20:16:58.462Z","contributors":[]},"2.1.0":{"name":"colorthief","version":"2.1.0","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","scripts":{"build":"node ./build/build.js","dev":"./node_modules/http-server/bin/http-server","test":"cypress open"},"main":"dist/color-thief.min.js","devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","cypress":"^3.3.1","eslint":"^5.16.0","http-server":"^0.11.1","mustache":"^3.0.1"},"engines":{"node":">=10.15.3"},"gitHead":"6f5c2c8d7d8a4adc6791518cbd50311aed88d35b","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.1.0","_npmVersion":"5.5.1","_nodeVersion":"8.9.3","_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"dist":{"shasum":"6eca9267a1a9f9db0ec213f045cf86461f8a7e58","size":427049,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.1.0.tgz","integrity":"sha512-vPS24Ubz2fqPlWSswu2jcmx2/B1Ax8KVoQvY5AbnXmzCpoTwzhDi2btLdYzyYaMDHKFXtZ/F/76YEMsKTdKc+Q=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.1.0_1563122840463_0.5409941867667365"},"_hasShrinkwrap":false,"publish_time":1563122840695,"_cnpm_publish_time":1563122840695,"_cnpmcore_publish_time":"2021-12-18T20:16:58.821Z","contributors":[]},"2.0.2":{"name":"colorthief","version":"2.0.2","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"licenses":[{"type":"MIT","url":"https://raw.githubusercontent.com/lokesh/color-thief/master/LICENSE/"}],"main":"dist/color-thief.min.js","devDependencies":{"grunt":"~1.0.1","grunt-contrib-watch":"^1.0.0","grunt-contrib-connect":"^1.0.2","grunt-contrib-uglify":"~2.0.0","grunt-contrib-jshint":"^0.11.2","grunt-jscs":"^1.8.0"},"gitHead":"25876fbaba41867b9e2bc11cb9e263c19a270748","_id":"colorthief@2.0.2","scripts":{},"_shasum":"40feda8b28c2e92aa069954e2627d482f906fa48","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.9.0","_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"dist":{"shasum":"40feda8b28c2e92aa069954e2627d482f906fa48","size":401119,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.0.2.tgz","integrity":"sha512-oWS2KWnuWTRAB2IM2VXut985tL+rfRK31z6vPHSy4qY+6xArdAsuAY8uHTOWP0YB+mk+FiBSqpzMJvbCj2ZurQ=="},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief-2.0.2.tgz_1511750168098_0.24326248443685472"},"directories":{},"publish_time":1511750168549,"_hasShrinkwrap":false,"_cnpm_publish_time":1511750168549,"_cnpmcore_publish_time":"2021-12-18T20:16:59.134Z","contributors":[]},"2.4.0":{"name":"colorthief","version":"2.4.0","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle --no-sourcemap && node ./build/build.js","watch":"microbundle watch --no-sourcemap","dev":"http-server","test":"mocha && cypress run --config video=false","test:browser":"cypress run --headed --browser chrome","test:node":"mocha","cypress":"cypress open"},"devDependencies":{"@node-minify/core":"^4.0.5","@node-minify/uglify-es":"^4.0.5","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^12.6.0","eslint":"^5.16.0","http-server":"^0.11.1","microbundle":"^0.15.0","mocha":"^6.2.0","mustache":"^3.0.1"},"dependencies":{"@lokesh.dhakar/quantize":"^1.3.0","get-pixels":"^3.3.2"},"gitHead":"4dc3bb0b43250f0d006278998aa91c4156f77cc3","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_id":"colorthief@2.4.0","_nodeVersion":"18.14.0","_npmVersion":"9.3.1","dist":{"integrity":"sha512-0U48RGNRo5fVO+yusBwgp+d3augWSorXabnqXUu9SabEhCpCgZJEUjUTTI41OOBBYuMMxawa3177POT6qLfLeQ==","shasum":"74e6edd142695655bd5f52c7f8116b125ea2b2bd","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.4.0.tgz","fileCount":43,"unpackedSize":562930,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIG8d6iSy56hxmkUt6ZFrumRpcU7BrBR446FfbhPbbV46AiEAwXDSSe5KDYqJnQT17wMMeu5XYBlTtWR7qlfOcHcLVfU="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj/nyiACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqCKBAAikxj7kCXiUqCf7I5Mpu9gnoZqLuRG1kMQrag9vg8D9a3JbfK\r\n1tOqRfy1dFLyFkOiVR7C0ju+cOTyJ43Ne+dwHe9V+3G9dctYZHGxKSRoq9PP\r\nzYGp8ZjOJLIdXCrM+BgxL2DVD5rbXAniWBlQsznOwUdzxLXyjw5XCXMc9ufZ\r\n1BUP9ihKh1FE/XRMOn9xv0PoEe15hfnfuW5UWXIJ049N6v2jqRaBf35AdZdM\r\nNIBS5/rz5QFSjcQC97Qhz9XvUg/rCrOKs51ffqbR44tlgGv20lPErd07UXJE\r\n58rQ2u7fGq0dDITOEEU2uSWvhIquzXVkGZyaAABDCm01LfbyRoCL9YMVMWom\r\nsM77fUnhfFlMSTKslDgl2wcDWonVnLPUL8C+pnkfKGJRA0KqjDKR1F+ycWLj\r\nOh7QKyzRgnZMXM0CvlrbnWEzSzbCNeeH/y4rUMFReLPS9bFwwPJ7s7hqVV13\r\nJv9X3CC+AuACt1EggzUd+uJ6RZugdx6dUVkciM3TblJDmE4wgm+voYNSH1Sf\r\njwZzYqZFCAFyUezO+NP6T9gNv9b30NauXlvHFevJqhH0v05TdYFI672dbm1J\r\ntt8Kke5U1dziRa0IznOf2CyDJyIflWzECKlv99TB2wxqTWvBgecJr3ZyHNq7\r\nJppWY8qmlGEgSvMrA0VF49z/wS/NTLSrFOc=\r\n=Bynt\r\n-----END PGP SIGNATURE-----\r\n","size":423458},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.4.0_1677622434469_0.09458627324729729"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-02-28T22:13:54.690Z","publish_time":1677622434690,"contributors":[]},"2.6.0":{"name":"colorthief","version":"2.6.0","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"build":"microbundle --no-sourcemap && node ./build/build.js","watch":"microbundle watch --no-sourcemap","dev":"http-server","test":"mocha && cypress run --config video=false","test:browser":"cypress run --headed --browser chrome","test:node":"mocha","cypress":"cypress open"},"devDependencies":{"chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","eslint":"^5.16.0","http-server":"^14.1.1","microbundle":"^0.15.0","mocha":"^10.2.0","mustache":"^3.0.1"},"dependencies":{"@lokesh.dhakar/quantize":"^1.4.0","file-type":"^16.5.3","ndarray-pixels":"^4.1.0","sharp":"^0.33.5"},"_id":"colorthief@2.6.0","gitHead":"292d5c1c8e87cf122ad8a6a1a5d1ccf6491f0612","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"18.20.4","_npmVersion":"10.7.0","dist":{"integrity":"sha512-yL3B7laeOr4kH9XasFF5rl+9Taz+Pmt/CRbaTI6XepZFyQvk4K/abaGKIAsngVpxKkgFeoJ2IwdRpS228icrig==","shasum":"f5a7852cd66af31d9559a0341b05c5bb83281f03","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.6.0.tgz","fileCount":43,"unpackedSize":563787,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCyVH0wTmVmSXrOuTYmAAgZyacsofUqcc3+9+7XfTEaagIgA1xJywjA3gl9dpSgRd5QJnhpKyFDk+fiDOBhCf0fxWQ="}],"size":423908},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/colorthief_2.6.0_1728501486996_0.42655268552785874"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-10-09T19:18:07.339Z","publish_time":1728501487339,"_source_registry_name":"default","contributors":[]},"2.7.0":{"name":"colorthief","version":"2.7.0","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Get the dominant color or color palette from an image.","keywords":["color","palette","sampling","image","picture","photo","canvas"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","source":"src/color-thief.js","main":"dist/color-thief.js","types":"dist/color-thief-node.d.ts","module":"dist/color-thief.mjs","umd:main":"dist/color-thief.umd.js","amdName":"ColorThief","scripts":{"prepublishOnly":"npm run build","build":"microbundle --no-sourcemap && node ./build/build.js","watch":"microbundle watch --no-sourcemap","dev":"http-server","test":"mocha && cypress run --config video=false","test:browser":"cypress run --headed --browser chrome","test:node":"mocha","cypress":"cypress open"},"devDependencies":{"chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","http-server":"^14.1.1","microbundle":"^0.15.0","mocha":"^10.2.0","mustache":"^3.0.1"},"dependencies":{"@lokesh.dhakar/quantize":"^1.4.0","ndarray-pixels":"^4.1.0","sharp":"^0.33.5"},"gitHead":"b3f8420f0555623ab1710de7af7db685b2706419","_id":"colorthief@2.7.0","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-iOLPi3bzz0ZBLEGEFXhP19/DsT9aVeE8fK4Yfz2efkUiE01G7ku6u5xqYGpOX9Dbs2V1K2t0XvW8sGJFGNa9Nw==","shasum":"0fe51d04c174f65ea9ce0f3add98415fb0901ba3","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-2.7.0.tgz","fileCount":15,"unpackedSize":75880,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIEQJYb0Cv8ucubl9DoGyu/shzSTtmLuWOipKunVLsPDYAiAP52WjZQ0gdYISu40GUMBtNQkvNXwr7op4VEKkdStpHQ=="}],"size":12941},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/colorthief_2.7.0_1772269542348_0.7656478627941807"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-02-28T09:05:42.570Z","publish_time":1772269542570,"_source_registry_name":"default","contributors":[]},"3.0.0":{"name":"colorthief","version":"3.0.0","type":"module","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Extract dominant colors and palettes from images — TypeScript, OKLCH, semantic swatches, live video extraction.","keywords":["color","palette","sampling","image","picture","photo","canvas","oklch","swatch"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","exports":{".":{"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.cjs"}},"./internals":{"import":{"types":"./dist/types/internals.d.ts","default":"./dist/internals.js"},"require":{"types":"./dist/types/internals.d.cts","default":"./dist/internals.cjs"}}},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/types/index.d.ts","scripts":{"prepublishOnly":"npm run build","build":"tsup","watch":"tsup --watch","dev":"http-server","test":"mocha && cypress run --config video=false","test:node":"mocha","test:browser":"cypress run --headed --browser chrome","cypress":"cypress open","typecheck":"tsc --noEmit"},"devDependencies":{"@types/node":"^20.11.0","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","http-server":"^14.1.1","mocha":"^10.2.0","mustache":"^3.0.1","sharp":"^0.34.5","tsup":"^8.0.0","typescript":"^5.3.0"},"peerDependencies":{"sharp":">=0.33.0"},"peerDependenciesMeta":{"sharp":{"optional":true}},"gitHead":"a79371f225cbf5467191b748aa310f3196f04cde","_id":"colorthief@3.0.0","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-trWTnTcTg77Ct+KAT9A0AENTT5RkZin20XOIO4i5w5wq2IAdVsFhrgdm0f58P8cPenp27Rajl6pGy4pkKjaRIg==","shasum":"9e244a47554be3ef2b5f74e047a2fb0e28c9107c","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-3.0.0.tgz","fileCount":39,"unpackedSize":1422410,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIBsgx6HmcAvPzcCG3rVeVxqw5jmYLoJfMjpDQlNptBbmAiBKBIA0LOqLCHqZdAXNzKz81XrNuvSAb5P9s+TuLeWK7Q=="}],"size":338775},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/colorthief_3.0.0_1772426555548_0.36616743507264116"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-03-02T04:42:35.809Z","publish_time":1772426555809,"_source_registry_name":"default","contributors":[]},"3.1.0":{"name":"colorthief","version":"3.1.0","type":"module","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Extract dominant colors and palettes from images — TypeScript, OKLCH, semantic swatches, live video extraction.","keywords":["color","palette","sampling","image","picture","photo","canvas","oklch","swatch"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","exports":{".":{"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.cjs"}},"./internals":{"import":{"types":"./dist/types/internals.d.ts","default":"./dist/internals.js"},"require":{"types":"./dist/types/internals.d.cts","default":"./dist/internals.cjs"}}},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/types/index.d.ts","scripts":{"prepublishOnly":"npm run build","build":"tsup","watch":"tsup --watch","dev":"http-server","test":"mocha && cypress run --config video=false","test:node":"mocha","test:browser":"cypress run --headed --browser chrome","cypress":"cypress open","typecheck":"tsc --noEmit"},"devDependencies":{"@types/node":"^20.11.0","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","http-server":"^14.1.1","mocha":"^10.2.0","mustache":"^3.0.1","sharp":"^0.34.5","tsup":"^8.0.0","typescript":"^5.3.0"},"peerDependencies":{"sharp":">=0.33.0"},"peerDependenciesMeta":{"sharp":{"optional":true}},"gitHead":"f39d44649ada91cdc879e2eeaec1cf4ab742f3e1","_id":"colorthief@3.1.0","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-zyxGopM2rfCTsMwswWjHdEKguuCF6xDgoJfJ/GjTJ7YBNYTm8eNjKn5cWH6YZSKQoSIK0M80ow0px1SUNtuUCA==","shasum":"fff2b24f4523d1e2441015715b79cfe94e94240f","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-3.1.0.tgz","fileCount":39,"unpackedSize":1422425,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIEPkXVI2mFm/00dI8ItOCmz3IUVtaFUHDsnu6Wu0+p4DAiAWXRWsFKOgycZpVF/Ss6qCcgZjy/BrzjG1mBGMNt1MoA=="}],"size":338770},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/colorthief_3.1.0_1772643868841_0.2771794371884886"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-03-04T17:04:29.041Z","publish_time":1772643869041,"_source_registry_name":"default","contributors":[]},"3.2.0":{"name":"colorthief","version":"3.2.0","type":"module","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Extract dominant colors and palettes from images — TypeScript, OKLCH, semantic swatches, live video extraction.","keywords":["color","palette","sampling","image","picture","photo","canvas","oklch","swatch"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","exports":{".":{"browser":{"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.browser.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.browser.cjs"}},"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.cjs"}},"./internals":{"browser":{"import":{"types":"./dist/types/internals.browser.d.ts","default":"./dist/internals.browser.js"},"require":{"types":"./dist/types/internals.browser.d.cts","default":"./dist/internals.browser.cjs"}},"import":{"types":"./dist/types/internals.d.ts","default":"./dist/internals.js"},"require":{"types":"./dist/types/internals.d.cts","default":"./dist/internals.cjs"}}},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/types/index.d.ts","scripts":{"prepublishOnly":"npm run build","build":"tsup","watch":"tsup --watch","dev":"http-server","test":"mocha && cypress run --config video=false","test:node":"mocha","test:browser":"cypress run --headed --browser chrome","cypress":"cypress open","typecheck":"tsc --noEmit"},"devDependencies":{"@types/node":"^20.11.0","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","http-server":"^14.1.1","mocha":"^10.2.0","mustache":"^3.0.1","sharp":"^0.34.5","tsup":"^8.0.0","typescript":"^5.3.0"},"peerDependencies":{"sharp":">=0.33.0"},"peerDependenciesMeta":{"sharp":{"optional":true}},"gitHead":"27fa209631d00f648db51d3520c11ed24c330163","_id":"colorthief@3.2.0","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-pnWNR8cqwUpyvBj7rT2OsoFSL+LU2TYAwtAmqa5jtXe/4Pep2qQSUWKKr4dr/GURCuSoyWG3JMS53hGk4XQftg==","shasum":"e602ae506e52535809e11292808d6bf6dc6ed452","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-3.2.0.tgz","fileCount":52,"unpackedSize":1411625,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIGvCRadiucjg8Nj8id59hJtWWmefayku+z6/qdcfdBZrAiBjNgJ4nNYTFrlC2POzXbVaDWK5CuiUPgWtNKtr2T4GNA=="}],"size":315976},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/colorthief_3.2.0_1772645891994_0.6695448430284798"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-03-04T17:38:12.149Z","publish_time":1772645892149,"_source_registry_name":"default","contributors":[]},"3.3.0":{"name":"colorthief","version":"3.3.0","type":"module","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Extract dominant colors and palettes from images — TypeScript, OKLCH, semantic swatches, live video extraction.","keywords":["color","palette","sampling","image","picture","photo","canvas","oklch","swatch"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","bin":{"colorthief":"dist/cli.js"},"exports":{".":{"browser":{"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.browser.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.browser.cjs"}},"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.cjs"}},"./internals":{"browser":{"import":{"types":"./dist/types/internals.browser.d.ts","default":"./dist/internals.browser.js"},"require":{"types":"./dist/types/internals.browser.d.cts","default":"./dist/internals.browser.cjs"}},"import":{"types":"./dist/types/internals.d.ts","default":"./dist/internals.js"},"require":{"types":"./dist/types/internals.d.cts","default":"./dist/internals.cjs"}}},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/types/index.d.ts","scripts":{"prepublishOnly":"npm run build","build":"tsup","watch":"tsup --watch","dev":"http-server","test":"mocha && cypress run --config video=false","test:node":"mocha","test:browser":"cypress run --headed --browser chrome","cypress":"cypress open","typecheck":"tsc --noEmit"},"devDependencies":{"@types/node":"^20.11.0","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","http-server":"^14.1.1","mocha":"^10.2.0","mustache":"^3.0.1","sharp":"^0.34.5","tsup":"^8.0.0","typescript":"^5.3.0"},"peerDependencies":{"sharp":">=0.33.0"},"peerDependenciesMeta":{"sharp":{"optional":true}},"gitHead":"e1ceaa316d67f9e25f497c0e803ac2672d9d4ee5","_id":"colorthief@3.3.0","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-0hMB8YKZjI5QqLjw2FwN2EQOA8A8GW32TNWUJMdxh+dL3fi6WM1Q1iJK25R4X9d2L6EhV+7ey25CQHTTvMik4Q==","shasum":"175394e63080afc1390014dd7914bbe8f300aa05","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-3.3.0.tgz","fileCount":56,"unpackedSize":1483262,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIGAUqIlMarlNvcFPLQPnowK33NzAa7s3/UO7dURtATSzAiBRi4HZifT2cQ0kB6R7inx7CiIDf9CFHnZ8rtLhOrxwLA=="}],"size":330539},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/colorthief_3.3.0_1772652359276_0.0834242955621094"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-03-04T19:25:59.535Z","publish_time":1772652359535,"_source_registry_name":"default","contributors":[]},"3.3.1":{"name":"colorthief","version":"3.3.1","type":"module","author":{"name":"Lokesh Dhakar","email":"lokesh.dhakar@gmail.com","url":"http://lokeshdhakar.com/"},"description":"Extract dominant colors and palettes from images — TypeScript, OKLCH, semantic swatches, live video extraction.","keywords":["color","palette","sampling","image","picture","photo","canvas","oklch","swatch"],"homepage":"http://lokeshdhakar.com/projects/color-thief/","repository":{"type":"git","url":"git+https://github.com/lokesh/color-thief.git"},"license":"MIT","bin":{"colorthief":"dist/cli.js"},"exports":{".":{"browser":{"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.browser.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.browser.cjs"}},"import":{"types":"./dist/types/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/types/index.d.cts","default":"./dist/index.cjs"}},"./internals":{"browser":{"import":{"types":"./dist/types/internals.browser.d.ts","default":"./dist/internals.browser.js"},"require":{"types":"./dist/types/internals.browser.d.cts","default":"./dist/internals.browser.cjs"}},"import":{"types":"./dist/types/internals.d.ts","default":"./dist/internals.js"},"require":{"types":"./dist/types/internals.d.cts","default":"./dist/internals.cjs"}},"./cli":{"import":"./dist/cli.js"}},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/types/index.d.ts","scripts":{"prepublishOnly":"npm run build","build":"tsup","watch":"tsup --watch","dev":"http-server","test":"mocha && cypress run --config video=false","test:node":"mocha","test:browser":"cypress run --headed --browser chrome","cypress":"cypress open","typecheck":"tsc --noEmit"},"devDependencies":{"@types/node":"^20.11.0","chai":"^4.2.0","chai-as-promised":"^7.1.1","cypress":"^13.15.0","http-server":"^14.1.1","mocha":"^10.2.0","mustache":"^3.0.1","sharp":"^0.34.5","tsup":"^8.0.0","typescript":"^5.3.0"},"peerDependencies":{"sharp":">=0.33.0"},"peerDependenciesMeta":{"sharp":{"optional":true}},"gitHead":"01dc0f3a8759226e91f767a6ec9deaa622ba8931","_id":"colorthief@3.3.1","bugs":{"url":"https://github.com/lokesh/color-thief/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-a3qzYXy51h6p3725pV8rnJwUBGTtvYQge2pVhKJwL+vETUD5pCi6VKmQyu51pBHdUbu/BPEXbwFLS0GnxXNhGA==","shasum":"99cf41dfe70168e67e9d877a7a6f0f161a27c08e","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/colorthief/-/colorthief-3.3.1.tgz","fileCount":56,"unpackedSize":1483754,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIFdJxuBepfNvlrEMcbtIx4UPhLRHVEIMbGvG2zcGanUZAiEAwfaKe6pjV7oJmwQPkrORruLJuGkzd+edKq6e18SMjA0="}],"size":330735},"_npmUser":{"name":"anonymous","email":"lokesh.dhakar@gmail.com"},"directories":{},"maintainers":[{"name":"anonymous","email":"lokesh.dhakar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/colorthief_3.3.1_1772781971924_0.9268639132423073"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-03-06T07:26:12.150Z","publish_time":1772781972150,"_source_registry_name":"default","contributors":[]}},"dist-tags":{"latest":"3.3.1"},"name":"colorthief","time":{"created":"2022-01-27T09:36:10.779Z","modified":"2026-03-06T07:26:26.868Z","2.3.2":"2020-07-06T04:32:18.763Z","2.3.1":"2020-07-06T02:42:18.229Z","2.3.0":"2019-08-04T15:56:28.606Z","2.2.1":"2019-07-22T14:37:31.937Z","2.2.0":"2019-07-15T03:14:10.812Z","2.1.0":"2019-07-14T16:47:20.695Z","2.0.2":"2017-11-27T02:36:08.549Z","2.4.0":"2023-02-28T22:13:54.690Z","2.6.0":"2024-10-09T19:18:07.339Z","2.7.0":"2026-02-28T09:05:42.570Z","3.0.0":"2026-03-02T04:42:35.809Z","3.1.0":"2026-03-04T17:04:29.041Z","3.2.0":"2026-03-04T17:38:12.149Z","3.3.0":"2026-03-04T19:25:59.535Z","3.3.1":"2026-03-06T07:26:12.150Z"},"readme":"# Color Thief\n\n> Extract dominant colors and palettes from images in the browser and Node.js.\n\n[![npm version](https://img.shields.io/npm/v/colorthief)](https://www.npmjs.com/package/colorthief)\n[![npm bundle size](https://img.shields.io/bundlephobia/minzip/colorthief)](https://bundlephobia.com/package/colorthief)\n[![types](https://img.shields.io/npm/types/colorthief)](https://www.npmjs.com/package/colorthief)\n\n## Install\n\n```bash\nnpm install colorthief\n```\n\nOr load directly from a CDN:\n\n```html\n<script src=\"https://unpkg.com/colorthief@3/dist/umd/color-thief.global.js\"></script>\n```\n\n## Quick Start\n\n```js\nimport { getColorSync, getPaletteSync, getSwatches } from 'colorthief';\n\n// Dominant color\nconst color = getColorSync(img);\ncolor.hex();      // '#e84393'\ncolor.css();      // 'rgb(232, 67, 147)'\ncolor.isDark;     // false\ncolor.textColor;  // '#000000'\n\n// Palette\nconst palette = getPaletteSync(img, { colorCount: 6 });\npalette.forEach(c => console.log(c.hex()));\n\n// Semantic swatches (Vibrant, Muted, DarkVibrant, etc.)\nconst swatches = await getSwatches(img);\nswatches.Vibrant?.color.hex();\n```\n\n## Features\n\n- **TypeScript** — full type definitions included\n- **Browser + Node.js** — same API, both platforms\n- **Sync & async** — synchronous browser API, async for Node.js and Web Workers\n- **Live extraction** — `observe()` watches video, canvas, or img elements and emits palette updates reactively\n- **Web Workers** — offload quantization off the main thread with `worker: true`\n- **Progressive extraction** — 3-pass refinement for instant rough results\n- **OKLCH quantization** — perceptually uniform palettes via `colorSpace: 'oklch'`\n- **Semantic swatches** — Vibrant, Muted, DarkVibrant, DarkMuted, LightVibrant, LightMuted\n- **Rich Color objects** — `.hex()`, `.rgb()`, `.hsl()`, `.oklch()`, `.css()`, contrast ratios, text color recommendations\n- **WCAG contrast** — `color.contrast.white`, `color.contrast.black`, `color.contrast.foreground`\n- **AbortSignal** — cancel in-flight extractions\n- **CLI** — `colorthief photo.jpg` with JSON, CSS, and ANSI output\n- **Zero runtime dependencies**\n\n## API at a Glance\n\n| Function | Description |\n|---|---|\n| `getColorSync(source, options?)` | Dominant color (sync, browser only) |\n| `getPaletteSync(source, options?)` | Color palette (sync, browser only) |\n| `getSwatchesSync(source, options?)` | Semantic swatches (sync, browser only) |\n| `getColor(source, options?)` | Dominant color (async, browser + Node.js) |\n| `getPalette(source, options?)` | Color palette (async, browser + Node.js) |\n| `getSwatches(source, options?)` | Semantic swatches (async, browser + Node.js) |\n| `getPaletteProgressive(source, options?)` | 3-pass progressive palette (async generator) |\n| `observe(source, options)` | Watch a source and emit palette updates (browser only) |\n| `createColor(r, g, b, population)` | Build a Color object from RGB values |\n\n### Options\n\n| Option | Default | Description |\n|---|---|---|\n| `colorCount` | `10` | Number of palette colors (2–20) |\n| `quality` | `10` | Sampling rate (1 = every pixel, 10 = every 10th) |\n| `colorSpace` | `'oklch'` | Quantization space: `'rgb'` or `'oklch'` |\n| `worker` | `false` | Offload to Web Worker (browser only) |\n| `signal` | — | `AbortSignal` to cancel extraction |\n| `ignoreWhite` | `true` | Skip white pixels |\n\n### Color Object\n\n| Property / Method | Returns |\n|---|---|\n| `.rgb()` | `{ r, g, b }` |\n| `.hex()` | `'#ff8000'` |\n| `.hsl()` | `{ h, s, l }` |\n| `.oklch()` | `{ l, c, h }` |\n| `.css(format?)` | `'rgb(255, 128, 0)'`, `'hsl(…)'`, or `'oklch(…)'` |\n| `.array()` | `[r, g, b]` |\n| `.toString()` | Hex string (works in template literals) |\n| `.textColor` | `'#ffffff'` or `'#000000'` |\n| `.isDark` / `.isLight` | Boolean |\n| `.contrast` | `{ white, black, foreground }` — WCAG ratios |\n| `.population` | Raw pixel count |\n| `.proportion` | 0–1 share of total |\n\n## Browser\n\n```js\nimport { getColorSync, getPaletteSync } from 'colorthief';\n\nconst img = document.querySelector('img');\nconst color = getColorSync(img);\nconsole.log(color.hex());\n\nconst palette = getPaletteSync(img, { colorCount: 5 });\n```\n\nAccepts `HTMLImageElement`, `HTMLCanvasElement`, `HTMLVideoElement`, `ImageData`, `ImageBitmap`, and `OffscreenCanvas`.\n\n### Live extraction with observe()\n\n```js\nimport { observe } from 'colorthief';\n\n// Watch a video and update ambient lighting as it plays\nconst controller = observe(videoElement, {\n    throttle: 200,    // ms between updates\n    colorCount: 5,\n    onChange(palette) {\n        updateAmbientBackground(palette);\n    },\n});\n\n// Stop when done\ncontroller.stop();\n```\n\nWorks with `<video>`, `<canvas>`, and `<img>` elements. For images, it uses a MutationObserver to detect `src` changes. For video and canvas, it polls using requestAnimationFrame with throttle.\n\n## Node.js\n\n```js\nimport { getColor, getPalette } from 'colorthief';\n\nconst color = await getColor('/path/to/image.jpg');\nconsole.log(color.hex());\n\nconst palette = await getPalette(Buffer.from(data), { colorCount: 5 });\n```\n\nAccepts file paths and Buffers. Uses [sharp](https://sharp.pixelplumbing.com/) for image decoding.\n\n## CLI\n\n### Quick start\n\n```bash\nnpx colorthief-cli photo.jpg\n```\n\nThe `colorthief-cli` package bundles everything needed (including sharp for image\ndecoding), so it works immediately with no extra setup.\n\n### Commands\n\n```bash\n# Dominant color\ncolorthief-cli photo.jpg\n\n# Color palette\ncolorthief-cli palette photo.jpg\n\n# Semantic swatches\ncolorthief-cli swatches photo.jpg\n```\n\n### Output formats\n\n```bash\n# Default: ANSI color swatches\ncolorthief-cli photo.jpg\n# ▇▇ #e84393\n\n# JSON with full color data\ncolorthief-cli photo.jpg --json\n\n# CSS custom properties\ncolorthief-cli palette photo.jpg --css\n# :root {\n#     --color-1: #e84393;\n#     --color-2: #6c5ce7;\n# }\n```\n\n### Options\n\n```bash\ncolorthief-cli palette photo.jpg --count 5        # Number of colors (2-20)\ncolorthief-cli photo.jpg --quality 1              # Sampling quality (1=best)\ncolorthief-cli photo.jpg --color-space rgb        # Color space (rgb or oklch)\n```\n\nStdin is supported — use `-` or pipe directly:\n\n```bash\ncat photo.jpg | colorthief-cli -\n```\n\nMultiple files are supported. Output is prefixed with filenames, and `--json` wraps\nresults in an object keyed by filename.\n\n> **Note:** If you already have `colorthief` and `sharp` installed in a project, you\n> can also use `colorthief` directly as the command name (without the `-cli` suffix).\n\n## Links\n\n- [Demo page & live examples](https://lokeshdhakar.com/projects/color-thief/)\n- [GitHub](https://github.com/lokesh/color-thief)\n- [npm](https://www.npmjs.com/package/colorthief)\n\n## Contributing\n\n```bash\nnpm run build          # Build all dist formats\nnpm run test           # Run all tests (Mocha + Cypress)\nnpm run test:node      # Node tests only\nnpm run test:browser   # Browser tests (requires npm run dev)\nnpm run dev            # Start local server on port 8080\n```\n\n## Releasing\n\n```bash\n# 1. Make sure you're on master with a clean working tree\ngit status\n\n# 2. Run the full test suite\nnpm run build\nnpm run test:node\nnpm run test:browser   # requires npm run dev in another terminal\n\n# 3. Preview what will be published\nnpm pack --dry-run\n\n# 4. Tag and publish\nnpm version <major|minor|patch>   # bumps version, creates git tag\nnpm publish                       # builds via prepublishOnly, then publishes\ngit push && git push --tags\n```\n\n## License\n\n[MIT](LICENSE) - Lokesh Dhakar","users":{}}