0
I have this snippet of my code that scrooges for the class ".flaps"
$('html, body').animate({scrollTop: $(".abas").offset().top}, 300);
It would be possible to call the class .flaps on desktop and mobile the class .abas_mobile?
I’m doing it like this, but it’s not working
$('html, body').animate({scrollTop: $(".abas").offset().top}, 300);
$(window).resize(function(){
if ($(window).width() <= 800){
$('html, body').animate({scrollTop: $(".abas_mobile").offset().top}, 300);
}
});
It is possible yes. In theory, the mobile site version should have the same behavior as the desktop version. What is not working?
– Sam
with my code it does not change class, calls the same class on mobile and desktop, I want to call the class . tabs on desktop and mobile the class . abas_mobile
– Wagner Martins Bodyboard
@Rickpariz was still the same thing, I want to call the class . tabs on desktop and mobile the class . tabs_mobile
– Wagner Martins Bodyboard