reacthub-pixitweenjs 0.2.107-alpha.22 → 0.2.107-alpha.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +4 -5
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -20913,6 +20913,7 @@ const L5 = re.forwardRef((t, e) => {
|
|
|
20913
20913
|
}
|
|
20914
20914
|
);
|
|
20915
20915
|
}), k5 = (t) => {
|
|
20916
|
+
var b;
|
|
20916
20917
|
const { startAt: e, endAt: r, uniqueId: n } = t, i = ge(null), a = ge(null), u = ge(null), l = ge(null), f = ge(!1), {
|
|
20917
20918
|
tl: p,
|
|
20918
20919
|
totalDuration: v = 0,
|
|
@@ -20933,7 +20934,7 @@ const L5 = re.forwardRef((t, e) => {
|
|
|
20933
20934
|
x > e && x < r ? (a.current && (a.current.alpha = 1), i.current && (i.current.alpha = 1)) : (a.current && (a.current.alpha = 0), i.current && (i.current.alpha = 0));
|
|
20934
20935
|
}
|
|
20935
20936
|
};
|
|
20936
|
-
ft(Ze.COMPLETE, () => {
|
|
20937
|
+
return ft(Ze.COMPLETE, () => {
|
|
20937
20938
|
}), re.useEffect(() => {
|
|
20938
20939
|
const x = wt.context(() => {
|
|
20939
20940
|
if (i.current && p.current) {
|
|
@@ -20957,13 +20958,11 @@ const L5 = re.forwardRef((t, e) => {
|
|
|
20957
20958
|
return () => {
|
|
20958
20959
|
l.current && (p.current.remove(l.current), l.current.progress(0).kill()), x.revert();
|
|
20959
20960
|
};
|
|
20960
|
-
}, [e, r, v, n])
|
|
20961
|
-
const b = () => p && p.current && p.current.time() > e && e > 0.2 ? m.current : e < 0.2 ? 1 : 0;
|
|
20962
|
-
return /* @__PURE__ */ Ce.jsx(
|
|
20961
|
+
}, [e, r, v, n]), console.log("current alpha with time", (b = i == null ? void 0 : i.current) == null ? void 0 : b.alpha), /* @__PURE__ */ Ce.jsx(
|
|
20963
20962
|
St,
|
|
20964
20963
|
{
|
|
20965
20964
|
ref: i,
|
|
20966
|
-
alpha:
|
|
20965
|
+
alpha: e < 0.2 ? 1 : 0,
|
|
20967
20966
|
eventMode: e < 0.2 ? "static" : "none",
|
|
20968
20967
|
children: /* @__PURE__ */ Ce.jsx(St, { ref: u, children: /* @__PURE__ */ Ce.jsx(St, { ref: a, alpha: 1, children: t.children }) })
|
|
20969
20968
|
}
|
package/dist/index.umd.js
CHANGED
|
@@ -1989,4 +1989,4 @@ __p += '`),Ie&&(G+=`' +
|
|
|
1989
1989
|
function print() { __p += __j.call(arguments, '') }
|
|
1990
1990
|
`:`;
|
|
1991
1991
|
`)+G+`return __p
|
|
1992
|
-
}`;var me=rv(function(){return ke(S,te+"return "+G).apply(r,C)});if(me.source=G,Kc(me))throw me;return me}function oD(s){return Ue(s).toLowerCase()}function uD(s){return Ue(s).toUpperCase()}function lD(s,o,h){if(s=Ue(s),s&&(h||o===r))return hm(s);if(!s||!(o=Yt(o)))return s;var g=wr(s),y=wr(o),S=fm(g,y),C=dm(g,y)+1;return gn(g,S,C).join("")}function cD(s,o,h){if(s=Ue(s),s&&(h||o===r))return s.slice(0,gm(s)+1);if(!s||!(o=Yt(o)))return s;var g=wr(s),y=dm(g,wr(o))+1;return gn(g,0,y).join("")}function hD(s,o,h){if(s=Ue(s),s&&(h||o===r))return s.replace(Kl,"");if(!s||!(o=Yt(o)))return s;var g=wr(s),y=fm(g,wr(o));return gn(g,y).join("")}function fD(s,o){var h=j,g=Q;if(lt(o)){var y="separator"in o?o.separator:y;h="length"in o?ge(o.length):h,g="omission"in o?Yt(o.omission):g}s=Ue(s);var S=s.length;if(Oi(s)){var C=wr(s);S=C.length}if(h>=S)return s;var R=h-Fi(g);if(R<1)return g;var M=C?gn(C,0,R).join(""):s.slice(0,R);if(y===r)return M+g;if(C&&(R+=M.length-R),Zc(y)){if(s.slice(R).search(y)){var U,$=M;for(y.global||(y=dc(y.source,Ue(Fg.exec(y))+"g")),y.lastIndex=0;U=y.exec($);)var G=U.index;M=M.slice(0,G===r?R:G)}}else if(s.indexOf(Yt(y),R)!=R){var q=M.lastIndexOf(y);q>-1&&(M=M.slice(0,q))}return M+g}function dD(s){return s=Ue(s),s&&SO.test(s)?s.replace(Pg,zF):s}var pD=$i(function(s,o,h){return s+(h?" ":"")+o.toUpperCase()}),eh=n0("toUpperCase");function tv(s,o,h){return s=Ue(s),o=h?r:o,o===r?BF(s)?XF(s):IF(s):s.match(o)||[]}var rv=_e(function(s,o){try{return Wt(s,r,o)}catch(h){return Kc(h)?h:new he(h)}}),gD=qr(function(s,o){return ir(o,function(h){h=kr(h),jr(s,h,qc(s[h],s))}),s});function mD(s){var o=s==null?0:s.length,h=ie();return s=o?it(s,function(g){if(typeof g[1]!="function")throw new sr(u);return[h(g[0]),g[1]]}):[],_e(function(g){for(var y=-1;++y<o;){var S=s[y];if(Wt(S[0],this,g))return Wt(S[1],this,g)}})}function vD(s){return z3(or(s,c))}function th(s){return function(){return s}}function _D(s,o){return s==null||s!==s?o:s}var yD=s0(),xD=s0(!0);function Vt(s){return s}function rh(s){return Lm(typeof s=="function"?s:or(s,c))}function bD(s){return Bm(or(s,c))}function wD(s,o){return Dm(s,or(o,c))}var TD=_e(function(s,o){return function(h){return Is(h,s,o)}}),SD=_e(function(s,o){return function(h){return Is(s,h,o)}});function nh(s,o,h){var g=St(o),y=xo(o,g);h==null&&!(lt(o)&&(y.length||!g.length))&&(h=o,o=s,s=this,y=xo(o,St(o)));var S=!(lt(h)&&"chain"in h)||!!h.chain,C=Kr(s);return ir(y,function(R){var M=o[R];s[R]=M,C&&(s.prototype[R]=function(){var U=this.__chain__;if(S||U){var $=s(this.__wrapped__),G=$.__actions__=Gt(this.__actions__);return G.push({func:M,args:arguments,thisArg:s}),$.__chain__=U,$}return M.apply(s,ln([this.value()],arguments))})}),s}function AD(){return Ct._===this&&(Ct._=ZF),this}function ih(){}function ED(s){return s=ge(s),_e(function(o){return Um(o,s)})}var CD=Lc(it),ID=Lc(am),RD=Lc(ac);function nv(s){return zc(s)?oc(kr(s)):sN(s)}function PD(s){return function(o){return s==null?r:Hn(s,o)}}var MD=o0(),OD=o0(!0);function sh(){return[]}function ah(){return!1}function FD(){return{}}function ND(){return""}function LD(){return!0}function kD(s,o){if(s=ge(s),s<1||s>ee)return[];var h=Y,g=Ft(s,Y);o=ie(o),s-=Y;for(var y=cc(g,o);++h<s;)o(h);return y}function BD(s){return de(s)?it(s,kr):Kt(s)?[s]:Gt(T0(Ue(s)))}function DD(s){var o=++YF;return Ue(s)+o}var UD=Eo(function(s,o){return s+o},0),$D=kc("ceil"),GD=Eo(function(s,o){return s/o},1),zD=kc("floor");function HD(s){return s&&s.length?yo(s,Vt,bc):r}function VD(s,o){return s&&s.length?yo(s,ie(o,2),bc):r}function XD(s){return lm(s,Vt)}function jD(s,o){return lm(s,ie(o,2))}function WD(s){return s&&s.length?yo(s,Vt,Ac):r}function qD(s,o){return s&&s.length?yo(s,ie(o,2),Ac):r}var YD=Eo(function(s,o){return s*o},1),KD=kc("round"),ZD=Eo(function(s,o){return s-o},0);function QD(s){return s&&s.length?lc(s,Vt):0}function JD(s,o){return s&&s.length?lc(s,ie(o,2)):0}return T.after=bk,T.ary=N0,T.assign=uB,T.assignIn=q0,T.assignInWith=Uo,T.assignWith=lB,T.at=cB,T.before=L0,T.bind=qc,T.bindAll=gD,T.bindKey=k0,T.castArray=Fk,T.chain=M0,T.chunk=zN,T.compact=HN,T.concat=VN,T.cond=mD,T.conforms=vD,T.constant=th,T.countBy=QL,T.create=hB,T.curry=B0,T.curryRight=D0,T.debounce=U0,T.defaults=fB,T.defaultsDeep=dB,T.defer=wk,T.delay=Tk,T.difference=XN,T.differenceBy=jN,T.differenceWith=WN,T.drop=qN,T.dropRight=YN,T.dropRightWhile=KN,T.dropWhile=ZN,T.fill=QN,T.filter=ek,T.flatMap=nk,T.flatMapDeep=ik,T.flatMapDepth=sk,T.flatten=C0,T.flattenDeep=JN,T.flattenDepth=eL,T.flip=Sk,T.flow=yD,T.flowRight=xD,T.fromPairs=tL,T.functions=xB,T.functionsIn=bB,T.groupBy=ak,T.initial=nL,T.intersection=iL,T.intersectionBy=sL,T.intersectionWith=aL,T.invert=TB,T.invertBy=SB,T.invokeMap=uk,T.iteratee=rh,T.keyBy=lk,T.keys=St,T.keysIn=Ht,T.map=Fo,T.mapKeys=EB,T.mapValues=CB,T.matches=bD,T.matchesProperty=wD,T.memoize=Lo,T.merge=IB,T.mergeWith=Y0,T.method=TD,T.methodOf=SD,T.mixin=nh,T.negate=ko,T.nthArg=ED,T.omit=RB,T.omitBy=PB,T.once=Ak,T.orderBy=ck,T.over=CD,T.overArgs=Ek,T.overEvery=ID,T.overSome=RD,T.partial=Yc,T.partialRight=$0,T.partition=hk,T.pick=MB,T.pickBy=K0,T.property=nv,T.propertyOf=PD,T.pull=cL,T.pullAll=R0,T.pullAllBy=hL,T.pullAllWith=fL,T.pullAt=dL,T.range=MD,T.rangeRight=OD,T.rearg=Ck,T.reject=pk,T.remove=pL,T.rest=Ik,T.reverse=jc,T.sampleSize=mk,T.set=FB,T.setWith=NB,T.shuffle=vk,T.slice=gL,T.sortBy=xk,T.sortedUniq=wL,T.sortedUniqBy=TL,T.split=nD,T.spread=Rk,T.tail=SL,T.take=AL,T.takeRight=EL,T.takeRightWhile=CL,T.takeWhile=IL,T.tap=HL,T.throttle=Pk,T.thru=Oo,T.toArray=X0,T.toPairs=Z0,T.toPairsIn=Q0,T.toPath=BD,T.toPlainObject=W0,T.transform=LB,T.unary=Mk,T.union=RL,T.unionBy=PL,T.unionWith=ML,T.uniq=OL,T.uniqBy=FL,T.uniqWith=NL,T.unset=kB,T.unzip=Wc,T.unzipWith=P0,T.update=BB,T.updateWith=DB,T.values=Hi,T.valuesIn=UB,T.without=LL,T.words=tv,T.wrap=Ok,T.xor=kL,T.xorBy=BL,T.xorWith=DL,T.zip=UL,T.zipObject=$L,T.zipObjectDeep=GL,T.zipWith=zL,T.entries=Z0,T.entriesIn=Q0,T.extend=q0,T.extendWith=Uo,nh(T,T),T.add=UD,T.attempt=rv,T.camelCase=HB,T.capitalize=J0,T.ceil=$D,T.clamp=$B,T.clone=Nk,T.cloneDeep=kk,T.cloneDeepWith=Bk,T.cloneWith=Lk,T.conformsTo=Dk,T.deburr=ev,T.defaultTo=_D,T.divide=GD,T.endsWith=VB,T.eq=Sr,T.escape=XB,T.escapeRegExp=jB,T.every=JL,T.find=tk,T.findIndex=A0,T.findKey=pB,T.findLast=rk,T.findLastIndex=E0,T.findLastKey=gB,T.floor=zD,T.forEach=O0,T.forEachRight=F0,T.forIn=mB,T.forInRight=vB,T.forOwn=_B,T.forOwnRight=yB,T.get=Qc,T.gt=Uk,T.gte=$k,T.has=wB,T.hasIn=Jc,T.head=I0,T.identity=Vt,T.includes=ok,T.indexOf=rL,T.inRange=GB,T.invoke=AB,T.isArguments=jn,T.isArray=de,T.isArrayBuffer=Gk,T.isArrayLike=zt,T.isArrayLikeObject=dt,T.isBoolean=zk,T.isBuffer=mn,T.isDate=Hk,T.isElement=Vk,T.isEmpty=Xk,T.isEqual=jk,T.isEqualWith=Wk,T.isError=Kc,T.isFinite=qk,T.isFunction=Kr,T.isInteger=G0,T.isLength=Bo,T.isMap=z0,T.isMatch=Yk,T.isMatchWith=Kk,T.isNaN=Zk,T.isNative=Qk,T.isNil=eB,T.isNull=Jk,T.isNumber=H0,T.isObject=lt,T.isObjectLike=ht,T.isPlainObject=Ns,T.isRegExp=Zc,T.isSafeInteger=tB,T.isSet=V0,T.isString=Do,T.isSymbol=Kt,T.isTypedArray=zi,T.isUndefined=rB,T.isWeakMap=nB,T.isWeakSet=iB,T.join=oL,T.kebabCase=WB,T.last=lr,T.lastIndexOf=uL,T.lowerCase=qB,T.lowerFirst=YB,T.lt=sB,T.lte=aB,T.max=HD,T.maxBy=VD,T.mean=XD,T.meanBy=jD,T.min=WD,T.minBy=qD,T.stubArray=sh,T.stubFalse=ah,T.stubObject=FD,T.stubString=ND,T.stubTrue=LD,T.multiply=YD,T.nth=lL,T.noConflict=AD,T.noop=ih,T.now=No,T.pad=KB,T.padEnd=ZB,T.padStart=QB,T.parseInt=JB,T.random=zB,T.reduce=fk,T.reduceRight=dk,T.repeat=eD,T.replace=tD,T.result=OB,T.round=KD,T.runInContext=P,T.sample=gk,T.size=_k,T.snakeCase=rD,T.some=yk,T.sortedIndex=mL,T.sortedIndexBy=vL,T.sortedIndexOf=_L,T.sortedLastIndex=yL,T.sortedLastIndexBy=xL,T.sortedLastIndexOf=bL,T.startCase=iD,T.startsWith=sD,T.subtract=ZD,T.sum=QD,T.sumBy=JD,T.template=aD,T.times=kD,T.toFinite=Zr,T.toInteger=ge,T.toLength=j0,T.toLower=oD,T.toNumber=cr,T.toSafeInteger=oB,T.toString=Ue,T.toUpper=uD,T.trim=lD,T.trimEnd=cD,T.trimStart=hD,T.truncate=fD,T.unescape=dD,T.uniqueId=DD,T.upperCase=pD,T.upperFirst=eh,T.each=O0,T.eachRight=F0,T.first=I0,nh(T,function(){var s={};return Nr(T,function(o,h){He.call(T.prototype,h)||(s[h]=o)}),s}(),{chain:!1}),T.VERSION=n,ir(["bind","bindKey","curry","curryRight","partial","partialRight"],function(s){T[s].placeholder=T}),ir(["drop","take"],function(s,o){Ae.prototype[s]=function(h){h=h===r?1:yt(ge(h),0);var g=this.__filtered__&&!o?new Ae(this):this.clone();return g.__filtered__?g.__takeCount__=Ft(h,g.__takeCount__):g.__views__.push({size:Ft(h,Y),type:s+(g.__dir__<0?"Right":"")}),g},Ae.prototype[s+"Right"]=function(h){return this.reverse()[s](h).reverse()}}),ir(["filter","map","takeWhile"],function(s,o){var h=o+1,g=h==V||h==ve;Ae.prototype[s]=function(y){var S=this.clone();return S.__iteratees__.push({iteratee:ie(y,3),type:h}),S.__filtered__=S.__filtered__||g,S}}),ir(["head","last"],function(s,o){var h="take"+(o?"Right":"");Ae.prototype[s]=function(){return this[h](1).value()[0]}}),ir(["initial","tail"],function(s,o){var h="drop"+(o?"":"Right");Ae.prototype[s]=function(){return this.__filtered__?new Ae(this):this[h](1)}}),Ae.prototype.compact=function(){return this.filter(Vt)},Ae.prototype.find=function(s){return this.filter(s).head()},Ae.prototype.findLast=function(s){return this.reverse().find(s)},Ae.prototype.invokeMap=_e(function(s,o){return typeof s=="function"?new Ae(this):this.map(function(h){return Is(h,s,o)})}),Ae.prototype.reject=function(s){return this.filter(ko(ie(s)))},Ae.prototype.slice=function(s,o){s=ge(s);var h=this;return h.__filtered__&&(s>0||o<0)?new Ae(h):(s<0?h=h.takeRight(-s):s&&(h=h.drop(s)),o!==r&&(o=ge(o),h=o<0?h.dropRight(-o):h.take(o-s)),h)},Ae.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Ae.prototype.toArray=function(){return this.take(Y)},Nr(Ae.prototype,function(s,o){var h=/^(?:filter|find|map|reject)|While$/.test(o),g=/^(?:head|last)$/.test(o),y=T[g?"take"+(o=="last"?"Right":""):o],S=g||/^find/.test(o);y&&(T.prototype[o]=function(){var C=this.__wrapped__,R=g?[1]:arguments,M=C instanceof Ae,U=R[0],$=M||de(C),G=function(we){var Ie=y.apply(T,ln([we],R));return g&&q?Ie[0]:Ie};$&&h&&typeof U=="function"&&U.length!=1&&(M=$=!1);var q=this.__chain__,te=!!this.__actions__.length,ae=S&&!q,me=M&&!te;if(!S&&$){C=me?C:new Ae(this);var oe=s.apply(C,R);return oe.__actions__.push({func:Oo,args:[G],thisArg:r}),new ar(oe,q)}return ae&&me?s.apply(this,R):(oe=this.thru(G),ae?g?oe.value()[0]:oe.value():oe)})}),ir(["pop","push","shift","sort","splice","unshift"],function(s){var o=no[s],h=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",g=/^(?:pop|shift)$/.test(s);T.prototype[s]=function(){var y=arguments;if(g&&!this.__chain__){var S=this.value();return o.apply(de(S)?S:[],y)}return this[h](function(C){return o.apply(de(C)?C:[],y)})}}),Nr(Ae.prototype,function(s,o){var h=T[o];if(h){var g=h.name+"";He.call(Bi,g)||(Bi[g]=[]),Bi[g].push({name:o,func:h})}}),Bi[Ao(r,w).name]=[{name:"wrapper",func:r}],Ae.prototype.clone=d3,Ae.prototype.reverse=p3,Ae.prototype.value=g3,T.prototype.at=VL,T.prototype.chain=XL,T.prototype.commit=jL,T.prototype.next=WL,T.prototype.plant=YL,T.prototype.reverse=KL,T.prototype.toJSON=T.prototype.valueOf=T.prototype.value=ZL,T.prototype.first=T.prototype.head,bs&&(T.prototype[bs]=qL),T},Ni=jF();Dn?((Dn.exports=Ni)._=Ni,rc._=Ni):Ct._=Ni}).call(At)}(Ya,Ya.exports);var xg=Ya.exports;const XM={isPlaying:!1,progress:0,speed:1,isMuted:!1,isWaiting:!1,loaded:!1,size:{width:50,height:50},isDragging:!1,totalFrames:0,totalDuration:0},bg=ne.forwardRef((t,e)=>{const[r,n]=ne.useState([]),[,i]=ne.useState(0),[a,u]=ne.useState([]),[,l]=W.useState(!1),[f,p]=LM({autoPlay:!1}),v=W.useRef(null),c=W.useRef(null),d=W.useRef(XM),m=W.useRef(),{tl:_,dragModeRef:b}=W.useContext(_n),{frames:x,delays:w}=f,{src:E,startAt:A,endAt:I,frameStartAt:O,frameEndAt:N,loop:L,visible:k,disabled:D,transformation:{width:j=0,height:Q=0,x:fe,y:H,animation:V,colorCorrection:le={}},pointerdown:ve}=t,{temperatureFilter:z,sharpnessFilter:ee,hueFilter:pe,blurFilter:X,adjustmentFilter:Y,vignetteFilter:ce,noiseFilter:Se}=_i(le),{blurRadius:xe=0,vignette:Me=0,noise:Oe=0}=le,Ge=.1;HM(E,p),ct(je.PAUSE,()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)}),ct(je.SEEK_END,()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)}),ct(je.SCRUBBER_CLICKED,()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)}),ne.useEffect(()=>{d.current&&v.current&&(b.current?(v.current.stop(),d.current.isPlaying=!1,d.current.isDragging=!0):d.current.isDragging=!1)},[b]),ne.useEffect(()=>{if(!$s(x)){const Le=hM(x,ut=>{const{data:rr,width:Ot,height:mt}=ut,Hr=new Uint8Array(rr);return Jt.Texture.fromBuffer(Hr,Ot,mt)}),J=Le.map((ut,rr)=>({texture:ut,time:w[rr]}));n(Le),u(J);let se=0;w.forEach(ut=>{se+=ut*10}),i(se),d.current.totalDuration=se,d.current.totalFrames=x.length}},[x,w]);const ze=xg.debounce(Le=>{if(v.current){let J=Le===0?0:Le/Ge;J=isNaN(J)?0:J;const se=d.current.totalFrames;J=J>se?se:J,J>=se?(v.current.gotoAndStop(0),d.current.isPlaying=!1):(v.current.gotoAndPlay(J||0),d.current.isPlaying=!0)}},20),Ke=xg.debounce(()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)},50),Ze=Le=>{if(v.current){let J=Le===0?0:Le/Ge;J=isNaN(J)?0:J;const se=d.current.totalFrames;J=J>se?se:J,J>=se?(v.current.gotoAndStop(0),d.current.isPlaying=!1):(v.current.gotoAndPlay(J||0),d.current.isPlaying=!0)}},be=()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)},De=()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)},Qe=Le=>{var se;const J=Le+((se=m.current)==null?void 0:se.time());v.current&&b.current?(ze(J),Ke(),d.current.isPlaying=!1):m.current&&v.current&&!d.current.isPlaying&&m.current.isActive()&&_.current.isActive()&&(ze(J),d.current.isPlaying=!0)},Je=()=>{l(!0)};return W.useEffect(()=>{let Le=xt.context(()=>{});if(c.current&&_.current){const J={duration:Number(N)-Number(O),onStart:Ze,onComplete:be,onStartParams:[O,N],onCompleteParams:[],onInterrupt:De,onUpdate:Qe,onUpdateParams:[O,N]};m.current&&m.current.kill(),Le=xt.context(()=>{m.current=xt.from(c.current,J,O),_.current.add(m.current,A)})}return()=>{m.current&&(m.current.kill(),xt.killTweensOf(m.current)),Le.revert()}},[V,A,I,O,N]),Ee.jsx(xn,{...t,ref:e,ignoreTlForVideo:!0,isGif:!0,children:Ee.jsx(Xe.Container,{ref:c,children:r&&r.length>0&&Ee.jsx(yg,{x:fe,y:H,width:j,height:Q,animationSpeed:1,alpha:k?1:0,loop:L,textures:a,onComplete:Je,anchor:.5,forwardRef:v,...!D&&k&&{interactive:!0,pointerdown:ve},filters:[z,ee,pe,Y,...xe>0?[X]:[],...Me>0?[ce]:[],...Oe>0?[Se]:[]]})})})});bg.whyDidYouRender={logOnDifferentValues:!0,customName:"PixiGifSprite"};const jM=ne.forwardRef((t,e)=>{const n=W.useRef(null),i=W.useRef(0),a=W.useRef(null),u=W.useRef(null),l=W.useRef(16),f=W.useRef(null),{visible:p,text:v,disabled:c,transformation:d,pointerdown:m,onDobuleClick:_}=t,{x:b,y:x,fontFamily:w="Arial",fontWeight:E="normal",fontStyle:A="normal",fontSize:I=16,fontVariant:O="normal",fill:N="black",stroke:L,strokeThickness:k=0,blurRadius:D=0,blurEnabled:j=!1,dropShadowColor:Q=null,dropShadow:fe=!1,dropShadowBlur:H=0,wordWrapWidth:V=5e7,leading:le=0,letterSpacing:ve,colorCorrection:z={}}=d,{temperatureFilter:ee,sharpnessFilter:pe,hueFilter:X,blurFilter:Y,adjustmentFilter:ce}=_i(z),{blurRadius:Se=0}=z;ne.useEffect(()=>{l.current=Number(I)},[I]);const xe=["italic","oblique"].includes(A)?A:void 0,Me=["small-caps"].includes(O),Oe=["bold","bolder","lighter","100","200","300"].includes(E)?E:void 0,Ge=Number(ve)>0?ve:void 0,ze=ne.useMemo(()=>new Jt.TextStyle({fontFamily:w,fontSize:I,fill:N||"white",...L&&k>0&&{stroke:L,strokeThickness:k},...xe&&{fontStyle:xe},...Me&&{fontVariant:Me},...Oe&&{fontWeight:Oe},...Ge&&{letterSpacing:Ge},...j&&{dropShadow:!0,dropShadowBlur:Number(D),dropShadowColor:(Q==null?void 0:Q.toString())||"black",dropShadowAngle:.5235987755982988,dropShadowDistance:5},...fe&&{dropShadow:!0,dropShadowBlur:Number(H),dropShadowColor:(Q==null?void 0:Q.toString())||"black",dropShadowAngle:.5235987755982988,dropShadowDistance:5},wordWrap:!0,breakWords:!0,wordWrapWidth:V||500,leading:le||0}),[j,D,N,w,I,A,le,xe,Oe,Me,Ge,Q,L,k,V,fe,H]);ne.useEffect(()=>{f.current={...d}},[d]);const Ke=()=>{const be=new Date().getTime();be-i.current<300&&_?_():m&&m(),i.current=be},Ze=()=>{!c&&_&&_()};return Ee.jsx(xn,{...t,ref:e,isText:!0,onDoubleClick:Ze,children:Ee.jsx(Xe.Container,{ref:n,children:Ee.jsx(Xe.Container,{alpha:1,ref:u,children:Ee.jsx(Xe.Text,{style:ze,x:b,y:x,anchor:.5,text:v,alpha:p?1:0,...p&&!c&&{interactive:!0,buttonMode:!0,pointerdown:Ke},ref:a,filters:[ee,pe,X,ce,...Se>0?[Y]:[]]})})})})});var WM=Er,qM=function(){return WM.Date.now()},YM=qM,KM=/\s/;function ZM(t){for(var e=t.length;e--&&KM.test(t.charAt(e)););return e}var QM=ZM,JM=QM,eO=/^\s+/;function tO(t){return t&&t.slice(0,JM(t)+1).replace(eO,"")}var rO=tO,nO=rO,wg=ji,iO=Va,Tg=0/0,sO=/^[-+]0x[0-9a-f]+$/i,aO=/^0b[01]+$/i,oO=/^0o[0-7]+$/i,uO=parseInt;function lO(t){if(typeof t=="number")return t;if(iO(t))return Tg;if(wg(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=wg(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=nO(t);var r=aO.test(t);return r||oO.test(t)?uO(t.slice(2),r?2:8):sO.test(t)?Tg:+t}var cO=lO,hO=ji,Dl=YM,Sg=cO,fO="Expected a function",dO=Math.max,pO=Math.min;function gO(t,e,r){var n,i,a,u,l,f,p=0,v=!1,c=!1,d=!0;if(typeof t!="function")throw new TypeError(fO);e=Sg(e)||0,hO(r)&&(v=!!r.leading,c="maxWait"in r,a=c?dO(Sg(r.maxWait)||0,e):a,d="trailing"in r?!!r.trailing:d);function m(N){var L=n,k=i;return n=i=void 0,p=N,u=t.apply(k,L),u}function _(N){return p=N,l=setTimeout(w,e),v?m(N):u}function b(N){var L=N-f,k=N-p,D=e-L;return c?pO(D,a-k):D}function x(N){var L=N-f,k=N-p;return f===void 0||L>=e||L<0||c&&k>=a}function w(){var N=Dl();if(x(N))return E(N);l=setTimeout(w,b(N))}function E(N){return l=void 0,d&&n?m(N):(n=i=void 0,u)}function A(){l!==void 0&&clearTimeout(l),p=0,n=f=i=l=void 0}function I(){return l===void 0?u:E(Dl())}function O(){var N=Dl(),L=x(N);if(n=arguments,i=this,f=N,L){if(l===void 0)return _(f);if(c)return clearTimeout(l),l=setTimeout(w,e),m(f)}return l===void 0&&(l=setTimeout(w,e)),u}return O.cancel=A,O.flush=I,O}var mO=gO;const Ka=Wn(mO),Ag=(t,e,r,n)=>{const i=W.useCallback(Ka(t,n),[t,n]),a=W.useCallback(Ka(e,n),[e,n]),u=W.useCallback(Ka(r,n),[r,n]),l=W.useCallback(()=>{i()},[i]),f=W.useCallback(()=>{a()},[a]),p=W.useCallback(()=>{u()},[u]);return{onPointerOver:l,onPointerDown:f,onPointerOut:p}},vO={isPlaying:!1,progress:0,speed:1,isMuted:!1,isWaiting:!1,isStalled:!1,loaded:!1,size:{width:50,height:50},isDragging:!1,timeDiff:0},Eg=ne.forwardRef((t,e)=>{const[r,n]=ne.useState(0),[i,a]=ne.useState(),u=W.useRef(null),l=W.useRef(null),f=W.useRef(null),p=W.useRef(vO),v=W.useRef(),{uniqueId:c,mute:d=!1,src:m,startAt:_,endAt:b,frameStartAt:x,frameEndAt:w,visible:E,disabled:A,transformation:{x:I,y:O,width:N,height:L,animation:k,colorCorrection:D={}},pointerdown:j=()=>{},pointerout:Q=()=>{},pointerover:fe=()=>{}}=t,{tl:H,dragModeRef:V,isRemotion:le}=W.useContext(_n),{onPointerDown:ve,onPointerOut:z,onPointerOver:ee}=Ag(fe,j,Q,1),{blurRadius:pe=0,vignette:X=0,noise:Y=0}=D,{temperatureFilter:ce,sharpnessFilter:Se,hueFilter:xe,blurFilter:Me,adjustmentFilter:Oe,vignetteFilter:Ge,noiseFilter:ze}=_i(D),Ke=m||"",Ze=ne.useMemo(()=>{const J=document.createElement("video");return J.src=m,J.crossOrigin="Anonymus",J.autoplay=!1,J.currentTime=x===0?.001:x,J},[m,x]);ct(je.PAUSE,()=>{f.current&&(f.current.pause(),p.current.isPlaying=!1)}),ct(je.SCRUBBER_CLICKED,()=>{f.current&&(f.current.pause(),p.current.isPlaying=!1)}),ct(je.REVERSE_MODE_END,()=>{f.current&&(f.current.pause(),p.current.isPlaying=!1)});const be=ne.useCallback(Ka(()=>{if(f.current){const J=f.current;J.currentTime>0&&!J.paused&&!J.ended&&J.readyState>J.HAVE_CURRENT_DATA&&f.current.pause(),p.current.isPlaying=!1}},400),[f]);ne.useEffect(()=>{f.current&&!le?(V.current?(be(),p.current.isPlaying=!1,p.current.isDragging=!0):p.current.isDragging=!1,f.current.muted=d):p.current.isDragging=!1},[d,V,be,f]);const De=J=>{if(f.current){if(f.current.currentTime=Number(J),!V.current){const se=f.current,ut=se.currentTime>0&&!se.paused&&!se.ended&&se.readyState>se.HAVE_CURRENT_DATA;H.current&&H.current.isActive()&&v.current&&v.current.isActive()&&(ut||f.current.play(),p.current.isPlaying=!0,n(rr=>rr+1))}p.current.progress=0}},Qe=()=>{if(f.current){const J=f.current;J.currentTime>0&&!J.paused&&!J.ended&&J.readyState>J.HAVE_CURRENT_DATA&&f.current.pause(),p.current.isPlaying=!1,v.current&&(p.current.progress=v.current.progress())}},Je=()=>{},Le=()=>{var J,se;if(v.current&&(p.current.progress=v.current.progress()),f.current&&v.current){const ut=x+((J=v==null?void 0:v.current)==null?void 0:J.time()),rr=Math.abs(f.current.currentTime-ut),Ot=f.current,mt=Ot.currentTime>0&&!Ot.paused&&!Ot.ended&&Ot.readyState>Ot.HAVE_CURRENT_DATA;V.current?(f.current.currentTime=ut,setTimeout(()=>{f.current&&f.current.play().then(()=>{p.current.isPlaying=!1,f.current&&f.current.pause()})},100),p.current.isPlaying=!1):(mt!==p.current.isPlaying||!mt)&&p.current.progress>.01&&p.current.progress<.99?(se=H.current)!=null&&se.isActive()&&v.current&&v.current.isActive()&&(mt||f.current.play(),p.current.isPlaying=!0):rr>.3&&p.current.progress>.01&&p.current.progress<.99&&(f.current.currentTime=ut)}};return W.useEffect(()=>{let J=xt.context(()=>{});if(l.current&&H.current){const se={duration:Number(w)-Number(x),onStart:De,onComplete:Qe,onStartParams:[x,w],onCompleteParams:[],onInterrupt:Je,onUpdate:Le,onUpdateParams:[x,w],onPause:()=>{console.log("onPause video sprite pause",c)},onResume:()=>{console.log("onResume video sprite resume",c)},onReverseComplete:()=>{console.log("onReverseComplete video sprite reverse complete",c)},onKill:()=>{console.log("onKill video sprite kill",c)}};J=xt.context(()=>{v.current=xt.from(l.current,se,x),H.current.add(v.current,_)})}return()=>{v.current&&(v.current.kill(),xt.killTweensOf(v.current)),J.revert()}},[k,_,b,x,w]),ne.useEffect(()=>{f.current&&(f.current.muted=d)},[d]),ne.useEffect(()=>{const J=Math.round((Number(x)+Number.EPSILON)*100)/100,se=function(){f.current&&(f.current.currentTime=J)},ut=function(){if(f.current){const Bt=f.current;Bt.currentTime>0&&!Bt.paused&&!Bt.ended&&Bt.readyState>Bt.HAVE_CURRENT_DATA&&f.current.pause()}p.current.isWaiting=!1,p.current.isStalled=!1},rr=function(){f.current&&f.current.pause(),p.current.isWaiting=!0,p.current.isStalled=!1},Ot=function(){p.current.isWaiting=!1,p.current.isStalled=!1},mt=function(){p.current.isWaiting=!1,p.current.isStalled=!0},Hr=Math.round((Number(x)+Number.EPSILON)*100)/100,Ii=Math.round((Number(w)+Number.EPSILON)*100)/100,Ul=`${Ke}#t=${Hr},${Ii}`;return Jt.Texture.fromLoader(Ze,Ul,c,{pixiIdPrefix:c,resourceOptions:{autoPlay:!1,crossorigin:"Anonymus",updateFPS:30}}).then(Bt=>{Bt&&(a(Bt),f.current=Bt.baseTexture.resource.source,f.current.id=c,f.current.addEventListener("loadedmetadata",se),f.current.addEventListener("ended",ut),f.current.addEventListener("loadstart",rr),f.current.addEventListener("canplaythrough",Ot),f.current.addEventListener("stalled",mt))}),()=>{f.current&&(f.current.pause(),f.current.removeEventListener("loadedmetadata",se),f.current.removeEventListener("ended",ut),f.current.removeEventListener("loadstart",rr),f.current.removeEventListener("canplaythrough",Ot),f.current.removeEventListener("stalled",mt))}},[Ke,c,x,w,Ze]),ne.useEffect(()=>{const J=setTimeout(()=>{i&&v.current&&H.current&&v.current.progress()<.1&&f.current&&!v.current.isActive()&&!le&&f.current.play().then(()=>{p.current.isPlaying=!1,f.current&&f.current.pause()})},30);return()=>{clearTimeout(J)}},[i]),ne.useEffect(()=>{H.current&&!H.current.isActive()&&!le&&(p.current.isPlaying=!1,f.current&&f.current.pause());const J=setTimeout(()=>{if(i&&H.current&&r>0&&!le){H.current.isActive()||(p.current.isPlaying=!1,f.current&&f.current.pause());const se=f.current;se&&H.current.isActive()&&v.current&&v.current.isActive()&&(se.currentTime>0&&!se.paused&&!se.ended&&se.readyState>se.HAVE_CURRENT_DATA||f.current.play(),p.current.isPlaying=!0)}},10);return()=>{clearTimeout(J)}},[r,i]),Ee.jsx(xn,{...t,ref:e,ignoreTlForVideo:!0,pointerdown:ve,pointerover:ee,pointerout:z,children:Ee.jsx(Xe.Container,{ref:l,children:i&&Ee.jsx(Xe.Sprite,{texture:i,width:N,height:L,anchor:.5,x:I,y:O,ref:u,alpha:E?1:0,...!A&&E&&{interactive:!0,pointerdown:j},filters:[ce,Se,xe,Oe,...pe>0?[Me]:[],...X>0?[Ge]:[],...Y>0?[ze]:[]]})})})});Eg.whyDidYouRender={logOnDifferentValues:!0,customName:"PixiVideoSprite"};const _O=ne.forwardRef((t,e)=>{const[r,n]=ne.useState(),i=W.useRef(null),a=W.useRef(null),{visible:u,disabled:l,transformation:{x:f,y:p,width:v,height:c,colorCorrection:d={}},pointerdown:m=()=>{},pointerout:_=()=>{},pointerover:b=()=>{},canvasImageRef:x}=t,w=x&&(x==null?void 0:x.getCanvas()),E=Xe.useApp(),{onPointerDown:A,onPointerOut:I,onPointerOver:O}=Ag(b,m,_,1),{blurRadius:N=0,vignette:L=0,noise:k=0}=d,{temperatureFilter:D,sharpnessFilter:j,hueFilter:Q,blurFilter:fe,adjustmentFilter:H,vignetteFilter:V,noiseFilter:le}=_i(d);return Xe.useTick(()=>{if(i.current&&i.current.texture){const ve=i.current.texture.baseTexture;ve&&ve.update(),a.current&&E.renderer.render(a.current)}}),ne.useEffect(()=>{if(!$s(w)){const ve=Jt.Texture.from(w);n(ve)}},[w]),Ee.jsx(xn,{...t,ref:e,ignoreTlForVideo:!0,pointerdown:A,pointerover:O,pointerout:I,children:Ee.jsx(Xe.Container,{ref:a,children:r&&Ee.jsx(Xe.Sprite,{texture:r,width:v,height:c,anchor:.5,x:f,y:p,ref:i,alpha:u?1:0,...!l&&u&&{interactive:!0,pointerdown:m},filters:[D,j,Q,H,...N>0?[fe]:[],...L>0?[V]:[],...k>0?[le]:[]]})})})}),yO=t=>{const{startAt:e,endAt:r,uniqueId:n}=t,i=W.useRef(null),a=W.useRef(null),u=W.useRef(null),l=W.useRef(null),f=W.useRef(!1),{tl:p,totalDuration:v=0,reverseModeRef:c}=W.useContext(_n),d=e<.2?"static":"none",m=W.useRef(1);ct(je.COMPLETE,()=>{i.current&&(i.current.eventMode=d)}),ct(je.REVERSE_MODE_END,()=>{if(p.current){const x=p.current.time();x>e&&x<r?(a.current&&(a.current.alpha=1),i.current&&(i.current.alpha=1,i.current.eventMode="static")):(a.current&&(a.current.alpha=0),i.current&&(i.current.alpha=0,i.current.eventMode="none"))}});const _=()=>{if(c.current&&l.current&&p.current){f.current=!0;const x=p.current.time();x>e&&x<r?(a.current&&(a.current.alpha=1),i.current&&(i.current.alpha=1)):(a.current&&(a.current.alpha=0),i.current&&(i.current.alpha=0))}};ct(je.COMPLETE,()=>{}),ne.useEffect(()=>{const x=xt.context(()=>{if(i.current&&p.current){const w=xt.to(i.current,{alpha:1,duration:.1});l.current=xt.to(a.current,{alpha:1,duration:Number(r)-Number(e),onStart:()=>{i.current&&(i.current.alpha=1,i.current.eventMode="static",m.current=1)},onUpdate:_,onComplete:()=>{i.current&&(i.current.alpha=0,i.current.eventMode="none",m.current=0)}}),p.current.add([w,l.current],e)}});return()=>{l.current&&(p.current.remove(l.current),l.current.progress(0).kill()),x.revert()}},[e,r,v,n]);const b=()=>p&&p.current&&p.current.time()>e&&e>.2?m.current:e<.2?1:0;return Ee.jsx(Xe.Container,{ref:i,alpha:b(),eventMode:e<.2?"static":"none",children:Ee.jsx(Xe.Container,{ref:u,children:Ee.jsx(Xe.Container,{ref:a,alpha:1,children:t.children})})})},xO=t=>{const{startAt:e,endAt:r}=t,{setTotalDuration:n}=W.useContext(_n);return ne.useEffect(()=>{n&&n(Number(r)+.2)},[e,r]),t.children};var Cg=(t=>(t.FADE_IN="FADE_IN",t.FADE_OUT="FADE_OUT",t.FADE_IN_OUT="FADE_IN_OUT",t.SLIDE_IN_LEFT="SLIDE_IN_LEFT",t.SLIDE_IN_RIGHT="SLIDE_IN_RIGHT",t.SLIDE_IN_TOP="SLIDE_IN_TOP",t.SLIDE_IN_BOTTOM="SLIDE_IN_BOTTOM",t.SLIDE_OUT_LEFT="SLIDE_OUT_LEFT",t.SLIDE_OUT_RIGHT="SLIDE_OUT_RIGHT",t.SLIDE_OUT_TOP="SLIDE_OUT_TOP",t.SLIDE_OUT_BOTTOM="SLIDE_OUT_BOTTOM",t.ZOOM_IN="ZOOM_IN",t.ZOOM_OUT="ZOOM_OUT",t.ZOOM_IN_OUT="ZOOM_IN_OUT",t.BOUNCE_IN="BOUNCE_IN",t.BOUNCE_OUT="BOUNCE_OUT",t.BOUNCE_IN_OUT="BOUNCE_IN_OUT",t.ELASTIC_IN="ELASTIC_IN",t.ELASTIC_OUT="ELASTIC_OUT",t.ELASTIC_IN_OUT="ELASTIC_IN_OUT",t.BACK_IN="BACK_IN",t.BACK_OUT="BACK_OUT",t.BACK_IN_OUT="BACK_IN_OUT",t.CIRCULAR_IN="CIRCULAR_IN",t.CIRCULAR_OUT="CIRCULAR_OUT",t.CIRCULAR_IN_OUT="CIRCULAR_IN_OUT",t.EXPO_IN="EXPO_IN",t.EXPO_OUT="EXPO_OUT",t.EXPO_IN_OUT="EXPO_IN_OUT",t.SINE_IN="SINE_IN",t.SINE_OUT="SINE_OUT",t.SINE_IN_OUT="SINE_IN_OUT",t.BOUNCE="BOUNCE",t.ELASTIC="ELASTIC",t.BACK="BACK",t.CIRCULAR="CIRCULAR",t.EXPO="EXPO",t.SINE="SINE",t))(Cg||{}),Ig=(t=>(t[t.NORMAL=0]="NORMAL",t[t.ADD=1]="ADD",t[t.MULTIPLY=2]="MULTIPLY",t[t.SCREEN=3]="SCREEN",t[t.OVERLAY=4]="OVERLAY",t[t.DARKEN=5]="DARKEN",t[t.LIGHTEN=6]="LIGHTEN",t[t.COLOR_DODGE=7]="COLOR_DODGE",t[t.COLOR_BURN=8]="COLOR_BURN",t[t.HARD_LIGHT=9]="HARD_LIGHT",t[t.SOFT_LIGHT=10]="SOFT_LIGHT",t[t.DIFFERENCE=11]="DIFFERENCE",t[t.EXCLUSION=12]="EXCLUSION",t[t.HUE=13]="HUE",t[t.SATURATION=14]="SATURATION",t[t.COLOR=15]="COLOR",t[t.LUMINOSITY=16]="LUMINOSITY",t))(Ig||{});Ve.Animations=Cg,Ve.BlendModes=Ig,Ve.Events=je,Ve.GsapPixieContext=_n,Ve.GsapPixieContextProvider=vv,Ve.PixiAnimatedSprite=yg,Ve.PixiAudioSprite=aE,Ve.PixiGifSprite=bg,Ve.PixiImageSprite=mp,Ve.PixiSequence=yO,Ve.PixiSequenceWrapper=xO,Ve.PixiSvgPathSprite=sE,Ve.PixiTextSprite=jM,Ve.PixiVideoCanvasSyncSprite=_O,Ve.PixiVideoSprite=Eg,Ve.emitCustomEvent=qn,Ve.newCustomEventEmitter=mv,Ve.useCustomEventListener=ct,Object.defineProperty(Ve,Symbol.toStringTag,{value:"Module"})});
|
|
1992
|
+
}`;var me=rv(function(){return ke(S,te+"return "+G).apply(r,C)});if(me.source=G,Kc(me))throw me;return me}function oD(s){return Ue(s).toLowerCase()}function uD(s){return Ue(s).toUpperCase()}function lD(s,o,h){if(s=Ue(s),s&&(h||o===r))return hm(s);if(!s||!(o=Yt(o)))return s;var g=wr(s),y=wr(o),S=fm(g,y),C=dm(g,y)+1;return gn(g,S,C).join("")}function cD(s,o,h){if(s=Ue(s),s&&(h||o===r))return s.slice(0,gm(s)+1);if(!s||!(o=Yt(o)))return s;var g=wr(s),y=dm(g,wr(o))+1;return gn(g,0,y).join("")}function hD(s,o,h){if(s=Ue(s),s&&(h||o===r))return s.replace(Kl,"");if(!s||!(o=Yt(o)))return s;var g=wr(s),y=fm(g,wr(o));return gn(g,y).join("")}function fD(s,o){var h=j,g=Q;if(lt(o)){var y="separator"in o?o.separator:y;h="length"in o?ge(o.length):h,g="omission"in o?Yt(o.omission):g}s=Ue(s);var S=s.length;if(Oi(s)){var C=wr(s);S=C.length}if(h>=S)return s;var R=h-Fi(g);if(R<1)return g;var M=C?gn(C,0,R).join(""):s.slice(0,R);if(y===r)return M+g;if(C&&(R+=M.length-R),Zc(y)){if(s.slice(R).search(y)){var U,$=M;for(y.global||(y=dc(y.source,Ue(Fg.exec(y))+"g")),y.lastIndex=0;U=y.exec($);)var G=U.index;M=M.slice(0,G===r?R:G)}}else if(s.indexOf(Yt(y),R)!=R){var q=M.lastIndexOf(y);q>-1&&(M=M.slice(0,q))}return M+g}function dD(s){return s=Ue(s),s&&SO.test(s)?s.replace(Pg,zF):s}var pD=$i(function(s,o,h){return s+(h?" ":"")+o.toUpperCase()}),eh=n0("toUpperCase");function tv(s,o,h){return s=Ue(s),o=h?r:o,o===r?BF(s)?XF(s):IF(s):s.match(o)||[]}var rv=_e(function(s,o){try{return Wt(s,r,o)}catch(h){return Kc(h)?h:new he(h)}}),gD=qr(function(s,o){return ir(o,function(h){h=kr(h),jr(s,h,qc(s[h],s))}),s});function mD(s){var o=s==null?0:s.length,h=ie();return s=o?it(s,function(g){if(typeof g[1]!="function")throw new sr(u);return[h(g[0]),g[1]]}):[],_e(function(g){for(var y=-1;++y<o;){var S=s[y];if(Wt(S[0],this,g))return Wt(S[1],this,g)}})}function vD(s){return z3(or(s,c))}function th(s){return function(){return s}}function _D(s,o){return s==null||s!==s?o:s}var yD=s0(),xD=s0(!0);function Vt(s){return s}function rh(s){return Lm(typeof s=="function"?s:or(s,c))}function bD(s){return Bm(or(s,c))}function wD(s,o){return Dm(s,or(o,c))}var TD=_e(function(s,o){return function(h){return Is(h,s,o)}}),SD=_e(function(s,o){return function(h){return Is(s,h,o)}});function nh(s,o,h){var g=St(o),y=xo(o,g);h==null&&!(lt(o)&&(y.length||!g.length))&&(h=o,o=s,s=this,y=xo(o,St(o)));var S=!(lt(h)&&"chain"in h)||!!h.chain,C=Kr(s);return ir(y,function(R){var M=o[R];s[R]=M,C&&(s.prototype[R]=function(){var U=this.__chain__;if(S||U){var $=s(this.__wrapped__),G=$.__actions__=Gt(this.__actions__);return G.push({func:M,args:arguments,thisArg:s}),$.__chain__=U,$}return M.apply(s,ln([this.value()],arguments))})}),s}function AD(){return Ct._===this&&(Ct._=ZF),this}function ih(){}function ED(s){return s=ge(s),_e(function(o){return Um(o,s)})}var CD=Lc(it),ID=Lc(am),RD=Lc(ac);function nv(s){return zc(s)?oc(kr(s)):sN(s)}function PD(s){return function(o){return s==null?r:Hn(s,o)}}var MD=o0(),OD=o0(!0);function sh(){return[]}function ah(){return!1}function FD(){return{}}function ND(){return""}function LD(){return!0}function kD(s,o){if(s=ge(s),s<1||s>ee)return[];var h=Y,g=Ft(s,Y);o=ie(o),s-=Y;for(var y=cc(g,o);++h<s;)o(h);return y}function BD(s){return de(s)?it(s,kr):Kt(s)?[s]:Gt(T0(Ue(s)))}function DD(s){var o=++YF;return Ue(s)+o}var UD=Eo(function(s,o){return s+o},0),$D=kc("ceil"),GD=Eo(function(s,o){return s/o},1),zD=kc("floor");function HD(s){return s&&s.length?yo(s,Vt,bc):r}function VD(s,o){return s&&s.length?yo(s,ie(o,2),bc):r}function XD(s){return lm(s,Vt)}function jD(s,o){return lm(s,ie(o,2))}function WD(s){return s&&s.length?yo(s,Vt,Ac):r}function qD(s,o){return s&&s.length?yo(s,ie(o,2),Ac):r}var YD=Eo(function(s,o){return s*o},1),KD=kc("round"),ZD=Eo(function(s,o){return s-o},0);function QD(s){return s&&s.length?lc(s,Vt):0}function JD(s,o){return s&&s.length?lc(s,ie(o,2)):0}return T.after=bk,T.ary=N0,T.assign=uB,T.assignIn=q0,T.assignInWith=Uo,T.assignWith=lB,T.at=cB,T.before=L0,T.bind=qc,T.bindAll=gD,T.bindKey=k0,T.castArray=Fk,T.chain=M0,T.chunk=zN,T.compact=HN,T.concat=VN,T.cond=mD,T.conforms=vD,T.constant=th,T.countBy=QL,T.create=hB,T.curry=B0,T.curryRight=D0,T.debounce=U0,T.defaults=fB,T.defaultsDeep=dB,T.defer=wk,T.delay=Tk,T.difference=XN,T.differenceBy=jN,T.differenceWith=WN,T.drop=qN,T.dropRight=YN,T.dropRightWhile=KN,T.dropWhile=ZN,T.fill=QN,T.filter=ek,T.flatMap=nk,T.flatMapDeep=ik,T.flatMapDepth=sk,T.flatten=C0,T.flattenDeep=JN,T.flattenDepth=eL,T.flip=Sk,T.flow=yD,T.flowRight=xD,T.fromPairs=tL,T.functions=xB,T.functionsIn=bB,T.groupBy=ak,T.initial=nL,T.intersection=iL,T.intersectionBy=sL,T.intersectionWith=aL,T.invert=TB,T.invertBy=SB,T.invokeMap=uk,T.iteratee=rh,T.keyBy=lk,T.keys=St,T.keysIn=Ht,T.map=Fo,T.mapKeys=EB,T.mapValues=CB,T.matches=bD,T.matchesProperty=wD,T.memoize=Lo,T.merge=IB,T.mergeWith=Y0,T.method=TD,T.methodOf=SD,T.mixin=nh,T.negate=ko,T.nthArg=ED,T.omit=RB,T.omitBy=PB,T.once=Ak,T.orderBy=ck,T.over=CD,T.overArgs=Ek,T.overEvery=ID,T.overSome=RD,T.partial=Yc,T.partialRight=$0,T.partition=hk,T.pick=MB,T.pickBy=K0,T.property=nv,T.propertyOf=PD,T.pull=cL,T.pullAll=R0,T.pullAllBy=hL,T.pullAllWith=fL,T.pullAt=dL,T.range=MD,T.rangeRight=OD,T.rearg=Ck,T.reject=pk,T.remove=pL,T.rest=Ik,T.reverse=jc,T.sampleSize=mk,T.set=FB,T.setWith=NB,T.shuffle=vk,T.slice=gL,T.sortBy=xk,T.sortedUniq=wL,T.sortedUniqBy=TL,T.split=nD,T.spread=Rk,T.tail=SL,T.take=AL,T.takeRight=EL,T.takeRightWhile=CL,T.takeWhile=IL,T.tap=HL,T.throttle=Pk,T.thru=Oo,T.toArray=X0,T.toPairs=Z0,T.toPairsIn=Q0,T.toPath=BD,T.toPlainObject=W0,T.transform=LB,T.unary=Mk,T.union=RL,T.unionBy=PL,T.unionWith=ML,T.uniq=OL,T.uniqBy=FL,T.uniqWith=NL,T.unset=kB,T.unzip=Wc,T.unzipWith=P0,T.update=BB,T.updateWith=DB,T.values=Hi,T.valuesIn=UB,T.without=LL,T.words=tv,T.wrap=Ok,T.xor=kL,T.xorBy=BL,T.xorWith=DL,T.zip=UL,T.zipObject=$L,T.zipObjectDeep=GL,T.zipWith=zL,T.entries=Z0,T.entriesIn=Q0,T.extend=q0,T.extendWith=Uo,nh(T,T),T.add=UD,T.attempt=rv,T.camelCase=HB,T.capitalize=J0,T.ceil=$D,T.clamp=$B,T.clone=Nk,T.cloneDeep=kk,T.cloneDeepWith=Bk,T.cloneWith=Lk,T.conformsTo=Dk,T.deburr=ev,T.defaultTo=_D,T.divide=GD,T.endsWith=VB,T.eq=Sr,T.escape=XB,T.escapeRegExp=jB,T.every=JL,T.find=tk,T.findIndex=A0,T.findKey=pB,T.findLast=rk,T.findLastIndex=E0,T.findLastKey=gB,T.floor=zD,T.forEach=O0,T.forEachRight=F0,T.forIn=mB,T.forInRight=vB,T.forOwn=_B,T.forOwnRight=yB,T.get=Qc,T.gt=Uk,T.gte=$k,T.has=wB,T.hasIn=Jc,T.head=I0,T.identity=Vt,T.includes=ok,T.indexOf=rL,T.inRange=GB,T.invoke=AB,T.isArguments=jn,T.isArray=de,T.isArrayBuffer=Gk,T.isArrayLike=zt,T.isArrayLikeObject=dt,T.isBoolean=zk,T.isBuffer=mn,T.isDate=Hk,T.isElement=Vk,T.isEmpty=Xk,T.isEqual=jk,T.isEqualWith=Wk,T.isError=Kc,T.isFinite=qk,T.isFunction=Kr,T.isInteger=G0,T.isLength=Bo,T.isMap=z0,T.isMatch=Yk,T.isMatchWith=Kk,T.isNaN=Zk,T.isNative=Qk,T.isNil=eB,T.isNull=Jk,T.isNumber=H0,T.isObject=lt,T.isObjectLike=ht,T.isPlainObject=Ns,T.isRegExp=Zc,T.isSafeInteger=tB,T.isSet=V0,T.isString=Do,T.isSymbol=Kt,T.isTypedArray=zi,T.isUndefined=rB,T.isWeakMap=nB,T.isWeakSet=iB,T.join=oL,T.kebabCase=WB,T.last=lr,T.lastIndexOf=uL,T.lowerCase=qB,T.lowerFirst=YB,T.lt=sB,T.lte=aB,T.max=HD,T.maxBy=VD,T.mean=XD,T.meanBy=jD,T.min=WD,T.minBy=qD,T.stubArray=sh,T.stubFalse=ah,T.stubObject=FD,T.stubString=ND,T.stubTrue=LD,T.multiply=YD,T.nth=lL,T.noConflict=AD,T.noop=ih,T.now=No,T.pad=KB,T.padEnd=ZB,T.padStart=QB,T.parseInt=JB,T.random=zB,T.reduce=fk,T.reduceRight=dk,T.repeat=eD,T.replace=tD,T.result=OB,T.round=KD,T.runInContext=P,T.sample=gk,T.size=_k,T.snakeCase=rD,T.some=yk,T.sortedIndex=mL,T.sortedIndexBy=vL,T.sortedIndexOf=_L,T.sortedLastIndex=yL,T.sortedLastIndexBy=xL,T.sortedLastIndexOf=bL,T.startCase=iD,T.startsWith=sD,T.subtract=ZD,T.sum=QD,T.sumBy=JD,T.template=aD,T.times=kD,T.toFinite=Zr,T.toInteger=ge,T.toLength=j0,T.toLower=oD,T.toNumber=cr,T.toSafeInteger=oB,T.toString=Ue,T.toUpper=uD,T.trim=lD,T.trimEnd=cD,T.trimStart=hD,T.truncate=fD,T.unescape=dD,T.uniqueId=DD,T.upperCase=pD,T.upperFirst=eh,T.each=O0,T.eachRight=F0,T.first=I0,nh(T,function(){var s={};return Nr(T,function(o,h){He.call(T.prototype,h)||(s[h]=o)}),s}(),{chain:!1}),T.VERSION=n,ir(["bind","bindKey","curry","curryRight","partial","partialRight"],function(s){T[s].placeholder=T}),ir(["drop","take"],function(s,o){Ae.prototype[s]=function(h){h=h===r?1:yt(ge(h),0);var g=this.__filtered__&&!o?new Ae(this):this.clone();return g.__filtered__?g.__takeCount__=Ft(h,g.__takeCount__):g.__views__.push({size:Ft(h,Y),type:s+(g.__dir__<0?"Right":"")}),g},Ae.prototype[s+"Right"]=function(h){return this.reverse()[s](h).reverse()}}),ir(["filter","map","takeWhile"],function(s,o){var h=o+1,g=h==V||h==ve;Ae.prototype[s]=function(y){var S=this.clone();return S.__iteratees__.push({iteratee:ie(y,3),type:h}),S.__filtered__=S.__filtered__||g,S}}),ir(["head","last"],function(s,o){var h="take"+(o?"Right":"");Ae.prototype[s]=function(){return this[h](1).value()[0]}}),ir(["initial","tail"],function(s,o){var h="drop"+(o?"":"Right");Ae.prototype[s]=function(){return this.__filtered__?new Ae(this):this[h](1)}}),Ae.prototype.compact=function(){return this.filter(Vt)},Ae.prototype.find=function(s){return this.filter(s).head()},Ae.prototype.findLast=function(s){return this.reverse().find(s)},Ae.prototype.invokeMap=_e(function(s,o){return typeof s=="function"?new Ae(this):this.map(function(h){return Is(h,s,o)})}),Ae.prototype.reject=function(s){return this.filter(ko(ie(s)))},Ae.prototype.slice=function(s,o){s=ge(s);var h=this;return h.__filtered__&&(s>0||o<0)?new Ae(h):(s<0?h=h.takeRight(-s):s&&(h=h.drop(s)),o!==r&&(o=ge(o),h=o<0?h.dropRight(-o):h.take(o-s)),h)},Ae.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Ae.prototype.toArray=function(){return this.take(Y)},Nr(Ae.prototype,function(s,o){var h=/^(?:filter|find|map|reject)|While$/.test(o),g=/^(?:head|last)$/.test(o),y=T[g?"take"+(o=="last"?"Right":""):o],S=g||/^find/.test(o);y&&(T.prototype[o]=function(){var C=this.__wrapped__,R=g?[1]:arguments,M=C instanceof Ae,U=R[0],$=M||de(C),G=function(we){var Ie=y.apply(T,ln([we],R));return g&&q?Ie[0]:Ie};$&&h&&typeof U=="function"&&U.length!=1&&(M=$=!1);var q=this.__chain__,te=!!this.__actions__.length,ae=S&&!q,me=M&&!te;if(!S&&$){C=me?C:new Ae(this);var oe=s.apply(C,R);return oe.__actions__.push({func:Oo,args:[G],thisArg:r}),new ar(oe,q)}return ae&&me?s.apply(this,R):(oe=this.thru(G),ae?g?oe.value()[0]:oe.value():oe)})}),ir(["pop","push","shift","sort","splice","unshift"],function(s){var o=no[s],h=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",g=/^(?:pop|shift)$/.test(s);T.prototype[s]=function(){var y=arguments;if(g&&!this.__chain__){var S=this.value();return o.apply(de(S)?S:[],y)}return this[h](function(C){return o.apply(de(C)?C:[],y)})}}),Nr(Ae.prototype,function(s,o){var h=T[o];if(h){var g=h.name+"";He.call(Bi,g)||(Bi[g]=[]),Bi[g].push({name:o,func:h})}}),Bi[Ao(r,w).name]=[{name:"wrapper",func:r}],Ae.prototype.clone=d3,Ae.prototype.reverse=p3,Ae.prototype.value=g3,T.prototype.at=VL,T.prototype.chain=XL,T.prototype.commit=jL,T.prototype.next=WL,T.prototype.plant=YL,T.prototype.reverse=KL,T.prototype.toJSON=T.prototype.valueOf=T.prototype.value=ZL,T.prototype.first=T.prototype.head,bs&&(T.prototype[bs]=qL),T},Ni=jF();Dn?((Dn.exports=Ni)._=Ni,rc._=Ni):Ct._=Ni}).call(At)}(Ya,Ya.exports);var xg=Ya.exports;const XM={isPlaying:!1,progress:0,speed:1,isMuted:!1,isWaiting:!1,loaded:!1,size:{width:50,height:50},isDragging:!1,totalFrames:0,totalDuration:0},bg=ne.forwardRef((t,e)=>{const[r,n]=ne.useState([]),[,i]=ne.useState(0),[a,u]=ne.useState([]),[,l]=W.useState(!1),[f,p]=LM({autoPlay:!1}),v=W.useRef(null),c=W.useRef(null),d=W.useRef(XM),m=W.useRef(),{tl:_,dragModeRef:b}=W.useContext(_n),{frames:x,delays:w}=f,{src:E,startAt:A,endAt:I,frameStartAt:O,frameEndAt:N,loop:L,visible:k,disabled:D,transformation:{width:j=0,height:Q=0,x:fe,y:H,animation:V,colorCorrection:le={}},pointerdown:ve}=t,{temperatureFilter:z,sharpnessFilter:ee,hueFilter:pe,blurFilter:X,adjustmentFilter:Y,vignetteFilter:ce,noiseFilter:Se}=_i(le),{blurRadius:xe=0,vignette:Me=0,noise:Oe=0}=le,Ge=.1;HM(E,p),ct(je.PAUSE,()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)}),ct(je.SEEK_END,()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)}),ct(je.SCRUBBER_CLICKED,()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)}),ne.useEffect(()=>{d.current&&v.current&&(b.current?(v.current.stop(),d.current.isPlaying=!1,d.current.isDragging=!0):d.current.isDragging=!1)},[b]),ne.useEffect(()=>{if(!$s(x)){const Le=hM(x,ut=>{const{data:rr,width:Ot,height:mt}=ut,Hr=new Uint8Array(rr);return Jt.Texture.fromBuffer(Hr,Ot,mt)}),J=Le.map((ut,rr)=>({texture:ut,time:w[rr]}));n(Le),u(J);let se=0;w.forEach(ut=>{se+=ut*10}),i(se),d.current.totalDuration=se,d.current.totalFrames=x.length}},[x,w]);const ze=xg.debounce(Le=>{if(v.current){let J=Le===0?0:Le/Ge;J=isNaN(J)?0:J;const se=d.current.totalFrames;J=J>se?se:J,J>=se?(v.current.gotoAndStop(0),d.current.isPlaying=!1):(v.current.gotoAndPlay(J||0),d.current.isPlaying=!0)}},20),Ke=xg.debounce(()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)},50),Ze=Le=>{if(v.current){let J=Le===0?0:Le/Ge;J=isNaN(J)?0:J;const se=d.current.totalFrames;J=J>se?se:J,J>=se?(v.current.gotoAndStop(0),d.current.isPlaying=!1):(v.current.gotoAndPlay(J||0),d.current.isPlaying=!0)}},be=()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)},De=()=>{v.current&&(v.current.stop(),d.current.isPlaying=!1)},Qe=Le=>{var se;const J=Le+((se=m.current)==null?void 0:se.time());v.current&&b.current?(ze(J),Ke(),d.current.isPlaying=!1):m.current&&v.current&&!d.current.isPlaying&&m.current.isActive()&&_.current.isActive()&&(ze(J),d.current.isPlaying=!0)},Je=()=>{l(!0)};return W.useEffect(()=>{let Le=xt.context(()=>{});if(c.current&&_.current){const J={duration:Number(N)-Number(O),onStart:Ze,onComplete:be,onStartParams:[O,N],onCompleteParams:[],onInterrupt:De,onUpdate:Qe,onUpdateParams:[O,N]};m.current&&m.current.kill(),Le=xt.context(()=>{m.current=xt.from(c.current,J,O),_.current.add(m.current,A)})}return()=>{m.current&&(m.current.kill(),xt.killTweensOf(m.current)),Le.revert()}},[V,A,I,O,N]),Ee.jsx(xn,{...t,ref:e,ignoreTlForVideo:!0,isGif:!0,children:Ee.jsx(Xe.Container,{ref:c,children:r&&r.length>0&&Ee.jsx(yg,{x:fe,y:H,width:j,height:Q,animationSpeed:1,alpha:k?1:0,loop:L,textures:a,onComplete:Je,anchor:.5,forwardRef:v,...!D&&k&&{interactive:!0,pointerdown:ve},filters:[z,ee,pe,Y,...xe>0?[X]:[],...Me>0?[ce]:[],...Oe>0?[Se]:[]]})})})});bg.whyDidYouRender={logOnDifferentValues:!0,customName:"PixiGifSprite"};const jM=ne.forwardRef((t,e)=>{const n=W.useRef(null),i=W.useRef(0),a=W.useRef(null),u=W.useRef(null),l=W.useRef(16),f=W.useRef(null),{visible:p,text:v,disabled:c,transformation:d,pointerdown:m,onDobuleClick:_}=t,{x:b,y:x,fontFamily:w="Arial",fontWeight:E="normal",fontStyle:A="normal",fontSize:I=16,fontVariant:O="normal",fill:N="black",stroke:L,strokeThickness:k=0,blurRadius:D=0,blurEnabled:j=!1,dropShadowColor:Q=null,dropShadow:fe=!1,dropShadowBlur:H=0,wordWrapWidth:V=5e7,leading:le=0,letterSpacing:ve,colorCorrection:z={}}=d,{temperatureFilter:ee,sharpnessFilter:pe,hueFilter:X,blurFilter:Y,adjustmentFilter:ce}=_i(z),{blurRadius:Se=0}=z;ne.useEffect(()=>{l.current=Number(I)},[I]);const xe=["italic","oblique"].includes(A)?A:void 0,Me=["small-caps"].includes(O),Oe=["bold","bolder","lighter","100","200","300"].includes(E)?E:void 0,Ge=Number(ve)>0?ve:void 0,ze=ne.useMemo(()=>new Jt.TextStyle({fontFamily:w,fontSize:I,fill:N||"white",...L&&k>0&&{stroke:L,strokeThickness:k},...xe&&{fontStyle:xe},...Me&&{fontVariant:Me},...Oe&&{fontWeight:Oe},...Ge&&{letterSpacing:Ge},...j&&{dropShadow:!0,dropShadowBlur:Number(D),dropShadowColor:(Q==null?void 0:Q.toString())||"black",dropShadowAngle:.5235987755982988,dropShadowDistance:5},...fe&&{dropShadow:!0,dropShadowBlur:Number(H),dropShadowColor:(Q==null?void 0:Q.toString())||"black",dropShadowAngle:.5235987755982988,dropShadowDistance:5},wordWrap:!0,breakWords:!0,wordWrapWidth:V||500,leading:le||0}),[j,D,N,w,I,A,le,xe,Oe,Me,Ge,Q,L,k,V,fe,H]);ne.useEffect(()=>{f.current={...d}},[d]);const Ke=()=>{const be=new Date().getTime();be-i.current<300&&_?_():m&&m(),i.current=be},Ze=()=>{!c&&_&&_()};return Ee.jsx(xn,{...t,ref:e,isText:!0,onDoubleClick:Ze,children:Ee.jsx(Xe.Container,{ref:n,children:Ee.jsx(Xe.Container,{alpha:1,ref:u,children:Ee.jsx(Xe.Text,{style:ze,x:b,y:x,anchor:.5,text:v,alpha:p?1:0,...p&&!c&&{interactive:!0,buttonMode:!0,pointerdown:Ke},ref:a,filters:[ee,pe,X,ce,...Se>0?[Y]:[]]})})})})});var WM=Er,qM=function(){return WM.Date.now()},YM=qM,KM=/\s/;function ZM(t){for(var e=t.length;e--&&KM.test(t.charAt(e)););return e}var QM=ZM,JM=QM,eO=/^\s+/;function tO(t){return t&&t.slice(0,JM(t)+1).replace(eO,"")}var rO=tO,nO=rO,wg=ji,iO=Va,Tg=0/0,sO=/^[-+]0x[0-9a-f]+$/i,aO=/^0b[01]+$/i,oO=/^0o[0-7]+$/i,uO=parseInt;function lO(t){if(typeof t=="number")return t;if(iO(t))return Tg;if(wg(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=wg(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=nO(t);var r=aO.test(t);return r||oO.test(t)?uO(t.slice(2),r?2:8):sO.test(t)?Tg:+t}var cO=lO,hO=ji,Dl=YM,Sg=cO,fO="Expected a function",dO=Math.max,pO=Math.min;function gO(t,e,r){var n,i,a,u,l,f,p=0,v=!1,c=!1,d=!0;if(typeof t!="function")throw new TypeError(fO);e=Sg(e)||0,hO(r)&&(v=!!r.leading,c="maxWait"in r,a=c?dO(Sg(r.maxWait)||0,e):a,d="trailing"in r?!!r.trailing:d);function m(N){var L=n,k=i;return n=i=void 0,p=N,u=t.apply(k,L),u}function _(N){return p=N,l=setTimeout(w,e),v?m(N):u}function b(N){var L=N-f,k=N-p,D=e-L;return c?pO(D,a-k):D}function x(N){var L=N-f,k=N-p;return f===void 0||L>=e||L<0||c&&k>=a}function w(){var N=Dl();if(x(N))return E(N);l=setTimeout(w,b(N))}function E(N){return l=void 0,d&&n?m(N):(n=i=void 0,u)}function A(){l!==void 0&&clearTimeout(l),p=0,n=f=i=l=void 0}function I(){return l===void 0?u:E(Dl())}function O(){var N=Dl(),L=x(N);if(n=arguments,i=this,f=N,L){if(l===void 0)return _(f);if(c)return clearTimeout(l),l=setTimeout(w,e),m(f)}return l===void 0&&(l=setTimeout(w,e)),u}return O.cancel=A,O.flush=I,O}var mO=gO;const Ka=Wn(mO),Ag=(t,e,r,n)=>{const i=W.useCallback(Ka(t,n),[t,n]),a=W.useCallback(Ka(e,n),[e,n]),u=W.useCallback(Ka(r,n),[r,n]),l=W.useCallback(()=>{i()},[i]),f=W.useCallback(()=>{a()},[a]),p=W.useCallback(()=>{u()},[u]);return{onPointerOver:l,onPointerDown:f,onPointerOut:p}},vO={isPlaying:!1,progress:0,speed:1,isMuted:!1,isWaiting:!1,isStalled:!1,loaded:!1,size:{width:50,height:50},isDragging:!1,timeDiff:0},Eg=ne.forwardRef((t,e)=>{const[r,n]=ne.useState(0),[i,a]=ne.useState(),u=W.useRef(null),l=W.useRef(null),f=W.useRef(null),p=W.useRef(vO),v=W.useRef(),{uniqueId:c,mute:d=!1,src:m,startAt:_,endAt:b,frameStartAt:x,frameEndAt:w,visible:E,disabled:A,transformation:{x:I,y:O,width:N,height:L,animation:k,colorCorrection:D={}},pointerdown:j=()=>{},pointerout:Q=()=>{},pointerover:fe=()=>{}}=t,{tl:H,dragModeRef:V,isRemotion:le}=W.useContext(_n),{onPointerDown:ve,onPointerOut:z,onPointerOver:ee}=Ag(fe,j,Q,1),{blurRadius:pe=0,vignette:X=0,noise:Y=0}=D,{temperatureFilter:ce,sharpnessFilter:Se,hueFilter:xe,blurFilter:Me,adjustmentFilter:Oe,vignetteFilter:Ge,noiseFilter:ze}=_i(D),Ke=m||"",Ze=ne.useMemo(()=>{const J=document.createElement("video");return J.src=m,J.crossOrigin="Anonymus",J.autoplay=!1,J.currentTime=x===0?.001:x,J},[m,x]);ct(je.PAUSE,()=>{f.current&&(f.current.pause(),p.current.isPlaying=!1)}),ct(je.SCRUBBER_CLICKED,()=>{f.current&&(f.current.pause(),p.current.isPlaying=!1)}),ct(je.REVERSE_MODE_END,()=>{f.current&&(f.current.pause(),p.current.isPlaying=!1)});const be=ne.useCallback(Ka(()=>{if(f.current){const J=f.current;J.currentTime>0&&!J.paused&&!J.ended&&J.readyState>J.HAVE_CURRENT_DATA&&f.current.pause(),p.current.isPlaying=!1}},400),[f]);ne.useEffect(()=>{f.current&&!le?(V.current?(be(),p.current.isPlaying=!1,p.current.isDragging=!0):p.current.isDragging=!1,f.current.muted=d):p.current.isDragging=!1},[d,V,be,f]);const De=J=>{if(f.current){if(f.current.currentTime=Number(J),!V.current){const se=f.current,ut=se.currentTime>0&&!se.paused&&!se.ended&&se.readyState>se.HAVE_CURRENT_DATA;H.current&&H.current.isActive()&&v.current&&v.current.isActive()&&(ut||f.current.play(),p.current.isPlaying=!0,n(rr=>rr+1))}p.current.progress=0}},Qe=()=>{if(f.current){const J=f.current;J.currentTime>0&&!J.paused&&!J.ended&&J.readyState>J.HAVE_CURRENT_DATA&&f.current.pause(),p.current.isPlaying=!1,v.current&&(p.current.progress=v.current.progress())}},Je=()=>{},Le=()=>{var J,se;if(v.current&&(p.current.progress=v.current.progress()),f.current&&v.current){const ut=x+((J=v==null?void 0:v.current)==null?void 0:J.time()),rr=Math.abs(f.current.currentTime-ut),Ot=f.current,mt=Ot.currentTime>0&&!Ot.paused&&!Ot.ended&&Ot.readyState>Ot.HAVE_CURRENT_DATA;V.current?(f.current.currentTime=ut,setTimeout(()=>{f.current&&f.current.play().then(()=>{p.current.isPlaying=!1,f.current&&f.current.pause()})},100),p.current.isPlaying=!1):(mt!==p.current.isPlaying||!mt)&&p.current.progress>.01&&p.current.progress<.99?(se=H.current)!=null&&se.isActive()&&v.current&&v.current.isActive()&&(mt||f.current.play(),p.current.isPlaying=!0):rr>.3&&p.current.progress>.01&&p.current.progress<.99&&(f.current.currentTime=ut)}};return W.useEffect(()=>{let J=xt.context(()=>{});if(l.current&&H.current){const se={duration:Number(w)-Number(x),onStart:De,onComplete:Qe,onStartParams:[x,w],onCompleteParams:[],onInterrupt:Je,onUpdate:Le,onUpdateParams:[x,w],onPause:()=>{console.log("onPause video sprite pause",c)},onResume:()=>{console.log("onResume video sprite resume",c)},onReverseComplete:()=>{console.log("onReverseComplete video sprite reverse complete",c)},onKill:()=>{console.log("onKill video sprite kill",c)}};J=xt.context(()=>{v.current=xt.from(l.current,se,x),H.current.add(v.current,_)})}return()=>{v.current&&(v.current.kill(),xt.killTweensOf(v.current)),J.revert()}},[k,_,b,x,w]),ne.useEffect(()=>{f.current&&(f.current.muted=d)},[d]),ne.useEffect(()=>{const J=Math.round((Number(x)+Number.EPSILON)*100)/100,se=function(){f.current&&(f.current.currentTime=J)},ut=function(){if(f.current){const Bt=f.current;Bt.currentTime>0&&!Bt.paused&&!Bt.ended&&Bt.readyState>Bt.HAVE_CURRENT_DATA&&f.current.pause()}p.current.isWaiting=!1,p.current.isStalled=!1},rr=function(){f.current&&f.current.pause(),p.current.isWaiting=!0,p.current.isStalled=!1},Ot=function(){p.current.isWaiting=!1,p.current.isStalled=!1},mt=function(){p.current.isWaiting=!1,p.current.isStalled=!0},Hr=Math.round((Number(x)+Number.EPSILON)*100)/100,Ii=Math.round((Number(w)+Number.EPSILON)*100)/100,Ul=`${Ke}#t=${Hr},${Ii}`;return Jt.Texture.fromLoader(Ze,Ul,c,{pixiIdPrefix:c,resourceOptions:{autoPlay:!1,crossorigin:"Anonymus",updateFPS:30}}).then(Bt=>{Bt&&(a(Bt),f.current=Bt.baseTexture.resource.source,f.current.id=c,f.current.addEventListener("loadedmetadata",se),f.current.addEventListener("ended",ut),f.current.addEventListener("loadstart",rr),f.current.addEventListener("canplaythrough",Ot),f.current.addEventListener("stalled",mt))}),()=>{f.current&&(f.current.pause(),f.current.removeEventListener("loadedmetadata",se),f.current.removeEventListener("ended",ut),f.current.removeEventListener("loadstart",rr),f.current.removeEventListener("canplaythrough",Ot),f.current.removeEventListener("stalled",mt))}},[Ke,c,x,w,Ze]),ne.useEffect(()=>{const J=setTimeout(()=>{i&&v.current&&H.current&&v.current.progress()<.1&&f.current&&!v.current.isActive()&&!le&&f.current.play().then(()=>{p.current.isPlaying=!1,f.current&&f.current.pause()})},30);return()=>{clearTimeout(J)}},[i]),ne.useEffect(()=>{H.current&&!H.current.isActive()&&!le&&(p.current.isPlaying=!1,f.current&&f.current.pause());const J=setTimeout(()=>{if(i&&H.current&&r>0&&!le){H.current.isActive()||(p.current.isPlaying=!1,f.current&&f.current.pause());const se=f.current;se&&H.current.isActive()&&v.current&&v.current.isActive()&&(se.currentTime>0&&!se.paused&&!se.ended&&se.readyState>se.HAVE_CURRENT_DATA||f.current.play(),p.current.isPlaying=!0)}},10);return()=>{clearTimeout(J)}},[r,i]),Ee.jsx(xn,{...t,ref:e,ignoreTlForVideo:!0,pointerdown:ve,pointerover:ee,pointerout:z,children:Ee.jsx(Xe.Container,{ref:l,children:i&&Ee.jsx(Xe.Sprite,{texture:i,width:N,height:L,anchor:.5,x:I,y:O,ref:u,alpha:E?1:0,...!A&&E&&{interactive:!0,pointerdown:j},filters:[ce,Se,xe,Oe,...pe>0?[Me]:[],...X>0?[Ge]:[],...Y>0?[ze]:[]]})})})});Eg.whyDidYouRender={logOnDifferentValues:!0,customName:"PixiVideoSprite"};const _O=ne.forwardRef((t,e)=>{const[r,n]=ne.useState(),i=W.useRef(null),a=W.useRef(null),{visible:u,disabled:l,transformation:{x:f,y:p,width:v,height:c,colorCorrection:d={}},pointerdown:m=()=>{},pointerout:_=()=>{},pointerover:b=()=>{},canvasImageRef:x}=t,w=x&&(x==null?void 0:x.getCanvas()),E=Xe.useApp(),{onPointerDown:A,onPointerOut:I,onPointerOver:O}=Ag(b,m,_,1),{blurRadius:N=0,vignette:L=0,noise:k=0}=d,{temperatureFilter:D,sharpnessFilter:j,hueFilter:Q,blurFilter:fe,adjustmentFilter:H,vignetteFilter:V,noiseFilter:le}=_i(d);return Xe.useTick(()=>{if(i.current&&i.current.texture){const ve=i.current.texture.baseTexture;ve&&ve.update(),a.current&&E.renderer.render(a.current)}}),ne.useEffect(()=>{if(!$s(w)){const ve=Jt.Texture.from(w);n(ve)}},[w]),Ee.jsx(xn,{...t,ref:e,ignoreTlForVideo:!0,pointerdown:A,pointerover:O,pointerout:I,children:Ee.jsx(Xe.Container,{ref:a,children:r&&Ee.jsx(Xe.Sprite,{texture:r,width:v,height:c,anchor:.5,x:f,y:p,ref:i,alpha:u?1:0,...!l&&u&&{interactive:!0,pointerdown:m},filters:[D,j,Q,H,...N>0?[fe]:[],...L>0?[V]:[],...k>0?[le]:[]]})})})}),yO=t=>{var b;const{startAt:e,endAt:r,uniqueId:n}=t,i=W.useRef(null),a=W.useRef(null),u=W.useRef(null),l=W.useRef(null),f=W.useRef(!1),{tl:p,totalDuration:v=0,reverseModeRef:c}=W.useContext(_n),d=e<.2?"static":"none",m=W.useRef(1);ct(je.COMPLETE,()=>{i.current&&(i.current.eventMode=d)}),ct(je.REVERSE_MODE_END,()=>{if(p.current){const x=p.current.time();x>e&&x<r?(a.current&&(a.current.alpha=1),i.current&&(i.current.alpha=1,i.current.eventMode="static")):(a.current&&(a.current.alpha=0),i.current&&(i.current.alpha=0,i.current.eventMode="none"))}});const _=()=>{if(c.current&&l.current&&p.current){f.current=!0;const x=p.current.time();x>e&&x<r?(a.current&&(a.current.alpha=1),i.current&&(i.current.alpha=1)):(a.current&&(a.current.alpha=0),i.current&&(i.current.alpha=0))}};return ct(je.COMPLETE,()=>{}),ne.useEffect(()=>{const x=xt.context(()=>{if(i.current&&p.current){const w=xt.to(i.current,{alpha:1,duration:.1});l.current=xt.to(a.current,{alpha:1,duration:Number(r)-Number(e),onStart:()=>{i.current&&(i.current.alpha=1,i.current.eventMode="static",m.current=1)},onUpdate:_,onComplete:()=>{i.current&&(i.current.alpha=0,i.current.eventMode="none",m.current=0)}}),p.current.add([w,l.current],e)}});return()=>{l.current&&(p.current.remove(l.current),l.current.progress(0).kill()),x.revert()}},[e,r,v,n]),console.log("current alpha with time",(b=i==null?void 0:i.current)==null?void 0:b.alpha),Ee.jsx(Xe.Container,{ref:i,alpha:e<.2?1:0,eventMode:e<.2?"static":"none",children:Ee.jsx(Xe.Container,{ref:u,children:Ee.jsx(Xe.Container,{ref:a,alpha:1,children:t.children})})})},xO=t=>{const{startAt:e,endAt:r}=t,{setTotalDuration:n}=W.useContext(_n);return ne.useEffect(()=>{n&&n(Number(r)+.2)},[e,r]),t.children};var Cg=(t=>(t.FADE_IN="FADE_IN",t.FADE_OUT="FADE_OUT",t.FADE_IN_OUT="FADE_IN_OUT",t.SLIDE_IN_LEFT="SLIDE_IN_LEFT",t.SLIDE_IN_RIGHT="SLIDE_IN_RIGHT",t.SLIDE_IN_TOP="SLIDE_IN_TOP",t.SLIDE_IN_BOTTOM="SLIDE_IN_BOTTOM",t.SLIDE_OUT_LEFT="SLIDE_OUT_LEFT",t.SLIDE_OUT_RIGHT="SLIDE_OUT_RIGHT",t.SLIDE_OUT_TOP="SLIDE_OUT_TOP",t.SLIDE_OUT_BOTTOM="SLIDE_OUT_BOTTOM",t.ZOOM_IN="ZOOM_IN",t.ZOOM_OUT="ZOOM_OUT",t.ZOOM_IN_OUT="ZOOM_IN_OUT",t.BOUNCE_IN="BOUNCE_IN",t.BOUNCE_OUT="BOUNCE_OUT",t.BOUNCE_IN_OUT="BOUNCE_IN_OUT",t.ELASTIC_IN="ELASTIC_IN",t.ELASTIC_OUT="ELASTIC_OUT",t.ELASTIC_IN_OUT="ELASTIC_IN_OUT",t.BACK_IN="BACK_IN",t.BACK_OUT="BACK_OUT",t.BACK_IN_OUT="BACK_IN_OUT",t.CIRCULAR_IN="CIRCULAR_IN",t.CIRCULAR_OUT="CIRCULAR_OUT",t.CIRCULAR_IN_OUT="CIRCULAR_IN_OUT",t.EXPO_IN="EXPO_IN",t.EXPO_OUT="EXPO_OUT",t.EXPO_IN_OUT="EXPO_IN_OUT",t.SINE_IN="SINE_IN",t.SINE_OUT="SINE_OUT",t.SINE_IN_OUT="SINE_IN_OUT",t.BOUNCE="BOUNCE",t.ELASTIC="ELASTIC",t.BACK="BACK",t.CIRCULAR="CIRCULAR",t.EXPO="EXPO",t.SINE="SINE",t))(Cg||{}),Ig=(t=>(t[t.NORMAL=0]="NORMAL",t[t.ADD=1]="ADD",t[t.MULTIPLY=2]="MULTIPLY",t[t.SCREEN=3]="SCREEN",t[t.OVERLAY=4]="OVERLAY",t[t.DARKEN=5]="DARKEN",t[t.LIGHTEN=6]="LIGHTEN",t[t.COLOR_DODGE=7]="COLOR_DODGE",t[t.COLOR_BURN=8]="COLOR_BURN",t[t.HARD_LIGHT=9]="HARD_LIGHT",t[t.SOFT_LIGHT=10]="SOFT_LIGHT",t[t.DIFFERENCE=11]="DIFFERENCE",t[t.EXCLUSION=12]="EXCLUSION",t[t.HUE=13]="HUE",t[t.SATURATION=14]="SATURATION",t[t.COLOR=15]="COLOR",t[t.LUMINOSITY=16]="LUMINOSITY",t))(Ig||{});Ve.Animations=Cg,Ve.BlendModes=Ig,Ve.Events=je,Ve.GsapPixieContext=_n,Ve.GsapPixieContextProvider=vv,Ve.PixiAnimatedSprite=yg,Ve.PixiAudioSprite=aE,Ve.PixiGifSprite=bg,Ve.PixiImageSprite=mp,Ve.PixiSequence=yO,Ve.PixiSequenceWrapper=xO,Ve.PixiSvgPathSprite=sE,Ve.PixiTextSprite=jM,Ve.PixiVideoCanvasSyncSprite=_O,Ve.PixiVideoSprite=Eg,Ve.emitCustomEvent=qn,Ve.newCustomEventEmitter=mv,Ve.useCustomEventListener=ct,Object.defineProperty(Ve,Symbol.toStringTag,{value:"Module"})});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "reacthub-pixitweenjs",
|
|
3
|
-
"version": "0.2.107-alpha.
|
|
3
|
+
"version": "0.2.107-alpha.24",
|
|
4
4
|
"description": "reacthub-pixitweenjs is a library that provides a powerful combination of React, PixiJS, GSAP, and image manipulation capabilities in a timeline sequence. With this library, you can easily create stunning animations and interactive graphics for your React applications",
|
|
5
5
|
"author": "khanzzirfan <reacthub.ai@gmail.com>",
|
|
6
6
|
"main": "dist/index.es.js",
|