-
Notifications
You must be signed in to change notification settings - Fork 31
/
55816.645ed87d.iframe.bundle.js
1 lines (1 loc) · 240 KB
/
55816.645ed87d.iframe.bundle.js
1
(globalThis.webpackChunkmetamask_crx=globalThis.webpackChunkmetamask_crx||[]).push([[55816],{"./node_modules/lottie-web/build/player/lottie_light.js":function(module,exports,__webpack_require__){var factory;"undefined"!=typeof navigator&&(factory=function(){"use strict";var _count,_length,_maxLength,pool,blendModeEnums,ob,value,locationHref="",_useWebWorker=!1,setLocationHref=function setLocationHref(value){locationHref=value},getLocationHref=function getLocationHref(){return locationHref};function createTag(type){return document.createElement(type)}function extendPrototype(sources,destination){var i,sourcePrototype,len=sources.length;for(i=0;i<len;i+=1)for(var attr in sourcePrototype=sources[i].prototype)Object.prototype.hasOwnProperty.call(sourcePrototype,attr)&&(destination.prototype[attr]=sourcePrototype[attr])}function createProxyFunction(prototype){function ProxyFunction(){}return ProxyFunction.prototype=prototype,ProxyFunction}var audioControllerFactory=function(){function AudioController(audioFactory){this.audios=[],this.audioFactory=audioFactory,this._volume=1,this._isMuted=!1}return AudioController.prototype={addAudio:function addAudio(audio){this.audios.push(audio)},pause:function pause(){var i,len=this.audios.length;for(i=0;i<len;i+=1)this.audios[i].pause()},resume:function resume(){var i,len=this.audios.length;for(i=0;i<len;i+=1)this.audios[i].resume()},setRate:function setRate(rateValue){var i,len=this.audios.length;for(i=0;i<len;i+=1)this.audios[i].setRate(rateValue)},createAudio:function createAudio(assetPath){return this.audioFactory?this.audioFactory(assetPath):window.Howl?new window.Howl({src:[assetPath]}):{isPlaying:!1,play:function play(){this.isPlaying=!0},seek:function seek(){this.isPlaying=!1},playing:function playing(){},rate:function rate(){},setVolume:function setVolume(){}}},setAudioFactory:function setAudioFactory(audioFactory){this.audioFactory=audioFactory},setVolume:function setVolume(value){this._volume=value,this._updateVolume()},mute:function mute(){this._isMuted=!0,this._updateVolume()},unmute:function unmute(){this._isMuted=!1,this._updateVolume()},getVolume:function getVolume(){return this._volume},_updateVolume:function _updateVolume(){var i,len=this.audios.length;for(i=0;i<len;i+=1)this.audios[i].volume(this._volume*(this._isMuted?0:1))}},function(){return new AudioController}}(),createTypedArray=function(){function createRegularArray(type,len){var value,i=0,arr=[];switch(type){case"int16":case"uint8c":value=1;break;default:value=1.1}for(i=0;i<len;i+=1)arr.push(value);return arr}function createTypedArrayFactory(type,len){return"float32"===type?new Float32Array(len):"int16"===type?new Int16Array(len):"uint8c"===type?new Uint8ClampedArray(len):createRegularArray(type,len)}return"function"==typeof Uint8ClampedArray&&"function"==typeof Float32Array?createTypedArrayFactory:createRegularArray}();function createSizedArray(len){return Array.apply(null,{length:len})}function _typeof$3(obj){return(_typeof$3="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function _typeof(obj){return typeof obj}:function _typeof(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj})(obj)}var subframeEnabled=!0,expressionsPlugin=null,idPrefix$1="",isSafari=/^((?!chrome|android).)*safari/i.test(navigator.userAgent),bmPow=Math.pow,bmSqrt=Math.sqrt,bmFloor=Math.floor,bmMin=Math.min,BMMath={};(function(){var i,propertyNames=["abs","acos","acosh","asin","asinh","atan","atanh","atan2","ceil","cbrt","expm1","clz32","cos","cosh","exp","floor","fround","hypot","imul","log","log1p","log2","log10","max","min","pow","random","round","sign","sin","sinh","sqrt","tan","tanh","trunc","E","LN10","LN2","LOG10E","LOG2E","PI","SQRT1_2","SQRT2"],len=propertyNames.length;for(i=0;i<len;i+=1)BMMath[propertyNames[i]]=Math[propertyNames[i]]})(),BMMath.random=Math.random,BMMath.abs=function(val){if("object"===_typeof$3(val)&&val.length){var i,absArr=createSizedArray(val.length),len=val.length;for(i=0;i<len;i+=1)absArr[i]=Math.abs(val[i]);return absArr}return Math.abs(val)};var defaultCurveSegments=150,degToRads=Math.PI/180;function BMEnterFrameEvent(type,currentTime,totalTime,frameMultiplier){this.type=type,this.currentTime=currentTime,this.totalTime=totalTime,this.direction=frameMultiplier<0?-1:1}function BMCompleteEvent(type,frameMultiplier){this.type=type,this.direction=frameMultiplier<0?-1:1}function BMCompleteLoopEvent(type,totalLoops,currentLoop,frameMultiplier){this.type=type,this.currentLoop=currentLoop,this.totalLoops=totalLoops,this.direction=frameMultiplier<0?-1:1}function BMSegmentStartEvent(type,firstFrame,totalFrames){this.type=type,this.firstFrame=firstFrame,this.totalFrames=totalFrames}function BMDestroyEvent(type,target){this.type=type,this.target=target}function BMRenderFrameErrorEvent(nativeError,currentTime){this.type="renderFrameError",this.nativeError=nativeError,this.currentTime=currentTime}function BMConfigErrorEvent(nativeError){this.type="configError",this.nativeError=nativeError}var createElementID=(_count=0,function createID(){return _count+=1,idPrefix$1+"__lottie_element_"+_count});function HSVtoRGB(h,s,v){var r,g,b,i,f,p,q,t;switch(i=Math.floor(6*h),f=6*h-i,p=v*(1-s),q=v*(1-f*s),t=v*(1-(1-f)*s),i%6){case 0:r=v,g=t,b=p;break;case 1:r=q,g=v,b=p;break;case 2:r=p,g=v,b=t;break;case 3:r=p,g=q,b=v;break;case 4:r=t,g=p,b=v;break;case 5:r=v,g=p,b=q}return[r,g,b]}function RGBtoHSV(r,g,b){var h,max=Math.max(r,g,b),min=Math.min(r,g,b),d=max-min;switch(max){case min:h=0;break;case r:h=(g-b+d*(g<b?6:0))/(6*d);break;case g:h=(b-r+2*d)/(6*d);break;case b:h=(r-g+4*d)/(6*d)}return[h,0===max?0:d/max,max/255]}function addSaturationToRGB(color,offset){var hsv=RGBtoHSV(255*color[0],255*color[1],255*color[2]);return hsv[1]+=offset,hsv[1]>1?hsv[1]=1:hsv[1]<=0&&(hsv[1]=0),HSVtoRGB(hsv[0],hsv[1],hsv[2])}function addBrightnessToRGB(color,offset){var hsv=RGBtoHSV(255*color[0],255*color[1],255*color[2]);return hsv[2]+=offset,hsv[2]>1?hsv[2]=1:hsv[2]<0&&(hsv[2]=0),HSVtoRGB(hsv[0],hsv[1],hsv[2])}function addHueToRGB(color,offset){var hsv=RGBtoHSV(255*color[0],255*color[1],255*color[2]);return hsv[0]+=offset/360,hsv[0]>1?hsv[0]-=1:hsv[0]<0&&(hsv[0]+=1),HSVtoRGB(hsv[0],hsv[1],hsv[2])}!function(){var i,hex,colorMap=[];for(i=0;i<256;i+=1)hex=i.toString(16),colorMap[i]=1===hex.length?"0"+hex:hex}();var setSubframeEnabled=function setSubframeEnabled(flag){subframeEnabled=!!flag},setExpressionsPlugin=function setExpressionsPlugin(value){expressionsPlugin=value},getExpressionsPlugin=function getExpressionsPlugin(){return expressionsPlugin},getExpressionInterfaces=function getExpressionInterfaces(){return null},setDefaultCurveSegments=function setDefaultCurveSegments(value){defaultCurveSegments=value},getDefaultCurveSegments=function getDefaultCurveSegments(){return defaultCurveSegments},setIdPrefix=function setIdPrefix(value){idPrefix$1=value};function createNS(type){return document.createElementNS("http://www.w3.org/2000/svg",type)}function _typeof$2(obj){return(_typeof$2="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function _typeof(obj){return typeof obj}:function _typeof(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj})(obj)}var dataManager=function(){var workerFn,workerInstance,_counterId=1,processes=[],workerProxy={onmessage:function onmessage(){},postMessage:function postMessage(path){workerFn({data:path})}},_workerSelf={postMessage:function postMessage(data){workerProxy.onmessage({data:data})}};function createWorker(fn){if(window.Worker&&window.Blob&&_useWebWorker){var blob=new Blob(["var _workerSelf = self; self.onmessage = ",fn.toString()],{type:"text/javascript"});return new Worker(URL.createObjectURL(blob))}return workerFn=fn,workerProxy}function setupWorker(){workerInstance||((workerInstance=createWorker(function workerStart(e){function dataFunctionManager(){function completeLayers(layers,comps){var layerData,i,j,jLen,k,kLen,len=layers.length;for(i=0;i<len;i+=1)if("ks"in(layerData=layers[i])&&!layerData.completed){if(layerData.completed=!0,layerData.hasMask){var maskProps=layerData.masksProperties;for(j=0,jLen=maskProps.length;j<jLen;j+=1)if(maskProps[j].pt.k.i)convertPathsToAbsoluteValues(maskProps[j].pt.k);else for(k=0,kLen=maskProps[j].pt.k.length;k<kLen;k+=1)maskProps[j].pt.k[k].s&&convertPathsToAbsoluteValues(maskProps[j].pt.k[k].s[0]),maskProps[j].pt.k[k].e&&convertPathsToAbsoluteValues(maskProps[j].pt.k[k].e[0])}0===layerData.ty?(layerData.layers=findCompLayers(layerData.refId,comps),completeLayers(layerData.layers,comps)):4===layerData.ty?completeShapes(layerData.shapes):5===layerData.ty&&completeText(layerData)}}function completeChars(chars,assets){if(chars){var i=0,len=chars.length;for(i=0;i<len;i+=1)1===chars[i].t&&(chars[i].data.layers=findCompLayers(chars[i].data.refId,assets),completeLayers(chars[i].data.layers,assets))}}function findComp(id,comps){for(var i=0,len=comps.length;i<len;){if(comps[i].id===id)return comps[i];i+=1}return null}function findCompLayers(id,comps){var comp=findComp(id,comps);return comp?comp.layers.__used?JSON.parse(JSON.stringify(comp.layers)):(comp.layers.__used=!0,comp.layers):null}function completeShapes(arr){var i,j,jLen;for(i=arr.length-1;i>=0;i-=1)if("sh"===arr[i].ty){if(arr[i].ks.k.i)convertPathsToAbsoluteValues(arr[i].ks.k);else for(j=0,jLen=arr[i].ks.k.length;j<jLen;j+=1)arr[i].ks.k[j].s&&convertPathsToAbsoluteValues(arr[i].ks.k[j].s[0]),arr[i].ks.k[j].e&&convertPathsToAbsoluteValues(arr[i].ks.k[j].e[0])}else"gr"===arr[i].ty&&completeShapes(arr[i].it)}function convertPathsToAbsoluteValues(path){var i,len=path.i.length;for(i=0;i<len;i+=1)path.i[i][0]+=path.v[i][0],path.i[i][1]+=path.v[i][1],path.o[i][0]+=path.v[i][0],path.o[i][1]+=path.v[i][1]}function checkVersion(minimum,animVersionString){var animVersion=animVersionString?animVersionString.split("."):[100,100,100];return minimum[0]>animVersion[0]||!(animVersion[0]>minimum[0])&&(minimum[1]>animVersion[1]||!(animVersion[1]>minimum[1])&&(minimum[2]>animVersion[2]||!(animVersion[2]>minimum[2])&&null))}var minimumVersion,checkText=function(){var minimumVersion=[4,4,14];function updateTextLayer(textLayer){var documentData=textLayer.t.d;textLayer.t.d={k:[{s:documentData,t:0}]}}function iterateLayers(layers){var i,len=layers.length;for(i=0;i<len;i+=1)5===layers[i].ty&&updateTextLayer(layers[i])}return function(animationData){if(checkVersion(minimumVersion,animationData.v)&&(iterateLayers(animationData.layers),animationData.assets)){var i,len=animationData.assets.length;for(i=0;i<len;i+=1)animationData.assets[i].layers&&iterateLayers(animationData.assets[i].layers)}}}(),checkChars=(minimumVersion=[4,7,99],function(animationData){if(animationData.chars&&!checkVersion(minimumVersion,animationData.v)){var i,len=animationData.chars.length;for(i=0;i<len;i+=1){var charData=animationData.chars[i];charData.data&&charData.data.shapes&&(completeShapes(charData.data.shapes),charData.data.ip=0,charData.data.op=99999,charData.data.st=0,charData.data.sr=1,charData.data.ks={p:{k:[0,0],a:0},s:{k:[100,100],a:0},a:{k:[0,0],a:0},r:{k:0,a:0},o:{k:100,a:0}},animationData.chars[i].t||(charData.data.shapes.push({ty:"no"}),charData.data.shapes[0].it.push({p:{k:[0,0],a:0},s:{k:[100,100],a:0},a:{k:[0,0],a:0},r:{k:0,a:0},o:{k:100,a:0},sk:{k:0,a:0},sa:{k:0,a:0},ty:"tr"})))}}}),checkPathProperties=function(){var minimumVersion=[5,7,15];function updateTextLayer(textLayer){var pathData=textLayer.t.p;"number"==typeof pathData.a&&(pathData.a={a:0,k:pathData.a}),"number"==typeof pathData.p&&(pathData.p={a:0,k:pathData.p}),"number"==typeof pathData.r&&(pathData.r={a:0,k:pathData.r})}function iterateLayers(layers){var i,len=layers.length;for(i=0;i<len;i+=1)5===layers[i].ty&&updateTextLayer(layers[i])}return function(animationData){if(checkVersion(minimumVersion,animationData.v)&&(iterateLayers(animationData.layers),animationData.assets)){var i,len=animationData.assets.length;for(i=0;i<len;i+=1)animationData.assets[i].layers&&iterateLayers(animationData.assets[i].layers)}}}(),checkColors=function(){var minimumVersion=[4,1,9];function iterateShapes(shapes){var i,j,jLen,len=shapes.length;for(i=0;i<len;i+=1)if("gr"===shapes[i].ty)iterateShapes(shapes[i].it);else if("fl"===shapes[i].ty||"st"===shapes[i].ty){if(shapes[i].c.k&&shapes[i].c.k[0].i)for(j=0,jLen=shapes[i].c.k.length;j<jLen;j+=1)shapes[i].c.k[j].s&&(shapes[i].c.k[j].s[0]/=255,shapes[i].c.k[j].s[1]/=255,shapes[i].c.k[j].s[2]/=255,shapes[i].c.k[j].s[3]/=255),shapes[i].c.k[j].e&&(shapes[i].c.k[j].e[0]/=255,shapes[i].c.k[j].e[1]/=255,shapes[i].c.k[j].e[2]/=255,shapes[i].c.k[j].e[3]/=255);else shapes[i].c.k[0]/=255,shapes[i].c.k[1]/=255,shapes[i].c.k[2]/=255,shapes[i].c.k[3]/=255}}function iterateLayers(layers){var i,len=layers.length;for(i=0;i<len;i+=1)4===layers[i].ty&&iterateShapes(layers[i].shapes)}return function(animationData){if(checkVersion(minimumVersion,animationData.v)&&(iterateLayers(animationData.layers),animationData.assets)){var i,len=animationData.assets.length;for(i=0;i<len;i+=1)animationData.assets[i].layers&&iterateLayers(animationData.assets[i].layers)}}}(),checkShapes=function(){var minimumVersion=[4,4,18];function completeClosingShapes(arr){var i,j,jLen;for(i=arr.length-1;i>=0;i-=1)if("sh"===arr[i].ty){if(arr[i].ks.k.i)arr[i].ks.k.c=arr[i].closed;else for(j=0,jLen=arr[i].ks.k.length;j<jLen;j+=1)arr[i].ks.k[j].s&&(arr[i].ks.k[j].s[0].c=arr[i].closed),arr[i].ks.k[j].e&&(arr[i].ks.k[j].e[0].c=arr[i].closed)}else"gr"===arr[i].ty&&completeClosingShapes(arr[i].it)}function iterateLayers(layers){var layerData,i,j,jLen,k,kLen,len=layers.length;for(i=0;i<len;i+=1){if((layerData=layers[i]).hasMask){var maskProps=layerData.masksProperties;for(j=0,jLen=maskProps.length;j<jLen;j+=1)if(maskProps[j].pt.k.i)maskProps[j].pt.k.c=maskProps[j].cl;else for(k=0,kLen=maskProps[j].pt.k.length;k<kLen;k+=1)maskProps[j].pt.k[k].s&&(maskProps[j].pt.k[k].s[0].c=maskProps[j].cl),maskProps[j].pt.k[k].e&&(maskProps[j].pt.k[k].e[0].c=maskProps[j].cl)}4===layerData.ty&&completeClosingShapes(layerData.shapes)}}return function(animationData){if(checkVersion(minimumVersion,animationData.v)&&(iterateLayers(animationData.layers),animationData.assets)){var i,len=animationData.assets.length;for(i=0;i<len;i+=1)animationData.assets[i].layers&&iterateLayers(animationData.assets[i].layers)}}}();function completeData(animationData){animationData.__complete||(checkColors(animationData),checkText(animationData),checkChars(animationData),checkPathProperties(animationData),checkShapes(animationData),completeLayers(animationData.layers,animationData.assets),completeChars(animationData.chars,animationData.assets),animationData.__complete=!0)}function completeText(data){0===data.t.a.length&&data.t.p}var moduleOb={};return moduleOb.completeData=completeData,moduleOb.checkColors=checkColors,moduleOb.checkChars=checkChars,moduleOb.checkPathProperties=checkPathProperties,moduleOb.checkShapes=checkShapes,moduleOb.completeLayers=completeLayers,moduleOb}if(_workerSelf.dataManager||(_workerSelf.dataManager=dataFunctionManager()),_workerSelf.assetLoader||(_workerSelf.assetLoader=function(){function formatResponse(xhr){var contentTypeHeader=xhr.getResponseHeader("content-type");return contentTypeHeader&&"json"===xhr.responseType&&-1!==contentTypeHeader.indexOf("json")||xhr.response&&"object"===_typeof$2(xhr.response)?xhr.response:xhr.response&&"string"==typeof xhr.response?JSON.parse(xhr.response):xhr.responseText?JSON.parse(xhr.responseText):null}return{load:function loadAsset(path,fullPath,callback,errorCallback){var response,xhr=new XMLHttpRequest;try{xhr.responseType="json"}catch(err){}xhr.onreadystatechange=function(){if(4===xhr.readyState){if(200===xhr.status)callback(response=formatResponse(xhr));else try{response=formatResponse(xhr),callback(response)}catch(err){errorCallback&&errorCallback(err)}}};try{xhr.open("GET",path,!0)}catch(error){xhr.open("GET",fullPath+"/"+path,!0)}xhr.send()}}}()),"loadAnimation"===e.data.type)_workerSelf.assetLoader.load(e.data.path,e.data.fullPath,function(data){_workerSelf.dataManager.completeData(data),_workerSelf.postMessage({id:e.data.id,payload:data,status:"success"})},function(){_workerSelf.postMessage({id:e.data.id,status:"error"})});else if("complete"===e.data.type){var animation=e.data.animation;_workerSelf.dataManager.completeData(animation),_workerSelf.postMessage({id:e.data.id,payload:animation,status:"success"})}else"loadData"===e.data.type&&_workerSelf.assetLoader.load(e.data.path,e.data.fullPath,function(data){_workerSelf.postMessage({id:e.data.id,payload:data,status:"success"})},function(){_workerSelf.postMessage({id:e.data.id,status:"error"})})})).onmessage=function(event){var data=event.data,id=data.id,process=processes[id];processes[id]=null,"success"===data.status?process.onComplete(data.payload):process.onError&&process.onError()})}function createProcess(onComplete,onError){var id="processId_"+(_counterId+=1);return processes[id]={onComplete:onComplete,onError:onError},id}return{loadAnimation:function loadAnimation(path,onComplete,onError){setupWorker();var processId=createProcess(onComplete,onError);workerInstance.postMessage({type:"loadAnimation",path:path,fullPath:window.location.origin+window.location.pathname,id:processId})},loadData:function loadData(path,onComplete,onError){setupWorker();var processId=createProcess(onComplete,onError);workerInstance.postMessage({type:"loadData",path:path,fullPath:window.location.origin+window.location.pathname,id:processId})},completeAnimation:function completeAnimation(anim,onComplete,onError){setupWorker();var processId=createProcess(onComplete,onError);workerInstance.postMessage({type:"complete",animation:anim,id:processId})}}}(),ImagePreloader=function(){var canvas,ctx,proxyImage=((canvas=createTag("canvas")).width=1,canvas.height=1,(ctx=canvas.getContext("2d")).fillStyle="rgba(0,0,0,0)",ctx.fillRect(0,0,1,1),canvas);function imageLoaded(){this.loadedAssets+=1,this.loadedAssets===this.totalImages&&this.loadedFootagesCount===this.totalFootages&&this.imagesLoadedCb&&this.imagesLoadedCb(null)}function footageLoaded(){this.loadedFootagesCount+=1,this.loadedAssets===this.totalImages&&this.loadedFootagesCount===this.totalFootages&&this.imagesLoadedCb&&this.imagesLoadedCb(null)}function getAssetsPath(assetData,assetsPath,originalPath){var path="";if(assetData.e)path=assetData.p;else if(assetsPath){var imagePath=assetData.p;-1!==imagePath.indexOf("images/")&&(imagePath=imagePath.split("/")[1]),path=assetsPath+imagePath}else path=originalPath+(assetData.u?assetData.u:"")+assetData.p;return path}function testImageLoaded(img){var _count=0,intervalId=setInterval((function(){(img.getBBox().width||_count>500)&&(this._imageLoaded(),clearInterval(intervalId)),_count+=1}).bind(this),50)}function createImageData(assetData){var path=getAssetsPath(assetData,this.assetsPath,this.path),img=createNS("image");isSafari?this.testImageLoaded(img):img.addEventListener("load",this._imageLoaded,!1),img.addEventListener("error",(function(){ob.img=proxyImage,this._imageLoaded()}).bind(this),!1),img.setAttributeNS("http://www.w3.org/1999/xlink","href",path),this._elementHelper.append?this._elementHelper.append(img):this._elementHelper.appendChild(img);var ob={img:img,assetData:assetData};return ob}function createImgData(assetData){var path=getAssetsPath(assetData,this.assetsPath,this.path),img=createTag("img");img.crossOrigin="anonymous",img.addEventListener("load",this._imageLoaded,!1),img.addEventListener("error",(function(){ob.img=proxyImage,this._imageLoaded()}).bind(this),!1),img.src=path;var ob={img:img,assetData:assetData};return ob}function createFootageData(data){var ob={assetData:data},path=getAssetsPath(data,this.assetsPath,this.path);return dataManager.loadData(path,(function(footageData){ob.img=footageData,this._footageLoaded()}).bind(this),(function(){ob.img={},this._footageLoaded()}).bind(this)),ob}function loadAssets(assets,cb){this.imagesLoadedCb=cb;var i,len=assets.length;for(i=0;i<len;i+=1)assets[i].layers||(assets[i].t&&"seq"!==assets[i].t?3===assets[i].t&&(this.totalFootages+=1,this.images.push(this.createFootageData(assets[i]))):(this.totalImages+=1,this.images.push(this._createImageData(assets[i]))))}function setPath(path){this.path=path||""}function setAssetsPath(path){this.assetsPath=path||""}function getAsset(assetData){for(var i=0,len=this.images.length;i<len;){if(this.images[i].assetData===assetData)return this.images[i].img;i+=1}return null}function destroy(){this.imagesLoadedCb=null,this.images.length=0}function loadedImages(){return this.totalImages===this.loadedAssets}function loadedFootages(){return this.totalFootages===this.loadedFootagesCount}function setCacheType(type,elementHelper){"svg"===type?(this._elementHelper=elementHelper,this._createImageData=this.createImageData.bind(this)):this._createImageData=this.createImgData.bind(this)}function ImagePreloaderFactory(){this._imageLoaded=imageLoaded.bind(this),this._footageLoaded=footageLoaded.bind(this),this.testImageLoaded=testImageLoaded.bind(this),this.createFootageData=createFootageData.bind(this),this.assetsPath="",this.path="",this.totalImages=0,this.totalFootages=0,this.loadedAssets=0,this.loadedFootagesCount=0,this.imagesLoadedCb=null,this.images=[]}return ImagePreloaderFactory.prototype={loadAssets:loadAssets,setAssetsPath:setAssetsPath,setPath:setPath,loadedImages:loadedImages,loadedFootages:loadedFootages,destroy:destroy,getAsset:getAsset,createImgData:createImgData,createImageData:createImageData,imageLoaded:imageLoaded,footageLoaded:footageLoaded,setCacheType:setCacheType},ImagePreloaderFactory}();function BaseEvent(){}BaseEvent.prototype={triggerEvent:function triggerEvent(eventName,args){if(this._cbs[eventName])for(var callbacks=this._cbs[eventName],i=0;i<callbacks.length;i+=1)callbacks[i](args)},addEventListener:function addEventListener(eventName,callback){return this._cbs[eventName]||(this._cbs[eventName]=[]),this._cbs[eventName].push(callback),(function(){this.removeEventListener(eventName,callback)}).bind(this)},removeEventListener:function removeEventListener(eventName,callback){if(callback){if(this._cbs[eventName]){for(var i=0,len=this._cbs[eventName].length;i<len;)this._cbs[eventName][i]===callback&&(this._cbs[eventName].splice(i,1),i-=1,len-=1),i+=1;this._cbs[eventName].length||(this._cbs[eventName]=null)}}else this._cbs[eventName]=null}};var markerParser=function(){function parsePayloadLines(payload){for(var line,lines=payload.split("\r\n"),keys={},keysCount=0,i=0;i<lines.length;i+=1)2===(line=lines[i].split(":")).length&&(keys[line[0]]=line[1].trim(),keysCount+=1);if(0===keysCount)throw Error();return keys}return function(_markers){for(var markers=[],i=0;i<_markers.length;i+=1){var _marker=_markers[i],markerData={time:_marker.tm,duration:_marker.dr};try{markerData.payload=JSON.parse(_markers[i].cm)}catch(_){try{markerData.payload=parsePayloadLines(_markers[i].cm)}catch(__){markerData.payload={name:_markers[i].cm}}}markers.push(markerData)}return markers}}(),ProjectInterface=function(){function registerComposition(comp){this.compositions.push(comp)}return function(){function _thisProjectFunction(name){for(var i=0,len=this.compositions.length;i<len;){if(this.compositions[i].data&&this.compositions[i].data.nm===name)return this.compositions[i].prepareFrame&&this.compositions[i].data.xt&&this.compositions[i].prepareFrame(this.currentFrame),this.compositions[i].compInterface;i+=1}return null}return _thisProjectFunction.compositions=[],_thisProjectFunction.currentFrame=0,_thisProjectFunction.registerComposition=registerComposition,_thisProjectFunction}}(),renderers={};function getRenderer(key){return renderers[key]}function getRegisteredRenderer(){if(renderers.canvas)return"canvas";for(var key in renderers)if(renderers[key])return key;return""}function _typeof$1(obj){return(_typeof$1="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function _typeof(obj){return typeof obj}:function _typeof(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj})(obj)}var AnimationItem=function AnimationItem(){this._cbs=[],this.name="",this.path="",this.isLoaded=!1,this.currentFrame=0,this.currentRawFrame=0,this.firstFrame=0,this.totalFrames=0,this.frameRate=0,this.frameMult=0,this.playSpeed=1,this.playDirection=1,this.playCount=0,this.animationData={},this.assets=[],this.isPaused=!0,this.autoplay=!1,this.loop=!0,this.renderer=null,this.animationID=createElementID(),this.assetsPath="",this.timeCompleted=0,this.segmentPos=0,this.isSubframeEnabled=subframeEnabled,this.segments=[],this._idle=!0,this._completedLoop=!1,this.projectInterface=ProjectInterface(),this.imagePreloader=new ImagePreloader,this.audioController=audioControllerFactory(),this.markers=[],this.configAnimation=this.configAnimation.bind(this),this.onSetupError=this.onSetupError.bind(this),this.onSegmentComplete=this.onSegmentComplete.bind(this),this.drawnFrameEvent=new BMEnterFrameEvent("drawnFrame",0,0,0),this.expressionsPlugin=getExpressionsPlugin()};extendPrototype([BaseEvent],AnimationItem),AnimationItem.prototype.setParams=function(params){(params.wrapper||params.container)&&(this.wrapper=params.wrapper||params.container);var animType="svg";params.animType?animType=params.animType:params.renderer&&(animType=params.renderer);var RendererClass=getRenderer(animType);this.renderer=new RendererClass(this,params.rendererSettings),this.imagePreloader.setCacheType(animType,this.renderer.globalData.defs),this.renderer.setProjectInterface(this.projectInterface),this.animType=animType,""===params.loop||null===params.loop||void 0===params.loop||!0===params.loop?this.loop=!0:!1===params.loop?this.loop=!1:this.loop=parseInt(params.loop,10),this.autoplay=!("autoplay"in params)||params.autoplay,this.name=params.name?params.name:"",this.autoloadSegments=!Object.prototype.hasOwnProperty.call(params,"autoloadSegments")||params.autoloadSegments,this.assetsPath=params.assetsPath,this.initialSegment=params.initialSegment,params.audioFactory&&this.audioController.setAudioFactory(params.audioFactory),params.animationData?this.setupAnimation(params.animationData):params.path&&(-1!==params.path.lastIndexOf("\\")?this.path=params.path.substr(0,params.path.lastIndexOf("\\")+1):this.path=params.path.substr(0,params.path.lastIndexOf("/")+1),this.fileName=params.path.substr(params.path.lastIndexOf("/")+1),this.fileName=this.fileName.substr(0,this.fileName.lastIndexOf(".json")),dataManager.loadAnimation(params.path,this.configAnimation,this.onSetupError))},AnimationItem.prototype.onSetupError=function(){this.trigger("data_failed")},AnimationItem.prototype.setupAnimation=function(data){dataManager.completeAnimation(data,this.configAnimation)},AnimationItem.prototype.setData=function(wrapper,animationData){animationData&&"object"!==_typeof$1(animationData)&&(animationData=JSON.parse(animationData));var params={wrapper:wrapper,animationData:animationData},wrapperAttributes=wrapper.attributes;params.path=wrapperAttributes.getNamedItem("data-animation-path")?wrapperAttributes.getNamedItem("data-animation-path").value:wrapperAttributes.getNamedItem("data-bm-path")?wrapperAttributes.getNamedItem("data-bm-path").value:wrapperAttributes.getNamedItem("bm-path")?wrapperAttributes.getNamedItem("bm-path").value:"",params.animType=wrapperAttributes.getNamedItem("data-anim-type")?wrapperAttributes.getNamedItem("data-anim-type").value:wrapperAttributes.getNamedItem("data-bm-type")?wrapperAttributes.getNamedItem("data-bm-type").value:wrapperAttributes.getNamedItem("bm-type")?wrapperAttributes.getNamedItem("bm-type").value:wrapperAttributes.getNamedItem("data-bm-renderer")?wrapperAttributes.getNamedItem("data-bm-renderer").value:wrapperAttributes.getNamedItem("bm-renderer")?wrapperAttributes.getNamedItem("bm-renderer").value:getRegisteredRenderer()||"canvas";var loop=wrapperAttributes.getNamedItem("data-anim-loop")?wrapperAttributes.getNamedItem("data-anim-loop").value:wrapperAttributes.getNamedItem("data-bm-loop")?wrapperAttributes.getNamedItem("data-bm-loop").value:wrapperAttributes.getNamedItem("bm-loop")?wrapperAttributes.getNamedItem("bm-loop").value:"";"false"===loop?params.loop=!1:"true"===loop?params.loop=!0:""!==loop&&(params.loop=parseInt(loop,10));var autoplay=wrapperAttributes.getNamedItem("data-anim-autoplay")?wrapperAttributes.getNamedItem("data-anim-autoplay").value:wrapperAttributes.getNamedItem("data-bm-autoplay")?wrapperAttributes.getNamedItem("data-bm-autoplay").value:!wrapperAttributes.getNamedItem("bm-autoplay")||wrapperAttributes.getNamedItem("bm-autoplay").value;params.autoplay="false"!==autoplay,params.name=wrapperAttributes.getNamedItem("data-name")?wrapperAttributes.getNamedItem("data-name").value:wrapperAttributes.getNamedItem("data-bm-name")?wrapperAttributes.getNamedItem("data-bm-name").value:wrapperAttributes.getNamedItem("bm-name")?wrapperAttributes.getNamedItem("bm-name").value:"","false"===(wrapperAttributes.getNamedItem("data-anim-prerender")?wrapperAttributes.getNamedItem("data-anim-prerender").value:wrapperAttributes.getNamedItem("data-bm-prerender")?wrapperAttributes.getNamedItem("data-bm-prerender").value:wrapperAttributes.getNamedItem("bm-prerender")?wrapperAttributes.getNamedItem("bm-prerender").value:"")&&(params.prerender=!1),params.path?this.setParams(params):this.trigger("destroy")},AnimationItem.prototype.includeLayers=function(data){data.op>this.animationData.op&&(this.animationData.op=data.op,this.totalFrames=Math.floor(data.op-this.animationData.ip));var i,j,layers=this.animationData.layers,len=layers.length,newLayers=data.layers,jLen=newLayers.length;for(j=0;j<jLen;j+=1)for(i=0;i<len;){if(layers[i].id===newLayers[j].id){layers[i]=newLayers[j];break}i+=1}if((data.chars||data.fonts)&&(this.renderer.globalData.fontManager.addChars(data.chars),this.renderer.globalData.fontManager.addFonts(data.fonts,this.renderer.globalData.defs)),data.assets)for(i=0,len=data.assets.length;i<len;i+=1)this.animationData.assets.push(data.assets[i]);this.animationData.__complete=!1,dataManager.completeAnimation(this.animationData,this.onSegmentComplete)},AnimationItem.prototype.onSegmentComplete=function(data){this.animationData=data;var expressionsPlugin=getExpressionsPlugin();expressionsPlugin&&expressionsPlugin.initExpressions(this),this.loadNextSegment()},AnimationItem.prototype.loadNextSegment=function(){var segments=this.animationData.segments;if(!segments||0===segments.length||!this.autoloadSegments){this.trigger("data_ready"),this.timeCompleted=this.totalFrames;return}var segment=segments.shift();this.timeCompleted=segment.time*this.frameRate;var segmentPath=this.path+this.fileName+"_"+this.segmentPos+".json";this.segmentPos+=1,dataManager.loadData(segmentPath,this.includeLayers.bind(this),(function(){this.trigger("data_failed")}).bind(this))},AnimationItem.prototype.loadSegments=function(){this.animationData.segments||(this.timeCompleted=this.totalFrames),this.loadNextSegment()},AnimationItem.prototype.imagesLoaded=function(){this.trigger("loaded_images"),this.checkLoaded()},AnimationItem.prototype.preloadImages=function(){this.imagePreloader.setAssetsPath(this.assetsPath),this.imagePreloader.setPath(this.path),this.imagePreloader.loadAssets(this.animationData.assets,this.imagesLoaded.bind(this))},AnimationItem.prototype.configAnimation=function(animData){if(this.renderer)try{this.animationData=animData,this.initialSegment?(this.totalFrames=Math.floor(this.initialSegment[1]-this.initialSegment[0]),this.firstFrame=Math.round(this.initialSegment[0])):(this.totalFrames=Math.floor(this.animationData.op-this.animationData.ip),this.firstFrame=Math.round(this.animationData.ip)),this.renderer.configAnimation(animData),animData.assets||(animData.assets=[]),this.assets=this.animationData.assets,this.frameRate=this.animationData.fr,this.frameMult=this.animationData.fr/1e3,this.renderer.searchExtraCompositions(animData.assets),this.markers=markerParser(animData.markers||[]),this.trigger("config_ready"),this.preloadImages(),this.loadSegments(),this.updaFrameModifier(),this.waitForFontsLoaded(),this.isPaused&&this.audioController.pause()}catch(error){this.triggerConfigError(error)}},AnimationItem.prototype.waitForFontsLoaded=function(){this.renderer&&(this.renderer.globalData.fontManager.isLoaded?this.checkLoaded():setTimeout(this.waitForFontsLoaded.bind(this),20))},AnimationItem.prototype.checkLoaded=function(){if(!this.isLoaded&&this.renderer.globalData.fontManager.isLoaded&&(this.imagePreloader.loadedImages()||"canvas"!==this.renderer.rendererType)&&this.imagePreloader.loadedFootages()){this.isLoaded=!0;var expressionsPlugin=getExpressionsPlugin();expressionsPlugin&&expressionsPlugin.initExpressions(this),this.renderer.initItems(),setTimeout((function(){this.trigger("DOMLoaded")}).bind(this),0),this.gotoFrame(),this.autoplay&&this.play()}},AnimationItem.prototype.resize=function(width,height){this.renderer.updateContainerSize("number"==typeof width?width:void 0,"number"==typeof height?height:void 0)},AnimationItem.prototype.setSubframe=function(flag){this.isSubframeEnabled=!!flag},AnimationItem.prototype.gotoFrame=function(){this.currentFrame=this.isSubframeEnabled?this.currentRawFrame:~~this.currentRawFrame,this.timeCompleted!==this.totalFrames&&this.currentFrame>this.timeCompleted&&(this.currentFrame=this.timeCompleted),this.trigger("enterFrame"),this.renderFrame(),this.trigger("drawnFrame")},AnimationItem.prototype.renderFrame=function(){if(!1!==this.isLoaded&&this.renderer)try{this.expressionsPlugin&&this.expressionsPlugin.resetFrame(),this.renderer.renderFrame(this.currentFrame+this.firstFrame)}catch(error){this.triggerRenderFrameError(error)}},AnimationItem.prototype.play=function(name){(!name||this.name===name)&&!0===this.isPaused&&(this.isPaused=!1,this.trigger("_play"),this.audioController.resume(),this._idle&&(this._idle=!1,this.trigger("_active")))},AnimationItem.prototype.pause=function(name){name&&this.name!==name||!1!==this.isPaused||(this.isPaused=!0,this.trigger("_pause"),this._idle=!0,this.trigger("_idle"),this.audioController.pause())},AnimationItem.prototype.togglePause=function(name){name&&this.name!==name||(!0===this.isPaused?this.play():this.pause())},AnimationItem.prototype.stop=function(name){name&&this.name!==name||(this.pause(),this.playCount=0,this._completedLoop=!1,this.setCurrentRawFrameValue(0))},AnimationItem.prototype.getMarkerData=function(markerName){for(var marker,i=0;i<this.markers.length;i+=1)if((marker=this.markers[i]).payload&&marker.payload.name===markerName)return marker;return null},AnimationItem.prototype.goToAndStop=function(value,isFrame,name){if(!name||this.name===name){if(isNaN(Number(value))){var marker=this.getMarkerData(value);marker&&this.goToAndStop(marker.time,!0)}else isFrame?this.setCurrentRawFrameValue(value):this.setCurrentRawFrameValue(value*this.frameModifier);this.pause()}},AnimationItem.prototype.goToAndPlay=function(value,isFrame,name){if(!name||this.name===name){var numValue=Number(value);if(isNaN(numValue)){var marker=this.getMarkerData(value);marker&&(marker.duration?this.playSegments([marker.time,marker.time+marker.duration],!0):this.goToAndStop(marker.time,!0))}else this.goToAndStop(numValue,isFrame,name);this.play()}},AnimationItem.prototype.advanceTime=function(value){if(!0!==this.isPaused&&!1!==this.isLoaded){var nextValue=this.currentRawFrame+value*this.frameModifier,_isComplete=!1;nextValue>=this.totalFrames-1&&this.frameModifier>0?this.loop&&this.playCount!==this.loop?nextValue>=this.totalFrames?(this.playCount+=1,this.checkSegments(nextValue%this.totalFrames)||(this.setCurrentRawFrameValue(nextValue%this.totalFrames),this._completedLoop=!0,this.trigger("loopComplete"))):this.setCurrentRawFrameValue(nextValue):this.checkSegments(nextValue>this.totalFrames?nextValue%this.totalFrames:0)||(_isComplete=!0,nextValue=this.totalFrames-1):nextValue<0?this.checkSegments(nextValue%this.totalFrames)||(this.loop&&!(this.playCount--<=0&&!0!==this.loop)?(this.setCurrentRawFrameValue(this.totalFrames+nextValue%this.totalFrames),this._completedLoop?this.trigger("loopComplete"):this._completedLoop=!0):(_isComplete=!0,nextValue=0)):this.setCurrentRawFrameValue(nextValue),_isComplete&&(this.setCurrentRawFrameValue(nextValue),this.pause(),this.trigger("complete"))}},AnimationItem.prototype.adjustSegment=function(arr,offset){this.playCount=0,arr[1]<arr[0]?(this.frameModifier>0&&(this.playSpeed<0?this.setSpeed(-this.playSpeed):this.setDirection(-1)),this.totalFrames=arr[0]-arr[1],this.timeCompleted=this.totalFrames,this.firstFrame=arr[1],this.setCurrentRawFrameValue(this.totalFrames-.001-offset)):arr[1]>arr[0]&&(this.frameModifier<0&&(this.playSpeed<0?this.setSpeed(-this.playSpeed):this.setDirection(1)),this.totalFrames=arr[1]-arr[0],this.timeCompleted=this.totalFrames,this.firstFrame=arr[0],this.setCurrentRawFrameValue(.001+offset)),this.trigger("segmentStart")},AnimationItem.prototype.setSegment=function(init,end){var pendingFrame=-1;this.isPaused&&(this.currentRawFrame+this.firstFrame<init?pendingFrame=init:this.currentRawFrame+this.firstFrame>end&&(pendingFrame=end-init)),this.firstFrame=init,this.totalFrames=end-init,this.timeCompleted=this.totalFrames,-1!==pendingFrame&&this.goToAndStop(pendingFrame,!0)},AnimationItem.prototype.playSegments=function(arr,forceFlag){if(forceFlag&&(this.segments.length=0),"object"===_typeof$1(arr[0])){var i,len=arr.length;for(i=0;i<len;i+=1)this.segments.push(arr[i])}else this.segments.push(arr);this.segments.length&&forceFlag&&this.adjustSegment(this.segments.shift(),0),this.isPaused&&this.play()},AnimationItem.prototype.resetSegments=function(forceFlag){this.segments.length=0,this.segments.push([this.animationData.ip,this.animationData.op]),forceFlag&&this.checkSegments(0)},AnimationItem.prototype.checkSegments=function(offset){return!!this.segments.length&&(this.adjustSegment(this.segments.shift(),offset),!0)},AnimationItem.prototype.destroy=function(name){(!name||this.name===name)&&this.renderer&&(this.renderer.destroy(),this.imagePreloader.destroy(),this.trigger("destroy"),this._cbs=null,this.onEnterFrame=null,this.onLoopComplete=null,this.onComplete=null,this.onSegmentStart=null,this.onDestroy=null,this.renderer=null,this.expressionsPlugin=null,this.imagePreloader=null,this.projectInterface=null)},AnimationItem.prototype.setCurrentRawFrameValue=function(value){this.currentRawFrame=value,this.gotoFrame()},AnimationItem.prototype.setSpeed=function(val){this.playSpeed=val,this.updaFrameModifier()},AnimationItem.prototype.setDirection=function(val){this.playDirection=val<0?-1:1,this.updaFrameModifier()},AnimationItem.prototype.setLoop=function(isLooping){this.loop=isLooping},AnimationItem.prototype.setVolume=function(val,name){name&&this.name!==name||this.audioController.setVolume(val)},AnimationItem.prototype.getVolume=function(){return this.audioController.getVolume()},AnimationItem.prototype.mute=function(name){name&&this.name!==name||this.audioController.mute()},AnimationItem.prototype.unmute=function(name){name&&this.name!==name||this.audioController.unmute()},AnimationItem.prototype.updaFrameModifier=function(){this.frameModifier=this.frameMult*this.playSpeed*this.playDirection,this.audioController.setRate(this.playSpeed*this.playDirection)},AnimationItem.prototype.getPath=function(){return this.path},AnimationItem.prototype.getAssetsPath=function(assetData){var path="";if(assetData.e)path=assetData.p;else if(this.assetsPath){var imagePath=assetData.p;-1!==imagePath.indexOf("images/")&&(imagePath=imagePath.split("/")[1]),path=this.assetsPath+imagePath}else path=this.path+(assetData.u?assetData.u:"")+assetData.p;return path},AnimationItem.prototype.getAssetData=function(id){for(var i=0,len=this.assets.length;i<len;){if(id===this.assets[i].id)return this.assets[i];i+=1}return null},AnimationItem.prototype.hide=function(){this.renderer.hide()},AnimationItem.prototype.show=function(){this.renderer.show()},AnimationItem.prototype.getDuration=function(isFrame){return isFrame?this.totalFrames:this.totalFrames/this.frameRate},AnimationItem.prototype.updateDocumentData=function(path,documentData,index){try{this.renderer.getElementByPath(path).updateDocumentData(documentData,index)}catch(error){}},AnimationItem.prototype.trigger=function(name){if(this._cbs&&this._cbs[name])switch(name){case"enterFrame":this.triggerEvent(name,new BMEnterFrameEvent(name,this.currentFrame,this.totalFrames,this.frameModifier));break;case"drawnFrame":this.drawnFrameEvent.currentTime=this.currentFrame,this.drawnFrameEvent.totalTime=this.totalFrames,this.drawnFrameEvent.direction=this.frameModifier,this.triggerEvent(name,this.drawnFrameEvent);break;case"loopComplete":this.triggerEvent(name,new BMCompleteLoopEvent(name,this.loop,this.playCount,this.frameMult));break;case"complete":this.triggerEvent(name,new BMCompleteEvent(name,this.frameMult));break;case"segmentStart":this.triggerEvent(name,new BMSegmentStartEvent(name,this.firstFrame,this.totalFrames));break;case"destroy":this.triggerEvent(name,new BMDestroyEvent(name,this));break;default:this.triggerEvent(name)}"enterFrame"===name&&this.onEnterFrame&&this.onEnterFrame.call(this,new BMEnterFrameEvent(name,this.currentFrame,this.totalFrames,this.frameMult)),"loopComplete"===name&&this.onLoopComplete&&this.onLoopComplete.call(this,new BMCompleteLoopEvent(name,this.loop,this.playCount,this.frameMult)),"complete"===name&&this.onComplete&&this.onComplete.call(this,new BMCompleteEvent(name,this.frameMult)),"segmentStart"===name&&this.onSegmentStart&&this.onSegmentStart.call(this,new BMSegmentStartEvent(name,this.firstFrame,this.totalFrames)),"destroy"===name&&this.onDestroy&&this.onDestroy.call(this,new BMDestroyEvent(name,this))},AnimationItem.prototype.triggerRenderFrameError=function(nativeError){var error=new BMRenderFrameErrorEvent(nativeError,this.currentFrame);this.triggerEvent("error",error),this.onError&&this.onError.call(this,error)},AnimationItem.prototype.triggerConfigError=function(nativeError){var error=new BMConfigErrorEvent(nativeError,this.currentFrame);this.triggerEvent("error",error),this.onError&&this.onError.call(this,error)};var animationManager=function(){var moduleOb={},registeredAnimations=[],initTime=0,len=0,playingAnimationsNum=0,_stopped=!0,_isFrozen=!1;function removeElement(ev){for(var i=0,animItem=ev.target;i<len;)registeredAnimations[i].animation!==animItem||(registeredAnimations.splice(i,1),i-=1,len-=1,animItem.isPaused||subtractPlayingCount()),i+=1}function registerAnimation(element,animationData){if(!element)return null;for(var i=0;i<len;){if(registeredAnimations[i].elem===element&&null!==registeredAnimations[i].elem)return registeredAnimations[i].animation;i+=1}var animItem=new AnimationItem;return setupAnimation(animItem,element),animItem.setData(element,animationData),animItem}function getRegisteredAnimations(){var i,lenAnims=registeredAnimations.length,animations=[];for(i=0;i<lenAnims;i+=1)animations.push(registeredAnimations[i].animation);return animations}function addPlayingCount(){playingAnimationsNum+=1,activate()}function subtractPlayingCount(){playingAnimationsNum-=1}function setupAnimation(animItem,element){animItem.addEventListener("destroy",removeElement),animItem.addEventListener("_active",addPlayingCount),animItem.addEventListener("_idle",subtractPlayingCount),registeredAnimations.push({elem:element,animation:animItem}),len+=1}function loadAnimation(params){var animItem=new AnimationItem;return setupAnimation(animItem,null),animItem.setParams(params),animItem}function setSpeed(val,animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.setSpeed(val,animation)}function setDirection(val,animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.setDirection(val,animation)}function play(animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.play(animation)}function resume(nowTime){var i,elapsedTime=nowTime-initTime;for(i=0;i<len;i+=1)registeredAnimations[i].animation.advanceTime(elapsedTime);initTime=nowTime,playingAnimationsNum&&!_isFrozen?window.requestAnimationFrame(resume):_stopped=!0}function first(nowTime){initTime=nowTime,window.requestAnimationFrame(resume)}function pause(animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.pause(animation)}function goToAndStop(value,isFrame,animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.goToAndStop(value,isFrame,animation)}function stop(animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.stop(animation)}function togglePause(animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.togglePause(animation)}function destroy(animation){var i;for(i=len-1;i>=0;i-=1)registeredAnimations[i].animation.destroy(animation)}function searchAnimations(animationData,standalone,renderer){var i,animElements=[].concat([].slice.call(document.getElementsByClassName("lottie")),[].slice.call(document.getElementsByClassName("bodymovin"))),lenAnims=animElements.length;for(i=0;i<lenAnims;i+=1)renderer&&animElements[i].setAttribute("data-bm-type",renderer),registerAnimation(animElements[i],animationData);if(standalone&&0===lenAnims){renderer||(renderer="svg");var body=document.getElementsByTagName("body")[0];body.innerText="";var div=createTag("div");div.style.width="100%",div.style.height="100%",div.setAttribute("data-bm-type",renderer),body.appendChild(div),registerAnimation(div,animationData)}}function resize(){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.resize()}function activate(){!_isFrozen&&playingAnimationsNum&&_stopped&&(window.requestAnimationFrame(first),_stopped=!1)}function freeze(){_isFrozen=!0}function unfreeze(){_isFrozen=!1,activate()}function setVolume(val,animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.setVolume(val,animation)}function mute(animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.mute(animation)}function unmute(animation){var i;for(i=0;i<len;i+=1)registeredAnimations[i].animation.unmute(animation)}return moduleOb.registerAnimation=registerAnimation,moduleOb.loadAnimation=loadAnimation,moduleOb.setSpeed=setSpeed,moduleOb.setDirection=setDirection,moduleOb.play=play,moduleOb.pause=pause,moduleOb.stop=stop,moduleOb.togglePause=togglePause,moduleOb.searchAnimations=searchAnimations,moduleOb.resize=resize,moduleOb.goToAndStop=goToAndStop,moduleOb.destroy=destroy,moduleOb.freeze=freeze,moduleOb.unfreeze=unfreeze,moduleOb.setVolume=setVolume,moduleOb.mute=mute,moduleOb.unmute=unmute,moduleOb.getRegisteredAnimations=getRegisteredAnimations,moduleOb}(),BezierFactory=function(){var ob={};ob.getBezierEasing=getBezierEasing;var beziers={};function getBezierEasing(a,b,c,d,nm){var str=nm||("bez_"+a+"_"+b+"_"+c+"_"+d).replace(/\./g,"p");if(beziers[str])return beziers[str];var bezEasing=new BezierEasing([a,b,c,d]);return beziers[str]=bezEasing,bezEasing}var float32ArraySupported="function"==typeof Float32Array;function calcBezier(aT,aA1,aA2){return(((1-3*aA2+3*aA1)*aT+(3*aA2-6*aA1))*aT+3*aA1)*aT}function getSlope(aT,aA1,aA2){return 3*(1-3*aA2+3*aA1)*aT*aT+2*(3*aA2-6*aA1)*aT+3*aA1}function binarySubdivide(aX,aA,aB,mX1,mX2){var currentX,currentT,i=0;do(currentX=calcBezier(currentT=aA+(aB-aA)/2,mX1,mX2)-aX)>0?aB=currentT:aA=currentT;while(Math.abs(currentX)>1e-7&&++i<10)return currentT}function newtonRaphsonIterate(aX,aGuessT,mX1,mX2){for(var i=0;i<4;++i){var currentSlope=getSlope(aGuessT,mX1,mX2);if(0===currentSlope)break;var currentX=calcBezier(aGuessT,mX1,mX2)-aX;aGuessT-=currentX/currentSlope}return aGuessT}function BezierEasing(points){this._p=points,this._mSampleValues=float32ArraySupported?new Float32Array(11):Array(11),this._precomputed=!1,this.get=this.get.bind(this)}return BezierEasing.prototype={get:function get(x){var mX1=this._p[0],mY1=this._p[1],mX2=this._p[2],mY2=this._p[3];return(this._precomputed||this._precompute(),mX1===mY1&&mX2===mY2)?x:0===x?0:1===x?1:calcBezier(this._getTForX(x),mY1,mY2)},_precompute:function _precompute(){var mX1=this._p[0],mY1=this._p[1],mX2=this._p[2],mY2=this._p[3];this._precomputed=!0,(mX1!==mY1||mX2!==mY2)&&this._calcSampleValues()},_calcSampleValues:function _calcSampleValues(){for(var mX1=this._p[0],mX2=this._p[2],i=0;i<11;++i)this._mSampleValues[i]=calcBezier(.1*i,mX1,mX2)},_getTForX:function _getTForX(aX){for(var mX1=this._p[0],mX2=this._p[2],mSampleValues=this._mSampleValues,intervalStart=0,currentSample=1;10!==currentSample&&mSampleValues[currentSample]<=aX;++currentSample)intervalStart+=.1;var guessForT=intervalStart+(aX-mSampleValues[--currentSample])/(mSampleValues[currentSample+1]-mSampleValues[currentSample])*.1,initialSlope=getSlope(guessForT,mX1,mX2);return initialSlope>=.001?newtonRaphsonIterate(aX,guessForT,mX1,mX2):0===initialSlope?guessForT:binarySubdivide(aX,intervalStart,intervalStart+.1,mX1,mX2)}},ob}(),pooling={double:function _double(arr){return arr.concat(createSizedArray(arr.length))}},poolFactory=function(initialLength,_create,_release){var _length=0,_maxLength=initialLength,pool=createSizedArray(_maxLength);return{newElement:function newElement(){var element;return _length?(_length-=1,element=pool[_length]):element=_create(),element},release:function release(element){_length===_maxLength&&(pool=pooling.double(pool),_maxLength*=2),_release&&_release(element),pool[_length]=element,_length+=1}}},bezierLengthPool=poolFactory(8,function create(){return{addedLength:0,percents:createTypedArray("float32",getDefaultCurveSegments()),lengths:createTypedArray("float32",getDefaultCurveSegments())}}),segmentsLengthPool=poolFactory(8,function create(){return{lengths:[],totalLength:0}},function release(element){var i,len=element.lengths.length;for(i=0;i<len;i+=1)bezierLengthPool.release(element.lengths[i]);element.lengths.length=0}),bez=function bezFunction(){var storedData,math=Math;function pointOnLine2D(x1,y1,x2,y2,x3,y3){var det1=x1*y2+y1*x3+x2*y3-x3*y2-y3*x1-x2*y1;return det1>-.001&&det1<.001}function pointOnLine3D(x1,y1,z1,x2,y2,z2,x3,y3,z3){if(0===z1&&0===z2&&0===z3)return pointOnLine2D(x1,y1,x2,y2,x3,y3);var diffDist,dist1=math.sqrt(math.pow(x2-x1,2)+math.pow(y2-y1,2)+math.pow(z2-z1,2)),dist2=math.sqrt(math.pow(x3-x1,2)+math.pow(y3-y1,2)+math.pow(z3-z1,2)),dist3=math.sqrt(math.pow(x3-x2,2)+math.pow(y3-y2,2)+math.pow(z3-z2,2));return(diffDist=dist1>dist2?dist1>dist3?dist1-dist2-dist3:dist3-dist2-dist1:dist3>dist2?dist3-dist2-dist1:dist2-dist1-dist3)>-.0001&&diffDist<1e-4}var getBezierLength=function(pt1,pt2,pt3,pt4){var k,i,len,ptCoord,perc,ptDistance,curveSegments=getDefaultCurveSegments(),addedLength=0,point=[],lastPoint=[],lengthData=bezierLengthPool.newElement();for(k=0,len=pt3.length;k<curveSegments;k+=1){for(i=0,perc=k/(curveSegments-1),ptDistance=0;i<len;i+=1)ptCoord=bmPow(1-perc,3)*pt1[i]+3*bmPow(1-perc,2)*perc*pt3[i]+3*(1-perc)*bmPow(perc,2)*pt4[i]+bmPow(perc,3)*pt2[i],point[i]=ptCoord,null!==lastPoint[i]&&(ptDistance+=bmPow(point[i]-lastPoint[i],2)),lastPoint[i]=point[i];ptDistance&&(addedLength+=ptDistance=bmSqrt(ptDistance)),lengthData.percents[k]=perc,lengthData.lengths[k]=addedLength}return lengthData.addedLength=addedLength,lengthData};function getSegmentsLength(shapeData){var i,segmentsLength=segmentsLengthPool.newElement(),closed=shapeData.c,pathV=shapeData.v,pathO=shapeData.o,pathI=shapeData.i,len=shapeData._length,lengths=segmentsLength.lengths,totalLength=0;for(i=0;i<len-1;i+=1)lengths[i]=getBezierLength(pathV[i],pathV[i+1],pathO[i],pathI[i+1]),totalLength+=lengths[i].addedLength;return closed&&len&&(lengths[i]=getBezierLength(pathV[i],pathV[0],pathO[i],pathI[0]),totalLength+=lengths[i].addedLength),segmentsLength.totalLength=totalLength,segmentsLength}function BezierData(length){this.segmentLength=0,this.points=Array(length)}function PointData(partial,point){this.partialLength=partial,this.point=point}var buildBezierData=(storedData={},function(pt1,pt2,pt3,pt4){var bezierName=(pt1[0]+"_"+pt1[1]+"_"+pt2[0]+"_"+pt2[1]+"_"+pt3[0]+"_"+pt3[1]+"_"+pt4[0]+"_"+pt4[1]).replace(/\./g,"p");if(!storedData[bezierName]){var k,i,len,ptCoord,perc,ptDistance,point,curveSegments=getDefaultCurveSegments(),addedLength=0,lastPoint=null;2===pt1.length&&(pt1[0]!==pt2[0]||pt1[1]!==pt2[1])&&pointOnLine2D(pt1[0],pt1[1],pt2[0],pt2[1],pt1[0]+pt3[0],pt1[1]+pt3[1])&&pointOnLine2D(pt1[0],pt1[1],pt2[0],pt2[1],pt2[0]+pt4[0],pt2[1]+pt4[1])&&(curveSegments=2);var bezierData=new BezierData(curveSegments);for(k=0,len=pt3.length;k<curveSegments;k+=1){for(i=0,point=createSizedArray(len),perc=k/(curveSegments-1),ptDistance=0;i<len;i+=1)ptCoord=bmPow(1-perc,3)*pt1[i]+3*bmPow(1-perc,2)*perc*(pt1[i]+pt3[i])+3*(1-perc)*bmPow(perc,2)*(pt2[i]+pt4[i])+bmPow(perc,3)*pt2[i],point[i]=ptCoord,null!==lastPoint&&(ptDistance+=bmPow(point[i]-lastPoint[i],2));addedLength+=ptDistance=bmSqrt(ptDistance),bezierData.points[k]=new PointData(ptDistance,point),lastPoint=point}bezierData.segmentLength=addedLength,storedData[bezierName]=bezierData}return storedData[bezierName]});function getDistancePerc(perc,bezierData){var percents=bezierData.percents,lengths=bezierData.lengths,len=percents.length,initPos=bmFloor((len-1)*perc),lengthPos=perc*bezierData.addedLength,lPerc=0;if(initPos===len-1||0===initPos||lengthPos===lengths[initPos])return percents[initPos];for(var dir=lengths[initPos]>lengthPos?-1:1,flag=!0;flag;)if(lengths[initPos]<=lengthPos&&lengths[initPos+1]>lengthPos?(lPerc=(lengthPos-lengths[initPos])/(lengths[initPos+1]-lengths[initPos]),flag=!1):initPos+=dir,initPos<0||initPos>=len-1){if(initPos===len-1)return percents[initPos];flag=!1}return percents[initPos]+(percents[initPos+1]-percents[initPos])*lPerc}function getPointInSegment(pt1,pt2,pt3,pt4,percent,bezierData){var t1=getDistancePerc(percent,bezierData),u1=1-t1;return[math.round((u1*u1*u1*pt1[0]+(t1*u1*u1+u1*t1*u1+u1*u1*t1)*pt3[0]+(t1*t1*u1+u1*t1*t1+t1*u1*t1)*pt4[0]+t1*t1*t1*pt2[0])*1e3)/1e3,math.round((u1*u1*u1*pt1[1]+(t1*u1*u1+u1*t1*u1+u1*u1*t1)*pt3[1]+(t1*t1*u1+u1*t1*t1+t1*u1*t1)*pt4[1]+t1*t1*t1*pt2[1])*1e3)/1e3]}var bezierSegmentPoints=createTypedArray("float32",8);return{getSegmentsLength:getSegmentsLength,getNewSegment:function getNewSegment(pt1,pt2,pt3,pt4,startPerc,endPerc,bezierData){startPerc<0?startPerc=0:startPerc>1&&(startPerc=1);var i,t0=getDistancePerc(startPerc,bezierData),t1=getDistancePerc(endPerc=endPerc>1?1:endPerc,bezierData),len=pt1.length,u0=1-t0,u1=1-t1,u0u0u0=u0*u0*u0,t0u0u0_3=t0*u0*u0*3,t0t0u0_3=t0*t0*u0*3,t0t0t0=t0*t0*t0,u0u0u1=u0*u0*u1,t0u0u1_3=t0*u0*u1+u0*t0*u1+u0*u0*t1,t0t0u1_3=t0*t0*u1+u0*t0*t1+t0*u0*t1,t0t0t1=t0*t0*t1,u0u1u1=u0*u1*u1,t0u1u1_3=t0*u1*u1+u0*t1*u1+u0*u1*t1,t0t1u1_3=t0*t1*u1+u0*t1*t1+t0*u1*t1,t0t1t1=t0*t1*t1,u1u1u1=u1*u1*u1,t1u1u1_3=t1*u1*u1+u1*t1*u1+u1*u1*t1,t1t1u1_3=t1*t1*u1+u1*t1*t1+t1*u1*t1,t1t1t1=t1*t1*t1;for(i=0;i<len;i+=1)bezierSegmentPoints[4*i]=math.round((u0u0u0*pt1[i]+t0u0u0_3*pt3[i]+t0t0u0_3*pt4[i]+t0t0t0*pt2[i])*1e3)/1e3,bezierSegmentPoints[4*i+1]=math.round((u0u0u1*pt1[i]+t0u0u1_3*pt3[i]+t0t0u1_3*pt4[i]+t0t0t1*pt2[i])*1e3)/1e3,bezierSegmentPoints[4*i+2]=math.round((u0u1u1*pt1[i]+t0u1u1_3*pt3[i]+t0t1u1_3*pt4[i]+t0t1t1*pt2[i])*1e3)/1e3,bezierSegmentPoints[4*i+3]=math.round((u1u1u1*pt1[i]+t1u1u1_3*pt3[i]+t1t1u1_3*pt4[i]+t1t1t1*pt2[i])*1e3)/1e3;return bezierSegmentPoints},getPointInSegment:getPointInSegment,buildBezierData:buildBezierData,pointOnLine2D:pointOnLine2D,pointOnLine3D:pointOnLine3D}}(),mathAbs=Math.abs;function interpolateValue(frameNum,caching){var outX,outY,inX,inY,keyValue,offsetTime=this.offsetTime;"multidimensional"===this.propType&&(newValue=createTypedArray("float32",this.pv.length));for(var iterationIndex=caching.lastIndex,i=iterationIndex,len=this.keyframes.length-1,flag=!0;flag;){if(keyData=this.keyframes[i],nextKeyData=this.keyframes[i+1],i===len-1&&frameNum>=nextKeyData.t-offsetTime){keyData.h&&(keyData=nextKeyData),iterationIndex=0;break}if(nextKeyData.t-offsetTime>frameNum){iterationIndex=i;break}i<len-1?i+=1:(iterationIndex=0,flag=!1)}keyframeMetadata=this.keyframesMetadata[i]||{};var nextKeyTime=nextKeyData.t-offsetTime,keyTime=keyData.t-offsetTime;if(keyData.to){keyframeMetadata.bezierData||(keyframeMetadata.bezierData=bez.buildBezierData(keyData.s,nextKeyData.s||keyData.e,keyData.to,keyData.ti));var bezierData=keyframeMetadata.bezierData;if(frameNum>=nextKeyTime||frameNum<keyTime){var ind=frameNum>=nextKeyTime?bezierData.points.length-1:0;for(k=0,kLen=bezierData.points[ind].point.length;k<kLen;k+=1)newValue[k]=bezierData.points[ind].point[k]}else{keyframeMetadata.__fnct?fnc=keyframeMetadata.__fnct:(fnc=BezierFactory.getBezierEasing(keyData.o.x,keyData.o.y,keyData.i.x,keyData.i.y,keyData.n).get,keyframeMetadata.__fnct=fnc),perc=fnc((frameNum-keyTime)/(nextKeyTime-keyTime));var newValue,keyData,nextKeyData,keyframeMetadata,k,kLen,perc,jLen,j,fnc,endValue,segmentPerc,distanceInLine=bezierData.segmentLength*perc,addedLength=caching.lastFrame<frameNum&&caching._lastKeyframeIndex===i?caching._lastAddedLength:0;for(j=caching.lastFrame<frameNum&&caching._lastKeyframeIndex===i?caching._lastPoint:0,flag=!0,jLen=bezierData.points.length;flag;){if(addedLength+=bezierData.points[j].partialLength,0===distanceInLine||0===perc||j===bezierData.points.length-1){for(k=0,kLen=bezierData.points[j].point.length;k<kLen;k+=1)newValue[k]=bezierData.points[j].point[k];break}if(distanceInLine>=addedLength&&distanceInLine<addedLength+bezierData.points[j+1].partialLength){for(k=0,segmentPerc=(distanceInLine-addedLength)/bezierData.points[j+1].partialLength,kLen=bezierData.points[j].point.length;k<kLen;k+=1)newValue[k]=bezierData.points[j].point[k]+(bezierData.points[j+1].point[k]-bezierData.points[j].point[k])*segmentPerc;break}j<jLen-1?j+=1:flag=!1}caching._lastPoint=j,caching._lastAddedLength=addedLength-bezierData.points[j].partialLength,caching._lastKeyframeIndex=i}}else if(len=keyData.s.length,endValue=nextKeyData.s||keyData.e,this.sh&&1!==keyData.h)frameNum>=nextKeyTime?(newValue[0]=endValue[0],newValue[1]=endValue[1],newValue[2]=endValue[2]):frameNum<=keyTime?(newValue[0]=keyData.s[0],newValue[1]=keyData.s[1],newValue[2]=keyData.s[2]):quaternionToEuler(newValue,slerp(createQuaternion(keyData.s),createQuaternion(endValue),(frameNum-keyTime)/(nextKeyTime-keyTime)));else for(i=0;i<len;i+=1)1!==keyData.h&&(frameNum>=nextKeyTime?perc=1:frameNum<keyTime?perc=0:(keyData.o.x.constructor===Array?(keyframeMetadata.__fnct||(keyframeMetadata.__fnct=[]),keyframeMetadata.__fnct[i]?fnc=keyframeMetadata.__fnct[i]:(outX=void 0===keyData.o.x[i]?keyData.o.x[0]:keyData.o.x[i],outY=void 0===keyData.o.y[i]?keyData.o.y[0]:keyData.o.y[i],inX=void 0===keyData.i.x[i]?keyData.i.x[0]:keyData.i.x[i],inY=void 0===keyData.i.y[i]?keyData.i.y[0]:keyData.i.y[i],fnc=BezierFactory.getBezierEasing(outX,outY,inX,inY).get,keyframeMetadata.__fnct[i]=fnc)):keyframeMetadata.__fnct?fnc=keyframeMetadata.__fnct:(outX=keyData.o.x,outY=keyData.o.y,inX=keyData.i.x,inY=keyData.i.y,fnc=BezierFactory.getBezierEasing(outX,outY,inX,inY).get,keyData.keyframeMetadata=fnc),perc=fnc((frameNum-keyTime)/(nextKeyTime-keyTime)))),endValue=nextKeyData.s||keyData.e,keyValue=1===keyData.h?keyData.s[i]:keyData.s[i]+(endValue[i]-keyData.s[i])*perc,"multidimensional"===this.propType?newValue[i]=keyValue:newValue=keyValue;return caching.lastIndex=iterationIndex,newValue}function slerp(a,b,t){var omega,cosom,sinom,scale0,scale1,out=[],ax=a[0],ay=a[1],az=a[2],aw=a[3],bx=b[0],by=b[1],bz=b[2],bw=b[3];return(cosom=ax*bx+ay*by+az*bz+aw*bw)<0&&(cosom=-cosom,bx=-bx,by=-by,bz=-bz,bw=-bw),1-cosom>1e-6?(sinom=Math.sin(omega=Math.acos(cosom)),scale0=Math.sin((1-t)*omega)/sinom,scale1=Math.sin(t*omega)/sinom):(scale0=1-t,scale1=t),out[0]=scale0*ax+scale1*bx,out[1]=scale0*ay+scale1*by,out[2]=scale0*az+scale1*bz,out[3]=scale0*aw+scale1*bw,out}function quaternionToEuler(out,quat){var qx=quat[0],qy=quat[1],qz=quat[2],qw=quat[3],heading=Math.atan2(2*qy*qw-2*qx*qz,1-2*qy*qy-2*qz*qz),attitude=Math.asin(2*qx*qy+2*qz*qw),bank=Math.atan2(2*qx*qw-2*qy*qz,1-2*qx*qx-2*qz*qz);out[0]=heading/degToRads,out[1]=attitude/degToRads,out[2]=bank/degToRads}function createQuaternion(values){var heading=values[0]*degToRads,attitude=values[1]*degToRads,bank=values[2]*degToRads,c1=Math.cos(heading/2),c2=Math.cos(attitude/2),c3=Math.cos(bank/2),s1=Math.sin(heading/2),s2=Math.sin(attitude/2),s3=Math.sin(bank/2);return[s1*s2*c3+c1*c2*s3,s1*c2*c3+c1*s2*s3,c1*s2*c3-s1*c2*s3,c1*c2*c3-s1*s2*s3]}function getValueAtCurrentTime(){var frameNum=this.comp.renderedFrame-this.offsetTime,initTime=this.keyframes[0].t-this.offsetTime,endTime=this.keyframes[this.keyframes.length-1].t-this.offsetTime;if(!(frameNum===this._caching.lastFrame||-999999!==this._caching.lastFrame&&(this._caching.lastFrame>=endTime&&frameNum>=endTime||this._caching.lastFrame<initTime&&frameNum<initTime))){this._caching.lastFrame>=frameNum&&(this._caching._lastKeyframeIndex=-1,this._caching.lastIndex=0);var renderResult=this.interpolateValue(frameNum,this._caching);this.pv=renderResult}return this._caching.lastFrame=frameNum,this.pv}function setVValue(val){var multipliedValue;if("unidimensional"===this.propType)multipliedValue=val*this.mult,mathAbs(this.v-multipliedValue)>1e-5&&(this.v=multipliedValue,this._mdf=!0);else for(var i=0,len=this.v.length;i<len;)multipliedValue=val[i]*this.mult,mathAbs(this.v[i]-multipliedValue)>1e-5&&(this.v[i]=multipliedValue,this._mdf=!0),i+=1}function processEffectsSequence(){if(this.elem.globalData.frameId!==this.frameId&&this.effectsSequence.length){if(this.lock){this.setVValue(this.pv);return}this.lock=!0,this._mdf=this._isFirstFrame;var i,len=this.effectsSequence.length,finalValue=this.kf?this.pv:this.data.k;for(i=0;i<len;i+=1)finalValue=this.effectsSequence[i](finalValue);this.setVValue(finalValue),this._isFirstFrame=!1,this.lock=!1,this.frameId=this.elem.globalData.frameId}}function addEffect(effectFunction){this.effectsSequence.push(effectFunction),this.container.addDynamicProperty(this)}function ValueProperty(elem,data,mult,container){this.propType="unidimensional",this.mult=mult||1,this.data=data,this.v=mult?data.k*mult:data.k,this.pv=data.k,this._mdf=!1,this.elem=elem,this.container=container,this.comp=elem.comp,this.k=!1,this.kf=!1,this.vel=0,this.effectsSequence=[],this._isFirstFrame=!0,this.getValue=processEffectsSequence,this.setVValue=setVValue,this.addEffect=addEffect}function MultiDimensionalProperty(elem,data,mult,container){this.propType="multidimensional",this.mult=mult||1,this.data=data,this._mdf=!1,this.elem=elem,this.container=container,this.comp=elem.comp,this.k=!1,this.kf=!1,this.frameId=-1;var i,len=data.k.length;for(i=0,this.v=createTypedArray("float32",len),this.pv=createTypedArray("float32",len),this.vel=createTypedArray("float32",len);i<len;i+=1)this.v[i]=data.k[i]*this.mult,this.pv[i]=data.k[i];this._isFirstFrame=!0,this.effectsSequence=[],this.getValue=processEffectsSequence,this.setVValue=setVValue,this.addEffect=addEffect}function KeyframedValueProperty(elem,data,mult,container){this.propType="unidimensional",this.keyframes=data.k,this.keyframesMetadata=[],this.offsetTime=elem.data.st,this.frameId=-1,this._caching={lastFrame:-999999,lastIndex:0,value:0,_lastKeyframeIndex:-1},this.k=!0,this.kf=!0,this.data=data,this.mult=mult||1,this.elem=elem,this.container=container,this.comp=elem.comp,this.v=-999999,this.pv=-999999,this._isFirstFrame=!0,this.getValue=processEffectsSequence,this.setVValue=setVValue,this.interpolateValue=interpolateValue,this.effectsSequence=[getValueAtCurrentTime.bind(this)],this.addEffect=addEffect}function KeyframedMultidimensionalProperty(elem,data,mult,container){this.propType="multidimensional";var i,s,e,to,ti,len=data.k.length;for(i=0;i<len-1;i+=1)data.k[i].to&&data.k[i].s&&data.k[i+1]&&data.k[i+1].s&&(s=data.k[i].s,e=data.k[i+1].s,to=data.k[i].to,ti=data.k[i].ti,(2===s.length&&!(s[0]===e[0]&&s[1]===e[1])&&bez.pointOnLine2D(s[0],s[1],e[0],e[1],s[0]+to[0],s[1]+to[1])&&bez.pointOnLine2D(s[0],s[1],e[0],e[1],e[0]+ti[0],e[1]+ti[1])||3===s.length&&!(s[0]===e[0]&&s[1]===e[1]&&s[2]===e[2])&&bez.pointOnLine3D(s[0],s[1],s[2],e[0],e[1],e[2],s[0]+to[0],s[1]+to[1],s[2]+to[2])&&bez.pointOnLine3D(s[0],s[1],s[2],e[0],e[1],e[2],e[0]+ti[0],e[1]+ti[1],e[2]+ti[2]))&&(data.k[i].to=null,data.k[i].ti=null),s[0]===e[0]&&s[1]===e[1]&&0===to[0]&&0===to[1]&&0===ti[0]&&0===ti[1]&&(2===s.length||s[2]===e[2]&&0===to[2]&&0===ti[2])&&(data.k[i].to=null,data.k[i].ti=null));this.effectsSequence=[getValueAtCurrentTime.bind(this)],this.data=data,this.keyframes=data.k,this.keyframesMetadata=[],this.offsetTime=elem.data.st,this.k=!0,this.kf=!0,this._isFirstFrame=!0,this.mult=mult||1,this.elem=elem,this.container=container,this.comp=elem.comp,this.getValue=processEffectsSequence,this.setVValue=setVValue,this.interpolateValue=interpolateValue,this.frameId=-1;var arrLen=data.k[0].s.length;for(i=0,this.v=createTypedArray("float32",arrLen),this.pv=createTypedArray("float32",arrLen);i<arrLen;i+=1)this.v[i]=-999999,this.pv[i]=-999999;this._caching={lastFrame:-999999,lastIndex:0,value:createTypedArray("float32",arrLen)},this.addEffect=addEffect}var PropertyFactory={getProp:function getProp(elem,data,type,mult,container){var p;if(data.sid&&(data=elem.globalData.slotManager.getProp(data)),data.k.length){if("number"==typeof data.k[0])p=new MultiDimensionalProperty(elem,data,mult,container);else switch(type){case 0:p=new KeyframedValueProperty(elem,data,mult,container);break;case 1:p=new KeyframedMultidimensionalProperty(elem,data,mult,container)}}else p=new ValueProperty(elem,data,mult,container);return p.effectsSequence.length&&container.addDynamicProperty(p),p}};function DynamicPropertyContainer(){}DynamicPropertyContainer.prototype={addDynamicProperty:function addDynamicProperty(prop){-1===this.dynamicProperties.indexOf(prop)&&(this.dynamicProperties.push(prop),this.container.addDynamicProperty(this),this._isAnimated=!0)},iterateDynamicProperties:function iterateDynamicProperties(){this._mdf=!1;var i,len=this.dynamicProperties.length;for(i=0;i<len;i+=1)this.dynamicProperties[i].getValue(),this.dynamicProperties[i]._mdf&&(this._mdf=!0)},initDynamicPropertyContainer:function initDynamicPropertyContainer(container){this.container=container,this.dynamicProperties=[],this._mdf=!1,this._isAnimated=!1}};var pointPool=poolFactory(8,function create(){return createTypedArray("float32",2)});function ShapePath(){this.c=!1,this._length=0,this._maxLength=8,this.v=createSizedArray(this._maxLength),this.o=createSizedArray(this._maxLength),this.i=createSizedArray(this._maxLength)}ShapePath.prototype.setPathData=function(closed,len){this.c=closed,this.setLength(len);for(var i=0;i<len;)this.v[i]=pointPool.newElement(),this.o[i]=pointPool.newElement(),this.i[i]=pointPool.newElement(),i+=1},ShapePath.prototype.setLength=function(len){for(;this._maxLength<len;)this.doubleArrayLength();this._length=len},ShapePath.prototype.doubleArrayLength=function(){this.v=this.v.concat(createSizedArray(this._maxLength)),this.i=this.i.concat(createSizedArray(this._maxLength)),this.o=this.o.concat(createSizedArray(this._maxLength)),this._maxLength*=2},ShapePath.prototype.setXYAt=function(x,y,type,pos,replace){var arr;switch(this._length=Math.max(this._length,pos+1),this._length>=this._maxLength&&this.doubleArrayLength(),type){case"v":arr=this.v;break;case"i":arr=this.i;break;case"o":arr=this.o;break;default:arr=[]}arr[pos]&&(!arr[pos]||replace)||(arr[pos]=pointPool.newElement()),arr[pos][0]=x,arr[pos][1]=y},ShapePath.prototype.setTripleAt=function(vX,vY,oX,oY,iX,iY,pos,replace){this.setXYAt(vX,vY,"v",pos,replace),this.setXYAt(oX,oY,"o",pos,replace),this.setXYAt(iX,iY,"i",pos,replace)},ShapePath.prototype.reverse=function(){var i,newPath=new ShapePath;newPath.setPathData(this.c,this._length);var vertices=this.v,outPoints=this.o,inPoints=this.i,init=0;this.c&&(newPath.setTripleAt(vertices[0][0],vertices[0][1],inPoints[0][0],inPoints[0][1],outPoints[0][0],outPoints[0][1],0,!1),init=1);var cnt=this._length-1,len=this._length;for(i=init;i<len;i+=1)newPath.setTripleAt(vertices[cnt][0],vertices[cnt][1],inPoints[cnt][0],inPoints[cnt][1],outPoints[cnt][0],outPoints[cnt][1],i,!1),cnt-=1;return newPath},ShapePath.prototype.length=function(){return this._length};var shapePool=function(){function clone(shape){var i,cloned=factory.newElement(),len=void 0===shape._length?shape.v.length:shape._length;for(cloned.setLength(len),cloned.c=shape.c,i=0;i<len;i+=1)cloned.setTripleAt(shape.v[i][0],shape.v[i][1],shape.o[i][0],shape.o[i][1],shape.i[i][0],shape.i[i][1],i);return cloned}var factory=poolFactory(4,function create(){return new ShapePath},function release(shapePath){var i,len=shapePath._length;for(i=0;i<len;i+=1)pointPool.release(shapePath.v[i]),pointPool.release(shapePath.i[i]),pointPool.release(shapePath.o[i]),shapePath.v[i]=null,shapePath.i[i]=null,shapePath.o[i]=null;shapePath._length=0,shapePath.c=!1});return factory.clone=clone,factory}();function ShapeCollection(){this._length=0,this._maxLength=4,this.shapes=createSizedArray(this._maxLength)}ShapeCollection.prototype.addShape=function(shapeData){this._length===this._maxLength&&(this.shapes=this.shapes.concat(createSizedArray(this._maxLength)),this._maxLength*=2),this.shapes[this._length]=shapeData,this._length+=1},ShapeCollection.prototype.releaseShapes=function(){var i;for(i=0;i<this._length;i+=1)shapePool.release(this.shapes[i]);this._length=0};var shapeCollectionPool=(_length=0,_maxLength=4,pool=createSizedArray(4),{newShapeCollection:function newShapeCollection(){var shapeCollection;return _length?(_length-=1,shapeCollection=pool[_length]):shapeCollection=new ShapeCollection,shapeCollection},release:function release(shapeCollection){var i,len=shapeCollection._length;for(i=0;i<len;i+=1)shapePool.release(shapeCollection.shapes[i]);shapeCollection._length=0,_length===_maxLength&&(pool=pooling.double(pool),_maxLength*=2),pool[_length]=shapeCollection,_length+=1}}),ShapePropertyFactory=function(){function interpolateShape(frameNum,previousValue,caching){var iterationIndex=caching.lastIndex,kf=this.keyframes;if(frameNum<kf[0].t-this.offsetTime)keyPropS=kf[0].s[0],isHold=!0,iterationIndex=0;else if(frameNum>=kf[kf.length-1].t-this.offsetTime)keyPropS=kf[kf.length-1].s?kf[kf.length-1].s[0]:kf[kf.length-2].e[0],isHold=!0;else{for(var keyPropS,keyPropE,isHold,j,k,jLen,kLen,perc,vertexValue,keyData,nextKeyData,keyframeMetadata,fnc,i=iterationIndex,len=kf.length-1,flag=!0;flag&&(keyData=kf[i],!((nextKeyData=kf[i+1]).t-this.offsetTime>frameNum));)i<len-1?i+=1:flag=!1;keyframeMetadata=this.keyframesMetadata[i]||{},isHold=1===keyData.h,iterationIndex=i,isHold||(frameNum>=nextKeyData.t-this.offsetTime?perc=1:frameNum<keyData.t-this.offsetTime?perc=0:(keyframeMetadata.__fnct?fnc=keyframeMetadata.__fnct:(fnc=BezierFactory.getBezierEasing(keyData.o.x,keyData.o.y,keyData.i.x,keyData.i.y).get,keyframeMetadata.__fnct=fnc),perc=fnc((frameNum-(keyData.t-this.offsetTime))/(nextKeyData.t-this.offsetTime-(keyData.t-this.offsetTime)))),keyPropE=nextKeyData.s?nextKeyData.s[0]:keyData.e[0]),keyPropS=keyData.s[0]}for(j=0,jLen=previousValue._length,kLen=keyPropS.i[0].length,caching.lastIndex=iterationIndex;j<jLen;j+=1)for(k=0;k<kLen;k+=1)vertexValue=isHold?keyPropS.i[j][k]:keyPropS.i[j][k]+(keyPropE.i[j][k]-keyPropS.i[j][k])*perc,previousValue.i[j][k]=vertexValue,vertexValue=isHold?keyPropS.o[j][k]:keyPropS.o[j][k]+(keyPropE.o[j][k]-keyPropS.o[j][k])*perc,previousValue.o[j][k]=vertexValue,vertexValue=isHold?keyPropS.v[j][k]:keyPropS.v[j][k]+(keyPropE.v[j][k]-keyPropS.v[j][k])*perc,previousValue.v[j][k]=vertexValue}function interpolateShapeCurrentTime(){var frameNum=this.comp.renderedFrame-this.offsetTime,initTime=this.keyframes[0].t-this.offsetTime,endTime=this.keyframes[this.keyframes.length-1].t-this.offsetTime,lastFrame=this._caching.lastFrame;return -999999!==lastFrame&&(lastFrame<initTime&&frameNum<initTime||lastFrame>endTime&&frameNum>endTime)||(this._caching.lastIndex=lastFrame<frameNum?this._caching.lastIndex:0,this.interpolateShape(frameNum,this.pv,this._caching)),this._caching.lastFrame=frameNum,this.pv}function resetShape(){this.paths=this.localShapeCollection}function shapesEqual(shape1,shape2){if(shape1._length!==shape2._length||shape1.c!==shape2.c)return!1;var i,len=shape1._length;for(i=0;i<len;i+=1)if(shape1.v[i][0]!==shape2.v[i][0]||shape1.v[i][1]!==shape2.v[i][1]||shape1.o[i][0]!==shape2.o[i][0]||shape1.o[i][1]!==shape2.o[i][1]||shape1.i[i][0]!==shape2.i[i][0]||shape1.i[i][1]!==shape2.i[i][1])return!1;return!0}function setVValue(newPath){shapesEqual(this.v,newPath)||(this.v=shapePool.clone(newPath),this.localShapeCollection.releaseShapes(),this.localShapeCollection.addShape(this.v),this._mdf=!0,this.paths=this.localShapeCollection)}function processEffectsSequence(){if(this.elem.globalData.frameId!==this.frameId){if(!this.effectsSequence.length){this._mdf=!1;return}if(this.lock){this.setVValue(this.pv);return}this.lock=!0,this._mdf=!1,finalValue=this.kf?this.pv:this.data.ks?this.data.ks.k:this.data.pt.k;var finalValue,i,len=this.effectsSequence.length;for(i=0;i<len;i+=1)finalValue=this.effectsSequence[i](finalValue);this.setVValue(finalValue),this.lock=!1,this.frameId=this.elem.globalData.frameId}}function ShapeProperty(elem,data,type){this.propType="shape",this.comp=elem.comp,this.container=elem,this.elem=elem,this.data=data,this.k=!1,this.kf=!1,this._mdf=!1;var pathData=3===type?data.pt.k:data.ks.k;this.v=shapePool.clone(pathData),this.pv=shapePool.clone(this.v),this.localShapeCollection=shapeCollectionPool.newShapeCollection(),this.paths=this.localShapeCollection,this.paths.addShape(this.v),this.reset=resetShape,this.effectsSequence=[]}function addEffect(effectFunction){this.effectsSequence.push(effectFunction),this.container.addDynamicProperty(this)}function KeyframedShapeProperty(elem,data,type){this.propType="shape",this.comp=elem.comp,this.elem=elem,this.container=elem,this.offsetTime=elem.data.st,this.keyframes=3===type?data.pt.k:data.ks.k,this.keyframesMetadata=[],this.k=!0,this.kf=!0;var len=this.keyframes[0].s[0].i.length;this.v=shapePool.newElement(),this.v.setPathData(this.keyframes[0].s[0].c,len),this.pv=shapePool.clone(this.v),this.localShapeCollection=shapeCollectionPool.newShapeCollection(),this.paths=this.localShapeCollection,this.paths.addShape(this.v),this.lastFrame=-999999,this.reset=resetShape,this._caching={lastFrame:-999999,lastIndex:0},this.effectsSequence=[interpolateShapeCurrentTime.bind(this)]}ShapeProperty.prototype.interpolateShape=interpolateShape,ShapeProperty.prototype.getValue=processEffectsSequence,ShapeProperty.prototype.setVValue=setVValue,ShapeProperty.prototype.addEffect=addEffect,KeyframedShapeProperty.prototype.getValue=processEffectsSequence,KeyframedShapeProperty.prototype.interpolateShape=interpolateShape,KeyframedShapeProperty.prototype.setVValue=setVValue,KeyframedShapeProperty.prototype.addEffect=addEffect;var EllShapeProperty=function(){function EllShapePropertyFactory(elem,data){this.v=shapePool.newElement(),this.v.setPathData(!0,4),this.localShapeCollection=shapeCollectionPool.newShapeCollection(),this.paths=this.localShapeCollection,this.localShapeCollection.addShape(this.v),this.d=data.d,this.elem=elem,this.comp=elem.comp,this.frameId=-1,this.initDynamicPropertyContainer(elem),this.p=PropertyFactory.getProp(elem,data.p,1,0,this),this.s=PropertyFactory.getProp(elem,data.s,1,0,this),this.dynamicProperties.length?this.k=!0:(this.k=!1,this.convertEllToPath())}return EllShapePropertyFactory.prototype={reset:resetShape,getValue:function getValue(){this.elem.globalData.frameId!==this.frameId&&(this.frameId=this.elem.globalData.frameId,this.iterateDynamicProperties(),this._mdf&&this.convertEllToPath())},convertEllToPath:function convertEllToPath(){var p0=this.p.v[0],p1=this.p.v[1],s0=this.s.v[0]/2,s1=this.s.v[1]/2,_cw=3!==this.d,_v=this.v;_v.v[0][0]=p0,_v.v[0][1]=p1-s1,_v.v[1][0]=_cw?p0+s0:p0-s0,_v.v[1][1]=p1,_v.v[2][0]=p0,_v.v[2][1]=p1+s1,_v.v[3][0]=_cw?p0-s0:p0+s0,_v.v[3][1]=p1,_v.i[0][0]=_cw?p0-.5519*s0:p0+.5519*s0,_v.i[0][1]=p1-s1,_v.i[1][0]=_cw?p0+s0:p0-s0,_v.i[1][1]=p1-.5519*s1,_v.i[2][0]=_cw?p0+.5519*s0:p0-.5519*s0,_v.i[2][1]=p1+s1,_v.i[3][0]=_cw?p0-s0:p0+s0,_v.i[3][1]=p1+.5519*s1,_v.o[0][0]=_cw?p0+.5519*s0:p0-.5519*s0,_v.o[0][1]=p1-s1,_v.o[1][0]=_cw?p0+s0:p0-s0,_v.o[1][1]=p1+.5519*s1,_v.o[2][0]=_cw?p0-.5519*s0:p0+.5519*s0,_v.o[2][1]=p1+s1,_v.o[3][0]=_cw?p0-s0:p0+s0,_v.o[3][1]=p1-.5519*s1}},extendPrototype([DynamicPropertyContainer],EllShapePropertyFactory),EllShapePropertyFactory}(),StarShapeProperty=function(){function StarShapePropertyFactory(elem,data){this.v=shapePool.newElement(),this.v.setPathData(!0,0),this.elem=elem,this.comp=elem.comp,this.data=data,this.frameId=-1,this.d=data.d,this.initDynamicPropertyContainer(elem),1===data.sy?(this.ir=PropertyFactory.getProp(elem,data.ir,0,0,this),this.is=PropertyFactory.getProp(elem,data.is,0,.01,this),this.convertToPath=this.convertStarToPath):this.convertToPath=this.convertPolygonToPath,this.pt=PropertyFactory.getProp(elem,data.pt,0,0,this),this.p=PropertyFactory.getProp(elem,data.p,1,0,this),this.r=PropertyFactory.getProp(elem,data.r,0,degToRads,this),this.or=PropertyFactory.getProp(elem,data.or,0,0,this),this.os=PropertyFactory.getProp(elem,data.os,0,.01,this),this.localShapeCollection=shapeCollectionPool.newShapeCollection(),this.localShapeCollection.addShape(this.v),this.paths=this.localShapeCollection,this.dynamicProperties.length?this.k=!0:(this.k=!1,this.convertToPath())}return StarShapePropertyFactory.prototype={reset:resetShape,getValue:function getValue(){this.elem.globalData.frameId!==this.frameId&&(this.frameId=this.elem.globalData.frameId,this.iterateDynamicProperties(),this._mdf&&this.convertToPath())},convertStarToPath:function convertStarToPath(){var i,rad,roundness,perimSegment,numPts=2*Math.floor(this.pt.v),angle=2*Math.PI/numPts,longFlag=!0,longRad=this.or.v,shortRad=this.ir.v,longRound=this.os.v,shortRound=this.is.v,longPerimSegment=2*Math.PI*longRad/(2*numPts),shortPerimSegment=2*Math.PI*shortRad/(2*numPts),currentAng=-Math.PI/2;currentAng+=this.r.v;var dir=3===this.data.d?-1:1;for(i=0,this.v._length=0;i<numPts;i+=1){rad=longFlag?longRad:shortRad,roundness=longFlag?longRound:shortRound,perimSegment=longFlag?longPerimSegment:shortPerimSegment;var x=rad*Math.cos(currentAng),y=rad*Math.sin(currentAng),ox=0===x&&0===y?0:y/Math.sqrt(x*x+y*y),oy=0===x&&0===y?0:-x/Math.sqrt(x*x+y*y);x+=+this.p.v[0],y+=+this.p.v[1],this.v.setTripleAt(x,y,x-ox*perimSegment*roundness*dir,y-oy*perimSegment*roundness*dir,x+ox*perimSegment*roundness*dir,y+oy*perimSegment*roundness*dir,i,!0),longFlag=!longFlag,currentAng+=angle*dir}},convertPolygonToPath:function convertPolygonToPath(){var i,numPts=Math.floor(this.pt.v),angle=2*Math.PI/numPts,rad=this.or.v,roundness=this.os.v,perimSegment=2*Math.PI*rad/(4*numPts),currentAng=-(.5*Math.PI),dir=3===this.data.d?-1:1;for(currentAng+=this.r.v,this.v._length=0,i=0;i<numPts;i+=1){var x=rad*Math.cos(currentAng),y=rad*Math.sin(currentAng),ox=0===x&&0===y?0:y/Math.sqrt(x*x+y*y),oy=0===x&&0===y?0:-x/Math.sqrt(x*x+y*y);x+=+this.p.v[0],y+=+this.p.v[1],this.v.setTripleAt(x,y,x-ox*perimSegment*roundness*dir,y-oy*perimSegment*roundness*dir,x+ox*perimSegment*roundness*dir,y+oy*perimSegment*roundness*dir,i,!0),currentAng+=angle*dir}this.paths.length=0,this.paths[0]=this.v}},extendPrototype([DynamicPropertyContainer],StarShapePropertyFactory),StarShapePropertyFactory}(),RectShapeProperty=function(){function RectShapePropertyFactory(elem,data){this.v=shapePool.newElement(),this.v.c=!0,this.localShapeCollection=shapeCollectionPool.newShapeCollection(),this.localShapeCollection.addShape(this.v),this.paths=this.localShapeCollection,this.elem=elem,this.comp=elem.comp,this.frameId=-1,this.d=data.d,this.initDynamicPropertyContainer(elem),this.p=PropertyFactory.getProp(elem,data.p,1,0,this),this.s=PropertyFactory.getProp(elem,data.s,1,0,this),this.r=PropertyFactory.getProp(elem,data.r,0,0,this),this.dynamicProperties.length?this.k=!0:(this.k=!1,this.convertRectToPath())}return RectShapePropertyFactory.prototype={convertRectToPath:function convertRectToPath(){var p0=this.p.v[0],p1=this.p.v[1],v0=this.s.v[0]/2,v1=this.s.v[1]/2,round=bmMin(v0,v1,this.r.v),cPoint=.44810000000000005*round;this.v._length=0,2===this.d||1===this.d?(this.v.setTripleAt(p0+v0,p1-v1+round,p0+v0,p1-v1+round,p0+v0,p1-v1+cPoint,0,!0),this.v.setTripleAt(p0+v0,p1+v1-round,p0+v0,p1+v1-cPoint,p0+v0,p1+v1-round,1,!0),0!==round?(this.v.setTripleAt(p0+v0-round,p1+v1,p0+v0-round,p1+v1,p0+v0-cPoint,p1+v1,2,!0),this.v.setTripleAt(p0-v0+round,p1+v1,p0-v0+cPoint,p1+v1,p0-v0+round,p1+v1,3,!0),this.v.setTripleAt(p0-v0,p1+v1-round,p0-v0,p1+v1-round,p0-v0,p1+v1-cPoint,4,!0),this.v.setTripleAt(p0-v0,p1-v1+round,p0-v0,p1-v1+cPoint,p0-v0,p1-v1+round,5,!0),this.v.setTripleAt(p0-v0+round,p1-v1,p0-v0+round,p1-v1,p0-v0+cPoint,p1-v1,6,!0),this.v.setTripleAt(p0+v0-round,p1-v1,p0+v0-cPoint,p1-v1,p0+v0-round,p1-v1,7,!0)):(this.v.setTripleAt(p0-v0,p1+v1,p0-v0+cPoint,p1+v1,p0-v0,p1+v1,2),this.v.setTripleAt(p0-v0,p1-v1,p0-v0,p1-v1+cPoint,p0-v0,p1-v1,3))):(this.v.setTripleAt(p0+v0,p1-v1+round,p0+v0,p1-v1+cPoint,p0+v0,p1-v1+round,0,!0),0!==round?(this.v.setTripleAt(p0+v0-round,p1-v1,p0+v0-round,p1-v1,p0+v0-cPoint,p1-v1,1,!0),this.v.setTripleAt(p0-v0+round,p1-v1,p0-v0+cPoint,p1-v1,p0-v0+round,p1-v1,2,!0),this.v.setTripleAt(p0-v0,p1-v1+round,p0-v0,p1-v1+round,p0-v0,p1-v1+cPoint,3,!0),this.v.setTripleAt(p0-v0,p1+v1-round,p0-v0,p1+v1-cPoint,p0-v0,p1+v1-round,4,!0),this.v.setTripleAt(p0-v0+round,p1+v1,p0-v0+round,p1+v1,p0-v0+cPoint,p1+v1,5,!0),this.v.setTripleAt(p0+v0-round,p1+v1,p0+v0-cPoint,p1+v1,p0+v0-round,p1+v1,6,!0),this.v.setTripleAt(p0+v0,p1+v1-round,p0+v0,p1+v1-round,p0+v0,p1+v1-cPoint,7,!0)):(this.v.setTripleAt(p0-v0,p1-v1,p0-v0+cPoint,p1-v1,p0-v0,p1-v1,1,!0),this.v.setTripleAt(p0-v0,p1+v1,p0-v0,p1+v1-cPoint,p0-v0,p1+v1,2,!0),this.v.setTripleAt(p0+v0,p1+v1,p0+v0-cPoint,p1+v1,p0+v0,p1+v1,3,!0)))},getValue:function getValue(){this.elem.globalData.frameId!==this.frameId&&(this.frameId=this.elem.globalData.frameId,this.iterateDynamicProperties(),this._mdf&&this.convertRectToPath())},reset:resetShape},extendPrototype([DynamicPropertyContainer],RectShapePropertyFactory),RectShapePropertyFactory}();function getShapeProp(elem,data,type){var prop;return 3===type||4===type?prop=(3===type?data.pt:data.ks).k.length?new KeyframedShapeProperty(elem,data,type):new ShapeProperty(elem,data,type):5===type?prop=new RectShapeProperty(elem,data):6===type?prop=new EllShapeProperty(elem,data):7===type&&(prop=new StarShapeProperty(elem,data)),prop.k&&elem.addDynamicProperty(prop),prop}function getConstructorFunction(){return ShapeProperty}function getKeyframedConstructorFunction(){return KeyframedShapeProperty}var ob={};return ob.getShapeProp=getShapeProp,ob.getConstructorFunction=getConstructorFunction,ob.getKeyframedConstructorFunction=getKeyframedConstructorFunction,ob}(),Matrix=function(){var _cos=Math.cos,_sin=Math.sin,_tan=Math.tan,_rnd=Math.round;function reset(){return this.props[0]=1,this.props[1]=0,this.props[2]=0,this.props[3]=0,this.props[4]=0,this.props[5]=1,this.props[6]=0,this.props[7]=0,this.props[8]=0,this.props[9]=0,this.props[10]=1,this.props[11]=0,this.props[12]=0,this.props[13]=0,this.props[14]=0,this.props[15]=1,this}function rotate(angle){if(0===angle)return this;var mCos=_cos(angle),mSin=_sin(angle);return this._t(mCos,-mSin,0,0,mSin,mCos,0,0,0,0,1,0,0,0,0,1)}function rotateX(angle){if(0===angle)return this;var mCos=_cos(angle),mSin=_sin(angle);return this._t(1,0,0,0,0,mCos,-mSin,0,0,mSin,mCos,0,0,0,0,1)}function rotateY(angle){if(0===angle)return this;var mCos=_cos(angle),mSin=_sin(angle);return this._t(mCos,0,mSin,0,0,1,0,0,-mSin,0,mCos,0,0,0,0,1)}function rotateZ(angle){if(0===angle)return this;var mCos=_cos(angle),mSin=_sin(angle);return this._t(mCos,-mSin,0,0,mSin,mCos,0,0,0,0,1,0,0,0,0,1)}function shear(sx,sy){return this._t(1,sy,sx,1,0,0)}function skew(ax,ay){return this.shear(_tan(ax),_tan(ay))}function skewFromAxis(ax,angle){var mCos=_cos(angle),mSin=_sin(angle);return this._t(mCos,mSin,0,0,-mSin,mCos,0,0,0,0,1,0,0,0,0,1)._t(1,0,0,0,_tan(ax),1,0,0,0,0,1,0,0,0,0,1)._t(mCos,-mSin,0,0,mSin,mCos,0,0,0,0,1,0,0,0,0,1)}function scale(sx,sy,sz){return(sz||0===sz||(sz=1),1===sx&&1===sy&&1===sz)?this:this._t(sx,0,0,0,0,sy,0,0,0,0,sz,0,0,0,0,1)}function setTransform(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p){return this.props[0]=a,this.props[1]=b,this.props[2]=c,this.props[3]=d,this.props[4]=e,this.props[5]=f,this.props[6]=g,this.props[7]=h,this.props[8]=i,this.props[9]=j,this.props[10]=k,this.props[11]=l,this.props[12]=m,this.props[13]=n,this.props[14]=o,this.props[15]=p,this}function translate(tx,ty,tz){return(tz=tz||0,0!==tx||0!==ty||0!==tz)?this._t(1,0,0,0,0,1,0,0,0,0,1,0,tx,ty,tz,1):this}function transform(a2,b2,c2,d2,e2,f2,g2,h2,i2,j2,k2,l2,m2,n2,o2,p2){var _p=this.props;if(1===a2&&0===b2&&0===c2&&0===d2&&0===e2&&1===f2&&0===g2&&0===h2&&0===i2&&0===j2&&1===k2&&0===l2)return _p[12]=_p[12]*a2+_p[15]*m2,_p[13]=_p[13]*f2+_p[15]*n2,_p[14]=_p[14]*k2+_p[15]*o2,_p[15]*=p2,this._identityCalculated=!1,this;var a1=_p[0],b1=_p[1],c1=_p[2],d1=_p[3],e1=_p[4],f1=_p[5],g1=_p[6],h1=_p[7],i1=_p[8],j1=_p[9],k1=_p[10],l1=_p[11],m1=_p[12],n1=_p[13],o1=_p[14],p1=_p[15];return _p[0]=a1*a2+b1*e2+c1*i2+d1*m2,_p[1]=a1*b2+b1*f2+c1*j2+d1*n2,_p[2]=a1*c2+b1*g2+c1*k2+d1*o2,_p[3]=a1*d2+b1*h2+c1*l2+d1*p2,_p[4]=e1*a2+f1*e2+g1*i2+h1*m2,_p[5]=e1*b2+f1*f2+g1*j2+h1*n2,_p[6]=e1*c2+f1*g2+g1*k2+h1*o2,_p[7]=e1*d2+f1*h2+g1*l2+h1*p2,_p[8]=i1*a2+j1*e2+k1*i2+l1*m2,_p[9]=i1*b2+j1*f2+k1*j2+l1*n2,_p[10]=i1*c2+j1*g2+k1*k2+l1*o2,_p[11]=i1*d2+j1*h2+k1*l2+l1*p2,_p[12]=m1*a2+n1*e2+o1*i2+p1*m2,_p[13]=m1*b2+n1*f2+o1*j2+p1*n2,_p[14]=m1*c2+n1*g2+o1*k2+p1*o2,_p[15]=m1*d2+n1*h2+o1*l2+p1*p2,this._identityCalculated=!1,this}function multiply(matrix){var matrixProps=matrix.props;return this.transform(matrixProps[0],matrixProps[1],matrixProps[2],matrixProps[3],matrixProps[4],matrixProps[5],matrixProps[6],matrixProps[7],matrixProps[8],matrixProps[9],matrixProps[10],matrixProps[11],matrixProps[12],matrixProps[13],matrixProps[14],matrixProps[15])}function isIdentity(){return this._identityCalculated||(this._identity=!(1!==this.props[0]||0!==this.props[1]||0!==this.props[2]||0!==this.props[3]||0!==this.props[4]||1!==this.props[5]||0!==this.props[6]||0!==this.props[7]||0!==this.props[8]||0!==this.props[9]||1!==this.props[10]||0!==this.props[11]||0!==this.props[12]||0!==this.props[13]||0!==this.props[14]||1!==this.props[15]),this._identityCalculated=!0),this._identity}function equals(matr){for(var i=0;i<16;){if(matr.props[i]!==this.props[i])return!1;i+=1}return!0}function clone(matr){var i;for(i=0;i<16;i+=1)matr.props[i]=this.props[i];return matr}function cloneFromProps(props){var i;for(i=0;i<16;i+=1)this.props[i]=props[i]}function applyToPoint(x,y,z){return{x:x*this.props[0]+y*this.props[4]+z*this.props[8]+this.props[12],y:x*this.props[1]+y*this.props[5]+z*this.props[9]+this.props[13],z:x*this.props[2]+y*this.props[6]+z*this.props[10]+this.props[14]}}function applyToX(x,y,z){return x*this.props[0]+y*this.props[4]+z*this.props[8]+this.props[12]}function applyToY(x,y,z){return x*this.props[1]+y*this.props[5]+z*this.props[9]+this.props[13]}function applyToZ(x,y,z){return x*this.props[2]+y*this.props[6]+z*this.props[10]+this.props[14]}function getInverseMatrix(){var determinant=this.props[0]*this.props[5]-this.props[1]*this.props[4],a=this.props[5]/determinant,b=-this.props[1]/determinant,c=-this.props[4]/determinant,d=this.props[0]/determinant,e=(this.props[4]*this.props[13]-this.props[5]*this.props[12])/determinant,f=-(this.props[0]*this.props[13]-this.props[1]*this.props[12])/determinant,inverseMatrix=new Matrix;return inverseMatrix.props[0]=a,inverseMatrix.props[1]=b,inverseMatrix.props[4]=c,inverseMatrix.props[5]=d,inverseMatrix.props[12]=e,inverseMatrix.props[13]=f,inverseMatrix}function inversePoint(pt){return this.getInverseMatrix().applyToPointArray(pt[0],pt[1],pt[2]||0)}function inversePoints(pts){var i,len=pts.length,retPts=[];for(i=0;i<len;i+=1)retPts[i]=inversePoint(pts[i]);return retPts}function applyToTriplePoints(pt1,pt2,pt3){var arr=createTypedArray("float32",6);if(this.isIdentity())arr[0]=pt1[0],arr[1]=pt1[1],arr[2]=pt2[0],arr[3]=pt2[1],arr[4]=pt3[0],arr[5]=pt3[1];else{var p0=this.props[0],p1=this.props[1],p4=this.props[4],p5=this.props[5],p12=this.props[12],p13=this.props[13];arr[0]=pt1[0]*p0+pt1[1]*p4+p12,arr[1]=pt1[0]*p1+pt1[1]*p5+p13,arr[2]=pt2[0]*p0+pt2[1]*p4+p12,arr[3]=pt2[0]*p1+pt2[1]*p5+p13,arr[4]=pt3[0]*p0+pt3[1]*p4+p12,arr[5]=pt3[0]*p1+pt3[1]*p5+p13}return arr}function applyToPointArray(x,y,z){return this.isIdentity()?[x,y,z]:[x*this.props[0]+y*this.props[4]+z*this.props[8]+this.props[12],x*this.props[1]+y*this.props[5]+z*this.props[9]+this.props[13],x*this.props[2]+y*this.props[6]+z*this.props[10]+this.props[14]]}function applyToPointStringified(x,y){if(this.isIdentity())return x+","+y;var _p=this.props;return Math.round((x*_p[0]+y*_p[4]+_p[12])*100)/100+","+Math.round((x*_p[1]+y*_p[5]+_p[13])*100)/100}function toCSS(){for(var i=0,props=this.props,cssValue="matrix3d(";i<16;)cssValue+=_rnd(1e4*props[i])/1e4+(15===i?")":","),i+=1;return cssValue}function roundMatrixProperty(val){return val<1e-6&&val>0||val>-.000001&&val<0?_rnd(1e4*val)/1e4:val}function to2dCSS(){var props=this.props;return"matrix("+roundMatrixProperty(props[0])+","+roundMatrixProperty(props[1])+","+roundMatrixProperty(props[4])+","+roundMatrixProperty(props[5])+","+roundMatrixProperty(props[12])+","+roundMatrixProperty(props[13])+")"}return function(){this.reset=reset,this.rotate=rotate,this.rotateX=rotateX,this.rotateY=rotateY,this.rotateZ=rotateZ,this.skew=skew,this.skewFromAxis=skewFromAxis,this.shear=shear,this.scale=scale,this.setTransform=setTransform,this.translate=translate,this.transform=transform,this.multiply=multiply,this.applyToPoint=applyToPoint,this.applyToX=applyToX,this.applyToY=applyToY,this.applyToZ=applyToZ,this.applyToPointArray=applyToPointArray,this.applyToTriplePoints=applyToTriplePoints,this.applyToPointStringified=applyToPointStringified,this.toCSS=toCSS,this.to2dCSS=to2dCSS,this.clone=clone,this.cloneFromProps=cloneFromProps,this.equals=equals,this.inversePoints=inversePoints,this.inversePoint=inversePoint,this.getInverseMatrix=getInverseMatrix,this._t=this.transform,this.isIdentity=isIdentity,this._identity=!0,this._identityCalculated=!1,this.props=createTypedArray("float32",16),this.reset()}}();function _typeof(obj){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function _typeof(obj){return typeof obj}:function _typeof(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj})(obj)}var lottie={},standalone="__[STANDALONE]__",animationData="__[ANIMATIONDATA]__",renderer="";function setLocation(href){setLocationHref(href)}function searchAnimations(){!0===standalone?animationManager.searchAnimations(animationData,standalone,renderer):animationManager.searchAnimations()}function setSubframeRendering(flag){setSubframeEnabled(flag)}function setPrefix(prefix){setIdPrefix(prefix)}function loadAnimation(params){return!0===standalone&&(params.animationData=JSON.parse(animationData)),animationManager.loadAnimation(params)}function setQuality(value){if("string"==typeof value)switch(value){case"high":setDefaultCurveSegments(200);break;default:case"medium":setDefaultCurveSegments(50);break;case"low":setDefaultCurveSegments(10)}else!isNaN(value)&&value>1&&setDefaultCurveSegments(value);getDefaultCurveSegments()}function inBrowser(){return"undefined"!=typeof navigator}function installPlugin(type,plugin){"expressions"===type&&setExpressionsPlugin(plugin)}function getFactory(name){switch(name){case"propertyFactory":return PropertyFactory;case"shapePropertyFactory":return ShapePropertyFactory;case"matrix":return Matrix;default:return null}}function checkReady(){"complete"===document.readyState&&(clearInterval(readyStateCheckInterval),searchAnimations())}function getQueryVariable(variable){for(var vars=queryString.split("&"),i=0;i<vars.length;i+=1){var pair=vars[i].split("=");if(decodeURIComponent(pair[0])==variable)return decodeURIComponent(pair[1])}return null}lottie.play=animationManager.play,lottie.pause=animationManager.pause,lottie.setLocationHref=setLocation,lottie.togglePause=animationManager.togglePause,lottie.setSpeed=animationManager.setSpeed,lottie.setDirection=animationManager.setDirection,lottie.stop=animationManager.stop,lottie.searchAnimations=searchAnimations,lottie.registerAnimation=animationManager.registerAnimation,lottie.loadAnimation=loadAnimation,lottie.setSubframeRendering=setSubframeRendering,lottie.resize=animationManager.resize,lottie.goToAndStop=animationManager.goToAndStop,lottie.destroy=animationManager.destroy,lottie.setQuality=setQuality,lottie.inBrowser=inBrowser,lottie.installPlugin=installPlugin,lottie.freeze=animationManager.freeze,lottie.unfreeze=animationManager.unfreeze,lottie.setVolume=animationManager.setVolume,lottie.mute=animationManager.mute,lottie.unmute=animationManager.unmute,lottie.getRegisteredAnimations=animationManager.getRegisteredAnimations,lottie.useWebWorker=function setWebWorker(flag){_useWebWorker=!!flag},lottie.setIDPrefix=setPrefix,lottie.__getFactory=getFactory,lottie.version="5.12.2";var queryString="";if(standalone){var scripts=document.getElementsByTagName("script"),index=scripts.length-1,myScript=scripts[index]||{src:""};queryString=myScript.src?myScript.src.replace(/^[^\?]+\??/,""):"",renderer=getQueryVariable("renderer")}var readyStateCheckInterval=setInterval(checkReady,100);try{"object"!==_typeof(exports)&&__webpack_require__.amdO}catch(err){}var ShapeModifiers=function(){var ob={},modifiers={};function registerModifier(nm,factory){modifiers[nm]||(modifiers[nm]=factory)}function getModifier(nm,elem,data){return new modifiers[nm](elem,data)}return ob.registerModifier=registerModifier,ob.getModifier=getModifier,ob}();function ShapeModifier(){}function TrimModifier(){}function PuckerAndBloatModifier(){}ShapeModifier.prototype.initModifierProperties=function(){},ShapeModifier.prototype.addShapeToModifier=function(){},ShapeModifier.prototype.addShape=function(data){if(!this.closed){data.sh.container.addDynamicProperty(data.sh);var shapeData={shape:data.sh,data:data,localShapeCollection:shapeCollectionPool.newShapeCollection()};this.shapes.push(shapeData),this.addShapeToModifier(shapeData),this._isAnimated&&data.setAsAnimated()}},ShapeModifier.prototype.init=function(elem,data){this.shapes=[],this.elem=elem,this.initDynamicPropertyContainer(elem),this.initModifierProperties(elem,data),this.frameId=-999999,this.closed=!1,this.k=!1,this.dynamicProperties.length?this.k=!0:this.getValue(!0)},ShapeModifier.prototype.processKeys=function(){this.elem.globalData.frameId!==this.frameId&&(this.frameId=this.elem.globalData.frameId,this.iterateDynamicProperties())},extendPrototype([DynamicPropertyContainer],ShapeModifier),extendPrototype([ShapeModifier],TrimModifier),TrimModifier.prototype.initModifierProperties=function(elem,data){this.s=PropertyFactory.getProp(elem,data.s,0,.01,this),this.e=PropertyFactory.getProp(elem,data.e,0,.01,this),this.o=PropertyFactory.getProp(elem,data.o,0,0,this),this.sValue=0,this.eValue=0,this.getValue=this.processKeys,this.m=data.m,this._isAnimated=!!this.s.effectsSequence.length||!!this.e.effectsSequence.length||!!this.o.effectsSequence.length},TrimModifier.prototype.addShapeToModifier=function(shapeData){shapeData.pathsData=[]},TrimModifier.prototype.calculateShapeEdges=function(s,e,shapeLength,addedLength,totalModifierLength){var i,segmentOb,segments=[];e<=1?segments.push({s:s,e:e}):s>=1?segments.push({s:s-1,e:e-1}):(segments.push({s:s,e:1}),segments.push({s:0,e:e-1}));var shapeSegments=[],len=segments.length;for(i=0;i<len;i+=1)(segmentOb=segments[i]).e*totalModifierLength<addedLength||segmentOb.s*totalModifierLength>addedLength+shapeLength||shapeSegments.push([segmentOb.s*totalModifierLength<=addedLength?0:(segmentOb.s*totalModifierLength-addedLength)/shapeLength,segmentOb.e*totalModifierLength>=addedLength+shapeLength?1:(segmentOb.e*totalModifierLength-addedLength)/shapeLength]);return shapeSegments.length||shapeSegments.push([0,0]),shapeSegments},TrimModifier.prototype.releasePathsData=function(pathsData){var i,len=pathsData.length;for(i=0;i<len;i+=1)segmentsLengthPool.release(pathsData[i]);return pathsData.length=0,pathsData},TrimModifier.prototype.processShapes=function(_isFirstFrame){if(this._mdf||_isFirstFrame){var o=this.o.v%360/360;if(o<0&&(o+=1),(s=this.s.v>1?1+o:this.s.v<0?0+o:this.s.v+o)>(e=this.e.v>1?1+o:this.e.v<0?0+o:this.e.v+o)){var _s=s;s=e,e=_s}s=1e-4*Math.round(1e4*s),e=1e-4*Math.round(1e4*e),this.sValue=s,this.eValue=e}else s=this.sValue,e=this.eValue;var len=this.shapes.length,totalModifierLength=0;if(e===s)for(i=0;i<len;i+=1)this.shapes[i].localShapeCollection.releaseShapes(),this.shapes[i].shape._mdf=!0,this.shapes[i].shape.paths=this.shapes[i].localShapeCollection,this._mdf&&(this.shapes[i].pathsData.length=0);else if(1===e&&0===s||0===e&&1===s){if(this._mdf)for(i=0;i<len;i+=1)this.shapes[i].pathsData.length=0,this.shapes[i].shape._mdf=!0}else{var s,e,shapePaths,i,j,jLen,pathsData,pathData,totalShapeLength,shapeData,localShapeCollection,edges,segments=[];for(i=0;i<len;i+=1)if((shapeData=this.shapes[i]).shape._mdf||this._mdf||_isFirstFrame||2===this.m){if(jLen=(shapePaths=shapeData.shape.paths)._length,totalShapeLength=0,!shapeData.shape._mdf&&shapeData.pathsData.length)totalShapeLength=shapeData.totalShapeLength;else{for(j=0,pathsData=this.releasePathsData(shapeData.pathsData);j<jLen;j+=1)pathData=bez.getSegmentsLength(shapePaths.shapes[j]),pathsData.push(pathData),totalShapeLength+=pathData.totalLength;shapeData.totalShapeLength=totalShapeLength,shapeData.pathsData=pathsData}totalModifierLength+=totalShapeLength,shapeData.shape._mdf=!0}else shapeData.shape.paths=shapeData.localShapeCollection;var shapeS=s,shapeE=e,addedLength=0;for(i=len-1;i>=0;i-=1)if((shapeData=this.shapes[i]).shape._mdf){for((localShapeCollection=shapeData.localShapeCollection).releaseShapes(),2===this.m&&len>1?(edges=this.calculateShapeEdges(s,e,shapeData.totalShapeLength,addedLength,totalModifierLength),addedLength+=shapeData.totalShapeLength):edges=[[shapeS,shapeE]],jLen=edges.length,j=0;j<jLen;j+=1){shapeS=edges[j][0],shapeE=edges[j][1],segments.length=0,shapeE<=1?segments.push({s:shapeData.totalShapeLength*shapeS,e:shapeData.totalShapeLength*shapeE}):shapeS>=1?segments.push({s:shapeData.totalShapeLength*(shapeS-1),e:shapeData.totalShapeLength*(shapeE-1)}):(segments.push({s:shapeData.totalShapeLength*shapeS,e:shapeData.totalShapeLength}),segments.push({s:0,e:shapeData.totalShapeLength*(shapeE-1)}));var newShapesData=this.addShapes(shapeData,segments[0]);if(segments[0].s!==segments[0].e){if(segments.length>1){if(shapeData.shape.paths.shapes[shapeData.shape.paths._length-1].c){var lastShape=newShapesData.pop();this.addPaths(newShapesData,localShapeCollection),newShapesData=this.addShapes(shapeData,segments[1],lastShape)}else this.addPaths(newShapesData,localShapeCollection),newShapesData=this.addShapes(shapeData,segments[1])}this.addPaths(newShapesData,localShapeCollection)}}shapeData.shape.paths=localShapeCollection}}},TrimModifier.prototype.addPaths=function(newPaths,localShapeCollection){var i,len=newPaths.length;for(i=0;i<len;i+=1)localShapeCollection.addShape(newPaths[i])},TrimModifier.prototype.addSegment=function(pt1,pt2,pt3,pt4,shapePath,pos,newShape){shapePath.setXYAt(pt2[0],pt2[1],"o",pos),shapePath.setXYAt(pt3[0],pt3[1],"i",pos+1),newShape&&shapePath.setXYAt(pt1[0],pt1[1],"v",pos),shapePath.setXYAt(pt4[0],pt4[1],"v",pos+1)},TrimModifier.prototype.addSegmentFromArray=function(points,shapePath,pos,newShape){shapePath.setXYAt(points[1],points[5],"o",pos),shapePath.setXYAt(points[2],points[6],"i",pos+1),newShape&&shapePath.setXYAt(points[0],points[4],"v",pos),shapePath.setXYAt(points[3],points[7],"v",pos+1)},TrimModifier.prototype.addShapes=function(shapeData,shapeSegment,shapePath){var i,j,jLen,currentLengthData,segmentCount,lengths,segment,initPos,pathsData=shapeData.pathsData,shapePaths=shapeData.shape.paths.shapes,len=shapeData.shape.paths._length,addedLength=0,shapes=[],newShape=!0;for(shapePath?(segmentCount=shapePath._length,initPos=shapePath._length):(shapePath=shapePool.newElement(),segmentCount=0,initPos=0),shapes.push(shapePath),i=0;i<len;i+=1){for(j=1,lengths=pathsData[i].lengths,shapePath.c=shapePaths[i].c,jLen=shapePaths[i].c?lengths.length:lengths.length+1;j<jLen;j+=1)if(addedLength+(currentLengthData=lengths[j-1]).addedLength<shapeSegment.s)addedLength+=currentLengthData.addedLength,shapePath.c=!1;else if(addedLength>shapeSegment.e){shapePath.c=!1;break}else shapeSegment.s<=addedLength&&shapeSegment.e>=addedLength+currentLengthData.addedLength?(this.addSegment(shapePaths[i].v[j-1],shapePaths[i].o[j-1],shapePaths[i].i[j],shapePaths[i].v[j],shapePath,segmentCount,newShape),newShape=!1):(segment=bez.getNewSegment(shapePaths[i].v[j-1],shapePaths[i].v[j],shapePaths[i].o[j-1],shapePaths[i].i[j],(shapeSegment.s-addedLength)/currentLengthData.addedLength,(shapeSegment.e-addedLength)/currentLengthData.addedLength,lengths[j-1]),this.addSegmentFromArray(segment,shapePath,segmentCount,newShape),newShape=!1,shapePath.c=!1),addedLength+=currentLengthData.addedLength,segmentCount+=1;if(shapePaths[i].c&&lengths.length){if(currentLengthData=lengths[j-1],addedLength<=shapeSegment.e){var segmentLength=lengths[j-1].addedLength;shapeSegment.s<=addedLength&&shapeSegment.e>=addedLength+segmentLength?(this.addSegment(shapePaths[i].v[j-1],shapePaths[i].o[j-1],shapePaths[i].i[0],shapePaths[i].v[0],shapePath,segmentCount,newShape),newShape=!1):(segment=bez.getNewSegment(shapePaths[i].v[j-1],shapePaths[i].v[0],shapePaths[i].o[j-1],shapePaths[i].i[0],(shapeSegment.s-addedLength)/segmentLength,(shapeSegment.e-addedLength)/segmentLength,lengths[j-1]),this.addSegmentFromArray(segment,shapePath,segmentCount,newShape),newShape=!1,shapePath.c=!1)}else shapePath.c=!1;addedLength+=currentLengthData.addedLength,segmentCount+=1}if(shapePath._length&&(shapePath.setXYAt(shapePath.v[initPos][0],shapePath.v[initPos][1],"i",initPos),shapePath.setXYAt(shapePath.v[shapePath._length-1][0],shapePath.v[shapePath._length-1][1],"o",shapePath._length-1)),addedLength>shapeSegment.e)break;i<len-1&&(shapePath=shapePool.newElement(),newShape=!0,shapes.push(shapePath),segmentCount=0)}return shapes},extendPrototype([ShapeModifier],PuckerAndBloatModifier),PuckerAndBloatModifier.prototype.initModifierProperties=function(elem,data){this.getValue=this.processKeys,this.amount=PropertyFactory.getProp(elem,data.a,0,null,this),this._isAnimated=!!this.amount.effectsSequence.length},PuckerAndBloatModifier.prototype.processPath=function(path,amount){var vX,vY,oX,oY,iX,iY,percent=amount/100,centerPoint=[0,0],pathLength=path._length,i=0;for(i=0;i<pathLength;i+=1)centerPoint[0]+=path.v[i][0],centerPoint[1]+=path.v[i][1];centerPoint[0]/=pathLength,centerPoint[1]/=pathLength;var clonedPath=shapePool.newElement();for(i=0,clonedPath.c=path.c;i<pathLength;i+=1)vX=path.v[i][0]+(centerPoint[0]-path.v[i][0])*percent,vY=path.v[i][1]+(centerPoint[1]-path.v[i][1])*percent,oX=path.o[i][0]+-((centerPoint[0]-path.o[i][0])*percent),oY=path.o[i][1]+-((centerPoint[1]-path.o[i][1])*percent),iX=path.i[i][0]+-((centerPoint[0]-path.i[i][0])*percent),iY=path.i[i][1]+-((centerPoint[1]-path.i[i][1])*percent),clonedPath.setTripleAt(vX,vY,oX,oY,iX,iY,i);return clonedPath},PuckerAndBloatModifier.prototype.processShapes=function(_isFirstFrame){var shapePaths,i,j,jLen,shapeData,localShapeCollection,len=this.shapes.length,amount=this.amount.v;if(0!==amount)for(i=0;i<len;i+=1){if(localShapeCollection=(shapeData=this.shapes[i]).localShapeCollection,!(!shapeData.shape._mdf&&!this._mdf&&!_isFirstFrame))for(localShapeCollection.releaseShapes(),shapeData.shape._mdf=!0,shapePaths=shapeData.shape.paths.shapes,jLen=shapeData.shape.paths._length,j=0;j<jLen;j+=1)localShapeCollection.addShape(this.processPath(shapePaths[j],amount));shapeData.shape.paths=shapeData.localShapeCollection}this.dynamicProperties.length||(this._mdf=!1)};var TransformPropertyFactory=function(){var defaultVector=[0,0];function applyToMatrix(mat){var _mdf=this._mdf;this.iterateDynamicProperties(),this._mdf=this._mdf||_mdf,this.a&&mat.translate(-this.a.v[0],-this.a.v[1],this.a.v[2]),this.s&&mat.scale(this.s.v[0],this.s.v[1],this.s.v[2]),this.sk&&mat.skewFromAxis(-this.sk.v,this.sa.v),this.r?mat.rotate(-this.r.v):mat.rotateZ(-this.rz.v).rotateY(this.ry.v).rotateX(this.rx.v).rotateZ(-this.or.v[2]).rotateY(this.or.v[1]).rotateX(this.or.v[0]),this.data.p.s?this.data.p.z?mat.translate(this.px.v,this.py.v,-this.pz.v):mat.translate(this.px.v,this.py.v,0):mat.translate(this.p.v[0],this.p.v[1],-this.p.v[2])}function processKeys(forceRender){if(this.elem.globalData.frameId!==this.frameId){if(this._isDirty&&(this.precalculateMatrix(),this._isDirty=!1),this.iterateDynamicProperties(),this._mdf||forceRender){var frameRate;if(this.v.cloneFromProps(this.pre.props),this.appliedTransformations<1&&this.v.translate(-this.a.v[0],-this.a.v[1],this.a.v[2]),this.appliedTransformations<2&&this.v.scale(this.s.v[0],this.s.v[1],this.s.v[2]),this.sk&&this.appliedTransformations<3&&this.v.skewFromAxis(-this.sk.v,this.sa.v),this.r&&this.appliedTransformations<4?this.v.rotate(-this.r.v):!this.r&&this.appliedTransformations<4&&this.v.rotateZ(-this.rz.v).rotateY(this.ry.v).rotateX(this.rx.v).rotateZ(-this.or.v[2]).rotateY(this.or.v[1]).rotateX(this.or.v[0]),this.autoOriented){if(frameRate=this.elem.globalData.frameRate,this.p&&this.p.keyframes&&this.p.getValueAtTime)this.p._caching.lastFrame+this.p.offsetTime<=this.p.keyframes[0].t?(v1=this.p.getValueAtTime((this.p.keyframes[0].t+.01)/frameRate,0),v2=this.p.getValueAtTime(this.p.keyframes[0].t/frameRate,0)):this.p._caching.lastFrame+this.p.offsetTime>=this.p.keyframes[this.p.keyframes.length-1].t?(v1=this.p.getValueAtTime(this.p.keyframes[this.p.keyframes.length-1].t/frameRate,0),v2=this.p.getValueAtTime((this.p.keyframes[this.p.keyframes.length-1].t-.05)/frameRate,0)):(v1=this.p.pv,v2=this.p.getValueAtTime((this.p._caching.lastFrame+this.p.offsetTime-.01)/frameRate,this.p.offsetTime));else if(this.px&&this.px.keyframes&&this.py.keyframes&&this.px.getValueAtTime&&this.py.getValueAtTime){v1=[],v2=[];var v1,v2,px=this.px,py=this.py;px._caching.lastFrame+px.offsetTime<=px.keyframes[0].t?(v1[0]=px.getValueAtTime((px.keyframes[0].t+.01)/frameRate,0),v1[1]=py.getValueAtTime((py.keyframes[0].t+.01)/frameRate,0),v2[0]=px.getValueAtTime(px.keyframes[0].t/frameRate,0),v2[1]=py.getValueAtTime(py.keyframes[0].t/frameRate,0)):px._caching.lastFrame+px.offsetTime>=px.keyframes[px.keyframes.length-1].t?(v1[0]=px.getValueAtTime(px.keyframes[px.keyframes.length-1].t/frameRate,0),v1[1]=py.getValueAtTime(py.keyframes[py.keyframes.length-1].t/frameRate,0),v2[0]=px.getValueAtTime((px.keyframes[px.keyframes.length-1].t-.01)/frameRate,0),v2[1]=py.getValueAtTime((py.keyframes[py.keyframes.length-1].t-.01)/frameRate,0)):(v1=[px.pv,py.pv],v2[0]=px.getValueAtTime((px._caching.lastFrame+px.offsetTime-.01)/frameRate,px.offsetTime),v2[1]=py.getValueAtTime((py._caching.lastFrame+py.offsetTime-.01)/frameRate,py.offsetTime))}else v1=v2=defaultVector;this.v.rotate(-Math.atan2(v1[1]-v2[1],v1[0]-v2[0]))}this.data.p&&this.data.p.s?this.data.p.z?this.v.translate(this.px.v,this.py.v,-this.pz.v):this.v.translate(this.px.v,this.py.v,0):this.v.translate(this.p.v[0],this.p.v[1],-this.p.v[2])}this.frameId=this.elem.globalData.frameId}}function precalculateMatrix(){if(this.appliedTransformations=0,this.pre.reset(),!this.a.effectsSequence.length&&(this.pre.translate(-this.a.v[0],-this.a.v[1],this.a.v[2]),this.appliedTransformations=1,!this.s.effectsSequence.length)){if(this.pre.scale(this.s.v[0],this.s.v[1],this.s.v[2]),this.appliedTransformations=2,this.sk){if(this.sk.effectsSequence.length||this.sa.effectsSequence.length)return;this.pre.skewFromAxis(-this.sk.v,this.sa.v),this.appliedTransformations=3}this.r?this.r.effectsSequence.length||(this.pre.rotate(-this.r.v),this.appliedTransformations=4):this.rz.effectsSequence.length||this.ry.effectsSequence.length||this.rx.effectsSequence.length||this.or.effectsSequence.length||(this.pre.rotateZ(-this.rz.v).rotateY(this.ry.v).rotateX(this.rx.v).rotateZ(-this.or.v[2]).rotateY(this.or.v[1]).rotateX(this.or.v[0]),this.appliedTransformations=4)}}function autoOrient(){}function addDynamicProperty(prop){this._addDynamicProperty(prop),this.elem.addDynamicProperty(prop),this._isDirty=!0}function TransformProperty(elem,data,container){if(this.elem=elem,this.frameId=-1,this.propType="transform",this.data=data,this.v=new Matrix,this.pre=new Matrix,this.appliedTransformations=0,this.initDynamicPropertyContainer(container||elem),data.p&&data.p.s?(this.px=PropertyFactory.getProp(elem,data.p.x,0,0,this),this.py=PropertyFactory.getProp(elem,data.p.y,0,0,this),data.p.z&&(this.pz=PropertyFactory.getProp(elem,data.p.z,0,0,this))):this.p=PropertyFactory.getProp(elem,data.p||{k:[0,0,0]},1,0,this),data.rx){if(this.rx=PropertyFactory.getProp(elem,data.rx,0,degToRads,this),this.ry=PropertyFactory.getProp(elem,data.ry,0,degToRads,this),this.rz=PropertyFactory.getProp(elem,data.rz,0,degToRads,this),data.or.k[0].ti){var i,len=data.or.k.length;for(i=0;i<len;i+=1)data.or.k[i].to=null,data.or.k[i].ti=null}this.or=PropertyFactory.getProp(elem,data.or,1,degToRads,this),this.or.sh=!0}else this.r=PropertyFactory.getProp(elem,data.r||{k:0},0,degToRads,this);data.sk&&(this.sk=PropertyFactory.getProp(elem,data.sk,0,degToRads,this),this.sa=PropertyFactory.getProp(elem,data.sa,0,degToRads,this)),this.a=PropertyFactory.getProp(elem,data.a||{k:[0,0,0]},1,0,this),this.s=PropertyFactory.getProp(elem,data.s||{k:[100,100,100]},1,.01,this),data.o?this.o=PropertyFactory.getProp(elem,data.o,0,.01,elem):this.o={_mdf:!1,v:1},this._isDirty=!0,this.dynamicProperties.length||this.getValue(!0)}return TransformProperty.prototype={applyToMatrix:applyToMatrix,getValue:processKeys,precalculateMatrix:precalculateMatrix,autoOrient:autoOrient},extendPrototype([DynamicPropertyContainer],TransformProperty),TransformProperty.prototype.addDynamicProperty=addDynamicProperty,TransformProperty.prototype._addDynamicProperty=DynamicPropertyContainer.prototype.addDynamicProperty,{getTransformProperty:function getTransformProperty(elem,data,container){return new TransformProperty(elem,data,container)}}}();function RepeaterModifier(){}function RoundCornersModifier(){}function floatEqual(a,b){return 1e5*Math.abs(a-b)<=Math.min(Math.abs(a),Math.abs(b))}function floatZero(f){return 1e-5>=Math.abs(f)}function lerpPoint(p0,p1,amount){return[p0[0]*(1-amount)+p1[0]*amount,p0[1]*(1-amount)+p1[1]*amount]}function quadRoots(a,b,c){if(0===a)return[];var s=b*b-4*a*c;if(s<0)return[];var singleRoot=-b/(2*a);if(0===s)return[singleRoot];var delta=Math.sqrt(s)/(2*a);return[singleRoot-delta,singleRoot+delta]}function polynomialCoefficients(p0,p1,p2,p3){return[-p0+3*p1-3*p2+p3,3*p0-6*p1+3*p2,-3*p0+3*p1,p0]}function singlePoint(p){return new PolynomialBezier(p,p,p,p,!1)}function PolynomialBezier(p0,p1,p2,p3,linearize){linearize&&pointEqual(p0,p1)&&(p1=lerpPoint(p0,p3,1/3)),linearize&&pointEqual(p2,p3)&&(p2=lerpPoint(p0,p3,2/3));var coeffx=polynomialCoefficients(p0[0],p1[0],p2[0],p3[0]),coeffy=polynomialCoefficients(p0[1],p1[1],p2[1],p3[1]);this.a=[coeffx[0],coeffy[0]],this.b=[coeffx[1],coeffy[1]],this.c=[coeffx[2],coeffy[2]],this.d=[coeffx[3],coeffy[3]],this.points=[p0,p1,p2,p3]}function extrema(bez,comp){var min=bez.points[0][comp],max=bez.points[bez.points.length-1][comp];if(min>max){var e=max;max=min,min=e}for(var f=quadRoots(3*bez.a[comp],2*bez.b[comp],bez.c[comp]),i=0;i<f.length;i+=1)if(f[i]>0&&f[i]<1){var val=bez.point(f[i])[comp];val<min?min=val:val>max&&(max=val)}return{min:min,max:max}}function intersectData(bez,t1,t2){var box=bez.boundingBox();return{cx:box.cx,cy:box.cy,width:box.width,height:box.height,bez:bez,t:(t1+t2)/2,t1:t1,t2:t2}}function splitData(data){var split=data.bez.split(.5);return[intersectData(split[0],data.t1,data.t),intersectData(split[1],data.t,data.t2)]}function boxIntersect(b1,b2){return 2*Math.abs(b1.cx-b2.cx)<b1.width+b2.width&&2*Math.abs(b1.cy-b2.cy)<b1.height+b2.height}function intersectsImpl(d1,d2,depth,tolerance,intersections,maxRecursion){if(boxIntersect(d1,d2)){if(depth>=maxRecursion||d1.width<=tolerance&&d1.height<=tolerance&&d2.width<=tolerance&&d2.height<=tolerance){intersections.push([d1.t,d2.t]);return}var d1s=splitData(d1),d2s=splitData(d2);intersectsImpl(d1s[0],d2s[0],depth+1,tolerance,intersections,maxRecursion),intersectsImpl(d1s[0],d2s[1],depth+1,tolerance,intersections,maxRecursion),intersectsImpl(d1s[1],d2s[0],depth+1,tolerance,intersections,maxRecursion),intersectsImpl(d1s[1],d2s[1],depth+1,tolerance,intersections,maxRecursion)}}function crossProduct(a,b){return[a[1]*b[2]-a[2]*b[1],a[2]*b[0]-a[0]*b[2],a[0]*b[1]-a[1]*b[0]]}function lineIntersection(start1,end1,start2,end2){var v1=[start1[0],start1[1],1],v2=[end1[0],end1[1],1],v3=[start2[0],start2[1],1],v4=[end2[0],end2[1],1],r=crossProduct(crossProduct(v1,v2),crossProduct(v3,v4));return floatZero(r[2])?null:[r[0]/r[2],r[1]/r[2]]}function polarOffset(p,angle,length){return[p[0]+Math.cos(angle)*length,p[1]-Math.sin(angle)*length]}function pointDistance(p1,p2){return Math.hypot(p1[0]-p2[0],p1[1]-p2[1])}function pointEqual(p1,p2){return floatEqual(p1[0],p2[0])&&floatEqual(p1[1],p2[1])}function ZigZagModifier(){}function setPoint(outputBezier,point,angle,direction,amplitude,outAmplitude,inAmplitude){var angO=angle-Math.PI/2,angI=angle+Math.PI/2,px=point[0]+Math.cos(angle)*direction*amplitude,py=point[1]-Math.sin(angle)*direction*amplitude;outputBezier.setTripleAt(px,py,px+Math.cos(angO)*outAmplitude,py-Math.sin(angO)*outAmplitude,px+Math.cos(angI)*inAmplitude,py-Math.sin(angI)*inAmplitude,outputBezier.length())}function getPerpendicularVector(pt1,pt2){var vector=[pt2[0]-pt1[0],pt2[1]-pt1[1]],rot=-(.5*Math.PI);return[Math.cos(rot)*vector[0]-Math.sin(rot)*vector[1],Math.sin(rot)*vector[0]+Math.cos(rot)*vector[1]]}function getProjectingAngle(path,cur){var prevIndex=0===cur?path.length()-1:cur-1,nextIndex=(cur+1)%path.length(),pVector=getPerpendicularVector(path.v[prevIndex],path.v[nextIndex]);return Math.atan2(0,1)-Math.atan2(pVector[1],pVector[0])}function zigZagCorner(outputBezier,path,cur,amplitude,frequency,pointType,direction){var angle=getProjectingAngle(path,cur),point=path.v[cur%path._length],prevPoint=path.v[0===cur?path._length-1:cur-1],nextPoint=path.v[(cur+1)%path._length],prevDist=2===pointType?Math.sqrt(Math.pow(point[0]-prevPoint[0],2)+Math.pow(point[1]-prevPoint[1],2)):0,nextDist=2===pointType?Math.sqrt(Math.pow(point[0]-nextPoint[0],2)+Math.pow(point[1]-nextPoint[1],2)):0;setPoint(outputBezier,path.v[cur%path._length],angle,direction,amplitude,nextDist/((frequency+1)*2),prevDist/((frequency+1)*2),pointType)}function zigZagSegment(outputBezier,segment,amplitude,frequency,pointType,direction){for(var i=0;i<frequency;i+=1){var t=(i+1)/(frequency+1),dist=2===pointType?Math.sqrt(Math.pow(segment.points[3][0]-segment.points[0][0],2)+Math.pow(segment.points[3][1]-segment.points[0][1],2)):0,angle=segment.normalAngle(t);setPoint(outputBezier,segment.point(t),angle,direction,amplitude,dist/((frequency+1)*2),dist/((frequency+1)*2),pointType),direction=-direction}return direction}function linearOffset(p1,p2,amount){var angle=Math.atan2(p2[0]-p1[0],p2[1]-p1[1]);return[polarOffset(p1,angle,amount),polarOffset(p2,angle,amount)]}function offsetSegment(segment,amount){p0=(e=linearOffset(segment.points[0],segment.points[1],amount))[0],p1a=e[1],p1b=(e=linearOffset(segment.points[1],segment.points[2],amount))[0],p2b=e[1],p2a=(e=linearOffset(segment.points[2],segment.points[3],amount))[0],p3=e[1];var p0,p1a,p1b,p2b,p2a,p3,e,p1=lineIntersection(p0,p1a,p1b,p2b);null===p1&&(p1=p1a);var p2=lineIntersection(p2a,p3,p1b,p2b);return null===p2&&(p2=p2a),new PolynomialBezier(p0,p1,p2,p3)}function joinLines(outputBezier,seg1,seg2,lineJoin,miterLimit){var p0=seg1.points[3],p1=seg2.points[0];if(3===lineJoin||pointEqual(p0,p1))return p0;if(2===lineJoin){var angleOut=-seg1.tangentAngle(1),angleIn=-seg2.tangentAngle(0)+Math.PI,center=lineIntersection(p0,polarOffset(p0,angleOut+Math.PI/2,100),p1,polarOffset(p1,angleOut+Math.PI/2,100)),radius=center?pointDistance(center,p0):pointDistance(p0,p1)/2,tan=polarOffset(p0,angleOut,2*radius*.5519);return outputBezier.setXYAt(tan[0],tan[1],"o",outputBezier.length()-1),tan=polarOffset(p1,angleIn,2*radius*.5519),outputBezier.setTripleAt(p1[0],p1[1],p1[0],p1[1],tan[0],tan[1],outputBezier.length()),p1}var t0=pointEqual(p0,seg1.points[2])?seg1.points[0]:seg1.points[2],t1=pointEqual(p1,seg2.points[1])?seg2.points[3]:seg2.points[1],intersection=lineIntersection(t0,p0,p1,t1);return intersection&&pointDistance(intersection,p0)<miterLimit?(outputBezier.setTripleAt(intersection[0],intersection[1],intersection[0],intersection[1],intersection[0],intersection[1],outputBezier.length()),intersection):p0}function getIntersection(a,b){var intersect=a.intersections(b);return(intersect.length&&floatEqual(intersect[0][0],1)&&intersect.shift(),intersect.length)?intersect[0]:null}function pruneSegmentIntersection(a,b){var outa=a.slice(),outb=b.slice(),intersect=getIntersection(a[a.length-1],b[0]);return(intersect&&(outa[a.length-1]=a[a.length-1].split(intersect[0])[0],outb[0]=b[0].split(intersect[1])[1]),a.length>1&&b.length>1&&(intersect=getIntersection(a[0],b[b.length-1])))?[[a[0].split(intersect[0])[0]],[b[b.length-1].split(intersect[1])[1]]]:[outa,outb]}function pruneIntersections(segments){for(var e,i=1;i<segments.length;i+=1)e=pruneSegmentIntersection(segments[i-1],segments[i]),segments[i-1]=e[0],segments[i]=e[1];return segments.length>1&&(e=pruneSegmentIntersection(segments[segments.length-1],segments[0]),segments[segments.length-1]=e[0],segments[0]=e[1]),segments}function offsetSegmentSplit(segment,amount){var left,right,split,mid,flex=segment.inflectionPoints();if(0===flex.length)return[offsetSegment(segment,amount)];if(1===flex.length||floatEqual(flex[1],1))return left=(split=segment.split(flex[0]))[0],right=split[1],[offsetSegment(left,amount),offsetSegment(right,amount)];left=(split=segment.split(flex[0]))[0];var t=(flex[1]-flex[0])/(1-flex[0]);return mid=(split=split[1].split(t))[0],right=split[1],[offsetSegment(left,amount),offsetSegment(mid,amount),offsetSegment(right,amount)]}function OffsetPathModifier(){}function getFontProperties(fontData){for(var styles=fontData.fStyle?fontData.fStyle.split(" "):[],fWeight="normal",fStyle="normal",len=styles.length,i=0;i<len;i+=1)switch(styles[i].toLowerCase()){case"italic":fStyle="italic";break;case"bold":fWeight="700";break;case"black":fWeight="900";break;case"medium":fWeight="500";break;case"regular":case"normal":fWeight="400";break;case"light":case"thin":fWeight="200"}return{style:fStyle,weight:fontData.fWeight||fWeight}}extendPrototype([ShapeModifier],RepeaterModifier),RepeaterModifier.prototype.initModifierProperties=function(elem,data){this.getValue=this.processKeys,this.c=PropertyFactory.getProp(elem,data.c,0,null,this),this.o=PropertyFactory.getProp(elem,data.o,0,null,this),this.tr=TransformPropertyFactory.getTransformProperty(elem,data.tr,this),this.so=PropertyFactory.getProp(elem,data.tr.so,0,.01,this),this.eo=PropertyFactory.getProp(elem,data.tr.eo,0,.01,this),this.data=data,this.dynamicProperties.length||this.getValue(!0),this._isAnimated=!!this.dynamicProperties.length,this.pMatrix=new Matrix,this.rMatrix=new Matrix,this.sMatrix=new Matrix,this.tMatrix=new Matrix,this.matrix=new Matrix},RepeaterModifier.prototype.applyTransforms=function(pMatrix,rMatrix,sMatrix,transform,perc,inv){var dir=inv?-1:1,scaleX=transform.s.v[0]+(1-transform.s.v[0])*(1-perc),scaleY=transform.s.v[1]+(1-transform.s.v[1])*(1-perc);pMatrix.translate(transform.p.v[0]*dir*perc,transform.p.v[1]*dir*perc,transform.p.v[2]),rMatrix.translate(-transform.a.v[0],-transform.a.v[1],transform.a.v[2]),rMatrix.rotate(-transform.r.v*dir*perc),rMatrix.translate(transform.a.v[0],transform.a.v[1],transform.a.v[2]),sMatrix.translate(-transform.a.v[0],-transform.a.v[1],transform.a.v[2]),sMatrix.scale(inv?1/scaleX:scaleX,inv?1/scaleY:scaleY),sMatrix.translate(transform.a.v[0],transform.a.v[1],transform.a.v[2])},RepeaterModifier.prototype.init=function(elem,arr,pos,elemsData){for(this.elem=elem,this.arr=arr,this.pos=pos,this.elemsData=elemsData,this._currentCopies=0,this._elements=[],this._groups=[],this.frameId=-1,this.initDynamicPropertyContainer(elem),this.initModifierProperties(elem,arr[pos]);pos>0;)pos-=1,this._elements.unshift(arr[pos]);this.dynamicProperties.length?this.k=!0:this.getValue(!0)},RepeaterModifier.prototype.resetElements=function(elements){var i,len=elements.length;for(i=0;i<len;i+=1)elements[i]._processed=!1,"gr"===elements[i].ty&&this.resetElements(elements[i].it)},RepeaterModifier.prototype.cloneElements=function(elements){var newElements=JSON.parse(JSON.stringify(elements));return this.resetElements(newElements),newElements},RepeaterModifier.prototype.changeGroupRender=function(elements,renderFlag){var i,len=elements.length;for(i=0;i<len;i+=1)elements[i]._render=renderFlag,"gr"===elements[i].ty&&this.changeGroupRender(elements[i].it,renderFlag)},RepeaterModifier.prototype.processShapes=function(_isFirstFrame){var hasReloaded=!1;if(this._mdf||_isFirstFrame){var items,itemsTransform,i,dir,cont,renderFlag,j,jLen,copies=Math.ceil(this.c.v);if(this._groups.length<copies){for(;this._groups.length<copies;){var group={it:this.cloneElements(this._elements),ty:"gr"};group.it.push({a:{a:0,ix:1,k:[0,0]},nm:"Transform",o:{a:0,ix:7,k:100},p:{a:0,ix:2,k:[0,0]},r:{a:1,ix:6,k:[{s:0,e:0,t:0},{s:0,e:0,t:1}]},s:{a:0,ix:3,k:[100,100]},sa:{a:0,ix:5,k:0},sk:{a:0,ix:4,k:0},ty:"tr"}),this.arr.splice(0,0,group),this._groups.splice(0,0,group),this._currentCopies+=1}this.elem.reloadShapes(),hasReloaded=!0}for(i=0,cont=0;i<=this._groups.length-1;i+=1){if(renderFlag=cont<copies,this._groups[i]._render=renderFlag,this.changeGroupRender(this._groups[i].it,renderFlag),!renderFlag){var elems=this.elemsData[i].it,transformData=elems[elems.length-1];0!==transformData.transform.op.v?(transformData.transform.op._mdf=!0,transformData.transform.op.v=0):transformData.transform.op._mdf=!1}cont+=1}this._currentCopies=copies;var offset=this.o.v,offsetModulo=offset%1,roundOffset=offset>0?Math.floor(offset):Math.ceil(offset),pProps=this.pMatrix.props,rProps=this.rMatrix.props,sProps=this.sMatrix.props;this.pMatrix.reset(),this.rMatrix.reset(),this.sMatrix.reset(),this.tMatrix.reset(),this.matrix.reset();var iteration=0;if(offset>0){for(;iteration<roundOffset;)this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,1,!1),iteration+=1;offsetModulo&&(this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,offsetModulo,!1),iteration+=offsetModulo)}else if(offset<0){for(;iteration>roundOffset;)this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,1,!0),iteration-=1;offsetModulo&&(this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,-offsetModulo,!0),iteration-=offsetModulo)}for(i=1===this.data.m?0:this._currentCopies-1,dir=1===this.data.m?1:-1,cont=this._currentCopies;cont;){if(jLen=(itemsTransform=(items=this.elemsData[i].it)[items.length-1].transform.mProps.v.props).length,items[items.length-1].transform.mProps._mdf=!0,items[items.length-1].transform.op._mdf=!0,items[items.length-1].transform.op.v=1===this._currentCopies?this.so.v:this.so.v+(this.eo.v-this.so.v)*(i/(this._currentCopies-1)),0!==iteration){for((0!==i&&1===dir||i!==this._currentCopies-1&&-1===dir)&&this.applyTransforms(this.pMatrix,this.rMatrix,this.sMatrix,this.tr,1,!1),this.matrix.transform(rProps[0],rProps[1],rProps[2],rProps[3],rProps[4],rProps[5],rProps[6],rProps[7],rProps[8],rProps[9],rProps[10],rProps[11],rProps[12],rProps[13],rProps[14],rProps[15]),this.matrix.transform(sProps[0],sProps[1],sProps[2],sProps[3],sProps[4],sProps[5],sProps[6],sProps[7],sProps[8],sProps[9],sProps[10],sProps[11],sProps[12],sProps[13],sProps[14],sProps[15]),this.matrix.transform(pProps[0],pProps[1],pProps[2],pProps[3],pProps[4],pProps[5],pProps[6],pProps[7],pProps[8],pProps[9],pProps[10],pProps[11],pProps[12],pProps[13],pProps[14],pProps[15]),j=0;j<jLen;j+=1)itemsTransform[j]=this.matrix.props[j];this.matrix.reset()}else for(this.matrix.reset(),j=0;j<jLen;j+=1)itemsTransform[j]=this.matrix.props[j];iteration+=1,cont-=1,i+=dir}}else for(cont=this._currentCopies,i=0,dir=1;cont;)itemsTransform=(items=this.elemsData[i].it)[items.length-1].transform.mProps.v.props,items[items.length-1].transform.mProps._mdf=!1,items[items.length-1].transform.op._mdf=!1,cont-=1,i+=dir;return hasReloaded},RepeaterModifier.prototype.addShape=function(){},extendPrototype([ShapeModifier],RoundCornersModifier),RoundCornersModifier.prototype.initModifierProperties=function(elem,data){this.getValue=this.processKeys,this.rd=PropertyFactory.getProp(elem,data.r,0,null,this),this._isAnimated=!!this.rd.effectsSequence.length},RoundCornersModifier.prototype.processPath=function(path,round){var i,currentV,currentI,currentO,closerV,distance,newPosPerc,vX,vY,oX,oY,iX,iY,clonedPath=shapePool.newElement();clonedPath.c=path.c;var len=path._length,index=0;for(i=0;i<len;i+=1)currentV=path.v[i],currentO=path.o[i],currentI=path.i[i],currentV[0]===currentO[0]&¤tV[1]===currentO[1]&¤tV[0]===currentI[0]&¤tV[1]===currentI[1]?0!==i&&i!==len-1||path.c?(closerV=0===i?path.v[len-1]:path.v[i-1],newPosPerc=(distance=Math.sqrt(Math.pow(currentV[0]-closerV[0],2)+Math.pow(currentV[1]-closerV[1],2)))?Math.min(distance/2,round)/distance:0,vX=iX=currentV[0]+(closerV[0]-currentV[0])*newPosPerc,vY=iY=currentV[1]-(currentV[1]-closerV[1])*newPosPerc,oX=vX-(vX-currentV[0])*.5519,oY=vY-(vY-currentV[1])*.5519,clonedPath.setTripleAt(vX,vY,oX,oY,iX,iY,index),index+=1,closerV=i===len-1?path.v[0]:path.v[i+1],newPosPerc=(distance=Math.sqrt(Math.pow(currentV[0]-closerV[0],2)+Math.pow(currentV[1]-closerV[1],2)))?Math.min(distance/2,round)/distance:0,vX=oX=currentV[0]+(closerV[0]-currentV[0])*newPosPerc,vY=oY=currentV[1]+(closerV[1]-currentV[1])*newPosPerc,iX=vX-(vX-currentV[0])*.5519,iY=vY-(vY-currentV[1])*.5519,clonedPath.setTripleAt(vX,vY,oX,oY,iX,iY,index)):clonedPath.setTripleAt(currentV[0],currentV[1],currentO[0],currentO[1],currentI[0],currentI[1],index):clonedPath.setTripleAt(path.v[i][0],path.v[i][1],path.o[i][0],path.o[i][1],path.i[i][0],path.i[i][1],index),index+=1;return clonedPath},RoundCornersModifier.prototype.processShapes=function(_isFirstFrame){var shapePaths,i,j,jLen,shapeData,localShapeCollection,len=this.shapes.length,rd=this.rd.v;if(0!==rd)for(i=0;i<len;i+=1){if(localShapeCollection=(shapeData=this.shapes[i]).localShapeCollection,!(!shapeData.shape._mdf&&!this._mdf&&!_isFirstFrame))for(localShapeCollection.releaseShapes(),shapeData.shape._mdf=!0,shapePaths=shapeData.shape.paths.shapes,jLen=shapeData.shape.paths._length,j=0;j<jLen;j+=1)localShapeCollection.addShape(this.processPath(shapePaths[j],rd));shapeData.shape.paths=shapeData.localShapeCollection}this.dynamicProperties.length||(this._mdf=!1)},PolynomialBezier.prototype.point=function(t){return[((this.a[0]*t+this.b[0])*t+this.c[0])*t+this.d[0],((this.a[1]*t+this.b[1])*t+this.c[1])*t+this.d[1]]},PolynomialBezier.prototype.derivative=function(t){return[(3*t*this.a[0]+2*this.b[0])*t+this.c[0],(3*t*this.a[1]+2*this.b[1])*t+this.c[1]]},PolynomialBezier.prototype.tangentAngle=function(t){var p=this.derivative(t);return Math.atan2(p[1],p[0])},PolynomialBezier.prototype.normalAngle=function(t){var p=this.derivative(t);return Math.atan2(p[0],p[1])},PolynomialBezier.prototype.inflectionPoints=function(){var denom=this.a[1]*this.b[0]-this.a[0]*this.b[1];if(floatZero(denom))return[];var tcusp=-.5*(this.a[1]*this.c[0]-this.a[0]*this.c[1])/denom,square=tcusp*tcusp-1/3*(this.b[1]*this.c[0]-this.b[0]*this.c[1])/denom;if(square<0)return[];var root=Math.sqrt(square);return floatZero(root)?root>0&&root<1?[tcusp]:[]:[tcusp-root,tcusp+root].filter(function(r){return r>0&&r<1})},PolynomialBezier.prototype.split=function(t){if(t<=0)return[singlePoint(this.points[0]),this];if(t>=1)return[this,singlePoint(this.points[this.points.length-1])];var p10=lerpPoint(this.points[0],this.points[1],t),p11=lerpPoint(this.points[1],this.points[2],t),p12=lerpPoint(this.points[2],this.points[3],t),p20=lerpPoint(p10,p11,t),p21=lerpPoint(p11,p12,t),p3=lerpPoint(p20,p21,t);return[new PolynomialBezier(this.points[0],p10,p20,p3,!0),new PolynomialBezier(p3,p21,p12,this.points[3],!0)]},PolynomialBezier.prototype.bounds=function(){return{x:extrema(this,0),y:extrema(this,1)}},PolynomialBezier.prototype.boundingBox=function(){var bounds=this.bounds();return{left:bounds.x.min,right:bounds.x.max,top:bounds.y.min,bottom:bounds.y.max,width:bounds.x.max-bounds.x.min,height:bounds.y.max-bounds.y.min,cx:(bounds.x.max+bounds.x.min)/2,cy:(bounds.y.max+bounds.y.min)/2}},PolynomialBezier.prototype.intersections=function(other,tolerance,maxRecursion){void 0===tolerance&&(tolerance=2),void 0===maxRecursion&&(maxRecursion=7);var intersections=[];return intersectsImpl(intersectData(this,0,1),intersectData(other,0,1),0,tolerance,intersections,maxRecursion),intersections},PolynomialBezier.shapeSegment=function(shapePath,index){var nextIndex=(index+1)%shapePath.length();return new PolynomialBezier(shapePath.v[index],shapePath.o[index],shapePath.i[nextIndex],shapePath.v[nextIndex],!0)},PolynomialBezier.shapeSegmentInverted=function(shapePath,index){var nextIndex=(index+1)%shapePath.length();return new PolynomialBezier(shapePath.v[nextIndex],shapePath.i[nextIndex],shapePath.o[index],shapePath.v[index],!0)},extendPrototype([ShapeModifier],ZigZagModifier),ZigZagModifier.prototype.initModifierProperties=function(elem,data){this.getValue=this.processKeys,this.amplitude=PropertyFactory.getProp(elem,data.s,0,null,this),this.frequency=PropertyFactory.getProp(elem,data.r,0,null,this),this.pointsType=PropertyFactory.getProp(elem,data.pt,0,null,this),this._isAnimated=0!==this.amplitude.effectsSequence.length||0!==this.frequency.effectsSequence.length||0!==this.pointsType.effectsSequence.length},ZigZagModifier.prototype.processPath=function(path,amplitude,frequency,pointType){var count=path._length,clonedPath=shapePool.newElement();if(clonedPath.c=path.c,path.c||(count-=1),0===count)return clonedPath;var direction=-1,segment=PolynomialBezier.shapeSegment(path,0);zigZagCorner(clonedPath,path,0,amplitude,frequency,pointType,direction);for(var i=0;i<count;i+=1)direction=zigZagSegment(clonedPath,segment,amplitude,frequency,pointType,-direction),segment=i!==count-1||path.c?PolynomialBezier.shapeSegment(path,(i+1)%count):null,zigZagCorner(clonedPath,path,i+1,amplitude,frequency,pointType,direction);return clonedPath},ZigZagModifier.prototype.processShapes=function(_isFirstFrame){var shapePaths,i,j,jLen,shapeData,localShapeCollection,len=this.shapes.length,amplitude=this.amplitude.v,frequency=Math.max(0,Math.round(this.frequency.v)),pointType=this.pointsType.v;if(0!==amplitude)for(i=0;i<len;i+=1){if(localShapeCollection=(shapeData=this.shapes[i]).localShapeCollection,!(!shapeData.shape._mdf&&!this._mdf&&!_isFirstFrame))for(localShapeCollection.releaseShapes(),shapeData.shape._mdf=!0,shapePaths=shapeData.shape.paths.shapes,jLen=shapeData.shape.paths._length,j=0;j<jLen;j+=1)localShapeCollection.addShape(this.processPath(shapePaths[j],amplitude,frequency,pointType));shapeData.shape.paths=shapeData.localShapeCollection}this.dynamicProperties.length||(this._mdf=!1)},extendPrototype([ShapeModifier],OffsetPathModifier),OffsetPathModifier.prototype.initModifierProperties=function(elem,data){this.getValue=this.processKeys,this.amount=PropertyFactory.getProp(elem,data.a,0,null,this),this.miterLimit=PropertyFactory.getProp(elem,data.ml,0,null,this),this.lineJoin=data.lj,this._isAnimated=0!==this.amount.effectsSequence.length},OffsetPathModifier.prototype.processPath=function(inputBezier,amount,lineJoin,miterLimit){var i,j,segment,outputBezier=shapePool.newElement();outputBezier.c=inputBezier.c;var count=inputBezier.length();inputBezier.c||(count-=1);var multiSegments=[];for(i=0;i<count;i+=1)segment=PolynomialBezier.shapeSegment(inputBezier,i),multiSegments.push(offsetSegmentSplit(segment,amount));if(!inputBezier.c)for(i=count-1;i>=0;i-=1)segment=PolynomialBezier.shapeSegmentInverted(inputBezier,i),multiSegments.push(offsetSegmentSplit(segment,amount));multiSegments=pruneIntersections(multiSegments);var lastPoint=null,lastSeg=null;for(i=0;i<multiSegments.length;i+=1){var multiSegment=multiSegments[i];for(lastSeg&&(lastPoint=joinLines(outputBezier,lastSeg,multiSegment[0],lineJoin,miterLimit)),lastSeg=multiSegment[multiSegment.length-1],j=0;j<multiSegment.length;j+=1)segment=multiSegment[j],lastPoint&&pointEqual(segment.points[0],lastPoint)?outputBezier.setXYAt(segment.points[1][0],segment.points[1][1],"o",outputBezier.length()-1):outputBezier.setTripleAt(segment.points[0][0],segment.points[0][1],segment.points[1][0],segment.points[1][1],segment.points[0][0],segment.points[0][1],outputBezier.length()),outputBezier.setTripleAt(segment.points[3][0],segment.points[3][1],segment.points[3][0],segment.points[3][1],segment.points[2][0],segment.points[2][1],outputBezier.length()),lastPoint=segment.points[3]}return multiSegments.length&&joinLines(outputBezier,lastSeg,multiSegments[0][0],lineJoin,miterLimit),outputBezier},OffsetPathModifier.prototype.processShapes=function(_isFirstFrame){var shapePaths,i,j,jLen,shapeData,localShapeCollection,len=this.shapes.length,amount=this.amount.v,miterLimit=this.miterLimit.v,lineJoin=this.lineJoin;if(0!==amount)for(i=0;i<len;i+=1){if(localShapeCollection=(shapeData=this.shapes[i]).localShapeCollection,!(!shapeData.shape._mdf&&!this._mdf&&!_isFirstFrame))for(localShapeCollection.releaseShapes(),shapeData.shape._mdf=!0,shapePaths=shapeData.shape.paths.shapes,jLen=shapeData.shape.paths._length,j=0;j<jLen;j+=1)localShapeCollection.addShape(this.processPath(shapePaths[j],amount,lineJoin,miterLimit));shapeData.shape.paths=shapeData.localShapeCollection}this.dynamicProperties.length||(this._mdf=!1)};var FontManager=function(){var emptyChar={w:0,size:0,shapes:[],data:{shapes:[]}},combinedCharacters=[];combinedCharacters=combinedCharacters.concat([2304,2305,2306,2307,2362,2363,2364,2364,2366,2367,2368,2369,2370,2371,2372,2373,2374,2375,2376,2377,2378,2379,2380,2381,2382,2383,2387,2388,2389,2390,2391,2402,2403]);var surrogateModifiers=["d83cdffb","d83cdffc","d83cdffd","d83cdffe","d83cdfff"];function trimFontOptions(font){var i,familyArray=font.split(","),len=familyArray.length,enabledFamilies=[];for(i=0;i<len;i+=1)"sans-serif"!==familyArray[i]&&"monospace"!==familyArray[i]&&enabledFamilies.push(familyArray[i]);return enabledFamilies.join(",")}function setUpNode(font,family){var parentNode=createTag("span");parentNode.setAttribute("aria-hidden",!0),parentNode.style.fontFamily=family;var node=createTag("span");node.innerText="giItT1WQy@!-/#",parentNode.style.position="absolute",parentNode.style.left="-10000px",parentNode.style.top="-10000px",parentNode.style.fontSize="300px",parentNode.style.fontVariant="normal",parentNode.style.fontStyle="normal",parentNode.style.fontWeight="normal",parentNode.style.letterSpacing="0",parentNode.appendChild(node),document.body.appendChild(parentNode);var width=node.offsetWidth;return node.style.fontFamily=trimFontOptions(font)+", "+family,{node:node,w:width,parent:parentNode}}function checkLoadedFonts(){var i,node,w,len=this.fonts.length,loadedCount=len;for(i=0;i<len;i+=1)this.fonts[i].loaded?loadedCount-=1:"n"===this.fonts[i].fOrigin||0===this.fonts[i].origin?this.fonts[i].loaded=!0:(node=this.fonts[i].monoCase.node,w=this.fonts[i].monoCase.w,node.offsetWidth!==w?(loadedCount-=1,this.fonts[i].loaded=!0):(node=this.fonts[i].sansCase.node,w=this.fonts[i].sansCase.w,node.offsetWidth!==w&&(loadedCount-=1,this.fonts[i].loaded=!0)),this.fonts[i].loaded&&(this.fonts[i].sansCase.parent.parentNode.removeChild(this.fonts[i].sansCase.parent),this.fonts[i].monoCase.parent.parentNode.removeChild(this.fonts[i].monoCase.parent)));0!==loadedCount&&Date.now()-this.initTime<5e3?setTimeout(this.checkLoadedFontsBinded,20):setTimeout(this.setIsLoadedBinded,10)}function createHelper(fontData,def){var helper,engine=document.body&&def?"svg":"canvas",fontProps=getFontProperties(fontData);if("svg"===engine){var tHelper=createNS("text");tHelper.style.fontSize="100px",tHelper.setAttribute("font-family",fontData.fFamily),tHelper.setAttribute("font-style",fontProps.style),tHelper.setAttribute("font-weight",fontProps.weight),tHelper.textContent="1",fontData.fClass?(tHelper.style.fontFamily="inherit",tHelper.setAttribute("class",fontData.fClass)):tHelper.style.fontFamily=fontData.fFamily,def.appendChild(tHelper),helper=tHelper}else{var tCanvasHelper=new OffscreenCanvas(500,500).getContext("2d");tCanvasHelper.font=fontProps.style+" "+fontProps.weight+" 100px "+fontData.fFamily,helper=tCanvasHelper}return{measureText:function measure(text){return"svg"===engine?(helper.textContent=text,helper.getComputedTextLength()):helper.measureText(text).width}}}function addFonts(fontData,defs){if(!fontData){this.isLoaded=!0;return}if(this.chars){this.isLoaded=!0,this.fonts=fontData.list;return}if(!document.body){this.isLoaded=!0,fontData.list.forEach(function(data){data.helper=createHelper(data),data.cache={}}),this.fonts=fontData.list;return}var fontArr=fontData.list,len=fontArr.length,_pendingFonts=len;for(i=0;i<len;i+=1){var i,loadedSelector,j,shouldLoadFont=!0;if(fontArr[i].loaded=!1,fontArr[i].monoCase=setUpNode(fontArr[i].fFamily,"monospace"),fontArr[i].sansCase=setUpNode(fontArr[i].fFamily,"sans-serif"),fontArr[i].fPath){if("p"===fontArr[i].fOrigin||3===fontArr[i].origin){if((loadedSelector=document.querySelectorAll('style[f-forigin="p"][f-family="'+fontArr[i].fFamily+'"], style[f-origin="3"][f-family="'+fontArr[i].fFamily+'"]')).length>0&&(shouldLoadFont=!1),shouldLoadFont){var s=createTag("style");s.setAttribute("f-forigin",fontArr[i].fOrigin),s.setAttribute("f-origin",fontArr[i].origin),s.setAttribute("f-family",fontArr[i].fFamily),s.type="text/css",s.innerText="@font-face {font-family: "+fontArr[i].fFamily+"; font-style: normal; src: url('"+fontArr[i].fPath+"');}",defs.appendChild(s)}}else if("g"===fontArr[i].fOrigin||1===fontArr[i].origin){for(j=0,loadedSelector=document.querySelectorAll('link[f-forigin="g"], link[f-origin="1"]');j<loadedSelector.length;j+=1)-1!==loadedSelector[j].href.indexOf(fontArr[i].fPath)&&(shouldLoadFont=!1);if(shouldLoadFont){var l=createTag("link");l.setAttribute("f-forigin",fontArr[i].fOrigin),l.setAttribute("f-origin",fontArr[i].origin),l.type="text/css",l.rel="stylesheet",l.href=fontArr[i].fPath,document.body.appendChild(l)}}else if("t"===fontArr[i].fOrigin||2===fontArr[i].origin){for(j=0,loadedSelector=document.querySelectorAll('script[f-forigin="t"], script[f-origin="2"]');j<loadedSelector.length;j+=1)fontArr[i].fPath===loadedSelector[j].src&&(shouldLoadFont=!1);if(shouldLoadFont){var sc=createTag("link");sc.setAttribute("f-forigin",fontArr[i].fOrigin),sc.setAttribute("f-origin",fontArr[i].origin),sc.setAttribute("rel","stylesheet"),sc.setAttribute("href",fontArr[i].fPath),defs.appendChild(sc)}}}else fontArr[i].loaded=!0,_pendingFonts-=1;fontArr[i].helper=createHelper(fontArr[i],defs),fontArr[i].cache={},this.fonts.push(fontArr[i])}0===_pendingFonts?this.isLoaded=!0:setTimeout(this.checkLoadedFonts.bind(this),100)}function addChars(chars){if(chars){this.chars||(this.chars=[]);var i,j,found,len=chars.length,jLen=this.chars.length;for(i=0;i<len;i+=1){for(j=0,found=!1;j<jLen;)this.chars[j].style===chars[i].style&&this.chars[j].fFamily===chars[i].fFamily&&this.chars[j].ch===chars[i].ch&&(found=!0),j+=1;found||(this.chars.push(chars[i]),jLen+=1)}}}function getCharData(_char,style,font){for(var i=0,len=this.chars.length;i<len;){if(this.chars[i].ch===_char&&this.chars[i].style===style&&this.chars[i].fFamily===font)return this.chars[i];i+=1}return("string"==typeof _char&&13!==_char.charCodeAt(0)||!_char)&&console&&console.warn&&!this._warned&&(this._warned=!0,console.warn("Missing character from exported characters list: ",_char,style,font)),emptyChar}function measureText(_char2,fontName,size){var fontData=this.getFontByName(fontName);if(!fontData.cache[_char2]){var tHelper=fontData.helper;if(" "===_char2){var doubleSize=tHelper.measureText("|"+_char2+"|"),singleSize=tHelper.measureText("||");fontData.cache[_char2]=(doubleSize-singleSize)/100}else fontData.cache[_char2]=tHelper.measureText(_char2)/100}return fontData.cache[_char2]*size}function getFontByName(name){for(var i=0,len=this.fonts.length;i<len;){if(this.fonts[i].fName===name)return this.fonts[i];i+=1}return this.fonts[0]}function getCodePoint(string){var codePoint=0,first=string.charCodeAt(0);if(first>=55296&&first<=56319){var second=string.charCodeAt(1);second>=56320&&second<=57343&&(codePoint=(first-55296)*1024+second-56320+65536)}return codePoint}function isModifier(firstCharCode,secondCharCode){var sum=firstCharCode.toString(16)+secondCharCode.toString(16);return -1!==surrogateModifiers.indexOf(sum)}function isZeroWidthJoiner(charCode){return 8205===charCode}function isVariationSelector(charCode){return 65039===charCode}function isRegionalCode(string){var codePoint=getCodePoint(string);return codePoint>=127462&&codePoint<=127487}function isFlagEmoji(string){return isRegionalCode(string.substr(0,2))&&isRegionalCode(string.substr(2,2))}function isCombinedCharacter(_char3){return -1!==combinedCharacters.indexOf(_char3)}function isRegionalFlag(text,index){var codePoint=getCodePoint(text.substr(index,2));if(127988!==codePoint)return!1;var count=0;for(index+=2;count<5;){if((codePoint=getCodePoint(text.substr(index,2)))<917601||codePoint>917626)return!1;count+=1,index+=2}return 917631===getCodePoint(text.substr(index,2))}function setIsLoaded(){this.isLoaded=!0}var Font=function Font(){this.fonts=[],this.chars=null,this.typekitLoaded=0,this.isLoaded=!1,this._warned=!1,this.initTime=Date.now(),this.setIsLoadedBinded=this.setIsLoaded.bind(this),this.checkLoadedFontsBinded=this.checkLoadedFonts.bind(this)};return Font.isModifier=isModifier,Font.isZeroWidthJoiner=isZeroWidthJoiner,Font.isFlagEmoji=isFlagEmoji,Font.isRegionalCode=isRegionalCode,Font.isCombinedCharacter=isCombinedCharacter,Font.isRegionalFlag=isRegionalFlag,Font.isVariationSelector=isVariationSelector,Font.BLACK_FLAG_CODE_POINT=127988,Font.prototype={addChars:addChars,addFonts:addFonts,getCharData:getCharData,getFontByName:getFontByName,measureText:measureText,checkLoadedFonts:checkLoadedFonts,setIsLoaded:setIsLoaded},Font}();function SlotManager(animationData){this.animationData=animationData}function slotFactory(animationData){return new SlotManager(animationData)}function RenderableElement(){}SlotManager.prototype.getProp=function(data){return this.animationData.slots&&this.animationData.slots[data.sid]?Object.assign(data,this.animationData.slots[data.sid].p):data},RenderableElement.prototype={initRenderable:function initRenderable(){this.isInRange=!1,this.hidden=!1,this.isTransparent=!1,this.renderableComponents=[]},addRenderableComponent:function addRenderableComponent(component){-1===this.renderableComponents.indexOf(component)&&this.renderableComponents.push(component)},removeRenderableComponent:function removeRenderableComponent(component){-1!==this.renderableComponents.indexOf(component)&&this.renderableComponents.splice(this.renderableComponents.indexOf(component),1)},prepareRenderableFrame:function prepareRenderableFrame(num){this.checkLayerLimits(num)},checkTransparency:function checkTransparency(){this.finalTransform.mProp.o.v<=0?!this.isTransparent&&this.globalData.renderConfig.hideOnTransparent&&(this.isTransparent=!0,this.hide()):this.isTransparent&&(this.isTransparent=!1,this.show())},checkLayerLimits:function checkLayerLimits(num){this.data.ip-this.data.st<=num&&this.data.op-this.data.st>num?!0!==this.isInRange&&(this.globalData._mdf=!0,this._mdf=!0,this.isInRange=!0,this.show()):!1!==this.isInRange&&(this.globalData._mdf=!0,this.isInRange=!1,this.hide())},renderRenderable:function renderRenderable(){var i,len=this.renderableComponents.length;for(i=0;i<len;i+=1)this.renderableComponents[i].renderFrame(this._isFirstFrame)},sourceRectAtTime:function sourceRectAtTime(){return{top:0,left:0,width:100,height:100}},getLayerSize:function getLayerSize(){return 5===this.data.ty?{w:this.data.textData.width,h:this.data.textData.height}:{w:this.data.width,h:this.data.height}}};var getBlendMode=(blendModeEnums={0:"source-over",1:"multiply",2:"screen",3:"overlay",4:"darken",5:"lighten",6:"color-dodge",7:"color-burn",8:"hard-light",9:"soft-light",10:"difference",11:"exclusion",12:"hue",13:"saturation",14:"color",15:"luminosity"},function(mode){return blendModeEnums[mode]||""});function SliderEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,0,0,container)}function AngleEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,0,0,container)}function ColorEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,1,0,container)}function PointEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,1,0,container)}function LayerIndexEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,0,0,container)}function MaskIndexEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,0,0,container)}function CheckboxEffect(data,elem,container){this.p=PropertyFactory.getProp(elem,data.v,0,0,container)}function NoValueEffect(){this.p={}}function EffectsManager(data,element){var i,effectItem,effects=data.ef||[];this.effectElements=[];var len=effects.length;for(i=0;i<len;i+=1)effectItem=new GroupEffect(effects[i],element),this.effectElements.push(effectItem)}function GroupEffect(data,element){this.init(data,element)}function BaseElement(){}function FrameElement(){}function FootageElement(data,globalData,comp){this.initFrame(),this.initRenderable(),this.assetData=globalData.getAssetData(data.refId),this.footageData=globalData.imageLoader.getAsset(this.assetData),this.initBaseData(data,globalData,comp)}function AudioElement(data,globalData,comp){this.initFrame(),this.initRenderable(),this.assetData=globalData.getAssetData(data.refId),this.initBaseData(data,globalData,comp),this._isPlaying=!1,this._canPlay=!1;var assetPath=this.globalData.getAssetsPath(this.assetData);this.audio=this.globalData.audioController.createAudio(assetPath),this._currentTime=0,this.globalData.audioController.addAudio(this),this._volumeMultiplier=1,this._volume=1,this._previousVolume=null,this.tm=data.tm?PropertyFactory.getProp(this,data.tm,0,globalData.frameRate,this):{_placeholder:!0},this.lv=PropertyFactory.getProp(this,data.au&&data.au.lv?data.au.lv:{k:[100]},1,.01,this)}function BaseRenderer(){}extendPrototype([DynamicPropertyContainer],GroupEffect),GroupEffect.prototype.getValue=GroupEffect.prototype.iterateDynamicProperties,GroupEffect.prototype.init=function(data,element){this.data=data,this.effectElements=[],this.initDynamicPropertyContainer(element);var i,eff,len=this.data.ef.length,effects=this.data.ef;for(i=0;i<len;i+=1){switch(eff=null,effects[i].ty){case 0:eff=new SliderEffect(effects[i],element,this);break;case 1:eff=new AngleEffect(effects[i],element,this);break;case 2:eff=new ColorEffect(effects[i],element,this);break;case 3:eff=new PointEffect(effects[i],element,this);break;case 4:case 7:eff=new CheckboxEffect(effects[i],element,this);break;case 10:eff=new LayerIndexEffect(effects[i],element,this);break;case 11:eff=new MaskIndexEffect(effects[i],element,this);break;case 5:eff=new EffectsManager(effects[i],element,this);break;default:eff=new NoValueEffect(effects[i],element,this)}eff&&this.effectElements.push(eff)}},BaseElement.prototype={checkMasks:function checkMasks(){if(!this.data.hasMask)return!1;for(var i=0,len=this.data.masksProperties.length;i<len;){if("n"!==this.data.masksProperties[i].mode&&!1!==this.data.masksProperties[i].cl)return!0;i+=1}return!1},initExpressions:function initExpressions(){var expressionsInterfaces=getExpressionInterfaces();if(expressionsInterfaces){var LayerExpressionInterface=expressionsInterfaces("layer"),EffectsExpressionInterface=expressionsInterfaces("effects"),ShapeExpressionInterface=expressionsInterfaces("shape"),TextExpressionInterface=expressionsInterfaces("text"),CompExpressionInterface=expressionsInterfaces("comp");this.layerInterface=LayerExpressionInterface(this),this.data.hasMask&&this.maskManager&&this.layerInterface.registerMaskInterface(this.maskManager);var effectsInterface=EffectsExpressionInterface.createEffectsInterface(this,this.layerInterface);this.layerInterface.registerEffectsInterface(effectsInterface),0===this.data.ty||this.data.xt?this.compInterface=CompExpressionInterface(this):4===this.data.ty?(this.layerInterface.shapeInterface=ShapeExpressionInterface(this.shapesData,this.itemsData,this.layerInterface),this.layerInterface.content=this.layerInterface.shapeInterface):5===this.data.ty&&(this.layerInterface.textInterface=TextExpressionInterface(this),this.layerInterface.text=this.layerInterface.textInterface)}},setBlendMode:function setBlendMode(){var blendModeValue=getBlendMode(this.data.bm);(this.baseElement||this.layerElement).style["mix-blend-mode"]=blendModeValue},initBaseData:function initBaseData(data,globalData,comp){this.globalData=globalData,this.comp=comp,this.data=data,this.layerId=createElementID(),this.data.sr||(this.data.sr=1),this.effectsManager=new EffectsManager(this.data,this,this.dynamicProperties)},getType:function getType(){return this.type},sourceRectAtTime:function sourceRectAtTime(){}},FrameElement.prototype={initFrame:function initFrame(){this._isFirstFrame=!1,this.dynamicProperties=[],this._mdf=!1},prepareProperties:function prepareProperties(num,isVisible){var i,len=this.dynamicProperties.length;for(i=0;i<len;i+=1)(isVisible||this._isParent&&"transform"===this.dynamicProperties[i].propType)&&(this.dynamicProperties[i].getValue(),this.dynamicProperties[i]._mdf&&(this.globalData._mdf=!0,this._mdf=!0))},addDynamicProperty:function addDynamicProperty(prop){-1===this.dynamicProperties.indexOf(prop)&&this.dynamicProperties.push(prop)}},FootageElement.prototype.prepareFrame=function(){},extendPrototype([RenderableElement,BaseElement,FrameElement],FootageElement),FootageElement.prototype.getBaseElement=function(){return null},FootageElement.prototype.renderFrame=function(){},FootageElement.prototype.destroy=function(){},FootageElement.prototype.initExpressions=function(){var expressionsInterfaces=getExpressionInterfaces();if(expressionsInterfaces){var FootageInterface=expressionsInterfaces("footage");this.layerInterface=FootageInterface(this)}},FootageElement.prototype.getFootageData=function(){return this.footageData},AudioElement.prototype.prepareFrame=function(num){if(this.prepareRenderableFrame(num,!0),this.prepareProperties(num,!0),this.tm._placeholder)this._currentTime=num/this.data.sr;else{var timeRemapped=this.tm.v;this._currentTime=timeRemapped}this._volume=this.lv.v[0];var totalVolume=this._volume*this._volumeMultiplier;this._previousVolume!==totalVolume&&(this._previousVolume=totalVolume,this.audio.volume(totalVolume))},extendPrototype([RenderableElement,BaseElement,FrameElement],AudioElement),AudioElement.prototype.renderFrame=function(){this.isInRange&&this._canPlay&&(this._isPlaying?(!this.audio.playing()||Math.abs(this._currentTime/this.globalData.frameRate-this.audio.seek())>.1)&&this.audio.seek(this._currentTime/this.globalData.frameRate):(this.audio.play(),this.audio.seek(this._currentTime/this.globalData.frameRate),this._isPlaying=!0))},AudioElement.prototype.show=function(){},AudioElement.prototype.hide=function(){this.audio.pause(),this._isPlaying=!1},AudioElement.prototype.pause=function(){this.audio.pause(),this._isPlaying=!1,this._canPlay=!1},AudioElement.prototype.resume=function(){this._canPlay=!0},AudioElement.prototype.setRate=function(rateValue){this.audio.rate(rateValue)},AudioElement.prototype.volume=function(volumeValue){this._volumeMultiplier=volumeValue,this._previousVolume=volumeValue*this._volume,this.audio.volume(this._previousVolume)},AudioElement.prototype.getBaseElement=function(){return null},AudioElement.prototype.destroy=function(){},AudioElement.prototype.sourceRectAtTime=function(){},AudioElement.prototype.initExpressions=function(){},BaseRenderer.prototype.checkLayers=function(num){var i,data,len=this.layers.length;for(this.completeLayers=!0,i=len-1;i>=0;i-=1)!this.elements[i]&&(data=this.layers[i]).ip-data.st<=num-this.layers[i].st&&data.op-data.st>num-this.layers[i].st&&this.buildItem(i),this.completeLayers=!!this.elements[i]&&this.completeLayers;this.checkPendingElements()},BaseRenderer.prototype.createItem=function(layer){switch(layer.ty){case 2:return this.createImage(layer);case 0:return this.createComp(layer);case 1:return this.createSolid(layer);case 3:default:return this.createNull(layer);case 4:return this.createShape(layer);case 5:return this.createText(layer);case 6:return this.createAudio(layer);case 13:return this.createCamera(layer);case 15:return this.createFootage(layer)}},BaseRenderer.prototype.createCamera=function(){throw Error("You're using a 3d camera. Try the html renderer.")},BaseRenderer.prototype.createAudio=function(data){return new AudioElement(data,this.globalData,this)},BaseRenderer.prototype.createFootage=function(data){return new FootageElement(data,this.globalData,this)},BaseRenderer.prototype.buildAllItems=function(){var i,len=this.layers.length;for(i=0;i<len;i+=1)this.buildItem(i);this.checkPendingElements()},BaseRenderer.prototype.includeLayers=function(newLayers){this.completeLayers=!1;var i,j,len=newLayers.length,jLen=this.layers.length;for(i=0;i<len;i+=1)for(j=0;j<jLen;){if(this.layers[j].id===newLayers[i].id){this.layers[j]=newLayers[i];break}j+=1}},BaseRenderer.prototype.setProjectInterface=function(pInterface){this.globalData.projectInterface=pInterface},BaseRenderer.prototype.initItems=function(){this.globalData.progressiveLoad||this.buildAllItems()},BaseRenderer.prototype.buildElementParenting=function(element,parentName,hierarchy){for(var elements=this.elements,layers=this.layers,i=0,len=layers.length;i<len;)layers[i].ind==parentName&&(elements[i]&&!0!==elements[i]?(hierarchy.push(elements[i]),elements[i].setAsParent(),void 0!==layers[i].parent?this.buildElementParenting(element,layers[i].parent,hierarchy):element.setHierarchy(hierarchy)):(this.buildItem(i),this.addPendingElement(element))),i+=1},BaseRenderer.prototype.addPendingElement=function(element){this.pendingElements.push(element)},BaseRenderer.prototype.searchExtraCompositions=function(assets){var i,len=assets.length;for(i=0;i<len;i+=1)if(assets[i].xt){var comp=this.createComp(assets[i]);comp.initExpressions(),this.globalData.projectInterface.registerComposition(comp)}},BaseRenderer.prototype.getElementById=function(ind){var i,len=this.elements.length;for(i=0;i<len;i+=1)if(this.elements[i].data.ind===ind)return this.elements[i];return null},BaseRenderer.prototype.getElementByPath=function(path){var pathValue=path.shift();if("number"==typeof pathValue)element=this.elements[pathValue];else{var element,i,len=this.elements.length;for(i=0;i<len;i+=1)if(this.elements[i].data.nm===pathValue){element=this.elements[i];break}}return 0===path.length?element:element.getElementByPath(path)},BaseRenderer.prototype.setupGlobalData=function(animData,fontsContainer){this.globalData.fontManager=new FontManager,this.globalData.slotManager=slotFactory(animData),this.globalData.fontManager.addChars(animData.chars),this.globalData.fontManager.addFonts(animData.fonts,fontsContainer),this.globalData.getAssetData=this.animationItem.getAssetData.bind(this.animationItem),this.globalData.getAssetsPath=this.animationItem.getAssetsPath.bind(this.animationItem),this.globalData.imageLoader=this.animationItem.imagePreloader,this.globalData.audioController=this.animationItem.audioController,this.globalData.frameId=0,this.globalData.frameRate=animData.fr,this.globalData.nm=animData.nm,this.globalData.compSize={w:animData.w,h:animData.h}};var effectTypes={TRANSFORM_EFFECT:"transformEFfect"};function TransformElement(){}function MaskElement(data,element,globalData){this.data=data,this.element=element,this.globalData=globalData,this.storedData=[],this.masksProperties=this.data.masksProperties||[],this.maskElement=null;var defs=this.globalData.defs,len=this.masksProperties?this.masksProperties.length:0;this.viewData=createSizedArray(len),this.solidPath="";var properties=this.masksProperties,count=0,currentMasks=[],layerId=createElementID(),maskType="clipPath",maskRef="clip-path";for(i=0;i<len;i+=1)if(("a"!==properties[i].mode&&"n"!==properties[i].mode||properties[i].inv||100!==properties[i].o.k||properties[i].o.x)&&(maskType="mask",maskRef="mask"),("s"===properties[i].mode||"i"===properties[i].mode)&&0===count?((rect=createNS("rect")).setAttribute("fill","#ffffff"),rect.setAttribute("width",this.element.comp.data.w||0),rect.setAttribute("height",this.element.comp.data.h||0),currentMasks.push(rect)):rect=null,path=createNS("path"),"n"===properties[i].mode)this.viewData[i]={op:PropertyFactory.getProp(this.element,properties[i].o,0,.01,this.element),prop:ShapePropertyFactory.getShapeProp(this.element,properties[i],3),elem:path,lastPath:""},defs.appendChild(path);else{if(count+=1,path.setAttribute("fill","s"===properties[i].mode?"#000000":"#ffffff"),path.setAttribute("clip-rule","nonzero"),0!==properties[i].x.k?(maskType="mask",maskRef="mask",x=PropertyFactory.getProp(this.element,properties[i].x,0,null,this.element),filterID=createElementID(),(expansor=createNS("filter")).setAttribute("id",filterID),(feMorph=createNS("feMorphology")).setAttribute("operator","erode"),feMorph.setAttribute("in","SourceGraphic"),feMorph.setAttribute("radius","0"),expansor.appendChild(feMorph),defs.appendChild(expansor),path.setAttribute("stroke","s"===properties[i].mode?"#000000":"#ffffff")):(feMorph=null,x=null),this.storedData[i]={elem:path,x:x,expan:feMorph,lastPath:"",lastOperator:"",filterId:filterID,lastRadius:0},"i"===properties[i].mode){jLen=currentMasks.length;var i,path,j,jLen,rect,expansor,feMorph,x,filterID,g=createNS("g");for(j=0;j<jLen;j+=1)g.appendChild(currentMasks[j]);var mask=createNS("mask");mask.setAttribute("mask-type","alpha"),mask.setAttribute("id",layerId+"_"+count),mask.appendChild(path),defs.appendChild(mask),g.setAttribute("mask","url("+getLocationHref()+"#"+layerId+"_"+count+")"),currentMasks.length=0,currentMasks.push(g)}else currentMasks.push(path);properties[i].inv&&!this.solidPath&&(this.solidPath=this.createLayerSolidPath()),this.viewData[i]={elem:path,lastPath:"",op:PropertyFactory.getProp(this.element,properties[i].o,0,.01,this.element),prop:ShapePropertyFactory.getShapeProp(this.element,properties[i],3),invRect:rect},this.viewData[i].prop.k||this.drawPath(properties[i],this.viewData[i].prop.v,this.viewData[i])}for(i=0,this.maskElement=createNS(maskType),len=currentMasks.length;i<len;i+=1)this.maskElement.appendChild(currentMasks[i]);count>0&&(this.maskElement.setAttribute("id",layerId),this.element.maskedElement.setAttribute(maskRef,"url("+getLocationHref()+"#"+layerId+")"),defs.appendChild(this.maskElement)),this.viewData.length&&this.element.addRenderableComponent(this)}TransformElement.prototype={initTransform:function initTransform(){var mat=new Matrix;this.finalTransform={mProp:this.data.ks?TransformPropertyFactory.getTransformProperty(this,this.data.ks,this):{o:0},_matMdf:!1,_localMatMdf:!1,_opMdf:!1,mat:mat,localMat:mat,localOpacity:1},this.data.ao&&(this.finalTransform.mProp.autoOriented=!0),this.data.ty},renderTransform:function renderTransform(){if(this.finalTransform._opMdf=this.finalTransform.mProp.o._mdf||this._isFirstFrame,this.finalTransform._matMdf=this.finalTransform.mProp._mdf||this._isFirstFrame,this.hierarchy){var mat,finalMat=this.finalTransform.mat,i=0,len=this.hierarchy.length;if(!this.finalTransform._matMdf)for(;i<len;){if(this.hierarchy[i].finalTransform.mProp._mdf){this.finalTransform._matMdf=!0;break}i+=1}if(this.finalTransform._matMdf)for(mat=this.finalTransform.mProp.v.props,finalMat.cloneFromProps(mat),i=0;i<len;i+=1)finalMat.multiply(this.hierarchy[i].finalTransform.mProp.v)}this.finalTransform._matMdf&&(this.finalTransform._localMatMdf=this.finalTransform._matMdf),this.finalTransform._opMdf&&(this.finalTransform.localOpacity=this.finalTransform.mProp.o.v)},renderLocalTransform:function renderLocalTransform(){if(this.localTransforms){var i=0,len=this.localTransforms.length;if(this.finalTransform._localMatMdf=this.finalTransform._matMdf,!this.finalTransform._localMatMdf||!this.finalTransform._opMdf)for(;i<len;)this.localTransforms[i]._mdf&&(this.finalTransform._localMatMdf=!0),this.localTransforms[i]._opMdf&&!this.finalTransform._opMdf&&(this.finalTransform.localOpacity=this.finalTransform.mProp.o.v,this.finalTransform._opMdf=!0),i+=1;if(this.finalTransform._localMatMdf){var localMat=this.finalTransform.localMat;for(this.localTransforms[0].matrix.clone(localMat),i=1;i<len;i+=1){var lmat=this.localTransforms[i].matrix;localMat.multiply(lmat)}localMat.multiply(this.finalTransform.mat)}if(this.finalTransform._opMdf){var localOp=this.finalTransform.localOpacity;for(i=0;i<len;i+=1)localOp*=.01*this.localTransforms[i].opacity;this.finalTransform.localOpacity=localOp}}},searchEffectTransforms:function searchEffectTransforms(){if(this.renderableEffectsManager){var transformEffects=this.renderableEffectsManager.getEffects(effectTypes.TRANSFORM_EFFECT);if(transformEffects.length){this.localTransforms=[],this.finalTransform.localMat=new Matrix;var i=0,len=transformEffects.length;for(i=0;i<len;i+=1)this.localTransforms.push(transformEffects[i])}}},globalToLocal:function globalToLocal(pt){var i,ptNew,transforms=[];transforms.push(this.finalTransform);for(var flag=!0,comp=this.comp;flag;)comp.finalTransform?(comp.data.hasMask&&transforms.splice(0,0,comp.finalTransform),comp=comp.comp):flag=!1;var len=transforms.length;for(i=0;i<len;i+=1)ptNew=transforms[i].mat.applyToPointArray(0,0,0),pt=[pt[0]-ptNew[0],pt[1]-ptNew[1],0];return pt},mHelper:new Matrix},MaskElement.prototype.getMaskProperty=function(pos){return this.viewData[pos].prop},MaskElement.prototype.renderFrame=function(isFirstFrame){var i,finalMat=this.element.finalTransform.mat,len=this.masksProperties.length;for(i=0;i<len;i+=1)if((this.viewData[i].prop._mdf||isFirstFrame)&&this.drawPath(this.masksProperties[i],this.viewData[i].prop.v,this.viewData[i]),(this.viewData[i].op._mdf||isFirstFrame)&&this.viewData[i].elem.setAttribute("fill-opacity",this.viewData[i].op.v),"n"!==this.masksProperties[i].mode&&(this.viewData[i].invRect&&(this.element.finalTransform.mProp._mdf||isFirstFrame)&&this.viewData[i].invRect.setAttribute("transform",finalMat.getInverseMatrix().to2dCSS()),this.storedData[i].x&&(this.storedData[i].x._mdf||isFirstFrame))){var feMorph=this.storedData[i].expan;this.storedData[i].x.v<0?("erode"!==this.storedData[i].lastOperator&&(this.storedData[i].lastOperator="erode",this.storedData[i].elem.setAttribute("filter","url("+getLocationHref()+"#"+this.storedData[i].filterId+")")),feMorph.setAttribute("radius",-this.storedData[i].x.v)):("dilate"!==this.storedData[i].lastOperator&&(this.storedData[i].lastOperator="dilate",this.storedData[i].elem.setAttribute("filter",null)),this.storedData[i].elem.setAttribute("stroke-width",2*this.storedData[i].x.v))}},MaskElement.prototype.getMaskelement=function(){return this.maskElement},MaskElement.prototype.createLayerSolidPath=function(){return"M0,0 "+(" h"+this.globalData.compSize.w+" v"+this.globalData.compSize.h+" h-"+this.globalData.compSize.w+" v-"+this.globalData.compSize.h)+" "},MaskElement.prototype.drawPath=function(pathData,pathNodes,viewData){var i,len,pathString=" M"+pathNodes.v[0][0]+","+pathNodes.v[0][1];for(i=1,len=pathNodes._length;i<len;i+=1)pathString+=" C"+pathNodes.o[i-1][0]+","+pathNodes.o[i-1][1]+" "+pathNodes.i[i][0]+","+pathNodes.i[i][1]+" "+pathNodes.v[i][0]+","+pathNodes.v[i][1];if(pathNodes.c&&len>1&&(pathString+=" C"+pathNodes.o[i-1][0]+","+pathNodes.o[i-1][1]+" "+pathNodes.i[0][0]+","+pathNodes.i[0][1]+" "+pathNodes.v[0][0]+","+pathNodes.v[0][1]),viewData.lastPath!==pathString){var pathShapeValue="";viewData.elem&&(pathNodes.c&&(pathShapeValue=pathData.inv?this.solidPath+pathString:pathString),viewData.elem.setAttribute("d",pathShapeValue)),viewData.lastPath=pathString}},MaskElement.prototype.destroy=function(){this.element=null,this.globalData=null,this.maskElement=null,this.data=null,this.masksProperties=null};var filtersFactory=function(){var ob={};function createFilter(filId,skipCoordinates){var fil=createNS("filter");return fil.setAttribute("id",filId),!0!==skipCoordinates&&(fil.setAttribute("filterUnits","objectBoundingBox"),fil.setAttribute("x","0%"),fil.setAttribute("y","0%"),fil.setAttribute("width","100%"),fil.setAttribute("height","100%")),fil}function createAlphaToLuminanceFilter(){var feColorMatrix=createNS("feColorMatrix");return feColorMatrix.setAttribute("type","matrix"),feColorMatrix.setAttribute("color-interpolation-filters","sRGB"),feColorMatrix.setAttribute("values","0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 1"),feColorMatrix}return ob.createFilter=createFilter,ob.createAlphaToLuminanceFilter=createAlphaToLuminanceFilter,ob}(),featureSupport=(ob={maskType:!0,svgLumaHidden:!0,offscreenCanvas:"undefined"!=typeof OffscreenCanvas},(/MSIE 10/i.test(navigator.userAgent)||/MSIE 9/i.test(navigator.userAgent)||/rv:11.0/i.test(navigator.userAgent)||/Edge\/\d./i.test(navigator.userAgent))&&(ob.maskType=!1),/firefox/i.test(navigator.userAgent)&&(ob.svgLumaHidden=!1),ob),registeredEffects={},idPrefix="filter_result_";function SVGEffects(elem){var i,filterManager,source="SourceGraphic",len=elem.data.ef?elem.data.ef.length:0,filId=createElementID(),fil=filtersFactory.createFilter(filId,!0),count=0;for(i=0,this.filters=[];i<len;i+=1){filterManager=null;var type=elem.data.ef[i].ty;registeredEffects[type]&&(filterManager=new registeredEffects[type].effect(fil,elem.effectsManager.effectElements[i],elem,idPrefix+count,source),source=idPrefix+count,registeredEffects[type].countsAsEffect&&(count+=1)),filterManager&&this.filters.push(filterManager)}count&&(elem.globalData.defs.appendChild(fil),elem.layerElement.setAttribute("filter","url("+getLocationHref()+"#"+filId+")")),this.filters.length&&elem.addRenderableComponent(this)}function SVGBaseElement(){}function HierarchyElement(){}function RenderableDOMElement(){}function IImageElement(data,globalData,comp){this.assetData=globalData.getAssetData(data.refId),this.assetData&&this.assetData.sid&&(this.assetData=globalData.slotManager.getProp(this.assetData)),this.initElement(data,globalData,comp),this.sourceRect={top:0,left:0,width:this.assetData.w,height:this.assetData.h}}function ProcessedElement(element,position){this.elem=element,this.pos=position}function IShapeElement(){}SVGEffects.prototype.renderFrame=function(_isFirstFrame){var i,len=this.filters.length;for(i=0;i<len;i+=1)this.filters[i].renderFrame(_isFirstFrame)},SVGEffects.prototype.getEffects=function(type){var i,len=this.filters.length,effects=[];for(i=0;i<len;i+=1)this.filters[i].type===type&&effects.push(this.filters[i]);return effects},SVGBaseElement.prototype={initRendererElement:function initRendererElement(){this.layerElement=createNS("g")},createContainerElements:function createContainerElements(){this.matteElement=createNS("g"),this.transformedElement=this.layerElement,this.maskedElement=this.layerElement,this._sizeChanged=!1;var layerElementParent=null;if(this.data.td){this.matteMasks={};var gg=createNS("g");gg.setAttribute("id",this.layerId),gg.appendChild(this.layerElement),layerElementParent=gg,this.globalData.defs.appendChild(gg)}else this.data.tt?(this.matteElement.appendChild(this.layerElement),layerElementParent=this.matteElement,this.baseElement=this.matteElement):this.baseElement=this.layerElement;if(this.data.ln&&this.layerElement.setAttribute("id",this.data.ln),this.data.cl&&this.layerElement.setAttribute("class",this.data.cl),0===this.data.ty&&!this.data.hd){var cp=createNS("clipPath"),pt=createNS("path");pt.setAttribute("d","M0,0 L"+this.data.w+",0 L"+this.data.w+","+this.data.h+" L0,"+this.data.h+"z");var clipId=createElementID();if(cp.setAttribute("id",clipId),cp.appendChild(pt),this.globalData.defs.appendChild(cp),this.checkMasks()){var cpGroup=createNS("g");cpGroup.setAttribute("clip-path","url("+getLocationHref()+"#"+clipId+")"),cpGroup.appendChild(this.layerElement),this.transformedElement=cpGroup,layerElementParent?layerElementParent.appendChild(this.transformedElement):this.baseElement=this.transformedElement}else this.layerElement.setAttribute("clip-path","url("+getLocationHref()+"#"+clipId+")")}0!==this.data.bm&&this.setBlendMode()},renderElement:function renderElement(){this.finalTransform._localMatMdf&&this.transformedElement.setAttribute("transform",this.finalTransform.localMat.to2dCSS()),this.finalTransform._opMdf&&this.transformedElement.setAttribute("opacity",this.finalTransform.localOpacity)},destroyBaseElement:function destroyBaseElement(){this.layerElement=null,this.matteElement=null,this.maskManager.destroy()},getBaseElement:function getBaseElement(){return this.data.hd?null:this.baseElement},createRenderableComponents:function createRenderableComponents(){this.maskManager=new MaskElement(this.data,this,this.globalData),this.renderableEffectsManager=new SVGEffects(this),this.searchEffectTransforms()},getMatte:function getMatte(matteType){if(this.matteMasks||(this.matteMasks={}),!this.matteMasks[matteType]){var filId,fil,useElement,gg,id=this.layerId+"_"+matteType;if(1===matteType||3===matteType){var masker=createNS("mask");masker.setAttribute("id",id),masker.setAttribute("mask-type",3===matteType?"luminance":"alpha"),(useElement=createNS("use")).setAttributeNS("http://www.w3.org/1999/xlink","href","#"+this.layerId),masker.appendChild(useElement),this.globalData.defs.appendChild(masker),featureSupport.maskType||1!==matteType||(masker.setAttribute("mask-type","luminance"),filId=createElementID(),fil=filtersFactory.createFilter(filId),this.globalData.defs.appendChild(fil),fil.appendChild(filtersFactory.createAlphaToLuminanceFilter()),(gg=createNS("g")).appendChild(useElement),masker.appendChild(gg),gg.setAttribute("filter","url("+getLocationHref()+"#"+filId+")"))}else if(2===matteType){var maskGroup=createNS("mask");maskGroup.setAttribute("id",id),maskGroup.setAttribute("mask-type","alpha");var maskGrouper=createNS("g");maskGroup.appendChild(maskGrouper),filId=createElementID(),fil=filtersFactory.createFilter(filId);var feCTr=createNS("feComponentTransfer");feCTr.setAttribute("in","SourceGraphic"),fil.appendChild(feCTr);var feFunc=createNS("feFuncA");feFunc.setAttribute("type","table"),feFunc.setAttribute("tableValues","1.0 0.0"),feCTr.appendChild(feFunc),this.globalData.defs.appendChild(fil);var alphaRect=createNS("rect");alphaRect.setAttribute("width",this.comp.data.w),alphaRect.setAttribute("height",this.comp.data.h),alphaRect.setAttribute("x","0"),alphaRect.setAttribute("y","0"),alphaRect.setAttribute("fill","#ffffff"),alphaRect.setAttribute("opacity","0"),maskGrouper.setAttribute("filter","url("+getLocationHref()+"#"+filId+")"),maskGrouper.appendChild(alphaRect),(useElement=createNS("use")).setAttributeNS("http://www.w3.org/1999/xlink","href","#"+this.layerId),maskGrouper.appendChild(useElement),featureSupport.maskType||(maskGroup.setAttribute("mask-type","luminance"),fil.appendChild(filtersFactory.createAlphaToLuminanceFilter()),gg=createNS("g"),maskGrouper.appendChild(alphaRect),gg.appendChild(this.layerElement),maskGrouper.appendChild(gg)),this.globalData.defs.appendChild(maskGroup)}this.matteMasks[matteType]=id}return this.matteMasks[matteType]},setMatte:function setMatte(id){this.matteElement&&this.matteElement.setAttribute("mask","url("+getLocationHref()+"#"+id+")")}},HierarchyElement.prototype={initHierarchy:function initHierarchy(){this.hierarchy=[],this._isParent=!1,this.checkParenting()},setHierarchy:function setHierarchy(hierarchy){this.hierarchy=hierarchy},setAsParent:function setAsParent(){this._isParent=!0},checkParenting:function checkParenting(){void 0!==this.data.parent&&this.comp.buildElementParenting(this,this.data.parent,[])}},extendPrototype([RenderableElement,createProxyFunction({initElement:function initElement(data,globalData,comp){this.initFrame(),this.initBaseData(data,globalData,comp),this.initTransform(data,globalData,comp),this.initHierarchy(),this.initRenderable(),this.initRendererElement(),this.createContainerElements(),this.createRenderableComponents(),this.createContent(),this.hide()},hide:function hide(){this.hidden||this.isInRange&&!this.isTransparent||((this.baseElement||this.layerElement).style.display="none",this.hidden=!0)},show:function show(){this.isInRange&&!this.isTransparent&&(this.data.hd||((this.baseElement||this.layerElement).style.display="block"),this.hidden=!1,this._isFirstFrame=!0)},renderFrame:function renderFrame(){this.data.hd||this.hidden||(this.renderTransform(),this.renderRenderable(),this.renderLocalTransform(),this.renderElement(),this.renderInnerContent(),this._isFirstFrame&&(this._isFirstFrame=!1))},renderInnerContent:function renderInnerContent(){},prepareFrame:function prepareFrame(num){this._mdf=!1,this.prepareRenderableFrame(num),this.prepareProperties(num,this.isInRange),this.checkTransparency()},destroy:function destroy(){this.innerElem=null,this.destroyBaseElement()}})],RenderableDOMElement),extendPrototype([BaseElement,TransformElement,SVGBaseElement,HierarchyElement,FrameElement,RenderableDOMElement],IImageElement),IImageElement.prototype.createContent=function(){var assetPath=this.globalData.getAssetsPath(this.assetData);this.innerElem=createNS("image"),this.innerElem.setAttribute("width",this.assetData.w+"px"),this.innerElem.setAttribute("height",this.assetData.h+"px"),this.innerElem.setAttribute("preserveAspectRatio",this.assetData.pr||this.globalData.renderConfig.imagePreserveAspectRatio),this.innerElem.setAttributeNS("http://www.w3.org/1999/xlink","href",assetPath),this.layerElement.appendChild(this.innerElem)},IImageElement.prototype.sourceRectAtTime=function(){return this.sourceRect},IShapeElement.prototype={addShapeToModifiers:function addShapeToModifiers(data){var i,len=this.shapeModifiers.length;for(i=0;i<len;i+=1)this.shapeModifiers[i].addShape(data)},isShapeInAnimatedModifiers:function isShapeInAnimatedModifiers(data){for(var len=this.shapeModifiers.length;0<len;)if(this.shapeModifiers[0].isAnimatedWithShape(data))return!0;return!1},renderModifiers:function renderModifiers(){if(this.shapeModifiers.length){var i,len=this.shapes.length;for(i=0;i<len;i+=1)this.shapes[i].sh.reset();for(i=(len=this.shapeModifiers.length)-1;i>=0&&!this.shapeModifiers[i].processShapes(this._isFirstFrame);i-=1);}},searchProcessedElement:function searchProcessedElement(elem){for(var elements=this.processedElements,i=0,len=elements.length;i<len;){if(elements[i].elem===elem)return elements[i].pos;i+=1}return 0},addProcessedElement:function addProcessedElement(elem,pos){for(var elements=this.processedElements,i=elements.length;i;)if(elements[i-=1].elem===elem){elements[i].pos=pos;return}elements.push(new ProcessedElement(elem,pos))},prepareFrame:function prepareFrame(num){this.prepareRenderableFrame(num),this.prepareProperties(num,this.isInRange)}};var lineCapEnum={1:"butt",2:"round",3:"square"},lineJoinEnum={1:"miter",2:"round",3:"bevel"};function SVGShapeData(transformers,level,shape){this.caches=[],this.styles=[],this.transformers=transformers,this.lStr="",this.sh=shape,this.lvl=level,this._isAnimated=!!shape.k;for(var i=0,len=transformers.length;i<len;){if(transformers[i].mProps.dynamicProperties.length){this._isAnimated=!0;break}i+=1}}function SVGStyleData(data,level){this.data=data,this.type=data.ty,this.d="",this.lvl=level,this._mdf=!1,this.closed=!0===data.hd,this.pElem=createNS("path"),this.msElem=null}function DashProperty(elem,data,renderer,container){this.elem=elem,this.frameId=-1,this.dataProps=createSizedArray(data.length),this.renderer=renderer,this.k=!1,this.dashStr="",this.dashArray=createTypedArray("float32",data.length?data.length-1:0),this.dashoffset=createTypedArray("float32",1),this.initDynamicPropertyContainer(container);var i,prop,len=data.length||0;for(i=0;i<len;i+=1)prop=PropertyFactory.getProp(elem,data[i].v,0,0,this),this.k=prop.k||this.k,this.dataProps[i]={n:data[i].n,p:prop};this.k||this.getValue(!0),this._isAnimated=this.k}function SVGStrokeStyleData(elem,data,styleOb){this.initDynamicPropertyContainer(elem),this.getValue=this.iterateDynamicProperties,this.o=PropertyFactory.getProp(elem,data.o,0,.01,this),this.w=PropertyFactory.getProp(elem,data.w,0,null,this),this.d=new DashProperty(elem,data.d||{},"svg",this),this.c=PropertyFactory.getProp(elem,data.c,1,255,this),this.style=styleOb,this._isAnimated=!!this._isAnimated}function SVGFillStyleData(elem,data,styleOb){this.initDynamicPropertyContainer(elem),this.getValue=this.iterateDynamicProperties,this.o=PropertyFactory.getProp(elem,data.o,0,.01,this),this.c=PropertyFactory.getProp(elem,data.c,1,255,this),this.style=styleOb}function SVGNoStyleData(elem,data,styleOb){this.initDynamicPropertyContainer(elem),this.getValue=this.iterateDynamicProperties,this.style=styleOb}function GradientProperty(elem,data,container){this.data=data,this.c=createTypedArray("uint8c",4*data.p);var cLength=data.k.k[0].s?data.k.k[0].s.length-4*data.p:data.k.k.length-4*data.p;this.o=createTypedArray("float32",cLength),this._cmdf=!1,this._omdf=!1,this._collapsable=this.checkCollapsable(),this._hasOpacity=cLength,this.initDynamicPropertyContainer(container),this.prop=PropertyFactory.getProp(elem,data.k,1,null,this),this.k=this.prop.k,this.getValue(!0)}function SVGGradientFillStyleData(elem,data,styleOb){this.initDynamicPropertyContainer(elem),this.getValue=this.iterateDynamicProperties,this.initGradientData(elem,data,styleOb)}function SVGGradientStrokeStyleData(elem,data,styleOb){this.initDynamicPropertyContainer(elem),this.getValue=this.iterateDynamicProperties,this.w=PropertyFactory.getProp(elem,data.w,0,null,this),this.d=new DashProperty(elem,data.d||{},"svg",this),this.initGradientData(elem,data,styleOb),this._isAnimated=!!this._isAnimated}function ShapeGroupData(){this.it=[],this.prevViewData=[],this.gr=createNS("g")}function SVGTransformData(mProps,op,container){this.transform={mProps:mProps,op:op,container:container},this.elements=[],this._isAnimated=this.transform.mProps.dynamicProperties.length||this.transform.op.effectsSequence.length}SVGShapeData.prototype.setAsAnimated=function(){this._isAnimated=!0},SVGStyleData.prototype.reset=function(){this.d="",this._mdf=!1},DashProperty.prototype.getValue=function(forceRender){if((this.elem.globalData.frameId!==this.frameId||forceRender)&&(this.frameId=this.elem.globalData.frameId,this.iterateDynamicProperties(),this._mdf=this._mdf||forceRender,this._mdf)){var i=0,len=this.dataProps.length;for("svg"===this.renderer&&(this.dashStr=""),i=0;i<len;i+=1)"o"!==this.dataProps[i].n?"svg"===this.renderer?this.dashStr+=" "+this.dataProps[i].p.v:this.dashArray[i]=this.dataProps[i].p.v:this.dashoffset[0]=this.dataProps[i].p.v}},extendPrototype([DynamicPropertyContainer],DashProperty),extendPrototype([DynamicPropertyContainer],SVGStrokeStyleData),extendPrototype([DynamicPropertyContainer],SVGFillStyleData),extendPrototype([DynamicPropertyContainer],SVGNoStyleData),GradientProperty.prototype.comparePoints=function(values,points){for(var i=0,len=this.o.length/2;i<len;){if(Math.abs(values[4*i]-values[4*points+2*i])>.01)return!1;i+=1}return!0},GradientProperty.prototype.checkCollapsable=function(){if(this.o.length/2!=this.c.length/4)return!1;if(this.data.k.k[0].s)for(var i=0,len=this.data.k.k.length;i<len;){if(!this.comparePoints(this.data.k.k[i].s,this.data.p))return!1;i+=1}else if(!this.comparePoints(this.data.k.k,this.data.p))return!1;return!0},GradientProperty.prototype.getValue=function(forceRender){if(this.prop.getValue(),this._mdf=!1,this._cmdf=!1,this._omdf=!1,this.prop._mdf||forceRender){var i,mult,val,len=4*this.data.p;for(i=0;i<len;i+=1)mult=i%4==0?100:255,val=Math.round(this.prop.v[i]*mult),this.c[i]!==val&&(this.c[i]=val,this._cmdf=!forceRender);if(this.o.length)for(len=this.prop.v.length,i=4*this.data.p;i<len;i+=1)mult=i%2==0?100:1,val=i%2==0?Math.round(100*this.prop.v[i]):this.prop.v[i],this.o[i-4*this.data.p]!==val&&(this.o[i-4*this.data.p]=val,this._omdf=!forceRender);this._mdf=!forceRender}},extendPrototype([DynamicPropertyContainer],GradientProperty),SVGGradientFillStyleData.prototype.initGradientData=function(elem,data,styleOb){this.o=PropertyFactory.getProp(elem,data.o,0,.01,this),this.s=PropertyFactory.getProp(elem,data.s,1,null,this),this.e=PropertyFactory.getProp(elem,data.e,1,null,this),this.h=PropertyFactory.getProp(elem,data.h||{k:0},0,.01,this),this.a=PropertyFactory.getProp(elem,data.a||{k:0},0,degToRads,this),this.g=new GradientProperty(elem,data.g,this),this.style=styleOb,this.stops=[],this.setGradientData(styleOb.pElem,data),this.setGradientOpacity(data,styleOb),this._isAnimated=!!this._isAnimated},SVGGradientFillStyleData.prototype.setGradientData=function(pathElement,data){var stop,j,jLen,gradientId=createElementID(),gfill=createNS(1===data.t?"linearGradient":"radialGradient");gfill.setAttribute("id",gradientId),gfill.setAttribute("spreadMethod","pad"),gfill.setAttribute("gradientUnits","userSpaceOnUse");var stops=[];for(j=0,jLen=4*data.g.p;j<jLen;j+=4)stop=createNS("stop"),gfill.appendChild(stop),stops.push(stop);pathElement.setAttribute("gf"===data.ty?"fill":"stroke","url("+getLocationHref()+"#"+gradientId+")"),this.gf=gfill,this.cst=stops},SVGGradientFillStyleData.prototype.setGradientOpacity=function(data,styleOb){if(this.g._hasOpacity&&!this.g._collapsable){var stop,j,jLen,mask=createNS("mask"),maskElement=createNS("path");mask.appendChild(maskElement);var opacityId=createElementID(),maskId=createElementID();mask.setAttribute("id",maskId);var opFill=createNS(1===data.t?"linearGradient":"radialGradient");opFill.setAttribute("id",opacityId),opFill.setAttribute("spreadMethod","pad"),opFill.setAttribute("gradientUnits","userSpaceOnUse"),jLen=data.g.k.k[0].s?data.g.k.k[0].s.length:data.g.k.k.length;var stops=this.stops;for(j=4*data.g.p;j<jLen;j+=2)(stop=createNS("stop")).setAttribute("stop-color","rgb(255,255,255)"),opFill.appendChild(stop),stops.push(stop);maskElement.setAttribute("gf"===data.ty?"fill":"stroke","url("+getLocationHref()+"#"+opacityId+")"),"gs"===data.ty&&(maskElement.setAttribute("stroke-linecap",lineCapEnum[data.lc||2]),maskElement.setAttribute("stroke-linejoin",lineJoinEnum[data.lj||2]),1===data.lj&&maskElement.setAttribute("stroke-miterlimit",data.ml)),this.of=opFill,this.ms=mask,this.ost=stops,this.maskId=maskId,styleOb.msElem=maskElement}},extendPrototype([DynamicPropertyContainer],SVGGradientFillStyleData),extendPrototype([SVGGradientFillStyleData,DynamicPropertyContainer],SVGGradientStrokeStyleData);var buildShapeString=function buildShapeString(pathNodes,length,closed,mat){if(0===length)return"";var i,_o=pathNodes.o,_i=pathNodes.i,_v=pathNodes.v,shapeString=" M"+mat.applyToPointStringified(_v[0][0],_v[0][1]);for(i=1;i<length;i+=1)shapeString+=" C"+mat.applyToPointStringified(_o[i-1][0],_o[i-1][1])+" "+mat.applyToPointStringified(_i[i][0],_i[i][1])+" "+mat.applyToPointStringified(_v[i][0],_v[i][1]);return closed&&length&&(shapeString+=" C"+mat.applyToPointStringified(_o[i-1][0],_o[i-1][1])+" "+mat.applyToPointStringified(_i[0][0],_i[0][1])+" "+mat.applyToPointStringified(_v[0][0],_v[0][1])+"z"),shapeString},SVGElementsRenderer=function(){var _identityMatrix=new Matrix,_matrixHelper=new Matrix;function renderContentTransform(styleData,itemData,isFirstFrame){(isFirstFrame||itemData.transform.op._mdf)&&itemData.transform.container.setAttribute("opacity",itemData.transform.op.v),(isFirstFrame||itemData.transform.mProps._mdf)&&itemData.transform.container.setAttribute("transform",itemData.transform.mProps.v.to2dCSS())}function renderNoop(){}function renderPath(styleData,itemData,isFirstFrame){var j,jLen,pathStringTransformed,redraw,pathNodes,l,paths,mat,iterations,k,lLen=itemData.styles.length,lvl=itemData.lvl;for(l=0;l<lLen;l+=1){if(redraw=itemData.sh._mdf||isFirstFrame,itemData.styles[l].lvl<lvl){for(mat=_matrixHelper.reset(),iterations=lvl-itemData.styles[l].lvl,k=itemData.transformers.length-1;!redraw&&iterations>0;)redraw=itemData.transformers[k].mProps._mdf||redraw,iterations-=1,k-=1;if(redraw)for(iterations=lvl-itemData.styles[l].lvl,k=itemData.transformers.length-1;iterations>0;)mat.multiply(itemData.transformers[k].mProps.v),iterations-=1,k-=1}else mat=_identityMatrix;if(jLen=(paths=itemData.sh.paths)._length,redraw){for(j=0,pathStringTransformed="";j<jLen;j+=1)(pathNodes=paths.shapes[j])&&pathNodes._length&&(pathStringTransformed+=buildShapeString(pathNodes,pathNodes._length,pathNodes.c,mat));itemData.caches[l]=pathStringTransformed}else pathStringTransformed=itemData.caches[l];itemData.styles[l].d+=!0===styleData.hd?"":pathStringTransformed,itemData.styles[l]._mdf=redraw||itemData.styles[l]._mdf}}function renderFill(styleData,itemData,isFirstFrame){var styleElem=itemData.style;(itemData.c._mdf||isFirstFrame)&&styleElem.pElem.setAttribute("fill","rgb("+bmFloor(itemData.c.v[0])+","+bmFloor(itemData.c.v[1])+","+bmFloor(itemData.c.v[2])+")"),(itemData.o._mdf||isFirstFrame)&&styleElem.pElem.setAttribute("fill-opacity",itemData.o.v)}function renderGradientStroke(styleData,itemData,isFirstFrame){renderGradient(styleData,itemData,isFirstFrame),renderStroke(styleData,itemData,isFirstFrame)}function renderGradient(styleData,itemData,isFirstFrame){var stops,i,len,stop,rad,gfill=itemData.gf,hasOpacity=itemData.g._hasOpacity,pt1=itemData.s.v,pt2=itemData.e.v;if(itemData.o._mdf||isFirstFrame){var attr="gf"===styleData.ty?"fill-opacity":"stroke-opacity";itemData.style.pElem.setAttribute(attr,itemData.o.v)}if(itemData.s._mdf||isFirstFrame){var attr1=1===styleData.t?"x1":"cx",attr2="x1"===attr1?"y1":"cy";gfill.setAttribute(attr1,pt1[0]),gfill.setAttribute(attr2,pt1[1]),hasOpacity&&!itemData.g._collapsable&&(itemData.of.setAttribute(attr1,pt1[0]),itemData.of.setAttribute(attr2,pt1[1]))}if(itemData.g._cmdf||isFirstFrame){stops=itemData.cst;var cValues=itemData.g.c;for(i=0,len=stops.length;i<len;i+=1)(stop=stops[i]).setAttribute("offset",cValues[4*i]+"%"),stop.setAttribute("stop-color","rgb("+cValues[4*i+1]+","+cValues[4*i+2]+","+cValues[4*i+3]+")")}if(hasOpacity&&(itemData.g._omdf||isFirstFrame)){var oValues=itemData.g.o;for(i=0,len=(stops=itemData.g._collapsable?itemData.cst:itemData.ost).length;i<len;i+=1)stop=stops[i],itemData.g._collapsable||stop.setAttribute("offset",oValues[2*i]+"%"),stop.setAttribute("stop-opacity",oValues[2*i+1])}if(1===styleData.t)(itemData.e._mdf||isFirstFrame)&&(gfill.setAttribute("x2",pt2[0]),gfill.setAttribute("y2",pt2[1]),hasOpacity&&!itemData.g._collapsable&&(itemData.of.setAttribute("x2",pt2[0]),itemData.of.setAttribute("y2",pt2[1])));else if((itemData.s._mdf||itemData.e._mdf||isFirstFrame)&&(rad=Math.sqrt(Math.pow(pt1[0]-pt2[0],2)+Math.pow(pt1[1]-pt2[1],2)),gfill.setAttribute("r",rad),hasOpacity&&!itemData.g._collapsable&&itemData.of.setAttribute("r",rad)),itemData.e._mdf||itemData.h._mdf||itemData.a._mdf||isFirstFrame){rad||(rad=Math.sqrt(Math.pow(pt1[0]-pt2[0],2)+Math.pow(pt1[1]-pt2[1],2)));var ang=Math.atan2(pt2[1]-pt1[1],pt2[0]-pt1[0]),percent=itemData.h.v;percent>=1?percent=.99:percent<=-1&&(percent=-.99);var dist=rad*percent,x=Math.cos(ang+itemData.a.v)*dist+pt1[0],y=Math.sin(ang+itemData.a.v)*dist+pt1[1];gfill.setAttribute("fx",x),gfill.setAttribute("fy",y),hasOpacity&&!itemData.g._collapsable&&(itemData.of.setAttribute("fx",x),itemData.of.setAttribute("fy",y))}}function renderStroke(styleData,itemData,isFirstFrame){var styleElem=itemData.style,d=itemData.d;d&&(d._mdf||isFirstFrame)&&d.dashStr&&(styleElem.pElem.setAttribute("stroke-dasharray",d.dashStr),styleElem.pElem.setAttribute("stroke-dashoffset",d.dashoffset[0])),itemData.c&&(itemData.c._mdf||isFirstFrame)&&styleElem.pElem.setAttribute("stroke","rgb("+bmFloor(itemData.c.v[0])+","+bmFloor(itemData.c.v[1])+","+bmFloor(itemData.c.v[2])+")"),(itemData.o._mdf||isFirstFrame)&&styleElem.pElem.setAttribute("stroke-opacity",itemData.o.v),(itemData.w._mdf||isFirstFrame)&&(styleElem.pElem.setAttribute("stroke-width",itemData.w.v),styleElem.msElem&&styleElem.msElem.setAttribute("stroke-width",itemData.w.v))}return{createRenderFunction:function createRenderFunction(data){switch(data.ty){case"fl":return renderFill;case"gf":return renderGradient;case"gs":return renderGradientStroke;case"st":return renderStroke;case"sh":case"el":case"rc":case"sr":return renderPath;case"tr":return renderContentTransform;case"no":return renderNoop;default:return null}}}}();function SVGShapeElement(data,globalData,comp){this.shapes=[],this.shapesData=data.shapes,this.stylesList=[],this.shapeModifiers=[],this.itemsData=[],this.processedElements=[],this.animatedContents=[],this.initElement(data,globalData,comp),this.prevViewData=[]}function LetterProps(o,sw,sc,fc,m,p){this.o=o,this.sw=sw,this.sc=sc,this.fc=fc,this.m=m,this.p=p,this._mdf={o:!0,sw:!!sw,sc:!!sc,fc:!!fc,m:!0,p:!0}}function TextProperty(elem,data){this._frameId=-999999,this.pv="",this.v="",this.kf=!1,this._isFirstFrame=!0,this._mdf=!1,data.d&&data.d.sid&&(data.d=elem.globalData.slotManager.getProp(data.d)),this.data=data,this.elem=elem,this.comp=this.elem.comp,this.keysIndex=0,this.canResize=!1,this.minimumFontSize=1,this.effectsSequence=[],this.currentData={ascent:0,boxWidth:this.defaultBoxWidth,f:"",fStyle:"",fWeight:"",fc:"",j:"",justifyOffset:"",l:[],lh:0,lineWidths:[],ls:"",of:"",s:"",sc:"",sw:0,t:0,tr:0,sz:0,ps:null,fillColorAnim:!1,strokeColorAnim:!1,strokeWidthAnim:!1,yOffset:0,finalSize:0,finalText:[],finalLineHeight:0,__complete:!1},this.copyData(this.currentData,this.data.d.k[0].s),this.searchProperty()||this.completeTextData(this.currentData)}extendPrototype([BaseElement,TransformElement,SVGBaseElement,IShapeElement,HierarchyElement,FrameElement,RenderableDOMElement],SVGShapeElement),SVGShapeElement.prototype.initSecondaryElement=function(){},SVGShapeElement.prototype.identityMatrix=new Matrix,SVGShapeElement.prototype.buildExpressionInterface=function(){},SVGShapeElement.prototype.createContent=function(){this.searchShapes(this.shapesData,this.itemsData,this.prevViewData,this.layerElement,0,[],!0),this.filterUniqueShapes()},SVGShapeElement.prototype.filterUniqueShapes=function(){var i,shape,j,style,len=this.shapes.length,jLen=this.stylesList.length,tempShapes=[],areAnimated=!1;for(j=0;j<jLen;j+=1){for(i=0,style=this.stylesList[j],areAnimated=!1,tempShapes.length=0;i<len;i+=1)-1!==(shape=this.shapes[i]).styles.indexOf(style)&&(tempShapes.push(shape),areAnimated=shape._isAnimated||areAnimated);tempShapes.length>1&&areAnimated&&this.setShapesAsAnimated(tempShapes)}},SVGShapeElement.prototype.setShapesAsAnimated=function(shapes){var i,len=shapes.length;for(i=0;i<len;i+=1)shapes[i].setAsAnimated()},SVGShapeElement.prototype.createStyleElement=function(data,level){var elementData,styleOb=new SVGStyleData(data,level),pathElement=styleOb.pElem;return"st"===data.ty?elementData=new SVGStrokeStyleData(this,data,styleOb):"fl"===data.ty?elementData=new SVGFillStyleData(this,data,styleOb):"gf"===data.ty||"gs"===data.ty?(elementData=new("gf"===data.ty?SVGGradientFillStyleData:SVGGradientStrokeStyleData)(this,data,styleOb),this.globalData.defs.appendChild(elementData.gf),elementData.maskId&&(this.globalData.defs.appendChild(elementData.ms),this.globalData.defs.appendChild(elementData.of),pathElement.setAttribute("mask","url("+getLocationHref()+"#"+elementData.maskId+")"))):"no"===data.ty&&(elementData=new SVGNoStyleData(this,data,styleOb)),("st"===data.ty||"gs"===data.ty)&&(pathElement.setAttribute("stroke-linecap",lineCapEnum[data.lc||2]),pathElement.setAttribute("stroke-linejoin",lineJoinEnum[data.lj||2]),pathElement.setAttribute("fill-opacity","0"),1===data.lj&&pathElement.setAttribute("stroke-miterlimit",data.ml)),2===data.r&&pathElement.setAttribute("fill-rule","evenodd"),data.ln&&pathElement.setAttribute("id",data.ln),data.cl&&pathElement.setAttribute("class",data.cl),data.bm&&(pathElement.style["mix-blend-mode"]=getBlendMode(data.bm)),this.stylesList.push(styleOb),this.addToAnimatedContents(data,elementData),elementData},SVGShapeElement.prototype.createGroupElement=function(data){var elementData=new ShapeGroupData;return data.ln&&elementData.gr.setAttribute("id",data.ln),data.cl&&elementData.gr.setAttribute("class",data.cl),data.bm&&(elementData.gr.style["mix-blend-mode"]=getBlendMode(data.bm)),elementData},SVGShapeElement.prototype.createTransformElement=function(data,container){var transformProperty=TransformPropertyFactory.getTransformProperty(this,data,this),elementData=new SVGTransformData(transformProperty,transformProperty.o,container);return this.addToAnimatedContents(data,elementData),elementData},SVGShapeElement.prototype.createShapeElement=function(data,ownTransformers,level){var ty=4;"rc"===data.ty?ty=5:"el"===data.ty?ty=6:"sr"===data.ty&&(ty=7);var elementData=new SVGShapeData(ownTransformers,level,ShapePropertyFactory.getShapeProp(this,data,ty,this));return this.shapes.push(elementData),this.addShapeToModifiers(elementData),this.addToAnimatedContents(data,elementData),elementData},SVGShapeElement.prototype.addToAnimatedContents=function(data,element){for(var i=0,len=this.animatedContents.length;i<len;){if(this.animatedContents[i].element===element)return;i+=1}this.animatedContents.push({fn:SVGElementsRenderer.createRenderFunction(data),element:element,data:data})},SVGShapeElement.prototype.setElementStyles=function(elementData){var j,arr=elementData.styles,jLen=this.stylesList.length;for(j=0;j<jLen;j+=1)this.stylesList[j].closed||arr.push(this.stylesList[j])},SVGShapeElement.prototype.reloadShapes=function(){this._isFirstFrame=!0;var i,len=this.itemsData.length;for(i=0;i<len;i+=1)this.prevViewData[i]=this.itemsData[i];for(this.searchShapes(this.shapesData,this.itemsData,this.prevViewData,this.layerElement,0,[],!0),this.filterUniqueShapes(),len=this.dynamicProperties.length,i=0;i<len;i+=1)this.dynamicProperties[i].getValue();this.renderModifiers()},SVGShapeElement.prototype.searchShapes=function(arr,itemsData,prevViewData,container,level,transformers,render){var i,j,jLen,currentTransform,modifier,processedPos,ownTransformers=[].concat(transformers),len=arr.length-1,ownStyles=[],ownModifiers=[];for(i=len;i>=0;i-=1){if((processedPos=this.searchProcessedElement(arr[i]))?itemsData[i]=prevViewData[processedPos-1]:arr[i]._render=render,"fl"===arr[i].ty||"st"===arr[i].ty||"gf"===arr[i].ty||"gs"===arr[i].ty||"no"===arr[i].ty)processedPos?itemsData[i].style.closed=!1:itemsData[i]=this.createStyleElement(arr[i],level),arr[i]._render&&itemsData[i].style.pElem.parentNode!==container&&container.appendChild(itemsData[i].style.pElem),ownStyles.push(itemsData[i].style);else if("gr"===arr[i].ty){if(processedPos)for(j=0,jLen=itemsData[i].it.length;j<jLen;j+=1)itemsData[i].prevViewData[j]=itemsData[i].it[j];else itemsData[i]=this.createGroupElement(arr[i]);this.searchShapes(arr[i].it,itemsData[i].it,itemsData[i].prevViewData,itemsData[i].gr,level+1,ownTransformers,render),arr[i]._render&&itemsData[i].gr.parentNode!==container&&container.appendChild(itemsData[i].gr)}else"tr"===arr[i].ty?(processedPos||(itemsData[i]=this.createTransformElement(arr[i],container)),currentTransform=itemsData[i].transform,ownTransformers.push(currentTransform)):"sh"===arr[i].ty||"rc"===arr[i].ty||"el"===arr[i].ty||"sr"===arr[i].ty?(processedPos||(itemsData[i]=this.createShapeElement(arr[i],ownTransformers,level)),this.setElementStyles(itemsData[i])):"tm"===arr[i].ty||"rd"===arr[i].ty||"ms"===arr[i].ty||"pb"===arr[i].ty||"zz"===arr[i].ty||"op"===arr[i].ty?(processedPos?(modifier=itemsData[i]).closed=!1:((modifier=ShapeModifiers.getModifier(arr[i].ty)).init(this,arr[i]),itemsData[i]=modifier,this.shapeModifiers.push(modifier)),ownModifiers.push(modifier)):"rp"===arr[i].ty&&(processedPos?(modifier=itemsData[i]).closed=!0:(modifier=ShapeModifiers.getModifier(arr[i].ty),itemsData[i]=modifier,modifier.init(this,arr,i,itemsData),this.shapeModifiers.push(modifier),render=!1),ownModifiers.push(modifier));this.addProcessedElement(arr[i],i+1)}for(i=0,len=ownStyles.length;i<len;i+=1)ownStyles[i].closed=!0;for(i=0,len=ownModifiers.length;i<len;i+=1)ownModifiers[i].closed=!0},SVGShapeElement.prototype.renderInnerContent=function(){this.renderModifiers();var i,len=this.stylesList.length;for(i=0;i<len;i+=1)this.stylesList[i].reset();for(this.renderShape(),i=0;i<len;i+=1)(this.stylesList[i]._mdf||this._isFirstFrame)&&(this.stylesList[i].msElem&&(this.stylesList[i].msElem.setAttribute("d",this.stylesList[i].d),this.stylesList[i].d="M0 0"+this.stylesList[i].d),this.stylesList[i].pElem.setAttribute("d",this.stylesList[i].d||"M0 0"))},SVGShapeElement.prototype.renderShape=function(){var i,animatedContent,len=this.animatedContents.length;for(i=0;i<len;i+=1)animatedContent=this.animatedContents[i],(this._isFirstFrame||animatedContent.element._isAnimated)&&!0!==animatedContent.data&&animatedContent.fn(animatedContent.data,animatedContent.element,this._isFirstFrame)},SVGShapeElement.prototype.destroy=function(){this.destroyBaseElement(),this.shapesData=null,this.itemsData=null},LetterProps.prototype.update=function(o,sw,sc,fc,m,p){this._mdf.o=!1,this._mdf.sw=!1,this._mdf.sc=!1,this._mdf.fc=!1,this._mdf.m=!1,this._mdf.p=!1;var updated=!1;return this.o!==o&&(this.o=o,this._mdf.o=!0,updated=!0),this.sw!==sw&&(this.sw=sw,this._mdf.sw=!0,updated=!0),this.sc!==sc&&(this.sc=sc,this._mdf.sc=!0,updated=!0),this.fc!==fc&&(this.fc=fc,this._mdf.fc=!0,updated=!0),this.m!==m&&(this.m=m,this._mdf.m=!0,updated=!0),p.length&&(this.p[0]!==p[0]||this.p[1]!==p[1]||this.p[4]!==p[4]||this.p[5]!==p[5]||this.p[12]!==p[12]||this.p[13]!==p[13])&&(this.p=p,this._mdf.p=!0,updated=!0),updated},TextProperty.prototype.defaultBoxWidth=[0,0],TextProperty.prototype.copyData=function(obj,data){for(var s in data)Object.prototype.hasOwnProperty.call(data,s)&&(obj[s]=data[s]);return obj},TextProperty.prototype.setCurrentData=function(data){data.__complete||this.completeTextData(data),this.currentData=data,this.currentData.boxWidth=this.currentData.boxWidth||this.defaultBoxWidth,this._mdf=!0},TextProperty.prototype.searchProperty=function(){return this.searchKeyframes()},TextProperty.prototype.searchKeyframes=function(){return this.kf=this.data.d.k.length>1,this.kf&&this.addEffect(this.getKeyframeValue.bind(this)),this.kf},TextProperty.prototype.addEffect=function(effectFunction){this.effectsSequence.push(effectFunction),this.elem.addDynamicProperty(this)},TextProperty.prototype.getValue=function(_finalValue){if(this.elem.globalData.frameId!==this.frameId&&this.effectsSequence.length||_finalValue){this.currentData.t=this.data.d.k[this.keysIndex].s.t;var i,currentValue=this.currentData,currentIndex=this.keysIndex;if(this.lock){this.setCurrentData(this.currentData);return}this.lock=!0,this._mdf=!1;var len=this.effectsSequence.length,finalValue=_finalValue||this.data.d.k[this.keysIndex].s;for(i=0;i<len;i+=1)finalValue=currentIndex!==this.keysIndex?this.effectsSequence[i](finalValue,finalValue.t):this.effectsSequence[i](this.currentData,finalValue.t);currentValue!==finalValue&&this.setCurrentData(finalValue),this.v=this.currentData,this.pv=this.v,this.lock=!1,this.frameId=this.elem.globalData.frameId}},TextProperty.prototype.getKeyframeValue=function(){for(var textKeys=this.data.d.k,frameNum=this.elem.comp.renderedFrame,i=0,len=textKeys.length;i<=len-1&&i!==len-1&&!(textKeys[i+1].t>frameNum);)i+=1;return this.keysIndex!==i&&(this.keysIndex=i),this.data.d.k[this.keysIndex].s},TextProperty.prototype.buildFinalText=function(text){for(var charCode,secondCharCode,charactersArray=[],i=0,len=text.length,shouldCombine=!1,shouldCombineNext=!1,currentChars="";i<len;)shouldCombine=shouldCombineNext,shouldCombineNext=!1,charCode=text.charCodeAt(i),currentChars=text.charAt(i),FontManager.isCombinedCharacter(charCode)?shouldCombine=!0:charCode>=55296&&charCode<=56319?FontManager.isRegionalFlag(text,i)?currentChars=text.substr(i,14):(secondCharCode=text.charCodeAt(i+1))>=56320&&secondCharCode<=57343&&(FontManager.isModifier(charCode,secondCharCode)?(currentChars=text.substr(i,2),shouldCombine=!0):currentChars=FontManager.isFlagEmoji(text.substr(i,4))?text.substr(i,4):text.substr(i,2)):charCode>56319?(secondCharCode=text.charCodeAt(i+1),FontManager.isVariationSelector(charCode)&&(shouldCombine=!0)):FontManager.isZeroWidthJoiner(charCode)&&(shouldCombine=!0,shouldCombineNext=!0),shouldCombine?(charactersArray[charactersArray.length-1]+=currentChars,shouldCombine=!1):charactersArray.push(currentChars),i+=currentChars.length;return charactersArray},TextProperty.prototype.completeTextData=function(documentData){documentData.__complete=!0;var fontManager=this.elem.globalData.fontManager,data=this.data,letters=[],index=0,anchorGrouping=data.m.g,currentSize=0,currentPos=0,currentLine=0,lineWidths=[],lineWidth=0,maxLineWidth=0,fontData=fontManager.getFontByName(documentData.f),cLength=0,fontProps=getFontProperties(fontData);documentData.fWeight=fontProps.weight,documentData.fStyle=fontProps.style,documentData.finalSize=documentData.s,documentData.finalText=this.buildFinalText(documentData.t),len=documentData.finalText.length,documentData.finalLineHeight=documentData.lh;var trackingOffset=documentData.tr/1e3*documentData.finalSize;if(documentData.sz)for(var i,len,newLineFlag,val,j,jLen,charData,charCode,currentHeight,finalText,flag=!0,boxWidth=documentData.sz[0],boxHeight=documentData.sz[1];flag;){finalText=this.buildFinalText(documentData.t),currentHeight=0,lineWidth=0,len=finalText.length,trackingOffset=documentData.tr/1e3*documentData.finalSize;var lastSpaceIndex=-1;for(i=0;i<len;i+=1)charCode=finalText[i].charCodeAt(0),newLineFlag=!1," "===finalText[i]?lastSpaceIndex=i:(13===charCode||3===charCode)&&(lineWidth=0,newLineFlag=!0,currentHeight+=documentData.finalLineHeight||1.2*documentData.finalSize),fontManager.chars?(charData=fontManager.getCharData(finalText[i],fontData.fStyle,fontData.fFamily),cLength=newLineFlag?0:charData.w*documentData.finalSize/100):cLength=fontManager.measureText(finalText[i],documentData.f,documentData.finalSize),lineWidth+cLength>boxWidth&&" "!==finalText[i]?(-1===lastSpaceIndex?len+=1:i=lastSpaceIndex,currentHeight+=documentData.finalLineHeight||1.2*documentData.finalSize,finalText.splice(i,lastSpaceIndex===i?1:0,"\r"),lastSpaceIndex=-1,lineWidth=0):lineWidth+=cLength+trackingOffset;currentHeight+=fontData.ascent*documentData.finalSize/100,this.canResize&&documentData.finalSize>this.minimumFontSize&&boxHeight<currentHeight?(documentData.finalSize-=1,documentData.finalLineHeight=documentData.finalSize*documentData.lh/documentData.s):(documentData.finalText=finalText,len=documentData.finalText.length,flag=!1)}lineWidth=-trackingOffset,cLength=0;var uncollapsedSpaces=0;for(i=0;i<len;i+=1)if(newLineFlag=!1,13===(charCode=(currentChar=documentData.finalText[i]).charCodeAt(0))||3===charCode?(uncollapsedSpaces=0,lineWidths.push(lineWidth),maxLineWidth=lineWidth>maxLineWidth?lineWidth:maxLineWidth,lineWidth=-2*trackingOffset,val="",newLineFlag=!0,currentLine+=1):val=currentChar,fontManager.chars?(charData=fontManager.getCharData(currentChar,fontData.fStyle,fontManager.getFontByName(documentData.f).fFamily),cLength=newLineFlag?0:charData.w*documentData.finalSize/100):cLength=fontManager.measureText(val,documentData.f,documentData.finalSize)," "===currentChar?uncollapsedSpaces+=cLength+trackingOffset:(lineWidth+=cLength+trackingOffset+uncollapsedSpaces,uncollapsedSpaces=0),letters.push({l:cLength,an:cLength,add:currentSize,n:newLineFlag,anIndexes:[],val:val,line:currentLine,animatorJustifyOffset:0}),2==anchorGrouping){if(currentSize+=cLength,""===val||" "===val||i===len-1){for((""===val||" "===val)&&(currentSize-=cLength);currentPos<=i;)letters[currentPos].an=currentSize,letters[currentPos].ind=index,letters[currentPos].extra=cLength,currentPos+=1;index+=1,currentSize=0}}else if(3==anchorGrouping){if(currentSize+=cLength,""===val||i===len-1){for(""===val&&(currentSize-=cLength);currentPos<=i;)letters[currentPos].an=currentSize,letters[currentPos].ind=index,letters[currentPos].extra=cLength,currentPos+=1;currentSize=0,index+=1}}else letters[index].ind=index,letters[index].extra=0,index+=1;if(documentData.l=letters,maxLineWidth=lineWidth>maxLineWidth?lineWidth:maxLineWidth,lineWidths.push(lineWidth),documentData.sz)documentData.boxWidth=documentData.sz[0],documentData.justifyOffset=0;else switch(documentData.boxWidth=maxLineWidth,documentData.j){case 1:documentData.justifyOffset=-documentData.boxWidth;break;case 2:documentData.justifyOffset=-documentData.boxWidth/2;break;default:documentData.justifyOffset=0}documentData.lineWidths=lineWidths;var animators=data.a;jLen=animators.length;var indexes=[];for(j=0;j<jLen;j+=1){for((animatorData=animators[j]).a.sc&&(documentData.strokeColorAnim=!0),animatorData.a.sw&&(documentData.strokeWidthAnim=!0),(animatorData.a.fc||animatorData.a.fh||animatorData.a.fs||animatorData.a.fb)&&(documentData.fillColorAnim=!0),ind=0,based=animatorData.s.b,i=0;i<len;i+=1)(letterData=letters[i]).anIndexes[j]=ind,(1==based&&""!==letterData.val||2==based&&""!==letterData.val&&" "!==letterData.val||3==based&&(letterData.n||" "==letterData.val||i==len-1)||4==based&&(letterData.n||i==len-1))&&(1===animatorData.s.rn&&indexes.push(ind),ind+=1);data.a[j].s.totalChars=ind;var currentChar,animatorData,letterData,based,ind,newInd,currentInd=-1;if(1===animatorData.s.rn)for(i=0;i<len;i+=1)currentInd!=(letterData=letters[i]).anIndexes[j]&&(currentInd=letterData.anIndexes[j],newInd=indexes.splice(Math.floor(Math.random()*indexes.length),1)[0]),letterData.anIndexes[j]=newInd}documentData.yOffset=documentData.finalLineHeight||1.2*documentData.finalSize,documentData.ls=documentData.ls||0,documentData.ascent=fontData.ascent*documentData.finalSize/100},TextProperty.prototype.updateDocumentData=function(newData,index){index=void 0===index?this.keysIndex:index;var dData=this.copyData({},this.data.d.k[index].s);dData=this.copyData(dData,newData),this.data.d.k[index].s=dData,this.recalculate(index),this.setCurrentData(dData),this.elem.addDynamicProperty(this)},TextProperty.prototype.recalculate=function(index){var dData=this.data.d.k[index].s;dData.__complete=!1,this.keysIndex=0,this._isFirstFrame=!0,this.getValue(dData)},TextProperty.prototype.canResizeFont=function(_canResize){this.canResize=_canResize,this.recalculate(this.keysIndex),this.elem.addDynamicProperty(this)},TextProperty.prototype.setMinimumFontSize=function(_fontValue){this.minimumFontSize=Math.floor(_fontValue)||1,this.recalculate(this.keysIndex),this.elem.addDynamicProperty(this)};var TextSelectorProp=function(){var max=Math.max,min=Math.min,floor=Math.floor;function TextSelectorPropFactory(elem,data){this._currentTextLength=-1,this.k=!1,this.data=data,this.elem=elem,this.comp=elem.comp,this.finalS=0,this.finalE=0,this.initDynamicPropertyContainer(elem),this.s=PropertyFactory.getProp(elem,data.s||{k:0},0,0,this),"e"in data?this.e=PropertyFactory.getProp(elem,data.e,0,0,this):this.e={v:100},this.o=PropertyFactory.getProp(elem,data.o||{k:0},0,0,this),this.xe=PropertyFactory.getProp(elem,data.xe||{k:0},0,0,this),this.ne=PropertyFactory.getProp(elem,data.ne||{k:0},0,0,this),this.sm=PropertyFactory.getProp(elem,data.sm||{k:100},0,0,this),this.a=PropertyFactory.getProp(elem,data.a,0,.01,this),this.dynamicProperties.length||this.getValue()}return TextSelectorPropFactory.prototype={getMult:function getMult(ind){this._currentTextLength!==this.elem.textProperty.currentData.l.length&&this.getValue();var x1=0,y1=0,x2=1,y2=1;this.ne.v>0?x1=this.ne.v/100:y1=-this.ne.v/100,this.xe.v>0?x2=1-this.xe.v/100:y2=1+this.xe.v/100;var easer=BezierFactory.getBezierEasing(x1,y1,x2,y2).get,mult=0,s=this.finalS,e=this.finalE,type=this.data.sh;if(2===type)mult=easer(mult=e===s?ind>=e?1:0:max(0,min(.5/(e-s)+(ind-s)/(e-s),1)));else if(3===type)mult=easer(mult=e===s?ind>=e?0:1:1-max(0,min(.5/(e-s)+(ind-s)/(e-s),1)));else if(4===type)e===s?mult=0:(mult=max(0,min(.5/(e-s)+(ind-s)/(e-s),1)))<.5?mult*=2:mult=1-2*(mult-.5),mult=easer(mult);else if(5===type){if(e===s)mult=0;else{var tot=e-s,x=-tot/2+(ind=min(max(0,ind+.5-s),e-s)),a=tot/2;mult=Math.sqrt(1-x*x/(a*a))}mult=easer(mult)}else 6===type?mult=easer(mult=e===s?0:(1+Math.cos(Math.PI+2*Math.PI*(ind=min(max(0,ind+.5-s),e-s))/(e-s)))/2):(ind>=floor(s)&&(mult=ind-s<0?max(0,min(min(e,1)-(s-ind),1)):max(0,min(e-ind,1))),mult=easer(mult));if(100!==this.sm.v){var smoothness=.01*this.sm.v;0===smoothness&&(smoothness=1e-8);var threshold=.5-.5*smoothness;mult<threshold?mult=0:(mult=(mult-threshold)/smoothness)>1&&(mult=1)}return mult*this.a.v},getValue:function getValue(newCharsFlag){this.iterateDynamicProperties(),this._mdf=newCharsFlag||this._mdf,this._currentTextLength=this.elem.textProperty.currentData.l.length||0,newCharsFlag&&2===this.data.r&&(this.e.v=this._currentTextLength);var divisor=2===this.data.r?1:100/this.data.totalChars,o=this.o.v/divisor,s=this.s.v/divisor+o,e=this.e.v/divisor+o;if(s>e){var _s=s;s=e,e=_s}this.finalS=s,this.finalE=e}},extendPrototype([DynamicPropertyContainer],TextSelectorPropFactory),{getTextSelectorProp:function getTextSelectorProp(elem,data,arr){return new TextSelectorPropFactory(elem,data,arr)}}}();function TextAnimatorDataProperty(elem,animatorProps,container){var defaultData={propType:!1},getProp=PropertyFactory.getProp,textAnimatorAnimatables=animatorProps.a;this.a={r:textAnimatorAnimatables.r?getProp(elem,textAnimatorAnimatables.r,0,degToRads,container):defaultData,rx:textAnimatorAnimatables.rx?getProp(elem,textAnimatorAnimatables.rx,0,degToRads,container):defaultData,ry:textAnimatorAnimatables.ry?getProp(elem,textAnimatorAnimatables.ry,0,degToRads,container):defaultData,sk:textAnimatorAnimatables.sk?getProp(elem,textAnimatorAnimatables.sk,0,degToRads,container):defaultData,sa:textAnimatorAnimatables.sa?getProp(elem,textAnimatorAnimatables.sa,0,degToRads,container):defaultData,s:textAnimatorAnimatables.s?getProp(elem,textAnimatorAnimatables.s,1,.01,container):defaultData,a:textAnimatorAnimatables.a?getProp(elem,textAnimatorAnimatables.a,1,0,container):defaultData,o:textAnimatorAnimatables.o?getProp(elem,textAnimatorAnimatables.o,0,.01,container):defaultData,p:textAnimatorAnimatables.p?getProp(elem,textAnimatorAnimatables.p,1,0,container):defaultData,sw:textAnimatorAnimatables.sw?getProp(elem,textAnimatorAnimatables.sw,0,0,container):defaultData,sc:textAnimatorAnimatables.sc?getProp(elem,textAnimatorAnimatables.sc,1,0,container):defaultData,fc:textAnimatorAnimatables.fc?getProp(elem,textAnimatorAnimatables.fc,1,0,container):defaultData,fh:textAnimatorAnimatables.fh?getProp(elem,textAnimatorAnimatables.fh,0,0,container):defaultData,fs:textAnimatorAnimatables.fs?getProp(elem,textAnimatorAnimatables.fs,0,.01,container):defaultData,fb:textAnimatorAnimatables.fb?getProp(elem,textAnimatorAnimatables.fb,0,.01,container):defaultData,t:textAnimatorAnimatables.t?getProp(elem,textAnimatorAnimatables.t,0,0,container):defaultData},this.s=TextSelectorProp.getTextSelectorProp(elem,animatorProps.s,container),this.s.t=animatorProps.s.t}function TextAnimatorProperty(textData,renderType,elem){this._isFirstFrame=!0,this._hasMaskedPath=!1,this._frameId=-1,this._textData=textData,this._renderType=renderType,this._elem=elem,this._animatorsData=createSizedArray(this._textData.a.length),this._pathData={},this._moreOptions={alignment:{}},this.renderedLetters=[],this.lettersChangedFlag=!1,this.initDynamicPropertyContainer(elem)}function ITextElement(){}TextAnimatorProperty.prototype.searchProperties=function(){var i,animatorProps,len=this._textData.a.length,getProp=PropertyFactory.getProp;for(i=0;i<len;i+=1)animatorProps=this._textData.a[i],this._animatorsData[i]=new TextAnimatorDataProperty(this._elem,animatorProps,this);this._textData.p&&"m"in this._textData.p?(this._pathData={a:getProp(this._elem,this._textData.p.a,0,0,this),f:getProp(this._elem,this._textData.p.f,0,0,this),l:getProp(this._elem,this._textData.p.l,0,0,this),r:getProp(this._elem,this._textData.p.r,0,0,this),p:getProp(this._elem,this._textData.p.p,0,0,this),m:this._elem.maskManager.getMaskProperty(this._textData.p.m)},this._hasMaskedPath=!0):this._hasMaskedPath=!1,this._moreOptions.alignment=getProp(this._elem,this._textData.m.a,1,0,this)},TextAnimatorProperty.prototype.getMeasures=function(documentData,lettersChangedFlag){if(this.lettersChangedFlag=lettersChangedFlag,this._mdf||this._isFirstFrame||lettersChangedFlag||this._hasMaskedPath&&this._pathData.m._mdf){this._isFirstFrame=!1;var animatorProps,j,jLen,letterValue,mult,offf,xPathPos,yPathPos,elemOpacity,sc,sw,fc,k,letterSw,letterSc,letterFc,letterO,alignment=this._moreOptions.alignment.v,animators=this._animatorsData,textData=this._textData,matrixHelper=this.mHelper,renderType=this._renderType,renderedLettersCount=this.renderedLetters.length,letters=documentData.l;if(this._hasMaskedPath){if(mask=this._pathData.m,!this._pathData.n||this._pathData._mdf){var xPos,yPos,i,len,pathInfo,currentLength,currentPoint,segmentLength,flag,pointInd,segmentInd,prevPoint,points,segments,partialLength,totalLength,perc,mask,bezierData,paths=mask.v;for(this._pathData.r.v&&(paths=paths.reverse()),pathInfo={tLength:0,segments:[]},len=paths._length-1,totalLength=0,i=0;i<len;i+=1)bezierData=bez.buildBezierData(paths.v[i],paths.v[i+1],[paths.o[i][0]-paths.v[i][0],paths.o[i][1]-paths.v[i][1]],[paths.i[i+1][0]-paths.v[i+1][0],paths.i[i+1][1]-paths.v[i+1][1]]),pathInfo.tLength+=bezierData.segmentLength,pathInfo.segments.push(bezierData),totalLength+=bezierData.segmentLength;i=len,mask.v.c&&(bezierData=bez.buildBezierData(paths.v[i],paths.v[0],[paths.o[i][0]-paths.v[i][0],paths.o[i][1]-paths.v[i][1]],[paths.i[0][0]-paths.v[0][0],paths.i[0][1]-paths.v[0][1]]),pathInfo.tLength+=bezierData.segmentLength,pathInfo.segments.push(bezierData),totalLength+=bezierData.segmentLength),this._pathData.pi=pathInfo}if(pathInfo=this._pathData.pi,currentLength=this._pathData.f.v,segmentInd=0,pointInd=1,segmentLength=0,flag=!0,segments=pathInfo.segments,currentLength<0&&mask.v.c)for(pathInfo.tLength<Math.abs(currentLength)&&(currentLength=-Math.abs(currentLength)%pathInfo.tLength),segmentInd=segments.length-1,pointInd=(points=segments[segmentInd].points).length-1;currentLength<0;)currentLength+=points[pointInd].partialLength,(pointInd-=1)<0&&(segmentInd-=1,pointInd=(points=segments[segmentInd].points).length-1);prevPoint=(points=segments[segmentInd].points)[pointInd-1],partialLength=(currentPoint=points[pointInd]).partialLength}len=letters.length,xPos=0,yPos=0;var yOff=1.2*documentData.finalSize*.714,firstLine=!0;jLen=animators.length;var ind=-1,initPathPos=currentLength,initSegmentInd=segmentInd,initPointInd=pointInd,currentLine=-1,letterM="",letterP=this.defaultPropsArray;if(2===documentData.j||1===documentData.j){var animatorJustifyOffset=0,animatorFirstCharOffset=0,justifyOffsetMult=2===documentData.j?-.5:-1,lastIndex=0,isNewLine=!0;for(i=0;i<len;i+=1)if(letters[i].n){for(animatorJustifyOffset&&(animatorJustifyOffset+=animatorFirstCharOffset);lastIndex<i;)letters[lastIndex].animatorJustifyOffset=animatorJustifyOffset,lastIndex+=1;animatorJustifyOffset=0,isNewLine=!0}else{for(j=0;j<jLen;j+=1)(animatorProps=animators[j].a).t.propType&&(isNewLine&&2===documentData.j&&(animatorFirstCharOffset+=animatorProps.t.v*justifyOffsetMult),(mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars)).length?animatorJustifyOffset+=animatorProps.t.v*mult[0]*justifyOffsetMult:animatorJustifyOffset+=animatorProps.t.v*mult*justifyOffsetMult);isNewLine=!1}for(animatorJustifyOffset&&(animatorJustifyOffset+=animatorFirstCharOffset);lastIndex<i;)letters[lastIndex].animatorJustifyOffset=animatorJustifyOffset,lastIndex+=1}for(i=0;i<len;i+=1){if(matrixHelper.reset(),elemOpacity=1,letters[i].n)xPos=0,yPos+=documentData.yOffset+(firstLine?1:0),currentLength=initPathPos,firstLine=!1,this._hasMaskedPath&&(segmentInd=initSegmentInd,pointInd=initPointInd,prevPoint=(points=segments[segmentInd].points)[pointInd-1],partialLength=(currentPoint=points[pointInd]).partialLength,segmentLength=0),letterM="",letterFc="",letterSw="",letterO="",letterP=this.defaultPropsArray;else{if(this._hasMaskedPath){if(currentLine!==letters[i].line){switch(documentData.j){case 1:currentLength+=totalLength-documentData.lineWidths[letters[i].line];break;case 2:currentLength+=(totalLength-documentData.lineWidths[letters[i].line])/2}currentLine=letters[i].line}ind!==letters[i].ind&&(letters[ind]&&(currentLength+=letters[ind].extra),currentLength+=letters[i].an/2,ind=letters[i].ind),currentLength+=alignment[0]*letters[i].an*.005;var animatorOffset=0;for(j=0;j<jLen;j+=1)(animatorProps=animators[j].a).p.propType&&((mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars)).length?animatorOffset+=animatorProps.p.v[0]*mult[0]:animatorOffset+=animatorProps.p.v[0]*mult),animatorProps.a.propType&&((mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars)).length?animatorOffset+=animatorProps.a.v[0]*mult[0]:animatorOffset+=animatorProps.a.v[0]*mult);for(flag=!0,this._pathData.a.v&&(currentLength=.5*letters[0].an+(totalLength-this._pathData.f.v-.5*letters[0].an-.5*letters[letters.length-1].an)*ind/(len-1)+this._pathData.f.v);flag;)segmentLength+partialLength>=currentLength+animatorOffset||!points?(perc=(currentLength+animatorOffset-segmentLength)/currentPoint.partialLength,xPathPos=prevPoint.point[0]+(currentPoint.point[0]-prevPoint.point[0])*perc,yPathPos=prevPoint.point[1]+(currentPoint.point[1]-prevPoint.point[1])*perc,matrixHelper.translate(-alignment[0]*letters[i].an*.005,-(.01*(alignment[1]*yOff))),flag=!1):points&&(segmentLength+=currentPoint.partialLength,(pointInd+=1)>=points.length&&(pointInd=0,segments[segmentInd+=1]?points=segments[segmentInd].points:mask.v.c?(pointInd=0,points=segments[segmentInd=0].points):(segmentLength-=currentPoint.partialLength,points=null)),points&&(prevPoint=currentPoint,partialLength=(currentPoint=points[pointInd]).partialLength));offf=letters[i].an/2-letters[i].add,matrixHelper.translate(-offf,0,0)}else offf=letters[i].an/2-letters[i].add,matrixHelper.translate(-offf,0,0),matrixHelper.translate(-alignment[0]*letters[i].an*.005,-alignment[1]*yOff*.01,0);for(j=0;j<jLen;j+=1)(animatorProps=animators[j].a).t.propType&&(mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars),(0!==xPos||0!==documentData.j)&&(this._hasMaskedPath?mult.length?currentLength+=animatorProps.t.v*mult[0]:currentLength+=animatorProps.t.v*mult:mult.length?xPos+=animatorProps.t.v*mult[0]:xPos+=animatorProps.t.v*mult));for(documentData.strokeWidthAnim&&(sw=documentData.sw||0),documentData.strokeColorAnim&&(sc=documentData.sc?[documentData.sc[0],documentData.sc[1],documentData.sc[2]]:[0,0,0]),documentData.fillColorAnim&&documentData.fc&&(fc=[documentData.fc[0],documentData.fc[1],documentData.fc[2]]),j=0;j<jLen;j+=1)(animatorProps=animators[j].a).a.propType&&((mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars)).length?matrixHelper.translate(-animatorProps.a.v[0]*mult[0],-animatorProps.a.v[1]*mult[1],animatorProps.a.v[2]*mult[2]):matrixHelper.translate(-animatorProps.a.v[0]*mult,-animatorProps.a.v[1]*mult,animatorProps.a.v[2]*mult));for(j=0;j<jLen;j+=1)(animatorProps=animators[j].a).s.propType&&((mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars)).length?matrixHelper.scale(1+(animatorProps.s.v[0]-1)*mult[0],1+(animatorProps.s.v[1]-1)*mult[1],1):matrixHelper.scale(1+(animatorProps.s.v[0]-1)*mult,1+(animatorProps.s.v[1]-1)*mult,1));for(j=0;j<jLen;j+=1){if(animatorProps=animators[j].a,mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars),animatorProps.sk.propType&&(mult.length?matrixHelper.skewFromAxis(-animatorProps.sk.v*mult[0],animatorProps.sa.v*mult[1]):matrixHelper.skewFromAxis(-animatorProps.sk.v*mult,animatorProps.sa.v*mult)),animatorProps.r.propType&&(mult.length?matrixHelper.rotateZ(-animatorProps.r.v*mult[2]):matrixHelper.rotateZ(-animatorProps.r.v*mult)),animatorProps.ry.propType&&(mult.length?matrixHelper.rotateY(animatorProps.ry.v*mult[1]):matrixHelper.rotateY(animatorProps.ry.v*mult)),animatorProps.rx.propType&&(mult.length?matrixHelper.rotateX(animatorProps.rx.v*mult[0]):matrixHelper.rotateX(animatorProps.rx.v*mult)),animatorProps.o.propType&&(mult.length?elemOpacity+=(animatorProps.o.v*mult[0]-elemOpacity)*mult[0]:elemOpacity+=(animatorProps.o.v*mult-elemOpacity)*mult),documentData.strokeWidthAnim&&animatorProps.sw.propType&&(mult.length?sw+=animatorProps.sw.v*mult[0]:sw+=animatorProps.sw.v*mult),documentData.strokeColorAnim&&animatorProps.sc.propType)for(k=0;k<3;k+=1)mult.length?sc[k]+=(animatorProps.sc.v[k]-sc[k])*mult[0]:sc[k]+=(animatorProps.sc.v[k]-sc[k])*mult;if(documentData.fillColorAnim&&documentData.fc){if(animatorProps.fc.propType)for(k=0;k<3;k+=1)mult.length?fc[k]+=(animatorProps.fc.v[k]-fc[k])*mult[0]:fc[k]+=(animatorProps.fc.v[k]-fc[k])*mult;animatorProps.fh.propType&&(fc=mult.length?addHueToRGB(fc,animatorProps.fh.v*mult[0]):addHueToRGB(fc,animatorProps.fh.v*mult)),animatorProps.fs.propType&&(fc=mult.length?addSaturationToRGB(fc,animatorProps.fs.v*mult[0]):addSaturationToRGB(fc,animatorProps.fs.v*mult)),animatorProps.fb.propType&&(fc=mult.length?addBrightnessToRGB(fc,animatorProps.fb.v*mult[0]):addBrightnessToRGB(fc,animatorProps.fb.v*mult))}}for(j=0;j<jLen;j+=1)(animatorProps=animators[j].a).p.propType&&(mult=(0,animators[j].s).getMult(letters[i].anIndexes[j],textData.a[j].s.totalChars),this._hasMaskedPath?mult.length?matrixHelper.translate(0,animatorProps.p.v[1]*mult[0],-animatorProps.p.v[2]*mult[1]):matrixHelper.translate(0,animatorProps.p.v[1]*mult,-animatorProps.p.v[2]*mult):mult.length?matrixHelper.translate(animatorProps.p.v[0]*mult[0],animatorProps.p.v[1]*mult[1],-animatorProps.p.v[2]*mult[2]):matrixHelper.translate(animatorProps.p.v[0]*mult,animatorProps.p.v[1]*mult,-animatorProps.p.v[2]*mult));if(documentData.strokeWidthAnim&&(letterSw=sw<0?0:sw),documentData.strokeColorAnim&&(letterSc="rgb("+Math.round(255*sc[0])+","+Math.round(255*sc[1])+","+Math.round(255*sc[2])+")"),documentData.fillColorAnim&&documentData.fc&&(letterFc="rgb("+Math.round(255*fc[0])+","+Math.round(255*fc[1])+","+Math.round(255*fc[2])+")"),this._hasMaskedPath){if(matrixHelper.translate(0,-documentData.ls),matrixHelper.translate(0,alignment[1]*yOff*.01+yPos,0),this._pathData.p.v){var rot=180*Math.atan((currentPoint.point[1]-prevPoint.point[1])/(currentPoint.point[0]-prevPoint.point[0]))/Math.PI;currentPoint.point[0]<prevPoint.point[0]&&(rot+=180),matrixHelper.rotate(-rot*Math.PI/180)}matrixHelper.translate(xPathPos,yPathPos,0),currentLength-=alignment[0]*letters[i].an*.005,letters[i+1]&&ind!==letters[i+1].ind&&(currentLength+=letters[i].an/2+.001*documentData.tr*documentData.finalSize)}else{switch(matrixHelper.translate(xPos,yPos,0),documentData.ps&&matrixHelper.translate(documentData.ps[0],documentData.ps[1]+documentData.ascent,0),documentData.j){case 1:matrixHelper.translate(letters[i].animatorJustifyOffset+documentData.justifyOffset+(documentData.boxWidth-documentData.lineWidths[letters[i].line]),0,0);break;case 2:matrixHelper.translate(letters[i].animatorJustifyOffset+documentData.justifyOffset+(documentData.boxWidth-documentData.lineWidths[letters[i].line])/2,0,0)}matrixHelper.translate(0,-documentData.ls),matrixHelper.translate(offf,0,0),matrixHelper.translate(alignment[0]*letters[i].an*.005,alignment[1]*yOff*.01,0),xPos+=letters[i].l+.001*documentData.tr*documentData.finalSize}"html"===renderType?letterM=matrixHelper.toCSS():"svg"===renderType?letterM=matrixHelper.to2dCSS():letterP=[matrixHelper.props[0],matrixHelper.props[1],matrixHelper.props[2],matrixHelper.props[3],matrixHelper.props[4],matrixHelper.props[5],matrixHelper.props[6],matrixHelper.props[7],matrixHelper.props[8],matrixHelper.props[9],matrixHelper.props[10],matrixHelper.props[11],matrixHelper.props[12],matrixHelper.props[13],matrixHelper.props[14],matrixHelper.props[15]],letterO=elemOpacity}renderedLettersCount<=i?(letterValue=new LetterProps(letterO,letterSw,letterSc,letterFc,letterM,letterP),this.renderedLetters.push(letterValue),renderedLettersCount+=1,this.lettersChangedFlag=!0):(letterValue=this.renderedLetters[i],this.lettersChangedFlag=letterValue.update(letterO,letterSw,letterSc,letterFc,letterM,letterP)||this.lettersChangedFlag)}}},TextAnimatorProperty.prototype.getValue=function(){this._elem.globalData.frameId!==this._frameId&&(this._frameId=this._elem.globalData.frameId,this.iterateDynamicProperties())},TextAnimatorProperty.prototype.mHelper=new Matrix,TextAnimatorProperty.prototype.defaultPropsArray=[],extendPrototype([DynamicPropertyContainer],TextAnimatorProperty),ITextElement.prototype.initElement=function(data,globalData,comp){this.lettersChangedFlag=!0,this.initFrame(),this.initBaseData(data,globalData,comp),this.textProperty=new TextProperty(this,data.t,this.dynamicProperties),this.textAnimator=new TextAnimatorProperty(data.t,this.renderType,this),this.initTransform(data,globalData,comp),this.initHierarchy(),this.initRenderable(),this.initRendererElement(),this.createContainerElements(),this.createRenderableComponents(),this.createContent(),this.hide(),this.textAnimator.searchProperties(this.dynamicProperties)},ITextElement.prototype.prepareFrame=function(num){this._mdf=!1,this.prepareRenderableFrame(num),this.prepareProperties(num,this.isInRange)},ITextElement.prototype.createPathShape=function(matrixHelper,shapes){var j,pathNodes,jLen=shapes.length,shapeStr="";for(j=0;j<jLen;j+=1)"sh"===shapes[j].ty&&(shapeStr+=buildShapeString(pathNodes=shapes[j].ks.k,pathNodes.i.length,!0,matrixHelper));return shapeStr},ITextElement.prototype.updateDocumentData=function(newData,index){this.textProperty.updateDocumentData(newData,index)},ITextElement.prototype.canResizeFont=function(_canResize){this.textProperty.canResizeFont(_canResize)},ITextElement.prototype.setMinimumFontSize=function(_fontSize){this.textProperty.setMinimumFontSize(_fontSize)},ITextElement.prototype.applyTextPropertiesToMatrix=function(documentData,matrixHelper,lineNumber,xPos,yPos){switch(documentData.ps&&matrixHelper.translate(documentData.ps[0],documentData.ps[1]+documentData.ascent,0),matrixHelper.translate(0,-documentData.ls,0),documentData.j){case 1:matrixHelper.translate(documentData.justifyOffset+(documentData.boxWidth-documentData.lineWidths[lineNumber]),0,0);break;case 2:matrixHelper.translate(documentData.justifyOffset+(documentData.boxWidth-documentData.lineWidths[lineNumber])/2,0,0)}matrixHelper.translate(xPos,yPos,0)},ITextElement.prototype.buildColor=function(colorData){return"rgb("+Math.round(255*colorData[0])+","+Math.round(255*colorData[1])+","+Math.round(255*colorData[2])+")"},ITextElement.prototype.emptyProp=new LetterProps,ITextElement.prototype.destroy=function(){},ITextElement.prototype.validateText=function(){(this.textProperty._mdf||this.textProperty._isFirstFrame)&&(this.buildNewText(),this.textProperty._isFirstFrame=!1,this.textProperty._mdf=!1)};var emptyShapeData={shapes:[]};function SVGTextLottieElement(data,globalData,comp){this.textSpans=[],this.renderType="svg",this.initElement(data,globalData,comp)}function ISolidElement(data,globalData,comp){this.initElement(data,globalData,comp)}function NullElement(data,globalData,comp){this.initFrame(),this.initBaseData(data,globalData,comp),this.initFrame(),this.initTransform(data,globalData,comp),this.initHierarchy()}function SVGRendererBase(){}function ICompElement(){}function SVGCompElement(data,globalData,comp){this.layers=data.layers,this.supports3d=!0,this.completeLayers=!1,this.pendingElements=[],this.elements=this.layers?createSizedArray(this.layers.length):[],this.initElement(data,globalData,comp),this.tm=data.tm?PropertyFactory.getProp(this,data.tm,0,globalData.frameRate,this):{_placeholder:!0}}function SVGRenderer(animationItem,config){this.animationItem=animationItem,this.layers=null,this.renderedFrame=-1,this.svgElement=createNS("svg");var ariaLabel="";if(config&&config.title){var titleElement=createNS("title"),titleId=createElementID();titleElement.setAttribute("id",titleId),titleElement.textContent=config.title,this.svgElement.appendChild(titleElement),ariaLabel+=titleId}if(config&&config.description){var descElement=createNS("desc"),descId=createElementID();descElement.setAttribute("id",descId),descElement.textContent=config.description,this.svgElement.appendChild(descElement),ariaLabel+=" "+descId}ariaLabel&&this.svgElement.setAttribute("aria-labelledby",ariaLabel);var defs=createNS("defs");this.svgElement.appendChild(defs);var maskElement=createNS("g");this.svgElement.appendChild(maskElement),this.layerElement=maskElement,this.renderConfig={preserveAspectRatio:config&&config.preserveAspectRatio||"xMidYMid meet",imagePreserveAspectRatio:config&&config.imagePreserveAspectRatio||"xMidYMid slice",contentVisibility:config&&config.contentVisibility||"visible",progressiveLoad:config&&config.progressiveLoad||!1,hideOnTransparent:!(config&&!1===config.hideOnTransparent),viewBoxOnly:config&&config.viewBoxOnly||!1,viewBoxSize:config&&config.viewBoxSize||!1,className:config&&config.className||"",id:config&&config.id||"",focusable:config&&config.focusable,filterSize:{width:config&&config.filterSize&&config.filterSize.width||"100%",height:config&&config.filterSize&&config.filterSize.height||"100%",x:config&&config.filterSize&&config.filterSize.x||"0%",y:config&&config.filterSize&&config.filterSize.y||"0%"},width:config&&config.width,height:config&&config.height,runExpressions:!config||void 0===config.runExpressions||config.runExpressions},this.globalData={_mdf:!1,frameNum:-1,defs:defs,renderConfig:this.renderConfig},this.elements=[],this.pendingElements=[],this.destroyed=!1,this.rendererType="svg"}return extendPrototype([BaseElement,TransformElement,SVGBaseElement,HierarchyElement,FrameElement,RenderableDOMElement,ITextElement],SVGTextLottieElement),SVGTextLottieElement.prototype.createContent=function(){this.data.singleShape&&!this.globalData.fontManager.chars&&(this.textContainer=createNS("text"))},SVGTextLottieElement.prototype.buildTextContents=function(textArray){for(var i=0,len=textArray.length,textContents=[],currentTextContent="";i<len;)"\r"===textArray[i]||"\x03"===textArray[i]?(textContents.push(currentTextContent),currentTextContent=""):currentTextContent+=textArray[i],i+=1;return textContents.push(currentTextContent),textContents},SVGTextLottieElement.prototype.buildShapeData=function(data,scale){if(data.shapes&&data.shapes.length){var shape=data.shapes[0];if(shape.it){var shapeItem=shape.it[shape.it.length-1];shapeItem.s&&(shapeItem.s.k[0]=scale,shapeItem.s.k[1]=scale)}}return data},SVGTextLottieElement.prototype.buildNewText=function(){this.addDynamicProperty(this);var documentData=this.textProperty.currentData;this.renderedLetters=createSizedArray(documentData?documentData.l.length:0),documentData.fc?this.layerElement.setAttribute("fill",this.buildColor(documentData.fc)):this.layerElement.setAttribute("fill","rgba(0,0,0,0)"),documentData.sc&&(this.layerElement.setAttribute("stroke",this.buildColor(documentData.sc)),this.layerElement.setAttribute("stroke-width",documentData.sw)),this.layerElement.setAttribute("font-size",documentData.finalSize);var fontData=this.globalData.fontManager.getFontByName(documentData.f);if(fontData.fClass)this.layerElement.setAttribute("class",fontData.fClass);else{this.layerElement.setAttribute("font-family",fontData.fFamily);var fWeight=documentData.fWeight,fStyle=documentData.fStyle;this.layerElement.setAttribute("font-style",fStyle),this.layerElement.setAttribute("font-weight",fWeight)}this.layerElement.setAttribute("aria-label",documentData.t);var letters=documentData.l||[],usesGlyphs=!!this.globalData.fontManager.chars;len=letters.length;var matrixHelper=this.mHelper,singleShape=this.data.singleShape,xPos=0,yPos=0,firstLine=!0,trackingOffset=.001*documentData.tr*documentData.finalSize;if(!singleShape||usesGlyphs||documentData.sz){var cachedSpansLength=this.textSpans.length;for(i=0;i<len;i+=1){if(this.textSpans[i]||(this.textSpans[i]={span:null,childSpan:null,glyph:null}),!usesGlyphs||!singleShape||0===i){if(tSpan=cachedSpansLength>i?this.textSpans[i].span:createNS(usesGlyphs?"g":"text"),cachedSpansLength<=i){if(tSpan.setAttribute("stroke-linecap","butt"),tSpan.setAttribute("stroke-linejoin","round"),tSpan.setAttribute("stroke-miterlimit","4"),this.textSpans[i].span=tSpan,usesGlyphs){var childSpan=createNS("g");tSpan.appendChild(childSpan),this.textSpans[i].childSpan=childSpan}this.textSpans[i].span=tSpan,this.layerElement.appendChild(tSpan)}tSpan.style.display="inherit"}if(matrixHelper.reset(),singleShape&&(letters[i].n&&(xPos=-trackingOffset,yPos+=documentData.yOffset+(firstLine?1:0),firstLine=!1),this.applyTextPropertiesToMatrix(documentData,matrixHelper,letters[i].line,xPos,yPos),xPos+=(letters[i].l||0)+trackingOffset),usesGlyphs){if(1===(charData=this.globalData.fontManager.getCharData(documentData.finalText[i],fontData.fStyle,this.globalData.fontManager.getFontByName(documentData.f).fFamily)).t)glyphElement=new SVGCompElement(charData.data,this.globalData,this);else{var i,len,tSpan,charData,glyphElement,data=emptyShapeData;charData.data&&charData.data.shapes&&(data=this.buildShapeData(charData.data,documentData.finalSize)),glyphElement=new SVGShapeElement(data,this.globalData,this)}if(this.textSpans[i].glyph){var glyph=this.textSpans[i].glyph;this.textSpans[i].childSpan.removeChild(glyph.layerElement),glyph.destroy()}this.textSpans[i].glyph=glyphElement,glyphElement._debug=!0,glyphElement.prepareFrame(0),glyphElement.renderFrame(),this.textSpans[i].childSpan.appendChild(glyphElement.layerElement),1===charData.t&&this.textSpans[i].childSpan.setAttribute("transform","scale("+documentData.finalSize/100+","+documentData.finalSize/100+")")}else singleShape&&tSpan.setAttribute("transform","translate("+matrixHelper.props[12]+","+matrixHelper.props[13]+")"),tSpan.textContent=letters[i].val,tSpan.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve")}singleShape&&tSpan&&tSpan.setAttribute("d","")}else{var tElement=this.textContainer,justify="start";switch(documentData.j){case 1:justify="end";break;case 2:justify="middle";break;default:justify="start"}tElement.setAttribute("text-anchor",justify),tElement.setAttribute("letter-spacing",trackingOffset);var textContent=this.buildTextContents(documentData.finalText);for(i=0,len=textContent.length,yPos=documentData.ps?documentData.ps[1]+documentData.ascent:0;i<len;i+=1)(tSpan=this.textSpans[i].span||createNS("tspan")).textContent=textContent[i],tSpan.setAttribute("x",0),tSpan.setAttribute("y",yPos),tSpan.style.display="inherit",tElement.appendChild(tSpan),this.textSpans[i]||(this.textSpans[i]={span:null,glyph:null}),this.textSpans[i].span=tSpan,yPos+=documentData.finalLineHeight;this.layerElement.appendChild(tElement)}for(;i<this.textSpans.length;)this.textSpans[i].span.style.display="none",i+=1;this._sizeChanged=!0},SVGTextLottieElement.prototype.sourceRectAtTime=function(){if(this.prepareFrame(this.comp.renderedFrame-this.data.st),this.renderInnerContent(),this._sizeChanged){this._sizeChanged=!1;var textBox=this.layerElement.getBBox();this.bbox={top:textBox.y,left:textBox.x,width:textBox.width,height:textBox.height}}return this.bbox},SVGTextLottieElement.prototype.getValue=function(){var i,glyphElement,len=this.textSpans.length;for(i=0,this.renderedFrame=this.comp.renderedFrame;i<len;i+=1)(glyphElement=this.textSpans[i].glyph)&&(glyphElement.prepareFrame(this.comp.renderedFrame-this.data.st),glyphElement._mdf&&(this._mdf=!0))},SVGTextLottieElement.prototype.renderInnerContent=function(){if(this.validateText(),(!this.data.singleShape||this._mdf)&&(this.textAnimator.getMeasures(this.textProperty.currentData,this.lettersChangedFlag),this.lettersChangedFlag||this.textAnimator.lettersChangedFlag)){this._sizeChanged=!0;var i,len,renderedLetter,textSpan,glyphElement,renderedLetters=this.textAnimator.renderedLetters,letters=this.textProperty.currentData.l;for(i=0,len=letters.length;i<len;i+=1)!letters[i].n&&(renderedLetter=renderedLetters[i],textSpan=this.textSpans[i].span,(glyphElement=this.textSpans[i].glyph)&&glyphElement.renderFrame(),renderedLetter._mdf.m&&textSpan.setAttribute("transform",renderedLetter.m),renderedLetter._mdf.o&&textSpan.setAttribute("opacity",renderedLetter.o),renderedLetter._mdf.sw&&textSpan.setAttribute("stroke-width",renderedLetter.sw),renderedLetter._mdf.sc&&textSpan.setAttribute("stroke",renderedLetter.sc),renderedLetter._mdf.fc&&textSpan.setAttribute("fill",renderedLetter.fc))}},extendPrototype([IImageElement],ISolidElement),ISolidElement.prototype.createContent=function(){var rect=createNS("rect");rect.setAttribute("width",this.data.sw),rect.setAttribute("height",this.data.sh),rect.setAttribute("fill",this.data.sc),this.layerElement.appendChild(rect)},NullElement.prototype.prepareFrame=function(num){this.prepareProperties(num,!0)},NullElement.prototype.renderFrame=function(){},NullElement.prototype.getBaseElement=function(){return null},NullElement.prototype.destroy=function(){},NullElement.prototype.sourceRectAtTime=function(){},NullElement.prototype.hide=function(){},extendPrototype([BaseElement,TransformElement,HierarchyElement,FrameElement],NullElement),extendPrototype([BaseRenderer],SVGRendererBase),SVGRendererBase.prototype.createNull=function(data){return new NullElement(data,this.globalData,this)},SVGRendererBase.prototype.createShape=function(data){return new SVGShapeElement(data,this.globalData,this)},SVGRendererBase.prototype.createText=function(data){return new SVGTextLottieElement(data,this.globalData,this)},SVGRendererBase.prototype.createImage=function(data){return new IImageElement(data,this.globalData,this)},SVGRendererBase.prototype.createSolid=function(data){return new ISolidElement(data,this.globalData,this)},SVGRendererBase.prototype.configAnimation=function(animData){this.svgElement.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.svgElement.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),this.renderConfig.viewBoxSize?this.svgElement.setAttribute("viewBox",this.renderConfig.viewBoxSize):this.svgElement.setAttribute("viewBox","0 0 "+animData.w+" "+animData.h),this.renderConfig.viewBoxOnly||(this.svgElement.setAttribute("width",animData.w),this.svgElement.setAttribute("height",animData.h),this.svgElement.style.width="100%",this.svgElement.style.height="100%",this.svgElement.style.transform="translate3d(0,0,0)",this.svgElement.style.contentVisibility=this.renderConfig.contentVisibility),this.renderConfig.width&&this.svgElement.setAttribute("width",this.renderConfig.width),this.renderConfig.height&&this.svgElement.setAttribute("height",this.renderConfig.height),this.renderConfig.className&&this.svgElement.setAttribute("class",this.renderConfig.className),this.renderConfig.id&&this.svgElement.setAttribute("id",this.renderConfig.id),void 0!==this.renderConfig.focusable&&this.svgElement.setAttribute("focusable",this.renderConfig.focusable),this.svgElement.setAttribute("preserveAspectRatio",this.renderConfig.preserveAspectRatio),this.animationItem.wrapper.appendChild(this.svgElement);var defs=this.globalData.defs;this.setupGlobalData(animData,defs),this.globalData.progressiveLoad=this.renderConfig.progressiveLoad,this.data=animData;var maskElement=createNS("clipPath"),rect=createNS("rect");rect.setAttribute("width",animData.w),rect.setAttribute("height",animData.h),rect.setAttribute("x",0),rect.setAttribute("y",0);var maskId=createElementID();maskElement.setAttribute("id",maskId),maskElement.appendChild(rect),this.layerElement.setAttribute("clip-path","url("+getLocationHref()+"#"+maskId+")"),defs.appendChild(maskElement),this.layers=animData.layers,this.elements=createSizedArray(animData.layers.length)},SVGRendererBase.prototype.destroy=function(){this.animationItem.wrapper&&(this.animationItem.wrapper.innerText=""),this.layerElement=null,this.globalData.defs=null;var i,len=this.layers?this.layers.length:0;for(i=0;i<len;i+=1)this.elements[i]&&this.elements[i].destroy&&this.elements[i].destroy();this.elements.length=0,this.destroyed=!0,this.animationItem=null},SVGRendererBase.prototype.updateContainerSize=function(){},SVGRendererBase.prototype.findIndexByInd=function(ind){var i=0,len=this.layers.length;for(i=0;i<len;i+=1)if(this.layers[i].ind===ind)return i;return -1},SVGRendererBase.prototype.buildItem=function(pos){var elements=this.elements;if(!elements[pos]&&99!==this.layers[pos].ty){elements[pos]=!0;var element=this.createItem(this.layers[pos]);if(elements[pos]=element,getExpressionsPlugin()&&(0===this.layers[pos].ty&&this.globalData.projectInterface.registerComposition(element),element.initExpressions()),this.appendElementInPos(element,pos),this.layers[pos].tt){var elementIndex="tp"in this.layers[pos]?this.findIndexByInd(this.layers[pos].tp):pos-1;if(-1===elementIndex)return;if(this.elements[elementIndex]&&!0!==this.elements[elementIndex]){var matteMask=elements[elementIndex].getMatte(this.layers[pos].tt);element.setMatte(matteMask)}else this.buildItem(elementIndex),this.addPendingElement(element)}}},SVGRendererBase.prototype.checkPendingElements=function(){for(;this.pendingElements.length;){var element=this.pendingElements.pop();if(element.checkParenting(),element.data.tt)for(var i=0,len=this.elements.length;i<len;){if(this.elements[i]===element){var elementIndex="tp"in element.data?this.findIndexByInd(element.data.tp):i-1,matteMask=this.elements[elementIndex].getMatte(this.layers[i].tt);element.setMatte(matteMask);break}i+=1}}},SVGRendererBase.prototype.renderFrame=function(num){if(this.renderedFrame!==num&&!this.destroyed){null===num?num=this.renderedFrame:this.renderedFrame=num,this.globalData.frameNum=num,this.globalData.frameId+=1,this.globalData.projectInterface.currentFrame=num,this.globalData._mdf=!1;var i,len=this.layers.length;for(this.completeLayers||this.checkLayers(num),i=len-1;i>=0;i-=1)(this.completeLayers||this.elements[i])&&this.elements[i].prepareFrame(num-this.layers[i].st);if(this.globalData._mdf)for(i=0;i<len;i+=1)(this.completeLayers||this.elements[i])&&this.elements[i].renderFrame()}},SVGRendererBase.prototype.appendElementInPos=function(element,pos){var nextElement,newElement=element.getBaseElement();if(newElement){for(var i=0;i<pos;)this.elements[i]&&!0!==this.elements[i]&&this.elements[i].getBaseElement()&&(nextElement=this.elements[i].getBaseElement()),i+=1;nextElement?this.layerElement.insertBefore(newElement,nextElement):this.layerElement.appendChild(newElement)}},SVGRendererBase.prototype.hide=function(){this.layerElement.style.display="none"},SVGRendererBase.prototype.show=function(){this.layerElement.style.display="block"},extendPrototype([BaseElement,TransformElement,HierarchyElement,FrameElement,RenderableDOMElement],ICompElement),ICompElement.prototype.initElement=function(data,globalData,comp){this.initFrame(),this.initBaseData(data,globalData,comp),this.initTransform(data,globalData,comp),this.initRenderable(),this.initHierarchy(),this.initRendererElement(),this.createContainerElements(),this.createRenderableComponents(),(this.data.xt||!globalData.progressiveLoad)&&this.buildAllItems(),this.hide()},ICompElement.prototype.prepareFrame=function(num){if(this._mdf=!1,this.prepareRenderableFrame(num),this.prepareProperties(num,this.isInRange),this.isInRange||this.data.xt){if(this.tm._placeholder)this.renderedFrame=num/this.data.sr;else{var i,timeRemapped=this.tm.v;timeRemapped===this.data.op&&(timeRemapped=this.data.op-1),this.renderedFrame=timeRemapped}var len=this.elements.length;for(this.completeLayers||this.checkLayers(this.renderedFrame),i=len-1;i>=0;i-=1)(this.completeLayers||this.elements[i])&&(this.elements[i].prepareFrame(this.renderedFrame-this.layers[i].st),this.elements[i]._mdf&&(this._mdf=!0))}},ICompElement.prototype.renderInnerContent=function(){var i,len=this.layers.length;for(i=0;i<len;i+=1)(this.completeLayers||this.elements[i])&&this.elements[i].renderFrame()},ICompElement.prototype.setElements=function(elems){this.elements=elems},ICompElement.prototype.getElements=function(){return this.elements},ICompElement.prototype.destroyElements=function(){var i,len=this.layers.length;for(i=0;i<len;i+=1)this.elements[i]&&this.elements[i].destroy()},ICompElement.prototype.destroy=function(){this.destroyElements(),this.destroyBaseElement()},extendPrototype([SVGRendererBase,ICompElement,SVGBaseElement],SVGCompElement),SVGCompElement.prototype.createComp=function(data){return new SVGCompElement(data,this.globalData,this)},extendPrototype([SVGRendererBase],SVGRenderer),SVGRenderer.prototype.createComp=function(data){return new SVGCompElement(data,this.globalData,this)},value=SVGRenderer,renderers.svg=value,ShapeModifiers.registerModifier("tm",TrimModifier),ShapeModifiers.registerModifier("pb",PuckerAndBloatModifier),ShapeModifiers.registerModifier("rp",RepeaterModifier),ShapeModifiers.registerModifier("rd",RoundCornersModifier),ShapeModifiers.registerModifier("zz",ZigZagModifier),ShapeModifiers.registerModifier("op",OffsetPathModifier),lottie},module.exports=factory())}}]);