- WordPress 6.9.4 (es_ES) with Kadence theme - Homepage: Hero, La Asociación, Pilares, Beneficios, Eventos, Miembros, Hazte Miembro, Contacto - Brand identity: #13294b navy, #a12932 burgundy, #c69c48 gold - Fonts: Raleway (headings) + Source Sans 3 (body) + Lato (UI) - Plugins: Kadence Blocks, Polylang, Contact Form 7 - Custom CSS with full brand styling and responsive layout - HTTPS enforced via wp-config.php proxy detection
1 line
3.3 KiB
JavaScript
1 line
3.3 KiB
JavaScript
(function(){"use strict";var a={cache:[],wrapper:[],trigger:[],initAll(){const b=["zoom","zoomBack","fade","slide","slideBack","flip","none"];a.cache=document.querySelectorAll(".kadence-video-popup-link");for(let e=0;e<a.cache.length;e++){var c=b[0],d=a.cache[e].getAttribute("data-effect");b.includes(d)?c=d:"fade-right"==d||"fade-left"==d?c="fade":"slide-right"==d?c="slideBack":"slide-left"==d?c="slide":"zoom-out"==d?c="zoomBack":"3d-unfold"==d&&(c="flip");const f=a.cache[e].classList.contains("kadence-video-type-local"),g=a.cache[e].getAttribute("data-popup-id"),h=a.cache[e].getAttribute("data-popup-class"),i=!("true"!==a.cache[e].getAttribute("data-popup-auto")),j=!("true"!==a.cache[e].getAttribute("data-youtube-cookies")),k=a.getActiveSize(),l=a.cache[e].getAttribute("data-media-ratio")??"16:9",m=a.cache[e].getAttribute("data-media-ratio-mobile")??"",n="mobile"===k&&m?m:l;if(f){if(a.wrapper[e]=document.getElementById(g),"mobile"===k){const b=a.wrapper[e]?.querySelector(".kadence-local-video-popup"),c=b?.getAttribute("data-src-mobile");b&&c&&b.setAttribute("src",c)}a.cache[e].addEventListener("click",function(b){b.preventDefault(),a.trigger[e]=GLightbox({elements:[{href:a.wrapper[e].querySelector(".kadence-local-video-popup").getAttribute("src"),type:"video",source:"local"}],touchNavigation:!0,skin:"kadence-dark "+h,loop:!1,openEffect:c,closeEffect:c,autoplayVideos:i,preload:!1,plyr:{css:kadence_pro_video_pop.plyr_css,js:kadence_pro_video_pop.plyr_js,config:{ratio:n,hideControls:!0}},cssEfects:{flip:{in:"flipIn",out:"flipOut"},zoomBack:{in:"zoomBackIn",out:"zoomBackOut"}}}),a.trigger[e].on("close",()=>{document.querySelectorAll("video.kadence-video-poster").forEach(a=>{a.play()})}),a.trigger[e].on("open",()=>{document.querySelectorAll("video.kadence-video-poster").forEach(a=>{a.pause()})}),a.trigger[e].open()})}else{if("mobile"===k){const b=a.cache[e]?.getAttribute("data-href-mobile");b&&a.cache[e].setAttribute("href",b)}const b=GLightbox({selector:".kadence-video-popup-link[data-popup-class=\""+h+"\"]",touchNavigation:!0,skin:"kadence-dark",loop:!1,openEffect:c,closeEffect:c,autoplayVideos:i,preload:!1,plyr:{css:kadence_pro_video_pop.plyr_css,js:kadence_pro_video_pop.plyr_js,config:{hideControls:!0,ratio:n,youtube:{noCookie:j},vimeo:{dnt:j}}},cssEfects:{flip:{in:"flipIn",out:"flipOut"},zoomBack:{in:"zoomBackIn",out:"zoomBackOut"}}});b.on("slide_before_load",()=>{const a=document.getElementById("glightbox-body");h&&a&&(a.classList="",a.classList.add("glightbox-container"),a.classList.add("glightbox-kadence-dark"),a.classList.add(h))}),b.on("slide_after_load",a=>{const b=a.slideConfig.href.match(/^(.*vimeo.com\/|.*video\/)?(\d+)(\?.*&*h=|\/)+([\d,a-f]+)/);if(b){const c=a.slideNode.querySelector("iframe");c.src=c.src+"&h="+b[b.length-1]}}),b.on("close",()=>{document.querySelectorAll("video.kadence-video-poster").forEach(a=>{a.play()})}),b.on("open",()=>{document.querySelectorAll("video.kadence-video-poster").forEach(a=>{a.pause()})})}}},init(){if("function"==typeof GLightbox)a.initAll();else var b=setInterval(function(){"function"==typeof GLightbox&&(a.initAll(),clearInterval(b))},200)},getActiveSize(){return 768<window.innerWidth?"desktop":"mobile"}};"loading"===document.readyState?(document.addEventListener("DOMContentLoaded",a.init),document.addEventListener("kb-query-loaded",a.init)):a.init()})(); |