PluginProbe
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder / 2.14.0
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder v2.14.0
2.14.0 2.13.0 2.13.1 2.12.0 2.11.1 2.11.0 2.10.0 2.9.0 2.7.4 2.7.5 2.7.6 2.7.7 2.8.0 2.8.1 2.9.1 trunk 1.0 1.0-beta1 1.0-beta2 1.0-beta3 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 All 81 releases
ablocks / assets / build / blocks / atomic-image / view.js

view.js in aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder 2.14.0, at assets/build/blocks/atomic-image/view.js

3 lines 2.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 (()=>{var e={1664(){!function(){const e=function(e){const t=e.getBoundingClientRect(),n=window.innerHeight||document.documentElement.clientHeight;return t.top<n&&t.bottom>0&&t.height>0},t=function(t){const n=function(){t.classList.add("ablocks-in-view")};if(t.classList.add("ablocks-anim-ready"),e(t))return void n();let o=!1;const i=function(){o||(o=!0,n(),window.removeEventListener("scroll",s),window.removeEventListener("resize",s),c&&c.disconnect(),clearTimeout(r))},s=function(){e(t)&&i()};let c=null;"IntersectionObserver"in window&&(c=new IntersectionObserver(function(e){e.forEach(function(e){e.isIntersecting&&i()})},{threshold:0}),c.observe(t)),window.addEventListener("scroll",s,{passive:!0}),window.addEventListener("resize",s,{passive:!0});const r=setTimeout(i,4e3)},n=function(e){const t=parseFloat(e.getAttribute("data-ablocks-scroll-start")),n=parseFloat(e.getAttribute("data-ablocks-scroll-end")),o=isNaN(t)?85:t,i=isNaN(n)?15:n,s=o-i||1;let c=!1;const r=function(){c=!1
2 ;const t=e.getBoundingClientRect(),n=window.innerHeight||document.documentElement.clientHeight,i=t.top/n*100;let r=(o-i)/s;r<0&&(r=0),r>1&&(r=1),e.style.animationDelay=1e3*-r+"ms"},a=function(){c||(c=!0,window.requestAnimationFrame(r))};r(),window.addEventListener("scroll",a,{passive:!0}),window.addEventListener("resize",a,{passive:!0})},o=function(){document.querySelectorAll(".ablocks-anim-scroll[data-ablocks-scroll]").forEach(t),document.querySelectorAll("[data-ablocks-scrollon]").forEach(n),document.querySelectorAll("[data-ablocks-click]").forEach(function(e){e.addEventListener("click",function(){e.classList.remove("ablocks-anim-active"),e.offsetWidth,e.classList.add("ablocks-anim-active")})})};"loading"!==document.readyState?o():document.addEventListener("DOMContentLoaded",o)}()}},t={};function n(o){var i=t[o];if(void 0!==i)return i.exports;var s=t[o]={exports:{}};return e[o](s,s.exports,n),s.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},
3 n.d=(e,t)=>{for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";n(1664)})()})();