{"_id":"@alexseitsinger/previewable-image","_rev":"2-60a0a954f1782afde7ae5ed2cec9ed8e","name":"@alexseitsinger/previewable-image","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@alexseitsinger/previewable-image","version":"0.1.0","description":"An input file field that automatically renders a preview of the image file loaded.","main":"dist/main.js","homepage":"https://github.com/alexseitsinger/previewable-image#readme","author":{"name":"Alex Seitsinger","email":"alexseitsinger@gmail.com","url":"https://www.alexseitsinger.com"},"license":"BSD-2-Clause","repository":{"type":"git","url":"https://github.com/alexseitsinger/previewable-image.git"},"devDependencies":{"babel-core":"^6.26.3","babel-jest":"^23.6.0","babel-loader":"^7.1.5","babel-plugin-emotion":"^9.2.10","babel-plugin-transform-react-remove-prop-types":"^0.4.13","babel-preset-env":"^1.7.0","babel-preset-react":"^6.24.1","babel-preset-stage-0":"^6.24.1","enzyme":"^3.7.0","enzyme-adapter-react-16":"^1.6.0","jest":"^23.6.0","react-dom":"^16.6.1","react-emotion":"^9.2.10","webpack":"^4.16.1","webpack-cli":"^3.1.0","emotion":"^9.2.10"},"dependencies":{"prop-types":"^15.6.2","react":"^16.4.1"},"scripts":{"build":"./node_modules/.bin/webpack --config=webpack.config.js","test":"./node_modules/.bin/jest test"},"_id":"@alexseitsinger/previewable-image@0.1.0","dist":{"shasum":"df2d4172e82d338694bc0859e255db3986611a86","tarball":"https://registry.npmjs.org/@alexseitsinger/previewable-image/-/previewable-image-0.1.0.tgz","integrity":"sha512-UilKOhaBHMpRqIATXvFTXng9tLfGFy6G8gBrxKieHCt11eC6EUh7T8j5betc/PnUL4Ab5UqRz0pwVv4YCi4xew==","fileCount":5,"unpackedSize":38019,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJb9HpACRA9TVsSAnZWagAAKdMP/0K45Hbvo/UCT4fMpFYs\niKScy1T5GaqXE4l+sB89PvF6OLElmCgh2sbRQIHCupnhEJXb7wENrA3SDP8x\nR2tfT965k589h+sz47ItVlfRADjKqwMWo2eWQk9a6gK5AmmFB4KEdOc+59/E\nG3nNxTX8bCTyw57bkwNqa01qcz1QdVw67QlVPZHXoUj5Y0GE1hflBjyOMFoa\ns1331oVjJHoXbRWAkfGq+GcauZvjDEdIjIl4BdP2Bciex52LVLXGSZ7DL8cD\nQBSCqNhRRGD4w3N08csLFd2XvIsyZIts9+X3y/f/IixunMjxx6VyhzyZuWKc\nIcpMxBbWGQUrTFRZlwt61dpzTCCe+RbagE/QC6P9SYMNOMKIUmKdgTb19Gu8\ntg6as+FVj2RkIlrhCsotzK43XwbpHyO2TqMPqHt1sBDJFwFTquI9PN91MLZh\nyA0FKWPux8UqSJvvQ4zJ5whXPDlNwFGoWhjaA/79e/KLgn++xW9FSQdvCkcA\nhFVUlamW5q1SjF0QyjS3HsStVZN3qp+fobeCqOlVA++Am/TTeRuP6+kyysWu\nyhWfgLOfW8RzE6/jc0/akf4IIIOthzSQW8n2W+mC02ALksetabbLEEFeAX/u\nOiXFqQgV3HhnJPLFw30TVWdmkKswlAf1tNTc/YmUNLsmdDtAFaYFhk1u4XW/\ncnwG\r\n=Bl7z\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCXt4yiZfRE+pe02qF8GLwvUqCRDe0y2Y80yZPu/CYL/wIhAJ7KPp37dQ6zmqBkQ/xYqGK7IsSNwsrZU4kWxCrZC98U"}]},"maintainers":[{"name":"alexseitsinger","email":"alexseitsinger@gmail.com"}],"_npmUser":{"name":"alexseitsinger","email":"alexseitsinger@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/previewable-image_0.1.0_1542748735412_0.5111479676947108"},"_hasShrinkwrap":false},"0.1.1":{"name":"@alexseitsinger/previewable-image","version":"0.1.1","description":"An input file field that automatically renders a preview of the image file loaded.","main":"dist/main.js","homepage":"https://github.com/alexseitsinger/previewable-image#readme","author":{"name":"Alex Seitsinger","email":"alexseitsinger@gmail.com","url":"https://www.alexseitsinger.com"},"license":"BSD-2-Clause","repository":{"type":"git","url":"https://github.com/alexseitsinger/previewable-image.git"},"devDependencies":{"@babel/core":"^7.2.2","@babel/plugin-proposal-class-properties":"^7.2.3","@babel/preset-env":"^7.2.3","@babel/preset-react":"^7.0.0","babel-core":"^7.0.0-bridge.0","babel-jest":"^23.6.0","babel-loader":"^8.0.4","babel-plugin-emotion":"^10.0.5","enzyme":"^3.8.0","enzyme-adapter-react-16":"^1.7.1","jest":"^23.6.0","webpack":"^4.28.3","webpack-cli":"^3.1.0"},"dependencies":{"@emotion/core":"^10.0.5","@emotion/styled":"^10.0.5","prop-types":"^15.6.2","react":"^16.7.0","react-dom":"^16.7.0"},"scripts":{"build":"./node_modules/.bin/webpack --config=webpack.config.js","test":"./node_modules/.bin/jest test"},"_id":"@alexseitsinger/previewable-image@0.1.1","dist":{"shasum":"3165f7221852898d8dc8238df478ff2794400d27","integrity":"sha512-yePlPPb+73uPceTP5MvPpaX7wLH8q0uvTx24sQgqG323db+93ew74tRz/YmdAFWFAYk/937DirYwxwPP5e/CBA==","tarball":"https://registry.npmjs.org/@alexseitsinger/previewable-image/-/previewable-image-0.1.1.tgz","fileCount":5,"unpackedSize":39629,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcLSF1CRA9TVsSAnZWagAABOQP/0sL5Hv6yeqdaFVmjAx/\nYCr8yncwBu4FB7NUAbzmijyH6gygrXu9R84mlCfXQwK9YeVdoraQLrJU0+Op\n9lVFHvQju1O/Wrhnu2+VhxHqX792+YpIt+GSdgi5HtPA16Tq4vsdvpTgvLHu\nkh0cQgIPoikyFfDba7pp0hLbTM5W6442jEzTQuqO1WmfxNw12zYA/a+AcgKl\nfqmsG1klMUMb579j8gmGcZa5lFTI/qczs4x/axn2Ua14i8S6xg0Ec5DF8C7E\nb25mlg+6W35fTKQ0VE9pxtoaVCpGXid/CY0OmvJnRB+L3F3D7PNlxredqU+/\n7WmHi9honlcBs7StWPThABOEyujncmZcKwc7+n7sigJfzfzodBxpOFGc8P6E\nk/zRMingWnwWscciT4xK9vsMWoIEtcEIUumQAntHJZAbngeprPxX10G2rq/K\nkAyG+FTT8X4GBZjvEHY51RPukI0hjOz63b8D/qR0DLHx1GvIhi+bIAiJ2GNO\nnb+J8vGEV5MUPGDtz5DEVP6yvxxSHTgpk2edxDXN+VScL4H82CqVJSQO57s+\nHdK6DDYzKDELU1QugozvWEBXc2kR8QUdS5fVK95hzL3mNSQ0TKuhRu6IeGCx\n3HSo3a76LqmTnGNwajha4/Hmak2Gsx7tcmoyvF9xLyHaZ6ZCM5LJNbbMbCOo\nRfPO\r\n=dcpO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFIQLuODgvfYtseS3Sc40izX6qBR2Ro43FDGTu3yM9WXAiEA2+5lKxV61jMAkEd3OpsXdd2Lhv76o0NO8FG+16kcb64="}]},"maintainers":[{"name":"alexseitsinger","email":"alexseitsinger@gmail.com"}],"_npmUser":{"name":"alexseitsinger","email":"alexseitsinger@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/previewable-image_0.1.1_1546461557066_0.3303791884544198"},"_hasShrinkwrap":false}},"time":{"created":"2018-11-20T21:18:55.227Z","0.1.0":"2018-11-20T21:18:55.562Z","modified":"2022-04-04T12:41:35.651Z","0.1.1":"2019-01-02T20:39:17.189Z"},"maintainers":[{"name":"alexseitsinger","email":"alexseitsinger@gmail.com"}],"description":"An input file field that automatically renders a preview of the image file loaded.","homepage":"https://github.com/alexseitsinger/previewable-image#readme","repository":{"type":"git","url":"https://github.com/alexseitsinger/previewable-image.git"},"author":{"name":"Alex Seitsinger","email":"alexseitsinger@gmail.com","url":"https://www.alexseitsinger.com"},"license":"BSD-2-Clause","readme":"<!-- Generated by documentation.js. Update this documentation by updating the source code. -->\n\n## PreviewableImage\n\n**Extends React.Component**\n\nA file input that automatically displays the image file its given.\n\n### Parameters\n\n-   `name` **[String][1]** The name of the file input (optional, default `\"image\"`)\n-   `onLoaded` **[Function][2]** The function to invoke when the file is loaded by the browser (optional, default `()=>{}`)\n-   `containerClassName` **[String][1]** The classname to use for the container element. (optional, default `\"PreviewableImage\"`)\n-   `containerHeight` **[Number][3]** The height to use for the image. (optional, default `200`)\n-   `containerWidth` **[Number][3]** The width to use for the image. (optional, default `200`)\n-   `alt` **[String][1]** The alternative string to use for the image. (optional, default `\"\"`)\n-   `initialImage` **[String][1]** The path to an image to display before anything is loaded. (optional, default `\"\"`)\n-   `fallbackImage` **[String][1]** The path to an image to display as a fallback. (optional, default `\"\"`)\n-   `withResetButton` **[Boolean][4]** Whether or not to use a reset button when the image preview is displayed. (optional, default `true`)\n-   `resetButtonStyle` **[Object][5]** The style to apply to the reset button. (optional, default `{}`)\n-   `resetButtonBody` **([Object][5] \\| [String][1])** The node to render inside the reset button. (optional, default `\"reset\"`)\n\n### Examples\n\n```javascript\nimport React from \"react\"\nimport PreviewableImage from \"@alexseitsinger/previewable-image\"\n\nfunction ExampleComponent({ onCompleted }){\n  return (\n  \t <Form\n  \t   onSubmit={(event) => {\n  \t     event.preventDefault()\n  \t     event.stopPropagation()\n  \t     const form = event.target\n  \t     const imageField = form.querySelector(\"input[name=image]\")\n  \t     onCompleted(imageField.files[0])\n  \t   }}>\n      <PreviewableImage/>\n      <SubmitButton>\n        Submit\n      </SubmitButton>\n    </Form>\n  )\n}\n```\n\n[1]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String\n\n[2]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function\n\n[3]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number\n\n[4]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Boolean\n\n[5]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object\n","readmeFilename":"README.md"}