function GSSeqinit(t,e=!1,a=!1,r=""){let i=r||document;var g={};if(t.getAttribute("data-triggertype"))var s=t.getAttribute("data-triggertype");else var s="scroll";let d=[],n=t.getAttribute("data-imagesexternal"),u=[];if(!(d=n?(n=n.trim()).split(","):JSON.parse(t.getAttribute("data-images"))).length)return;d.forEach(t=>{let e=new Image;e.src=t.trim(),u.push(e)});let l=t;gsap.set(l,{attr:{"data-index":0}});let o={};if(t.getAttribute("data-delay")&&(o.delay=parseFloat(t.getAttribute("data-delay"))),t.getAttribute("data-duration")&&(o.duration=parseFloat(t.getAttribute("data-duration"))),"none"==t.getAttribute("data-ease"))o.ease="none";else if(t.getAttribute("data-ease")){let c=t.getAttribute("data-ease").split("-");o.ease=c[0]+"."+c[1]}o.immediateRender=!0,o.attr={"data-index":d.length-1},o.snap="data-index";let b=t.getAttribute("data-rendertype"),A=b&&"canvas"==b?t.querySelector("canvas"):"",p=A?A.getContext("2d"):"";if(A){A.width=t.getAttribute("data-canvaswidth"),A.height=t.getAttribute("data-canvasheight");let f=()=>{p.clearRect(0,0,A.width,A.height),p.drawImage(u[0],0,0)};u[0].onload=f}o.onUpdate=function(){if(A){let e=A.parentNode.getAttribute("data-index");p.clearRect(0,0,A.width,A.height),p.drawImage(u[e],0,0)}else{let a=t.querySelector("img").parentNode.getAttribute("data-index");t.querySelector("img").setAttribute("src",d[a])}};let m=gsap.timeline();if(m.to(l,o),"yes"==t.getAttribute("data-loop")&&("yes"==t.getAttribute("data-yoyo")&&m.yoyo(!0),m.repeat(-1),t.getAttribute("data-delay")&&"yes"==t.getAttribute("repeat-delay")&&m.repeatDelay(parseFloat(t.getAttribute("data-delay")))),"load"==s||e)m.play();else if("hover"==s){let y="";if(t.getAttribute("data-customtrigger")){if(0==t.getAttribute("data-customtrigger").indexOf("#")||0==t.getAttribute("data-customtrigger").indexOf("."))var v=t.getAttribute("data-customtrigger");else var v="#"+t.getAttribute("data-customtrigger");y=i.querySelector(v)}else y=t;m.pause(),m.reverse(),y&&(y.addEventListener("mouseenter",function(t){m.play()}),y.addEventListener("mouseleave",function(e){t.getAttribute("data-hoverpause")?m.pause():m.reverse()}))}else if("click"==s){let $="";if(t.getAttribute("data-customtrigger")){if(0==t.getAttribute("data-customtrigger").indexOf("#")||0==t.getAttribute("data-customtrigger").indexOf("."))var v=t.getAttribute("data-customtrigger");else var v="#"+t.getAttribute("data-customtrigger");$=i.querySelector(v)}else $=t;m.pause(),m.reverse(),$&&$.addEventListener("click",function(t){m.play()})}else{if(t.getAttribute("data-customtrigger")){if(0==t.getAttribute("data-customtrigger").indexOf("#")||0==t.getAttribute("data-customtrigger").indexOf("."))var v=t.getAttribute("data-customtrigger");else var v="#"+t.getAttribute("data-customtrigger")}else var v=t;if(g.trigger=v,t.getAttribute("data-triggerstart")?g.start=t.getAttribute("data-triggerstart"):t.getAttribute("data-triggerscrub")?g.start="clamp(top 92%)":g.start="top 92%",t.getAttribute("data-triggerend")&&(g.end=t.getAttribute("data-triggerend"),g.scrub=1,t.getAttribute("data-triggerscrub")&&(g.scrub=parseFloat(t.getAttribute("data-triggerscrub")))),t.getAttribute("data-pinned")&&(g.pin=!0),t.getAttribute("data-pinspace")&&(g.pinSpacing=!1),t.getAttribute("data-triggeraction")?g.toggleActions=t.getAttribute("data-triggeraction"):g.toggleActions="play pause resume reverse",g.animation=m,g.fastScrollEnd=!0,a)t.getAttribute("data-pinpreview")&&(g.pinType="fixed"),g.scroller=".interface-interface-skeleton__content";else if("yes"==t.getAttribute("data-scrollcontainer")&&t.closest(".gs-gsap-scrollx-wrap")){let h=gsap.getTweensOf(t.closest(".gs-gsap-scrollx-wrap"));g.containerAnimation=h[0]}"yes"==t.getAttribute("data-scrollernav")&&(g.scroller=t.closest(".gspb_pagenav")),ScrollTrigger.create(g)}}document.addEventListener("DOMContentLoaded",function(t){let e=document.getElementsByClassName("gs-sequencer-wrap");if(e.length>0)for(let a=0;a<e.length;a++)GSSeqinit(e[a])});