PageSourceSearch

https://www.youmail.com/wp-content/plugins/light-modal-block/build/view.js?ver=b9ad66bdc15db6e7c1f3

js youmail.com collected 2026-09-24 08:48:15 UTC 8,595 bytes, 1 lines download raw bytes

1(()=>{"use strict";function e(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var i in o)"__proto__"!==i&&(e[i]=o[i])}return e}var t=function t(o,i){function n(t,n,s){if("undefined"!=typeof document){"number"==typeof(s=e({},i,s)).expires&&(s.expires=new Date(Date.now()+864e5*s.expires)),s.expires&&(s.expires=s.expires.toUTCString()),t=encodeURIComponent(t).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var r in s)s[r]&&(a+="; "+r,!0!==s[r]&&(a+="="+s[r].split(";")[0]));return document.cookie=t+"="+o.write(n,t)+a}}return Object.create({set:n,get:function(e){if("undefined"!=typeof document&&(!arguments.length||e)){for(var t=document.cookie?document.cookie.split("; "):[],i={},n=0;n<t.length;n++){var s=t[n].split("="),a=s.slice(1).join("=");try{var r=decodeURIComponent(s[0]);if(r in i||(i[r]=o.read(a,r)),e===r)break}catch(e){}}return e?i[e]:i}},remove:function(t,o){n(t,"",e({},o,{expires:-1}))},withAttributes:function(o){return t(this.converter,e({},this.attributes,o))},withConverter:function(o){return t(e({},this.converter,o),this.attributes)}},{attributes:{value:Object.freeze(i)},converter:{value:Object.freeze(o)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"});class o{openTrigger="data-trigger-modal";closeTrigger="wp-block-cloudcatch-light-modal-block__close";triggeringDebounce=!1;openClass="is-open";cookieDuration=0;interactionSetsCookie=!1;autoplayMedia=!1;focusableElements='a[href],area[href],input:not([disabled]):not([type="hidden"]):not([aria-hidden]),select:not([disabled]):not([aria-hidden]),textarea:not([disabled]):not([aria-hidden]),button:not([disabled]):not([aria-hidden]),iframe,object,embed,[contenteditable],[tabindex]:not([tabindex^="-"])';constructor({targetModal:e,triggers:t=[],cookieDuration:o,interactionSetsCookie:i=!1,autoplayMedia:n=!1}){this.modalId=e,this.triggers=t,this.cookieDuration=o,this.interactionSetsCookie=i,this.autoplayMedia=n,this.modal=document.querySelector(`[data-modal-id="${this.modalId}"]`),t.length>0&&this.registerTriggers(...t),this.modal.removeAttribute("data-trigger-delay"),this.modal.removeAttribute("data-trigger-selector"),this.modal.removeAttribute("data-cookie-duration"),this.modal.removeAttribute("data-cookie-interaction"),this.onClick=this.onClick.bind(this),this.onKeydown=this.onKeydown.bind(this),this.onSubmit=this.onSubmit.bind(this),this.prepareYouTubeIframes()}registerTriggers(...e){e.filter(Boolean).forEach(e=>{const t=t=>{this.triggeringDebounce||(t&&this.shouldPreventTriggerDefault(t,e)&&t.preventDefault(),this.triggeringDebounce=!0,this.showModal(!0),setTimeout(()=>{this.triggeringDebounce=!1},100))};e.addEventListener("click",t),e.addEventListener("keydown",e=>{13!==e.keyCode&&32!==e.keyCode||(e.preventDefault(),t(e))})})}shouldPreventTriggerDefault(e,t){if("A"!==t.tagName)return!1;if(e instanceof MouseEvent){if(0!==e.button)return!1;if(e.metaKey||e.ctrlKey||e.shiftKey||e.altKey)return!1}return!0}setCookie(){const e=new Date((new Date).getTime()+60*this.cookieDuration*1e3);t.set("wordpress_lmb_"+this.modalId,"1",{expires:e})}getCookie(){return t.get("wordpress_lmb_"+this.modalId)}showModal(e=!1){this.cookieDuration&&this.getCookie()&&!1===e||(this.activeElement=this.modal.ownerDocument.activeElement,this.modal.classList.add(this.openClass),document.body.classList.add("lmb-open"),this.addEventListeners(),this.setFocusToFirstNode(),this.autoplayMedia&&setTimeout(()=>{this.playVideos()},100),this.modal.dispatchEvent(new CustomEvent("light-modal-block:modal-show",{bubbles:!0})))}closeModal(){const e=this.modal;this.removeEventListeners(),this.activeElement&&this.activeElement.focus&&this.activeElement.focus(),e.classList.remove(this.openClass),document.body.classList.remove("lmb-open"),this.pauseVideos(),this.cookieDuration&&this.setCookie(),this.modal.dispatchEvent(new CustomEvent("light-modal-block:modal-close",{bubbles:!0}))}addEventListeners(){this.modal.addEventListener("touchstart",this.onClick),this.modal.addEventListener("click",this.onClick),this.modal.addEventListener("submit",this.onSubmit),document.addEventListener("keydown",this.onKeydown)}removeEventListeners(){this.modal.removeEventListener("touchstart",this.onClick),this.modal.removeEventListener("click",this.onClick),this.modal.removeEventListener("submit",this.onSubmit),document.removeEventListener("keydown",this.onKeydown)}onClick(e){e.target.classList.contains(this.closeTrigger)||e.target.parentNode.classList.contains(this.closeTrigger)||e.target.classList.contains("wp-block-cloudcatch-light-modal-block__wrapper")?(e.preventDefault(),e.stopPropagation(),this.closeModal()):this.interactionSetsCookie&&("A"!==e.target.tagName&&"BUTTON"!==e.target.tagName||this.setCookie())}
1onKeydown(e){27===e.keyCode&&this.closeModal(),9===e.keyCode&&this.retainFocus(e)}onSubmit(){this.interactionSetsCookie&&this.setCookie()}getFocusableNodes(){const e=void 0!==window.lmbFocusableElements?window.lmbFocusableElements:this.focusableElements;if(!e)return[];const t=this.modal.querySelectorAll(e);return Array.from(t)}setFocusToFirstNode(){const e=this.getFocusableNodes();if(0===e.length)return;const t=e.filter(e=>!e.classList.contains(this.closeTrigger));t.length>0&&this.focusElement(t[0],!0),0===t.length&&this.focusElement(e[0],!0)}retainFocus(e){let t=this.getFocusableNodes();if(0===t.length)return;t=t.filter(e=>null!==e.offsetParent);const o=t.indexOf(this.modal.ownerDocument.activeElement);e.shiftKey&&0===o&&(this.focusElement(t[t.length-1]),e.preventDefault()),!e.shiftKey&&t.length>0&&o===t.length-1&&(this.focusElement(t[0]),e.preventDefault())}focusElement(e,t=!1){if(!e||"function"!=typeof e.focus)return;const o=e;try{o.focus(t?{preventScroll:!0}:void 0)}catch{o.focus()}}pauseVideos(){this.modal.querySelectorAll("video").forEach(e=>{e.paused||e.pause()}),this.modal.querySelectorAll("audio").forEach(e=>{e.paused||e.pause()}),this.modal.querySelectorAll("iframe").forEach(e=>{const t=e.src;if(t.includes("youtube.com")||t.includes("youtu.be")){if(!t.includes("enablejsapi=1")){const o=t.includes("?")?"&":"?";e.src=t+o+"enablejsapi=1"}e.contentWindow?.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*")}if(t.includes("vimeo.com")&&e.contentWindow?.postMessage('{"method":"pause"}',"*"),!t.includes("youtube.com")&&!t.includes("youtu.be")&&!t.includes("vimeo.com")){const t=e.src;e.src="",e.src=t}})}prepareYouTubeIframes(){this.modal.querySelectorAll("iframe").forEach(e=>{const t=e.src;if(t&&(t.includes("youtube.com")||t.includes("youtu.be"))&&!t.includes("enablejsapi=1")){const o=t.includes("?")?"&":"?";e.src=t+o+"enablejsapi=1"}})}playVideos(){this.modal.querySelectorAll("video").forEach(e=>{e.play().catch(()=>{})}),this.modal.querySelectorAll("audio").forEach(e=>{e.play().catch(()=>{})}),this.modal.querySelectorAll("iframe").forEach(e=>{const t=e.src;(t.includes("youtube.com")||t.includes("youtu.be"))&&(e.contentWindow?.postMessage('{"event":"command","func":"mute","args":""}',"*"),e.contentWindow?.postMessage('{"event":"command","func":"playVideo","args":""}',"*"),setTimeout(()=>{e.contentWindow?.postMessage('{"event":"command","func":"unMute","args":""}',"*")},500)),t.includes("vimeo.com")&&e.contentWindow?.postMessage('{"method":"play"}',"*")})}}const i={"wp-block-button":".wp-block-button__link"};function n(e){for(const t in i)if(e.classList.contains(t)){const o=e.querySelector(i[t]);if(o)return o}return e}function s(){window.lightModalBlocks=new Map,document.querySelectorAll(".wp-block-cloudcatch-light-modal-block__wrapper").forEach(e=>{const t=e.getAttribute("data-modal-id"),i=e.getAttribute("data-trigger-selector"),s=e.getAttribute("data-trigger-delay"),a=null!==s?parseInt(s)||0:null,r=parseInt(e.getAttribute("data-cookie-duration"))||0,c="true"===(e.getAttribute("data-cookie-interaction")||!1),l="true"===(e.getAttribute("data-autoplay-media")||!1),d=Object.assign({},{openTrigger:"data-trigger-modal"}),u=[`[${d.openTrigger}="${t}"]`,...i?[i]:[]].flatMap(e=>[...document.querySelectorAll(e)]).map(n),h=Array.from(new Set(u));d.targetModal=t,d.triggers=h,d.cookieDuration=r,d.interactionSetsCookie=c,d.autoplayMedia=l,window.lightModalBlocks.set(t,new o(d)),null!==a&&setTimeout(()=>window.lightModalBlocks.get(t).showModal(),a)}),document.dispatchEvent(new CustomEvent("light-modal-block:ready"))}"loading"===document.readyState?window.addEventListener("DOMContentLoaded",s):s()})();

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.