text: !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("three")):"function"==typeof define&&define.amd?define(["three"],t):"object"==typeof exports?exports.ORE=t(require("three")):e.ORE=t(e.THREE)}(self,(function(e){return(()=>{var t={714:function(e,t){(function(){(null!==t?t:this).Lethargy=function(){function e(e,t,i,n){this.stability=null!=e?Math.abs(e):8,this.sensitivity=null!=t?1+Math.abs(t):100,this.tolerance=null!=i?1+Math.abs(i):1.1,this.delay=null!=n?n:150,this.lastUpDeltas=function(){var e,t,i;for(i=[],e=1,t=2*this.stability;1<=t?e<=t:e>=t;1<=t?e++:e--)i.push(null);return i}.call(this),this.lastDownDeltas=function(){var e,t,i;for(i=[],e=1,t=2*this.stability;1<=t?e<=t:e>=t;1<=t?e++:e--)i.push(null);return i}.call(this),this.deltasTimestamp=function(){var e,t,i;for(i=[],e=1,t=2*this.stability;1<=t?e<=t:e>=t;1<=t?e++:e--)i.push(null);return i}.call(this)}return e.prototype.check=function(e){var t;return null!=(e=e.originalEvent||e).wheelDelta?t=e.wheelDelta:null!=e.deltaY?t=-40*e.deltaY:null==e.detail&&0!==e.detail||(t=-40*e.detail),this.deltasTimestamp.push(Date.now()),this.deltasTimestamp.shift(),t>0?(this.lastUpDeltas.push(t),this.lastUpDeltas.shift(),this.isInertia(1)):(this.lastDownDeltas.push(t),this.lastDownDeltas.shift(),this.isInertia(-1))},e.prototype.isInertia=function(e){var t,i,n,s,r,o,a;return null===(t=-1===e?this.lastDownDeltas:this.lastUpDeltas)[0]?e:!(this.deltasTimestamp[2*this.stability-2]+this.delay>Date.now()&&t[0]===t[2*this.stability-1])&&(n=t.slice(0,this.stability),i=t.slice(this.stability,2*this.stability),a=n.reduce((function(e,t){return e+t})),r=i.reduce((function(e,t){return e+t})),o=a/n.length,s=r/i.length,Math.abs(o)<Math.abs(s*this.tolerance)&&this.sensitivity<Math.abs(s)&&e)},e.prototype.showLastUpDeltas=function(){return this.lastUpDeltas},e.prototype.showLastDownDeltas=function(){return this.lastDownDeltas},e}()}).call(this)},885:e=>{e.exports=function(e,t){t||(t=[0,""]),e=String(e);var i=parseFloat(e,10);return t[0]=i,t[1]=e.match(/[\d.\-\+]*\s*(.*)/)[1]||"",t}},810:(e,t,i)=>{"use strict";var n=i(885);e.exports=a;var s=o("in",document.body);function r(e,t){var i=n(getComputedStyle(e).getPropertyValue(t));return i[0]*a(i[1],e)}function o(e,t){var i=document.createElement("div");i.style.height="128"+e,t.appendChild(i);var n=r(i,"height")/128;return t.removeChild(i),n}function a(e,t){if(!e)return null;switch(t=t||document.body,e=(e+""||"px").trim().toLowerCase(),t!==window&&t!==document||(t=document.body),e){case"%":return t.clientHeight/100;case"ch":case"ex":return o(e,t);case"em":return r(t,"font-size");case"rem":return r(document.body,"font-size");case"vw":return window.innerWidth/100;case"vh":return window.innerHeight/100;case"vmin":return Math.min(window.innerWidth,window.innerHeight)/100;case"vmax":return Math.max(window.innerWidth,window.innerHeight)/100;case"in":return s;case"cm":return s/2.54;case"mm":return s/25.4;case"pt":return s/72;case"pc":return s/6;case"px":return 1}var i=n(e);if(!isNaN(i[0])&&i[1]){var l=a(i[1],t);return"number"==typeof l?i[0]*l:null}return null}},250:(e,t,i)=>{"use strict";i.r(t),i.d(t,{Animator:()=>d,Background:()=>p,BaseLayer:()=>s,Controller:()=>l,DOMMesh:()=>m,Easings:()=>h,EventDispatcher:()=>f,GPUComputationController:()=>g,LayoutController:()=>b,Lerps:()=>c,MouseRotator:()=>v,PageScroller:()=>y,PageScrollerSection:()=>S,Pointer:()=>a,PostProcessing:()=>w,TimelineAnimator:()=>x,UniformsLib:()=>u});var n=i(807);class s extends n.EventDispatcher{constructor(){super(),this.readyAnimate=!1,this.time=0,this.info={name:"",aspectSetting:{mainAspect:16/9,wideAspect:10,portraitAspect:.5},size:{windowSize:new n.Vector2,windowAspectRatio:1,canvasSize:new n.Vector2,canvasPixelSize:new n.Vector2,canvasAspectRatio:1,pixelRatio:window.devicePixelRatio,portraitWeight:0,wideWeight:0}},this.commonUniforms={time:{value:0}},this.scene=new n.Scene,this.camera=new n.PerspectiveCamera(50,1,.1,1e3)}tick(e){this.time+=e,this.commonUniforms.time.value=this.time,this.readyAnimate&&this.animate(e)}animate(e){}onBind(e){this.info.name=e.name,this.info.canvas=e.canvas,this.info.wrapperElement=e.wrapperElement,this.info.wrapperElementRect=e.wrapperElement&&e.wrapperElement.getBoundingClientRect(),this.info.aspectSetting=e.aspectSetting||this.info.aspectSetting,this.info.alpha=e.alpha,this.info.size.pixelRatio=e.pixelRatio||this.info.size.pixelRatio,this.renderer=new n.WebGLRenderer(this.info),this.renderer.setPixelRatio(this.info.size.pixelRatio),this.renderer.debug.checkShaderErrors=!0,setTimeout((()=>{this.onResize(),this.readyAnimate=!0}),0)}onUnbind(){this.removeChildrens(this.scene),this.readyAnimate=!1}removeChildrens(e){for(let t=e.children.length-1;t>=0;t--){let i,n;this.removeChildrens(e.children[t]),e.children[t].isMesh&&(i=e.children[t].geometry,n=e.children[t].material),e.remove(e.children[t]),i&&i.dispose(),n&&n.dispose()}}onResize(){if(null==this.renderer)return;const e=new n.Vector2(window.innerWidth,window.innerHeight),t=new n.Vector2;this.info.wrapperElement?t.set(this.info.wrapperElement.clientWidth,this.info.wrapperElement.clientHeight):t.copy(e);let i=1-(t.x/t.y-this.info.aspectSetting.portraitAspect)/(this.info.aspectSetting.mainAspect-this.info.aspectSetting.portraitAspect);i=Math.min(1,Math.max(0,i));let s=1-(t.x/t.y-this.info.aspectSetting.wideAspect)/(this.info.aspectSetting.mainAspect-this.info.aspectSetting.wideAspect);s=Math.min(1,Math.max(0,s)),this.info.size.windowSize.copy(e),this.info.size.windowAspectRatio=e.x/e.y,this.info.size.canvasSize.copy(t),this.info.size.canvasPixelSize.copy(t.clone().multiplyScalar(this.renderer.getPixelRatio())),this.info.size.canvasAspectRatio=t.x/t.y,this.info.size.portraitWeight=i,this.info.size.wideWeight=s,this.renderer.setPixelRatio(this.info.size.pixelRatio),this.renderer.setSize(this.info.size.canvasSize.x,this.info.size.canvasSize.y),this.camera.aspect=this.info.size.canvasAspectRatio,this.camera.updateProjectionMatrix(),this.info.wrapperElement&&(this.info.wrapperElementRect=this.info.wrapperElement.getBoundingClientRect())}pointerEvent(e){let t=new n.Vector2;if(t.copy(e.position),this.info.canvas){let e=this.info.canvas.getBoundingClientRect();t.sub(new n.Vector2(e.x,e.y))}const i=t.clone();i.divide(this.info.size.canvasSize),i.y=1-i.y,i.multiplyScalar(2).subScalar(1);const s={event:e.pointerEvent,position:t.clone(),delta:e.delta.clone(),normalizedPosition:i.clone(),windowPosition:e.position.clone()};"hover"==e.pointerEventType?this.onHover(s):"start"==e.pointerEventType?this.onTouchStart(s):"move"==e.pointerEventType?this.onTouchMove(s):"end"==e.pointerEventType&&this.onTouchEnd(s)}onTouchStart(e){}onTouchMove(e){}onTouchEnd(e){}onHover(e){}onWheel(e,t){}}const{Lethargy:r}=i(714),o=i(810);class a extends n.EventDispatcher{constructor(){super(),this.trackpadMemDelta=0,this.trackpadMax=!1,this.lethargy=new r(7,0,.05),this.position=new n.Vector2(NaN,NaN),this.delta=new n.Vector2(NaN,NaN);const e=navigator.userAgent;this.isSP=e.indexOf("iPhone")>=0||e.indexOf("iPad")>=0||e.indexOf("Android")>=0||"iPad"==navigator.platform||"MacIntel"==navigator.platform&&-1!=navigator.userAgent.indexOf("Safari")&&-1==navigator.userAgent.indexOf("Chrome")&&void 0!==navigator.standalone,window.addEventListener("touchstart",this.onTouch.bind(this,"start"),{passive:!1}),window.addEventListener("touchmove",this.onTouch.bind(this,"move"),{passive:!1}),window.addEventListener("touchend",this.onTouch.bind(this,"end"),{passive:!1}),window.addEventListener("pointerdown",this.onPointer.bind(this,"start")),window.addEventListener("pointermove",this.onPointer.bind(this,"move")),window.addEventListener("pointerup",this.onPointer.bind(this,"end")),window.addEventListener("dragend",this.onPointer.bind(this,"end")),window.addEventListener("wheel",this.wheel.bind(this),{passive:!1}),this.position.set(NaN,NaN),this.isTouching=!1}getNormalizePosition(e){if(this.position.x!=this.position.x)return new n.Vector2(NaN,NaN);const t=this.position.clone().divide(e).multiplyScalar(2).subScalar(1);return t.y*=-1,t}getRelativePosition(e,t){const i=e.getClientRects()[0];let s=this.position.x-i.left,r=this.position.y-i.top;return t&&(s/=i.width,r/=i.height),new n.Vector2(s,r)}setPos(e,t){this.position.x!=this.position.x||this.position.y!=this.position.y?this.delta.set(0,0):this.delta.set(e-this.position.x,t-this.position.y),this.position.set(e,t)}onTouch(e,t){const i=t.touches[0];i?this.touchEventHandler(i.pageX,i.pageY,e,t):"end"==e&&this.touchEventHandler(NaN,NaN,e,t)}onPointer(e,t){const i=t.pointerType;null!=i&&("mouse"!=i||-1!=t.button&&0!=t.button)||this.touchEventHandler(t.pageX,t.pageY,e,t)}touchEventHandler(e,t,i,n){let s=!1;const r=e-window.pageXOffset,o=t-window.pageYOffset;"start"==i?(this.isTouching=!0,this.setPos(r,o),this.delta.set(0,0),s=!0):"move"==i?(this.setPos(r,o),this.isTouching&&(s=!0)):"end"==i&&(this.isTouching=!1,s=!0),s&&this.dispatchEvent({type:"update",pointerEvent:n,pointerEventType:i,position:this.position.clone(),delta:this.delta.clone()})}update(){this.isSP||this.dispatchEvent({type:"update",pointerEvent:null,pointerEventType:"hover",position:this.position.clone(),delta:this.delta.clone()})}wheel(e){let t=e.deltaY,i=0;switch(e.deltaMode){case e.DOM_DELTA_LINE:t*=2.5*o("ex",window);break;case e.DOM_DELTA_PAGE:t*=window.innerHeight}this.lethargy.check(e)&&(i=t),this.dispatchEvent({type:"wheel",wheelEvent:e,trackpadDelta:i})}}class l extends n.EventDispatcher{constructor(e){super(),this.layers=[],e&&e.silent||console.log("%c- ore-three "+i(306).i8+" -","padding: 5px 10px ;background-color: black; color: white;font-size:11px"),this.clock=new n.Clock,this.pointer=new a;let t=this.pointerEvent.bind(this),s=this.onWheel.bind(this),r=this.onOrientationDevice.bind(this),o=this.onWindowResize.bind(this);this.pointer.addEventListener("update",t),this.pointer.addEventListener("wheel",s),window.addEventListener("orientationchange",r),window.addEventListener("resize",o),this.addEventListener("dispose",(()=>{this.pointer.removeEventListener("update",t),this.pointer.removeEventListener("wheel",s),window.removeEventListener("orientationchange",r),window.removeEventListener("resize",o)})),this.tick()}tick(){const e=this.clock.getDelta();this.pointer.update();for(let t=0;t<this.layers.length;t++)this.layers[t].tick(e);requestAnimationFrame(this.tick.bind(this))}onWindowResize(){for(let e=0;e<this.layers.length;e++)this.layers[e].onResize()}onOrientationDevice(){this.onWindowResize()}pointerEvent(e){for(let t=0;t<this.layers.length;t++)this.layers[t].pointerEvent(e)}onWheel(e){for(let t=0;t<this.layers.length;t++)this.layers[t].onWheel(e.wheelEvent,e.trackpadDelta)}addLayer(e,t){for(;this.getLayer(t.name);)t.name+="_";this.layers.push(e),e.onBind(t)}getLayer(e){for(let t=0;t<this.layers.length;t++)if(this.layers[t].info.name==e)return this.layers[t];return null}removeLayer(e){for(let t=this.layers.length-1;t>=0;t--){const i=this.layers[t];i.info.name==e&&(i.onUnbind(),this.layers.splice(t,1))}}dispose(){this.layers.forEach((e=>{this.removeLayer(e.info.name)})),this.tick=()=>{},this.dispatchEvent({type:"dispose"})}}var h,c,u;!function(e){e.sigmoid=function(e,...t){let i=6;t[0]&&(i=t[0]);var n=Math.exp(-i*(2*e-1)),s=Math.exp(-i);return(1+(1-n)/(1+n)*(1+s)/(1-s))/2},e.smoothstep=function(e,t,i){let n=Math.max(0,Math.min(1,i-e/(t-e)));return n*n*(3-2*n)},e.lerpNumber=function(e,t,i){return(1-i)*e+i*t},e.linear=function(e){return e},e.easeInQuad=function(e){return e*e},e.easeOutQuad=function(e){return e*(2-e)},e.easeInOutQuad=function(e){return e<.5?2*e*e:(4-2*e)*e-1},e.easeInCubic=function(e){return e*e*e},e.easeOutCubic=function(e){return--e*e*e+1},e.easeInOutCubic=function(e){return e<.5?4*e*e*e:(e-1)*(2*e-2)*(2*e-2)+1},e.easeInQuart=function(e){return e*e*e*e},e.easeOutQuart=function(e){return 1- --e*e*e*e},e.easeInOutQuart=function(e){return e<.5?8*e*e*e*e:1-8*--e*e*e*e},e.easeInQuint=function(e){return e*e*e*e*e},e.easeOutQuint=function(e){return 1+--e*e*e*e*e},e.easeInOutQuint=function(e){return e<.5?16*e*e*e*e*e:1+16*--e*e*e*e*e}}(h||(h={})),function(e){e.number=function(e,t,i){return e+(t-e)*i},e.numberArray=function(e,t,i){if(e.length==t.length){let n=[];for(let s=0;s<e.length;s++)n.push(e[s]+(t[s]-e[s])*i);return n}return console.log("Different length Arrays!!!"),!1},e.THREEVectors=function(e,t,i){return e.clone().lerp(t,i)},e.THREEQuaternion=function(e,t,i){return e.clone().slerp(t,i)},e.THREEEuler=function(e,t,i){let n=e.clone(),s=t.clone();return n.x=n.x+(s.x-n.x)*i,n.y=n.y+(s.y-n.y)*i,n.z=n.z+(s.z-n.z)*i,n},e.getLerpFunc=function(t){return"number"==typeof t?e.number:t instanceof Array&&"number"==typeof t[0]?e.numberArray:t.isVector2|t.isVector3|t.isVector4|t.isColor?e.THREEVectors:t.isQuaternion?e.THREEQuaternion:t.isEuler?e.THREEEuler:void 0}}(c||(c={}));class d extends n.EventDispatcher{constructor(){super(),this._isAnimating=!1,this.animatingCount=0,this.dispatchEvents=[],this.variables={}}get isAnimating(){return this._isAnimating}add(e){let t=e.customLerpFunc||c.getLerpFunc(e.initValue),i={time:-1,value:e.initValue,startValue:e.initValue,goalValue:null,easing:e.easing||{func:h.sigmoid,args:6},lerpFunc:t};return this.variables[e.name]=i,i}setEasing(e,t){let i=this.variables[e];i?i.easing=t:console.warn('"'+e+'" is not exist')}animate(e,t,i=1,n,s){let r=this.variables[e];return new Promise((o=>{if(r){if(i<=0)return this.setValue(e,t),r.time=1,void(r.onAnimationFinished=()=>{n&&n(),o(null)});-1==r.time&&(this._isAnimating=!0,this.animatingCount++),r.time=0,r.duration=i,r.startValue=r.value,r.goalValue=t,r.onAnimationFinished=()=>{n&&n(),o(null)},s&&this.setEasing(e,s)}else console.warn('"'+e+'" is not exist')}))}cancelAnimate(e){let t=this.variables[e];t?(t.time=1,t.onAnimationFinished=null):console.warn('"'+e+'" is not exist')}setValue(e,t){if(!this.variables[e])return console.warn('"'+e+'" is not exist'),null;this.variables[e].value=t,this.cancelAnimate(e)}get(e){return this.variables[e]?this.variables[e].value:(console.warn('"'+e+'" is not exist'),null)}getVariableObject(e,t=!1){return this.variables[e]?this.variables[e]:(t||console.warn('"'+e+'" is not exist'),null)}isAnimatingVariable(e,t=!1){return this.variables[e]?-1!=this.variables[e].time:(t||console.warn('"'+e+'" is not exist'),null)}applyToUniforms(e){let t=Object.keys(this.variables);for(let i=0;i<t.length;i++){let n=this.getVariableObject(t[i]);n&&(e[t[i]]=n)}}update(e){0==this.animatingCount&&(this._isAnimating=!1);let t=Object.keys(this.variables);for(let i=0;i<t.length;i++){let n=this.variables[t[i]],s=n.time;if(1==s&&(this.animatingCount--,s=-1,n.onAnimationFinished&&this.dispatchEvents.push(n.onAnimationFinished)),s>=0&&s<1){let r=n.duration,o=n.easing,a=n.lerpFunc;r&&(s+=(e||.016)/r,(0==r||s>=1)&&(s=1)),a&&(n.value=a(n.startValue,n.goalValue,o.func(s,o.args))),1==s&&(n.value=n.goalValue),this.dispatchEvent({type:"update/"+t[i],deltaTime:e,value:n.value})}n.time=s}for(;0!=this.dispatchEvents.length;){let e=this.dispatchEvents.pop();e&&e()}this.dispatchEvent({type:"update",deltaTime:e}),this._isAnimating&&this.dispatchEvent({type:"animate",deltaTime:e})}}class p extends n.Mesh{constructor(e){let t=new n.BufferGeometry,i=[],s=[],r=[];i.push(-1,1,0),i.push(1,1,0),i.push(1,-1,0),i.push(-1,-1,0),r.push(0,1),r.push(1,1),r.push(1,0),r.push(0,0),s.push(0,2,1,0,3,2);let o=new Float32Array(i),a=new Uint32Array(s),l=new Float32Array(r);t.setAttribute("position",new n.BufferAttribute(o,3)),t.setAttribute("uv",new n.BufferAttribute(l,2)),t.setIndex(new n.BufferAttribute(a,1)),e.vertexShader=e.vertexShader||"#define GLSLIFY 1\nvarying vec2 vUv;\nvarying vec4 vColor;\n\nvoid main( void ) {\n    \n    vec3 pos = position;\n\n    pos.z = 1.0;\n    \n    gl_Position = vec4( pos, 1.0 );\n    \n    vUv = uv;\n    vColor = vec4( 1.0 );\n\n}",e.transparent=null==e.transparent||e.transparent,e.depthFunc=null!=e.depthFunc?e.depthFunc:n.NeverDepth,super(t,new n.ShaderMaterial(e)),this.uniforms=e.uniforms||{},this.frustumCulled=!1}resize(e){this.uniforms.resolution={value:e.canvasSize},this.uniforms.aspectRatio={value:e.canvasAspectRatio}}}!function(e){e.mergeUniforms=function(...e){let t={};for(let i=0;i<e.length;i++)null!=e[i]&&Object.assign(t,e[i]);return t}}(u||(u={}));class m extends n.Mesh{constructor(e,t){let i=new n.PlaneBufferGeometry(2,2);t.vertexShader="#define GLSLIFY 1\nvarying vec2 vUv;\nuniform vec2 domPos;\nuniform vec2 domSize;\nuniform vec2 windowSize;\nuniform float aspectRatio;\n\nvoid main(  )\n{\n  float width = domSize.x / windowSize.x;\n\n  //左上( 0,0 )に\n  vec3 pos = position + vec3( 1.0,-1.0,0.0 );\n\n  //size\n  pos.x *= width;\n  pos.y *= ( width * aspectRatio ) * ( domSize.y / domSize.x );\n\n  pos += vec3( -1.0, 1.0, 0.0 );\n\n  pos += vec3( domPos.x / windowSize.x * 2.0, -domPos.y / windowSize.y * 2.0, 0.0 );\n\n  gl_Position = vec4( pos, 1.0 );\n  vUv = uv;\n}\n";let s=u.mergeUniforms(t.uniforms,{domPos:{value:new n.Vector2},domSize:{value:new n.Vector2},windowSize:{value:new n.Vector2},aspectRatio:{value:1}});t.uniforms=s,super(i,new n.ShaderMaterial(t)),this.frustumCulled=!1,this._uniforms=s,this.element=e,this.update()}get uniforms(){return this._uniforms}update(){let e=this.element.getBoundingClientRect();this._uniforms.windowSize.value.set(window.innerWidth,window.innerHeight),this._uniforms.aspectRatio.value=window.innerWidth/window.innerHeight,this._uniforms.domSize.value.set(e.width,e.height),this._uniforms.domPos.value.set(e.left,e.top)}}class f{constructor(){this.events=[]}addEventListener(e,t){this.events.push({type:e,listener:t})}dispatchEvent(e){e.target=this;for(let t=0;t<this.events.length;t++)e.type==this.events[t].type&&this.events[t].listener(e)}removeEventListener(e,t){for(let i=this.events.length;i>=0;i--)e==this.events[i].type&&t==this.events[i].listener&&this.events.splice(i,1)}}class g{constructor(e,t){this.renderTargets=[],this.renderer=e,this.dataSize=t.clone(),this.uniforms={dataSize:{value:this.dataSize}},this.tempDataLinear=this.createData({minFilter:n.LinearFilter,magFilter:n.LinearFilter}),this.tempDataNear=this.createData({minFilter:n.NearestFilter,magFilter:n.NearestFilter}),this.scene=new n.Scene,this.camera=new n.Camera,this.materials=[],this.mesh=new n.Mesh(new n.PlaneBufferGeometry(2,2)),this.scene.add(this.mesh)}get isSupported(){return this.renderer.extensions.get("OES_texture_float")}createInitializeTexture(){let e=new Float32Array(this.uniforms.dataSize.value.x*this.uniforms.dataSize.value.y*4),t=new n.DataTexture(e,this.uniforms.dataSize.value.x,this.uniforms.dataSize.value.y,n.RGBAFormat,n.FloatType);return t.needsUpdate=!0,t}createData(e,t){let i=navigator.userAgent,s=i.indexOf("iPhone")>=0||i.indexOf("iPad")>=0||"iPad"==navigator.platform||"MacIntel"==navigator.platform&&-1!=navigator.userAgent.indexOf("Safari")&&-1==navigator.userAgent.indexOf("Chrome")&&void 0!==navigator.standalone,r={wrapS:n.ClampToEdgeWrapping,wrapT:n.ClampToEdgeWrapping,minFilter:n.NearestFilter,magFilter:n.NearestFilter,format:n.RGBAFormat,type:s?n.HalfFloatType:n.FloatType,stencilBuffer:!1,depthBuffer:!1},o=null,a=null;e&&(e.isDataTexture?(o=e,t&&(a=t)):a=e),a&&(r.wrapS=a.wrapS||r.wrapS,r.wrapT=a.wrapT||r.wrapT,r.minFilter=a.minFilter||r.minFilter,r.magFilter=a.magFilter||r.magFilter,r.format=a.format||r.format,r.type=a.type||r.type,r.stencilBuffer=a.stencilBuffer||r.stencilBuffer,r.depthBuffer=a.depthBuffer||r.depthBuffer);let l=new n.WebGLRenderTarget(this.uniforms.dataSize.value.x,this.uniforms.dataSize.value.y,r),h={buffer:l};if(this.renderTargets.push(l),o){let e=this.createKernel({fragmentShader:"#define GLSLIFY 1\nuniform sampler2D tex;\nvarying vec2 vUv;\n\nvoid main() {\n    gl_FragColor = texture2D(tex,vUv);\n}",uniforms:{tex:{value:o}}});this.compute(e,h)}return h}createKernel(e){let t=u.mergeUniforms(e.uniforms,{});t=u.mergeUniforms(this.uniforms,t),e.vertexShader=e.vertexShader||"#define GLSLIFY 1\nvarying vec2 vUv;\n\nvoid main() {\n    gl_Position = vec4( position, 1.0 );\n    vUv = uv;\n}";let i=new n.ShaderMaterial(e);return this.materials.push(i),{material:i,uniforms:t}}compute(e,t,i){let s;s=t.buffer.texture.magFilter==n.LinearFilter?this.tempDataLinear:this.tempDataNear,this.mesh.material=e.material;let r=this.renderer.getRenderTarget();this.renderer.setRenderTarget(s.buffer),this.renderer.render(this.scene,i||this.camera),this.swapBuffers(t,s),this.renderer.setRenderTarget(r)}swapBuffers(e,t){let i=e.buffer;e.buffer=t.buffer,t.buffer=i}dispose(){this.mesh.geometry.dispose();for(let e=0;e<this.materials.length;e++)this.materials[e].dispose();this.scene.remove(this.mesh),this.tempDataLinear.buffer.dispose(),this.tempDataNear.buffer.dispose()}resizeData(e){this.dataSize.copy(e);for(let t=0;t<this.renderTargets.length;t++)this.renderTargets[t].setSize(e.x,e.y)}}class v{constructor(e){this.target=e,this.scrollVel=new n.Vector2}update(){this.scrollVel.multiplyScalar(.96);let e=new n.Vector3(this.scrollVel.y,this.scrollVel.x,0).normalize(),t=(new n.Quaternion).setFromAxisAngle(e,this.scrollVel.length());t.multiply(this.target.quaternion),this.target.quaternion.copy(t)}addVelocity(e){this.scrollVel.addVectors(this.scrollVel,e.multiplyScalar(.001))}}class w{constructor(e,t){this.renderer=e,this.scene=new n.Scene,this.camera=new n.OrthographicCamera(-1,1,1,-1),this.screen=new n.Mesh(new n.PlaneBufferGeometry(2,2)),this.scene.add(this.screen),t.vertexShader=t.vertexShader||"#define GLSLIFY 1\nvarying vec2 vUv;\nvoid main() {\n    vUv = uv;\n    gl_Position = vec4( position, 1.0 );\n}   ",t.uniforms=t.uniforms||{},t.uniforms.resolution={value:new n.Vector2},this.effect={material:new n.ShaderMaterial(t)}}render(e,t=null){let i=this.renderer.getRenderTarget(),n=this.effect,s=n.material,r=s.uniforms;if(e){let t=Object.keys(e);for(let i=0;i<t.length;i++)r[t[i]]?r[t[i]].value=e[t[i]]:(r[t[i]]={value:e[t[i]]},n.material.needsUpdate=!0,n.material.uniforms=r)}t?r.resolution.value.set(t.width,t.height):this.renderer.getSize(r.resolution.value),this.screen.material=s,this.renderer.setRenderTarget(t),this.renderer.render(this.scene,this.camera),this.renderer.setRenderTarget(i)}}class y{constructor(e){this.isAutoMove=!1,this.delaySpeed=.1,this.dragDelaySpeed=.4,this.isTouching=!1,this.deltaMem=0,this.scrollReady=!1,this.sumDelta=0,this._scrollPos=0,this._scrollPosMem=0,this._scrollPercentage=0,this._scrollPosDelay=0,this._scrollPercentageDelay=0,this.dragStop=!1,this.dragUnlockReady=!0,this.parentElement=e,this.parentElementHeight=e.getBoundingClientRect().height,this.sections=[],this.caughtSection=null,this.animator=new d,this.animator.add({name:"scrollPos",initValue:0,easing:{func:h.sigmoid,args:4}})}get scrollPos(){return this._scrollPos}get scrollPosDelay(){return this._scrollPosDelay}get scrollPercentage(){return this._scrollPercentage}get scrollPercentageDelay(){return this._scrollPercentageDelay}get scrollTimelinePercentage(){let e=0;for(let t=0;t<this.sections.length;t++){let i=this.sections[t],n=this.sections[t-1],s=1-Math.max(0,i.element.offsetTop-this.scrollPosDelay+(i.bottom?i.rect.height-window.innerHeight:0))/((n?n.rect.height-(n.bottom?window.innerHeight:0):0)+(i.bottom?i.rect.height-window.innerHeight:0)||1);if(s=Math.max(0,s),e+=s,s<1)break}return e/this.sections.length}add(e){return this.sections.push(e),this.sortSections(),e}sortSections(){this.sections.sort(((e,t)=>e.rect.y>t.rect.y?1:-1));for(let e=0;e<this.sections.length;e++)this.sections[e].timelinePercentage=(e+1)/this.sections.length}get(e){for(let t=0;t<this.sections.length;t++)if(this.sections[t].name==e)return this.sections[t];return console.warn('section "'+e+'" is not exist.'),null}update(e){this.updateParentElement(),this.updateScrollPos(e),this.applyParentElementTransform(),this.sumDelta=0}updateScrollPos(e){this.updateAutoMove(e),this.addScrollPos(),this.calcScrollProperties(e)}updateAutoMove(e){if(this.animator.update(e),this.isAutoMove){let e=this.animator.get("scrollPos");e&&(this.sumDelta=e-this.scrollPos)}}addScrollPos(){if(this.checkUnlockStopScroll(this.sumDelta)){let e=this.checkThrow(this.sumDelta);null!==e?this._scrollPos=e:this._scrollPos+=this.sumDelta,this._scrollPos=Math.max(Math.min(this._scrollPos,this.parentElementHeight-window.innerHeight),0)}}checkUnlockStopScroll(e){let t=0,i=!1;if(this.caughtSection){let n=this.scrollPos-this.scrollPosDelay;if((e*n<0||Math.abs(n)<10||this.isAutoMove)&&(e<0?(-e>(this.caughtSection.startScrollUp||0)||this.isAutoMove)&&(t=-1):e>0&&(e>(this.caughtSection.startScrollDown||0)||this.isAutoMove)&&(t=1)),0!=t&&this.caughtSection.events&&this.caughtSection.events.onStartScroll){let i,n={scroller:this,section:this.caughtSection,scrollMode:this.isAutoMove?"auto":"manual",scrollDelta:e,scrollPower:Math.abs(e)},s=this.caughtSection.events.onStartScroll.common&&this.caughtSection.events.onStartScroll.common(n);-1==t&&(i=this.caughtSection.events.onStartScroll.up&&this.caughtSection.events.onStartScroll.up(n)),1==t&&(i=this.caughtSection.events.onStartScroll.down&&this.caughtSection.events.onStartScroll.down(n)),!1!==s&&!1!==i||(t=0)}i=0!=t}else i=!0;return t&&(this.caughtSection=null),i}checkThrow(e){for(let t=0;t<this.sections.length;t++){let i=this.sections[t];i.updateRect(this._scrollPos);let n=this.checkThrowSectionEvents(i,e);if(null!==n)return this.caughtSection=i,this.isAutoMove?null:n}return null}checkThrowSectionEvents(e,t){let i=e.getScrollPercentage(),n=e.getScrollPercentage(t);if(e.events){let s={scroller:this,section:e,scrollMode:this.isAutoMove?"auto":"manual",scrollDelta:t,scrollPower:Math.abs(t)};if(e.events.onArrivals)for(let t=0;t<e.events.onArrivals.length;t++){let r=e.events.onArrivals[t],o=this.checkThrowLine(i,n,r.percentage);0!=o&&(r.event.common&&r.event.common(s),o<0?r.event.up&&r.event.up(s):r.event.down&&r.event.down(s))}}return e.stop&&this.checkThrowLine(i,n,1)?(this.dragUnlockReady=!1,e.element.offsetTop+(e.bottom?e.rect.height-window.innerHeight:0)):null}checkThrowLine(e,t,i){return e<i&&i<=t?1:e>i&&i>=t?-1:e==i&&i==t?2:0}calcScrollProperties(e){this._scrollPosDelay+=(this._scrollPos-this._scrollPosDelay)*(this.isTouching&&!this.caughtSection?this.dragDelaySpeed:this.delaySpeed)*Math.min(1,60*e),this._scrollPercentage=this.scrollPosToPerecntage(this.scrollPos),this._scrollPercentageDelay=this.scrollPosToPerecntage(this.scrollPosDelay)}scrollPosToPerecntage(e){return e/(this.parentElementHeight-window.innerHeight)}updateParentElement(){this.parentElementHeight=this.parentElement.getBoundingClientRect().height}applyParentElementTransform(){this.parentElement.style.transform="translate3d( 0,"+-this.scrollPosDelay.toString()+"px, 0 )"}scroll(e){this.deltaMem=(this.deltaMem+e)/2,this.sumDelta+=e}catch(){this.isAutoMove||(this.isTouching=!0,this.deltaMem=0,this.caughtSection||(this._scrollPos=this._scrollPosDelay))}drag(e){this.isTouching&&this.scroll(e)}release(e=10){this.isTouching&&(this.isTouching=!1,this.caughtSection||this.scroll(this.deltaMem*e))}autoMove(e){let t=0;if(e.target.isPageScrollerSection){let i=e.target,n=e.bottom?i.rect.height-window.innerHeight:0;t=i.element.offsetTop+n}else if("string"==typeof e.target){let i=this.get(e.target);if(i){let n=e.bottom?i.rect.height-window.innerHeight:0;t=i.element.offsetTop+n}}else"number"==typeof e.target&&(t=e.target);this.animator.setValue("scrollPos",this._scrollPos),this.animator.animate("scrollPos",t,e.duration,(()=>{e.callBack&&e.callBack(),this.isAutoMove=!1}),e.easing),this.sumDelta=(t-this.sumDelta)/Math.abs(t-this.sumDelta)*1e-5,this.isAutoMove=!0}}class S{constructor(e){this.timelinePercentage=0,this.name=e.name,this.element=e.element,this.rect=this.element.getBoundingClientRect(),this.stop=e.stop,this.events=e.events,this.bottom=e.bottom,this.startScrollDown=e.startScrollDown||0,this.startScrollUp=e.startScrollUp||0,this.updateRect(0)}get isPageScrollerSection(){return!0}updateRect(e){this.rect={x:this.element.offsetLeft,y:this.element.offsetTop-e,width:this.element.offsetWidth,height:this.element.offsetHeight}}getScrollPercentage(e){let t=this.bottom?this.rect.height-window.innerHeight:0,i=this.rect.y+t-(e||0),n=this.bottom?this.rect.height:window.innerHeight,s=Math.min(1,1-i/n),r=this.bottom?window.innerHeight:this.rect.height;return s+Math.max(0,-i/r)}}class b{constructor(e,t,i){this.obj=e,this.baseTransform={position:this.obj.position.clone(),rotation:this.obj.quaternion.clone(),scale:this.obj.scale.clone()},this.transform=t,i||(this.transform.position&&this.transform.position.add(this.obj.position),this.transform.rotation&&this.transform.rotation.multiply(this.obj.quaternion))}updateTransform(e){this.transform.position&&this.obj.position.copy(this.baseTransform.position.clone().lerp(this.transform.position,e)),this.transform.rotation&&this.obj.quaternion.copy(this.baseTransform.rotation.clone().slerp(this.transform.rotation,e)),this.transform.scale&&this.obj.scale.copy(this.baseTransform.scale.clone().multiplyScalar(this.transform.scale*e+1-e))}}class x{constructor(){this.variables={},this.time=0}add(e){if(0!=e.keyframes.length)return this.variables[e.name]={keyframes:e.keyframes,lerpFunc:e.customLerp,easing:e.easing,value:null},this.variables[e.name].keyframes.sort(((e,t)=>e.time<t.time?-1:1)),this.variables[e.name].lerpFunc||(this.variables[e.name].lerpFunc=c.getLerpFunc(e.keyframes[0].value)),this.calc(),e.name;console.warn('"'+e.name+'"',"Keyframe length is 0!!")}get(e){return this.variables[e]?this.variables[e].value:(console.warn('"'+e+'" is not exist'),null)}getVariableObject(e){return this.variables[e]?this.variables[e]:(console.warn('"'+e+'" is not exist'),null)}update(e){this.time=e,this.calc()}calc(){let e=Object.keys(this.variables);for(let t=0;t<e.length;t++){let i=this.variables[e[t]],n=i.keyframes,s=null,r=null,o=Math.max(n[0].time,Math.min(n[n.length-1].time,this.time)),a=null;if(1==n.length)o=n[0].time,s=r=n[0];else{for(let e=0;e<n.length-1&&(s=n[e],r=n[e+1],a=s.easing,!(s.time<=o&&o<=r.time));e++);null!=s&&null!=r&&(o=(o-s.time)/(r.time-s.time))}a?o=a.func(o,a.args):i.easing?o=i.easing.func(o,i.easing.args):this.defaultEasing&&(o=this.defaultEasing.func(o,this.defaultEasing.args)),i.lerpFunc?(null!=s&&null!=r&&(i.value=i.lerpFunc(s.value,r.value,o)),!1===i.value&&console.log('error at "'+e[t]+'"')):console.warn('"'+e[t]+'"',"lerp function is not set.")}}}},306:e=>{"use strict";e.exports={i8:"2.0.6"}},807:t=>{"use strict";t.exports=e}},i={};function n(e){if(i[e])return i[e].exports;var s=i[e]={exports:{}};return t[e].call(s.exports,s,s.exports,n),s.exports}return n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n(250)})()}));