Chloroplast (Talk | contribs) |
Chloroplast (Talk | contribs) |
||
(7 intermediate revisions by the same user not shown) | |||
Line 1,691: | Line 1,691: | ||
} | } | ||
− | if(id == 2 || id == 3 || id == 4 || id == 7){ | + | if(id == 2 || id == 3 || id == 4 || id == 7 || id == 9){ |
$("#sidebar-arrow-" + id).toggleClass("side-bar-arrow-up"); | $("#sidebar-arrow-" + id).toggleClass("side-bar-arrow-up"); | ||
} | } | ||
Line 1,721: | Line 1,721: | ||
$('#sci_logo').css('display', "none"); | $('#sci_logo').css('display', "none"); | ||
$('#sps_logo').css('display', "none"); | $('#sps_logo').css('display', "none"); | ||
+ | $('.canvas_parts').css('display', "none"); | ||
}else{ | }else{ | ||
$('#nus_logo').css('left', "0%"); | $('#nus_logo').css('left', "0%"); | ||
$('#sci_logo').css('display', "block"); | $('#sci_logo').css('display', "block"); | ||
$('#sps_logo').css('display', "block"); | $('#sps_logo').css('display', "block"); | ||
+ | $('.canvas_parts').css('display', "block"); | ||
} | } | ||
}; | }; | ||
Line 1,896: | Line 1,898: | ||
hasPerspective = false, | hasPerspective = false, | ||
− | perspective = | + | perspective = hasPerspective, |
// initialize function | // initialize function | ||
init = function() { | init = function() { | ||
Line 2,127: | Line 2,129: | ||
}); | }); | ||
− | + | $(document).ready(function() { | |
− | + | // Show or hide the sticky footer button | |
− | + | $(window).scroll(function() { | |
− | + | if ($(this).scrollTop() > 200) { | |
− | </script> | + | $('.go-top').fadeIn(200); |
+ | } else { | ||
+ | $('.go-top').fadeOut(200); | ||
+ | } | ||
+ | }); | ||
+ | |||
+ | // Animate the scroll to top | ||
+ | $('.go-top').click(function(event) { | ||
+ | event.preventDefault(); | ||
+ | |||
+ | $('html, body').animate({scrollTop: 0}, 300); | ||
+ | }) | ||
+ | }); | ||
+ | </script> | ||
</html> | </html> |
Latest revision as of 07:39, 16 October 2016