1/* 2 MIT 3*/ 4!function(c,d){"object"==typeof exports&&"object"==typeof module?module.exports=d():"function"==typeof define&&define.amd?define("whatInput",[],d):"object"==typeof exports?exports.whatInput=d():c.whatInput=d()}(this,function(){function c(e){if(f[e])return f[e].exports;var k=f[e]={exports:{},id:e,loaded:!1};return d[e].call(k.exports,k,k.exports,c),k.loaded=!0,k.exports}return f={},c.m=d=[function(c,d){c.exports=function(){if("undefined"==typeof document||"undefined"==typeof window)return{ask:function(){return"initial"}, 5element:function(){return null},ignoreKeys:function(){},specificKeys:function(){},registerOnChange:function(){},unRegisterOnChange:function(){}};var c=document.documentElement,d=null,g="initial",h=g,e=Date.now(),f="false",k=["button","input","select","textarea"],l=[],w=[16,17,18,91,93],p=[],t={keydown:"keyboard",keyup:"keyboard",mousedown:"mouse",mousemove:"mouse",MSPointerDown:"pointer",MSPointerMove:"pointer",pointerdown:"pointer",pointermove:"pointer",touchstart:"touch",touchend:"touch"},q=!1, 6x=null,y=null,E={2:"touch",3:"touch",4:"mouse"},z=!1;try{var u=Object.defineProperty({},"passive",{get:function(){z=!0}});window.addEventListener("test",null,u)}catch(a){}var u=function(){var a=!!z&&{passive:!0};document.addEventListener("DOMContentLoaded",F);window.PointerEvent?(window.addEventListener("pointerdown",m),window.addEventListener("pointermove",r)):window.MSPointerEvent?(window.addEventListener("MSPointerDown",m),window.addEventListener("MSPointerMove",r)):(window.addEventListener("mousedown", 7m),window.addEventListener("mousemove",r),"ontouchstart"in window&&(window.addEventListener("touchstart",m,a),window.addEventListener("touchend",m)));window.addEventListener(A(),r,a);window.addEventListener("keydown",m);window.addEventListener("keyup",m);window.addEventListener("focusin",G);window.addEventListener("focusout",B)},F=function(){if(f=!(c.getAttribute("data-whatpersist")||"false"===document.body.getAttribute("data-whatpersist")))try{window.sessionStorage.getItem("what-input")&&(g=window.sessionStorage.getItem("what-input")), 8window.sessionStorage.getItem("what-intent")&&(h=window.sessionStorage.getItem("what-intent"))}catch(a){}n("input");n("intent")},m=function(a){var b=a.which,c=t[a.type];"pointer"===c&&(c=C(a));a=!p.length&&-1===w.indexOf(b);var d=p.length&&-1!==p.indexOf(b),b="keyboard"===c&&b&&(a||d)||"mouse"===c||"touch"===c;if(D(c)&&(b=!1),b&&g!==c&&(v("input",g=c),n("input")),b&&h!==c){if((a=(b=document.activeElement)&&b.nodeName)&&!(a=-1===k.indexOf(b.nodeName.toLowerCase()))&&(a="button"===b.nodeName.toLowerCase())){a:if(a= 9window.Element.prototype,a.matches||(a.matches=a.msMatchesSelector||a.webkitMatchesSelector),a.closest)b=b.closest("form");else{do{if(b.matches("form"))break a;b=b.parentElement||b.parentNode}while(null!==b&&1===b.nodeType);
9b=null}a=!b}a&&(v("intent",h=c),n("intent"))}},n=function(a){c.setAttribute("data-what"+a,"input"===a?g:h);for(var b=0,d=l.length;b<d;b++)l[b].type===a&&l[b].fn.call(void 0,"input"===a?g:h)},r=function(a){var b=t[a.type];"pointer"===b&&(b=C(a));x!==a.screenX||y!==a.screenY?(q= 10!1,x=a.screenX,y=a.screenY):q=!0;(!q&&!D(b)||q&&"wheel"===a.type||"mousewheel"===a.type||"DOMMouseScroll"===a.type)&&h!==b&&(v("intent",h=b),n("intent"))},G=function(a){a.target.nodeName?(d=a.target.nodeName.toLowerCase(),c.setAttribute("data-whatelement",d),a.target.classList&&a.target.classList.length&&c.setAttribute("data-whatclasses",a.target.classList.toString().replace(" ",","))):B()},B=function(){d=null;c.removeAttribute("data-whatelement");c.removeAttribute("data-whatclasses")},v=function(a, 11b){if(f)try{window.sessionStorage.setItem("what-"+a,b)}catch(c){}},C=function(a){return"number"==typeof a.pointerType?E[a.pointerType]:"pen"===a.pointerType?"touch":a.pointerType},D=function(a){var b=Date.now();a="mouse"===a&&"touch"===g&&200>b-e;return e=b,a},A=function(){return"onwheel"in document.createElement("div")?"wheel":void 0!==document.onmousewheel?"mousewheel":"DOMMouseScroll"};return"addEventListener"in window&&Array.prototype.indexOf&&(t[A()]="mouse",u()),{ask:function(a){return"intent"=== 12a?h:g},element:function(){return d},ignoreKeys:function(a){w=a},specificKeys:function(a){p=a},registerOnChange:function(a,b){l.push({fn:a,type:b||"input"})},unRegisterOnChange:function(a){a:{for(var b=0,c=l.length;b<c;b++)if(l[b].fn===a){a=b;break a}a=void 0}!a&&0!==a||l.splice(a,1)},clearStorage:function(){window.sessionStorage.clear()}}}()}],c.c=f,c.p="",c(0);var d,f});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.