// Move the element off screen | |
if($('.home_consult_content').length) { | |
$('.home_consult_content').css('left', '-100%'); | |
} | |
// When parent visible, move on screen | |
function inf_control_effects() { | |
if($('.home_consult_content_wrap').length) { | |
if($('.home_consult_content_wrap').is_on_screen()) { | |
$('.home_consult_content').animate({ | |
'left': '0' | |
}, 900, 'easeOutCubic'); | |
} | |
} | |
} | |
$(window).scroll(inf_control_effects); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment