PageSourceSearch

https://redbarrelsgames.com/wp-content/themes/redbarrelsgames/dist…ero_index_js.8ccfb2fac98989a82bc7.bundle.js

js redbarrelsgames.com collected 2026-10-02 05:06:29 UTC 6,979 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunkredbarrelsgames=self.webpackChunkredbarrelsgames||[]).push([["src_js_modules_pb-row-hero_index_js"],{
1"./src/js/modules/pb-row-hero/index.js":(t,e,i)=>{i.r(e),i.d(e,{default:()=>d});var s=i("./src/js/scroll/constants.js"),n=i("./src/js/utils/dom.js"),r=i("./src/js/utils/listener.js"),o=i("./src/js/utils/math.js"),l=i("./src/js/utils/raf.js"),a=i("./src/js/utils/resize.js"),u=i("./src/js/utils/transform.js"),h=i("./src/js/utils/viewport.js");function c(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,s=new Array(e);i<e;i++)s[i]=t[i];return s}function f(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,s.key,s)}}function _(t){return function(t){if(Array.isArray(t))return c(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(!t)return;if("string"==typeof t)return c(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);"Object"===i&&t.constructor&&(i=t.constructor.name);if("Map"===i||"Set"===i)return Array.from(i);if("Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return c(t,e)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const d=function(){function t(e,i){var s;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.el=e,this.emitter=i,this.media=(0,n.$)(".pb-row-hero__bgVideo",this.el),this.title=(0,n.$)(".pb-row-hero__title",this.el),this.titleWords=this.title?_((0,n.$$)(".pb-row-hero__title__word",this.title)):null,this.mouseFollowEnabled=null===(s="true"===this.el.dataset.mouseFollowEnabled)||void 0===s||s,this._data={offset:{x:0,y:0},mouse:{x:0,y:0},value:{x:0,y:0},inView:!1},this._raf=null,this._onResize=this._onResize.bind(this),this._onScrollCall=this._onScrollCall.bind(this),this._onMouseMove=this._onMouseMove.bind(this),this._onRAF=this._onRAF.bind(this)}var e,i,c;return e=t,(i=[{key:"init",value:function(){this._onResize(),this._bindEvents()}},{key:"destroy",value:function(){this._unbindEvents(),this._raf&&this._raf(!1),this.el=null,this.emitter=null,this.media=null,this.title=null,this.titleWords=null,this.mouseFollowEnabled=null,this._data=null,this._raf=null,this._onResize=null,this._onScrollCall=null,this._onMouseMove=null,this._onRAF=null}},{key:"_bindEvents",value:function(){a.ZP.add(this._onResize),this.media&&(this.mouseFollowEnabled&&(this._raf=l.ZP.add(this._onRAF)),this.emitter.on("SiteScroll.pb-row-hero",this._onScrollCall),this.mouseFollowEnabled&&(0,r.on)(document,"mousemove",this._onMouseMove))}},{key:"_unbindEvents",value:function(){this.media&&(this.emitter.off("SiteScroll.pb-row-hero",this._onScrollCall),this.mouseFollowEnabled&&l.ZP.remove(this._onRAF),this.mouseFollowEnabled&&(0,r.S1)(document,"mousemove",this._onMouseMove)),a.ZP.remove(this._onResize)}},{key:"_onResize",value:function(){var t=this._data.offset;if(this.media){var e=getComputedStyle(this.media);t.x=parseInt(e.getPropertyValue("--offset-x")),t.y=parseInt(e.getPropertyValue("--offset-y"))}if(this.titleWords){var i=(0,n.JA)(this.title),s=this.titleWords.map((function(t){return(0,n.JA)(t)})),r=s.reduce((function(t,e){return t+e.width}),0),o=(i.width-r)/2,l=0;this.titleWords.forEach((function(t,e){var n=o+l,r=s[e],a=(0,u.R)(t),h=n-(r.left-a.x-i.left);t.style.setProperty("--tx","".concat(h,"px")),l+=r.width}))}}},{key:"_onScrollCall",value:function(t,e){if(e.el===this.el){var i=t===s.gY;this._data.inView=i,this._raf&&this._raf(i)}}},{key:"_onMouseMove",value:function(t){var e=this._data.mouse;e.x=t.clientX,e.y=t.clientY}},{key:"_onRAF",value:function(t){var e=this._data,i=e.value,s=e.mouse,n=e.offset;i.x=(0,o.t7)(i.x,s.x,.05*t),i.y=(0,o.t7)(i.y,s.y,.05*t);var r=(0,o.UI)(i.x,0,h.Z.width,1,-1),l=(0,o.UI)(i.y,0,h.Z.height,1,-1);this.media.style.transform="translate3d(".concat(r*n.x,"px, ").concat(l*n.y,"px, 0px)")}}])&&f(e.prototype,i),c&&f(e,c),t}()},
1"./src/js/scroll/constants.js":(t,e,i)=>{i.d(e,{A2:()=>s,C2:()=>l,Hg:()=>o,SJ:()=>m,ZC:()=>h,dI:()=>n,fX:()=>c,gY:()=>r,i6:()=>f,n3:()=>v,sp:()=>_,uO:()=>a,y0:()=>u,zM:()=>d});var s="is-outview",n="is-inview",r="enter",o="exit",l="down",a="up",u="--js-scroll-down",h="--js-scroll-up",c=500,f="--js-logo-min",_=200,d="--js-scroll-min",m="--js-scrollbar-hidden",v={offset:0,smooth:!0,callback:!1,duration:null,easing:"linear"}},
1"./src/js/utils/raf.js":(t,e,i)=>{function s(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,s.key,s)}}i.d(e,{ZP:()=>o,ol:()=>n});var n=450,r=new(function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this._lastTime=null,this._listeners=[],this._running=!1,this._rafID=null,this._runBnd=this._run.bind(this)}var e,i,n;return e=t,i=[{key:"add",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!this._exists(t)){var s={callback:t,priority:e,active:i};return this._listeners.push(s),this._listeners.sort((function(t,e){return e.priority>t.priority?1:e.priority<t.priority?-1:0})),this._running||this._startRAF(),function(t){s.active=!0===t,s.active&&r._startRAF()}}}},{key:"remove",value:function(t){if(this._exists(t)){var e=this._listeners.findIndex((function(e){return e.callback===t}));this._listeners.splice(e,1)[0],this._running&&this._listeners&&0===this._listeners.length&&this._stopRAF()}}},{key:"_exists",value:function(t){return this._listeners.find((function(e){return e.callback===t}))}},{key:"_startRAF",value:function(){this._running||(this._running=!0,this._rafID=requestAnimationFrame(this._runBnd))}},{key:"_stopRAF",value:function(){this._running&&(this._rafID&&cancelAnimationFrame(this._rafID),this._rafID=null,this._running=!1)}},{key:"_run",value:function(){if(this._rafID=null,this._running){var t=!1,e=performance.now(),i=this._lastTime?Math.min(Math.ceil((e-this._lastTime)/16.666666666666668*10)/10,1):1;this._lastTime=e,this._listeners.forEach((function(e){e.active&&(e.callback(i),e.active&&(t=!0))})),t?this._rafID=requestAnimationFrame(this._runBnd):this._stopRAF()}}}],i&&s(e.prototype,i),n&&s(e,n),t}());const o=r},
1"./src/js/utils/transform.js":(t,e,i)=>{function s(t){var e={};if(window.getComputedStyle){var i=getComputedStyle(t),s=i.transform||i.webkitTransform||i.mozTransform,n=s.match(/^matrix3d\((.+)\)$/);return n?(e.x=n?parseFloat(n[1].split(", ")[12]):0,e.y=n?parseFloat(n[1].split(", ")[13]):0):(n=s.match(/^matrix\((.+)\)$/),e.x=n?parseFloat(n[1].split(", ")[4]):0,e.y=n?parseFloat(n[1].split(", ")[5]):0),e}}i.d(e,{R:()=>s})}
1}]);
2//# sourceMappingURL=src_js_modules_pb-row-hero_index_js.8ccfb2fac98989a82bc7.bundle.js.map

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.