"undefined"!=typeof navigator&&function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).lottie=e()}(this,(function(){"use strict";var t="",e=!1,i=-999999,s=function(){return t};function r(t){return document.createElement(t)}function a(t,e){var i,s,r=t.length;for(i=0;i1?i[1]=1:i[1]<=0&&(i[1]=0),z(i[0],i[1],i[2])}function V(t,e){var i=R(255*t[0],255*t[1],255*t[2]);return i[2]+=e,i[2]>1?i[2]=1:i[2]<0&&(i[2]=0),z(i[0],i[1],i[2])}function N(t,e){var i=R(255*t[0],255*t[1],255*t[2]);return i[0]+=e/360,i[0]>1?i[0]-=1:i[0]<0&&(i[0]+=1),z(i[0],i[1],i[2])}!function(){var t,e,i=[];for(t=0;t<256;t+=1)e=t.toString(16),i[t]=1===e.length?"0"+e:e}();var j=function(){return d},G=function(t){P=t},q=function(){return P};function W(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function H(t){return H="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},H(t)}var X=function(){var t,i,s=1,r=[],a={onmessage:function(){},postMessage:function(e){t({data:e})}},n={postMessage:function(t){a.onmessage({data:t})}};function o(i){if(window.Worker&&window.Blob&&e){var s=new Blob(["var _workerSelf = self; self.onmessage = ",i.toString()],{type:"text/javascript"}),r=URL.createObjectURL(s);return new Worker(r)}return t=i,a}function h(){i||(i=o((function(t){if(n.dataManager||(n.dataManager=function(){function t(r,a){var n,o,h,l,p,m,d=r.length;for(o=0;o=0;e-=1)if("sh"===t[e].ty)if(t[e].ks.k.i)s(t[e].ks.k);else for(a=t[e].ks.k.length,r=0;ri[0]||!(i[0]>t[0])&&(t[1]>i[1]||!(i[1]>t[1])&&(t[2]>i[2]||!(i[2]>t[2])&&null))}var a,n=function(){var t=[4,4,14];function e(t){var e,i,s,r=t.length;for(e=0;e=0;i-=1)if("sh"===t[i].ty)if(t[i].ks.k.i)t[i].ks.k.c=t[i].closed;else for(r=t[i].ks.k.length,s=0;s500)&&(this._imageLoaded(),clearInterval(i)),e+=1}.bind(this),50)}function n(t){var e={assetData:t},i=s(t,this.assetsPath,this.path);return X.loadData(i,function(t){e.img=t,this._footageLoaded()}.bind(this),function(){e.img={},this._footageLoaded()}.bind(this)),e}function o(){this._imageLoaded=e.bind(this),this._footageLoaded=i.bind(this),this.testImageLoaded=a.bind(this),this.createFootageData=n.bind(this),this.assetsPath="",this.path="",this.totalImages=0,this.totalFootages=0,this.loadedAssets=0,this.loadedFootagesCount=0,this.imagesLoadedCb=null,this.images=[]}return o.prototype={loadAssets:function(t,e){var i;this.imagesLoadedCb=e;var s=t.length;for(i=0;ithis.animationData.op&&(this.animationData.op=t.op,this.totalFrames=Math.floor(t.op-this.animationData.ip));var e,i,s=this.animationData.layers,r=s.length,a=t.layers,n=a.length;for(i=0;ithis.timeCompleted&&(this.currentFrame=this.timeCompleted),this.trigger("enterFrame"),this.renderFrame(),this.trigger("drawnFrame")},$.prototype.renderFrame=function(){if(!1!==this.isLoaded&&this.renderer)try{this.renderer.renderFrame(this.currentFrame+this.firstFrame)}catch(t){this.triggerRenderFrameError(t)}},$.prototype.play=function(t){t&&this.name!==t||!0===this.isPaused&&(this.isPaused=!1,this.trigger("_pause"),this.audioController.resume(),this._idle&&(this._idle=!1,this.trigger("_active")))},$.prototype.pause=function(t){t&&this.name!==t||!1===this.isPaused&&(this.isPaused=!0,this.trigger("_play"),this._idle=!0,this.trigger("_idle"),this.audioController.pause())},$.prototype.togglePause=function(t){t&&this.name!==t||(!0===this.isPaused?this.play():this.pause())},$.prototype.stop=function(t){t&&this.name!==t||(this.pause(),this.playCount=0,this._completedLoop=!1,this.setCurrentRawFrameValue(0))},$.prototype.getMarkerData=function(t){for(var e,i=0;i=this.totalFrames-1&&this.frameModifier>0?this.loop&&this.playCount!==this.loop?e>=this.totalFrames?(this.playCount+=1,this.checkSegments(e%this.totalFrames)||(this.setCurrentRawFrameValue(e%this.totalFrames),this._completedLoop=!0,this.trigger("loopComplete"))):this.setCurrentRawFrameValue(e):this.checkSegments(e>this.totalFrames?e%this.totalFrames:0)||(i=!0,e=this.totalFrames-1):e<0?this.checkSegments(e%this.totalFrames)||(!this.loop||this.playCount--<=0&&!0!==this.loop?(i=!0,e=0):(this.setCurrentRawFrameValue(this.totalFrames+e%this.totalFrames),this._completedLoop?this.trigger("loopComplete"):this._completedLoop=!0)):this.setCurrentRawFrameValue(e),i&&(this.setCurrentRawFrameValue(e),this.pause(),this.trigger("complete"))}},$.prototype.adjustSegment=function(t,e){this.playCount=0,t[1]0&&(this.playSpeed<0?this.setSpeed(-this.playSpeed):this.setDirection(-1)),this.totalFrames=t[0]-t[1],this.timeCompleted=this.totalFrames,this.firstFrame=t[1],this.setCurrentRawFrameValue(this.totalFrames-.001-e)):t[1]>t[0]&&(this.frameModifier<0&&(this.playSpeed<0?this.setSpeed(-this.playSpeed):this.setDirection(1)),this.totalFrames=t[1]-t[0],this.timeCompleted=this.totalFrames,this.firstFrame=t[0],this.setCurrentRawFrameValue(.001+e)),this.trigger("segmentStart")},$.prototype.setSegment=function(t,e){var i=-1;this.isPaused&&(this.currentRawFrame+this.firstFramee&&(i=e-t)),this.firstFrame=t,this.totalFrames=e-t,this.timeCompleted=this.totalFrames,-1!==i&&this.goToAndStop(i,!0)},$.prototype.playSegments=function(t,e){if(e&&(this.segments.length=0),"object"===Q(t[0])){var i,s=t.length;for(i=0;i=0;i-=1)e[i].animation.destroy(t)},t.freeze=function(){o=!0},t.unfreeze=function(){o=!1,u()},t.setVolume=function(t,i){var r;for(r=0;r=.001?function(t,e,i,s){for(var r=0;r<4;++r){var a=h(e,i,s);if(0===a)return e;e-=(o(e,i,s)-t)/a}return e}(t,l,e,s):0===p?l:function(t,e,i,s,r){var a,n,h=0;do{(a=o(n=e+(i-e)/2,s,r)-t)>0?i=n:e=n}while(Math.abs(a)>1e-7&&++h<10);return n}(t,a,a+i,e,s)}},t}(),it={double:function(t){return t.concat(p(t.length))}},st=function(t,e,i){var s=0,r=t,a=p(r);return{newElement:function(){return s?a[s-=1]:e()},release:function(t){s===r&&(a=it.double(a),r*=2),i&&i(t),a[s]=t,s+=1}}},rt=st(8,(function(){return{addedLength:0,percents:l("float32",q()),lengths:l("float32",q())}})),at=st(8,(function(){return{lengths:[],totalLength:0}}),(function(t){var e,i=t.lengths.length;for(e=0;e-.001&&n<.001}var i=function(t,e,i,s){var r,a,n,o,h,l,p=q(),f=0,m=[],d=[],c=rt.newElement();for(n=i.length,r=0;rn?-1:1,l=!0;l;)if(s[a]<=n&&s[a+1]>n?(o=(n-s[a])/(s[a+1]-s[a]),l=!1):a+=h,a<0||a>=r-1){if(a===r-1)return i[a];l=!1}return i[a]+(i[a+1]-i[a])*o}var h=l("float32",8);return{getSegmentsLength:function(t){var e,s=at.newElement(),r=t.c,a=t.v,n=t.o,o=t.i,h=t._length,l=s.lengths,p=0;for(e=0;e1&&(a=1);var p,f=o(a,l),m=o(n=n>1?1:n,l),d=e.length,c=1-f,u=1-m,g=c*c*c,y=f*c*c*3,v=f*f*c*3,b=f*f*f,_=c*c*u,x=f*c*u+c*f*u+c*c*m,P=f*f*u+c*f*m+f*c*m,k=f*f*m,w=c*u*u,A=f*u*u+c*m*u+c*u*m,D=f*m*u+c*m*m+f*u*m,S=f*m*m,C=u*u*u,E=m*u*u+u*m*u+u*u*m,T=m*m*u+u*m*m+m*u*m,M=m*m*m;for(p=0;pd?m>c?m-d-c:c-d-m:c>d?c-d-m:d-m-c)>-1e-4&&f<1e-4}}}(),ot=function(){var t=i,e=Math.abs;function s(t,e){var i,s=this.offsetTime;"multidimensional"===this.propType&&(i=l("float32",this.pv.length));for(var a,n,o,h,p,f,m,d,c,u=e.lastIndex,g=u,y=this.keyframes.length-1,v=!0;v;){if(a=this.keyframes[g],n=this.keyframes[g+1],g===y-1&&t>=n.t-s){a.h&&(a=n),u=0;break}if(n.t-s>t){u=g;break}g=T||t=T?F.points.length-1:0;for(p=F.points[I].point.length,h=0;h=z&&B=T)i[0]=b[0],i[1]=b[1],i[2]=b[2];else if(t<=M)i[0]=a.s[0],i[1]=a.s[1],i[2]=a.s[2];else{var G=r(a.s),q=r(b);_=i,x=function(t,e,i){var s,r,a,n,o,h=[],l=t[0],p=t[1],f=t[2],m=t[3],d=e[0],c=e[1],u=e[2],g=e[3];return(r=l*d+p*c+f*u+m*g)<0&&(r=-r,d=-d,c=-c,u=-u,g=-g),1-r>1e-6?(s=Math.acos(r),a=Math.sin(s),n=Math.sin((1-i)*s)/a,o=Math.sin(i*s)/a):(n=1-i,o=i),h[0]=n*l+o*d,h[1]=n*p+o*c,h[2]=n*f+o*u,h[3]=n*m+o*g,h}(G,q,(t-M)/(T-M)),P=x[0],w=x[1],A=x[2],D=x[3],S=Math.atan2(2*w*D-2*P*A,1-2*w*w-2*A*A),C=Math.asin(2*P*w+2*A*D),E=Math.atan2(2*P*D-2*w*A,1-2*P*P-2*A*A),_[0]=S/k,_[1]=C/k,_[2]=E/k}else for(g=0;g=T?f=1:t=s&&e>=s||this._caching.lastFrame=e&&(this._caching._lastKeyframeIndex=-1,this._caching.lastIndex=0);var r=this.interpolateValue(e,this._caching);this.pv=r}return this._caching.lastFrame=e,this.pv}function n(t){var i;if("unidimensional"===this.propType)i=t*this.mult,e(this.v-i)>1e-5&&(this.v=i,this._mdf=!0);else for(var s=0,r=this.v.length;s1e-5&&(this.v[s]=i,this._mdf=!0),s+=1}function o(){if(this.elem.globalData.frameId!==this.frameId&&this.effectsSequence.length)if(this.lock)this.setVValue(this.pv);else{var t;this.lock=!0,this._mdf=this._isFirstFrame;var e=this.effectsSequence.length,i=this.kf?this.pv:this.data.k;for(t=0;t=this._maxLength&&this.doubleArrayLength(),i){case"v":a=this.v;break;case"i":a=this.i;break;case"o":a=this.o;break;default:a=[]}(!a[s]||a[s]&&!r)&&(a[s]=lt.newElement()),a[s][0]=t,a[s][1]=e},pt.prototype.setTripleAt=function(t,e,i,s,r,a,n,o){this.setXYAt(t,e,"v",n,o),this.setXYAt(i,s,"o",n,o),this.setXYAt(r,a,"i",n,o)},pt.prototype.reverse=function(){var t=new pt;t.setPathData(this.c,this._length);var e=this.v,i=this.o,s=this.i,r=0;this.c&&(t.setTripleAt(e[0][0],e[0][1],s[0][0],s[0][1],i[0][0],i[0][1],0,!1),r=1);var a,n=this._length-1,o=this._length;for(a=r;a=d[d.length-1].t-this.offsetTime)s=d[d.length-1].s?d[d.length-1].s[0]:d[d.length-2].e[0],a=!0;else{for(var c,u,g,y=m,v=d.length-1,b=!0;b&&(c=d[y],!((u=d[y+1]).t-this.offsetTime>t));)y=u.t-this.offsetTime)p=1;else if(ts&&e>s)||(this._caching.lastIndex=r0||t>-1e-6&&t<0?s(1e4*t)/1e4:t}function I(){var t=this.props;return"matrix("+F(t[0])+","+F(t[1])+","+F(t[4])+","+F(t[5])+","+F(t[12])+","+F(t[13])+")"}return function(){this.reset=r,this.rotate=a,this.rotateX=n,this.rotateY=o,this.rotateZ=h,this.skew=f,this.skewFromAxis=m,this.shear=p,this.scale=d,this.setTransform=c,this.translate=u,this.transform=g,this.applyToPoint=x,this.applyToX=P,this.applyToY=k,this.applyToZ=w,this.applyToPointArray=E,this.applyToTriplePoints=C,this.applyToPointStringified=T,this.toCSS=M,this.to2dCSS=I,this.clone=b,this.cloneFromProps=_,this.equals=v,this.inversePoints=S,this.inversePoint=D,this.getInverseMatrix=A,this._t=this.transform,this.isIdentity=y,this._identity=!0,this._identityCalculated=!1,this.props=l("float32",16),this.reset()}}();function xt(t){return xt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xt(t)}var Pt={};function kt(){tt.searchAnimations()}Pt.play=tt.play,Pt.pause=tt.pause,Pt.setLocationHref=function(e){t=e},Pt.togglePause=tt.togglePause,Pt.setSpeed=tt.setSpeed,Pt.setDirection=tt.setDirection,Pt.stop=tt.stop,Pt.searchAnimations=kt,Pt.registerAnimation=tt.registerAnimation,Pt.loadAnimation=function(t){return tt.loadAnimation(t)},Pt.setSubframeRendering=function(t){!function(t){m=!!t}(t)},Pt.resize=tt.resize,Pt.goToAndStop=tt.goToAndStop,Pt.destroy=tt.destroy,Pt.setQuality=function(t){if("string"==typeof t)switch(t){case"high":G(200);break;default:case"medium":G(50);break;case"low":G(10)}else!isNaN(t)&&t>1&&G(t);q()>=50?A(!1):A(!0)},Pt.inBrowser=function(){return"undefined"!=typeof navigator},Pt.installPlugin=function(t,e){"expressions"===t&&(d=e)},Pt.freeze=tt.freeze,Pt.unfreeze=tt.unfreeze,Pt.setVolume=tt.setVolume,Pt.mute=tt.mute,Pt.unmute=tt.unmute,Pt.getRegisteredAnimations=tt.getRegisteredAnimations,Pt.useWebWorker=function(t){e=!!t},Pt.setIDPrefix=function(t){c=t},Pt.__getFactory=function(t){switch(t){case"propertyFactory":return ot;case"shapePropertyFactory":return bt;case"matrix":return _t;default:return null}},Pt.version="5.9.4";var wt="",At=document.getElementsByTagName("script"),Dt=At[At.length-1]||{src:""};wt=Dt.src?Dt.src.replace(/^[^\?]+\??/,""):"",function(t){for(var e=wt.split("&"),i=0;i=1?a.push({s:t-1,e:e-1}):(a.push({s:t,e:1}),a.push({s:0,e:e-1}));var n,o,h=[],l=a.length;for(n=0;ns+i))p=o.s*r<=s?0:(o.s*r-s)/i,f=o.e*r>=s+i?1:(o.e*r-s)/i,h.push([p,f])}return h.length||h.push([0,0]),h},Tt.prototype.releasePathsData=function(t){var e,i=t.length;for(e=0;e1?1+a:this.s.v<0?0+a:this.s.v+a)>(i=this.e.v>1?1+a:this.e.v<0?0+a:this.e.v+a)){var n=e;e=i,i=n}e=1e-4*Math.round(1e4*e),i=1e-4*Math.round(1e4*i),this.sValue=e,this.eValue=i}else e=this.sValue,i=this.eValue;var o,h,l,p,f,m=this.shapes.length,d=0;if(i===e)for(r=0;r=0;r-=1)if((c=this.shapes[r]).shape._mdf){for((u=c.localShapeCollection).releaseShapes(),2===this.m&&m>1?(y=this.calculateShapeEdges(e,i,c.totalShapeLength,_,d),_+=c.totalShapeLength):y=[[v,b]],h=y.length,o=0;o=1?g.push({s:c.totalShapeLength*(v-1),e:c.totalShapeLength*(b-1)}):(g.push({s:c.totalShapeLength*v,e:c.totalShapeLength}),g.push({s:0,e:c.totalShapeLength*(b-1)}));var x=this.addShapes(c,g[0]);if(g[0].s!==g[0].e){if(g.length>1)if(c.shape.paths.shapes[c.shape.paths._length-1].c){var P=x.pop();this.addPaths(x,u),x=this.addShapes(c,g[1],P)}else this.addPaths(x,u),x=this.addShapes(c,g[1]);this.addPaths(x,u)}}c.shape.paths=u}}},Tt.prototype.addPaths=function(t,e){var i,s=t.length;for(i=0;ie.e){i.c=!1;break}e.s<=c&&e.e>=c+n.addedLength?(this.addSegment(m[s].v[r-1],m[s].o[r-1],m[s].i[r],m[s].v[r],i,o,g),g=!1):(l=nt.getNewSegment(m[s].v[r-1],m[s].v[r],m[s].o[r-1],m[s].i[r],(e.s-c)/n.addedLength,(e.e-c)/n.addedLength,h[r-1]),this.addSegmentFromArray(l,i,o,g),g=!1,i.c=!1),c+=n.addedLength,o+=1}if(m[s].c&&h.length){if(n=h[r-1],c<=e.e){var y=h[r-1].addedLength;e.s<=c&&e.e>=c+y?(this.addSegment(m[s].v[r-1],m[s].o[r-1],m[s].i[0],m[s].v[0],i,o,g),g=!1):(l=nt.getNewSegment(m[s].v[r-1],m[s].v[0],m[s].o[r-1],m[s].i[0],(e.s-c)/y,(e.e-c)/y,h[r-1]),this.addSegmentFromArray(l,i,o,g),g=!1,i.c=!1)}else i.c=!1;c+=n.addedLength,o+=1}if(i._length&&(i.setXYAt(i.v[p][0],i.v[p][1],"i",p),i.setXYAt(i.v[i._length-1][0],i.v[i._length-1][1],"o",i._length-1)),c>e.e)break;s=this.p.keyframes[this.p.keyframes.length-1].t?(s=this.p.getValueAtTime(this.p.keyframes[this.p.keyframes.length-1].t/i,0),r=this.p.getValueAtTime((this.p.keyframes[this.p.keyframes.length-1].t-.05)/i,0)):(s=this.p.pv,r=this.p.getValueAtTime((this.p._caching.lastFrame+this.p.offsetTime-.01)/i,this.p.offsetTime));else if(this.px&&this.px.keyframes&&this.py.keyframes&&this.px.getValueAtTime&&this.py.getValueAtTime){s=[],r=[];var a=this.px,n=this.py;a._caching.lastFrame+a.offsetTime<=a.keyframes[0].t?(s[0]=a.getValueAtTime((a.keyframes[0].t+.01)/i,0),s[1]=n.getValueAtTime((n.keyframes[0].t+.01)/i,0),r[0]=a.getValueAtTime(a.keyframes[0].t/i,0),r[1]=n.getValueAtTime(n.keyframes[0].t/i,0)):a._caching.lastFrame+a.offsetTime>=a.keyframes[a.keyframes.length-1].t?(s[0]=a.getValueAtTime(a.keyframes[a.keyframes.length-1].t/i,0),s[1]=n.getValueAtTime(n.keyframes[n.keyframes.length-1].t/i,0),r[0]=a.getValueAtTime((a.keyframes[a.keyframes.length-1].t-.01)/i,0),r[1]=n.getValueAtTime((n.keyframes[n.keyframes.length-1].t-.01)/i,0)):(s=[a.pv,n.pv],r[0]=a.getValueAtTime((a._caching.lastFrame+a.offsetTime-.01)/i,a.offsetTime),r[1]=n.getValueAtTime((n._caching.lastFrame+n.offsetTime-.01)/i,n.offsetTime))}else s=r=t;this.v.rotate(-Math.atan2(s[1]-r[1],s[0]-r[0]))}this.data.p&&this.data.p.s?this.data.p.z?this.v.translate(this.px.v,this.py.v,-this.pz.v):this.v.translate(this.px.v,this.py.v,0):this.v.translate(this.p.v[0],this.p.v[1],-this.p.v[2])}this.frameId=this.elem.globalData.frameId}},precalculateMatrix:function(){if(!this.a.k&&(this.pre.translate(-this.a.v[0],-this.a.v[1],this.a.v[2]),this.appliedTransformations=1,!this.s.effectsSequence.length)){if(this.pre.scale(this.s.v[0],this.s.v[1],this.s.v[2]),this.appliedTransformations=2,this.sk){if(this.sk.effectsSequence.length||this.sa.effectsSequence.length)return;this.pre.skewFromAxis(-this.sk.v,this.sa.v),this.appliedTransformations=3}this.r?this.r.effectsSequence.length||(this.pre.rotate(-this.r.v),this.appliedTransformations=4):this.rz.effectsSequence.length||this.ry.effectsSequence.length||this.rx.effectsSequence.length||this.or.effectsSequence.length||(this.pre.rotateZ(-this.rz.v).rotateY(this.ry.v).rotateX(this.rx.v).rotateZ(-this.or.v[2]).rotateY(this.or.v[1]).rotateX(this.or.v[0]),this.appliedTransformations=4)}},autoOrient:function(){}},a([ht],e),e.prototype.addDynamicProperty=function(t){this._addDynamicProperty(t),this.elem.addDynamicProperty(t),this._isDirty=!0},e.prototype._addDynamicProperty=ht.prototype.addDynamicProperty,{getTransformProperty:function(t,i,s){return new e(t,i,s)}}}();function It(){}function Lt(){}function Bt(t){for(var e=t.fStyle?t.fStyle.split(" "):[],i="normal",s="normal",r=e.length,a=0;a0;)i-=1,this._elements.unshift(e[i]);this.dynamicProperties.length?this.k=!0:this.getValue(!0)},It.prototype.resetElements=function(t){var e,i=t.length;for(e=0;e0?Math.floor(m):Math.ceil(m),u=this.pMatrix.props,g=this.rMatrix.props,y=this.sMatrix.props;this.pMatrix.reset(),this.rMatrix.reset(),this.sMatrix.reset(),this.tMatrix.reset(),this.matrix.reset();var v,b,_=0;if(m>0){for(;_c;)this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,1,!0),_-=1;d&&(this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,-d,!0),_-=d)}for(s=1===this.data.m?0:this._currentCopies-1,r=1===this.data.m?1:-1,a=this._currentCopies;a;){if(b=(i=(e=this.elemsData[s].it)[e.length-1].transform.mProps.v.props).length,e[e.length-1].transform.mProps._mdf=!0,e[e.length-1].transform.op._mdf=!0,e[e.length-1].transform.op.v=1===this._currentCopies?this.so.v:this.so.v+(this.eo.v-this.so.v)*(s/(this._currentCopies-1)),0!==_){for((0!==s&&1===r||s!==this._currentCopies-1&&-1===r)&&this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,1,!1),this.matrix.transform(g[0],g[1],g[2],g[3],g[4],g[5],g[6],g[7],g[8],g[9],g[10],g[11],g[12],g[13],g[14],g[15]),this.matrix.transform(y[0],y[1],y[2],y[3],y[4],y[5],y[6],y[7],y[8],y[9],y[10],y[11],y[12],y[13],y[14],y[15]),this.matrix.transform(u[0],u[1],u[2],u[3],u[4],u[5],u[6],u[7],u[8],u[9],u[10],u[11],u[12],u[13],u[14],u[15]),v=0;v0&&(f=!1),f){var m=r("style");m.setAttribute("f-forigin",s[i].fOrigin),m.setAttribute("f-origin",s[i].origin),m.setAttribute("f-family",s[i].fFamily),m.type="text/css",m.innerText="@font-face {font-family: "+s[i].fFamily+"; font-style: normal; src: url('"+s[i].fPath+"');}",e.appendChild(m)}}else if("g"===s[i].fOrigin||1===s[i].origin){for(l=document.querySelectorAll('link[f-forigin="g"], link[f-origin="1"]'),p=0;pt?!0!==this.isInRange&&(this.globalData._mdf=!0,this._mdf=!0,this.isInRange=!0,this.show()):!1!==this.isInRange&&(this.globalData._mdf=!0,this.isInRange=!1,this.hide())},renderRenderable:function(){var t,e=this.renderableComponents.length;for(t=0;t0&&(this.maskElement.setAttribute("id",v),this.element.maskedElement.setAttribute(_,"url("+s()+"#"+v+")"),n.appendChild(this.maskElement)),this.viewData.length&&this.element.addRenderableComponent(this)}me.prototype.prepareFrame=function(){},a([Rt,oe,he],me),me.prototype.getBaseElement=function(){return null},me.prototype.renderFrame=function(){},me.prototype.destroy=function(){},me.prototype.initExpressions=function(){this.layerInterface=fe(this)},me.prototype.getFootageData=function(){return this.footageData},de.prototype.prepareFrame=function(t){if(this.prepareRenderableFrame(t,!0),this.prepareProperties(t,!0),this.tm._placeholder)this._currentTime=t/this.data.sr;else{var e=this.tm.v;this._currentTime=e}this._volume=this.lv.v[0];var i=this._volume*this._volumeMultiplier;this._previousVolume!==i&&(this._previousVolume=i,this.audio.volume(i))},a([Rt,oe,he],de),de.prototype.renderFrame=function(){this.isInRange&&this._canPlay&&(this._isPlaying?(!this.audio.playing()||Math.abs(this._currentTime/this.globalData.frameRate-this.audio.seek())>.1)&&this.audio.seek(this._currentTime/this.globalData.frameRate):(this.audio.play(),this.audio.seek(this._currentTime/this.globalData.frameRate),this._isPlaying=!0))},de.prototype.show=function(){},de.prototype.hide=function(){this.audio.pause(),this._isPlaying=!1},de.prototype.pause=function(){this.audio.pause(),this._isPlaying=!1,this._canPlay=!1},de.prototype.resume=function(){this._canPlay=!0},de.prototype.setRate=function(t){this.audio.rate(t)},de.prototype.volume=function(t){this._volumeMultiplier=t,this._previousVolume=t*this._volume,this.audio.volume(this._previousVolume)},de.prototype.getBaseElement=function(){return null},de.prototype.destroy=function(){},de.prototype.sourceRectAtTime=function(){},de.prototype.initExpressions=function(){},ce.prototype.checkLayers=function(t){var e,i,s=this.layers.length;for(this.completeLayers=!0,e=s-1;e>=0;e-=1)this.elements[e]||(i=this.layers[e]).ip-i.st<=t-this.layers[e].st&&i.op-i.st>t-this.layers[e].st&&this.buildItem(e),this.completeLayers=!!this.elements[e]&&this.completeLayers;this.checkPendingElements()},ce.prototype.createItem=function(t){switch(t.ty){case 2:return this.createImage(t);case 0:return this.createComp(t);case 1:return this.createSolid(t);case 3:default:return this.createNull(t);case 4:return this.createShape(t);case 5:return this.createText(t);case 6:return this.createAudio(t);case 13:return this.createCamera(t);case 15:return this.createFootage(t)}},ce.prototype.createCamera=function(){throw new Error("You're using a 3d camera. Try the html renderer.")},ce.prototype.createAudio=function(t){return new de(t,this.globalData,this)},ce.prototype.createFootage=function(t){return new me(t,this.globalData,this)},ce.prototype.buildAllItems=function(){var t,e=this.layers.length;for(t=0;t1&&(a+=" C"+e.o[s-1][0]+","+e.o[s-1][1]+" "+e.i[0][0]+","+e.i[0][1]+" "+e.v[0][0]+","+e.v[0][1]),i.lastPath!==a){var n="";i.elem&&(e.c&&(n=t.inv?this.solidPath+a:a),i.elem.setAttribute("d",n)),i.lastPath=a}},ge.prototype.destroy=function(){this.element=null,this.globalData=null,this.maskElement=null,this.data=null,this.masksProperties=null};var ye=function(){var t={};return t.createFilter=function(t,e){var i=W("filter");i.setAttribute("id",t),!0!==e&&(i.setAttribute("filterUnits","objectBoundingBox"),i.setAttribute("x","0%"),i.setAttribute("y","0%"),i.setAttribute("width","100%"),i.setAttribute("height","100%"));return i},t.createAlphaToLuminanceFilter=function(){var t=W("feColorMatrix");return t.setAttribute("type","matrix"),t.setAttribute("color-interpolation-filters","sRGB"),t.setAttribute("values","0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 1"),t},t}(),ve=function(){var t={maskType:!0};return(/MSIE 10/i.test(navigator.userAgent)||/MSIE 9/i.test(navigator.userAgent)||/rv:11.0/i.test(navigator.userAgent)||/Edge\/\d./i.test(navigator.userAgent))&&(t.maskType=!1),t}(),be={},_e="filter_result_";function xe(t){var e,i,r="SourceGraphic",a=t.data.ef?t.data.ef.length:0,n=B(),o=ye.createFilter(n,!0),h=0;for(this.filters=[],e=0;e=0&&!this.shapeModifiers[t].processShapes(this._isFirstFrame);t-=1);}},searchProcessedElement:function(t){for(var e=this.processedElements,i=0,s=e.length;i.01)return!1;i+=1}return!0},ze.prototype.checkCollapsable=function(){if(this.o.length/2!=this.c.length/4)return!1;if(this.data.k.k[0].s)for(var t=0,e=this.data.k.k.length;t0;)h=s.transformers[u].mProps._mdf||h,c-=1,u-=1;if(h)for(c=y-s.styles[p].lvl,u=s.transformers.length-1;c>0;)d=s.transformers[u].mProps.v.props,m.transform(d[0],d[1],d[2],d[3],d[4],d[5],d[6],d[7],d[8],d[9],d[10],d[11],d[12],d[13],d[14],d[15]),c-=1,u-=1}else m=t;if(n=(f=s.sh.paths)._length,h){for(o="",a=0;a=1?v=.99:v<=-1&&(v=-.99);var b=o*v,_=Math.cos(y+e.a.v)*b+p[0],x=Math.sin(y+e.a.v)*b+p[1];h.setAttribute("fx",_),h.setAttribute("fy",x),l&&!e.g._collapsable&&(e.of.setAttribute("fx",_),e.of.setAttribute("fy",x))}}function h(t,e,i){var s=e.style,r=e.d;r&&(r._mdf||i)&&r.dashStr&&(s.pElem.setAttribute("stroke-dasharray",r.dashStr),s.pElem.setAttribute("stroke-dashoffset",r.dashoffset[0])),e.c&&(e.c._mdf||i)&&s.pElem.setAttribute("stroke","rgb("+v(e.c.v[0])+","+v(e.c.v[1])+","+v(e.c.v[2])+")"),(e.o._mdf||i)&&s.pElem.setAttribute("stroke-opacity",e.o.v),(e.w._mdf||i)&&(s.pElem.setAttribute("stroke-width",e.w.v),s.msElem&&s.msElem.setAttribute("stroke-width",e.w.v))}return{createRenderFunction:function(t){switch(t.ty){case"fl":return a;case"gf":return o;case"gs":return n;case"st":return h;case"sh":case"el":case"rc":case"sr":return r;case"tr":return i;case"no":return s;default:return null}}}}();function qe(t,e,i){this.shapes=[],this.shapesData=t.shapes,this.stylesList=[],this.shapeModifiers=[],this.itemsData=[],this.processedElements=[],this.animatedContents=[],this.initElement(t,e,i),this.prevViewData=[]}function We(t,e,i,s,r,a){this.o=t,this.sw=e,this.sc=i,this.fc=s,this.m=r,this.p=a,this._mdf={o:!0,sw:!!e,sc:!!i,fc:!!s,m:!0,p:!0}}function He(t,e){this._frameId=i,this.pv="",this.v="",this.kf=!1,this._isFirstFrame=!0,this._mdf=!1,this.data=e,this.elem=t,this.comp=this.elem.comp,this.keysIndex=0,this.canResize=!1,this.minimumFontSize=1,this.effectsSequence=[],this.currentData={ascent:0,boxWidth:this.defaultBoxWidth,f:"",fStyle:"",fWeight:"",fc:"",j:"",justifyOffset:"",l:[],lh:0,lineWidths:[],ls:"",of:"",s:"",sc:"",sw:0,t:0,tr:0,sz:0,ps:null,fillColorAnim:!1,strokeColorAnim:!1,strokeWidthAnim:!1,yOffset:0,finalSize:0,finalText:[],finalLineHeight:0,__complete:!1},this.copyData(this.currentData,this.data.d.k[0].s),this.searchProperty()||this.completeTextData(this.currentData)}a([oe,ue,Pe,Se,ke,he,we],qe),qe.prototype.initSecondaryElement=function(){},qe.prototype.identityMatrix=new _t,qe.prototype.buildExpressionInterface=function(){},qe.prototype.createContent=function(){this.searchShapes(this.shapesData,this.itemsData,this.prevViewData,this.layerElement,0,[],!0),this.filterUniqueShapes()},qe.prototype.filterUniqueShapes=function(){var t,e,i,s,r=this.shapes.length,a=this.stylesList.length,n=[],o=!1;for(i=0;i1&&o&&this.setShapesAsAnimated(n)}},qe.prototype.setShapesAsAnimated=function(t){var e,i=t.length;for(e=0;e=0;o-=1){if((m=this.searchProcessedElement(t[o]))?e[o]=i[m-1]:t[o]._render=n,"fl"===t[o].ty||"st"===t[o].ty||"gf"===t[o].ty||"gs"===t[o].ty||"no"===t[o].ty)m?e[o].style.closed=!1:e[o]=this.createStyleElement(t[o],r),t[o]._render&&e[o].style.pElem.parentNode!==s&&s.appendChild(e[o].style.pElem),u.push(e[o].style);else if("gr"===t[o].ty){if(m)for(l=e[o].it.length,h=0;h1,this.kf&&this.addEffect(this.getKeyframeValue.bind(this)),this.kf},He.prototype.addEffect=function(t){this.effectsSequence.push(t),this.elem.addDynamicProperty(this)},He.prototype.getValue=function(t){if(this.elem.globalData.frameId!==this.frameId&&this.effectsSequence.length||t){this.currentData.t=this.data.d.k[this.keysIndex].s.t;var e=this.currentData,i=this.keysIndex;if(this.lock)this.setCurrentData(this.currentData);else{var s;this.lock=!0,this._mdf=!1;var r=this.effectsSequence.length,a=t||this.data.d.k[this.keysIndex].s;for(s=0;se);)i+=1;return this.keysIndex!==i&&(this.keysIndex=i),this.data.d.k[this.keysIndex].s},He.prototype.buildFinalText=function(t){for(var e,i,s=[],r=0,a=t.length,n=!1;r=55296&&e<=56319?(i=t.charCodeAt(r+1))>=56320&&i<=57343?(n||zt.isModifier(e,i)?(s[s.length-1]+=t.substr(r,2),n=!1):s.push(t.substr(r,2)),r+=1):s.push(t.charAt(r)):e>56319?(i=t.charCodeAt(r+1),zt.isZeroWidthJoiner(e,i)?(n=!0,s[s.length-1]+=t.substr(r,2),r+=1):s.push(t.charAt(r))):zt.isZeroWidthJoiner(e)?(s[s.length-1]+=t.charAt(r),n=!0):s.push(t.charAt(r)),r+=1;return s},He.prototype.completeTextData=function(t){t.__complete=!0;var e,i,s,r,a,n,o,h=this.elem.globalData.fontManager,l=this.data,p=[],f=0,m=l.m.g,d=0,c=0,u=0,g=[],y=0,v=0,b=h.getFontByName(t.f),_=0,x=Bt(b);t.fWeight=x.weight,t.fStyle=x.style,t.finalSize=t.s,t.finalText=this.buildFinalText(t.t),i=t.finalText.length,t.finalLineHeight=t.lh;var P,k=t.tr/1e3*t.finalSize;if(t.sz)for(var w,A,D=!0,S=t.sz[0],C=t.sz[1];D;){w=0,y=0,i=(A=this.buildFinalText(t.t)).length,k=t.tr/1e3*t.finalSize;var E=-1;for(e=0;eS&&" "!==A[e]?(-1===E?i+=1:e=E,w+=t.finalLineHeight||1.2*t.finalSize,A.splice(e,E===e?1:0,"\r"),E=-1,y=0):(y+=_,y+=k);w+=b.ascent*t.finalSize/100,this.canResize&&t.finalSize>this.minimumFontSize&&Cv?y:v,y=-2*k,r="",s=!0,u+=1):r=T,h.chars?(o=h.getCharData(T,b.fStyle,h.getFontByName(t.f).fFamily),_=s?0:o.w*t.finalSize/100):_=h.measureText(r,t.f,t.finalSize)," "===T?M+=_+k:(y+=_+k+M,M=0),p.push({l:_,an:_,add:d,n:s,anIndexes:[],val:r,line:u,animatorJustifyOffset:0}),2==m){if(d+=_,""===r||" "===r||e===i-1){for(""!==r&&" "!==r||(d-=_);c<=e;)p[c].an=d,p[c].ind=f,p[c].extra=_,c+=1;f+=1,d=0}}else if(3==m){if(d+=_,""===r||e===i-1){for(""===r&&(d-=_);c<=e;)p[c].an=d,p[c].ind=f,p[c].extra=_,c+=1;d=0,f+=1}}else p[f].ind=f,p[f].extra=0,f+=1;if(t.l=p,v=y>v?y:v,g.push(y),t.sz)t.boxWidth=t.sz[0],t.justifyOffset=0;else switch(t.boxWidth=v,t.j){case 1:t.justifyOffset=-t.boxWidth;break;case 2:t.justifyOffset=-t.boxWidth/2;break;default:t.justifyOffset=0}t.lineWidths=g;var F,I,L,B,z=l.a;n=z.length;var R=[];for(a=0;a0?r=this.ne.v/100:a=-this.ne.v/100,this.xe.v>0?n=1-this.xe.v/100:o=1+this.xe.v/100;var h=et.getBezierEasing(r,a,n,o).get,l=0,p=this.finalS,f=this.finalE,m=this.data.sh;if(2===m)l=h(l=f===p?s>=f?1:0:t(0,e(.5/(f-p)+(s-p)/(f-p),1)));else if(3===m)l=h(l=f===p?s>=f?0:1:1-t(0,e(.5/(f-p)+(s-p)/(f-p),1)));else if(4===m)f===p?l=0:(l=t(0,e(.5/(f-p)+(s-p)/(f-p),1)))<.5?l*=2:l=1-2*(l-.5),l=h(l);else if(5===m){if(f===p)l=0;else{var d=f-p,c=-d/2+(s=e(t(0,s+.5-p),f-p)),u=d/2;l=Math.sqrt(1-c*c/(u*u))}l=h(l)}else 6===m?(f===p?l=0:(s=e(t(0,s+.5-p),f-p),l=(1+Math.cos(Math.PI+2*Math.PI*s/(f-p)))/2),l=h(l)):(s>=i(p)&&(l=t(0,e(s-p<0?e(f,1)-(p-s):f-s,1))),l=h(l));if(100!==this.sm.v){var g=.01*this.sm.v;0===g&&(g=1e-8);var y=.5-.5*g;l1&&(l=1)}return l*this.a.v},getValue:function(t){this.iterateDynamicProperties(),this._mdf=t||this._mdf,this._currentTextLength=this.elem.textProperty.currentData.l.length||0,t&&2===this.data.r&&(this.e.v=this._currentTextLength);var e=2===this.data.r?1:100/this.data.totalChars,i=this.o.v/e,s=this.s.v/e+i,r=this.e.v/e+i;if(s>r){var a=s;s=r,r=a}this.finalS=s,this.finalE=r}},a([ht],s),{getTextSelectorProp:function(t,e,i){return new s(t,e,i)}}}();function Ye(t,e,i){var s={propType:!1},r=ot.getProp,a=e.a;this.a={r:a.r?r(t,a.r,0,k,i):s,rx:a.rx?r(t,a.rx,0,k,i):s,ry:a.ry?r(t,a.ry,0,k,i):s,sk:a.sk?r(t,a.sk,0,k,i):s,sa:a.sa?r(t,a.sa,0,k,i):s,s:a.s?r(t,a.s,1,.01,i):s,a:a.a?r(t,a.a,1,0,i):s,o:a.o?r(t,a.o,0,.01,i):s,p:a.p?r(t,a.p,1,0,i):s,sw:a.sw?r(t,a.sw,0,0,i):s,sc:a.sc?r(t,a.sc,1,0,i):s,fc:a.fc?r(t,a.fc,1,0,i):s,fh:a.fh?r(t,a.fh,0,0,i):s,fs:a.fs?r(t,a.fs,0,.01,i):s,fb:a.fb?r(t,a.fb,0,.01,i):s,t:a.t?r(t,a.t,0,0,i):s},this.s=Xe.getTextSelectorProp(t,e.s,i),this.s.t=e.s.t}function Ze(t,e,i){this._isFirstFrame=!0,this._hasMaskedPath=!1,this._frameId=-1,this._textData=t,this._renderType=e,this._elem=i,this._animatorsData=p(this._textData.a.length),this._pathData={},this._moreOptions={alignment:{}},this.renderedLetters=[],this.lettersChangedFlag=!1,this.initDynamicPropertyContainer(i)}function Ke(){}Ze.prototype.searchProperties=function(){var t,e,i=this._textData.a.length,s=ot.getProp;for(t=0;t=o+ft||!c?(v=(o+ft-l)/h.partialLength,j=d.point[0]+(h.point[0]-d.point[0])*v,G=d.point[1]+(h.point[1]-d.point[1])*v,w.translate(-x[0]*S[r].an*.005,-x[1]*B*.01),p=!1):c&&(l+=h.partialLength,(f+=1)>=c.length&&(f=0,u[m+=1]?c=u[m].points:_.v.c?(f=0,c=u[m=0].points):(l-=h.partialLength,c=null)),c&&(d=h,g=(h=c[f]).partialLength));R=S[r].an/2-S[r].add,w.translate(-R,0,0)}else R=S[r].an/2-S[r].add,w.translate(-R,0,0),w.translate(-x[0]*S[r].an*.005,-x[1]*B*.01,0);for(M=0;Mt?this.textSpans[t].span:W(h?"g":"text"),y<=t){if(n.setAttribute("stroke-linecap","butt"),n.setAttribute("stroke-linejoin","round"),n.setAttribute("stroke-miterlimit","4"),this.textSpans[t].span=n,h){var v=W("g");n.appendChild(v),this.textSpans[t].childSpan=v}this.textSpans[t].span=n,this.layerElement.appendChild(n)}n.style.display="inherit"}if(l.reset(),f&&(o[t].n&&(m=-u,d+=i.yOffset,d+=c?1:0,c=!1),this.applyTextPropertiesToMatrix(i,l,o[t].line,m,d),m+=o[t].l||0,m+=u),h){var b;if(1===(g=this.globalData.fontManager.getCharData(i.finalText[t],s.fStyle,this.globalData.fontManager.getFontByName(i.f).fFamily)).t)b=new si(g.data,this.globalData,this);else{var _=Ue;g.data&&g.data.shapes&&(_=this.buildShapeData(g.data,i.finalSize)),b=new qe(_,this.globalData,this)}if(this.textSpans[t].glyph){var x=this.textSpans[t].glyph;this.textSpans[t].childSpan.removeChild(x.layerElement),x.destroy()}this.textSpans[t].glyph=b,b._debug=!0,b.prepareFrame(0),b.renderFrame(),this.textSpans[t].childSpan.appendChild(b.layerElement),1===g.t&&this.textSpans[t].childSpan.setAttribute("transform","scale("+i.finalSize/100+","+i.finalSize/100+")")}else f&&n.setAttribute("transform","translate("+l.props[12]+","+l.props[13]+")"),n.textContent=o[t].val,n.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve")}f&&n&&n.setAttribute("d","")}else{var P=this.textContainer,k="start";switch(i.j){case 1:k="end";break;case 2:k="middle";break;default:k="start"}P.setAttribute("text-anchor",k),P.setAttribute("letter-spacing",u);var w=this.buildTextContents(i.finalText);for(e=w.length,d=i.ps?i.ps[1]+i.ascent:0,t=0;t=0;e-=1)(this.completeLayers||this.elements[e])&&this.elements[e].prepareFrame(t-this.layers[e].st);if(this.globalData._mdf)for(e=0;e=0;i-=1)(this.completeLayers||this.elements[i])&&(this.elements[i].prepareFrame(this.renderedFrame-this.layers[i].st),this.elements[i]._mdf&&(this._mdf=!0))}},ii.prototype.renderInnerContent=function(){var t,e=this.layers.length;for(t=0;t0&&o<1&&f[m].push(this.calculateF(o,t,e,i,s,m)):(h=a*a-4*n*r)>=0&&((l=(-a+y(h))/(2*r))>0&&l<1&&f[m].push(this.calculateF(l,t,e,i,s,m)),(p=(-a-y(h))/(2*r))>0&&p<1&&f[m].push(this.calculateF(p,t,e,i,s,m))));this.shapeBoundingBox.left=_.apply(null,f[0]),this.shapeBoundingBox.top=_.apply(null,f[1]),this.shapeBoundingBox.right=b.apply(null,f[0]),this.shapeBoundingBox.bottom=b.apply(null,f[1])},hi.prototype.calculateF=function(t,e,i,s,r,a){return g(1-t,3)*e[a]+3*g(1-t,2)*t*i[a]+3*(1-t)*g(t,2)*s[a]+g(t,3)*r[a]},hi.prototype.calculateBoundingBox=function(t,e){var i,s=t.length;for(i=0;i=t.x+t.width&&this.currentBBox.height+this.currentBBox.y>=t.y+t.height},hi.prototype.renderInnerContent=function(){if(this._renderShapeFrame(),!this.hidden&&(this._isFirstFrame||this._mdf)){var t=this.tempBoundingBox,e=999999;if(t.x=e,t.xMax=-e,t.y=e,t.yMax=-e,this.calculateBoundingBox(this.itemsData,t),t.width=t.xMax=0;t-=1){var s=this.hierarchy[t].finalTransform.mProp;this.mat.translate(-s.p.v[0],-s.p.v[1],s.p.v[2]),this.mat.rotateX(-s.or.v[0]).rotateY(-s.or.v[1]).rotateZ(s.or.v[2]),this.mat.rotateX(-s.rx.v).rotateY(-s.ry.v).rotateZ(s.rz.v),this.mat.scale(1/s.s.v[0],1/s.s.v[1],1/s.s.v[2]),this.mat.translate(s.a.v[0],s.a.v[1],s.a.v[2])}if(this.p?this.mat.translate(-this.p.v[0],-this.p.v[1],this.p.v[2]):this.mat.translate(-this.px.v,-this.py.v,this.pz.v),this.a){var r;r=this.p?[this.p.v[0]-this.a.v[0],this.p.v[1]-this.a.v[1],this.p.v[2]-this.a.v[2]]:[this.px.v-this.a.v[0],this.py.v-this.a.v[1],this.pz.v-this.a.v[2]];var a=Math.sqrt(Math.pow(r[0],2)+Math.pow(r[1],2)+Math.pow(r[2],2)),n=[r[0]/a,r[1]/a,r[2]/a],o=Math.sqrt(n[2]*n[2]+n[0]*n[0]),h=Math.atan2(n[1],o),l=Math.atan2(n[0],-n[2]);this.mat.rotateY(l).rotateX(-h)}this.mat.rotateX(-this.rx.v).rotateY(-this.ry.v).rotateZ(this.rz.v),this.mat.rotateX(-this.or.v[0]).rotateY(-this.or.v[1]).rotateZ(this.or.v[2]),this.mat.translate(this.globalData.compSize.w/2,this.globalData.compSize.h/2,0),this.mat.translate(0,0,this.pe.v);var p=!this._prevMat.equals(this.mat);if((p||this.pe._mdf)&&this.comp.threeDElements){var f,m,d;for(e=this.comp.threeDElements.length,t=0;t=t)return this.threeDElements[e].perspectiveElem;e+=1}return null},mi.prototype.createThreeDContainer=function(t,e){var i,s,a=r("div");D(a);var n=r("div");if(D(n),"3d"===e){(i=a.style).width=this.globalData.compSize.w+"px",i.height=this.globalData.compSize.h+"px";var o="50% 50%";i.webkitTransformOrigin=o,i.mozTransformOrigin=o,i.transformOrigin=o;var h="matrix3d(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1)";(s=n.style).transform=h,s.webkitTransform=h}a.appendChild(n);var l={container:n,perspectiveElem:a,startPos:t,endPos:t,type:e};return this.threeDElements.push(l),l},mi.prototype.build3dContainers=function(){var t,e,i=this.layers.length,s="";for(t=0;t=0;t-=1)this.resizerElem.appendChild(this.threeDElements[t].perspectiveElem)},mi.prototype.addTo3dContainer=function(t,e){for(var i=0,s=this.threeDElements.length;in?(t=r/this.globalData.compSize.w,e=r/this.globalData.compSize.w,i=0,s=(a-this.globalData.compSize.h*(r/this.globalData.compSize.w))/2):(t=a/this.globalData.compSize.h,e=a/this.globalData.compSize.h,i=(r-this.globalData.compSize.w*(a/this.globalData.compSize.h))/2,s=0);var o=this.resizerElem.style;o.webkitTransform="matrix3d("+t+",0,0,0,0,"+e+",0,0,0,0,1,0,"+i+","+s+",0,1)",o.transform=o.webkitTransform},mi.prototype.renderFrame=ri.prototype.renderFrame,mi.prototype.hide=function(){this.resizerElem.style.display="none"},mi.prototype.show=function(){this.resizerElem.style.display="block"},mi.prototype.initItems=function(){if(this.buildAllItems(),this.camera)this.camera.setup();else{var t,e=this.globalData.compSize.w,i=this.globalData.compSize.h,s=this.threeDElements.length;for(t=0;t