new build
diff --git a/build/player/bodymovin.js b/build/player/bodymovin.js
index c9034bd..96c548f 100644
--- a/build/player/bodymovin.js
+++ b/build/player/bodymovin.js
@@ -1,4 +1,4 @@
-(function(window){function Matrix(t){var e=this;e._t=e.transform,e.a=e.d=1,e.b=e.c=e.e=e.f=0,e.props=[1,0,0,1,0,0],e.cssParts=["matrix(","",")"],e.a1=e.b1=e.c1=e.d1=e.e1=e.f1=0,e.context=t,e.cos=e.sin=0,t&&t.setTransform(1,0,0,1,0,0)}function BM_CanvasRenderingContext2D(t){this.renderer=t}function matrixManagerFunction(){var t=new Matrix,e=function(t,e,a,r,i,s,n,o,h){var l,p,m,d,c,f,u;return l=$M([[1,0,0,0],[0,Math.cos(t),Math.sin(-t),0],[0,Math.sin(t),Math.cos(t),0],[0,0,0,1]]),p=$M([[Math.cos(e),0,Math.sin(e),0],[0,1,0,0],[Math.sin(-e),0,Math.cos(e),0],[0,0,0,1]]),m=$M([[Math.cos(a),Math.sin(-a),0,0],[Math.sin(a),Math.cos(a),0,0],[0,0,1,0],[0,0,0,1]]),c=$M([[r,0,0,0],[0,i,0,0],[0,0,s,0],[0,0,0,1]]),f=l.x(p).x(m).x(c),f=f.transpose(),u=$M([[1,0,0,0],[0,1,0,0],[0,0,1,0],[n,o,h,1]]),f=f.x(u),d="matrix3d(",d+=f.e(1,1).toFixed(5)+","+f.e(1,2).toFixed(5)+","+f.e(1,3).toFixed(5)+","+f.e(1,4).toFixed(5)+",",d+=f.e(2,1).toFixed(5)+","+f.e(2,2).toFixed(5)+","+f.e(2,3).toFixed(5)+","+f.e(2,4).toFixed(5)+",",d+=f.e(3,1).toFixed(5)+","+f.e(3,2).toFixed(5)+","+f.e(3,3).toFixed(5)+","+f.e(3,4).toFixed(5)+",",d+=f.e(4,1).toFixed(5)+","+f.e(4,2).toFixed(5)+","+f.e(4,3).toFixed(5)+","+f.e(4,4).toFixed(5),d+=")"},a=function(e,a,r,i,s){return t.reset().translate(i,s).rotate(e).scale(a,r).toCSS()},r=function(e,a,r,i,s){return t.reset().translate(i,s).rotate(e).scale(a,r).toArray()},i=function(t){return a(t.r,t.s[0],t.s[1],t.p[0],t.p[1])},s=function(t,r){return r?e(-t.tr.r[0],t.tr.r[1],t.tr.r[2],t.tr.s[0],t.tr.s[1],t.tr.s[2],t.tr.p[0],t.tr.p[1],t.tr.p[2]):a(t.tr.r[2],t.tr.s[0],t.tr.s[1],t.tr.p[0],t.tr.p[1])},n=function(t,r){return r?e(-t.r[0],t.r[1],t.r[2],t.s[0],t.s[1],t.s[2],t.p[0],t.p[1],t.p[2]):a(t.r[2],t.s[0],t.s[1],t.p[0],t.p[1])},o=function(t,e){return e?null:r(t.r[2],t.s[0],t.s[1],t.p[0],t.p[1])};return{get2DMatrix:i,getMatrix:s,getMatrix2:n,getMatrixArray:o,getMatrixArrayFromParams:r,getMatrix2FromParams:a}}function styleDiv(t){t.style.position="absolute",t.style.top=0,t.style.left=0,t.style.display="block",t.style.verticalAlign="top",t.style.backfaceVisibility=t.style.webkitBackfaceVisibility="hidden",styleUnselectableDiv(t)}function styleUnselectableDiv(t){t.style.userSelect="none",t.style.MozUserSelect="none",t.style.webkitUserSelect="none",t.style.oUserSelect="none"}function randomString(t,e){void 0===e&&(e="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890");var a,r="";for(a=t;a>0;--a)r+=e[Math.round(Math.random()*(e.length-1))];return r}function componentToHex(t){var e=t.toString(16);return 1==e.length?"0"+e:e}function fillToRgba(t,e){if(!cachedColors[t]){var a=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);cachedColors[t]=parseInt(a[1],16)+","+parseInt(a[2],16)+","+parseInt(a[3],16)}return"rgba("+cachedColors[t]+","+e+")"}function createElement(t,e,a){if(!e){var r=Object.create(t.prototype,a),i={};return r&&"[object Function]"===i.toString.call(r.init)&&r.init(),r}e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.prototype.parent=t.prototype}function defineDescriptor(t,e,a,r){var i={writable:!1,configurable:!1,enumerable:!1,value:a};if(r)for(var s in r)i[s]=r[s];var n={};t&&"[object Function]"===n.toString.call(t)&&(t=t.prototype),Object.defineProperty(t,e,i)}function defineAccessor(t,e,a){var r,i={enumerable:!1,configurable:!1,get:function(){return r},set:function(t){r=t}};if(a)for(var s in a)i[s]=a[s];var n={};t&&"[object Function]"===n.toString.call(t)&&(t=t.prototype),Object.defineProperty(t,e,i)}function bezFunction(){function t(t,e,a,r,i,s){return l.abs((a-t)*(s-e)-(i-t)*(r-e))<1e-5}function e(t){return h[t].fnc}function a(t,e,a,r,i){if(i||(i=("bez_"+t+"_"+e+"_"+a+"_"+r).replace(/\./g,"p")),h[i])return h[i];var s,n,o,l,p,m;return h[i]=function(i,h,d,c,f){var u=h/f;i=u;for(var y,g=0;++g<14&&(o=3*t,n=3*(a-t)-o,s=1-o-n,y=i*(o+i*(n+i*s))-u,!(Math.abs(y)<.001));)i-=y/(o+i*(2*n+3*s*i));m=3*e,p=3*(r-e)-m,l=1-m-p;var v=i*(m+i*(p+i*l));return c*v+d},h[i]}function r(t){this.segmentLength=0,this.points=new Array(t)}function i(e){var a,i,s,n,o,h,l,p=e.s,m=e.e,d=e.to,c=e.ti,f=500,u=0,y=null;(p[0]!=m[0]||p[1]!=m[1])&&t(p[0],p[1],m[0],m[1],p[0]+d[0],p[1]+d[1])&&t(p[0],p[1],m[0],m[1],m[0]+c[0],m[1]+c[1])&&(f=2);var g=new r(f);for(s=d.length,a=0;f>a;a+=1){for(l=[],o=a/(f-1),h=0,i=0;s>i;i+=1)n=Math.pow(1-o,3)*p[i]+3*Math.pow(1-o,2)*o*(p[i]+d[i])+3*(1-o)*Math.pow(o,2)*(m[i]+c[i])+Math.pow(o,3)*m[i],l.push(n),null!==y&&(h+=Math.pow(l[i]-y[i],2));h=Math.sqrt(h),u+=h,g.points[a]={partialLength:h,cumulatedLength:u,point:l},y=l}g.segmentLength=u,e.bezierData=g}function s(t,e){var a=e.segments,r=a.length,i=Math.floor((r-1)*t),s=t*e.addedLength,n=0;if(s==a[i].l)return a[i].p;for(var o=a[i].l>s?-1:1,h=!0;h;)a[i].l<=s&&a[i+1].l>s?(n=(s-a[i].l)/(a[i+1].l-a[i].l),h=!1):i+=o,(0>i||i>=r-1)&&(h=!1);return a[i].p+(a[i+1].p-a[i].p)*n}function n(){this.pt1=new Array(2),this.pt2=new Array(2),this.pt3=new Array(2),this.pt4=new Array(2)}function o(t,e,a,r,i,o,h){var l=new n;i=0>i?0:i;var p=s(i,h);o=o>1?1:o;var m,d=s(o,h),c=t.length,f=1-p,u=1-d;for(m=0;c>m;m+=1)l.pt1[m]=f*f*f*t[m]+(p*f*f+f*p*f+f*f*p)*a[m]+(p*p*f+f*p*p+p*f*p)*r[m]+p*p*p*e[m],l.pt3[m]=f*f*u*t[m]+(p*f*u+f*p*u+f*f*d)*a[m]+(p*p*u+f*p*d+p*f*d)*r[m]+p*p*d*e[m],l.pt4[m]=f*u*u*t[m]+(p*u*u+f*d*u+f*u*d)*a[m]+(p*d*u+f*d*d+p*u*d)*r[m]+p*d*d*e[m],l.pt2[m]=u*u*u*t[m]+(d*u*u+u*d*u+u*u*d)*a[m]+(d*d*u+u*d*d+d*u*d)*r[m]+d*d*d*e[m];return l}var h=[],l=Math,p=function(){var e={};return function(a,r,i,s){var n=(a.join("_")+"_"+r.join("_")+"_"+i.join("_")+"_"+s.join("_")).replace(/\./g,"p");if(e[n])return e[n];var o,h,l,p,m,d,c=100,f=0,u=[],y=[],g={addedLength:0,segments:[]};for((a[0]!=r[0]||a[1]!=r[1])&&t(a[0],a[1],r[0],r[1],i[0],i[1])&&t(a[0],a[1],r[0],r[1],s[0],s[1])&&(c=2),l=i.length,o=0;c>o;o+=1){for(m=o/(c-1),d=0,h=0;l>h;h+=1)p=Math.pow(1-m,3)*a[h]+3*Math.pow(1-m,2)*m*i[h]+3*(1-m)*Math.pow(m,2)*s[h]+Math.pow(m,3)*r[h],u[h]=p,null!==y[h]&&(d+=Math.pow(u[h]-y[h],2)),y[h]=u[h];d&&(d=Math.sqrt(d),f+=d),g.segments.push({l:f,p:m})}return g.addedLength=f,e[n]=g,g}}();return{getEasingCurve:a,getEasingCurveByIndex:e,getBezierLength:p,getNewSegment:o,buildBezierData:i}}function dataFunctionManager(){function t(t,e,a){var r,i=o(t,e,a),s=[];for(r=0;e>r;r+=1)s.push(Math.floor(i[r]*v));return s}function e(t,e){var a,r,i,s=t.length;for(a=0;s>a;a+=1)if(void 0!==t[a].t)if(t[a].s instanceof Array)for(i=t[a].s.length,r=0;i>r;r+=1)t[a].s[r]*=e,void 0!==t[a].e&&(t[a].e[r]*=e);else t[a].s&&(t[a].s*=e,t[a].e&&(t[a].e*=e));else t[a]=t[a]*e}function a(n,o){o||(o=n);var h,l,p,m,d,c,f,u,y,g,v=n.length;for(c=0;v>c;c+=1){if(p=n[c],h=p.outPoint-p.startTime,l=p.startTime,p.tt&&(n[c-1].td=p.tt),p.renderedFrame={},p.renderedData={},m=[],d=-1,p.tm&&(p.trmp=p.tm,p.tm=t(p.tm,h,l)),p.ks.o instanceof Array?e(p.ks.o,.01):p.ks.o/=100,p.ks.s instanceof Array?e(p.ks.s,.01):p.ks.s/=100,p.ks.r instanceof Array?e(p.ks.r,C):p.ks.r*=C,p.hasMask){var b=p.masksProperties;for(u=b.length,f=0;u>f;f+=1)if(b[f].pt.i)s(b[f].pt);else for(g=b[f].pt.length,y=0;g>y;y+=1)b[f].pt[y].s&&s(b[f].pt[y].s[0]),b[f].pt[y].e&&s(b[f].pt[y].e[0])}"PreCompLayer"==p.ty?p.refId&&!p.layers?p.layers=r(p.refId,o):a(p.layers,o):"ShapeLayer"==p.ty&&i(p.shapes)}}function r(t,e,a){a||(a=e);var i,s=e.length;for(i=0;s>i;i+=1){if(e[i].compId==t)return e[i].layers||(e[i].layers=r(e[i].refId,a)),e[i].layers;if("PreCompLayer"==e[i].ty){var n=r(t,e[i].layers,a);if(n)return n}}return null}function i(t,a){var r,n,o,h,l=t.length,p=a?a:!1;for(r=l-1;r>=0;r-=1)if(t[r].renderedData=[],"tm"==t[r].ty&&(p=!0),"fl"==t[r].ty||"st"==t[r].ty)t[r].o instanceof Array?e(t[r].o,.01):t[r].o*=.01;else if("sh"==t[r].ty)if(t[r].trimmed=p,t[r].ks.i)s(t[r].ks);else for(o=t[r].ks.length,n=0;o>n;n+=1)t[r].ks[n].s&&(s(t[r].ks[n].s[0]),s(t[r].ks[n].e[0]));else"gr"==t[r].ty?i(t[r].it,p):"tr"==t[r].ty?(h=t[r],h.renderedData=[],h.o instanceof Array?e(h.o,.01):h.o/=100,h.s instanceof Array?e(h.s,.01):h.s/=100,h.r instanceof Array?e(h.r,C):h.r*=C):"rc"==t[r].ty&&(t[r].trimmed=p,t[r].trimmed=!0)}function s(t){var e,a=t.i.length;for(e=0;a>e;e+=1)t.i[e][0]+=t.v[e][0],t.i[e][1]+=t.v[e][1],t.o[e][0]+=t.v[e][0],t.o[e][1]+=t.v[e][1]}function n(t){x[t._id]={data:t,renderedFrames:[]},v=t.animation.frameRate,a(t.animation.layers)}function o(t,e,a){var r,i,s=[];if(!(t instanceof Array)||null===t[0].t)return s.push(t),s;var n,o;s=[];var h,l,p,m=[];i=t.length;var d,c,f;for(r=0;i>r;r+=1)n=t[r],n.t-=a;var u=0,y=0;for(r=0;e>r;r+=1){h=u;for(var g=!1;i-1>h;){if(n=t[h],o=t[h+1],r<n.t&&0===h){for(p=n.s.length,m=[],l=0;p>l;l+=1)m.push(n.s[l]);s.push(m),g=!0,u!=h&&(u=h,y=0);break}if(r>=n.t&&r<o.t){if(m=[],n.to){d=bez.getEasingCurve(n.o.x,n.o.y,n.i.x,n.i.y)("",r-n.t,0,1,o.t-n.t),c=n.bezierData;var v,b,x=c.segmentLength*d;for(l=y;l<c.points.length;){if(0===r||0===x||0===d){m=c.points[l].point,y=l;break}if(l==c.points.length-1)m=c.points[l].point;else if(x>c.points[l].partialLength&&x<c.points[l+1].partialLength){for(v=c.points[l].point.length,b=(x-c.points[l].partialLength)/(c.points[l+1].partialLength-c.points[l].partialLength),f=0;v>f;f+=1)m.push(c.points[l].point[f]+(c.points[l+1].point[f]-c.points[l].point[f])*b);y=l;break}l+=1}}else{var C,E,D,w;n.s.forEach(function(t,e){if(1!==n.h&&(n.o.x instanceof Array?(C=n.o.x[e],E=n.o.y[e],D=n.i.x[e],w=n.i.y[e]):(C=n.o.x,E=n.o.y,D=n.i.x,w=n.i.y),d=bez.getEasingCurve(C,E,D,w)("",r-n.t,0,1,o.t-n.t)),t.i){var a={i:[],o:[],v:[]};t.i.forEach(function(r,i){var s=[],o=[],h=[];r.forEach(function(a,r){1===n.h?(s.push(a),o.push(t.o[i][r]),h.push(t.v[i][r])):(s.push(a+(n.e[e].i[i][r]-a)*d),o.push(t.o[i][r]+(n.e[e].o[i][r]-t.o[i][r])*d),h.push(t.v[i][r]+(n.e[e].v[i][r]-t.v[i][r])*d))}),a.i.push(s),a.o.push(o),a.v.push(h)}),m.push(a)}else m.push(1===n.h?t:t+(n.e[e]-t)*d)})}s.push(m),g=!0,u!=h&&(u=h,y=0);break}h+=1}g===!1&&(n=t[t.length-2],m=[],n.e.forEach(function(t){m.push(t)}),s.push(m))}for(h=s.length;e>h;)s.push(m),h+=1;return s}function h(t,e,a,r){var i,s,n,o,h,l;if(!t.length)return"p"==r.type?(w.px=t,w.py=t):"s"==r.type?(w.sx=t,w.sy=t):("r"==r.type||"px"==r.type||"py"==r.type)&&(w[r.type]=t),r.toArray?[t]:t;if(void 0===t[0].t)return"p"==r.type?(w.px=t[0],w.py=t[1]):"s"==r.type?(w.sx=t[0],w.sy=t[1]):("r"==r.type||"px"==r.type||"py"==r.type)&&(w[r.type]=t[0]),t;h=0,l=t.length-1;for(var p=1,m=!0;!(!m||(i=t[h],s=t[h+1],h==l-1&&e>=s.t-a)||s.t-a>e&&1==p);){if(s.t-a<e&&-1==p){h+=1,i=t[h],s=t[h+1];break}l-1>h&&1==p||h>0&&-1==p?h+=p:m=!1}i.to&&!i.bezierData&&bez.buildBezierData(i);var d,c,f,u,y,g=0;if("default"==r.type&&(n=[]),i.to){if(o=i.bezierData,e>=s.t-a)return"p"==r.type?(w.px=o.points[o.points.length-1].point[0],w.py=o.points[o.points.length-1].point[1]):"s"==r.type?(w.sx=o.points[o.points.length-1].point[0],w.sy=o.points[o.points.length-1].point[1]):("r"==r.type||"px"==r.type||"py"==r.type)&&(w[r.type]=o.points[o.points.length-1].point[0]),o.points[o.points.length-1].point;if(e<i.t-a)return"p"==r.type?(w.px=o.points[0].point[0],w.py=o.points[0].point[1]):"s"==r.type?(w.sx=o.points[0].point[0],w.sy=o.points[0].point[1]):("r"==r.type||"px"==r.type||"py"==r.type)&&(w[r.type]=o.points[0].point[0]),o.points[0].point;i.__fnct?y=i.__fnct:(y=bez.getEasingCurve(i.o.x,i.o.y,i.i.x,i.i.y,i.n),i.__fnct=y),f=y("",e-(i.t-a),0,1,s.t-a-(i.t-a));var v,b=o.segmentLength*f,x=0;for(p=1,m=!0,u=o.points.length;m;){if(x+=o.points[g].partialLength*p,0===b||0===f){"p"==r.type?(w.px=o.points[g].point[0],w.py=o.points[g].point[1]):"s"==r.type?(w.sx=o.points[g].point[0],w.sy=o.points[g].point[1]):"r"==r.type||"px"==r.type||"py"==r.type?w[r.type]=o.points[g].point[0]:n=o.points[g].point;break}if(g==o.points.length-1){"p"==r.type?(w.px=o.points[g].point[0],w.py=o.points[g].point[1]):"s"==r.type?(w.sx=o.points[g].point[0],w.sy=o.points[g].point[1]):"r"==r.type||"px"==r.type||"py"==r.type?w[r.type]=o.points[g].point[0]:n=o.points[g].point;break}if(b>x&&b<x+o.points[g+1].partialLength){if(v=(b-x)/o.points[g+1].partialLength,"p"==r.type)w.px=o.points[g].point[0]+(o.points[g+1].point[0]-o.points[g].point[0])*v,w.py=o.points[g].point[1]+(o.points[g+1].point[1]-o.points[g].point[1])*v;else if("s"==r.type)w.sx=o.points[g].point[0]+(o.points[g+1].point[0]-o.points[g].point[0])*v,w.sy=o.points[g].point[1]+(o.points[g+1].point[1]-o.points[g].point[1])*v;else if("r"==r.type||"px"==r.type||"py"==r.type)w[r.type]=o.points[g].point[0]+(o.points[g+1].point[0]-o.points[g].point[0])*v;else for(c=o.points[g].point.length,d=0;c>d;d+=1)n.push(o.points[g].point[d]+(o.points[g+1].point[d]-o.points[g].point[d])*v);break}u-1>g&&1==p||g>0&&-1==p?g+=p:m=!1}}else{var C,E,D,S,A=!1;for(l=i.s.length,h=0;l>h;h+=1)1!==i.h&&(i.o.x instanceof Array?(A=!0,C=i.o.x[h]?i.o.x[h]:i.o.x[0],E=i.o.y[h]?i.o.y[h]:i.o.y[0],D=i.i.x[h]?i.i.x[h]:i.i.x[0],S=i.i.y[h]?i.i.y[h]:i.i.y[0],i.__fnct||(i.__fnct=[])):(A=!1,C=i.o.x,E=i.o.y,D=i.i.x,S=i.i.y),A?i.__fnct[h]?y=i.__fnct[h]:(y=bez.getEasingCurve(C,E,D,S),i.__fnct[h]=y):i.__fnct?y=i.__fnct:(y=bez.getEasingCurve(C,E,D,S),i.__fnct=y),f=e>=s.t-a?1:e<i.t-a?0:y("",e-(i.t-a),0,1,s.t-a-(i.t-a))),1===i.h?"p"==r.type?0===h?w.px=i.s[h]:1==h&&(w.py=i.s[h]):"s"==r.type?0===h?w.sx=i.s[h]:1==h&&(w.sy=i.s[h]):"px"==r.type||"py"==r.type||"r"==r.type?w[r.type]=i.s[h]:n.push(i.s[h]):"p"==r.type?0===h?w.px=i.s[h]+(i.e[h]-i.s[h])*f:1==h&&(w.py=i.s[h]+(i.e[h]-i.s[h])*f):"s"==r.type?0===h?w.sx=i.s[h]+(i.e[h]-i.s[h])*f:1==h&&(w.sy=i.s[h]+(i.e[h]-i.s[h])*f):"px"==r.type||"py"==r.type||"r"==r.type?w[r.type]=i.s[h]+(i.e[h]-i.s[h])*f:n.push(i.s[h]+(i.e[h]-i.s[h])*f)}return n}function l(t,e){if(!t.__lengths){t.__lengths=[],t.__totalLength=0;var a,r=t.v,i=t.o,s=t.i,n=r.length;for(a=0;n-1>a;a+=1)t.__lengths.push(bez.getBezierLength(r[a],r[a+1],i[a],s[a+1])),t.__totalLength+=t.__lengths[a].addedLength;e&&(t.__lengths.push(bez.getBezierLength(r[a],r[0],i[a],s[0])),t.__totalLength+=t.__lengths[a].addedLength)}}function p(t,e,a,r,i,s){var n=s&&s.length>0,o={};o.closed=i?t.cl:t.closed;var h=i?t.pt:t.ks;if(h.v)return o.pathNodes=n?D(h,o.closed,s,!1):h,o;t={i:[],o:[],v:[]};var l,p,m,d,c,f,u,y=[];if(e<h[0].t-a){if(!h.__minValue){for(p=h[0].s[0].i.length,l=0;p>l;l+=1){for(c=[],f=[],u=[],d=h[0].s[0].i[l].length,m=0;d>m;m+=1)c.push(h[0].s[0].i[l][m]),f.push(h[0].s[0].o[l][m]),u.push(h[0].s[0].v[l][m]);t.i.push(c),t.o.push(f),t.v.push(u)}y.push(t),h.__minValue=y[0]}return o.pathNodes=n?D(h.__minValue,o.closed,s,!1):h.__minValue,o}if(e>h[h.length-1].t-a){if(!h.__maxValue){var g=h.length-2;for(p=h[g].s[0].i.length,l=0;p>l;l+=1){for(c=[],f=[],u=[],d=h[g].s[0].i[l].length,m=0;d>m;m+=1)c.push(h[g].e[0].i[l][m]),f.push(h[g].e[0].o[l][m]),u.push(h[g].e[0].v[l][m]);t.i.push(c),t.o.push(f),t.v.push(u)}y.push(t),h.__maxValue=y[0]}return o.pathNodes=n?D(h.__maxValue,o.closed,s,!1):h.__maxValue,o}for(var v,b,x=0,C=h.length-1,E=1,w=!0;w&&(v=h[x],b=h[x+1],!(b.t-a>e&&1==E));)C-1>x&&1==E||x>0&&-1==E?x+=E:w=!1;var S,A,M,F,I;if(1!==v.h){S=v.o.x,A=v.o.y,M=v.i.x,F=v.i.y;var P;v.__fnct?P=v.__fnct:(P=bez.getEasingCurve(S,A,M,F),v.__fnct=P),I=P("",e-(v.t-a),0,1,b.t-a-(v.t-a)),e>=b.t-a?I=1:e<v.t-a&&(I=0)}if(1===v.h&&v.__hValue)y.push(v.__hValue);else for(t={i:[],o:[],v:[]},p=v.s[0].i.length,l=0;p>l;l+=1){for(c=[],f=[],u=[],d=v.s[0].i[l].length,m=0;d>m;m+=1)1===v.h?(c.push(v.s[0].i[l][m]),f.push(v.s[0].o[l][m]),u.push(v.s[0].v[l][m])):(c.push(v.s[0].i[l][m]+(v.e[0].i[l][m]-v.s[0].i[l][m])*I),f.push(v.s[0].o[l][m]+(v.e[0].o[l][m]-v.s[0].o[l][m])*I),u.push(v.s[0].v[l][m]+(v.e[0].v[l][m]-v.s[0].v[l][m])*I));t.i.push(c),t.o.push(f),t.v.push(u),1===v.h&&(v.__hValue=t),y.push(t)}return o.pathNodes=n?D(y[0],o.closed,s,!1):y[0],o}function m(t,e,a){var r,i,s,n,o,l,d,f,u,y=t.length;for(f=0;y>f;f+=1){if(u=t[f],n=e-u.startTime,r={},E.arrayFlag=!1,E.type="default",r.a=h(u.ks.a,n,u.startTime,E),r.o=h(u.ks.o,n,u.startTime,E),E.arrayFlag=!1,u.ks.p.s?(E.type="px",h(u.ks.p.x,n,u.startTime,E),E.type="py",h(u.ks.p.y,n,u.startTime,E)):(E.type="p",h(u.ks.p,n,u.startTime,E)),E.arrayFlag=!0,E.type="r",h(u.ks.r,n,u.startTime,E),E.arrayFlag=!0,E.type="s",h(u.ks.s,n,u.startTime,E),d={},d.an={tr:r},E.arrayFlag=!1,E.type="default",d.an.matrixArray="canvas"==a?b.getMatrixArrayFromParams(w.r,w.sx,w.sy,w.px,w.py):b.getMatrixArrayFromParams(w.r,w.sx,w.sy,w.px,w.py),u.renderedData[n]=d,u.hasMask)for(i=u.masksProperties,l=i.length,o=0;l>o;o+=1)i[o].paths||(i[o].paths=[],i[o].opacity=[]),i[o].paths[n]=p(i[o],n,u.startTime,a,!0),i[o].opacity[n]=h(i[o].o,n,u.startTime,E),i[o].opacity[n]=i[o].opacity[n]instanceof Array?i[o].opacity[n][0]/100:i[o].opacity[n]/100;e<u.inPoint||e>u.outPoint||("PreCompLayer"==u.ty?(s=u.tm?u.tm[n]<0?0:n>=u.tm.length?u.tm[u.tm.length-1]:u.tm[n]:n,void 0===s&&(s=h(u.trmp,n,0,E)[0]*v,u.tm[n]=s),m(u.layers,s,a)):"ShapeLayer"==u.ty&&c(u.shapes,n,u.startTime,a))}}function d(t,e,a){a=Math.min(e[0],e[1],a/2);var r=new Array(8),i=new Array(8),s=new Array(8),n=a/2;return a*=1,r[0]=[t[0]+e[0]/2,t[1]-e[1]/2+a],s[0]=r[0],i[0]=[t[0]+e[0]/2,t[1]-e[1]/2+n],r[1]=[t[0]+e[0]/2,t[1]+e[1]/2-a],s[1]=[t[0]+e[0]/2,t[1]+e[1]/2-n],i[1]=r[1],r[2]=[t[0]+e[0]/2-a,t[1]+e[1]/2],s[2]=r[2],i[2]=[t[0]+e[0]/2-n,t[1]+e[1]/2],r[3]=[t[0]-e[0]/2+a,t[1]+e[1]/2],s[3]=[t[0]-e[0]/2+n,t[1]+e[1]/2],i[3]=r[3],r[4]=[t[0]-e[0]/2,t[1]+e[1]/2-a],s[4]=r[4],i[4]=[t[0]-e[0]/2,t[1]+e[1]/2-n],r[5]=[t[0]-e[0]/2,t[1]-e[1]/2+a],s[5]=[t[0]-e[0]/2,t[1]-e[1]/2+n],i[5]=r[5],r[6]=[t[0]-e[0]/2+a,t[1]-e[1]/2],s[6]=r[6],i[6]=[t[0]-e[0]/2+n,t[1]-e[1]/2],r[7]=[t[0]+e[0]/2-a,t[1]-e[1]/2],s[7]=[t[0]+e[0]/2-n,t[1]-e[1]/2],i[7]=r[7],{v:r,o:s,i:i,c:!0}}function c(t,e,a,r,i){var s,n,o,l,m,u,y,g,v,x,C=t.length;i||(i=[]);var S,A,M,F,I;for(s=C-1;s>=0;s-=1)if(n=t[s],"sh"==n.ty)n.renderedData[e]={path:p(n,e,a,r,!1,i)};else if("fl"==n.ty)o=h(n.c,e,a,E),l=h(n.o,e,a,E),n.renderedData[e]={opacity:l instanceof Array?l[0]:l},"canvas"==r?(f(o),n.renderedData[e].color=o):n.renderedData[e].color=rgbToHex(Math.round(o[0]),Math.round(o[1]),Math.round(o[2]));else if("rc"==n.ty)m=h(n.p,e,a,E),u=h(n.s,e,a,E),y=h(n.r,e,a,E),n.trimmed?(n.renderedData[e]={path:{closed:!0}},n.renderedData[e].path.pathNodes=D(d(m,u,y),!0,i,!1)):n.renderedData[e]={position:m,size:u,roundness:y};else if("el"==n.ty){if(m=h(n.p,e,a,E),u=h(n.s,e,a,E),n.renderedData[e]={p:m,size:u},"svg"==r){var P={v:new Array(4),i:new Array(4),o:new Array(4)};P.v[0]=[m[0],m[1]-u[1]/2],P.o[0]=[m[0]-u[0]/2*.55,m[1]-u[1]/2],P.i[0]=[m[0]+u[0]/2*.55,m[1]-u[1]/2],P.v[1]=[m[0]-u[0]/2,m[1]],P.o[1]=[m[0]-u[0]/2,m[1]+u[1]/2*.55],P.i[1]=[m[0]-u[0]/2,m[1]-u[1]/2*.55],P.v[2]=[m[0],m[1]+u[1]/2],P.o[2]=[m[0]+u[0]/2*.55,m[1]+u[1]/2],P.i[2]=[m[0]-u[0]/2*.55,m[1]+u[1]/2],P.v[3]=[m[0]+u[0]/2,m[1]],P.o[3]=[m[0]+u[0]/2,m[1]-u[1]/2*.55],P.i[3]=[m[0]+u[0]/2,m[1]+u[1]/2*.55],n.renderedData[e].path={pathNodes:P},n.closed=!0}}else if("st"==n.ty){if(g=h(n.c,e,a,E),v=h(n.o,e,a,E),x=h(n.w,e,a,E),n.renderedData[e]={opacity:v instanceof Array?v[0]:v,width:x instanceof Array?x[0]:x},n.d){var T=[];I=n.d.length;var k;for(F=0;I>F;F+=1)k=h(n.d[F].v,e,a,E),T.push({v:k instanceof Array?k[0]:k,n:n.d[F].n});n.renderedData[e].dashes=T}"canvas"==r?(f(g),n.renderedData[e].color=g):n.renderedData[e].color=rgbToHex(Math.round(g[0]),Math.round(g[1]),Math.round(g[2]))}else if("tr"==n.ty)n.renderedData[e]={a:h(n.a,e,a,E),o:h(n.o,e,a,E)},E.arrayFlag=!0,E.type="s",h(n.s,e,a,E),E.arrayFlag=!0,E.type="r",h(n.r,e,a,E),E.arrayFlag=!1,E.type="p",h(n.p,e,a,E),E.arrayFlag=!1,E.type="default",n.renderedData[e].mtArr="canvas"==r?b.getMatrixArrayFromParams(w.r,w.sx,w.sy,w.px,w.py):b.getMatrixArrayFromParams(w.r,w.sx,w.sy,w.px,w.py);else if("tm"==n.ty){S=h(n.s,e,a,E),A=h(n.e,e,a,E),M=h(n.o,e,a,E);var _={s:S,e:A,o:M};i.push(_),n.renderedData[e]=_}else"gr"==n.ty&&c(n.it,e,a,r,i)}function f(t){var e,a=t.length;for(e=0;a>e;e+=1)t[e]=Math.round(t[e])}function u(t,e){for(var a=1;a>0;){if(e+=1,e>=t.data.animation.totalFrames){t.renderFinished=!0;break}t.renderedFrames[e]||(y(t.data._id,e),a-=1)}}function y(t,e){return 2==x[t].renderedFrames[e]?void(x[t].renderFinished||u(x[t],e)):(v=x[t].data.animation.frameRate,x[t].renderedFrames[e]=2,void m(x[t].data.animation.layers,e,x[t].data._animType))}function g(t){var e,a=x[t].data,r=a.animation.totalFrames,i=[];for(e=0;r>e;e+=1)i.push({num:e,data:y(t,e)})}var v=0,b=new MatrixManager,x={},C=Math.PI/180,E={arrayFlag:!1},D=function(){function t(t,s,n,l,m){r[o]=s,e[o+1]=n,a[o+1]=l,h?a[o]=t:(p+=" M"+t.join(","),h=!0,i[o]=t),p+=" C"+s.join(",")+" "+n.join(",")+" "+l.join(","),o+=1}var e,a,r,i,s,n,o,h=!1,p="";return function(m,d,c,f){l(m,d);var u,y=c.length,g=m;a=e=r=i=null;var v,b,x,C,E;for(u=y-1;u>=0;u-=1){var D=[],w=c[u].o%360/360;if(0!==w||0!==c[u].s||100!=c[u].e){p="",h=!1,e=[],r=[],a=[],i=[],s=[],n=0,0>w&&(w+=1);var S=c[u].s/100+w,A=c[u].e/100+w;if(S==A)return f?"":{};if(S>A){var M=S;S=A,A=M}1>=A?D.push({s:g.__totalLength*S,e:g.__totalLength*A}):S>=1?D.push({s:g.__totalLength*(S-1),e:g.__totalLength*(A-1)}):(D.push({s:g.__totalLength*S,e:g.__totalLength}),D.push({s:0,e:g.__totalLength*(A-1)})),v=[],b=[],x=[];var F;v=g.v,b=g.o,x=g.i,F=g.__lengths,E=v.length;var I,P,T=0,k=0,_=D.length;for(o=0,I=0;_>I;I+=1){for(T=0,C=1;E>C;C++)if(k=F[C-1].addedLength,T+k<D[I].s)T+=k;else{if(T>D[I].e)break;D[I].s<=T&&D[I].e>=T+k?t(v[C-1],b[C-1],x[C],v[C],F[C-1]):(P=bez.getNewSegment(v[C-1],v[C],b[C-1],x[C],(D[I].s-T)/k,(D[I].e-T)/k,F[C-1]),t(P.pt1,P.pt3,P.pt4,P.pt2)),T+=k}d!==!1?T<=D[I].e&&(k=F[C-1].addedLength,D[I].s<=T&&D[I].e>=T+k?t(v[C-1],b[C-1],x[0],v[0],F[C-1]):(P=bez.getNewSegment(v[C-1],v[0],b[C-1],x[0],(D[I].s-T)/k,(D[I].e-T)/k,F[C-1]),t(P.pt1,P.pt3,P.pt4,P.pt2))):h=!1}d=!1}}if(a?(v=a,b=r,x=e):(v=g.v,b=g.o,x=g.i,i=[]),E=v.length,f){for(p="",C=1;E>C;C++)i[C-1]?p+="M"+i[C-1].join(","):1==C&&(p+="M"+v[0].join(",")),p+=" C"+b[C-1].join(",")+" "+x[C].join(",")+" "+v[C].join(",");return d!==!1&&(p+=" C"+b[C-1].join(",")+" "+x[0].join(",")+" "+v[0].join(",")),p}return{i:x,o:b,v:v,s:i,c:d}}}(),w={r:0,sx:1,sy:1,px:1,py:1},S={};return S.completeData=n,S.renderFrame=y,S.renderAllFrames=g,S}function SVGRenderer(t){this.animationItem=t,this.layers=null,this.lastFrame=-1,this.globalData={frameNum:-1},this.elements=[]}function CanvasRenderer(t,e){this.animationItem=t,this.renderConfig=e?e:{clearCanvas:!0,context:null,scaleMode:"fit"},this.lastFrame=-1,this.globalData={frameNum:-1},this.contextData={saved:new Array(15),savedOp:new Array(15),cArrPos:0,cTr:new Matrix,cO:1};var a,r=15;for(a=0;r>a;a+=1)this.contextData.saved[a]=new Array(6);this.elements=[]}function MaskElement(t,e,a){this.data=t,this.storedData=[],this.element=e,this.globalData=a,this.paths=[],this.registeredEffects=[],this.masksProperties=[],this.maskElement=document.createElementNS(svgNS,"mask")}function ICompElement(t,e,a,r){this.parent.constructor.call(this,t,e,a,r),this.layers=t.layers}function IImageElement(t,e,a,r){this.animationItem=e,this.assetData=this.animationItem.getAssetData(t.id),this.path=this.animationItem.getPath(),this.parent.constructor.call(this,t,e,a,r)}function IShapeElement(t,e,a,r){this.shapes=[],this.parent.constructor.call(this,t,e,a,r)}function ShapeItemElement(t,e,a){this.stylesList=[],this.viewData=[],this.shape=e,this.data=t,this.globalData=a,this.searchShapes(this.data,this.viewData),styleUnselectableDiv(this.shape)}function ISolidElement(t,e,a,r){this.parent.constructor.call(this,t,e,a,r)}function ITextElement(t,e,a,r){this.parent.constructor.call(this,t,e,a,r)}function CVBaseElement(t,e){this.data=t,this.globalData=e,this.canvasContext=e.canvasContext,this.currentAnimData=null,this.renderFrame=!1,this.ownMatrix=new Matrix,this.finalTransform={mat:new Matrix,opacity:1},this.init()}function CVCompElement(t,e){this.parent.constructor.call(this,t,e),this.layers=t.layers}function CVImageElement(t,e){this.animationItem=e.renderer.animationItem,this.assetData=this.animationItem.getAssetData(t.id),this.path=this.animationItem.getPath(),this.parent.constructor.call(this,t,e),this.animationItem.pendingElements+=1}function CVShapeElement(t,e){this.shapes=[],this.parent.constructor.call(this,t,e)}function CVShapeItemElement(t,e,a){this.data=t,this.globalData=a,this.canvasContext=a.canvasContext,this.frameNum=-1,this.dataLength=this.data.length,this.mainFlag=e,this.stylesList=[],this.ownStylesList=[],this.stylesPool=[],this.currentStylePoolPos=0,this.transform={opacity:1,mat:new Matrix},this.mat=new Matrix;var r,i=this.dataLength-1;this.renderedPaths=new Array(this.globalData.totalFrames);var s;for(r=i;r>=0;r-=1)"gr"==this.data[r].ty?this.data[r].item=new CVShapeItemElement(this.data[r].it,!1,this.globalData):("st"==this.data[r].ty||"fl"==this.data[r].ty)&&(s={type:"fill",styleOpacity:0,opacity:0,value:"rgba(0,0,0,0)",closed:!1},"fl"==this.data[r].ty?s.type="fill":(s.type="stroke",s.width=0),this.stylesPool.push(s))}function CVSolidElement(t,e){this.parent.constructor.call(this,t,e)}function CVTextElement(t,e){this.parent.constructor.call(this,t,e)}function CVMaskElement(){}var svgNS="http://www.w3.org/2000/svg";Matrix.prototype={concat:function(t){return this.clone()._t(t.a,t.b,t.c,t.d,t.e,t.f)},flipX:function(){return this._t(-1,0,0,1,0,0)},flipY:function(){return this._t(1,0,0,-1,0,0)},reflectVector:function(t,e){var a=this.applyToPoint(0,1),r=2*(a.x*t+a.y*e);return t-=r*a.x,e-=r*a.y,{x:t,y:e}},reset:function(){return this.setTransform(1,0,0,1,0,0)},rotate:function(t){return 0===t?this:(this.cos=Math.cos(t),this.sin=Math.sin(t),this._t(this.cos,this.sin,-this.sin,this.cos,0,0))},rotateFromVector:function(t,e){return this.rotate(Math.atan2(e,t))},rotateDeg:function(t){return this.rotate(t*Math.PI/180)},scaleU:function(t){return this._t(t,0,0,t,0,0)},scale:function(t,e){return 1==t&&1==e?this:this._t(t,0,0,e,0,0)},scaleX:function(t){return this._t(t,0,0,1,0,0)},scaleY:function(t){return this._t(1,0,0,t,0,0)},shear:function(t,e){return this._t(1,e,t,1,0,0)},shearX:function(t){return this._t(1,0,t,1,0,0)},shearY:function(t){return this._t(1,t,0,1,0,0)},skew:function(t,e){return this.shear(Math.tan(t),Math.tan(e))},skewX:function(t){return this.shearX(Math.tan(t))},skewY:function(t){return this.shearY(Math.tan(t))},setTransform:function(t,e,a,r,i,s){return this.props[0]=t,this.props[1]=e,this.props[2]=a,this.props[3]=r,this.props[4]=i,this.props[5]=s,this._x()},translate:function(t,e){return this._t(1,0,0,1,t,e)},translateX:function(t){return this._t(1,0,0,1,t,0)},translateY:function(t){return this._t(1,0,0,1,0,t)},transform:function(t,e,a,r,i,s){return this.a1=this.props[0],this.b1=this.props[1],this.c1=this.props[2],this.d1=this.props[3],this.e1=this.props[4],this.f1=this.props[5],this.props[0]=this.a1*t+this.c1*e,this.props[1]=this.b1*t+this.d1*e,this.props[2]=this.a1*a+this.c1*r,this.props[3]=this.b1*a+this.d1*r,this.props[4]=this.a1*i+this.c1*s+this.e1,this.props[5]=this.b1*i+this.d1*s+this.f1,this._x()},divide:function(t){if(!t.isInvertible())throw"Input matrix is not invertible";var e=t.inverse();return this._t(e.a,e.b,e.c,e.d,e.e,e.f)},divideScalar:function(t){var e=this;return e.a/=t,e.b/=t,e.c/=t,e.d/=t,e.e/=t,e.f/=t,e._x()},inverse:function(){if(this.isIdentity())return new Matrix;if(this.isInvertible()){var t=this,e=t.a,a=t.b,r=t.c,i=t.d,s=t.e,n=t.f,o=new Matrix,h=e*i-a*r;return o.a=i/h,o.b=-a/h,o.c=-r/h,o.d=e/h,o.e=(r*n-i*s)/h,o.f=-(e*n-a*s)/h,o}throw"Matrix is not invertible."},interpolate:function(t,e,a){var r=this,i=a?new Matrix(a):new Matrix;return i.a=r.a+(t.a-r.a)*e,i.b=r.b+(t.b-r.b)*e,i.c=r.c+(t.c-r.c)*e,i.d=r.d+(t.d-r.d)*e,i.e=r.e+(t.e-r.e)*e,i.f=r.f+(t.f-r.f)*e,i._x()},interpolateAnim:function(t,e,a){var r=this,i=a?new Matrix(a):new Matrix,s=r.decompose(),n=t.decompose(),o=s.rotation+(n.rotation-s.rotation)*e,h=s.translate.x+(n.translate.x-s.translate.x)*e,l=s.translate.y+(n.translate.y-s.translate.y)*e,p=s.scale.x+(n.scale.x-s.scale.x)*e,m=s.scale.y+(n.scale.y-s.scale.y)*e;return i.translate(h,l),i.rotate(o),i.scale(p,m),i._x()},decompose:function(t){var e=this.props[0],a=this.props[1],r=this.props[2],i=this.props[3],s=Math.acos,n=Math.atan,o=Math.sqrt,h=Math.PI,l={x:this.props[4],y:this.props[5]},p=0,m={x:1,y:1},d={x:0,y:0},c=e*i-a*r;if(t)e?(d={x:n(r/e),y:n(a/e)},m={x:e,y:c/e}):a?(p=.5*h,m={x:a,y:c/a},d.x=n(i/a)):(m={x:r,y:i},d.x=.25*h);else if(e||a){var f=o(e*e+a*a);p=a>0?s(e/f):-s(e/f),m={x:f,y:c/f},d.x=n((e*r+a*i)/(f*f))}else if(r||i){var u=o(r*r+i*i);p=.5*h-(i>0?s(-r/u):-s(r/u)),m={x:c/u,y:u},d.y=n((e*r+a*i)/(u*u))}else m={x:0,y:0};return{scale:m,translate:l,rotation:p,skew:d}},determinant:function(){return this.a*this.d-this.b*this.c},applyToPoint:function(t,e){return{x:t*this.props[0]+e*this.props[2]+this.props[4],y:t*this.props[1]+e*this.props[3]+this.props[5]}},applyToPointStringified:function(t,e){return t*this.props[0]+e*this.props[2]+this.props[4]+","+(t*this.props[1]+e*this.props[3]+this.props[5])},applyToArray:function(t){var e,a,r=0,i=[];if("number"==typeof t[0])for(a=t.length;a>r;)e=this.applyToPoint(t[r++],t[r++]),i.push(e.x,e.y);else for(a=t.length,r=0;a>r;r++)i.push(this.applyToPoint(t[r].x,t[r].y));return i},applyToTypedArray:function(t,e){for(var a,r=0,i=t.length,s=e?new Float64Array(i):new Float32Array(i);i>r;)a=this.applyToPoint(t[r],t[r+1]),s[r++]=a.x,s[r++]=a.y;return s},applyToContext:function(t){var e=this;return t.setTransform(e.a,e.b,e.c,e.d,e.e,e.f),e},isIdentity:function(){var t=this;return t._q(t.a,1)&&t._q(t.b,0)&&t._q(t.c,0)&&t._q(t.d,1)&&t._q(t.e,0)&&t._q(t.f,0)},isInvertible:function(){return!this._q(this.determinant(),0)},isValid:function(){return!this._q(this.a*this.d,0)},clone:function(t){var e=this,a=new Matrix;return a.a=e.a,a.b=e.b,a.c=e.c,a.d=e.d,a.e=e.e,a.f=e.f,t||(a.context=e.context),a},isEqual:function(t){var e=this,a=e._q;return a(e.a,t.a)&&a(e.b,t.b)&&a(e.c,t.c)&&a(e.d,t.d)&&a(e.e,t.e)&&a(e.f,t.f)},toArray:function(){return[this.props[0],this.props[1],this.props[2],this.props[3],this.props[4],this.props[5]]},toCSS:function(){return this.cssParts[1]=this.props.join(","),this.cssParts.join("")},toJSON:function(){var t=this;return'{"a":'+t.a+',"b":'+t.b+',"c":'+t.c+',"d":'+t.d+',"e":'+t.e+',"f":'+t.f+"}"},toString:function(){return""+this.toArray()},_q:function(t,e){return Math.abs(t-e)<1e-14},_x:function(){return this.context&&this.context.setTransform(this.a,this.b,this.c,this.d,this.e,this.f),this}},void 0===CanvasRenderingContext2D.prototype.ellipse&&(CanvasRenderingContext2D.prototype.ellipse=function(t,e,a,r,i,s,n,o){this.save(),this.translate(t,e),this.rotate(i),this.scale(a,r),this.arc(0,0,1,s,n,o),this.restore()});var BM_Path2D;!function(){function t(t){if(this.ops_=[],void 0!==t)if("string"==typeof t)try{this.ops_=parser.parse(t)}catch(e){}else{if(!t.hasOwnProperty("ops_"))throw"Error: "+typeof t+"is not a valid argument to Path";this.ops_=t.ops_.slice(0)}}function e(t){return function(){var e,a=arguments.length,r=[];for(e=0;a>e;e+=1)r.push(arguments[e]);this.ops_.push({type:t,args:r})}}for(var a=CanvasRenderingContext2D.prototype,r=BM_CanvasRenderingContext2D.prototype,i=["closePath","moveTo","lineTo","quadraticCurveTo","bezierCurveTo","rect","arc","arcTo","ellipse"],s=0;s<i.length;s++){var n=i[s];t.prototype[n]=e(n)}t.prototype.addPath=function(t,e){var a=!1;!e||1==e[0]&&0===e[1]&&0===e[2]&&1==e[3]&&0===e[4]&&0===e[5]||(a=!0,this.ops_.push({type:"save",args:[]}),this.ops_.push({type:"transform",args:[e[0],e[1],e[2],e[3],e[4],e[5]]})),this.ops_=this.ops_.concat(t.ops_),a&&this.ops_.push({type:"restore",args:[]})};var o=a.fill,h=a.stroke,l=a.clip;r.fill=function(e){if(e instanceof t){this.renderer.canvasContext.beginPath();for(var a=0,r=e.ops_.length;r>a;a++){var i=e.ops_[a];"transform"==i.type?this.renderer.ctxTransform(i.args):"save"==i.type?this.renderer.save():"restore"==i.type?this.renderer.restore():this.renderer.canvasContext[i.type].apply(this.renderer.canvasContext,i.args)}r=arguments.length;var s=[];for(a=1;r>a;a+=1)s.push(arguments[a]);o.apply(this.renderer.canvasContext,s)}else o.apply(this.renderer.canvasContext,arguments)},r.stroke=function(e){if(e instanceof t){this.renderer.canvasContext.beginPath();for(var a=0,r=e.ops_.length;r>a;a++){var i=e.ops_[a];this.renderer.canvasContext[i.type].apply(this.renderer.canvasContext,i.args)}h.call(this.renderer.canvasContext)}else h.call(this.renderer.canvasContext)},r.clip=function(e){if(e instanceof t){this.renderer.canvasContext.beginPath();
+(function(window){function Matrix(t){var e=this;e._t=e.transform,e.a=e.d=1,e.b=e.c=e.e=e.f=0,e.props=[1,0,0,1,0,0],e.cssParts=["matrix(","",")"],e.a1=e.b1=e.c1=e.d1=e.e1=e.f1=0,e.context=t,e.cos=e.sin=0,t&&t.setTransform(1,0,0,1,0,0)}function BM_CanvasRenderingContext2D(t){this.renderer=t}function matrixManagerFunction(){var t=new Matrix,e=function(t,e,a,s,r,i,n,o,h){var l,p,m,d,c,u,f;return l=$M([[1,0,0,0],[0,Math.cos(t),Math.sin(-t),0],[0,Math.sin(t),Math.cos(t),0],[0,0,0,1]]),p=$M([[Math.cos(e),0,Math.sin(e),0],[0,1,0,0],[Math.sin(-e),0,Math.cos(e),0],[0,0,0,1]]),m=$M([[Math.cos(a),Math.sin(-a),0,0],[Math.sin(a),Math.cos(a),0,0],[0,0,1,0],[0,0,0,1]]),c=$M([[s,0,0,0],[0,r,0,0],[0,0,i,0],[0,0,0,1]]),u=l.x(p).x(m).x(c),u=u.transpose(),f=$M([[1,0,0,0],[0,1,0,0],[0,0,1,0],[n,o,h,1]]),u=u.x(f),d="matrix3d(",d+=u.e(1,1).toFixed(5)+","+u.e(1,2).toFixed(5)+","+u.e(1,3).toFixed(5)+","+u.e(1,4).toFixed(5)+",",d+=u.e(2,1).toFixed(5)+","+u.e(2,2).toFixed(5)+","+u.e(2,3).toFixed(5)+","+u.e(2,4).toFixed(5)+",",d+=u.e(3,1).toFixed(5)+","+u.e(3,2).toFixed(5)+","+u.e(3,3).toFixed(5)+","+u.e(3,4).toFixed(5)+",",d+=u.e(4,1).toFixed(5)+","+u.e(4,2).toFixed(5)+","+u.e(4,3).toFixed(5)+","+u.e(4,4).toFixed(5),d+=")"},a=function(e,a,s,r,i){return t.reset().translate(r,i).rotate(e).scale(a,s).toCSS()},s=function(e,a,s,r,i){return t.reset().translate(r,i).rotate(e).scale(a,s).toArray()},r=function(t){return a(t.r,t.s[0],t.s[1],t.p[0],t.p[1])},i=function(t,s){return s?e(-t.tr.r[0],t.tr.r[1],t.tr.r[2],t.tr.s[0],t.tr.s[1],t.tr.s[2],t.tr.p[0],t.tr.p[1],t.tr.p[2]):a(t.tr.r[2],t.tr.s[0],t.tr.s[1],t.tr.p[0],t.tr.p[1])},n=function(t,s){return s?e(-t.r[0],t.r[1],t.r[2],t.s[0],t.s[1],t.s[2],t.p[0],t.p[1],t.p[2]):a(t.r[2],t.s[0],t.s[1],t.p[0],t.p[1])},o=function(t,e){return e?null:s(t.r[2],t.s[0],t.s[1],t.p[0],t.p[1])};return{get2DMatrix:r,getMatrix:i,getMatrix2:n,getMatrixArray:o,getMatrixArrayFromParams:s,getMatrix2FromParams:a}}function styleDiv(t){t.style.position="absolute",t.style.top=0,t.style.left=0,t.style.display="block",t.style.verticalAlign="top",t.style.backfaceVisibility=t.style.webkitBackfaceVisibility="hidden",styleUnselectableDiv(t)}function styleUnselectableDiv(t){t.style.userSelect="none",t.style.MozUserSelect="none",t.style.webkitUserSelect="none",t.style.oUserSelect="none"}function randomString(t,e){void 0===e&&(e="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890");var a,s="";for(a=t;a>0;--a)s+=e[Math.round(Math.random()*(e.length-1))];return s}function componentToHex(t){var e=t.toString(16);return 1==e.length?"0"+e:e}function fillToRgba(t,e){if(!cachedColors[t]){var a=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);cachedColors[t]=parseInt(a[1],16)+","+parseInt(a[2],16)+","+parseInt(a[3],16)}return"rgba("+cachedColors[t]+","+e+")"}function createElement(t,e,a){if(!e){var s=Object.create(t.prototype,a),r={};return s&&"[object Function]"===r.toString.call(s.init)&&s.init(),s}e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.prototype.parent=t.prototype}function defineDescriptor(t,e,a,s){var r={writable:!1,configurable:!1,enumerable:!1,value:a};if(s)for(var i in s)r[i]=s[i];var n={};t&&"[object Function]"===n.toString.call(t)&&(t=t.prototype),Object.defineProperty(t,e,r)}function defineAccessor(t,e,a){var s,r={enumerable:!1,configurable:!1,get:function(){return s},set:function(t){s=t}};if(a)for(var i in a)r[i]=a[i];var n={};t&&"[object Function]"===n.toString.call(t)&&(t=t.prototype),Object.defineProperty(t,e,r)}function bezFunction(){function t(t,e,a,s,r,i){return l.abs((a-t)*(i-e)-(r-t)*(s-e))<1e-5}function e(t){return h[t].fnc}function a(t,e,a,s,r){if(r||(r=("bez_"+t+"_"+e+"_"+a+"_"+s).replace(/\./g,"p")),h[r])return h[r];var i,n,o,l,p,m;return h[r]=function(r,h,d,c,u){var f=h/u;r=f;for(var y,g=0;++g<14&&(o=3*t,n=3*(a-t)-o,i=1-o-n,y=r*(o+r*(n+r*i))-f,!(Math.abs(y)<.001));)r-=y/(o+r*(2*n+3*i*r));m=3*e,p=3*(s-e)-m,l=1-m-p;var v=r*(m+r*(p+r*l));return c*v+d},h[r]}function s(t){this.segmentLength=0,this.points=new Array(t)}function r(e){var a,r,i,n,o,h,l,p=e.s,m=e.e,d=e.to,c=e.ti,u=500,f=0,y=null;(p[0]!=m[0]||p[1]!=m[1])&&t(p[0],p[1],m[0],m[1],p[0]+d[0],p[1]+d[1])&&t(p[0],p[1],m[0],m[1],m[0]+c[0],m[1]+c[1])&&(u=2);var g=new s(u);for(i=d.length,a=0;u>a;a+=1){for(l=[],o=a/(u-1),h=0,r=0;i>r;r+=1)n=Math.pow(1-o,3)*p[r]+3*Math.pow(1-o,2)*o*(p[r]+d[r])+3*(1-o)*Math.pow(o,2)*(m[r]+c[r])+Math.pow(o,3)*m[r],l.push(n),null!==y&&(h+=Math.pow(l[r]-y[r],2));h=Math.sqrt(h),f+=h,g.points[a]={partialLength:h,cumulatedLength:f,point:l},y=l}g.segmentLength=f,e.bezierData=g}function i(t,e){var a=e.segments,s=a.length,r=Math.floor((s-1)*t),i=t*e.addedLength,n=0;if(i==a[r].l)return a[r].p;for(var o=a[r].l>i?-1:1,h=!0;h;)a[r].l<=i&&a[r+1].l>i?(n=(i-a[r].l)/(a[r+1].l-a[r].l),h=!1):r+=o,(0>r||r>=s-1)&&(h=!1);return a[r].p+(a[r+1].p-a[r].p)*n}function n(){this.pt1=new Array(2),this.pt2=new Array(2),this.pt3=new Array(2),this.pt4=new Array(2)}function o(t,e,a,s,r,o,h){var l=new n;r=0>r?0:r;var p=i(r,h);o=o>1?1:o;var m,d=i(o,h),c=t.length,u=1-p,f=1-d;for(m=0;c>m;m+=1)l.pt1[m]=u*u*u*t[m]+(p*u*u+u*p*u+u*u*p)*a[m]+(p*p*u+u*p*p+p*u*p)*s[m]+p*p*p*e[m],l.pt3[m]=u*u*f*t[m]+(p*u*f+u*p*f+u*u*d)*a[m]+(p*p*f+u*p*d+p*u*d)*s[m]+p*p*d*e[m],l.pt4[m]=u*f*f*t[m]+(p*f*f+u*d*f+u*f*d)*a[m]+(p*d*f+u*d*d+p*f*d)*s[m]+p*d*d*e[m],l.pt2[m]=f*f*f*t[m]+(d*f*f+f*d*f+f*f*d)*a[m]+(d*d*f+f*d*d+d*f*d)*s[m]+d*d*d*e[m];return l}var h=[],l=Math,p=function(){var e={};return function(a,s,r,i){var n=(a.join("_")+"_"+s.join("_")+"_"+r.join("_")+"_"+i.join("_")).replace(/\./g,"p");if(e[n])return e[n];var o,h,l,p,m,d,c=100,u=0,f=[],y=[],g={addedLength:0,segments:[]};for((a[0]!=s[0]||a[1]!=s[1])&&t(a[0],a[1],s[0],s[1],r[0],r[1])&&t(a[0],a[1],s[0],s[1],i[0],i[1])&&(c=2),l=r.length,o=0;c>o;o+=1){for(m=o/(c-1),d=0,h=0;l>h;h+=1)p=Math.pow(1-m,3)*a[h]+3*Math.pow(1-m,2)*m*r[h]+3*(1-m)*Math.pow(m,2)*i[h]+Math.pow(m,3)*s[h],f[h]=p,null!==y[h]&&(d+=Math.pow(f[h]-y[h],2)),y[h]=f[h];d&&(d=Math.sqrt(d),u+=d),g.segments.push({l:u,p:m})}return g.addedLength=u,e[n]=g,g}}();return{getEasingCurve:a,getEasingCurveByIndex:e,getBezierLength:p,getNewSegment:o,buildBezierData:r}}function dataFunctionManager(){function t(t,e,a){var s,r=o(t,e,a),i=[];for(s=0;e>s;s+=1)i.push(Math.floor(r[s]*v));return i}function e(t,e){var a,s,r,i=t.length;for(a=0;i>a;a+=1)if(void 0!==t[a].t)if(t[a].s instanceof Array)for(r=t[a].s.length,s=0;r>s;s+=1)t[a].s[s]*=e,void 0!==t[a].e&&(t[a].e[s]*=e);else t[a].s&&(t[a].s*=e,t[a].e&&(t[a].e*=e));else t[a]=t[a]*e}function a(n,o){o||(o=n);var h,l,p,m,d,c,u,f,y,g,v=n.length;for(c=0;v>c;c+=1){if(p=n[c],h=p.outPoint-p.startTime,l=p.startTime,p.tt&&(n[c-1].td=p.tt),p.renderedFrame={},p.renderedData={},m=[],d=-1,p.tm&&(p.trmp=p.tm,p.tm=t(p.tm,h,l)),p.ks.o instanceof Array?e(p.ks.o,.01):p.ks.o/=100,p.ks.s instanceof Array?e(p.ks.s,.01):p.ks.s/=100,p.ks.r instanceof Array?e(p.ks.r,C):p.ks.r*=C,p.hasMask){var b=p.masksProperties;for(f=b.length,u=0;f>u;u+=1)if(b[u].pt.i)i(b[u].pt);else for(g=b[u].pt.length,y=0;g>y;y+=1)b[u].pt[y].s&&i(b[u].pt[y].s[0]),b[u].pt[y].e&&i(b[u].pt[y].e[0])}"PreCompLayer"==p.ty?p.refId&&!p.layers?p.layers=s(p.refId,o):a(p.layers,o):"ShapeLayer"==p.ty&&r(p.shapes)}}function s(t,e,a){a||(a=e);var r,i=e.length;for(r=0;i>r;r+=1){if(e[r].compId==t)return e[r].layers||(e[r].layers=s(e[r].refId,a)),e[r].layers;if("PreCompLayer"==e[r].ty){var n=s(t,e[r].layers,a);if(n)return n}}return null}function r(t,a){var s,n,o,h,l=t.length,p=a?a:!1;for(s=l-1;s>=0;s-=1)if(t[s].renderedData=[],"tm"==t[s].ty&&(p=!0),"fl"==t[s].ty||"st"==t[s].ty)t[s].o instanceof Array?e(t[s].o,.01):t[s].o*=.01;else if("sh"==t[s].ty)if(t[s].trimmed=p,t[s].ks.i)i(t[s].ks);else for(o=t[s].ks.length,n=0;o>n;n+=1)t[s].ks[n].s&&(i(t[s].ks[n].s[0]),i(t[s].ks[n].e[0]));else"gr"==t[s].ty?r(t[s].it,p):"tr"==t[s].ty?(h=t[s],h.renderedData=[],h.o instanceof Array?e(h.o,.01):h.o/=100,h.s instanceof Array?e(h.s,.01):h.s/=100,h.r instanceof Array?e(h.r,C):h.r*=C):"rc"==t[s].ty&&(t[s].trimmed=p,t[s].trimmed=!0)}function i(t){var e,a=t.i.length;for(e=0;a>e;e+=1)t.i[e][0]+=t.v[e][0],t.i[e][1]+=t.v[e][1],t.o[e][0]+=t.v[e][0],t.o[e][1]+=t.v[e][1]}function n(t){x[t._id]={data:t,renderedFrames:[]},v=t.animation.frameRate,a(t.animation.layers)}function o(t,e,a){var s,r,i=[];if(!(t instanceof Array)||null===t[0].t)return i.push(t),i;var n,o;i=[];var h,l,p,m=[];r=t.length;var d,c,u;for(s=0;r>s;s+=1)n=t[s],n.t-=a;var f=0,y=0;for(s=0;e>s;s+=1){h=f;for(var g=!1;r-1>h;){if(n=t[h],o=t[h+1],s<n.t&&0===h){for(p=n.s.length,m=[],l=0;p>l;l+=1)m.push(n.s[l]);i.push(m),g=!0,f!=h&&(f=h,y=0);break}if(s>=n.t&&s<o.t){if(m=[],n.to){d=bez.getEasingCurve(n.o.x,n.o.y,n.i.x,n.i.y)("",s-n.t,0,1,o.t-n.t),c=n.bezierData;var v,b,x=c.segmentLength*d;for(l=y;l<c.points.length;){if(0===s||0===x||0===d){m=c.points[l].point,y=l;break}if(l==c.points.length-1)m=c.points[l].point;else if(x>c.points[l].partialLength&&x<c.points[l+1].partialLength){for(v=c.points[l].point.length,b=(x-c.points[l].partialLength)/(c.points[l+1].partialLength-c.points[l].partialLength),u=0;v>u;u+=1)m.push(c.points[l].point[u]+(c.points[l+1].point[u]-c.points[l].point[u])*b);y=l;break}l+=1}}else{var C,E,D,S;n.s.forEach(function(t,e){if(1!==n.h&&(n.o.x instanceof Array?(C=n.o.x[e],E=n.o.y[e],D=n.i.x[e],S=n.i.y[e]):(C=n.o.x,E=n.o.y,D=n.i.x,S=n.i.y),d=bez.getEasingCurve(C,E,D,S)("",s-n.t,0,1,o.t-n.t)),t.i){var a={i:[],o:[],v:[]};t.i.forEach(function(s,r){var i=[],o=[],h=[];s.forEach(function(a,s){1===n.h?(i.push(a),o.push(t.o[r][s]),h.push(t.v[r][s])):(i.push(a+(n.e[e].i[r][s]-a)*d),o.push(t.o[r][s]+(n.e[e].o[r][s]-t.o[r][s])*d),h.push(t.v[r][s]+(n.e[e].v[r][s]-t.v[r][s])*d))}),a.i.push(i),a.o.push(o),a.v.push(h)}),m.push(a)}else m.push(1===n.h?t:t+(n.e[e]-t)*d)})}i.push(m),g=!0,f!=h&&(f=h,y=0);break}h+=1}g===!1&&(n=t[t.length-2],m=[],n.e.forEach(function(t){m.push(t)}),i.push(m))}for(h=i.length;e>h;)i.push(m),h+=1;return i}function h(t,e,a,s){var r,i,n,o,h,l;if(!t.length)return"p"==s.type?(S.px=t,S.py=t):"s"==s.type?(S.sx=t,S.sy=t):("r"==s.type||"px"==s.type||"py"==s.type)&&(S[s.type]=t),s.toArray?[t]:t;if(void 0===t[0].t)return"p"==s.type?(S.px=t[0],S.py=t[1]):"s"==s.type?(S.sx=t[0],S.sy=t[1]):("r"==s.type||"px"==s.type||"py"==s.type)&&(S[s.type]=t[0]),t;h=0,l=t.length-1;for(var p=1,m=!0;!(!m||(r=t[h],i=t[h+1],h==l-1&&e>=i.t-a)||i.t-a>e&&1==p);){if(i.t-a<e&&-1==p){h+=1,r=t[h],i=t[h+1];break}l-1>h&&1==p||h>0&&-1==p?h+=p:m=!1}r.to&&!r.bezierData&&bez.buildBezierData(r);var d,c,u,f,y,g=0;if("default"==s.type&&(n=[]),r.to){if(o=r.bezierData,e>=i.t-a)return"p"==s.type?(S.px=o.points[o.points.length-1].point[0],S.py=o.points[o.points.length-1].point[1]):"s"==s.type?(S.sx=o.points[o.points.length-1].point[0],S.sy=o.points[o.points.length-1].point[1]):("r"==s.type||"px"==s.type||"py"==s.type)&&(S[s.type]=o.points[o.points.length-1].point[0]),o.points[o.points.length-1].point;if(e<r.t-a)return"p"==s.type?(S.px=o.points[0].point[0],S.py=o.points[0].point[1]):"s"==s.type?(S.sx=o.points[0].point[0],S.sy=o.points[0].point[1]):("r"==s.type||"px"==s.type||"py"==s.type)&&(S[s.type]=o.points[0].point[0]),o.points[0].point;r.__fnct?y=r.__fnct:(y=bez.getEasingCurve(r.o.x,r.o.y,r.i.x,r.i.y,r.n),r.__fnct=y),u=y("",e-(r.t-a),0,1,i.t-a-(r.t-a));var v,b=o.segmentLength*u,x=0;for(p=1,m=!0,f=o.points.length;m;){if(x+=o.points[g].partialLength*p,0===b||0===u){"p"==s.type?(S.px=o.points[g].point[0],S.py=o.points[g].point[1]):"s"==s.type?(S.sx=o.points[g].point[0],S.sy=o.points[g].point[1]):"r"==s.type||"px"==s.type||"py"==s.type?S[s.type]=o.points[g].point[0]:n=o.points[g].point;break}if(g==o.points.length-1){"p"==s.type?(S.px=o.points[g].point[0],S.py=o.points[g].point[1]):"s"==s.type?(S.sx=o.points[g].point[0],S.sy=o.points[g].point[1]):"r"==s.type||"px"==s.type||"py"==s.type?S[s.type]=o.points[g].point[0]:n=o.points[g].point;break}if(b>x&&b<x+o.points[g+1].partialLength){if(v=(b-x)/o.points[g+1].partialLength,"p"==s.type)S.px=o.points[g].point[0]+(o.points[g+1].point[0]-o.points[g].point[0])*v,S.py=o.points[g].point[1]+(o.points[g+1].point[1]-o.points[g].point[1])*v;else if("s"==s.type)S.sx=o.points[g].point[0]+(o.points[g+1].point[0]-o.points[g].point[0])*v,S.sy=o.points[g].point[1]+(o.points[g+1].point[1]-o.points[g].point[1])*v;else if("r"==s.type||"px"==s.type||"py"==s.type)S[s.type]=o.points[g].point[0]+(o.points[g+1].point[0]-o.points[g].point[0])*v;else for(c=o.points[g].point.length,d=0;c>d;d+=1)n.push(o.points[g].point[d]+(o.points[g+1].point[d]-o.points[g].point[d])*v);break}f-1>g&&1==p||g>0&&-1==p?g+=p:m=!1}}else{var C,E,D,w,M=!1;for(l=r.s.length,h=0;l>h;h+=1)1!==r.h&&(r.o.x instanceof Array?(M=!0,C=r.o.x[h]?r.o.x[h]:r.o.x[0],E=r.o.y[h]?r.o.y[h]:r.o.y[0],D=r.i.x[h]?r.i.x[h]:r.i.x[0],w=r.i.y[h]?r.i.y[h]:r.i.y[0],r.__fnct||(r.__fnct=[])):(M=!1,C=r.o.x,E=r.o.y,D=r.i.x,w=r.i.y),M?r.__fnct[h]?y=r.__fnct[h]:(y=bez.getEasingCurve(C,E,D,w),r.__fnct[h]=y):r.__fnct?y=r.__fnct:(y=bez.getEasingCurve(C,E,D,w),r.__fnct=y),u=e>=i.t-a?1:e<r.t-a?0:y("",e-(r.t-a),0,1,i.t-a-(r.t-a))),1===r.h?"p"==s.type?0===h?S.px=r.s[h]:1==h&&(S.py=r.s[h]):"s"==s.type?0===h?S.sx=r.s[h]:1==h&&(S.sy=r.s[h]):"px"==s.type||"py"==s.type||"r"==s.type?S[s.type]=r.s[h]:n.push(r.s[h]):"p"==s.type?0===h?S.px=r.s[h]+(r.e[h]-r.s[h])*u:1==h&&(S.py=r.s[h]+(r.e[h]-r.s[h])*u):"s"==s.type?0===h?S.sx=r.s[h]+(r.e[h]-r.s[h])*u:1==h&&(S.sy=r.s[h]+(r.e[h]-r.s[h])*u):"px"==s.type||"py"==s.type||"r"==s.type?S[s.type]=r.s[h]+(r.e[h]-r.s[h])*u:n.push(r.s[h]+(r.e[h]-r.s[h])*u)}return n}function l(t,e){if(!t.__lengths){t.__lengths=[],t.__totalLength=0;var a,s=t.v,r=t.o,i=t.i,n=s.length;for(a=0;n-1>a;a+=1)t.__lengths.push(bez.getBezierLength(s[a],s[a+1],r[a],i[a+1])),t.__totalLength+=t.__lengths[a].addedLength;e&&(t.__lengths.push(bez.getBezierLength(s[a],s[0],r[a],i[0])),t.__totalLength+=t.__lengths[a].addedLength)}}function p(t,e,a,s,r,i){var n=i&&i.length>0,o={};o.closed=r?t.cl:t.closed;var h=r?t.pt:t.ks;if(h.v)return o.pathNodes=n?D(h,o.closed,i,!1):h,o;t={i:[],o:[],v:[]};var l,p,m,d,c,u,f,y=[];if(e<h[0].t-a){if(!h.__minValue){for(p=h[0].s[0].i.length,l=0;p>l;l+=1){for(c=[],u=[],f=[],d=h[0].s[0].i[l].length,m=0;d>m;m+=1)c.push(h[0].s[0].i[l][m]),u.push(h[0].s[0].o[l][m]),f.push(h[0].s[0].v[l][m]);t.i.push(c),t.o.push(u),t.v.push(f)}y.push(t),h.__minValue=y[0]}return o.pathNodes=n?D(h.__minValue,o.closed,i,!1):h.__minValue,o}if(e>h[h.length-1].t-a){if(!h.__maxValue){var g=h.length-2;for(p=h[g].s[0].i.length,l=0;p>l;l+=1){for(c=[],u=[],f=[],d=h[g].s[0].i[l].length,m=0;d>m;m+=1)c.push(h[g].e[0].i[l][m]),u.push(h[g].e[0].o[l][m]),f.push(h[g].e[0].v[l][m]);t.i.push(c),t.o.push(u),t.v.push(f)}y.push(t),h.__maxValue=y[0]}return o.pathNodes=n?D(h.__maxValue,o.closed,i,!1):h.__maxValue,o}for(var v,b,x=0,C=h.length-1,E=1,S=!0;S&&(v=h[x],b=h[x+1],!(b.t-a>e&&1==E));)C-1>x&&1==E||x>0&&-1==E?x+=E:S=!1;var w,M,A,I,F;if(1!==v.h){w=v.o.x,M=v.o.y,A=v.i.x,I=v.i.y;var P;v.__fnct?P=v.__fnct:(P=bez.getEasingCurve(w,M,A,I),v.__fnct=P),F=P("",e-(v.t-a),0,1,b.t-a-(v.t-a)),e>=b.t-a?F=1:e<v.t-a&&(F=0)}if(1===v.h&&v.__hValue)y.push(v.__hValue);else for(t={i:[],o:[],v:[]},p=v.s[0].i.length,l=0;p>l;l+=1){for(c=[],u=[],f=[],d=v.s[0].i[l].length,m=0;d>m;m+=1)1===v.h?(c.push(v.s[0].i[l][m]),u.push(v.s[0].o[l][m]),f.push(v.s[0].v[l][m])):(c.push(v.s[0].i[l][m]+(v.e[0].i[l][m]-v.s[0].i[l][m])*F),u.push(v.s[0].o[l][m]+(v.e[0].o[l][m]-v.s[0].o[l][m])*F),f.push(v.s[0].v[l][m]+(v.e[0].v[l][m]-v.s[0].v[l][m])*F));t.i.push(c),t.o.push(u),t.v.push(f),1===v.h&&(v.__hValue=t),y.push(t)}return o.pathNodes=n?D(y[0],o.closed,i,!1):y[0],o}function m(t,e,a){var s,r,i,n,o,l,d,u,f,y=t.length;for(u=0;y>u;u+=1){if(f=t[u],n=e-f.startTime,s={},E.arrayFlag=!1,E.type="default",s.a=h(f.ks.a,n,f.startTime,E),s.o=h(f.ks.o,n,f.startTime,E),E.arrayFlag=!1,f.ks.p.s?(E.type="px",h(f.ks.p.x,n,f.startTime,E),E.type="py",h(f.ks.p.y,n,f.startTime,E)):(E.type="p",h(f.ks.p,n,f.startTime,E)),E.arrayFlag=!0,E.type="r",h(f.ks.r,n,f.startTime,E),E.arrayFlag=!0,E.type="s",h(f.ks.s,n,f.startTime,E),d={},d.an={tr:s},E.arrayFlag=!1,E.type="default",d.an.matrixArray="canvas"==a?b.getMatrixArrayFromParams(S.r,S.sx,S.sy,S.px,S.py):b.getMatrixArrayFromParams(S.r,S.sx,S.sy,S.px,S.py),f.renderedData[n]=d,f.hasMask)for(r=f.masksProperties,l=r.length,o=0;l>o;o+=1)r[o].paths||(r[o].paths=[],r[o].opacity=[]),r[o].paths[n]=p(r[o],n,f.startTime,a,!0),r[o].opacity[n]=h(r[o].o,n,f.startTime,E),r[o].opacity[n]=r[o].opacity[n]instanceof Array?r[o].opacity[n][0]/100:r[o].opacity[n]/100;e<f.inPoint||e>f.outPoint||("PreCompLayer"==f.ty?(i=f.tm?f.tm[n]<0?0:n>=f.tm.length?f.tm[f.tm.length-1]:f.tm[n]:n,void 0===i&&(i=h(f.trmp,n,0,E)[0]*v,f.tm[n]=i),m(f.layers,i,a)):"ShapeLayer"==f.ty&&c(f.shapes,n,f.startTime,a))}}function d(t,e,a){a=Math.min(e[0],e[1],a/2);var s=new Array(8),r=new Array(8),i=new Array(8),n=a/2;return a*=1,s[0]=[t[0]+e[0]/2,t[1]-e[1]/2+a],i[0]=s[0],r[0]=[t[0]+e[0]/2,t[1]-e[1]/2+n],s[1]=[t[0]+e[0]/2,t[1]+e[1]/2-a],i[1]=[t[0]+e[0]/2,t[1]+e[1]/2-n],r[1]=s[1],s[2]=[t[0]+e[0]/2-a,t[1]+e[1]/2],i[2]=s[2],r[2]=[t[0]+e[0]/2-n,t[1]+e[1]/2],s[3]=[t[0]-e[0]/2+a,t[1]+e[1]/2],i[3]=[t[0]-e[0]/2+n,t[1]+e[1]/2],r[3]=s[3],s[4]=[t[0]-e[0]/2,t[1]+e[1]/2-a],i[4]=s[4],r[4]=[t[0]-e[0]/2,t[1]+e[1]/2-n],s[5]=[t[0]-e[0]/2,t[1]-e[1]/2+a],i[5]=[t[0]-e[0]/2,t[1]-e[1]/2+n],r[5]=s[5],s[6]=[t[0]-e[0]/2+a,t[1]-e[1]/2],i[6]=s[6],r[6]=[t[0]-e[0]/2+n,t[1]-e[1]/2],s[7]=[t[0]+e[0]/2-a,t[1]-e[1]/2],i[7]=[t[0]+e[0]/2-n,t[1]-e[1]/2],r[7]=s[7],{v:s,o:i,i:r,c:!0}}function c(t,e,a,s,r){var i,n,o,l,m,f,y,g,v,x,C=t.length;r||(r=[]);var w,M,A,I,F;for(i=C-1;i>=0;i-=1)if(n=t[i],"sh"==n.ty)n.renderedData[e]={path:p(n,e,a,s,!1,r)};else if("fl"==n.ty)o=h(n.c,e,a,E),l=h(n.o,e,a,E),n.renderedData[e]={opacity:l instanceof Array?l[0]:l},"canvas"==s?(u(o),n.renderedData[e].color=o):n.renderedData[e].color=rgbToHex(Math.round(o[0]),Math.round(o[1]),Math.round(o[2]));else if("rc"==n.ty)m=h(n.p,e,a,E),f=h(n.s,e,a,E),y=h(n.r,e,a,E),n.trimmed?(n.renderedData[e]={path:{closed:!0}},n.renderedData[e].path.pathNodes=D(d(m,f,y),!0,r,!1)):n.renderedData[e]={position:m,size:f,roundness:y};else if("el"==n.ty){if(m=h(n.p,e,a,E),f=h(n.s,e,a,E),n.renderedData[e]={p:m,size:f},"svg"==s){var P={v:new Array(4),i:new Array(4),o:new Array(4)};P.v[0]=[m[0],m[1]-f[1]/2],P.o[0]=[m[0]-f[0]/2*.55,m[1]-f[1]/2],P.i[0]=[m[0]+f[0]/2*.55,m[1]-f[1]/2],P.v[1]=[m[0]-f[0]/2,m[1]],P.o[1]=[m[0]-f[0]/2,m[1]+f[1]/2*.55],P.i[1]=[m[0]-f[0]/2,m[1]-f[1]/2*.55],P.v[2]=[m[0],m[1]+f[1]/2],P.o[2]=[m[0]+f[0]/2*.55,m[1]+f[1]/2],P.i[2]=[m[0]-f[0]/2*.55,m[1]+f[1]/2],P.v[3]=[m[0]+f[0]/2,m[1]],P.o[3]=[m[0]+f[0]/2,m[1]-f[1]/2*.55],P.i[3]=[m[0]+f[0]/2,m[1]+f[1]/2*.55],n.renderedData[e].path={pathNodes:P},n.closed=!0}}else if("st"==n.ty){if(g=h(n.c,e,a,E),v=h(n.o,e,a,E),x=h(n.w,e,a,E),n.renderedData[e]={opacity:v instanceof Array?v[0]:v,width:x instanceof Array?x[0]:x},n.d){var T=[];F=n.d.length;var k;for(I=0;F>I;I+=1)k=h(n.d[I].v,e,a,E),T.push({v:k instanceof Array?k[0]:k,n:n.d[I].n});n.renderedData[e].dashes=T}"canvas"==s?(u(g),n.renderedData[e].color=g):n.renderedData[e].color=rgbToHex(Math.round(g[0]),Math.round(g[1]),Math.round(g[2]))}else if("tr"==n.ty)n.renderedData[e]={a:h(n.a,e,a,E),o:h(n.o,e,a,E)},E.arrayFlag=!0,E.type="s",h(n.s,e,a,E),E.arrayFlag=!0,E.type="r",h(n.r,e,a,E),E.arrayFlag=!1,E.type="p",h(n.p,e,a,E),E.arrayFlag=!1,E.type="default",n.renderedData[e].mtArr="canvas"==s?b.getMatrixArrayFromParams(S.r,S.sx,S.sy,S.px,S.py):b.getMatrixArrayFromParams(S.r,S.sx,S.sy,S.px,S.py);else if("tm"==n.ty){w=h(n.s,e,a,E),M=h(n.e,e,a,E),A=h(n.o,e,a,E);var _={s:w,e:M,o:A};r.push(_),n.renderedData[e]=_}else"gr"==n.ty&&c(n.it,e,a,s,r)}function u(t){var e,a=t.length;for(e=0;a>e;e+=1)t[e]=Math.round(t[e])}function f(t,e){for(var a=1;a>0;){if(e+=1,e>=t.data.animation.totalFrames){t.renderFinished=!0;break}t.renderedFrames[e]||(y(t.data._id,e),a-=1)}}function y(t,e){return 2==x[t].renderedFrames[e]?void(x[t].renderFinished||f(x[t],e)):(v=x[t].data.animation.frameRate,x[t].renderedFrames[e]=2,void m(x[t].data.animation.layers,e,x[t].data._animType))}function g(t){var e,a=x[t].data,s=a.animation.totalFrames,r=[];for(e=0;s>e;e+=1)r.push({num:e,data:y(t,e)})}var v=0,b=new MatrixManager,x={},C=Math.PI/180,E={arrayFlag:!1},D=function(){function t(t,i,n,l,m){s[o]=i,e[o+1]=n,a[o+1]=l,h?a[o]=t:(p+=" M"+t.join(","),h=!0,r[o]=t),p+=" C"+i.join(",")+" "+n.join(",")+" "+l.join(","),o+=1}var e,a,s,r,i,n,o,h=!1,p="";return function(m,d,c,u){l(m,d);var f,y=c.length,g=m;a=e=s=r=null;var v,b,x,C,E;for(f=y-1;f>=0;f-=1){var D=[],S=c[f].o%360/360;if(0!==S||0!==c[f].s||100!=c[f].e){p="",h=!1,e=[],s=[],a=[],r=[],i=[],n=0,0>S&&(S+=1);var w=c[f].s/100+S,M=c[f].e/100+S;if(w==M)return u?"":{};if(w>M){var A=w;w=M,M=A}1>=M?D.push({s:g.__totalLength*w,e:g.__totalLength*M}):w>=1?D.push({s:g.__totalLength*(w-1),e:g.__totalLength*(M-1)}):(D.push({s:g.__totalLength*w,e:g.__totalLength}),D.push({s:0,e:g.__totalLength*(M-1)})),v=[],b=[],x=[];var I;v=g.v,b=g.o,x=g.i,I=g.__lengths,E=v.length;var F,P,T=0,k=0,_=D.length;for(o=0,F=0;_>F;F+=1){for(T=0,C=1;E>C;C++)if(k=I[C-1].addedLength,T+k<D[F].s)T+=k;else{if(T>D[F].e)break;D[F].s<=T&&D[F].e>=T+k?t(v[C-1],b[C-1],x[C],v[C],I[C-1]):(P=bez.getNewSegment(v[C-1],v[C],b[C-1],x[C],(D[F].s-T)/k,(D[F].e-T)/k,I[C-1]),t(P.pt1,P.pt3,P.pt4,P.pt2)),T+=k}d!==!1?T<=D[F].e&&(k=I[C-1].addedLength,D[F].s<=T&&D[F].e>=T+k?t(v[C-1],b[C-1],x[0],v[0],I[C-1]):(P=bez.getNewSegment(v[C-1],v[0],b[C-1],x[0],(D[F].s-T)/k,(D[F].e-T)/k,I[C-1]),t(P.pt1,P.pt3,P.pt4,P.pt2))):h=!1}d=!1}}if(a?(v=a,b=s,x=e):(v=g.v,b=g.o,x=g.i,r=[]),E=v.length,u){for(p="",C=1;E>C;C++)r[C-1]?p+="M"+r[C-1].join(","):1==C&&(p+="M"+v[0].join(",")),p+=" C"+b[C-1].join(",")+" "+x[C].join(",")+" "+v[C].join(",");return d!==!1&&(p+=" C"+b[C-1].join(",")+" "+x[0].join(",")+" "+v[0].join(",")),p}return{i:x,o:b,v:v,s:r,c:d}}}(),S={r:0,sx:1,sy:1,px:1,py:1},w={};return w.completeData=n,w.renderFrame=y,w.renderAllFrames=g,w}function SVGRenderer(t){this.animationItem=t,this.layers=null,this.lastFrame=-1,this.globalData={frameNum:-1},this.elements=[],this.destroyed=!1}function CanvasRenderer(t,e){this.animationItem=t,this.renderConfig=e?e:{clearCanvas:!0,context:null,scaleMode:"fit"},this.lastFrame=-1,this.globalData={frameNum:-1},this.contextData={saved:new Array(15),savedOp:new Array(15),cArrPos:0,cTr:new Matrix,cO:1};var a,s=15;for(a=0;s>a;a+=1)this.contextData.saved[a]=new Array(6);this.elements=[]}function MaskElement(t,e,a){this.data=t,this.storedData=[],this.element=e,this.globalData=a,this.paths=[],this.registeredEffects=[],this.masksProperties=[],this.maskElement=null,this.layerSize=null}function ICompElement(t,e,a){this.parent.constructor.call(this,t,e,a),this.layers=t.layers}function IImageElement(t,e,a){this.assetData=a.getAssetData(t.id),this.path=a.getPath(),this.parent.constructor.call(this,t,e,a)}function IShapeElement(t,e,a){this.shapes=[],this.parent.constructor.call(this,t,e,a)}function ShapeItemElement(t,e,a){this.stylesList=[],this.viewData=[],this.shape=e,this.data=t,this.globalData=a,this.searchShapes(this.data,this.viewData),styleUnselectableDiv(this.shape)}function ISolidElement(t,e,a){this.parent.constructor.call(this,t,e,a)}function ITextElement(t,e,a,s){this.parent.constructor.call(this,t,e,a,s)}function CVBaseElement(t,e){this.data=t,this.globalData=e,this.canvasContext=e.canvasContext,this.currentAnimData=null,this.renderFrame=!1,this.ownMatrix=new Matrix,this.finalTransform={mat:new Matrix,opacity:1},this.init()}function CVCompElement(t,e){this.parent.constructor.call(this,t,e),this.layers=t.layers}function CVImageElement(t,e){this.animationItem=e.renderer.animationItem,this.assetData=this.animationItem.getAssetData(t.id),this.path=this.animationItem.getPath(),this.parent.constructor.call(this,t,e),this.animationItem.pendingElements+=1}function CVShapeElement(t,e){this.shapes=[],this.parent.constructor.call(this,t,e)}function CVShapeItemElement(t,e,a){this.data=t,this.globalData=a,this.canvasContext=a.canvasContext,this.frameNum=-1,this.dataLength=this.data.length,this.mainFlag=e,this.stylesList=[],this.ownStylesList=[],this.stylesPool=[],this.currentStylePoolPos=0,this.transform={opacity:1,mat:new Matrix},this.mat=new Matrix;var s,r=this.dataLength-1;this.renderedPaths=new Array(this.globalData.totalFrames);var i;for(s=r;s>=0;s-=1)"gr"==this.data[s].ty?this.data[s].item=new CVShapeItemElement(this.data[s].it,!1,this.globalData):("st"==this.data[s].ty||"fl"==this.data[s].ty)&&(i={type:"fill",styleOpacity:0,opacity:0,value:"rgba(0,0,0,0)",closed:!1},"fl"==this.data[s].ty?i.type="fill":(i.type="stroke",i.width=0),this.stylesPool.push(i))}function CVSolidElement(t,e){this.parent.constructor.call(this,t,e)}function CVTextElement(t,e){this.parent.constructor.call(this,t,e)}function CVMaskElement(){}var svgNS="http://www.w3.org/2000/svg";Matrix.prototype={concat:function(t){return this.clone()._t(t.a,t.b,t.c,t.d,t.e,t.f)},flipX:function(){return this._t(-1,0,0,1,0,0)},flipY:function(){return this._t(1,0,0,-1,0,0)},reflectVector:function(t,e){var a=this.applyToPoint(0,1),s=2*(a.x*t+a.y*e);return t-=s*a.x,e-=s*a.y,{x:t,y:e}},reset:function(){return this.setTransform(1,0,0,1,0,0)},rotate:function(t){return 0===t?this:(this.cos=Math.cos(t),this.sin=Math.sin(t),this._t(this.cos,this.sin,-this.sin,this.cos,0,0))},rotateFromVector:function(t,e){return this.rotate(Math.atan2(e,t))},rotateDeg:function(t){return this.rotate(t*Math.PI/180)},scaleU:function(t){return this._t(t,0,0,t,0,0)},scale:function(t,e){return 1==t&&1==e?this:this._t(t,0,0,e,0,0)},scaleX:function(t){return this._t(t,0,0,1,0,0)},scaleY:function(t){return this._t(1,0,0,t,0,0)},shear:function(t,e){return this._t(1,e,t,1,0,0)},shearX:function(t){return this._t(1,0,t,1,0,0)},shearY:function(t){return this._t(1,t,0,1,0,0)},skew:function(t,e){return this.shear(Math.tan(t),Math.tan(e))},skewX:function(t){return this.shearX(Math.tan(t))},skewY:function(t){return this.shearY(Math.tan(t))},setTransform:function(t,e,a,s,r,i){return this.props[0]=t,this.props[1]=e,this.props[2]=a,this.props[3]=s,this.props[4]=r,this.props[5]=i,this._x()},translate:function(t,e){return this._t(1,0,0,1,t,e)},translateX:function(t){return this._t(1,0,0,1,t,0)},translateY:function(t){return this._t(1,0,0,1,0,t)},transform:function(t,e,a,s,r,i){return this.a1=this.props[0],this.b1=this.props[1],this.c1=this.props[2],this.d1=this.props[3],this.e1=this.props[4],this.f1=this.props[5],this.props[0]=this.a1*t+this.c1*e,this.props[1]=this.b1*t+this.d1*e,this.props[2]=this.a1*a+this.c1*s,this.props[3]=this.b1*a+this.d1*s,this.props[4]=this.a1*r+this.c1*i+this.e1,this.props[5]=this.b1*r+this.d1*i+this.f1,this._x()},divide:function(t){if(!t.isInvertible())throw"Input matrix is not invertible";var e=t.inverse();return this._t(e.a,e.b,e.c,e.d,e.e,e.f)},divideScalar:function(t){var e=this;return e.a/=t,e.b/=t,e.c/=t,e.d/=t,e.e/=t,e.f/=t,e._x()},inverse:function(){if(this.isIdentity())return new Matrix;if(this.isInvertible()){var t=this,e=t.a,a=t.b,s=t.c,r=t.d,i=t.e,n=t.f,o=new Matrix,h=e*r-a*s;return o.a=r/h,o.b=-a/h,o.c=-s/h,o.d=e/h,o.e=(s*n-r*i)/h,o.f=-(e*n-a*i)/h,o}throw"Matrix is not invertible."},interpolate:function(t,e,a){var s=this,r=a?new Matrix(a):new Matrix;return r.a=s.a+(t.a-s.a)*e,r.b=s.b+(t.b-s.b)*e,r.c=s.c+(t.c-s.c)*e,r.d=s.d+(t.d-s.d)*e,r.e=s.e+(t.e-s.e)*e,r.f=s.f+(t.f-s.f)*e,r._x()},interpolateAnim:function(t,e,a){var s=this,r=a?new Matrix(a):new Matrix,i=s.decompose(),n=t.decompose(),o=i.rotation+(n.rotation-i.rotation)*e,h=i.translate.x+(n.translate.x-i.translate.x)*e,l=i.translate.y+(n.translate.y-i.translate.y)*e,p=i.scale.x+(n.scale.x-i.scale.x)*e,m=i.scale.y+(n.scale.y-i.scale.y)*e;return r.translate(h,l),r.rotate(o),r.scale(p,m),r._x()},decompose:function(t){var e=this.props[0],a=this.props[1],s=this.props[2],r=this.props[3],i=Math.acos,n=Math.atan,o=Math.sqrt,h=Math.PI,l={x:this.props[4],y:this.props[5]},p=0,m={x:1,y:1},d={x:0,y:0},c=e*r-a*s;if(t)e?(d={x:n(s/e),y:n(a/e)},m={x:e,y:c/e}):a?(p=.5*h,m={x:a,y:c/a},d.x=n(r/a)):(m={x:s,y:r},d.x=.25*h);else if(e||a){var u=o(e*e+a*a);p=a>0?i(e/u):-i(e/u),m={x:u,y:c/u},d.x=n((e*s+a*r)/(u*u))}else if(s||r){var f=o(s*s+r*r);p=.5*h-(r>0?i(-s/f):-i(s/f)),m={x:c/f,y:f},d.y=n((e*s+a*r)/(f*f))}else m={x:0,y:0};return{scale:m,translate:l,rotation:p,skew:d}},determinant:function(){return this.a*this.d-this.b*this.c},applyToPoint:function(t,e){return{x:t*this.props[0]+e*this.props[2]+this.props[4],y:t*this.props[1]+e*this.props[3]+this.props[5]}},applyToPointStringified:function(t,e){return t*this.props[0]+e*this.props[2]+this.props[4]+","+(t*this.props[1]+e*this.props[3]+this.props[5])},applyToArray:function(t){var e,a,s=0,r=[];if("number"==typeof t[0])for(a=t.length;a>s;)e=this.applyToPoint(t[s++],t[s++]),r.push(e.x,e.y);else for(a=t.length,s=0;a>s;s++)r.push(this.applyToPoint(t[s].x,t[s].y));return r},applyToTypedArray:function(t,e){for(var a,s=0,r=t.length,i=e?new Float64Array(r):new Float32Array(r);r>s;)a=this.applyToPoint(t[s],t[s+1]),i[s++]=a.x,i[s++]=a.y;return i},applyToContext:function(t){var e=this;return t.setTransform(e.a,e.b,e.c,e.d,e.e,e.f),e},isIdentity:function(){var t=this;return t._q(t.a,1)&&t._q(t.b,0)&&t._q(t.c,0)&&t._q(t.d,1)&&t._q(t.e,0)&&t._q(t.f,0)},isInvertible:function(){return!this._q(this.determinant(),0)},isValid:function(){return!this._q(this.a*this.d,0)},clone:function(t){var e=this,a=new Matrix;return a.a=e.a,a.b=e.b,a.c=e.c,a.d=e.d,a.e=e.e,a.f=e.f,t||(a.context=e.context),a},isEqual:function(t){var e=this,a=e._q;return a(e.a,t.a)&&a(e.b,t.b)&&a(e.c,t.c)&&a(e.d,t.d)&&a(e.e,t.e)&&a(e.f,t.f)},toArray:function(){return[this.props[0],this.props[1],this.props[2],this.props[3],this.props[4],this.props[5]]},toCSS:function(){return this.cssParts[1]=this.props.join(","),this.cssParts.join("")},toJSON:function(){var t=this;return'{"a":'+t.a+',"b":'+t.b+',"c":'+t.c+',"d":'+t.d+',"e":'+t.e+',"f":'+t.f+"}"},toString:function(){return""+this.toArray()},_q:function(t,e){return Math.abs(t-e)<1e-14},_x:function(){return this.context&&this.context.setTransform(this.a,this.b,this.c,this.d,this.e,this.f),this}},void 0===CanvasRenderingContext2D.prototype.ellipse&&(CanvasRenderingContext2D.prototype.ellipse=function(t,e,a,s,r,i,n,o){this.save(),this.translate(t,e),this.rotate(r),this.scale(a,s),this.arc(0,0,1,i,n,o),this.restore()});var BM_Path2D;!function(){function t(t){if(this.ops_=[],void 0!==t)if("string"==typeof t)try{this.ops_=parser.parse(t)}catch(e){}else{if(!t.hasOwnProperty("ops_"))throw"Error: "+typeof t+"is not a valid argument to Path";this.ops_=t.ops_.slice(0)}}function e(t){return function(){var e,a=arguments.length,s=[];for(e=0;a>e;e+=1)s.push(arguments[e]);this.ops_.push({type:t,args:s})}}for(var a=CanvasRenderingContext2D.prototype,s=BM_CanvasRenderingContext2D.prototype,r=["closePath","moveTo","lineTo","quadraticCurveTo","bezierCurveTo","rect","arc","arcTo","ellipse"],i=0;i<r.length;i++){var n=r[i];t.prototype[n]=e(n)}t.prototype.addPath=function(t,e){var a=!1;!e||1==e[0]&&0===e[1]&&0===e[2]&&1==e[3]&&0===e[4]&&0===e[5]||(a=!0,this.ops_.push({type:"save",args:[]}),this.ops_.push({type:"transform",args:[e[0],e[1],e[2],e[3],e[4],e[5]]})),this.ops_=this.ops_.concat(t.ops_),a&&this.ops_.push({type:"restore",args:[]})};var o=a.fill,h=a.stroke,l=a.clip;s.fill=function(e){if(e instanceof t){this.renderer.canvasContext.beginPath();for(var a=0,s=e.ops_.length;s>a;a++){var r=e.ops_[a];"transform"==r.type?this.renderer.ctxTransform(r.args):"save"==r.type?this.renderer.save():"restore"==r.type?this.renderer.restore():this.renderer.canvasContext[r.type].apply(this.renderer.canvasContext,r.args)}s=arguments.length;var i=[];for(a=1;s>a;a+=1)i.push(arguments[a]);o.apply(this.renderer.canvasContext,i)}else o.apply(this.renderer.canvasContext,arguments)},s.stroke=function(e){if(e instanceof t){this.renderer.canvasContext.beginPath();for(var a=0,s=e.ops_.length;s>a;a++){var r=e.ops_[a];this.renderer.canvasContext[r.type].apply(this.renderer.canvasContext,r.args)}h.call(this.renderer.canvasContext)}else h.call(this.renderer.canvasContext)},s.clip=function(e){if(e instanceof t){this.renderer.canvasContext.beginPath();for(var a=0,s=e.ops_.length;s>a;a++){var r=e.ops_[a];this.renderer.canvasContext[r.type].apply(this.renderer.canvasContext,r.args);
-for(var a=0,r=e.ops_.length;r>a;a++){var i=e.ops_[a];this.renderer.canvasContext[i.type].apply(this.renderer.canvasContext,i.args)}r=arguments.length;var s=[];for(a=1;r>a;a+=1)s.push(arguments[a]);l.apply(this.renderer.canvasContext,s)}else l.apply(this.renderer.canvasContext,arguments)},BM_Path2D=t}();var MatrixManager=matrixManagerFunction;!function(){for(var t=0,e=["ms","moz","webkit","o"],a=0;a<e.length&&!window.requestAnimationFrame;++a)window.requestAnimationFrame=window[e[a]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[e[a]+"CancelAnimationFrame"]||window[e[a]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(e,a){var r=(new Date).getTime(),i=Math.max(0,16-(r-t)),s=window.setTimeout(function(){e(r+i)},i);return t=r+i,s}),window.cancelAnimationFrame||(window.cancelAnimationFrame=function(t){clearTimeout(t)})}();var subframeEnabled=!1,cachedColors={},rgbToHex=function(){var t,e,a=[];for(t=0;256>t;t+=1)e=t.toString(16),a[t]=1==e.length?"0"+e:e;return function(t,e,r){return 0>t&&(t=0),0>e&&(e=0),0>r&&(r=0),"#"+a[t]+a[e]+a[r]}}(),fillColorToString=function(){var t=[];return function(e,a){return t[e[0]]||(t[e[0]]=[]),t[e[0]][e[1]]||(t[e[0]][e[1]]=[]),t[e[0]][e[1]][e[2]]||(void 0!==a&&(e[3]=a),t[e[0]][e[1]][e[2]]="rgba("+e.join(",")+")"),t[e[0]][e[1]][e[2]]}}(),bez=bezFunction(),dataManager=dataFunctionManager();SVGRenderer.prototype.buildItems=function(t,e,a){var r,i=0,s=t.length;for(a||(a=this.elements),e||(e=this.animationItem.container),r=s-1;r>=0;r--){if("StillLayer"==t[r].ty)i++,a[r]=this.createImage(t[r],e);else if("PreCompLayer"==t[r].ty){a[r]=this.createComp(t[r],e);var n=[];this.buildItems(t[r].layers,a[r].getDomElement(),n),a[r].setElements(n)}else a[r]="SolidLayer"==t[r].ty?this.createSolid(t[r],e):"ShapeLayer"==t[r].ty?this.createShape(t[r],e):"TextLayer"==t[r].ty?this.createText(t[r],e):this.createBase(t[r],e);t[r].td&&a[r+1].setMatte(a[r].layerId)}},SVGRenderer.prototype.createBase=function(t,e){return new BaseElement(t,this.animationItem,e,this.globalData)},SVGRenderer.prototype.createShape=function(t,e){return new IShapeElement(t,this.animationItem,e,this.globalData)},SVGRenderer.prototype.createText=function(t,e){return new ITextElement(t,this.animationItem,e,this.globalData)},SVGRenderer.prototype.createImage=function(t,e){return new IImageElement(t,this.animationItem,e,this.globalData)},SVGRenderer.prototype.createComp=function(t,e){return new ICompElement(t,this.animationItem,e,this.globalData)},SVGRenderer.prototype.createSolid=function(t,e){return new ISolidElement(t,this.animationItem,e,this.globalData)},SVGRenderer.prototype.configAnimation=function(t){this.animationItem.container=document.createElementNS(svgNS,"svg"),this.animationItem.container.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.animationItem.container.setAttribute("width",t.animation.compWidth),this.animationItem.container.setAttribute("height",t.animation.compHeight),this.animationItem.container.setAttribute("viewBox","0 0 "+t.animation.compWidth+" "+t.animation.compHeight),this.animationItem.container.setAttribute("preserveAspectRatio","xMidYMid meet"),this.animationItem.container.style.width="100%",this.animationItem.container.style.height="100%",this.animationItem.container.style.transformOrigin=this.animationItem.container.style.mozTransformOrigin=this.animationItem.container.style.webkitTransformOrigin=this.animationItem.container.style["-webkit-transform"]="0px 0px 0px",this.animationItem.wrapper.appendChild(this.animationItem.container);var e=document.createElementNS(svgNS,"defs");this.globalData.defs=e,this.animationItem.container.appendChild(e);var a=document.createElementNS(svgNS,"clipPath"),r=document.createElementNS(svgNS,"rect");r.setAttribute("width",t.animation.compWidth),r.setAttribute("height",t.animation.compHeight),r.setAttribute("x",0),r.setAttribute("y",0);var i="animationMask_"+randomString(10);a.setAttribute("id",i),a.appendChild(r);var s=document.createElementNS(svgNS,"g");s.setAttribute("clip-path","url(#"+i+")"),this.animationItem.container.appendChild(s),e.appendChild(a),this.animationItem.container=s,this.layers=t.animation.layers},SVGRenderer.prototype.buildStage=function(t,e,a){var r,i,s=e.length;for(a||(a=this.elements),r=s-1;r>=0;r--)i=e[r],void 0!==i.parent&&this.buildItemParenting(i,a[r],e,i.parent,a),"PreCompLayer"==i.ty&&this.buildStage(a[r].getComposingElement(),i.layers,a[r].getElements())},SVGRenderer.prototype.buildItemParenting=function(t,e,a,r,i){t.parents||(t.parents=[]);for(var s=0,n=a.length;n>s;)a[s].ind==r&&(e.getHierarchy().push(i[s]),void 0!==a[s].parent&&this.buildItemParenting(t,e,a,a[s].parent,i)),s+=1},SVGRenderer.prototype.updateContainerSize=function(){},SVGRenderer.prototype.renderFrame=function(t){if(this.lastFrame!=t){this.lastFrame=t,this.globalData.frameNum=t;var e,a=this.layers.length;for(e=0;a>e;e++)this.elements[e].prepareFrame(t-this.layers[e].startTime);for(e=0;a>e;e++)this.elements[e].renderFrame(t-this.layers[e].startTime)}},CanvasRenderer.prototype.buildItems=function(t,e){e||(e=this.elements);var a,r=0,i=t.length;for(a=0;i>a;a++)if("StillLayer"==t[a].ty)r++,e.push(this.createImage(t[a]));else if("PreCompLayer"==t[a].ty){e.push(this.createComp(t[a]));var s=[];this.buildItems(t[a].layers,s),e[e.length-1].setElements(s)}else e.push("SolidLayer"==t[a].ty?this.createSolid(t[a]):"ShapeLayer"==t[a].ty?this.createShape(t[a]):"TextLayer"==t[a].ty?this.createText(t[a]):this.createBase(t[a]))},CanvasRenderer.prototype.createBase=function(t){return new CVBaseElement(t,this.globalData)},CanvasRenderer.prototype.createShape=function(t){return new CVShapeElement(t,this.globalData)},CanvasRenderer.prototype.createText=function(t){return new CVTextElement(t,this.globalData)},CanvasRenderer.prototype.createImage=function(t){return new CVImageElement(t,this.globalData)},CanvasRenderer.prototype.createComp=function(t){return new CVCompElement(t,this.globalData)},CanvasRenderer.prototype.createSolid=function(t){return new CVSolidElement(t,this.globalData)},CanvasRenderer.prototype.ctxTransform=function(t){if(!this.renderConfig.clearCanvas)return void this.canvasContext.transform(t[0],t[1],t[2],t[3],t[4],t[5]);this.contextData.cTr.transform(t[0],t[1],t[2],t[3],t[4],t[5]);var e=this.contextData.cTr.props;this.canvasContext.setTransform(e[0],e[1],e[2],e[3],e[4],e[5])},CanvasRenderer.prototype.ctxOpacity=function(t){return this.renderConfig.clearCanvas?(this.contextData.cO*=0>t?0:t,void(this.canvasContext.globalAlpha=this.contextData.cO)):void(this.canvasContext.globalAlpha*=0>t?0:t)},CanvasRenderer.prototype.reset=function(){return this.renderConfig.clearCanvas?(this.contextData.cArrPos=0,this.contextData.cTr.reset(),void(this.contextData.cO=1)):void this.canvasContext.restore()},CanvasRenderer.prototype.save=function(t){if(!this.renderConfig.clearCanvas)return void this.canvasContext.save();t&&this.canvasContext.save();var e=this.contextData.cTr.props;(null===this.contextData.saved[this.contextData.cArrPos]||void 0===this.contextData.saved[this.contextData.cArrPos])&&(this.contextData.saved[this.contextData.cArrPos]=new Array(6));var a,r=6,i=this.contextData.saved[this.contextData.cArrPos];for(a=0;r>a;a+=1)i[a]=e[a];this.contextData.savedOp[this.contextData.cArrPos]=this.contextData.cO,this.contextData.cArrPos+=1},CanvasRenderer.prototype.restore=function(t){if(!this.renderConfig.clearCanvas)return void this.canvasContext.restore();t&&this.canvasContext.restore(),this.contextData.cArrPos-=1;var e,a=this.contextData.saved[this.contextData.cArrPos],r=6,i=this.contextData.cTr.props;for(e=0;r>e;e+=1)i[e]=a[e];this.canvasContext.setTransform(a[0],a[1],a[2],a[3],a[4],a[5]),a=this.contextData.savedOp[this.contextData.cArrPos],this.contextData.cO=a,this.canvasContext.globalAlpha=a},CanvasRenderer.prototype.configAnimation=function(t){this.animationItem.wrapper?(this.animationItem.container=document.createElement("canvas"),this.animationItem.container.style.width="100%",this.animationItem.container.style.height="100%",this.animationItem.container.style.transformOrigin=this.animationItem.container.style.mozTransformOrigin=this.animationItem.container.style.webkitTransformOrigin=this.animationItem.container.style["-webkit-transform"]="0px 0px 0px",this.animationItem.wrapper.appendChild(this.animationItem.container),this.canvasContext=this.animationItem.container.getContext("2d")):this.canvasContext=this.renderConfig.context,this.globalData.canvasContext=this.canvasContext,this.globalData.bmCtx=new BM_CanvasRenderingContext2D(this),this.globalData.renderer=this,this.globalData.totalFrames=Math.floor(t.animation.totalFrames),this.globalData.compWidth=t.animation.compWidth,this.globalData.compHeight=t.animation.compHeight,this.layers=t.animation.layers,this.transformCanvas={},this.transformCanvas.w=t.animation.compWidth,this.transformCanvas.h=t.animation.compHeight,this.updateContainerSize()},CanvasRenderer.prototype.updateContainerSize=function(){var t,e;if(this.animationItem.wrapper&&this.animationItem.container?(t=this.animationItem.wrapper.offsetWidth,e=this.animationItem.wrapper.offsetHeight,this.animationItem.container.setAttribute("width",t),this.animationItem.container.setAttribute("height",e)):(t=this.canvasContext.canvas.width,e=this.canvasContext.canvas.height),"fit"==this.renderConfig.scaleMode){var a=t/e,r=this.transformCanvas.w/this.transformCanvas.h;r>a?(this.transformCanvas.sx=t/this.transformCanvas.w,this.transformCanvas.sy=t/this.transformCanvas.w,this.transformCanvas.tx=0,this.transformCanvas.ty=(e-this.transformCanvas.h*(t/this.transformCanvas.w))/2):(this.transformCanvas.sx=e/this.transformCanvas.h,this.transformCanvas.sy=e/this.transformCanvas.h,this.transformCanvas.tx=(t-this.transformCanvas.w*(e/this.transformCanvas.h))/2,this.transformCanvas.ty=0)}else this.transformCanvas.sx=1,this.transformCanvas.sy=1,this.transformCanvas.tx=0,this.transformCanvas.ty=0;this.transformCanvas.props=[this.transformCanvas.sx,0,0,this.transformCanvas.sy,this.transformCanvas.tx,this.transformCanvas.ty],this.clipper=new BM_Path2D,this.clipper.rect(0,0,this.transformCanvas.w,this.transformCanvas.h)},CanvasRenderer.prototype.buildStage=function(t,e,a){a||(a=this.elements);var r,i,s=e.length;for(r=s-1;r>=0;r--)i=e[r],void 0!==i.parent&&this.buildItemHierarchy(i,a[r],e,i.parent,a),"PreCompLayer"==i.ty&&this.buildStage(null,i.layers,a[r].getElements())},CanvasRenderer.prototype.buildItemHierarchy=function(t,e,a,r,i){for(var s=0,n=a.length;n>s;)a[s].ind===r&&(e.getHierarchy().push(i[s]),void 0!==a[s].parent&&this.buildItemHierarchy(t,e,a,a[s].parent,i)),s+=1},CanvasRenderer.prototype.prepareFrame=function(t){var e,a=this.elements.length;for(e=0;a>e;e++)this.elements[e].prepareFrame(t-this.layers[e].startTime)},CanvasRenderer.prototype.draw=function(){var t,e=this.layers.length;for(t=e-1;t>=0;t-=1)this.elements[t].draw()},CanvasRenderer.prototype.renderFrame=function(t){(this.lastFrame!=t||this.renderConfig.clearCanvas!==!0)&&(this.lastFrame=t,this.globalData.frameNum=t-this.animationItem.firstFrame,this.renderConfig.clearCanvas===!0?(this.reset(),this.canvasContext.canvas.width=this.canvasContext.canvas.width):this.save(),this.ctxTransform(this.transformCanvas.props),this.globalData.bmCtx.clip(this.clipper),this.prepareFrame(t),this.draw(),this.renderConfig.clearCanvas!==!0&&this.restore())},MaskElement.prototype.init=function(){this.masksProperties=this.data.masksProperties;var t=this.element.maskedElement,e=this.globalData.defs,a=0,r=this.masksProperties.length;this.layerSize=this.element.getLayerSize();var i,s,n,o,h=this.data.masksProperties,l=0,p=[],m=randomString(10);for(this.maskElement=document.createElementNS(svgNS,"mask"),a=0;r>a;a++)if(h[a].inv&&!this.solidPath&&(this.solidPath=this.createLayerSolidPath()),"s"!=h[a].mode&&"i"!=h[a].mode||0!=l||(o=document.createElementNS(svgNS,"rect"),o.setAttribute("fill","#ffffff"),o.setAttribute("x","0"),o.setAttribute("y","0"),o.setAttribute("width","100%"),o.setAttribute("height","100%"),p.push(o)),!("f"==h[a].mode&&l>0||"n"==h[a].mode))if(l+=1,i=document.createElementNS(svgNS,"path"),h[a].cl?"s"==h[a].mode?i.setAttribute("fill","#000000"):i.setAttribute("fill","#ffffff"):(i.setAttribute("fill","none"),"s"==h[a].mode?i.setAttribute("fill","#000000"):i.setAttribute("fill","#ffffff"),i.setAttribute("stroke-width","1"),i.setAttribute("stroke-miterlimit","10")),i.setAttribute("clip-rule","nonzero"),this.storedData[a]={elem:i,lastPath:""},"i"==h[a].mode){n=p.length;var d=document.createElementNS(svgNS,"g");for(s=0;n>s;s+=1)d.appendChild(p[s]);var c=document.createElementNS(svgNS,"mask");c.setAttribute("mask-type","alpha"),c.setAttribute("id",m+"_"+l),c.appendChild(i),e.appendChild(c),d.setAttribute("mask","url(#"+m+"_"+l+")"),p.length=0,p.push(d)}else p.push(i);for(r=p.length,a=0;r>a;a+=1)this.maskElement.appendChild(p[a]);this.maskElement.setAttribute("id",m),l>0&&t.setAttribute("mask","url(#"+m+")"),e.appendChild(this.maskElement)},MaskElement.prototype.renderFrame=function(t){var e,a=this.data.masksProperties.length,r=0;for(e=0;a>e;e++)"f"==this.data.masksProperties[e].mode&&r>0||"n"==this.data.masksProperties[e].mode||(r+=1,this.drawPath(this.data.masksProperties[e],this.data.masksProperties[e].paths[t].pathNodes,this.storedData[e]))},MaskElement.prototype.processMaskFromEffects=function(t,e){var a,r=this.registeredEffects.length;for(a=0;r>a;a++)this.registeredEffects[a].renderMask(t,e)},MaskElement.prototype.registerEffect=function(t){this.registeredEffects.push(t)},MaskElement.prototype.getMaskelement=function(){return this.maskElement},MaskElement.prototype.createLayerSolidPath=function(){var t="M0,0 ";return t+="h"+this.layerSize.w,t+="v"+this.layerSize.h,t+="h"+-this.layerSize.w,t+="v"+-this.layerSize.h},MaskElement.prototype.drawPath=function(t,e,a){var r,i,s="";if(e.__renderedString)s=e.__renderedString;else{for(i=e.v.length,r=1;i>r;r+=1)1==r&&(s+=" M"+e.v[0][0]+","+e.v[0][1]),s+=" C"+e.o[r-1][0]+","+e.o[r-1][1]+" "+e.i[r][0]+","+e.i[r][1]+" "+e.v[r][0]+","+e.v[r][1];t.cl&&(s+=" C"+e.o[r-1][0]+","+e.o[r-1][1]+" "+e.i[0][0]+","+e.i[0][1]+" "+e.v[0][0]+","+e.v[0][1]),e.__renderedString=s}a.lastPath!==s&&(t.inv?a.elem.setAttribute("d",this.solidPath+s):a.elem.setAttribute("d",s),a.lastPath=s)};var BaseElement=function(t,e,a,r){this.animationItem=e,this.globalData=r,this.data=t,this.ownMatrix=new Matrix,this.finalTransform={mat:new Matrix,op:1},this.matteElement=null,this.renderedFrames=[],this.lastData={},this.parentContainer=a,this.layerId=randomString(10),this.hidden=!1,this.init()};BaseElement.prototype.init=function(){this.createElements(),this.data.hasMask&&this.addMasks(this.data),this.data.eff},BaseElement.prototype.createElements=function(){if(this.data.td){if(3==this.data.td)this.layerElement=document.createElementNS(svgNS,"mask"),this.layerElement.setAttribute("id",this.layerId),this.layerElement.setAttribute("mask-type","luminance"),this.globalData.defs.appendChild(this.layerElement);else if(2==this.data.td){var t=document.createElementNS(svgNS,"mask");t.setAttribute("id",this.layerId),t.setAttribute("mask-type","alpha");var e=document.createElementNS(svgNS,"g");t.appendChild(e),this.layerElement=document.createElementNS(svgNS,"g");var a=document.createElementNS(svgNS,"filter"),r=randomString(10);a.setAttribute("id",r),a.setAttribute("filterUnits","objectBoundingBox"),a.setAttribute("x","0%"),a.setAttribute("y","0%"),a.setAttribute("width","100%"),a.setAttribute("height","100%");var i=document.createElementNS(svgNS,"feComponentTransfer");i.setAttribute("in","SourceGraphic"),a.appendChild(i);var s=document.createElementNS(svgNS,"feFuncA");s.setAttribute("type","table"),s.setAttribute("tableValues","1.0 0.0"),i.appendChild(s),this.globalData.defs.appendChild(a);var n=document.createElementNS(svgNS,"rect");n.setAttribute("width","100%"),n.setAttribute("height","100%"),n.setAttribute("x","0"),n.setAttribute("y","0"),n.setAttribute("fill","#ffffff"),n.setAttribute("opacity","0"),e.setAttribute("filter","url(#"+r+")"),e.appendChild(n),e.appendChild(this.layerElement),this.globalData.defs.appendChild(t)}else{this.layerElement=document.createElementNS(svgNS,"g");var o=document.createElementNS(svgNS,"mask");o.setAttribute("id",this.layerId),o.setAttribute("mask-type","alpha"),o.appendChild(this.layerElement),this.globalData.defs.appendChild(o)}this.data.hasMask&&(this.maskedElement=this.layerElement)}else this.data.hasMask?(this.layerElement=document.createElementNS(svgNS,"g"),this.data.tt?(this.matteElement=document.createElementNS(svgNS,"g"),this.matteElement.appendChild(this.layerElement),this.parentContainer.appendChild(this.matteElement)):this.parentContainer.appendChild(this.layerElement),this.maskedElement=this.layerElement):this.data.tt?(this.matteElement=document.createElementNS(svgNS,"g"),this.matteElement.setAttribute("id",this.layerId),this.parentContainer.appendChild(this.matteElement),this.layerElement=this.matteElement):this.layerElement=this.parentContainer},BaseElement.prototype.prepareFrame=function(t){this.currentAnimData=this.data.renderedData[t].an;var e=this.currentAnimData.matrixArray;this.ownMatrix.reset().transform(e[0],e[1],e[2],e[3],e[4],e[5]).translate(-this.currentAnimData.tr.a[0],-this.currentAnimData.tr.a[1])},BaseElement.prototype.renderFrame=function(t,e){if("NullLayer"!=this.data.ty){if(this.data.inPoint-this.data.startTime<=t&&this.data.outPoint-this.data.startTime>t?(this.isVisible!==!0&&(this.isVisible=!0),this.finalTransform.opacity=1):(this.isVisible!==!1&&(this.isVisible=!1),this.finalTransform.opacity=0),this.data.eff,t===this.data.renderedFrame.num)return this.isVisible;this.data.hasMask&&this.maskManager.renderFrame(t),this.finalTransform.opacity*=this.currentAnimData.tr.o;var a,r=this.finalTransform.mat;if(e&&(a=e.mat.props,r.reset().transform(a[0],a[1],a[2],a[3],a[4],a[5]),this.finalTransform.opacity*=e.opacity),this.hierarchy){var i,s=this.hierarchy.length;for(e||r.reset(),i=s-1;i>=0;i-=1)a=this.hierarchy[i].ownMatrix.props,r.transform(a[0],a[1],a[2],a[3],a[4],a[5]);a=this.ownMatrix.props,r.transform(a[0],a[1],a[2],a[3],a[4],a[5])}else this.isVisible&&(e?(a=this.ownMatrix.props,r.transform(a[0],a[1],a[2],a[3],a[4],a[5])):(this.finalTransform.mat.props[0]=this.ownMatrix.props[0],this.finalTransform.mat.props[1]=this.ownMatrix.props[1],this.finalTransform.mat.props[2]=this.ownMatrix.props[2],this.finalTransform.mat.props[3]=this.ownMatrix.props[3],this.finalTransform.mat.props[4]=this.ownMatrix.props[4],this.finalTransform.mat.props[5]=this.ownMatrix.props[5]));if(this.data.hasMask){this.renderedFrames[this.globalData.frameNum]||(this.renderedFrames[this.globalData.frameNum]={tr:"matrix("+r.props.join(",")+")",o:this.finalTransform.opacity});var n=this.renderedFrames[this.globalData.frameNum];this.lastData.tr!=n.tr&&(this.lastData.tr=n.tr,this.layerElement.setAttribute("transform",n.tr)),this.lastData.o!==n.o&&(this.lastData.o=n.o,this.layerElement.setAttribute("opacity",n.o))}return this.isVisible}},BaseElement.prototype.getDomElement=function(){return this.layerElement},BaseElement.prototype.getMaskManager=function(){return this.maskManager},BaseElement.prototype.addMasks=function(t){this.maskManager=new MaskElement(t,this,this.globalData),this.maskManager.init()},BaseElement.prototype.createEffectsManager=function(t){var e={effects:{value:t.eff},element:{value:this}};this.effectsManager=createElement(EffectsManager,null,e)},BaseElement.prototype.getType=function(){return this.type},BaseElement.prototype.getLayerSize=function(){return"TextLayer"==this.data.ty?{w:this.data.textData.width,h:this.data.textData.height}:{w:this.data.width,h:this.data.height}},BaseElement.prototype.getHierarchy=function(){return this.hierarchy||(this.hierarchy=[]),this.hierarchy},BaseElement.prototype.setMatte=function(t){this.matteElement&&this.matteElement.setAttribute("mask","url(#"+t+")")},BaseElement.prototype.hide=function(){},createElement(BaseElement,ICompElement),ICompElement.prototype.getComposingElement=function(){return this.layerElement},ICompElement.prototype.hide=function(){if(!this.hidden){var t,e=this.elements.length;for(t=0;e>t;t+=1)this.elements[t].hide();this.hidden=!0}},ICompElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);if(a===!1)return void this.hide();this.hidden=!1;var r,i=this.layers.length,s=this.data.tm?this.data.tm[t]<0?0:t>=this.data.tm.length?this.data.tm[this.data.tm.length-1]:this.data.tm[t]:t;for(r=0;i>r;r+=1)this.elements[r].prepareFrame(s-this.layers[r].startTime);for(r=0;i>r;r+=1)this.data.hasMask?this.elements[r].renderFrame(s-this.layers[r].startTime):this.elements[r].renderFrame(s-this.layers[r].startTime,this.finalTransform)},ICompElement.prototype.setElements=function(t){this.elements=t},ICompElement.prototype.getElements=function(){return this.elements},createElement(BaseElement,IImageElement),IImageElement.prototype.createElements=function(){var t=this,e=function(){t.image.setAttributeNS("http://www.w3.org/1999/xlink","href",t.path+t.assetData.p),t.maskedElement=t.image,t.animationItem.elementLoaded()},a=new Image;a.addEventListener("load",e,!1),a.addEventListener("error",e,!1),a.src=this.path+this.assetData.p,this.parent.createElements.call(this),this.image=document.createElementNS(svgNS,"image"),this.image.setAttribute("width",this.assetData.w+"px"),this.image.setAttribute("height",this.assetData.h+"px"),this.layerElement.appendChild(this.image)},IImageElement.prototype.hide=function(){this.hidden||(this.image.setAttribute("opacity","0"),this.hidden=!0)},IImageElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);if(a===!1)return void this.hide();if(this.hidden&&(this.lastData.o=-1,this.hidden=!1,this.image.setAttribute("opacity","1")),!this.data.hasMask){this.renderedFrames[this.globalData.frameNum]||(this.renderedFrames[this.globalData.frameNum]={tr:"matrix("+this.finalTransform.mat.props.join(",")+")",o:this.finalTransform.opacity});var r=this.renderedFrames[this.globalData.frameNum];this.lastData.tr!=r.tr&&(this.lastData.tr=r.tr,this.image.setAttribute("transform",r.tr)),this.lastData.o!==r.o&&(this.lastData.o=r.o,this.image.setAttribute("opacity",r.o))}},createElement(BaseElement,IShapeElement),IShapeElement.prototype.createElements=function(){this.parent.createElements.call(this),this.mainShape=new ShapeItemElement(this.data.shapes,this.layerElement,this.globalData)},IShapeElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);return a===!1?void this.hide():void this.renderShapes(t)},IShapeElement.prototype.hide=function(){this.hidden||(this.mainShape.hideShape(),this.hidden=!0)},IShapeElement.prototype.renderShapes=function(t){this.hidden=!1,this.data.hasMask?this.mainShape.renderShape(t,{opacity:1,mat:new Matrix}):this.mainShape.renderShape(t,this.finalTransform)},ShapeItemElement.prototype.searchShapes=function(t,e){var a,r,i,s=t.length-1,n=[];for(a=s;a>=0;a-=1)if("fl"==t[a].ty||"st"==t[a].ty){e[a]={renderedFrames:[],lastData:{c:"",o:-1,w:""}};var o=document.createElementNS(svgNS,"path");this.shape.appendChild(o),this.stylesList.push({pathElement:o,type:t[a].ty,d:""}),e[a].style=this.stylesList[this.stylesList.length-1],n.push(e[a].style)}else if("gr"==t[a].ty)e[a]={it:[]},this.searchShapes(t[a].it,e[a].it);else if("tr"==t[a].ty)e[a]={transform:{mat:new Matrix,opacity:1}};else if("sh"==t[a].ty||"rc"==t[a].ty||"el"==t[a].ty)for(e[a]={elements:[],renderedFrames:[],styles:[],lastData:{d:"",o:"",tr:""}},i=this.stylesList.length,r=0;i>r;r+=1)this.stylesList[r].closed||(e[a].styles.push(this.stylesList[r]),"st"==this.stylesList[r].type&&(this.stylesList[r].pathElement.setAttribute("fill-opacity",0),this.stylesList[r].pathElement.setAttribute("stroke-linejoin","round"),this.stylesList[r].pathElement.setAttribute("stroke-linecap","round")));for(s=n.length,a=0;s>a;a+=1)n[a].closed=!0},ShapeItemElement.prototype.getElement=function(){return this.shape},ShapeItemElement.prototype.hideShape=function(){var t,e=this.stylesList.length;for(t=e-1;t>=0;t-=1)this.stylesList[t].pathElement.setAttribute("d","M 0,0")},ShapeItemElement.prototype.renderShape=function(t,e,a,r){var i,s;if(!a)for(a=this.data,s=this.stylesList.length,i=0;s>i;i+=1)this.stylesList[i].d="";r||(r=this.viewData),this.frameNum=t,s=a.length-1;var n,o;for(n=e,i=s;i>=0;i-=1)if("tr"==a[i].ty){var h=a[i].renderedData[t].mtArr;if(n=r[i].transform,o=n.mat,o.reset(),e){var l=e.mat.props;n.opacity=e.opacity,n.opacity*=a[i].renderedData[t].o,o.transform(l[0],l[1],l[2],l[3],l[4],l[5])}else n.opacity=a[i].renderedData[t].o;o.transform(h[0],h[1],h[2],h[3],h[4],h[5]).translate(-a[i].renderedData[t].a[0],-a[i].renderedData[t].a[1])}else"sh"==a[i].ty?this.renderPath(a[i],r[i],t,n):"el"==a[i].ty?this.renderPath(a[i],r[i],t,n):"rc"==a[i].ty?a[i].trimmed?this.renderPath(a[i],r[i],t,n):this.renderRect(a[i],r[i],t,n):"fl"==a[i].ty?this.renderFill(a[i],r[i],t,n):"st"==a[i].ty?this.renderStroke(a[i],r[i],t,n):"gr"==a[i].ty?this.renderShape(t,n,a[i].it,r[i].it):"tm"==a[i].ty;for(s=this.stylesList.length,i=0;s>i;i+=1)""==this.stylesList[i].d?this.stylesList[i].pathElement.setAttribute("d","M 0,0"):this.stylesList[i].pathElement.setAttribute("d",this.stylesList[i].d)},ShapeItemElement.prototype.renderPath=function(t,e,a,r){var i,s;if(!e.renderedFrames[this.globalData.frameNum]){var n=t.renderedData[a].path.pathNodes;if(!n.v)return;i=n.v.length;var o=n.s?n.s:[],h="";for(s=1;i>s;s+=1)o[s-1]?h+=" M"+o[s-1][0]+","+o[s-1][1]:1==s&&(h+=" M"+n.v[0][0]+","+n.v[0][1]),h+=" C"+n.o[s-1][0]+","+n.o[s-1][1]+" "+n.i[s][0]+","+n.i[s][1]+" "+n.v[s][0]+","+n.v[s][1];1==i&&(h+=o[0]?" M"+o[0][0]+","+o[0][1]:" M"+n.v[0][0]+","+n.v[0][1]),!t.closed||t.trimmed&&!n.c||(h+=" C"+n.o[s-1][0]+","+n.o[s-1][1]+" "+n.i[0][0]+","+n.i[0][1]+" "+n.v[0][0]+","+n.v[0][1]),e.renderedFrames[this.globalData.frameNum]={dTr:h}}var l=e.renderedFrames[this.globalData.frameNum];for(i=e.styles.length,s=0;i>s;s+=1)e.styles[s].d+=l.dTr},ShapeItemElement.prototype.renderFill=function(t,e,a,r){var i=t.renderedData[a],s=e.style;e.renderedFrames[this.globalData.frameNum]||(e.renderedFrames[this.globalData.frameNum]={c:i.color,o:i.opacity*r.opacity,t:"matrix("+r.mat.props.join(",")+")"});var n=e.renderedFrames[this.globalData.frameNum],o=n.c,h=n.o,l=n.t;e.lastData.c!=o&&s.pathElement.setAttribute("fill",o),e.lastData.o!=h&&s.pathElement.setAttribute("fill-opacity",h),e.lastData.t!=l&&s.pathElement.setAttribute("transform",l),e.lastData.c=o,e.lastData.o=h,e.lastData.t=l},ShapeItemElement.prototype.renderStroke=function(t,e,a,r){var i=t.renderedData[a],s=e.style;e.renderedFrames[this.globalData.frameNum]||(e.renderedFrames[this.globalData.frameNum]={c:i.color,o:i.opacity*r.opacity,w:i.width,t:"matrix("+r.mat.props.join(",")+")"},i.dashes&&(e.renderedFrames[this.globalData.frameNum].d=i.dashes));var n,o,h=e.renderedFrames[this.globalData.frameNum],l=h.c,p=h.o,m=h.w,d=h.d,c=h.t;if(d){var f,u=d.length;for(n="",o="",f=0;u>f;f+=1)"o"!=d[f].n?n+=" "+d[f].v:o+=d[f].v}e.lastData.c!=l&&s.pathElement.setAttribute("stroke",l),e.lastData.o!=p&&s.pathElement.setAttribute("stroke-opacity",p),e.lastData.w!==m&&s.pathElement.setAttribute("stroke-width",m),e.lastData.t!==c&&s.pathElement.setAttribute("transform",c),d&&(e.lastData.da!=n&&s.pathElement.setAttribute("stroke-dasharray",n),e.lastData["do"]!=o&&s.pathElement.setAttribute("stroke-dashoffset",o)),e.lastData.c=l,e.lastData.o=p,e.lastData.w=m,e.lastData.t=c,d&&(e.lastData.da=n,e.lastData["do"]=o)},createElement(BaseElement,ISolidElement),ISolidElement.prototype.createElements=function(){this.parent.createElements.call(this);var t=document.createElementNS(svgNS,"rect");t.setAttribute("width",this.data.width),t.setAttribute("height",this.data.height),t.setAttribute("fill",this.data.color),this.layerElement.appendChild(t),this.rectElement=t},ISolidElement.prototype.hide=function(){this.hidden||(this.rectElement.setAttribute("opacity","0"),this.hidden=!0)},ISolidElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);if(a===!1)return void this.hide();if(this.hidden&&(this.lastData.o=-1,this.hidden=!1,this.data.hasMask&&this.rectElement.setAttribute("opacity","1")),!this.data.hasMask){this.renderedFrames[this.globalData.frameNum]||(this.renderedFrames[this.globalData.frameNum]={tr:"matrix("+this.finalTransform.mat.props.join(",")+")",o:this.finalTransform.opacity});var r=this.renderedFrames[this.globalData.frameNum];this.lastData.tr!=r.tr&&(this.lastData.tr=r.tr,this.rectElement.setAttribute("transform",r.tr)),this.lastData.o!==r.o&&(this.lastData.o=r.o,this.rectElement.setAttribute("opacity",r.o))}},createElement(BaseElement,ITextElement),ITextElement.prototype.createElements=function(){this.parent.createElements.call(this)},CVBaseElement.prototype.init=function(){this.createElements(),this.data.hasMask&&this.addMasks(this.data),this.data.eff},CVBaseElement.prototype.createElements=function(){},CVBaseElement.prototype.prepareFrame=function(t){this.currentAnimData=this.data.renderedData[t].an;var e=this.currentAnimData.matrixArray;return this.ownMatrix.reset().transform(e[0],e[1],e[2],e[3],e[4],e[5]).translate(-this.currentAnimData.tr.a[0],-this.currentAnimData.tr.a[1]),this.data.inPoint-this.data.startTime<=t&&this.data.outPoint-this.data.startTime>=t?(this.renderFrame=!0,this.finalTransform.opacity=1,void(this.data.hasMask&&this.maskManager.prepareFrame(t))):(this.renderFrame=!1,this.finalTransform.opacity=0,!1)},CVBaseElement.prototype.draw=function(t){if("NullLayer"!=this.data.ty){if(!this.renderFrame)return!1;var e,a=(this.canvasContext,this.finalTransform.mat);if(this.finalTransform.opacity*=this.currentAnimData.tr.o,t&&(e=t.mat.props,a.reset().transform(e[0],e[1],e[2],e[3],e[4],e[5]),this.finalTransform.opacity*=t.opacity),this.hierarchy){var r,i=this.hierarchy.length;for(t||a.reset(),r=i-1;r>=0;r-=1)e=this.hierarchy[r].ownMatrix.props,a.transform(e[0],e[1],e[2],e[3],e[4],e[5]);e=this.ownMatrix.props,a.transform(e[0],e[1],e[2],e[3],e[4],e[5])}else this.renderFrame&&(t?(e=this.ownMatrix.props,a.transform(e[0],e[1],e[2],e[3],e[4],e[5])):this.finalTransform.mat=this.ownMatrix);this.data.hasMask&&(this.globalData.renderer.save(!0),this.maskManager.draw(this.finalTransform))}},CVBaseElement.prototype.getCurrentAnimData=function(){return this.currentAnimData},CVBaseElement.prototype.addMasks=function(t){var e={data:{value:t},element:{value:this},globalData:{value:this.globalData}};this.maskManager=createElement(CVMaskElement,null,e)},CVBaseElement.prototype.createEffectsManager=function(t){var e={effects:{value:t.eff},element:{value:this}};this.effectsManager=createElement(EffectsManager,null,e)},CVBaseElement.prototype.getType=function(){return this.type},CVBaseElement.prototype.getHierarchy=function(){return this.hierarchy||(this.hierarchy=[]),this.hierarchy},CVBaseElement.prototype.getLayerSize=function(){return"TextLayer"==this.data.ty?{w:this.data.textData.width,h:this.data.textData.height}:{w:this.data.width,h:this.data.height}},createElement(CVBaseElement,CVCompElement),CVCompElement.prototype.prepareFrame=function(t){var e=this.parent.prepareFrame.call(this,t);if(e!==!1){var a,r=this.elements.length,i=this.data.tm?this.data.tm[t]<0?0:t>=this.data.tm.length?this.data.tm[this.data.tm.length-1]:this.data.tm[t]:t;for(a=0;r>a;a+=1)this.elements[a].prepareFrame(i-this.layers[a].startTime)}},CVCompElement.prototype.draw=function(t){if(this.parent.draw.call(this,t)!==!1){var e,a=this.layers.length;for(e=a-1;e>=0;e-=1)this.elements[e].draw(this.finalTransform);this.data.hasMask&&this.globalData.renderer.restore(!0)}},CVCompElement.prototype.setElements=function(t){this.elements=t},CVCompElement.prototype.getElements=function(){return this.elements},createElement(CVBaseElement,CVImageElement),CVImageElement.prototype.createElements=function(){var t=this,e=function(){t.animationItem.elementLoaded()},a=function(){
-t.failed=!0,t.animationItem.elementLoaded()};this.img=new Image,this.img.addEventListener("load",e,!1),this.img.addEventListener("error",a,!1),this.img.src=this.path+this.assetData.p,this.parent.createElements.call(this)},CVImageElement.prototype.draw=function(t){if(!this.failed&&this.parent.draw.call(this,t)!==!1){var e=this.canvasContext;this.globalData.renderer.save();var a=this.finalTransform.mat.props;this.globalData.renderer.ctxTransform(a),this.globalData.renderer.ctxOpacity(this.finalTransform.opacity),e.drawImage(this.img,0,0),this.globalData.renderer.restore(this.data.hasMask)}},createElement(CVBaseElement,CVShapeElement),CVShapeElement.prototype.createElements=function(){this.parent.createElements.call(this),this.mainShape=new CVShapeItemElement(this.data.shapes,!0,this.globalData)},CVShapeElement.prototype.prepareFrame=function(t){var e=this.parent.prepareFrame.call(this,t);e!==!1&&this.mainShape.prepareFrame(t)},CVShapeElement.prototype.draw=function(t){this.parent.draw.call(this,t)!==!1&&(this.drawShapes(this.finalTransform),this.data.hasMask&&this.globalData.renderer.restore(!0))},CVShapeElement.prototype.drawShapes=function(t){this.mainShape.renderShape(t)},CVShapeItemElement.prototype.drawPaths=function(t){var e,a;t?(a=[],e=this.stylesList):e=this.renderedPaths[this.globalData.frameNum];var r,i=e.length,s=this.canvasContext;for(this.globalData.renderer.save(),s.lineCap="round",s.lineJoin="round",r=0;i>r;r+=1)"stroke"==e[r].type?(1!=e[r].opacity&&(this.globalData.renderer.save(),this.globalData.renderer.ctxOpacity(e[r].opacity)),s.strokeStyle=e[r].value,s.lineWidth=e[r].width,e[r].dasharray?(s.setLineDash(e[r].dasharray),s.lineDashOffset=e[r].dashoffset):(s.setLineDash([]),s.lineDashOffset=0),this.globalData.bmCtx.stroke(e[r].path),1!=e[r].opacity&&this.globalData.renderer.restore(),t&&(a.push({type:e[r].type,opacity:e[r].opacity,value:e[r].value,width:e[r].width,path:e[r].path}),e[r].dasharray&&(a[a.length-1].dasharray=e[r].dasharray,a[a.length-1].dashoffset=e[r].dashoffset))):"fill"==e[r].type&&(1!=e[r].opacity&&(this.globalData.renderer.save(),this.globalData.renderer.ctxOpacity(e[r].opacity)),s.fillStyle=e[r].value,this.globalData.bmCtx.fill(e[r].path),1!=e[r].opacity&&this.globalData.renderer.restore(),t&&a.push({type:e[r].type,opacity:e[r].opacity,value:e[r].value,path:e[r].path}));this.globalData.renderer.restore(),t&&(this.renderedPaths[this.globalData.frameNum]=a)},CVShapeItemElement.prototype.prepareFrame=function(t){this.frameNum=t;var e,a=this.dataLength-1;for(e=a;e>=0;e-=1)"gr"==this.data[e].ty&&this.data[e].item.prepareFrame(t)},CVShapeItemElement.prototype.renderShape=function(t,e){if(this.renderedPaths[this.globalData.frameNum])return void this.drawPaths(!1);this.transform.opacity=1;var a,r;for(this.ownStylesList.length=0,this.currentStylePoolPos=0,e?this.stylesList=e:this.stylesList.length=0,t?(this.transform.mat.props[0]=t.mat.props[0],this.transform.mat.props[1]=t.mat.props[1],this.transform.mat.props[2]=t.mat.props[2],this.transform.mat.props[3]=t.mat.props[3],this.transform.mat.props[4]=t.mat.props[4],this.transform.mat.props[5]=t.mat.props[5],this.transform.opacity*=t.opacity):(this.transform.mat.props[0]=this.transform.mat.props[3]=1,this.transform.mat.props[1]=this.transform.mat.props[2]=this.transform.mat.props[4]=this.transform.mat.props[5]=0),r=this.dataLength-1,a=r;a>=0;a-=1)"gr"==this.data[a].ty?this.data[a].item.renderShape(this.transform,this.stylesList):"tr"==this.data[a].ty?this.renderTransform(this.data[a]):"sh"==this.data[a].ty?this.renderPath(this.data[a]):"el"==this.data[a].ty?this.renderEllipse(this.data[a]):"rc"==this.data[a].ty?this.data[a].trimmed?this.renderPath(this.data[a]):this.renderRect(this.data[a]):"fl"==this.data[a].ty?this.renderFill(this.data[a]):"st"==this.data[a].ty&&this.renderStroke(this.data[a]);if(this.mainFlag)this.drawPaths(!0);else for(r=this.ownStylesList.length,a=0;r>a;a+=1)this.ownStylesList[a].closed=!0},CVShapeItemElement.prototype.renderTransform=function(t){var e=t.renderedData[this.frameNum],a=e.mtArr;this.transform.mat.transform(a[0],a[1],a[2],a[3],a[4],a[5]).translate(-e.a[0],-e.a[1]),this.transform.opacity*=e.o},CVShapeItemElement.prototype.renderPath=function(t){if(t.trimmed){var e=this.canvasContext;e.lineCap="round",e.lineJoin="round"}var a=t.renderedData[this.frameNum].path,r=new BM_Path2D,i=a.pathNodes;if(i instanceof Array&&(i=i[0]),i.v){var s,n=i.v.length,o=i.s?i.s:[];for(s=1;n>s;s+=1)o[s-1]?r.moveTo(o[s-1][0],o[s-1][1]):1==s&&r.moveTo(i.v[0][0],i.v[0][1]),r.bezierCurveTo(i.o[s-1][0],i.o[s-1][1],i.i[s][0],i.i[s][1],i.v[s][0],i.v[s][1]);1==n&&(o[0]?r.moveTo(o[0][0],o[0][1]):r.moveTo(i.v[0][0],i.v[0][1])),!t.closed||t.trimmed&&!i.c||r.bezierCurveTo(i.o[s-1][0],i.o[s-1][1],i.i[0][0],i.i[0][1],i.v[0][0],i.v[0][1]),this.addPathToStyles(r)}},CVShapeItemElement.prototype.renderEllipse=function(t){var e=new BM_Path2D,a=t.renderedData[this.frameNum];e.moveTo(a.p[0]+a.size[0]/2,a.p[1]),e.ellipse(a.p[0],a.p[1],a.size[0]/2,a.size[1]/2,0,0,2*Math.PI,!1),this.addPathToStyles(e)},CVShapeItemElement.prototype.renderRect=function(t){var e=new BM_Path2D,a=t.renderedData[this.frameNum],r=a.roundness;if(0===r)e.rect(a.position[0]-a.size[0]/2,a.position[1]-a.size[1]/2,a.size[0],a.size[1]);else{var i=a.position[0]-a.size[0]/2,s=a.position[1]-a.size[1]/2,n=a.size[0],o=a.size[1];r instanceof Array&&(r=r[0]),r>n/2&&(r=n/2),r>o/2&&(r=o/2),e.moveTo(i+r,s),e.lineTo(i+n-r,s),e.quadraticCurveTo(i+n,s,i+n,s+r),e.lineTo(i+n,s+o-r),e.quadraticCurveTo(i+n,s+o,i+n-r,s+o),e.lineTo(i+r,s+o),e.quadraticCurveTo(i,s+o,i,s+o-r),e.lineTo(i,s+r),e.quadraticCurveTo(i,s,i+r,s)}this.addPathToStyles(e)},CVShapeItemElement.prototype.addPathToStyles=function(t){var e,a=this.stylesList.length,r=!0,i=0;for(e=a-1;e>=0;e-=1)this.stylesList[e].closed||("stroke"==this.stylesList[e].type?(this.stylesList[e].width>i&&this.stylesList[e].path.addPath(t,this.transform.mat.props),1==this.stylesList[e].styleOpacity&&1==this.stylesList[e].opacity&&(i=this.stylesList[e].width)):r&&"fill"==this.stylesList[e].type&&(this.stylesList[e].path.addPath(t,this.transform.mat.props),1==this.stylesList[e].styleOpacity&&1==this.stylesList[e].opacity&&(r=!1)))},CVShapeItemElement.prototype.renderFill=function(t){var e=t.renderedData[this.frameNum];return t.fillEnabled!==!1?(this.stylesPool[this.currentStylePoolPos].path=new BM_Path2D,this.stylesPool[this.currentStylePoolPos].closed=!1,this.stylesPool[this.currentStylePoolPos].styleOpacity=e.opacity<1?e.opacity:1,this.stylesPool[this.currentStylePoolPos].opacity=this.transform.opacity,this.stylesPool[this.currentStylePoolPos].value=e.opacity<1?fillColorToString(e.color,e.opacity):fillColorToString(e.color),this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),void(this.currentStylePoolPos+=1)):(this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),void(this.currentStylePoolPos+=1))},CVShapeItemElement.prototype.renderStroke=function(t){var e=t.renderedData[this.frameNum];if(this.data.strokeEnabled!==!1){if(this.stylesPool[this.currentStylePoolPos].path=new BM_Path2D,this.stylesPool[this.currentStylePoolPos].closed=!1,this.stylesPool[this.currentStylePoolPos].styleOpacity=e.opacity<1?e.opacity:1,this.stylesPool[this.currentStylePoolPos].width=e.width,this.stylesPool[this.currentStylePoolPos].opacity=this.transform.opacity,this.stylesPool[this.currentStylePoolPos].value=e.opacity<1?fillColorToString(e.color,e.opacity):fillColorToString(e.color),e.dashes){var a,r=e.dashes,i=r.length,s=[],n="";for(a=0;i>a;a+=1)"o"!=r[a].n?s.push(r[a].v):n=r[a].v;this.stylesPool[this.currentStylePoolPos].dasharray=s,this.stylesPool[this.currentStylePoolPos].dashoffset=n}return this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),void(this.currentStylePoolPos+=1)}this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),this.currentStylePoolPos+=1},createElement(CVBaseElement,CVSolidElement),CVSolidElement.prototype.draw=function(t){if(this.parent.draw.call(this,t)!==!1){var e=this.canvasContext;this.globalData.renderer.save();var a=this.finalTransform.mat.props;this.globalData.renderer.ctxTransform(a),this.globalData.renderer.ctxOpacity(this.finalTransform.opacity),e.fillStyle=this.data.color,e.fillRect(0,0,this.data.width,this.data.height),this.globalData.renderer.restore(this.data.hasMask)}},createElement(CVBaseElement,CVTextElement),CVTextElement.prototype.createElements=function(){this.parent.createElements.call(this)},CVMaskElement.prototype.init=function(){this.registeredEffects=[],this.masksProperties=this.data.masksProperties,this.totalMasks=this.masksProperties.length,this.ctx=this.element.canvasContext,this.layerSize=this.element.getLayerSize(),this.renderedFrames=new Array(this.globalData.totalFrames+1)},CVMaskElement.prototype.prepareFrame=function(t){this.frameNum=t},CVMaskElement.prototype.draw=function(t){var e;if(this.renderedFrames[this.globalData.frameNum])e=this.renderedFrames[this.globalData.frameNum];else{var a,r=new BM_Path2D,i=this.data.masksProperties.length;for(e=new BM_Path2D,a=0;i>a;a++)this.masksProperties[a].inv&&this.createInvertedMask(r,this.data.masksProperties[a].paths[this.frameNum].pathNodes),this.drawShape(r,this.data.masksProperties[a].paths[this.frameNum].pathNodes);e.addPath(r,t.mat.props),this.renderedFrames[this.globalData.frameNum]=e}this.globalData.bmCtx.clip(e)},CVMaskElement.prototype.drawShape=function(t,e){var a,r=e.v.length;for(t.moveTo(e.v[0][0],e.v[0][1]),a=1;r>a;a++)t.bezierCurveTo(e.o[a-1][0],e.o[a-1][1],e.i[a][0],e.i[a][1],e.v[a][0],e.v[a][1]);t.bezierCurveTo(e.o[a-1][0],e.o[a-1][1],e.i[0][0],e.i[0][1],e.v[0][0],e.v[0][1])},CVMaskElement.prototype.createInvertedMask=function(t){t.moveTo(0,0),t.lineTo(this.globalData.compWidth,0),t.lineTo(this.globalData.compWidth,this.globalData.compHeight),t.lineTo(0,this.globalData.compHeight),t.lineTo(0,0)};var animationManager=function(){function t(t){if(!t)return null;for(var e=0;v>e;){if(u[e].elem==t&&null!==u[e].elem)return u[e].animation;e+=1}var a=new AnimationItem;return a.setData(t),u.push({elem:t,animation:a}),v+=1,a}function e(t){var e=new AnimationItem;return e.setParams(t),u.push({elem:null,animation:e}),v+=1,e}function a(t,e){var a;for(a=0;v>a;a+=1)u[a].animation.setSpeed(t,e)}function r(t,e){var a;for(a=0;v>a;a+=1)u[a].animation.setDirection(t,e)}function i(t){var e;for(e=0;v>e;e+=1)u[e].animation.play(t)}function s(t,e){g=!1,y=Date.now();var a;for(a=0;v>a;a+=1)u[a].animation.moveFrame(t,e)}function n(){var t,e=Date.now(),a=e-y;for(t=0;v>t;t+=1)u[t].animation.advanceTime(a);y=e,requestAnimationFrame(n)}function o(t){var e;for(e=0;v>e;e+=1)u[e].animation.pause(t)}function h(t,e,a){var r;for(r=0;v>r;r+=1)u[r].animation.goToAndStop(t,e,a)}function l(t){var e;for(e=0;v>e;e+=1)u[e].animation.stop(t)}function p(t){var e;for(e=0;v>e;e+=1)u[e].animation.togglePause(t)}function m(){var e=document.getElementsByClassName("bodymovin");Array.prototype.forEach.call(e,t)}function d(){var t;for(t=0;v>t;t+=1)u[t].animation.resize()}function c(){y=Date.now(),requestAnimationFrame(n)}var f={},u=[],y=0,g=!0,v=0;return setTimeout(c,0),f.registerAnimation=t,f.loadAnimation=e,f.setSpeed=a,f.setDirection=r,f.play=i,f.moveFrame=s,f.pause=o,f.stop=l,f.togglePause=p,f.searchAnimations=m,f.resize=d,f.start=c,f.goToAndStop=h,f}(),AnimationItem=function(){this.name="",this.path="",this.isLoaded=!1,this.currentFrame=0,this.currentRawFrame=0,this.totalFrames=0,this.frameRate=0,this.frameMult=0,this.playSpeed=1,this.playDirection=1,this.pendingElements=0,this.playCount=0,this.prerenderFramesFlag=!0,this.repeat="indefinite",this.animationData={},this.layers=[],this.assets=[],this.isPaused=!0,this.isScrolling=!1,this.autoplay=!1,this.loop=!0,this.renderer=null,this.animationID=randomString(10),this.renderedFrameCount=0,this.scaleMode="fit",this.math=Math};AnimationItem.prototype.setParams=function(t){var e=this;t.context&&(this.context=t.context),t.wrapper&&(this.wrapper=t.wrapper);var a=t.animType?t.animType:"canvas";switch(a){case"canvas":this.renderer=new CanvasRenderer(this,t.renderer);break;case"svg":this.renderer=new SVGRenderer(this,t.renderer)}if(this.animType=a,""===t.loop||null===t.loop||(this.loop=t.loop===!1?!1:t.loop===!0?!0:parseInt(t.loop)),this.autoplay="autoplay"in t?t.autoplay:!0,this.name=t.name?t.name:"",this.prerenderFramesFlag="prerender"in t?t.prerender:!0,t.animationData)e.configAnimation(t.animationData);else if(t.path){"json"!=t.path.substr(-4)&&("/"!=t.path.substr(-1,1)&&(t.path+="/"),t.path+="data.json");var r=new XMLHttpRequest;this.path=t.path.substr(0,t.path.lastIndexOf("/")+1),r.open("GET",t.path,!0),r.send(),r.onreadystatechange=function(){if(4==r.readyState)if(200==r.status)e.configAnimation(JSON.parse(r.responseText));else try{var t=JSON.parse(r.responseText);e.configAnimation(t)}catch(a){}}}},AnimationItem.prototype.setData=function(t){var e={wrapper:t},a=t.attributes;e.path=a.getNamedItem("data-animation-path")?a.getNamedItem("data-animation-path").value:a.getNamedItem("data-bm-path")?a.getNamedItem("data-bm-path").value:a.getNamedItem("bm-path")?a.getNamedItem("bm-path").value:"",e.animType=a.getNamedItem("data-anim-type")?a.getNamedItem("data-anim-type").value:a.getNamedItem("data-bm-type")?a.getNamedItem("data-bm-type").value:a.getNamedItem("bm-type")?a.getNamedItem("bm-type").value:"canvas";var r=a.getNamedItem("data-anim-loop")?a.getNamedItem("data-anim-loop").value:a.getNamedItem("data-bm-loop")?a.getNamedItem("data-bm-loop").value:a.getNamedItem("bm-loop")?a.getNamedItem("bm-loop").value:"";""===r||(e.loop="false"===r?!1:"true"===r?!0:parseInt(r)),e.name=a.getNamedItem("data-name")?a.getNamedItem("data-name").value:a.getNamedItem("data-bm-name")?a.getNamedItem("data-bm-name").value:a.getNamedItem("bm-name")?a.getNamedItem("bm-name").value:"";var i=a.getNamedItem("data-anim-prerender")?a.getNamedItem("data-anim-prerender").value:a.getNamedItem("data-bm-prerender")?a.getNamedItem("data-bm-prerender").value:a.getNamedItem("bm-prerender")?a.getNamedItem("bm-prerender").value:"";"false"===i&&(e.prerender=!1),this.setParams(e)},AnimationItem.prototype.configAnimation=function(t){this.renderer.configAnimation(t),this.animationData=t,this.animationData._id=this.animationID,this.animationData._animType=this.animType,this.layers=this.animationData.animation.layers,this.assets=this.animationData.assets,this.totalFrames=this.animationData.animation.totalFrames,this.frameRate=this.animationData.animation.frameRate,this.firstFrame=Math.round(this.animationData.animation.ff*this.frameRate),this.frameMult=this.animationData.animation.frameRate/1e3,dataManager.completeData(this.animationData),this.renderer.buildItems(this.animationData.animation.layers),this.updaFrameModifier(),this.checkLoaded()},AnimationItem.prototype.elementLoaded=function(){this.pendingElements--,this.checkLoaded()},AnimationItem.prototype.checkLoaded=function(){0===this.pendingElements&&(this.renderer.buildStage(this.container,this.layers),this.prerenderFramesFlag?(this.prerenderFrames(0),dataManager.renderFrame(this.animationID,this.currentFrame+this.firstFrame),this.renderer.renderFrame(this.currentFrame+this.firstFrame)):(this.isLoaded=!0,this.gotoFrame(),this.autoplay&&this.play()))},AnimationItem.prototype.prerenderFrames=function(t){t||(t=0),this.renderedFrameCount===Math.floor(this.totalFrames)?(this.isLoaded=!0,this.gotoFrame(),this.autoplay&&this.play()):(dataManager.renderFrame(this.animationID,this.renderedFrameCount+this.firstFrame),this.renderedFrameCount+=1,t>10?setTimeout(this.prerenderFrames.bind(this),0):(t+=1,this.prerenderFrames(t)))},AnimationItem.prototype.resize=function(){this.renderer.updateContainerSize()},AnimationItem.prototype.gotoFrame=function(){this.currentFrame=subframeEnabled?this.math.round(100*this.currentRawFrame)/100:this.math.floor(this.currentRawFrame),this.renderFrame()},AnimationItem.prototype.renderFrame=function(){this.isLoaded!==!1&&(dataManager.renderFrame(this.animationID,this.currentFrame+this.firstFrame),this.renderer.renderFrame(this.currentFrame+this.firstFrame))},AnimationItem.prototype.play=function(t){t&&this.name!=t||this.isPaused===!0&&(this.isPaused=!1)},AnimationItem.prototype.pause=function(t){t&&this.name!=t||this.isPaused===!1&&(this.isPaused=!0)},AnimationItem.prototype.togglePause=function(t){t&&this.name!=t||(this.isPaused===!0?(this.isPaused=!1,this.play()):(this.isPaused=!0,this.pause()))},AnimationItem.prototype.stop=function(t){t&&this.name!=t||(this.isPaused=!0,this.currentFrame=this.currentRawFrame=0,this.playCount=0,this.gotoFrame())},AnimationItem.prototype.goToAndStop=function(t,e,a){a&&this.name!=a||(this.setCurrentRawFrameValue(e?t:t*this.frameModifier),this.isPaused=!0)},AnimationItem.prototype.advanceTime=function(t){this.isPaused!==!0&&this.isScrolling!==!0&&this.isLoaded!==!1&&this.setCurrentRawFrameValue(this.currentRawFrame+t*this.frameModifier)},AnimationItem.prototype.updateAnimation=function(t){this.setCurrentRawFrameValue(this.totalFrames*t)},AnimationItem.prototype.moveFrame=function(t,e){e&&this.name!=e||this.setCurrentRawFrameValue(this.currentRawFrame+t)},AnimationItem.prototype.setCurrentRawFrameValue=function(t){if(this.currentRawFrame=t,this.currentRawFrame>=this.totalFrames){if(this.loop===!1)return this.currentRawFrame=this.totalFrames-1,this.gotoFrame(),void this.pause();if(this.playCount+=1,this.loop!==!0&&this.playCount==this.loop)return this.currentRawFrame=this.totalFrames-1,this.gotoFrame(),void this.pause()}else if(this.currentRawFrame<0)return this.playCount-=1,this.playCount<0&&(this.playCount=0),this.loop===!1?(this.currentRawFrame=0,this.gotoFrame(),void this.pause()):(this.currentRawFrame=this.totalFrames+this.currentRawFrame,void this.gotoFrame());this.currentRawFrame=this.currentRawFrame%this.totalFrames,this.gotoFrame()},AnimationItem.prototype.setSpeed=function(t){this.playSpeed=t,this.updaFrameModifier()},AnimationItem.prototype.setDirection=function(t){this.playDirection=0>t?-1:1,this.updaFrameModifier()},AnimationItem.prototype.updaFrameModifier=function(){this.frameModifier=this.frameMult*this.playSpeed*this.playDirection},AnimationItem.prototype.getPath=function(){return this.path},AnimationItem.prototype.getAssetData=function(t){for(var e=0,a=this.assets.length;a>e;){if(t==this.assets[e].id)return this.assets[e];e+=1}return this.assets},AnimationItem.prototype.getAssets=function(){return this.assets},function(t){function e(t){animationManager.play(t)}function a(t){animationManager.pause(t)}function r(t){animationManager.togglePause(t)}function i(t,e){animationManager.setSpeed(t,e)}function s(t,e){animationManager.setDirection(t,e)}function n(t){animationManager.stop(t)}function o(t){animationManager.moveFrame(t)}function h(){animationManager.searchAnimations()}function l(t){return animationManager.registerAnimation(t)}function p(){animationManager.resize()}function m(){animationManager.start()}function d(t,e,a){animationManager.goToAndStop(t,e,a)}function c(t){subframeEnabled=t}function f(t){return animationManager.loadAnimation(t)}function u(){"complete"===document.readyState&&(clearInterval(g),h())}var y={};y.play=e,y.pause=a,y.togglePause=r,y.setSpeed=i,y.setDirection=s,y.stop=n,y.moveFrame=o,y.searchAnimations=h,y.registerAnimation=l,y.loadAnimation=f,y.setSubframeRendering=c,y.resize=p,y.start=m,y.goToAndStop=d,y.checkReady=u,t.bodymovin=y;var g=setInterval(u,100)}(window);}(window));
\ No newline at end of file
+}s=arguments.length;var i=[];for(a=1;s>a;a+=1)i.push(arguments[a]);l.apply(this.renderer.canvasContext,i)}else l.apply(this.renderer.canvasContext,arguments)},BM_Path2D=t}();var MatrixManager=matrixManagerFunction;!function(){for(var t=0,e=["ms","moz","webkit","o"],a=0;a<e.length&&!window.requestAnimationFrame;++a)window.requestAnimationFrame=window[e[a]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[e[a]+"CancelAnimationFrame"]||window[e[a]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(e,a){var s=(new Date).getTime(),r=Math.max(0,16-(s-t)),i=window.setTimeout(function(){e(s+r)},r);return t=s+r,i}),window.cancelAnimationFrame||(window.cancelAnimationFrame=function(t){clearTimeout(t)})}();var subframeEnabled=!1,cachedColors={},rgbToHex=function(){var t,e,a=[];for(t=0;256>t;t+=1)e=t.toString(16),a[t]=1==e.length?"0"+e:e;return function(t,e,s){return 0>t&&(t=0),0>e&&(e=0),0>s&&(s=0),"#"+a[t]+a[e]+a[s]}}(),fillColorToString=function(){var t=[];return function(e,a){return t[e[0]]||(t[e[0]]=[]),t[e[0]][e[1]]||(t[e[0]][e[1]]=[]),t[e[0]][e[1]][e[2]]||(void 0!==a&&(e[3]=a),t[e[0]][e[1]][e[2]]="rgba("+e.join(",")+")"),t[e[0]][e[1]][e[2]]}}(),bez=bezFunction(),dataManager=dataFunctionManager();SVGRenderer.prototype.buildItems=function(t,e,a){var s,r=0,i=t.length;for(a||(a=this.elements),e||(e=this.animationItem.container),s=i-1;s>=0;s--){if("StillLayer"==t[s].ty)r++,a[s]=this.createImage(t[s],e);else if("PreCompLayer"==t[s].ty){a[s]=this.createComp(t[s],e);var n=[];this.buildItems(t[s].layers,a[s].getDomElement(),n),a[s].setElements(n)}else a[s]="SolidLayer"==t[s].ty?this.createSolid(t[s],e):"ShapeLayer"==t[s].ty?this.createShape(t[s],e):"TextLayer"==t[s].ty?this.createText(t[s],e):this.createBase(t[s],e);t[s].td&&a[s+1].setMatte(a[s].layerId)}},SVGRenderer.prototype.createBase=function(t,e){return new BaseElement(t,e,this.globalData)},SVGRenderer.prototype.createShape=function(t,e){return new IShapeElement(t,e,this.globalData)},SVGRenderer.prototype.createText=function(t,e){return new ITextElement(t,e,this.globalData)},SVGRenderer.prototype.createImage=function(t,e){return new IImageElement(t,e,this.globalData)},SVGRenderer.prototype.createComp=function(t,e){return new ICompElement(t,e,this.globalData)},SVGRenderer.prototype.createSolid=function(t,e){return new ISolidElement(t,e,this.globalData)},SVGRenderer.prototype.configAnimation=function(t){this.animationItem.container=document.createElementNS(svgNS,"svg"),this.animationItem.container.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.animationItem.container.setAttribute("width",t.animation.compWidth),this.animationItem.container.setAttribute("height",t.animation.compHeight),this.animationItem.container.setAttribute("viewBox","0 0 "+t.animation.compWidth+" "+t.animation.compHeight),this.animationItem.container.setAttribute("preserveAspectRatio","xMidYMid meet"),this.animationItem.container.style.width="100%",this.animationItem.container.style.height="100%",this.animationItem.container.style.transformOrigin=this.animationItem.container.style.mozTransformOrigin=this.animationItem.container.style.webkitTransformOrigin=this.animationItem.container.style["-webkit-transform"]="0px 0px 0px",this.animationItem.wrapper.appendChild(this.animationItem.container);var e=document.createElementNS(svgNS,"defs");this.globalData.defs=e,this.animationItem.container.appendChild(e),this.globalData.getAssetData=this.animationItem.getAssetData.bind(this.animationItem),this.globalData.getPath=this.animationItem.getPath.bind(this.animationItem),this.globalData.elementLoaded=this.animationItem.elementLoaded.bind(this.animationItem);var a=document.createElementNS(svgNS,"clipPath"),s=document.createElementNS(svgNS,"rect");s.setAttribute("width",t.animation.compWidth),s.setAttribute("height",t.animation.compHeight),s.setAttribute("x",0),s.setAttribute("y",0);var r="animationMask_"+randomString(10);a.setAttribute("id",r),a.appendChild(s);var i=document.createElementNS(svgNS,"g");i.setAttribute("clip-path","url(#"+r+")"),this.animationItem.container.appendChild(i),e.appendChild(a),this.animationItem.container=i,this.layers=t.animation.layers},SVGRenderer.prototype.buildStage=function(t,e,a){var s,r,i=e.length;for(a||(a=this.elements),s=i-1;s>=0;s--)r=e[s],void 0!==r.parent&&this.buildItemParenting(r,a[s],e,r.parent,a),"PreCompLayer"==r.ty&&this.buildStage(a[s].getComposingElement(),r.layers,a[s].getElements())},SVGRenderer.prototype.buildItemParenting=function(t,e,a,s,r){t.parents||(t.parents=[]);for(var i=0,n=a.length;n>i;)a[i].ind==s&&(e.getHierarchy().push(r[i]),void 0!==a[i].parent&&this.buildItemParenting(t,e,a,a[i].parent,r)),i+=1},SVGRenderer.prototype.destroy=function(){this.animationItem.wrapper.innerHTML="",this.animationItem.container=null,this.globalData.defs=null;var t,e=this.layers.length;for(t=0;e>t;t++)this.elements[t].destroy();this.elements.length=0,this.destroyed=!0},SVGRenderer.prototype.updateContainerSize=function(){},SVGRenderer.prototype.renderFrame=function(t){if(this.lastFrame!=t&&!this.destroyed){this.lastFrame=t,this.globalData.frameNum=t;var e,a=this.layers.length;for(e=0;a>e;e++)this.elements[e].prepareFrame(t-this.layers[e].startTime);for(e=0;a>e;e++)this.elements[e].renderFrame(t-this.layers[e].startTime)}},CanvasRenderer.prototype.buildItems=function(t,e){e||(e=this.elements);var a,s=0,r=t.length;for(a=0;r>a;a++)if("StillLayer"==t[a].ty)s++,e.push(this.createImage(t[a]));else if("PreCompLayer"==t[a].ty){e.push(this.createComp(t[a]));var i=[];this.buildItems(t[a].layers,i),e[e.length-1].setElements(i)}else e.push("SolidLayer"==t[a].ty?this.createSolid(t[a]):"ShapeLayer"==t[a].ty?this.createShape(t[a]):"TextLayer"==t[a].ty?this.createText(t[a]):this.createBase(t[a]))},CanvasRenderer.prototype.createBase=function(t){return new CVBaseElement(t,this.globalData)},CanvasRenderer.prototype.createShape=function(t){return new CVShapeElement(t,this.globalData)},CanvasRenderer.prototype.createText=function(t){return new CVTextElement(t,this.globalData)},CanvasRenderer.prototype.createImage=function(t){return new CVImageElement(t,this.globalData)},CanvasRenderer.prototype.createComp=function(t){return new CVCompElement(t,this.globalData)},CanvasRenderer.prototype.createSolid=function(t){return new CVSolidElement(t,this.globalData)},CanvasRenderer.prototype.ctxTransform=function(t){if(!this.renderConfig.clearCanvas)return void this.canvasContext.transform(t[0],t[1],t[2],t[3],t[4],t[5]);this.contextData.cTr.transform(t[0],t[1],t[2],t[3],t[4],t[5]);var e=this.contextData.cTr.props;this.canvasContext.setTransform(e[0],e[1],e[2],e[3],e[4],e[5])},CanvasRenderer.prototype.ctxOpacity=function(t){return this.renderConfig.clearCanvas?(this.contextData.cO*=0>t?0:t,void(this.canvasContext.globalAlpha=this.contextData.cO)):void(this.canvasContext.globalAlpha*=0>t?0:t)},CanvasRenderer.prototype.reset=function(){return this.renderConfig.clearCanvas?(this.contextData.cArrPos=0,this.contextData.cTr.reset(),void(this.contextData.cO=1)):void this.canvasContext.restore()},CanvasRenderer.prototype.save=function(t){if(!this.renderConfig.clearCanvas)return void this.canvasContext.save();t&&this.canvasContext.save();var e=this.contextData.cTr.props;(null===this.contextData.saved[this.contextData.cArrPos]||void 0===this.contextData.saved[this.contextData.cArrPos])&&(this.contextData.saved[this.contextData.cArrPos]=new Array(6));var a,s=6,r=this.contextData.saved[this.contextData.cArrPos];for(a=0;s>a;a+=1)r[a]=e[a];this.contextData.savedOp[this.contextData.cArrPos]=this.contextData.cO,this.contextData.cArrPos+=1},CanvasRenderer.prototype.restore=function(t){if(!this.renderConfig.clearCanvas)return void this.canvasContext.restore();t&&this.canvasContext.restore(),this.contextData.cArrPos-=1;var e,a=this.contextData.saved[this.contextData.cArrPos],s=6,r=this.contextData.cTr.props;for(e=0;s>e;e+=1)r[e]=a[e];this.canvasContext.setTransform(a[0],a[1],a[2],a[3],a[4],a[5]),a=this.contextData.savedOp[this.contextData.cArrPos],this.contextData.cO=a,this.canvasContext.globalAlpha=a},CanvasRenderer.prototype.configAnimation=function(t){this.animationItem.wrapper?(this.animationItem.container=document.createElement("canvas"),this.animationItem.container.style.width="100%",this.animationItem.container.style.height="100%",this.animationItem.container.style.transformOrigin=this.animationItem.container.style.mozTransformOrigin=this.animationItem.container.style.webkitTransformOrigin=this.animationItem.container.style["-webkit-transform"]="0px 0px 0px",this.animationItem.wrapper.appendChild(this.animationItem.container),this.canvasContext=this.animationItem.container.getContext("2d")):this.canvasContext=this.renderConfig.context,this.globalData.canvasContext=this.canvasContext,this.globalData.bmCtx=new BM_CanvasRenderingContext2D(this),this.globalData.renderer=this,this.globalData.totalFrames=Math.floor(t.animation.totalFrames),this.globalData.compWidth=t.animation.compWidth,this.globalData.compHeight=t.animation.compHeight,this.layers=t.animation.layers,this.transformCanvas={},this.transformCanvas.w=t.animation.compWidth,this.transformCanvas.h=t.animation.compHeight,this.updateContainerSize()},CanvasRenderer.prototype.updateContainerSize=function(){var t,e;if(this.animationItem.wrapper&&this.animationItem.container?(t=this.animationItem.wrapper.offsetWidth,e=this.animationItem.wrapper.offsetHeight,this.animationItem.container.setAttribute("width",t),this.animationItem.container.setAttribute("height",e)):(t=this.canvasContext.canvas.width,e=this.canvasContext.canvas.height),"fit"==this.renderConfig.scaleMode){var a=t/e,s=this.transformCanvas.w/this.transformCanvas.h;s>a?(this.transformCanvas.sx=t/this.transformCanvas.w,this.transformCanvas.sy=t/this.transformCanvas.w,this.transformCanvas.tx=0,this.transformCanvas.ty=(e-this.transformCanvas.h*(t/this.transformCanvas.w))/2):(this.transformCanvas.sx=e/this.transformCanvas.h,this.transformCanvas.sy=e/this.transformCanvas.h,this.transformCanvas.tx=(t-this.transformCanvas.w*(e/this.transformCanvas.h))/2,this.transformCanvas.ty=0)}else this.transformCanvas.sx=1,this.transformCanvas.sy=1,this.transformCanvas.tx=0,this.transformCanvas.ty=0;this.transformCanvas.props=[this.transformCanvas.sx,0,0,this.transformCanvas.sy,this.transformCanvas.tx,this.transformCanvas.ty],this.clipper=new BM_Path2D,this.clipper.rect(0,0,this.transformCanvas.w,this.transformCanvas.h)},CanvasRenderer.prototype.buildStage=function(t,e,a){a||(a=this.elements);var s,r,i=e.length;for(s=i-1;s>=0;s--)r=e[s],void 0!==r.parent&&this.buildItemHierarchy(r,a[s],e,r.parent,a),"PreCompLayer"==r.ty&&this.buildStage(null,r.layers,a[s].getElements())},CanvasRenderer.prototype.buildItemHierarchy=function(t,e,a,s,r){for(var i=0,n=a.length;n>i;)a[i].ind===s&&(e.getHierarchy().push(r[i]),void 0!==a[i].parent&&this.buildItemHierarchy(t,e,a,a[i].parent,r)),i+=1},CanvasRenderer.prototype.prepareFrame=function(t){if(!this.destroyed){var e,a=this.elements.length;for(e=0;a>e;e++)this.elements[e].prepareFrame(t-this.layers[e].startTime)}},CanvasRenderer.prototype.draw=function(){var t,e=this.layers.length;for(t=e-1;t>=0;t-=1)this.elements[t].draw()},CanvasRenderer.prototype.destroy=function(){this.renderConfig.clearCanvas&&(this.animationItem.wrapper.innerHTML="");var t,e=this.layers.length;for(t=e-1;t>=0;t-=1)this.elements[t].destroy();this.elements.length=0,this.globalData.bmCtx=null,this.globalData.canvasContext=null,this.animationItem.container=null,this.destroyed=!0},CanvasRenderer.prototype.renderFrame=function(t){this.lastFrame==t&&this.renderConfig.clearCanvas===!0||this.destroyed||(this.lastFrame=t,this.globalData.frameNum=t-this.animationItem.firstFrame,this.renderConfig.clearCanvas===!0?(this.reset(),this.canvasContext.canvas.width=this.canvasContext.canvas.width):this.save(),this.ctxTransform(this.transformCanvas.props),this.globalData.bmCtx.clip(this.clipper),this.prepareFrame(t),this.draw(),this.renderConfig.clearCanvas!==!0&&this.restore())},MaskElement.prototype.init=function(){this.masksProperties=this.data.masksProperties;var t=this.element.maskedElement,e=this.globalData.defs,a=0,s=this.masksProperties.length;this.layerSize=this.element.getLayerSize();var r,i,n,o,h=this.data.masksProperties,l=0,p=[],m=randomString(10);for(this.maskElement=document.createElementNS(svgNS,"mask"),a=0;s>a;a++)if(h[a].inv&&!this.solidPath&&(this.solidPath=this.createLayerSolidPath()),"s"!=h[a].mode&&"i"!=h[a].mode||0!=l||(o=document.createElementNS(svgNS,"rect"),o.setAttribute("fill","#ffffff"),o.setAttribute("x","0"),o.setAttribute("y","0"),o.setAttribute("width","100%"),o.setAttribute("height","100%"),p.push(o)),!("f"==h[a].mode&&l>0||"n"==h[a].mode))if(l+=1,r=document.createElementNS(svgNS,"path"),h[a].cl?"s"==h[a].mode?r.setAttribute("fill","#000000"):r.setAttribute("fill","#ffffff"):(r.setAttribute("fill","none"),"s"==h[a].mode?r.setAttribute("fill","#000000"):r.setAttribute("fill","#ffffff"),r.setAttribute("stroke-width","1"),r.setAttribute("stroke-miterlimit","10")),r.setAttribute("clip-rule","nonzero"),this.storedData[a]={elem:r,lastPath:""},"i"==h[a].mode){n=p.length;var d=document.createElementNS(svgNS,"g");for(i=0;n>i;i+=1)d.appendChild(p[i]);var c=document.createElementNS(svgNS,"mask");c.setAttribute("mask-type","alpha"),c.setAttribute("id",m+"_"+l),c.appendChild(r),e.appendChild(c),d.setAttribute("mask","url(#"+m+"_"+l+")"),p.length=0,p.push(d)}else p.push(r);for(s=p.length,a=0;s>a;a+=1)this.maskElement.appendChild(p[a]);this.maskElement.setAttribute("id",m),l>0&&t.setAttribute("mask","url(#"+m+")"),e.appendChild(this.maskElement)},MaskElement.prototype.renderFrame=function(t){var e,a=this.data.masksProperties.length,s=0;for(e=0;a>e;e++)"f"==this.data.masksProperties[e].mode&&s>0||"n"==this.data.masksProperties[e].mode||(s+=1,this.drawPath(this.data.masksProperties[e],this.data.masksProperties[e].paths[t].pathNodes,this.storedData[e]))},MaskElement.prototype.processMaskFromEffects=function(t,e){var a,s=this.registeredEffects.length;for(a=0;s>a;a++)this.registeredEffects[a].renderMask(t,e)},MaskElement.prototype.registerEffect=function(t){this.registeredEffects.push(t)},MaskElement.prototype.getMaskelement=function(){return this.maskElement},MaskElement.prototype.createLayerSolidPath=function(){var t="M0,0 ";return t+="h"+this.layerSize.w,t+="v"+this.layerSize.h,t+="h"+-this.layerSize.w,t+="v"+-this.layerSize.h},MaskElement.prototype.drawPath=function(t,e,a){var s,r,i="";if(e.__renderedString)i=e.__renderedString;else{for(r=e.v.length,s=1;r>s;s+=1)1==s&&(i+=" M"+e.v[0][0]+","+e.v[0][1]),i+=" C"+e.o[s-1][0]+","+e.o[s-1][1]+" "+e.i[s][0]+","+e.i[s][1]+" "+e.v[s][0]+","+e.v[s][1];t.cl&&(i+=" 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]),e.__renderedString=i}a.lastPath!==i&&(t.inv?a.elem.setAttribute("d",this.solidPath+i):a.elem.setAttribute("d",i),a.lastPath=i)},MaskElement.prototype.destroy=function(){this.element=null,this.globalData=null,this.maskElement=null,this.data=null,this.paths=null,this.registeredEffects=null,this.masksProperties=null};var BaseElement=function(t,e,a){this.globalData=a,this.data=t,this.ownMatrix=new Matrix,this.finalTransform={mat:new Matrix,op:1},this.matteElement=null,this.renderedFrames=[],this.lastData={},this.parentContainer=e,this.layerId=randomString(10),this.hidden=!1,this.init()};BaseElement.prototype.init=function(){this.createElements(),this.data.hasMask&&this.addMasks(this.data),this.data.eff},BaseElement.prototype.createElements=function(){if(this.data.td){if(3==this.data.td)this.layerElement=document.createElementNS(svgNS,"mask"),this.layerElement.setAttribute("id",this.layerId),this.layerElement.setAttribute("mask-type","luminance"),this.globalData.defs.appendChild(this.layerElement);else if(2==this.data.td){var t=document.createElementNS(svgNS,"mask");t.setAttribute("id",this.layerId),t.setAttribute("mask-type","alpha");var e=document.createElementNS(svgNS,"g");t.appendChild(e),this.layerElement=document.createElementNS(svgNS,"g");var a=document.createElementNS(svgNS,"filter"),s=randomString(10);a.setAttribute("id",s),a.setAttribute("filterUnits","objectBoundingBox"),a.setAttribute("x","0%"),a.setAttribute("y","0%"),a.setAttribute("width","100%"),a.setAttribute("height","100%");var r=document.createElementNS(svgNS,"feComponentTransfer");r.setAttribute("in","SourceGraphic"),a.appendChild(r);var i=document.createElementNS(svgNS,"feFuncA");i.setAttribute("type","table"),i.setAttribute("tableValues","1.0 0.0"),r.appendChild(i),this.globalData.defs.appendChild(a);var n=document.createElementNS(svgNS,"rect");n.setAttribute("width","100%"),n.setAttribute("height","100%"),n.setAttribute("x","0"),n.setAttribute("y","0"),n.setAttribute("fill","#ffffff"),n.setAttribute("opacity","0"),e.setAttribute("filter","url(#"+s+")"),e.appendChild(n),e.appendChild(this.layerElement),this.globalData.defs.appendChild(t)}else{this.layerElement=document.createElementNS(svgNS,"g");var o=document.createElementNS(svgNS,"mask");o.setAttribute("id",this.layerId),o.setAttribute("mask-type","alpha"),o.appendChild(this.layerElement),this.globalData.defs.appendChild(o)}this.data.hasMask&&(this.maskedElement=this.layerElement)}else this.data.hasMask?(this.layerElement=document.createElementNS(svgNS,"g"),this.data.tt?(this.matteElement=document.createElementNS(svgNS,"g"),this.matteElement.appendChild(this.layerElement),this.parentContainer.appendChild(this.matteElement)):this.parentContainer.appendChild(this.layerElement),this.maskedElement=this.layerElement):this.data.tt?(this.matteElement=document.createElementNS(svgNS,"g"),this.matteElement.setAttribute("id",this.layerId),this.parentContainer.appendChild(this.matteElement),this.layerElement=this.matteElement):this.layerElement=this.parentContainer},BaseElement.prototype.prepareFrame=function(t){this.currentAnimData=this.data.renderedData[t].an;var e=this.currentAnimData.matrixArray;this.ownMatrix.reset().transform(e[0],e[1],e[2],e[3],e[4],e[5]).translate(-this.currentAnimData.tr.a[0],-this.currentAnimData.tr.a[1])},BaseElement.prototype.renderFrame=function(t,e){if("NullLayer"!=this.data.ty){if(this.data.inPoint-this.data.startTime<=t&&this.data.outPoint-this.data.startTime>t?(this.isVisible!==!0&&(this.isVisible=!0),this.finalTransform.opacity=1):(this.isVisible!==!1&&(this.isVisible=!1),this.finalTransform.opacity=0),this.data.eff,t===this.data.renderedFrame.num)return this.isVisible;this.data.hasMask&&this.maskManager.renderFrame(t),this.finalTransform.opacity*=this.currentAnimData.tr.o;var a,s=this.finalTransform.mat;if(e&&(a=e.mat.props,s.reset().transform(a[0],a[1],a[2],a[3],a[4],a[5]),this.finalTransform.opacity*=e.opacity),this.hierarchy){var r,i=this.hierarchy.length;for(e||s.reset(),r=i-1;r>=0;r-=1)a=this.hierarchy[r].ownMatrix.props,s.transform(a[0],a[1],a[2],a[3],a[4],a[5]);a=this.ownMatrix.props,s.transform(a[0],a[1],a[2],a[3],a[4],a[5])}else this.isVisible&&(e?(a=this.ownMatrix.props,s.transform(a[0],a[1],a[2],a[3],a[4],a[5])):(this.finalTransform.mat.props[0]=this.ownMatrix.props[0],this.finalTransform.mat.props[1]=this.ownMatrix.props[1],this.finalTransform.mat.props[2]=this.ownMatrix.props[2],this.finalTransform.mat.props[3]=this.ownMatrix.props[3],this.finalTransform.mat.props[4]=this.ownMatrix.props[4],this.finalTransform.mat.props[5]=this.ownMatrix.props[5]));if(this.data.hasMask){this.renderedFrames[this.globalData.frameNum]||(this.renderedFrames[this.globalData.frameNum]={tr:"matrix("+s.props.join(",")+")",o:this.finalTransform.opacity});var n=this.renderedFrames[this.globalData.frameNum];this.lastData.tr!=n.tr&&(this.lastData.tr=n.tr,this.layerElement.setAttribute("transform",n.tr)),this.lastData.o!==n.o&&(this.lastData.o=n.o,this.layerElement.setAttribute("opacity",n.o))}return this.isVisible}},BaseElement.prototype.destroy=function(){this.layerElement=null,this.parentContainer=null,this.matteElement&&(this.matteElement=null),this.maskManager&&this.maskManager.destroy()},BaseElement.prototype.getDomElement=function(){return this.layerElement},BaseElement.prototype.getMaskManager=function(){return this.maskManager},BaseElement.prototype.addMasks=function(t){this.maskManager=new MaskElement(t,this,this.globalData),this.maskManager.init()},BaseElement.prototype.createEffectsManager=function(t){var e={effects:{value:t.eff},element:{value:this}};this.effectsManager=createElement(EffectsManager,null,e)},BaseElement.prototype.getType=function(){return this.type},BaseElement.prototype.getLayerSize=function(){return"TextLayer"==this.data.ty?{w:this.data.textData.width,h:this.data.textData.height}:{w:this.data.width,h:this.data.height}},BaseElement.prototype.getHierarchy=function(){return this.hierarchy||(this.hierarchy=[]),this.hierarchy},BaseElement.prototype.setMatte=function(t){this.matteElement&&this.matteElement.setAttribute("mask","url(#"+t+")")},BaseElement.prototype.hide=function(){},createElement(BaseElement,ICompElement),ICompElement.prototype.getComposingElement=function(){return this.layerElement},ICompElement.prototype.hide=function(){if(!this.hidden){var t,e=this.elements.length;for(t=0;e>t;t+=1)this.elements[t].hide();this.hidden=!0}},ICompElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);if(a===!1)return void this.hide();this.hidden=!1;var s,r=this.layers.length,i=this.data.tm?this.data.tm[t]<0?0:t>=this.data.tm.length?this.data.tm[this.data.tm.length-1]:this.data.tm[t]:t;for(s=0;r>s;s+=1)this.elements[s].prepareFrame(i-this.layers[s].startTime);for(s=0;r>s;s+=1)this.data.hasMask?this.elements[s].renderFrame(i-this.layers[s].startTime):this.elements[s].renderFrame(i-this.layers[s].startTime,this.finalTransform)},ICompElement.prototype.setElements=function(t){this.elements=t},ICompElement.prototype.getElements=function(){return this.elements},ICompElement.prototype.destroy=function(){this.parent.destroy.call();var t,e=this.layers.length;for(t=0;e>t;t+=1)this.elements[t].destroy()},createElement(BaseElement,IImageElement),IImageElement.prototype.createElements=function(){var t=this,e=function(){t.image.setAttributeNS("http://www.w3.org/1999/xlink","href",t.path+t.assetData.p),t.maskedElement=t.image},a=new Image;a.addEventListener("load",e,!1),a.addEventListener("error",e,!1),a.src=this.path+this.assetData.p,this.parent.createElements.call(this),this.image=document.createElementNS(svgNS,"image"),this.image.setAttribute("width",this.assetData.w+"px"),this.image.setAttribute("height",this.assetData.h+"px"),this.layerElement.appendChild(this.image)},IImageElement.prototype.hide=function(){this.hidden||(this.image.setAttribute("opacity","0"),this.hidden=!0)},IImageElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);if(a===!1)return void this.hide();if(this.hidden&&(this.lastData.o=-1,this.hidden=!1,this.image.setAttribute("opacity","1")),!this.data.hasMask){this.renderedFrames[this.globalData.frameNum]||(this.renderedFrames[this.globalData.frameNum]={tr:"matrix("+this.finalTransform.mat.props.join(",")+")",o:this.finalTransform.opacity});var s=this.renderedFrames[this.globalData.frameNum];this.lastData.tr!=s.tr&&(this.lastData.tr=s.tr,this.image.setAttribute("transform",s.tr)),this.lastData.o!==s.o&&(this.lastData.o=s.o,this.image.setAttribute("opacity",s.o))}},IImageElement.prototype.destroy=function(){this.parent.destroy.call(),this.image=null},createElement(BaseElement,IShapeElement),IShapeElement.prototype.createElements=function(){this.parent.createElements.call(this),this.mainShape=new ShapeItemElement(this.data.shapes,this.layerElement,this.globalData)},IShapeElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);return a===!1?void this.hide():void this.renderShapes(t)},IShapeElement.prototype.hide=function(){this.hidden||(this.mainShape.hideShape(),this.hidden=!0)},IShapeElement.prototype.renderShapes=function(t){this.hidden=!1,this.data.hasMask?this.mainShape.renderShape(t,{opacity:1,mat:new Matrix}):this.mainShape.renderShape(t,this.finalTransform)},IShapeElement.prototype.destroy=function(){this.parent.destroy.call(),this.mainShape.destroy()},ShapeItemElement.prototype.searchShapes=function(t,e){var a,s,r,i=t.length-1,n=[];for(a=i;a>=0;a-=1)if("fl"==t[a].ty||"st"==t[a].ty){e[a]={renderedFrames:[],lastData:{c:"",o:-1,w:""}};var o=document.createElementNS(svgNS,"path");this.shape.appendChild(o),this.stylesList.push({pathElement:o,type:t[a].ty,d:""}),e[a].style=this.stylesList[this.stylesList.length-1],n.push(e[a].style)}else if("gr"==t[a].ty)e[a]={it:[]},this.searchShapes(t[a].it,e[a].it);else if("tr"==t[a].ty)e[a]={transform:{mat:new Matrix,opacity:1}};else if("sh"==t[a].ty||"rc"==t[a].ty||"el"==t[a].ty)for(e[a]={elements:[],renderedFrames:[],styles:[],lastData:{d:"",o:"",tr:""}},r=this.stylesList.length,s=0;r>s;s+=1)this.stylesList[s].closed||(e[a].styles.push(this.stylesList[s]),"st"==this.stylesList[s].type&&(this.stylesList[s].pathElement.setAttribute("fill-opacity",0),this.stylesList[s].pathElement.setAttribute("stroke-linejoin","round"),this.stylesList[s].pathElement.setAttribute("stroke-linecap","round")));for(i=n.length,a=0;i>a;a+=1)n[a].closed=!0},ShapeItemElement.prototype.getElement=function(){return this.shape},ShapeItemElement.prototype.hideShape=function(){var t,e=this.stylesList.length;for(t=e-1;t>=0;t-=1)this.stylesList[t].pathElement.setAttribute("d","M 0,0")},ShapeItemElement.prototype.renderShape=function(t,e,a,s){var r,i;if(!a)for(a=this.data,i=this.stylesList.length,r=0;i>r;r+=1)this.stylesList[r].d="";s||(s=this.viewData),this.frameNum=t,i=a.length-1;var n,o;for(n=e,r=i;r>=0;r-=1)if("tr"==a[r].ty){var h=a[r].renderedData[t].mtArr;if(n=s[r].transform,o=n.mat,o.reset(),e){var l=e.mat.props;n.opacity=e.opacity,n.opacity*=a[r].renderedData[t].o,o.transform(l[0],l[1],l[2],l[3],l[4],l[5])}else n.opacity=a[r].renderedData[t].o;o.transform(h[0],h[1],h[2],h[3],h[4],h[5]).translate(-a[r].renderedData[t].a[0],-a[r].renderedData[t].a[1])}else"sh"==a[r].ty?this.renderPath(a[r],s[r],t,n):"el"==a[r].ty?this.renderPath(a[r],s[r],t,n):"rc"==a[r].ty?a[r].trimmed?this.renderPath(a[r],s[r],t,n):this.renderRect(a[r],s[r],t,n):"fl"==a[r].ty?this.renderFill(a[r],s[r],t,n):"st"==a[r].ty?this.renderStroke(a[r],s[r],t,n):"gr"==a[r].ty?this.renderShape(t,n,a[r].it,s[r].it):"tm"==a[r].ty;for(i=this.stylesList.length,r=0;i>r;r+=1)""==this.stylesList[r].d?this.stylesList[r].pathElement.setAttribute("d","M 0,0"):this.stylesList[r].pathElement.setAttribute("d",this.stylesList[r].d)},ShapeItemElement.prototype.renderPath=function(t,e,a,s){var r,i;if(!e.renderedFrames[this.globalData.frameNum]){var n=t.renderedData[a].path.pathNodes;if(!n.v)return;r=n.v.length;var o=n.s?n.s:[],h="";for(i=1;r>i;i+=1)o[i-1]?h+=" M"+o[i-1][0]+","+o[i-1][1]:1==i&&(h+=" M"+n.v[0][0]+","+n.v[0][1]),h+=" C"+n.o[i-1][0]+","+n.o[i-1][1]+" "+n.i[i][0]+","+n.i[i][1]+" "+n.v[i][0]+","+n.v[i][1];1==r&&(h+=o[0]?" M"+o[0][0]+","+o[0][1]:" M"+n.v[0][0]+","+n.v[0][1]),!t.closed||t.trimmed&&!n.c||(h+=" C"+n.o[i-1][0]+","+n.o[i-1][1]+" "+n.i[0][0]+","+n.i[0][1]+" "+n.v[0][0]+","+n.v[0][1]),e.renderedFrames[this.globalData.frameNum]={dTr:h}}var l=e.renderedFrames[this.globalData.frameNum];for(r=e.styles.length,i=0;r>i;i+=1)e.styles[i].d+=l.dTr},ShapeItemElement.prototype.renderFill=function(t,e,a,s){var r=t.renderedData[a],i=e.style;e.renderedFrames[this.globalData.frameNum]||(e.renderedFrames[this.globalData.frameNum]={c:r.color,o:r.opacity*s.opacity,t:"matrix("+s.mat.props.join(",")+")"});var n=e.renderedFrames[this.globalData.frameNum],o=n.c,h=n.o,l=n.t;e.lastData.c!=o&&i.pathElement.setAttribute("fill",o),e.lastData.o!=h&&i.pathElement.setAttribute("fill-opacity",h),e.lastData.t!=l&&i.pathElement.setAttribute("transform",l),e.lastData.c=o,e.lastData.o=h,e.lastData.t=l},ShapeItemElement.prototype.renderStroke=function(t,e,a,s){var r=t.renderedData[a],i=e.style;e.renderedFrames[this.globalData.frameNum]||(e.renderedFrames[this.globalData.frameNum]={c:r.color,o:r.opacity*s.opacity,w:r.width,t:"matrix("+s.mat.props.join(",")+")"},r.dashes&&(e.renderedFrames[this.globalData.frameNum].d=r.dashes));var n,o,h=e.renderedFrames[this.globalData.frameNum],l=h.c,p=h.o,m=h.w,d=h.d,c=h.t;if(d){var u,f=d.length;for(n="",o="",u=0;f>u;u+=1)"o"!=d[u].n?n+=" "+d[u].v:o+=d[u].v}e.lastData.c!=l&&i.pathElement.setAttribute("stroke",l),e.lastData.o!=p&&i.pathElement.setAttribute("stroke-opacity",p),e.lastData.w!==m&&i.pathElement.setAttribute("stroke-width",m),e.lastData.t!==c&&i.pathElement.setAttribute("transform",c),d&&(e.lastData.da!=n&&i.pathElement.setAttribute("stroke-dasharray",n),e.lastData["do"]!=o&&i.pathElement.setAttribute("stroke-dashoffset",o)),e.lastData.c=l,e.lastData.o=p,e.lastData.w=m,e.lastData.t=c,d&&(e.lastData.da=n,e.lastData["do"]=o)},ShapeItemElement.prototype.destroy=function(t,e){this.shape=null,this.data=null,this.viewData=null},createElement(BaseElement,ISolidElement),ISolidElement.prototype.createElements=function(){this.parent.createElements.call(this);var t=document.createElementNS(svgNS,"rect");t.setAttribute("width",this.data.width),t.setAttribute("height",this.data.height),t.setAttribute("fill",this.data.color),this.layerElement.appendChild(t),this.rectElement=t},ISolidElement.prototype.hide=function(){this.hidden||(this.rectElement.setAttribute("opacity","0"),this.hidden=!0)},ISolidElement.prototype.renderFrame=function(t,e){var a=this.parent.renderFrame.call(this,t,e);if(a===!1)return void this.hide();if(this.hidden&&(this.lastData.o=-1,this.hidden=!1,this.data.hasMask&&this.rectElement.setAttribute("opacity","1")),!this.data.hasMask){this.renderedFrames[this.globalData.frameNum]||(this.renderedFrames[this.globalData.frameNum]={tr:"matrix("+this.finalTransform.mat.props.join(",")+")",o:this.finalTransform.opacity});var s=this.renderedFrames[this.globalData.frameNum];this.lastData.tr!=s.tr&&(this.lastData.tr=s.tr,this.rectElement.setAttribute("transform",s.tr)),this.lastData.o!==s.o&&(this.lastData.o=s.o,this.rectElement.setAttribute("opacity",s.o))}},ICompElement.prototype.destroy=function(){this.parent.destroy.call(),this.rectElement=null},createElement(BaseElement,ITextElement),ITextElement.prototype.createElements=function(){this.parent.createElements.call(this)},CVBaseElement.prototype.init=function(){this.createElements(),this.data.hasMask&&this.addMasks(this.data),this.data.eff},CVBaseElement.prototype.createElements=function(){},CVBaseElement.prototype.prepareFrame=function(t){this.currentAnimData=this.data.renderedData[t].an;var e=this.currentAnimData.matrixArray;return this.ownMatrix.reset().transform(e[0],e[1],e[2],e[3],e[4],e[5]).translate(-this.currentAnimData.tr.a[0],-this.currentAnimData.tr.a[1]),this.data.inPoint-this.data.startTime<=t&&this.data.outPoint-this.data.startTime>=t?(this.renderFrame=!0,this.finalTransform.opacity=1,void(this.data.hasMask&&this.maskManager.prepareFrame(t))):(this.renderFrame=!1,this.finalTransform.opacity=0,!1)},CVBaseElement.prototype.draw=function(t){if("NullLayer"!=this.data.ty){if(!this.renderFrame)return!1;var e,a=(this.canvasContext,this.finalTransform.mat);if(this.finalTransform.opacity*=this.currentAnimData.tr.o,t&&(e=t.mat.props,a.reset().transform(e[0],e[1],e[2],e[3],e[4],e[5]),this.finalTransform.opacity*=t.opacity),this.hierarchy){var s,r=this.hierarchy.length;for(t||a.reset(),s=r-1;s>=0;s-=1)e=this.hierarchy[s].ownMatrix.props,a.transform(e[0],e[1],e[2],e[3],e[4],e[5]);e=this.ownMatrix.props,a.transform(e[0],e[1],e[2],e[3],e[4],e[5])}else this.renderFrame&&(t?(e=this.ownMatrix.props,a.transform(e[0],e[1],e[2],e[3],e[4],e[5])):this.finalTransform.mat=this.ownMatrix);this.data.hasMask&&(this.globalData.renderer.save(!0),this.maskManager.draw(this.finalTransform))}},CVBaseElement.prototype.getCurrentAnimData=function(){return this.currentAnimData},CVBaseElement.prototype.addMasks=function(t){var e={data:{value:t},element:{value:this},globalData:{value:this.globalData
+}};this.maskManager=createElement(CVMaskElement,null,e)},CVBaseElement.prototype.createEffectsManager=function(t){var e={effects:{value:t.eff},element:{value:this}};this.effectsManager=createElement(EffectsManager,null,e)},CVBaseElement.prototype.getType=function(){return this.type},CVBaseElement.prototype.getHierarchy=function(){return this.hierarchy||(this.hierarchy=[]),this.hierarchy},CVBaseElement.prototype.getLayerSize=function(){return"TextLayer"==this.data.ty?{w:this.data.textData.width,h:this.data.textData.height}:{w:this.data.width,h:this.data.height}},CVBaseElement.prototype.destroy=function(){this.canvasContext=null,this.data=null,this.globalData=null,this.maskManager&&this.maskManager.destroy()},createElement(CVBaseElement,CVCompElement),CVCompElement.prototype.prepareFrame=function(t){var e=this.parent.prepareFrame.call(this,t);if(e!==!1){var a,s=this.elements.length,r=this.data.tm?this.data.tm[t]<0?0:t>=this.data.tm.length?this.data.tm[this.data.tm.length-1]:this.data.tm[t]:t;for(a=0;s>a;a+=1)this.elements[a].prepareFrame(r-this.layers[a].startTime)}},CVCompElement.prototype.draw=function(t){if(this.parent.draw.call(this,t)!==!1){var e,a=this.layers.length;for(e=a-1;e>=0;e-=1)this.elements[e].draw(this.finalTransform);this.data.hasMask&&this.globalData.renderer.restore(!0)}},CVCompElement.prototype.setElements=function(t){this.elements=t},CVCompElement.prototype.getElements=function(){return this.elements},CVCompElement.prototype.destroy=function(){var t,e=this.layers.length;for(t=e-1;t>=0;t-=1)this.elements[t].destroy();this.layers=null,this.elements=null,this.parent.destroy.call()},createElement(CVBaseElement,CVImageElement),CVImageElement.prototype.createElements=function(){var t=this,e=function(){t.animationItem.elementLoaded()},a=function(){t.failed=!0,t.animationItem.elementLoaded()};this.img=new Image,this.img.addEventListener("load",e,!1),this.img.addEventListener("error",a,!1),this.img.src=this.path+this.assetData.p,this.parent.createElements.call(this)},CVImageElement.prototype.draw=function(t){if(!this.failed&&this.parent.draw.call(this,t)!==!1){var e=this.canvasContext;this.globalData.renderer.save();var a=this.finalTransform.mat.props;this.globalData.renderer.ctxTransform(a),this.globalData.renderer.ctxOpacity(this.finalTransform.opacity),e.drawImage(this.img,0,0),this.globalData.renderer.restore(this.data.hasMask)}},CVImageElement.prototype.destroy=function(){this.img=null,this.animationItem=null,this.parent.destroy.call()},createElement(CVBaseElement,CVShapeElement),CVShapeElement.prototype.createElements=function(){this.parent.createElements.call(this),this.mainShape=new CVShapeItemElement(this.data.shapes,!0,this.globalData)},CVShapeElement.prototype.prepareFrame=function(t){var e=this.parent.prepareFrame.call(this,t);e!==!1&&this.mainShape.prepareFrame(t)},CVShapeElement.prototype.draw=function(t){this.parent.draw.call(this,t)!==!1&&(this.drawShapes(this.finalTransform),this.data.hasMask&&this.globalData.renderer.restore(!0))},CVShapeElement.prototype.drawShapes=function(t){this.mainShape.renderShape(t)},CVShapeElement.prototype.destroy=function(){this.mainShape.destroy(),this.parent.destroy.call()},CVShapeItemElement.prototype.drawPaths=function(t){var e,a;t?(a=[],e=this.stylesList):e=this.renderedPaths[this.globalData.frameNum];var s,r=e.length,i=this.canvasContext;for(this.globalData.renderer.save(),i.lineCap="round",i.lineJoin="round",s=0;r>s;s+=1)"stroke"==e[s].type?(1!=e[s].opacity&&(this.globalData.renderer.save(),this.globalData.renderer.ctxOpacity(e[s].opacity)),i.strokeStyle=e[s].value,i.lineWidth=e[s].width,e[s].dasharray?(i.setLineDash(e[s].dasharray),i.lineDashOffset=e[s].dashoffset):(i.setLineDash([]),i.lineDashOffset=0),this.globalData.bmCtx.stroke(e[s].path),1!=e[s].opacity&&this.globalData.renderer.restore(),t&&(a.push({type:e[s].type,opacity:e[s].opacity,value:e[s].value,width:e[s].width,path:e[s].path}),e[s].dasharray&&(a[a.length-1].dasharray=e[s].dasharray,a[a.length-1].dashoffset=e[s].dashoffset))):"fill"==e[s].type&&(1!=e[s].opacity&&(this.globalData.renderer.save(),this.globalData.renderer.ctxOpacity(e[s].opacity)),i.fillStyle=e[s].value,this.globalData.bmCtx.fill(e[s].path),1!=e[s].opacity&&this.globalData.renderer.restore(),t&&a.push({type:e[s].type,opacity:e[s].opacity,value:e[s].value,path:e[s].path}));this.globalData.renderer.restore(),t&&(this.renderedPaths[this.globalData.frameNum]=a)},CVShapeItemElement.prototype.prepareFrame=function(t){this.frameNum=t;var e,a=this.dataLength-1;for(e=a;e>=0;e-=1)"gr"==this.data[e].ty&&this.data[e].item.prepareFrame(t)},CVShapeItemElement.prototype.renderShape=function(t,e){if(this.renderedPaths[this.globalData.frameNum])return void this.drawPaths(!1);this.transform.opacity=1;var a,s;for(this.ownStylesList.length=0,this.currentStylePoolPos=0,e?this.stylesList=e:this.stylesList.length=0,t?(this.transform.mat.props[0]=t.mat.props[0],this.transform.mat.props[1]=t.mat.props[1],this.transform.mat.props[2]=t.mat.props[2],this.transform.mat.props[3]=t.mat.props[3],this.transform.mat.props[4]=t.mat.props[4],this.transform.mat.props[5]=t.mat.props[5],this.transform.opacity*=t.opacity):(this.transform.mat.props[0]=this.transform.mat.props[3]=1,this.transform.mat.props[1]=this.transform.mat.props[2]=this.transform.mat.props[4]=this.transform.mat.props[5]=0),s=this.dataLength-1,a=s;a>=0;a-=1)"gr"==this.data[a].ty?this.data[a].item.renderShape(this.transform,this.stylesList):"tr"==this.data[a].ty?this.renderTransform(this.data[a]):"sh"==this.data[a].ty?this.renderPath(this.data[a]):"el"==this.data[a].ty?this.renderEllipse(this.data[a]):"rc"==this.data[a].ty?this.data[a].trimmed?this.renderPath(this.data[a]):this.renderRect(this.data[a]):"fl"==this.data[a].ty?this.renderFill(this.data[a]):"st"==this.data[a].ty&&this.renderStroke(this.data[a]);if(this.mainFlag)this.drawPaths(!0);else for(s=this.ownStylesList.length,a=0;s>a;a+=1)this.ownStylesList[a].closed=!0},CVShapeItemElement.prototype.renderTransform=function(t){var e=t.renderedData[this.frameNum],a=e.mtArr;this.transform.mat.transform(a[0],a[1],a[2],a[3],a[4],a[5]).translate(-e.a[0],-e.a[1]),this.transform.opacity*=e.o},CVShapeItemElement.prototype.renderPath=function(t){if(t.trimmed){var e=this.canvasContext;e.lineCap="round",e.lineJoin="round"}var a=t.renderedData[this.frameNum].path,s=new BM_Path2D,r=a.pathNodes;if(r instanceof Array&&(r=r[0]),r.v){var i,n=r.v.length,o=r.s?r.s:[];for(i=1;n>i;i+=1)o[i-1]?s.moveTo(o[i-1][0],o[i-1][1]):1==i&&s.moveTo(r.v[0][0],r.v[0][1]),s.bezierCurveTo(r.o[i-1][0],r.o[i-1][1],r.i[i][0],r.i[i][1],r.v[i][0],r.v[i][1]);1==n&&(o[0]?s.moveTo(o[0][0],o[0][1]):s.moveTo(r.v[0][0],r.v[0][1])),!t.closed||t.trimmed&&!r.c||s.bezierCurveTo(r.o[i-1][0],r.o[i-1][1],r.i[0][0],r.i[0][1],r.v[0][0],r.v[0][1]),this.addPathToStyles(s)}},CVShapeItemElement.prototype.renderEllipse=function(t){var e=new BM_Path2D,a=t.renderedData[this.frameNum];e.moveTo(a.p[0]+a.size[0]/2,a.p[1]),e.ellipse(a.p[0],a.p[1],a.size[0]/2,a.size[1]/2,0,0,2*Math.PI,!1),this.addPathToStyles(e)},CVShapeItemElement.prototype.renderRect=function(t){var e=new BM_Path2D,a=t.renderedData[this.frameNum],s=a.roundness;if(0===s)e.rect(a.position[0]-a.size[0]/2,a.position[1]-a.size[1]/2,a.size[0],a.size[1]);else{var r=a.position[0]-a.size[0]/2,i=a.position[1]-a.size[1]/2,n=a.size[0],o=a.size[1];s instanceof Array&&(s=s[0]),s>n/2&&(s=n/2),s>o/2&&(s=o/2),e.moveTo(r+s,i),e.lineTo(r+n-s,i),e.quadraticCurveTo(r+n,i,r+n,i+s),e.lineTo(r+n,i+o-s),e.quadraticCurveTo(r+n,i+o,r+n-s,i+o),e.lineTo(r+s,i+o),e.quadraticCurveTo(r,i+o,r,i+o-s),e.lineTo(r,i+s),e.quadraticCurveTo(r,i,r+s,i)}this.addPathToStyles(e)},CVShapeItemElement.prototype.addPathToStyles=function(t){var e,a=this.stylesList.length,s=!0,r=0;for(e=a-1;e>=0;e-=1)this.stylesList[e].closed||("stroke"==this.stylesList[e].type?(this.stylesList[e].width>r&&this.stylesList[e].path.addPath(t,this.transform.mat.props),1==this.stylesList[e].styleOpacity&&1==this.stylesList[e].opacity&&(r=this.stylesList[e].width)):s&&"fill"==this.stylesList[e].type&&(this.stylesList[e].path.addPath(t,this.transform.mat.props),1==this.stylesList[e].styleOpacity&&1==this.stylesList[e].opacity&&(s=!1)))},CVShapeItemElement.prototype.renderFill=function(t){var e=t.renderedData[this.frameNum];return t.fillEnabled!==!1?(this.stylesPool[this.currentStylePoolPos].path=new BM_Path2D,this.stylesPool[this.currentStylePoolPos].closed=!1,this.stylesPool[this.currentStylePoolPos].styleOpacity=e.opacity<1?e.opacity:1,this.stylesPool[this.currentStylePoolPos].opacity=this.transform.opacity,this.stylesPool[this.currentStylePoolPos].value=e.opacity<1?fillColorToString(e.color,e.opacity):fillColorToString(e.color),this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),void(this.currentStylePoolPos+=1)):(this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),void(this.currentStylePoolPos+=1))},CVShapeItemElement.prototype.renderStroke=function(t){var e=t.renderedData[this.frameNum];if(this.data.strokeEnabled!==!1){if(this.stylesPool[this.currentStylePoolPos].path=new BM_Path2D,this.stylesPool[this.currentStylePoolPos].closed=!1,this.stylesPool[this.currentStylePoolPos].styleOpacity=e.opacity<1?e.opacity:1,this.stylesPool[this.currentStylePoolPos].width=e.width,this.stylesPool[this.currentStylePoolPos].opacity=this.transform.opacity,this.stylesPool[this.currentStylePoolPos].value=e.opacity<1?fillColorToString(e.color,e.opacity):fillColorToString(e.color),e.dashes){var a,s=e.dashes,r=s.length,i=[],n="";for(a=0;r>a;a+=1)"o"!=s[a].n?i.push(s[a].v):n=s[a].v;this.stylesPool[this.currentStylePoolPos].dasharray=i,this.stylesPool[this.currentStylePoolPos].dashoffset=n}return this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),void(this.currentStylePoolPos+=1)}this.stylesList.push(this.stylesPool[this.currentStylePoolPos]),this.ownStylesList.push(this.stylesList[this.stylesList.length-1]),this.currentStylePoolPos+=1},CVShapeItemElement.prototype.destroy=function(){this.data=null,this.globalData=null,this.canvasContext=null},createElement(CVBaseElement,CVSolidElement),CVSolidElement.prototype.draw=function(t){if(this.parent.draw.call(this,t)!==!1){var e=this.canvasContext;this.globalData.renderer.save();var a=this.finalTransform.mat.props;this.globalData.renderer.ctxTransform(a),this.globalData.renderer.ctxOpacity(this.finalTransform.opacity),e.fillStyle=this.data.color,e.fillRect(0,0,this.data.width,this.data.height),this.globalData.renderer.restore(this.data.hasMask)}},createElement(CVBaseElement,CVTextElement),CVTextElement.prototype.createElements=function(){this.parent.createElements.call(this)},CVMaskElement.prototype.init=function(){this.registeredEffects=[],this.masksProperties=this.data.masksProperties,this.totalMasks=this.masksProperties.length,this.ctx=this.element.canvasContext,this.layerSize=this.element.getLayerSize(),this.renderedFrames=new Array(this.globalData.totalFrames+1)},CVMaskElement.prototype.prepareFrame=function(t){this.frameNum=t},CVMaskElement.prototype.draw=function(t){var e;if(this.renderedFrames[this.globalData.frameNum])e=this.renderedFrames[this.globalData.frameNum];else{var a,s=new BM_Path2D,r=this.data.masksProperties.length;for(e=new BM_Path2D,a=0;r>a;a++)this.masksProperties[a].inv&&this.createInvertedMask(s,this.data.masksProperties[a].paths[this.frameNum].pathNodes),this.drawShape(s,this.data.masksProperties[a].paths[this.frameNum].pathNodes);e.addPath(s,t.mat.props),this.renderedFrames[this.globalData.frameNum]=e}this.globalData.bmCtx.clip(e)},CVMaskElement.prototype.drawShape=function(t,e){var a,s=e.v.length;for(t.moveTo(e.v[0][0],e.v[0][1]),a=1;s>a;a++)t.bezierCurveTo(e.o[a-1][0],e.o[a-1][1],e.i[a][0],e.i[a][1],e.v[a][0],e.v[a][1]);t.bezierCurveTo(e.o[a-1][0],e.o[a-1][1],e.i[0][0],e.i[0][1],e.v[0][0],e.v[0][1])},CVMaskElement.prototype.createInvertedMask=function(t){t.moveTo(0,0),t.lineTo(this.globalData.compWidth,0),t.lineTo(this.globalData.compWidth,this.globalData.compHeight),t.lineTo(0,this.globalData.compHeight),t.lineTo(0,0)},CVMaskElement.prototype.destroy=function(){this.ctx=null};var animationManager=function(){function t(t){if(!t)return null;for(var e=0;v>e;){if(f[e].elem==t&&null!==f[e].elem)return f[e].animation;e+=1}var a=new AnimationItem;return a.setData(t),f.push({elem:t,animation:a}),v+=1,a}function e(t){var e=new AnimationItem;return e.setParams(t),f.push({elem:null,animation:e}),v+=1,e}function a(t,e){var a;for(a=0;v>a;a+=1)f[a].animation.setSpeed(t,e)}function s(t,e){var a;for(a=0;v>a;a+=1)f[a].animation.setDirection(t,e)}function r(t){var e;for(e=0;v>e;e+=1)f[e].animation.play(t)}function i(t,e){g=!1,y=Date.now();var a;for(a=0;v>a;a+=1)f[a].animation.moveFrame(t,e)}function n(){var t,e=Date.now(),a=e-y;for(t=0;v>t;t+=1)f[t].animation.renderer.destroyed?(f.splice(t,1),t-=1,v-=1):f[t].animation.advanceTime(a);y=e,requestAnimationFrame(n)}function o(t){var e;for(e=0;v>e;e+=1)f[e].animation.pause(t)}function h(t,e,a){var s;for(s=0;v>s;s+=1)f[s].animation.goToAndStop(t,e,a)}function l(t){var e;for(e=0;v>e;e+=1)f[e].animation.stop(t)}function p(t){var e;for(e=0;v>e;e+=1)f[e].animation.togglePause(t)}function m(){var e=document.getElementsByClassName("bodymovin");Array.prototype.forEach.call(e,t)}function d(){var t;for(t=0;v>t;t+=1)f[t].animation.resize()}function c(){y=Date.now(),requestAnimationFrame(n)}var u={},f=[],y=0,g=!0,v=0;return setTimeout(c,0),u.registerAnimation=t,u.loadAnimation=e,u.setSpeed=a,u.setDirection=s,u.play=r,u.moveFrame=i,u.pause=o,u.stop=l,u.togglePause=p,u.searchAnimations=m,u.resize=d,u.start=c,u.goToAndStop=h,u}(),AnimationItem=function(){this.name="",this.path="",this.isLoaded=!1,this.currentFrame=0,this.currentRawFrame=0,this.totalFrames=0,this.frameRate=0,this.frameMult=0,this.playSpeed=1,this.playDirection=1,this.pendingElements=0,this.playCount=0,this.prerenderFramesFlag=!0,this.repeat="indefinite",this.animationData={},this.layers=[],this.assets=[],this.isPaused=!0,this.isScrolling=!1,this.autoplay=!1,this.loop=!0,this.renderer=null,this.animationID=randomString(10),this.renderedFrameCount=0,this.scaleMode="fit",this.math=Math,this.removed=!1};AnimationItem.prototype.setParams=function(t){var e=this;t.context&&(this.context=t.context),t.wrapper&&(this.wrapper=t.wrapper);var a=t.animType?t.animType:"canvas";switch(a){case"canvas":this.renderer=new CanvasRenderer(this,t.renderer);break;case"svg":this.renderer=new SVGRenderer(this,t.renderer)}if(this.animType=a,""===t.loop||null===t.loop||(this.loop=t.loop===!1?!1:t.loop===!0?!0:parseInt(t.loop)),this.autoplay="autoplay"in t?t.autoplay:!0,this.name=t.name?t.name:"",this.prerenderFramesFlag="prerender"in t?t.prerender:!0,t.animationData)e.configAnimation(t.animationData);else if(t.path){"json"!=t.path.substr(-4)&&("/"!=t.path.substr(-1,1)&&(t.path+="/"),t.path+="data.json");var s=new XMLHttpRequest;this.path=t.path.substr(0,t.path.lastIndexOf("/")+1),s.open("GET",t.path,!0),s.send(),s.onreadystatechange=function(){if(4==s.readyState)if(200==s.status)e.configAnimation(JSON.parse(s.responseText));else try{var t=JSON.parse(s.responseText);e.configAnimation(t)}catch(a){}}}},AnimationItem.prototype.setData=function(t){var e={wrapper:t},a=t.attributes;e.path=a.getNamedItem("data-animation-path")?a.getNamedItem("data-animation-path").value:a.getNamedItem("data-bm-path")?a.getNamedItem("data-bm-path").value:a.getNamedItem("bm-path")?a.getNamedItem("bm-path").value:"",e.animType=a.getNamedItem("data-anim-type")?a.getNamedItem("data-anim-type").value:a.getNamedItem("data-bm-type")?a.getNamedItem("data-bm-type").value:a.getNamedItem("bm-type")?a.getNamedItem("bm-type").value:"canvas";var s=a.getNamedItem("data-anim-loop")?a.getNamedItem("data-anim-loop").value:a.getNamedItem("data-bm-loop")?a.getNamedItem("data-bm-loop").value:a.getNamedItem("bm-loop")?a.getNamedItem("bm-loop").value:"";""===s||(e.loop="false"===s?!1:"true"===s?!0:parseInt(s)),e.name=a.getNamedItem("data-name")?a.getNamedItem("data-name").value:a.getNamedItem("data-bm-name")?a.getNamedItem("data-bm-name").value:a.getNamedItem("bm-name")?a.getNamedItem("bm-name").value:"";var r=a.getNamedItem("data-anim-prerender")?a.getNamedItem("data-anim-prerender").value:a.getNamedItem("data-bm-prerender")?a.getNamedItem("data-bm-prerender").value:a.getNamedItem("bm-prerender")?a.getNamedItem("bm-prerender").value:"";"false"===r&&(e.prerender=!1),this.setParams(e)},AnimationItem.prototype.configAnimation=function(t){this.renderer.configAnimation(t),this.animationData=t,this.animationData._id=this.animationID,this.animationData._animType=this.animType,this.layers=this.animationData.animation.layers,this.assets=this.animationData.assets,this.totalFrames=this.animationData.animation.totalFrames,this.frameRate=this.animationData.animation.frameRate,this.firstFrame=Math.round(this.animationData.animation.ff*this.frameRate),this.frameMult=this.animationData.animation.frameRate/1e3,dataManager.completeData(this.animationData),this.renderer.buildItems(this.animationData.animation.layers),this.updaFrameModifier(),this.checkLoaded()},AnimationItem.prototype.elementLoaded=function(){this.pendingElements--,this.checkLoaded()},AnimationItem.prototype.checkLoaded=function(){0===this.pendingElements&&(this.renderer.buildStage(this.container,this.layers),this.prerenderFramesFlag?(this.prerenderFrames(0),dataManager.renderFrame(this.animationID,this.currentFrame+this.firstFrame),this.renderer.renderFrame(this.currentFrame+this.firstFrame)):(this.isLoaded=!0,this.gotoFrame(),this.autoplay&&this.play()))},AnimationItem.prototype.prerenderFrames=function(t){t||(t=0),this.renderedFrameCount===Math.floor(this.totalFrames)?(this.isLoaded=!0,this.gotoFrame(),this.autoplay&&this.play()):(dataManager.renderFrame(this.animationID,this.renderedFrameCount+this.firstFrame),this.renderedFrameCount+=1,t>10?setTimeout(this.prerenderFrames.bind(this),0):(t+=1,this.prerenderFrames(t)))},AnimationItem.prototype.resize=function(){this.renderer.updateContainerSize()},AnimationItem.prototype.gotoFrame=function(){this.currentFrame=subframeEnabled?this.math.round(100*this.currentRawFrame)/100:this.math.floor(this.currentRawFrame),this.renderFrame()},AnimationItem.prototype.renderFrame=function(){this.isLoaded!==!1&&(dataManager.renderFrame(this.animationID,this.currentFrame+this.firstFrame),this.renderer.renderFrame(this.currentFrame+this.firstFrame))},AnimationItem.prototype.play=function(t){t&&this.name!=t||this.isPaused===!0&&(this.isPaused=!1)},AnimationItem.prototype.pause=function(t){t&&this.name!=t||this.isPaused===!1&&(this.isPaused=!0)},AnimationItem.prototype.togglePause=function(t){t&&this.name!=t||(this.isPaused===!0?(this.isPaused=!1,this.play()):(this.isPaused=!0,this.pause()))},AnimationItem.prototype.stop=function(t){t&&this.name!=t||(this.isPaused=!0,this.currentFrame=this.currentRawFrame=0,this.playCount=0,this.gotoFrame())},AnimationItem.prototype.goToAndStop=function(t,e,a){a&&this.name!=a||(this.setCurrentRawFrameValue(e?t:t*this.frameModifier),this.isPaused=!0)},AnimationItem.prototype.advanceTime=function(t){this.isPaused!==!0&&this.isScrolling!==!0&&this.isLoaded!==!1&&this.setCurrentRawFrameValue(this.currentRawFrame+t*this.frameModifier)},AnimationItem.prototype.updateAnimation=function(t){this.setCurrentRawFrameValue(this.totalFrames*t)},AnimationItem.prototype.moveFrame=function(t,e){e&&this.name!=e||this.setCurrentRawFrameValue(this.currentRawFrame+t)},AnimationItem.prototype.remove=function(t){t&&this.name!=t||this.renderer.destroy()},AnimationItem.prototype.destroy=function(t){t&&this.name!=t||this.renderer.destroy()},AnimationItem.prototype.setCurrentRawFrameValue=function(t){if(this.currentRawFrame=t,this.currentRawFrame>=this.totalFrames){if(this.loop===!1)return this.currentRawFrame=this.totalFrames-1,this.gotoFrame(),void this.pause();if(this.playCount+=1,this.loop!==!0&&this.playCount==this.loop)return this.currentRawFrame=this.totalFrames-1,this.gotoFrame(),void this.pause()}else if(this.currentRawFrame<0)return this.playCount-=1,this.playCount<0&&(this.playCount=0),this.loop===!1?(this.currentRawFrame=0,this.gotoFrame(),void this.pause()):(this.currentRawFrame=this.totalFrames+this.currentRawFrame,void this.gotoFrame());this.currentRawFrame=this.currentRawFrame%this.totalFrames,this.gotoFrame()},AnimationItem.prototype.setSpeed=function(t){this.playSpeed=t,this.updaFrameModifier()},AnimationItem.prototype.setDirection=function(t){this.playDirection=0>t?-1:1,this.updaFrameModifier()},AnimationItem.prototype.updaFrameModifier=function(){this.frameModifier=this.frameMult*this.playSpeed*this.playDirection},AnimationItem.prototype.getPath=function(){return this.path},AnimationItem.prototype.getAssetData=function(t){for(var e=0,a=this.assets.length;a>e;){if(t==this.assets[e].id)return this.assets[e];e+=1}return this.assets},AnimationItem.prototype.getAssets=function(){return this.assets},function(t){function e(t){animationManager.play(t)}function a(t){animationManager.pause(t)}function s(t){animationManager.togglePause(t)}function r(t,e){animationManager.setSpeed(t,e)}function i(t,e){animationManager.setDirection(t,e)}function n(t){animationManager.stop(t)}function o(t){animationManager.moveFrame(t)}function h(){animationManager.searchAnimations()}function l(t){return animationManager.registerAnimation(t)}function p(){animationManager.resize()}function m(){animationManager.start()}function d(t,e,a){animationManager.goToAndStop(t,e,a)}function c(t){subframeEnabled=t}function u(t){return animationManager.loadAnimation(t)}function f(){"complete"===document.readyState&&(clearInterval(g),h())}var y={};y.play=e,y.pause=a,y.togglePause=s,y.setSpeed=r,y.setDirection=i,y.stop=n,y.moveFrame=o,y.searchAnimations=h,y.registerAnimation=l,y.loadAnimation=u,y.setSubframeRendering=c,y.resize=p,y.start=m,y.goToAndStop=d,y.checkReady=f,t.bodymovin=y;var g=setInterval(f,100)}(window);}(window));
\ No newline at end of file