From: moodyroto Date: Mon, 11 Nov 2013 17:21:34 +0000 (-0500) Subject: Update scrollspy.js X-Git-Tag: v3.2.0~363^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9f30f557213f1e8f821414473550639f5f93f29a;p=thirdparty%2Fbootstrap.git Update scrollspy.js Scrollspy target in tab content does not work properly. Calling .parents('.active') will return all parents with an active class (including the tab pane). Changing this line to .parentsUntil(this.options.target, '.active') should resolve the issue. This will scope the query to only search for active elements inside the scrollspy target. --- diff --git a/js/scrollspy.js b/js/scrollspy.js index 1d2fc78595..295c2e0758 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -96,7 +96,7 @@ this.activeTarget = target $(this.selector) - .parents('.active') + .parentsUntil(this.options.target, '.active') .removeClass('active') var selector = this.selector