<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Timeline Examples</title> <link rel="icon" HREF="favicon.ico"> <!-- Bootstrap --> <link href="./css/bootstrap.css" rel="stylesheet"> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> <link href="./css/prettify.css" rel="stylesheet" type="text/css" /> <script type="text/javascript" src="./js/prettify/prettify.js"></script> <script src="./dist/vis.js"></script> <link href="./dist/vis.css" rel="stylesheet" type="text/css" /> <link href="./css/examples.css" rel="stylesheet" type="text/css" /> <style> img.example { height:150px; } </style> <script language="JavaScript"> function loadVis() { // DOM element where the Timeline will be attached var container = document.getElementById('visualization'); // Create a DataSet (allows two way data-binding) var items = new vis.DataSet([ {id: 1, content: 'item 1', start: '2014-04-20'}, {id: 2, content: 'item 2', start: '2014-04-14'}, {id: 3, content: 'item 3', start: '2014-04-18'}, {id: 4, content: 'item 4', start: '2014-04-16', end: '2014-04-19'}, {id: 5, content: 'item 5', start: '2014-04-25'}, {id: 6, content: 'item 6', start: '2014-04-27', type: 'point'} ]); // Configuration for the Timeline var options = {height:'552px', clickToUse:true}; // Create a Timeline var timeline = new vis.Timeline(container, items, options); } </script> </head> <body onload="prettyPrint(); loadVis();"> <div class="navbar-wrapper"> <div class="container"> <nav class="navbar navbar-inverse navbar-static-top" role="navigation"> <div class="container"> <div class="navbar-header"> <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> <a class="navbar-brand hidden-sm" href="./index.html">vis.js</a> </div> <div id="navbar" class="navbar-collapse collapse"> <ul class="nav navbar-nav"> <li class="active"><a href="./index.html#modules">Modules</a></li> <li><a href="./docs/index.html" target="_blank">Documentation <img class="icon" src="./images/external-link-icons/external-link-icon-white.png"></a></li> <li><a href="./blog.html">Blog</a></li> <li><a href="./index.html#download_install">Download</a></li> <li><a href="./index.html#showcase">Showcase</a></li> <li><a href="./index.html#contribute">Contribute</a></li> <li><a href="./index.html#featureRequests">Feature requests</a></li> <li><a href="./index.html#licenses">License</a></li> </ul> </div> </div> </nav> </div> </div> <div class="contentWrapper"> <h1>Timeline Examples</h1> <a class="btn btn-default" href="#allExamples" role="button">View all examples »</a> <a class="btn btn-primary" href="./docs/timeline.html" role="button">View docs »</a> <div class="textHTMLContent">This small code example shows the easiest way to get a timline up and running. This code has been taken from example 1. The working example is shown next to it. Click it to start the interaction.</div> <pre class="prettyprint lang-html"> <div id="visualization"></div> <script type="text/javascript"> // DOM element where the Timeline will be attached var container = document.getElementById('visualization'); // Create a DataSet (allows two way data-binding) var items = new vis.DataSet([ {id: 1, content: 'item 1', start: '2014-04-20'}, {id: 2, content: 'item 2', start: '2014-04-14'}, {id: 3, content: 'item 3', start: '2014-04-18'}, {id: 4, content: 'item 4', start: '2014-04-16'} {id: 5, content: 'item 5', start: '2014-04-25'}, {id: 6, content: 'item 6', start: '2014-04-27'} ]); // Configuration for the Timeline var options = {}; // Create a Timeline var timeline = new vis.Timeline( container, items, options ); </script></pre> <div id="visualization"></div> <h2 id="allExamples">All examples</h2> <div class="container-fluid"> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/01_basic.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/1.png"> <div class="exampleTitle">basic usage</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/02_interactive.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/2.png"> <div class="exampleTitle">interactive</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/03_performance.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/3.png"> <div class="exampleTitle">performance</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/04_html_data.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/4.png"> <div class="exampleTitle">html data</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/05_groups.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/5.png"> <div class="exampleTitle">groups</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/06_event_listeners.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/6.png"> <div class="exampleTitle">event listeners</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/07_custom_time_bar.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/7.png"> <div class="exampleTitle">custom time bar</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/08_edit_items.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/8.png"> <div class="exampleTitle">edit items</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/09_order_groups.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/9.png"> <div class="exampleTitle">order groups</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/10_limit_move_and_zoom.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/10.png"> <div class="exampleTitle">limit move and zoom</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/11_points.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/11.png"> <div class="exampleTitle">points</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/12_custom_styling.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/12.png"> <div class="exampleTitle">custom styling</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/13_past_and_future.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/13.png"> <div class="exampleTitle">past and future</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/14_group_performance.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/14.png"> <div class="exampleTitle">group performance</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/15_item_class_names.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/15.png"> <div class="exampleTitle">item class names</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/16_navigation_menu.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/16.png"> <div class="exampleTitle">navigation menu</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/17_data_serialization.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/17.png"> <div class="exampleTitle">data serialization</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/18_range_overflow.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/18.png"> <div class="exampleTitle">range overflow</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/19_localization.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/19.png"> <div class="exampleTitle">localization</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/20_click_to_use.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/20.png"> <div class="exampleTitle">click to use</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/21_set_selection.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/21.png"> <div class="exampleTitle">set selection</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/22_window_adjustment.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/22.png"> <div class="exampleTitle">window adjustment</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/23_data_attributes.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/23.png"> <div class="exampleTitle">data attributes</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/24_all_data_attributes.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/24.png"> <div class="exampleTitle">all data attributes</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/25_background_areas.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/25.png"> <div class="exampleTitle">background areas</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/26_external_data.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/26.png"> <div class="exampleTitle">external data</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/27_templates.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/27.png"> <div class="exampleTitle">templates</div> </a> </div> <!--there is no example 28?--> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/29_hiding_times.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/28.png"> <div class="exampleTitle">hiding times</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/30_subgroups.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/29.png"> <div class="exampleTitle">subgroups</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/31_background_areas_with_groups.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/30.png"> <div class="exampleTitle">background areas with groups</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/32_grid_styling.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/31.png"> <div class="exampleTitle">grid styling</div> </a> </div> <div class="col-lg-2 col-md-3 col-sm-6"> <a href="examples/timeline/requirejs/requirejs_example.html"> <img class="example img-responsive" src="./images/exampleScreenshots/timeline/requirejs.png"> <div class="exampleTitle">grid styling</div> </a> </div> </div> <br /> <br /> <br /> <br /> </div> <!-- jQuery (necessary for Bootstrap's JavaScript plugins) --> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <!-- Include all compiled plugins (below), or include individual files as needed --> <script src="js/bootstrap.min.js"></script> </body> </html>