jquery - swipe right on touch to toggle class? -


is possible, jquery mobile or jquery have swipe event changes class something?

$(document).ready(function() {     $("body").swiperight(function(event){         $('.main-content').toggleclass('.swiped');     }); }); 

would use jquery or jquery mobile sort of thing?

$('.main-content').toggleclass('.swiped'); //                              ^ not dot please! 

should be:

$('.main-content').toggleclass('swiped'); 

btw, think without plugin jquery mobile gives api:

$("body").on('swiperight', function(){}); 

Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -