Skip to content

Instantly share code, notes, and snippets.

@mkdizajn
Created June 22, 2017 16:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mkdizajn/a11002e7024667dfcee68207f5e03545 to your computer and use it in GitHub Desktop.
Save mkdizajn/a11002e7024667dfcee68207f5e03545 to your computer and use it in GitHub Desktop.
total fullscreen mobile menu link patch
(function($){
$('.mobile-menu-toggle').on('click', function(){
if( !window.bindOnceAfterMobileMenuFinished){
$( '.full-screen-overlay-nav.black li a span' ).on('click', function(event) {
var hash = $(this).attr('data-ls_linkto');
setTimeout(function() {
window.wpex.scrollTo(hash);
}, 600, hash);
$('.full-screen-overlay-nav-close').click();
});
window.bindOnceAfterMobileMenuFinished = true;
}
});
})(jQuery);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment