This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE> | |
<html> | |
<head> | |
<title>cytoscape-dagre.js demo</title> | |
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1, maximum-scale=1"> | |
<script src="http://code.jquery.com/jquery-2.0.3.min.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dummy file to create gist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(function(){ // on dom ready | |
// photos from flickr with creative commons license | |
var cy = cytoscape({ | |
container: document.getElementById('cy'), | |
boxSelectionEnabled: false, | |
autounselectify: true, | |
This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"format_version" : "1.0", | |
"generated_by" : "cytoscape-3.1.1", | |
"target_cytoscapejs_version" : "~2.1", | |
"data" : { | |
"selected" : true, | |
"__Annotations" : [ "" ], | |
"shared_name" : "main_islands_japan(1)", | |
"SUID" : 20760, | |
"name" : "tokyo_only" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const React = require('react'); | |
const h = require('react-hyperscript'); | |
class Textbox extends React.Component { | |
constructor( props ){ | |
super(props); | |
// props | |
// defaultValue, value, onClick | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// a very simple example of angular/cytoscape.js integration | |
// context (rightclick/2finger) drag to resize in graph | |
// use text boxes to resize in angular | |
var app = angular.module('app', []); | |
// use a factory instead of a directive, because cy.js is not just for visualisation; you need access to the graph model and events etc | |
app.factory('peopleGraph', [ '$q', function( $q ){ | |
var cy; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"format_version" : "1.0", | |
"generated_by" : "cytoscape-3.2.0", | |
"target_cytoscapejs_version" : "~2.1", | |
"data" : { | |
"selected" : true, | |
"__Annotations" : [ ], | |
"shared_name" : "WineCheeseNetwork", | |
"SUID" : 52, | |
"name" : "WineCheeseNetwork" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE> | |
<html> | |
<head> | |
<title>Circle demo</title> | |
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1, maximum-scale=1"> | |
<script src="http://code.jquery.com/jquery-2.0.3.min.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
document.addEventListener('DOMContentLoaded', function(){ // on dom ready | |
var cy = cytoscape({ | |
container: document.querySelector('#cy'), | |
boxSelectionEnabled: false, | |
autounselectify: true, | |
style: cytoscape.stylesheet() | |
.selector('node') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(function(){ // on dom ready | |
var cy = cytoscape({ | |
container: document.getElementById('cy'), | |
boxSelectionEnabled: false, | |
autounselectify: true, | |
minZoom: 0.5, | |
maxZoom: 2, |
NewerOlder