Difference between revisions of "Template:Marburg"

Line 278: Line 278:
 
/* - - - - - - -  MOBILE - - - - - - - */
 
/* - - - - - - -  MOBILE - - - - - - - */
 
@media only screen and (max-width: 992px) {
 
@media only screen and (max-width: 992px) {
 +
.menu::before {
 +
content: unset;
 +
}
 
.menu {
 
.menu {
display:none;
+
display: none;
 +
margin: 0 0 0 0;
 +
height: unset;
 +
}
 +
.menu li {
 +
width: 100%;
 +
}
 +
.menu >li>a{
 +
background-color: gray;
 +
border-bottom: 2px solid rgb(50,50,50);
 +
}
 +
.menu>li>ul{
 +
border-bottom: 2px solid rgb(50,50,50);
 +
}
 +
.menu li ul {
 +
position: relative;
 +
visibility: visible;
 +
max-height: unset;box-shadow: none;
 +
opacity: 1.0;
 +
}
 +
.menu_wrapper {
 +
display: inline-block;
 +
position: absolute;
 +
left:0;
 +
top:60px;
 +
height: calc(100vh - 60px);
 +
width: 100%;
 +
overflow-y: auto;
 +
}
 +
header {
 +
height: 60px;
 
}
 
}
 
#h_logo {
 
#h_logo {
 
margin-left: -84px;
 
margin-left: -84px;
 +
line-height: 60px;
 
}
 
}
 
#canvas {
 
#canvas {
Line 289: Line 323:
 
#h_logo {
 
#h_logo {
 
animation: none;
 
animation: none;
 +
top:0;
 +
left:50%;
 
}
 
}
.m_team {
+
#h_wrapper {
border-radius: 0;
+
width: 100%;
 
}
 
}
}  
+
}
  
  
Line 302: Line 338:
 
<script type="text/javascript">
 
<script type="text/javascript">
 
$(document).ready(function() {
 
$(document).ready(function() {
 +
// MOBILE
 +
var mobile = false;
 +
var burger = $("#burger");
 +
var menu = $("#menu");
 +
 +
const media = window.matchMedia("(max-width: 992px)");
 +
if(media.matches){
 +
burger.show();
 +
mobile = true;
 +
}
 +
 +
media.addListener(function(e){
 +
if (e.matches) {
 +
burger.show();
 +
mobile = true;
 +
if(menu.is(":visible")) menu.hide();
 +
} else {
 +
burger.hide();
 +
mobile = false;
 +
if(!menu.is(":visible")) menu.show();
 +
}
 +
});
 +
 +
burger.click(function(){
 +
if(menu.is(":visible")){
 +
menu.hide();
 +
} else {
 +
menu.show().css("display", "inline-block");
 +
}
 +
});
 +
 +
// ORDER FIX
 
$("footer").insertAfter("main");
 
$("footer").insertAfter("main");
 +
 +
// BACKGROUND
 
var canvas = document.getElementById("canvas");  
 
var canvas = document.getElementById("canvas");  
 
var c = canvas.getContext("2d");
 
var c = canvas.getContext("2d");

Revision as of 01:21, 9 July 2018