{"versions":{"2.0.1":{"name":"@migrate-to-esm/clipboard","version":"2.0.1","description":"Modern copy to clipboard. No Flash. Just 2kb","repository":{"type":"git","url":"git+https://github.com/zenorocha/clipboard.js.git"},"license":"MIT","main":"dist/clipboard.js","module":"src/clipboard.js","keywords":["clipboard","copy","cut"],"dependencies":{"@migrate-to-esm/good-listener":"^1.2.2","@migrate-to-esm/select":"^1.1.2","tiny-emitter":"^2.0.0"},"devDependencies":{"babel-cli":"^6.5.1","babel-core":"^6.5.2","babel-loader":"^6.2.10","babel-plugin-transform-es2015-modules-umd":"^6.5.0","babel-preset-es2015":"^6.5.0","chai":"^3.4.1","cross-env":"^3.1.4","karma":"^1.3.0","karma-chai":"^0.1.0","karma-mocha":"^1.2.0","karma-phantomjs-launcher":"^1.0.0","karma-sinon":"^1.0.4","karma-webpack":"^2.0.2","mocha":"^3.1.2","phantomjs-prebuilt":"^2.1.4","sinon":"^1.17.2","webpack":"^2.2.1"},"scripts":{"build":"npm run build-debug && npm run build-min","build-debug":"webpack","build-min":"cross-env NODE_ENV=production webpack --optimize-minimize","build-watch":"webpack --watch","test":"karma start --single-run","prepublish":"npm run build"},"gitHead":"cf569a62d0db6ab67490f4f68e09ce0d6023fdc7","bugs":{"url":"https://github.com/zenorocha/clipboard.js/issues"},"homepage":"https://github.com/zenorocha/clipboard.js#readme","_id":"@migrate-to-esm/clipboard@2.0.1","_npmVersion":"6.4.1","_nodeVersion":"8.12.0","_npmUser":{"name":"anonymous","email":"horacio.gonzalez@gmail.com"},"dist":{"integrity":"sha512-KYx+HUvWd/mCH8kd1AeXxnXg69LJqY8Ef+Fn627J1+FNlaO7YM5BoVvcU1yTJLHkMu1wOten7wj8zCKX5D6Zfg==","shasum":"409f3c474b4217f0f56bba270e6eb351a2f362e3","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/@migrate-to-esm/clipboard/-/clipboard-2.0.1.tgz","fileCount":10,"unpackedSize":64844,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJb4S1RCRA9TVsSAnZWagAAIH0P/2aLMW7rGjot5fjNwQPf\n5jvsIDfzcutKOnng4lbej+MwxfKgZ8XJH3F+RQUY5NNAS/H+qYXcUfuZeOBc\nXmcRMlNF9NMo/tTSTE/PfI1HMJIIRiBENAcAPcQhtVzpNEfL9ZbpFaxm6Nj1\n0XmXCIAGuxerfb1FTN++Ae+R8CpStoCv0NyayoTQHGUbQIEfka/N0/svK+6x\nUDvphwo+Iiha9xITEennixHfNWkBzCdmqnvrBcKHRCjl+N2Uf26qgUy7Gnme\nn/+OABxHlVlx78eLasbECto2xKYW68wmh75dz8gR5a/Z3ugJCP7/+omJENzB\n167tDx8zQaywltVraqEDjHDuBJlMOAjmksJuB/yo7iuc2xHuUNWJLnJqeFaQ\n2JYKivqRS/aQ4nV5IwBtpzADXpAgrgabGQ2qXOJDiArAaf6LlsqIaMsrkrjL\nLRFFEegfOn3GwTPtKL+pxhhaxk5GA5fkuvjPxZ1bxt43lk5Zm2c0vqo/0fI9\nv67xOmBiDxJasu++fpNDiZ59lkfLgibFAYo5x5ZxBC6yWHGoZ7kfmIhnXsls\nJZsMKgsrS97c8LDfEl7f3qNdFUIOewSsDE2uPNdJhzKJMkmPT4vibjJKfIXY\nX/8dca+d91Wh4X2/tzc83Qeq8uMUjPjTQUzO/OgirUysljzIRsEMQjpieM3K\nNJzH\r\n=cg/W\r\n-----END PGP SIGNATURE-----\r\n","size":16219},"maintainers":[{"name":"anonymous","email":"horacio.gonzalez@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/clipboard_2.0.1_1541483856834_0.7319661526529351"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2021-12-24T20:34:13.554Z","contributors":[]},"2.0.1-1":{"name":"@migrate-to-esm/clipboard","version":"2.0.1-1","description":"Modern copy to clipboard. No Flash. Just 2kb","repository":{"type":"git","url":"git+https://github.com/zenorocha/clipboard.js.git"},"license":"MIT","main":"dist/clipboard.js","module":"src/clipboard.js","keywords":["clipboard","copy","cut"],"dependencies":{"@migrate-to-esm/good-listener":"^1.2.2","@migrate-to-esm/select":"^1.1.2","@migrate-to-esm/tiny-emitter":"^2.0.2"},"devDependencies":{"babel-cli":"^6.5.1","babel-core":"^6.5.2","babel-loader":"^6.2.10","babel-plugin-transform-es2015-modules-umd":"^6.5.0","babel-preset-es2015":"^6.5.0","chai":"^3.4.1","cross-env":"^3.1.4","karma":"^1.3.0","karma-chai":"^0.1.0","karma-mocha":"^1.2.0","karma-phantomjs-launcher":"^1.0.0","karma-sinon":"^1.0.4","karma-webpack":"^2.0.2","mocha":"^3.1.2","phantomjs-prebuilt":"^2.1.4","sinon":"^1.17.2","webpack":"^2.2.1"},"scripts":{"build":"npm run build-debug && npm run build-min","build-debug":"webpack","build-min":"cross-env NODE_ENV=production webpack --optimize-minimize","build-watch":"webpack --watch","test":"karma start --single-run","prepublish":"npm run build"},"gitHead":"87cab7dfb6297e51547789c48268ee3ed01dfbcb","bugs":{"url":"https://github.com/zenorocha/clipboard.js/issues"},"homepage":"https://github.com/zenorocha/clipboard.js#readme","_id":"@migrate-to-esm/clipboard@2.0.1-1","_npmVersion":"6.4.1","_nodeVersion":"8.12.0","_npmUser":{"name":"anonymous","email":"horacio.gonzalez@gmail.com"},"dist":{"integrity":"sha512-t6UrssHhmEbWwWfMuLnMkp76HQtOTplr1paHLtuFnBsuJzixP5MBEuGUrm2C20+wE5aD8nuLoB7TLmuF6eVoOQ==","shasum":"fe2b3f1cbd9cc7231996ad541b3a543a7222a86c","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/@migrate-to-esm/clipboard/-/clipboard-2.0.1-1.tgz","fileCount":10,"unpackedSize":65130,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJb4T2NCRA9TVsSAnZWagAArNAP/2GOFBmIFweq8PwfUAed\n8xPXlgy9D6RSROu+R9itLZDCO3Je9eB2jMu4YVgV+3gW81Iim7Vc4MQTU7Fg\nwEgRjvfCi8ORdetkUpsEV3iSUMs0NYz5lro9oQsKtLqCX7WY6f1lLgvwHOmE\nzV/2EsTL6s7o8G9pPIzLmfXtF8rV9TnBJI0F16lzdmIEQ4bKvb9ll7g/eow9\n0XOvR/bjJ+6NhTZWWfbT4xjXEELPVEc+/llI+c0UA5o7pPsVh7zAzmNpfiEa\niH0a96y/RcTv67KyOCJPcMac+Xdz6lS6O8XtF5ZjFyFm7t7Xa8rYFrEf9tOf\nRgGfZX+Vpp8OLpkoInZza+Cwmeo6jABdvWfCG+GYzrT07RewHpPGD+a9vmqb\nFsIPVncqZARB7+sDJqRtHokdG0I4saPblFUxWS5ROjWFt2kGgJxIuDS2LAXd\nJZ3Wl6j9zlJhv36t81HHWon4hD4tCFyFcRtHpMejMCWdGR6pKQ0iLpkZVbgc\nGQRdJI0Lp2BT0VuUQunSmcML5adB4TpaVqBJHs3fO43qEpvFI/DN5soRDw4j\nrLpZRMsODN0az09qn1pTBqEXKaKttP5liMs8xRqY6jh5aK8qOIGjBP1pXF7D\njigHfl06VL06FouLQIgTQ9651tqYc1NdFp0+419ar5/nyCFRNPZT0mIVjJBF\n9rMx\r\n=Y8+g\r\n-----END PGP SIGNATURE-----\r\n","size":16163},"maintainers":[{"name":"anonymous","email":"horacio.gonzalez@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/clipboard_2.0.1-1_1541488012403_0.8203325346927464"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2021-12-24T20:34:15.189Z","contributors":[]},"2.0.6-1":{"name":"@migrate-to-esm/clipboard","version":"2.0.6-1","description":"Modern copy to clipboard. No Flash. Just 2kb","repository":{"type":"git","url":"git+https://github.com/LostInBrittany/clipboard.js.git"},"license":"MIT","main":"dist/clipboard.js","module":"src/clipboard.js","keywords":["clipboard","copy","cut"],"dependencies":{"@migrate-to-esm/good-listener":"^1.2.2","@migrate-to-esm/select":"^1.1.2","@migrate-to-esm/tiny-emitter":"^2.0.2"},"devDependencies":{"babel-core":"^6.26.0","babel-loader":"^7.1.4","babel-preset-env":"^1.7.0","chai":"^4.2.0","cross-env":"^5.2.0","karma":"^3.1.1","karma-chai":"^0.1.0","karma-mocha":"^1.2.0","karma-chrome-launcher":"^2.2.0","karma-sinon":"^1.0.4","karma-webpack":"^3.0.5","mocha":"^5.2.0","sinon":"^7.1.1","uglifyjs-webpack-plugin":"^2.0.1","webpack":"^4.5.0","webpack-cli":"^3.1.2"},"scripts":{"build":"npm run build-debug && npm run build-min","build-debug":"webpack","build-min":"cross-env NODE_ENV=production webpack","build-watch":"webpack --watch","test":"karma start --single-run","prepublish":"npm run build"},"gitHead":"f84bb30dd5bb823875887cc1fa10a4cede24f9cc","bugs":{"url":"https://github.com/LostInBrittany/clipboard.js/issues"},"homepage":"https://github.com/LostInBrittany/clipboard.js#readme","_id":"@migrate-to-esm/clipboard@2.0.6-1","_nodeVersion":"12.6.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-WZz0P4g80WgbZsGZD660qSmxP1QXo4Ynaw2uelBm7shObDZI1MDGFz/t7wAKoNUXdo4VILez1hDeWE3Qui+DHg==","shasum":"7f24f9d2a504549a7168b256be286bbbb792ba9d","tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/@migrate-to-esm/clipboard/-/clipboard-2.0.6-1.tgz","fileCount":11,"unpackedSize":63981,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJemhc+CRA9TVsSAnZWagAAFJoP/AkzaKSuQfXK4kgU1VpJ\nAftUVxqq8g5puTIYN/i9Ss094boaI3Cmf30jul0/2CnVidfnIlfKI8NFuxjb\n/CdNwSq3EEAeAn1RCNKTXHrhg6zmLKnTfaMkseOdh8/tG7otW5JFv+cBgoHq\nKl7IZgdJBaHCBH3MkJnnxoC4dostmKDpoOTXcvuWOkQiZ/QuwRn/fSRjg4wf\nNWFlk2hQ5I9Ko6QBBgyBOkNnLcE3fvNoLanREQ9J1LKL6BtIFTJqTJJDYv29\n8YdAY1xnQ5unBstA1e1Ezc+J6/FI9/7wFYt9RXLWe++bfr1Q+KOj2VsEM5q1\nPI1C4FAKTDa7/Tnpf1dlQ1ZufJN1fES8p/1jJosG32z3Ri4pjHm8RAXbowJp\ntJ8enrRUHq0gNJQMDKAzKkfRclQ2SHptSnXVjSy/4E5eubVZSnqQvVpRxw1e\nUfsJJpBzVnXBd1A0Pw6e7hXI6jGc0Os7H/H+itmZKuISLaI8w2O9o4XwdEME\npVL8GCkUoPt7qLi5PPR0k57r5beCo4SNrILPQxz0C3nE64AWrKpw+ae4q4QC\n05YJUByOTCFtlM23pUrjGoiCi5eAos7pNfFiwFPhP0RFsGIqMNmdTER9oUCo\n9Zy5wIdoAlN6GHrSLHiYwE6S53BkBIoAlVxm9uMawymbRyxtbq4MzgIS0KvT\nx1Z4\r\n=nlbM\r\n-----END PGP SIGNATURE-----\r\n","size":16733},"maintainers":[{"name":"anonymous","email":"horacio.gonzalez@gmail.com"}],"_npmUser":{"name":"anonymous","email":"horacio.gonzalez@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/clipboard_2.0.6-1_1587156798353_0.5614400560373005"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2021-12-24T20:34:16.821Z","contributors":[]}},"dist-tags":{"latest":"2.0.6-1"},"name":"@migrate-to-esm/clipboard","time":{"created":"2022-01-28T19:29:09.649Z","modified":"2022-01-28T19:29:09.649Z","2.0.1":"2018-11-06T05:57:37.053Z","2.0.1-1":"2018-11-06T07:06:52.552Z","2.0.6-1":"2020-04-17T20:53:18.512Z"},"readme":"# clipboard.js\n\n[![Build Status](http://img.shields.io/travis/zenorocha/clipboard.js/master.svg?style=flat)](https://travis-ci.org/zenorocha/clipboard.js)\n![Killing Flash](https://img.shields.io/badge/killing-flash-brightgreen.svg?style=flat)\n\n> Modern copy to clipboard. No Flash. Just 3kb gzipped.\n\n<a href=\"https://clipboardjs.com/\"><img width=\"728\" src=\"https://cloud.githubusercontent.com/assets/398893/16165747/a0f6fc46-349a-11e6-8c9b-c5fd58d9099c.png\" alt=\"Demo\"></a>\n\n## Why\n\nCopying text to the clipboard shouldn't be hard. It shouldn't require dozens of steps to configure or hundreds of KBs to load. But most of all, it shouldn't depend on Flash or any bloated framework.\n\nThat's why clipboard.js exists.\n\n## Install\n\nYou can get it on npm.\n\n```\nnpm install clipboard --save\n```\n\nOr if you're not into package management, just [download a ZIP](https://github.com/zenorocha/clipboard.js/archive/master.zip) file.\n\n## Setup\n\nFirst, include the script located on the `dist` folder or load it from [a third-party CDN provider](https://github.com/zenorocha/clipboard.js/wiki/CDN-Providers).\n\n```html\n<script src=\"dist/clipboard.min.js\"></script>\n```\n\nNow, you need to instantiate it by [passing a DOM selector](https://github.com/zenorocha/clipboard.js/blob/master/demo/constructor-selector.html#L18), [HTML element](https://github.com/zenorocha/clipboard.js/blob/master/demo/constructor-node.html#L16-L17), or [list of HTML elements](https://github.com/zenorocha/clipboard.js/blob/master/demo/constructor-nodelist.html#L18-L19).\n\n```js\nnew ClipboardJS('.btn');\n```\n\nInternally, we need to fetch all elements that matches with your selector and attach event listeners for each one. But guess what? If you have hundreds of matches, this operation can consume a lot of memory.\n\nFor this reason we use [event delegation](https://stackoverflow.com/questions/1687296/what-is-dom-event-delegation) which replaces multiple event listeners with just a single listener. After all, [#perfmatters](https://twitter.com/hashtag/perfmatters).\n\n# Usage\n\nWe're living a _declarative renaissance_, that's why we decided to take advantage of [HTML5 data attributes](https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/Using_data_attributes) for better usability.\n\n### Copy text from another element\n\nA pretty common use case is to copy content from another element. You can do that by adding a `data-clipboard-target` attribute in your trigger element.\n\nThe value you include on this attribute needs to match another's element selector.\n\n<a href=\"https://clipboardjs.com/#example-target\"><img width=\"473\" alt=\"example-2\" src=\"https://cloud.githubusercontent.com/assets/398893/9983467/a4946aaa-5fb1-11e5-9780-f09fcd7ca6c8.png\"></a>\n\n```html\n<!-- Target -->\n<input id=\"foo\" value=\"https://github.com/zenorocha/clipboard.js.git\">\n\n<!-- Trigger -->\n<button class=\"btn\" data-clipboard-target=\"#foo\">\n    <img src=\"assets/clippy.svg\" alt=\"Copy to clipboard\">\n</button>\n```\n\n### Cut text from another element\n\nAdditionally, you can define a `data-clipboard-action` attribute to specify if you want to either `copy` or `cut` content.\n\nIf you omit this attribute, `copy` will be used by default.\n\n<a href=\"https://clipboardjs.com/#example-action\"><img width=\"473\" alt=\"example-3\" src=\"https://cloud.githubusercontent.com/assets/398893/10000358/7df57b9c-6050-11e5-9cd1-fbc51d2fd0a7.png\"></a>\n\n```html\n<!-- Target -->\n<textarea id=\"bar\">Mussum ipsum cacilds...</textarea>\n\n<!-- Trigger -->\n<button class=\"btn\" data-clipboard-action=\"cut\" data-clipboard-target=\"#bar\">\n    Cut to clipboard\n</button>\n```\n\nAs you may expect, the `cut` action only works on `<input>` or `<textarea>` elements.\n\n### Copy text from attribute\n\nTruth is, you don't even need another element to copy its content from. You can just include a `data-clipboard-text` attribute in your trigger element.\n\n<a href=\"https://clipboardjs.com/#example-text\"><img width=\"147\" alt=\"example-1\" src=\"https://cloud.githubusercontent.com/assets/398893/10000347/6e16cf8c-6050-11e5-9883-1c5681f9ec45.png\"></a>\n\n```html\n<!-- Trigger -->\n<button class=\"btn\" data-clipboard-text=\"Just because you can doesn't mean you should — clipboard.js\">\n    Copy to clipboard\n</button>\n```\n\n## Events\n\nThere are cases where you'd like to show some user feedback or capture what has been selected after a copy/cut operation.\n\nThat's why we fire custom events such as `success` and `error` for you to listen and implement your custom logic.\n\n```js\nvar clipboard = new ClipboardJS('.btn');\n\nclipboard.on('success', function(e) {\n    console.info('Action:', e.action);\n    console.info('Text:', e.text);\n    console.info('Trigger:', e.trigger);\n\n    e.clearSelection();\n});\n\nclipboard.on('error', function(e) {\n    console.error('Action:', e.action);\n    console.error('Trigger:', e.trigger);\n});\n```\n\nFor a live demonstration, go to this [site](https://clipboardjs.com/) and open your console.\n\n## Tooltips\n\nEach application has different design needs, that's why clipboard.js does not include any CSS or built-in tooltip solution.\n\nThe tooltips you see on the [demo site](https://clipboardjs.com/) were built using [GitHub's Primer](https://primer.style/css/components/tooltips). You may want to check that out if you're looking for a similar look and feel.\n\n## Advanced Options\n\nIf you don't want to modify your HTML, there's a pretty handy imperative API for you to use. All you need to do is declare a function, do your thing, and return a value.\n\nFor instance, if you want to dynamically set a `target`, you'll need to return a Node.\n\n```js\nnew ClipboardJS('.btn', {\n    target: function(trigger) {\n        return trigger.nextElementSibling;\n    }\n});\n```\n\nIf you want to dynamically set a `text`, you'll return a String.\n\n```js\nnew ClipboardJS('.btn', {\n    text: function(trigger) {\n        return trigger.getAttribute('aria-label');\n    }\n});\n```\n\nFor use in Bootstrap Modals or with any other library that changes the focus you'll want to set the focused element as the `container` value.\n\n```js\nnew ClipboardJS('.btn', {\n    container: document.getElementById('modal')\n});\n```\n\nAlso, if you are working with single page apps, you may want to manage the lifecycle of the DOM more precisely. Here's how you clean up the events and objects that we create.\n\n```js\nvar clipboard = new ClipboardJS('.btn');\nclipboard.destroy();\n```\n\n## Browser Support\n\nThis library relies on both [Selection](https://developer.mozilla.org/en-US/docs/Web/API/Selection) and [execCommand](https://developer.mozilla.org/en-US/docs/Web/API/Document/execCommand) APIs. The first one is [supported by all browsers](https://caniuse.com/#search=selection) while the second one is supported in the following browsers.\n\n| <img src=\"https://clipboardjs.com/assets/images/chrome.png\" width=\"48px\" height=\"48px\" alt=\"Chrome logo\"> | <img src=\"https://clipboardjs.com/assets/images/edge.png\" width=\"48px\" height=\"48px\" alt=\"Edge logo\"> | <img src=\"https://clipboardjs.com/assets/images/firefox.png\" width=\"48px\" height=\"48px\" alt=\"Firefox logo\"> | <img src=\"https://clipboardjs.com/assets/images/ie.png\" width=\"48px\" height=\"48px\" alt=\"Internet Explorer logo\"> | <img src=\"https://clipboardjs.com/assets/images/opera.png\" width=\"48px\" height=\"48px\" alt=\"Opera logo\"> | <img src=\"https://clipboardjs.com/assets/images/safari.png\" width=\"48px\" height=\"48px\" alt=\"Safari logo\"> |\n|:---:|:---:|:---:|:---:|:---:|:---:|\n| 42+ ✔ | 12+ ✔ | 41+ ✔ | 9+ ✔ | 29+ ✔ | 10+ ✔ |\n\nThe good news is that clipboard.js gracefully degrades if you need to support older browsers. All you have to do is show a tooltip saying `Copied!` when `success` event is called and `Press Ctrl+C to copy` when `error` event is called because the text is already selected.\n\nYou can also check if clipboard.js is supported or not by running `ClipboardJS.isSupported()`, that way you can hide copy/cut buttons from the UI.\n\n## Bonus\n\nA browser extension that adds a \"copy to clipboard\" button to every code block on *GitHub, MDN, Gist, StackOverflow, StackExchange, npm, and even Medium.*\n\nInstall for [Chrome](https://chrome.google.com/webstore/detail/codecopy/fkbfebkcoelajmhanocgppanfoojcdmg) and [Firefox](https://addons.mozilla.org/en-US/firefox/addon/codecopy/).\n\n## License\n\n[MIT License](https://zenorocha.mit-license.org/) © Zeno Rocha","users":{}}