1
0
mirror of https://github.com/actix/actix-website synced 2025-06-29 08:14:58 +02:00

make mobile Responsive right

This commit is contained in:
krircc
2018-01-07 13:44:13 +08:00
parent 920a48f0c5
commit dbd274a8bf
5 changed files with 45 additions and 33 deletions

14
public/js/nav.js Normal file
View File

@ -0,0 +1,14 @@
var menu = document.getElementById('menu');
menu.addEventListener('click', function() {
var nav = document.getElementById('rnav');
if (nav.style.height == 'auto') {
nav.style.height = '0';
}else{
nav.style.height = 'auto';
}
// they are same
// manv.style.height = 'auto';
// manv.setAttribute('style', 'height: auto !important');
// manv.style.setProperty( 'height',' auto', 'important');
}, false);