Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ewc-lib/ewc-dialog-clipboard

Package Overview
Dependencies
Maintainers
0
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ewc-lib/ewc-dialog-clipboard

This is a dialog with added functionality for leting a user copy some given text into the OS's clipboard.

  • 0.1.0
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-85.71%
Maintainers
0
Weekly downloads
 
Created
Source

Screenshot

This is a dialog with added functionality for leting a user copy some given text into the OS's clipboard.

Before click on button

Screenshot

After click on button

Screenshot

API

The API of ewc-dialog applies to this element as well, because this element derives from ewc-dialog.

Additionally, there is the following property:

  • clipboardContent - the given string is copied into the clipboard. Can be modified at runtime.

Usage with WebPack

package.json

"dependencies": {
  "@ewc-lib/ewc-dialog-clipboard": "^0.1.0"
},

main.js

import "@ewc-lib/ewc-css/ewc.css"
import "@ewc-lib/ewc-dialog-clipboard"

index.html

<body>

  <script src="bundle.js"></script>

  <ewc-dialog-clipboard></ewc-dialog-clipboard>

  <script>
    document.addEventListener("DOMContentLoaded", function(event) {
      const el = document.getElementsByTagName("ewc-dialog")[0]
      el.title = "ewc-dialog-feedback demonstration"
      el.bodyHtml = "Click to copy to clipboard."
      el.visible = true
      el.clipboardContent = "This is the text being copied into the clipboard."
    })
  </script>

</body>

FAQs

Package last updated on 05 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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