m |
m |
||
Line 16: | Line 16: | ||
<script> | <script> | ||
− | $( document ).ready(function() { | + | $(document).ready(function() { |
− | $('body').scrollspy({ target: '# | + | $('body').scrollspy({ target: '#toc', offset:150 }) |
$('li.active').prevAll().addClass('before'); | $('li.active').prevAll().addClass('before'); | ||
− | $('# | + | $('#toc').on('activate.bs.scrollspy', function () { |
$('li.active').prevAll().addClass('before'); | $('li.active').prevAll().addClass('before'); | ||
$('li.active').removeClass('before'); | $('li.active').removeClass('before'); |
Revision as of 11:24, 10 July 2016