Skip to content

Commit 2850502

Browse files
committed
refactor: Change selector
1 parent 91c7fd7 commit 2850502

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

resources/js/functions.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ $(document).ready(function() {
284284
});
285285
const target = $('#sidebar-toc .active');
286286
if (target.length) {
287-
const marginTop = $('#sidebar-toc').find('.type-chapter').length ? 15 : 10;
287+
const marginTop = $('#sidebar-toc .type-chapter').length ? 15 : 10;
288288
$('#sidebar-toc').animate({scrollTop: target.position().top - marginTop}, 200);
289289
};
290290
}

0 commit comments

Comments
 (0)