var ClixtellRecorder=function(){var e=function(){var e=(String.fromCharCode,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="),t={cmp:function(r){if(null==r)return"";var o=t._trp(r,6,function(t){return e.charAt(t)});switch(o.length%4){default:case 0:return o;case 1:return o+"===";case 2:return o+"==";case 3:return o+"="}},_trp:function(e,t,r){if(null==e)return"";var o,n,a,i={},c={},l="",s="",u="",d=2,p=3,h=2,f=[],m=0,g=0;for(a=0;a>=1}else{for(n=1,o=0;o>=1}d--,0==d&&(d=Math.pow(2,h),h++),delete c[u]}else for(n=i[u],o=0;o>=1;d--,0==d&&(d=Math.pow(2,h),h++),i[s]=p++,u=String(l)}if(""!==u){if(Object.prototype.hasOwnProperty.call(c,u)){if(u.charCodeAt(0)<256){for(o=0;o>=1}else{for(n=1,o=0;o>=1}d--,0==d&&(d=Math.pow(2,h),h++),delete c[u]}else for(n=i[u],o=0;o>=1;d--,0==d&&(d=Math.pow(2,h),h++)}for(n=2,o=0;o>=1;for(;;){if(m<<=1,g==t-1){f.push(r(m));break}g++}return f.join("")}};return t}(),t=[],r=null,o=null,n=function(){var n={RecordingId:r,SessionId:o,Actions:t},a=document.location.protocol,i=new XMLHttpRequest;i.open("POST",a+"//recorder.clixtell.com/record",!0),i.setRequestHeader("Content-Type","application/json;charset=UTF-8"),i.send(e.cmp(JSON.stringify(n))),t=[]},a=function(e,r){t.length>=100&&n();var o={};if(o.type=e,o.time=(new Date).getTime(),"unload"==e||"beforeunload"==e)n();else{switch(e){case"new":var a=Math.max(document.documentElement.clientWidth,window.innerWidth||0),i=Math.max(document.documentElement.clientHeight,window.innerHeight||0);o.URL=window.location.href,o.UserAgent=navigator.userAgent,o.Width=a,o.Height=i;break;case"start":break;case"mousemove":o.x=r.x,o.y=r.y;break;case"scroll":o.top=window.scrollY;break;case"click":o.x=r.pageX,o.y=r.pageY;break;case"touchstart":o.x=r.touches[0].pageX,o.y=r.touches[0].pageY;break;case"resize":var a=Math.max(document.documentElement.clientWidth,window.innerWidth||0),i=Math.max(document.documentElement.clientHeight,window.innerHeight||0);o.w=a,o.h=i;break;case"keyup":var c="";if(r instanceof KeyboardEvent)if(r.target.id)c="#"+r.target.id;else{for(var l="",s=r.path.length-1;s>=0;s--)r.path[s].nodeName&&(l+=" "+r.path[s].nodeName.toLowerCase());l=l.replace("#document html","");var u=Array.prototype.slice.call(document.querySelectorAll(l));if(u.length>1){var d=u.indexOf(r.target);c=l+"|"+d}else c=l}o.target=c,o.value=r.target.value}t.push(o)}},i=["mousemove","scroll","click","contextmenu","beforeunload","unload","keyup","resize","touchstart"],c=function(){if("undefined"==typeof Clixtell)throw"Failed to initialize Clixtell Recorder. No Clixtell Tracking Script";o="undefined"!=typeof Clixtell?Clixtell.sessionId:null;var c=new XMLHttpRequest;c.onreadystatechange=function(){if(c.readyState==XMLHttpRequest.DONE){var e=JSON.parse(c.responseText);if(e.record){r=e.recordingId,a("start"),n();for(var t in i)window.addEventListener(i[t],function(e){a(e.type,e)},!1)}}},a("new");var l={RecordingId:null,SessionId:o,Actions:t},s=document.location.protocol;c.open("POST",s+"//recorder.clixtell.com/record",!0),c.setRequestHeader("Content-Type","application/json;charset=UTF-8"),c.send(e.cmp(JSON.stringify(l))),t=[]};c()}();