Permalink
Browse files

Merge pull request #2 from jrmlstf/patch-1

Update js/stickysidebar.jquery.js
  • Loading branch information...
2 parents 7ffb7a7 + 87c6860 commit 401107f54d5a0763bbf69e5b19c682c6973ae2cb @p-m-p committed Dec 7, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 js/stickysidebar.jquery.js
@@ -5,6 +5,7 @@
, easing: "linear" //use easing plugin for more options
, padding: 10
, constrain: false
+ , offset: 0
}
, $window = $(window)
, stickyboxes = []
@@ -51,7 +52,7 @@
var $this = $sb
, data = $this.data("stickySB");
if (data) {
- var sTop = $window.scrollTop() - data.offs.top
+ var sTop = $window.scrollTop() - data.offs.top + settings.offset
, currOffs = $this.offset()
, origTop = data.orig.offset.top - data.offs.top
, animTo = origTop;

0 comments on commit 401107f

Please sign in to comment.