Work progress on project UI

This commit is contained in:
2019-01-14 13:17:05 +01:00
parent 497b8f1274
commit f2ab71cf3f
3 changed files with 110 additions and 12 deletions

View File

@ -1,5 +1,19 @@
/**
* Data export result stylesheet
*
* @author Pierre HUBERT
*/
.sidenav.sidenav-fixed {
/*transform: unset;*/
/*margin-top: 80px;*/
}
main {
margin-left: 300px;
}
main .container {
display: none;
}

View File

@ -0,0 +1,34 @@
/**
* Data export visualization navigator
*
* @author Pierre HUBERT
*/
/**
* Refresh tabs visibility accordingly to the hash of
* the current URL
*/
function RefreshTabsVisibility(){
var hash = location.href.toString().split("#")[1];
if(!hash)
return;
document.querySelectorAll(".category").forEach(el => {
el.style.display = el.id === hash ? "block" : "none";
});
}
/**
* Automatically switch the tab when it
* is required by the user
*/
window.addEventListener("hashchange", RefreshTabsVisibility);
//Page initialization
RefreshTabsVisibility();