From 23d7215dbe6f075436fd13ef5376419143a079f5 Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Fri, 29 Mar 2013 23:32:47 -0700 Subject: Modify scrollspy to add .active to all parent li items /cc @fat --- js/bootstrap-scrollspy.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'js/bootstrap-scrollspy.js') diff --git a/js/bootstrap-scrollspy.js b/js/bootstrap-scrollspy.js index 7e845a513..8ccd43fa1 100644 --- a/js/bootstrap-scrollspy.js +++ b/js/bootstrap-scrollspy.js @@ -97,7 +97,7 @@ this.activeTarget = target $(this.selector) - .parent('.active') + .parents('.active') .removeClass('active') selector = this.selector @@ -105,7 +105,7 @@ + this.selector + '[href="' + target + '"]' active = $(selector) - .parent('li') + .parents('li') .addClass('active') if (active.parent('.dropdown-menu').length) { -- cgit v1.2.3