@uiw/copy-to-clipboard
Advanced tools
Comparing version 1.0.14 to 1.0.15
/**! | ||
* @uiw/copy-to-clipboard v1.0.14 | ||
* @uiw/copy-to-clipboard v1.0.15 | ||
* Copy to clipboard. | ||
@@ -41,2 +41,3 @@ * | ||
function copyTextToClipboard(text, cb) { | ||
if (typeof document === "undefined") return; | ||
const el = document.createElement('textarea'); | ||
@@ -43,0 +44,0 @@ el.value = text; |
/**! | ||
* @uiw/copy-to-clipboard v1.0.14 | ||
* @uiw/copy-to-clipboard v1.0.15 | ||
* Copy to clipboard. | ||
@@ -39,2 +39,3 @@ * | ||
function copyTextToClipboard(text, cb) { | ||
if (typeof document === "undefined") return; | ||
const el = document.createElement('textarea'); | ||
@@ -41,0 +42,0 @@ el.value = text; |
/**! | ||
* @uiw/copy-to-clipboard v1.0.14 | ||
* @uiw/copy-to-clipboard v1.0.15 | ||
* Copy to clipboard. | ||
@@ -45,2 +45,3 @@ * | ||
function copyTextToClipboard(text, cb) { | ||
if (typeof document === "undefined") return; | ||
const el = document.createElement('textarea'); | ||
@@ -47,0 +48,0 @@ el.value = text; |
@@ -1,3 +0,3 @@ | ||
/*! @uiw/copy-to-clipboard v1.0.14 | MIT © 2023 Kenny Wang https://uiwjs.github.io/copy-to-clipboard */ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).copyTextToClipboard=t()}(this,(function(){"use strict";return function(e,t){const o=document.createElement("textarea");o.value=e,o.setAttribute("readonly",""),o.style={position:"absolute",left:"-9999px"},document.body.appendChild(o);const n=document.getSelection().rangeCount>0&&document.getSelection().getRangeAt(0);o.select();let c=!1;try{c=!!document.execCommand("copy")}catch(e){c=!1}document.body.removeChild(o),n&&document.getSelection&&(document.getSelection().removeAllRanges(),document.getSelection().addRange(n)),t&&t(c)}})); | ||
/*! @uiw/copy-to-clipboard v1.0.15 | MIT © 2023 Kenny Wang https://uiwjs.github.io/copy-to-clipboard */ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).copyTextToClipboard=t()}(this,(function(){"use strict";return function(e,t){if("undefined"==typeof document)return;const o=document.createElement("textarea");o.value=e,o.setAttribute("readonly",""),o.style={position:"absolute",left:"-9999px"},document.body.appendChild(o);const n=document.getSelection().rangeCount>0&&document.getSelection().getRangeAt(0);o.select();let d=!1;try{d=!!document.execCommand("copy")}catch(e){d=!1}document.body.removeChild(o),n&&document.getSelection&&(document.getSelection().removeAllRanges(),document.getSelection().addRange(n)),t&&t(d)}})); | ||
//# sourceMappingURL=copy-to-clipboard.umd.min.js.map |
{ | ||
"name": "@uiw/copy-to-clipboard", | ||
"version": "1.0.14", | ||
"version": "1.0.15", | ||
"description": "Copy to clipboard.", | ||
@@ -5,0 +5,0 @@ "main": "dist/copy-to-clipboard.cjs.js", |
@@ -1,2 +0,2 @@ | ||
copy text to clipboard | ||
Copy Text to Clipboard | ||
=== | ||
@@ -9,3 +9,3 @@ | ||
[![npm version](https://img.shields.io/npm/v/@uiw/copy-to-clipboard.svg)](https://www.npmjs.com/package/@uiw/copy-to-clipboard) | ||
[![Repo Dependents](https://badgen.net/github/dependents-repo/uiwjs/copy-to-clipboard)](https://github.com/jaywcjlove/rehype-rewrite/network/dependents) | ||
[![Repo Dependents](https://badgen.net/github/dependents-repo/uiwjs/copy-to-clipboard)](https://github.com/uiwjs/copy-to-clipboard/network/dependents) | ||
@@ -12,0 +12,0 @@ **This styling is an extra step which is likely not required.** |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
87707
22
1904
1