garand / sticky

jQuery Plugin for Sticky Objects
Other
3.3k stars 1.06k forks source link

bottomSpacing and jQuery versions #239

Open tyssen opened 8 years ago

tyssen commented 8 years ago

Using this with jQuery 1.7.2:

var formFooterHeight = $('.enquiry-form').height() + $('.ftr-base').height() + 80;
$('#tour-details-map').sticky({topSpacing:50,bottomSpacing:formFooterHeight});

the map sticks and unsticks at the right places.

As soon as I increase the jQuery version (i.e. 1.8 or higher), the map sticks when you scroll to it, but doesn't unstick when it gets to the elements below it. Any idea why that might be?

danielbachhuber commented 7 years ago

I found that https://github.com/leafo/sticky-kit/ addresses this problem