(function(d,w,activeClass){var hasTouch=(('ontouchstart'in w)||w.DocumentTouch&&d instanceof DocumentTouch);if(!hasTouch){$("html").addClass("no-touch");}else{var activeElement=null,clearActive=function(){if(activeElement){activeElement.classList.remove(activeClass);activeElement=null;}},setActive=function(e){clearActive();if(e.currentTarget.tagName=='A'){activeElement=e.currentTarget;activeElement.classList.add(activeClass);}};$("html").addClass("touch");$("html").removeClass("no-touch");$("body").on("touchstart","a",setActive);$("body").on("touchmove",clearActive);}})(document,window,'touch-active');