m |
m |
||
Line 199: | Line 199: | ||
//console.log($(window).scrollTop() + $(window).height() - $(this).offset().top - $(this).height()); | //console.log($(window).scrollTop() + $(window).height() - $(this).offset().top - $(this).height()); | ||
var bottomMargin = ($(window).scrollTop() + $(window).height() - $(this).offset().top); | var bottomMargin = ($(window).scrollTop() + $(window).height() - $(this).offset().top); | ||
+ | var topMargin = ($(window).scrollTop() - $(this).offset().top - $(this).height()); | ||
//console.log($(window).scrollTop()); | //console.log($(window).scrollTop()); | ||
//console.log($(window).height()); | //console.log($(window).height()); | ||
//console.log($(this).offset().top); | //console.log($(this).offset().top); | ||
− | console.log(bottomMargin); | + | console.log(topMargin + " " + bottomMargin); |
if (($(this).offset().top - $(window).scrollTop()) < 500) { | if (($(this).offset().top - $(window).scrollTop()) < 500) { | ||
$(this).stop().fadeTo(0, ($(this).offset().top -$(window).scrollTop())/100.0); | $(this).stop().fadeTo(0, ($(this).offset().top -$(window).scrollTop())/100.0); |
Revision as of 16:55, 8 August 2016
SUPER CELLS
WashU and PSU
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat."
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat."
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat."
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat."