vis.js is a dynamic, browser-based visualization library
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

193 lines
8.5 KiB

9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <meta charset="utf-8">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  7. <meta name="viewport" content="width=device-width, initial-scale=1">
  8. <meta name="description" content="">
  9. <meta name="author" content="">
  10. <link rel="icon" HREF="favicon.ico">
  11. <title>vis.js - Configure documentation.</title>
  12. <!-- Bootstrap core CSS -->
  13. <link href="../css/bootstrap.css" rel="stylesheet">
  14. <!-- Tipue vendor css -->
  15. <link href="../css/tipuesearch.css" rel="stylesheet">
  16. <link href="../css/style.css" rel="stylesheet">
  17. <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
  18. <!--[if lt IE 9]>
  19. <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
  20. <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
  21. <![endif]-->
  22. <link href="../css/prettify.css" type="text/css" rel="stylesheet"/>
  23. <script type="text/javascript" src="../js/googleAnalytics.js"></script>
  24. <script type="text/javascript" src="../js/toggleTable.js"></script>
  25. <script type="text/javascript" src="../js/prettify/prettify.js"></script>
  26. <script src="../js/smooth-scroll.min.js"></script>
  27. <script language="JavaScript">
  28. smoothScroll.init();
  29. </script>
  30. <style>
  31. </style>
  32. </head>
  33. <body onload="prettyPrint();">
  34. <div class="navbar-wrapper">
  35. <div class="container">
  36. <nav class="navbar navbar-inverse navbar-static-top" role="navigation">
  37. <div class="container">
  38. <div class="navbar-header">
  39. <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar"
  40. aria-expanded="false" aria-controls="navbar">
  41. <span class="sr-only">Toggle navigation</span>
  42. <span class="icon-bar"></span>
  43. <span class="icon-bar"></span>
  44. <span class="icon-bar"></span>
  45. </button>
  46. <a class="navbar-brand hidden-sm" href="./index.html">vis.js</a>
  47. </div>
  48. <div id="navbar" class="navbar-collapse collapse">
  49. <ul class="nav navbar-nav">
  50. <li><a href="http://www.visjs.org/index.html#modules">Modules</a></li>
  51. <li><a href="http://www.visjs.org/blog.html">Blog</a></li>
  52. <li><a href="http://www.visjs.org/index.html#download_install">Download</a></li>
  53. <li><a href="http://www.visjs.org/showcase/index.html">Showcase</a></li>
  54. <li><a href="http://www.visjs.org/index.html#contribute">Contribute</a></li>
  55. <li><a href="http://www.visjs.org/featureRequests.html">Feature requests</a></li>
  56. <li><a href="http://www.visjs.org/index.html#licenses">License</a></li>
  57. </ul>
  58. <form class="navbar-form navbar-right" role="search">
  59. <input name="q" id="tipue_search_input" autocomplete="off" type="text" class="form-control" placeholder="Enter keywords">
  60. <button type="button" class="btn btn-default" onclick="vis.initSiteSearch(true);">Go!</button>
  61. </form>
  62. <div id="search-results-wrapper" class="panel panel-default">
  63. <div class="panel-body">
  64. <div id="tipue_search_content"></div>
  65. </div>
  66. </div>
  67. <div id="keyword-info" class="panel panel-success">
  68. <div class="panel-body">
  69. Found <span id="keyword-count"></span> results. Click <a id="keyword-jumper-button" href="">here</a> to jump to the first keyword occurence!
  70. </div>
  71. </div>
  72. </div>
  73. </div>
  74. </nav>
  75. </div>
  76. </div>
  77. <a href="https://github.com/almende/vis" class="hidden-xs hidden-sm hidden-md"><img
  78. style="position: absolute; top: 0; right: 0; border: 0;"
  79. src="https://camo.githubusercontent.com/38ef81f8aca64bb9a64448d0d70f1308ef5341ab/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f6461726b626c75655f3132313632312e706e67"
  80. alt="Fork me on GitHub"
  81. data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_darkblue_121621.png"></a>
  82. <div class="container full">
  83. <h1>Network - configure</h1>
  84. <p>Handles the HTML part of the canvas.</p>
  85. <h3>Options</h3>
  86. <p>The options for the canvas have to be contained in an object titled 'configure'.</p>
  87. <p>Click on the full options or shorthand options to show how these options are supposed to be used.</p>
  88. <ul class="nav nav-tabs">
  89. <li role="presentation" class="active" onclick="toggleTab(this)"><a href="#">options hidden</a></li>
  90. <li role="presentation" onclick="toggleTab(this);" targetNode="fullOptions"><a href="#">full options</a></li>
  91. <li role="presentation" onclick="toggleTab(this);" targetNode="shortOptions"><a href="#">shorthand options</a></li>
  92. </ul>
  93. <br>
  94. <pre class="prettyprint lang-js options top hidden" id="fullOptions">
  95. // these are all options in full.
  96. var options = {
  97. configure: {
  98. enabled: true,
  99. filter: 'nodes,edges',
  100. container: undefined,
  101. showButton: true
  102. }
  103. }
  104. network.setOptions(options);
  105. </pre>
  106. <pre class="prettyprint lang-js options top hidden" id="shortOptions">
  107. // only the options that have shorthand notations are shown.
  108. var options = {
  109. configure: 'nodes,edges'
  110. }
  111. network.setOptions(options);
  112. </pre>
  113. <p>As shown above, alternative to supplying an object, you can supply a <code>String</code>, <code>Array</code>, <code>Function</code> or
  114. <code>Boolean</code>. These will do the same as the filter option described below.</p>
  115. <table class="options">
  116. <tr>
  117. <th>Name</th>
  118. <th>Type</th>
  119. <th>Default</th>
  120. <th>Description</th>
  121. </tr>
  122. <tr>
  123. <td>enabled</td>
  124. <td>Boolean</td>
  125. <td><code>true</code></td>
  126. <td>Toggle the configuration interface on or off. This is an optional parameter. If left undefined and any of the other properties of this object are defined, this will be set to true.
  127. </td>
  128. </tr>
  129. <tr>
  130. <td>filter</td>
  131. <td>String, Array, Boolean, Function</td>
  132. <td><code>true</code></td>
  133. <td>When a boolean, true gives you all options, false will not show any. If a string is supplied, any
  134. combination of the following is allowed: nodes, edges, layout, interaction, manipulation, physics,
  135. selection, renderer. Feel free to come up with a fun seperating character. Finally, when supplied an
  136. array of strings, any of the previously mentioned fields are accepted. <br><br>
  137. When supplying a function, you receive two arguments. The option and the path of the option within the options object. If it returns true, the options will be shown in the configurator. Example:
  138. <pre class="prettyprint lang-js">
  139. function (option, path) {
  140. return path.indexOf('physics') !== -1;
  141. }</pre>
  142. This only shows the physics options.
  143. </td>
  144. </tr>
  145. <tr>
  146. <td>container</td>
  147. <td>DOM element</td>
  148. <td><code>undefined</code></td>
  149. <td>This allows you to put the configure list in another HTML container than below the network.</td>
  150. </tr>
  151. <tr>
  152. <td>showButton</td>
  153. <td>Boolean</td>
  154. <td><code>true</code></td>
  155. <td>Show the generate options button at the bottom of the configurator.</td>
  156. </tr>
  157. </table>
  158. </div>
  159. <!-- Bootstrap core JavaScript
  160. ================================================== -->
  161. <!-- Placed at the end of the document so the pages load faster -->
  162. <script src="../js/jquery.min.js"></script>
  163. <script src="../js/bootstrap.min.js"></script>
  164. <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
  165. <script src="../js/ie10-viewport-bug-workaround.js"></script>
  166. <!-- jquery extensions -->
  167. <script src="../js/jquery.highlight.js"></script>
  168. <script src="../js/jquery.url.min.js"></script>
  169. <!-- Tipue vendor js -->
  170. <script src="../js/tipuesearch.config.js"></script>
  171. <script src="../js/tipuesearch.js"></script>
  172. <!-- controller -->
  173. <script src="../js/main.js"></script>