PageSourceSearch

https://kunsthallewien.at/build/assets/vendor/what-input.js?v=ab3b1954

js kunsthallewien.at collected 2026-10-02 03:46:23 UTC 4,693 bytes, 1 lines download raw bytes

1import{t as e}from"../rolldown-runtime.js?v=2178f5bc";var t=e(((e,t)=>{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r():typeof define==`function`&&define.amd?define(`whatInput`,[],r):typeof e==`object`?e.whatInput=r():n.whatInput=r()})(e,function(){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}return n.m=e,n.c=t,n.p=``,n(0)})([(function(e,t){e.exports=function(){if(typeof document>`u`||typeof window>`u`)return{ask:function(){return`initial`},element:function(){return null},ignoreKeys:function(){},specificKeys:function(){},registerOnChange:function(){},unRegisterOnChange:function(){}};var e=document.documentElement,t=null,n=`initial`,r=n,i=Date.now(),a=!1,o=[`button`,`input`,`select`,`textarea`],s=[],c=[16,17,18,91,93],l=[],u={keydown:`keyboard`,keyup:`keyboard`,mousedown:`mouse`,mousemove:`mouse`,MSPointerDown:`pointer`,MSPointerMove:`pointer`,pointerdown:`pointer`,pointermove:`pointer`,touchstart:`touch`,touchend:`touch`},d=!1,f={x:null,y:null},p={2:`touch`,3:`touch`,4:`mouse`},m=!1;try{var h=Object.defineProperty({},"passive",{get:function(){m=!0}});window.addEventListener(`test`,null,h)}catch{}var g=function(){u[D()]=`mouse`,_()},_=function(){var e=!m||{passive:!0,capture:!0};document.addEventListener(`DOMContentLoaded`,v,!0),window.PointerEvent?(window.addEventListener(`pointerdown`,y,!0),window.addEventListener(`pointermove`,x,!0)):window.MSPointerEvent?(window.addEventListener(`MSPointerDown`,y,!0),window.addEventListener(`MSPointerMove`,x,!0)):(window.addEventListener(`mousedown`,y,!0),window.addEventListener(`mousemove`,x,!0),`ontouchstart`in window&&(window.addEventListener(`touchstart`,y,e),window.addEventListener(`touchend`,y,!0))),window.addEventListener(D(),x,e),window.addEventListener(`keydown`,y,!0),window.addEventListener(`keyup`,y,!0),window.addEventListener(`focusin`,S,!0),window.addEventListener(`focusout`,C,!0)},v=function(){if(a=e.getAttribute(`data-whatpersist`)!==`false`&&document.body.getAttribute(`data-whatpersist`)!==`false`,a)try{window.sessionStorage.getItem(`what-input`)&&(n=window.sessionStorage.getItem(`what-input`)),window.sessionStorage.getItem(`what-intent`)&&(r=window.sessionStorage.getItem(`what-intent`))}catch{}b(`input`),b(`intent`)},y=function(e){var t=e.which,i=u[e.type];i===`pointer`&&(i=T(e));var a=!l.length&&c.indexOf(t)===-1,s=l.length&&l.indexOf(t)!==-1,d=i===`keyboard`&&t&&(a||s)||i===`mouse`||i===`touch`;if(E(i)&&(d=!1),d&&n!==i&&(n=i,w(`input`,n),b(`input`)),d&&r!==i){var f=document.activeElement;f&&f.nodeName&&(o.indexOf(f.nodeName.toLowerCase())===-1||f.nodeName.toLowerCase()===`button`&&!j(f,`form`))&&(r=i,w(`intent`,r),b(`intent`))}},b=function(t){e.setAttribute(`data-what`+t,t===`input`?n:r),O(t)},x=function(e){var t=u[e.type];t===`pointer`&&(t=T(e)),A(e),(!d&&!E(t)||d&&e.type===`wheel`||e.type===`mousewheel`||e.type===`DOMMouseScroll`)&&r!==t&&(r=t,w(`intent`,r),b(`intent`))},S=function(n){if(!n.target.nodeName){C();return}t=n.target.nodeName.toLowerCase(),e.setAttribute(`data-whatelement`,t),n.target.classList&&n.target.classList.length&&e.setAttribute(`data-whatclasses`,n.target.classList.toString().replace(` `,`,`))},C=function(){t=null,e.removeAttribute(`data-whatelement`),e.removeAttribute(`data-whatclasses`)},w=function(e,t){if(a)try{window.sessionStorage.setItem(`what-`+e,t)}catch{}},T=function(e){return typeof e.pointerType==`number`?p[e.pointerType]:e.pointerType===`pen`?`touch`:e.pointerType},E=function(e){var t=Date.now(),r=e===`mouse`&&n===`touch`&&t-i<200;return i=t,r},D=function(){var e=null;return e=`onwheel`in document.createElement(`div`)?`wheel`:document.onmousewheel===void 0?`DOMMouseScroll`:`mousewheel`,e},O=function(e){for(var t=0,i=s.length;t<i;t++)s[t].type===e&&s[t].fn.call(void 0,e===`input`?n:r)},k=function(e){for(var t=0,n=s.length;t<n;t++)if(s[t].fn===e)return t},A=function(e){f.x!==e.screenX||f.y!==e.screenY?(d=!1,f.x=e.screenX,f.y=e.screenY):d=!0},j=function(e,t){var n=window.Element.prototype;if(n.matches||=n.msMatchesSelector||n.webkitMatchesSelector,n.closest)return e.closest(t);do{if(e.matches(t))return e;e=e.parentElement||e.parentNode}while(e!==null&&e.nodeType===1);return null};return`addEventListener`in window&&Array.prototype.indexOf&&g(),{ask:function(e){return e===`intent`?r:n},element:function(){return t},ignoreKeys:function(e){c=e},specificKeys:function(e){l=e},registerOnChange:function(e,t){s.push({fn:e,type:t||`input`})},unRegisterOnChange:function(e){var t=k(e);(t||t===0)&&s.splice(t,1)},clearStorage:function(){window.sessionStorage.clear()}}}()})])})}));export{t};

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.