Line 1,737: | Line 1,737: | ||
var currentScrollPos = window.pageYOffset; | var currentScrollPos = window.pageYOffset; | ||
if (prevScrollpos > currentScrollPos) { | if (prevScrollpos > currentScrollPos) { | ||
− | document.getElementById( | + | document.getElementById("main-container").style.top = "0"; |
} else { | } else { | ||
− | document.getElementById( | + | document.getElementById("main-container").style.top = "-80px"; |
} | } | ||
prevScrollpos = currentScrollPos; | prevScrollpos = currentScrollPos; | ||
Line 1,747: | Line 1,747: | ||
</html> | </html> | ||
+ | |||
+ | {{NCTU Formosa/Scroll_nav}} |
Revision as of 22:01, 12 October 2018