summaryrefslogtreecommitdiff
path: root/www/lib/vis/examples/network/other/clustersOfclusters.html
diff options
context:
space:
mode:
authorPliable Pixels <pliablepixels@gmail.com>2017-09-27 12:42:48 -0400
committerPliable Pixels <pliablepixels@gmail.com>2017-09-27 12:42:48 -0400
commit210e8feae2fb4842bfb2de38666e6c41671fef3c (patch)
treecbdafa34b1a6260bb20236d7e9de9eb1b690a1c5 /www/lib/vis/examples/network/other/clustersOfclusters.html
parente7e7baeaad90229ccb3e0f45f4ebd77be7d79b14 (diff)
removed lib
Diffstat (limited to 'www/lib/vis/examples/network/other/clustersOfclusters.html')
-rw-r--r--www/lib/vis/examples/network/other/clustersOfclusters.html75
1 files changed, 0 insertions, 75 deletions
diff --git a/www/lib/vis/examples/network/other/clustersOfclusters.html b/www/lib/vis/examples/network/other/clustersOfclusters.html
deleted file mode 100644
index 0e90bcf0..00000000
--- a/www/lib/vis/examples/network/other/clustersOfclusters.html
+++ /dev/null
@@ -1,75 +0,0 @@
-<!DOCTYPE html>
-<html lang="en">
-<head>
- <meta charset="UTF-8">
- <title>Cluster Test</title>
- <script type="text/javascript" src="../../../dist/vis.js"></script>
- <link href="../../../dist/vis.css" rel="stylesheet" type="text/css"/>
- <style type="text/css">
- #network_graph {
- width: 1000px;
- height: 800px;
- border: 1px solid lightgray;
- }
- </style>
-</head>
-<body onload="draw()">
-<p>
- Clusters can contain other clusters, but clusters of a single node is only possible by adding
-<pre>allowSingleNodeCluster: true</pre>
-to clusterNodeProperties<br/>
-In this example repeatedly clicking on the node with open the Clusters.
-</p>
-<div id="network_graph"></div>
-<div id="info"></div>
-<script type="text/javascript">
- var network;
-
- var node_color = ['orange', 'green', 'red', 'yellow', 'cyan'];
- var node_shape = ['star', 'database', 'diamond', 'square', 'triangle'];
- var nodes = new vis.DataSet([
- {id: 'x', label: 'Node X'},
- {id: 'y', label: 'Node Y'},
- ]);
- var network_options = {};
- var edges = new vis.DataSet([
- {from: 'x', to: 'y'}
- ]);
-
- var cluster_id = 1;
-
- function draw() {
- network = new vis.Network(
- document.getElementById('network_graph'),
- {
- nodes: nodes,
- edges: edges
- },
- network_options
- );
- network.on('click', function (params) {
- if (params.nodes.length == 1) {
- if (network.isCluster(params.nodes[0]) == true) {
- network.openCluster(params.nodes[0]);
- }
- }
- });
- cluster();
- cluster();
- cluster();
- }
-
- function cluster() {
- var clusterOptions = {
- joinCondition: function (childOptions) {
- console.log(childOptions);
- return true;
- },
- clusterNodeProperties: {id: cluster_id, label: "Cluster " + cluster_id, color: node_color[cluster_id - 1], shape: node_shape[cluster_id - 1], allowSingleNodeCluster: true}
- };
- cluster_id++;
- network.cluster(clusterOptions);
- }
-</script>
-</body>
-</html>