add pages and menu to web frontend

This commit is contained in:
j3d1 2021-08-03 02:02:48 +02:00
parent 9e8f14846a
commit c049c04e8e

View file

@ -12,6 +12,11 @@
<span>fiatlux v0.2</span>
<span class="label warning" id="status_box">Loading...</span>
</a>
<input id="bmenub" type="checkbox" class="show">
<label for="bmenub" class="burger pseudo button">&#9776;</label>
<div class="menu">
<a href="/" class="button icon-picture" onclick="use_page('dashboard'); return false">Dashboard</a>
</div>
</nav>
<main data-page="dashboard" id="page">
<section id="dashboard">
@ -128,6 +133,7 @@
<div id="unused_values" style="display:none;"></div>
<script type="text/javascript" src="js/smoothie_min.js"></script>
<script>
var section = document.getElementById("page");
var menu = document.getElementById("bmenub");
var voltage = document.getElementById("out_voltage");
@ -146,6 +152,10 @@
return pos;
};
function use_page(name) {
section.dataset.page = name;
}
var ws;
var retries;
var series = new TimeSeries();