{"_id":"@ads.silva/png-js","name":"@ads.silva/png-js","dist-tags":{"latest":"2.1.0"},"versions":{"2.1.0":{"name":"@ads.silva/png-js","description":"A PNG decoder in JS","version":"2.1.0","main":"./lib/png-js.cjs.js","module":"./lib/png-js.es.js","browser":{"./lib/png-js.es.js":"./lib/png-js.browser.es.js","./lib/png-js.cjs.js":"./lib/png-js.browser.cjs.js"},"repository":{"type":"git","url":"git+https://github.com/diegomura/react-pdf.git","directory":"packages/png-js"},"author":{"name":"Devon Govett","email":"devongovett@gmail.com","url":"http://badassjs.com/"},"scripts":{"build":"rimraf ./lib && rollup -c","watch":"rimraf ./lib && rollup -c -w"},"dependencies":{"browserify-zlib":"^0.2.0"},"gitHead":"f207c177650d9109b80b2983434fa3741ac485f9","bugs":{"url":"https://github.com/diegomura/react-pdf/issues"},"homepage":"https://github.com/diegomura/react-pdf#readme","_id":"@ads.silva/png-js@2.1.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-j/xYGlUO/JlpbwwA2FbAM7FhqQQaTgc2IliiWyvb3dbA2Cj64IpBQRsxkRcRDdql8oMF5Y1r78Z0yt5lQP0NJQ==","shasum":"5b64af74d8d8afb6b2e84c2f7056ce2ef36047f4","tarball":"https://registry.npmjs.org/@ads.silva/png-js/-/png-js-2.1.0.tgz","fileCount":7,"unpackedSize":1166048,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAizxS6n37fY/qg2sftGhhSS00s7bmU9imb70EQ31xjOAiEA0Ub+Wt09Co54kLLpi7imFTpSIyyzXk7SkGTkyP3Pk1w="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi9V75ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoJOQ//QvKvUiy1QFZ5ECFdshSMkBrLhb2ZZ1jQ8pBcJPTRTFpaekBm\r\nnwQlK//GlOJ2RTAlcbmFB0DLbUpKSi/lz2cd7+/qoFlqWo54WMadkvQU1WEv\r\n4rd5pnKBDtp4N4mUljFYUsK1v83vZiURnEX3L+sjjjR/kXMiIB4imoMw26nl\r\nJEVFQzfS0XhhDgoja5hfw9jz4qMscBu5OVKWYOgTarsQde4RCn/lW5rF0LVm\r\nHJ2Fk+UOCSw0baOanTLabGp3QKnx7bhHoKipb3UhdASJqQjwp12cxnue47Dg\r\nxgyIfpwKSy29YOR0iy3ByaKuZNz3gD2NU3yaKVi/VeJsIkAHCws8GAzolSRs\r\nK6UeLUebnqamsaCXveQ5tj4tHTFe8W+agLEMlQq5pvovfOReF6PsY0tarn5X\r\nSlqAKnzp96DKFqZouw+DN7WxqeVmaqqyCuiGaCXoHbnEI9dP95zJbp+86nI1\r\n87vO6Ku82wkEGyTOppYoEZwp8sY6W/Dj2CUh1AX0UaB5FiN/O3N6FhQIqw36\r\nv/p1NBVx9hSRbXGx5zcdh1Czp2WoPP9GQ8GSlSRxeumD0V3h3nwgFJKRhGHD\r\n1r5MGEJ/qd5z82mq/cF7YrEXHa6BGRYprpcsp2EgoXK6KF+wastzFrsaxVP1\r\nARs3mEtfnAYOaPIOFmneSLf/UVgBwr6Kek4=\r\n=Wd9l\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"ads.silva","email":"dautodroid@gmail.com"},"directories":{},"maintainers":[{"name":"ads.silva","email":"dautodroid@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/png-js_2.1.0_1660247800881_0.6283771782080041"},"_hasShrinkwrap":false}},"time":{"created":"2022-08-11T19:56:40.829Z","2.1.0":"2022-08-11T19:56:41.139Z","modified":"2022-08-11T19:56:41.295Z"},"maintainers":[{"name":"ads.silva","email":"dautodroid@gmail.com"}],"description":"A PNG decoder in JS","homepage":"https://github.com/diegomura/react-pdf#readme","repository":{"type":"git","url":"git+https://github.com/diegomura/react-pdf.git","directory":"packages/png-js"},"author":{"name":"Devon Govett","email":"devongovett@gmail.com","url":"http://badassjs.com/"},"bugs":{"url":"https://github.com/diegomura/react-pdf/issues"},"readme":"<p align=\"center\">\n  <img src=\"https://user-images.githubusercontent.com/5600341/27505816-c8bc37aa-587f-11e7-9a86-08a2d081a8b9.png\" height=\"280px\">\n</p>\n\n# @ads.silva/png-js\n\nA PNG decoder in JS for the canvas element or Node.js.\n\n## Acknowledges\n\nThis project is a fork of [png.js](https://github.com/foliojs/png.js) by @devongovett and continued under the scope of this project since it has react-pdf specific features. Any recongnition should go to him and the original project mantainers.\n\n## About this fork\n\n> Updated to 977b857a11676c1e720e79ed8d9178a005a9abd6\n\n- Build node and browser specific bundles\n- Uses rollup for build\n## Browser Usage\n\nSimply include png.js and zlib.js on your HTML page, create a canvas element, and call PNG.load to load an image.\n\n    <canvas></canvas>\n    <script src=\"zlib.js\"></script>\n    <script src=\"png.js\"></script>\n    <script>\n        var canvas = document.getElementsByTagName('canvas')[0];\n        PNG.load('some.png', canvas);\n    </script>\n\nThe source code for the browser version resides in `png.js` and also supports loading and displaying animated PNGs.\n\n## Node.js Usage\n\nInstall the module using npm\n\n    sudo npm install png-js\n\nRequire the module and decode a PNG\n\n    var PNG = require('png-js');\n    PNG.decode('some.png', function(pixels) {\n        // pixels is a 1d array (in rgba order) of decoded pixel data\n    });\n\nYou can also call `PNG.load` if you want to load the PNG (but not decode the pixels) synchronously.  If you already\nhave the PNG data in a buffer, simply use `new PNG(buffer)`.  In both of these cases, you need to call `png.decode`\nyourself which passes your callback the decoded pixels as a buffer.  If you already have a buffer you want the pixels\ncopied to, call `copyToImageData` with your buffer and the decoded pixels as returned from `decodePixels`.\n","readmeFilename":"README.md"}