Skip to content

Commit

Permalink
Merge pull request #4 from ryuran/fix/20minutes/offsetTop
Browse files Browse the repository at this point in the history
fix offsetTop
  • Loading branch information
ryuran authored Apr 11, 2017
2 parents fa82b0f + 52410d7 commit 6fcf0f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sticky.js
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@
if (this.parentFromTop > this.offsetTop && this.parentFromTop < this.stuckLimit && !this.isSticked) {
this.el.classList.add(this.options.stickClass);
this.options.onStick(this.el);
this.el.style.top = this.spacerHeight + 'px';
this.el.style.top = this.offsetTop + 'px';
}

// ON DESTICK
Expand Down

0 comments on commit 6fcf0f8

Please sign in to comment.