Socket
Socket
Sign inDemoInstall

cytoscape-clipboard

Package Overview
Dependencies
0
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    cytoscape-clipboard

Adds copy-paste utilities to cytoscape.


Version published
Weekly downloads
666
increased by105.56%
Maintainers
1
Install size
76.5 kB
Created
Weekly downloads
 

Readme

Source

cytoscape-clipboard

Description

Adds copy-paste utilities to cytoscape.

API

    var cy = cytoscape({...});

    var cb = cy.clipboard(options);

cy.clipboard(options) Initializes extension & sets options.

cb.copy(eles [, id]) Copies eles and returns id of operation. If id is not specified, it will be assigned automatically.

cb.paste([id]) Pastes the copied elements which has id. If id is not specified, it will have the last operation's id.

Default Options

            var options = {
                clipboardSize: 0
            };

Default Undo Redo Actions

ur.do("paste"[, { id: idOfOperation }]) Pastes operation. id is optional as is in cb.paste()

Dependencies

  • Cytoscape.js ^2.6.12
  • cytoscape-undo-redo ^1.0.8 (optional)

Usage instructions

Download the library:

  • via npm: npm install cytoscape-clipboard,
  • via bower: bower install cytoscape-clipboard, or
  • via direct download in the repository (probably from a tag).

require() the library as appropriate for your project:

CommonJS:

var cytoscape = require('cytoscape');
var clipboard = require('cytoscape-clipboard');

clipboard( cytoscape ); // register extension

AMD:

require(['cytoscape', 'cytoscape-clipboard'], function( cytoscape, clipboard ){
  clipboard( cytoscape ); // register extension
});

Plain HTML/JS has the extension registered for you automatically, because no require() is needed.

Publishing instructions

This project is set up to automatically be published to npm and bower. To publish:

  1. Set the version number environment variable: export VERSION=1.2.3
  2. Publish: gulp publish
  3. If publishing to bower for the first time, you'll need to run bower register cytoscape-clipboard https://github.com/iVis-at-Bilkent/clipboard.git

Team

  • Selim Firat Yilmaz, Metin Can Siper, Ugur Dogrusoz of i-Vis at Bilkent University

Keywords

FAQs

Last updated on 26 Jul 2016

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc