We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 376a759 commit 44cd5d4Copy full SHA for 44cd5d4
1 file changed
public/js/extra.js
@@ -226,7 +226,7 @@ function generateToc(id) {
226
'class': 'toc',
227
'targetId': id
228
});
229
- if(target.text() == 'undefined')
+ if (target.text() == 'undefined')
230
target.html('');
231
var backtotop = $('<a class="back-to-top" href="#">Back to top</a>');
232
var gotobottom = $('<a class="go-to-bottom" href="#">Go to bottom</a>');
@@ -262,7 +262,7 @@ function smoothHashScroll() {
262
// prevent default anchor click behavior
263
e.preventDefault();
264
// animate
265
- $('html, body').animate({
+ $('body, html').stop(true, true).animate({
266
scrollTop: $(hash).offset().top
267
}, 100, "linear", function () {
268
// when done, add hash to url
0 commit comments