<!DOCTYPE html>
<html>
<head>
<style>
body {
  font-family: helvetica,serif;
  font-size: 14px;
}

#cy {
  width: 100%;
  height: 100%;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 10;
  background-color: #FFFFFF;
}

h1 {
  opacity: 0.5;
  font-size: 1em;
}

.floating {
    max-width: 30%;
    width: 120px;
    float: right;
    position: absolute;
    right: 10px;
    top: 10px;
    z-index: 100;
    justify-content: center;
    align-items: center;
}

.cy-button {
    background-color: #555555;
    border: none;
    color: white;
    padding: 6px 0px;
    width: 100%;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    margin: 4px 2px;
    cursor: pointer;
    border-radius: 8px;
    box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2), 0 3px 10px 0 rgba(0,0,0,0.19);
}

a.cy-button:link, a.cy-button:visited, a.cy-button:hover {
    color: white;
    text-decoration: none;
}


.slidertext {
    width: 100%;
    color: #555555;
    border: none;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    margin: 4px 2px;
}

.slider {
    -webkit-appearance: none;
    width: 100%;
    height: 15px;
    text-align: center;
    border-radius: 5px;
    background: #d3d3d3;
    outline: none;
    opacity: 0.7;
    -webkit-transition: .2s;
    transition: opacity .2s;
    margin: 10px 0px;
    display: inline-block;
    box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2), 0 3px 10px 0 rgba(0,0,0,0.19);
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: #555555;
    cursor: pointer;
}

.slider::-moz-range-thumb {
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: #555555;
    cursor: pointer;
}

@media all and (max-width: 600px) {
    .buttontext {
        display: none;
    }
}


</style>
<meta charset=utf-8 />
<meta name="viewport" content="user-scalable=no, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, minimal-ui">
<title>{{title}}</title>
    {% for js in js_list %}
    <script  type='text/javascript' src="{{js}}"></script>
    {% endfor %}
    {% for css in css_list %}
    <link rel="stylesheet" type="text/css" href="{{css}}"/>
    {% endfor %}
<meta http-Equiv="Cache-Control" Content="no-cache" />
<meta http-Equiv="Pragma" Content="no-cache" />
<meta http-Equiv="Expires" Content="0" />
</head>
<body>
<div id="fullscreenDiv">
<div id="cy"></div>
<div class="floating">
    <a class="cy-button" href="#" id="fit" onclick="fit()">
        <span class="glyphicon glyphicon-resize-full"></span><span class="buttontext">  Fit screen</span>
    </a>
    <a class="cy-button" href="#" id="reset" onclick="resetLayout()">
        <span class="glyphicon glyphicon-picture"></span><span class="buttontext">  Restore layout</span>
    </a>
    <a class="cy-button" href="#" id="downloader" onclick="toImage()" download="{{title}}.jpg">
        <span class="glyphicon glyphicon-save"></span><span class="buttontext">  Save (jpg)</span>
    </a>
    <a class="cy-button" href="#" id="downloader_svg" onclick="saveAsSvg()" download="{{title}}.svg">
        <span class="glyphicon glyphicon-save"></span><span class="buttontext">  Save (svg)</span>
    </a>
    <a class="cy-button" href="#" id="fullscreen" onclick="toggleFullScreen()">
        <span id="fsspan" class="glyphicon glyphicon-fullscreen"></span><span id="fstext" class="buttontext">  Full screen</span>
    </a>
    {{slider}}
</div></div>
<!-- Load appplication code at the end to ensure DOM is loaded -->
<script type="text/javascript">{{graph}}</script>
</body>
</html>
