PageSourceSearch

https://www.anicura.nl/dist/modal.js?v=jmuOHUCFa1B1fW_DFzqMq24Nszgbtn05l3z7e3mM3e0

js anicura.nl collected 2026-09-28 06:30:04 UTC 3,620 bytes, 2 lines download raw bytes

1"use strict";(()=>{var h=e=>{let t=window.getComputedStyle(e);return t.display!=="none"&&t.visibility!=="hidden"},b=e=>{if(h(e)){let t;if(e.tabIndex<0)t=!1;else if(e.inert)t=!1;else if(e.disabled)t=!1;else if(e.tabIndex>=0)t=!0;else switch(e.nodeName){case"A":let n=e;t=!!n.href&&n.rel!=="ignore";case"INPUT":t=e.type!=="hidden";case"BUTTON":case"SELECT":case"TEXTAREA":t=!0;break;default:t=!1}return{focusable:t,visible:!0}}else return{focusable:!1,visible:!1}},M=e=>{for(let t=0;t<e.children.length;++t){let n=e.children[t],s=b(n);if(s.visible){if(s.focusable)return n;{let i=M(n);if(i)return i}}}},L=e=>{for(let t=e.children.length-1;t>=0;--t){let n=e.children[t],s=b(n);if(s.visible){let i=L(n);if(i)return i;if(s.focusable)return n}}},d=e=>{let t=M(e);if(t)return t.focus(),!0},T=e=>{let t=L(e);if(t)return t.focus(),!0};var E=e=>{let n=window.getComputedStyle(e).overflowY;return e.scrollHeight>e.clientHeight&&(n==="scroll"||n==="auto")},p=(e,t)=>{let n=e.scrollTop===0,s=e.scrollTop>=e.scrollHeight-e.clientHeight-1;return t&&!s||!t&&!n},m=(e,t)=>{let n=0,s;e.addEventListener("touchstart",i=>{t?.()&&(n=i.touches[0].clientY,s=void 0)}),e.addEventListener("wheel",i=>{if(t?.()&&i.target){let o=i.target,r=i.deltaY>0;for(;o!==null&&o!==e;){if(E(o)&&p(o,r))return;o=o.parentElement}i.preventDefault()}},{passive:!1}),e.addEventListener("touchmove",i=>{if(t?.()&&i.target){let o=i.target;for(s===void 0&&(s=i.touches[0].clientY<n);o!==null&&o!==e;){if(E(o)&&p(o,s))return;o=o.parentElement}i.preventDefault()}},{passive:!1})};window.ani_modals||(window.ani_modals=new Map);var a=window.ani_modals,v=()=>{document.addEventListener("keydown",e=>{e.key==="Escape"&&a.forEach(t=>{t.element.dataset.closeable==="true"&&t.close(e)})}),document.addEventListener("focus",e=>{let t=e.relatedTarget,n=e.target;if(n){for(let{element:s,isOpen:i}of a.values())if(i()){s.contains(n)===!1&&(t?!!(t.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_FOLLOWING)?d(s):T(s):d(s));break}}},!0)},w=e=>{window.ani_modalsInitialized||(window.ani_modalsInitialized=!0,v());let t=e.querySelector("[data-dialog]"),n=e.querySelector("[data-dialog-content]"),s=e.querySelectorAll("[data-close-button]");
1if(!t)throw`Modal with id "${e.id}" dialog missing`;if(!n)throw`Modal with id "${e.id}" dialog content missing`;let i=()=>document.querySelectorAll(`[aria-controls="${t.id}"]`),o=()=>e.inert===!1,r=l=>{if(o()){i().forEach(g=>g.setAttribute("aria-expanded","false")),e.inert=!0,i()[0]?.focus();let c=new CustomEvent("modal:close",{detail:{originalEvent:l}});e.dispatchEvent(c)}},u=()=>{o()||(i().forEach(l=>l.setAttribute("aria-expanded","true")),e.inert=!1,window.requestAnimationFrame(()=>n.focus({preventScroll:!0})),e.dispatchEvent(new Event("modal:open")))};i().forEach(l=>l.addEventListener("click",c=>{o()||u()})),m(e,o),e.dataset.closeable==="true"&&(e.addEventListener("click",l=>{t.contains(l.target)===!1&&r(l)}),s.forEach(l=>{l.addEventListener("click",c=>{r(c)})}));let f={close:r,element:e,isOpen:o,open:u};return a.set(e.id,f),document.body.appendChild(e),f},D=e=>H(e.id),H=e=>(e.endsWith("-container")||(e=`${e}-container`),a.get(e)),y=e=>{let t=a.get(e.id);t&&(a.delete(e.id),t.isOpen()?(t.close(),delete e.dataset.modal,e.id="",setTimeout(()=>{e.remove()},500)):e.remove())};document.addEventListener("htmx:beforeSwap",e=>{let t=e;new DOMParser().parseFromString(t.detail.serverResponse,"text/html").querySelectorAll("[data-modal]").forEach(i=>{let o=document.getElementById(i.id);o&&y(o)})});document.querySelectorAll("[data-modal]").forEach(e=>{e.dataset.autoInit!=="false"&&w(e)});})();
2//# sourceMappingURL=modal.js.map

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.