Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Bootstrap
bootstrap
Commits
23d7215d
Commit
23d7215d
authored
12 years ago
by
Mark Otto
Browse files
Options
Download
Email Patches
Plain Diff
Modify scrollspy to add .active to all parent li items /cc @fat
parent
4dfc4e10
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
docs/assets/js/bootstrap-scrollspy.js
+2
-2
docs/assets/js/bootstrap-scrollspy.js
docs/assets/js/bootstrap.js
+2
-2
docs/assets/js/bootstrap.js
docs/assets/js/bootstrap.min.js
+1
-1
docs/assets/js/bootstrap.min.js
js/bootstrap-scrollspy.js
+2
-2
js/bootstrap-scrollspy.js
with
7 additions
and
7 deletions
+7
-7
docs/assets/js/bootstrap-scrollspy.js
+
2
-
2
View file @
23d7215d
...
@@ -97,7 +97,7 @@
...
@@ -97,7 +97,7 @@
this
.
activeTarget
=
target
this
.
activeTarget
=
target
$
(
this
.
selector
)
$
(
this
.
selector
)
.
parent
(
'
.active
'
)
.
parent
s
(
'
.active
'
)
.
removeClass
(
'
active
'
)
.
removeClass
(
'
active
'
)
selector
=
this
.
selector
selector
=
this
.
selector
...
@@ -105,7 +105,7 @@
...
@@ -105,7 +105,7 @@
+
this
.
selector
+
'
[href="
'
+
target
+
'
"]
'
+
this
.
selector
+
'
[href="
'
+
target
+
'
"]
'
active
=
$
(
selector
)
active
=
$
(
selector
)
.
parent
(
'
li
'
)
.
parent
s
(
'
li
'
)
.
addClass
(
'
active
'
)
.
addClass
(
'
active
'
)
if
(
active
.
parent
(
'
.dropdown-menu
'
).
length
)
{
if
(
active
.
parent
(
'
.dropdown-menu
'
).
length
)
{
...
...
This diff is collapsed.
Click to expand it.
docs/assets/js/bootstrap.js
+
2
-
2
View file @
23d7215d
...
@@ -1621,7 +1621,7 @@
...
@@ -1621,7 +1621,7 @@
this
.
activeTarget
=
target
this
.
activeTarget
=
target
$
(
this
.
selector
)
$
(
this
.
selector
)
.
parent
(
'
.active
'
)
.
parent
s
(
'
.active
'
)
.
removeClass
(
'
active
'
)
.
removeClass
(
'
active
'
)
selector
=
this
.
selector
selector
=
this
.
selector
...
@@ -1629,7 +1629,7 @@
...
@@ -1629,7 +1629,7 @@
+
this
.
selector
+
'
[href="
'
+
target
+
'
"]
'
+
this
.
selector
+
'
[href="
'
+
target
+
'
"]
'
active
=
$
(
selector
)
active
=
$
(
selector
)
.
parent
(
'
li
'
)
.
parent
s
(
'
li
'
)
.
addClass
(
'
active
'
)
.
addClass
(
'
active
'
)
if
(
active
.
parent
(
'
.dropdown-menu
'
).
length
)
{
if
(
active
.
parent
(
'
.dropdown-menu
'
).
length
)
{
...
...
This diff is collapsed.
Click to expand it.
docs/assets/js/bootstrap.min.js
+
1
-
1
View file @
23d7215d
This diff is collapsed.
Click to expand it.
js/bootstrap-scrollspy.js
+
2
-
2
View file @
23d7215d
...
@@ -97,7 +97,7 @@
...
@@ -97,7 +97,7 @@
this
.
activeTarget
=
target
this
.
activeTarget
=
target
$
(
this
.
selector
)
$
(
this
.
selector
)
.
parent
(
'
.active
'
)
.
parent
s
(
'
.active
'
)
.
removeClass
(
'
active
'
)
.
removeClass
(
'
active
'
)
selector
=
this
.
selector
selector
=
this
.
selector
...
@@ -105,7 +105,7 @@
...
@@ -105,7 +105,7 @@
+
this
.
selector
+
'
[href="
'
+
target
+
'
"]
'
+
this
.
selector
+
'
[href="
'
+
target
+
'
"]
'
active
=
$
(
selector
)
active
=
$
(
selector
)
.
parent
(
'
li
'
)
.
parent
s
(
'
li
'
)
.
addClass
(
'
active
'
)
.
addClass
(
'
active
'
)
if
(
active
.
parent
(
'
.dropdown-menu
'
).
length
)
{
if
(
active
.
parent
(
'
.dropdown-menu
'
).
length
)
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment