golden hour
/home/godaofbq/dev.hyperredbed.com/wp-content/plugins/essential-blocks/assets/blocks/popup
⬆️ Go Up
Upload
File/Folder
Size
Actions
block.json
440 B
Del
OK
frontend.asset.php
84 B
Del
OK
frontend.js
5.12 KB
Del
OK
icon.svg
2.35 KB
Del
OK
style.css
2.39 KB
Del
OK
Edit: frontend.js
(()=>{"use strict";var e,t={9547:(e,t,o)=>{var r=o(9394);document.addEventListener("DOMContentLoaded",(function(e){var t=document.querySelectorAll(".eb-popup-container"),o=document.querySelectorAll(".modal-main-wrap");if(t)for(var a=function(e){var t=e.querySelector("iframe"),o=e.querySelector("video");if(t){var r=t.src;t.src=r}o&&o.pause()},i=function(e){var i=t[e].getAttribute("data-close-btn");if("external"==t[e].getAttribute("data-popup-type")){var l=t[e].getAttribute("data-external-identifier");document.querySelectorAll(l).forEach((function(o){o.addEventListener("click",(function(){t[e].querySelector(".eb-popup-overlay").style.display="block",t[e].querySelector(".modal-main-wrap").style.display="block",n(t[e])}))}))}if("page_load"==t[e].getAttribute("data-popup-type")&&("false"==t[e].getAttribute("data-use-cookie")&&u(t[e].getAttribute("data-use-cookie"),t[e].getAttribute("data-block-id"),t[e].getAttribute("data-cookie-expire-time")),"yes"==c(t[e].getAttribute("data-block-id"))?(t[e].querySelector(".eb-popup-overlay").style.display="none",t[e].querySelector(".modal-main-wrap").style.display="none"):setTimeout((function(){t[e].querySelector(".eb-popup-overlay").style.display="block",t[e].querySelector(".modal-main-wrap").style.display="block",u(t[e].getAttribute("data-use-cookie"),t[e].getAttribute("data-block-id"),t[e].getAttribute("data-cookie-expire-time"))}),1e3*parseInt(t[e].getAttribute("data-popup-delay"))),n(t[e])),"btn_click"==t[e].getAttribute("data-popup-type")&&(t[e].querySelector(".eb-popup-button-anchor").onclick=function(){t[e].querySelector(".eb-popup-overlay").style.display="block",t[e].querySelector(".modal-main-wrap").style.display="block",n(t[e])}),"exit_intent"==t[e].getAttribute("data-popup-type")){"false"==t[e].getAttribute("data-use-cookie")&&u(t[e].getAttribute("data-use-cookie"),t[e].getAttribute("data-block-id"),t[e].getAttribute("data-cookie-expire-time"));var p=!1;"yes"==c(t[e].getAttribute("data-block-id"))?(t[e].querySelector(".eb-popup-overlay").style.display="none",t[e].querySelector(".modal-main-wrap").style.display="none"):document.addEventListener("mouseleave",(function(o){o.clientY<0&&(p||(t[e].querySelector(".eb-popup-overlay").style.display="block",t[e].querySelector(".modal-main-wrap").style.display="block",n(t[e]),u(t[e].getAttribute("data-use-cookie"),t[e].getAttribute("data-block-id"),t[e].getAttribute("data-cookie-expire-time"))),p=!0)}))}"true"===i&&t[e].querySelector(".eb-popup-close-icon")&&(t[e].querySelector(".eb-popup-close-icon").onclick=function(){t[e].querySelector(".eb-popup-overlay").style.display="none",t[e].querySelector(".modal-main-wrap").style.display="none",a(t[e].querySelector(".modal-main-wrap"))}),"true"==t[e].getAttribute("data-esc-btn")&&(document.onkeyup=function(o){27==o.keyCode&&"true"===t[e].getAttribute("data-esc-btn")&&((0,r.A)(t[e].querySelectorAll(".eb-popup-overlay")).map((function(e){e.style.display="none"})),(0,r.A)(t[e].querySelectorAll(".modal-main-wrap")).map((function(e){e.style.display="none",a(e)})))});for(var d=function(e){"true"==t[e].getAttribute("data-click-exit")&&(o[e].onclick=function(t){o[e].querySelector(".eb-popup-content").contains(t.target)||((0,r.A)(document.querySelectorAll(".eb-popup-overlay")).map((function(e){e.style.display="none"})),(0,r.A)(document.querySelectorAll(".modal-main-wrap")).map((function(e){e.style.display="none",a(e)})))})},s=0;s<o.length;s++)d(s)},l=0;l<t.length;l++)i(l);function n(e){"true"==e.getAttribute("data-auto-exit")&&setTimeout((function(){e.querySelector(".eb-popup-overlay").style.display="none",e.querySelector(".modal-main-wrap").style.display="none"}),1e3*parseInt(e.getAttribute("data-auto-exit-time")))}function u(e,t,o){if("false"==e)document.cookie=t+"=no;path=/";else if("string"==typeof o&&o.length>0){var r=new Date;r.setTime(r.getTime()+24*parseInt(o)*60*60*1e3);var a="expires="+r.toUTCString();document.cookie=t+"=yes;"+a+";path=/"}else document.cookie=t+"=yes"}function c(e){for(var t=e+"=",o=decodeURIComponent(document.cookie).split(";"),r=0;r<o.length;r++){for(var a=o[r];" "==a.charAt(0);)a=a.substring(1);if(0==a.indexOf(t))return a.substring(t.length,a.length)}return""}}))}},o={};function r(e){var a=o[e];if(void 0!==a)return a.exports;var i=o[e]={exports:{}};return t[e](i,i.exports,r),i.exports}r.m=t,e=[],r.O=(t,o,a,i)=>{if(!o){var l=1/0;for(p=0;p<e.length;p++){for(var[o,a,i]=e[p],n=!0,u=0;u<o.length;u++)(!1&i||l>=i)&&Object.keys(r.O).every((e=>r.O[e](o[u])))?o.splice(u--,1):(n=!1,i<l&&(l=i));if(n){e.splice(p--,1);var c=a();void 0!==c&&(t=c)}}return t}i=i||0;for(var p=e.length;p>0&&e[p-1][2]>i;p--)e[p]=e[p-1];e[p]=[o,a,i]},r.d=(e,t)=>{for(var o in t)r.o(t,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.j=5645,(()=>{var e={5645:0};r.O.j=t=>0===e[t];var t=(t,o)=>{var a,i,[l,n,u]=o,c=0;if(l.some((t=>0!==e[t]))){for(a in n)r.o(n,a)&&(r.m[a]=n[a]);if(u)var p=u(r)}for(t&&t(o);c<l.length;c++)i=l[c],r.o(e,i)&&e[i]&&e[i][0](),e[i]=0;return r.O(p)},o=globalThis.webpackChunkessential_blocks=globalThis.webpackChunkessential_blocks||[];o.forEach(t.bind(null,0)),o.push=t.bind(null,o.push.bind(o))})();var a=r.O(void 0,[3935],(()=>r(9547)));a=r.O(a)})();
Save