Sha256: f66c97a8c983fab6b78b466ada032801b00d77c42f8fe194e356eebc57a49d70
Contents?: true
Size: 924 Bytes
Versions: 8
Compression:
Stored size: 924 Bytes
Contents
$(document).ready(function(){ $("#menu-close").click(function(e) { e.preventDefault(); $("#sidebar-wrapper").toggleClass("active"); }); // Opens the sidebar menu $("#menu-toggle").click(function(e) { e.preventDefault(); $("#sidebar-wrapper").toggleClass("active"); }); // Scrolls to the selected menu item on the page $(function() { $('a[href*=#]:not([href=#])').click(function() { if (location.pathname.replace(/^\//, '') == this.pathname.replace(/^\//, '') || location.hostname == this.hostname) { var target = $(this.hash); target = target.length ? target : $('[name=' + this.hash.slice(1) + ']'); if (target.length) { $('html,body').animate({ scrollTop: target.offset().top }, 1000); return false; } } }); }); })
Version data entries
8 entries across 8 versions & 1 rubygems