Skip to content

Commit

Permalink
Merge pull request twbs#6118 from godric7/master
Browse files Browse the repository at this point in the history
scrollSpy - add parent scrollTop to offset calculation
  • Loading branch information
fat committed Dec 7, 2012
2 parents a7eb9c2 + 8b959ca commit 2526c3f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/bootstrap-scrollspy.js
Expand Up @@ -59,7 +59,7 @@
, $href = /^#\w/.test(href) && $(href)
return ( $href
&& $href.length
&& [[ $href.position().top, href ]] ) || null
&& [[ $href.position().top + self.$scrollElement.scrollTop(), href ]] ) || null
})
.sort(function (a, b) { return a[0] - b[0] })
.each(function () {
Expand Down

0 comments on commit 2526c3f

Please sign in to comment.