Skip to content

Commit 44cd5d4

Browse files
committed
Fixed for code consistency
1 parent 376a759 commit 44cd5d4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

public/js/extra.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ function generateToc(id) {
226226
'class': 'toc',
227227
'targetId': id
228228
});
229-
if(target.text() == 'undefined')
229+
if (target.text() == 'undefined')
230230
target.html('');
231231
var backtotop = $('<a class="back-to-top" href="#">Back to top</a>');
232232
var gotobottom = $('<a class="go-to-bottom" href="#">Go to bottom</a>');
@@ -262,7 +262,7 @@ function smoothHashScroll() {
262262
// prevent default anchor click behavior
263263
e.preventDefault();
264264
// animate
265-
$('html, body').animate({
265+
$('body, html').stop(true, true).animate({
266266
scrollTop: $(hash).offset().top
267267
}, 100, "linear", function () {
268268
// when done, add hash to url

0 commit comments

Comments
 (0)