Socket
Socket
Sign inDemoInstall

clipboard-dom

Package Overview
Dependencies
Maintainers
2
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clipboard-dom - npm Package Compare versions

Comparing version 0.0.2 to 0.0.3

26

clipboard-dom.js

@@ -36,22 +36,2 @@

/**
* Sets "display: none" on the DOM node.
*
* @api private
*/
function hide(node){
node.style.display = 'none';
}
/**
* Sets "display: " on the DOM node.
*
* @api private
*/
function show(node){
node.style.display = '';
}
/**
* Get absolute coordinates for dom element.

@@ -174,8 +154,2 @@ * XXX: this probably belongs in a more focused component ("position"?)

if (typeof(stylesToAdd) == 'object') {
for (var addedStyle in stylesToAdd) {
style[addedStyle] = stylesToAdd[addedStyle];
}
}
appendElem.appendChild(this.div);

@@ -182,0 +156,0 @@ this.div.innerHTML = this.getHTML(box.width, box.height);

2

package.json

@@ -5,3 +5,3 @@ {

"keywords": ["copy", "clipboard", "text", "click", "dom", "button"],
"version": "0.0.2",
"version": "0.0.3",
"dependencies": {

@@ -8,0 +8,0 @@ "classes-component": "*",

@@ -14,3 +14,19 @@

``` html
<html>
<body>
<!-- The "copy-button" *should* be inside a div with "position: relative"
or something else that "has layout". -->
<div style="position: relative;">
<button id="copy-button">Copy to Clipboard</button>
</div>
<script src="build/build.js"></script>
<script src="main.js"></script>
</body>
</html>
```
``` js
// main.js
var Clip = require('clipboard-dom');

@@ -17,0 +33,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc