PageSourceSearch

https://monkey-donkey.es/wp-content/plugins/bdthemes-element-pack/assets/js/modules/ep-modal.min.js?ver=9.3.0

js monkey-donkey.es collected 2026-09-24 10:15:33 UTC 4,248 bytes, 1 lines download raw bytes

1!function(){"use strict";function e(e){const t=e instanceof jQuery?e[0]:e,o=t?.querySelectorAll?.(".bdt-modal")||[];o.length&&o.forEach((e=>{const t=function(e){const t=e instanceof jQuery?e[0]:e,o=t?.getAttribute?.("data-settings");if(!o)return null;try{return JSON.parse(o)}catch{return null}}(e);if(!t)return;const o=t.id,n=t.displayTimes,i=t.scrollDirection,s=t.scrollSelector,l=t.scrollOffset,r=t.splashInactivity,a=t.closeBtnDelayShow,d=t.delayTime,c=t.splashDelay,m=t.widgetId,u=t.layout,w=Boolean(elementorFrontend?.isEditMode?.());let y;const g={setLocalize(){if((document.body.classList.contains("logged-in")||w)&&!0!==t.cacheOnAdmin)return localStorage.removeItem(m+"_expiresIn"),void localStorage.removeItem(m);this.clearLocalize();const e=60*(t.displayTimesExpire||4)*60,o=Date.now()+1e3*e;null===localStorage.getItem(m)&&(localStorage.setItem(m,"0"),localStorage.setItem(m+"_expiresIn",String(o)));const n=parseInt(localStorage.getItem(m)||"0",10)+1;localStorage.setItem(m,String(n))},clearLocalize(){const e=parseInt(localStorage.getItem(m+"_expiresIn")||"0",10);Date.now()>=e&&(localStorage.removeItem(m+"_expiresIn"),localStorage.removeItem(m))},modalFire(){if("splash"===u||"exit"===u||"on_scroll"===u){g.setLocalize();const e=parseInt(localStorage.getItem(m)||"0",10);if(!1!==n&&e>n)return}window.bdtUIkit&&bdtUIkit.modal(e).show()},closeBtnDelayShow(){const t=e.querySelector("#bdt-modal-close-button");t&&(t.style.display="none",e.addEventListener("shown",(function o(){t.style.display="",t.style.opacity="0",t.style.transition=`opacity ${d||300}ms`,requestAnimationFrame((()=>{t.style.opacity="1"})),e.removeEventListener("shown",o)})),e.addEventListener("hide",(function o(){t.style.display="none",e.removeEventListener("hide",o)})))},customTrigger(){const e=String(o||"").startsWith("#")?o:"#"+o,t=document.querySelector(e);t&&t.addEventListener("click",(e=>{e.preventDefault(),g.modalFire()}))},scrollDetect(e){let t=0,o=!1;window.addEventListener("scroll",(()=>{const n=t;t=window.scrollY,o||(requestAnimationFrame((()=>{e(t,n),o=!1})),o=!0)}))},modalFireOnSelector(){if(!s)return;const e=document.querySelector(s);if(!e)return;if(e.dataset.modalSelectorInit)return;e.dataset.modalSelectorInit="1";const t=m+"-fired";window.addEventListener("scroll",(()=>{const o=e.getBoundingClientRect().top+window.scrollY,n=e.offsetHeight,i=window.innerHeight;window.scrollY>o+n-i&&(e.classList.contains(t)||g.modalFire(),e.classList.add(t))}))},onScroll(){this.scrollDetect(((e,t)=>{const o=document.documentElement.scrollHeight,n=window.innerHeight,s=l/100,r=m+"-fired";t>e&&"up"===i?document.body.classList.contains(r)||(g.modalFire(),document.body.classList.add(r)):t<e&&"down"===i&&0!==t?e/(o-n)>s&&(document.body.classList.contains(r)||(g.modalFire(),document.body.classList.add(r))):t<e&&"selector"===i&&0!==t&&g.modalFireOnSelector()}))},exitPopup(){document.addEventListener("mouseleave",(e=>{w||(e.clientY<=0||e.clientX<=0||e.clientX>=window.innerWidth||e.clientY>=window.innerHeight)&&g.modalFire()}))},resetTimer(){clearTimeout(y),y=setTimeout((()=>g.modalFire()),r)},splashInactivity(){const e=()=>g.resetTimer();window.addEventListener("load",e),window.addEventListener("mousemove",e),window.addEventListener("mousedown",e),window.addEventListener("touchstart",e),window.addEventListener("click",e),window.addEventListener("keydown",e),window.addEventListener("scroll",e,!0)},splashTiming(){setTimeout((()=>g.modalFire()),c)},splashInit(){r?this.splashInactivity():this.splashTiming()},defaultLayout(){const e=String(o||"").startsWith("#")?o:"#"+o,t=document.querySelector(e);t&&t.addEventListener("click",(e=>{e.preventDefault(),g.modalFire()}))},init(){"default"===u&&g.defaultLayout(),"splash"===u&&g.splashInit(),"exit"===u&&g.exitPopup(),"on_scroll"===u&&g.onScroll(),"custom"===u&&g.customTrigger(),a&&g.closeBtnDelayShow()}};if(g.init(),t&&!w&&!1!==t.custom_section){const o=document.querySelector(t.custom_section),n=e.querySelector(".bdt-modal-body");o&&n&&(e.classList.add("elementor","elementor-"+(t.pageID||"")),n.appendChild(o))}}))}window.addEventListener("elementor/frontend/init",(()=>{window.elementorFrontend?.hooks&&elementorFrontend.hooks.addAction("frontend/element_ready/bdt-modal.default",e)}))}();

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.