hi after update wp (4.9.6) and X-Theme Version: 6.0.4 on: http://birnstiel.ch,
the anchor scroll navigation doesnt work anymore.
What could be the Problem?
I get some TypeError: n.easing[this.easing] is not a function
Thanks for help
André
Hi @andreschuler,
Thanks for writing in.
In your custom javascript code (related to scrolling), you should see something like this.
}, 850, 'easeInOutExpo');
Please change it to this
}, 850 );
There should be two similar lines that you need to change.
Thanks!
Hi Rad
I found it in x-body.min.js (and x-body.js )
return;e(s,850,“xEaseInOutExpo”)
I changed it in x-body.min.js to:
return;e(s,850)
but nothing happend.
You mean there must be two Lines?
Do i have to clear a cache before?
thanx
Do i have to clear a site-cache first?
Hi,
You need to change it in Theme Options > JS or Appearance > Customize > Custom > Edit Global JS
instead of changeing it in x-body.min.js
Thanks
Hi Paul
Ok, works again, but without easing (in/out).
jQuery(document).ready(function($) {
$(’.x-nav a’).on(‘touchend click’, function(){
$(’.x-btn-navbar’).click();
});
});
jQuery(document).ready(function($) {
function belowMastheadArrow() {
var $body = $(‘body’);
var $bodyHeight = $body.outerHeight();
var $adminbarHeight = $(’#wpadminbar’).outerHeight();
var $navbarHeight = $(’.x-navbar’).outerHeight();
var scrollSpyLinks = $('.x-nav > li > a[href^="#"]');
if ($(window).width() <= 979) {
scrollSpyLinks.off('click');
scrollSpyLinks.click(function(e) {
e.preventDefault();
var $contentBand = $(this).attr('href');
$('html, body').animate({
scrollTop: $($contentBand).offset().top + 1
}, 850);
});
} else {
scrollSpyLinks.off('click');
scrollSpyLinks.click(function(e) {
e.preventDefault();
var $contentBand = $(this).attr('href');
$('html, body').animate({
scrollTop: $($contentBand).offset().top - $adminbarHeight - $navbarHeight + 1
}, 850);
});
}
}
belowMastheadArrow();
$(window).resize(belowMastheadArrow);
});
Hi there,
Yes, there should be no easing. Glad it works now.
Thanks!
This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.